Merge branch 'jihu' of https://gitlab.zcorp.cc/easycorp/zentaopms into jihu
This commit is contained in:
@@ -82,3 +82,8 @@ $config->gitlab->bugStateMap['active'] = 'reopen';
|
||||
$config->gitlab->bugStateMap['resolved'] = 'reopen';
|
||||
$config->gitlab->bugStateMap['closed'] = 'close';
|
||||
|
||||
$config->gitlab->objectTables = new stdclass;
|
||||
$config->gitlab->objectTables->story = TABLE_STORY;
|
||||
$config->gitlab->objectTables->task = TABLE_TASK;
|
||||
$config->gitlab->objectTables->bug = TABLE_BUG;
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ class gitlab extends control
|
||||
//$input = file_get_contents('php://input');
|
||||
$requestBody = json_decode($input);
|
||||
$result = $this->gitlab->webhookParseBody($requestBody, $gitlab);
|
||||
a($result);exit;
|
||||
|
||||
$logFile = $this->app->getLogRoot() . 'webhook.'. date('Ymd') . '.log.php';
|
||||
if(!file_exists($logFile)) file_put_contents($logFile, '<?php die(); ?' . '>');
|
||||
|
||||
@@ -233,7 +233,7 @@ class gitlab extends control
|
||||
|
||||
$this->view->result = 'success';
|
||||
$this->view->status = 'ok';
|
||||
$this->view->data = 'ougiugjvh';
|
||||
$this->view->data = $result->object;
|
||||
$this->display();
|
||||
}
|
||||
|
||||
|
||||
@@ -878,6 +878,9 @@ class gitlabModel extends model
|
||||
$issue->issue->objectType = $object->type;
|
||||
$issue->issue->objectID = $object->id;
|
||||
|
||||
/* Parse markdown description to html. */
|
||||
$issue->issue->description = $this->app->loadClass('hyperdown')->makeHtml($issue->issue->description);
|
||||
|
||||
if(!isset($this->config->gitlab->maps->{$object->type})) return false;
|
||||
$issue->object = $this->issueToZentaoObject($issue->issue, $gitlabID);
|
||||
return $issue;
|
||||
@@ -967,7 +970,7 @@ class gitlabModel extends model
|
||||
if(!isset($this->config->gitlab->maps->{$issue->objectType})) return null;
|
||||
|
||||
$maps = $this->config->gitlab->maps->{$issue->objectType};
|
||||
$gitlabUsers = $this->getUserAccountIdPairs($gitlabID);
|
||||
$gitlabUsers = $this->getUserIdAccountPairs($gitlabID);
|
||||
|
||||
$object = new stdclass;
|
||||
$object->id = $issue->objectID;
|
||||
|
||||
Reference in New Issue
Block a user