From 2b1f4aed56c5bfbf014f3f871e9dcc336b5a31b7 Mon Sep 17 00:00:00 2001 From: Geo Halkiadakis Date: Wed, 24 May 2023 18:38:04 +0300 Subject: new application form is ready --- public/app/controllers/Office.php | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) (limited to 'public/app/controllers/Office.php') diff --git a/public/app/controllers/Office.php b/public/app/controllers/Office.php index 9eb2a4c..5038200 100644 --- a/public/app/controllers/Office.php +++ b/public/app/controllers/Office.php @@ -160,6 +160,9 @@ class Office { } + /** render application form + * + */ private static function render_application_form($opts) { // #1: user-id --------------------------------------------------------- @@ -170,15 +173,30 @@ class Office { // #3: inject default values ------------------------------------------- + $userData = Auth::user_data(); + // #3.1: inject user data $form_setup->defaults = json_decode( json_encode( - Auth::user_data(), JSON_UNESCAPED_UNICODE + $userData, JSON_UNESCAPED_UNICODE )); + // #3.2 inject `sector` and `position`