mirror of
https://github.com/silverstripe/silverstripe-userforms.git
synced 2024-10-22 15:05:42 +00:00
BUGFIX: fixed using UDF with the workflow module which only publishs a page when its been modified and UDF was always returning false to any changes
This commit is contained in:
parent
2c1974eae2
commit
3257590dc8
@ -122,7 +122,7 @@ class UserDefinedForm extends Page {
|
|||||||
$field->doDeleteFromStage('Live');
|
$field->doDeleteFromStage('Live');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// publish the draft pages
|
// publish the draft pages
|
||||||
if($this->Fields()) {
|
if($this->Fields()) {
|
||||||
foreach($this->Fields() as $field) {
|
foreach($this->Fields() as $field) {
|
||||||
@ -210,6 +210,18 @@ class UserDefinedForm extends Page {
|
|||||||
new CheckboxField("ShowClearButton", _t('UserDefinedForm.SHOWCLEARFORM', 'Show Clear Form Button'), $this->ShowClearButton)
|
new CheckboxField("ShowClearButton", _t('UserDefinedForm.SHOWCLEARFORM', 'Show Clear Form Button'), $this->ShowClearButton)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return if this form has been modified on the stage site and not published.
|
||||||
|
* this is used on the workflow module and for a couple highlighting things
|
||||||
|
*
|
||||||
|
* @todo make this a bit smarter - the issue with userforms is that it uses several
|
||||||
|
* relationships to form fields which has a undefined amount of options so
|
||||||
|
* for now just say its always modified
|
||||||
|
*/
|
||||||
|
public function getIsModifiedOnStage() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user