Skip to content

Commit

Permalink
Fix indentantion
Browse files Browse the repository at this point in the history
  • Loading branch information
anarute committed Jun 9, 2022
1 parent 4e5f64a commit 485f30d
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 36 deletions.
45 changes: 22 additions & 23 deletions model/dao/TaskDAO/PostgreSQLTaskDAO.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,29 +69,28 @@ function __construct() {
*/
protected function setValues($row)
{

$taskVO = new TaskVO();

$taskVO->setId($row['id']);
$taskVO->setDate(date_create($row['_date']));
$taskVO->setInit($row['init']);
$taskVO->setEnd($row['_end']);
$taskVO->setStory($row['story']);
if (strtolower($row['telework']) == "t")
$taskVO->setTelework(True);
elseif (strtolower($row['telework']) == "f")
$taskVO->setTelework(False);
if (strtolower($row['onsite']) == "t")
$taskVO->setOnsite(True);
elseif (strtolower($row['onsite']) == "f")
$taskVO->setOnsite(False);
$taskVO->setText($row['text']);
$taskVO->setTtype($row['ttype']);
$taskVO->setPhase($row['phase']);
$taskVO->setUserId($row['usrid']);
$taskVO->setProjectId($row['projectid']);

return $taskVO;
$taskVO = new TaskVO();

$taskVO->setId($row['id']);
$taskVO->setDate(date_create($row['_date']));
$taskVO->setInit($row['init']);
$taskVO->setEnd($row['_end']);
$taskVO->setStory($row['story']);
if (strtolower($row['telework']) == "t")
$taskVO->setTelework(True);
elseif (strtolower($row['telework']) == "f")
$taskVO->setTelework(False);
if (strtolower($row['onsite']) == "t")
$taskVO->setOnsite(True);
elseif (strtolower($row['onsite']) == "f")
$taskVO->setOnsite(False);
$taskVO->setText($row['text']);
$taskVO->setTtype($row['ttype']);
$taskVO->setPhase($row['phase']);
$taskVO->setUserId($row['usrid']);
$taskVO->setProjectId($row['projectid']);

return $taskVO;
}

/** Task retriever by id for PostgreSQL.
Expand Down
26 changes: 13 additions & 13 deletions model/vo/TaskVO.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@ class TaskVO {
protected $projectId = NULL;

public function setId($id) {
if (is_null($id))
$this->id = $id;
else
if (is_null($id))
$this->id = $id;
else
$this->id = (int) $id;
}

Expand All @@ -87,9 +87,9 @@ public function getDate() {
}

public function setInit($init) {
if (is_null($init))
$this->init = $init;
else
if (is_null($init))
$this->init = $init;
else
$this->init = (int) $init;
}

Expand All @@ -98,9 +98,9 @@ public function getInit() {
}

public function setEnd($_end) {
if (is_null($_end))
$this->_end = $_end;
else
if (is_null($_end))
$this->_end = $_end;
else
$this->_end = (int) $_end;
}

Expand Down Expand Up @@ -158,8 +158,8 @@ public function getPhase() {

public function setUserId($userId) {
if (is_null($userId))
$this->userId = $userId;
else
$this->userId = $userId;
else
$this->userId = (int) $userId;
}

Expand All @@ -169,8 +169,8 @@ public function getUserId() {

public function setProjectId($projectId) {
if (is_null($projectId))
$this->projectId = $projectId;
else
$this->projectId = $projectId;
else
$this->projectId = (int) $projectId;
}

Expand Down

0 comments on commit 485f30d

Please sign in to comment.