From c8fc075ad6475080b0c20c898e846530b9f2f3e5 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Mon, 23 Sep 2024 15:26:26 +0300 Subject: [PATCH] fix EnrollmetFlow and EnrollmentFlowSteps fields --- app/templates/EnrollmentFlowSteps/fields.inc | 19 +++++---- app/templates/EnrollmentFlows/fields.inc | 43 ++++++++++++-------- 2 files changed, 38 insertions(+), 24 deletions(-) diff --git a/app/templates/EnrollmentFlowSteps/fields.inc b/app/templates/EnrollmentFlowSteps/fields.inc index 4eb841b48..d24a674fd 100644 --- a/app/templates/EnrollmentFlowSteps/fields.inc +++ b/app/templates/EnrollmentFlowSteps/fields.inc @@ -27,13 +27,16 @@ // This view does not support read-only if($vv_action == 'add' || $vv_action == 'edit') { - print $this->Field->control('description'); - print $this->Field->control('status'); - - print $this->Field->control('plugin'); - - print $this->Field->control('ordr'); - - print $this->Field->control('actor_type'); + foreach (['description', + 'status', + 'plugin', + 'ordr', + 'actor_type', + ] as $field) { + print $this->element('form/listItem', [ + 'arguments' => [ + 'fieldName' => $field + ]]); + } } diff --git a/app/templates/EnrollmentFlows/fields.inc b/app/templates/EnrollmentFlows/fields.inc index f7513ede2..b6e9b5ec4 100644 --- a/app/templates/EnrollmentFlows/fields.inc +++ b/app/templates/EnrollmentFlows/fields.inc @@ -52,24 +52,35 @@ Field->control('name'); - print $this->Field->control('status'); - -// print $this->Field->control('sor_label'); + foreach ( ['name', + 'status', +// 'sor_label', + ] as $field) { + print $this->element('form/listItem', [ + 'arguments' => [ + 'fieldName' => $field + ]]); + } - print $this->Field->control( - fieldName: 'authz_type', - options: [ - 'onChange' => 'updateGadgets()' + print $this->element('form/listItem', [ + 'arguments' => [ + 'fieldName' => 'authz_type', + 'fieldOptions' => [ + 'onChange' => 'updateGadgets()' + ] ] - ); - - print $this->Field->control('authz_cou_id'); + ]); - print $this->Field->control('authz_group_id'); - - print $this->Field->control('collect_enrollee_email'); - - print $this->Field->control('redirect_on_finalize'); + foreach (['authz_cou_id', + 'authz_group_id', + 'collect_enrollee_email', + 'collect_enrollee_email', + 'redirect_on_finalize', + ] as $field) { + print $this->element('form/listItem', [ + 'arguments' => [ + 'fieldName' => $field + ]]); + } }