问题描述
我创建了一个自定义内容元素“ accordion”,该元素具有可变数量的手风琴元素。这些元素具有标题,文本和一个小图标。即使我使用了不赞成使用的属性值,它在T3 9.5中也能正常工作。
好吧,在T3 10中,它们最终got dropped,在尝试编辑后端的内容元素时导致错误(但在FE中仍然可以正常工作)。
表tt_content中的“图像”字段的TCA internal_type必须设置为“ db”或“文件夹”。
这是我当前的FlexForm XML
<T3DataStructure>
<meta>
<langDisable>1</langDisable>
</meta>
<sheets>
<main>
<ROOT>
<TCEforms>
<sheetTitle>Accordion</sheetTitle>
</TCEforms>
<type>array</type>
<el>
<settings.accordion type="array">
<title>Accordion</title>
<type>array</type>
<section>1</section>
<el>
<accordionConfiguration>
<type>array</type>
<title>Accordion Element</title>
<el>
<title>
<TCEforms>
<label>Title</label>
<config>
<type>input</type>
<max>100</max>
<eval>trim</eval>
</config>
</TCEforms>
</title>
<text>
<TCEforms>
<label>Content</label>
<config>
<type>text</type>
<enableRichtext>1</enableRichtext>
</config>
</TCEforms>
</text>
<image>
<TCEforms>
<label>Image</label>
<config>
<type>group</type>
<internal_type>file</internal_type>
<allowed>jpg,gif,png</allowed>
<max_size>2000</max_size>
<uploadfolder>fileadmin/user_upload</uploadfolder>
<show_thumbs>FALSE</show_thumbs>
<size>1</size>
<minitems>0</minitems>
<maxitems>1</maxitems>
</config>
</TCEforms>
</image>
</el>
</accordionConfiguration>
</el>
</settings.accordion>
</el>
</ROOT>
</main>
</sheets>
</T3DataStructure>
我试图解决这个问题:
...
<image>
<TCEforms>
<label>Image</label>
<config>
<type>inline</type>
<foreign_table>sys_file_reference</foreign_table>
<foreign_table_field>tablenames</foreign_table_field>
<foreign_label>uid_local</foreign_label>
<foreign_sortby>sorting_foreign</foreign_sortby>
<foreign_selector>uid_local</foreign_selector>
<minitems>1</minitems>
<maxitems>1</maxitems>
<foreign_selector_fieldTcaOverride type="array">
<config>
<appearance>
<elementBrowserType>file</elementBrowserType>
<elementBrowserAllowed>jpg,png</elementBrowserAllowed>
</appearance>
</config>
</foreign_selector_fieldTcaOverride>
<foreign_match_fields type="array">
<fieldname>image</fieldname>
</foreign_match_fields>
<appearance type="array">
<newRecordLinkAddTitle>1</newRecordLinkAddTitle>
<headerThumbnail>
<field>uid_local</field>
<height>64</height>
<width>64</width>
</headerThumbnail>
</appearance>
</config>
</TCEforms>
</image>
...
如果我用上面的代码替换<image>
部分,则会收到新错误。
字段名称“ pi_flexform”上的无效flex表单数据结构,带有 节容器“ accordionConfiguration”中的元素“ image”:嵌套 不允许在flex表单部分中使用内联元素。
我不确定是否可以像我一样使用手风琴。 Checking the Bootstrap Package,他们使用了完全不同的方法(老实说我不喜欢)。是否有修复程序可以保持它过去的工作方式?
谢谢!
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)