module == 'product' && in_array($action->method, array('requirement', 'epic'))) ? 'browse' : $action->method; $disabledFields = in_array($actionMethod, $config->workflowaction->defaultActions) ? zget($config->workflowlayout->disabledFields, $actionMethod, '') : $config->workflowlayout->disabledFields['custom']; $controlList = array('select', 'multi-select', 'checkbox', 'radio', 'date', 'datetime'); $dateControlList = array('date', 'datetime'); $requiredFields = zget($config->workflowlayout->default->required, $action->action, array()); if($flow->approval == 'enabled') $requiredFields = array_merge($requiredFields, zget($config->workflowlayout->approval->required, $action->action, array())); ?> $field):?> show) continue; if(strpos(",{$disabledFields},", ",{$key},") !== false) continue; if(isset($field->hasAction) && !$field->hasAction) $field->defaultValue = $field->default; $required = in_array($key, $requiredFields); $fixed = $required ? 'required' : 'enabled'; $show = $field->show == '1'; $subTable = isset($subTables[$key]); $disabled = $mode == 'edit' ? '' : "disabled='disabled'"; $readonly = ''; if($subTable) $disabled = "disabled='disabled'"; if($mode == 'edit' && !empty($flow->belong) && $field->field == $flow->belong && ($action->action == 'create' || $action->action == 'batchcreate')) { $required = true; $disabled = "disabled='disabled'"; } ?> ' data-fixed='' data-module='module;?>' data-field='field;?>' data-control='control;?>'> type, $config->workflowfield->numberTypes) && strpos(",{$config->workflowlayout->noTotalFields},", ",{$field->field},") === false):?> control != 'file'):?> type == 'batch' && $action->batchMode == 'different')):?> layout == 'side'):?> type == 'single' && !in_array($actionMethod, $config->workflowaction->readonlyActions) && $field->field != 'actions' && $actionMethod != 'browse'):?>
name;?> workflowlayout->require})";?>
workflowlayout->summary;?> workflowlayout->summaryList, !empty($field->summary) ? $field->summary: 0, "class='form-control chosen' multiple $disabled");?>
workflowlayout->width;?> width, "id='width{$key}' class='form-control' readonly");?>
workflowlayout->layoutRules;?> layoutRules, "class='form-control chosen' multiple='multiple' $disabled");?>
workflowlayout->defaultValue;?> module}' data-field='{$field->field}'"; if($field->control == 'multi-select' or $field->control == 'checkbox') { echo html::select("defaultValue[$key][]", $field->options, $field->defaultValue, "id='defaultValue{$key}' class='form-control picker-select' multiple $data $disabled"); } else { echo html::select("defaultValue[$key]", array('' => '') + $field->options, $field->defaultValue, "id='defaultValue{$key}' class='form-control picker-select' $data $disabled"); } echo ""; if(in_array($field->control, $dateControlList)) { $class = 'form-' . $field->control; echo html::input("defaultValue[$key]", ($field->defaultValue && $field->defaultValue != 'currentTime') ? $field->defaultValue : '', "id='defaultValue{$key}' class='form-control $class' $disabled"); } else { echo html::input("defaultValue[$key]", (isset($field->defaultValue) && strpos(',currentUser,currentDept,currentTime,', ",$field->defaultValue,") === false) ? $field->defaultValue : '', "id='defaultValue{$key}' class='form-control' disabled='disabled'"); } $checked = ''; if(!in_array($field->control, $controlList)) $checked .= "checked='checked'"; if(in_array($field->control, $dateControlList) && !empty($field->defaultValue) && $field->defaultValue != 'currentTime') $checked .= "checked='checked'"; if(!in_array($field->control, $dateControlList)) $checked .= "disabled='disabled'"; ?>
/>
workflowlayout->defaultValue;?>
workflowlayout->mobileShow;?> workflowlayout->mobileList, !empty($field->mobileShow) ? $field->mobileShow : 0, "class='form-control' $disabled");?>
workflowlayout->alignment : $lang->workflowlayout->position;?> position) ? $field->position : zget($defaultPositions, $field->field, ''), "class='form-control' $disabled");?>
readonly ? "checked='checked'" : '';?> control == 'file') ? "disabled='disabled'" : '';?>
/>
workflowlayout->show : $lang->workflowlayout->hide;?>