I've got a custom handler for ContentService.Saving of an object, I'd like to be able to set the default values for some DocType fields when the node is first created. I've looked around and seen metion that it wasn't possible in 7.0.0 but should be by 7.0.1 . I'm currently running the latest nightly of 7.0.2 and am wondering if someone could point me in the right direction to either docs or a sample bit of code?
A package that does the job would be nice but I was even thinking of something like Application Handler like "ContentService.Creating += ContentService_Creating;" but we're not supposed to use that, and Saving seems to happen too late in the process or doesn't get wired to the js/control correctly. In particular, I'm looking to see if a DateTime filed has a value set when a new node is created, if not set it to DateTime.Now.
v7 Possible to set default field values yet?
I've got a custom handler for ContentService.Saving of an object, I'd like to be able to set the default values for some DocType fields when the node is first created. I've looked around and seen metion that it wasn't possible in 7.0.0 but should be by 7.0.1 . I'm currently running the latest nightly of 7.0.2 and am wondering if someone could point me in the right direction to either docs or a sample bit of code?
Any help is greatly appreciated.
Regards,
Phill
Hello,
Do you mean something like the Standerd Values packages, but than for v7? I don't think that's possible yet.
Jeroen
Hi Jeroen,
A package that does the job would be nice but I was even thinking of something like Application Handler like "ContentService.Creating += ContentService_Creating;" but we're not supposed to use that, and Saving seems to happen too late in the process or doesn't get wired to the js/control correctly. In particular, I'm looking to see if a DateTime filed has a value set when a new node is created, if not set it to DateTime.Now.
Phill
is working on a reply...