* Code for function getBudgetWithUnit .

This commit is contained in:
guofeilong
2023-04-28 14:04:15 +08:00
parent ebd0dab492
commit 45af6d2fbb
3 changed files with 24 additions and 3 deletions
+2 -2
View File
@@ -2286,9 +2286,9 @@ class projectModel extends model
/**
* Convert budget unit.
*
* @param int $budget
* @param int $budget
* @access public
* @return void
* @return int|string $projectBudget
*/
public function getBudgetWithUnit($budget)
{
+9
View File
@@ -0,0 +1,9 @@
#!/usr/bin/env php
<?php
include dirname(__FILE__, 5) . "/test/lib/init.php";
su('admin');
global $tester;
$tester->loadModel('project');
r($oriject->getBudgetWithUnit(99)) && p() && e('99');
+13 -1
View File
@@ -161,7 +161,7 @@ class Project
}
/**
* doActivate a project.
* Do activate a project.
*
* @param int $projectID
* @param object $project
@@ -172,4 +172,16 @@ class Project
{
return $this->project->doActivate($projectID, $project);
}
/**
* Get budget with unit.
*
* @param int $budget
* @access public
* @return int|string $projectBudget
*/
public function getBudgetWithUnit($budget)
{
return $this->project->getBudgetWithUnit($budget);
}
}