* The programplan module calls the updateUserView method.
This commit is contained in:
+2
-2
@@ -66,7 +66,7 @@ CREATE TABLE `zt_stage` (
|
||||
|
||||
-- DROP TABLE IF EXISTS `zt_stakeholder`;
|
||||
CREATE TABLE `zt_stakeholder` (
|
||||
`id` mediumint(8) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
`id` mediumint(8) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
`objectID` mediumint(8) NOT NULL,
|
||||
`objectType` char(30) NOT NULL,
|
||||
`user` char(30) NOT NULL,
|
||||
@@ -77,7 +77,7 @@ CREATE TABLE `zt_stakeholder` (
|
||||
`createdDate` date NOT NULL,
|
||||
`editedBy` char(30) NOT NULL,
|
||||
`editedDate` date NOT NULL,
|
||||
`deleted` enum('0','1') NOT NULL
|
||||
`deleted` enum('0','1') NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
|
||||
-- DROP TABLE IF EXISTS `zt_expect`;
|
||||
|
||||
+2
-2
@@ -875,7 +875,7 @@ CREATE TABLE `zt_risk` (
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
-- DROP TABLE IF EXISTS `zt_stakeholder`;
|
||||
CREATE TABLE `zt_stakeholder` (
|
||||
`id` mediumint(8) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
`id` mediumint(8) NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
`objectID` mediumint(8) NOT NULL,
|
||||
`objectType` char(30) NOT NULL,
|
||||
`user` char(30) NOT NULL,
|
||||
@@ -886,7 +886,7 @@ CREATE TABLE `zt_stakeholder` (
|
||||
`createdDate` date NOT NULL,
|
||||
`editedBy` char(30) NOT NULL,
|
||||
`editedDate` date NOT NULL,
|
||||
`deleted` enum('0','1') NOT NULL
|
||||
`deleted` enum('0','1') NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
-- DROP TABLE IF EXISTS `zt_story`;
|
||||
CREATE TABLE IF NOT EXISTS `zt_story` (
|
||||
|
||||
@@ -159,7 +159,6 @@ class programplan extends control
|
||||
public function edit($planID = 0, $programID = 0)
|
||||
{
|
||||
$plan = $this->programplan->getByID($planID);
|
||||
$this->commonAction($plan->program, $plan->product);
|
||||
|
||||
if($_POST)
|
||||
{
|
||||
|
||||
@@ -333,7 +333,7 @@ class programplanModel extends model
|
||||
*/
|
||||
public function getTotalPercent($plan)
|
||||
{
|
||||
$plans = $this->getList($plan->program, $plan->product, $plan->parent,'parent');
|
||||
$plans = $this->getList($plan->project, $plan->product, $plan->parent, 'parent');
|
||||
|
||||
$totalPercent = 0;
|
||||
foreach($plans as $id => $stage)
|
||||
@@ -508,8 +508,6 @@ class programplanModel extends model
|
||||
return false;
|
||||
}
|
||||
|
||||
$this->post->set('products', array(0 => $productID));//目前计划阶段用的就是迭代,迭代和产品会有个绑定关系,调用迭代(项目)模块的updateProducts方法来实现这个绑定关系,需要往post里塞入产品数据。
|
||||
|
||||
$account = $this->app->user->account;
|
||||
$now = helper::now();
|
||||
foreach($datas as $data)
|
||||
@@ -536,6 +534,8 @@ class programplanModel extends model
|
||||
->where('id')->eq($planID)
|
||||
->exec();
|
||||
|
||||
if($data->acl != 'open') $this->loadModel('user')->updateUserView($planID, 'stage');
|
||||
|
||||
if($planChanged)
|
||||
{
|
||||
$spec = new stdclass();
|
||||
@@ -569,7 +569,11 @@ class programplanModel extends model
|
||||
if(!dao::isError())
|
||||
{
|
||||
$planID = $this->dao->lastInsertID();
|
||||
|
||||
$this->setTreePath($planID);
|
||||
if($data->acl != 'open') $this->loadModel('user')->updateUserView($planID, 'stage');
|
||||
|
||||
$this->post->set('products', array(0 => $productID));
|
||||
$this->loadModel('project')->updateProducts($planID);
|
||||
|
||||
$spec = new stdclass();
|
||||
@@ -671,6 +675,7 @@ class programplanModel extends model
|
||||
|
||||
if(dao::isError()) return false;
|
||||
$this->setTreePath($planID);
|
||||
if($plan->acl != 'open') $this->loadModel('user')->updateUserView($planID, 'stage');
|
||||
|
||||
if($planChanged)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user