Hello,
I migrated to omeka-s v4.0.4 recently.
I had a very long, ugly and convenient custom version of view/omeka/site/item/show.phtml in my theme.
In that file I wrote php functions and php rendering lines to show up some (filtered) data from some (filtered) linked items. (see issue1966).
I also created some viewFile
for displaying, in an item page, the content of another item.
Now I should port this to block layout
I read the doc for dev and Iām lost.
I think I need to create a new block (or more).
This doc page āmodule/Page blocksā is a basic requirement only.
btw why is this page sorted in the āmoduleā section, and not āthemeā section?
ā should I
- first create a module that does the job (gathering and filtering),
- then create a theme which call this ājobā to be displayed?
Indeed the new block definition (extending the AbstractBlockLayout
) seems to be located in src/Site/BlockLayout directory. This directory not rewritable by the theme, is it?
In the doc, elsewhere, I also found the section Updating An Existing Custom Show Page to Use Resource Page Blocks. But no new block is displayed, only existing standard blocks are re-used.
What are the files I have to create, and what should they contain?
Iām sorry Iām really into php and MVC architecture (but react ).
I canāt find any example of a definition of a new block used to show something new in e.g. item/show.phtml
An example is really what I need.
Is it a very special case?
Is the doc clear about this and I didnāt succeed in understanding it?
thank you for your help.