diff --git a/config/filter.php b/config/filter.php index 868577e010..34eb11263f 100644 --- a/config/filter.php +++ b/config/filter.php @@ -11,7 +11,7 @@ $filter->rules->orderBy = '/^\w+_(desc|asc)$/i'; $filter->rules->browseType = '/^by\w+$/i'; $filter->rules->word = '/^\w+$/'; $filter->rules->paramName = '/^[a-zA-Z0-9_\.]+$/'; -$filter->rules->paramValue = '/^[a-zA-Z0-9=_,`#+\^\/\.%\|\x7f-\xff]+$/'; +$filter->rules->paramValue = '/^[a-zA-Z0-9=_,`#+\s\^\/\.%\|\x7f-\xff]+$/'; $filter->default = new stdclass(); $filter->default->moduleName = 'code'; diff --git a/db/update9.3.beta.sql b/db/update9.3.beta.sql new file mode 100644 index 0000000000..1a241ea247 --- /dev/null +++ b/db/update9.3.beta.sql @@ -0,0 +1,4 @@ +alter table zt_bug modify column mailto text; +alter table zt_story modify column mailto text; +alter table zt_task modify column mailto text; +alter table zt_testtask modify column mailto text; diff --git a/db/zentao.sql b/db/zentao.sql index bf500ff379..a0e4d3b78e 100644 --- a/db/zentao.sql +++ b/db/zentao.sql @@ -68,7 +68,7 @@ CREATE TABLE IF NOT EXISTS `zt_bug` ( `color` char(7) NOT NULL, `confirmed` tinyint(1) NOT NULL default '0', `activatedCount` smallint(6) NOT NULL, - `mailto` varchar(255) NOT NULL default '', + `mailto` text, `openedBy` varchar(30) NOT NULL default '', `openedDate` datetime NOT NULL, `openedBuild` varchar(255) NOT NULL, @@ -353,7 +353,7 @@ CREATE TABLE IF NOT EXISTS `zt_group` ( `name` char(30) NOT NULL, `role` char(30) NOT NULL default '', `desc` char(255) NOT NULL default '', - `acl` text NOT NULL default '', + `acl` text, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; -- DROP TABLE IF EXISTS `zt_grouppriv`; @@ -513,7 +513,7 @@ CREATE TABLE IF NOT EXISTS `zt_story` ( `product` mediumint(8) unsigned NOT NULL default '0', `branch` mediumint(8) unsigned NOT NULL default '0', `module` mediumint(8) unsigned NOT NULL default '0', - `plan` text NOT NULL default '', + `plan` text, `source` varchar(20) NOT NULL, `sourceNote` varchar(255) NOT NULL, `fromBug` mediumint(8) unsigned NOT NULL default '0', @@ -525,7 +525,7 @@ CREATE TABLE IF NOT EXISTS `zt_story` ( `status` enum('','changed','active','draft','closed') NOT NULL default '', `color` char(7) NOT NULL, `stage` enum('','wait','planned','projected','developing','developed','testing','tested','verified','released') NOT NULL DEFAULT 'wait', - `mailto` varchar(255) NOT NULL default '', + `mailto` text, `openedBy` varchar(30) NOT NULL default '', `openedDate` datetime NOT NULL, `assignedTo` varchar(30) NOT NULL default '', @@ -587,7 +587,7 @@ CREATE TABLE IF NOT EXISTS `zt_task` ( `deadline` date NOT NULL, `status` enum('wait','doing','done','pause','cancel','closed') NOT NULL default 'wait', `color` char(7) NOT NULL, - `mailto` varchar(255) NOT NULL default '', + `mailto` text, `desc` text NOT NULL, `openedBy` varchar(30) NOT NULL, `openedDate` datetime NOT NULL, @@ -705,7 +705,7 @@ CREATE TABLE IF NOT EXISTS `zt_testtask` ( `pri` tinyint(3) unsigned NOT NULL default '0', `begin` date NOT NULL, `end` date NOT NULL, - `mailto` varchar(255) NOT NULL default '', + `mailto` text, `desc` text NOT NULL, `report` text NOT NULL, `status` enum('blocked','doing','wait','done') NOT NULL DEFAULT 'wait', diff --git a/module/admin/control.php b/module/admin/control.php index ca21460e1e..86ecabbaaa 100644 --- a/module/admin/control.php +++ b/module/admin/control.php @@ -205,10 +205,11 @@ class admin extends control if(!empty($_POST)) { $ssoConfig = new stdclass(); - $ssoConfig->turnon = $this->post->turnon; - $ssoConfig->addr = $this->post->addr; - $ssoConfig->code = trim($this->post->code); - $ssoConfig->key = trim($this->post->key); + $ssoConfig->turnon = $this->post->turnon; + $ssoConfig->redirect = $this->post->redirect; + $ssoConfig->addr = $this->post->addr; + $ssoConfig->code = trim($this->post->code); + $ssoConfig->key = trim($this->post->key); $this->loadModel('setting')->setItems('system.sso', $ssoConfig); if(dao::isError()) die(js::error(dao::getError())); @@ -221,10 +222,11 @@ class admin extends control $this->view->title = $this->lang->admin->sso; $this->view->position[] = $this->lang->admin->sso; - $this->view->turnon = isset($this->config->sso->turnon) ? $this->config->sso->turnon : 1; - $this->view->addr = isset($this->config->sso->addr) ? $this->config->sso->addr : ''; - $this->view->key = isset($this->config->sso->key) ? $this->config->sso->key : ''; - $this->view->code = isset($this->config->sso->code) ? $this->config->sso->code : ''; + $this->view->turnon = isset($this->config->sso->turnon) ? $this->config->sso->turnon : 1; + $this->view->redirect = isset($this->config->sso->redirect) ? $this->config->sso->redirect : 0; + $this->view->addr = isset($this->config->sso->addr) ? $this->config->sso->addr : ''; + $this->view->key = isset($this->config->sso->key) ? $this->config->sso->key : ''; + $this->view->code = isset($this->config->sso->code) ? $this->config->sso->code : ''; $this->display(); } diff --git a/module/admin/view/sso.html.php b/module/admin/view/sso.html.php index cb0d53acaa..41a954797f 100644 --- a/module/admin/view/sso.html.php +++ b/module/admin/view/sso.html.php @@ -24,6 +24,10 @@ sso->turnon; ?> sso->turnonList, $turnon);?> + + sso->redirect; ?> + sso->turnonList, $redirect);?> + sso->addr; ?> sso->addrNotice}' autocomplete='off'");?> diff --git a/module/bug/config.php b/module/bug/config.php index 525b6d7bca..ad1dc49272 100644 --- a/module/bug/config.php +++ b/module/bug/config.php @@ -27,7 +27,7 @@ $config->bug->list->defaultFields = 'id,severity,pri,title,openedBy,assignedTo,r $config->bug->list->exportFields = 'id, product, branch, module, project, story, task, title, keywords, severity, pri, type, os, browser, - steps, status, activatedCount, confirmed, mailto, + steps, status, deadline, activatedCount, confirmed, mailto, openedBy, openedDate, openedBuild, assignedTo, assignedDate, resolvedBy, resolution, resolvedBuild, resolvedDate, diff --git a/module/bug/view/create.html.php b/module/bug/view/create.html.php index 8cbafe06d6..a91f34327c 100644 --- a/module/bug/view/create.html.php +++ b/module/bug/view/create.html.php @@ -231,7 +231,7 @@ js::set('confirmDeleteTemplate', $lang->bug->confirmDeleteTemplate); - + -config->sso->turnon)):?> +config->sso->redirect)):?> config->sso->addr; $ranzhiURL = substr($ranzhiAddr, 0, strrpos($ranzhiAddr, '/sys/')); diff --git a/module/common/view/header.html.php b/module/common/view/header.html.php index 078a73800f..e813913dc3 100755 --- a/module/common/view/header.html.php +++ b/module/common/view/header.html.php @@ -7,7 +7,7 @@ include 'chosen.html.php'; app->loadConfig('sso');?>