Merge branch 'spirnt/165_liyuchun_42860' into 'sprint/165'

* Finish task #42860.

See merge request easycorp/zentaopms!26
This commit is contained in:
朱金勇
2021-09-26 08:57:41 +00:00
2 changed files with 5 additions and 8 deletions
+3 -6
View File
@@ -687,17 +687,14 @@ class personnelModel extends model
/**
* Determine whether the user exists in the white list of multiple products.
*
* @param int $objectID
* @param int $programID
* @param string $account
* @access public
* @return void
*/
public function deleteProgramWhitelist($objectID = 0, $account = '')
public function deleteProgramWhitelist($programID = 0, $account = '')
{
$program = $this->dao->select('id,program,whitelist')->from(TABLE_PRODUCT)->where('id')->eq($objectID)->fetch();
if(empty($program)) return false;
$programID = $program->program;
$program = $this->loadModel('program')->getByID($programID);
$products = $this->dao->select('id')->from(TABLE_PRODUCT)->where('program')->eq($programID)->andWhere('deleted')->eq('0')->fetchPairs('id');
$whitelist = $this->dao->select('*')->from(TABLE_ACL)->where('objectID')->in($products)->andWhere('account')->eq($account)->andWhere('objectType')->eq('product')->fetch();
+2 -2
View File
@@ -2394,8 +2394,8 @@ class storyModel extends model
/* Get the sql and form status from the query. */
if($query)
{
$this->session->set('storyQuery', $query->sql, $this->app->tab);
$this->session->set('storyForm', $query->form, $this->app->tab);
$this->session->set('storyQuery', $query->sql);
$this->session->set('storyForm', $query->form);
}
if($this->session->storyQuery == false) $this->session->set('storyQuery', ' 1 = 1');