mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-26 20:18:52 +02:00
N°729 Form prefill : Allow to overload new methods in order to prefill search forms, creation forms and transition forms
SVN:trunk[5609]
This commit is contained in:
@@ -458,6 +458,9 @@ class ObjectController extends AbstractController
|
||||
// Retrieve action rules information to auto-fill the form if available
|
||||
// Preparing object
|
||||
$oApp['context_manipulator']->PrepareObject($aActionRules, $oObject);
|
||||
$aPrefillFormParam = array( 'user' => $_SESSION["auth_user"],
|
||||
'origin' => 'portal');
|
||||
$oObject->PrefillForm('creation_from_0', $aPrefillFormParam);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -515,6 +518,13 @@ class ObjectController extends AbstractController
|
||||
$aFormData['buttons']['submit']['label'] = Dict::S('Portal:Button:Apply');
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$aPrefillFormParam = array('user' => $_SESSION["auth_user"],
|
||||
'origin' => 'portal',
|
||||
'stimulus' => $oRequestParams->get('apply_stimulus')['code']);
|
||||
$oObject->PrefillForm('state_change', $aPrefillFormParam);
|
||||
}
|
||||
|
||||
// Preparing callback urls
|
||||
$aCallbackUrls = $oApp['context_manipulator']->GetCallbackUrls($oApp, $aActionRules, $oObject, $bModal);
|
||||
|
||||
Reference in New Issue
Block a user