Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Missing Add-button in getCMSFields_forPopup


Go to End


2 Posts   683 Views

Avatar
esakrielaart

Community Member, 59 Posts

18 October 2011 at 4:41am

(Also see: http://www.silverstripe.org/general-questions/show/15576; same problem)

Hi,

I have an ArticleHolder/ArticleContent DataObject which contains certain data. Also I have an InvoicePersonal, InvoiceHolder and InvoiceContent class, which respectively contain personal details, packages and package content. Last two both refer to the Article Dataobjects.

The relation between them are all one_to_many, so one InvoiceHolder contains many ArticleHolders, one InvoiceHolder contains many InvoiceContents which on turn contains one ArticleContent per row.

Now I can add all InvoiceHolder stuff, but than I get an popup where I can edit the InvoiceContent of an InvoiceHolder. This unfortunatelly does not show an Add-button.

I think I have to define a complex table field myself, based on the URL posted above, I only do not know exactly where or how. ny help for this will be appreceated.

Thanks in advance,
Maurice

Avatar
martimiz

Forum Moderator, 1391 Posts

18 October 2011 at 10:45pm

I don't think you can add a ComplexTableField to another CTF's popup, unless it's read-only. Otherwise you'd have to call a popup on top of another popup, involving lot's of Ajax requests on top of each other...

For these types of relation chains, the way to go would probably be ModelAdmin...