* Finish task #42851.
This commit is contained in:
@@ -1499,7 +1499,6 @@ class productModel extends model
|
||||
foreach($products as $product) $programKeys[] = $product->program;
|
||||
$programs = $this->dao->select('id,name')->from(TABLE_PROGRAM)
|
||||
->where('id')->in(array_unique($programKeys))
|
||||
->andWhere('deleted')->eq('0')
|
||||
->fetchPairs();
|
||||
|
||||
foreach($products as $product) $product->programName = isset($programs[$product->program]) ? $programs[$product->program] : '';
|
||||
|
||||
@@ -379,6 +379,9 @@ class program extends control
|
||||
$childrenCount = $this->dao->select('count(*) as count')->from(TABLE_PROGRAM)->where('parent')->eq($programID)->andWhere('deleted')->eq(0)->fetch('count');
|
||||
if($childrenCount) die(js::alert($this->lang->program->hasChildren));
|
||||
|
||||
$productCount = $this->dao->select('count(*) as count')->from(TABLE_PRODUCT)->where('program')->eq($programID)->andWhere('deleted')->eq(0)->fetch('count');
|
||||
if($productCount) die(js::alert($this->lang->program->hasProduct));
|
||||
|
||||
$program = $this->dao->select('*')->from(TABLE_PROGRAM)->where('id')->eq($programID)->fetch();
|
||||
if($confirm == 'no') die(js::confirm($this->lang->program->confirmDelete, $this->createLink('program', 'delete', "programID=$programID&confirm=yes")));
|
||||
|
||||
|
||||
@@ -58,6 +58,7 @@ $lang->program->confirmChangePRJUint = 'Synchronize the budget unit of the su
|
||||
$lang->program->exRateNotNegative = 'The『exchange rate』should not be negative.';
|
||||
$lang->program->changePRJUnit = 'Update the budget unit of the project';
|
||||
$lang->program->hasChildren = 'It has child programs or projects. You cannot delete it.';
|
||||
$lang->program->hasProduct = 'It has products. You cannot delete it.';
|
||||
$lang->program->readjustTime = 'Change the program begin&end date.';
|
||||
|
||||
$lang->program->stakeholderTypeList['inside'] = 'Inside';
|
||||
|
||||
@@ -85,6 +85,7 @@ $lang->program->beginGreateChild = "Child earliest begin: %s, parent begin dat
|
||||
$lang->program->endLetterChild = "Child latest end: %s, parent end date > = child latest end date.";
|
||||
$lang->program->closeErrorMessage = 'There are subprograms or projects that are not closed';
|
||||
$lang->program->hasChildren = 'The program has a child program or the project exists and can not be deleted.';
|
||||
$lang->program->hasProduct = 'The program has products exist and can not be deleted.';
|
||||
$lang->program->confirmDelete = "Do you want to delete it?";
|
||||
$lang->program->readjustTime = 'Change the program begin&end date.';
|
||||
$lang->program->accessDenied = 'You have no access to the program.';
|
||||
|
||||
@@ -58,6 +58,7 @@ $lang->program->confirmChangePRJUint = 'Synchronize the budget unit of the su
|
||||
$lang->program->exRateNotNegative = 'The『exchange rate』should not be negative.';
|
||||
$lang->program->changePRJUnit = 'Update the budget unit of the project';
|
||||
$lang->program->hasChildren = 'It has child programs or projects. You cannot delete it.';
|
||||
$lang->program->hasProduct = 'It has products. You cannot delete it.';
|
||||
$lang->program->readjustTime = 'Change the program begin&end date.';
|
||||
|
||||
$lang->program->stakeholderTypeList['inside'] = 'Inside';
|
||||
|
||||
@@ -58,6 +58,7 @@ $lang->program->confirmChangePRJUint = 'Synchronize the budget unit of the su
|
||||
$lang->program->exRateNotNegative = 'The『exchange rate』should not be negative.';
|
||||
$lang->program->changePRJUnit = 'Update the budget unit of the project';
|
||||
$lang->program->hasChildren = 'It has child programs or projects. You cannot delete it.';
|
||||
$lang->program->hasProduct = 'It has products. You cannot delete it.';
|
||||
$lang->program->readjustTime = 'Change the program begin&end date.';
|
||||
|
||||
$lang->program->stakeholderTypeList['inside'] = 'Inside';
|
||||
|
||||
@@ -85,6 +85,7 @@ $lang->program->beginGreateChild = "子项目集的最小开始日期:%s,
|
||||
$lang->program->endLetterChild = "子项目的最大完成日期:%s,父项目的完成日期不能小于子项目的最大完成日期";
|
||||
$lang->program->closeErrorMessage = '存在子项目集或项目为未关闭状态';
|
||||
$lang->program->hasChildren = '该项目集有子项目集或项目存在,不能删除。';
|
||||
$lang->program->hasProduct = '该项目集有产品存在,不能删除。';
|
||||
$lang->program->confirmDelete = "您确定要删除吗?";
|
||||
$lang->program->readjustTime = '重新调整项目集起止时间';
|
||||
$lang->program->accessDenied = '你无权访问该项目集';
|
||||
|
||||
@@ -85,6 +85,7 @@ $lang->program->beginGreateChild = "子項目集的最小開始日期:%s,
|
||||
$lang->program->endLetterChild = "子項目的最大完成日期:%s,父項目的完成日期不能小於子項目的最大完成日期";
|
||||
$lang->program->closeErrorMessage = '存在子項目集或項目為未關閉狀態';
|
||||
$lang->program->hasChildren = '該項目集有子項目集或項目存在,不能刪除。';
|
||||
$lang->program->hasChildren = '該項目集有產品存在,不能刪除。';
|
||||
$lang->program->confirmDelete = "您確定要刪除嗎?";
|
||||
$lang->program->readjustTime = '重新調整項目集起止時間';
|
||||
$lang->program->accessDenied = '你無權訪問該項目集';
|
||||
|
||||
Reference in New Issue
Block a user