diff --git a/.vscode/ftp-kr.sync.cache.json b/.vscode/ftp-kr.sync.cache.json index 48b4aa1..246dba8 100644 --- a/.vscode/ftp-kr.sync.cache.json +++ b/.vscode/ftp-kr.sync.cache.json @@ -63,6 +63,12 @@ "modified": false }, "controls": { + "class.BackendSites.php": { + "type": "-", + "size": 2508, + "lmtime": 1746373999381, + "modified": false + }, "class.Crm.php": { "type": "-", "size": 1824, @@ -101,8 +107,8 @@ }, "class.Users.php": { "type": "-", - "size": 3591, - "lmtime": 0, + "size": 3681, + "lmtime": 1746370508373, "modified": false }, "class.Wiki.php": { @@ -113,6 +119,12 @@ } }, "factory": { + "class.BackendSites.php": { + "type": "-", + "size": 2566, + "lmtime": 1746374004947, + "modified": false + }, "class.Crm.php": { "type": "-", "size": 1863, @@ -191,20 +203,20 @@ "layout": { "style.css": { "type": "-", - "size": 22469, - "lmtime": 1744580016978, + "size": 22689, + "lmtime": 1746373939657, "modified": false }, "style.css.map": { "type": "-", - "size": 39280, - "lmtime": 1744580016978, + "size": 39717, + "lmtime": 1746373939656, "modified": false }, "style.scss": { "type": "-", - "size": 27332, - "lmtime": 1744580016556, + "size": 27607, + "lmtime": 1746373939490, "modified": false } }, @@ -349,6 +361,46 @@ "lmtime": 0, "modified": false } + }, + "grid": { + "templates": { + "container.php": { + "type": "-", + "size": 16603, + "lmtime": 1746371511458, + "modified": false + }, + "edit.php": { + "type": "-", + "size": 6041, + "lmtime": 0, + "modified": false + }, + "edit-simple.php": { + "type": "-", + "size": 10753, + "lmtime": 0, + "modified": false + }, + "print.php": { + "type": "-", + "size": 5140, + "lmtime": 0, + "modified": false + }, + "results.php": { + "type": "-", + "size": 20382, + "lmtime": 0, + "modified": false + }, + "upload.php": { + "type": "-", + "size": 6498, + "lmtime": 0, + "modified": false + } + } } }, "robots.txt": { @@ -359,6 +411,32 @@ }, "temp": {}, "templates": { + "backpro": {}, + "crm": {}, + "cron": {}, + "finances": {}, + "html": {}, + "projects": {}, + "site": { + "layout-cron.php": { + "type": "-", + "size": 5804, + "lmtime": 0, + "modified": false + }, + "layout-logged.php": { + "type": "-", + "size": 6017, + "lmtime": 1746372845193, + "modified": false + }, + "layout-unlogged.php": { + "type": "-", + "size": 986, + "lmtime": 0, + "modified": false + } + }, "tasks": { "filtr_save_form.php": { "type": "-", @@ -403,23 +481,31 @@ "modified": false } }, - "site": { - "layout-cron.php": { + "users": {}, + "wiki": {}, + "backend_sites": { + "collective_topic_edit.php": { "type": "-", - "size": 5804, - "lmtime": 0, + "size": 1859, + "lmtime": 1746372498433, "modified": false }, - "layout-logged.php": { + "collective_topics.php": { "type": "-", - "size": 5556, - "lmtime": 1744321038374, + "size": 1801, + "lmtime": 1746373172486, "modified": false }, - "layout-unlogged.php": { + "topic_edit.php": { "type": "-", - "size": 986, - "lmtime": 0, + "size": 2079, + "lmtime": 1746373620277, + "modified": false + }, + "topics.php": { + "type": "-", + "size": 2493, + "lmtime": 1746376040917, "modified": false } } diff --git a/templates/site/layout-logged.php b/templates/site/layout-logged.php index decd971..ecfc89b 100644 --- a/templates/site/layout-logged.php +++ b/templates/site/layout-logged.php @@ -22,6 +22,7 @@ + @@ -31,6 +32,7 @@ +
diff --git a/templates/tasks/task_edit.php b/templates/tasks/task_edit.php index 659f575..add1142 100644 --- a/templates/tasks/task_edit.php +++ b/templates/tasks/task_edit.php @@ -26,32 +26,41 @@ ob_start(); ] ); ?> -= -\Html::input( - [ - 'label' => 'Data rozpoczęcia', - 'name' => 'date_start', - 'id' => 'date_start', - 'value' => $this -> task[ 'date_start' ], - 'class' => 'datetime', - 'inline' => true, - 'autocomplete' => 'off' - ] -); -?> -= -\Html::input( - [ - 'label' => 'Data zakończenia', - 'name' => 'date_end', - 'id' => 'date_end', - 'value' => $this -> task[ 'date_end' ], - 'class' => 'datetime', - 'inline' => true, - 'autocomplete' => 'off' - ] -); + +if ( $this -> task['date_start'] ) + $date_start = date( 'Y-m-d', strtotime( $this -> task['date_start'] ) ); +else +{ + if ( !$this -> task['id'] ) + $date_start = date( 'Y-m-d' ); +} + +if ( $this -> task['date_end'] ) + $date_end = date( 'Y-m-d', strtotime( $this -> task['date_end'] ) ); +else +{ + if ( !$this -> task['id'] ) + $date_end = date( 'Y-m-d' ); +} ?> += \Html::input([ + 'label' => 'Data rozpoczęcia', + 'name' => 'date_start', + 'id' => 'date_start', + 'value' => $date_start, + 'class' => 'datetime', + 'inline' => true, + 'autocomplete' => 'off' +]);?> += \Html::input([ + 'label' => 'Data zakończenia', + 'name' => 'date_end', + 'id' => 'date_end', + 'value' => $date_end, + 'class' => 'datetime', + 'inline' => true, + 'autocomplete' => 'off' +]);?> $projects[ 0 ] = '--- wybierz projekt ---'; if ( is_array( $this -> projects ) ) @@ -141,7 +150,7 @@ if ( is_array( $this -> priorities ) ) 'label' => 'Powiadom o zmianie statusu', 'name' => 'status_change_mail', 'id' => 'status_change_mail', - 'checked' => $this -> task[ 'status_change_mail' ] ? true : false, + 'checked' => ( $this -> task[ 'status_change_mail' ] or !$this -> taks['id'] ) ? true : false, 'type' => 'checkbox' ] ); ?> @@ -200,7 +209,7 @@ if ( is_array( $this -> priorities ) ) 'label' => 'Pokaż w kalendarzu', 'name' => 'show_in_calendar', 'id' => 'show_in_calendar', - 'checked' => $this -> task[ 'show_in_calendar' ] ? true : false, + 'checked' => ( $this -> task[ 'show_in_calendar' ] or !$this -> taks['id'] ) ? true : false, 'type' => 'checkbox' ] ); ?> @@ -246,6 +255,11 @@ echo $grid -> draw();