TYPO3: new fields in TCEforms for localized pages - typo3

I know how to add fields to the pages table and placing them wherever I want in the TCEforms using the function addToAllTCAtypes(), no problem with that. However, the fields only appear for the pages in the default language, they don't in localized pages. Is there a way to make the added fields visible for any language?

As you can see in $TCA['pages']['ctrl']['transForeignTable'] the table pages uses an extra table for its localization.
Your new fields need to exist in that overlay table pages_language_overlay. Also have a look at this tables TCA, that'll help you out.

Related

Jhipster React Form Grid Layout Issue

I'm currently using the latest version of Jhipster 7.6.0 and Node 16.14.0. If we try to arrange form fields in column view in other words if we wrap ValidatedField to and , the field values are not populated during Edit mode of the page and the same is true for insert mode. The attached link is showing a simple layout change on the existing user management page, and we are trying to see Last Name and First Name in one row, and we are unable to see the value or update the value if we realign these fields in multiple columns views.
Does anyone know a simple workaround we can use ValidatedForm and ValidatedField in Row, Col, and regular CRUD works like with other pages generated by the framework? Please let me know if more clarification or detail is needed on this case.
Layout and code Sample from User Management page

How to add class in TinyMce table properties

In my application I make my TinyMCE readonly except several word in class editablecontent. It work perfectly, by using contenteditable attribute from HTML. Now I want to make certain table in TinyMCE editor can edit, only table with class editablecontent.
To do that, my plan is when user make an template, to make certain table that editable user set it in Table Properties. When user set it editable than javascript will add class in tag <table>. The principle is like add style in table properties.
In TinyMCE 4 and 5, you can use the table_class_list to configure a list of classes that can be applied to tables from the dialog you reference.
https://www.tiny.cloud/docs/plugins/opensource/table/#table_class_list
Here is a Tiny Fiddle example:
https://fiddle.tiny.cloud/w8haab

Typo3, set title for Mask Elements

I have a typo3 server and using the mask extension. When an editor creates a new mask element, there isnt a title in the list view. Its always "no title":
I checked the database and found the titles in the db in the field: tt_content.header but no way to set them automatically oder manually by an editor. Anyone have an idea how the title can be set automatically? Oder manually by an editor?
ext:mask has the option to reuse existing fields of tt_content for new kinds of content elements (CEs). use it to get the bonus of better interoperability with TYPO3.
TYPO3 has a logic how to show records (content elements) in the backend. one of it is the usage of the fields header and description. if you reuse these fields your CEs will look like others automatically.
If you use other fields you need to declare your fields for usage AND in case you change the kind of a CE from your kind to e.g. TEXT with Media the header stays.
Especially header is handled in the layout/partial of FSC or CSC global for any kind of CE. if the handling/rendering is changed (e.g. special layout) in an installation your CEs need special effort if they have their own building of the header.
Try to use the same fields as existing CEs and your life can be easier.
I'm having the same issue, but I found a way around it for the meantime. I edit the mask element and chenge its type to something elseโ€”like Textโ€”where I can set the title. After typing the title I save it, then change back to mask element and save again. This works by me without losing the content of the mask element. This way I can see the title in typo3 backend when I view as list or page or add content from another page. As I said, it doesn't solve the problem, but can help until there is a proper solution.
EDIT
I've just found another solution. You can add the title field to en existing mask element. To do it, go to ADMIN TOOLS > Mask, click your mask element to edit it. Add a new item by dragging the ๐—ฆ๐˜๐—ฟ๐—ถ๐—ป๐—ด item (the one on top of the list of available items) to the right where your items are. Then in General under ๐—–๐—ต๐—ผ๐—ผ๐˜€๐—ฒ ๐—ณ๐—ถ๐—ฒ๐—น๐—ฑ dropdown choose an ๐—˜๐˜…๐—ถ๐˜€๐˜๐—ถ๐—ป๐—ด named:
๐—›๐—ฒ๐—ฎ๐—ฑ๐—ฒ๐—ฟ: (๐—ต๐—ฒ๐—ฎ๐—ฑ๐—ฒ๐—ฟ)
Save, close, go to your page to add your title. This still doesn't add the title field automatically to all mask elements, but it is a step forward.
If anywhere, you should be able to set a static title automatically in your page tsconfig. You could to something like
mod.wizards.newContentElement.wizardItems.mask.elements.[title of your mask element].tt_content_defValues {
header = My Awesome title
}
Personally, I usually give every mask element a header field and ask content editors to fill it in.
See also this discussion on Mask elements and backend titles.
Hope, this helps.

Sulu CMS admin: is there a way to add new content automatically to the "top" of the order list?

In a situation where, for instance, a user creates a new news_item content under a news content that already has several items of the news_item type (or any other type, for that matter), the new content will be added to the bottom of the already existing volume of news_item content.
However, after adding several dozens of content-items, it's pretty annoying for the user to scroll all the way down to find the most recent item (and then often reorder it to get it all the way to the top).
Is there a setting somewhere that you can manipulate in order to make Sulu add new content to the top instead of to the bottom of an existing body of content?
I am sorry to say that this is currently not possible... Except you try to override some behavior, but I don't think that can be done in a reasonable amount of time...

Tab control to autoenter field contents

I have a set of tabs inside the window items layout in the database file.
when I click the plus popover button, I want it to generate a new record in the products layout and fill out all the fields based on the active tabs and the extra description field based on the last edit box field at the bottom of the tabs. can someone help me do this as I have tried a few different scripts and have had no success. once the record has been created in the products layout/table, I also want it to generate a record in the window item table based on the linked itemid field and the autoenter calculation that is setup on the description field.
this is probably all very confusing but I would be glad of any help you can offer.
Window Item Database Copy
Your question is more a problem than a question.
I'm assuming your questions:
1) should I use a script trigger for that?
Probably not. You should use a button to call the script, it should create all the records you need, come back to the layout and open the popover.
2) how to check the active tabs?
You should you the getLayoutObjectAttribute ( , "isFrontPanel" ). That will allow you to correctly set the ifs.
3) how to create a record in any table?
to be honest, you should start by going to the layout you want and then creating the record. That's an easier way.
What you are trying to accomplish is not that hard. You just need to break it in smaller steps.