Exemple #1
0
 function add_item($item)
 {
     $problem_item = new stdClass();
     $problem_item->owner_id = $item->engineer_id;
     $problem_item->specificmatters = $item->scope;
     $problem_item->begin_time = date('Y-m-d H:i:s');
     $problem_item->instruction = $item->frequency;
     $problem_item->description = 'UserBug' . '(' . $problem_item->begin_time . ')';
     $problem = new problem();
     $result = $problem->add_item($problem_item);
     if (!$result['success']) {
         return $result;
     }
     $item->track_id = $result['data']->id;
     $result = parent::add_item($item);
     if (!$result['success']) {
         return $result;
     }
     return $result;
 }
Exemple #2
0
 function add_item($item)
 {
     $problem_item = new stdClass();
     $problem_item->owner_id = $item->engineer_id;
     $problem_item->specificmatters = $item->description;
     $problem_item->begin_time = date('Y-m-d H:i');
     $problem_item->progress = 0;
     $problem_item->description = 'JointBug' . '(' . $problem_item->begin_time . ')';
     $problem = new problem();
     $result = $problem->add_item($problem_item);
     if (!$result['success']) {
         return $result;
     }
     $item->track_id = $result['data']->id;
     $result = parent::add_item($item);
     if (!$result['success']) {
         return $result;
     }
     return $result;
 }
Exemple #3
0
    {
        $item->complete_time = date('Y-m-d H:i:s');
        $result = parent::mod_item($item);
        if (!$result['success']) {
            return $result;
        }
        return $result;
    }
    function add_item($item)
    {
        $item->complete_time = date('Y-m-d H:i:s');
        $item->begin_time = date('Y-m-d H:i:s');
        $result = parent::add_item($item);
        if (!$result['success']) {
            return $result;
        }
        return $result;
    }
    function table_name()
    {
        return "t_problem";
    }
    function auto_id()
    {
        return true;
    }
}
if (!isset($no_process)) {
    $problem = new problem();
    $problem->process();
}