* TODO create function split version 3.
This commit is contained in:
@@ -41,6 +41,4 @@ $config->todo->objectList = array();
|
||||
$config->todo->objectList['bug'] = 'bugs';
|
||||
$config->todo->objectList['task'] = 'tasks';
|
||||
$config->todo->objectList['story'] = 'stories';
|
||||
$config->todo->objectList['testtask'] = 'testtasks';
|
||||
|
||||
include 'config/form.php';
|
||||
$config->todo->objectList['testtask'] = 'testtasks';
|
||||
+16
-16
@@ -1,20 +1,20 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
$config->todo->createform = array();
|
||||
$config->todo->createform['type'] = array('required' => true, 'type' => 'string');
|
||||
$config->todo->createform['name'] = array('required' => true, 'type' => 'string');
|
||||
$config->todo->createform['status'] = array('required' => true, 'type' => 'string');
|
||||
$config->todo->createform['pri'] = array('required' => true, 'type' => 'int');
|
||||
$config->todo->create->form = array();
|
||||
$config->todo->create->form['type'] = array('required' => true, 'type' => 'string');
|
||||
$config->todo->create->form['name'] = array('required' => true, 'type' => 'string');
|
||||
$config->todo->create->form['status'] = array('required' => true, 'type' => 'string');
|
||||
$config->todo->create->form['pri'] = array('required' => true, 'type' => 'int');
|
||||
|
||||
$config->todo->createform['date'] = array('required' => false, 'type' => 'string', 'default' => helper::today());
|
||||
$config->todo->createform['begin'] = array('required' => false, 'type' => 'int', 'default' => 2400);
|
||||
$config->todo->createform['end'] = array('required' => false, 'type' => 'int', 'default' => 2400);
|
||||
$config->todo->createform['private'] = array('required' => false, 'type' => 'int', 'default' => 0);
|
||||
$config->todo->createform['assignedDate'] = array('required' => false, 'type' => 'string', 'default' => helper::now());
|
||||
$config->todo->createform['assignedTo'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->createform['assignedBy'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->createform['vision'] = array('required' => false, 'type' => 'string', 'default' => $this->config->vision);
|
||||
$config->todo->createform['idvalue'] = array('required' => false, 'type' => 'int', 'default' => 0);
|
||||
$config->todo->createform['desc'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->createform['uid'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->create->form['date'] = array('required' => false, 'type' => 'string', 'default' => helper::today());
|
||||
$config->todo->create->form['begin'] = array('required' => false, 'type' => 'int', 'default' => 2400);
|
||||
$config->todo->create->form['end'] = array('required' => false, 'type' => 'int', 'default' => 2400);
|
||||
$config->todo->create->form['private'] = array('required' => false, 'type' => 'int', 'default' => 0);
|
||||
$config->todo->create->form['assignedDate'] = array('required' => false, 'type' => 'string', 'default' => helper::now());
|
||||
$config->todo->create->form['assignedTo'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->create->form['assignedBy'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->create->form['vision'] = array('required' => false, 'type' => 'string', 'default' => $this->config->vision);
|
||||
$config->todo->create->form['idvalue'] = array('required' => false, 'type' => 'int', 'default' => 0);
|
||||
$config->todo->create->form['desc'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
$config->todo->create->form['uid'] = array('required' => false, 'type' => 'string', 'default' => '');
|
||||
|
||||
@@ -41,7 +41,7 @@ class todo extends control
|
||||
|
||||
if(!empty($_POST))
|
||||
{
|
||||
$formData = form::data($this->config->todo->createform);
|
||||
$formData = form::data($this->config->todo->create->form);
|
||||
|
||||
$todo = $this->todoZen->beforeCreate($formData);
|
||||
$todoID = $this->todoZen->doCreate($todo);
|
||||
|
||||
Reference in New Issue
Block a user