* Modify upgrade whitelist.
This commit is contained in:
@@ -352,6 +352,5 @@ CREATE TABLE IF NOT EXISTS `zt_acl` (
|
||||
`objectID` mediumint(9) NOT NULL DEFAULT '0',
|
||||
`type` char(40) NOT NULL DEFAULT 'whitelist',
|
||||
`source` char(30) NOT NULL,
|
||||
`desc` varchar(255) DEFAULT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
|
||||
+2
-3
@@ -1,12 +1,11 @@
|
||||
-- DROP TABLE IF EXISTS `zt_acllist`;
|
||||
CREATE TABLE IF NOT EXISTS `zt_acllist` (
|
||||
-- DROP TABLE IF EXISTS `zt_acl`;
|
||||
CREATE TABLE IF NOT EXISTS `zt_acl` (
|
||||
`id` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`account` char(30) NOT NULL,
|
||||
`objectType` char(30) NOT NULL,
|
||||
`objectID` mediumint(9) NOT NULL DEFAULT '0',
|
||||
`type` char(40) NOT NULL DEFAULT 'whitelist',
|
||||
`source` char(30) NOT NULL,
|
||||
`desc` varchar(255) DEFAULT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
|
||||
|
||||
@@ -156,13 +156,14 @@ class groupModel extends model
|
||||
/**
|
||||
* Get the account number in the group.
|
||||
*
|
||||
* @param int $groupID
|
||||
* @param array $groupIdList
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getGroupAccounts($groupID = 0)
|
||||
public function getGroupAccounts($groupIdList = array())
|
||||
{
|
||||
return $this->dao->select('account')->from(TABLE_USERGROUP)->where('group')->eq($groupIdList)->fetchPairs('account');
|
||||
if(empty($groupIdList)) return array();
|
||||
return $this->dao->select('account')->from(TABLE_USERGROUP)->where('group')->in($groupIdList)->fetchPairs('account');
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -1587,7 +1587,6 @@ class project extends control
|
||||
$this->view->products = $products;
|
||||
$this->view->branchGroups = $this->loadModel('branch')->getByProducts(array_keys($products), '', $linkedBranches);
|
||||
$this->view->planGroups = $this->project->getPlans($products);
|
||||
$this->view->groups = $this->loadModel('group')->getPairs();
|
||||
$this->view->actions = $this->loadModel('action')->getList('project', $projectID);
|
||||
$this->view->dynamics = $this->loadModel('action')->getDynamic('all', 'all', 'date_desc', $pager, 'all', $projectID);
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter');
|
||||
|
||||
@@ -281,14 +281,6 @@
|
||||
<div class="detail-title"><strong><?php echo $lang->project->acl;?></strong></div>
|
||||
<div class="detail-content">
|
||||
<p><?php echo $lang->project->aclList[$project->acl];?></p>
|
||||
<?php if($project->acl == 'custom'):?>
|
||||
<p>
|
||||
<?php
|
||||
$whitelist = explode(',', $project->whitelist);
|
||||
foreach($whitelist as $groupID) if(isset($groups[$groupID])) echo $groups[$groupID] . ' ';
|
||||
?>
|
||||
</p>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
<?php $this->printExtendFields($project, 'div', "position=right&inForm=0&inCell=1");?>
|
||||
|
||||
Reference in New Issue
Block a user