Added tags for Github builds.

This commit is contained in:
Dmitry Khomutov 2017-04-22 20:02:24 +07:00
commit 647a5cedcd
No known key found for this signature in database
GPG key ID: 7EB36C9576F9ECB9
9 changed files with 151 additions and 22 deletions

View file

@ -51,6 +51,7 @@ class Build extends Model
'status' => null,
'log' => null,
'branch' => null,
'tag' => null,
'created' => null,
'started' => null,
'finished' => null,
@ -71,6 +72,7 @@ class Build extends Model
'status' => 'getStatus',
'log' => 'getLog',
'branch' => 'getBranch',
'tag' => 'getTag',
'created' => 'getCreated',
'started' => 'getStarted',
'finished' => 'getFinished',
@ -94,6 +96,7 @@ class Build extends Model
'status' => 'setStatus',
'log' => 'setLog',
'branch' => 'setBranch',
'setTag' => 'setTag',
'created' => 'setCreated',
'started' => 'setStarted',
'finished' => 'setFinished',
@ -142,6 +145,11 @@ class Build extends Model
'length' => 250,
'default' => 'master',
],
'tag' => [
'type' => 'varchar',
'length' => 250,
'default' => null,
],
'created' => [
'type' => 'datetime',
'nullable' => true,
@ -986,6 +994,36 @@ class Build extends Model
return false;
}
/**
* Get the value of Tag / tag.
*
* @return string
*/
public function getTag()
{
$rtn = $this->data['tag'];
return $rtn;
}
/**
* Set the value of Tag / tag.
*
* @param $value string
*/
public function setTag($value)
{
$this->validateString('Tag', $value);
if ($this->data['tag'] === $value) {
return;
}
$this->data['tag'] = $value;
$this->setModified('tag');
}
/**
* Get the value of Environment / environment.
*