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.

General Questions /

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

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

Missing Add-button in getCMSFields_forPopup


Reply


2 Posts   352 Views

Avatar
esakrielaart

Community Member, 56 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, 1098 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...