finish the task #689.

This commit is contained in:
shiyangyangwork@yahoo.cn
2012-02-09 06:56:35 +00:00
parent c86a3fcc3e
commit b30c103ecc
370 changed files with 46270 additions and 46270 deletions

View File

@@ -1,60 +1,60 @@
<?php
/**
* The control file of common module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chen congzhi <congzhi@cnezsoft.com>
* @package common
* @version $Id$
* @link http://www.zentao.net
*/
include '../config/config.php';
$modules = array();
$moduleRoot = realpath('../module/') . '/';
if(is_dir($moduleRoot))
{
if($dh = opendir($moduleRoot))
{
while($module = readdir($dh))
{
if(strpos(basename($module), '.') === false) $modules[] = $module;
}
closedir($dh);
}
}
else
{
die("The module you input does not exist. \n");
}
foreach($modules as $module)
{
/* 设定各个目录。*/
$extRoot = $moduleRoot . DIRECTORY_SEPARATOR. $module . DIRECTORY_SEPARATOR . 'ext';
$extControl = $extRoot . DIRECTORY_SEPARATOR . 'control';
$extModel = $extRoot . DIRECTORY_SEPARATOR . 'model';
$extView = $extRoot . DIRECTORY_SEPARATOR . 'view';
$extConfig = $extRoot . DIRECTORY_SEPARATOR . 'config';
$extLang = $extRoot . DIRECTORY_SEPARATOR . 'lang' . DIRECTORY_SEPARATOR;
/* 建立各个扩展目录 */
if(!file_exists($extRoot)) mkdir($extRoot, 0777);
if(!file_exists($extControl)) mkdir($extControl, 0777);
if(!file_exists($extModel)) mkdir($extModel, 0777);
if(!file_exists($extView)) mkdir($extView, 0777);
if(!file_exists($extConfig)) mkdir($extConfig, 0777);
if(!file_exists($extLang)) mkdir($extLang, 0777);
/* 创建语言目录。*/
$langs = array_keys($config->langs);
foreach($langs as $lang)
{
$langPath = $extLang . $lang;
if(!file_exists($langPath)) mkdir($langPath, 0777);
}
echo "init $module ... \n";
}
<?php
/**
* The control file of common module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chen congzhi <congzhi@cnezsoft.com>
* @package common
* @version $Id$
* @link http://www.zentao.net
*/
include '../config/config.php';
$modules = array();
$moduleRoot = realpath('../module/') . '/';
if(is_dir($moduleRoot))
{
if($dh = opendir($moduleRoot))
{
while($module = readdir($dh))
{
if(strpos(basename($module), '.') === false) $modules[] = $module;
}
closedir($dh);
}
}
else
{
die("The module you input does not exist. \n");
}
foreach($modules as $module)
{
/* 设定各个目录。*/
$extRoot = $moduleRoot . DIRECTORY_SEPARATOR. $module . DIRECTORY_SEPARATOR . 'ext';
$extControl = $extRoot . DIRECTORY_SEPARATOR . 'control';
$extModel = $extRoot . DIRECTORY_SEPARATOR . 'model';
$extView = $extRoot . DIRECTORY_SEPARATOR . 'view';
$extConfig = $extRoot . DIRECTORY_SEPARATOR . 'config';
$extLang = $extRoot . DIRECTORY_SEPARATOR . 'lang' . DIRECTORY_SEPARATOR;
/* 建立各个扩展目录 */
if(!file_exists($extRoot)) mkdir($extRoot, 0777);
if(!file_exists($extControl)) mkdir($extControl, 0777);
if(!file_exists($extModel)) mkdir($extModel, 0777);
if(!file_exists($extView)) mkdir($extView, 0777);
if(!file_exists($extConfig)) mkdir($extConfig, 0777);
if(!file_exists($extLang)) mkdir($extLang, 0777);
/* 创建语言目录。*/
$langs = array_keys($config->langs);
foreach($langs as $lang)
{
$langPath = $extLang . $lang;
if(!file_exists($langPath)) mkdir($langPath, 0777);
}
echo "init $module ... \n";
}

View File

@@ -1,46 +1,46 @@
#!/usr/bin/env php
<?php
/**
* The cli router file of zentaopms.
*
* @copyright Copyright 2009-2011 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bin
* @version $Id$
* @link http://www.ZenTaoPMS.com
*/
//error_reporting(0);
define('IN_SHELL', true);
/* Judge the args. */
if($argc != 2) die('Usage: ' . basename(__FILE__) . " <request>\n");
/* Parse the request into params. */
$request = parse_url(trim($argv[1]));
$_SERVER['HTTP_HOST'] = $request['host'];
/* Load the framework. */
chdir(dirname(__FILE__));
include '../framework/router.class.php';
include '../framework/control.class.php';
include '../framework/model.class.php';
include '../framework/helper.class.php';
include '../config/config.php';
if($config->requestType == 'PATH_INFO')
{
$_SERVER['PATH_INFO'] = str_replace($config->webRoot, '', $request['path']);
}
else
{
parse_str($request['query'], $_GET);
$_SERVER['SCRIPT_NAME'] = $_SERVER['PATH_INFO'] . 'index.php';
$_SERVER['REQUEST_URI'] = isset($request['query']) ? $request['query'] : '';
}
/* Instance the app and run it. */
$app = router::createApp('pms', dirname(dirname(__FILE__)));
$common = $app->loadCommon();
$app->parseRequest();
$app->loadModule();
#!/usr/bin/env php
<?php
/**
* The cli router file of zentaopms.
*
* @copyright Copyright 2009-2012 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bin
* @version $Id$
* @link http://www.ZenTaoPMS.com
*/
//error_reporting(0);
define('IN_SHELL', true);
/* Judge the args. */
if($argc != 2) die('Usage: ' . basename(__FILE__) . " <request>\n");
/* Parse the request into params. */
$request = parse_url(trim($argv[1]));
$_SERVER['HTTP_HOST'] = $request['host'];
/* Load the framework. */
chdir(dirname(__FILE__));
include '../framework/router.class.php';
include '../framework/control.class.php';
include '../framework/model.class.php';
include '../framework/helper.class.php';
include '../config/config.php';
if($config->requestType == 'PATH_INFO')
{
$_SERVER['PATH_INFO'] = str_replace($config->webRoot, '', $request['path']);
}
else
{
parse_str($request['query'], $_GET);
$_SERVER['SCRIPT_NAME'] = $_SERVER['PATH_INFO'] . 'index.php';
$_SERVER['REQUEST_URI'] = isset($request['query']) ? $request['query'] : '';
}
/* Instance the app and run it. */
$app = router::createApp('pms', dirname(dirname(__FILE__)));
$common = $app->loadCommon();
$app->parseRequest();
$app->loadModule();

View File

@@ -1,121 +1,121 @@
<?php
/**
* The config file of ZenTaoPMS.
*
* Don't modify this file directly, copy the item to my.php and change it.
*
* @copyright Copyright 2009-2011 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package config
* @version $Id$
* @link http://www.zentao.net
*/
/* Basic settings. */
$config->version = '3.0.beta1'; // The version of zentaopms. Don't change it.
$config->encoding = 'UTF-8'; // The encoding of znetaopms.
$config->cookieLife = time() + 2592000; // The cookie life time.
$config->timezone = 'Asia/Shanghai'; // The time zone setting, for more see http://www.php.net/manual/en/timezones.php
$config->webRoot = ''; // The root path of the pms.
/* The request settings. */
$config->requestType = 'PATH_INFO'; // The request type: PATH_INFO|GET, if PATH_INFO, must use url rewrite.
$config->pathType = 'clean'; // If the request type is PATH_INFO, the path type.
$config->requestFix = '-'; // The divider in the url when PATH_INFO.
$config->moduleVar = 'm'; // requestType=GET: the module var name.
$config->methodVar = 'f'; // requestType=GET: the method var name.
$config->viewVar = 't'; // requestType=GET: the view var name.
$config->sessionVar = 'sid'; // requestType=GET: the session var name.
/* Supported views. */
$config->views = ',html,json,';
/* Set the wide window size. */
$config->wideSize = 1400;
/* Supported languages. */
$config->langs['zh-cn'] = '中文简体';
$config->langs['zh-tw'] = '中文繁體';
$config->langs['en'] = 'English';
/* Default settings. */
$config->default->view = 'html'; // Default view.
$config->default->lang = 'en'; // Default language.
$config->default->theme = 'default'; // Default theme.
$config->default->module = 'index'; // Default module.
$config->default->method = 'index'; // Default method.
/* Upload settings. */
$config->file->dangers = 'php,jsp,py,rb,asp,'; // Dangerous files.
$config->file->maxSize = 1024 * 1024; // Max size.
/* Master database settings. */
$config->db->persistant = false; // Pconnect or not.
$config->db->driver = 'mysql'; // Must be MySQL. Don't support other database server yet.
$config->db->encoding = 'UTF8'; // Encoding of database.
$config->db->strictMode = false; // Turn off the strict mode of MySQL.
//$config->db->emulatePrepare = true; // PDO::ATTR_EMULATE_PREPARES
//$config->db->bufferQuery = true; // PDO::MYSQL_ATTR_USE_BUFFERED_QUERY
/* Slave database settings. */
$config->slaveDB->persistant = false;
$config->slaveDB->driver = 'mysql';
$config->slaveDB->encoding = 'UTF8';
$config->slaveDB->strictMode = false;
$config->slaveDB->checkCentOS= true;
/* Include the custom config file. */
$configRoot = dirname(__FILE__) . DIRECTORY_SEPARATOR;
$myConfig = $configRoot . 'my.php';
if(file_exists($myConfig)) include $myConfig;
/* Include extension config files. */
$extConfigFiles = glob($configRoot . 'ext/*.php');
foreach($extConfigFiles as $extConfigFile) include $extConfigFile;
/* Set default table prefix. */
if(!isset($config->db->prefix)) $config->db->prefix = 'zt_';
/* Define the tables. */
define('TABLE_COMPANY', '`' . $config->db->prefix . 'company`');
define('TABLE_DEPT', '`' . $config->db->prefix . 'dept`');
define('TABLE_CONFIG', '`' . $config->db->prefix . 'config`');
define('TABLE_USER', '`' . $config->db->prefix . 'user`');
define('TABLE_TODO', '`' . $config->db->prefix . 'todo`');
define('TABLE_GROUP', '`' . $config->db->prefix . 'group`');
define('TABLE_GROUPPRIV', '`' . $config->db->prefix . 'groupPriv`');
define('TABLE_USERGROUP', '`' . $config->db->prefix . 'userGroup`');
define('TABLE_USERQUERY', '`' . $config->db->prefix . 'userQuery`');
define('TABLE_BUG', '`' . $config->db->prefix . 'bug`');
define('TABLE_CASE', '`' . $config->db->prefix . 'case`');
define('TABLE_CASESTEP', '`' . $config->db->prefix . 'caseStep`');
define('TABLE_TESTTASK', '`' . $config->db->prefix . 'testTask`');
define('TABLE_TESTRUN', '`' . $config->db->prefix . 'testRun`');
define('TABLE_TESTRESULT', '`' . $config->db->prefix . 'testResult`');
define('TABLE_USERTPL', '`' . $config->db->prefix . 'userTPL`');
define('TABLE_PRODUCT', '`' . $config->db->prefix . 'product`');
define('TABLE_STORY', '`' . $config->db->prefix . 'story`');
define('TABLE_STORYSPEC', '`' . $config->db->prefix . 'storySpec`');
define('TABLE_PRODUCTPLAN', '`' . $config->db->prefix . 'productPlan`');
define('TABLE_RELEASE', '`' . $config->db->prefix . 'release`');
define('TABLE_PROJECT', '`' . $config->db->prefix . 'project`');
define('TABLE_TASK', '`' . $config->db->prefix . 'task`');
define('TABLE_TEAM', '`' . $config->db->prefix . 'team`');
define('TABLE_PROJECTPRODUCT','`' . $config->db->prefix . 'projectProduct`');
define('TABLE_PROJECTSTORY', '`' . $config->db->prefix . 'projectStory`');
define('TABLE_TASKESTIMATE', '`' . $config->db->prefix . 'taskEstimate`');
define('TABLE_EFFORT', '`' . $config->db->prefix . 'effort`');
define('TABLE_BURN', '`' . $config->db->prefix . 'burn`');
define('TABLE_BUILD', '`' . $config->db->prefix . 'build`');
define('TABLE_DOCLIB', '`' . $config->db->prefix . 'docLib`');
define('TABLE_DOC', '`' . $config->db->prefix . 'doc`');
define('TABLE_MODULE', '`' . $config->db->prefix . 'module`');
define('TABLE_ACTION', '`' . $config->db->prefix . 'action`');
define('TABLE_FILE', '`' . $config->db->prefix . 'file`');
define('TABLE_HISTORY', '`' . $config->db->prefix . 'history`');
define('TABLE_EXTENSION', '`' . $config->db->prefix . 'extension`');
<?php
/**
* The config file of ZenTaoPMS.
*
* Don't modify this file directly, copy the item to my.php and change it.
*
* @copyright Copyright 2009-2012 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package config
* @version $Id$
* @link http://www.zentao.net
*/
/* Basic settings. */
$config->version = '3.0.beta1'; // The version of zentaopms. Don't change it.
$config->encoding = 'UTF-8'; // The encoding of znetaopms.
$config->cookieLife = time() + 2592000; // The cookie life time.
$config->timezone = 'Asia/Shanghai'; // The time zone setting, for more see http://www.php.net/manual/en/timezones.php
$config->webRoot = ''; // The root path of the pms.
/* The request settings. */
$config->requestType = 'PATH_INFO'; // The request type: PATH_INFO|GET, if PATH_INFO, must use url rewrite.
$config->pathType = 'clean'; // If the request type is PATH_INFO, the path type.
$config->requestFix = '-'; // The divider in the url when PATH_INFO.
$config->moduleVar = 'm'; // requestType=GET: the module var name.
$config->methodVar = 'f'; // requestType=GET: the method var name.
$config->viewVar = 't'; // requestType=GET: the view var name.
$config->sessionVar = 'sid'; // requestType=GET: the session var name.
/* Supported views. */
$config->views = ',html,json,';
/* Set the wide window size. */
$config->wideSize = 1400;
/* Supported languages. */
$config->langs['zh-cn'] = '中文简体';
$config->langs['zh-tw'] = '中文繁體';
$config->langs['en'] = 'English';
/* Default settings. */
$config->default->view = 'html'; // Default view.
$config->default->lang = 'en'; // Default language.
$config->default->theme = 'default'; // Default theme.
$config->default->module = 'index'; // Default module.
$config->default->method = 'index'; // Default method.
/* Upload settings. */
$config->file->dangers = 'php,jsp,py,rb,asp,'; // Dangerous files.
$config->file->maxSize = 1024 * 1024; // Max size.
/* Master database settings. */
$config->db->persistant = false; // Pconnect or not.
$config->db->driver = 'mysql'; // Must be MySQL. Don't support other database server yet.
$config->db->encoding = 'UTF8'; // Encoding of database.
$config->db->strictMode = false; // Turn off the strict mode of MySQL.
//$config->db->emulatePrepare = true; // PDO::ATTR_EMULATE_PREPARES
//$config->db->bufferQuery = true; // PDO::MYSQL_ATTR_USE_BUFFERED_QUERY
/* Slave database settings. */
$config->slaveDB->persistant = false;
$config->slaveDB->driver = 'mysql';
$config->slaveDB->encoding = 'UTF8';
$config->slaveDB->strictMode = false;
$config->slaveDB->checkCentOS= true;
/* Include the custom config file. */
$configRoot = dirname(__FILE__) . DIRECTORY_SEPARATOR;
$myConfig = $configRoot . 'my.php';
if(file_exists($myConfig)) include $myConfig;
/* Include extension config files. */
$extConfigFiles = glob($configRoot . 'ext/*.php');
foreach($extConfigFiles as $extConfigFile) include $extConfigFile;
/* Set default table prefix. */
if(!isset($config->db->prefix)) $config->db->prefix = 'zt_';
/* Define the tables. */
define('TABLE_COMPANY', '`' . $config->db->prefix . 'company`');
define('TABLE_DEPT', '`' . $config->db->prefix . 'dept`');
define('TABLE_CONFIG', '`' . $config->db->prefix . 'config`');
define('TABLE_USER', '`' . $config->db->prefix . 'user`');
define('TABLE_TODO', '`' . $config->db->prefix . 'todo`');
define('TABLE_GROUP', '`' . $config->db->prefix . 'group`');
define('TABLE_GROUPPRIV', '`' . $config->db->prefix . 'groupPriv`');
define('TABLE_USERGROUP', '`' . $config->db->prefix . 'userGroup`');
define('TABLE_USERQUERY', '`' . $config->db->prefix . 'userQuery`');
define('TABLE_BUG', '`' . $config->db->prefix . 'bug`');
define('TABLE_CASE', '`' . $config->db->prefix . 'case`');
define('TABLE_CASESTEP', '`' . $config->db->prefix . 'caseStep`');
define('TABLE_TESTTASK', '`' . $config->db->prefix . 'testTask`');
define('TABLE_TESTRUN', '`' . $config->db->prefix . 'testRun`');
define('TABLE_TESTRESULT', '`' . $config->db->prefix . 'testResult`');
define('TABLE_USERTPL', '`' . $config->db->prefix . 'userTPL`');
define('TABLE_PRODUCT', '`' . $config->db->prefix . 'product`');
define('TABLE_STORY', '`' . $config->db->prefix . 'story`');
define('TABLE_STORYSPEC', '`' . $config->db->prefix . 'storySpec`');
define('TABLE_PRODUCTPLAN', '`' . $config->db->prefix . 'productPlan`');
define('TABLE_RELEASE', '`' . $config->db->prefix . 'release`');
define('TABLE_PROJECT', '`' . $config->db->prefix . 'project`');
define('TABLE_TASK', '`' . $config->db->prefix . 'task`');
define('TABLE_TEAM', '`' . $config->db->prefix . 'team`');
define('TABLE_PROJECTPRODUCT','`' . $config->db->prefix . 'projectProduct`');
define('TABLE_PROJECTSTORY', '`' . $config->db->prefix . 'projectStory`');
define('TABLE_TASKESTIMATE', '`' . $config->db->prefix . 'taskEstimate`');
define('TABLE_EFFORT', '`' . $config->db->prefix . 'effort`');
define('TABLE_BURN', '`' . $config->db->prefix . 'burn`');
define('TABLE_BUILD', '`' . $config->db->prefix . 'build`');
define('TABLE_DOCLIB', '`' . $config->db->prefix . 'docLib`');
define('TABLE_DOC', '`' . $config->db->prefix . 'doc`');
define('TABLE_MODULE', '`' . $config->db->prefix . 'module`');
define('TABLE_ACTION', '`' . $config->db->prefix . 'action`');
define('TABLE_FILE', '`' . $config->db->prefix . 'file`');
define('TABLE_HISTORY', '`' . $config->db->prefix . 'history`');
define('TABLE_EXTENSION', '`' . $config->db->prefix . 'extension`');

File diff suppressed because it is too large Load Diff

View File

@@ -1,66 +1,66 @@
<?php
/**
* The control file of action module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
class action extends control
{
/**
* Trash
*
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
public function trash($orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Save session. */
$uri = $this->app->getURI(true);
$this->session->set('productList', $uri);
$this->session->set('productPlanList', $uri);
$this->session->set('releaseList', $uri);
$this->session->set('storyList', $uri);
$this->session->set('projectList', $uri);
$this->session->set('taskList', $uri);
$this->session->set('buildList', $uri);
$this->session->set('bugList', $uri);
$this->session->set('caseList', $uri);
$this->session->set('testtaskList', $uri);
/* Header and position. */
$this->view->header->title = $this->lang->action->trash;
$this->view->position[] = $this->lang->action->trash;
/* Get deleted objects. */
$this->app->loadClass('pager', $static = true);
$pager = pager::init($recTotal, $recPerPage, $pageID);
$this->view->trashes = $this->action->getTrashes($orderBy, $pager);
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->users['system'] = 'system';
$this->view->orderBy = $orderBy;
$this->view->pager = $pager;
$this->display();
}
/**
* Undelete an object.
*
* @param int $actionID
* @access public
* @return void
*/
public function undelete($actionID)
{
$this->action->undelete($actionID);
die(js::locate(inlink('trash'), 'parent'));
}
}
<?php
/**
* The control file of action module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
class action extends control
{
/**
* Trash
*
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
public function trash($orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Save session. */
$uri = $this->app->getURI(true);
$this->session->set('productList', $uri);
$this->session->set('productPlanList', $uri);
$this->session->set('releaseList', $uri);
$this->session->set('storyList', $uri);
$this->session->set('projectList', $uri);
$this->session->set('taskList', $uri);
$this->session->set('buildList', $uri);
$this->session->set('bugList', $uri);
$this->session->set('caseList', $uri);
$this->session->set('testtaskList', $uri);
/* Header and position. */
$this->view->header->title = $this->lang->action->trash;
$this->view->position[] = $this->lang->action->trash;
/* Get deleted objects. */
$this->app->loadClass('pager', $static = true);
$pager = pager::init($recTotal, $recPerPage, $pageID);
$this->view->trashes = $this->action->getTrashes($orderBy, $pager);
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->users['system'] = 'system';
$this->view->orderBy = $orderBy;
$this->view->pager = $pager;
$this->display();
}
/**
* Undelete an object.
*
* @param int $actionID
* @access public
* @return void
*/
public function undelete($actionID)
{
$this->action->undelete($actionID);
die(js::locate(inlink('trash'), 'parent'));
}
}

View File

@@ -1,181 +1,181 @@
<?php
/**
* The action module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
$lang->action->common = 'Logs';
$lang->action->trash = 'Trash';
$lang->action->undelete = 'Restore';
$lang->action->product = 'Product';
$lang->action->project = 'Project';
$lang->action->objectType = 'Object';
$lang->action->objectID = 'ID';
$lang->action->objectName = 'Name';
$lang->action->actor = 'Actor';
$lang->action->action = 'Action';
$lang->action->actionID = 'ActionID';
$lang->action->date = 'Date';
$lang->action->trashTips = "Tips:The deleting actions in zentao are all logic";
$lang->action->dynamic->today = 'Today';
$lang->action->dynamic->yesterday = 'Yesterday';
$lang->action->dynamic->twoDaysAgo = 'Two days ago';
$lang->action->dynamic->thisWeek = 'This week';
$lang->action->dynamic->lastWeek = 'Last week';
$lang->action->dynamic->thisMonth = 'This month';
$lang->action->dynamic->lastMonth = 'Last month';
$lang->action->dynamic->all = 'All';
$lang->action->dynamic->search = 'Search';
$lang->action->objectTypes['product'] = 'PRODUCT';
$lang->action->objectTypes['story'] = 'STORY';
$lang->action->objectTypes['productplan'] = 'PLAN';
$lang->action->objectTypes['release'] = 'RELEASE';
$lang->action->objectTypes['project'] = 'PROJECT';
$lang->action->objectTypes['task'] = 'TASK';
$lang->action->objectTypes['build'] = 'Build';
$lang->action->objectTypes['bug'] = 'Bug';
$lang->action->objectTypes['case'] = 'Case';
$lang->action->objectTypes['testtask'] = 'Test Task';
$lang->action->objectTypes['user'] = 'User';
$lang->action->objectTypes['doc'] = 'DOC';
$lang->action->objectTypes['doclib'] = 'DocLib';
$lang->action->objectTypes['todo'] = 'TODO';
/* The desc of actions. */
$lang->action->desc->common = '$date, <strong>$action</strong> by <strong>$actor</strong>';
$lang->action->desc->extra = '$date, <strong>$action</strong> as <strong>$extra</strong> by <strong>$actor</strong>';
$lang->action->desc->opened = '$date, Opened by <strong>$actor</strong>.';
$lang->action->desc->created = '$date, Created by <strong>$actor</strong>.';
$lang->action->desc->changed = '$date, Changed by <strong>$actor</strong>.';
$lang->action->desc->edited = '$date, Edited by <strong>$actor</strong>.';
$lang->action->desc->assigned = '$date, <strong>$actor</strong> assigned task to <strong>$extra</strong>.' . "\n";
$lang->action->desc->closed = '$date, Closed by <strong>$actor</strong>.';
$lang->action->desc->deleted = '$date, Deleted by <strong>$actor</strong>.';
$lang->action->desc->deletedfile = '$date, Deleted file by <strong>$actor</strong>, the file is <strong><i>$extra</i></strong>';
$lang->action->desc->editfile = '$date, Edit file by <strong>$actor</strong>, the file is <strong><i>$extra</i></strong>';
$lang->action->desc->erased = '$date, Erased by <strong>$actor</strong>.';
$lang->action->desc->undeleted = '$date, Restored by <strong>$actor</strong>.';
$lang->action->desc->commented = '$date, Commented by <strong>$actor</strong>.';
$lang->action->desc->activated = '$date, Activated by <strong>$actor</strong>.';
$lang->action->desc->moved = '$date, Moved by <strong>$actor</strong>, previouse is "$extra"';
$lang->action->desc->confirmed = '$date, Confirmed by <strong>$actor</strong>, version is<strong>#$extra</strong>';
$lang->action->desc->bugconfirmed = '$date, Confirmed by <strong>$actor</strong>';
$lang->action->desc->frombug = '$date, From Bug by <strong>$actor</strong> BugID:<strong>$extra</strong>。';
$lang->action->desc->started = '$date, Started by <strong>$actor</strong>.';
$lang->action->desc->canceled = '$date, Canceled by <strong>$actor</strong>.';
$lang->action->desc->svncommited = '$date, <strong>$actor</strong> commited to svnrevision is <strong>#$extra</strong>' . "\n";
$lang->action->desc->finished = '$date, Finished by <strong>$actor</strong>.';
$lang->action->desc->diff1 = 'Changed <strong><i>%s</i></strong>, old is "%s", new is "%s".<br />';
$lang->action->desc->diff2 = 'Changed <strong><i>%s</i></strong>, the diff is<blockquote>%s</blockquote>' . "\n";
$lang->action->desc->diff3 = "Changed file's name %s to %s ";
/* The action labels. */
$lang->action->label->created = 'created';
$lang->action->label->opened = 'opened';
$lang->action->label->changed = 'changed';
$lang->action->label->edited = 'edited';
$lang->action->label->assigned = 'assigned';
$lang->action->label->closed = 'closed';
$lang->action->label->deleted = 'deleted';
$lang->action->label->deletedfile = 'deleted file';
$lang->action->label->editfile = 'edit file name';
$lang->action->label->erased = 'deleted';
$lang->action->label->undeleted = 'restore';
$lang->action->label->commented = 'commented';
$lang->action->label->activated = 'activated';
$lang->action->label->resolved = 'resolved';
$lang->action->label->reviewed = 'reviewed';
$lang->action->label->moved = 'moded';
$lang->action->label->confirmed = 'confirmed,';
$lang->action->label->bugconfirmed = 'confirmed';
$lang->action->label->tostory = 'converted to story';
$lang->action->label->frombug = 'converted from bug';
$lang->action->label->totask = 'converted to task';
$lang->action->label->svncommited = 'commited code';
$lang->action->label->linked2plan = 'link to plan';
$lang->action->label->unlinkedfromplan = 'unlink from plan';
$lang->action->label->linked2project = 'link to project';
$lang->action->label->unlinkedfromproject = 'unlik from project';
$lang->action->label->marked = 'edited';
$lang->action->label->started = 'started';
$lang->action->label->canceled = 'canceled';
$lang->action->label->finished = 'finished';
$lang->action->label->login = 'login';
$lang->action->label->logout = "logout";
/* Link of every action. */
$lang->action->label->product = 'product|product|view|productID=%s';
$lang->action->label->productplan = 'plan|productplan|view|productID=%s';
$lang->action->label->release = 'release|release|view|productID=%s';
$lang->action->label->story = 'story|story|view|storyID=%s';
$lang->action->label->project = 'project|project|view|projectID=%s';
$lang->action->label->task = 'task|task|view|taskID=%s';
$lang->action->label->build = 'build|build|view|buildID=%s';
$lang->action->label->bug = 'bug|bug|view|bugID=%s';
$lang->action->label->case = 'case|testcase|view|caseID=%s';
$lang->action->label->testtask = 'test task|testtask|view|caseID=%s';
$lang->action->label->todo = 'todo|todo|view|todoID=%s';
$lang->action->label->doclib = 'doc library|doc|browse|libID=%s';
$lang->action->label->doc = 'doc|doc|view|docID=%s';
$lang->action->label->user = 'user';
$lang->action->label->space = ' ';
/* Object type. */
$lang->action->search->objectTypeList[''] = '';
$lang->action->search->objectTypeList['product'] = 'product';
$lang->action->search->objectTypeList['project'] = 'project';
$lang->action->search->objectTypeList['bug'] = 'bug';
$lang->action->search->objectTypeList['case'] = 'case';
$lang->action->search->objectTypeList['story'] = 'story';
$lang->action->search->objectTypeList['task'] = 'task';
$lang->action->search->objectTypeList['testtask'] = 'testtask';
$lang->action->search->objectTypeList['user'] = 'user';
$lang->action->search->objectTypeList['doc'] = 'doc';
$lang->action->search->objectTypeList['doclib'] = 'doclib';
$lang->action->search->objectTypeList['todo'] = 'todo';
$lang->action->search->objectTypeList['build'] = 'build';
$lang->action->search->objectTypeList['release'] = 'release';
$lang->action->search->objectTypeList['productplan'] = 'productplan';
/* Display action for search. */
$lang->action->search->label[''] = '';
$lang->action->search->label['created'] = $lang->action->label->created;
$lang->action->search->label['opened'] = $lang->action->label->opened;
$lang->action->search->label['changed'] = $lang->action->label->changed;
$lang->action->search->label['edited'] = $lang->action->label->edited;
$lang->action->search->label['assigned'] = $lang->action->label->assigned;
$lang->action->search->label['closed'] = $lang->action->label->closed;
$lang->action->search->label['deleted'] = $lang->action->label->deleted;
$lang->action->search->label['deletedfile'] = $lang->action->label->deletedfile;
$lang->action->search->label['editfile'] = $lang->action->label->editfile;
$lang->action->search->label['erased'] = $lang->action->label->erased;
$lang->action->search->label['undeleted'] = $lang->action->label->undeleted;
$lang->action->search->label['commented'] = $lang->action->label->commented;
$lang->action->search->label['activated'] = $lang->action->label->activated;
$lang->action->search->label['resolved'] = $lang->action->label->resolved;
$lang->action->search->label['reviewed'] = $lang->action->label->reviewed;
$lang->action->search->label['moved'] = $lang->action->label->moved;
$lang->action->search->label['confirmed'] = $lang->action->label->confirmed;
$lang->action->search->label['bugconfirmed'] = $lang->action->label->bugconfirmed;
$lang->action->search->label['tostory'] = $lang->action->label->tostory;
$lang->action->search->label['frombug'] = $lang->action->label->frombug;
$lang->action->search->label['totask'] = $lang->action->label->totask;
$lang->action->search->label['svncommited'] = $lang->action->label->svncommited;
$lang->action->search->label['linked2plan'] = $lang->action->label->linked2plan;
$lang->action->search->label['unlinkedfromplan'] = $lang->action->label->unlinkedfromplan;
$lang->action->search->label['linked2project'] = $lang->action->label->linked2project;
$lang->action->search->label['unlinkedfromproject'] = $lang->action->label->unlinkedfromproject;
$lang->action->search->label['marked'] = $lang->action->label->marked;
$lang->action->search->label['started'] = $lang->action->label->started;
$lang->action->search->label['canceled'] = $lang->action->label->canceled;
$lang->action->search->label['finished'] = $lang->action->label->finished;
$lang->action->search->label['login'] = $lang->action->label->login;
$lang->action->search->label['logout'] = $lang->action->label->logout;
<?php
/**
* The action module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
$lang->action->common = 'Logs';
$lang->action->trash = 'Trash';
$lang->action->undelete = 'Restore';
$lang->action->product = 'Product';
$lang->action->project = 'Project';
$lang->action->objectType = 'Object';
$lang->action->objectID = 'ID';
$lang->action->objectName = 'Name';
$lang->action->actor = 'Actor';
$lang->action->action = 'Action';
$lang->action->actionID = 'ActionID';
$lang->action->date = 'Date';
$lang->action->trashTips = "Tips:The deleting actions in zentao are all logic";
$lang->action->dynamic->today = 'Today';
$lang->action->dynamic->yesterday = 'Yesterday';
$lang->action->dynamic->twoDaysAgo = 'Two days ago';
$lang->action->dynamic->thisWeek = 'This week';
$lang->action->dynamic->lastWeek = 'Last week';
$lang->action->dynamic->thisMonth = 'This month';
$lang->action->dynamic->lastMonth = 'Last month';
$lang->action->dynamic->all = 'All';
$lang->action->dynamic->search = 'Search';
$lang->action->objectTypes['product'] = 'PRODUCT';
$lang->action->objectTypes['story'] = 'STORY';
$lang->action->objectTypes['productplan'] = 'PLAN';
$lang->action->objectTypes['release'] = 'RELEASE';
$lang->action->objectTypes['project'] = 'PROJECT';
$lang->action->objectTypes['task'] = 'TASK';
$lang->action->objectTypes['build'] = 'Build';
$lang->action->objectTypes['bug'] = 'Bug';
$lang->action->objectTypes['case'] = 'Case';
$lang->action->objectTypes['testtask'] = 'Test Task';
$lang->action->objectTypes['user'] = 'User';
$lang->action->objectTypes['doc'] = 'DOC';
$lang->action->objectTypes['doclib'] = 'DocLib';
$lang->action->objectTypes['todo'] = 'TODO';
/* The desc of actions. */
$lang->action->desc->common = '$date, <strong>$action</strong> by <strong>$actor</strong>';
$lang->action->desc->extra = '$date, <strong>$action</strong> as <strong>$extra</strong> by <strong>$actor</strong>';
$lang->action->desc->opened = '$date, Opened by <strong>$actor</strong>.';
$lang->action->desc->created = '$date, Created by <strong>$actor</strong>.';
$lang->action->desc->changed = '$date, Changed by <strong>$actor</strong>.';
$lang->action->desc->edited = '$date, Edited by <strong>$actor</strong>.';
$lang->action->desc->assigned = '$date, <strong>$actor</strong> assigned task to <strong>$extra</strong>.' . "\n";
$lang->action->desc->closed = '$date, Closed by <strong>$actor</strong>.';
$lang->action->desc->deleted = '$date, Deleted by <strong>$actor</strong>.';
$lang->action->desc->deletedfile = '$date, Deleted file by <strong>$actor</strong>, the file is <strong><i>$extra</i></strong>';
$lang->action->desc->editfile = '$date, Edit file by <strong>$actor</strong>, the file is <strong><i>$extra</i></strong>';
$lang->action->desc->erased = '$date, Erased by <strong>$actor</strong>.';
$lang->action->desc->undeleted = '$date, Restored by <strong>$actor</strong>.';
$lang->action->desc->commented = '$date, Commented by <strong>$actor</strong>.';
$lang->action->desc->activated = '$date, Activated by <strong>$actor</strong>.';
$lang->action->desc->moved = '$date, Moved by <strong>$actor</strong>, previouse is "$extra"';
$lang->action->desc->confirmed = '$date, Confirmed by <strong>$actor</strong>, version is<strong>#$extra</strong>';
$lang->action->desc->bugconfirmed = '$date, Confirmed by <strong>$actor</strong>';
$lang->action->desc->frombug = '$date, From Bug by <strong>$actor</strong> BugID:<strong>$extra</strong>。';
$lang->action->desc->started = '$date, Started by <strong>$actor</strong>.';
$lang->action->desc->canceled = '$date, Canceled by <strong>$actor</strong>.';
$lang->action->desc->svncommited = '$date, <strong>$actor</strong> commited to svnrevision is <strong>#$extra</strong>' . "\n";
$lang->action->desc->finished = '$date, Finished by <strong>$actor</strong>.';
$lang->action->desc->diff1 = 'Changed <strong><i>%s</i></strong>, old is "%s", new is "%s".<br />';
$lang->action->desc->diff2 = 'Changed <strong><i>%s</i></strong>, the diff is<blockquote>%s</blockquote>' . "\n";
$lang->action->desc->diff3 = "Changed file's name %s to %s ";
/* The action labels. */
$lang->action->label->created = 'created';
$lang->action->label->opened = 'opened';
$lang->action->label->changed = 'changed';
$lang->action->label->edited = 'edited';
$lang->action->label->assigned = 'assigned';
$lang->action->label->closed = 'closed';
$lang->action->label->deleted = 'deleted';
$lang->action->label->deletedfile = 'deleted file';
$lang->action->label->editfile = 'edit file name';
$lang->action->label->erased = 'deleted';
$lang->action->label->undeleted = 'restore';
$lang->action->label->commented = 'commented';
$lang->action->label->activated = 'activated';
$lang->action->label->resolved = 'resolved';
$lang->action->label->reviewed = 'reviewed';
$lang->action->label->moved = 'moded';
$lang->action->label->confirmed = 'confirmed,';
$lang->action->label->bugconfirmed = 'confirmed';
$lang->action->label->tostory = 'converted to story';
$lang->action->label->frombug = 'converted from bug';
$lang->action->label->totask = 'converted to task';
$lang->action->label->svncommited = 'commited code';
$lang->action->label->linked2plan = 'link to plan';
$lang->action->label->unlinkedfromplan = 'unlink from plan';
$lang->action->label->linked2project = 'link to project';
$lang->action->label->unlinkedfromproject = 'unlik from project';
$lang->action->label->marked = 'edited';
$lang->action->label->started = 'started';
$lang->action->label->canceled = 'canceled';
$lang->action->label->finished = 'finished';
$lang->action->label->login = 'login';
$lang->action->label->logout = "logout";
/* Link of every action. */
$lang->action->label->product = 'product|product|view|productID=%s';
$lang->action->label->productplan = 'plan|productplan|view|productID=%s';
$lang->action->label->release = 'release|release|view|productID=%s';
$lang->action->label->story = 'story|story|view|storyID=%s';
$lang->action->label->project = 'project|project|view|projectID=%s';
$lang->action->label->task = 'task|task|view|taskID=%s';
$lang->action->label->build = 'build|build|view|buildID=%s';
$lang->action->label->bug = 'bug|bug|view|bugID=%s';
$lang->action->label->case = 'case|testcase|view|caseID=%s';
$lang->action->label->testtask = 'test task|testtask|view|caseID=%s';
$lang->action->label->todo = 'todo|todo|view|todoID=%s';
$lang->action->label->doclib = 'doc library|doc|browse|libID=%s';
$lang->action->label->doc = 'doc|doc|view|docID=%s';
$lang->action->label->user = 'user';
$lang->action->label->space = ' ';
/* Object type. */
$lang->action->search->objectTypeList[''] = '';
$lang->action->search->objectTypeList['product'] = 'product';
$lang->action->search->objectTypeList['project'] = 'project';
$lang->action->search->objectTypeList['bug'] = 'bug';
$lang->action->search->objectTypeList['case'] = 'case';
$lang->action->search->objectTypeList['story'] = 'story';
$lang->action->search->objectTypeList['task'] = 'task';
$lang->action->search->objectTypeList['testtask'] = 'testtask';
$lang->action->search->objectTypeList['user'] = 'user';
$lang->action->search->objectTypeList['doc'] = 'doc';
$lang->action->search->objectTypeList['doclib'] = 'doclib';
$lang->action->search->objectTypeList['todo'] = 'todo';
$lang->action->search->objectTypeList['build'] = 'build';
$lang->action->search->objectTypeList['release'] = 'release';
$lang->action->search->objectTypeList['productplan'] = 'productplan';
/* Display action for search. */
$lang->action->search->label[''] = '';
$lang->action->search->label['created'] = $lang->action->label->created;
$lang->action->search->label['opened'] = $lang->action->label->opened;
$lang->action->search->label['changed'] = $lang->action->label->changed;
$lang->action->search->label['edited'] = $lang->action->label->edited;
$lang->action->search->label['assigned'] = $lang->action->label->assigned;
$lang->action->search->label['closed'] = $lang->action->label->closed;
$lang->action->search->label['deleted'] = $lang->action->label->deleted;
$lang->action->search->label['deletedfile'] = $lang->action->label->deletedfile;
$lang->action->search->label['editfile'] = $lang->action->label->editfile;
$lang->action->search->label['erased'] = $lang->action->label->erased;
$lang->action->search->label['undeleted'] = $lang->action->label->undeleted;
$lang->action->search->label['commented'] = $lang->action->label->commented;
$lang->action->search->label['activated'] = $lang->action->label->activated;
$lang->action->search->label['resolved'] = $lang->action->label->resolved;
$lang->action->search->label['reviewed'] = $lang->action->label->reviewed;
$lang->action->search->label['moved'] = $lang->action->label->moved;
$lang->action->search->label['confirmed'] = $lang->action->label->confirmed;
$lang->action->search->label['bugconfirmed'] = $lang->action->label->bugconfirmed;
$lang->action->search->label['tostory'] = $lang->action->label->tostory;
$lang->action->search->label['frombug'] = $lang->action->label->frombug;
$lang->action->search->label['totask'] = $lang->action->label->totask;
$lang->action->search->label['svncommited'] = $lang->action->label->svncommited;
$lang->action->search->label['linked2plan'] = $lang->action->label->linked2plan;
$lang->action->search->label['unlinkedfromplan'] = $lang->action->label->unlinkedfromplan;
$lang->action->search->label['linked2project'] = $lang->action->label->linked2project;
$lang->action->search->label['unlinkedfromproject'] = $lang->action->label->unlinkedfromproject;
$lang->action->search->label['marked'] = $lang->action->label->marked;
$lang->action->search->label['started'] = $lang->action->label->started;
$lang->action->search->label['canceled'] = $lang->action->label->canceled;
$lang->action->search->label['finished'] = $lang->action->label->finished;
$lang->action->search->label['login'] = $lang->action->label->login;
$lang->action->search->label['logout'] = $lang->action->label->logout;

View File

@@ -1,181 +1,181 @@
<?php
/**
* The action module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
$lang->action->common = '系统日志';
$lang->action->trash = '回收站';
$lang->action->undelete = '还原';
$lang->action->product = '产品';
$lang->action->project = '项目';
$lang->action->objectType = '对象类型';
$lang->action->objectID = '对象ID';
$lang->action->objectName = '对象名称';
$lang->action->actor = '操作者';
$lang->action->action = '动作';
$lang->action->actionID = '记录ID';
$lang->action->date = '日期';
$lang->action->trashTips = '提示:为了保证系统的完整性,禅道系统的删除都是标记删除。';
$lang->action->dynamic->today = '今天';
$lang->action->dynamic->yesterday = '昨天';
$lang->action->dynamic->twoDaysAgo = '前天';
$lang->action->dynamic->thisWeek = '本周';
$lang->action->dynamic->lastWeek = '上周';
$lang->action->dynamic->thisMonth = '本月';
$lang->action->dynamic->lastMonth = '上月';
$lang->action->dynamic->all = '所有';
$lang->action->dynamic->search = '搜索';
$lang->action->objectTypes['product'] = '产品';
$lang->action->objectTypes['story'] = '需求';
$lang->action->objectTypes['productplan'] = '产品计划';
$lang->action->objectTypes['release'] = '发布';
$lang->action->objectTypes['project'] = '项目';
$lang->action->objectTypes['task'] = '任务';
$lang->action->objectTypes['build'] = 'Build';
$lang->action->objectTypes['bug'] = 'Bug';
$lang->action->objectTypes['case'] = '用例';
$lang->action->objectTypes['testtask'] = '测试任务';
$lang->action->objectTypes['user'] = '用户';
$lang->action->objectTypes['doc'] = '文档';
$lang->action->objectTypes['doclib'] = '文档库';
$lang->action->objectTypes['todo'] = 'TODO';
/* 用来描述操作历史记录。*/
$lang->action->desc->common = '$date, <strong>$action</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->extra = '$date, <strong>$action</strong> as <strong>$extra</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->opened = '$date, 由 <strong>$actor</strong> 创建。' . "\n";
$lang->action->desc->created = '$date, 由 <strong>$actor</strong> 创建。' . "\n";
$lang->action->desc->changed = '$date, 由 <strong>$actor</strong> 变更。' . "\n";
$lang->action->desc->edited = '$date, 由 <strong>$actor</strong> 编辑。' . "\n";
$lang->action->desc->assigned = '$date, 由 <strong>$actor</strong> 指派给 <strong>$extra</strong>' . "\n";
$lang->action->desc->closed = '$date, 由 <strong>$actor</strong> 关闭。' . "\n";
$lang->action->desc->deleted = '$date, 由 <strong>$actor</strong> 删除。' . "\n";
$lang->action->desc->deletedfile = '$date, 由 <strong>$actor</strong> 删除了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->editfile = '$date, 由 <strong>$actor</strong> 编辑了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->erased = '$date, 由 <strong>$actor</strong> 删除。' . "\n";
$lang->action->desc->undeleted = '$date, 由 <strong>$actor</strong> 还原。' . "\n";
$lang->action->desc->commented = '$date, 由 <strong>$actor</strong> 添加备注。' . "\n";
$lang->action->desc->activated = '$date, 由 <strong>$actor</strong> 激活。' . "\n";
$lang->action->desc->moved = '$date, 由 <strong>$actor</strong> 移动,之前为 "$extra"' . "\n";
$lang->action->desc->confirmed = '$date, 由 <strong>$actor</strong> 确认需求变动,最新版本为<strong>#$extra</strong>' . "\n";
$lang->action->desc->bugconfirmed = '$date, 由 <strong>$actor</strong> 确认Bug' . "\n";
$lang->action->desc->frombug = '$date, 由 <strong>$actor</strong> Bug转化而来Bug编号为 <strong>$extra</strong>。';
$lang->action->desc->started = '$date, 由 <strong>$actor</strong> 启动。' . "\n";
$lang->action->desc->canceled = '$date, 由 <strong>$actor</strong> 取消。' . "\n";
$lang->action->desc->svncommited = '$date, 由 <strong>$actor</strong> 提交代码,版本为<strong>#$extra</strong>' . "\n";
$lang->action->desc->finished = '$date, 由 <strong>$actor</strong> 完成。' . "\n";
$lang->action->desc->diff1 = '修改了 <strong><i>%s</i></strong>,旧值为 "%s",新值为 "%s"。<br />' . "\n";
$lang->action->desc->diff2 = '修改了 <strong><i>%s</i></strong>,区别为:' . "\n" . '<blockquote>%s</blockquote>' . "\n";
$lang->action->desc->diff3 = '将文件名 %s 改为 %s ' . "\n";
/* 用来显示动态信息。*/
$lang->action->label->created = '创建了';
$lang->action->label->opened = '创建了';
$lang->action->label->changed = '变更了';
$lang->action->label->edited = '编辑了';
$lang->action->label->assigned = '指派了';
$lang->action->label->closed = '关闭了';
$lang->action->label->deleted = '删除了';
$lang->action->label->deletedfile = '删除附件';
$lang->action->label->editfile = '编辑附件';
$lang->action->label->erased = '删除了';
$lang->action->label->undeleted = '还原了';
$lang->action->label->commented = '评论了';
$lang->action->label->activated = '激活了';
$lang->action->label->resolved = '解决了';
$lang->action->label->reviewed = '评审了';
$lang->action->label->moved = '移动了';
$lang->action->label->confirmed = '确认了需求,';
$lang->action->label->bugconfirmed = '确认了';
$lang->action->label->tostory = '转需求';
$lang->action->label->frombug = '转需求';
$lang->action->label->totask = '转任务';
$lang->action->label->svncommited = '提交代码';
$lang->action->label->linked2plan = '关联计划';
$lang->action->label->unlinkedfromplan = '移除计划';
$lang->action->label->linked2project = '关联项目';
$lang->action->label->unlinkedfromproject = '移除项目';
$lang->action->label->marked = '编辑了';
$lang->action->label->started = '开始了';
$lang->action->label->canceled = '取消了';
$lang->action->label->finished = '完成了';
$lang->action->label->login = '登录系统';
$lang->action->label->logout = "退出登录";
/* 用来生成相应对象的链接。*/
$lang->action->label->product = '产品|product|view|productID=%s';
$lang->action->label->productplan = '计划|productplan|view|productID=%s';
$lang->action->label->release = '发布|release|view|productID=%s';
$lang->action->label->story = '需求|story|view|storyID=%s';
$lang->action->label->project = '项目|project|view|projectID=%s';
$lang->action->label->task = '任务|task|view|taskID=%s';
$lang->action->label->build = 'Build|build|view|buildID=%s';
$lang->action->label->bug = 'Bug|bug|view|bugID=%s';
$lang->action->label->case = '用例|testcase|view|caseID=%s';
$lang->action->label->testtask = '测试任务|testtask|view|caseID=%s';
$lang->action->label->todo = 'todo|todo|view|todoID=%s';
$lang->action->label->doclib = '文档库|doc|browse|libID=%s';
$lang->action->label->doc = '文档|doc|view|docID=%s';
$lang->action->label->user = '用户';
$lang->action->label->space = ' ';
/* Object type. */
$lang->action->search->objectTypeList[''] = '';
$lang->action->search->objectTypeList['product'] = '产品';
$lang->action->search->objectTypeList['project'] = '项目';
$lang->action->search->objectTypeList['bug'] = 'Bug';
$lang->action->search->objectTypeList['case'] = '用例';
$lang->action->search->objectTypeList['story'] = '需求';
$lang->action->search->objectTypeList['task'] = '任务';
$lang->action->search->objectTypeList['testtask'] = '测试任务';
$lang->action->search->objectTypeList['user'] = '用户';
$lang->action->search->objectTypeList['doc'] = '文档';
$lang->action->search->objectTypeList['doclib'] = '文档库';
$lang->action->search->objectTypeList['todo'] = 'TODO';
$lang->action->search->objectTypeList['build'] = 'Build';
$lang->action->search->objectTypeList['release'] = '发布';
$lang->action->search->objectTypeList['productplan'] = '计划';
/* 用来在动态显示中显示动作 */
$lang->action->search->label[''] = '';
$lang->action->search->label['created'] = $lang->action->label->created;
$lang->action->search->label['opened'] = $lang->action->label->opened;
$lang->action->search->label['changed'] = $lang->action->label->changed;
$lang->action->search->label['edited'] = $lang->action->label->edited;
$lang->action->search->label['assigned'] = $lang->action->label->assigned;
$lang->action->search->label['closed'] = $lang->action->label->closed;
$lang->action->search->label['deleted'] = $lang->action->label->deleted;
$lang->action->search->label['deletedfile'] = $lang->action->label->deletedfile;
$lang->action->search->label['editfile'] = $lang->action->label->editfile;
$lang->action->search->label['erased'] = $lang->action->label->erased;
$lang->action->search->label['undeleted'] = $lang->action->label->undeleted;
$lang->action->search->label['commented'] = $lang->action->label->commented;
$lang->action->search->label['activated'] = $lang->action->label->activated;
$lang->action->search->label['resolved'] = $lang->action->label->resolved;
$lang->action->search->label['reviewed'] = $lang->action->label->reviewed;
$lang->action->search->label['moved'] = $lang->action->label->moved;
$lang->action->search->label['confirmed'] = $lang->action->label->confirmed;
$lang->action->search->label['bugconfirmed'] = $lang->action->label->bugconfirmed;
$lang->action->search->label['tostory'] = $lang->action->label->tostory;
$lang->action->search->label['frombug'] = $lang->action->label->frombug;
$lang->action->search->label['totask'] = $lang->action->label->totask;
$lang->action->search->label['svncommited'] = $lang->action->label->svncommited;
$lang->action->search->label['linked2plan'] = $lang->action->label->linked2plan;
$lang->action->search->label['unlinkedfromplan'] = $lang->action->label->unlinkedfromplan;
$lang->action->search->label['linked2project'] = $lang->action->label->linked2project;
$lang->action->search->label['unlinkedfromproject'] = $lang->action->label->unlinkedfromproject;
$lang->action->search->label['marked'] = $lang->action->label->marked;
$lang->action->search->label['started'] = $lang->action->label->started;
$lang->action->search->label['canceled'] = $lang->action->label->canceled;
$lang->action->search->label['finished'] = $lang->action->label->finished;
$lang->action->search->label['login'] = $lang->action->label->login;
$lang->action->search->label['logout'] = $lang->action->label->logout;
<?php
/**
* The action module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
$lang->action->common = '系统日志';
$lang->action->trash = '回收站';
$lang->action->undelete = '还原';
$lang->action->product = '产品';
$lang->action->project = '项目';
$lang->action->objectType = '对象类型';
$lang->action->objectID = '对象ID';
$lang->action->objectName = '对象名称';
$lang->action->actor = '操作者';
$lang->action->action = '动作';
$lang->action->actionID = '记录ID';
$lang->action->date = '日期';
$lang->action->trashTips = '提示:为了保证系统的完整性,禅道系统的删除都是标记删除。';
$lang->action->dynamic->today = '今天';
$lang->action->dynamic->yesterday = '昨天';
$lang->action->dynamic->twoDaysAgo = '前天';
$lang->action->dynamic->thisWeek = '本周';
$lang->action->dynamic->lastWeek = '上周';
$lang->action->dynamic->thisMonth = '本月';
$lang->action->dynamic->lastMonth = '上月';
$lang->action->dynamic->all = '所有';
$lang->action->dynamic->search = '搜索';
$lang->action->objectTypes['product'] = '产品';
$lang->action->objectTypes['story'] = '需求';
$lang->action->objectTypes['productplan'] = '产品计划';
$lang->action->objectTypes['release'] = '发布';
$lang->action->objectTypes['project'] = '项目';
$lang->action->objectTypes['task'] = '任务';
$lang->action->objectTypes['build'] = 'Build';
$lang->action->objectTypes['bug'] = 'Bug';
$lang->action->objectTypes['case'] = '用例';
$lang->action->objectTypes['testtask'] = '测试任务';
$lang->action->objectTypes['user'] = '用户';
$lang->action->objectTypes['doc'] = '文档';
$lang->action->objectTypes['doclib'] = '文档库';
$lang->action->objectTypes['todo'] = 'TODO';
/* 用来描述操作历史记录。*/
$lang->action->desc->common = '$date, <strong>$action</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->extra = '$date, <strong>$action</strong> as <strong>$extra</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->opened = '$date, 由 <strong>$actor</strong> 创建。' . "\n";
$lang->action->desc->created = '$date, 由 <strong>$actor</strong> 创建。' . "\n";
$lang->action->desc->changed = '$date, 由 <strong>$actor</strong> 变更。' . "\n";
$lang->action->desc->edited = '$date, 由 <strong>$actor</strong> 编辑。' . "\n";
$lang->action->desc->assigned = '$date, 由 <strong>$actor</strong> 指派给 <strong>$extra</strong>' . "\n";
$lang->action->desc->closed = '$date, 由 <strong>$actor</strong> 关闭。' . "\n";
$lang->action->desc->deleted = '$date, 由 <strong>$actor</strong> 删除。' . "\n";
$lang->action->desc->deletedfile = '$date, 由 <strong>$actor</strong> 删除了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->editfile = '$date, 由 <strong>$actor</strong> 编辑了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->erased = '$date, 由 <strong>$actor</strong> 删除。' . "\n";
$lang->action->desc->undeleted = '$date, 由 <strong>$actor</strong> 还原。' . "\n";
$lang->action->desc->commented = '$date, 由 <strong>$actor</strong> 添加备注。' . "\n";
$lang->action->desc->activated = '$date, 由 <strong>$actor</strong> 激活。' . "\n";
$lang->action->desc->moved = '$date, 由 <strong>$actor</strong> 移动,之前为 "$extra"' . "\n";
$lang->action->desc->confirmed = '$date, 由 <strong>$actor</strong> 确认需求变动,最新版本为<strong>#$extra</strong>' . "\n";
$lang->action->desc->bugconfirmed = '$date, 由 <strong>$actor</strong> 确认Bug' . "\n";
$lang->action->desc->frombug = '$date, 由 <strong>$actor</strong> Bug转化而来Bug编号为 <strong>$extra</strong>。';
$lang->action->desc->started = '$date, 由 <strong>$actor</strong> 启动。' . "\n";
$lang->action->desc->canceled = '$date, 由 <strong>$actor</strong> 取消。' . "\n";
$lang->action->desc->svncommited = '$date, 由 <strong>$actor</strong> 提交代码,版本为<strong>#$extra</strong>' . "\n";
$lang->action->desc->finished = '$date, 由 <strong>$actor</strong> 完成。' . "\n";
$lang->action->desc->diff1 = '修改了 <strong><i>%s</i></strong>,旧值为 "%s",新值为 "%s"。<br />' . "\n";
$lang->action->desc->diff2 = '修改了 <strong><i>%s</i></strong>,区别为:' . "\n" . '<blockquote>%s</blockquote>' . "\n";
$lang->action->desc->diff3 = '将文件名 %s 改为 %s ' . "\n";
/* 用来显示动态信息。*/
$lang->action->label->created = '创建了';
$lang->action->label->opened = '创建了';
$lang->action->label->changed = '变更了';
$lang->action->label->edited = '编辑了';
$lang->action->label->assigned = '指派了';
$lang->action->label->closed = '关闭了';
$lang->action->label->deleted = '删除了';
$lang->action->label->deletedfile = '删除附件';
$lang->action->label->editfile = '编辑附件';
$lang->action->label->erased = '删除了';
$lang->action->label->undeleted = '还原了';
$lang->action->label->commented = '评论了';
$lang->action->label->activated = '激活了';
$lang->action->label->resolved = '解决了';
$lang->action->label->reviewed = '评审了';
$lang->action->label->moved = '移动了';
$lang->action->label->confirmed = '确认了需求,';
$lang->action->label->bugconfirmed = '确认了';
$lang->action->label->tostory = '转需求';
$lang->action->label->frombug = '转需求';
$lang->action->label->totask = '转任务';
$lang->action->label->svncommited = '提交代码';
$lang->action->label->linked2plan = '关联计划';
$lang->action->label->unlinkedfromplan = '移除计划';
$lang->action->label->linked2project = '关联项目';
$lang->action->label->unlinkedfromproject = '移除项目';
$lang->action->label->marked = '编辑了';
$lang->action->label->started = '开始了';
$lang->action->label->canceled = '取消了';
$lang->action->label->finished = '完成了';
$lang->action->label->login = '登录系统';
$lang->action->label->logout = "退出登录";
/* 用来生成相应对象的链接。*/
$lang->action->label->product = '产品|product|view|productID=%s';
$lang->action->label->productplan = '计划|productplan|view|productID=%s';
$lang->action->label->release = '发布|release|view|productID=%s';
$lang->action->label->story = '需求|story|view|storyID=%s';
$lang->action->label->project = '项目|project|view|projectID=%s';
$lang->action->label->task = '任务|task|view|taskID=%s';
$lang->action->label->build = 'Build|build|view|buildID=%s';
$lang->action->label->bug = 'Bug|bug|view|bugID=%s';
$lang->action->label->case = '用例|testcase|view|caseID=%s';
$lang->action->label->testtask = '测试任务|testtask|view|caseID=%s';
$lang->action->label->todo = 'todo|todo|view|todoID=%s';
$lang->action->label->doclib = '文档库|doc|browse|libID=%s';
$lang->action->label->doc = '文档|doc|view|docID=%s';
$lang->action->label->user = '用户';
$lang->action->label->space = ' ';
/* Object type. */
$lang->action->search->objectTypeList[''] = '';
$lang->action->search->objectTypeList['product'] = '产品';
$lang->action->search->objectTypeList['project'] = '项目';
$lang->action->search->objectTypeList['bug'] = 'Bug';
$lang->action->search->objectTypeList['case'] = '用例';
$lang->action->search->objectTypeList['story'] = '需求';
$lang->action->search->objectTypeList['task'] = '任务';
$lang->action->search->objectTypeList['testtask'] = '测试任务';
$lang->action->search->objectTypeList['user'] = '用户';
$lang->action->search->objectTypeList['doc'] = '文档';
$lang->action->search->objectTypeList['doclib'] = '文档库';
$lang->action->search->objectTypeList['todo'] = 'TODO';
$lang->action->search->objectTypeList['build'] = 'Build';
$lang->action->search->objectTypeList['release'] = '发布';
$lang->action->search->objectTypeList['productplan'] = '计划';
/* 用来在动态显示中显示动作 */
$lang->action->search->label[''] = '';
$lang->action->search->label['created'] = $lang->action->label->created;
$lang->action->search->label['opened'] = $lang->action->label->opened;
$lang->action->search->label['changed'] = $lang->action->label->changed;
$lang->action->search->label['edited'] = $lang->action->label->edited;
$lang->action->search->label['assigned'] = $lang->action->label->assigned;
$lang->action->search->label['closed'] = $lang->action->label->closed;
$lang->action->search->label['deleted'] = $lang->action->label->deleted;
$lang->action->search->label['deletedfile'] = $lang->action->label->deletedfile;
$lang->action->search->label['editfile'] = $lang->action->label->editfile;
$lang->action->search->label['erased'] = $lang->action->label->erased;
$lang->action->search->label['undeleted'] = $lang->action->label->undeleted;
$lang->action->search->label['commented'] = $lang->action->label->commented;
$lang->action->search->label['activated'] = $lang->action->label->activated;
$lang->action->search->label['resolved'] = $lang->action->label->resolved;
$lang->action->search->label['reviewed'] = $lang->action->label->reviewed;
$lang->action->search->label['moved'] = $lang->action->label->moved;
$lang->action->search->label['confirmed'] = $lang->action->label->confirmed;
$lang->action->search->label['bugconfirmed'] = $lang->action->label->bugconfirmed;
$lang->action->search->label['tostory'] = $lang->action->label->tostory;
$lang->action->search->label['frombug'] = $lang->action->label->frombug;
$lang->action->search->label['totask'] = $lang->action->label->totask;
$lang->action->search->label['svncommited'] = $lang->action->label->svncommited;
$lang->action->search->label['linked2plan'] = $lang->action->label->linked2plan;
$lang->action->search->label['unlinkedfromplan'] = $lang->action->label->unlinkedfromplan;
$lang->action->search->label['linked2project'] = $lang->action->label->linked2project;
$lang->action->search->label['unlinkedfromproject'] = $lang->action->label->unlinkedfromproject;
$lang->action->search->label['marked'] = $lang->action->label->marked;
$lang->action->search->label['started'] = $lang->action->label->started;
$lang->action->search->label['canceled'] = $lang->action->label->canceled;
$lang->action->search->label['finished'] = $lang->action->label->finished;
$lang->action->search->label['login'] = $lang->action->label->login;
$lang->action->search->label['logout'] = $lang->action->label->logout;

View File

@@ -1,181 +1,181 @@
<?php
/**
* The action module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id: zh-tw.php 2528 2012-01-04 00:33:25Z wwccss $
* @link http://www.zentao.net
*/
$lang->action->common = '系統日誌';
$lang->action->trash = '資源回收筒';
$lang->action->undelete = '還原';
$lang->action->product = '產品';
$lang->action->project = '項目';
$lang->action->objectType = '對象類型';
$lang->action->objectID = '對象ID';
$lang->action->objectName = '對象名稱';
$lang->action->actor = '操作者';
$lang->action->action = '動作';
$lang->action->actionID = '記錄ID';
$lang->action->date = '日期';
$lang->action->trashTips = '提示:為了保證系統的完整性,禪道系統的刪除都是標記刪除。';
$lang->action->dynamic->today = '今天';
$lang->action->dynamic->yesterday = '昨天';
$lang->action->dynamic->twoDaysAgo = '前天';
$lang->action->dynamic->thisWeek = '本週';
$lang->action->dynamic->lastWeek = '上周';
$lang->action->dynamic->thisMonth = '本月';
$lang->action->dynamic->lastMonth = '上月';
$lang->action->dynamic->all = '所有';
$lang->action->dynamic->search = '搜索';
$lang->action->objectTypes['product'] = '產品';
$lang->action->objectTypes['story'] = '需求';
$lang->action->objectTypes['productplan'] = '產品計劃';
$lang->action->objectTypes['release'] = '發佈';
$lang->action->objectTypes['project'] = '項目';
$lang->action->objectTypes['task'] = '任務';
$lang->action->objectTypes['build'] = 'Build';
$lang->action->objectTypes['bug'] = 'Bug';
$lang->action->objectTypes['case'] = '用例';
$lang->action->objectTypes['testtask'] = '測試任務';
$lang->action->objectTypes['user'] = '用戶';
$lang->action->objectTypes['doc'] = '文檔';
$lang->action->objectTypes['doclib'] = '文檔庫';
$lang->action->objectTypes['todo'] = 'TODO';
/* 用來描述操作歷史記錄。*/
$lang->action->desc->common = '$date, <strong>$action</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->extra = '$date, <strong>$action</strong> as <strong>$extra</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->opened = '$date, 由 <strong>$actor</strong> 創建。' . "\n";
$lang->action->desc->created = '$date, 由 <strong>$actor</strong> 創建。' . "\n";
$lang->action->desc->changed = '$date, 由 <strong>$actor</strong> 變更。' . "\n";
$lang->action->desc->edited = '$date, 由 <strong>$actor</strong> 編輯。' . "\n";
$lang->action->desc->assigned = '$date, 由 <strong>$actor</strong> 指派給 <strong>$extra</strong>' . "\n";
$lang->action->desc->closed = '$date, 由 <strong>$actor</strong> 關閉。' . "\n";
$lang->action->desc->deleted = '$date, 由 <strong>$actor</strong> 刪除。' . "\n";
$lang->action->desc->deletedfile = '$date, 由 <strong>$actor</strong> 刪除了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->editfile = '$date, 由 <strong>$actor</strong> 編輯了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->erased = '$date, 由 <strong>$actor</strong> 刪除。' . "\n";
$lang->action->desc->undeleted = '$date, 由 <strong>$actor</strong> 還原。' . "\n";
$lang->action->desc->commented = '$date, 由 <strong>$actor</strong> 添加備註。' . "\n";
$lang->action->desc->activated = '$date, 由 <strong>$actor</strong> 激活。' . "\n";
$lang->action->desc->moved = '$date, 由 <strong>$actor</strong> 移動,之前為 "$extra"' . "\n";
$lang->action->desc->confirmed = '$date, 由 <strong>$actor</strong> 確認需求變動,最新版本為<strong>#$extra</strong>' . "\n";
$lang->action->desc->bugconfirmed = '$date, 由 <strong>$actor</strong> 確認Bug' . "\n";
$lang->action->desc->frombug = '$date, 由 <strong>$actor</strong> Bug轉化而來Bug編號為 <strong>$extra</strong>。';
$lang->action->desc->started = '$date, 由 <strong>$actor</strong> 啟動。' . "\n";
$lang->action->desc->canceled = '$date, 由 <strong>$actor</strong> 取消。' . "\n";
$lang->action->desc->svncommited = '$date, 由 <strong>$actor</strong> 提交代碼,版本為<strong>#$extra</strong>' . "\n";
$lang->action->desc->finished = '$date, 由 <strong>$actor</strong> 完成。' . "\n";
$lang->action->desc->diff1 = '修改了 <strong><i>%s</i></strong>,舊值為 "%s",新值為 "%s"。<br />' . "\n";
$lang->action->desc->diff2 = '修改了 <strong><i>%s</i></strong>,區別為:' . "\n" . '<blockquote>%s</blockquote>' . "\n";
$lang->action->desc->diff3 = '將檔案名 %s 改為 %s ' . "\n";
/* 用來顯示動態信息。*/
$lang->action->label->created = '創建了';
$lang->action->label->opened = '創建了';
$lang->action->label->changed = '變更了';
$lang->action->label->edited = '編輯了';
$lang->action->label->assigned = '指派了';
$lang->action->label->closed = '關閉了';
$lang->action->label->deleted = '刪除了';
$lang->action->label->deletedfile = '刪除附件';
$lang->action->label->editfile = '編輯附件';
$lang->action->label->erased = '刪除了';
$lang->action->label->undeleted = '還原了';
$lang->action->label->commented = '評論了';
$lang->action->label->activated = '激活了';
$lang->action->label->resolved = '解決了';
$lang->action->label->reviewed = '評審了';
$lang->action->label->moved = '移動了';
$lang->action->label->confirmed = '確認了需求,';
$lang->action->label->bugconfirmed = '確認了';
$lang->action->label->tostory = '轉需求';
$lang->action->label->frombug = '轉需求';
$lang->action->label->totask = '轉任務';
$lang->action->label->svncommited = '提交代碼';
$lang->action->label->linked2plan = '關聯計劃';
$lang->action->label->unlinkedfromplan = '移除計劃';
$lang->action->label->linked2project = '關聯項目';
$lang->action->label->unlinkedfromproject = '移除項目';
$lang->action->label->marked = '編輯了';
$lang->action->label->started = '開始了';
$lang->action->label->canceled = '取消了';
$lang->action->label->finished = '完成了';
$lang->action->label->login = '登錄系統';
$lang->action->label->logout = "退出登錄";
/* 用來生成相應對象的連結。*/
$lang->action->label->product = '產品|product|view|productID=%s';
$lang->action->label->productplan = '計劃|productplan|view|productID=%s';
$lang->action->label->release = '發佈|release|view|productID=%s';
$lang->action->label->story = '需求|story|view|storyID=%s';
$lang->action->label->project = '項目|project|view|projectID=%s';
$lang->action->label->task = '任務|task|view|taskID=%s';
$lang->action->label->build = 'Build|build|view|buildID=%s';
$lang->action->label->bug = 'Bug|bug|view|bugID=%s';
$lang->action->label->case = '用例|testcase|view|caseID=%s';
$lang->action->label->testtask = '測試任務|testtask|view|caseID=%s';
$lang->action->label->todo = 'todo|todo|view|todoID=%s';
$lang->action->label->doclib = '文檔庫|doc|browse|libID=%s';
$lang->action->label->doc = '文檔|doc|view|docID=%s';
$lang->action->label->user = '用戶';
$lang->action->label->space = ' ';
/* Object type. */
$lang->action->search->objectTypeList[''] = '';
$lang->action->search->objectTypeList['product'] = '產品';
$lang->action->search->objectTypeList['project'] = '項目';
$lang->action->search->objectTypeList['bug'] = 'Bug';
$lang->action->search->objectTypeList['case'] = '用例';
$lang->action->search->objectTypeList['story'] = '需求';
$lang->action->search->objectTypeList['task'] = '任務';
$lang->action->search->objectTypeList['testtask'] = '測試任務';
$lang->action->search->objectTypeList['user'] = '用戶';
$lang->action->search->objectTypeList['doc'] = '文檔';
$lang->action->search->objectTypeList['doclib'] = '文檔庫';
$lang->action->search->objectTypeList['todo'] = 'TODO';
$lang->action->search->objectTypeList['build'] = 'Build';
$lang->action->search->objectTypeList['release'] = '發佈';
$lang->action->search->objectTypeList['productplan'] = '計劃';
/* 用來在動態顯示中顯示動作 */
$lang->action->search->label[''] = '';
$lang->action->search->label['created'] = $lang->action->label->created;
$lang->action->search->label['opened'] = $lang->action->label->opened;
$lang->action->search->label['changed'] = $lang->action->label->changed;
$lang->action->search->label['edited'] = $lang->action->label->edited;
$lang->action->search->label['assigned'] = $lang->action->label->assigned;
$lang->action->search->label['closed'] = $lang->action->label->closed;
$lang->action->search->label['deleted'] = $lang->action->label->deleted;
$lang->action->search->label['deletedfile'] = $lang->action->label->deletedfile;
$lang->action->search->label['editfile'] = $lang->action->label->editfile;
$lang->action->search->label['erased'] = $lang->action->label->erased;
$lang->action->search->label['undeleted'] = $lang->action->label->undeleted;
$lang->action->search->label['commented'] = $lang->action->label->commented;
$lang->action->search->label['activated'] = $lang->action->label->activated;
$lang->action->search->label['resolved'] = $lang->action->label->resolved;
$lang->action->search->label['reviewed'] = $lang->action->label->reviewed;
$lang->action->search->label['moved'] = $lang->action->label->moved;
$lang->action->search->label['confirmed'] = $lang->action->label->confirmed;
$lang->action->search->label['bugconfirmed'] = $lang->action->label->bugconfirmed;
$lang->action->search->label['tostory'] = $lang->action->label->tostory;
$lang->action->search->label['frombug'] = $lang->action->label->frombug;
$lang->action->search->label['totask'] = $lang->action->label->totask;
$lang->action->search->label['svncommited'] = $lang->action->label->svncommited;
$lang->action->search->label['linked2plan'] = $lang->action->label->linked2plan;
$lang->action->search->label['unlinkedfromplan'] = $lang->action->label->unlinkedfromplan;
$lang->action->search->label['linked2project'] = $lang->action->label->linked2project;
$lang->action->search->label['unlinkedfromproject'] = $lang->action->label->unlinkedfromproject;
$lang->action->search->label['marked'] = $lang->action->label->marked;
$lang->action->search->label['started'] = $lang->action->label->started;
$lang->action->search->label['canceled'] = $lang->action->label->canceled;
$lang->action->search->label['finished'] = $lang->action->label->finished;
$lang->action->search->label['login'] = $lang->action->label->login;
$lang->action->search->label['logout'] = $lang->action->label->logout;
<?php
/**
* The action module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id: zh-tw.php 2528 2012-01-04 00:33:25Z wwccss $
* @link http://www.zentao.net
*/
$lang->action->common = '系統日誌';
$lang->action->trash = '資源回收筒';
$lang->action->undelete = '還原';
$lang->action->product = '產品';
$lang->action->project = '項目';
$lang->action->objectType = '對象類型';
$lang->action->objectID = '對象ID';
$lang->action->objectName = '對象名稱';
$lang->action->actor = '操作者';
$lang->action->action = '動作';
$lang->action->actionID = '記錄ID';
$lang->action->date = '日期';
$lang->action->trashTips = '提示:為了保證系統的完整性,禪道系統的刪除都是標記刪除。';
$lang->action->dynamic->today = '今天';
$lang->action->dynamic->yesterday = '昨天';
$lang->action->dynamic->twoDaysAgo = '前天';
$lang->action->dynamic->thisWeek = '本週';
$lang->action->dynamic->lastWeek = '上周';
$lang->action->dynamic->thisMonth = '本月';
$lang->action->dynamic->lastMonth = '上月';
$lang->action->dynamic->all = '所有';
$lang->action->dynamic->search = '搜索';
$lang->action->objectTypes['product'] = '產品';
$lang->action->objectTypes['story'] = '需求';
$lang->action->objectTypes['productplan'] = '產品計劃';
$lang->action->objectTypes['release'] = '發佈';
$lang->action->objectTypes['project'] = '項目';
$lang->action->objectTypes['task'] = '任務';
$lang->action->objectTypes['build'] = 'Build';
$lang->action->objectTypes['bug'] = 'Bug';
$lang->action->objectTypes['case'] = '用例';
$lang->action->objectTypes['testtask'] = '測試任務';
$lang->action->objectTypes['user'] = '用戶';
$lang->action->objectTypes['doc'] = '文檔';
$lang->action->objectTypes['doclib'] = '文檔庫';
$lang->action->objectTypes['todo'] = 'TODO';
/* 用來描述操作歷史記錄。*/
$lang->action->desc->common = '$date, <strong>$action</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->extra = '$date, <strong>$action</strong> as <strong>$extra</strong> by <strong>$actor</strong>' . "\n";
$lang->action->desc->opened = '$date, 由 <strong>$actor</strong> 創建。' . "\n";
$lang->action->desc->created = '$date, 由 <strong>$actor</strong> 創建。' . "\n";
$lang->action->desc->changed = '$date, 由 <strong>$actor</strong> 變更。' . "\n";
$lang->action->desc->edited = '$date, 由 <strong>$actor</strong> 編輯。' . "\n";
$lang->action->desc->assigned = '$date, 由 <strong>$actor</strong> 指派給 <strong>$extra</strong>' . "\n";
$lang->action->desc->closed = '$date, 由 <strong>$actor</strong> 關閉。' . "\n";
$lang->action->desc->deleted = '$date, 由 <strong>$actor</strong> 刪除。' . "\n";
$lang->action->desc->deletedfile = '$date, 由 <strong>$actor</strong> 刪除了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->editfile = '$date, 由 <strong>$actor</strong> 編輯了附件:<strong><i>$extra</i></strong>' . "\n";
$lang->action->desc->erased = '$date, 由 <strong>$actor</strong> 刪除。' . "\n";
$lang->action->desc->undeleted = '$date, 由 <strong>$actor</strong> 還原。' . "\n";
$lang->action->desc->commented = '$date, 由 <strong>$actor</strong> 添加備註。' . "\n";
$lang->action->desc->activated = '$date, 由 <strong>$actor</strong> 激活。' . "\n";
$lang->action->desc->moved = '$date, 由 <strong>$actor</strong> 移動,之前為 "$extra"' . "\n";
$lang->action->desc->confirmed = '$date, 由 <strong>$actor</strong> 確認需求變動,最新版本為<strong>#$extra</strong>' . "\n";
$lang->action->desc->bugconfirmed = '$date, 由 <strong>$actor</strong> 確認Bug' . "\n";
$lang->action->desc->frombug = '$date, 由 <strong>$actor</strong> Bug轉化而來Bug編號為 <strong>$extra</strong>。';
$lang->action->desc->started = '$date, 由 <strong>$actor</strong> 啟動。' . "\n";
$lang->action->desc->canceled = '$date, 由 <strong>$actor</strong> 取消。' . "\n";
$lang->action->desc->svncommited = '$date, 由 <strong>$actor</strong> 提交代碼,版本為<strong>#$extra</strong>' . "\n";
$lang->action->desc->finished = '$date, 由 <strong>$actor</strong> 完成。' . "\n";
$lang->action->desc->diff1 = '修改了 <strong><i>%s</i></strong>,舊值為 "%s",新值為 "%s"。<br />' . "\n";
$lang->action->desc->diff2 = '修改了 <strong><i>%s</i></strong>,區別為:' . "\n" . '<blockquote>%s</blockquote>' . "\n";
$lang->action->desc->diff3 = '將檔案名 %s 改為 %s ' . "\n";
/* 用來顯示動態信息。*/
$lang->action->label->created = '創建了';
$lang->action->label->opened = '創建了';
$lang->action->label->changed = '變更了';
$lang->action->label->edited = '編輯了';
$lang->action->label->assigned = '指派了';
$lang->action->label->closed = '關閉了';
$lang->action->label->deleted = '刪除了';
$lang->action->label->deletedfile = '刪除附件';
$lang->action->label->editfile = '編輯附件';
$lang->action->label->erased = '刪除了';
$lang->action->label->undeleted = '還原了';
$lang->action->label->commented = '評論了';
$lang->action->label->activated = '激活了';
$lang->action->label->resolved = '解決了';
$lang->action->label->reviewed = '評審了';
$lang->action->label->moved = '移動了';
$lang->action->label->confirmed = '確認了需求,';
$lang->action->label->bugconfirmed = '確認了';
$lang->action->label->tostory = '轉需求';
$lang->action->label->frombug = '轉需求';
$lang->action->label->totask = '轉任務';
$lang->action->label->svncommited = '提交代碼';
$lang->action->label->linked2plan = '關聯計劃';
$lang->action->label->unlinkedfromplan = '移除計劃';
$lang->action->label->linked2project = '關聯項目';
$lang->action->label->unlinkedfromproject = '移除項目';
$lang->action->label->marked = '編輯了';
$lang->action->label->started = '開始了';
$lang->action->label->canceled = '取消了';
$lang->action->label->finished = '完成了';
$lang->action->label->login = '登錄系統';
$lang->action->label->logout = "退出登錄";
/* 用來生成相應對象的連結。*/
$lang->action->label->product = '產品|product|view|productID=%s';
$lang->action->label->productplan = '計劃|productplan|view|productID=%s';
$lang->action->label->release = '發佈|release|view|productID=%s';
$lang->action->label->story = '需求|story|view|storyID=%s';
$lang->action->label->project = '項目|project|view|projectID=%s';
$lang->action->label->task = '任務|task|view|taskID=%s';
$lang->action->label->build = 'Build|build|view|buildID=%s';
$lang->action->label->bug = 'Bug|bug|view|bugID=%s';
$lang->action->label->case = '用例|testcase|view|caseID=%s';
$lang->action->label->testtask = '測試任務|testtask|view|caseID=%s';
$lang->action->label->todo = 'todo|todo|view|todoID=%s';
$lang->action->label->doclib = '文檔庫|doc|browse|libID=%s';
$lang->action->label->doc = '文檔|doc|view|docID=%s';
$lang->action->label->user = '用戶';
$lang->action->label->space = ' ';
/* Object type. */
$lang->action->search->objectTypeList[''] = '';
$lang->action->search->objectTypeList['product'] = '產品';
$lang->action->search->objectTypeList['project'] = '項目';
$lang->action->search->objectTypeList['bug'] = 'Bug';
$lang->action->search->objectTypeList['case'] = '用例';
$lang->action->search->objectTypeList['story'] = '需求';
$lang->action->search->objectTypeList['task'] = '任務';
$lang->action->search->objectTypeList['testtask'] = '測試任務';
$lang->action->search->objectTypeList['user'] = '用戶';
$lang->action->search->objectTypeList['doc'] = '文檔';
$lang->action->search->objectTypeList['doclib'] = '文檔庫';
$lang->action->search->objectTypeList['todo'] = 'TODO';
$lang->action->search->objectTypeList['build'] = 'Build';
$lang->action->search->objectTypeList['release'] = '發佈';
$lang->action->search->objectTypeList['productplan'] = '計劃';
/* 用來在動態顯示中顯示動作 */
$lang->action->search->label[''] = '';
$lang->action->search->label['created'] = $lang->action->label->created;
$lang->action->search->label['opened'] = $lang->action->label->opened;
$lang->action->search->label['changed'] = $lang->action->label->changed;
$lang->action->search->label['edited'] = $lang->action->label->edited;
$lang->action->search->label['assigned'] = $lang->action->label->assigned;
$lang->action->search->label['closed'] = $lang->action->label->closed;
$lang->action->search->label['deleted'] = $lang->action->label->deleted;
$lang->action->search->label['deletedfile'] = $lang->action->label->deletedfile;
$lang->action->search->label['editfile'] = $lang->action->label->editfile;
$lang->action->search->label['erased'] = $lang->action->label->erased;
$lang->action->search->label['undeleted'] = $lang->action->label->undeleted;
$lang->action->search->label['commented'] = $lang->action->label->commented;
$lang->action->search->label['activated'] = $lang->action->label->activated;
$lang->action->search->label['resolved'] = $lang->action->label->resolved;
$lang->action->search->label['reviewed'] = $lang->action->label->reviewed;
$lang->action->search->label['moved'] = $lang->action->label->moved;
$lang->action->search->label['confirmed'] = $lang->action->label->confirmed;
$lang->action->search->label['bugconfirmed'] = $lang->action->label->bugconfirmed;
$lang->action->search->label['tostory'] = $lang->action->label->tostory;
$lang->action->search->label['frombug'] = $lang->action->label->frombug;
$lang->action->search->label['totask'] = $lang->action->label->totask;
$lang->action->search->label['svncommited'] = $lang->action->label->svncommited;
$lang->action->search->label['linked2plan'] = $lang->action->label->linked2plan;
$lang->action->search->label['unlinkedfromplan'] = $lang->action->label->unlinkedfromplan;
$lang->action->search->label['linked2project'] = $lang->action->label->linked2project;
$lang->action->search->label['unlinkedfromproject'] = $lang->action->label->unlinkedfromproject;
$lang->action->search->label['marked'] = $lang->action->label->marked;
$lang->action->search->label['started'] = $lang->action->label->started;
$lang->action->search->label['canceled'] = $lang->action->label->canceled;
$lang->action->search->label['finished'] = $lang->action->label->finished;
$lang->action->search->label['login'] = $lang->action->label->login;
$lang->action->search->label['logout'] = $lang->action->label->logout;

File diff suppressed because it is too large Load Diff

View File

@@ -1,49 +1,49 @@
<?php
/**
* The trash view file of action module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<table class='table-1 colored tablesorter'>
<?php $vars = "orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<thead>
<tr class='colhead'>
<th class='w-80px'><?php common::printOrderLink('objectType', $orderBy, $vars, $lang->action->objectType);?></th>
<th class='w-id'> <?php common::printOrderLink('objectID', $orderBy, $vars, $lang->idAB);?></th>
<th><?php echo $lang->action->objectName;?></th>
<th class='w-100px'><?php common::printOrderLink('actor', $orderBy, $vars, $lang->action->actor);?></th>
<th class='w-150px'><?php common::printOrderLink('date', $orderBy, $vars, $lang->action->date);?></th>
<th class='w-80px'><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($trashes as $action):?>
<?php $module = $action->objectType == 'case' ? 'testcase' : $action->objectType;?>
<tr class='a-center'>
<td><?php echo $lang->action->objectTypes[$action->objectType];?></td>
<td><?php echo $action->objectID;?></td>
<td class='a-left'><?php echo html::a($this->createLink($module, 'view', "id=$action->objectID"), $action->objectName);?></td>
<td><?php echo $users[$action->actor];?></td>
<td><?php echo $action->date;?></td>
<td><?php common::printLink('action', 'undelete', "actionid=$action->id", $lang->action->undelete, 'hiddenwin');?>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='6'>
<div class='f-left'><?php echo $lang->action->trashTips;?></div>
<div><?php $pager->show();?></div>
</td>
</tr>
</tfoot>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The trash view file of action module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package action
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<table class='table-1 colored tablesorter'>
<?php $vars = "orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<thead>
<tr class='colhead'>
<th class='w-80px'><?php common::printOrderLink('objectType', $orderBy, $vars, $lang->action->objectType);?></th>
<th class='w-id'> <?php common::printOrderLink('objectID', $orderBy, $vars, $lang->idAB);?></th>
<th><?php echo $lang->action->objectName;?></th>
<th class='w-100px'><?php common::printOrderLink('actor', $orderBy, $vars, $lang->action->actor);?></th>
<th class='w-150px'><?php common::printOrderLink('date', $orderBy, $vars, $lang->action->date);?></th>
<th class='w-80px'><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($trashes as $action):?>
<?php $module = $action->objectType == 'case' ? 'testcase' : $action->objectType;?>
<tr class='a-center'>
<td><?php echo $lang->action->objectTypes[$action->objectType];?></td>
<td><?php echo $action->objectID;?></td>
<td class='a-left'><?php echo html::a($this->createLink($module, 'view', "id=$action->objectID"), $action->objectName);?></td>
<td><?php echo $users[$action->actor];?></td>
<td><?php echo $action->date;?></td>
<td><?php common::printLink('action', 'undelete', "actionid=$action->id", $lang->action->undelete, 'hiddenwin');?>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='6'>
<div class='f-left'><?php echo $lang->action->trashTips;?></div>
<div><?php $pager->show();?></div>
</td>
</tr>
</tfoot>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,24 +1,24 @@
<?php
/**
* The control file of admin module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
class admin extends control
{
/**
* Index page of admin module. Locate to action's trash page.
*
* @access public
* @return void
*/
public function index()
{
$this->locate($this->createLink('extension', 'browse'));
}
}
<?php
/**
* The control file of admin module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
class admin extends control
{
/**
* Index page of admin module. Locate to action's trash page.
*
* @access public
* @return void
*/
public function index()
{
$this->locate($this->createLink('extension', 'browse'));
}
}

View File

@@ -1,19 +1,19 @@
<?php
/**
* The admin module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
$lang->admin->common = 'Admin';
$lang->admin->index = 'Index';
$lang->admin->company = 'Company';
$lang->admin->user = 'User';
$lang->admin->group = 'Group';
$lang->admin->welcome = 'Welcome to ZenTaoPMS.';
$lang->admin->browseCompany = 'Browse Company';
<?php
/**
* The admin module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
$lang->admin->common = 'Admin';
$lang->admin->index = 'Index';
$lang->admin->company = 'Company';
$lang->admin->user = 'User';
$lang->admin->group = 'Group';
$lang->admin->welcome = 'Welcome to ZenTaoPMS.';
$lang->admin->browseCompany = 'Browse Company';

View File

@@ -1,19 +1,19 @@
<?php
/**
* The admin module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
$lang->admin->common = '后台管理';
$lang->admin->index = '后台管理首页';
$lang->admin->company = '公司管理';
$lang->admin->user = '用户管理';
$lang->admin->group = '分组管理';
$lang->admin->welcome = '欢迎使用禅道管理软件后台管理系统';
$lang->admin->browseCompany = '浏览公司';
<?php
/**
* The admin module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
$lang->admin->common = '后台管理';
$lang->admin->index = '后台管理首页';
$lang->admin->company = '公司管理';
$lang->admin->user = '用户管理';
$lang->admin->group = '分组管理';
$lang->admin->welcome = '欢迎使用禅道管理软件后台管理系统';
$lang->admin->browseCompany = '浏览公司';

View File

@@ -1,19 +1,19 @@
<?php
/**
* The admin module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->admin->common = '後台管理';
$lang->admin->index = '後台管理首頁';
$lang->admin->company = '公司管理';
$lang->admin->user = '用戶管理';
$lang->admin->group = '分組管理';
$lang->admin->welcome = '歡迎使用禪道管理軟件後台管理系統';
$lang->admin->browseCompany = '瀏覽公司';
<?php
/**
* The admin module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->admin->common = '後台管理';
$lang->admin->index = '後台管理首頁';
$lang->admin->company = '公司管理';
$lang->admin->user = '用戶管理';
$lang->admin->group = '分組管理';
$lang->admin->welcome = '歡迎使用禪道管理軟件後台管理系統';
$lang->admin->browseCompany = '瀏覽公司';

View File

@@ -1,48 +1,48 @@
<?php
/**
* The model file of admin module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class adminModel extends model
{
/**
* Get status of zentaopms.
*
* @access public
* @return void
*/
public function getStatOfPMS()
{
$sql = "SHOW TABLE STATUS";
$tables = $this->dbh->query($sql)->fetchALL();
}
/**
* Get state of company.
*
* @param int $companyID
* @access public
* @return void
*/
public function getStatOfCompany($companyID)
{
}
/**
* Get system info.
*
* @access public
* @return void
*/
public function getStatOfSys()
{
}
}
<?php
/**
* The model file of admin module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class adminModel extends model
{
/**
* Get status of zentaopms.
*
* @access public
* @return void
*/
public function getStatOfPMS()
{
$sql = "SHOW TABLE STATUS";
$tables = $this->dbh->query($sql)->fetchALL();
}
/**
* Get state of company.
*
* @param int $companyID
* @access public
* @return void
*/
public function getStatOfCompany($companyID)
{
}
/**
* Get system info.
*
* @access public
* @return void
*/
public function getStatOfSys()
{
}
}

View File

@@ -1,47 +1,47 @@
<?php
/**
* The browse company view file of admin module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<table align='center' class='table-1'>
<tr class='colhead'>
<th><?php echo $lang->company->id;?></th>
<th><?php echo $lang->company->name;?></th>
<th><?php echo $lang->company->phone;?></th>
<th><?php echo $lang->company->fax;?></th>
<th><?php echo $lang->company->address;?></th>
<th><?php echo $lang->company->zipcode;?></th>
<th><?php echo $lang->company->website;?></th>
<th><?php echo $lang->company->backyard;?></th>
<th><?php echo $lang->company->pms;?></th>
<th><?php echo $lang->company->guest;?></th>
<th><?php echo $lang->actions;?></th>
</tr>
<?php foreach($companies as $company):?>
<tr>
<td class='a-center'><?php echo $company->id;?></td>
<td><?php echo $company->name;?></td>
<td><?php echo $company->phone;?></td>
<td><?php echo $company->fax;?></td>
<td><?php echo $company->address;?></td>
<td><?php echo $company->zipcode;?></td>
<td><?php echo html::a($company->website, $company->website, '_blank');?></td>
<td><?php echo html::a($company->backyard,$company->backyard, '_blank');?></td>
<td><?php echo html::a('http://' . $company->pms, $company->pms, '_blank');?></td>
<td><?php echo $lang->company->guestList[(int)$company->guest];?></td>
<td>
<?php echo html::a($this->createLink('company', 'edit', "companyID=$company->id"), $this->lang->company->edit);?>
<?php echo html::a($this->createLink('company', 'delete', "companyID=$company->id"), $this->lang->company->delete, "hiddenwin");?>
</td>
</tr>
<?php endforeach;?>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The browse company view file of admin module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package admin
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<table align='center' class='table-1'>
<tr class='colhead'>
<th><?php echo $lang->company->id;?></th>
<th><?php echo $lang->company->name;?></th>
<th><?php echo $lang->company->phone;?></th>
<th><?php echo $lang->company->fax;?></th>
<th><?php echo $lang->company->address;?></th>
<th><?php echo $lang->company->zipcode;?></th>
<th><?php echo $lang->company->website;?></th>
<th><?php echo $lang->company->backyard;?></th>
<th><?php echo $lang->company->pms;?></th>
<th><?php echo $lang->company->guest;?></th>
<th><?php echo $lang->actions;?></th>
</tr>
<?php foreach($companies as $company):?>
<tr>
<td class='a-center'><?php echo $company->id;?></td>
<td><?php echo $company->name;?></td>
<td><?php echo $company->phone;?></td>
<td><?php echo $company->fax;?></td>
<td><?php echo $company->address;?></td>
<td><?php echo $company->zipcode;?></td>
<td><?php echo html::a($company->website, $company->website, '_blank');?></td>
<td><?php echo html::a($company->backyard,$company->backyard, '_blank');?></td>
<td><?php echo html::a('http://' . $company->pms, $company->pms, '_blank');?></td>
<td><?php echo $lang->company->guestList[(int)$company->guest];?></td>
<td>
<?php echo html::a($this->createLink('company', 'edit', "companyID=$company->id"), $this->lang->company->edit);?>
<?php echo html::a($this->createLink('company', 'delete', "companyID=$company->id"), $this->lang->company->delete, "hiddenwin");?>
</td>
</tr>
<?php endforeach;?>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,50 +1,50 @@
<?php
/**
* The control file of api of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id$
* @link http://www.zentao.net
*/
class api extends control
{
/**
* Return session to the client.
*
* @access public
* @return void
*/
public function getSessionID()
{
$this->session->set('rand', mt_rand(0, 10000));
$this->view->sessionName = session_name();
$this->view->sessionID = session_id();
$this->view->rand = $this->session->rand;
$this->display();
}
/**
* Execute a module's model's method, return the result.
*
* @param string $moduleName
* @param string $methodName
* @param string $params param1=value1,param2=value2, don't use & to join them.
* @access public
* @return string
*/
public function getModel($moduleName, $methodName, $params = '')
{
parse_str(str_replace(',', '&', $params), $params);
$module = $this->loadModel($moduleName);
$result = call_user_func_array(array(&$module, $methodName), $params);
if(dao::isError()) die(json_encode(dao::getError()));
$output['status'] = $result ? 'success' : 'fail';
$output['data'] = json_encode($result);
$output['md5'] = md5($output['data']);
$this->output = json_encode($output);
die($this->output);
}
}
<?php
/**
* The control file of api of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id$
* @link http://www.zentao.net
*/
class api extends control
{
/**
* Return session to the client.
*
* @access public
* @return void
*/
public function getSessionID()
{
$this->session->set('rand', mt_rand(0, 10000));
$this->view->sessionName = session_name();
$this->view->sessionID = session_id();
$this->view->rand = $this->session->rand;
$this->display();
}
/**
* Execute a module's model's method, return the result.
*
* @param string $moduleName
* @param string $methodName
* @param string $params param1=value1,param2=value2, don't use & to join them.
* @access public
* @return string
*/
public function getModel($moduleName, $methodName, $params = '')
{
parse_str(str_replace(',', '&', $params), $params);
$module = $this->loadModel($moduleName);
$result = call_user_func_array(array(&$module, $methodName), $params);
if(dao::isError()) die(json_encode(dao::getError()));
$output['status'] = $result ? 'success' : 'fail';
$output['data'] = json_encode($result);
$output['md5'] = md5($output['data']);
$this->output = json_encode($output);
die($this->output);
}
}

View File

@@ -1,13 +1,13 @@
<?php
/**
* The api module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id: English.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
$lang->api->common = 'API';
$lang->api->getModel = 'Super Model API';
<?php
/**
* The api module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id: English.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
$lang->api->common = 'API';
$lang->api->getModel = 'Super Model API';

View File

@@ -1,13 +1,13 @@
<?php
/**
* The api module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id$
* @link http://www.zentao.net
*/
$lang->api->common = 'API接口';
$lang->api->getModel = '超级model调用接口';
<?php
/**
* The api module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id$
* @link http://www.zentao.net
*/
$lang->api->common = 'API接口';
$lang->api->getModel = '超级model调用接口';

View File

@@ -1,13 +1,13 @@
<?php
/**
* The api module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->api->common = 'API介面';
$lang->api->getModel = '超級model調用介面';
<?php
/**
* The api module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->api->common = 'API介面';
$lang->api->getModel = '超級model調用介面';

View File

@@ -1,15 +1,15 @@
<?php
/**
* The model file of api module of ZenTaoCMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id$
* @link http://www.zentao.net
*/
class apiModel extends model
{
}
<?php
/**
* The model file of api module of ZenTaoCMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package api
* @version $Id$
* @link http://www.zentao.net
*/
class apiModel extends model
{
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,312 +1,312 @@
<?php
/**
* The bug module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
/* Fieldlist. */
$lang->bug->common = 'Bug';
$lang->bug->id = 'ID';
$lang->bug->product = 'Product';
$lang->bug->module = 'Module';
$lang->bug->path = 'Path';
$lang->bug->project = 'Project';
$lang->bug->story = 'Story';
$lang->bug->storyVersion = 'Story Version';
$lang->bug->task = 'Task';
$lang->bug->title = 'Title';
$lang->bug->severity = 'Severity';
$lang->bug->severityAB = 'S';
$lang->bug->pri = 'Priority';
$lang->bug->type = 'Type';
$lang->bug->os = 'OS';
$lang->bug->hardware = 'Hardware';
$lang->bug->browser = 'Browser';
$lang->bug->machine = 'Machine';
$lang->bug->found = 'How found';
$lang->bug->steps = 'Steps';
$lang->bug->status = 'Status';
$lang->bug->statusAB = 'Status';
$lang->bug->activatedCount = 'Activated count';
$lang->bug->activatedCountAB = 'Activated count';
$lang->bug->confirmed = 'Confirmed';
$lang->bug->toTask = 'To task';
$lang->bug->toStory = 'To story';
$lang->bug->mailto = 'Mailto';
$lang->bug->openedBy = 'Opened By';
$lang->bug->openedByAB = 'Opened';
$lang->bug->openedDate = 'Opened date';
$lang->bug->openedDateAB = 'Date';
$lang->bug->openedBuild = 'Opened Build';
$lang->bug->assignedTo = 'Assigned';
$lang->bug->assignedDate = 'Assigned Date';
$lang->bug->resolvedBy = 'Resolved By';
$lang->bug->resolvedByAB = 'Resolve';
$lang->bug->resolution = 'Resolution';
$lang->bug->resolutionAB = 'Resolution';
$lang->bug->resolvedBuild = 'Resolved Build';
$lang->bug->resolvedDate = 'Resolved Date';
$lang->bug->resolvedDateAB = 'Date';
$lang->bug->closedBy = 'Closed By';
$lang->bug->closedDate = 'Closed Date';
$lang->bug->duplicateBug = 'Duplicate';
$lang->bug->lastEditedBy = 'Last Edited By';
$lang->bug->lastEditedDate = 'Last Edited Date';
$lang->bug->linkBug = 'Related';
$lang->bug->case = 'Case';
$lang->bug->files = 'Files';
$lang->bug->keywords = 'Keywords';
$lang->bug->lastEditedByAB = 'Edited';
$lang->bug->lastEditedDateAB = 'Edited Date';
/* Actions. */
$lang->bug->index = 'Index';
$lang->bug->create = 'Create Bug';
$lang->bug->confirmBug = 'Confirm Bug';
$lang->bug->edit = 'Edit Bug';
$lang->bug->browse = 'Browse Bug';
$lang->bug->view = 'Bug Info';
$lang->bug->resolve = 'Resolve Bug';
$lang->bug->close = 'Close Bug';
$lang->bug->activate = 'Activate Bug';
$lang->bug->reportChart = 'Report';
$lang->bug->export = 'Export data';
$lang->bug->delete = 'Delete Bug';
$lang->bug->saveTemplate = 'Save template';
$lang->bug->deleteTemplate = 'Delete template';
$lang->bug->customFields = 'Custom';
$lang->bug->restoreDefault = 'Default';
$lang->bug->ajaxGetUserBugs = 'API: My Bugs';
$lang->bug->ajaxGetModuleOwner = 'API: Get module default owner';
$lang->bug->confirmStoryChange = 'Confirm Story Change';
/* Browse tabs. */
$lang->bug->selectProduct = 'Select product';
$lang->bug->byModule = 'ByModule';
$lang->bug->assignToMe = 'MyBugs';
$lang->bug->openedByMe = 'MyOpen';
$lang->bug->resolvedByMe = 'MyResolve';
$lang->bug->closedByMe = 'MyClose';
$lang->bug->assignToNull = 'Unassigned';
$lang->bug->unResolved = 'Unresolved';
$lang->bug->unclosed = 'Unclosed';
$lang->bug->longLifeBugs = 'Longlife';
$lang->bug->postponedBugs = 'Postponed';
$lang->bug->allBugs = 'Allbug';
$lang->bug->moduleBugs = 'ByModule';
$lang->bug->byQuery = 'Search';
$lang->bug->needConfirm = 'StoryChanged';
$lang->bug->allProduct = 'All products';
/* Labels. */
$lang->bug->lblProductAndModule = 'Product&Module';
$lang->bug->lblProjectAndTask = 'Project&Task';
$lang->bug->lblStory = 'Story';
$lang->bug->lblTypeAndSeverity = 'Type&Severity';
$lang->bug->lblSystemBrowserAndHardware = 'OS&Browser';
$lang->bug->lblAssignedTo = 'Assigned to';
$lang->bug->lblMailto = 'Mailto';
$lang->bug->lblLastEdited = 'Last edited';
$lang->bug->lblResolved = 'Resolved';
$lang->bug->lblAllFields = 'All Fields';
$lang->bug->lblCustomFields = 'Custom Fields';
/* Legends. */
$lang->bug->legendBasicInfo = 'Basic info';
$lang->bug->legendMailto = 'Mailto';
$lang->bug->legendAttatch = 'Files';
$lang->bug->legendLinkBugs = 'Related bug';
$lang->bug->legendPrjStoryTask = 'Project, story & task';
$lang->bug->legendCases = 'Related case';
$lang->bug->legendSteps = 'Steps';
$lang->bug->legendAction = 'Action';
$lang->bug->legendHistory = 'History';
$lang->bug->legendComment = 'Comment';
$lang->bug->legendLife = 'Lifetime';
$lang->bug->legendMisc = 'Misc';
/* Action buttons. */
$lang->bug->buttonConfirm = 'Confirm';
$lang->bug->buttonCopy = 'Copy';
$lang->bug->buttonEdit = 'Edit';
$lang->bug->buttonActivate = 'Activate';
$lang->bug->buttonResolve = 'Resolve';
$lang->bug->buttonClose = 'Close';
$lang->bug->buttonToList = 'Back';
$lang->bug->buttonCreateTestcase = 'Create case';
/* Confirm messags. */
$lang->bug->confirmChangeProduct = 'Change product will change project, task and story also, are you sure?';
$lang->bug->confirmDelete = 'Are you sure to delete this bug?';
$lang->bug->setTemplateTitle = 'Please input the template title:';
$lang->bug->remindTask = 'This bug has been to be a task, update the task:%s or not?';
/* Templates. */
$lang->bug->tplStep = "<p>[Steps]</p>";
$lang->bug->tplResult = "<p>[Result]</p>";
$lang->bug->tplExpect = "<p>[Expect]</p>";
/* Field options lists. */
$lang->bug->severityList[3] = '3';
$lang->bug->severityList[1] = '1';
$lang->bug->severityList[2] = '2';
$lang->bug->severityList[4] = '4';
$lang->bug->priList[0] = '';
$lang->bug->priList[3] = '3';
$lang->bug->priList[1] = '1';
$lang->bug->priList[2] = '2';
$lang->bug->priList[4] = '4';
$lang->bug->osList[''] = '';
$lang->bug->osList['all'] = 'All';
$lang->bug->osList['windows'] = 'Windows';
$lang->bug->osList['winxp'] = 'Windows XP';
$lang->bug->osList['win7'] = 'Windows 7';
$lang->bug->osList['vista'] = 'Windows Vista';
$lang->bug->osList['win2000'] = 'Windows 2000';
$lang->bug->osList['win2003'] = 'Windows 2003';
$lang->bug->osList['win2008'] = 'Windows 2008';
$lang->bug->osList['winnt'] = 'Windows NT';
$lang->bug->osList['win98'] = 'Windows 98';
$lang->bug->osList['andriod'] = 'Andriod';
$lang->bug->osList['ios'] = 'IOS';
$lang->bug->osList['wp7'] = 'WP7';
$lang->bug->osList['symbian'] = 'Symbian';
$lang->bug->osList['linux'] = 'Linux';
$lang->bug->osList['freebsd'] = 'FreeBSD';
$lang->bug->osList['mac'] = 'Mac OS';
$lang->bug->osList['unix'] = 'Unix';
$lang->bug->osList['others'] = 'Others';
$lang->bug->browserList[''] = '';
$lang->bug->browserList['all'] = 'All';
$lang->bug->browserList['ie'] = 'IE';
$lang->bug->browserList['ie8'] = 'IE8';
$lang->bug->browserList['ie9'] = 'IE9';
$lang->bug->browserList['ie6'] = 'IE6';
$lang->bug->browserList['ie7'] = 'IE7';
$lang->bug->browserList['chrome'] = 'chrome';
$lang->bug->browserList['firefox'] = 'Firefox';
$lang->bug->browserList['firefox2'] = 'Firefox2';
$lang->bug->browserList['firefox3'] = 'Firefox3';
$lang->bug->browserList['firefox4'] = 'Firefox4';
$lang->bug->browserList['opera'] = 'opera';
$lang->bug->browserList['opera9'] = 'opera9';
$lang->bug->browserList['oprea10'] = 'opera10';
$lang->bug->browserList['oprea11'] = 'opera11';
$lang->bug->browserList['safari'] = 'safari';
$lang->bug->browserList['maxthon'] = '傲游';
$lang->bug->browserList['uc'] = 'UC';
$lang->bug->browserList['other'] = 'Others';
$lang->bug->typeList[''] = '';
$lang->bug->typeList['codeerror'] = 'Code error';
$lang->bug->typeList['interface'] = 'Interface';
$lang->bug->typeList['designchange'] = 'Design change';
$lang->bug->typeList['newfeature'] = 'New feature';
$lang->bug->typeList['designdefect'] = 'Design defect';
$lang->bug->typeList['config'] = 'Config';
$lang->bug->typeList['install'] = 'Install';
$lang->bug->typeList['security'] = 'Security';
$lang->bug->typeList['performance'] = 'Performance';
$lang->bug->typeList['standard'] = 'Standard';
$lang->bug->typeList['automation'] = 'Automation';
$lang->bug->typeList['trackthings'] = 'Tracking';
$lang->bug->typeList['others'] = 'Others';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = 'Active';
$lang->bug->statusList['resolved'] = 'Resolved';
$lang->bug->statusList['closed'] = 'Closed';
$lang->bug->confirmedList[1] = 'Confirmed';
$lang->bug->confirmedList[0] = 'Unconfirmed';
$lang->bug->resolutionList[''] = '';
$lang->bug->resolutionList['bydesign'] = 'By design';
$lang->bug->resolutionList['duplicate'] = 'Duplicate';
$lang->bug->resolutionList['external'] = 'External';
$lang->bug->resolutionList['fixed'] = 'Fixed';
$lang->bug->resolutionList['notrepro'] = 'Not reproduce';
$lang->bug->resolutionList['postponed'] = 'Postponed';
$lang->bug->resolutionList['willnotfix'] = "Won't fix";
$lang->bug->resolutionList['tostory'] = 'To story';
/* Report. */
$lang->bug->report->common = 'Report';
$lang->bug->report->select = 'Select';
$lang->bug->report->create = 'Create';
$lang->bug->report->selectAll = 'All';
$lang->bug->report->selectReverse = 'Reverse';
$lang->bug->report->charts['bugsPerProject'] = 'Project bugs';
$lang->bug->report->charts['bugsPerModule'] = 'Module bugs';
$lang->bug->report->charts['openedBugsPerDay'] = 'Opened bugs per day';
$lang->bug->report->charts['resolvedBugsPerDay'] = 'Resolved bugs per day';
$lang->bug->report->charts['closedBugsPerDay'] = 'Closed bugs per day';
$lang->bug->report->charts['openedBugsPerUser'] = 'Opened bugs per user';
$lang->bug->report->charts['resolvedBugsPerUser'] = 'Resolved bugs per user';
$lang->bug->report->charts['closedBugsPerUser'] = 'Closed bugs per user';
$lang->bug->report->charts['bugsPerSeverity'] = 'Severity';
$lang->bug->report->charts['bugsPerResolution'] = 'Resolution';
$lang->bug->report->charts['bugsPerStatus'] = 'Status';
$lang->bug->report->charts['bugsPerActivatedCount'] = 'Activated count';
$lang->bug->report->charts['bugsPerType'] = 'Type';
$lang->bug->report->charts['bugsPerAssignedTo'] = 'AssignedTo';
//$lang->bug->report->charts['bugLiveDays'] = 'Bug处理时间统计';
//$lang->bug->report->charts['bugHistories'] = 'Bug处理步骤统计';
$lang->bug->report->options->swf = 'pie2d';
$lang->bug->report->options->width = 'auto';
$lang->bug->report->options->height = 300;
$lang->bug->report->options->graph->baseFontSize = 12;
$lang->bug->report->options->graph->showNames = 1;
$lang->bug->report->options->graph->formatNumber = 1;
$lang->bug->report->options->graph->decimalPrecision = 0;
$lang->bug->report->options->graph->animation = 0;
$lang->bug->report->options->graph->rotateNames = 0;
$lang->bug->report->options->graph->yAxisName = 'COUNT';
$lang->bug->report->options->graph->pieRadius = 100;
$lang->bug->report->options->graph->showColumnShadow = 0;
$lang->bug->report->bugsPerProject->graph->xAxisName = 'Project';
$lang->bug->report->bugsPerModule->graph->xAxisName = 'Module';
$lang->bug->report->openedBugsPerDay->swf = 'column2d';
$lang->bug->report->openedBugsPerDay->height = 400;
$lang->bug->report->openedBugsPerDay->graph->xAxisName = 'Date';
$lang->bug->report->openedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->resolvedBugsPerDay->swf = 'column2d';
$lang->bug->report->resolvedBugsPerDay->height = 400;
$lang->bug->report->resolvedBugsPerDay->graph->xAxisName = 'Date';
$lang->bug->report->resolvedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->closedBugsPerDay->swf = 'column2d';
$lang->bug->report->closedBugsPerDay->height = 400;
$lang->bug->report->closedBugsPerDay->graph->xAxisName = 'Date';
$lang->bug->report->closedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->openedBugsPerUser->graph->xAxisName = 'User';
$lang->bug->report->resolvedBugsPerUser->graph->xAxisName= 'User';
$lang->bug->report->closedBugsPerUser->graph->xAxisName = 'User';
$lang->bug->report->bugsPerSeverity->graph->xAxisName = 'Severity';
$lang->bug->report->bugsPerResolution->graph->xAxisName = 'Resolution';
$lang->bug->report->bugsPerStatus->graph->xAxisName = 'Status';
$lang->bug->report->bugsPerActivatedCount->graph->xAxisName = 'Activated count';
$lang->bug->report->bugsPerType->graph->xAxisName = 'Type';
$lang->bug->report->bugsPerAssignedTo->graph->xAxisName = 'AssignedTo';
$lang->bug->report->bugLiveDays->graph->xAxisName = 'Live days';
$lang->bug->report->bugHistories->graph->xAxisName = 'Histories';
/* 操作记录。*/
$lang->bug->action->resolved = array('main' => '$date, Resolved by <strong>$actor</strong>, resolution is <strong>$extra</strong>.', 'extra' => $lang->bug->resolutionList);
$lang->bug->action->tostory = array('main' => '$date, To story by <strong>$actor</strong>, ID is <strong>$extra</strong>.');
$lang->bug->action->totask = array('main' => '$date, To task by <strong>$actor</strong>, ID is <strong>$extra</strong>.');
<?php
/**
* The bug module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
/* Fieldlist. */
$lang->bug->common = 'Bug';
$lang->bug->id = 'ID';
$lang->bug->product = 'Product';
$lang->bug->module = 'Module';
$lang->bug->path = 'Path';
$lang->bug->project = 'Project';
$lang->bug->story = 'Story';
$lang->bug->storyVersion = 'Story Version';
$lang->bug->task = 'Task';
$lang->bug->title = 'Title';
$lang->bug->severity = 'Severity';
$lang->bug->severityAB = 'S';
$lang->bug->pri = 'Priority';
$lang->bug->type = 'Type';
$lang->bug->os = 'OS';
$lang->bug->hardware = 'Hardware';
$lang->bug->browser = 'Browser';
$lang->bug->machine = 'Machine';
$lang->bug->found = 'How found';
$lang->bug->steps = 'Steps';
$lang->bug->status = 'Status';
$lang->bug->statusAB = 'Status';
$lang->bug->activatedCount = 'Activated count';
$lang->bug->activatedCountAB = 'Activated count';
$lang->bug->confirmed = 'Confirmed';
$lang->bug->toTask = 'To task';
$lang->bug->toStory = 'To story';
$lang->bug->mailto = 'Mailto';
$lang->bug->openedBy = 'Opened By';
$lang->bug->openedByAB = 'Opened';
$lang->bug->openedDate = 'Opened date';
$lang->bug->openedDateAB = 'Date';
$lang->bug->openedBuild = 'Opened Build';
$lang->bug->assignedTo = 'Assigned';
$lang->bug->assignedDate = 'Assigned Date';
$lang->bug->resolvedBy = 'Resolved By';
$lang->bug->resolvedByAB = 'Resolve';
$lang->bug->resolution = 'Resolution';
$lang->bug->resolutionAB = 'Resolution';
$lang->bug->resolvedBuild = 'Resolved Build';
$lang->bug->resolvedDate = 'Resolved Date';
$lang->bug->resolvedDateAB = 'Date';
$lang->bug->closedBy = 'Closed By';
$lang->bug->closedDate = 'Closed Date';
$lang->bug->duplicateBug = 'Duplicate';
$lang->bug->lastEditedBy = 'Last Edited By';
$lang->bug->lastEditedDate = 'Last Edited Date';
$lang->bug->linkBug = 'Related';
$lang->bug->case = 'Case';
$lang->bug->files = 'Files';
$lang->bug->keywords = 'Keywords';
$lang->bug->lastEditedByAB = 'Edited';
$lang->bug->lastEditedDateAB = 'Edited Date';
/* Actions. */
$lang->bug->index = 'Index';
$lang->bug->create = 'Create Bug';
$lang->bug->confirmBug = 'Confirm Bug';
$lang->bug->edit = 'Edit Bug';
$lang->bug->browse = 'Browse Bug';
$lang->bug->view = 'Bug Info';
$lang->bug->resolve = 'Resolve Bug';
$lang->bug->close = 'Close Bug';
$lang->bug->activate = 'Activate Bug';
$lang->bug->reportChart = 'Report';
$lang->bug->export = 'Export data';
$lang->bug->delete = 'Delete Bug';
$lang->bug->saveTemplate = 'Save template';
$lang->bug->deleteTemplate = 'Delete template';
$lang->bug->customFields = 'Custom';
$lang->bug->restoreDefault = 'Default';
$lang->bug->ajaxGetUserBugs = 'API: My Bugs';
$lang->bug->ajaxGetModuleOwner = 'API: Get module default owner';
$lang->bug->confirmStoryChange = 'Confirm Story Change';
/* Browse tabs. */
$lang->bug->selectProduct = 'Select product';
$lang->bug->byModule = 'ByModule';
$lang->bug->assignToMe = 'MyBugs';
$lang->bug->openedByMe = 'MyOpen';
$lang->bug->resolvedByMe = 'MyResolve';
$lang->bug->closedByMe = 'MyClose';
$lang->bug->assignToNull = 'Unassigned';
$lang->bug->unResolved = 'Unresolved';
$lang->bug->unclosed = 'Unclosed';
$lang->bug->longLifeBugs = 'Longlife';
$lang->bug->postponedBugs = 'Postponed';
$lang->bug->allBugs = 'Allbug';
$lang->bug->moduleBugs = 'ByModule';
$lang->bug->byQuery = 'Search';
$lang->bug->needConfirm = 'StoryChanged';
$lang->bug->allProduct = 'All products';
/* Labels. */
$lang->bug->lblProductAndModule = 'Product&Module';
$lang->bug->lblProjectAndTask = 'Project&Task';
$lang->bug->lblStory = 'Story';
$lang->bug->lblTypeAndSeverity = 'Type&Severity';
$lang->bug->lblSystemBrowserAndHardware = 'OS&Browser';
$lang->bug->lblAssignedTo = 'Assigned to';
$lang->bug->lblMailto = 'Mailto';
$lang->bug->lblLastEdited = 'Last edited';
$lang->bug->lblResolved = 'Resolved';
$lang->bug->lblAllFields = 'All Fields';
$lang->bug->lblCustomFields = 'Custom Fields';
/* Legends. */
$lang->bug->legendBasicInfo = 'Basic info';
$lang->bug->legendMailto = 'Mailto';
$lang->bug->legendAttatch = 'Files';
$lang->bug->legendLinkBugs = 'Related bug';
$lang->bug->legendPrjStoryTask = 'Project, story & task';
$lang->bug->legendCases = 'Related case';
$lang->bug->legendSteps = 'Steps';
$lang->bug->legendAction = 'Action';
$lang->bug->legendHistory = 'History';
$lang->bug->legendComment = 'Comment';
$lang->bug->legendLife = 'Lifetime';
$lang->bug->legendMisc = 'Misc';
/* Action buttons. */
$lang->bug->buttonConfirm = 'Confirm';
$lang->bug->buttonCopy = 'Copy';
$lang->bug->buttonEdit = 'Edit';
$lang->bug->buttonActivate = 'Activate';
$lang->bug->buttonResolve = 'Resolve';
$lang->bug->buttonClose = 'Close';
$lang->bug->buttonToList = 'Back';
$lang->bug->buttonCreateTestcase = 'Create case';
/* Confirm messags. */
$lang->bug->confirmChangeProduct = 'Change product will change project, task and story also, are you sure?';
$lang->bug->confirmDelete = 'Are you sure to delete this bug?';
$lang->bug->setTemplateTitle = 'Please input the template title:';
$lang->bug->remindTask = 'This bug has been to be a task, update the task:%s or not?';
/* Templates. */
$lang->bug->tplStep = "<p>[Steps]</p>";
$lang->bug->tplResult = "<p>[Result]</p>";
$lang->bug->tplExpect = "<p>[Expect]</p>";
/* Field options lists. */
$lang->bug->severityList[3] = '3';
$lang->bug->severityList[1] = '1';
$lang->bug->severityList[2] = '2';
$lang->bug->severityList[4] = '4';
$lang->bug->priList[0] = '';
$lang->bug->priList[3] = '3';
$lang->bug->priList[1] = '1';
$lang->bug->priList[2] = '2';
$lang->bug->priList[4] = '4';
$lang->bug->osList[''] = '';
$lang->bug->osList['all'] = 'All';
$lang->bug->osList['windows'] = 'Windows';
$lang->bug->osList['winxp'] = 'Windows XP';
$lang->bug->osList['win7'] = 'Windows 7';
$lang->bug->osList['vista'] = 'Windows Vista';
$lang->bug->osList['win2000'] = 'Windows 2000';
$lang->bug->osList['win2003'] = 'Windows 2003';
$lang->bug->osList['win2008'] = 'Windows 2008';
$lang->bug->osList['winnt'] = 'Windows NT';
$lang->bug->osList['win98'] = 'Windows 98';
$lang->bug->osList['andriod'] = 'Andriod';
$lang->bug->osList['ios'] = 'IOS';
$lang->bug->osList['wp7'] = 'WP7';
$lang->bug->osList['symbian'] = 'Symbian';
$lang->bug->osList['linux'] = 'Linux';
$lang->bug->osList['freebsd'] = 'FreeBSD';
$lang->bug->osList['mac'] = 'Mac OS';
$lang->bug->osList['unix'] = 'Unix';
$lang->bug->osList['others'] = 'Others';
$lang->bug->browserList[''] = '';
$lang->bug->browserList['all'] = 'All';
$lang->bug->browserList['ie'] = 'IE';
$lang->bug->browserList['ie8'] = 'IE8';
$lang->bug->browserList['ie9'] = 'IE9';
$lang->bug->browserList['ie6'] = 'IE6';
$lang->bug->browserList['ie7'] = 'IE7';
$lang->bug->browserList['chrome'] = 'chrome';
$lang->bug->browserList['firefox'] = 'Firefox';
$lang->bug->browserList['firefox2'] = 'Firefox2';
$lang->bug->browserList['firefox3'] = 'Firefox3';
$lang->bug->browserList['firefox4'] = 'Firefox4';
$lang->bug->browserList['opera'] = 'opera';
$lang->bug->browserList['opera9'] = 'opera9';
$lang->bug->browserList['oprea10'] = 'opera10';
$lang->bug->browserList['oprea11'] = 'opera11';
$lang->bug->browserList['safari'] = 'safari';
$lang->bug->browserList['maxthon'] = '傲游';
$lang->bug->browserList['uc'] = 'UC';
$lang->bug->browserList['other'] = 'Others';
$lang->bug->typeList[''] = '';
$lang->bug->typeList['codeerror'] = 'Code error';
$lang->bug->typeList['interface'] = 'Interface';
$lang->bug->typeList['designchange'] = 'Design change';
$lang->bug->typeList['newfeature'] = 'New feature';
$lang->bug->typeList['designdefect'] = 'Design defect';
$lang->bug->typeList['config'] = 'Config';
$lang->bug->typeList['install'] = 'Install';
$lang->bug->typeList['security'] = 'Security';
$lang->bug->typeList['performance'] = 'Performance';
$lang->bug->typeList['standard'] = 'Standard';
$lang->bug->typeList['automation'] = 'Automation';
$lang->bug->typeList['trackthings'] = 'Tracking';
$lang->bug->typeList['others'] = 'Others';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = 'Active';
$lang->bug->statusList['resolved'] = 'Resolved';
$lang->bug->statusList['closed'] = 'Closed';
$lang->bug->confirmedList[1] = 'Confirmed';
$lang->bug->confirmedList[0] = 'Unconfirmed';
$lang->bug->resolutionList[''] = '';
$lang->bug->resolutionList['bydesign'] = 'By design';
$lang->bug->resolutionList['duplicate'] = 'Duplicate';
$lang->bug->resolutionList['external'] = 'External';
$lang->bug->resolutionList['fixed'] = 'Fixed';
$lang->bug->resolutionList['notrepro'] = 'Not reproduce';
$lang->bug->resolutionList['postponed'] = 'Postponed';
$lang->bug->resolutionList['willnotfix'] = "Won't fix";
$lang->bug->resolutionList['tostory'] = 'To story';
/* Report. */
$lang->bug->report->common = 'Report';
$lang->bug->report->select = 'Select';
$lang->bug->report->create = 'Create';
$lang->bug->report->selectAll = 'All';
$lang->bug->report->selectReverse = 'Reverse';
$lang->bug->report->charts['bugsPerProject'] = 'Project bugs';
$lang->bug->report->charts['bugsPerModule'] = 'Module bugs';
$lang->bug->report->charts['openedBugsPerDay'] = 'Opened bugs per day';
$lang->bug->report->charts['resolvedBugsPerDay'] = 'Resolved bugs per day';
$lang->bug->report->charts['closedBugsPerDay'] = 'Closed bugs per day';
$lang->bug->report->charts['openedBugsPerUser'] = 'Opened bugs per user';
$lang->bug->report->charts['resolvedBugsPerUser'] = 'Resolved bugs per user';
$lang->bug->report->charts['closedBugsPerUser'] = 'Closed bugs per user';
$lang->bug->report->charts['bugsPerSeverity'] = 'Severity';
$lang->bug->report->charts['bugsPerResolution'] = 'Resolution';
$lang->bug->report->charts['bugsPerStatus'] = 'Status';
$lang->bug->report->charts['bugsPerActivatedCount'] = 'Activated count';
$lang->bug->report->charts['bugsPerType'] = 'Type';
$lang->bug->report->charts['bugsPerAssignedTo'] = 'AssignedTo';
//$lang->bug->report->charts['bugLiveDays'] = 'Bug处理时间统计';
//$lang->bug->report->charts['bugHistories'] = 'Bug处理步骤统计';
$lang->bug->report->options->swf = 'pie2d';
$lang->bug->report->options->width = 'auto';
$lang->bug->report->options->height = 300;
$lang->bug->report->options->graph->baseFontSize = 12;
$lang->bug->report->options->graph->showNames = 1;
$lang->bug->report->options->graph->formatNumber = 1;
$lang->bug->report->options->graph->decimalPrecision = 0;
$lang->bug->report->options->graph->animation = 0;
$lang->bug->report->options->graph->rotateNames = 0;
$lang->bug->report->options->graph->yAxisName = 'COUNT';
$lang->bug->report->options->graph->pieRadius = 100;
$lang->bug->report->options->graph->showColumnShadow = 0;
$lang->bug->report->bugsPerProject->graph->xAxisName = 'Project';
$lang->bug->report->bugsPerModule->graph->xAxisName = 'Module';
$lang->bug->report->openedBugsPerDay->swf = 'column2d';
$lang->bug->report->openedBugsPerDay->height = 400;
$lang->bug->report->openedBugsPerDay->graph->xAxisName = 'Date';
$lang->bug->report->openedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->resolvedBugsPerDay->swf = 'column2d';
$lang->bug->report->resolvedBugsPerDay->height = 400;
$lang->bug->report->resolvedBugsPerDay->graph->xAxisName = 'Date';
$lang->bug->report->resolvedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->closedBugsPerDay->swf = 'column2d';
$lang->bug->report->closedBugsPerDay->height = 400;
$lang->bug->report->closedBugsPerDay->graph->xAxisName = 'Date';
$lang->bug->report->closedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->openedBugsPerUser->graph->xAxisName = 'User';
$lang->bug->report->resolvedBugsPerUser->graph->xAxisName= 'User';
$lang->bug->report->closedBugsPerUser->graph->xAxisName = 'User';
$lang->bug->report->bugsPerSeverity->graph->xAxisName = 'Severity';
$lang->bug->report->bugsPerResolution->graph->xAxisName = 'Resolution';
$lang->bug->report->bugsPerStatus->graph->xAxisName = 'Status';
$lang->bug->report->bugsPerActivatedCount->graph->xAxisName = 'Activated count';
$lang->bug->report->bugsPerType->graph->xAxisName = 'Type';
$lang->bug->report->bugsPerAssignedTo->graph->xAxisName = 'AssignedTo';
$lang->bug->report->bugLiveDays->graph->xAxisName = 'Live days';
$lang->bug->report->bugHistories->graph->xAxisName = 'Histories';
/* 操作记录。*/
$lang->bug->action->resolved = array('main' => '$date, Resolved by <strong>$actor</strong>, resolution is <strong>$extra</strong>.', 'extra' => $lang->bug->resolutionList);
$lang->bug->action->tostory = array('main' => '$date, To story by <strong>$actor</strong>, ID is <strong>$extra</strong>.');
$lang->bug->action->totask = array('main' => '$date, To task by <strong>$actor</strong>, ID is <strong>$extra</strong>.');

View File

@@ -1,312 +1,312 @@
<?php
/**
* The bug module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
/* 字段列表。*/
$lang->bug->common = '缺陷管理';
$lang->bug->id = 'Bug编号';
$lang->bug->product = '所属产品';
$lang->bug->module = '所属模块';
$lang->bug->path = '模块路径';
$lang->bug->project = '所属项目';
$lang->bug->story = '相关需求';
$lang->bug->storyVersion = '需求版本';
$lang->bug->task = '相关任务';
$lang->bug->title = 'Bug标题';
$lang->bug->severity = '严重程度';
$lang->bug->severityAB = '级别';
$lang->bug->pri = '优先级';
$lang->bug->type = 'Bug类型';
$lang->bug->os = '操作系统';
$lang->bug->hardware = '硬件平台';
$lang->bug->browser = '浏览器';
$lang->bug->machine = '机器硬件';
$lang->bug->found = '如何发现';
$lang->bug->steps = '重现步骤';
$lang->bug->status = 'Bug状态';
$lang->bug->statusAB = '状态';
$lang->bug->activatedCount = '激活次数';
$lang->bug->activatedCountAB = '激活次数';
$lang->bug->confirmed = '是否确认';
$lang->bug->toTask = '转任务';
$lang->bug->toStory = '转需求';
$lang->bug->mailto = '抄送给';
$lang->bug->openedBy = '由谁创建';
$lang->bug->openedByAB = '创建';
$lang->bug->openedDate = '创建日期';
$lang->bug->openedDateAB = '创建日期';
$lang->bug->openedBuild = '影响版本';
$lang->bug->assignedTo = '指派给';
$lang->bug->assignedDate = '指派日期';
$lang->bug->resolvedBy = '解决者';
$lang->bug->resolvedByAB = '解决';
$lang->bug->resolution = '解决方案';
$lang->bug->resolutionAB = '方案';
$lang->bug->resolvedBuild = '解决版本';
$lang->bug->resolvedDate = '解决日期';
$lang->bug->resolvedDateAB = '解决日期';
$lang->bug->closedBy = '由谁关闭';
$lang->bug->closedDate = '关闭日期';
$lang->bug->duplicateBug = '重复Bug';
$lang->bug->lastEditedBy = '最后修改者';
$lang->bug->lastEditedDate = '最后修改日期';
$lang->bug->linkBug = '相关Bug';
$lang->bug->case = '相关用例';
$lang->bug->files = '附件';
$lang->bug->keywords = '关键词';
$lang->bug->lastEditedByAB = '修改者';
$lang->bug->lastEditedDateAB = '修改日期';
/* 方法列表。*/
$lang->bug->index = '首页';
$lang->bug->create = '创建Bug';
$lang->bug->confirmBug = '确认';
$lang->bug->edit = '编辑Bug';
$lang->bug->browse = 'Bug列表';
$lang->bug->view = 'Bug详情';
$lang->bug->resolve = '解决Bug';
$lang->bug->close = '关闭Bug';
$lang->bug->activate = '激活Bug';
$lang->bug->reportChart = '报表统计';
$lang->bug->export = '导出数据';
$lang->bug->delete = '删除Bug';
$lang->bug->saveTemplate = '保存模板';
$lang->bug->deleteTemplate = '删除模板';
$lang->bug->customFields = '自定义字段';
$lang->bug->restoreDefault = '恢复默认';
$lang->bug->ajaxGetUserBugs = '接口:我的Bug';
$lang->bug->ajaxGetModuleOwner = '接口:获得模块的默认指派人';
$lang->bug->confirmStoryChange = '确认需求变动';
/* 查询条件列表。*/
$lang->bug->selectProduct = '请选择产品';
$lang->bug->byModule = '按模块';
$lang->bug->assignToMe = '指派给我';
$lang->bug->openedByMe = '由我创建';
$lang->bug->resolvedByMe = '由我解决';
$lang->bug->closedByMe = '由我关闭';
$lang->bug->assignToNull = '未指派';
$lang->bug->unResolved = '未解决';
$lang->bug->unclosed = '未关闭';
$lang->bug->longLifeBugs = '久未处理';
$lang->bug->postponedBugs = '被延期';
$lang->bug->allBugs = '所有Bug';
$lang->bug->moduleBugs = '按模块浏览';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求变动';
$lang->bug->allProduct = '所有产品';
/* 页面标签。*/
$lang->bug->lblProductAndModule = '产品模块';
$lang->bug->lblProjectAndTask = '项目任务';
$lang->bug->lblStory = '相关需求';
$lang->bug->lblTypeAndSeverity = '类型/严重程度';
$lang->bug->lblSystemBrowserAndHardware = '系统/浏览器';
$lang->bug->lblAssignedTo = '当前指派';
$lang->bug->lblMailto = '抄送给';
$lang->bug->lblLastEdited = '最后修改';
$lang->bug->lblResolved = '由谁解决';
$lang->bug->lblAllFields = '所有字段';
$lang->bug->lblCustomFields = '自定义字段';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
$lang->bug->legendMailto = '抄送给';
$lang->bug->legendAttatch = '附件';
$lang->bug->legendLinkBugs = '相关Bug';
$lang->bug->legendPrjStoryTask = '项目/需求/任务';
$lang->bug->legendCases = '相关用例';
$lang->bug->legendSteps = '重现步骤';
$lang->bug->legendAction = '操作';
$lang->bug->legendHistory = '历史记录';
$lang->bug->legendComment = '备注';
$lang->bug->legendLife = 'BUG的一生';
$lang->bug->legendMisc = '其相关他';
/* 功能按钮。*/
$lang->bug->buttonConfirm = '确认';
$lang->bug->buttonCopy = '复制';
$lang->bug->buttonEdit = '编辑';
$lang->bug->buttonActivate = '激活';
$lang->bug->buttonResolve = '解决';
$lang->bug->buttonClose = '关闭';
$lang->bug->buttonToList = '返回';
$lang->bug->buttonCreateTestcase = '建用例';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = '修改产品会导致相应的项目、需求和任务发生变化,确定吗?';
$lang->bug->confirmDelete = '您确认要删除该Bug吗';
$lang->bug->setTemplateTitle = '请输入bug模板标题保存之前请先填写bug重现步骤';
$lang->bug->remindTask = '该Bug已经转化为任务是否更新任务(编号:%s)状态 ?';
/* 模板。*/
$lang->bug->tplStep = "<p>[步骤]</p>";
$lang->bug->tplResult = "<p>[结果]</p>";
$lang->bug->tplExpect = "<p>[期望]</p>";
/* 各个字段取值列表。*/
$lang->bug->severityList[3] = '3';
$lang->bug->severityList[1] = '1';
$lang->bug->severityList[2] = '2';
$lang->bug->severityList[4] = '4';
$lang->bug->priList[0] = '';
$lang->bug->priList[3] = '3';
$lang->bug->priList[1] = '1';
$lang->bug->priList[2] = '2';
$lang->bug->priList[4] = '4';
$lang->bug->osList[''] = '';
$lang->bug->osList['all'] = '全部';
$lang->bug->osList['windows'] = 'Windows';
$lang->bug->osList['winxp'] = 'Windows XP';
$lang->bug->osList['win7'] = 'Windows 7';
$lang->bug->osList['vista'] = 'Windows Vista';
$lang->bug->osList['win2000'] = 'Windows 2000';
$lang->bug->osList['win2003'] = 'Windows 2003';
$lang->bug->osList['win2008'] = 'Windows 2008';
$lang->bug->osList['winnt'] = 'Windows NT';
$lang->bug->osList['win98'] = 'Windows 98';
$lang->bug->osList['andriod'] = 'Andriod';
$lang->bug->osList['ios'] = 'IOS';
$lang->bug->osList['wp7'] = 'WP7';
$lang->bug->osList['symbian'] = 'Symbian';
$lang->bug->osList['linux'] = 'Linux';
$lang->bug->osList['freebsd'] = 'FreeBSD';
$lang->bug->osList['mac'] = 'Mac OS';
$lang->bug->osList['unix'] = 'Unix';
$lang->bug->osList['others'] = '其他';
$lang->bug->browserList[''] = '';
$lang->bug->browserList['all'] = '全部';
$lang->bug->browserList['ie'] = 'IE系列';
$lang->bug->browserList['ie8'] = 'IE8';
$lang->bug->browserList['ie9'] = 'IE9';
$lang->bug->browserList['ie6'] = 'IE6';
$lang->bug->browserList['ie7'] = 'IE7';
$lang->bug->browserList['chrome'] = 'chrome';
$lang->bug->browserList['firefox'] = 'firefox系列';
$lang->bug->browserList['firefox2'] = 'firefox2';
$lang->bug->browserList['firefox3'] = 'firefox3';
$lang->bug->browserList['firefox4'] = 'firefox4';
$lang->bug->browserList['opera'] = 'opera系列';
$lang->bug->browserList['opera9'] = 'opera9';
$lang->bug->browserList['oprea10'] = 'opera10';
$lang->bug->browserList['oprea11'] = 'opera11';
$lang->bug->browserList['safari'] = 'safari';
$lang->bug->browserList['maxthon'] = '傲游';
$lang->bug->browserList['uc'] = 'UC';
$lang->bug->browserList['other'] = '其他';
$lang->bug->typeList[''] = '';
$lang->bug->typeList['codeerror'] = '代码错误';
$lang->bug->typeList['interface'] = '界面优化';
$lang->bug->typeList['designchange'] = '设计变更';
$lang->bug->typeList['newfeature'] = '新增需求';
$lang->bug->typeList['designdefect'] = '设计缺陷';
$lang->bug->typeList['config'] = '配置相关';
$lang->bug->typeList['install'] = '安装部署';
$lang->bug->typeList['security'] = '安全相关';
$lang->bug->typeList['performance'] = '性能问题';
$lang->bug->typeList['standard'] = '标准规范';
$lang->bug->typeList['automation'] = '测试脚本';
$lang->bug->typeList['trackthings'] = '事务跟踪';
$lang->bug->typeList['others'] = '其他';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = '激活';
$lang->bug->statusList['resolved'] = '已解决';
$lang->bug->statusList['closed'] = '已关闭';
$lang->bug->confirmedList[1] = '已确认';
$lang->bug->confirmedList[0] = '未确认';
$lang->bug->resolutionList[''] = '';
$lang->bug->resolutionList['bydesign'] = '设计如此';
$lang->bug->resolutionList['duplicate'] = '重复Bug';
$lang->bug->resolutionList['external'] = '外部原因';
$lang->bug->resolutionList['fixed'] = '已解决';
$lang->bug->resolutionList['notrepro'] = '无法重现';
$lang->bug->resolutionList['postponed'] = '延期处理';
$lang->bug->resolutionList['willnotfix'] = "不予解决";
$lang->bug->resolutionList['tostory'] = '转为需求';
/* 统计报表。*/
$lang->bug->report->common = '统计报表';
$lang->bug->report->select = '请选择报表类型';
$lang->bug->report->create = '生成报表';
$lang->bug->report->selectAll = '全选';
$lang->bug->report->selectReverse = '反选';
$lang->bug->report->charts['bugsPerProject'] = '项目Bug数量';
$lang->bug->report->charts['bugsPerModule'] = '模块Bug数量';
$lang->bug->report->charts['openedBugsPerDay'] = '每天新增Bug数';
$lang->bug->report->charts['resolvedBugsPerDay'] = '每天解决Bug数';
$lang->bug->report->charts['closedBugsPerDay'] = '每天关闭的Bug数';
$lang->bug->report->charts['openedBugsPerUser'] = '每人提交的Bug数';
$lang->bug->report->charts['resolvedBugsPerUser'] = '每人解决的Bug数';
$lang->bug->report->charts['closedBugsPerUser'] = '每人关闭的Bug数';
$lang->bug->report->charts['bugsPerSeverity'] = 'Bug严重程度统计';
$lang->bug->report->charts['bugsPerResolution'] = 'Bug解决方案统计';
$lang->bug->report->charts['bugsPerStatus'] = 'Bug状态统计';
$lang->bug->report->charts['bugsPerActivatedCount'] = 'Bug激活次数统计';
$lang->bug->report->charts['bugsPerType'] = 'Bug类型统计';
$lang->bug->report->charts['bugsPerAssignedTo'] = '指派给统计';
//$lang->bug->report->charts['bugLiveDays'] = 'Bug处理时间统计';
//$lang->bug->report->charts['bugHistories'] = 'Bug处理步骤统计';
$lang->bug->report->options->swf = 'pie2d';
$lang->bug->report->options->width = 'auto';
$lang->bug->report->options->height = 300;
$lang->bug->report->options->graph->baseFontSize = 12;
$lang->bug->report->options->graph->showNames = 1;
$lang->bug->report->options->graph->formatNumber = 1;
$lang->bug->report->options->graph->decimalPrecision = 0;
$lang->bug->report->options->graph->animation = 0;
$lang->bug->report->options->graph->rotateNames = 0;
$lang->bug->report->options->graph->yAxisName = 'COUNT';
$lang->bug->report->options->graph->pieRadius = 100; // 饼图直径。
$lang->bug->report->options->graph->showColumnShadow = 0; // 是否显示柱状图阴影。
$lang->bug->report->bugsPerProject->graph->xAxisName = '项目';
$lang->bug->report->bugsPerModule->graph->xAxisName = '模块';
$lang->bug->report->openedBugsPerDay->swf = 'column2d';
$lang->bug->report->openedBugsPerDay->height = 400;
$lang->bug->report->openedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->openedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->resolvedBugsPerDay->swf = 'column2d';
$lang->bug->report->resolvedBugsPerDay->height = 400;
$lang->bug->report->resolvedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->resolvedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->closedBugsPerDay->swf = 'column2d';
$lang->bug->report->closedBugsPerDay->height = 400;
$lang->bug->report->closedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->closedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->openedBugsPerUser->graph->xAxisName = '用户';
$lang->bug->report->resolvedBugsPerUser->graph->xAxisName= '用户';
$lang->bug->report->closedBugsPerUser->graph->xAxisName = '用户';
$lang->bug->report->bugsPerSeverity->graph->xAxisName = '严重程度';
$lang->bug->report->bugsPerResolution->graph->xAxisName = '解决方案';
$lang->bug->report->bugsPerStatus->graph->xAxisName = '状态';
$lang->bug->report->bugsPerActivatedCount->graph->xAxisName = '激活次数';
$lang->bug->report->bugsPerType->graph->xAxisName = '类型';
$lang->bug->report->bugsPerAssignedTo->graph->xAxisName = '指派给';
$lang->bug->report->bugLiveDays->graph->xAxisName = '处理时间';
$lang->bug->report->bugHistories->graph->xAxisName = '处理步骤';
/* 操作记录。*/
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解决,方案为 <strong>$extra</strong>。', 'extra' => $lang->bug->resolutionList);
$lang->bug->action->tostory = array('main' => '$date, 由 <strong>$actor</strong> 转为<strong>需求</strong>,编号为 <strong>$extra</strong>。');
$lang->bug->action->totask = array('main' => '$date, 由 <strong>$actor</strong> 导入为<strong>任务</strong>,编号为 <strong>$extra</strong>。');
<?php
/**
* The bug module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
/* 字段列表。*/
$lang->bug->common = '缺陷管理';
$lang->bug->id = 'Bug编号';
$lang->bug->product = '所属产品';
$lang->bug->module = '所属模块';
$lang->bug->path = '模块路径';
$lang->bug->project = '所属项目';
$lang->bug->story = '相关需求';
$lang->bug->storyVersion = '需求版本';
$lang->bug->task = '相关任务';
$lang->bug->title = 'Bug标题';
$lang->bug->severity = '严重程度';
$lang->bug->severityAB = '级别';
$lang->bug->pri = '优先级';
$lang->bug->type = 'Bug类型';
$lang->bug->os = '操作系统';
$lang->bug->hardware = '硬件平台';
$lang->bug->browser = '浏览器';
$lang->bug->machine = '机器硬件';
$lang->bug->found = '如何发现';
$lang->bug->steps = '重现步骤';
$lang->bug->status = 'Bug状态';
$lang->bug->statusAB = '状态';
$lang->bug->activatedCount = '激活次数';
$lang->bug->activatedCountAB = '激活次数';
$lang->bug->confirmed = '是否确认';
$lang->bug->toTask = '转任务';
$lang->bug->toStory = '转需求';
$lang->bug->mailto = '抄送给';
$lang->bug->openedBy = '由谁创建';
$lang->bug->openedByAB = '创建';
$lang->bug->openedDate = '创建日期';
$lang->bug->openedDateAB = '创建日期';
$lang->bug->openedBuild = '影响版本';
$lang->bug->assignedTo = '指派给';
$lang->bug->assignedDate = '指派日期';
$lang->bug->resolvedBy = '解决者';
$lang->bug->resolvedByAB = '解决';
$lang->bug->resolution = '解决方案';
$lang->bug->resolutionAB = '方案';
$lang->bug->resolvedBuild = '解决版本';
$lang->bug->resolvedDate = '解决日期';
$lang->bug->resolvedDateAB = '解决日期';
$lang->bug->closedBy = '由谁关闭';
$lang->bug->closedDate = '关闭日期';
$lang->bug->duplicateBug = '重复Bug';
$lang->bug->lastEditedBy = '最后修改者';
$lang->bug->lastEditedDate = '最后修改日期';
$lang->bug->linkBug = '相关Bug';
$lang->bug->case = '相关用例';
$lang->bug->files = '附件';
$lang->bug->keywords = '关键词';
$lang->bug->lastEditedByAB = '修改者';
$lang->bug->lastEditedDateAB = '修改日期';
/* 方法列表。*/
$lang->bug->index = '首页';
$lang->bug->create = '创建Bug';
$lang->bug->confirmBug = '确认';
$lang->bug->edit = '编辑Bug';
$lang->bug->browse = 'Bug列表';
$lang->bug->view = 'Bug详情';
$lang->bug->resolve = '解决Bug';
$lang->bug->close = '关闭Bug';
$lang->bug->activate = '激活Bug';
$lang->bug->reportChart = '报表统计';
$lang->bug->export = '导出数据';
$lang->bug->delete = '删除Bug';
$lang->bug->saveTemplate = '保存模板';
$lang->bug->deleteTemplate = '删除模板';
$lang->bug->customFields = '自定义字段';
$lang->bug->restoreDefault = '恢复默认';
$lang->bug->ajaxGetUserBugs = '接口:我的Bug';
$lang->bug->ajaxGetModuleOwner = '接口:获得模块的默认指派人';
$lang->bug->confirmStoryChange = '确认需求变动';
/* 查询条件列表。*/
$lang->bug->selectProduct = '请选择产品';
$lang->bug->byModule = '按模块';
$lang->bug->assignToMe = '指派给我';
$lang->bug->openedByMe = '由我创建';
$lang->bug->resolvedByMe = '由我解决';
$lang->bug->closedByMe = '由我关闭';
$lang->bug->assignToNull = '未指派';
$lang->bug->unResolved = '未解决';
$lang->bug->unclosed = '未关闭';
$lang->bug->longLifeBugs = '久未处理';
$lang->bug->postponedBugs = '被延期';
$lang->bug->allBugs = '所有Bug';
$lang->bug->moduleBugs = '按模块浏览';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求变动';
$lang->bug->allProduct = '所有产品';
/* 页面标签。*/
$lang->bug->lblProductAndModule = '产品模块';
$lang->bug->lblProjectAndTask = '项目任务';
$lang->bug->lblStory = '相关需求';
$lang->bug->lblTypeAndSeverity = '类型/严重程度';
$lang->bug->lblSystemBrowserAndHardware = '系统/浏览器';
$lang->bug->lblAssignedTo = '当前指派';
$lang->bug->lblMailto = '抄送给';
$lang->bug->lblLastEdited = '最后修改';
$lang->bug->lblResolved = '由谁解决';
$lang->bug->lblAllFields = '所有字段';
$lang->bug->lblCustomFields = '自定义字段';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
$lang->bug->legendMailto = '抄送给';
$lang->bug->legendAttatch = '附件';
$lang->bug->legendLinkBugs = '相关Bug';
$lang->bug->legendPrjStoryTask = '项目/需求/任务';
$lang->bug->legendCases = '相关用例';
$lang->bug->legendSteps = '重现步骤';
$lang->bug->legendAction = '操作';
$lang->bug->legendHistory = '历史记录';
$lang->bug->legendComment = '备注';
$lang->bug->legendLife = 'BUG的一生';
$lang->bug->legendMisc = '其相关他';
/* 功能按钮。*/
$lang->bug->buttonConfirm = '确认';
$lang->bug->buttonCopy = '复制';
$lang->bug->buttonEdit = '编辑';
$lang->bug->buttonActivate = '激活';
$lang->bug->buttonResolve = '解决';
$lang->bug->buttonClose = '关闭';
$lang->bug->buttonToList = '返回';
$lang->bug->buttonCreateTestcase = '建用例';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = '修改产品会导致相应的项目、需求和任务发生变化,确定吗?';
$lang->bug->confirmDelete = '您确认要删除该Bug吗';
$lang->bug->setTemplateTitle = '请输入bug模板标题保存之前请先填写bug重现步骤';
$lang->bug->remindTask = '该Bug已经转化为任务是否更新任务(编号:%s)状态 ?';
/* 模板。*/
$lang->bug->tplStep = "<p>[步骤]</p>";
$lang->bug->tplResult = "<p>[结果]</p>";
$lang->bug->tplExpect = "<p>[期望]</p>";
/* 各个字段取值列表。*/
$lang->bug->severityList[3] = '3';
$lang->bug->severityList[1] = '1';
$lang->bug->severityList[2] = '2';
$lang->bug->severityList[4] = '4';
$lang->bug->priList[0] = '';
$lang->bug->priList[3] = '3';
$lang->bug->priList[1] = '1';
$lang->bug->priList[2] = '2';
$lang->bug->priList[4] = '4';
$lang->bug->osList[''] = '';
$lang->bug->osList['all'] = '全部';
$lang->bug->osList['windows'] = 'Windows';
$lang->bug->osList['winxp'] = 'Windows XP';
$lang->bug->osList['win7'] = 'Windows 7';
$lang->bug->osList['vista'] = 'Windows Vista';
$lang->bug->osList['win2000'] = 'Windows 2000';
$lang->bug->osList['win2003'] = 'Windows 2003';
$lang->bug->osList['win2008'] = 'Windows 2008';
$lang->bug->osList['winnt'] = 'Windows NT';
$lang->bug->osList['win98'] = 'Windows 98';
$lang->bug->osList['andriod'] = 'Andriod';
$lang->bug->osList['ios'] = 'IOS';
$lang->bug->osList['wp7'] = 'WP7';
$lang->bug->osList['symbian'] = 'Symbian';
$lang->bug->osList['linux'] = 'Linux';
$lang->bug->osList['freebsd'] = 'FreeBSD';
$lang->bug->osList['mac'] = 'Mac OS';
$lang->bug->osList['unix'] = 'Unix';
$lang->bug->osList['others'] = '其他';
$lang->bug->browserList[''] = '';
$lang->bug->browserList['all'] = '全部';
$lang->bug->browserList['ie'] = 'IE系列';
$lang->bug->browserList['ie8'] = 'IE8';
$lang->bug->browserList['ie9'] = 'IE9';
$lang->bug->browserList['ie6'] = 'IE6';
$lang->bug->browserList['ie7'] = 'IE7';
$lang->bug->browserList['chrome'] = 'chrome';
$lang->bug->browserList['firefox'] = 'firefox系列';
$lang->bug->browserList['firefox2'] = 'firefox2';
$lang->bug->browserList['firefox3'] = 'firefox3';
$lang->bug->browserList['firefox4'] = 'firefox4';
$lang->bug->browserList['opera'] = 'opera系列';
$lang->bug->browserList['opera9'] = 'opera9';
$lang->bug->browserList['oprea10'] = 'opera10';
$lang->bug->browserList['oprea11'] = 'opera11';
$lang->bug->browserList['safari'] = 'safari';
$lang->bug->browserList['maxthon'] = '傲游';
$lang->bug->browserList['uc'] = 'UC';
$lang->bug->browserList['other'] = '其他';
$lang->bug->typeList[''] = '';
$lang->bug->typeList['codeerror'] = '代码错误';
$lang->bug->typeList['interface'] = '界面优化';
$lang->bug->typeList['designchange'] = '设计变更';
$lang->bug->typeList['newfeature'] = '新增需求';
$lang->bug->typeList['designdefect'] = '设计缺陷';
$lang->bug->typeList['config'] = '配置相关';
$lang->bug->typeList['install'] = '安装部署';
$lang->bug->typeList['security'] = '安全相关';
$lang->bug->typeList['performance'] = '性能问题';
$lang->bug->typeList['standard'] = '标准规范';
$lang->bug->typeList['automation'] = '测试脚本';
$lang->bug->typeList['trackthings'] = '事务跟踪';
$lang->bug->typeList['others'] = '其他';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = '激活';
$lang->bug->statusList['resolved'] = '已解决';
$lang->bug->statusList['closed'] = '已关闭';
$lang->bug->confirmedList[1] = '已确认';
$lang->bug->confirmedList[0] = '未确认';
$lang->bug->resolutionList[''] = '';
$lang->bug->resolutionList['bydesign'] = '设计如此';
$lang->bug->resolutionList['duplicate'] = '重复Bug';
$lang->bug->resolutionList['external'] = '外部原因';
$lang->bug->resolutionList['fixed'] = '已解决';
$lang->bug->resolutionList['notrepro'] = '无法重现';
$lang->bug->resolutionList['postponed'] = '延期处理';
$lang->bug->resolutionList['willnotfix'] = "不予解决";
$lang->bug->resolutionList['tostory'] = '转为需求';
/* 统计报表。*/
$lang->bug->report->common = '统计报表';
$lang->bug->report->select = '请选择报表类型';
$lang->bug->report->create = '生成报表';
$lang->bug->report->selectAll = '全选';
$lang->bug->report->selectReverse = '反选';
$lang->bug->report->charts['bugsPerProject'] = '项目Bug数量';
$lang->bug->report->charts['bugsPerModule'] = '模块Bug数量';
$lang->bug->report->charts['openedBugsPerDay'] = '每天新增Bug数';
$lang->bug->report->charts['resolvedBugsPerDay'] = '每天解决Bug数';
$lang->bug->report->charts['closedBugsPerDay'] = '每天关闭的Bug数';
$lang->bug->report->charts['openedBugsPerUser'] = '每人提交的Bug数';
$lang->bug->report->charts['resolvedBugsPerUser'] = '每人解决的Bug数';
$lang->bug->report->charts['closedBugsPerUser'] = '每人关闭的Bug数';
$lang->bug->report->charts['bugsPerSeverity'] = 'Bug严重程度统计';
$lang->bug->report->charts['bugsPerResolution'] = 'Bug解决方案统计';
$lang->bug->report->charts['bugsPerStatus'] = 'Bug状态统计';
$lang->bug->report->charts['bugsPerActivatedCount'] = 'Bug激活次数统计';
$lang->bug->report->charts['bugsPerType'] = 'Bug类型统计';
$lang->bug->report->charts['bugsPerAssignedTo'] = '指派给统计';
//$lang->bug->report->charts['bugLiveDays'] = 'Bug处理时间统计';
//$lang->bug->report->charts['bugHistories'] = 'Bug处理步骤统计';
$lang->bug->report->options->swf = 'pie2d';
$lang->bug->report->options->width = 'auto';
$lang->bug->report->options->height = 300;
$lang->bug->report->options->graph->baseFontSize = 12;
$lang->bug->report->options->graph->showNames = 1;
$lang->bug->report->options->graph->formatNumber = 1;
$lang->bug->report->options->graph->decimalPrecision = 0;
$lang->bug->report->options->graph->animation = 0;
$lang->bug->report->options->graph->rotateNames = 0;
$lang->bug->report->options->graph->yAxisName = 'COUNT';
$lang->bug->report->options->graph->pieRadius = 100; // 饼图直径。
$lang->bug->report->options->graph->showColumnShadow = 0; // 是否显示柱状图阴影。
$lang->bug->report->bugsPerProject->graph->xAxisName = '项目';
$lang->bug->report->bugsPerModule->graph->xAxisName = '模块';
$lang->bug->report->openedBugsPerDay->swf = 'column2d';
$lang->bug->report->openedBugsPerDay->height = 400;
$lang->bug->report->openedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->openedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->resolvedBugsPerDay->swf = 'column2d';
$lang->bug->report->resolvedBugsPerDay->height = 400;
$lang->bug->report->resolvedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->resolvedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->closedBugsPerDay->swf = 'column2d';
$lang->bug->report->closedBugsPerDay->height = 400;
$lang->bug->report->closedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->closedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->openedBugsPerUser->graph->xAxisName = '用户';
$lang->bug->report->resolvedBugsPerUser->graph->xAxisName= '用户';
$lang->bug->report->closedBugsPerUser->graph->xAxisName = '用户';
$lang->bug->report->bugsPerSeverity->graph->xAxisName = '严重程度';
$lang->bug->report->bugsPerResolution->graph->xAxisName = '解决方案';
$lang->bug->report->bugsPerStatus->graph->xAxisName = '状态';
$lang->bug->report->bugsPerActivatedCount->graph->xAxisName = '激活次数';
$lang->bug->report->bugsPerType->graph->xAxisName = '类型';
$lang->bug->report->bugsPerAssignedTo->graph->xAxisName = '指派给';
$lang->bug->report->bugLiveDays->graph->xAxisName = '处理时间';
$lang->bug->report->bugHistories->graph->xAxisName = '处理步骤';
/* 操作记录。*/
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解决,方案为 <strong>$extra</strong>。', 'extra' => $lang->bug->resolutionList);
$lang->bug->action->tostory = array('main' => '$date, 由 <strong>$actor</strong> 转为<strong>需求</strong>,编号为 <strong>$extra</strong>。');
$lang->bug->action->totask = array('main' => '$date, 由 <strong>$actor</strong> 导入为<strong>任务</strong>,编号为 <strong>$extra</strong>。');

View File

@@ -1,312 +1,312 @@
<?php
/**
* The bug module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id: zh-tw.php 2484 2011-12-27 08:45:57Z shiyangyangwork@yahoo.cn $
* @link http://www.zentao.net
*/
/* 欄位列表。*/
$lang->bug->common = '缺陷管理';
$lang->bug->id = 'Bug編號';
$lang->bug->product = '所屬產品';
$lang->bug->module = '所屬模組';
$lang->bug->path = '模組路徑';
$lang->bug->project = '所屬項目';
$lang->bug->story = '相關需求';
$lang->bug->storyVersion = '需求版本';
$lang->bug->task = '相關任務';
$lang->bug->title = 'Bug標題';
$lang->bug->severity = '嚴重程度';
$lang->bug->severityAB = '級別';
$lang->bug->pri = '優先順序';
$lang->bug->type = 'Bug類型';
$lang->bug->os = '操作系統';
$lang->bug->hardware = '硬件平台';
$lang->bug->browser = '瀏覽器';
$lang->bug->machine = '機器硬件';
$lang->bug->found = '如何發現';
$lang->bug->steps = '重現步驟';
$lang->bug->status = 'Bug狀態';
$lang->bug->statusAB = '狀態';
$lang->bug->activatedCount = '激活次數';
$lang->bug->activatedCountAB = '激活次數';
$lang->bug->confirmed = '是否確認';
$lang->bug->toTask = '轉任務';
$lang->bug->toStory = '轉需求';
$lang->bug->mailto = '抄送給';
$lang->bug->openedBy = '由誰創建';
$lang->bug->openedByAB = '創建';
$lang->bug->openedDate = '創建日期';
$lang->bug->openedDateAB = '創建日期';
$lang->bug->openedBuild = '影響版本';
$lang->bug->assignedTo = '指派給';
$lang->bug->assignedDate = '指派日期';
$lang->bug->resolvedBy = '解決者';
$lang->bug->resolvedByAB = '解決';
$lang->bug->resolution = '解決方案';
$lang->bug->resolutionAB = '方案';
$lang->bug->resolvedBuild = '解決版本';
$lang->bug->resolvedDate = '解決日期';
$lang->bug->resolvedDateAB = '解決日期';
$lang->bug->closedBy = '由誰關閉';
$lang->bug->closedDate = '關閉日期';
$lang->bug->duplicateBug = '重複Bug';
$lang->bug->lastEditedBy = '最後修改者';
$lang->bug->lastEditedDate = '最後修改日期';
$lang->bug->linkBug = '相關Bug';
$lang->bug->case = '相關用例';
$lang->bug->files = '附件';
$lang->bug->keywords = '關鍵詞';
$lang->bug->lastEditedByAB = '修改者';
$lang->bug->lastEditedDateAB = '修改日期';
/* 方法列表。*/
$lang->bug->index = '首頁';
$lang->bug->create = '創建Bug';
$lang->bug->confirmBug = '確認';
$lang->bug->edit = '編輯Bug';
$lang->bug->browse = 'Bug列表';
$lang->bug->view = 'Bug詳情';
$lang->bug->resolve = '解決Bug';
$lang->bug->close = '關閉Bug';
$lang->bug->activate = '激活Bug';
$lang->bug->reportChart = '報表統計';
$lang->bug->export = '導出數據';
$lang->bug->delete = '刪除Bug';
$lang->bug->saveTemplate = '保存模板';
$lang->bug->deleteTemplate = '刪除模板';
$lang->bug->customFields = '自定義欄位';
$lang->bug->restoreDefault = '恢復預設';
$lang->bug->ajaxGetUserBugs = '介面:我的Bug';
$lang->bug->ajaxGetModuleOwner = '介面:獲得模組的預設指派人';
$lang->bug->confirmStoryChange = '確認需求變動';
/* 查詢條件列表。*/
$lang->bug->selectProduct = '請選擇產品';
$lang->bug->byModule = '按模組';
$lang->bug->assignToMe = '指派給我';
$lang->bug->openedByMe = '由我創建';
$lang->bug->resolvedByMe = '由我解決';
$lang->bug->closedByMe = '由我關閉';
$lang->bug->assignToNull = '未指派';
$lang->bug->unResolved = '未解決';
$lang->bug->unclosed = '未關閉';
$lang->bug->longLifeBugs = '久未處理';
$lang->bug->postponedBugs = '被延期';
$lang->bug->allBugs = '所有Bug';
$lang->bug->moduleBugs = '按模組瀏覽';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求變動';
$lang->bug->allProduct = '所有產品';
/* 頁面標籤。*/
$lang->bug->lblProductAndModule = '產品模組';
$lang->bug->lblProjectAndTask = '項目任務';
$lang->bug->lblStory = '相關需求';
$lang->bug->lblTypeAndSeverity = '類型/嚴重程度';
$lang->bug->lblSystemBrowserAndHardware = '系統/瀏覽器';
$lang->bug->lblAssignedTo = '當前指派';
$lang->bug->lblMailto = '抄送給';
$lang->bug->lblLastEdited = '最後修改';
$lang->bug->lblResolved = '由誰解決';
$lang->bug->lblAllFields = '所有欄位';
$lang->bug->lblCustomFields = '自定義欄位';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
$lang->bug->legendMailto = '抄送給';
$lang->bug->legendAttatch = '附件';
$lang->bug->legendLinkBugs = '相關Bug';
$lang->bug->legendPrjStoryTask = '項目/需求/任務';
$lang->bug->legendCases = '相關用例';
$lang->bug->legendSteps = '重現步驟';
$lang->bug->legendAction = '操作';
$lang->bug->legendHistory = '歷史記錄';
$lang->bug->legendComment = '備註';
$lang->bug->legendLife = 'BUG的一生';
$lang->bug->legendMisc = '其相關他';
/* 功能按鈕。*/
$lang->bug->buttonConfirm = '確認';
$lang->bug->buttonCopy = '複製';
$lang->bug->buttonEdit = '編輯';
$lang->bug->buttonActivate = '激活';
$lang->bug->buttonResolve = '解決';
$lang->bug->buttonClose = '關閉';
$lang->bug->buttonToList = '返回';
$lang->bug->buttonCreateTestcase = '建用例';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = '修改產品會導致相應的項目、需求和任務發生變化,確定嗎?';
$lang->bug->confirmDelete = '您確認要刪除該Bug嗎';
$lang->bug->setTemplateTitle = '請輸入bug模板標題保存之前請先填寫bug重現步驟';
$lang->bug->remindTask = '該Bug已經轉化為任務是否更新任務(編號:%s)狀態 ?';
/* 模板。*/
$lang->bug->tplStep = "<p>[步驟]</p>";
$lang->bug->tplResult = "<p>[結果]</p>";
$lang->bug->tplExpect = "<p>[期望]</p>";
/* 各個欄位取值列表。*/
$lang->bug->severityList[3] = '3';
$lang->bug->severityList[1] = '1';
$lang->bug->severityList[2] = '2';
$lang->bug->severityList[4] = '4';
$lang->bug->priList[0] = '';
$lang->bug->priList[3] = '3';
$lang->bug->priList[1] = '1';
$lang->bug->priList[2] = '2';
$lang->bug->priList[4] = '4';
$lang->bug->osList[''] = '';
$lang->bug->osList['all'] = '全部';
$lang->bug->osList['windows'] = 'Windows';
$lang->bug->osList['winxp'] = 'Windows XP';
$lang->bug->osList['win7'] = 'Windows 7';
$lang->bug->osList['vista'] = 'Windows Vista';
$lang->bug->osList['win2000'] = 'Windows 2000';
$lang->bug->osList['win2003'] = 'Windows 2003';
$lang->bug->osList['win2008'] = 'Windows 2008';
$lang->bug->osList['winnt'] = 'Windows NT';
$lang->bug->osList['win98'] = 'Windows 98';
$lang->bug->osList['andriod'] = 'Andriod';
$lang->bug->osList['ios'] = 'IOS';
$lang->bug->osList['wp7'] = 'WP7';
$lang->bug->osList['symbian'] = 'Symbian';
$lang->bug->osList['linux'] = 'Linux';
$lang->bug->osList['freebsd'] = 'FreeBSD';
$lang->bug->osList['mac'] = 'Mac OS';
$lang->bug->osList['unix'] = 'Unix';
$lang->bug->osList['others'] = '其他';
$lang->bug->browserList[''] = '';
$lang->bug->browserList['all'] = '全部';
$lang->bug->browserList['ie'] = 'IE系列';
$lang->bug->browserList['ie8'] = 'IE8';
$lang->bug->browserList['ie9'] = 'IE9';
$lang->bug->browserList['ie6'] = 'IE6';
$lang->bug->browserList['ie7'] = 'IE7';
$lang->bug->browserList['chrome'] = 'chrome';
$lang->bug->browserList['firefox'] = 'firefox系列';
$lang->bug->browserList['firefox2'] = 'firefox2';
$lang->bug->browserList['firefox3'] = 'firefox3';
$lang->bug->browserList['firefox4'] = 'firefox4';
$lang->bug->browserList['opera'] = 'opera系列';
$lang->bug->browserList['opera9'] = 'opera9';
$lang->bug->browserList['oprea10'] = 'opera10';
$lang->bug->browserList['oprea11'] = 'opera11';
$lang->bug->browserList['safari'] = 'safari';
$lang->bug->browserList['maxthon'] = '傲游';
$lang->bug->browserList['uc'] = 'UC';
$lang->bug->browserList['other'] = '其他';
$lang->bug->typeList[''] = '';
$lang->bug->typeList['codeerror'] = '代碼錯誤';
$lang->bug->typeList['interface'] = '界面優化';
$lang->bug->typeList['designchange'] = '設計變更';
$lang->bug->typeList['newfeature'] = '新增需求';
$lang->bug->typeList['designdefect'] = '設計缺陷';
$lang->bug->typeList['config'] = '配置相關';
$lang->bug->typeList['install'] = '安裝部署';
$lang->bug->typeList['security'] = '安全相關';
$lang->bug->typeList['performance'] = '性能問題';
$lang->bug->typeList['standard'] = '標準規範';
$lang->bug->typeList['automation'] = '測試腳本';
$lang->bug->typeList['trackthings'] = '事務跟蹤';
$lang->bug->typeList['others'] = '其他';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = '激活';
$lang->bug->statusList['resolved'] = '已解決';
$lang->bug->statusList['closed'] = '已關閉';
$lang->bug->confirmedList[1] = '已確認';
$lang->bug->confirmedList[0] = '未確認';
$lang->bug->resolutionList[''] = '';
$lang->bug->resolutionList['bydesign'] = '設計如此';
$lang->bug->resolutionList['duplicate'] = '重複Bug';
$lang->bug->resolutionList['external'] = '外部原因';
$lang->bug->resolutionList['fixed'] = '已解決';
$lang->bug->resolutionList['notrepro'] = '無法重現';
$lang->bug->resolutionList['postponed'] = '延期處理';
$lang->bug->resolutionList['willnotfix'] = "不予解決";
$lang->bug->resolutionList['tostory'] = '轉為需求';
/* 統計報表。*/
$lang->bug->report->common = '統計報表';
$lang->bug->report->select = '請選擇報表類型';
$lang->bug->report->create = '生成報表';
$lang->bug->report->selectAll = '全選';
$lang->bug->report->selectReverse = '反選';
$lang->bug->report->charts['bugsPerProject'] = '項目Bug數量';
$lang->bug->report->charts['bugsPerModule'] = '模組Bug數量';
$lang->bug->report->charts['openedBugsPerDay'] = '每天新增Bug數';
$lang->bug->report->charts['resolvedBugsPerDay'] = '每天解決Bug數';
$lang->bug->report->charts['closedBugsPerDay'] = '每天關閉的Bug數';
$lang->bug->report->charts['openedBugsPerUser'] = '每人提交的Bug數';
$lang->bug->report->charts['resolvedBugsPerUser'] = '每人解決的Bug數';
$lang->bug->report->charts['closedBugsPerUser'] = '每人關閉的Bug數';
$lang->bug->report->charts['bugsPerSeverity'] = 'Bug嚴重程度統計';
$lang->bug->report->charts['bugsPerResolution'] = 'Bug解決方案統計';
$lang->bug->report->charts['bugsPerStatus'] = 'Bug狀態統計';
$lang->bug->report->charts['bugsPerActivatedCount'] = 'Bug激活次數統計';
$lang->bug->report->charts['bugsPerType'] = 'Bug類型統計';
$lang->bug->report->charts['bugsPerAssignedTo'] = '指派給統計';
//$lang->bug->report->charts['bugLiveDays'] = 'Bug處理時間統計';
//$lang->bug->report->charts['bugHistories'] = 'Bug處理步驟統計';
$lang->bug->report->options->swf = 'pie2d';
$lang->bug->report->options->width = 'auto';
$lang->bug->report->options->height = 300;
$lang->bug->report->options->graph->baseFontSize = 12;
$lang->bug->report->options->graph->showNames = 1;
$lang->bug->report->options->graph->formatNumber = 1;
$lang->bug->report->options->graph->decimalPrecision = 0;
$lang->bug->report->options->graph->animation = 0;
$lang->bug->report->options->graph->rotateNames = 0;
$lang->bug->report->options->graph->yAxisName = 'COUNT';
$lang->bug->report->options->graph->pieRadius = 100; // 餅圖直徑。
$lang->bug->report->options->graph->showColumnShadow = 0; // 是否顯示柱狀圖陰影。
$lang->bug->report->bugsPerProject->graph->xAxisName = '項目';
$lang->bug->report->bugsPerModule->graph->xAxisName = '模組';
$lang->bug->report->openedBugsPerDay->swf = 'column2d';
$lang->bug->report->openedBugsPerDay->height = 400;
$lang->bug->report->openedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->openedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->resolvedBugsPerDay->swf = 'column2d';
$lang->bug->report->resolvedBugsPerDay->height = 400;
$lang->bug->report->resolvedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->resolvedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->closedBugsPerDay->swf = 'column2d';
$lang->bug->report->closedBugsPerDay->height = 400;
$lang->bug->report->closedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->closedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->openedBugsPerUser->graph->xAxisName = '用戶';
$lang->bug->report->resolvedBugsPerUser->graph->xAxisName= '用戶';
$lang->bug->report->closedBugsPerUser->graph->xAxisName = '用戶';
$lang->bug->report->bugsPerSeverity->graph->xAxisName = '嚴重程度';
$lang->bug->report->bugsPerResolution->graph->xAxisName = '解決方案';
$lang->bug->report->bugsPerStatus->graph->xAxisName = '狀態';
$lang->bug->report->bugsPerActivatedCount->graph->xAxisName = '激活次數';
$lang->bug->report->bugsPerType->graph->xAxisName = '類型';
$lang->bug->report->bugsPerAssignedTo->graph->xAxisName = '指派給';
$lang->bug->report->bugLiveDays->graph->xAxisName = '處理時間';
$lang->bug->report->bugHistories->graph->xAxisName = '處理步驟';
/* 操作記錄。*/
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解決,方案為 <strong>$extra</strong>。', 'extra' => $lang->bug->resolutionList);
$lang->bug->action->tostory = array('main' => '$date, 由 <strong>$actor</strong> 轉為<strong>需求</strong>,編號為 <strong>$extra</strong>。');
$lang->bug->action->totask = array('main' => '$date, 由 <strong>$actor</strong> 導入為<strong>任務</strong>,編號為 <strong>$extra</strong>。');
<?php
/**
* The bug module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id: zh-tw.php 2484 2011-12-27 08:45:57Z shiyangyangwork@yahoo.cn $
* @link http://www.zentao.net
*/
/* 欄位列表。*/
$lang->bug->common = '缺陷管理';
$lang->bug->id = 'Bug編號';
$lang->bug->product = '所屬產品';
$lang->bug->module = '所屬模組';
$lang->bug->path = '模組路徑';
$lang->bug->project = '所屬項目';
$lang->bug->story = '相關需求';
$lang->bug->storyVersion = '需求版本';
$lang->bug->task = '相關任務';
$lang->bug->title = 'Bug標題';
$lang->bug->severity = '嚴重程度';
$lang->bug->severityAB = '級別';
$lang->bug->pri = '優先順序';
$lang->bug->type = 'Bug類型';
$lang->bug->os = '操作系統';
$lang->bug->hardware = '硬件平台';
$lang->bug->browser = '瀏覽器';
$lang->bug->machine = '機器硬件';
$lang->bug->found = '如何發現';
$lang->bug->steps = '重現步驟';
$lang->bug->status = 'Bug狀態';
$lang->bug->statusAB = '狀態';
$lang->bug->activatedCount = '激活次數';
$lang->bug->activatedCountAB = '激活次數';
$lang->bug->confirmed = '是否確認';
$lang->bug->toTask = '轉任務';
$lang->bug->toStory = '轉需求';
$lang->bug->mailto = '抄送給';
$lang->bug->openedBy = '由誰創建';
$lang->bug->openedByAB = '創建';
$lang->bug->openedDate = '創建日期';
$lang->bug->openedDateAB = '創建日期';
$lang->bug->openedBuild = '影響版本';
$lang->bug->assignedTo = '指派給';
$lang->bug->assignedDate = '指派日期';
$lang->bug->resolvedBy = '解決者';
$lang->bug->resolvedByAB = '解決';
$lang->bug->resolution = '解決方案';
$lang->bug->resolutionAB = '方案';
$lang->bug->resolvedBuild = '解決版本';
$lang->bug->resolvedDate = '解決日期';
$lang->bug->resolvedDateAB = '解決日期';
$lang->bug->closedBy = '由誰關閉';
$lang->bug->closedDate = '關閉日期';
$lang->bug->duplicateBug = '重複Bug';
$lang->bug->lastEditedBy = '最後修改者';
$lang->bug->lastEditedDate = '最後修改日期';
$lang->bug->linkBug = '相關Bug';
$lang->bug->case = '相關用例';
$lang->bug->files = '附件';
$lang->bug->keywords = '關鍵詞';
$lang->bug->lastEditedByAB = '修改者';
$lang->bug->lastEditedDateAB = '修改日期';
/* 方法列表。*/
$lang->bug->index = '首頁';
$lang->bug->create = '創建Bug';
$lang->bug->confirmBug = '確認';
$lang->bug->edit = '編輯Bug';
$lang->bug->browse = 'Bug列表';
$lang->bug->view = 'Bug詳情';
$lang->bug->resolve = '解決Bug';
$lang->bug->close = '關閉Bug';
$lang->bug->activate = '激活Bug';
$lang->bug->reportChart = '報表統計';
$lang->bug->export = '導出數據';
$lang->bug->delete = '刪除Bug';
$lang->bug->saveTemplate = '保存模板';
$lang->bug->deleteTemplate = '刪除模板';
$lang->bug->customFields = '自定義欄位';
$lang->bug->restoreDefault = '恢復預設';
$lang->bug->ajaxGetUserBugs = '介面:我的Bug';
$lang->bug->ajaxGetModuleOwner = '介面:獲得模組的預設指派人';
$lang->bug->confirmStoryChange = '確認需求變動';
/* 查詢條件列表。*/
$lang->bug->selectProduct = '請選擇產品';
$lang->bug->byModule = '按模組';
$lang->bug->assignToMe = '指派給我';
$lang->bug->openedByMe = '由我創建';
$lang->bug->resolvedByMe = '由我解決';
$lang->bug->closedByMe = '由我關閉';
$lang->bug->assignToNull = '未指派';
$lang->bug->unResolved = '未解決';
$lang->bug->unclosed = '未關閉';
$lang->bug->longLifeBugs = '久未處理';
$lang->bug->postponedBugs = '被延期';
$lang->bug->allBugs = '所有Bug';
$lang->bug->moduleBugs = '按模組瀏覽';
$lang->bug->byQuery = '搜索';
$lang->bug->needConfirm = '需求變動';
$lang->bug->allProduct = '所有產品';
/* 頁面標籤。*/
$lang->bug->lblProductAndModule = '產品模組';
$lang->bug->lblProjectAndTask = '項目任務';
$lang->bug->lblStory = '相關需求';
$lang->bug->lblTypeAndSeverity = '類型/嚴重程度';
$lang->bug->lblSystemBrowserAndHardware = '系統/瀏覽器';
$lang->bug->lblAssignedTo = '當前指派';
$lang->bug->lblMailto = '抄送給';
$lang->bug->lblLastEdited = '最後修改';
$lang->bug->lblResolved = '由誰解決';
$lang->bug->lblAllFields = '所有欄位';
$lang->bug->lblCustomFields = '自定義欄位';
/* legend列表。*/
$lang->bug->legendBasicInfo = '基本信息';
$lang->bug->legendMailto = '抄送給';
$lang->bug->legendAttatch = '附件';
$lang->bug->legendLinkBugs = '相關Bug';
$lang->bug->legendPrjStoryTask = '項目/需求/任務';
$lang->bug->legendCases = '相關用例';
$lang->bug->legendSteps = '重現步驟';
$lang->bug->legendAction = '操作';
$lang->bug->legendHistory = '歷史記錄';
$lang->bug->legendComment = '備註';
$lang->bug->legendLife = 'BUG的一生';
$lang->bug->legendMisc = '其相關他';
/* 功能按鈕。*/
$lang->bug->buttonConfirm = '確認';
$lang->bug->buttonCopy = '複製';
$lang->bug->buttonEdit = '編輯';
$lang->bug->buttonActivate = '激活';
$lang->bug->buttonResolve = '解決';
$lang->bug->buttonClose = '關閉';
$lang->bug->buttonToList = '返回';
$lang->bug->buttonCreateTestcase = '建用例';
/* 交互提示。*/
$lang->bug->confirmChangeProduct = '修改產品會導致相應的項目、需求和任務發生變化,確定嗎?';
$lang->bug->confirmDelete = '您確認要刪除該Bug嗎';
$lang->bug->setTemplateTitle = '請輸入bug模板標題保存之前請先填寫bug重現步驟';
$lang->bug->remindTask = '該Bug已經轉化為任務是否更新任務(編號:%s)狀態 ?';
/* 模板。*/
$lang->bug->tplStep = "<p>[步驟]</p>";
$lang->bug->tplResult = "<p>[結果]</p>";
$lang->bug->tplExpect = "<p>[期望]</p>";
/* 各個欄位取值列表。*/
$lang->bug->severityList[3] = '3';
$lang->bug->severityList[1] = '1';
$lang->bug->severityList[2] = '2';
$lang->bug->severityList[4] = '4';
$lang->bug->priList[0] = '';
$lang->bug->priList[3] = '3';
$lang->bug->priList[1] = '1';
$lang->bug->priList[2] = '2';
$lang->bug->priList[4] = '4';
$lang->bug->osList[''] = '';
$lang->bug->osList['all'] = '全部';
$lang->bug->osList['windows'] = 'Windows';
$lang->bug->osList['winxp'] = 'Windows XP';
$lang->bug->osList['win7'] = 'Windows 7';
$lang->bug->osList['vista'] = 'Windows Vista';
$lang->bug->osList['win2000'] = 'Windows 2000';
$lang->bug->osList['win2003'] = 'Windows 2003';
$lang->bug->osList['win2008'] = 'Windows 2008';
$lang->bug->osList['winnt'] = 'Windows NT';
$lang->bug->osList['win98'] = 'Windows 98';
$lang->bug->osList['andriod'] = 'Andriod';
$lang->bug->osList['ios'] = 'IOS';
$lang->bug->osList['wp7'] = 'WP7';
$lang->bug->osList['symbian'] = 'Symbian';
$lang->bug->osList['linux'] = 'Linux';
$lang->bug->osList['freebsd'] = 'FreeBSD';
$lang->bug->osList['mac'] = 'Mac OS';
$lang->bug->osList['unix'] = 'Unix';
$lang->bug->osList['others'] = '其他';
$lang->bug->browserList[''] = '';
$lang->bug->browserList['all'] = '全部';
$lang->bug->browserList['ie'] = 'IE系列';
$lang->bug->browserList['ie8'] = 'IE8';
$lang->bug->browserList['ie9'] = 'IE9';
$lang->bug->browserList['ie6'] = 'IE6';
$lang->bug->browserList['ie7'] = 'IE7';
$lang->bug->browserList['chrome'] = 'chrome';
$lang->bug->browserList['firefox'] = 'firefox系列';
$lang->bug->browserList['firefox2'] = 'firefox2';
$lang->bug->browserList['firefox3'] = 'firefox3';
$lang->bug->browserList['firefox4'] = 'firefox4';
$lang->bug->browserList['opera'] = 'opera系列';
$lang->bug->browserList['opera9'] = 'opera9';
$lang->bug->browserList['oprea10'] = 'opera10';
$lang->bug->browserList['oprea11'] = 'opera11';
$lang->bug->browserList['safari'] = 'safari';
$lang->bug->browserList['maxthon'] = '傲游';
$lang->bug->browserList['uc'] = 'UC';
$lang->bug->browserList['other'] = '其他';
$lang->bug->typeList[''] = '';
$lang->bug->typeList['codeerror'] = '代碼錯誤';
$lang->bug->typeList['interface'] = '界面優化';
$lang->bug->typeList['designchange'] = '設計變更';
$lang->bug->typeList['newfeature'] = '新增需求';
$lang->bug->typeList['designdefect'] = '設計缺陷';
$lang->bug->typeList['config'] = '配置相關';
$lang->bug->typeList['install'] = '安裝部署';
$lang->bug->typeList['security'] = '安全相關';
$lang->bug->typeList['performance'] = '性能問題';
$lang->bug->typeList['standard'] = '標準規範';
$lang->bug->typeList['automation'] = '測試腳本';
$lang->bug->typeList['trackthings'] = '事務跟蹤';
$lang->bug->typeList['others'] = '其他';
$lang->bug->statusList[''] = '';
$lang->bug->statusList['active'] = '激活';
$lang->bug->statusList['resolved'] = '已解決';
$lang->bug->statusList['closed'] = '已關閉';
$lang->bug->confirmedList[1] = '已確認';
$lang->bug->confirmedList[0] = '未確認';
$lang->bug->resolutionList[''] = '';
$lang->bug->resolutionList['bydesign'] = '設計如此';
$lang->bug->resolutionList['duplicate'] = '重複Bug';
$lang->bug->resolutionList['external'] = '外部原因';
$lang->bug->resolutionList['fixed'] = '已解決';
$lang->bug->resolutionList['notrepro'] = '無法重現';
$lang->bug->resolutionList['postponed'] = '延期處理';
$lang->bug->resolutionList['willnotfix'] = "不予解決";
$lang->bug->resolutionList['tostory'] = '轉為需求';
/* 統計報表。*/
$lang->bug->report->common = '統計報表';
$lang->bug->report->select = '請選擇報表類型';
$lang->bug->report->create = '生成報表';
$lang->bug->report->selectAll = '全選';
$lang->bug->report->selectReverse = '反選';
$lang->bug->report->charts['bugsPerProject'] = '項目Bug數量';
$lang->bug->report->charts['bugsPerModule'] = '模組Bug數量';
$lang->bug->report->charts['openedBugsPerDay'] = '每天新增Bug數';
$lang->bug->report->charts['resolvedBugsPerDay'] = '每天解決Bug數';
$lang->bug->report->charts['closedBugsPerDay'] = '每天關閉的Bug數';
$lang->bug->report->charts['openedBugsPerUser'] = '每人提交的Bug數';
$lang->bug->report->charts['resolvedBugsPerUser'] = '每人解決的Bug數';
$lang->bug->report->charts['closedBugsPerUser'] = '每人關閉的Bug數';
$lang->bug->report->charts['bugsPerSeverity'] = 'Bug嚴重程度統計';
$lang->bug->report->charts['bugsPerResolution'] = 'Bug解決方案統計';
$lang->bug->report->charts['bugsPerStatus'] = 'Bug狀態統計';
$lang->bug->report->charts['bugsPerActivatedCount'] = 'Bug激活次數統計';
$lang->bug->report->charts['bugsPerType'] = 'Bug類型統計';
$lang->bug->report->charts['bugsPerAssignedTo'] = '指派給統計';
//$lang->bug->report->charts['bugLiveDays'] = 'Bug處理時間統計';
//$lang->bug->report->charts['bugHistories'] = 'Bug處理步驟統計';
$lang->bug->report->options->swf = 'pie2d';
$lang->bug->report->options->width = 'auto';
$lang->bug->report->options->height = 300;
$lang->bug->report->options->graph->baseFontSize = 12;
$lang->bug->report->options->graph->showNames = 1;
$lang->bug->report->options->graph->formatNumber = 1;
$lang->bug->report->options->graph->decimalPrecision = 0;
$lang->bug->report->options->graph->animation = 0;
$lang->bug->report->options->graph->rotateNames = 0;
$lang->bug->report->options->graph->yAxisName = 'COUNT';
$lang->bug->report->options->graph->pieRadius = 100; // 餅圖直徑。
$lang->bug->report->options->graph->showColumnShadow = 0; // 是否顯示柱狀圖陰影。
$lang->bug->report->bugsPerProject->graph->xAxisName = '項目';
$lang->bug->report->bugsPerModule->graph->xAxisName = '模組';
$lang->bug->report->openedBugsPerDay->swf = 'column2d';
$lang->bug->report->openedBugsPerDay->height = 400;
$lang->bug->report->openedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->openedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->resolvedBugsPerDay->swf = 'column2d';
$lang->bug->report->resolvedBugsPerDay->height = 400;
$lang->bug->report->resolvedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->resolvedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->closedBugsPerDay->swf = 'column2d';
$lang->bug->report->closedBugsPerDay->height = 400;
$lang->bug->report->closedBugsPerDay->graph->xAxisName = '日期';
$lang->bug->report->closedBugsPerDay->graph->rotateNames = 1;
$lang->bug->report->openedBugsPerUser->graph->xAxisName = '用戶';
$lang->bug->report->resolvedBugsPerUser->graph->xAxisName= '用戶';
$lang->bug->report->closedBugsPerUser->graph->xAxisName = '用戶';
$lang->bug->report->bugsPerSeverity->graph->xAxisName = '嚴重程度';
$lang->bug->report->bugsPerResolution->graph->xAxisName = '解決方案';
$lang->bug->report->bugsPerStatus->graph->xAxisName = '狀態';
$lang->bug->report->bugsPerActivatedCount->graph->xAxisName = '激活次數';
$lang->bug->report->bugsPerType->graph->xAxisName = '類型';
$lang->bug->report->bugsPerAssignedTo->graph->xAxisName = '指派給';
$lang->bug->report->bugLiveDays->graph->xAxisName = '處理時間';
$lang->bug->report->bugHistories->graph->xAxisName = '處理步驟';
/* 操作記錄。*/
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解決,方案為 <strong>$extra</strong>。', 'extra' => $lang->bug->resolutionList);
$lang->bug->action->tostory = array('main' => '$date, 由 <strong>$actor</strong> 轉為<strong>需求</strong>,編號為 <strong>$extra</strong>。');
$lang->bug->action->totask = array('main' => '$date, 由 <strong>$actor</strong> 導入為<strong>任務</strong>,編號為 <strong>$extra</strong>。');

File diff suppressed because it is too large Load Diff

View File

@@ -1,43 +1,43 @@
<?php
/**
* The activate file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->bug->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $bug->resolvedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->openedBuild;?></td>
<td><?php echo html::select('openedBuild[]', $builds, $bug->openedBuild, 'size=4 multiple=multiple class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->files;?></th>
<td class='a-left'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton();?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The activate file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->bug->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $bug->resolvedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->openedBuild;?></td>
<td><?php echo html::select('openedBuild[]', $builds, $bug->openedBuild, 'size=4 multiple=multiple class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->files;?></th>
<td class='a-left'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton();?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,175 +1,175 @@
<?php
/**
* The browse view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<script language='Javascript'>
var browseType = '<?php echo $browseType;?>';
var moduleID = '<?php echo $moduleID;?>';
var customed = <?php echo (int)$customed;?>;
</script>
<div id='featurebar'>
<div class='f-left'>
<?php
echo "<span id='bymoduleTab' onclick=\"browseByModule('$browseType')\"><a href='#'>" . $lang->bug->moduleBugs . "</a></span> ";
echo "<span id='assigntomeTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=assignToMe&param=0"), $lang->bug->assignToMe) . "</span>";
echo "<span id='openedbymeTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=openedByMe&param=0"), $lang->bug->openedByMe) . "</span>";
echo "<span id='resolvedbymeTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=resolvedByMe&param=0"), $lang->bug->resolvedByMe) . "</span>";
echo "<span id='assigntonullTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=assignToNull&param=0"), $lang->bug->assignToNull) . "</span>";
echo "<span id='unresolvedTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=unResolved&param=0"), $lang->bug->unResolved) . "</span>";
echo "<span id='unclosedTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=unclosed&param=0"), $lang->bug->unclosed) . "</span>";
echo "<span id='longlifebugsTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=longLifeBugs&param=0"), $lang->bug->longLifeBugs) . "</span>";
echo "<span id='postponedbugsTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=postponedBugs&param=0"), $lang->bug->postponedBugs) . "</span>";
echo "<span id='allTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=all&param=0&orderBy=$orderBy&recTotal=0&recPerPage=200"), $lang->bug->allBugs) . "</span>";
echo "<span id='needconfirmTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=needconfirm&param=0"), $lang->bug->needConfirm) . "</span>";
echo "<span id='bysearchTab'><a href='#'>{$lang->bug->byQuery}</a></span> ";
?>
</div>
<div class='f-right'>
<?php if($browseType != 'needconfirm') common::printLink('bug', 'export', "productID=$productID&orderBy=$orderBy", $lang->export, '', 'class="export"'); ?>
<?php common::printLink('bug', 'customFields', '', $lang->bug->customFields, '', "class='iframe'"); ?>
<?php common::printLink('bug', 'report', "productID=$productID&browseType=$browseType&moduleID=$moduleID", $lang->bug->report->common); ?>
<?php common::printLink('bug', 'create', "productID=$productID&extra=moduleID=$moduleID", $lang->bug->create); ?>
</div>
</div>
<div id='querybox' class='<?php if($browseType !='bysearch') echo 'hidden';?>'><?php echo $searchForm;?></div>
<?php if($customed){include 'browse.custom.html.php'; exit;}?>
<table class='cont-lt1'>
<tr valign='top'>
<td class='side <?php echo $treeClass;?>' id='treebox'>
<div class='box-title'><?php echo $productName;?></div>
<div class='box-content'>
<?php echo $moduleTree;?>
<div class='a-right'>
<?php if(common::hasPriv('tree', 'browse')) echo html::a($this->createLink('tree', 'browse', "productID=$productID&view=bug"), $lang->tree->manage);?>
</div>
</div>
</td>
<td class='divider <?php echo $treeClass;?>'></td>
<td>
<?php $vars = "productID=$productID&browseType=$browseType&param=$param&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<table class='table-1 fixed colored tablesorter datatable'>
<thead>
<tr class='colhead'>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='w-severity'> <?php common::printOrderLink('severity', $orderBy, $vars, $lang->bug->severityAB);?></th>
<th class='w-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th><?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<th class='w-80px'><?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->statusAB);?></th>
<?php endif;?>
<?php if($browseType == 'needconfirm'):?>
<th class='w-p40'><?php common::printOrderLink('story', $orderBy, $vars, $lang->bug->story);?></th>
<th class='w-50px'><?php echo $lang->actions;?></th>
<?php else:?>
<th class='w-user'><?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<th class='w-date'> <?php common::printOrderLink('openedDate', $orderBy, $vars, $lang->bug->openedDateAB);?></th>
<?php endif;?>
<th class='w-user'><?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='w-user'><?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedByAB);?></th>
<th class='w-resolution'><?php common::printOrderLink('resolution', $orderBy, $vars, $lang->bug->resolutionAB);?></th>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<th class='w-date'> <?php common::printOrderLink('resolvedDate', $orderBy, $vars, $lang->bug->resolvedDateAB);?></th>
<?php endif;?>
<th class='w-140px {sorter:false}'><?php echo $lang->actions;?></th>
<?php endif;?>
</tr>
</thead>
<tbody>
<?php foreach($bugs as $bug):?>
<?php $bugLink = inlink('view', "bugID=$bug->id");?>
<tr class='a-center'>
<?php $class = $bug->status == 'active' ? 'active' . $bug->severity : $bug->status;?>
<td class='linkbox <?php echo $class;?>'><?php echo html::a($bugLink, sprintf('%03d', $bug->id));?></td>
<td><?php echo $lang->bug->severityList[$bug->severity]?></td>
<td><?php echo $lang->bug->priList[$bug->pri]?></td>
<?php $class = 'confirm' . $bug->confirmed;?>
<td class='a-left nobr'><?php echo "<span class='$class'>[{$lang->bug->confirmedList[$bug->confirmed]}] </span>" . html::a($bugLink, $bug->title);?></td>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
<?php endif;?>
<?php if($browseType == 'needconfirm'):?>
<td class='a-left nobr'><?php echo html::a($this->createLink('story', 'view', "stoyID=$bug->story"), $bug->storyTitle, '_blank');?></td>
<td><?php echo html::a(inlink('confirmStoryChange', "bugID=$bug->id"), $lang->confirm, 'hiddenwin')?></td>
<?php else:?>
<td><?php echo $users[$bug->openedBy];?></td>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<?php endif;?>
<td <?php if($bug->assignedTo == $this->app->user->account) echo 'class="red"';?>><?php echo $users[$bug->assignedTo];?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo $lang->bug->resolutionList[$bug->resolution];?></td>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
<?php endif;?>
<td>
<?php
$params = "bugID=$bug->id";
if(!($bug->status == 'active' and common::printLink('bug', 'resolve', $params, $lang->bug->buttonResolve))) echo $lang->bug->buttonResolve . ' ';
if(!($bug->status == 'resolved' and common::printLink('bug', 'close', $params, $lang->bug->buttonClose))) echo $lang->bug->buttonClose . ' ';
common::printLink('bug', 'edit', $params, $lang->bug->buttonEdit);
if($this->cookie->windowWidth >= $this->config->wideSize) common::printLink('bug', 'create', "product=$bug->product&extra=bugID=$bug->id", $lang->bug->buttonCopy);
?>
</td>
<?php endif;?>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<?php $columns = $this->cookie->windowWidth > $this->config->wideSize ? 12 : 9;?>
<td colspan='<?php echo $columns;?>'>
<div class='f-left'>
<?php
foreach($lang->bug->statusList as $status => $label)
{
if($status != 'active')
{
echo "<span class='$status'> $label </span> ";
continue;
}
rsort($this->lang->bug->severityList);
foreach($this->lang->bug->severityList as $severity)
{
echo "<span class='$status$severity'> {$lang->bug->severity}:$severity </span> ";
}
}
?>
</div>
<div class='f-right'><?php $pager->show();?></div>
</td>
</tr>
</tfoot>
</table>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The browse view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<script language='Javascript'>
var browseType = '<?php echo $browseType;?>';
var moduleID = '<?php echo $moduleID;?>';
var customed = <?php echo (int)$customed;?>;
</script>
<div id='featurebar'>
<div class='f-left'>
<?php
echo "<span id='bymoduleTab' onclick=\"browseByModule('$browseType')\"><a href='#'>" . $lang->bug->moduleBugs . "</a></span> ";
echo "<span id='assigntomeTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=assignToMe&param=0"), $lang->bug->assignToMe) . "</span>";
echo "<span id='openedbymeTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=openedByMe&param=0"), $lang->bug->openedByMe) . "</span>";
echo "<span id='resolvedbymeTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=resolvedByMe&param=0"), $lang->bug->resolvedByMe) . "</span>";
echo "<span id='assigntonullTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=assignToNull&param=0"), $lang->bug->assignToNull) . "</span>";
echo "<span id='unresolvedTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=unResolved&param=0"), $lang->bug->unResolved) . "</span>";
echo "<span id='unclosedTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=unclosed&param=0"), $lang->bug->unclosed) . "</span>";
echo "<span id='longlifebugsTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=longLifeBugs&param=0"), $lang->bug->longLifeBugs) . "</span>";
echo "<span id='postponedbugsTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=postponedBugs&param=0"), $lang->bug->postponedBugs) . "</span>";
echo "<span id='allTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=all&param=0&orderBy=$orderBy&recTotal=0&recPerPage=200"), $lang->bug->allBugs) . "</span>";
echo "<span id='needconfirmTab'>" . html::a($this->createLink('bug', 'browse', "productid=$productID&browseType=needconfirm&param=0"), $lang->bug->needConfirm) . "</span>";
echo "<span id='bysearchTab'><a href='#'>{$lang->bug->byQuery}</a></span> ";
?>
</div>
<div class='f-right'>
<?php if($browseType != 'needconfirm') common::printLink('bug', 'export', "productID=$productID&orderBy=$orderBy", $lang->export, '', 'class="export"'); ?>
<?php common::printLink('bug', 'customFields', '', $lang->bug->customFields, '', "class='iframe'"); ?>
<?php common::printLink('bug', 'report', "productID=$productID&browseType=$browseType&moduleID=$moduleID", $lang->bug->report->common); ?>
<?php common::printLink('bug', 'create', "productID=$productID&extra=moduleID=$moduleID", $lang->bug->create); ?>
</div>
</div>
<div id='querybox' class='<?php if($browseType !='bysearch') echo 'hidden';?>'><?php echo $searchForm;?></div>
<?php if($customed){include 'browse.custom.html.php'; exit;}?>
<table class='cont-lt1'>
<tr valign='top'>
<td class='side <?php echo $treeClass;?>' id='treebox'>
<div class='box-title'><?php echo $productName;?></div>
<div class='box-content'>
<?php echo $moduleTree;?>
<div class='a-right'>
<?php if(common::hasPriv('tree', 'browse')) echo html::a($this->createLink('tree', 'browse', "productID=$productID&view=bug"), $lang->tree->manage);?>
</div>
</div>
</td>
<td class='divider <?php echo $treeClass;?>'></td>
<td>
<?php $vars = "productID=$productID&browseType=$browseType&param=$param&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<table class='table-1 fixed colored tablesorter datatable'>
<thead>
<tr class='colhead'>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='w-severity'> <?php common::printOrderLink('severity', $orderBy, $vars, $lang->bug->severityAB);?></th>
<th class='w-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th><?php common::printOrderLink('title', $orderBy, $vars, $lang->bug->title);?></th>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<th class='w-80px'><?php common::printOrderLink('status', $orderBy, $vars, $lang->bug->statusAB);?></th>
<?php endif;?>
<?php if($browseType == 'needconfirm'):?>
<th class='w-p40'><?php common::printOrderLink('story', $orderBy, $vars, $lang->bug->story);?></th>
<th class='w-50px'><?php echo $lang->actions;?></th>
<?php else:?>
<th class='w-user'><?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<th class='w-date'> <?php common::printOrderLink('openedDate', $orderBy, $vars, $lang->bug->openedDateAB);?></th>
<?php endif;?>
<th class='w-user'><?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='w-user'><?php common::printOrderLink('resolvedBy', $orderBy, $vars, $lang->bug->resolvedByAB);?></th>
<th class='w-resolution'><?php common::printOrderLink('resolution', $orderBy, $vars, $lang->bug->resolutionAB);?></th>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<th class='w-date'> <?php common::printOrderLink('resolvedDate', $orderBy, $vars, $lang->bug->resolvedDateAB);?></th>
<?php endif;?>
<th class='w-140px {sorter:false}'><?php echo $lang->actions;?></th>
<?php endif;?>
</tr>
</thead>
<tbody>
<?php foreach($bugs as $bug):?>
<?php $bugLink = inlink('view', "bugID=$bug->id");?>
<tr class='a-center'>
<?php $class = $bug->status == 'active' ? 'active' . $bug->severity : $bug->status;?>
<td class='linkbox <?php echo $class;?>'><?php echo html::a($bugLink, sprintf('%03d', $bug->id));?></td>
<td><?php echo $lang->bug->severityList[$bug->severity]?></td>
<td><?php echo $lang->bug->priList[$bug->pri]?></td>
<?php $class = 'confirm' . $bug->confirmed;?>
<td class='a-left nobr'><?php echo "<span class='$class'>[{$lang->bug->confirmedList[$bug->confirmed]}] </span>" . html::a($bugLink, $bug->title);?></td>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
<?php endif;?>
<?php if($browseType == 'needconfirm'):?>
<td class='a-left nobr'><?php echo html::a($this->createLink('story', 'view', "stoyID=$bug->story"), $bug->storyTitle, '_blank');?></td>
<td><?php echo html::a(inlink('confirmStoryChange', "bugID=$bug->id"), $lang->confirm, 'hiddenwin')?></td>
<?php else:?>
<td><?php echo $users[$bug->openedBy];?></td>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<?php endif;?>
<td <?php if($bug->assignedTo == $this->app->user->account) echo 'class="red"';?>><?php echo $users[$bug->assignedTo];?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo $lang->bug->resolutionList[$bug->resolution];?></td>
<?php if($this->cookie->windowWidth >= $this->config->wideSize):?>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
<?php endif;?>
<td>
<?php
$params = "bugID=$bug->id";
if(!($bug->status == 'active' and common::printLink('bug', 'resolve', $params, $lang->bug->buttonResolve))) echo $lang->bug->buttonResolve . ' ';
if(!($bug->status == 'resolved' and common::printLink('bug', 'close', $params, $lang->bug->buttonClose))) echo $lang->bug->buttonClose . ' ';
common::printLink('bug', 'edit', $params, $lang->bug->buttonEdit);
if($this->cookie->windowWidth >= $this->config->wideSize) common::printLink('bug', 'create', "product=$bug->product&extra=bugID=$bug->id", $lang->bug->buttonCopy);
?>
</td>
<?php endif;?>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<?php $columns = $this->cookie->windowWidth > $this->config->wideSize ? 12 : 9;?>
<td colspan='<?php echo $columns;?>'>
<div class='f-left'>
<?php
foreach($lang->bug->statusList as $status => $label)
{
if($status != 'active')
{
echo "<span class='$status'> $label </span> ";
continue;
}
rsort($this->lang->bug->severityList);
foreach($this->lang->bug->severityList as $severity)
{
echo "<span class='$status$severity'> {$lang->bug->severity}:$severity </span> ";
}
}
?>
</div>
<div class='f-right'><?php $pager->show();?></div>
</td>
</tr>
</tfoot>
</table>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,31 +1,31 @@
<?php
/**
* The close file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton();?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The close file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton();?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,31 +1,31 @@
<?php
/**
* The resolve file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id: resolve.html.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton($lang->bug->buttonConfirm);?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The resolve file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id: resolve.html.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton($lang->bug->buttonConfirm);?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,102 +1,102 @@
<?php
/**
* The create view of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/autocomplete.html.php';?>
<?php include '../../common/view/alert.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<script language='Javascript'>
userList = "<?php echo join(',', array_keys($users));?>".split(',');
</script>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->bug->create;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblProductAndModule;?></th>
<td>
<?php echo html::select('product', $products, $productID, "onchange='loadAll(this.value)' class='select-3'");?>
<span id='moduleIdBox'><?php echo html::select('module', $moduleOptionMenu, $moduleID, "onchange='setAssignedTo()'");?></span>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->project;?></th>
<td><span id='projectIdBox'><?php echo html::select('project', $projects, $projectID, 'class=select-3 onchange=loadProjectRelated(this.value)');?></span></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->openedBuild;?></th>
<td>
<span id='buildBox'><?php echo html::select('openedBuild[]', $builds, $buildID, 'size=3 multiple=multiple class=select-3');?></span>
</td>
</tr>
<tr>
<th class='rowhead'><nobr><?php echo $lang->bug->lblAssignedTo;?></nobr></th>
<td> <?php echo html::select('assignedTo', $users, $assignedTo, 'class=select-3');?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->title;?></th>
<td><?php echo html::input('title', $title, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->steps;?></th>
<td>
<table class='w-p100 bd-none'>
<tr class='bd-none' valign='top'>
<td class='w-p85 bd-none padding-zero'><?php echo html::textarea('steps', $steps, "rows='10'");?></td>
<td class='bd-none pl-10px' id='tplBox'><?php echo $this->fetch('bug', 'buildTemplates');?></td>
</tr>
</table>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblStory;?></th>
<td>
<span id='storyIdBox'><?php echo html::select('story', $stories, $storyID);?></span>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->task;?></th>
<td><span id='taskIdBox'><?php echo html::select('task', $tasks, $taskID);?></span></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblTypeAndSeverity;?></th>
<td>
<?php echo html::select('type', $lang->bug->typeList, $type, 'class=select-2');?>
<?php echo html::select('severity', $lang->bug->severityList, $severity, 'class=select-2');?>
</td>
</tr>
<tr>
<th class='rowhead'><nobr><?php echo $lang->bug->lblSystemBrowserAndHardware;?></nobr></th>
<td>
<?php echo html::select('os', $lang->bug->osList, $os, 'class=select-2');?>
<?php echo html::select('browser', $lang->bug->browserList, $browser, 'class=select-2');?>
</td>
</tr>
<tr>
<th class='rowhead'><nobr><?php echo $lang->bug->lblMailto;?></nobr></th>
<td> <?php echo html::input('mailto', $mailto, 'class=text-1');?> </td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->keywords;?></th>
<td><?php echo html::input('keywords', $keywords, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->files;?></th>
<td><?php echo $this->fetch('file', 'buildform', 'fileCount=2&percent=0.85');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton() . html::resetButton() . html::hidden('case', $caseID);?>
</td>
</tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The create view of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/autocomplete.html.php';?>
<?php include '../../common/view/alert.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<script language='Javascript'>
userList = "<?php echo join(',', array_keys($users));?>".split(',');
</script>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->bug->create;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblProductAndModule;?></th>
<td>
<?php echo html::select('product', $products, $productID, "onchange='loadAll(this.value)' class='select-3'");?>
<span id='moduleIdBox'><?php echo html::select('module', $moduleOptionMenu, $moduleID, "onchange='setAssignedTo()'");?></span>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->project;?></th>
<td><span id='projectIdBox'><?php echo html::select('project', $projects, $projectID, 'class=select-3 onchange=loadProjectRelated(this.value)');?></span></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->openedBuild;?></th>
<td>
<span id='buildBox'><?php echo html::select('openedBuild[]', $builds, $buildID, 'size=3 multiple=multiple class=select-3');?></span>
</td>
</tr>
<tr>
<th class='rowhead'><nobr><?php echo $lang->bug->lblAssignedTo;?></nobr></th>
<td> <?php echo html::select('assignedTo', $users, $assignedTo, 'class=select-3');?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->title;?></th>
<td><?php echo html::input('title', $title, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->steps;?></th>
<td>
<table class='w-p100 bd-none'>
<tr class='bd-none' valign='top'>
<td class='w-p85 bd-none padding-zero'><?php echo html::textarea('steps', $steps, "rows='10'");?></td>
<td class='bd-none pl-10px' id='tplBox'><?php echo $this->fetch('bug', 'buildTemplates');?></td>
</tr>
</table>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblStory;?></th>
<td>
<span id='storyIdBox'><?php echo html::select('story', $stories, $storyID);?></span>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->task;?></th>
<td><span id='taskIdBox'><?php echo html::select('task', $tasks, $taskID);?></span></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblTypeAndSeverity;?></th>
<td>
<?php echo html::select('type', $lang->bug->typeList, $type, 'class=select-2');?>
<?php echo html::select('severity', $lang->bug->severityList, $severity, 'class=select-2');?>
</td>
</tr>
<tr>
<th class='rowhead'><nobr><?php echo $lang->bug->lblSystemBrowserAndHardware;?></nobr></th>
<td>
<?php echo html::select('os', $lang->bug->osList, $os, 'class=select-2');?>
<?php echo html::select('browser', $lang->bug->browserList, $browser, 'class=select-2');?>
</td>
</tr>
<tr>
<th class='rowhead'><nobr><?php echo $lang->bug->lblMailto;?></nobr></th>
<td> <?php echo html::input('mailto', $mailto, 'class=text-1');?> </td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->keywords;?></th>
<td><?php echo html::input('keywords', $keywords, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->files;?></th>
<td><?php echo $this->fetch('file', 'buildform', 'fileCount=2&percent=0.85');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton() . html::resetButton() . html::hidden('case', $caseID);?>
</td>
</tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,49 +1,49 @@
<?php
/**
* The custom seting fields view of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package product
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/colorbox.html.php';?>
<form method='post' class='mt-20px'>
<table class='table-4' align='center'>
<caption class='caption-tl'><?php echo $lang->bug->customFields;?></caption>
<tr class='colhead'>
<th><?php echo $lang->bug->lblAllFields;?></th>
<th></th>
<th><?php echo $lang->bug->lblCustomFields;?></th>
<th></th>
</tr>
<tr>
<td>
<?php
echo html::select('allFields[]', $allFields, '', 'class=select-2 size=10 multiple');
echo html::select('defaultFields[]', $defaultFields, '', 'class=hidden');
?>
</td>
<td>
<?php
echo html::commonButton('>', "onclick=\"addItem('allFields', 'customFields')\"") . '<br />';
echo html::commonButton('<', "onclick=delItem('customFields')") . '<br />';
?>
</td>
<td><?php echo html::select('customFields[]', $customFields, '', 'class=select-2 size=10 multiple');?></td>
<td>
<?php
echo html::commonButton('+', "onclick=upItem('customFields')") . '<br />';
echo html::commonButton('-', "onclick=downItem('customFields')") . '<br />';
echo html::commonButton($lang->bug->restoreDefault, "onclick=restoreDefault()") . '<br />';
?>
</td>
</tr>
<tr><td colspan='4' class='a-center'><?php echo html::submitButton('', 'onclick=selectItem("customFields")');?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>
<?php
/**
* The custom seting fields view of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package product
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/colorbox.html.php';?>
<form method='post' class='mt-20px'>
<table class='table-4' align='center'>
<caption class='caption-tl'><?php echo $lang->bug->customFields;?></caption>
<tr class='colhead'>
<th><?php echo $lang->bug->lblAllFields;?></th>
<th></th>
<th><?php echo $lang->bug->lblCustomFields;?></th>
<th></th>
</tr>
<tr>
<td>
<?php
echo html::select('allFields[]', $allFields, '', 'class=select-2 size=10 multiple');
echo html::select('defaultFields[]', $defaultFields, '', 'class=hidden');
?>
</td>
<td>
<?php
echo html::commonButton('>', "onclick=\"addItem('allFields', 'customFields')\"") . '<br />';
echo html::commonButton('<', "onclick=delItem('customFields')") . '<br />';
?>
</td>
<td><?php echo html::select('customFields[]', $customFields, '', 'class=select-2 size=10 multiple');?></td>
<td>
<?php
echo html::commonButton('+', "onclick=upItem('customFields')") . '<br />';
echo html::commonButton('-', "onclick=downItem('customFields')") . '<br />';
echo html::commonButton($lang->bug->restoreDefault, "onclick=restoreDefault()") . '<br />';
?>
</td>
</tr>
<tr><td colspan='4' class='a-center'><?php echo html::submitButton('', 'onclick=selectItem("customFields")');?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>

View File

@@ -1,206 +1,206 @@
<?php
/**
* The edit file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/autocomplete.html.php';?>
<?php include '../../common/view/alert.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<script language='Javascript'>
changeProductConfirmed = false;
changeProjectConfirmed = false;
confirmChangeProduct = '<?php echo $lang->bug->confirmChangeProduct;?>';
oldProjectID = '<?php echo $bug->project;?>';
oldStoryID = '<?php echo $bug->story;?>';
oldTaskID = '<?php echo $bug->task;?>';
oldOpenedBuild = '<?php echo $bug->openedBuild;?>';
oldResolvedBuild = '<?php echo $bug->resolvedBuild;?>';
emptySelect = "<select name='task' id='task'><option value=''></option></select>";
userList = "<?php echo join(',', array_keys($users));?>".split(',');
</script>
<form method='post' target='hiddenwin' enctype='multipart/form-data'>
<div id='titlebar'>
<div id='main'>
BUG #<?php echo $bug->id . $lang->colon;?>
<?php echo html::input('title', str_replace("'","&#039;",$bug->title), 'class=text-1');?>
</div>
<div><?php echo html::submitButton()?></div>
</div>
<table class='cont-rt5'>
<tr valign='top'>
<td>
<table class='table-1 bd-none'>
<tr class='bd-none'><td class='bd-none'>
<fieldset>
<legend><?php echo $lang->bug->legendSteps;?></legend>
<div class='w-p90'><?php echo html::textarea('steps', htmlspecialchars($bug->steps), "rows='12'");?></div>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendComment;?></legend>
<?php echo html::textarea('comment', '', "rows='6' class='area-1'");?>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendAttatch;?></legend>
<?php echo $this->fetch('file', 'buildform', 'filecount=2');?>
</fieldset>
<div class='a-center'>
<?php
echo html::submitButton();
$browseLink = $app->session->bugList != false ? $app->session->bugList : inlink('browse', "productID=$bug->product");
echo html::linkButton($lang->goback, $browseLink);
?>
</div>
</td></tr>
</table>
<?php include '../../common/view/action.html.php';?>
</td>
<td class='divider'></td>
<td class='side'>
<fieldset>
<legend><?php echo $lang->bug->legendBasicInfo;?></legend>
<table class='table-1 a-left' cellpadding='0' cellspacing='0'>
<tr>
<td class='rowhead'><?php echo $lang->bug->product;?></td>
<td>
<?php echo html::select('product', $products, $productID, "onchange=loadAll(this.value);");?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->module;?></td>
<td>
<span id='moduleIdBox'><?php echo html::select('module', $moduleOptionMenu, $currentModuleID);?></span>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->type;?></td>
<td><?php echo html::select('type', $lang->bug->typeList, $bug->type, 'class=select-3');?>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->severity;?></td>
<td><?php echo html::select('severity', $lang->bug->severityList, $bug->severity, 'class=select-3');?>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->pri;?></td>
<td><?php echo html::select('pri', $lang->bug->priList, $bug->pri, 'class=select-3');?>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->status;?></td>
<td><?php echo html::select('status', $lang->bug->statusList, $bug->status, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->confirmed;?></td>
<td><?php echo $lang->bug->confirmedList[$bug->confirmed];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $bug->assignedTo, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->os;?></td>
<td><?php echo html::select('os', $lang->bug->osList, $bug->os, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->browser;?></td>
<td><?php echo html::select('browser', $lang->bug->browserList, $bug->browser, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->keywords;?></td>
<td><?php echo html::input('keywords', $bug->keywords, 'class="text-3"');?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendPrjStoryTask;?></legend>
<table class='table-1 a-left'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->project;?></td>
<td><span id='projectIdBox'><?php echo html::select('project', $projects, $bug->project, 'class=select-3 onchange=loadProjectRelated(this.value)');?></span></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->story;?></td>
<td><div id='storyIdBox' class='searchleft'><?php echo html::select('story', $stories, $bug->story, "class=select-3");?></div>
<!--<div id='storyListIdBox'><?php echo html::a('', $lang->go, "_blank", "class='search' id='searchStories' onclick=getList('story')");?></div>-->
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->task;?></td>
<td><div id='taskIdBox' class='searchleft'><?php echo html::select('task', $tasks, $bug->task, 'class=select-3');?></div>
<!--<div id='taskListIdBox'><?php echo html::a('', $lang->go, "_blank", "class='search' id='searchTasks' onclick=getList('task')");?></div>-->
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendLife;?></legend>
<table class='table-1 a-left'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->openedBy;?></td>
<td><?php echo $users[$bug->openedBy];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->openedBuild;?></td>
<td><span id='openedBuildBox'><?php echo html::select('openedBuild[]', $openedBuilds, $bug->openedBuild, 'size=4 multiple=multiple class=select-3');?></span></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedBy;?></td>
<td><?php echo html::select('resolvedBy', $users, $bug->resolvedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedDate;?></td>
<td><?php echo html::input('resolvedDate', $bug->resolvedDate, 'class=text-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedBuild;?></td>
<td><span id='resolvedBuildBox'><?php echo html::select('resolvedBuild', $resolvedBuilds, $bug->resolvedBuild, 'class=select-3');?></span></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolution;?></td>
<td><?php echo html::select('resolution', $lang->bug->resolutionList, $bug->resolution, 'class=select-3 onchange=setDuplicate(this.value)');?></td>
</tr>
<tr id='duplicateBugBox' <?php if($bug->resolution != 'duplicate') echo "style='display:none'";?>>
<td class='rowhead'><?php echo $lang->bug->duplicateBug;?></td>
<td><?php echo html::input('duplicateBug', $bug->duplicateBug, 'class=text-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->closedBy;?></td>
<td><?php echo html::select('closedBy', $users, $bug->closedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->closedDate;?></td>
<td><?php echo html::input('closedDate', $bug->closedDate, 'class=text-3');?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendMisc;?></legend>
<table class='table-1 a-left'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->mailto;?></td>
<td><?php echo html::input('mailto', $bug->mailto, 'class="text-3"');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->linkBug;?></td>
<td><?php echo html::input('linkBug', $bug->linkBug, 'class="text-3"');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->case;?></td>
<td><?php echo html::input('case', $bug->case, 'class="text-3"');?></td>
</tr>
</table>
</fieldset>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The edit file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/autocomplete.html.php';?>
<?php include '../../common/view/alert.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<script language='Javascript'>
changeProductConfirmed = false;
changeProjectConfirmed = false;
confirmChangeProduct = '<?php echo $lang->bug->confirmChangeProduct;?>';
oldProjectID = '<?php echo $bug->project;?>';
oldStoryID = '<?php echo $bug->story;?>';
oldTaskID = '<?php echo $bug->task;?>';
oldOpenedBuild = '<?php echo $bug->openedBuild;?>';
oldResolvedBuild = '<?php echo $bug->resolvedBuild;?>';
emptySelect = "<select name='task' id='task'><option value=''></option></select>";
userList = "<?php echo join(',', array_keys($users));?>".split(',');
</script>
<form method='post' target='hiddenwin' enctype='multipart/form-data'>
<div id='titlebar'>
<div id='main'>
BUG #<?php echo $bug->id . $lang->colon;?>
<?php echo html::input('title', str_replace("'","&#039;",$bug->title), 'class=text-1');?>
</div>
<div><?php echo html::submitButton()?></div>
</div>
<table class='cont-rt5'>
<tr valign='top'>
<td>
<table class='table-1 bd-none'>
<tr class='bd-none'><td class='bd-none'>
<fieldset>
<legend><?php echo $lang->bug->legendSteps;?></legend>
<div class='w-p90'><?php echo html::textarea('steps', htmlspecialchars($bug->steps), "rows='12'");?></div>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendComment;?></legend>
<?php echo html::textarea('comment', '', "rows='6' class='area-1'");?>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendAttatch;?></legend>
<?php echo $this->fetch('file', 'buildform', 'filecount=2');?>
</fieldset>
<div class='a-center'>
<?php
echo html::submitButton();
$browseLink = $app->session->bugList != false ? $app->session->bugList : inlink('browse', "productID=$bug->product");
echo html::linkButton($lang->goback, $browseLink);
?>
</div>
</td></tr>
</table>
<?php include '../../common/view/action.html.php';?>
</td>
<td class='divider'></td>
<td class='side'>
<fieldset>
<legend><?php echo $lang->bug->legendBasicInfo;?></legend>
<table class='table-1 a-left' cellpadding='0' cellspacing='0'>
<tr>
<td class='rowhead'><?php echo $lang->bug->product;?></td>
<td>
<?php echo html::select('product', $products, $productID, "onchange=loadAll(this.value);");?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->module;?></td>
<td>
<span id='moduleIdBox'><?php echo html::select('module', $moduleOptionMenu, $currentModuleID);?></span>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->type;?></td>
<td><?php echo html::select('type', $lang->bug->typeList, $bug->type, 'class=select-3');?>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->severity;?></td>
<td><?php echo html::select('severity', $lang->bug->severityList, $bug->severity, 'class=select-3');?>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->pri;?></td>
<td><?php echo html::select('pri', $lang->bug->priList, $bug->pri, 'class=select-3');?>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->status;?></td>
<td><?php echo html::select('status', $lang->bug->statusList, $bug->status, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->confirmed;?></td>
<td><?php echo $lang->bug->confirmedList[$bug->confirmed];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $bug->assignedTo, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->os;?></td>
<td><?php echo html::select('os', $lang->bug->osList, $bug->os, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->browser;?></td>
<td><?php echo html::select('browser', $lang->bug->browserList, $bug->browser, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->keywords;?></td>
<td><?php echo html::input('keywords', $bug->keywords, 'class="text-3"');?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendPrjStoryTask;?></legend>
<table class='table-1 a-left'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->project;?></td>
<td><span id='projectIdBox'><?php echo html::select('project', $projects, $bug->project, 'class=select-3 onchange=loadProjectRelated(this.value)');?></span></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->story;?></td>
<td><div id='storyIdBox' class='searchleft'><?php echo html::select('story', $stories, $bug->story, "class=select-3");?></div>
<!--<div id='storyListIdBox'><?php echo html::a('', $lang->go, "_blank", "class='search' id='searchStories' onclick=getList('story')");?></div>-->
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->task;?></td>
<td><div id='taskIdBox' class='searchleft'><?php echo html::select('task', $tasks, $bug->task, 'class=select-3');?></div>
<!--<div id='taskListIdBox'><?php echo html::a('', $lang->go, "_blank", "class='search' id='searchTasks' onclick=getList('task')");?></div>-->
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendLife;?></legend>
<table class='table-1 a-left'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->openedBy;?></td>
<td><?php echo $users[$bug->openedBy];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->openedBuild;?></td>
<td><span id='openedBuildBox'><?php echo html::select('openedBuild[]', $openedBuilds, $bug->openedBuild, 'size=4 multiple=multiple class=select-3');?></span></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedBy;?></td>
<td><?php echo html::select('resolvedBy', $users, $bug->resolvedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedDate;?></td>
<td><?php echo html::input('resolvedDate', $bug->resolvedDate, 'class=text-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedBuild;?></td>
<td><span id='resolvedBuildBox'><?php echo html::select('resolvedBuild', $resolvedBuilds, $bug->resolvedBuild, 'class=select-3');?></span></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolution;?></td>
<td><?php echo html::select('resolution', $lang->bug->resolutionList, $bug->resolution, 'class=select-3 onchange=setDuplicate(this.value)');?></td>
</tr>
<tr id='duplicateBugBox' <?php if($bug->resolution != 'duplicate') echo "style='display:none'";?>>
<td class='rowhead'><?php echo $lang->bug->duplicateBug;?></td>
<td><?php echo html::input('duplicateBug', $bug->duplicateBug, 'class=text-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->closedBy;?></td>
<td><?php echo html::select('closedBy', $users, $bug->closedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->closedDate;?></td>
<td><?php echo html::input('closedDate', $bug->closedDate, 'class=text-3');?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendMisc;?></legend>
<table class='table-1 a-left'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->mailto;?></td>
<td><?php echo html::input('mailto', $bug->mailto, 'class="text-3"');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->linkBug;?></td>
<td><?php echo html::input('linkBug', $bug->linkBug, 'class="text-3"');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->case;?></td>
<td><?php echo html::input('case', $bug->case, 'class="text-3"');?></td>
</tr>
</table>
</fieldset>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,13 +1,13 @@
<?php
/**
* The export view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Congzhi Chen<congzhi@cnezsoft.com>
* @package task
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../file/view/export.html.php';?>
<?php
/**
* The export view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Congzhi Chen<congzhi@cnezsoft.com>
* @package task
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../file/view/export.html.php';?>

View File

@@ -1,62 +1,62 @@
<?php
/**
* The report view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='featurebar'>
<div class='f-left'><?php echo $lang->bug->report->common;?></div>
<div class='f-right'><?php common::printLink('bug', 'browse', "productID=$productID&browseType=$browseType&moduleID=$moduleID", $lang->goback); ?></div>
</div>
<table class='cont-lt1'>
<tr valign='top'>
<td class='side'>
<div class='box-title'><?php echo $lang->bug->report->select;?></div>
<div class='box-content'>
<form method='post'>
<?php echo html::checkBox('charts', $lang->bug->report->charts, $checkedCharts);?>
<input type='button' value='<?php echo $lang->bug->report->selectAll;?>' onclick='checkAll()' />
<input type='button' value='<?php echo $lang->bug->report->selectReverse;?>' onclick='checkReverse()' />
<br /><br />
<?php echo html::submitButton($lang->bug->report->create);?>
</div>
</td>
<td class='divider'></td>
<td>
<table class='table-1'>
<caption><?php echo $lang->bug->report->common;?></caption>
<?php foreach($charts as $chartType => $chartContent):?>
<tr valign='top'>
<td><?php echo $chartContent;?></td>
<td width='300'>
<table class='table-1'>
<tr>
<th><?php echo $lang->report->item;?></th>
<th><?php echo $lang->report->value;?></th>
<th><?php echo $lang->report->percent;?></th>
</tr>
<?php foreach($datas[$chartType] as $key => $data):?>
<tr class='a-center'>
<td><?php echo $data->name;?></td>
<td><?php echo $data->value;?></td>
<td><?php echo ($data->percent * 100) . '%';?></td>
</tr>
<?php endforeach;?>
</table>
</td>
</tr>
<?php endforeach;?>
</table>
</td>
</tr>
</table>
<?php echo $renderJS;?>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The report view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='featurebar'>
<div class='f-left'><?php echo $lang->bug->report->common;?></div>
<div class='f-right'><?php common::printLink('bug', 'browse', "productID=$productID&browseType=$browseType&moduleID=$moduleID", $lang->goback); ?></div>
</div>
<table class='cont-lt1'>
<tr valign='top'>
<td class='side'>
<div class='box-title'><?php echo $lang->bug->report->select;?></div>
<div class='box-content'>
<form method='post'>
<?php echo html::checkBox('charts', $lang->bug->report->charts, $checkedCharts);?>
<input type='button' value='<?php echo $lang->bug->report->selectAll;?>' onclick='checkAll()' />
<input type='button' value='<?php echo $lang->bug->report->selectReverse;?>' onclick='checkReverse()' />
<br /><br />
<?php echo html::submitButton($lang->bug->report->create);?>
</div>
</td>
<td class='divider'></td>
<td>
<table class='table-1'>
<caption><?php echo $lang->bug->report->common;?></caption>
<?php foreach($charts as $chartType => $chartContent):?>
<tr valign='top'>
<td><?php echo $chartContent;?></td>
<td width='300'>
<table class='table-1'>
<tr>
<th><?php echo $lang->report->item;?></th>
<th><?php echo $lang->report->value;?></th>
<th><?php echo $lang->report->percent;?></th>
</tr>
<?php foreach($datas[$chartType] as $key => $data):?>
<tr class='a-center'>
<td><?php echo $data->name;?></td>
<td><?php echo $data->value;?></td>
<td><?php echo ($data->percent * 100) . '%';?></td>
</tr>
<?php endforeach;?>
</table>
</td>
</tr>
<?php endforeach;?>
</table>
</td>
</tr>
</table>
<?php echo $renderJS;?>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,47 +1,47 @@
<?php
/**
* The resolve file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolution;?></td>
<td><?php unset($lang->bug->resolutionList['tostory']); echo html::select('resolution', $lang->bug->resolutionList, '', 'class=select-3 onchange=setDuplicate(this.value)');?></td>
</tr>
<tr id='duplicateBugBox' style='display:none'>
<td class='rowhead'><?php echo $lang->bug->duplicateBug;?></td>
<td><?php echo html::input('duplicateBug', '', 'class=text-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedBuild;?></td>
<td><?php echo html::select('resolvedBuild', $builds, '', 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $bug->openedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton();?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The resolve file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $bug->title;?></caption>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolution;?></td>
<td><?php unset($lang->bug->resolutionList['tostory']); echo html::select('resolution', $lang->bug->resolutionList, '', 'class=select-3 onchange=setDuplicate(this.value)');?></td>
</tr>
<tr id='duplicateBugBox' style='display:none'>
<td class='rowhead'><?php echo $lang->bug->duplicateBug;?></td>
<td><?php echo html::input('duplicateBug', '', 'class=text-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->resolvedBuild;?></td>
<td><?php echo html::select('resolvedBuild', $builds, '', 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $bug->openedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "rows='6' class='area-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton();?>
<input type='button' value='<?php echo $lang->bug->buttonToList;?>' class='button-s'
onclick='location.href="<?php echo $this->session->bugList;?>"' />
</td>
</tr>
</table>
<?php include '../../common/view/action.html.php';?>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,22 +1,22 @@
<?php
/**
* The mail file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<table width='98%' align='center'>
<tr class='header'>
<td>
BUG #<?php echo $bug->id . "=>$bug->assignedTo " . html::a(common::getSysURL() . $this->createLink('bug', 'view', "bugID=$bug->id"), $bug->title);?>
</td>
</tr>
<tr>
<td><?php include '../../common/view/mail.html.php';?></td>
</tr>
</table>
<?php
/**
* The mail file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<table width='98%' align='center'>
<tr class='header'>
<td>
BUG #<?php echo $bug->id . "=>$bug->assignedTo " . html::a(common::getSysURL() . $this->createLink('bug', 'view', "bugID=$bug->id"), $bug->title);?>
</td>
</tr>
<tr>
<td><?php include '../../common/view/mail.html.php';?></td>
</tr>
</table>

View File

@@ -1,272 +1,272 @@
<?php
/**
* The view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='titlebar'>
<div id='main' <?php if($bug->deleted) echo "class='deleted'";?>>BUG #<?php echo $bug->id . $lang->colon . $bug->title;?></div>
<div>
<?php
$browseLink = $app->session->bugList != false ? $app->session->bugList : inlink('browse', "productID=$bug->product");
$params = "bugID=$bug->id";
$copyParams = "productID=$productID&extras=bugID=$bug->id";
$convertParams = "productID=$productID&moduleID=0&from=bug&bugID=$bug->id";
if(!$bug->deleted)
{
if(!($bug->status == 'active' and $bug->confirmed == 0 and common::printLink('bug', 'confirmBug', $params, $lang->bug->buttonConfirm))) echo $lang->bug->buttonConfirm . ' ';
if(!($bug->status == 'active' and common::printLink('bug', 'resolve', $params, $lang->bug->buttonResolve))) echo $lang->bug->buttonResolve . ' ';
common::printLink('bug', 'edit', $params, $lang->bug->buttonEdit);
if(common::hasPriv('bug', 'edit')) echo html::a('#', $lang->comment, '', 'onclick=setComment()'). ' ';
if(!($bug->status == 'resolved' and common::printLink('bug', 'close', $params, $lang->bug->buttonClose))) echo $lang->bug->buttonClose . ' ';
if(!(($bug->status == 'closed' or $bug->status == 'resolved') and $bug->resolution != 'tostory' and common::printLink('bug', 'activate', $params, $lang->bug->buttonActivate))) echo $lang->bug->buttonActivate . ' ';
common::printLink('bug', 'create', $copyParams, $lang->bug->buttonCopy);
if($bug->status == 'active' and common::hasPriv('story', 'create'))
{
common::printLink('story', 'create', "product=$bug->product&module=0&story=0&project=0&bugID=$bug->id", $lang->bug->toStory) . ' ';
}
else
{
echo $lang->bug->toStory . ' ';
}
common::printLink('testcase', 'create', $convertParams, $lang->bug->buttonCreateTestcase);
common::printLink('bug', 'delete', $params, $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
</div>
<table class='cont-rt5'>
<tr valign='top'>
<td>
<fieldset>
<legend><?php echo $lang->bug->legendSteps;?></legend>
<div class='content'><?php echo str_replace('<p>[', '<p class="stepTitle">[', $bug->steps);?></div>
</fieldset>
<?php echo $this->fetch('file', 'printFiles', array('files' => $bug->files, 'fieldset' => 'true'));?>
<?php include '../../common/view/action.html.php';?>
<div class='a-center' style='font-size:16px; font-weight:bold'>
<?php
if(!$bug->deleted)
{
if(!($bug->status == 'active' and $bug->confirmed == 0 and common::printLink('bug', 'confirmBug', $params, $lang->bug->buttonConfirm))) echo $lang->bug->buttonConfirm . ' ';
if(!($bug->status == 'active' and common::printLink('bug', 'resolve', $params, $lang->bug->buttonResolve))) echo $lang->bug->buttonResolve . ' ';
common::printLink('bug', 'edit', $params, $lang->bug->buttonEdit);
if(common::hasPriv('bug', 'edit')) echo html::a('#', $lang->comment, '', 'onclick=setComment()'). ' ';
if(!($bug->status == 'resolved' and common::printLink('bug', 'close', $params, $lang->bug->buttonClose))) echo $lang->bug->buttonClose . ' ';
if(!(($bug->status == 'closed' or $bug->status == 'resolved') and $bug->resolution != 'tostory' and common::printLink('bug', 'activate', $params, $lang->bug->buttonActivate))) echo $lang->bug->buttonActivate . ' ';
common::printLink('bug', 'create', $copyParams, $lang->bug->buttonCopy);
if($bug->status == 'active' and common::hasPriv('bug', 'resolve'))
{
common::printLink('story', 'create', "product=$bug->product&module=0&story=0&project=0&bugID=$bug->id", $lang->bug->toStory) . ' ';
}
else
{
echo $lang->bug->toStory . ' ';
}
common::printLink('testcase', 'create', $convertParams, $lang->bug->buttonCreateTestcase);
common::printLink('bug', 'delete', $params, $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
<div id='comment' class='hidden'>
<fieldset>
<legend><?php echo $lang->comment;?></legend>
<form method='post' action='<?php echo inlink('edit', "bugID=$bug->id&comment=true")?>'>
<table align='center' class='table-1'>
<tr><td><?php echo html::textarea('comment', '',"rows='5' class='w-p100'");?></td></tr>
<tr><td><?php echo html::submitButton() . html::resetButton();?></td></tr>
</table>
</form>
</fieldset>
</div>
</td>
<td class='divider'></td>
<td class='side'>
<fieldset>
<legend><?php echo $lang->bug->legendBasicInfo;?></legend>
<table class='table-1 a-left'>
<tr valign='middle'>
<th class='rowhead'><?php echo $lang->bug->product;?></th>
<td><?php if(!common::printLink('bug', 'browse', "productID=$bug->product", $productName)) echo $productName;?>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->module;?></th>
<td>
<?php
foreach($modulePath as $key => $module)
{
if(!common::printLink('bug', 'browse', "productID=$bug->product&browseType=byModule&param=$module->id", $module->name)) echo $module->name;
if(isset($modulePath[$key + 1])) echo $lang->arrow;
}
?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->type;?></td>
<td><?php if(isset($lang->bug->typeList[$bug->type])) echo $lang->bug->typeList[$bug->type]; else echo $bug->type;?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->severity;?></td>
<td><strong><?php echo $lang->bug->severityList[$bug->severity];?></strong></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->pri;?></td>
<td><strong><?php echo $lang->bug->priList[$bug->pri];?></strong></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->status;?></td>
<td><strong><?php echo $lang->bug->statusList[$bug->status];?></strong></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->activatedCount;?></td>
<td><?php echo $bug->activatedCount;?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->confirmed;?></td>
<td><?php echo $lang->bug->confirmedList[$bug->confirmed];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->lblAssignedTo;?></td>
<td><?php if($bug->assignedTo) echo $users[$bug->assignedTo] . $lang->at . $bug->assignedDate;?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->os;?></td>
<td><?php echo $lang->bug->osList[$bug->os];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->browser;?></td>
<td><?php echo $lang->bug->browserList[$bug->browser];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->keywords;?></td>
<td><?php echo $bug->keywords;?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendLife;?></legend>
<table class='table-1 a-left fixed'>
<tr>
<th class='rowhead w-p20'><?php echo $lang->bug->openedBy;?></th>
<td> <?php echo $users[$bug->openedBy] . $lang->at . $bug->openedDate;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->openedBuild;?></th>
<td>
<?php
if($bug->openedBuild)
{
$openedBuilds = explode(',', $bug->openedBuild);
foreach($openedBuilds as $openedBuild) isset($builds[$openedBuild]) ? print($builds[$openedBuild] . '<br />') : print($openedBuild . '<br />');
}
else
{
echo $bug->openedBuild;
}
?>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblResolved;?></th>
<td><?php if($bug->resolvedBy) echo $users[$bug->resolvedBy] . $lang->at . $bug->resolvedDate;?>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->resolvedBuild;?></th>
<td><?php if(isset($builds[$bug->resolvedBuild])) echo $builds[$bug->resolvedBuild]; else echo $bug->resolvedBuild;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->resolution;?></th>
<td>
<?php
echo $lang->bug->resolutionList[$bug->resolution];
if(isset($bug->duplicateBugTitle)) echo " #$bug->duplicateBug:" . html::a($this->createLink('bug', 'view', "bugID=$bug->duplicateBug"), $bug->duplicateBugTitle);
?>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->closedBy;?></th>
<td><?php if($bug->closedBy) echo $users[$bug->closedBy] . $lang->at . $bug->closedDate;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblLastEdited;?></th>
<td><?php if($bug->lastEditedBy) echo $users[$bug->lastEditedBy] . $lang->at . $bug->lastEditedDate?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendPrjStoryTask;?></legend>
<table class='table-1 a-left fixed'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->project;?></td>
<td><?php if($bug->project) echo html::a($this->createLink('project', 'browse', "projectid=$bug->project"), $bug->projectName);?></td>
</tr>
<tr class='nofixed'>
<td class='rowhead'><?php echo $lang->bug->story;?></td>
<td>
<?php
if($bug->story) echo html::a($this->createLink('story', 'view', "storyID=$bug->story"), $bug->storyTitle);
if($bug->storyStatus == 'active' and $bug->latestStoryVersion > $bug->storyVersion)
{
echo "(<span class='warning'>{$lang->story->changed}</span> ";
echo html::a($this->createLink('bug', 'confirmStoryChange', "bugID=$bug->id"), $lang->confirm, 'hiddenwin');
echo ")";
}
?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->task;?></td>
<td><?php if($bug->task) echo html::a($this->createLink('task', 'view', "taskID=$bug->task"), $bug->taskName);?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendMisc;?></legend>
<table class='table-1 a-left fixed'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->mailto;?></td>
<td><?php $mailto = explode(',', str_replace(' ', '', $bug->mailto)); foreach($mailto as $account) echo ' ' . $users[$account]; ?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->linkBug;?></td>
<td>
<?php
if(isset($bug->linkBugTitles))
{
foreach($bug->linkBugTitles as $linkBugID => $linkBugTitle)
{
echo html::a($this->createLink('bug', 'view', "bugID=$linkBugID"), "#$linkBugID $linkBugTitle", '_blank') . '<br />';
}
}
?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->case;?></td>
<td><?php if(isset($bug->caseTitle)) echo html::a($this->createLink('testcase', 'view', "caseID=$bug->case"), "#$bug->case $bug->caseTitle", '_blank');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->toStory;?></td>
<td><?php if($bug->toStory != 0) echo html::a($this->createLink('story', 'view', "storyID=$bug->toStory"), "#$bug->toStory $bug->toStoryTitle", '_blank');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->toTask;?></td>
<td><?php if($bug->toTask != 0) echo html::a($this->createLink('bug', 'view', "bugID=$bug->toTask"), "#$bug->toTask $bug->toTaskTitle", '_blank');?></td>
</tr>
</table>
</fieldset>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The view file of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='titlebar'>
<div id='main' <?php if($bug->deleted) echo "class='deleted'";?>>BUG #<?php echo $bug->id . $lang->colon . $bug->title;?></div>
<div>
<?php
$browseLink = $app->session->bugList != false ? $app->session->bugList : inlink('browse', "productID=$bug->product");
$params = "bugID=$bug->id";
$copyParams = "productID=$productID&extras=bugID=$bug->id";
$convertParams = "productID=$productID&moduleID=0&from=bug&bugID=$bug->id";
if(!$bug->deleted)
{
if(!($bug->status == 'active' and $bug->confirmed == 0 and common::printLink('bug', 'confirmBug', $params, $lang->bug->buttonConfirm))) echo $lang->bug->buttonConfirm . ' ';
if(!($bug->status == 'active' and common::printLink('bug', 'resolve', $params, $lang->bug->buttonResolve))) echo $lang->bug->buttonResolve . ' ';
common::printLink('bug', 'edit', $params, $lang->bug->buttonEdit);
if(common::hasPriv('bug', 'edit')) echo html::a('#', $lang->comment, '', 'onclick=setComment()'). ' ';
if(!($bug->status == 'resolved' and common::printLink('bug', 'close', $params, $lang->bug->buttonClose))) echo $lang->bug->buttonClose . ' ';
if(!(($bug->status == 'closed' or $bug->status == 'resolved') and $bug->resolution != 'tostory' and common::printLink('bug', 'activate', $params, $lang->bug->buttonActivate))) echo $lang->bug->buttonActivate . ' ';
common::printLink('bug', 'create', $copyParams, $lang->bug->buttonCopy);
if($bug->status == 'active' and common::hasPriv('story', 'create'))
{
common::printLink('story', 'create', "product=$bug->product&module=0&story=0&project=0&bugID=$bug->id", $lang->bug->toStory) . ' ';
}
else
{
echo $lang->bug->toStory . ' ';
}
common::printLink('testcase', 'create', $convertParams, $lang->bug->buttonCreateTestcase);
common::printLink('bug', 'delete', $params, $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
</div>
<table class='cont-rt5'>
<tr valign='top'>
<td>
<fieldset>
<legend><?php echo $lang->bug->legendSteps;?></legend>
<div class='content'><?php echo str_replace('<p>[', '<p class="stepTitle">[', $bug->steps);?></div>
</fieldset>
<?php echo $this->fetch('file', 'printFiles', array('files' => $bug->files, 'fieldset' => 'true'));?>
<?php include '../../common/view/action.html.php';?>
<div class='a-center' style='font-size:16px; font-weight:bold'>
<?php
if(!$bug->deleted)
{
if(!($bug->status == 'active' and $bug->confirmed == 0 and common::printLink('bug', 'confirmBug', $params, $lang->bug->buttonConfirm))) echo $lang->bug->buttonConfirm . ' ';
if(!($bug->status == 'active' and common::printLink('bug', 'resolve', $params, $lang->bug->buttonResolve))) echo $lang->bug->buttonResolve . ' ';
common::printLink('bug', 'edit', $params, $lang->bug->buttonEdit);
if(common::hasPriv('bug', 'edit')) echo html::a('#', $lang->comment, '', 'onclick=setComment()'). ' ';
if(!($bug->status == 'resolved' and common::printLink('bug', 'close', $params, $lang->bug->buttonClose))) echo $lang->bug->buttonClose . ' ';
if(!(($bug->status == 'closed' or $bug->status == 'resolved') and $bug->resolution != 'tostory' and common::printLink('bug', 'activate', $params, $lang->bug->buttonActivate))) echo $lang->bug->buttonActivate . ' ';
common::printLink('bug', 'create', $copyParams, $lang->bug->buttonCopy);
if($bug->status == 'active' and common::hasPriv('bug', 'resolve'))
{
common::printLink('story', 'create', "product=$bug->product&module=0&story=0&project=0&bugID=$bug->id", $lang->bug->toStory) . ' ';
}
else
{
echo $lang->bug->toStory . ' ';
}
common::printLink('testcase', 'create', $convertParams, $lang->bug->buttonCreateTestcase);
common::printLink('bug', 'delete', $params, $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
<div id='comment' class='hidden'>
<fieldset>
<legend><?php echo $lang->comment;?></legend>
<form method='post' action='<?php echo inlink('edit', "bugID=$bug->id&comment=true")?>'>
<table align='center' class='table-1'>
<tr><td><?php echo html::textarea('comment', '',"rows='5' class='w-p100'");?></td></tr>
<tr><td><?php echo html::submitButton() . html::resetButton();?></td></tr>
</table>
</form>
</fieldset>
</div>
</td>
<td class='divider'></td>
<td class='side'>
<fieldset>
<legend><?php echo $lang->bug->legendBasicInfo;?></legend>
<table class='table-1 a-left'>
<tr valign='middle'>
<th class='rowhead'><?php echo $lang->bug->product;?></th>
<td><?php if(!common::printLink('bug', 'browse', "productID=$bug->product", $productName)) echo $productName;?>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->module;?></th>
<td>
<?php
foreach($modulePath as $key => $module)
{
if(!common::printLink('bug', 'browse', "productID=$bug->product&browseType=byModule&param=$module->id", $module->name)) echo $module->name;
if(isset($modulePath[$key + 1])) echo $lang->arrow;
}
?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->type;?></td>
<td><?php if(isset($lang->bug->typeList[$bug->type])) echo $lang->bug->typeList[$bug->type]; else echo $bug->type;?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->severity;?></td>
<td><strong><?php echo $lang->bug->severityList[$bug->severity];?></strong></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->pri;?></td>
<td><strong><?php echo $lang->bug->priList[$bug->pri];?></strong></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->status;?></td>
<td><strong><?php echo $lang->bug->statusList[$bug->status];?></strong></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->activatedCount;?></td>
<td><?php echo $bug->activatedCount;?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->confirmed;?></td>
<td><?php echo $lang->bug->confirmedList[$bug->confirmed];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->lblAssignedTo;?></td>
<td><?php if($bug->assignedTo) echo $users[$bug->assignedTo] . $lang->at . $bug->assignedDate;?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->os;?></td>
<td><?php echo $lang->bug->osList[$bug->os];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->browser;?></td>
<td><?php echo $lang->bug->browserList[$bug->browser];?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->keywords;?></td>
<td><?php echo $bug->keywords;?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendLife;?></legend>
<table class='table-1 a-left fixed'>
<tr>
<th class='rowhead w-p20'><?php echo $lang->bug->openedBy;?></th>
<td> <?php echo $users[$bug->openedBy] . $lang->at . $bug->openedDate;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->openedBuild;?></th>
<td>
<?php
if($bug->openedBuild)
{
$openedBuilds = explode(',', $bug->openedBuild);
foreach($openedBuilds as $openedBuild) isset($builds[$openedBuild]) ? print($builds[$openedBuild] . '<br />') : print($openedBuild . '<br />');
}
else
{
echo $bug->openedBuild;
}
?>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblResolved;?></th>
<td><?php if($bug->resolvedBy) echo $users[$bug->resolvedBy] . $lang->at . $bug->resolvedDate;?>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->resolvedBuild;?></th>
<td><?php if(isset($builds[$bug->resolvedBuild])) echo $builds[$bug->resolvedBuild]; else echo $bug->resolvedBuild;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->resolution;?></th>
<td>
<?php
echo $lang->bug->resolutionList[$bug->resolution];
if(isset($bug->duplicateBugTitle)) echo " #$bug->duplicateBug:" . html::a($this->createLink('bug', 'view', "bugID=$bug->duplicateBug"), $bug->duplicateBugTitle);
?>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->closedBy;?></th>
<td><?php if($bug->closedBy) echo $users[$bug->closedBy] . $lang->at . $bug->closedDate;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->bug->lblLastEdited;?></th>
<td><?php if($bug->lastEditedBy) echo $users[$bug->lastEditedBy] . $lang->at . $bug->lastEditedDate?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendPrjStoryTask;?></legend>
<table class='table-1 a-left fixed'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->project;?></td>
<td><?php if($bug->project) echo html::a($this->createLink('project', 'browse', "projectid=$bug->project"), $bug->projectName);?></td>
</tr>
<tr class='nofixed'>
<td class='rowhead'><?php echo $lang->bug->story;?></td>
<td>
<?php
if($bug->story) echo html::a($this->createLink('story', 'view', "storyID=$bug->story"), $bug->storyTitle);
if($bug->storyStatus == 'active' and $bug->latestStoryVersion > $bug->storyVersion)
{
echo "(<span class='warning'>{$lang->story->changed}</span> ";
echo html::a($this->createLink('bug', 'confirmStoryChange', "bugID=$bug->id"), $lang->confirm, 'hiddenwin');
echo ")";
}
?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->task;?></td>
<td><?php if($bug->task) echo html::a($this->createLink('task', 'view', "taskID=$bug->task"), $bug->taskName);?></td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><?php echo $lang->bug->legendMisc;?></legend>
<table class='table-1 a-left fixed'>
<tr>
<td class='rowhead w-p20'><?php echo $lang->bug->mailto;?></td>
<td><?php $mailto = explode(',', str_replace(' ', '', $bug->mailto)); foreach($mailto as $account) echo ' ' . $users[$account]; ?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->linkBug;?></td>
<td>
<?php
if(isset($bug->linkBugTitles))
{
foreach($bug->linkBugTitles as $linkBugID => $linkBugTitle)
{
echo html::a($this->createLink('bug', 'view', "bugID=$linkBugID"), "#$linkBugID $linkBugTitle", '_blank') . '<br />';
}
}
?>
</td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->case;?></td>
<td><?php if(isset($bug->caseTitle)) echo html::a($this->createLink('testcase', 'view', "caseID=$bug->case"), "#$bug->case $bug->caseTitle", '_blank');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->toStory;?></td>
<td><?php if($bug->toStory != 0) echo html::a($this->createLink('story', 'view', "storyID=$bug->toStory"), "#$bug->toStory $bug->toStoryTitle", '_blank');?></td>
</tr>
<tr>
<td class='rowhead'><?php echo $lang->bug->toTask;?></td>
<td><?php if($bug->toTask != 0) echo html::a($this->createLink('bug', 'view', "bugID=$bug->toTask"), "#$bug->toTask $bug->toTaskTitle", '_blank');?></td>
</tr>
</table>
</fieldset>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,186 +1,186 @@
<?php
/**
* The control file of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
class build extends control
{
/**
* Create a buld.
*
* @param int $projectID
* @access public
* @return void
*/
public function create($projectID)
{
if(!empty($_POST))
{
$buildID = $this->build->create($projectID);
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('build', $buildID, 'opened');
die(js::locate($this->createLink('project', 'build', "project=$projectID"), 'parent'));
}
/* Load these models. */
$this->loadModel('story');
$this->loadModel('bug');
$this->loadModel('task');
$this->loadModel('project');
$this->loadModel('user');
/* Set menu. */
$this->project->setMenu($this->project->getPairs(), $projectID);
/* Get stories and bugs. */
$orderBy = 'status_asc, stage_asc, id_desc';
$stories = $this->story->getProjectStories($projectID, $orderBy);
$bugs = $this->project->getResolvedBugs($projectID);
/* Assign. */
$this->view->header->title = $this->lang->build->create;
$this->view->products = $this->project->getProducts($projectID);
$this->view->projectID = $projectID;
$this->view->users = $this->user->getPairs();
$this->view->stories = $stories;
$this->view->bugs = $bugs;
$this->view->orderBy = $orderBy;
$this->display();
}
/**
* Edit a build.
*
* @param int $buildID
* @access public
* @return void
*/
public function edit($buildID)
{
if(!empty($_POST))
{
$changes = $this->build->update($buildID);
if(dao::isError()) die(js::error(dao::getError()));
if($changes)
{
$actionID = $this->loadModel('action')->create('build', $buildID, 'edited');
$this->action->logHistory($actionID, $changes);
}
die(js::locate(inlink('view', "buildID=$buildID"), 'parent'));
}
$this->loadModel('story');
$this->loadModel('bug');
$this->loadModel('project');
/* Set menu. */
$build = $this->build->getById((int)$buildID);
$this->project->setMenu($this->project->getPairs(), $build->project);
/* Get stories and bugs. */
$orderBy = 'status_asc, stage_asc, id_desc';
$stories = $this->story->getProjectStories($build->project, $orderBy);
$bugs = $this->project->getResolvedBugs($build->project);
/* Assign. */
$this->view->header->title = $this->lang->build->edit;
$this->view->position[] = $this->lang->build->edit;
$this->view->products = $this->project->getProducts($build->project);
$this->view->users = $this->loadModel('user')->getPairs();
$this->view->build = $build;
$this->view->stories = $stories;
$this->view->bugs = $bugs;
$this->view->orderBy = $orderBy;
$this->display();
}
/**
* View a build.
*
* @param int $buildID
* @access public
* @return void
*/
public function view($buildID)
{
$this->loadModel('story');
$this->loadModel('bug');
/* Set menu. */
$build = $this->build->getById((int)$buildID);
if(!$build) die(js::error($this->lang->notFound) . js::locate('back'));
$stories = $this->dao->select('*')->from(TABLE_STORY)->where('id')->in($build->stories)->fetchAll();
$bugs = $this->dao->select('*')->from(TABLE_BUG)->where('id')->in($build->bugs)->fetchAll();
$this->loadModel('project')->setMenu($this->project->getPairs(), $build->project);
/* Assign. */
$this->view->header->title = $this->lang->build->view;
$this->view->position[] = $this->lang->build->view;
$this->view->products = $this->project->getProducts($build->project);
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->build = $build;
$this->view->stories = $stories;
$this->view->bugs = $bugs;
$this->view->actions = $this->loadModel('action')->getList('build', $buildID);
$this->display();
}
/**
* Delete a build.
*
* @param int $buildID
* @param string $confirm yes|noe
* @access public
* @return void
*/
public function delete($buildID, $confirm = 'no')
{
if($confirm == 'no')
{
die(js::confirm($this->lang->build->confirmDelete, $this->createLink('build', 'delete', "buildID=$buildID&confirm=yes")));
}
else
{
$build = $this->build->getById($buildID);
$this->build->delete(TABLE_BUILD, $buildID);
die(js::locate($this->createLink('project', 'build', "projectID=$build->project"), 'parent'));
}
}
/**
* AJAX: get builds of a product in html select.
*
* @param int $productID
* @param string $varName the name of the select object to create
* @param string $build build to selected
* @access public
* @return string
*/
public function ajaxGetProductBuilds($productID, $varName, $build = '')
{
if($varName == 'openedBuild') die(html::select($varName . '[]', $this->build->getProductBuildPairs($productID, 'noempty'), $build, 'size=4 class=select-3 multiple'));
if($varName == 'resolvedBuild') die(html::select($varName, $this->build->getProductBuildPairs($productID, 'noempty'), $build, 'class=select-3'));
}
/**
* AJAX: get builds of a project in html select.
*
* @param int $projectID
* @param string $varName the name of the select object to create
* @param string $build build to selected
* @access public
* @return string
*/
public function ajaxGetProjectBuilds($projectID, $productID, $varName, $build = '')
{
if($varName == 'openedBuild') die(html::select($varName . '[]', $this->build->getProjectBuildPairs($projectID, $productID, 'noempty'), $build, 'size=4 class=select-3 multiple'));
if($varName == 'resolvedBuild') die(html::select($varName, $this->build->getProjectBuildPairs($projectID, $productID, 'noempty'), $build, 'class=select-3'));
}
}
<?php
/**
* The control file of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
class build extends control
{
/**
* Create a buld.
*
* @param int $projectID
* @access public
* @return void
*/
public function create($projectID)
{
if(!empty($_POST))
{
$buildID = $this->build->create($projectID);
if(dao::isError()) die(js::error(dao::getError()));
$this->loadModel('action')->create('build', $buildID, 'opened');
die(js::locate($this->createLink('project', 'build', "project=$projectID"), 'parent'));
}
/* Load these models. */
$this->loadModel('story');
$this->loadModel('bug');
$this->loadModel('task');
$this->loadModel('project');
$this->loadModel('user');
/* Set menu. */
$this->project->setMenu($this->project->getPairs(), $projectID);
/* Get stories and bugs. */
$orderBy = 'status_asc, stage_asc, id_desc';
$stories = $this->story->getProjectStories($projectID, $orderBy);
$bugs = $this->project->getResolvedBugs($projectID);
/* Assign. */
$this->view->header->title = $this->lang->build->create;
$this->view->products = $this->project->getProducts($projectID);
$this->view->projectID = $projectID;
$this->view->users = $this->user->getPairs();
$this->view->stories = $stories;
$this->view->bugs = $bugs;
$this->view->orderBy = $orderBy;
$this->display();
}
/**
* Edit a build.
*
* @param int $buildID
* @access public
* @return void
*/
public function edit($buildID)
{
if(!empty($_POST))
{
$changes = $this->build->update($buildID);
if(dao::isError()) die(js::error(dao::getError()));
if($changes)
{
$actionID = $this->loadModel('action')->create('build', $buildID, 'edited');
$this->action->logHistory($actionID, $changes);
}
die(js::locate(inlink('view', "buildID=$buildID"), 'parent'));
}
$this->loadModel('story');
$this->loadModel('bug');
$this->loadModel('project');
/* Set menu. */
$build = $this->build->getById((int)$buildID);
$this->project->setMenu($this->project->getPairs(), $build->project);
/* Get stories and bugs. */
$orderBy = 'status_asc, stage_asc, id_desc';
$stories = $this->story->getProjectStories($build->project, $orderBy);
$bugs = $this->project->getResolvedBugs($build->project);
/* Assign. */
$this->view->header->title = $this->lang->build->edit;
$this->view->position[] = $this->lang->build->edit;
$this->view->products = $this->project->getProducts($build->project);
$this->view->users = $this->loadModel('user')->getPairs();
$this->view->build = $build;
$this->view->stories = $stories;
$this->view->bugs = $bugs;
$this->view->orderBy = $orderBy;
$this->display();
}
/**
* View a build.
*
* @param int $buildID
* @access public
* @return void
*/
public function view($buildID)
{
$this->loadModel('story');
$this->loadModel('bug');
/* Set menu. */
$build = $this->build->getById((int)$buildID);
if(!$build) die(js::error($this->lang->notFound) . js::locate('back'));
$stories = $this->dao->select('*')->from(TABLE_STORY)->where('id')->in($build->stories)->fetchAll();
$bugs = $this->dao->select('*')->from(TABLE_BUG)->where('id')->in($build->bugs)->fetchAll();
$this->loadModel('project')->setMenu($this->project->getPairs(), $build->project);
/* Assign. */
$this->view->header->title = $this->lang->build->view;
$this->view->position[] = $this->lang->build->view;
$this->view->products = $this->project->getProducts($build->project);
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->build = $build;
$this->view->stories = $stories;
$this->view->bugs = $bugs;
$this->view->actions = $this->loadModel('action')->getList('build', $buildID);
$this->display();
}
/**
* Delete a build.
*
* @param int $buildID
* @param string $confirm yes|noe
* @access public
* @return void
*/
public function delete($buildID, $confirm = 'no')
{
if($confirm == 'no')
{
die(js::confirm($this->lang->build->confirmDelete, $this->createLink('build', 'delete', "buildID=$buildID&confirm=yes")));
}
else
{
$build = $this->build->getById($buildID);
$this->build->delete(TABLE_BUILD, $buildID);
die(js::locate($this->createLink('project', 'build', "projectID=$build->project"), 'parent'));
}
}
/**
* AJAX: get builds of a product in html select.
*
* @param int $productID
* @param string $varName the name of the select object to create
* @param string $build build to selected
* @access public
* @return string
*/
public function ajaxGetProductBuilds($productID, $varName, $build = '')
{
if($varName == 'openedBuild') die(html::select($varName . '[]', $this->build->getProductBuildPairs($productID, 'noempty'), $build, 'size=4 class=select-3 multiple'));
if($varName == 'resolvedBuild') die(html::select($varName, $this->build->getProductBuildPairs($productID, 'noempty'), $build, 'class=select-3'));
}
/**
* AJAX: get builds of a project in html select.
*
* @param int $projectID
* @param string $varName the name of the select object to create
* @param string $build build to selected
* @access public
* @return string
*/
public function ajaxGetProjectBuilds($projectID, $productID, $varName, $build = '')
{
if($varName == 'openedBuild') die(html::select($varName . '[]', $this->build->getProjectBuildPairs($projectID, $productID, 'noempty'), $build, 'size=4 class=select-3 multiple'));
if($varName == 'resolvedBuild') die(html::select($varName, $this->build->getProjectBuildPairs($projectID, $productID, 'noempty'), $build, 'class=select-3'));
}
}

View File

@@ -1,35 +1,35 @@
<?php
/**
* The build module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
$lang->build->common = 'Build';
$lang->build->create = "Create";
$lang->build->edit = "Edit";
$lang->build->delete = "Delete";
$lang->build->view = "Info";
$lang->build->ajaxGetProductBuilds = 'API:Product builds';
$lang->build->ajaxGetProjectBuilds = 'API:Project builds';
$lang->build->confirmDelete = "Are sure to delete this build?";
$lang->build->id = 'ID';
$lang->build->product = 'Product';
$lang->build->project = 'Project';
$lang->build->name = 'Name';
$lang->build->date = 'Build date';
$lang->build->builder = 'Builder';
$lang->build->scmPath = 'Source code path';
$lang->build->filePath = 'Package file path';
$lang->build->desc = 'Desc';
$lang->build->linkStoriesAndBugs = 'stories and bugs';
$lang->build->linkStories = 'Stories';
$lang->build->linkBugs = 'Bugs';
$lang->build->stories = 'Linked stories';
$lang->build->bugs = 'Linked bugs';
<?php
/**
* The build module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
$lang->build->common = 'Build';
$lang->build->create = "Create";
$lang->build->edit = "Edit";
$lang->build->delete = "Delete";
$lang->build->view = "Info";
$lang->build->ajaxGetProductBuilds = 'API:Product builds';
$lang->build->ajaxGetProjectBuilds = 'API:Project builds';
$lang->build->confirmDelete = "Are sure to delete this build?";
$lang->build->id = 'ID';
$lang->build->product = 'Product';
$lang->build->project = 'Project';
$lang->build->name = 'Name';
$lang->build->date = 'Build date';
$lang->build->builder = 'Builder';
$lang->build->scmPath = 'Source code path';
$lang->build->filePath = 'Package file path';
$lang->build->desc = 'Desc';
$lang->build->linkStoriesAndBugs = 'stories and bugs';
$lang->build->linkStories = 'Stories';
$lang->build->linkBugs = 'Bugs';
$lang->build->stories = 'Linked stories';
$lang->build->bugs = 'Linked bugs';

View File

@@ -1,35 +1,35 @@
<?php
/**
* The build module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
$lang->build->common = 'Build';
$lang->build->create = "创建Build";
$lang->build->edit = "编辑Build";
$lang->build->delete = "删除Build";
$lang->build->view = "Build详情";
$lang->build->ajaxGetProductBuilds = '接口:产品Build列表';
$lang->build->ajaxGetProjectBuilds = '接口:项目Build列表';
$lang->build->confirmDelete = "您确认删除该build吗";
$lang->build->id = 'ID';
$lang->build->product = '产品';
$lang->build->project = '项目';
$lang->build->name = '名称编号';
$lang->build->date = 'Build日期';
$lang->build->builder = '构建者';
$lang->build->scmPath = '源代码地址';
$lang->build->filePath = '存储地址';
$lang->build->desc = '描述';
$lang->build->linkStoriesAndBugs = '关联需求和Bug';
$lang->build->linkStories = '相关需求';
$lang->build->linkBugs = '相关Bug';
$lang->build->stories = '已关联需求';
$lang->build->bugs = '已关联Bug';
<?php
/**
* The build module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
$lang->build->common = 'Build';
$lang->build->create = "创建Build";
$lang->build->edit = "编辑Build";
$lang->build->delete = "删除Build";
$lang->build->view = "Build详情";
$lang->build->ajaxGetProductBuilds = '接口:产品Build列表';
$lang->build->ajaxGetProjectBuilds = '接口:项目Build列表';
$lang->build->confirmDelete = "您确认删除该build吗";
$lang->build->id = 'ID';
$lang->build->product = '产品';
$lang->build->project = '项目';
$lang->build->name = '名称编号';
$lang->build->date = 'Build日期';
$lang->build->builder = '构建者';
$lang->build->scmPath = '源代码地址';
$lang->build->filePath = '存储地址';
$lang->build->desc = '描述';
$lang->build->linkStoriesAndBugs = '关联需求和Bug';
$lang->build->linkStories = '相关需求';
$lang->build->linkBugs = '相关Bug';
$lang->build->stories = '已关联需求';
$lang->build->bugs = '已关联Bug';

View File

@@ -1,35 +1,35 @@
<?php
/**
* The build module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id: zh-tw.php 2527 2012-01-04 00:16:23Z wwccss $
* @link http://www.zentao.net
*/
$lang->build->common = 'Build';
$lang->build->create = "創建Build";
$lang->build->edit = "編輯Build";
$lang->build->delete = "刪除Build";
$lang->build->view = "Build詳情";
$lang->build->ajaxGetProductBuilds = '介面:產品Build列表';
$lang->build->ajaxGetProjectBuilds = '介面:項目Build列表';
$lang->build->confirmDelete = "您確認刪除該build嗎";
$lang->build->id = 'ID';
$lang->build->product = '產品';
$lang->build->project = '項目';
$lang->build->name = '名稱編號';
$lang->build->date = 'Build日期';
$lang->build->builder = '構建者';
$lang->build->scmPath = '原始碼地址';
$lang->build->filePath = '存儲地址';
$lang->build->desc = '描述';
$lang->build->linkStoriesAndBugs = '關聯需求和Bug';
$lang->build->linkStories = '相關需求';
$lang->build->linkBugs = '相關Bug';
$lang->build->stories = '已關聯需求';
$lang->build->bugs = '已關聯Bug';
<?php
/**
* The build module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id: zh-tw.php 2527 2012-01-04 00:16:23Z wwccss $
* @link http://www.zentao.net
*/
$lang->build->common = 'Build';
$lang->build->create = "創建Build";
$lang->build->edit = "編輯Build";
$lang->build->delete = "刪除Build";
$lang->build->view = "Build詳情";
$lang->build->ajaxGetProductBuilds = '介面:產品Build列表';
$lang->build->ajaxGetProjectBuilds = '介面:項目Build列表';
$lang->build->confirmDelete = "您確認刪除該build嗎";
$lang->build->id = 'ID';
$lang->build->product = '產品';
$lang->build->project = '項目';
$lang->build->name = '名稱編號';
$lang->build->date = 'Build日期';
$lang->build->builder = '構建者';
$lang->build->scmPath = '原始碼地址';
$lang->build->filePath = '存儲地址';
$lang->build->desc = '描述';
$lang->build->linkStoriesAndBugs = '關聯需求和Bug';
$lang->build->linkStories = '相關需求';
$lang->build->linkBugs = '相關Bug';
$lang->build->stories = '已關聯需求';
$lang->build->bugs = '已關聯Bug';

View File

@@ -1,152 +1,152 @@
<?php
/**
* The model file of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class buildModel extends model
{
/**
* Get build info.
*
* @param int $buildID
* @access public
* @return object
*/
public function getByID($buildID)
{
$build = $this->dao->select('t1.*, t2.name as projectName, t3.name as productName')
->from(TABLE_BUILD)->alias('t1')
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id')
->leftJoin(TABLE_PRODUCT)->alias('t3')->on('t1.product = t3.id')
->where('t1.id')->eq((int)$buildID)
->orderBy('t1.id DESC')
->fetch();
if(!$build) return false;
$build->desc = $this->loadModel('file')->setImgSize($build->desc);
return $build;
}
/**
* Get builds of a project.
*
* @param int $projectID
* @access public
* @return array
*/
public function getProjectBuilds($projectID)
{
return $this->dao->select('t1.*, t2.name as projectName, t3.name as productName')
->from(TABLE_BUILD)->alias('t1')
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id')
->leftJoin(TABLE_PRODUCT)->alias('t3')->on('t1.product = t3.id')
->where('t1.project')->eq((int)$projectID)
->andWhere('t1.deleted')->eq(0)
->orderBy('t1.date DESC, t1.id desc')
->fetchAll();
}
/**
* Get builds of a project in pairs.
*
* @param int $projectID
* @param int $productID
* @param string $params noempty|notrunk, can be a set of them
* @access public
* @return array
*/
public function getProjectBuildPairs($projectID, $productID, $params = '')
{
$sysBuilds = array();
if(strpos($params, 'noempty') === false) $sysBuilds = array('' => '');
if(strpos($params, 'notrunk') === false) $sysBuilds = $sysBuilds + array('trunk' => 'Trunk');
$builds = $this->dao->select('id,name')->from(TABLE_BUILD)
->where('project')->eq((int)$projectID)
->beginIF($productID)->andWhere('product')->eq((int)$productID)->fi()
->andWhere('deleted')->eq(0)
->orderBy('date desc, id desc')->fetchPairs();
if(!$builds) return $sysBuilds;
$releases = $this->dao->select('build,name')->from(TABLE_RELEASE)
->where('build')->in(array_keys($builds))
->andWhere('deleted')->eq(0)
->fetchPairs();
foreach($releases as $buildID => $releaseName) $builds[$buildID] = $releaseName;
return $sysBuilds + $builds;
}
/**
* Get builds of a product in pairs.
*
* @param int $productID
* @param string $params noempty|notrunk, can be a set of them
* @access public
* @return string
*/
public function getProductBuildPairs($productID, $params = '')
{
$sysBuilds = array();
if(strpos($params, 'noempty') === false) $sysBuilds = array('' => '');
if(strpos($params, 'notrunk') === false) $sysBuilds = $sysBuilds + array('trunk' => 'Trunk');
$builds = $this->dao->select('id,name')->from(TABLE_BUILD)
->where('product')->eq((int)$productID)
->andWhere('deleted')->eq(0)
->orderBy('date desc, id desc')->fetchPairs();
if(!$builds) return $sysBuilds;
return $sysBuilds + $builds;
}
/**
* Create a build
*
* @param int $projectID
* @access public
* @return void
*/
public function create($projectID)
{
$build->stories = '';
$build->bugs = '';
$build = fixer::input('post')->stripTags('name')
->join('stories', ',')
->join('bugs', ',')
->add('project', (int)$projectID)->get();
$this->dao->insert(TABLE_BUILD)->data($build)->autoCheck()->batchCheck($this->config->build->create->requiredFields, 'notempty')->check('name','unique')->exec();
if(!dao::isError()) return $this->dao->lastInsertID();
}
/**
* Update a build.
*
* @param int $buildID
* @access public
* @return void
*/
public function update($buildID)
{
$oldBuild = $this->getByID($buildID);
$build = fixer::input('post')
->stripTags('name')
->setDefault('stories', '')
->setDefault('bugs', '')
->join('stories', ',')
->join('bugs', ',')
->get();
$this->dao->update(TABLE_BUILD)->data($build)
->autoCheck()
->batchCheck($this->config->build->edit->requiredFields, 'notempty')
->where('id')->eq((int)$buildID)
->check('name','unique', "id != $buildID")
->exec();
if(!dao::isError()) return common::createChanges($oldBuild, $build);
}
}
<?php
/**
* The model file of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class buildModel extends model
{
/**
* Get build info.
*
* @param int $buildID
* @access public
* @return object
*/
public function getByID($buildID)
{
$build = $this->dao->select('t1.*, t2.name as projectName, t3.name as productName')
->from(TABLE_BUILD)->alias('t1')
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id')
->leftJoin(TABLE_PRODUCT)->alias('t3')->on('t1.product = t3.id')
->where('t1.id')->eq((int)$buildID)
->orderBy('t1.id DESC')
->fetch();
if(!$build) return false;
$build->desc = $this->loadModel('file')->setImgSize($build->desc);
return $build;
}
/**
* Get builds of a project.
*
* @param int $projectID
* @access public
* @return array
*/
public function getProjectBuilds($projectID)
{
return $this->dao->select('t1.*, t2.name as projectName, t3.name as productName')
->from(TABLE_BUILD)->alias('t1')
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id')
->leftJoin(TABLE_PRODUCT)->alias('t3')->on('t1.product = t3.id')
->where('t1.project')->eq((int)$projectID)
->andWhere('t1.deleted')->eq(0)
->orderBy('t1.date DESC, t1.id desc')
->fetchAll();
}
/**
* Get builds of a project in pairs.
*
* @param int $projectID
* @param int $productID
* @param string $params noempty|notrunk, can be a set of them
* @access public
* @return array
*/
public function getProjectBuildPairs($projectID, $productID, $params = '')
{
$sysBuilds = array();
if(strpos($params, 'noempty') === false) $sysBuilds = array('' => '');
if(strpos($params, 'notrunk') === false) $sysBuilds = $sysBuilds + array('trunk' => 'Trunk');
$builds = $this->dao->select('id,name')->from(TABLE_BUILD)
->where('project')->eq((int)$projectID)
->beginIF($productID)->andWhere('product')->eq((int)$productID)->fi()
->andWhere('deleted')->eq(0)
->orderBy('date desc, id desc')->fetchPairs();
if(!$builds) return $sysBuilds;
$releases = $this->dao->select('build,name')->from(TABLE_RELEASE)
->where('build')->in(array_keys($builds))
->andWhere('deleted')->eq(0)
->fetchPairs();
foreach($releases as $buildID => $releaseName) $builds[$buildID] = $releaseName;
return $sysBuilds + $builds;
}
/**
* Get builds of a product in pairs.
*
* @param int $productID
* @param string $params noempty|notrunk, can be a set of them
* @access public
* @return string
*/
public function getProductBuildPairs($productID, $params = '')
{
$sysBuilds = array();
if(strpos($params, 'noempty') === false) $sysBuilds = array('' => '');
if(strpos($params, 'notrunk') === false) $sysBuilds = $sysBuilds + array('trunk' => 'Trunk');
$builds = $this->dao->select('id,name')->from(TABLE_BUILD)
->where('product')->eq((int)$productID)
->andWhere('deleted')->eq(0)
->orderBy('date desc, id desc')->fetchPairs();
if(!$builds) return $sysBuilds;
return $sysBuilds + $builds;
}
/**
* Create a build
*
* @param int $projectID
* @access public
* @return void
*/
public function create($projectID)
{
$build->stories = '';
$build->bugs = '';
$build = fixer::input('post')->stripTags('name')
->join('stories', ',')
->join('bugs', ',')
->add('project', (int)$projectID)->get();
$this->dao->insert(TABLE_BUILD)->data($build)->autoCheck()->batchCheck($this->config->build->create->requiredFields, 'notempty')->check('name','unique')->exec();
if(!dao::isError()) return $this->dao->lastInsertID();
}
/**
* Update a build.
*
* @param int $buildID
* @access public
* @return void
*/
public function update($buildID)
{
$oldBuild = $this->getByID($buildID);
$build = fixer::input('post')
->stripTags('name')
->setDefault('stories', '')
->setDefault('bugs', '')
->join('stories', ',')
->join('bugs', ',')
->get();
$this->dao->update(TABLE_BUILD)->data($build)
->autoCheck()
->batchCheck($this->config->build->edit->requiredFields, 'notempty')
->where('id')->eq((int)$buildID)
->check('name','unique', "id != $buildID")
->exec();
if(!dao::isError()) return common::createChanges($oldBuild, $build);
}
}

View File

@@ -1,97 +1,97 @@
<?php
/**
* The create view of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->create;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->build->product;?></th>
<td><?php echo html::select('product', $products, '', "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->name;?></th>
<td><?php echo html::input('name', '', "class='text-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->builder;?></th>
<td><?php echo html::select('builder', $users, $app->user->account, 'class="select-3"');?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->date;?></th>
<td><?php echo html::input('date', helper::today(), "class='text-3 date'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->scmPath;?></th>
<td><?php echo html::input('scmPath', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->filePath;?></th>
<td><?php echo html::input('filePath', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->linkStoriesAndBugs;?></th>
<td>
<div class="w-p90">
<div class='half-left linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkStories;?></caption>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->story->title;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->story->stageAB;?></th>
</tr>
<?php foreach($stories as $key => $story):?>
<?php
$storyLink = $this->createLink('story', 'view', "storyID=$story->id");
?>
<tr class='a-center'>
<td><input type='checkbox' name='stories[]' value="<?php echo $story->id;?>" <?php if($story->stage == 'developed') echo 'checked';?>> <?php echo sprintf('%03d', $story->id);?></td>
<td class='a-left nobr'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td class='<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
<div class='half-right linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkBugs;?></caption>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-100px'><?php echo $lang->bug->status;?></th>
</tr>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id");?>
<tr class='a-center'>
<td><input type='checkbox' name='bugs[]' value="<?php echo $bug->id;?>" checked> <?php echo sprintf('%03d', $bug->id);?></td>
<td class='a-left nobr'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->desc;?></th>
<td><?php echo html::textarea('desc', '', "rows='10' class='area-1'");?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton() . html::resetButton();?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The create view of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->create;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->build->product;?></th>
<td><?php echo html::select('product', $products, '', "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->name;?></th>
<td><?php echo html::input('name', '', "class='text-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->builder;?></th>
<td><?php echo html::select('builder', $users, $app->user->account, 'class="select-3"');?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->date;?></th>
<td><?php echo html::input('date', helper::today(), "class='text-3 date'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->scmPath;?></th>
<td><?php echo html::input('scmPath', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->filePath;?></th>
<td><?php echo html::input('filePath', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->linkStoriesAndBugs;?></th>
<td>
<div class="w-p90">
<div class='half-left linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkStories;?></caption>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->story->title;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->story->stageAB;?></th>
</tr>
<?php foreach($stories as $key => $story):?>
<?php
$storyLink = $this->createLink('story', 'view', "storyID=$story->id");
?>
<tr class='a-center'>
<td><input type='checkbox' name='stories[]' value="<?php echo $story->id;?>" <?php if($story->stage == 'developed') echo 'checked';?>> <?php echo sprintf('%03d', $story->id);?></td>
<td class='a-left nobr'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td class='<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
<div class='half-right linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkBugs;?></caption>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-100px'><?php echo $lang->bug->status;?></th>
</tr>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id");?>
<tr class='a-center'>
<td><input type='checkbox' name='bugs[]' value="<?php echo $bug->id;?>" checked> <?php echo sprintf('%03d', $bug->id);?></td>
<td class='a-left nobr'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->desc;?></th>
<td><?php echo html::textarea('desc', '', "rows='10' class='area-1'");?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton() . html::resetButton();?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,97 +1,97 @@
<?php
/**
* The edit view of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->build->edit;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->build->product;?></th>
<td><?php echo html::select('product', $products, $build->product, "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->name;?></th>
<td><?php echo html::input('name', $build->name, "class='text-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->builder;?></th>
<td><?php echo html::select('builder', $users, $build->builder, 'class="select-3"');?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->date;?></th>
<td><?php echo html::input('date', $build->date, "class='text-3 date'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->scmPath;?></th>
<td><?php echo html::input('scmPath', $build->scmPath, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->filePath;?></th>
<td><?php echo html::input('filePath', $build->filePath, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->linkStoriesAndBugs;?></th>
<td>
<div class="w-p90">
<div class='half-left linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkStories;?></caption>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->story->title;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->story->stageAB;?></th>
</tr>
<?php foreach($stories as $key => $story):?>
<?php
$storyLink = $this->createLink('story', 'view', "storyID=$story->id");
?>
<tr class='a-center'>
<td><input type='checkbox' name='stories[]' value="<?php echo $story->id;?>" <?php if(strpos($build->stories, $story->id) !== false) echo 'checked';?>> <?php echo sprintf('%03d', $story->id);?></td>
<td class='a-left nobr'><?php echo html::a($storyLink, $story->title, '', "class='preview'");?></td>
<td class='<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
<div class='half-right linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkBugs;?></caption>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-100px'><?php echo $lang->bug->status;?></th>
</tr>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id");?>
<tr class='a-center'>
<td><input type='checkbox' name='bugs[]' value="<?php echo $bug->id;?>" <?php if(strpos($build->bugs, $bug->id) !== false) echo 'checked';?>> <?php echo sprintf('%03d', $bug->id);?></td>
<td class='a-left nobr'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->desc;?></th>
<td><?php echo html::textarea('desc', htmlspecialchars($build->desc), "rows='15' class='area-1'");?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton() . html::resetButton() .html::hidden('project', $build->project);?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The edit view of build module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/datepicker.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->build->edit;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->build->product;?></th>
<td><?php echo html::select('product', $products, $build->product, "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->name;?></th>
<td><?php echo html::input('name', $build->name, "class='text-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->builder;?></th>
<td><?php echo html::select('builder', $users, $build->builder, 'class="select-3"');?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->date;?></th>
<td><?php echo html::input('date', $build->date, "class='text-3 date'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->scmPath;?></th>
<td><?php echo html::input('scmPath', $build->scmPath, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->filePath;?></th>
<td><?php echo html::input('filePath', $build->filePath, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->linkStoriesAndBugs;?></th>
<td>
<div class="w-p90">
<div class='half-left linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkStories;?></caption>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->story->title;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->story->stageAB;?></th>
</tr>
<?php foreach($stories as $key => $story):?>
<?php
$storyLink = $this->createLink('story', 'view', "storyID=$story->id");
?>
<tr class='a-center'>
<td><input type='checkbox' name='stories[]' value="<?php echo $story->id;?>" <?php if(strpos($build->stories, $story->id) !== false) echo 'checked';?>> <?php echo sprintf('%03d', $story->id);?></td>
<td class='a-left nobr'><?php echo html::a($storyLink, $story->title, '', "class='preview'");?></td>
<td class='<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
<div class='half-right linkbox'>
<table class='table-1 fixed'>
<caption><?php echo $lang->build->linkBugs;?></caption>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-100px'><?php echo $lang->bug->status;?></th>
</tr>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id");?>
<tr class='a-center'>
<td><input type='checkbox' name='bugs[]' value="<?php echo $bug->id;?>" <?php if(strpos($build->bugs, $bug->id) !== false) echo 'checked';?>> <?php echo sprintf('%03d', $bug->id);?></td>
<td class='a-left nobr'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->desc;?></th>
<td><?php echo html::textarea('desc', htmlspecialchars($build->desc), "rows='15' class='area-1'");?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton() . html::resetButton() .html::hidden('project', $build->project);?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,117 +1,117 @@
<?php
/**
* The view file of build module's view method of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<table class='table-1'>
<caption><?php echo $lang->build->view;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->build->product;?></th>
<td><?php echo $build->productName;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->name;?></th>
<td class='<?php if($build->deleted) echo 'deleted';?>'><?php echo $build->name;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->builder;?></th>
<td><?php echo $users[$build->builder];?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->date;?></th>
<td><?php echo $build->date;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->scmPath;?></th>
<td><?php strpos($build->scmPath, 'http') === 0 ? printf(html::a($build->scmPath)) : printf($build->scmPath);?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->filePath;?></th>
<td><?php strpos($build->filePath, 'http') === 0 ? printf(html::a($build->filePath)) : printf($build->filePath);?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->stories;?></th>
<td>
<div style="height:225px; overflow-y:auto">
<table class='table-1 fixed'>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th><?php echo $lang->story->title;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-hour'><?php echo $lang->story->estimateAB;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->story->stageAB;?></th>
</tr>
<?php foreach($stories as $storyID => $story):?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$story->id");?>
<tr class='a-center'>
<td><?php echo sprintf('%03d', $story->id);?></td>
<td><?php echo $lang->story->priList[$story->pri];?></td>
<td class='a-left nobr'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td><?php echo $users[$story->openedBy];?></td>
<td><?php echo $story->estimate;?></td>
<td class='<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->bugs;?></th>
<td>
<div style="height:225px; overflow-y:auto">
<table class='table-1 fixed'>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-100px'><?php echo $lang->bug->status;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-date'><?php echo $lang->bug->openedDateAB;?></th>
<th class='w-user'><?php echo $lang->bug->resolvedByAB;?></th>
<th class='w-date'><?php echo $lang->bug->resolvedDateAB;?></th>
</tr>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id");?>
<tr class='a-center'>
<td><?php echo sprintf('%03d', $bug->id);?></td>
<td class='a-left nobr'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->desc;?></th>
<td class='content'><?php echo $build->desc;?></td>
</tr>
</table>
<div class='a-center f-16px strong'>
<?php
$browseLink = $this->session->buildList ? $this->session->buildList : $this->createLink('project', 'build', "projectID=$build->project");
if(!$build->deleted)
{
common::printLink('build', 'edit', "buildID=$build->id", $lang->edit);
common::printLink('build', 'delete', "buildID=$build->id", $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
<?php include '../../common/view/action.html.php';?>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The view file of build module's view method of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package build
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<table class='table-1'>
<caption><?php echo $lang->build->view;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->build->product;?></th>
<td><?php echo $build->productName;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->name;?></th>
<td class='<?php if($build->deleted) echo 'deleted';?>'><?php echo $build->name;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->builder;?></th>
<td><?php echo $users[$build->builder];?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->date;?></th>
<td><?php echo $build->date;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->scmPath;?></th>
<td><?php strpos($build->scmPath, 'http') === 0 ? printf(html::a($build->scmPath)) : printf($build->scmPath);?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->filePath;?></th>
<td><?php strpos($build->filePath, 'http') === 0 ? printf(html::a($build->filePath)) : printf($build->filePath);?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->stories;?></th>
<td>
<div style="height:225px; overflow-y:auto">
<table class='table-1 fixed'>
<tr>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th class='w-pri'><?php echo $lang->priAB;?></th>
<th><?php echo $lang->story->title;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-hour'><?php echo $lang->story->estimateAB;?></th>
<th class='w-hour'><?php echo $lang->statusAB;?></th>
<th class='w-100px'><?php echo $lang->story->stageAB;?></th>
</tr>
<?php foreach($stories as $storyID => $story):?>
<?php $storyLink = $this->createLink('story', 'view', "storyID=$story->id");?>
<tr class='a-center'>
<td><?php echo sprintf('%03d', $story->id);?></td>
<td><?php echo $lang->story->priList[$story->pri];?></td>
<td class='a-left nobr'><?php echo html::a($storyLink,$story->title, '', "class='preview'");?></td>
<td><?php echo $users[$story->openedBy];?></td>
<td><?php echo $story->estimate;?></td>
<td class='<?php echo $story->status;?>'><?php echo $lang->story->statusList[$story->status];?></td>
<td><?php echo $lang->story->stageList[$story->stage];?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->bugs;?></th>
<td>
<div style="height:225px; overflow-y:auto">
<table class='table-1 fixed'>
<tr>
<th class='w-id'> <?php echo $lang->idAB;?></th>
<th><?php echo $lang->bug->title;?></th>
<th class='w-100px'><?php echo $lang->bug->status;?></th>
<th class='w-user'><?php echo $lang->openedByAB;?></th>
<th class='w-date'><?php echo $lang->bug->openedDateAB;?></th>
<th class='w-user'><?php echo $lang->bug->resolvedByAB;?></th>
<th class='w-date'><?php echo $lang->bug->resolvedDateAB;?></th>
</tr>
<?php foreach($bugs as $bug):?>
<?php $bugLink = $this->createLink('bug', 'view', "bugID=$bug->id");?>
<tr class='a-center'>
<td><?php echo sprintf('%03d', $bug->id);?></td>
<td class='a-left nobr'><?php echo html::a($bugLink, $bug->title, '', "class='preview'");?></td>
<td><?php echo $lang->bug->statusList[$bug->status];?></td>
<td><?php echo $users[$bug->openedBy];?></td>
<td><?php echo substr($bug->openedDate, 5, 11)?></td>
<td><?php echo $users[$bug->resolvedBy];?></td>
<td><?php echo substr($bug->resolvedDate, 5, 11)?></td>
</tr>
<?php endforeach;?>
</table>
</div>
</td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->build->desc;?></th>
<td class='content'><?php echo $build->desc;?></td>
</tr>
</table>
<div class='a-center f-16px strong'>
<?php
$browseLink = $this->session->buildList ? $this->session->buildList : $this->createLink('project', 'build', "projectID=$build->project");
if(!$build->deleted)
{
common::printLink('build', 'edit', "buildID=$build->id", $lang->edit);
common::printLink('build', 'delete', "buildID=$build->id", $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
<?php include '../../common/view/action.html.php';?>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,265 +1,265 @@
<?php
/**
* The control file of common module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package common
* @version $Id$
* @link http://www.zentao.net
*/
class common extends control
{
/**
* The construc method, to do some auto things.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->common->startSession();
$this->common->sendHeader();
$this->common->setCompany();
$this->common->setUser();
$this->app->loadLang('company');
}
/**
* Check the user has permission to access this method, if not, locate to the login page or deny page.
*
* @access public
* @return void
*/
public function checkPriv()
{
$module = $this->app->getModuleName();
$method = $this->app->getMethodName();
if($this->common->isOpenMethod($module, $method)) return true;
if(!$this->loadModel('user')->isLogon() and $this->server->php_auth_user) $this->user->identifyByPhpAuth();
if(!$this->loadModel('user')->isLogon() and $this->cookie->za) $this->user->identifyByCookie();
if(isset($this->app->user))
{
if(!common::hasPriv($module, $method)) $this->common->deny($module, $method);
}
else
{
$referer = helper::safe64Encode($this->app->getURI(true));
$this->locate($this->createLink('user', 'login', "referer=$referer"));
}
}
/**
* Check upgrade's status file is ok or not.
*
* @access public
* @return void
*/
public function checkUpgradeStatus()
{
$statusFile = $this->app->getAppRoot() . 'www' . $this->pathFix . 'ok';
if(!file_exists($statusFile) or time() - filemtime($statusFile) > 3600)
{
$this->app->loadLang('upgrade');
echo "<html><head><meta http-equiv='Content-Type' content='text/html; charset=utf-8' /></head><body>";
echo "<table align='center' style='margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td>";
printf($this->lang->upgrade->setStatusFile, $statusFile, $statusFile, $statusFile);
die('</td></tr></table></body></html>');
}
}
/**
* Check the user has permisson of one method of one module.
*
* @param string $module
* @param string $method
* @static
* @access public
* @return bool
*/
public static function hasPriv($module, $method)
{
global $app;
/* Check is the super admin or not. */
$account = ',' . $app->user->account . ',';
if(strpos($app->company->admins, $account) !== false) return true;
/* If not super admin, check the rights. */
$rights = $app->user->rights;
if(isset($rights[strtolower($module)][strtolower($method)])) return true;
return false;
}
/**
* Replace the %s of one key of a menu by $params.
*
* All the menus are defined in the common's language file. But there're many dynamic params, so in the defination,
* we used %s as placeholder. These %s should be setted in one module.
*
* The items of one module's menu may be an string or array. For example, please see module/common/lang.
*
* @param string $object the menus of one module
* @param string $key the menu item to be replaced
* @param string $params the params passed to the menu item
* @access public
* @return void
*/
public function setMenuVars($menu, $key, $params)
{
if(is_array($params))
{
if(is_array($menu->$key))
{
$menu->$key = (object)$menu->$key;
$menu->$key->link = vsprintf($menu->$key->link, $params);
$menu->$key = (array)$menu->$key;
}
else
{
$menu->$key = vsprintf($menu->$key, $params);
}
}
else
{
if(is_array($menu->$key))
{
$menu->$key = (object)$menu->$key;
$menu->$key->link = sprintf($menu->$key->link, $params);
$menu->$key = (array)$menu->$key;
}
else
{
$menu->$key = sprintf($menu->$key, $params);
}
}
}
/**
* Print the link contains orderBy field.
*
* This method will auto set the orderby param according the params. Fox example, if the order by is desc,
* will be changed to asc.
*
* @param string $fieldName the field name to sort by
* @param string $orderBy the order by string
* @param string $vars the vars to be passed
* @param string $label the label of the link
* @param string $module the module name
* @param string $method the method name
* @static
* @access public
* @return void
*/
public static function printOrderLink($fieldName, $orderBy, $vars, $label, $module = '', $method = '')
{
global $lang, $app;
if(empty($module)) $module= $app->getModuleName();
if(empty($method)) $method= $app->getMethodName();
$className = 'header';
if(strpos($orderBy, $fieldName) !== false)
{
if(stripos($orderBy, 'desc') !== false)
{
$orderBy = str_ireplace('desc', 'asc', $orderBy);
$className = 'headerSortUp';
}
elseif(stripos($orderBy, 'asc') !== false)
{
$orderBy = str_ireplace('asc', 'desc', $orderBy);
$className = 'headerSortDown';
}
}
else
{
$orderBy = $fieldName . '_' . 'asc';
$className = 'header';
}
$link = helper::createLink($module, $method, sprintf($vars, $orderBy));
echo "<div class='$className'>" . html::a($link, $label) . '</div>';
}
/**
* Print link to an modules' methd.
*
* Before printing, check the privilege first. If no privilege, return fasle. Else, print the link, return true.
*
* @param string $module the module name
* @param string $method the method
* @param string $vars vars to be passed
* @param string $label the label of the link
* @param string $target the target of the link
* @param string $misc others
* @static
* @access public
* @return bool
*/
public static function printLink($module, $method, $vars = '', $label, $target = '', $misc = '')
{
if(!common::hasPriv($module, $method)) return false;
echo html::a(helper::createLink($module, $method, $vars), $label, $target, $misc);
return true;
}
/**
* Create changes of one object.
*
* @param mixed $old the old object
* @param mixed $new the new object
* @static
* @access public
* @return array
*/
public static function createChanges($old, $new)
{
global $config;
$changes = array();
$magicQuote = get_magic_quotes_gpc();
foreach($new as $key => $value)
{
if(strtolower($key) == 'lastediteddate') continue;
if(strtolower($key) == 'lasteditedby') continue;
if(strtolower($key) == 'assigneddate') continue;
if(strtolower($key) == 'editedby') continue;
if(strtolower($key) == 'editeddate') continue;
if($magicQuote) $value = stripslashes($value);
if($value != $old->$key)
{
$diff = '';
if(substr_count($value, "\n") > 1 or substr_count($old->$key, "\n") > 1 or strpos('name,title,desc,spec,steps,content,digest', strtolower($key)) !== false) $diff = commonModel::diff($old->$key, $value);
$changes[] = array('field' => $key, 'old' => $old->$key, 'new' => $value, 'diff' => $diff);
}
}
return $changes;
}
/**
* Get the full url of the system.
*
* @access public
* @return string
*/
public function getSysURL()
{
$httpType = isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] == 'on' ? 'https' : 'http';
$httpHost = $_SERVER['HTTP_HOST'];
return "$httpType://$httpHost";
}
/**
* Print the run info.
*
* @param mixed $startTime the start time.
* @access public
* @return void
*/
public function printRunInfo($startTime)
{
vprintf($this->lang->runInfo, $this->common->getRunInfo($startTime));
}
}
<?php
/**
* The control file of common module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package common
* @version $Id$
* @link http://www.zentao.net
*/
class common extends control
{
/**
* The construc method, to do some auto things.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->common->startSession();
$this->common->sendHeader();
$this->common->setCompany();
$this->common->setUser();
$this->app->loadLang('company');
}
/**
* Check the user has permission to access this method, if not, locate to the login page or deny page.
*
* @access public
* @return void
*/
public function checkPriv()
{
$module = $this->app->getModuleName();
$method = $this->app->getMethodName();
if($this->common->isOpenMethod($module, $method)) return true;
if(!$this->loadModel('user')->isLogon() and $this->server->php_auth_user) $this->user->identifyByPhpAuth();
if(!$this->loadModel('user')->isLogon() and $this->cookie->za) $this->user->identifyByCookie();
if(isset($this->app->user))
{
if(!common::hasPriv($module, $method)) $this->common->deny($module, $method);
}
else
{
$referer = helper::safe64Encode($this->app->getURI(true));
$this->locate($this->createLink('user', 'login', "referer=$referer"));
}
}
/**
* Check upgrade's status file is ok or not.
*
* @access public
* @return void
*/
public function checkUpgradeStatus()
{
$statusFile = $this->app->getAppRoot() . 'www' . $this->pathFix . 'ok';
if(!file_exists($statusFile) or time() - filemtime($statusFile) > 3600)
{
$this->app->loadLang('upgrade');
echo "<html><head><meta http-equiv='Content-Type' content='text/html; charset=utf-8' /></head><body>";
echo "<table align='center' style='margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td>";
printf($this->lang->upgrade->setStatusFile, $statusFile, $statusFile, $statusFile);
die('</td></tr></table></body></html>');
}
}
/**
* Check the user has permisson of one method of one module.
*
* @param string $module
* @param string $method
* @static
* @access public
* @return bool
*/
public static function hasPriv($module, $method)
{
global $app;
/* Check is the super admin or not. */
$account = ',' . $app->user->account . ',';
if(strpos($app->company->admins, $account) !== false) return true;
/* If not super admin, check the rights. */
$rights = $app->user->rights;
if(isset($rights[strtolower($module)][strtolower($method)])) return true;
return false;
}
/**
* Replace the %s of one key of a menu by $params.
*
* All the menus are defined in the common's language file. But there're many dynamic params, so in the defination,
* we used %s as placeholder. These %s should be setted in one module.
*
* The items of one module's menu may be an string or array. For example, please see module/common/lang.
*
* @param string $object the menus of one module
* @param string $key the menu item to be replaced
* @param string $params the params passed to the menu item
* @access public
* @return void
*/
public function setMenuVars($menu, $key, $params)
{
if(is_array($params))
{
if(is_array($menu->$key))
{
$menu->$key = (object)$menu->$key;
$menu->$key->link = vsprintf($menu->$key->link, $params);
$menu->$key = (array)$menu->$key;
}
else
{
$menu->$key = vsprintf($menu->$key, $params);
}
}
else
{
if(is_array($menu->$key))
{
$menu->$key = (object)$menu->$key;
$menu->$key->link = sprintf($menu->$key->link, $params);
$menu->$key = (array)$menu->$key;
}
else
{
$menu->$key = sprintf($menu->$key, $params);
}
}
}
/**
* Print the link contains orderBy field.
*
* This method will auto set the orderby param according the params. Fox example, if the order by is desc,
* will be changed to asc.
*
* @param string $fieldName the field name to sort by
* @param string $orderBy the order by string
* @param string $vars the vars to be passed
* @param string $label the label of the link
* @param string $module the module name
* @param string $method the method name
* @static
* @access public
* @return void
*/
public static function printOrderLink($fieldName, $orderBy, $vars, $label, $module = '', $method = '')
{
global $lang, $app;
if(empty($module)) $module= $app->getModuleName();
if(empty($method)) $method= $app->getMethodName();
$className = 'header';
if(strpos($orderBy, $fieldName) !== false)
{
if(stripos($orderBy, 'desc') !== false)
{
$orderBy = str_ireplace('desc', 'asc', $orderBy);
$className = 'headerSortUp';
}
elseif(stripos($orderBy, 'asc') !== false)
{
$orderBy = str_ireplace('asc', 'desc', $orderBy);
$className = 'headerSortDown';
}
}
else
{
$orderBy = $fieldName . '_' . 'asc';
$className = 'header';
}
$link = helper::createLink($module, $method, sprintf($vars, $orderBy));
echo "<div class='$className'>" . html::a($link, $label) . '</div>';
}
/**
* Print link to an modules' methd.
*
* Before printing, check the privilege first. If no privilege, return fasle. Else, print the link, return true.
*
* @param string $module the module name
* @param string $method the method
* @param string $vars vars to be passed
* @param string $label the label of the link
* @param string $target the target of the link
* @param string $misc others
* @static
* @access public
* @return bool
*/
public static function printLink($module, $method, $vars = '', $label, $target = '', $misc = '')
{
if(!common::hasPriv($module, $method)) return false;
echo html::a(helper::createLink($module, $method, $vars), $label, $target, $misc);
return true;
}
/**
* Create changes of one object.
*
* @param mixed $old the old object
* @param mixed $new the new object
* @static
* @access public
* @return array
*/
public static function createChanges($old, $new)
{
global $config;
$changes = array();
$magicQuote = get_magic_quotes_gpc();
foreach($new as $key => $value)
{
if(strtolower($key) == 'lastediteddate') continue;
if(strtolower($key) == 'lasteditedby') continue;
if(strtolower($key) == 'assigneddate') continue;
if(strtolower($key) == 'editedby') continue;
if(strtolower($key) == 'editeddate') continue;
if($magicQuote) $value = stripslashes($value);
if($value != $old->$key)
{
$diff = '';
if(substr_count($value, "\n") > 1 or substr_count($old->$key, "\n") > 1 or strpos('name,title,desc,spec,steps,content,digest', strtolower($key)) !== false) $diff = commonModel::diff($old->$key, $value);
$changes[] = array('field' => $key, 'old' => $old->$key, 'new' => $value, 'diff' => $diff);
}
}
return $changes;
}
/**
* Get the full url of the system.
*
* @access public
* @return string
*/
public function getSysURL()
{
$httpType = isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] == 'on' ? 'https' : 'http';
$httpHost = $_SERVER['HTTP_HOST'];
return "$httpType://$httpHost";
}
/**
* Print the run info.
*
* @param mixed $startTime the start time.
* @access public
* @return void
*/
public function printRunInfo($startTime)
{
vprintf($this->lang->runInfo, $this->common->getRunInfo($startTime));
}
}

View File

@@ -1,296 +1,296 @@
<?php
/**
* The common simplified chinese file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id$
* @link http://www.zentao.net
*/
$lang->arrow = ' » ';
$lang->colon = '::';
$lang->comma = ',';
$lang->dot = '.';
$lang->at = ' at ';
$lang->downArrow = '↓';
$lang->ZenTaoPMS = 'ZenTaoPMS';
$lang->welcome = "Welcome to『%s』{$lang->colon} {$lang->ZenTaoPMS}";
$lang->myControl = "Dashboard";
$lang->currentPos = 'Current';
$lang->logout = 'Logout';
$lang->login = 'Login';
$lang->aboutZenTao = 'About';
$lang->todayIs = '%s, ';
$lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar'>Time: %s ms, Memory: %s KB, Queries: %s. </div></div>";
$lang->reset = 'Reset';
$lang->edit = 'Edit';
$lang->copy = 'Copy';
$lang->delete = 'Delete';
$lang->close = 'Close';
$lang->link = 'Link';
$lang->unlink = 'Unlink';
$lang->import = 'Import';
$lang->export = 'Export';
$lang->setFileName = 'Filename:';
$lang->activate = 'Activate';
$lang->submitting = 'Saving...';
$lang->save = 'Save';
$lang->confirm = 'Confirm';
$lang->preview = 'View';
$lang->goback = 'Back';
$lang->go = 'GO';
$lang->more = 'More';
$lang->actions = 'Actions';
$lang->comment = 'Comment';
$lang->history = 'History';
$lang->attatch = 'Attatch';
$lang->reverse = '[Reverse]';
$lang->switchDisplay= '[Toggle Show]';
$lang->switchHelp = 'Toggle Help';
$lang->addFiles = 'Add Files';
$lang->files = 'Files ';
$lang->unfold = '+';
$lang->fold = '-';
$lang->selectAll = 'Select All';
$lang->notFound = 'Sorry, the object not found.';
$lang->showAll = '++ Show All ++';
$lang->hideClosed = '-- Hide Closed--';
$lang->future = 'Future';
$lang->year = 'Year';
$lang->workingHour = 'Hour';
$lang->idAB = 'ID';
$lang->priAB = 'P';
$lang->statusAB = 'Status';
$lang->openedByAB = 'Open';
$lang->assignedToAB = 'To';
$lang->typeAB = 'Type';
$lang->common->common = 'Common module';
/* The main menu. */
$lang->menu->my = 'Dashboard|my|index';
$lang->menu->product = 'Product|product|index';
$lang->menu->project = 'Project|project|index';
$lang->menu->qa = 'Test|qa|index';
$lang->menu->doc = 'Doc|doc|index';
$lang->menu->company = 'Company|company|index';
$lang->menu->admin = 'Admin|admin|index';
/* The objects in the search box. */
$lang->searchObjects['bug'] = 'Bug';
$lang->searchObjects['story'] = 'Story';
$lang->searchObjects['task'] = 'Task';
$lang->searchObjects['testcase'] = 'Test Case';
$lang->searchObjects['project'] = 'Project';
$lang->searchObjects['product'] = 'Product';
$lang->searchObjects['user'] = 'User';
$lang->searchObjects['build'] = 'Build';
$lang->searchObjects['release'] = 'Release';
$lang->searchObjects['productplan'] = 'Plan';
$lang->searchObjects['testtask'] = 'Test Task';
$lang->searchObjects['doc'] = 'Doc';
$lang->searchTips = 'Id here';
/* File type of export. */
$lang->exportFileTypeList['csv'] = 'csv';
$lang->exportFileTypeList['xml'] = 'xml';
$lang->exportFileTypeList['html'] = 'html';
/* Themes. */
$lang->themes['default'] = 'Default';
$lang->themes['green'] = 'Green';
$lang->themes['red'] = 'Red';
$lang->themes['classblue'] = 'Blue';
/* Index mododule menu. */
$lang->index->menu->product = 'Products|product|browse';
$lang->index->menu->project = 'Projects|project|browse';
/* Dashboard menu. */
$lang->my->menu->account = '%s' . $lang->arrow;
$lang->my->menu->index = 'Index|my|index';
$lang->my->menu->todo = array('link' => 'Todo|my|todo|', 'subModule' => 'todo');
$lang->my->menu->task = 'Task|my|task|';
$lang->my->menu->bug = 'Bug|my|bug|';
$lang->my->menu->testtask = 'Test|my|testtask|';
$lang->my->menu->story = 'Story|my|story|';
$lang->my->menu->myProject = 'Project|my|project|';
$lang->my->menu->dynamic = 'Dynamic|my|dynamic|';
$lang->my->menu->profile = array('link' => 'Profile|my|profile|', 'alias' => 'editprofile');
$lang->todo->menu = $lang->my->menu;
/* Product menu. */
$lang->product->menu->list = '%s';
$lang->product->menu->story = array('link' => 'Story|product|browse|productID=%s', 'subModule' => 'story');
$lang->product->menu->dynamic = 'Dynamic|product|dynamic|productID=%s';
$lang->product->menu->plan = array('link' => 'Plan|productplan|browse|productID=%s', 'subModule' => 'productplan');
$lang->product->menu->release = array('link' => 'Release|release|browse|productID=%s', 'subModule' => 'release');
$lang->product->menu->roadmap = 'Roadmap|product|roadmap|productID=%s';
$lang->product->menu->doc = array('link' => 'Doc|product|doc|productID=%s', 'subModule' => 'doc');
$lang->product->menu->view = 'Info|product|view|productID=%s';
$lang->product->menu->edit = 'Edit|product|edit|productID=%s';
$lang->product->menu->delete = array('link' => 'Delete|product|delete|productID=%s', 'target' => 'hiddenwin');
$lang->product->menu->module = 'Modules|tree|browse|productID=%s&view=story';
$lang->product->menu->create = array('link' => 'New Product|product|create', 'float' => 'right');
$lang->product->menu->project = array('link' => 'Project list|product|project|status=all&productID=%s', 'float' => 'right');
$lang->product->menu->all = array('link' => 'All product|product|index|locate=false', 'float' => 'right');
$lang->story->menu = $lang->product->menu;
$lang->productplan->menu = $lang->product->menu;
$lang->release->menu = $lang->product->menu;
/* Project menu. */
$lang->project->menu->list = '%s';
$lang->project->menu->task = array('link' => 'Task|project|task|projectID=%s', 'subModule' => 'task', 'alias' => 'grouptask,importtask');
$lang->project->menu->story = array('link' => 'Story|project|story|projectID=%s');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = 'Dynamic|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => 'Build|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = 'Testtask|project|testtask|projectID=%s';
$lang->project->menu->burn = 'Burn|project|burn|projectID=%s';
$lang->project->menu->team = array('link' => 'Team|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->doc = array('link' => 'Doc|project|doc|porjectID=%s', 'subModule' => 'doc');
$lang->project->menu->product = 'Link Product|project|manageproducts|projectID=%s';
$lang->project->menu->linkstory = array('link' => 'Link Story|project|linkstory|projectID=%s');
$lang->project->menu->view = 'Info|project|view|projectID=%s';
$lang->project->menu->edit = 'Edit|project|edit|projectID=%s';
$lang->project->menu->delete = array('link' => 'Delete|project|delete|projectID=%s', 'target' => 'hiddenwin');
$lang->project->menu->create = array('link' => 'New Project|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => 'Project list|project|index|locate=no', 'float' => 'right');
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
/* QA menu. */
$lang->bug->menu->product = '%s';
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,edit,resolve,close,activate,report', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => 'Test Case|testcase|browse|productID=%s', 'alias' => 'view,create,edit');
$lang->bug->menu->testtask = array('link' => 'Test Task|testtask|browse|productID=%s');
$lang->testcase->menu->product = '%s';
$lang->testcase->menu->bug = array('link' => 'Bug|bug|browse|productID=%s');
$lang->testcase->menu->testcase = array('link' => 'Test Case|testcase|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit', 'subModule' => 'tree');
$lang->testcase->menu->testtask = array('link' => 'Test Task|testtask|browse|productID=%s');
$lang->testtask->menu->product = '%s';
$lang->testtask->menu->bug = array('link' => 'Bug|bug|browse|productID=%s');
$lang->testtask->menu->testcase = array('link' => 'Test Case|testcase|browse|productID=%s');
$lang->testtask->menu->testtask = array('link' => 'Test Task|testtask|browse|productID=%s', 'alias' => 'view,create,edit,linkcase,cases');
/* Doc menu. */
$lang->doc->menu->list = '%s';
$lang->doc->menu->browse = array('link' => 'Doc|doc|browse|libID=%s');
$lang->doc->menu->edit = 'Edit Library|doc|editLib|libID=%s';
$lang->doc->menu->module = 'Modules|tree|browse|libID=%s&viewType=doc';
$lang->doc->menu->delete = array('link' => 'Delete Library|doc|deleteLib|libID=%s', 'target' => 'hiddenwin');
$lang->doc->menu->create = array('link' => 'New Library|doc|createLib', 'float' => 'right');
/* Company menu. */
$lang->company->menu->name = '%s' . $lang->arrow;
$lang->company->menu->browseUser = array('link' => 'Users|company|browse', 'subModule' => 'user');
$lang->company->menu->dept = array('link' => 'Department|dept|browse', 'subModule' => 'dept');
$lang->company->menu->browseGroup = array('link' => 'Group|group|browse', 'subModule' => 'group');
$lang->company->menu->edit = array('link' => 'Company|company|edit');
$lang->company->menu->dynamic = 'Dynamic|company|dynamic|';
$lang->company->menu->addGroup = array('link' => 'Add Group|group|create', 'float' => 'right');
$lang->company->menu->addUser = array('link' => 'Add User|user|create|dept=%s&from=company', 'subModule' => 'user', 'float' => 'right');
$lang->dept->menu = $lang->company->menu;
$lang->group->menu = $lang->company->menu;
/* User menu. */
$lang->user->menu->account = '%s' . $lang->arrow;
$lang->user->menu->todo = array('link' => 'Todo|user|todo|account=%s', 'subModule' => 'todo');
$lang->user->menu->task = 'Task|user|task|account=%s';
$lang->user->menu->bug = 'Bug|user|bug|account=%s';
$lang->user->menu->dynamic = 'Dynamic|user|dynamic|type=today&account=%s';
$lang->user->menu->projectList = 'Project|user|project|account=%s';
$lang->user->menu->profile = array('link' => 'Profile|user|profile|account=%s', 'alias' => 'edit');
$lang->user->menu->browse = array('link' => 'Manage user|company|browse|', 'float' => 'right');
/* Admin menu. */
$lang->admin->menu->extension = array('link' => 'Extension|extension|browse', 'subModule' => 'extension');
$lang->admin->menu->editor = array('link' => 'Extension editor|editor|index', 'subModule' => 'editor');
$lang->admin->menu->mail = array('link' => 'ConfigEmail|mail|set', 'subModule' => 'mail');
$lang->admin->menu->convert = array('link' => 'Import|convert|index', 'subModule' => 'convert');
$lang->admin->menu->trashes = array('link' => 'Trash|action|trash', 'subModule' => 'action');
$lang->convert->menu = $lang->admin->menu;
$lang->upgrade->menu = $lang->admin->menu;
$lang->action->menu = $lang->admin->menu;
$lang->extension->menu = $lang->admin->menu;
$lang->editor->menu = $lang->admin->menu;
$lang->mail->menu = $lang->admin->menu;
/* Groups. */
$lang->menugroup->release = 'product';
$lang->menugroup->story = 'product';
$lang->menugroup->productplan = 'product';
$lang->menugroup->task = 'project';
$lang->menugroup->build = 'project';
$lang->menugroup->convert = 'admin';
$lang->menugroup->upgrade = 'admin';
$lang->menugroup->user = 'company';
$lang->menugroup->group = 'company';
$lang->menugroup->bug = 'qa';
$lang->menugroup->testcase = 'qa';
$lang->menugroup->testtask = 'qa';
$lang->menugroup->people = 'company';
$lang->menugroup->dept = 'company';
$lang->menugroup->todo = 'my';
$lang->menugroup->action = 'admin';
$lang->menugroup->extension = 'admin';
$lang->menugroup->editor = 'admin';
$lang->menugroup->mail = 'admin';
/* Error info. */
$lang->error->companyNotFound = "The domain %s does not exist.";
$lang->error->length = array("『%s』length should be『%s』", "『%s』length should between『%s』and 『%s』.");
$lang->error->reg = "『%s』should like『%s』";
$lang->error->unique = "『%s』has『%s』already.";
$lang->error->gt = "『%s』must great than『%s』.";
$lang->error->notempty = "『%s』can not be empty.";
$lang->error->empty = "『%s』 must be empty.";
$lang->error->equal = "『%s』must be『%s』.";
$lang->error->int = array("『%s』should be interger", "『%s』should between『%s-%s』.");
$lang->error->float = "『%s』should be a interger or float.";
$lang->error->email = "『%s』should be email.";
$lang->error->date = "『%s』should be date";
$lang->error->account = "『%s』should be a valid account.";
$lang->error->passwordsame = "Two passwords must be the same";
$lang->error->passwordrule = "Password should more than six letters.";
$lang->error->accessDenied = 'No purview';
/* Pager. */
$lang->pager->noRecord = "No records yet.";
$lang->pager->digest = "<strong>%s</strong> records, <strong>%s</strong> per page, <strong>%s/%s</strong> ";
$lang->pager->first = "First";
$lang->pager->pre = "Previous";
$lang->pager->next = "Next";
$lang->pager->last = "Last";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "Official Site";
$lang->chinaScrum = "<a href='http://www.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum community</a> ";
$lang->agileTraining = "<a href='http://www.zentao.net/goto.php?item=agiletrain' target='_blank'>Training</a> ";
$lang->donate = "<a href='http://www.zentao.net/goto.php?item=donate' target='_blank'>Donate</a> ";
$lang->zentaoKeywords = "Open Source Project Management System";
$lang->zentaoDESC = "ZenTaoPMS is an open sourced project management system.";
/* Date times. */
define('DT_DATETIME1', 'Y-m-d H:i:s');
define('DT_DATETIME2', 'y-m-d H:i');
define('DT_MONTHTIME1', 'n/d H:i');
define('DT_MONTHTIME2', 'F j, H:i');
define('DT_DATE1', 'Y-m-d');
define('DT_DATE2', 'Ymd');
define('DT_DATE3', 'F j, Y ');
define('DT_DATE4', 'M j');
define('DT_TIME1', 'H:i:s');
define('DT_TIME2', 'H:i');
<?php
/**
* The common simplified chinese file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id$
* @link http://www.zentao.net
*/
$lang->arrow = ' » ';
$lang->colon = '::';
$lang->comma = ',';
$lang->dot = '.';
$lang->at = ' at ';
$lang->downArrow = '↓';
$lang->ZenTaoPMS = 'ZenTaoPMS';
$lang->welcome = "Welcome to『%s』{$lang->colon} {$lang->ZenTaoPMS}";
$lang->myControl = "Dashboard";
$lang->currentPos = 'Current';
$lang->logout = 'Logout';
$lang->login = 'Login';
$lang->aboutZenTao = 'About';
$lang->todayIs = '%s, ';
$lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar'>Time: %s ms, Memory: %s KB, Queries: %s. </div></div>";
$lang->reset = 'Reset';
$lang->edit = 'Edit';
$lang->copy = 'Copy';
$lang->delete = 'Delete';
$lang->close = 'Close';
$lang->link = 'Link';
$lang->unlink = 'Unlink';
$lang->import = 'Import';
$lang->export = 'Export';
$lang->setFileName = 'Filename:';
$lang->activate = 'Activate';
$lang->submitting = 'Saving...';
$lang->save = 'Save';
$lang->confirm = 'Confirm';
$lang->preview = 'View';
$lang->goback = 'Back';
$lang->go = 'GO';
$lang->more = 'More';
$lang->actions = 'Actions';
$lang->comment = 'Comment';
$lang->history = 'History';
$lang->attatch = 'Attatch';
$lang->reverse = '[Reverse]';
$lang->switchDisplay= '[Toggle Show]';
$lang->switchHelp = 'Toggle Help';
$lang->addFiles = 'Add Files';
$lang->files = 'Files ';
$lang->unfold = '+';
$lang->fold = '-';
$lang->selectAll = 'Select All';
$lang->notFound = 'Sorry, the object not found.';
$lang->showAll = '++ Show All ++';
$lang->hideClosed = '-- Hide Closed--';
$lang->future = 'Future';
$lang->year = 'Year';
$lang->workingHour = 'Hour';
$lang->idAB = 'ID';
$lang->priAB = 'P';
$lang->statusAB = 'Status';
$lang->openedByAB = 'Open';
$lang->assignedToAB = 'To';
$lang->typeAB = 'Type';
$lang->common->common = 'Common module';
/* The main menu. */
$lang->menu->my = 'Dashboard|my|index';
$lang->menu->product = 'Product|product|index';
$lang->menu->project = 'Project|project|index';
$lang->menu->qa = 'Test|qa|index';
$lang->menu->doc = 'Doc|doc|index';
$lang->menu->company = 'Company|company|index';
$lang->menu->admin = 'Admin|admin|index';
/* The objects in the search box. */
$lang->searchObjects['bug'] = 'Bug';
$lang->searchObjects['story'] = 'Story';
$lang->searchObjects['task'] = 'Task';
$lang->searchObjects['testcase'] = 'Test Case';
$lang->searchObjects['project'] = 'Project';
$lang->searchObjects['product'] = 'Product';
$lang->searchObjects['user'] = 'User';
$lang->searchObjects['build'] = 'Build';
$lang->searchObjects['release'] = 'Release';
$lang->searchObjects['productplan'] = 'Plan';
$lang->searchObjects['testtask'] = 'Test Task';
$lang->searchObjects['doc'] = 'Doc';
$lang->searchTips = 'Id here';
/* File type of export. */
$lang->exportFileTypeList['csv'] = 'csv';
$lang->exportFileTypeList['xml'] = 'xml';
$lang->exportFileTypeList['html'] = 'html';
/* Themes. */
$lang->themes['default'] = 'Default';
$lang->themes['green'] = 'Green';
$lang->themes['red'] = 'Red';
$lang->themes['classblue'] = 'Blue';
/* Index mododule menu. */
$lang->index->menu->product = 'Products|product|browse';
$lang->index->menu->project = 'Projects|project|browse';
/* Dashboard menu. */
$lang->my->menu->account = '%s' . $lang->arrow;
$lang->my->menu->index = 'Index|my|index';
$lang->my->menu->todo = array('link' => 'Todo|my|todo|', 'subModule' => 'todo');
$lang->my->menu->task = 'Task|my|task|';
$lang->my->menu->bug = 'Bug|my|bug|';
$lang->my->menu->testtask = 'Test|my|testtask|';
$lang->my->menu->story = 'Story|my|story|';
$lang->my->menu->myProject = 'Project|my|project|';
$lang->my->menu->dynamic = 'Dynamic|my|dynamic|';
$lang->my->menu->profile = array('link' => 'Profile|my|profile|', 'alias' => 'editprofile');
$lang->todo->menu = $lang->my->menu;
/* Product menu. */
$lang->product->menu->list = '%s';
$lang->product->menu->story = array('link' => 'Story|product|browse|productID=%s', 'subModule' => 'story');
$lang->product->menu->dynamic = 'Dynamic|product|dynamic|productID=%s';
$lang->product->menu->plan = array('link' => 'Plan|productplan|browse|productID=%s', 'subModule' => 'productplan');
$lang->product->menu->release = array('link' => 'Release|release|browse|productID=%s', 'subModule' => 'release');
$lang->product->menu->roadmap = 'Roadmap|product|roadmap|productID=%s';
$lang->product->menu->doc = array('link' => 'Doc|product|doc|productID=%s', 'subModule' => 'doc');
$lang->product->menu->view = 'Info|product|view|productID=%s';
$lang->product->menu->edit = 'Edit|product|edit|productID=%s';
$lang->product->menu->delete = array('link' => 'Delete|product|delete|productID=%s', 'target' => 'hiddenwin');
$lang->product->menu->module = 'Modules|tree|browse|productID=%s&view=story';
$lang->product->menu->create = array('link' => 'New Product|product|create', 'float' => 'right');
$lang->product->menu->project = array('link' => 'Project list|product|project|status=all&productID=%s', 'float' => 'right');
$lang->product->menu->all = array('link' => 'All product|product|index|locate=false', 'float' => 'right');
$lang->story->menu = $lang->product->menu;
$lang->productplan->menu = $lang->product->menu;
$lang->release->menu = $lang->product->menu;
/* Project menu. */
$lang->project->menu->list = '%s';
$lang->project->menu->task = array('link' => 'Task|project|task|projectID=%s', 'subModule' => 'task', 'alias' => 'grouptask,importtask');
$lang->project->menu->story = array('link' => 'Story|project|story|projectID=%s');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = 'Dynamic|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => 'Build|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = 'Testtask|project|testtask|projectID=%s';
$lang->project->menu->burn = 'Burn|project|burn|projectID=%s';
$lang->project->menu->team = array('link' => 'Team|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->doc = array('link' => 'Doc|project|doc|porjectID=%s', 'subModule' => 'doc');
$lang->project->menu->product = 'Link Product|project|manageproducts|projectID=%s';
$lang->project->menu->linkstory = array('link' => 'Link Story|project|linkstory|projectID=%s');
$lang->project->menu->view = 'Info|project|view|projectID=%s';
$lang->project->menu->edit = 'Edit|project|edit|projectID=%s';
$lang->project->menu->delete = array('link' => 'Delete|project|delete|projectID=%s', 'target' => 'hiddenwin');
$lang->project->menu->create = array('link' => 'New Project|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => 'Project list|project|index|locate=no', 'float' => 'right');
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
/* QA menu. */
$lang->bug->menu->product = '%s';
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,edit,resolve,close,activate,report', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => 'Test Case|testcase|browse|productID=%s', 'alias' => 'view,create,edit');
$lang->bug->menu->testtask = array('link' => 'Test Task|testtask|browse|productID=%s');
$lang->testcase->menu->product = '%s';
$lang->testcase->menu->bug = array('link' => 'Bug|bug|browse|productID=%s');
$lang->testcase->menu->testcase = array('link' => 'Test Case|testcase|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit', 'subModule' => 'tree');
$lang->testcase->menu->testtask = array('link' => 'Test Task|testtask|browse|productID=%s');
$lang->testtask->menu->product = '%s';
$lang->testtask->menu->bug = array('link' => 'Bug|bug|browse|productID=%s');
$lang->testtask->menu->testcase = array('link' => 'Test Case|testcase|browse|productID=%s');
$lang->testtask->menu->testtask = array('link' => 'Test Task|testtask|browse|productID=%s', 'alias' => 'view,create,edit,linkcase,cases');
/* Doc menu. */
$lang->doc->menu->list = '%s';
$lang->doc->menu->browse = array('link' => 'Doc|doc|browse|libID=%s');
$lang->doc->menu->edit = 'Edit Library|doc|editLib|libID=%s';
$lang->doc->menu->module = 'Modules|tree|browse|libID=%s&viewType=doc';
$lang->doc->menu->delete = array('link' => 'Delete Library|doc|deleteLib|libID=%s', 'target' => 'hiddenwin');
$lang->doc->menu->create = array('link' => 'New Library|doc|createLib', 'float' => 'right');
/* Company menu. */
$lang->company->menu->name = '%s' . $lang->arrow;
$lang->company->menu->browseUser = array('link' => 'Users|company|browse', 'subModule' => 'user');
$lang->company->menu->dept = array('link' => 'Department|dept|browse', 'subModule' => 'dept');
$lang->company->menu->browseGroup = array('link' => 'Group|group|browse', 'subModule' => 'group');
$lang->company->menu->edit = array('link' => 'Company|company|edit');
$lang->company->menu->dynamic = 'Dynamic|company|dynamic|';
$lang->company->menu->addGroup = array('link' => 'Add Group|group|create', 'float' => 'right');
$lang->company->menu->addUser = array('link' => 'Add User|user|create|dept=%s&from=company', 'subModule' => 'user', 'float' => 'right');
$lang->dept->menu = $lang->company->menu;
$lang->group->menu = $lang->company->menu;
/* User menu. */
$lang->user->menu->account = '%s' . $lang->arrow;
$lang->user->menu->todo = array('link' => 'Todo|user|todo|account=%s', 'subModule' => 'todo');
$lang->user->menu->task = 'Task|user|task|account=%s';
$lang->user->menu->bug = 'Bug|user|bug|account=%s';
$lang->user->menu->dynamic = 'Dynamic|user|dynamic|type=today&account=%s';
$lang->user->menu->projectList = 'Project|user|project|account=%s';
$lang->user->menu->profile = array('link' => 'Profile|user|profile|account=%s', 'alias' => 'edit');
$lang->user->menu->browse = array('link' => 'Manage user|company|browse|', 'float' => 'right');
/* Admin menu. */
$lang->admin->menu->extension = array('link' => 'Extension|extension|browse', 'subModule' => 'extension');
$lang->admin->menu->editor = array('link' => 'Extension editor|editor|index', 'subModule' => 'editor');
$lang->admin->menu->mail = array('link' => 'ConfigEmail|mail|set', 'subModule' => 'mail');
$lang->admin->menu->convert = array('link' => 'Import|convert|index', 'subModule' => 'convert');
$lang->admin->menu->trashes = array('link' => 'Trash|action|trash', 'subModule' => 'action');
$lang->convert->menu = $lang->admin->menu;
$lang->upgrade->menu = $lang->admin->menu;
$lang->action->menu = $lang->admin->menu;
$lang->extension->menu = $lang->admin->menu;
$lang->editor->menu = $lang->admin->menu;
$lang->mail->menu = $lang->admin->menu;
/* Groups. */
$lang->menugroup->release = 'product';
$lang->menugroup->story = 'product';
$lang->menugroup->productplan = 'product';
$lang->menugroup->task = 'project';
$lang->menugroup->build = 'project';
$lang->menugroup->convert = 'admin';
$lang->menugroup->upgrade = 'admin';
$lang->menugroup->user = 'company';
$lang->menugroup->group = 'company';
$lang->menugroup->bug = 'qa';
$lang->menugroup->testcase = 'qa';
$lang->menugroup->testtask = 'qa';
$lang->menugroup->people = 'company';
$lang->menugroup->dept = 'company';
$lang->menugroup->todo = 'my';
$lang->menugroup->action = 'admin';
$lang->menugroup->extension = 'admin';
$lang->menugroup->editor = 'admin';
$lang->menugroup->mail = 'admin';
/* Error info. */
$lang->error->companyNotFound = "The domain %s does not exist.";
$lang->error->length = array("『%s』length should be『%s』", "『%s』length should between『%s』and 『%s』.");
$lang->error->reg = "『%s』should like『%s』";
$lang->error->unique = "『%s』has『%s』already.";
$lang->error->gt = "『%s』must great than『%s』.";
$lang->error->notempty = "『%s』can not be empty.";
$lang->error->empty = "『%s』 must be empty.";
$lang->error->equal = "『%s』must be『%s』.";
$lang->error->int = array("『%s』should be interger", "『%s』should between『%s-%s』.");
$lang->error->float = "『%s』should be a interger or float.";
$lang->error->email = "『%s』should be email.";
$lang->error->date = "『%s』should be date";
$lang->error->account = "『%s』should be a valid account.";
$lang->error->passwordsame = "Two passwords must be the same";
$lang->error->passwordrule = "Password should more than six letters.";
$lang->error->accessDenied = 'No purview';
/* Pager. */
$lang->pager->noRecord = "No records yet.";
$lang->pager->digest = "<strong>%s</strong> records, <strong>%s</strong> per page, <strong>%s/%s</strong> ";
$lang->pager->first = "First";
$lang->pager->pre = "Previous";
$lang->pager->next = "Next";
$lang->pager->last = "Last";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "Official Site";
$lang->chinaScrum = "<a href='http://www.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum community</a> ";
$lang->agileTraining = "<a href='http://www.zentao.net/goto.php?item=agiletrain' target='_blank'>Training</a> ";
$lang->donate = "<a href='http://www.zentao.net/goto.php?item=donate' target='_blank'>Donate</a> ";
$lang->zentaoKeywords = "Open Source Project Management System";
$lang->zentaoDESC = "ZenTaoPMS is an open sourced project management system.";
/* Date times. */
define('DT_DATETIME1', 'Y-m-d H:i:s');
define('DT_DATETIME2', 'y-m-d H:i');
define('DT_MONTHTIME1', 'n/d H:i');
define('DT_MONTHTIME2', 'F j, H:i');
define('DT_DATE1', 'Y-m-d');
define('DT_DATE2', 'Ymd');
define('DT_DATE3', 'F j, Y ');
define('DT_DATE4', 'M j');
define('DT_TIME1', 'H:i:s');
define('DT_TIME2', 'H:i');

View File

@@ -1,296 +1,296 @@
<?php
/**
* The common simplified chinese file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id$
* @link http://www.zentao.net
*/
$lang->arrow = ' » ';
$lang->colon = '::';
$lang->comma = '';
$lang->dot = '。';
$lang->at = ' 于 ';
$lang->downArrow = '↓';
$lang->ZenTaoPMS = '禅道管理';
$lang->welcome = "欢迎使用『%s』{$lang->colon} {$lang->ZenTaoPMS}";
$lang->myControl = "我的地盘";
$lang->currentPos = '当前位置:';
$lang->logout = '退出';
$lang->login = '登录';
$lang->aboutZenTao = '关于';
$lang->todayIs = '今天是%s';
$lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar'>时间: %s 毫秒, 内存: %s KB, 查询: %s. </div></div>";
$lang->reset = '重填';
$lang->edit = '编辑';
$lang->copy = '复制';
$lang->delete = '删除';
$lang->close = '关闭';
$lang->link = '关联';
$lang->unlink = '移除';
$lang->import = '导入';
$lang->export = '导出';
$lang->setFileName = '文件名:';
$lang->activate = '激活';
$lang->submitting = '稍候...';
$lang->save = '保存';
$lang->confirm = '确认';
$lang->preview = '查看';
$lang->goback = '返回';
$lang->go = 'GO';
$lang->more = '更多';
$lang->actions = '操作';
$lang->comment = '备注';
$lang->history = '历史记录';
$lang->attatch = '附件';
$lang->reverse = '[切换顺序]';
$lang->switchDisplay= '[切换显示]';
$lang->switchHelp = '切换帮助';
$lang->addFiles = '上传了附件 ';
$lang->files = '附件 ';
$lang->unfold = '+';
$lang->fold = '-';
$lang->selectAll = '全选';
$lang->notFound = '抱歉,您访问的对象并不存在!';
$lang->showAll = '++ 全部显示 ++';
$lang->hideClosed = '-- 隐藏已结束 --';
$lang->future = '未来';
$lang->year = '年';
$lang->workingHour = '工时';
$lang->idAB = 'ID';
$lang->priAB = 'P';
$lang->statusAB = '状态';
$lang->openedByAB = '创建';
$lang->assignedToAB = '指派';
$lang->typeAB = '类型';
$lang->common->common = '公有模块';
/* 主导航菜单。*/
$lang->menu->my = '我的地盘|my|index';
$lang->menu->product = '产品视图|product|index';
$lang->menu->project = '项目视图|project|index';
$lang->menu->qa = '测试视图|qa|index';
$lang->menu->doc = '文档视图|doc|index';
$lang->menu->company = '组织视图|company|index';
$lang->menu->admin = '后台管理|admin|index';
/* 查询条中可以选择的对象列表。*/
$lang->searchObjects['bug'] = 'B:Bug';
$lang->searchObjects['story'] = 'S:需求';
$lang->searchObjects['task'] = 'T:任务';
$lang->searchObjects['testcase'] = 'C:用例';
$lang->searchObjects['project'] = 'P:项目';
$lang->searchObjects['product'] = 'P:产品';
$lang->searchObjects['user'] = 'U:用户';
$lang->searchObjects['build'] = 'B:Build';
$lang->searchObjects['release'] = 'R:发布';
$lang->searchObjects['productplan'] = 'P:产品计划';
$lang->searchObjects['testtask'] = 'T:测试任务';
$lang->searchObjects['doc'] = 'D:文档';
$lang->searchTips = '输入编号';
/* 导出文件的类型列表。*/
$lang->exportFileTypeList['csv'] = 'csv';
$lang->exportFileTypeList['xml'] = 'xml';
$lang->exportFileTypeList['html'] = 'html';
/* 风格列表。*/
$lang->themes['default'] = '默认';
$lang->themes['green'] = '绿色';
$lang->themes['red'] = '红色';
$lang->themes['classblue'] = '经典蓝';
/* 首页菜单设置。*/
$lang->index->menu->product = '浏览产品|product|browse';
$lang->index->menu->project = '浏览项目|project|browse';
/* 我的地盘菜单设置。*/
$lang->my->menu->account = '%s' . $lang->arrow;
$lang->my->menu->index = '首页|my|index';
$lang->my->menu->todo = array('link' => '我的TODO|my|todo|', 'subModule' => 'todo');
$lang->my->menu->task = '我的任务|my|task|';
$lang->my->menu->bug = '我的Bug|my|bug|';
$lang->my->menu->testtask = '我的测试|my|testtask|';
$lang->my->menu->story = '我的需求|my|story|';
$lang->my->menu->myProject = '我的项目|my|project|';
$lang->my->menu->dynamic = '我的动态|my|dynamic|';
$lang->my->menu->profile = array('link' => '我的档案|my|profile|', 'alias' => 'editprofile');
$lang->todo->menu = $lang->my->menu;
/* 产品视图设置。*/
$lang->product->menu->list = '%s';
$lang->product->menu->story = array('link' => '需求|product|browse|productID=%s', 'subModule' => 'story');
$lang->product->menu->dynamic = '动态|product|dynamic|productID=%s';
$lang->product->menu->plan = array('link' => '计划|productplan|browse|productID=%s', 'subModule' => 'productplan');
$lang->product->menu->release = array('link' => '发布|release|browse|productID=%s', 'subModule' => 'release');
$lang->product->menu->roadmap = '路线图|product|roadmap|productID=%s';
$lang->product->menu->doc = array('link' => '文档|product|doc|productID=%s', 'subModule' => 'doc');
$lang->product->menu->view = '概况|product|view|productID=%s';
$lang->product->menu->edit = '编辑|product|edit|productID=%s';
$lang->product->menu->delete = array('link' => '删除|product|delete|productID=%s', 'target' => 'hiddenwin');
$lang->product->menu->module = '模块|tree|browse|productID=%s&view=story';
$lang->product->menu->create = array('link' => '新增产品|product|create', 'float' => 'right');
$lang->product->menu->project = array('link' => '项目列表|product|project|status=all&productID=%s', 'float' => 'right');
$lang->product->menu->all = array('link' => '所有产品|product|index|locate=false', 'float' => 'right');
$lang->story->menu = $lang->product->menu;
$lang->productplan->menu = $lang->product->menu;
$lang->release->menu = $lang->product->menu;
/* 项目视图菜单设置。*/
$lang->project->menu->list = '%s';
$lang->project->menu->task = array('link' => '任务|project|task|projectID=%s', 'subModule' => 'task', 'alias' => 'grouptask,importtask');
$lang->project->menu->story = array('link' => '需求|project|story|projectID=%s');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = '动态|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => 'Build|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = '测试任务|project|testtask|projectID=%s';
$lang->project->menu->burn = '燃尽图|project|burn|projectID=%s';
$lang->project->menu->team = array('link' => '团队|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->doc = array('link' => '文档|project|doc|porjectID=%s', 'subModule' => 'doc');
$lang->project->menu->product = '产品|project|manageproducts|projectID=%s';
$lang->project->menu->linkstory = array('link' => '关联需求|project|linkstory|projectID=%s');
$lang->project->menu->view = '概况|project|view|projectID=%s';
$lang->project->menu->edit = '编辑|project|edit|projectID=%s';
$lang->project->menu->delete = array('link' => '删除|project|delete|projectID=%s', 'target' => 'hiddenwin');
$lang->project->menu->create = array('link' => '新增项目|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => '所有项目|project|index|locate=false', 'float' => 'right');
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
/* QA视图菜单设置。*/
$lang->bug->menu->product = '%s';
$lang->bug->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s', 'alias' => 'view,create,edit,resolve,close,activate,report', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,edit');
$lang->bug->menu->testtask = array('link' => '测试任务|testtask|browse|productID=%s');
$lang->testcase->menu->product = '%s';
$lang->testcase->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testcase->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit', 'subModule' => 'tree');
$lang->testcase->menu->testtask = array('link' => '测试任务|testtask|browse|productID=%s');
$lang->testtask->menu->product = '%s';
$lang->testtask->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testtask->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s');
$lang->testtask->menu->testtask = array('link' => '测试任务|testtask|browse|productID=%s', 'alias' => 'view,create,edit,linkcase,cases');
/* 文档视图菜单设置。*/
$lang->doc->menu->list = '%s';
$lang->doc->menu->browse = array('link' => '文档列表|doc|browse|libID=%s');
$lang->doc->menu->edit = '编辑文档库|doc|editLib|libID=%s';
$lang->doc->menu->module = '维护模块|tree|browse|libID=%s&viewType=doc';
$lang->doc->menu->delete = array('link' => '删除文档库|doc|deleteLib|libID=%s', 'target' => 'hiddenwin');
$lang->doc->menu->create = array('link' => '新增文档库|doc|createLib', 'float' => 'right');
/* 组织结构视图菜单设置。*/
$lang->company->menu->name = '%s' . $lang->arrow;
$lang->company->menu->browseUser = array('link' => '用户列表|company|browse', 'subModule' => 'user');
$lang->company->menu->dept = array('link' => '部门维护|dept|browse', 'subModule' => 'dept');
$lang->company->menu->browseGroup = array('link' => '权限分组|group|browse', 'subModule' => 'group');
$lang->company->menu->edit = array('link' => '公司管理|company|edit');
$lang->company->menu->dynamic = '组织动态|company|dynamic|';
$lang->company->menu->addGroup = array('link' => '添加分组|group|create', 'float' => 'right');
$lang->company->menu->addUser = array('link' => '添加用户|user|create|dept=%s', 'subModule' => 'user', 'float' => 'right');
$lang->dept->menu = $lang->company->menu;
$lang->group->menu = $lang->company->menu;
/* 用户信息菜单设置。*/
$lang->user->menu->account = '%s' . $lang->arrow;
$lang->user->menu->todo = array('link' => 'TODO列表|user|todo|account=%s', 'subModule' => 'todo');
$lang->user->menu->task = '任务列表|user|task|account=%s';
$lang->user->menu->bug = 'Bug列表|user|bug|account=%s';
$lang->user->menu->dynamic = '用户动态|user|dynamic|type=today&account=%s';
$lang->user->menu->projectList = '项目列表|user|project|account=%s';
$lang->user->menu->profile = array('link' => '用户信息|user|profile|account=%s', 'alias' => 'edit');
$lang->user->menu->browse = array('link' => '用户管理|company|browse|', 'float' => 'right');
/* 后台管理菜单设置。*/
$lang->admin->menu->extension = array('link' => '插件管理|extension|browse', 'subModule' => 'extension');
$lang->admin->menu->editor = array('link' => '扩展编辑器|editor|index', 'subModule' => 'editor');
$lang->admin->menu->mail = array('link' => 'Email配置|mail|set', 'subModule' => 'mail');
$lang->admin->menu->convert = array('link' => '从其他系统导入|convert|index', 'subModule' => 'convert');
$lang->admin->menu->trashes = array('link' => '回收站|action|trash', 'subModule' => 'action');
$lang->convert->menu = $lang->admin->menu;
$lang->upgrade->menu = $lang->admin->menu;
$lang->action->menu = $lang->admin->menu;
$lang->extension->menu = $lang->admin->menu;
$lang->editor->menu = $lang->admin->menu;
$lang->mail->menu = $lang->admin->menu;
/*菜单设置:分组设置。*/
$lang->menugroup->release = 'product';
$lang->menugroup->story = 'product';
$lang->menugroup->productplan = 'product';
$lang->menugroup->task = 'project';
$lang->menugroup->build = 'project';
$lang->menugroup->convert = 'admin';
$lang->menugroup->upgrade = 'admin';
$lang->menugroup->user = 'company';
$lang->menugroup->group = 'company';
$lang->menugroup->bug = 'qa';
$lang->menugroup->testcase = 'qa';
$lang->menugroup->testtask = 'qa';
$lang->menugroup->people = 'company';
$lang->menugroup->dept = 'company';
$lang->menugroup->todo = 'my';
$lang->menugroup->action = 'admin';
$lang->menugroup->extension = 'admin';
$lang->menugroup->editor = 'admin';
$lang->menugroup->mail = 'admin';
/* 错误提示信息。*/
$lang->error->companyNotFound = "您访问的域名 %s 没有对应的公司。";
$lang->error->length = array("『%s』长度错误应当为『%s』", "『%s』长度应当不超过『%s』且不小于『%s』。");
$lang->error->reg = "『%s』不符合格式应当为:『%s』。";
$lang->error->unique = "『%s』已经有『%s』这条记录了。";
$lang->error->gt = "『%s』应当大于『%s』。";
$lang->error->notempty = "『%s』不能为空。";
$lang->error->empty = "『%s』必须为空。";
$lang->error->equal = "『%s』必须为『%s』。";
$lang->error->int = array("『%s』应当是数字。", "『%s』应当介于『%s-%s』之间。");
$lang->error->float = "『%s』应当是数字可以是小数。";
$lang->error->email = "『%s』应当为合法的EMAIL。";
$lang->error->date = "『%s』应当为合法的日期。";
$lang->error->account = "『%s』应当为合法的用户名。";
$lang->error->passwordsame = "两次密码应当相等。";
$lang->error->passwordrule = "密码应该符合规则,长度至少为六位。";
$lang->error->accessDenied = '您没有访问权限';
/* 分页信息。*/
$lang->pager->noRecord = "暂时没有记录";
$lang->pager->digest = "共<strong>%s</strong>条记录,每页 <strong>%s</strong>条,页面:<strong>%s/%s</strong> ";
$lang->pager->first = "首页";
$lang->pager->pre = "上页";
$lang->pager->next = "下页";
$lang->pager->last = "末页";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "官方网站";
$lang->chinaScrum = "<a href='http://www.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum社区</a> ";
$lang->agileTraining = "<a href='http://www.zentao.net/goto.php?item=agiletrain' target='_blank'>培训</a> ";
$lang->donate = "<a href='http://www.zentao.net/goto.php?item=donate' target='_blank'>捐助禅道</a> ";
$lang->zentaoKeywords = "开源项目管理软件,项目管理,项目管理软件,pmp,pms,php框架国产php框架scrum工具,scrum管理工具,scrum管理软件,敏捷项目管理,禅道";
$lang->zentaoDESC = "禅道项目管理软件(ZenTaoPMS)是一款国产的基于LGPL协议开源免费的项目管理软件(工具、系统)同时也是一款scrum管理工具。
它集产品管理、项目管理、测试管理于一体同时还包含了事务管理、组织管理等诸多功能是中小型企业项目管理的首选。禅道项目管理软件使用PHP + MySQL开发
基于自主的PHP开发框架──ZenTaoPHP而成。第三方开发者或者企业可以非常方便的开发插件或者进行定制。禅道在手项目无忧";
/* 时间格式设置。*/
define('DT_DATETIME1', 'Y-m-d H:i:s');
define('DT_DATETIME2', 'y-m-d H:i');
define('DT_MONTHTIME1', 'n/d H:i');
define('DT_MONTHTIME2', 'n月d日 H:i');
define('DT_DATE1', 'Y-m-d');
define('DT_DATE2', 'Ymd');
define('DT_DATE3', 'Y年m月d日');
define('DT_DATE4', 'n月j日');
define('DT_TIME1', 'H:i:s');
define('DT_TIME2', 'H:i');
<?php
/**
* The common simplified chinese file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id$
* @link http://www.zentao.net
*/
$lang->arrow = ' » ';
$lang->colon = '::';
$lang->comma = '';
$lang->dot = '。';
$lang->at = ' 于 ';
$lang->downArrow = '↓';
$lang->ZenTaoPMS = '禅道管理';
$lang->welcome = "欢迎使用『%s』{$lang->colon} {$lang->ZenTaoPMS}";
$lang->myControl = "我的地盘";
$lang->currentPos = '当前位置:';
$lang->logout = '退出';
$lang->login = '登录';
$lang->aboutZenTao = '关于';
$lang->todayIs = '今天是%s';
$lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar'>时间: %s 毫秒, 内存: %s KB, 查询: %s. </div></div>";
$lang->reset = '重填';
$lang->edit = '编辑';
$lang->copy = '复制';
$lang->delete = '删除';
$lang->close = '关闭';
$lang->link = '关联';
$lang->unlink = '移除';
$lang->import = '导入';
$lang->export = '导出';
$lang->setFileName = '文件名:';
$lang->activate = '激活';
$lang->submitting = '稍候...';
$lang->save = '保存';
$lang->confirm = '确认';
$lang->preview = '查看';
$lang->goback = '返回';
$lang->go = 'GO';
$lang->more = '更多';
$lang->actions = '操作';
$lang->comment = '备注';
$lang->history = '历史记录';
$lang->attatch = '附件';
$lang->reverse = '[切换顺序]';
$lang->switchDisplay= '[切换显示]';
$lang->switchHelp = '切换帮助';
$lang->addFiles = '上传了附件 ';
$lang->files = '附件 ';
$lang->unfold = '+';
$lang->fold = '-';
$lang->selectAll = '全选';
$lang->notFound = '抱歉,您访问的对象并不存在!';
$lang->showAll = '++ 全部显示 ++';
$lang->hideClosed = '-- 隐藏已结束 --';
$lang->future = '未来';
$lang->year = '年';
$lang->workingHour = '工时';
$lang->idAB = 'ID';
$lang->priAB = 'P';
$lang->statusAB = '状态';
$lang->openedByAB = '创建';
$lang->assignedToAB = '指派';
$lang->typeAB = '类型';
$lang->common->common = '公有模块';
/* 主导航菜单。*/
$lang->menu->my = '我的地盘|my|index';
$lang->menu->product = '产品视图|product|index';
$lang->menu->project = '项目视图|project|index';
$lang->menu->qa = '测试视图|qa|index';
$lang->menu->doc = '文档视图|doc|index';
$lang->menu->company = '组织视图|company|index';
$lang->menu->admin = '后台管理|admin|index';
/* 查询条中可以选择的对象列表。*/
$lang->searchObjects['bug'] = 'B:Bug';
$lang->searchObjects['story'] = 'S:需求';
$lang->searchObjects['task'] = 'T:任务';
$lang->searchObjects['testcase'] = 'C:用例';
$lang->searchObjects['project'] = 'P:项目';
$lang->searchObjects['product'] = 'P:产品';
$lang->searchObjects['user'] = 'U:用户';
$lang->searchObjects['build'] = 'B:Build';
$lang->searchObjects['release'] = 'R:发布';
$lang->searchObjects['productplan'] = 'P:产品计划';
$lang->searchObjects['testtask'] = 'T:测试任务';
$lang->searchObjects['doc'] = 'D:文档';
$lang->searchTips = '输入编号';
/* 导出文件的类型列表。*/
$lang->exportFileTypeList['csv'] = 'csv';
$lang->exportFileTypeList['xml'] = 'xml';
$lang->exportFileTypeList['html'] = 'html';
/* 风格列表。*/
$lang->themes['default'] = '默认';
$lang->themes['green'] = '绿色';
$lang->themes['red'] = '红色';
$lang->themes['classblue'] = '经典蓝';
/* 首页菜单设置。*/
$lang->index->menu->product = '浏览产品|product|browse';
$lang->index->menu->project = '浏览项目|project|browse';
/* 我的地盘菜单设置。*/
$lang->my->menu->account = '%s' . $lang->arrow;
$lang->my->menu->index = '首页|my|index';
$lang->my->menu->todo = array('link' => '我的TODO|my|todo|', 'subModule' => 'todo');
$lang->my->menu->task = '我的任务|my|task|';
$lang->my->menu->bug = '我的Bug|my|bug|';
$lang->my->menu->testtask = '我的测试|my|testtask|';
$lang->my->menu->story = '我的需求|my|story|';
$lang->my->menu->myProject = '我的项目|my|project|';
$lang->my->menu->dynamic = '我的动态|my|dynamic|';
$lang->my->menu->profile = array('link' => '我的档案|my|profile|', 'alias' => 'editprofile');
$lang->todo->menu = $lang->my->menu;
/* 产品视图设置。*/
$lang->product->menu->list = '%s';
$lang->product->menu->story = array('link' => '需求|product|browse|productID=%s', 'subModule' => 'story');
$lang->product->menu->dynamic = '动态|product|dynamic|productID=%s';
$lang->product->menu->plan = array('link' => '计划|productplan|browse|productID=%s', 'subModule' => 'productplan');
$lang->product->menu->release = array('link' => '发布|release|browse|productID=%s', 'subModule' => 'release');
$lang->product->menu->roadmap = '路线图|product|roadmap|productID=%s';
$lang->product->menu->doc = array('link' => '文档|product|doc|productID=%s', 'subModule' => 'doc');
$lang->product->menu->view = '概况|product|view|productID=%s';
$lang->product->menu->edit = '编辑|product|edit|productID=%s';
$lang->product->menu->delete = array('link' => '删除|product|delete|productID=%s', 'target' => 'hiddenwin');
$lang->product->menu->module = '模块|tree|browse|productID=%s&view=story';
$lang->product->menu->create = array('link' => '新增产品|product|create', 'float' => 'right');
$lang->product->menu->project = array('link' => '项目列表|product|project|status=all&productID=%s', 'float' => 'right');
$lang->product->menu->all = array('link' => '所有产品|product|index|locate=false', 'float' => 'right');
$lang->story->menu = $lang->product->menu;
$lang->productplan->menu = $lang->product->menu;
$lang->release->menu = $lang->product->menu;
/* 项目视图菜单设置。*/
$lang->project->menu->list = '%s';
$lang->project->menu->task = array('link' => '任务|project|task|projectID=%s', 'subModule' => 'task', 'alias' => 'grouptask,importtask');
$lang->project->menu->story = array('link' => '需求|project|story|projectID=%s');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = '动态|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => 'Build|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = '测试任务|project|testtask|projectID=%s';
$lang->project->menu->burn = '燃尽图|project|burn|projectID=%s';
$lang->project->menu->team = array('link' => '团队|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->doc = array('link' => '文档|project|doc|porjectID=%s', 'subModule' => 'doc');
$lang->project->menu->product = '产品|project|manageproducts|projectID=%s';
$lang->project->menu->linkstory = array('link' => '关联需求|project|linkstory|projectID=%s');
$lang->project->menu->view = '概况|project|view|projectID=%s';
$lang->project->menu->edit = '编辑|project|edit|projectID=%s';
$lang->project->menu->delete = array('link' => '删除|project|delete|projectID=%s', 'target' => 'hiddenwin');
$lang->project->menu->create = array('link' => '新增项目|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => '所有项目|project|index|locate=false', 'float' => 'right');
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
/* QA视图菜单设置。*/
$lang->bug->menu->product = '%s';
$lang->bug->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s', 'alias' => 'view,create,edit,resolve,close,activate,report', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,edit');
$lang->bug->menu->testtask = array('link' => '测试任务|testtask|browse|productID=%s');
$lang->testcase->menu->product = '%s';
$lang->testcase->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testcase->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit', 'subModule' => 'tree');
$lang->testcase->menu->testtask = array('link' => '测试任务|testtask|browse|productID=%s');
$lang->testtask->menu->product = '%s';
$lang->testtask->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testtask->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s');
$lang->testtask->menu->testtask = array('link' => '测试任务|testtask|browse|productID=%s', 'alias' => 'view,create,edit,linkcase,cases');
/* 文档视图菜单设置。*/
$lang->doc->menu->list = '%s';
$lang->doc->menu->browse = array('link' => '文档列表|doc|browse|libID=%s');
$lang->doc->menu->edit = '编辑文档库|doc|editLib|libID=%s';
$lang->doc->menu->module = '维护模块|tree|browse|libID=%s&viewType=doc';
$lang->doc->menu->delete = array('link' => '删除文档库|doc|deleteLib|libID=%s', 'target' => 'hiddenwin');
$lang->doc->menu->create = array('link' => '新增文档库|doc|createLib', 'float' => 'right');
/* 组织结构视图菜单设置。*/
$lang->company->menu->name = '%s' . $lang->arrow;
$lang->company->menu->browseUser = array('link' => '用户列表|company|browse', 'subModule' => 'user');
$lang->company->menu->dept = array('link' => '部门维护|dept|browse', 'subModule' => 'dept');
$lang->company->menu->browseGroup = array('link' => '权限分组|group|browse', 'subModule' => 'group');
$lang->company->menu->edit = array('link' => '公司管理|company|edit');
$lang->company->menu->dynamic = '组织动态|company|dynamic|';
$lang->company->menu->addGroup = array('link' => '添加分组|group|create', 'float' => 'right');
$lang->company->menu->addUser = array('link' => '添加用户|user|create|dept=%s', 'subModule' => 'user', 'float' => 'right');
$lang->dept->menu = $lang->company->menu;
$lang->group->menu = $lang->company->menu;
/* 用户信息菜单设置。*/
$lang->user->menu->account = '%s' . $lang->arrow;
$lang->user->menu->todo = array('link' => 'TODO列表|user|todo|account=%s', 'subModule' => 'todo');
$lang->user->menu->task = '任务列表|user|task|account=%s';
$lang->user->menu->bug = 'Bug列表|user|bug|account=%s';
$lang->user->menu->dynamic = '用户动态|user|dynamic|type=today&account=%s';
$lang->user->menu->projectList = '项目列表|user|project|account=%s';
$lang->user->menu->profile = array('link' => '用户信息|user|profile|account=%s', 'alias' => 'edit');
$lang->user->menu->browse = array('link' => '用户管理|company|browse|', 'float' => 'right');
/* 后台管理菜单设置。*/
$lang->admin->menu->extension = array('link' => '插件管理|extension|browse', 'subModule' => 'extension');
$lang->admin->menu->editor = array('link' => '扩展编辑器|editor|index', 'subModule' => 'editor');
$lang->admin->menu->mail = array('link' => 'Email配置|mail|set', 'subModule' => 'mail');
$lang->admin->menu->convert = array('link' => '从其他系统导入|convert|index', 'subModule' => 'convert');
$lang->admin->menu->trashes = array('link' => '回收站|action|trash', 'subModule' => 'action');
$lang->convert->menu = $lang->admin->menu;
$lang->upgrade->menu = $lang->admin->menu;
$lang->action->menu = $lang->admin->menu;
$lang->extension->menu = $lang->admin->menu;
$lang->editor->menu = $lang->admin->menu;
$lang->mail->menu = $lang->admin->menu;
/*菜单设置:分组设置。*/
$lang->menugroup->release = 'product';
$lang->menugroup->story = 'product';
$lang->menugroup->productplan = 'product';
$lang->menugroup->task = 'project';
$lang->menugroup->build = 'project';
$lang->menugroup->convert = 'admin';
$lang->menugroup->upgrade = 'admin';
$lang->menugroup->user = 'company';
$lang->menugroup->group = 'company';
$lang->menugroup->bug = 'qa';
$lang->menugroup->testcase = 'qa';
$lang->menugroup->testtask = 'qa';
$lang->menugroup->people = 'company';
$lang->menugroup->dept = 'company';
$lang->menugroup->todo = 'my';
$lang->menugroup->action = 'admin';
$lang->menugroup->extension = 'admin';
$lang->menugroup->editor = 'admin';
$lang->menugroup->mail = 'admin';
/* 错误提示信息。*/
$lang->error->companyNotFound = "您访问的域名 %s 没有对应的公司。";
$lang->error->length = array("『%s』长度错误应当为『%s』", "『%s』长度应当不超过『%s』且不小于『%s』。");
$lang->error->reg = "『%s』不符合格式应当为:『%s』。";
$lang->error->unique = "『%s』已经有『%s』这条记录了。";
$lang->error->gt = "『%s』应当大于『%s』。";
$lang->error->notempty = "『%s』不能为空。";
$lang->error->empty = "『%s』必须为空。";
$lang->error->equal = "『%s』必须为『%s』。";
$lang->error->int = array("『%s』应当是数字。", "『%s』应当介于『%s-%s』之间。");
$lang->error->float = "『%s』应当是数字可以是小数。";
$lang->error->email = "『%s』应当为合法的EMAIL。";
$lang->error->date = "『%s』应当为合法的日期。";
$lang->error->account = "『%s』应当为合法的用户名。";
$lang->error->passwordsame = "两次密码应当相等。";
$lang->error->passwordrule = "密码应该符合规则,长度至少为六位。";
$lang->error->accessDenied = '您没有访问权限';
/* 分页信息。*/
$lang->pager->noRecord = "暂时没有记录";
$lang->pager->digest = "共<strong>%s</strong>条记录,每页 <strong>%s</strong>条,页面:<strong>%s/%s</strong> ";
$lang->pager->first = "首页";
$lang->pager->pre = "上页";
$lang->pager->next = "下页";
$lang->pager->last = "末页";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "官方网站";
$lang->chinaScrum = "<a href='http://www.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum社区</a> ";
$lang->agileTraining = "<a href='http://www.zentao.net/goto.php?item=agiletrain' target='_blank'>培训</a> ";
$lang->donate = "<a href='http://www.zentao.net/goto.php?item=donate' target='_blank'>捐助禅道</a> ";
$lang->zentaoKeywords = "开源项目管理软件,项目管理,项目管理软件,pmp,pms,php框架国产php框架scrum工具,scrum管理工具,scrum管理软件,敏捷项目管理,禅道";
$lang->zentaoDESC = "禅道项目管理软件(ZenTaoPMS)是一款国产的基于LGPL协议开源免费的项目管理软件(工具、系统)同时也是一款scrum管理工具。
它集产品管理、项目管理、测试管理于一体同时还包含了事务管理、组织管理等诸多功能是中小型企业项目管理的首选。禅道项目管理软件使用PHP + MySQL开发
基于自主的PHP开发框架──ZenTaoPHP而成。第三方开发者或者企业可以非常方便的开发插件或者进行定制。禅道在手项目无忧";
/* 时间格式设置。*/
define('DT_DATETIME1', 'Y-m-d H:i:s');
define('DT_DATETIME2', 'y-m-d H:i');
define('DT_MONTHTIME1', 'n/d H:i');
define('DT_MONTHTIME2', 'n月d日 H:i');
define('DT_DATE1', 'Y-m-d');
define('DT_DATE2', 'Ymd');
define('DT_DATE3', 'Y年m月d日');
define('DT_DATE4', 'n月j日');
define('DT_TIME1', 'H:i:s');
define('DT_TIME2', 'H:i');

View File

@@ -1,296 +1,296 @@
<?php
/**
* The common simplified chinese file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id: zh-tw.php 2538 2012-01-04 07:25:59Z shiyangyangwork@yahoo.cn $
* @link http://www.zentao.net
*/
$lang->arrow = ' » ';
$lang->colon = '::';
$lang->comma = '';
$lang->dot = '。';
$lang->at = ' 于 ';
$lang->downArrow = '↓';
$lang->ZenTaoPMS = '禪道管理';
$lang->welcome = "歡迎使用『%s』{$lang->colon} {$lang->ZenTaoPMS}";
$lang->myControl = "我的地盤";
$lang->currentPos = '當前位置:';
$lang->logout = '退出';
$lang->login = '登錄';
$lang->aboutZenTao = '關於';
$lang->todayIs = '今天是%s';
$lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar'>時間: %s 毫秒, 內存: %s KB, 查詢: %s. </div></div>";
$lang->reset = '重填';
$lang->edit = '編輯';
$lang->copy = '複製';
$lang->delete = '刪除';
$lang->close = '關閉';
$lang->link = '關聯';
$lang->unlink = '移除';
$lang->import = '導入';
$lang->export = '導出';
$lang->setFileName = '檔案名:';
$lang->activate = '激活';
$lang->submitting = '稍候...';
$lang->save = '保存';
$lang->confirm = '確認';
$lang->preview = '查看';
$lang->goback = '返回';
$lang->go = 'GO';
$lang->more = '更多';
$lang->actions = '操作';
$lang->comment = '備註';
$lang->history = '歷史記錄';
$lang->attatch = '附件';
$lang->reverse = '[切換順序]';
$lang->switchDisplay= '[切換顯示]';
$lang->switchHelp = '切換幫助';
$lang->addFiles = '上傳了附件 ';
$lang->files = '附件 ';
$lang->unfold = '+';
$lang->fold = '-';
$lang->selectAll = '全選';
$lang->notFound = '抱歉,您訪問的對象並不存在!';
$lang->showAll = '++ 全部顯示 ++';
$lang->hideClosed = '-- 隱藏已結束 --';
$lang->feature = '未來';
$lang->year = '年';
$lang->workingHour = '工時';
$lang->idAB = 'ID';
$lang->priAB = 'P';
$lang->statusAB = '狀態';
$lang->openedByAB = '創建';
$lang->assignedToAB = '指派';
$lang->typeAB = '類型';
$lang->common->common = '公有模組';
/* 主導航菜單。*/
$lang->menu->my = '我的地盤|my|index';
$lang->menu->product = '產品視圖|product|index';
$lang->menu->project = '項目視圖|project|index';
$lang->menu->qa = '測試視圖|qa|index';
$lang->menu->doc = '文檔視圖|doc|index';
$lang->menu->company = '組織視圖|company|index';
$lang->menu->admin = '後台管理|admin|index';
/* 查詢條中可以選擇的對象列表。*/
$lang->searchObjects['bug'] = 'B:Bug';
$lang->searchObjects['story'] = 'S:需求';
$lang->searchObjects['task'] = 'T:任務';
$lang->searchObjects['testcase'] = 'C:用例';
$lang->searchObjects['project'] = 'P:項目';
$lang->searchObjects['product'] = 'P:產品';
$lang->searchObjects['user'] = 'U:用戶';
$lang->searchObjects['build'] = 'B:Build';
$lang->searchObjects['release'] = 'R:發佈';
$lang->searchObjects['productplan'] = 'P:產品計劃';
$lang->searchObjects['testtask'] = 'T:測試任務';
$lang->searchObjects['doc'] = 'D:文檔';
$lang->searchTips = '輸入編號';
/* 導出檔案的類型列表。*/
$lang->exportFileTypeList['csv'] = 'csv';
$lang->exportFileTypeList['xml'] = 'xml';
$lang->exportFileTypeList['html'] = 'html';
/* 風格列表。*/
$lang->themes['default'] = '預設';
$lang->themes['green'] = '綠色';
$lang->themes['red'] = '紅色';
$lang->themes['classblue'] = '經典藍';
/* 首頁菜單設置。*/
$lang->index->menu->product = '瀏覽產品|product|browse';
$lang->index->menu->project = '瀏覽項目|project|browse';
/* 我的地盤菜單設置。*/
$lang->my->menu->account = '%s' . $lang->arrow;
$lang->my->menu->index = '首頁|my|index';
$lang->my->menu->todo = array('link' => '我的TODO|my|todo|', 'subModule' => 'todo');
$lang->my->menu->task = '我的任務|my|task|';
$lang->my->menu->bug = '我的Bug|my|bug|';
$lang->my->menu->testtask = '我的測試|my|testtask|';
$lang->my->menu->story = '我的需求|my|story|';
$lang->my->menu->myProject = '我的項目|my|project|';
$lang->my->menu->dynamic = '我的動態|my|dynamic|';
$lang->my->menu->profile = array('link' => '我的檔案|my|profile|', 'alias' => 'editprofile');
$lang->todo->menu = $lang->my->menu;
/* 產品視圖設置。*/
$lang->product->menu->list = '%s';
$lang->product->menu->story = array('link' => '需求|product|browse|productID=%s', 'subModule' => 'story');
$lang->product->menu->dynamic = '動態|product|dynamic|productID=%s';
$lang->product->menu->plan = array('link' => '計劃|productplan|browse|productID=%s', 'subModule' => 'productplan');
$lang->product->menu->release = array('link' => '發佈|release|browse|productID=%s', 'subModule' => 'release');
$lang->product->menu->roadmap = '路線圖|product|roadmap|productID=%s';
$lang->product->menu->doc = array('link' => '文檔|product|doc|productID=%s', 'subModule' => 'doc');
$lang->product->menu->view = '概況|product|view|productID=%s';
$lang->product->menu->edit = '編輯|product|edit|productID=%s';
$lang->product->menu->delete = array('link' => '刪除|product|delete|productID=%s', 'target' => 'hiddenwin');
$lang->product->menu->module = '模組|tree|browse|productID=%s&view=story';
$lang->product->menu->create = array('link' => '新增產品|product|create', 'float' => 'right');
$lang->product->menu->project = array('link' => '項目列表|product|project|status=all&productID=%s', 'float' => 'right');
$lang->product->menu->all = array('link' => '所有產品|product|index|locate=false', 'float' => 'right');
$lang->story->menu = $lang->product->menu;
$lang->productplan->menu = $lang->product->menu;
$lang->release->menu = $lang->product->menu;
/* 項目視圖菜單設置。*/
$lang->project->menu->list = '%s';
$lang->project->menu->task = array('link' => '任務|project|task|projectID=%s', 'subModule' => 'task', 'alias' => 'grouptask,importtask');
$lang->project->menu->story = array('link' => '需求|project|story|projectID=%s');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = '動態|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => 'Build|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = '測試任務|project|testtask|projectID=%s';
$lang->project->menu->burn = '燃盡圖|project|burn|projectID=%s';
$lang->project->menu->team = array('link' => '團隊|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->doc = array('link' => '文檔|project|doc|porjectID=%s', 'subModule' => 'doc');
$lang->project->menu->product = '產品|project|manageproducts|projectID=%s';
$lang->project->menu->linkstory = array('link' => '關聯需求|project|linkstory|projectID=%s');
$lang->project->menu->view = '概況|project|view|projectID=%s';
$lang->project->menu->edit = '編輯|project|edit|projectID=%s';
$lang->project->menu->delete = array('link' => '刪除|project|delete|projectID=%s', 'target' => 'hiddenwin');
$lang->project->menu->create = array('link' => '新增項目|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => '所有項目|project|index|locate=false', 'float' => 'right');
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
/* QA視圖菜單設置。*/
$lang->bug->menu->product = '%s';
$lang->bug->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s', 'alias' => 'view,create,edit,resolve,close,activate,report', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,edit');
$lang->bug->menu->testtask = array('link' => '測試任務|testtask|browse|productID=%s');
$lang->testcase->menu->product = '%s';
$lang->testcase->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testcase->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit', 'subModule' => 'tree');
$lang->testcase->menu->testtask = array('link' => '測試任務|testtask|browse|productID=%s');
$lang->testtask->menu->product = '%s';
$lang->testtask->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testtask->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s');
$lang->testtask->menu->testtask = array('link' => '測試任務|testtask|browse|productID=%s', 'alias' => 'view,create,edit,linkcase,cases');
/* 文檔視圖菜單設置。*/
$lang->doc->menu->list = '%s';
$lang->doc->menu->browse = array('link' => '文檔列表|doc|browse|libID=%s');
$lang->doc->menu->edit = '編輯文檔庫|doc|editLib|libID=%s';
$lang->doc->menu->module = '維護模組|tree|browse|libID=%s&viewType=doc';
$lang->doc->menu->delete = array('link' => '刪除文檔庫|doc|deleteLib|libID=%s', 'target' => 'hiddenwin');
$lang->doc->menu->create = array('link' => '新增文檔庫|doc|createLib', 'float' => 'right');
/* 組織結構視圖菜單設置。*/
$lang->company->menu->name = '%s' . $lang->arrow;
$lang->company->menu->browseUser = array('link' => '用戶列表|company|browse', 'subModule' => 'user');
$lang->company->menu->dept = array('link' => '部門維護|dept|browse', 'subModule' => 'dept');
$lang->company->menu->browseGroup = array('link' => '權限分組|group|browse', 'subModule' => 'group');
$lang->company->menu->edit = array('link' => '公司管理|company|edit');
$lang->company->menu->dynamic = '組織動態|company|dynamic|';
$lang->company->menu->addGroup = array('link' => '添加分組|group|create', 'float' => 'right');
$lang->company->menu->addUser = array('link' => '添加用戶|user|create|dept=%s', 'subModule' => 'user', 'float' => 'right');
$lang->dept->menu = $lang->company->menu;
$lang->group->menu = $lang->company->menu;
/* 用戶信息菜單設置。*/
$lang->user->menu->account = '%s' . $lang->arrow;
$lang->user->menu->todo = array('link' => 'TODO列表|user|todo|account=%s', 'subModule' => 'todo');
$lang->user->menu->task = '任務列表|user|task|account=%s';
$lang->user->menu->bug = 'Bug列表|user|bug|account=%s';
$lang->user->menu->dynamic = '用戶動態|user|dynamic|type=today&account=%s';
$lang->user->menu->projectList = '項目列表|user|project|account=%s';
$lang->user->menu->profile = array('link' => '用戶信息|user|profile|account=%s', 'alias' => 'edit');
$lang->user->menu->browse = array('link' => '用戶管理|company|browse|', 'float' => 'right');
/* 後台管理菜單設置。*/
$lang->admin->menu->extension = array('link' => '插件管理|extension|browse', 'subModule' => 'extension');
$lang->admin->menu->editor = array('link' => '擴展編輯器|editor|index', 'subModule' => 'editor');
$lang->admin->menu->mail = array('link' => 'Email配置|mail|set', 'subModule' => 'mail');
$lang->admin->menu->convert = array('link' => '從其他系統導入|convert|index', 'subModule' => 'convert');
$lang->admin->menu->trashes = array('link' => '資源回收筒|action|trash', 'subModule' => 'action');
$lang->convert->menu = $lang->admin->menu;
$lang->upgrade->menu = $lang->admin->menu;
$lang->action->menu = $lang->admin->menu;
$lang->extension->menu = $lang->admin->menu;
$lang->editor->menu = $lang->admin->menu;
$lang->mail->menu = $lang->admin->menu;
/*菜單設置:分組設置。*/
$lang->menugroup->release = 'product';
$lang->menugroup->story = 'product';
$lang->menugroup->productplan = 'product';
$lang->menugroup->task = 'project';
$lang->menugroup->build = 'project';
$lang->menugroup->convert = 'admin';
$lang->menugroup->upgrade = 'admin';
$lang->menugroup->user = 'company';
$lang->menugroup->group = 'company';
$lang->menugroup->bug = 'qa';
$lang->menugroup->testcase = 'qa';
$lang->menugroup->testtask = 'qa';
$lang->menugroup->people = 'company';
$lang->menugroup->dept = 'company';
$lang->menugroup->todo = 'my';
$lang->menugroup->action = 'admin';
$lang->menugroup->extension = 'admin';
$lang->menugroup->editor = 'admin';
$lang->menugroup->mail = 'admin';
/* 錯誤提示信息。*/
$lang->error->companyNotFound = "您訪問的域名 %s 沒有對應的公司。";
$lang->error->length = array("『%s』長度錯誤應當為『%s』", "『%s』長度應當不超過『%s』且不小於『%s』。");
$lang->error->reg = "『%s』不符合格式應當為:『%s』。";
$lang->error->unique = "『%s』已經有『%s』這條記錄了。";
$lang->error->gt = "『%s』應當大於『%s』。";
$lang->error->notempty = "『%s』不能為空。";
$lang->error->empty = "『%s』必須為空。";
$lang->error->equal = "『%s』必須為『%s』。";
$lang->error->int = array("『%s』應當是數字。", "『%s』應當介於『%s-%s』之間。");
$lang->error->float = "『%s』應當是數字可以是小數。";
$lang->error->email = "『%s』應當為合法的EMAIL。";
$lang->error->date = "『%s』應當為合法的日期。";
$lang->error->account = "『%s』應當為合法的用戶名。";
$lang->error->passwordsame = "兩次密碼應當相等。";
$lang->error->passwordrule = "密碼應該符合規則,長度至少為六位。";
$lang->error->accessDenied = '您沒有訪問權限';
/* 分頁信息。*/
$lang->pager->noRecord = "暫時沒有記錄";
$lang->pager->digest = "共<strong>%s</strong>條記錄,每頁 <strong>%s</strong>條,頁面:<strong>%s/%s</strong> ";
$lang->pager->first = "首頁";
$lang->pager->pre = "上頁";
$lang->pager->next = "下頁";
$lang->pager->last = "末頁";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "官方網站";
$lang->chinaScrum = "<a href='http://www.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum社區</a> ";
$lang->agileTraining = "<a href='http://www.zentao.net/goto.php?item=agiletrain' target='_blank'>培訓</a> ";
$lang->donate = "<a href='http://www.zentao.net/goto.php?item=donate' target='_blank'>捐助禪道</a> ";
$lang->zentaoKeywords = "開源項目管理軟件,項目管理,項目管理軟件,pmp,pms,php框架國產php框架scrum工具,scrum管理工具,scrum管理軟件,敏捷項目管理,禪道";
$lang->zentaoDESC = "禪道項目管理軟件(ZenTaoPMS)是一款國產的基于LGPL協議開源免費的項目管理軟件(工具、系統)同時也是一款scrum管理工具。
它集產品管理、項目管理、測試管理於一體同時還包含了事務管理、組織管理等諸多功能是中小型企業項目管理的首選。禪道項目管理軟件使用PHP + MySQL開發
基于自主的PHP開發框架──ZenTaoPHP而成。第三方開發者或者企業可以非常方便的開發插件或者進行定製。禪道在手項目無憂";
/* 時間格式設置。*/
define('DT_DATETIME1', 'Y-m-d H:i:s');
define('DT_DATETIME2', 'y-m-d H:i');
define('DT_MONTHTIME1', 'n/d H:i');
define('DT_MONTHTIME2', 'n月d日 H:i');
define('DT_DATE1', 'Y-m-d');
define('DT_DATE2', 'Ymd');
define('DT_DATE3', 'Y年m月d日');
define('DT_DATE4', 'n月j日');
define('DT_TIME1', 'H:i:s');
define('DT_TIME2', 'H:i');
<?php
/**
* The common simplified chinese file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id: zh-tw.php 2538 2012-01-04 07:25:59Z shiyangyangwork@yahoo.cn $
* @link http://www.zentao.net
*/
$lang->arrow = ' » ';
$lang->colon = '::';
$lang->comma = '';
$lang->dot = '。';
$lang->at = ' 于 ';
$lang->downArrow = '↓';
$lang->ZenTaoPMS = '禪道管理';
$lang->welcome = "歡迎使用『%s』{$lang->colon} {$lang->ZenTaoPMS}";
$lang->myControl = "我的地盤";
$lang->currentPos = '當前位置:';
$lang->logout = '退出';
$lang->login = '登錄';
$lang->aboutZenTao = '關於';
$lang->todayIs = '今天是%s';
$lang->runInfo = "<div class='row'><div class='u-1 a-center' id='debugbar'>時間: %s 毫秒, 內存: %s KB, 查詢: %s. </div></div>";
$lang->reset = '重填';
$lang->edit = '編輯';
$lang->copy = '複製';
$lang->delete = '刪除';
$lang->close = '關閉';
$lang->link = '關聯';
$lang->unlink = '移除';
$lang->import = '導入';
$lang->export = '導出';
$lang->setFileName = '檔案名:';
$lang->activate = '激活';
$lang->submitting = '稍候...';
$lang->save = '保存';
$lang->confirm = '確認';
$lang->preview = '查看';
$lang->goback = '返回';
$lang->go = 'GO';
$lang->more = '更多';
$lang->actions = '操作';
$lang->comment = '備註';
$lang->history = '歷史記錄';
$lang->attatch = '附件';
$lang->reverse = '[切換順序]';
$lang->switchDisplay= '[切換顯示]';
$lang->switchHelp = '切換幫助';
$lang->addFiles = '上傳了附件 ';
$lang->files = '附件 ';
$lang->unfold = '+';
$lang->fold = '-';
$lang->selectAll = '全選';
$lang->notFound = '抱歉,您訪問的對象並不存在!';
$lang->showAll = '++ 全部顯示 ++';
$lang->hideClosed = '-- 隱藏已結束 --';
$lang->feature = '未來';
$lang->year = '年';
$lang->workingHour = '工時';
$lang->idAB = 'ID';
$lang->priAB = 'P';
$lang->statusAB = '狀態';
$lang->openedByAB = '創建';
$lang->assignedToAB = '指派';
$lang->typeAB = '類型';
$lang->common->common = '公有模組';
/* 主導航菜單。*/
$lang->menu->my = '我的地盤|my|index';
$lang->menu->product = '產品視圖|product|index';
$lang->menu->project = '項目視圖|project|index';
$lang->menu->qa = '測試視圖|qa|index';
$lang->menu->doc = '文檔視圖|doc|index';
$lang->menu->company = '組織視圖|company|index';
$lang->menu->admin = '後台管理|admin|index';
/* 查詢條中可以選擇的對象列表。*/
$lang->searchObjects['bug'] = 'B:Bug';
$lang->searchObjects['story'] = 'S:需求';
$lang->searchObjects['task'] = 'T:任務';
$lang->searchObjects['testcase'] = 'C:用例';
$lang->searchObjects['project'] = 'P:項目';
$lang->searchObjects['product'] = 'P:產品';
$lang->searchObjects['user'] = 'U:用戶';
$lang->searchObjects['build'] = 'B:Build';
$lang->searchObjects['release'] = 'R:發佈';
$lang->searchObjects['productplan'] = 'P:產品計劃';
$lang->searchObjects['testtask'] = 'T:測試任務';
$lang->searchObjects['doc'] = 'D:文檔';
$lang->searchTips = '輸入編號';
/* 導出檔案的類型列表。*/
$lang->exportFileTypeList['csv'] = 'csv';
$lang->exportFileTypeList['xml'] = 'xml';
$lang->exportFileTypeList['html'] = 'html';
/* 風格列表。*/
$lang->themes['default'] = '預設';
$lang->themes['green'] = '綠色';
$lang->themes['red'] = '紅色';
$lang->themes['classblue'] = '經典藍';
/* 首頁菜單設置。*/
$lang->index->menu->product = '瀏覽產品|product|browse';
$lang->index->menu->project = '瀏覽項目|project|browse';
/* 我的地盤菜單設置。*/
$lang->my->menu->account = '%s' . $lang->arrow;
$lang->my->menu->index = '首頁|my|index';
$lang->my->menu->todo = array('link' => '我的TODO|my|todo|', 'subModule' => 'todo');
$lang->my->menu->task = '我的任務|my|task|';
$lang->my->menu->bug = '我的Bug|my|bug|';
$lang->my->menu->testtask = '我的測試|my|testtask|';
$lang->my->menu->story = '我的需求|my|story|';
$lang->my->menu->myProject = '我的項目|my|project|';
$lang->my->menu->dynamic = '我的動態|my|dynamic|';
$lang->my->menu->profile = array('link' => '我的檔案|my|profile|', 'alias' => 'editprofile');
$lang->todo->menu = $lang->my->menu;
/* 產品視圖設置。*/
$lang->product->menu->list = '%s';
$lang->product->menu->story = array('link' => '需求|product|browse|productID=%s', 'subModule' => 'story');
$lang->product->menu->dynamic = '動態|product|dynamic|productID=%s';
$lang->product->menu->plan = array('link' => '計劃|productplan|browse|productID=%s', 'subModule' => 'productplan');
$lang->product->menu->release = array('link' => '發佈|release|browse|productID=%s', 'subModule' => 'release');
$lang->product->menu->roadmap = '路線圖|product|roadmap|productID=%s';
$lang->product->menu->doc = array('link' => '文檔|product|doc|productID=%s', 'subModule' => 'doc');
$lang->product->menu->view = '概況|product|view|productID=%s';
$lang->product->menu->edit = '編輯|product|edit|productID=%s';
$lang->product->menu->delete = array('link' => '刪除|product|delete|productID=%s', 'target' => 'hiddenwin');
$lang->product->menu->module = '模組|tree|browse|productID=%s&view=story';
$lang->product->menu->create = array('link' => '新增產品|product|create', 'float' => 'right');
$lang->product->menu->project = array('link' => '項目列表|product|project|status=all&productID=%s', 'float' => 'right');
$lang->product->menu->all = array('link' => '所有產品|product|index|locate=false', 'float' => 'right');
$lang->story->menu = $lang->product->menu;
$lang->productplan->menu = $lang->product->menu;
$lang->release->menu = $lang->product->menu;
/* 項目視圖菜單設置。*/
$lang->project->menu->list = '%s';
$lang->project->menu->task = array('link' => '任務|project|task|projectID=%s', 'subModule' => 'task', 'alias' => 'grouptask,importtask');
$lang->project->menu->story = array('link' => '需求|project|story|projectID=%s');
$lang->project->menu->bug = 'Bug|project|bug|projectID=%s';
$lang->project->menu->dynamic = '動態|project|dynamic|projectID=%s';
$lang->project->menu->build = array('link' => 'Build|project|build|projectID=%s', 'subModule' => 'build');
$lang->project->menu->testtask = '測試任務|project|testtask|projectID=%s';
$lang->project->menu->burn = '燃盡圖|project|burn|projectID=%s';
$lang->project->menu->team = array('link' => '團隊|project|team|projectID=%s', 'alias' => 'managemembers');
$lang->project->menu->doc = array('link' => '文檔|project|doc|porjectID=%s', 'subModule' => 'doc');
$lang->project->menu->product = '產品|project|manageproducts|projectID=%s';
$lang->project->menu->linkstory = array('link' => '關聯需求|project|linkstory|projectID=%s');
$lang->project->menu->view = '概況|project|view|projectID=%s';
$lang->project->menu->edit = '編輯|project|edit|projectID=%s';
$lang->project->menu->delete = array('link' => '刪除|project|delete|projectID=%s', 'target' => 'hiddenwin');
$lang->project->menu->create = array('link' => '新增項目|project|create', 'float' => 'right');
$lang->project->menu->all = array('link' => '所有項目|project|index|locate=false', 'float' => 'right');
$lang->task->menu = $lang->project->menu;
$lang->build->menu = $lang->project->menu;
/* QA視圖菜單設置。*/
$lang->bug->menu->product = '%s';
$lang->bug->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s', 'alias' => 'view,create,edit,resolve,close,activate,report', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,edit');
$lang->bug->menu->testtask = array('link' => '測試任務|testtask|browse|productID=%s');
$lang->testcase->menu->product = '%s';
$lang->testcase->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testcase->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit', 'subModule' => 'tree');
$lang->testcase->menu->testtask = array('link' => '測試任務|testtask|browse|productID=%s');
$lang->testtask->menu->product = '%s';
$lang->testtask->menu->bug = array('link' => '缺陷管理|bug|browse|productID=%s');
$lang->testtask->menu->testcase = array('link' => '用例管理|testcase|browse|productID=%s');
$lang->testtask->menu->testtask = array('link' => '測試任務|testtask|browse|productID=%s', 'alias' => 'view,create,edit,linkcase,cases');
/* 文檔視圖菜單設置。*/
$lang->doc->menu->list = '%s';
$lang->doc->menu->browse = array('link' => '文檔列表|doc|browse|libID=%s');
$lang->doc->menu->edit = '編輯文檔庫|doc|editLib|libID=%s';
$lang->doc->menu->module = '維護模組|tree|browse|libID=%s&viewType=doc';
$lang->doc->menu->delete = array('link' => '刪除文檔庫|doc|deleteLib|libID=%s', 'target' => 'hiddenwin');
$lang->doc->menu->create = array('link' => '新增文檔庫|doc|createLib', 'float' => 'right');
/* 組織結構視圖菜單設置。*/
$lang->company->menu->name = '%s' . $lang->arrow;
$lang->company->menu->browseUser = array('link' => '用戶列表|company|browse', 'subModule' => 'user');
$lang->company->menu->dept = array('link' => '部門維護|dept|browse', 'subModule' => 'dept');
$lang->company->menu->browseGroup = array('link' => '權限分組|group|browse', 'subModule' => 'group');
$lang->company->menu->edit = array('link' => '公司管理|company|edit');
$lang->company->menu->dynamic = '組織動態|company|dynamic|';
$lang->company->menu->addGroup = array('link' => '添加分組|group|create', 'float' => 'right');
$lang->company->menu->addUser = array('link' => '添加用戶|user|create|dept=%s', 'subModule' => 'user', 'float' => 'right');
$lang->dept->menu = $lang->company->menu;
$lang->group->menu = $lang->company->menu;
/* 用戶信息菜單設置。*/
$lang->user->menu->account = '%s' . $lang->arrow;
$lang->user->menu->todo = array('link' => 'TODO列表|user|todo|account=%s', 'subModule' => 'todo');
$lang->user->menu->task = '任務列表|user|task|account=%s';
$lang->user->menu->bug = 'Bug列表|user|bug|account=%s';
$lang->user->menu->dynamic = '用戶動態|user|dynamic|type=today&account=%s';
$lang->user->menu->projectList = '項目列表|user|project|account=%s';
$lang->user->menu->profile = array('link' => '用戶信息|user|profile|account=%s', 'alias' => 'edit');
$lang->user->menu->browse = array('link' => '用戶管理|company|browse|', 'float' => 'right');
/* 後台管理菜單設置。*/
$lang->admin->menu->extension = array('link' => '插件管理|extension|browse', 'subModule' => 'extension');
$lang->admin->menu->editor = array('link' => '擴展編輯器|editor|index', 'subModule' => 'editor');
$lang->admin->menu->mail = array('link' => 'Email配置|mail|set', 'subModule' => 'mail');
$lang->admin->menu->convert = array('link' => '從其他系統導入|convert|index', 'subModule' => 'convert');
$lang->admin->menu->trashes = array('link' => '資源回收筒|action|trash', 'subModule' => 'action');
$lang->convert->menu = $lang->admin->menu;
$lang->upgrade->menu = $lang->admin->menu;
$lang->action->menu = $lang->admin->menu;
$lang->extension->menu = $lang->admin->menu;
$lang->editor->menu = $lang->admin->menu;
$lang->mail->menu = $lang->admin->menu;
/*菜單設置:分組設置。*/
$lang->menugroup->release = 'product';
$lang->menugroup->story = 'product';
$lang->menugroup->productplan = 'product';
$lang->menugroup->task = 'project';
$lang->menugroup->build = 'project';
$lang->menugroup->convert = 'admin';
$lang->menugroup->upgrade = 'admin';
$lang->menugroup->user = 'company';
$lang->menugroup->group = 'company';
$lang->menugroup->bug = 'qa';
$lang->menugroup->testcase = 'qa';
$lang->menugroup->testtask = 'qa';
$lang->menugroup->people = 'company';
$lang->menugroup->dept = 'company';
$lang->menugroup->todo = 'my';
$lang->menugroup->action = 'admin';
$lang->menugroup->extension = 'admin';
$lang->menugroup->editor = 'admin';
$lang->menugroup->mail = 'admin';
/* 錯誤提示信息。*/
$lang->error->companyNotFound = "您訪問的域名 %s 沒有對應的公司。";
$lang->error->length = array("『%s』長度錯誤應當為『%s』", "『%s』長度應當不超過『%s』且不小於『%s』。");
$lang->error->reg = "『%s』不符合格式應當為:『%s』。";
$lang->error->unique = "『%s』已經有『%s』這條記錄了。";
$lang->error->gt = "『%s』應當大於『%s』。";
$lang->error->notempty = "『%s』不能為空。";
$lang->error->empty = "『%s』必須為空。";
$lang->error->equal = "『%s』必須為『%s』。";
$lang->error->int = array("『%s』應當是數字。", "『%s』應當介於『%s-%s』之間。");
$lang->error->float = "『%s』應當是數字可以是小數。";
$lang->error->email = "『%s』應當為合法的EMAIL。";
$lang->error->date = "『%s』應當為合法的日期。";
$lang->error->account = "『%s』應當為合法的用戶名。";
$lang->error->passwordsame = "兩次密碼應當相等。";
$lang->error->passwordrule = "密碼應該符合規則,長度至少為六位。";
$lang->error->accessDenied = '您沒有訪問權限';
/* 分頁信息。*/
$lang->pager->noRecord = "暫時沒有記錄";
$lang->pager->digest = "共<strong>%s</strong>條記錄,每頁 <strong>%s</strong>條,頁面:<strong>%s/%s</strong> ";
$lang->pager->first = "首頁";
$lang->pager->pre = "上頁";
$lang->pager->next = "下頁";
$lang->pager->last = "末頁";
$lang->pager->locate = "GO!";
$lang->zentaoSite = "官方網站";
$lang->chinaScrum = "<a href='http://www.zentao.net/goto.php?item=chinascrum' target='_blank'>Scrum社區</a> ";
$lang->agileTraining = "<a href='http://www.zentao.net/goto.php?item=agiletrain' target='_blank'>培訓</a> ";
$lang->donate = "<a href='http://www.zentao.net/goto.php?item=donate' target='_blank'>捐助禪道</a> ";
$lang->zentaoKeywords = "開源項目管理軟件,項目管理,項目管理軟件,pmp,pms,php框架國產php框架scrum工具,scrum管理工具,scrum管理軟件,敏捷項目管理,禪道";
$lang->zentaoDESC = "禪道項目管理軟件(ZenTaoPMS)是一款國產的基于LGPL協議開源免費的項目管理軟件(工具、系統)同時也是一款scrum管理工具。
它集產品管理、項目管理、測試管理於一體同時還包含了事務管理、組織管理等諸多功能是中小型企業項目管理的首選。禪道項目管理軟件使用PHP + MySQL開發
基于自主的PHP開發框架──ZenTaoPHP而成。第三方開發者或者企業可以非常方便的開發插件或者進行定製。禪道在手項目無憂";
/* 時間格式設置。*/
define('DT_DATETIME1', 'Y-m-d H:i:s');
define('DT_DATETIME2', 'y-m-d H:i');
define('DT_MONTHTIME1', 'n/d H:i');
define('DT_MONTHTIME2', 'n月d日 H:i');
define('DT_DATE1', 'Y-m-d');
define('DT_DATE2', 'Ymd');
define('DT_DATE3', 'Y年m月d日');
define('DT_DATE4', 'n月j日');
define('DT_TIME1', 'H:i:s');
define('DT_TIME2', 'H:i');

View File

@@ -1,366 +1,366 @@
<?php
/**
* The model file of common module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package common
* @version $Id$
* @link http://www.zentao.net
*/
class commonModel extends model
{
/**
* Start the session.
*
* @access public
* @return void
*/
public function startSession()
{
session_name($this->config->sessionVar);
if(isset($_GET[$this->config->sessionVar])) session_id($_GET[$this->config->sessionVar]);
session_start();
}
/**
* Set the header info.
*
* @access public
* @return void
*/
public function sendHeader()
{
header("Content-Type: text/html; Language={$this->config->encoding}");
header("Cache-control: private");
}
/**
* Set the commpany.
*
* First, search company by the http host. If not found, search by the default domain. Last, use the first as the default.
* After get the company, save it to session.
* @access public
* @return void
*/
public function setCompany()
{
$httpHost = $this->server->http_host;
if(strpos($httpHost, ":"))
{
$httpHost = explode(":", $httpHost);
$httpHost = $httpHost[0];
}
if($this->session->company and $this->session->company->pms == $httpHost)
{
$this->app->company = $this->session->company;
}
else
{
$company = $this->loadModel('company')->getByDomain();
if(!$company and isset($this->config->default->domain)) $company = $this->company->getByDomain($this->config->default->domain);
if(!$company) $company = $this->company->getFirst();
if(!$company) $this->app->error(sprintf($this->lang->error->companyNotFound, $httpHost), __FILE__, __LINE__, $exit = true);
$this->session->set('company', $company);
$this->app->company = $company;
}
}
/**
* Set the user info.
*
* @access public
* @return void
*/
public function setUser()
{
if($this->session->user)
{
$this->app->user = $this->session->user;
}
elseif($this->app->company->guest)
{
$user = new stdClass();
$user->id = 0;
$user->account = 'guest';
$user->realname = 'guest';
$user->rights = $this->loadModel('user')->authorize('guest');
$this->session->set('user', $user);
$this->app->user = $this->session->user;
}
}
/**
* Juage a method of one module is open or not?
*
* @param string $module
* @param string $method
* @access public
* @return bool
*/
public function isOpenMethod($module, $method)
{
if($module == 'user' and strpos('login|logout|deny', $method) !== false) return true;
if($module == 'api' and $method == 'getsessionid') return true;
if($module == 'misc' and $method == 'about') return true;
if($module == 'help' and $method == 'field') return true;
return false;
}
/**
* Deny access.
*
* @access public
* @return void
*/
public function deny($module, $method)
{
$vars = "module=$module&method=$method";
if(isset($this->server->http_referer))
{
$referer = helper::safe64Encode($this->server->http_referer);
$vars .= "&referer=$referer";
}
$denyLink = helper::createLink('user', 'deny', $vars);
/* Fix the bug of IE: use js locate, can't get the referer. */
if(strpos($this->server->http_user_agent, 'MSIE') !== false)
{
echo "<a href='$denyLink' id='denylink' style='display:none'>deny</a>";
echo "<script language='javascript'>document.getElementById('denylink').click();</script>";
}
else
{
echo js::locate($denyLink);
}
exit;
}
/**
* Get the run info.
*
* @param mixed $startTime the start time of this execution
* @access public
* @return array the run info array.
*/
public function getRunInfo($startTime)
{
$info['timeUsed'] = round(getTime() - $startTime, 4) * 1000;
$info['memory'] = round(memory_get_peak_usage() / 1024, 1);
$info['querys'] = count(dao::$querys);
return $info;
}
/**
* Print top bar.
*
* @static
* @access public
* @return void
*/
public static function printTopBar()
{
global $lang, $app;
printf($lang->todayIs, date(DT_DATE3));
if(isset($app->user)) echo $app->user->realname . ' ';
if(isset($app->user) and $app->user->account != 'guest')
{
echo html::a(helper::createLink('my', 'index'), $lang->myControl);
echo html::a(helper::createLink('user', 'logout'), $lang->logout);
}
else
{
echo html::a(helper::createLink('user', 'login'), $lang->login);
}
echo html::a(helper::createLink('misc', 'about'), $lang->aboutZenTao, '', "class='about'");
echo $lang->agileTraining;
echo $lang->donate;
}
/**
* Print the main menu.
*
* @param string $moduleName
* @static
* @access public
* @return void
*/
public static function printMainmenu($moduleName)
{
global $app, $lang;
echo "<ul>\n";
/* Set the main main menu. */
$mainMenu = $moduleName;
if(isset($lang->menugroup->$moduleName)) $mainMenu = $lang->menugroup->$moduleName;
/* Print all main menus. */
foreach($lang->menu as $menuKey => $menu)
{
$active = $menuKey == $mainMenu ? "class='active'" : '';
list($menuLabel, $module, $method) = explode('|', $menu);
if(common::hasPriv($module, $method))
{
$link = helper::createLink($module, $method);
echo "<li $active><nobr><a href='$link' id='menu$menuKey'>$menuLabel</a></nobr></li>\n";
}
}
}
/**
* Print the search box.
*
* @static
* @access public
* @return void
*/
public static function printSearchBox()
{
global $app, $lang;
$moduleName = $app->getModuleName();
$methodName = $app->getMethodName();
$searchObject = $moduleName;
if($moduleName == 'product')
{
if($methodName == 'browse') $searchObject = 'story';
}
elseif($moduleName == 'project')
{
if(strpos('task|story|bug|build', $methodName) !== false) $searchObject = $methodName;
}
elseif($moduleName == 'my' or $moduleName == 'user')
{
$searchObject = $methodName;
}
echo "<li id='searchbox'>";
echo html::select('searchType', $lang->searchObjects, $searchObject);
echo html::input('searchQuery', $lang->searchTips, "onclick=this.value='' onkeydown='if(event.keyCode==13) shortcut()' class='w-60px'");
echo html::commonButton($lang->go, 'id="objectSwitcher" onclick="shortcut()"');
echo "</li>";
echo "</ul>\n";
}
/**
* Print the module menu.
*
* @param string $moduleName
* @static
* @access public
* @return void
*/
public static function printModuleMenu($moduleName)
{
global $lang, $app;
if(!isset($lang->$moduleName->menu)) {echo "<ul></ul>"; return;}
/* Get the sub menus of the module, and get current module and method. */
$submenus = $lang->$moduleName->menu;
$currentModule = $app->getModuleName();
$currentMethod = $app->getMethodName();
/* The beginning of the menu. */
echo "<ul>\n";
/* Cycling to print every sub menus. */
foreach($submenus as $subMenuKey => $submenu)
{
/* Init the these vars. */
$link = $submenu;
$subModule = '';
$alias = '';
$float = '';
$active = '';
$target = '';
if(is_array($submenu)) extract($submenu); // If the sub menu is an array, extract it.
/* Print the menu. */
if(strpos($link, '|') === false)
{
echo "<li>$link</li>\n";
}
else
{
$link = explode('|', $link);
list($label, $module, $method) = $link;
$vars = isset($link[3]) ? $link[3] : '';
if(common::hasPriv($module, $method))
{
/* Is the currentModule active? */
if($currentModule == $subModule) $active = 'active';
if($module == $currentModule and ($method == $currentMethod or strpos($alias, $currentMethod) !== false)) $active = 'active';
echo "<li class='$float $active'>" . html::a(helper::createLink($module, $method, $vars), $label, $target, "id=submenu$subMenuKey") . "</li>\n";
}
}
}
echo "</ul>\n";
}
/**
* Print the bread menu.
*
* @param string $moduleName
* @param string $position
* @static
* @access public
* @return void
*/
public static function printBreadMenu($moduleName, $position)
{
global $lang;
$mainMenu = $moduleName;
if(isset($lang->menugroup->$moduleName)) $mainMenu = $lang->menugroup->$moduleName;
echo html::a(helper::createLink('my', 'index'), $lang->ZenTaoPMS) . $lang->arrow;
if($moduleName != 'index')
{
list($menuLabel, $module, $method) = explode('|', $lang->menu->$mainMenu);
echo html::a(helper::createLink($module, $method), $menuLabel);
}
else
{
echo $lang->index->common;
}
if(empty($position)) return;
echo $lang->arrow;
foreach($position as $key => $link)
{
echo $link;
if(isset($position[$key + 1])) echo $lang->arrow;
}
}
/**
* Diff two string. (see phpt)
*
* @param string $text1
* @param string $text2
* @static
* @access public
* @return string
*/
public static function diff($text1, $text2)
{
$text1 = str_replace('&nbsp;', '', trim($text1));
$text2 = str_replace('&nbsp;', '', trim($text2));
$w = explode("\n", $text1);
$o = explode("\n", $text2);
$w1 = array_diff_assoc($w,$o);
$o1 = array_diff_assoc($o,$w);
$w2 = array();
$o2 = array();
foreach($w1 as $idx => $val) $w2[sprintf("%03d<",$idx)] = sprintf("%03d- ", $idx+1) . "<del>" . trim($val) . "</del>";
foreach($o1 as $idx => $val) $o2[sprintf("%03d>",$idx)] = sprintf("%03d+ ", $idx+1) . "<ins>" . trim($val) . "</ins>";
$diff = array_merge($w2, $o2);
ksort($diff);
return implode("\n", $diff);
}
}
<?php
/**
* The model file of common module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package common
* @version $Id$
* @link http://www.zentao.net
*/
class commonModel extends model
{
/**
* Start the session.
*
* @access public
* @return void
*/
public function startSession()
{
session_name($this->config->sessionVar);
if(isset($_GET[$this->config->sessionVar])) session_id($_GET[$this->config->sessionVar]);
session_start();
}
/**
* Set the header info.
*
* @access public
* @return void
*/
public function sendHeader()
{
header("Content-Type: text/html; Language={$this->config->encoding}");
header("Cache-control: private");
}
/**
* Set the commpany.
*
* First, search company by the http host. If not found, search by the default domain. Last, use the first as the default.
* After get the company, save it to session.
* @access public
* @return void
*/
public function setCompany()
{
$httpHost = $this->server->http_host;
if(strpos($httpHost, ":"))
{
$httpHost = explode(":", $httpHost);
$httpHost = $httpHost[0];
}
if($this->session->company and $this->session->company->pms == $httpHost)
{
$this->app->company = $this->session->company;
}
else
{
$company = $this->loadModel('company')->getByDomain();
if(!$company and isset($this->config->default->domain)) $company = $this->company->getByDomain($this->config->default->domain);
if(!$company) $company = $this->company->getFirst();
if(!$company) $this->app->error(sprintf($this->lang->error->companyNotFound, $httpHost), __FILE__, __LINE__, $exit = true);
$this->session->set('company', $company);
$this->app->company = $company;
}
}
/**
* Set the user info.
*
* @access public
* @return void
*/
public function setUser()
{
if($this->session->user)
{
$this->app->user = $this->session->user;
}
elseif($this->app->company->guest)
{
$user = new stdClass();
$user->id = 0;
$user->account = 'guest';
$user->realname = 'guest';
$user->rights = $this->loadModel('user')->authorize('guest');
$this->session->set('user', $user);
$this->app->user = $this->session->user;
}
}
/**
* Juage a method of one module is open or not?
*
* @param string $module
* @param string $method
* @access public
* @return bool
*/
public function isOpenMethod($module, $method)
{
if($module == 'user' and strpos('login|logout|deny', $method) !== false) return true;
if($module == 'api' and $method == 'getsessionid') return true;
if($module == 'misc' and $method == 'about') return true;
if($module == 'help' and $method == 'field') return true;
return false;
}
/**
* Deny access.
*
* @access public
* @return void
*/
public function deny($module, $method)
{
$vars = "module=$module&method=$method";
if(isset($this->server->http_referer))
{
$referer = helper::safe64Encode($this->server->http_referer);
$vars .= "&referer=$referer";
}
$denyLink = helper::createLink('user', 'deny', $vars);
/* Fix the bug of IE: use js locate, can't get the referer. */
if(strpos($this->server->http_user_agent, 'MSIE') !== false)
{
echo "<a href='$denyLink' id='denylink' style='display:none'>deny</a>";
echo "<script language='javascript'>document.getElementById('denylink').click();</script>";
}
else
{
echo js::locate($denyLink);
}
exit;
}
/**
* Get the run info.
*
* @param mixed $startTime the start time of this execution
* @access public
* @return array the run info array.
*/
public function getRunInfo($startTime)
{
$info['timeUsed'] = round(getTime() - $startTime, 4) * 1000;
$info['memory'] = round(memory_get_peak_usage() / 1024, 1);
$info['querys'] = count(dao::$querys);
return $info;
}
/**
* Print top bar.
*
* @static
* @access public
* @return void
*/
public static function printTopBar()
{
global $lang, $app;
printf($lang->todayIs, date(DT_DATE3));
if(isset($app->user)) echo $app->user->realname . ' ';
if(isset($app->user) and $app->user->account != 'guest')
{
echo html::a(helper::createLink('my', 'index'), $lang->myControl);
echo html::a(helper::createLink('user', 'logout'), $lang->logout);
}
else
{
echo html::a(helper::createLink('user', 'login'), $lang->login);
}
echo html::a(helper::createLink('misc', 'about'), $lang->aboutZenTao, '', "class='about'");
echo $lang->agileTraining;
echo $lang->donate;
}
/**
* Print the main menu.
*
* @param string $moduleName
* @static
* @access public
* @return void
*/
public static function printMainmenu($moduleName)
{
global $app, $lang;
echo "<ul>\n";
/* Set the main main menu. */
$mainMenu = $moduleName;
if(isset($lang->menugroup->$moduleName)) $mainMenu = $lang->menugroup->$moduleName;
/* Print all main menus. */
foreach($lang->menu as $menuKey => $menu)
{
$active = $menuKey == $mainMenu ? "class='active'" : '';
list($menuLabel, $module, $method) = explode('|', $menu);
if(common::hasPriv($module, $method))
{
$link = helper::createLink($module, $method);
echo "<li $active><nobr><a href='$link' id='menu$menuKey'>$menuLabel</a></nobr></li>\n";
}
}
}
/**
* Print the search box.
*
* @static
* @access public
* @return void
*/
public static function printSearchBox()
{
global $app, $lang;
$moduleName = $app->getModuleName();
$methodName = $app->getMethodName();
$searchObject = $moduleName;
if($moduleName == 'product')
{
if($methodName == 'browse') $searchObject = 'story';
}
elseif($moduleName == 'project')
{
if(strpos('task|story|bug|build', $methodName) !== false) $searchObject = $methodName;
}
elseif($moduleName == 'my' or $moduleName == 'user')
{
$searchObject = $methodName;
}
echo "<li id='searchbox'>";
echo html::select('searchType', $lang->searchObjects, $searchObject);
echo html::input('searchQuery', $lang->searchTips, "onclick=this.value='' onkeydown='if(event.keyCode==13) shortcut()' class='w-60px'");
echo html::commonButton($lang->go, 'id="objectSwitcher" onclick="shortcut()"');
echo "</li>";
echo "</ul>\n";
}
/**
* Print the module menu.
*
* @param string $moduleName
* @static
* @access public
* @return void
*/
public static function printModuleMenu($moduleName)
{
global $lang, $app;
if(!isset($lang->$moduleName->menu)) {echo "<ul></ul>"; return;}
/* Get the sub menus of the module, and get current module and method. */
$submenus = $lang->$moduleName->menu;
$currentModule = $app->getModuleName();
$currentMethod = $app->getMethodName();
/* The beginning of the menu. */
echo "<ul>\n";
/* Cycling to print every sub menus. */
foreach($submenus as $subMenuKey => $submenu)
{
/* Init the these vars. */
$link = $submenu;
$subModule = '';
$alias = '';
$float = '';
$active = '';
$target = '';
if(is_array($submenu)) extract($submenu); // If the sub menu is an array, extract it.
/* Print the menu. */
if(strpos($link, '|') === false)
{
echo "<li>$link</li>\n";
}
else
{
$link = explode('|', $link);
list($label, $module, $method) = $link;
$vars = isset($link[3]) ? $link[3] : '';
if(common::hasPriv($module, $method))
{
/* Is the currentModule active? */
if($currentModule == $subModule) $active = 'active';
if($module == $currentModule and ($method == $currentMethod or strpos($alias, $currentMethod) !== false)) $active = 'active';
echo "<li class='$float $active'>" . html::a(helper::createLink($module, $method, $vars), $label, $target, "id=submenu$subMenuKey") . "</li>\n";
}
}
}
echo "</ul>\n";
}
/**
* Print the bread menu.
*
* @param string $moduleName
* @param string $position
* @static
* @access public
* @return void
*/
public static function printBreadMenu($moduleName, $position)
{
global $lang;
$mainMenu = $moduleName;
if(isset($lang->menugroup->$moduleName)) $mainMenu = $lang->menugroup->$moduleName;
echo html::a(helper::createLink('my', 'index'), $lang->ZenTaoPMS) . $lang->arrow;
if($moduleName != 'index')
{
list($menuLabel, $module, $method) = explode('|', $lang->menu->$mainMenu);
echo html::a(helper::createLink($module, $method), $menuLabel);
}
else
{
echo $lang->index->common;
}
if(empty($position)) return;
echo $lang->arrow;
foreach($position as $key => $link)
{
echo $link;
if(isset($position[$key + 1])) echo $lang->arrow;
}
}
/**
* Diff two string. (see phpt)
*
* @param string $text1
* @param string $text2
* @static
* @access public
* @return string
*/
public static function diff($text1, $text2)
{
$text1 = str_replace('&nbsp;', '', trim($text1));
$text2 = str_replace('&nbsp;', '', trim($text2));
$w = explode("\n", $text1);
$o = explode("\n", $text2);
$w1 = array_diff_assoc($w,$o);
$o1 = array_diff_assoc($o,$w);
$w2 = array();
$o2 = array();
foreach($w1 as $idx => $val) $w2[sprintf("%03d<",$idx)] = sprintf("%03d- ", $idx+1) . "<del>" . trim($val) . "</del>";
foreach($o1 as $idx => $val) $o2[sprintf("%03d>",$idx)] = sprintf("%03d+ ", $idx+1) . "<ins>" . trim($val) . "</ins>";
$diff = array_merge($w2, $o2);
ksort($diff);
return implode("\n", $diff);
}
}

View File

@@ -1,236 +1,236 @@
<?php
/**
* The control file of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
class company extends control
{
/**
* Construct function, load dept and user models auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->loadModel('dept');
$this->app->loadLang('user');
$this->company->setMenu();
}
/**
* Index page, header to browse.
*
* @access public
* @return void
*/
public function index()
{
$this->locate($this->createLink('company', 'browse'));
}
/**
* Browse departments and users of a company.
*
* @param int $deptID
* @access public
* @return void
*/
public function browse($deptID = 0)
{
$this->lang->set('menugroup.company', 'company');
$childDeptIds = $this->dept->getAllChildID($deptID);
$this->company->setMenu($deptID);
$header['title'] = $this->lang->company->index . $this->lang->colon . $this->lang->dept->common;
$position[] = $this->lang->dept->common;
$this->view->header = $header;
$this->view->position = $position;
$this->view->users = $this->dept->getUsers($childDeptIds);
$this->view->deptTree = $this->dept->getTreeMenu($rooteDeptID = 0, array('deptModel', 'createMemberLink'));
$this->view->parentDepts = $this->dept->getParents($deptID);
$this->view->deptID = $deptID;
$this->display();
}
/**
* Create a company.
*
* @access public
* @return void
*/
public function create()
{
if(!empty($_POST))
{
$this->company->create();
if(dao::isError()) die(js::error(dao::getError()));
die(js::locate($this->createLink('admin', 'browsecompany'), 'parent'));
}
$this->lang->set('menugroup.company', 'admin');
$this->lang->company->menu = $this->lang->admin->menu;
$header['title'] = $this->lang->admin->common . $this->lang->colon . $this->lang->company->create;
$position[] = html::a($this->createLink('admin', 'browsecompany'), $this->lang->admin->company);
$position[] = $this->lang->company->create;
$this->view->header = $header;
$this->view->position = $position;
$this->display();
}
/**
* Edit a company.
*
* @access public
* @return void
*/
public function edit()
{
if(!empty($_POST))
{
$this->company->update();
if(dao::isError()) die(js::error(dao::getError()));
die(js::alert($this->lang->company->successSaved));
}
$header['title'] = $this->lang->company->common . $this->lang->colon . $this->lang->company->edit;
$position[] = $this->lang->company->edit;
$this->view->header = $header;
$this->view->position = $position;
$this->view->company = $this->company->getById($this->app->company->id);
$this->display();
}
/**
* Delete a company.
*
* @param int $companyID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function delete($companyID, $confirm = 'no')
{
if($confirm == 'no')
{
echo js::confirm($this->lang->company->confirmDelete, $this->createLink('company', 'delete', "companyID=$companyID&confirm=yes"));
exit;
}
else
{
$this->company->delete($companyID);
echo js::locate($this->createLink('admin', 'browseCompany'), 'parent');
exit;
}
}
/**
* Company dynamic.
*
* @param string $browseType
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
public function dynamic($browseType = 'today', $param = '', $orderBy = 'date_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
$this->app->loadLang('user');
$this->app->loadLang('project');
$this->loadModel('action');
/* Save session. */
$uri = $this->app->getURI(true);
$this->session->set('productList', $uri);
$this->session->set('productPlanList', $uri);
$this->session->set('releaseList', $uri);
$this->session->set('storyList', $uri);
$this->session->set('projectList', $uri);
$this->session->set('taskList', $uri);
$this->session->set('buildList', $uri);
$this->session->set('bugList', $uri);
$this->session->set('caseList', $uri);
$this->session->set('testtaskList', $uri);
/* Set the pager. */
$this->app->loadClass('pager', $static = true);
$pager = pager::init($recTotal, $recPerPage, $pageID);
$this->view->orderBy = $orderBy;
$this->view->pager = $pager;
/* Set the user and type. */
$account = $browseType == 'account' ? $param : 'all';
$product = $browseType == 'product' ? $param : 'all';
$project = $browseType == 'project' ? $param : 'all';
$period = ($browseType == 'account' or $browseType == 'product' or $browseType == 'project') ? 'all' : $browseType;
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Get products' list.*/
$products = $this->loadModel('product')->getPairs();
$products = array($this->lang->product->select) + $products;
$this->view->products = $products;
/* Get projects' list.*/
$projects = $this->loadModel('project')->getPairs();
$projects = array($this->lang->project->select) + $projects;
$this->view->projects = $projects;
/* Get users.*/
$users = $this->loadModel('user')->getPairs('nodeleted|noletter|noclosed');
$users[''] = $this->lang->user->select;
$this->view->users = $users;
/* The header and position. */
$this->view->header->title = $this->lang->company->common . $this->lang->colon . $this->lang->company->dynamic;
$this->view->position[] = $this->lang->company->dynamic;
/* Get actions. */
if($browseType != 'bysearch')
{
$actions = $this->action->getDynamic($account, $period, $orderBy, $pager, $product, $project);
}
else
{
$actions = $this->action->getDynamicBySearch($products, $projects, $queryID, $orderBy, $pager);
}
/* Build search form. */
$projects[0] = '';
$products[0] = '';
$users[''] = '';
ksort($projects);
ksort($products);
$projects['all'] = $this->lang->project->allProject;
$products['all'] = $this->lang->product->allProduct;
$this->config->company->dynamic->search['actionURL'] = $this->createLink('company', 'dynamic', "browseType=bysearch&param=myQueryID");
$this->config->company->dynamic->search['queryID'] = $queryID;
$this->config->company->dynamic->search['params']['project']['values'] = $projects;
$this->config->company->dynamic->search['params']['product']['values'] = $products;
$this->config->company->dynamic->search['params']['actor']['values'] = $users;
$this->view->searchForm = $this->fetch('search', 'buildForm', $this->config->company->dynamic->search);
/* Assign. */
$this->view->browseType = $browseType;
$this->view->account = $account;
$this->view->product = $product;
$this->view->project = $project;
$this->view->queryID = $queryID;
$this->view->actions = $actions;
$this->display();
}
}
<?php
/**
* The control file of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
class company extends control
{
/**
* Construct function, load dept and user models auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->loadModel('dept');
$this->app->loadLang('user');
$this->company->setMenu();
}
/**
* Index page, header to browse.
*
* @access public
* @return void
*/
public function index()
{
$this->locate($this->createLink('company', 'browse'));
}
/**
* Browse departments and users of a company.
*
* @param int $deptID
* @access public
* @return void
*/
public function browse($deptID = 0)
{
$this->lang->set('menugroup.company', 'company');
$childDeptIds = $this->dept->getAllChildID($deptID);
$this->company->setMenu($deptID);
$header['title'] = $this->lang->company->index . $this->lang->colon . $this->lang->dept->common;
$position[] = $this->lang->dept->common;
$this->view->header = $header;
$this->view->position = $position;
$this->view->users = $this->dept->getUsers($childDeptIds);
$this->view->deptTree = $this->dept->getTreeMenu($rooteDeptID = 0, array('deptModel', 'createMemberLink'));
$this->view->parentDepts = $this->dept->getParents($deptID);
$this->view->deptID = $deptID;
$this->display();
}
/**
* Create a company.
*
* @access public
* @return void
*/
public function create()
{
if(!empty($_POST))
{
$this->company->create();
if(dao::isError()) die(js::error(dao::getError()));
die(js::locate($this->createLink('admin', 'browsecompany'), 'parent'));
}
$this->lang->set('menugroup.company', 'admin');
$this->lang->company->menu = $this->lang->admin->menu;
$header['title'] = $this->lang->admin->common . $this->lang->colon . $this->lang->company->create;
$position[] = html::a($this->createLink('admin', 'browsecompany'), $this->lang->admin->company);
$position[] = $this->lang->company->create;
$this->view->header = $header;
$this->view->position = $position;
$this->display();
}
/**
* Edit a company.
*
* @access public
* @return void
*/
public function edit()
{
if(!empty($_POST))
{
$this->company->update();
if(dao::isError()) die(js::error(dao::getError()));
die(js::alert($this->lang->company->successSaved));
}
$header['title'] = $this->lang->company->common . $this->lang->colon . $this->lang->company->edit;
$position[] = $this->lang->company->edit;
$this->view->header = $header;
$this->view->position = $position;
$this->view->company = $this->company->getById($this->app->company->id);
$this->display();
}
/**
* Delete a company.
*
* @param int $companyID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function delete($companyID, $confirm = 'no')
{
if($confirm == 'no')
{
echo js::confirm($this->lang->company->confirmDelete, $this->createLink('company', 'delete', "companyID=$companyID&confirm=yes"));
exit;
}
else
{
$this->company->delete($companyID);
echo js::locate($this->createLink('admin', 'browseCompany'), 'parent');
exit;
}
}
/**
* Company dynamic.
*
* @param string $browseType
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
public function dynamic($browseType = 'today', $param = '', $orderBy = 'date_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
$this->app->loadLang('user');
$this->app->loadLang('project');
$this->loadModel('action');
/* Save session. */
$uri = $this->app->getURI(true);
$this->session->set('productList', $uri);
$this->session->set('productPlanList', $uri);
$this->session->set('releaseList', $uri);
$this->session->set('storyList', $uri);
$this->session->set('projectList', $uri);
$this->session->set('taskList', $uri);
$this->session->set('buildList', $uri);
$this->session->set('bugList', $uri);
$this->session->set('caseList', $uri);
$this->session->set('testtaskList', $uri);
/* Set the pager. */
$this->app->loadClass('pager', $static = true);
$pager = pager::init($recTotal, $recPerPage, $pageID);
$this->view->orderBy = $orderBy;
$this->view->pager = $pager;
/* Set the user and type. */
$account = $browseType == 'account' ? $param : 'all';
$product = $browseType == 'product' ? $param : 'all';
$project = $browseType == 'project' ? $param : 'all';
$period = ($browseType == 'account' or $browseType == 'product' or $browseType == 'project') ? 'all' : $browseType;
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Get products' list.*/
$products = $this->loadModel('product')->getPairs();
$products = array($this->lang->product->select) + $products;
$this->view->products = $products;
/* Get projects' list.*/
$projects = $this->loadModel('project')->getPairs();
$projects = array($this->lang->project->select) + $projects;
$this->view->projects = $projects;
/* Get users.*/
$users = $this->loadModel('user')->getPairs('nodeleted|noletter|noclosed');
$users[''] = $this->lang->user->select;
$this->view->users = $users;
/* The header and position. */
$this->view->header->title = $this->lang->company->common . $this->lang->colon . $this->lang->company->dynamic;
$this->view->position[] = $this->lang->company->dynamic;
/* Get actions. */
if($browseType != 'bysearch')
{
$actions = $this->action->getDynamic($account, $period, $orderBy, $pager, $product, $project);
}
else
{
$actions = $this->action->getDynamicBySearch($products, $projects, $queryID, $orderBy, $pager);
}
/* Build search form. */
$projects[0] = '';
$products[0] = '';
$users[''] = '';
ksort($projects);
ksort($products);
$projects['all'] = $this->lang->project->allProject;
$products['all'] = $this->lang->product->allProduct;
$this->config->company->dynamic->search['actionURL'] = $this->createLink('company', 'dynamic', "browseType=bysearch&param=myQueryID");
$this->config->company->dynamic->search['queryID'] = $queryID;
$this->config->company->dynamic->search['params']['project']['values'] = $projects;
$this->config->company->dynamic->search['params']['product']['values'] = $products;
$this->config->company->dynamic->search['params']['actor']['values'] = $users;
$this->view->searchForm = $this->fetch('search', 'buildForm', $this->config->company->dynamic->search);
/* Assign. */
$this->view->browseType = $browseType;
$this->view->account = $account;
$this->view->product = $product;
$this->view->project = $project;
$this->view->queryID = $queryID;
$this->view->actions = $actions;
$this->display();
}
}

View File

@@ -1,39 +1,39 @@
<?php
/**
* The company module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
$lang->company->common = 'Company';
$lang->company->index = "Index";
$lang->company->create = "Create";
$lang->company->edit = "Edit";
$lang->company->read = "Info";
$lang->company->update = "Update";
$lang->company->delete = "Delete";
$lang->company->browse = "User";
$lang->company->dynamic = "Dynamic";
$lang->company->depts = "Dept";
$lang->company->orgView = 'Company';
$lang->company->confirmDelete = "Are you sure to delete this company?";
$lang->company->successSaved = "Success saved";
$lang->company->id = 'ID';
$lang->company->name = 'Name';
$lang->company->phone = 'Phone';
$lang->company->fax = 'Fax';
$lang->company->address = 'Address';
$lang->company->zipcode = 'Zipcode';
$lang->company->website = 'Web site';
$lang->company->backyard = 'Internal Site';
$lang->company->pms = 'ZenTaoPMS Site';
$lang->company->guest = 'Guest visit';
$lang->company->guestList[0] = 'Deny';
$lang->company->guestList[1] = 'Allow';
<?php
/**
* The company module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
$lang->company->common = 'Company';
$lang->company->index = "Index";
$lang->company->create = "Create";
$lang->company->edit = "Edit";
$lang->company->read = "Info";
$lang->company->update = "Update";
$lang->company->delete = "Delete";
$lang->company->browse = "User";
$lang->company->dynamic = "Dynamic";
$lang->company->depts = "Dept";
$lang->company->orgView = 'Company';
$lang->company->confirmDelete = "Are you sure to delete this company?";
$lang->company->successSaved = "Success saved";
$lang->company->id = 'ID';
$lang->company->name = 'Name';
$lang->company->phone = 'Phone';
$lang->company->fax = 'Fax';
$lang->company->address = 'Address';
$lang->company->zipcode = 'Zipcode';
$lang->company->website = 'Web site';
$lang->company->backyard = 'Internal Site';
$lang->company->pms = 'ZenTaoPMS Site';
$lang->company->guest = 'Guest visit';
$lang->company->guestList[0] = 'Deny';
$lang->company->guestList[1] = 'Allow';

View File

@@ -1,39 +1,39 @@
<?php
/**
* The company module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
$lang->company->common = '组织视图';
$lang->company->index = "组织视图首页";
$lang->company->create = "新增公司";
$lang->company->edit = "编辑公司";
$lang->company->read = "公司信息";
$lang->company->update = "更新公司";
$lang->company->delete = "删除公司";
$lang->company->browse = "用户列表";
$lang->company->dynamic = "组织动态";
$lang->company->depts = "部门列表";
$lang->company->orgView = '组织视图';
$lang->company->confirmDelete = "您确定删除该公司吗?";
$lang->company->successSaved = "成功保存";
$lang->company->id = '编号';
$lang->company->name = '公司名称';
$lang->company->phone = '联系电话';
$lang->company->fax = '传真';
$lang->company->address = '通讯地址';
$lang->company->zipcode = '邮政编码';
$lang->company->website = '公司网站';
$lang->company->backyard = '公司内网';
$lang->company->pms = 'PMS网站';
$lang->company->guest = '匿名登录';
$lang->company->guestList[0] = '不允许';
$lang->company->guestList[1] = '允许';
<?php
/**
* The company module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
$lang->company->common = '组织视图';
$lang->company->index = "组织视图首页";
$lang->company->create = "新增公司";
$lang->company->edit = "编辑公司";
$lang->company->read = "公司信息";
$lang->company->update = "更新公司";
$lang->company->delete = "删除公司";
$lang->company->browse = "用户列表";
$lang->company->dynamic = "组织动态";
$lang->company->depts = "部门列表";
$lang->company->orgView = '组织视图';
$lang->company->confirmDelete = "您确定删除该公司吗?";
$lang->company->successSaved = "成功保存";
$lang->company->id = '编号';
$lang->company->name = '公司名称';
$lang->company->phone = '联系电话';
$lang->company->fax = '传真';
$lang->company->address = '通讯地址';
$lang->company->zipcode = '邮政编码';
$lang->company->website = '公司网站';
$lang->company->backyard = '公司内网';
$lang->company->pms = 'PMS网站';
$lang->company->guest = '匿名登录';
$lang->company->guestList[0] = '不允许';
$lang->company->guestList[1] = '允许';

View File

@@ -1,39 +1,39 @@
<?php
/**
* The company module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->company->common = '組織視圖';
$lang->company->index = "組織視圖首頁";
$lang->company->create = "新增公司";
$lang->company->edit = "編輯公司";
$lang->company->read = "公司信息";
$lang->company->update = "更新公司";
$lang->company->delete = "刪除公司";
$lang->company->browse = "用戶列表";
$lang->company->dynamic = "組織動態";
$lang->company->depts = "部門列表";
$lang->company->orgView = '組織視圖';
$lang->company->confirmDelete = "您確定刪除該公司嗎?";
$lang->company->successSaved = "成功保存";
$lang->company->id = '編號';
$lang->company->name = '公司名稱';
$lang->company->phone = '聯繫電話';
$lang->company->fax = '傳真';
$lang->company->address = '通訊地址';
$lang->company->zipcode = '郵政編碼';
$lang->company->website = '公司網站';
$lang->company->backyard = '公司內網';
$lang->company->pms = 'PMS網站';
$lang->company->guest = '匿名登錄';
$lang->company->guestList[0] = '不允許';
$lang->company->guestList[1] = '允許';
<?php
/**
* The company module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->company->common = '組織視圖';
$lang->company->index = "組織視圖首頁";
$lang->company->create = "新增公司";
$lang->company->edit = "編輯公司";
$lang->company->read = "公司信息";
$lang->company->update = "更新公司";
$lang->company->delete = "刪除公司";
$lang->company->browse = "用戶列表";
$lang->company->dynamic = "組織動態";
$lang->company->depts = "部門列表";
$lang->company->orgView = '組織視圖';
$lang->company->confirmDelete = "您確定刪除該公司嗎?";
$lang->company->successSaved = "成功保存";
$lang->company->id = '編號';
$lang->company->name = '公司名稱';
$lang->company->phone = '聯繫電話';
$lang->company->fax = '傳真';
$lang->company->address = '通訊地址';
$lang->company->zipcode = '郵政編碼';
$lang->company->website = '公司網站';
$lang->company->backyard = '公司內網';
$lang->company->pms = 'PMS網站';
$lang->company->guest = '匿名登錄';
$lang->company->guestList[0] = '不允許';
$lang->company->guestList[1] = '允許';

View File

@@ -1,123 +1,123 @@
<?php
/**
* The model file of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class companyModel extends model
{
/**
* Set menu.
*
* @param int $dept
* @access public
* @return void
*/
public function setMenu($dept = 0)
{
common::setMenuVars($this->lang->company->menu, 'name', array($this->app->company->name));
common::setMenuVars($this->lang->company->menu, 'addUser', array($dept));
}
/**
* Get company list.
*
* @access public
* @return void
*/
public function getList()
{
return $this->dao->select('*')->from(TABLE_COMPANY)->fetchAll();
}
/**
* Get the first company.
*
* @access public
* @return void
*/
public function getFirst()
{
return $this->dao->select('*')->from(TABLE_COMPANY)->orderBy('id')->limit(1)->fetch();
}
/**
* get company by domain.
*
* @param string $domain if empty, use current HTTP_HOST.
* @access public
* @return object
*/
public function getByDomain($domain = '')
{
if(empty($domain)) $domain = $this->server->http_host;
return $this->dao->findByPMS($domain)->from(TABLE_COMPANY)->fetch();
}
/**
* Get company info by id.
*
* @param int $companyID
* @access public
* @return object
*/
public function getByID($companyID = '')
{
return $this->dao->findById((int)$companyID)->from(TABLE_COMPANY)->fetch();
}
/**
* Create a company.
*
* @access public
* @return void
*/
public function create()
{
$company = fixer::input('post')->get();
$this->dao->insert(TABLE_COMPANY)
->data($company)
->autoCheck()
->batchCheck($this->config->company->create->requiredFields, 'notempty')
->batchCheck('name,pms', 'unique')
->exec();
}
/**
* Update a company.
*
* @access public
* @return void
*/
public function update()
{
$company = fixer::input('post')->stripTags('name')->get();
$companyID = $this->app->company->id;
$this->dao->update(TABLE_COMPANY)
->data($company)
->autoCheck()
->batchCheck($this->config->company->edit->requiredFields, 'notempty')
->batchCheck('name,pms', 'unique', "id != '$companyID'")
->where('id')->eq($companyID)
->exec();
}
/**
* Delete a company.
*
* @param int $companyID
* @access public
* @return void
*/
public function delete($companyID)
{
return $this->dao->delete()->from(TABLE_COMPANY)->where('id')->eq((int)$companyID)->limit(1)->exec();
}
}
<?php
/**
* The model file of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class companyModel extends model
{
/**
* Set menu.
*
* @param int $dept
* @access public
* @return void
*/
public function setMenu($dept = 0)
{
common::setMenuVars($this->lang->company->menu, 'name', array($this->app->company->name));
common::setMenuVars($this->lang->company->menu, 'addUser', array($dept));
}
/**
* Get company list.
*
* @access public
* @return void
*/
public function getList()
{
return $this->dao->select('*')->from(TABLE_COMPANY)->fetchAll();
}
/**
* Get the first company.
*
* @access public
* @return void
*/
public function getFirst()
{
return $this->dao->select('*')->from(TABLE_COMPANY)->orderBy('id')->limit(1)->fetch();
}
/**
* get company by domain.
*
* @param string $domain if empty, use current HTTP_HOST.
* @access public
* @return object
*/
public function getByDomain($domain = '')
{
if(empty($domain)) $domain = $this->server->http_host;
return $this->dao->findByPMS($domain)->from(TABLE_COMPANY)->fetch();
}
/**
* Get company info by id.
*
* @param int $companyID
* @access public
* @return object
*/
public function getByID($companyID = '')
{
return $this->dao->findById((int)$companyID)->from(TABLE_COMPANY)->fetch();
}
/**
* Create a company.
*
* @access public
* @return void
*/
public function create()
{
$company = fixer::input('post')->get();
$this->dao->insert(TABLE_COMPANY)
->data($company)
->autoCheck()
->batchCheck($this->config->company->create->requiredFields, 'notempty')
->batchCheck('name,pms', 'unique')
->exec();
}
/**
* Update a company.
*
* @access public
* @return void
*/
public function update()
{
$company = fixer::input('post')->stripTags('name')->get();
$companyID = $this->app->company->id;
$this->dao->update(TABLE_COMPANY)
->data($company)
->autoCheck()
->batchCheck($this->config->company->edit->requiredFields, 'notempty')
->batchCheck('name,pms', 'unique', "id != '$companyID'")
->where('id')->eq($companyID)
->exec();
}
/**
* Delete a company.
*
* @param int $companyID
* @access public
* @return void
*/
public function delete($companyID)
{
return $this->dao->delete()->from(TABLE_COMPANY)->where('id')->eq((int)$companyID)->limit(1)->exec();
}
}

View File

@@ -1,78 +1,78 @@
<?php
/**
* The browse view file of product dept of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package product
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
include '../../common/view/header.html.php';
include '../../common/view/treeview.html.php';
include '../../common/view/tablesorter.html.php';
?>
<table class='cont-lt1'>
<tr valign='top'>
<td class='side'>
<div class='box-title'><?php echo $lang->dept->common;?></div>
<div class='box-content'>
<?php echo $deptTree;?>
<div class='a-right'>
<?php
common::printLink('user', 'create', "dept=$deptID&from=company", $lang->user->create);echo '<br />';
common::printLink('company', 'browse', '', $lang->user->allUsers); echo '<br />';
common::printLink('dept', 'browse', '', $lang->dept->manage);
?>
</div>
</div>
</td>
<td class='divider'></td>
<td>
<table class='table-1 tablesorter'>
<thead>
<tr class='colhead'>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->user->realname;?></th>
<th><?php echo $lang->user->account;?></th>
<?php // echo $lang->user->nickname;?>
<th><?php echo $lang->user->email;?></th>
<th><?php echo $lang->user->gender;?></th>
<th><?php echo $lang->user->phone;?></th>
<th><?php echo $lang->user->join;?></th>
<th><?php echo $lang->user->last;?></th>
<th><?php echo $lang->user->visits;?></th>
<th><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($users as $user):?>
<tr class='a-center'>
<td><?php echo $user->id;?></td>
<td><?php if(!common::printLink('user', 'view', "account=$user->account", $user->realname)) echo $user->realname;?></td>
<td><?php echo $user->account;?></td>
<?php // echo $user->nickname;?>
<td><?php echo html::mailto($user->email);?></td>
<td><?php if(isset($lang->user->genderList->{$user->gender})) echo $lang->user->genderList->{$user->gender};?></td>
<td><?php echo $user->phone;?></td>
<td><?php echo $user->join;?></td>
<td><?php echo date('Y-m-d', $user->last);?></td>
<td><?php echo $user->visits;?></td>
<td>
<?php
common::printLink('user', 'edit', "userID=$user->id&from=company", $lang->edit);
common::printLink('user', 'delete', "userID=$user->id", $lang->delete, "hiddenwin");
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
</td>
</tr>
</table>
<script lanugage='Javascript'>$('#dept<?php echo $deptID;?>').addClass('active');</script>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The browse view file of product dept of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package product
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
include '../../common/view/header.html.php';
include '../../common/view/treeview.html.php';
include '../../common/view/tablesorter.html.php';
?>
<table class='cont-lt1'>
<tr valign='top'>
<td class='side'>
<div class='box-title'><?php echo $lang->dept->common;?></div>
<div class='box-content'>
<?php echo $deptTree;?>
<div class='a-right'>
<?php
common::printLink('user', 'create', "dept=$deptID&from=company", $lang->user->create);echo '<br />';
common::printLink('company', 'browse', '', $lang->user->allUsers); echo '<br />';
common::printLink('dept', 'browse', '', $lang->dept->manage);
?>
</div>
</div>
</td>
<td class='divider'></td>
<td>
<table class='table-1 tablesorter'>
<thead>
<tr class='colhead'>
<th class='w-id'><?php echo $lang->idAB;?></th>
<th><?php echo $lang->user->realname;?></th>
<th><?php echo $lang->user->account;?></th>
<?php // echo $lang->user->nickname;?>
<th><?php echo $lang->user->email;?></th>
<th><?php echo $lang->user->gender;?></th>
<th><?php echo $lang->user->phone;?></th>
<th><?php echo $lang->user->join;?></th>
<th><?php echo $lang->user->last;?></th>
<th><?php echo $lang->user->visits;?></th>
<th><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($users as $user):?>
<tr class='a-center'>
<td><?php echo $user->id;?></td>
<td><?php if(!common::printLink('user', 'view', "account=$user->account", $user->realname)) echo $user->realname;?></td>
<td><?php echo $user->account;?></td>
<?php // echo $user->nickname;?>
<td><?php echo html::mailto($user->email);?></td>
<td><?php if(isset($lang->user->genderList->{$user->gender})) echo $lang->user->genderList->{$user->gender};?></td>
<td><?php echo $user->phone;?></td>
<td><?php echo $user->join;?></td>
<td><?php echo date('Y-m-d', $user->last);?></td>
<td><?php echo $user->visits;?></td>
<td>
<?php
common::printLink('user', 'edit', "userID=$user->id&from=company", $lang->edit);
common::printLink('user', 'delete', "userID=$user->id", $lang->delete, "hiddenwin");
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
</table>
</td>
</tr>
</table>
<script lanugage='Javascript'>$('#dept<?php echo $deptID;?>').addClass('active');</script>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,56 +1,56 @@
<?php
/**
* The create view of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table align='center' class='table-5'>
<caption><?php echo $lang->company->create;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->company->name;?></th>
<td><?php echo html::input('name', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->phone;?></th>
<td><?php echo html::input('phone', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->fax;?></th>
<td><?php echo html::input('fax', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->address;?></th>
<td><?php echo html::input('address', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->zipcode;?></th>
<td><?php echo html::input('zipcode', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->website;?></th>
<td><?php echo html::input('website', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->backyard;?></th>
<td><?php echo html::input('backyard', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->pms;?></th>
<td><?php echo html::input('pms', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->guest;?></th>
<td><?php echo html::radio('guest', $lang->company->guestList);?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The create view of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table align='center' class='table-5'>
<caption><?php echo $lang->company->create;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->company->name;?></th>
<td><?php echo html::input('name', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->phone;?></th>
<td><?php echo html::input('phone', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->fax;?></th>
<td><?php echo html::input('fax', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->address;?></th>
<td><?php echo html::input('address', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->zipcode;?></th>
<td><?php echo html::input('zipcode', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->website;?></th>
<td><?php echo html::input('website', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->backyard;?></th>
<td><?php echo html::input('backyard', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->pms;?></th>
<td><?php echo html::input('pms', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->guest;?></th>
<td><?php echo html::radio('guest', $lang->company->guestList);?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,62 +1,62 @@
<?php
/**
* The action->dynamic view file of dashboard module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dashboard
* @version $Id: action->dynamic.html.php 1477 2011-03-01 15:25:50Z wwccss $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<script language='Javascript'>
var browseType = '<?php echo $browseType;?>';
</script>
<div id='featurebar'>
<?php
echo '<span id="today">' . html::a(inlink('dynamic', "browseType=today"), $lang->action->dynamic->today) . '</span>';
echo '<span id="yesterday">' . html::a(inlink('dynamic', "browseType=yesterday"), $lang->action->dynamic->yesterday) . '</span>';
echo '<span id="twodaysago">' . html::a(inlink('dynamic', "browseType=twodaysago"), $lang->action->dynamic->twoDaysAgo) . '</span>';
echo '<span id="thisweek">' . html::a(inlink('dynamic', "browseType=thisweek"), $lang->action->dynamic->thisWeek) . '</span>';
echo '<span id="lastweek">' . html::a(inlink('dynamic', "browseType=lastweek"), $lang->action->dynamic->lastWeek) . '</span>';
echo '<span id="thismonth">' . html::a(inlink('dynamic', "browseType=thismonth"), $lang->action->dynamic->thisMonth) . '</span>';
echo '<span id="lastmonth">' . html::a(inlink('dynamic', "browseType=lastmonth"), $lang->action->dynamic->lastMonth) . '</span>';
echo '<span id="all">' . html::a(inlink('dynamic', "browseType=all"), $lang->action->dynamic->all) . '</span>';
echo "<span id='account'>" . html::select('account', $users, $account, 'onchange=changeUser(this.value)') . '</span>';
echo "<span id='product'>" . html::select('product', $products, $product, 'onchange=changeProduct(this.value)') . '</span>';
echo "<span id='project'>" . html::select('project', $projects, $project, 'onchange=changeProject(this.value)') . '</span>';
echo "<span id='bysearchTab'>" . html::a('#', $lang->action->dynamic->search) . "</span>";
?>
</div>
<div id='querybox' class='<?php if($browseType !='bysearch') echo 'hidden';?>'><?php echo $searchForm;?></div>
<table class='table-1 colored tablesorter'>
<thead>
<tr class='colhead'>
<th class='w-150px'><?php echo $lang->action->date;?></th>
<th class='w-user'> <?php echo $lang->action->actor;?></th>
<th class='w-100px'><?php echo $lang->action->action;?></th>
<th class='w-80px'> <?php echo $lang->action->objectType;?></th>
<th class='w-id'> <?php echo $lang->idAB;?></th>
<th><?php echo $lang->action->objectName;?></th>
</tr>
</thead>
<tbody>
<?php foreach($actions as $action):?>
<?php $module = $action->objectType == 'case' ? 'testcase' : $action->objectType;?>
<tr class='a-center'>
<td><?php echo $action->date;?></td>
<td><?php isset($users[$action->actor]) ? print($users[$action->actor]) : print($action->actor);?></td>
<td><?php echo $action->actionLabel;?></td>
<td><?php echo $lang->action->objectTypes[$action->objectType];?></td>
<td><?php echo $action->objectID;?></td>
<td class='a-left'><?php echo html::a($action->objectLink, $action->objectName);?></td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot><tr><td colspan='6'><?php $pager->show();?></td></tr></tfoot>
</table>
<script>$('#<?php echo $browseType;?>').addClass('active')</script>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The action->dynamic view file of dashboard module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dashboard
* @version $Id: action->dynamic.html.php 1477 2011-03-01 15:25:50Z wwccss $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<script language='Javascript'>
var browseType = '<?php echo $browseType;?>';
</script>
<div id='featurebar'>
<?php
echo '<span id="today">' . html::a(inlink('dynamic', "browseType=today"), $lang->action->dynamic->today) . '</span>';
echo '<span id="yesterday">' . html::a(inlink('dynamic', "browseType=yesterday"), $lang->action->dynamic->yesterday) . '</span>';
echo '<span id="twodaysago">' . html::a(inlink('dynamic', "browseType=twodaysago"), $lang->action->dynamic->twoDaysAgo) . '</span>';
echo '<span id="thisweek">' . html::a(inlink('dynamic', "browseType=thisweek"), $lang->action->dynamic->thisWeek) . '</span>';
echo '<span id="lastweek">' . html::a(inlink('dynamic', "browseType=lastweek"), $lang->action->dynamic->lastWeek) . '</span>';
echo '<span id="thismonth">' . html::a(inlink('dynamic', "browseType=thismonth"), $lang->action->dynamic->thisMonth) . '</span>';
echo '<span id="lastmonth">' . html::a(inlink('dynamic', "browseType=lastmonth"), $lang->action->dynamic->lastMonth) . '</span>';
echo '<span id="all">' . html::a(inlink('dynamic', "browseType=all"), $lang->action->dynamic->all) . '</span>';
echo "<span id='account'>" . html::select('account', $users, $account, 'onchange=changeUser(this.value)') . '</span>';
echo "<span id='product'>" . html::select('product', $products, $product, 'onchange=changeProduct(this.value)') . '</span>';
echo "<span id='project'>" . html::select('project', $projects, $project, 'onchange=changeProject(this.value)') . '</span>';
echo "<span id='bysearchTab'>" . html::a('#', $lang->action->dynamic->search) . "</span>";
?>
</div>
<div id='querybox' class='<?php if($browseType !='bysearch') echo 'hidden';?>'><?php echo $searchForm;?></div>
<table class='table-1 colored tablesorter'>
<thead>
<tr class='colhead'>
<th class='w-150px'><?php echo $lang->action->date;?></th>
<th class='w-user'> <?php echo $lang->action->actor;?></th>
<th class='w-100px'><?php echo $lang->action->action;?></th>
<th class='w-80px'> <?php echo $lang->action->objectType;?></th>
<th class='w-id'> <?php echo $lang->idAB;?></th>
<th><?php echo $lang->action->objectName;?></th>
</tr>
</thead>
<tbody>
<?php foreach($actions as $action):?>
<?php $module = $action->objectType == 'case' ? 'testcase' : $action->objectType;?>
<tr class='a-center'>
<td><?php echo $action->date;?></td>
<td><?php isset($users[$action->actor]) ? print($users[$action->actor]) : print($action->actor);?></td>
<td><?php echo $action->actionLabel;?></td>
<td><?php echo $lang->action->objectTypes[$action->objectType];?></td>
<td><?php echo $action->objectID;?></td>
<td class='a-left'><?php echo html::a($action->objectLink, $action->objectName);?></td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot><tr><td colspan='6'><?php $pager->show();?></td></tr></tfoot>
</table>
<script>$('#<?php echo $browseType;?>').addClass('active')</script>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,56 +1,56 @@
<?php
/**
* The edit view of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table align='center' class='table-5'>
<caption><?php echo $lang->company->edit;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->company->name;?></th>
<td><?php echo html::input('name', $company->name, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->phone;?></th>
<td><?php echo html::input('phone', $company->phone, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->fax;?></th>
<td><?php echo html::input('fax', $company->fax, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->address;?></th>
<td><?php echo html::input('address', $company->address, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->zipcode;?></th>
<td><?php echo html::input('zipcode', $company->zipcode, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->website;?></th>
<td><?php echo html::input('website', $company->website, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->backyard;?></th>
<td><?php echo html::input('backyard', $company->backyard, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->pms;?></th>
<td><?php echo html::input('pms', $company->pms, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->guest;?></th>
<td><?php echo html::radio('guest', $lang->company->guestList, $company->guest);?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The edit view of company module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package company
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' target='hiddenwin'>
<table align='center' class='table-5'>
<caption><?php echo $lang->company->edit;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->company->name;?></th>
<td><?php echo html::input('name', $company->name, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->phone;?></th>
<td><?php echo html::input('phone', $company->phone, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->fax;?></th>
<td><?php echo html::input('fax', $company->fax, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->address;?></th>
<td><?php echo html::input('address', $company->address, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->zipcode;?></th>
<td><?php echo html::input('zipcode', $company->zipcode, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->website;?></th>
<td><?php echo html::input('website', $company->website, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->backyard;?></th>
<td><?php echo html::input('backyard', $company->backyard, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->pms;?></th>
<td><?php echo html::input('pms', $company->pms, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->company->guest;?></th>
<td><?php echo html::radio('guest', $lang->company->guestList, $company->guest);?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,240 +1,240 @@
<?php
/**
* The control file of convert currentModule of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
class convert extends control
{
/**
* Index page of convert.
*
* @access public
* @return void
*/
public function index()
{
$this->convert->saveState();
$this->view->header->title = $this->lang->convert->common;
$this->display();
}
/**
* Select the source system.
*
* @access public
* @return void
*/
public function selectSource()
{
$this->view->header->title = $this->lang->convert->common . $this->lang->colon;
$this->display();
}
/**
* Set configs of converter.
*
* This is the extrance of every system. It will call the set function of corresponding module.
*
* @access public
* @return void
*/
public function setConfig()
{
if(!$this->post->source)
{
echo js::alert($this->lang->convert->mustSelectSource);
die(js::locate('back'));
}
list($sourceName, $version) = explode('_', $this->post->source);
$setFunc = "set$sourceName";
$this->view->header->title = $this->lang->convert->setting;
$this->view->source = $sourceName;
$this->view->version = $version;
$this->view->setting = $this->fetch('convert', $setFunc, "version=$version");
$this->display();
}
/**
* The setting page of bugfree.
*
* @param string $version
* @access public
* @return void
*/
public function setBugFree($version)
{
$this->view->source = 'BugFree';
$this->view->version = $version;
$this->view->tablePrefix = $version > 1 ? 'bf_' : '';
$this->view->dbName = $version > 1 ? 'bugfree2' : 'BugFree';
$this->view->dbCharset = 'utf8';
$this->display();
}
/**
* The setting page of Redmine.
*
* @param string $version
* @access public
* @return void
*/
public function setRedmine($version)
{
$this->view->source = 'Redmine';
$this->view->version = $version;
$this->view->dbName = 'redmine';
$this->view->dbCharset = 'utf8';
$this->display();
}
/**
* Check config. Same as setConfig.
*
* @access public
* @return void
*/
public function checkConfig()
{
$checkFunc = 'check' . $this->post->source;
$this->view->header->title = $this->lang->convert->checkConfig;
$this->view->source = $this->post->source;
$this->view->checkResult = $this->fetch('convert', $checkFunc, "version={$this->post->version}");
$this->display();
}
/**
* Check settings of bugfree.
*
* @param int $version
* @access public
* @return void
*/
public function checkBugFree($version)
{
helper::import('./converter/bugfree.php');
$converter = new bugfreeConvertModel();
/* Check it. */
$checkInfo['db'] = $converter->connectDB();
//if(is_object($checkInfo['db'])) $checkInfo['table'] = $converter->checkTables();
$checkInfo['path'] = $converter->checkPath();
/* Compute the checking result. */
$result = 'pass';
if(!is_object($checkInfo['db']) or !$checkInfo['path']) $result = 'fail';
/* Assign. */
$this->view->version = $version;
$this->view->source = 'bugfree';
$this->view->result = $result;
$this->view->checkInfo = $checkInfo;
$this->display();
}
/**
* Check settings of Redmine.
*
* @param int $version
* @access public
* @return void
*/
public function checkRedmine($version)
{
helper::import('./converter/redmine.php');
$converter = new redmineConvertModel();
/* Check it. */
$checkInfo['db'] = $converter->connectDB();
$checkInfo['path'] = $converter->checkPath();
$this->view->trackers = $this->dao->dbh($converter->sourceDBH)->select('id, name')->from('trackers')->fetchAll('id', $autoCompany = false);
$this->view->statuses = $this->dao->dbh($converter->sourceDBH)->select('id, name')->from('issue_statuses')->fetchAll('id', $autoCompany = false);
$this->view->pries = $this->dao->dbh($converter->sourceDBH)->select('id, name')->from('enumerations')->where('type')->eq('IssuePriority')->fetchAll('id', $autoCompany = false);
/* Compute the checking result. */
$result = 'pass';
if(!is_object($checkInfo['db']) or !$checkInfo['path']) $result = 'fail';
$this->app->loadLang('bug');
$this->app->loadLang('story');
$this->app->loadLang('task');
$this->view->aimTypeList['bug'] = 'bug';
$this->view->aimTypeList['task'] = 'task';
$this->view->aimTypeList['story'] = 'story';
/* Assign. */
$this->view->version = $version;
$this->view->source = 'Redmine';
$this->view->result = $result;
$this->view->checkInfo = $checkInfo;
$this->display();
}
/**
* Execute the converting.
*
* @access public
* @return void
*/
public function execute()
{
$convertFunc = 'convert' . $this->post->source;
$this->view->header->title = $this->lang->convert->execute;
$this->view->source = $this->post->source;
$this->view->version = $this->post->version;
$this->view->executeResult = $this->fetch('convert', $convertFunc, "version={$this->post->version}");
$this->display();
}
/**
* Convert bugfree.
*
* @param int $version
* @access public
* @return void
*/
public function convertBugFree($version)
{
helper::import('./converter/bugfree.php');
helper::import("./converter/bugfree$version.php");
$className = "bugfree{$version}ConvertModel";
$converter = new $className();
$this->view->version = $version;
$this->view->result = $converter->execute($version);
$this->view->info = bugfreeConvertModel::$info;
$this->display();
}
/**
* convert redmine
*
* @param int $version
* @access public
* @return void
*/
public function convertRedmine($version)
{
helper::import('./converter/redmine.php');
helper::import("./converter/redmine$version.php");
$className = "redmine11ConvertModel";
$redmine->aimTypes = $this->post->aimTypes;
$redmine->statusTypes['bug'] = $this->post->statusTypesOfBug;
$redmine->statusTypes['story'] = $this->post->statusTypesOfStory;
$redmine->statusTypes['task'] = $this->post->statusTypesOfTask;
$redmine->priTypes['bug'] = $this->post->priTypesOfBug;
$redmine->priTypes['story'] = $this->post->priTypesOfStory;
$redmine->priTypes['task'] = $this->post->priTypesOfTask;
$converter = new $className($redmine);
$this->view->version = $version;
$this->view->result = $converter->execute($version);
$this->view->info = redmineConvertModel::$info;
$this->display();
}
}
<?php
/**
* The control file of convert currentModule of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
class convert extends control
{
/**
* Index page of convert.
*
* @access public
* @return void
*/
public function index()
{
$this->convert->saveState();
$this->view->header->title = $this->lang->convert->common;
$this->display();
}
/**
* Select the source system.
*
* @access public
* @return void
*/
public function selectSource()
{
$this->view->header->title = $this->lang->convert->common . $this->lang->colon;
$this->display();
}
/**
* Set configs of converter.
*
* This is the extrance of every system. It will call the set function of corresponding module.
*
* @access public
* @return void
*/
public function setConfig()
{
if(!$this->post->source)
{
echo js::alert($this->lang->convert->mustSelectSource);
die(js::locate('back'));
}
list($sourceName, $version) = explode('_', $this->post->source);
$setFunc = "set$sourceName";
$this->view->header->title = $this->lang->convert->setting;
$this->view->source = $sourceName;
$this->view->version = $version;
$this->view->setting = $this->fetch('convert', $setFunc, "version=$version");
$this->display();
}
/**
* The setting page of bugfree.
*
* @param string $version
* @access public
* @return void
*/
public function setBugFree($version)
{
$this->view->source = 'BugFree';
$this->view->version = $version;
$this->view->tablePrefix = $version > 1 ? 'bf_' : '';
$this->view->dbName = $version > 1 ? 'bugfree2' : 'BugFree';
$this->view->dbCharset = 'utf8';
$this->display();
}
/**
* The setting page of Redmine.
*
* @param string $version
* @access public
* @return void
*/
public function setRedmine($version)
{
$this->view->source = 'Redmine';
$this->view->version = $version;
$this->view->dbName = 'redmine';
$this->view->dbCharset = 'utf8';
$this->display();
}
/**
* Check config. Same as setConfig.
*
* @access public
* @return void
*/
public function checkConfig()
{
$checkFunc = 'check' . $this->post->source;
$this->view->header->title = $this->lang->convert->checkConfig;
$this->view->source = $this->post->source;
$this->view->checkResult = $this->fetch('convert', $checkFunc, "version={$this->post->version}");
$this->display();
}
/**
* Check settings of bugfree.
*
* @param int $version
* @access public
* @return void
*/
public function checkBugFree($version)
{
helper::import('./converter/bugfree.php');
$converter = new bugfreeConvertModel();
/* Check it. */
$checkInfo['db'] = $converter->connectDB();
//if(is_object($checkInfo['db'])) $checkInfo['table'] = $converter->checkTables();
$checkInfo['path'] = $converter->checkPath();
/* Compute the checking result. */
$result = 'pass';
if(!is_object($checkInfo['db']) or !$checkInfo['path']) $result = 'fail';
/* Assign. */
$this->view->version = $version;
$this->view->source = 'bugfree';
$this->view->result = $result;
$this->view->checkInfo = $checkInfo;
$this->display();
}
/**
* Check settings of Redmine.
*
* @param int $version
* @access public
* @return void
*/
public function checkRedmine($version)
{
helper::import('./converter/redmine.php');
$converter = new redmineConvertModel();
/* Check it. */
$checkInfo['db'] = $converter->connectDB();
$checkInfo['path'] = $converter->checkPath();
$this->view->trackers = $this->dao->dbh($converter->sourceDBH)->select('id, name')->from('trackers')->fetchAll('id', $autoCompany = false);
$this->view->statuses = $this->dao->dbh($converter->sourceDBH)->select('id, name')->from('issue_statuses')->fetchAll('id', $autoCompany = false);
$this->view->pries = $this->dao->dbh($converter->sourceDBH)->select('id, name')->from('enumerations')->where('type')->eq('IssuePriority')->fetchAll('id', $autoCompany = false);
/* Compute the checking result. */
$result = 'pass';
if(!is_object($checkInfo['db']) or !$checkInfo['path']) $result = 'fail';
$this->app->loadLang('bug');
$this->app->loadLang('story');
$this->app->loadLang('task');
$this->view->aimTypeList['bug'] = 'bug';
$this->view->aimTypeList['task'] = 'task';
$this->view->aimTypeList['story'] = 'story';
/* Assign. */
$this->view->version = $version;
$this->view->source = 'Redmine';
$this->view->result = $result;
$this->view->checkInfo = $checkInfo;
$this->display();
}
/**
* Execute the converting.
*
* @access public
* @return void
*/
public function execute()
{
$convertFunc = 'convert' . $this->post->source;
$this->view->header->title = $this->lang->convert->execute;
$this->view->source = $this->post->source;
$this->view->version = $this->post->version;
$this->view->executeResult = $this->fetch('convert', $convertFunc, "version={$this->post->version}");
$this->display();
}
/**
* Convert bugfree.
*
* @param int $version
* @access public
* @return void
*/
public function convertBugFree($version)
{
helper::import('./converter/bugfree.php');
helper::import("./converter/bugfree$version.php");
$className = "bugfree{$version}ConvertModel";
$converter = new $className();
$this->view->version = $version;
$this->view->result = $converter->execute($version);
$this->view->info = bugfreeConvertModel::$info;
$this->display();
}
/**
* convert redmine
*
* @param int $version
* @access public
* @return void
*/
public function convertRedmine($version)
{
helper::import('./converter/redmine.php');
helper::import("./converter/redmine$version.php");
$className = "redmine11ConvertModel";
$redmine->aimTypes = $this->post->aimTypes;
$redmine->statusTypes['bug'] = $this->post->statusTypesOfBug;
$redmine->statusTypes['story'] = $this->post->statusTypesOfStory;
$redmine->statusTypes['task'] = $this->post->statusTypesOfTask;
$redmine->priTypes['bug'] = $this->post->priTypesOfBug;
$redmine->priTypes['story'] = $this->post->priTypesOfStory;
$redmine->priTypes['task'] = $this->post->priTypesOfTask;
$converter = new $className($redmine);
$this->view->version = $version;
$this->view->result = $converter->execute($version);
$this->view->info = redmineConvertModel::$info;
$this->display();
}
}

View File

@@ -1,88 +1,88 @@
<?php
/**
* The baisc model file of bugfree convert of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
class bugfreeConvertModel extends convertModel
{
public $map = array();
public $filePath = '';
static public $info = array();
/**
* Connect to db auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
parent::connectDB();
}
/**
* Check table.
*
* @access public
* @return bool
*/
public function checkTables()
{
return true;
}
/**
* Check the install path.
*
* @access public
* @return bool
*/
public function checkPath()
{
$this->setPath();
return file_exists($this->filePath);
}
/**
* Set the path of attachments.
*
* @access public
* @return bool
*/
public function setPath()
{
$this->filePath = realpath($this->post->installPath) . $this->app->getPathFix() . 'BugFile' . $this->app->getPathFix();
}
/**
* Excute the convert.
*
* @param int $version
* @access public
* @return void
*/
public function execute($version)
{
}
/**
* Clear rows added in converting.
*
* @access public
* @return void
*/
public function clear()
{
foreach($this->session->state as $table => $maxID)
{
$this->dao->dbh($this->dbh)->delete()->from($table)->where('id')->gt($maxID)->exec();
}
}
}
<?php
/**
* The baisc model file of bugfree convert of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
class bugfreeConvertModel extends convertModel
{
public $map = array();
public $filePath = '';
static public $info = array();
/**
* Connect to db auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
parent::connectDB();
}
/**
* Check table.
*
* @access public
* @return bool
*/
public function checkTables()
{
return true;
}
/**
* Check the install path.
*
* @access public
* @return bool
*/
public function checkPath()
{
$this->setPath();
return file_exists($this->filePath);
}
/**
* Set the path of attachments.
*
* @access public
* @return bool
*/
public function setPath()
{
$this->filePath = realpath($this->post->installPath) . $this->app->getPathFix() . 'BugFile' . $this->app->getPathFix();
}
/**
* Excute the convert.
*
* @param int $version
* @access public
* @return void
*/
public function execute($version)
{
}
/**
* Clear rows added in converting.
*
* @access public
* @return void
*/
public function clear()
{
foreach($this->session->state as $table => $maxID)
{
$this->dao->dbh($this->dbh)->delete()->from($table)->where('id')->gt($maxID)->exec();
}
}
}

View File

@@ -1,318 +1,318 @@
<?php
/**
* The model file of bugfree version 1 convert of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
class bugfree1ConvertModel extends bugfreeConvertModel
{
/**
* Execute the convert.
*
* @access public
* @return array
*/
public function execute()
{
$this->clear();
$this->convertGroup();
$result['users'] = $this->convertUser();
$result['projects'] = $this->convertProject();
$result['modules'] = $this->convertModule();
$result['bugs'] = $this->convertBug();
$result['actions'] = $this->convertAction();
$result['files'] = $this->convertFile();
$this->dao->dbh($this->dbh);
$this->loadModel('tree')->fixModulePath();
return $result;
}
/**
* Convert groups.
*
* @access public
* @return void
*/
public function convertGroup()
{
$groups = $this->dao->dbh($this->sourceDBH)
->select("groupID AS id, groupName AS name, groupUser AS users")
->from('BugGroup')
->fetchAll('id', $autoCompany = false);
foreach($groups as $groupID => $group)
{
/* Explode into array. */
$groupUsers = explode(',', $group->users);
unset($group->id);
unset($group->users);
/* Insert the group. */
$this->dao->dbh($this->dbh)->insert(TABLE_GROUP)->data($group)->exec();
$zentaoGroupID = $this->dao->lastInsertId();
/* Insert account. */
foreach($groupUsers as $account)
{
if(empty($account)) continue;
$this->dao->dbh($this->dbh)->insert(TABLE_USERGROUP)->set('`group`')->eq($zentaoGroupID)->set('account')->eq($account)->exec();
}
}
}
/**
* Convert user.
*
* @access public
* @return int converted user count
*/
public function convertUser()
{
/* Get users exist in the system. */
$activeUsers = $this->dao
->dbh($this->sourceDBH)
->select("username AS account, userpassword AS password, realname, email")
->from('BugUser')
->orderBy('userID ASC')
->fetchAll('account', $autoCompany = false);
/* Get users in histories. */
$allUsers = $this->dao->select("distinct(username) AS account")->from('BugHistory')->fetchPairs('', '', $autoCompany = false);
/* Merge them. */
foreach($allUsers as $key => $account)
{
if(isset($activeUsers[$account]))
{
$allUsers[$key] = $activeUsers[$account];
}
else
{
$allUsers[$key] = array('account' => $account, 'realname' => $account, 'deleted' => '1');
}
}
foreach($activeUsers as $account => $user) if(!isset($allUsers[$account])) $allUsers[$account] = $user;
/* Insert into zentao. */
$convertCount = 0;
foreach($allUsers as $account => $user)
{
if(!$this->dao->dbh($this->dbh)->findByAccount($account)->from(TABLE_USER)->fetch('account'))
{
$this->dao->dbh($this->dbh)->insert(TABLE_USER)->data($user)->exec();
$convertCount ++;
}
else
{
self::$info['users'][] = sprintf($this->lang->convert->errorUserExists, $account);
}
}
return $convertCount;
}
/**
* Convert project in bugfree to product in zentao.
*
* @access public
* @return int converted project count
*/
public function convertProject()
{
$projects = $this->dao->dbh($this->sourceDBH)->select("projectID AS id, projectName AS name")->from('BugProject')->fetchAll('id', $autoCompany = false);
foreach($projects as $projectID => $project)
{
unset($project->id);
$this->dao->dbh($this->dbh)->insert(TABLE_PRODUCT)->data($project)->exec();
$this->map['product'][$projectID] = $this->dao->lastInsertID();
}
return count($projects);
}
/**
* Convert modules.
*
* @access public
* @return int converted modules count
*/
public function convertModule()
{
$this->map['module'][0] = 0;
$modules = $this->dao
->dbh($this->sourceDBH)
->select(
'moduleID AS id,
projectID AS root,
moduleName AS name,
moduleGrade AS grade,
parentID AS parent,
"bug" AS type')
->from('BugModule')
->orderBy('id ASC')
->fetchAll('id', $autoCompany = false);
foreach($modules as $moduleID => $module)
{
$module->root = $this->map['product'][$module->root];
unset($module->id);
$this->dao->dbh($this->dbh)->insert(TABLE_MODULE)->data($module)->exec();
$this->map['module'][$moduleID] = $this->dao->lastInsertID();
}
/* Update parents. */
foreach($modules as $oldModuleID => $module)
{
$newModuleID = $this->map['module'][$oldModuleID];
$newParentID = $this->map['module'][$module->parent];
$this->dao->dbh($this->dbh)->update(TABLE_MODULE)->set('parent')->eq($newParentID)->where('id')->eq($newModuleID)->exec();
}
return count($modules);
}
/**
* Convert bugs.
*
* @access public
* @return int converted bugs count.
*/
public function convertBug()
{
$bugs = $this->dao
->dbh($this->sourceDBH)
->select('
bugID AS id,
projectID AS product,
moduleID AS module,
bugTitle AS title,
bugSeverity AS severity,
bugType AS type,
bugOS AS os,
bugStatus AS status,
mailto,
openedBy, openedDate, openedBuild,
assignedTo, assignedDate,
resolvedBy, resolution, resolvedBuild, resolvedDate,
closedBy, closedDate,
lastEditedBy, lastEditedDate,
linkID as duplicateBug
')
->from('BugInfo')
->orderBy('bugID')
->fetchAll('id', $autoCompany = false);
foreach($bugs as $bugID => $bug)
{
/* Adjust some fields of bug. */
$bugID = (int)$bugID;
unset($bug->id);
if($bug->assignedTo == 'Closed') $bug->assignedTo = 'closed';
$bug->type = strtolower($bug->type);
$bug->os = strtolower($bug->os);
$bug->browser = 'all';
$bug->resolution = str_replace(' ','', strtolower($bug->resolution));
$bug->product = $this->map['product'][$bug->product];
$bug->module = $this->map['module'][$bug->module];
$this->dao->dbh($this->dbh)->insert(TABLE_BUG)->data($bug)->exec();
$this->map['bug'][$bugID] = $this->dao->lastInsertID();
}
/* Update duplicated bugs. */
foreach($this->map['bug'] as $oldBugID => $newBugID)
{
$this->dao->dbh($this->dbh)->update(TABLE_BUG)->set('duplicateBug')->eq($newBugID)->where('duplicateBug')->eq($oldBugID)->exec();
}
return count($bugs);
}
/**
* Convert actions.
*
* @access public
* @return int converted actions count.
*/
public function convertAction()
{
$actions = $this->dao
->dbh($this->sourceDBH)
->select("
'bug' AS objectType,
bugID AS objectID,
userName AS actor,
action,
fullInfo AS comment,
actionDate AS date")
->from('BugHistory')
->orderBy('bugID, historyID')
->fetchGroup('objectID', '', $autoCompany = false);
$convertCount = 0;
foreach($actions as $bugID => $bugActions)
{
/* Get the related bugID. */
$bugID = (int)$bugID;
$zentaoBugID = $this->map['bug'][$bugID];
/* Process actions. */
foreach($bugActions as $key => $action)
{
$action->objectID = $zentaoBugID;
if($key == 0)
{
$this->dao->dbh($this->dbh)->update(TABLE_BUG)->set('steps')->eq(nl2br($action->comment))->where('id')->eq($zentaoBugID)->exec();
$action->comment = '';
}
$this->dao->dbh($this->dbh)->insert(TABLE_ACTION)->data($action)->exec();
$convertCount ++;
}
}
return $convertCount;
}
/**
* Convert files.
*
* @access public
* @return int converted files count.
*/
public function convertFile()
{
$this->setPath();
$files = $this->dao->dbh($this->sourceDBH)
->select("
fileName AS pathname,
fileTitle AS title,
fileType AS extension,
fileSize AS size,
'bug' AS objectType,
bugID AS objectID,
addUser AS addedBy,
addDate AS addedDate
")
->from('BugFile')
->orderBy('fileID')
->fetchAll('', $autoCompany = false);
foreach($files as $file)
{
$file->objectID = $this->map['bug'][(int)$file->objectID];
if(strpos($file->size, 'KB')) $file->size = (int)(str_replace('KB', '', $file->size) * 1024);
if(strpos($file->size, 'MB')) $file->size = (int)(str_replace('MB', '', $file->size) * 1024 * 1024);
$this->dao->dbh($this->dbh)->insert(TABLE_FILE)->data($file)->exec();
/* Copy files. */
$soureFile = $this->filePath . $file->pathname;
if(!file_exists($soureFile))
{
self::$info['files'][] = sprintf($this->lang->convert->errorFileNotExits, $soureFile);
continue;
}
$targetFile = $this->app->getAppRoot() . "www/data/upload/{$this->app->company->id}/" . $file->pathname;
$targetPath = dirname($targetFile);
if(!is_dir($targetPath)) mkdir($targetPath, 0777, true);
if(!copy($soureFile, $targetFile))
{
self::$info['files'][] = sprintf($this->lang->convert->errorCopyFailed, $targetFile);
}
}
return count($files);
}
}
<?php
/**
* The model file of bugfree version 1 convert of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
class bugfree1ConvertModel extends bugfreeConvertModel
{
/**
* Execute the convert.
*
* @access public
* @return array
*/
public function execute()
{
$this->clear();
$this->convertGroup();
$result['users'] = $this->convertUser();
$result['projects'] = $this->convertProject();
$result['modules'] = $this->convertModule();
$result['bugs'] = $this->convertBug();
$result['actions'] = $this->convertAction();
$result['files'] = $this->convertFile();
$this->dao->dbh($this->dbh);
$this->loadModel('tree')->fixModulePath();
return $result;
}
/**
* Convert groups.
*
* @access public
* @return void
*/
public function convertGroup()
{
$groups = $this->dao->dbh($this->sourceDBH)
->select("groupID AS id, groupName AS name, groupUser AS users")
->from('BugGroup')
->fetchAll('id', $autoCompany = false);
foreach($groups as $groupID => $group)
{
/* Explode into array. */
$groupUsers = explode(',', $group->users);
unset($group->id);
unset($group->users);
/* Insert the group. */
$this->dao->dbh($this->dbh)->insert(TABLE_GROUP)->data($group)->exec();
$zentaoGroupID = $this->dao->lastInsertId();
/* Insert account. */
foreach($groupUsers as $account)
{
if(empty($account)) continue;
$this->dao->dbh($this->dbh)->insert(TABLE_USERGROUP)->set('`group`')->eq($zentaoGroupID)->set('account')->eq($account)->exec();
}
}
}
/**
* Convert user.
*
* @access public
* @return int converted user count
*/
public function convertUser()
{
/* Get users exist in the system. */
$activeUsers = $this->dao
->dbh($this->sourceDBH)
->select("username AS account, userpassword AS password, realname, email")
->from('BugUser')
->orderBy('userID ASC')
->fetchAll('account', $autoCompany = false);
/* Get users in histories. */
$allUsers = $this->dao->select("distinct(username) AS account")->from('BugHistory')->fetchPairs('', '', $autoCompany = false);
/* Merge them. */
foreach($allUsers as $key => $account)
{
if(isset($activeUsers[$account]))
{
$allUsers[$key] = $activeUsers[$account];
}
else
{
$allUsers[$key] = array('account' => $account, 'realname' => $account, 'deleted' => '1');
}
}
foreach($activeUsers as $account => $user) if(!isset($allUsers[$account])) $allUsers[$account] = $user;
/* Insert into zentao. */
$convertCount = 0;
foreach($allUsers as $account => $user)
{
if(!$this->dao->dbh($this->dbh)->findByAccount($account)->from(TABLE_USER)->fetch('account'))
{
$this->dao->dbh($this->dbh)->insert(TABLE_USER)->data($user)->exec();
$convertCount ++;
}
else
{
self::$info['users'][] = sprintf($this->lang->convert->errorUserExists, $account);
}
}
return $convertCount;
}
/**
* Convert project in bugfree to product in zentao.
*
* @access public
* @return int converted project count
*/
public function convertProject()
{
$projects = $this->dao->dbh($this->sourceDBH)->select("projectID AS id, projectName AS name")->from('BugProject')->fetchAll('id', $autoCompany = false);
foreach($projects as $projectID => $project)
{
unset($project->id);
$this->dao->dbh($this->dbh)->insert(TABLE_PRODUCT)->data($project)->exec();
$this->map['product'][$projectID] = $this->dao->lastInsertID();
}
return count($projects);
}
/**
* Convert modules.
*
* @access public
* @return int converted modules count
*/
public function convertModule()
{
$this->map['module'][0] = 0;
$modules = $this->dao
->dbh($this->sourceDBH)
->select(
'moduleID AS id,
projectID AS root,
moduleName AS name,
moduleGrade AS grade,
parentID AS parent,
"bug" AS type')
->from('BugModule')
->orderBy('id ASC')
->fetchAll('id', $autoCompany = false);
foreach($modules as $moduleID => $module)
{
$module->root = $this->map['product'][$module->root];
unset($module->id);
$this->dao->dbh($this->dbh)->insert(TABLE_MODULE)->data($module)->exec();
$this->map['module'][$moduleID] = $this->dao->lastInsertID();
}
/* Update parents. */
foreach($modules as $oldModuleID => $module)
{
$newModuleID = $this->map['module'][$oldModuleID];
$newParentID = $this->map['module'][$module->parent];
$this->dao->dbh($this->dbh)->update(TABLE_MODULE)->set('parent')->eq($newParentID)->where('id')->eq($newModuleID)->exec();
}
return count($modules);
}
/**
* Convert bugs.
*
* @access public
* @return int converted bugs count.
*/
public function convertBug()
{
$bugs = $this->dao
->dbh($this->sourceDBH)
->select('
bugID AS id,
projectID AS product,
moduleID AS module,
bugTitle AS title,
bugSeverity AS severity,
bugType AS type,
bugOS AS os,
bugStatus AS status,
mailto,
openedBy, openedDate, openedBuild,
assignedTo, assignedDate,
resolvedBy, resolution, resolvedBuild, resolvedDate,
closedBy, closedDate,
lastEditedBy, lastEditedDate,
linkID as duplicateBug
')
->from('BugInfo')
->orderBy('bugID')
->fetchAll('id', $autoCompany = false);
foreach($bugs as $bugID => $bug)
{
/* Adjust some fields of bug. */
$bugID = (int)$bugID;
unset($bug->id);
if($bug->assignedTo == 'Closed') $bug->assignedTo = 'closed';
$bug->type = strtolower($bug->type);
$bug->os = strtolower($bug->os);
$bug->browser = 'all';
$bug->resolution = str_replace(' ','', strtolower($bug->resolution));
$bug->product = $this->map['product'][$bug->product];
$bug->module = $this->map['module'][$bug->module];
$this->dao->dbh($this->dbh)->insert(TABLE_BUG)->data($bug)->exec();
$this->map['bug'][$bugID] = $this->dao->lastInsertID();
}
/* Update duplicated bugs. */
foreach($this->map['bug'] as $oldBugID => $newBugID)
{
$this->dao->dbh($this->dbh)->update(TABLE_BUG)->set('duplicateBug')->eq($newBugID)->where('duplicateBug')->eq($oldBugID)->exec();
}
return count($bugs);
}
/**
* Convert actions.
*
* @access public
* @return int converted actions count.
*/
public function convertAction()
{
$actions = $this->dao
->dbh($this->sourceDBH)
->select("
'bug' AS objectType,
bugID AS objectID,
userName AS actor,
action,
fullInfo AS comment,
actionDate AS date")
->from('BugHistory')
->orderBy('bugID, historyID')
->fetchGroup('objectID', '', $autoCompany = false);
$convertCount = 0;
foreach($actions as $bugID => $bugActions)
{
/* Get the related bugID. */
$bugID = (int)$bugID;
$zentaoBugID = $this->map['bug'][$bugID];
/* Process actions. */
foreach($bugActions as $key => $action)
{
$action->objectID = $zentaoBugID;
if($key == 0)
{
$this->dao->dbh($this->dbh)->update(TABLE_BUG)->set('steps')->eq(nl2br($action->comment))->where('id')->eq($zentaoBugID)->exec();
$action->comment = '';
}
$this->dao->dbh($this->dbh)->insert(TABLE_ACTION)->data($action)->exec();
$convertCount ++;
}
}
return $convertCount;
}
/**
* Convert files.
*
* @access public
* @return int converted files count.
*/
public function convertFile()
{
$this->setPath();
$files = $this->dao->dbh($this->sourceDBH)
->select("
fileName AS pathname,
fileTitle AS title,
fileType AS extension,
fileSize AS size,
'bug' AS objectType,
bugID AS objectID,
addUser AS addedBy,
addDate AS addedDate
")
->from('BugFile')
->orderBy('fileID')
->fetchAll('', $autoCompany = false);
foreach($files as $file)
{
$file->objectID = $this->map['bug'][(int)$file->objectID];
if(strpos($file->size, 'KB')) $file->size = (int)(str_replace('KB', '', $file->size) * 1024);
if(strpos($file->size, 'MB')) $file->size = (int)(str_replace('MB', '', $file->size) * 1024 * 1024);
$this->dao->dbh($this->dbh)->insert(TABLE_FILE)->data($file)->exec();
/* Copy files. */
$soureFile = $this->filePath . $file->pathname;
if(!file_exists($soureFile))
{
self::$info['files'][] = sprintf($this->lang->convert->errorFileNotExits, $soureFile);
continue;
}
$targetFile = $this->app->getAppRoot() . "www/data/upload/{$this->app->company->id}/" . $file->pathname;
$targetPath = dirname($targetFile);
if(!is_dir($targetPath)) mkdir($targetPath, 0777, true);
if(!copy($soureFile, $targetFile))
{
self::$info['files'][] = sprintf($this->lang->convert->errorCopyFailed, $targetFile);
}
}
return count($files);
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,88 +1,88 @@
<?php
/**
* The baisc model file of bugfree convert of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yangyang Shi <shiyangyang@cnezsoft.com>
* @package convert
* @version $Id $
* @link http://www.zentao.net
*/
class redmineConvertModel extends convertModel
{
public $map = array();
public $filePath = '';
static public $info = array();
/**
* Connect to db auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
parent::connectDB();
}
/**
* Check table.
*
* @access public
* @return bool
*/
public function checkTables()
{
return true;
}
/**
* Check the install path.
*
* @access public
* @return bool
*/
public function checkPath()
{
$this->setPath();
return file_exists($this->filePath);
}
/**
* Set the path of attachments.
*
* @access public
* @return bool
*/
public function setPath()
{
$this->filePath = realpath($this->post->installPath) . $this->app->getPathFix() . 'files' . $this->app->getPathFix();
}
/**
* Excute the convert.
*
* @param int $version
* @access public
* @return void
*/
public function execute($version)
{
}
/**
* Clear rows added in converting.
*
* @access public
* @return void
*/
public function clear()
{
foreach($this->session->state as $table => $maxID)
{
$this->dao->dbh($this->dbh)->delete()->from($table)->where('id')->gt($maxID)->exec();
}
}
}
<?php
/**
* The baisc model file of bugfree convert of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yangyang Shi <shiyangyang@cnezsoft.com>
* @package convert
* @version $Id $
* @link http://www.zentao.net
*/
class redmineConvertModel extends convertModel
{
public $map = array();
public $filePath = '';
static public $info = array();
/**
* Connect to db auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
parent::connectDB();
}
/**
* Check table.
*
* @access public
* @return bool
*/
public function checkTables()
{
return true;
}
/**
* Check the install path.
*
* @access public
* @return bool
*/
public function checkPath()
{
$this->setPath();
return file_exists($this->filePath);
}
/**
* Set the path of attachments.
*
* @access public
* @return bool
*/
public function setPath()
{
$this->filePath = realpath($this->post->installPath) . $this->app->getPathFix() . 'files' . $this->app->getPathFix();
}
/**
* Excute the convert.
*
* @param int $version
* @access public
* @return void
*/
public function execute($version)
{
}
/**
* Clear rows added in converting.
*
* @access public
* @return void
*/
public function clear()
{
foreach($this->session->state as $table => $maxID)
{
$this->dao->dbh($this->dbh)->delete()->from($table)->where('id')->gt($maxID)->exec();
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,109 +1,109 @@
<?php
/**
* The convert module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
$lang->convert->common = 'Import';
$lang->convert->next = 'Next';
$lang->convert->pre = 'Back';
$lang->convert->reload = 'Reload';
$lang->convert->error = 'Error ';
$lang->convert->start = 'Begin import';
$lang->convert->desc = <<<EOT
<p>Welcome to use this convert wizard which will help you to import other system data to ZenTaoPMS.</p>
<strong>Importing is dangerous. Be sure to backup your database and other data files and sure nobody is using pms when importing.</strong>
EOT;
$lang->convert->selectSource = 'Select source system and version';
$lang->convert->source = 'Source system';
$lang->convert->version = 'Version';
$lang->convert->mustSelectSource = "Must select a source system";
$lang->convert->direction = 'Please select the direction of issue in Redmine';
$lang->convert->questionTypeOfRedmine = 'Types of issue in Redmine';
$lang->convert->aimTypeOfZentao = 'Aim type in Zentao';
$lang->convert->directionList['bug'] = 'Bug';
$lang->convert->directionList['task'] = 'Task';
$lang->convert->directionList['story'] = 'Story';
$lang->convert->sourceList['BugFree'] = array('bugfree_1' => '1.x', 'bugfree_2' => '2.x');
$lang->convert->sourceList['Redmine'] = array('Redmine_1_1' => '1.1');
$lang->convert->setting = 'Setting';
$lang->convert->checkConfig = 'Check setting';
$lang->convert->ok = 'Check passed(√)';
$lang->convert->fail = 'Check failed(×)';
$lang->convert->settingDB = 'Set database';
$lang->convert->dbHost = 'Database server';
$lang->convert->dbPort = 'Server port';
$lang->convert->dbUser = 'Database user';
$lang->convert->dbPassword = 'Database password';
$lang->convert->dbName = '%s database';
$lang->convert->dbCharset = '%s charset';
$lang->convert->dbPrefix = '%s table prefix';
$lang->convert->installPath = '%s installed path';
$lang->convert->checkDB = 'Database';
$lang->convert->checkTable = 'Table';
$lang->convert->checkPath = 'Installed path';
$lang->convert->execute = 'Execute import';
$lang->convert->item = 'Imported items';
$lang->convert->count = 'Count';
$lang->convert->info = 'Info';
$lang->convert->bugfree->users = 'User';
$lang->convert->bugfree->projects = 'Project';
$lang->convert->bugfree->modules = 'Module';
$lang->convert->bugfree->bugs = 'Bug';
$lang->convert->bugfree->cases = 'Case';
$lang->convert->bugfree->results = 'Result';
$lang->convert->bugfree->actions = 'History';
$lang->convert->bugfree->files = 'File';
$lang->convert->redmine->users = 'Users';
$lang->convert->redmine->groups = 'Groups';
$lang->convert->redmine->products = 'Products';
$lang->convert->redmine->projects = 'Projects';
$lang->convert->redmine->stories = 'Stories';
$lang->convert->redmine->tasks = 'Tasks';
$lang->convert->redmine->bugs = 'Bugs';
$lang->convert->redmine->productPlans = 'ProductPlans';
$lang->convert->redmine->teams = 'Teams';
$lang->convert->redmine->releases = 'Releases';
$lang->convert->redmine->builds = 'Builds';
$lang->convert->redmine->docLibs = 'DocLibs';
$lang->convert->redmine->docs = 'Docs';
$lang->convert->redmine->files = 'files';
$lang->convert->errorConnectDB = 'Connect to database server failed.';
$lang->convert->errorFileNotExits = 'File %s not exits.';
$lang->convert->errorUserExists = 'User %s exits already.';
$lang->convert->errorGroupExists = 'Group %s exits already.';
$lang->convert->errorBuildExists = 'Build %s exits already.';
$lang->convert->errorReleaseExists = 'Release %s exits already.';
$lang->convert->errorCopyFailed = 'file %s copy failed.';
$lang->convert->setParam = 'Please set params';
$lang->convert->aimType = 'Issue types goto';
$lang->convert->statusType->bug = 'Status types goto(status of Bug)';
$lang->convert->statusType->story = 'Status types goto(status of story)';
$lang->convert->statusType->task = 'Status types goto(status of task)';
$lang->convert->priType->bug = 'Priority types goto(priority of Bug)';
$lang->convert->priType->story = 'Priority types goto(priority of story)';
$lang->convert->priType->task = 'Priority types goto(priority of task)';
$lang->convert->issue->redmine = 'Redmine';
$lang->convert->issue->zentao = 'ZenTao';
$lang->convert->issue->goto = 'Goto';
<?php
/**
* The convert module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
$lang->convert->common = 'Import';
$lang->convert->next = 'Next';
$lang->convert->pre = 'Back';
$lang->convert->reload = 'Reload';
$lang->convert->error = 'Error ';
$lang->convert->start = 'Begin import';
$lang->convert->desc = <<<EOT
<p>Welcome to use this convert wizard which will help you to import other system data to ZenTaoPMS.</p>
<strong>Importing is dangerous. Be sure to backup your database and other data files and sure nobody is using pms when importing.</strong>
EOT;
$lang->convert->selectSource = 'Select source system and version';
$lang->convert->source = 'Source system';
$lang->convert->version = 'Version';
$lang->convert->mustSelectSource = "Must select a source system";
$lang->convert->direction = 'Please select the direction of issue in Redmine';
$lang->convert->questionTypeOfRedmine = 'Types of issue in Redmine';
$lang->convert->aimTypeOfZentao = 'Aim type in Zentao';
$lang->convert->directionList['bug'] = 'Bug';
$lang->convert->directionList['task'] = 'Task';
$lang->convert->directionList['story'] = 'Story';
$lang->convert->sourceList['BugFree'] = array('bugfree_1' => '1.x', 'bugfree_2' => '2.x');
$lang->convert->sourceList['Redmine'] = array('Redmine_1_1' => '1.1');
$lang->convert->setting = 'Setting';
$lang->convert->checkConfig = 'Check setting';
$lang->convert->ok = 'Check passed(√)';
$lang->convert->fail = 'Check failed(×)';
$lang->convert->settingDB = 'Set database';
$lang->convert->dbHost = 'Database server';
$lang->convert->dbPort = 'Server port';
$lang->convert->dbUser = 'Database user';
$lang->convert->dbPassword = 'Database password';
$lang->convert->dbName = '%s database';
$lang->convert->dbCharset = '%s charset';
$lang->convert->dbPrefix = '%s table prefix';
$lang->convert->installPath = '%s installed path';
$lang->convert->checkDB = 'Database';
$lang->convert->checkTable = 'Table';
$lang->convert->checkPath = 'Installed path';
$lang->convert->execute = 'Execute import';
$lang->convert->item = 'Imported items';
$lang->convert->count = 'Count';
$lang->convert->info = 'Info';
$lang->convert->bugfree->users = 'User';
$lang->convert->bugfree->projects = 'Project';
$lang->convert->bugfree->modules = 'Module';
$lang->convert->bugfree->bugs = 'Bug';
$lang->convert->bugfree->cases = 'Case';
$lang->convert->bugfree->results = 'Result';
$lang->convert->bugfree->actions = 'History';
$lang->convert->bugfree->files = 'File';
$lang->convert->redmine->users = 'Users';
$lang->convert->redmine->groups = 'Groups';
$lang->convert->redmine->products = 'Products';
$lang->convert->redmine->projects = 'Projects';
$lang->convert->redmine->stories = 'Stories';
$lang->convert->redmine->tasks = 'Tasks';
$lang->convert->redmine->bugs = 'Bugs';
$lang->convert->redmine->productPlans = 'ProductPlans';
$lang->convert->redmine->teams = 'Teams';
$lang->convert->redmine->releases = 'Releases';
$lang->convert->redmine->builds = 'Builds';
$lang->convert->redmine->docLibs = 'DocLibs';
$lang->convert->redmine->docs = 'Docs';
$lang->convert->redmine->files = 'files';
$lang->convert->errorConnectDB = 'Connect to database server failed.';
$lang->convert->errorFileNotExits = 'File %s not exits.';
$lang->convert->errorUserExists = 'User %s exits already.';
$lang->convert->errorGroupExists = 'Group %s exits already.';
$lang->convert->errorBuildExists = 'Build %s exits already.';
$lang->convert->errorReleaseExists = 'Release %s exits already.';
$lang->convert->errorCopyFailed = 'file %s copy failed.';
$lang->convert->setParam = 'Please set params';
$lang->convert->aimType = 'Issue types goto';
$lang->convert->statusType->bug = 'Status types goto(status of Bug)';
$lang->convert->statusType->story = 'Status types goto(status of story)';
$lang->convert->statusType->task = 'Status types goto(status of task)';
$lang->convert->priType->bug = 'Priority types goto(priority of Bug)';
$lang->convert->priType->story = 'Priority types goto(priority of story)';
$lang->convert->priType->task = 'Priority types goto(priority of task)';
$lang->convert->issue->redmine = 'Redmine';
$lang->convert->issue->zentao = 'ZenTao';
$lang->convert->issue->goto = 'Goto';

View File

@@ -1,109 +1,109 @@
<?php
/**
* The convert module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
$lang->convert->common = '从其他系统导入';
$lang->convert->next = '下一步';
$lang->convert->pre = '返回';
$lang->convert->reload = '刷新';
$lang->convert->error = '错误 ';
$lang->convert->start = '开始转换';
$lang->convert->desc = <<<EOT
<p>欢迎使用系统转换向导,本程序会帮助您将其他系统的数据转换到禅道项目管理系统中。</p>
<strong>转换存在一定的风险,转换之前,我们强烈建议您备份数据库及相应的数据文件,并保证转换的时候,没有其他人进行操作。</strong>
EOT;
$lang->convert->selectSource = '选择来源系统及版本';
$lang->convert->source = '来源系统';
$lang->convert->version = '版本';
$lang->convert->mustSelectSource = "必须选择一个来源。";
$lang->convert->direction = '请选择项目问题转换方向';
$lang->convert->questionTypeOfRedmine = 'Redmine中问题类型';
$lang->convert->aimTypeOfZentao = '转化为Zentao中的类型';
$lang->convert->directionList['bug'] = 'Bug';
$lang->convert->directionList['task'] = '任务';
$lang->convert->directionList['story'] = '需求';
$lang->convert->sourceList['BugFree'] = array('bugfree_1' => '1.x', 'bugfree_2' => '2.x');
$lang->convert->sourceList['Redmine'] = array('Redmine_1.1' => '1.1');
$lang->convert->setting = '设置';
$lang->convert->checkConfig = '检查配置';
$lang->convert->ok = '检查通过(√)';
$lang->convert->fail = '检查失败(×)';
$lang->convert->settingDB = '设置数据库';
$lang->convert->dbHost = '数据库服务器';
$lang->convert->dbPort = '服务器端口';
$lang->convert->dbUser = '数据库用户名';
$lang->convert->dbPassword = '数据库密码';
$lang->convert->dbName = '%s使用的库';
$lang->convert->dbCharset = '%s数据库编码';
$lang->convert->dbPrefix = '%s表前缀';
$lang->convert->installPath = '%s安装的根目录';
$lang->convert->checkDB = '数据库';
$lang->convert->checkTable = '表';
$lang->convert->checkPath = '安装路径';
$lang->convert->execute = '执行转换';
$lang->convert->item = '转换项';
$lang->convert->count = '转换数量';
$lang->convert->info = '转换信息';
$lang->convert->bugfree->users = '用户';
$lang->convert->bugfree->projects = '项目';
$lang->convert->bugfree->modules = '模块';
$lang->convert->bugfree->bugs = 'Bug';
$lang->convert->bugfree->cases = '测试用例';
$lang->convert->bugfree->results = '测试结果';
$lang->convert->bugfree->actions = '历史记录';
$lang->convert->bugfree->files = '附件';
$lang->convert->redmine->users = '用户';
$lang->convert->redmine->groups = '用户分组';
$lang->convert->redmine->products = '产品';
$lang->convert->redmine->projects = '项目';
$lang->convert->redmine->stories = '需求';
$lang->convert->redmine->tasks = '任务';
$lang->convert->redmine->bugs = 'Bug';
$lang->convert->redmine->productPlans = '产品计划';
$lang->convert->redmine->teams = '团队';
$lang->convert->redmine->releases = '发布';
$lang->convert->redmine->builds = 'Build';
$lang->convert->redmine->docLibs = '文档库';
$lang->convert->redmine->docs = '文档';
$lang->convert->redmine->files = '附件';
$lang->convert->errorConnectDB = '数据库连接失败 ';
$lang->convert->errorFileNotExits = '文件 %s 不存在';
$lang->convert->errorUserExists = '用户 %s 已存在';
$lang->convert->errorGroupExists = '分组 %s 已存在';
$lang->convert->errorBuildExists = 'Build %s 已存在';
$lang->convert->errorReleaseExists = '发布 %s 已存在';
$lang->convert->errorCopyFailed = '文件 %s 拷贝失败';
$lang->convert->setParam = '请设置转换参数';
$lang->convert->aimType = '问题类型转换';
$lang->convert->statusType->bug = '状态类型转换(Bug状态)';
$lang->convert->statusType->story = '状态类型转换(Story状态)';
$lang->convert->statusType->task = '状态类型转换(Task状态)';
$lang->convert->priType->bug = '优先级类型转换(Bug状态)';
$lang->convert->priType->story = '优先级类型转换(Story状态)';
$lang->convert->priType->task = '优先级类型转换(Task状态)';
$lang->convert->issue->redmine = 'Redmine';
$lang->convert->issue->zentao = '禅道';
$lang->convert->issue->goto = '转换为';
<?php
/**
* The convert module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
$lang->convert->common = '从其他系统导入';
$lang->convert->next = '下一步';
$lang->convert->pre = '返回';
$lang->convert->reload = '刷新';
$lang->convert->error = '错误 ';
$lang->convert->start = '开始转换';
$lang->convert->desc = <<<EOT
<p>欢迎使用系统转换向导,本程序会帮助您将其他系统的数据转换到禅道项目管理系统中。</p>
<strong>转换存在一定的风险,转换之前,我们强烈建议您备份数据库及相应的数据文件,并保证转换的时候,没有其他人进行操作。</strong>
EOT;
$lang->convert->selectSource = '选择来源系统及版本';
$lang->convert->source = '来源系统';
$lang->convert->version = '版本';
$lang->convert->mustSelectSource = "必须选择一个来源。";
$lang->convert->direction = '请选择项目问题转换方向';
$lang->convert->questionTypeOfRedmine = 'Redmine中问题类型';
$lang->convert->aimTypeOfZentao = '转化为Zentao中的类型';
$lang->convert->directionList['bug'] = 'Bug';
$lang->convert->directionList['task'] = '任务';
$lang->convert->directionList['story'] = '需求';
$lang->convert->sourceList['BugFree'] = array('bugfree_1' => '1.x', 'bugfree_2' => '2.x');
$lang->convert->sourceList['Redmine'] = array('Redmine_1.1' => '1.1');
$lang->convert->setting = '设置';
$lang->convert->checkConfig = '检查配置';
$lang->convert->ok = '检查通过(√)';
$lang->convert->fail = '检查失败(×)';
$lang->convert->settingDB = '设置数据库';
$lang->convert->dbHost = '数据库服务器';
$lang->convert->dbPort = '服务器端口';
$lang->convert->dbUser = '数据库用户名';
$lang->convert->dbPassword = '数据库密码';
$lang->convert->dbName = '%s使用的库';
$lang->convert->dbCharset = '%s数据库编码';
$lang->convert->dbPrefix = '%s表前缀';
$lang->convert->installPath = '%s安装的根目录';
$lang->convert->checkDB = '数据库';
$lang->convert->checkTable = '表';
$lang->convert->checkPath = '安装路径';
$lang->convert->execute = '执行转换';
$lang->convert->item = '转换项';
$lang->convert->count = '转换数量';
$lang->convert->info = '转换信息';
$lang->convert->bugfree->users = '用户';
$lang->convert->bugfree->projects = '项目';
$lang->convert->bugfree->modules = '模块';
$lang->convert->bugfree->bugs = 'Bug';
$lang->convert->bugfree->cases = '测试用例';
$lang->convert->bugfree->results = '测试结果';
$lang->convert->bugfree->actions = '历史记录';
$lang->convert->bugfree->files = '附件';
$lang->convert->redmine->users = '用户';
$lang->convert->redmine->groups = '用户分组';
$lang->convert->redmine->products = '产品';
$lang->convert->redmine->projects = '项目';
$lang->convert->redmine->stories = '需求';
$lang->convert->redmine->tasks = '任务';
$lang->convert->redmine->bugs = 'Bug';
$lang->convert->redmine->productPlans = '产品计划';
$lang->convert->redmine->teams = '团队';
$lang->convert->redmine->releases = '发布';
$lang->convert->redmine->builds = 'Build';
$lang->convert->redmine->docLibs = '文档库';
$lang->convert->redmine->docs = '文档';
$lang->convert->redmine->files = '附件';
$lang->convert->errorConnectDB = '数据库连接失败 ';
$lang->convert->errorFileNotExits = '文件 %s 不存在';
$lang->convert->errorUserExists = '用户 %s 已存在';
$lang->convert->errorGroupExists = '分组 %s 已存在';
$lang->convert->errorBuildExists = 'Build %s 已存在';
$lang->convert->errorReleaseExists = '发布 %s 已存在';
$lang->convert->errorCopyFailed = '文件 %s 拷贝失败';
$lang->convert->setParam = '请设置转换参数';
$lang->convert->aimType = '问题类型转换';
$lang->convert->statusType->bug = '状态类型转换(Bug状态)';
$lang->convert->statusType->story = '状态类型转换(Story状态)';
$lang->convert->statusType->task = '状态类型转换(Task状态)';
$lang->convert->priType->bug = '优先级类型转换(Bug状态)';
$lang->convert->priType->story = '优先级类型转换(Story状态)';
$lang->convert->priType->task = '优先级类型转换(Task状态)';
$lang->convert->issue->redmine = 'Redmine';
$lang->convert->issue->zentao = '禅道';
$lang->convert->issue->goto = '转换为';

View File

@@ -1,109 +1,109 @@
<?php
/**
* The convert module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id: zh-tw.php 2001 2011-07-03 05:50:54Z shiyangyangwork@yahoo.cn $
* @link http://www.zentao.net
*/
$lang->convert->common = '從其他系統導入';
$lang->convert->next = '下一步';
$lang->convert->pre = '返回';
$lang->convert->reload = '刷新';
$lang->convert->error = '錯誤 ';
$lang->convert->start = '開始轉換';
$lang->convert->desc = <<<EOT
<p>歡迎使用系統轉換嚮導,本程序會幫助您將其他系統的數據轉換到禪道項目管理系統中。</p>
<strong>轉換存在一定的風險,轉換之前,我們強烈建議您備份資料庫及相應的數據檔案,並保證轉換的時候,沒有其他人進行操作。</strong>
EOT;
$lang->convert->selectSource = '選擇來源系統及版本';
$lang->convert->source = '來源系統';
$lang->convert->version = '版本';
$lang->convert->mustSelectSource = "必須選擇一個來源。";
$lang->convert->direction = '請選擇項目問題轉換方向';
$lang->convert->questionTypeOfRedmine = 'Redmine中問題類型';
$lang->convert->aimTypeOfZentao = '轉化為Zentao中的類型';
$lang->convert->directionList['bug'] = 'Bug';
$lang->convert->directionList['task'] = '任務';
$lang->convert->directionList['story'] = '需求';
$lang->convert->sourceList['BugFree'] = array('bugfree_1' => '1.x', 'bugfree_2' => '2.x');
$lang->convert->sourceList['Redmine'] = array('Redmine_1.1' => '1.1');
$lang->convert->setting = '設置';
$lang->convert->checkConfig = '檢查配置';
$lang->convert->ok = '檢查通過(√)';
$lang->convert->fail = '檢查失敗(×)';
$lang->convert->settingDB = '設置資料庫';
$lang->convert->dbHost = '資料庫伺服器';
$lang->convert->dbPort = '伺服器連接埠';
$lang->convert->dbUser = '資料庫用戶名';
$lang->convert->dbPassword = '資料庫密碼';
$lang->convert->dbName = '%s使用的庫';
$lang->convert->dbCharset = '%s資料庫編碼';
$lang->convert->dbPrefix = '%s表首碼';
$lang->convert->installPath = '%s安裝的根目錄';
$lang->convert->checkDB = '資料庫';
$lang->convert->checkTable = '表';
$lang->convert->checkPath = '安裝路徑';
$lang->convert->execute = '執行轉換';
$lang->convert->item = '轉換項';
$lang->convert->count = '轉換數量';
$lang->convert->info = '轉換信息';
$lang->convert->bugfree->users = '用戶';
$lang->convert->bugfree->projects = '項目';
$lang->convert->bugfree->modules = '模組';
$lang->convert->bugfree->bugs = 'Bug';
$lang->convert->bugfree->cases = '測試用例';
$lang->convert->bugfree->results = '測試結果';
$lang->convert->bugfree->actions = '歷史記錄';
$lang->convert->bugfree->files = '附件';
$lang->convert->redmine->users = '用戶';
$lang->convert->redmine->groups = '用戶分組';
$lang->convert->redmine->products = '產品';
$lang->convert->redmine->projects = '項目';
$lang->convert->redmine->stories = '需求';
$lang->convert->redmine->tasks = '任務';
$lang->convert->redmine->bugs = 'Bug';
$lang->convert->redmine->productPlans = '產品計劃';
$lang->convert->redmine->teams = '團隊';
$lang->convert->redmine->releases = '發佈';
$lang->convert->redmine->builds = 'Build';
$lang->convert->redmine->docLibs = '文檔庫';
$lang->convert->redmine->docs = '文檔';
$lang->convert->redmine->files = '附件';
$lang->convert->errorConnectDB = '資料庫連接失敗 ';
$lang->convert->errorFileNotExits = '檔案 %s 不存在';
$lang->convert->errorUserExists = '用戶 %s 已存在';
$lang->convert->errorGroupExists = '分組 %s 已存在';
$lang->convert->errorBuildExists = 'Build %s 已存在';
$lang->convert->errorReleaseExists = '發佈 %s 已存在';
$lang->convert->errorCopyFailed = '檔案 %s 拷貝失敗';
$lang->convert->setParam = '請設置轉換參數';
$lang->convert->aimType = '問題類型轉換';
$lang->convert->statusType->bug = '狀態類型轉換(Bug狀態)';
$lang->convert->statusType->story = '狀態類型轉換(Story狀態)';
$lang->convert->statusType->task = '狀態類型轉換(Task狀態)';
$lang->convert->priType->bug = '優先順序類型轉換(Bug狀態)';
$lang->convert->priType->story = '優先順序類型轉換(Story狀態)';
$lang->convert->priType->task = '優先順序類型轉換(Task狀態)';
$lang->convert->issue->redmine = 'Redmine';
$lang->convert->issue->zentao = '禪道';
$lang->convert->issue->goto = '轉換為';
<?php
/**
* The convert module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id: zh-tw.php 2001 2011-07-03 05:50:54Z shiyangyangwork@yahoo.cn $
* @link http://www.zentao.net
*/
$lang->convert->common = '從其他系統導入';
$lang->convert->next = '下一步';
$lang->convert->pre = '返回';
$lang->convert->reload = '刷新';
$lang->convert->error = '錯誤 ';
$lang->convert->start = '開始轉換';
$lang->convert->desc = <<<EOT
<p>歡迎使用系統轉換嚮導,本程序會幫助您將其他系統的數據轉換到禪道項目管理系統中。</p>
<strong>轉換存在一定的風險,轉換之前,我們強烈建議您備份資料庫及相應的數據檔案,並保證轉換的時候,沒有其他人進行操作。</strong>
EOT;
$lang->convert->selectSource = '選擇來源系統及版本';
$lang->convert->source = '來源系統';
$lang->convert->version = '版本';
$lang->convert->mustSelectSource = "必須選擇一個來源。";
$lang->convert->direction = '請選擇項目問題轉換方向';
$lang->convert->questionTypeOfRedmine = 'Redmine中問題類型';
$lang->convert->aimTypeOfZentao = '轉化為Zentao中的類型';
$lang->convert->directionList['bug'] = 'Bug';
$lang->convert->directionList['task'] = '任務';
$lang->convert->directionList['story'] = '需求';
$lang->convert->sourceList['BugFree'] = array('bugfree_1' => '1.x', 'bugfree_2' => '2.x');
$lang->convert->sourceList['Redmine'] = array('Redmine_1.1' => '1.1');
$lang->convert->setting = '設置';
$lang->convert->checkConfig = '檢查配置';
$lang->convert->ok = '檢查通過(√)';
$lang->convert->fail = '檢查失敗(×)';
$lang->convert->settingDB = '設置資料庫';
$lang->convert->dbHost = '資料庫伺服器';
$lang->convert->dbPort = '伺服器連接埠';
$lang->convert->dbUser = '資料庫用戶名';
$lang->convert->dbPassword = '資料庫密碼';
$lang->convert->dbName = '%s使用的庫';
$lang->convert->dbCharset = '%s資料庫編碼';
$lang->convert->dbPrefix = '%s表首碼';
$lang->convert->installPath = '%s安裝的根目錄';
$lang->convert->checkDB = '資料庫';
$lang->convert->checkTable = '表';
$lang->convert->checkPath = '安裝路徑';
$lang->convert->execute = '執行轉換';
$lang->convert->item = '轉換項';
$lang->convert->count = '轉換數量';
$lang->convert->info = '轉換信息';
$lang->convert->bugfree->users = '用戶';
$lang->convert->bugfree->projects = '項目';
$lang->convert->bugfree->modules = '模組';
$lang->convert->bugfree->bugs = 'Bug';
$lang->convert->bugfree->cases = '測試用例';
$lang->convert->bugfree->results = '測試結果';
$lang->convert->bugfree->actions = '歷史記錄';
$lang->convert->bugfree->files = '附件';
$lang->convert->redmine->users = '用戶';
$lang->convert->redmine->groups = '用戶分組';
$lang->convert->redmine->products = '產品';
$lang->convert->redmine->projects = '項目';
$lang->convert->redmine->stories = '需求';
$lang->convert->redmine->tasks = '任務';
$lang->convert->redmine->bugs = 'Bug';
$lang->convert->redmine->productPlans = '產品計劃';
$lang->convert->redmine->teams = '團隊';
$lang->convert->redmine->releases = '發佈';
$lang->convert->redmine->builds = 'Build';
$lang->convert->redmine->docLibs = '文檔庫';
$lang->convert->redmine->docs = '文檔';
$lang->convert->redmine->files = '附件';
$lang->convert->errorConnectDB = '資料庫連接失敗 ';
$lang->convert->errorFileNotExits = '檔案 %s 不存在';
$lang->convert->errorUserExists = '用戶 %s 已存在';
$lang->convert->errorGroupExists = '分組 %s 已存在';
$lang->convert->errorBuildExists = 'Build %s 已存在';
$lang->convert->errorReleaseExists = '發佈 %s 已存在';
$lang->convert->errorCopyFailed = '檔案 %s 拷貝失敗';
$lang->convert->setParam = '請設置轉換參數';
$lang->convert->aimType = '問題類型轉換';
$lang->convert->statusType->bug = '狀態類型轉換(Bug狀態)';
$lang->convert->statusType->story = '狀態類型轉換(Story狀態)';
$lang->convert->statusType->task = '狀態類型轉換(Task狀態)';
$lang->convert->priType->bug = '優先順序類型轉換(Bug狀態)';
$lang->convert->priType->story = '優先順序類型轉換(Story狀態)';
$lang->convert->priType->task = '優先順序類型轉換(Task狀態)';
$lang->convert->issue->redmine = 'Redmine';
$lang->convert->issue->zentao = '禪道';
$lang->convert->issue->goto = '轉換為';

View File

@@ -1,94 +1,94 @@
<?php
/**
* The model file of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class convertModel extends model
{
/**
* Connect to db.
*
* @access public
* @return void
*/
public function connectDB()
{
$dsn = "mysql:host={$this->post->dbHost}; port={$this->post->dbPort};dbname={$this->post->dbName}";
try
{
$dbh = new PDO($dsn, $this->post->dbUser, $this->post->dbPassword);
$dbh->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_OBJ);
$dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$dbh->exec("SET NAMES {$this->post->dbCharset}");
$this->sourceDBH = $dbh;
return $dbh;
}
catch (PDOException $exception)
{
return $exception->getMessage();
}
}
/**
* Check database exits or not.
*
* @access public
* @return bool
*/
public function dbExists()
{
$sql = "SHOW DATABASES like '{$this->post->db->name}'";
return $this->dbh->query($sql)->fetch();
}
/**
* Check table exits or not.
*
* @access public
* @return bool
*/
public function tableExists($table)
{
$sql = "SHOW tables like '$table'";
return $this->dbh->query($sql)->fetch();
}
/**
* Save the max id of every table. Thus when we convert again, when can delete id larger then the saved max id.
*
* @access public
* @return void
*/
public function saveState()
{
/* Get user defined tables. */
$constants = get_defined_constants(true);
$userConstants = $constants['user'];
/* These tables needn't save. */
unset($userConstants['TABLE_BURN']);
unset($userConstants['TABLE_GROUPPRIV']);
unset($userConstants['TABLE_PROJECTPRODUCT']);
unset($userConstants['TABLE_PROJECTSTORY']);
unset($userConstants['TABLE_STORYSPEC']);
unset($userConstants['TABLE_TEAM']);
unset($userConstants['TABLE_USERGROUP']);
/* Get max id of every table. */
foreach($userConstants as $key => $value)
{
if(strpos($key, 'TABLE') === false) continue;
if($key == 'TABLE_COMPANY') continue;
$state[$value] = (int)$this->dao->select('MAX(id) AS id')->from($value)->fetch('id');
}
$this->session->set('state', $state);
}
}
<?php
/**
* The model file of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class convertModel extends model
{
/**
* Connect to db.
*
* @access public
* @return void
*/
public function connectDB()
{
$dsn = "mysql:host={$this->post->dbHost}; port={$this->post->dbPort};dbname={$this->post->dbName}";
try
{
$dbh = new PDO($dsn, $this->post->dbUser, $this->post->dbPassword);
$dbh->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_OBJ);
$dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$dbh->exec("SET NAMES {$this->post->dbCharset}");
$this->sourceDBH = $dbh;
return $dbh;
}
catch (PDOException $exception)
{
return $exception->getMessage();
}
}
/**
* Check database exits or not.
*
* @access public
* @return bool
*/
public function dbExists()
{
$sql = "SHOW DATABASES like '{$this->post->db->name}'";
return $this->dbh->query($sql)->fetch();
}
/**
* Check table exits or not.
*
* @access public
* @return bool
*/
public function tableExists($table)
{
$sql = "SHOW tables like '$table'";
return $this->dbh->query($sql)->fetch();
}
/**
* Save the max id of every table. Thus when we convert again, when can delete id larger then the saved max id.
*
* @access public
* @return void
*/
public function saveState()
{
/* Get user defined tables. */
$constants = get_defined_constants(true);
$userConstants = $constants['user'];
/* These tables needn't save. */
unset($userConstants['TABLE_BURN']);
unset($userConstants['TABLE_GROUPPRIV']);
unset($userConstants['TABLE_PROJECTPRODUCT']);
unset($userConstants['TABLE_PROJECTSTORY']);
unset($userConstants['TABLE_STORYSPEC']);
unset($userConstants['TABLE_TEAM']);
unset($userConstants['TABLE_USERGROUP']);
/* Get max id of every table. */
foreach($userConstants as $key => $value)
{
if(strpos($key, 'TABLE') === false) continue;
if($key == 'TABLE_COMPANY') continue;
$state[$value] = (int)$this->dao->select('MAX(id) AS id')->from($value)->fetch('id');
}
$this->session->set('state', $state);
}
}

View File

@@ -1,29 +1,29 @@
<?php
/**
* The html template file of check config method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' action='<?php echo inlink('execute');?>'>
<table align='center' class='w-p65 f-14px'>
<caption><?php echo $lang->convert->checkConfig . $lang->colon . strtoupper($source);?></caption>
<?php echo $checkResult;?>
</table>
<?php
echo html::hidden('dbHost', $this->post->dbHost);
echo html::hidden('dbPort', $this->post->dbPort);
echo html::hidden('dbUser', $this->post->dbUser);
echo html::hidden('dbPassword', $this->post->dbPassword);
echo html::hidden('dbName', $this->post->dbName);
echo html::hidden('dbCharset', $this->post->dbCharset);
echo html::hidden('dbPrefix', $this->post->dbPrefix);
echo html::hidden('installPath',$this->post->installPath);
?>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The html template file of check config method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' action='<?php echo inlink('execute');?>'>
<table align='center' class='w-p65 f-14px'>
<caption><?php echo $lang->convert->checkConfig . $lang->colon . strtoupper($source);?></caption>
<?php echo $checkResult;?>
</table>
<?php
echo html::hidden('dbHost', $this->post->dbHost);
echo html::hidden('dbPort', $this->post->dbPort);
echo html::hidden('dbUser', $this->post->dbUser);
echo html::hidden('dbPassword', $this->post->dbPassword);
echo html::hidden('dbName', $this->post->dbName);
echo html::hidden('dbCharset', $this->post->dbCharset);
echo html::hidden('dbPrefix', $this->post->dbPrefix);
echo html::hidden('installPath',$this->post->installPath);
?>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,18 +1,18 @@
<?php
/**
* The html template file of execute method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<table align='center' class='f-14px'>
<caption><?php echo $lang->convert->execute . $lang->colon . strtoupper($source);?></caption>
<?php echo $executeResult;?>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The html template file of execute method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<table align='center' class='f-14px'>
<caption><?php echo $lang->convert->execute . $lang->colon . strtoupper($source);?></caption>
<?php echo $executeResult;?>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,18 +1,18 @@
<?php
/**
* The html template file of index method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<table align='center' class='table-5'>
<caption><?php echo $lang->convert->common;?></caption>
<tr><td><?php echo nl2br($lang->convert->desc);?></td></tr>
<tr><td><h3 class='a-center'><?php echo html::a($this->createLink('convert', 'selectsource'), $lang->convert->start);?></h3></td></tr>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The html template file of index method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package ZenTaoPMS
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<table align='center' class='table-5'>
<caption><?php echo $lang->convert->common;?></caption>
<tr><td><?php echo nl2br($lang->convert->desc);?></td></tr>
<tr><td><h3 class='a-center'><?php echo html::a($this->createLink('convert', 'selectsource'), $lang->convert->start);?></h3></td></tr>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,31 +1,31 @@
<?php
/**
* The html template file of select source method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' action='<?php echo inlink('setConfig');?>'>
<table align='center' class='table-5 f-14px'>
<caption><?php echo $lang->convert->selectSource;?></caption>
<tr>
<th class='w-p20'><?php echo $lang->convert->source;?></th>
<th><?php echo $lang->convert->version;?></th>
</tr>
<?php foreach($lang->convert->sourceList as $name => $versions):?>
<tr>
<th class='rowhead'><?php echo $name;?></th>
<td><?php echo html::radio('source', $versions);?></td>
</tr>
<?php endforeach;?>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton();?></td>
</tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The html template file of select source method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' action='<?php echo inlink('setConfig');?>'>
<table align='center' class='table-5 f-14px'>
<caption><?php echo $lang->convert->selectSource;?></caption>
<tr>
<th class='w-p20'><?php echo $lang->convert->source;?></th>
<th><?php echo $lang->convert->version;?></th>
</tr>
<?php foreach($lang->convert->sourceList as $name => $versions):?>
<tr>
<th class='rowhead'><?php echo $name;?></th>
<td><?php echo html::radio('source', $versions);?></td>
</tr>
<?php endforeach;?>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton();?></td>
</tr>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,23 +1,23 @@
<?php
/**
* The html template file of setconfig method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' action='<?php echo inlink('checkconfig');?>'>
<table align='center' class='table-5 f-14px'>
<caption><?php echo $lang->convert->setting . $lang->colon . strtoupper($source);?></caption>
<?php echo $setting;?>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton();?></td>
</tr>
</table>
<?php echo html::hidden('source', $source) . html::hidden('version', $version);?>
</form>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The html template file of setconfig method of convert module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package convert
* @version $Id$
*/
?>
<?php include '../../common/view/header.html.php';?>
<form method='post' action='<?php echo inlink('checkconfig');?>'>
<table align='center' class='table-5 f-14px'>
<caption><?php echo $lang->convert->setting . $lang->colon . strtoupper($source);?></caption>
<?php echo $setting;?>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton();?></td>
</tr>
</table>
<?php echo html::hidden('source', $source) . html::hidden('version', $version);?>
</form>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,101 +1,101 @@
<?php
/**
* The control file of dept module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
class dept extends control
{
const NEW_CHILD_COUNT = 5;
/**
* Construct function, set menu.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->loadModel('company')->setMenu();
}
/**
* Browse a department.
*
* @param int $deptID
* @access public
* @return void
*/
public function browse($deptID = 0)
{
$header['title'] = $this->lang->dept->manage . $this->lang->colon . $this->app->company->name;
$position[] = $this->lang->dept->manage;
$parentDepts = $this->dept->getParents($deptID);
$this->view->header = $header;
$this->view->position = $position;
$this->view->deptID = $deptID;
$this->view->depts = $this->dept->getTreeMenu($rooteDeptID = 0, array('deptmodel', 'createManageLink'));
$this->view->parentDepts = $parentDepts;
$this->view->sons = $this->dept->getSons($deptID);
$this->display();
}
/**
* Update the departments order.
*
* @access public
* @return void
*/
public function updateOrder()
{
if(!empty($_POST))
{
$this->dept->updateOrder($_POST['orders']);
die(js::reload('parent'));
}
}
/**
* Manage childs.
*
* @access public
* @return void
*/
public function manageChild()
{
if(!empty($_POST))
{
$this->dept->manageChild($_POST['parentDeptID'], $_POST['depts']);
die(js::reload('parent'));
}
}
/**
* Delete a department.
*
* @param int $deptID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function delete($deptID, $confirm = 'no')
{
if($confirm == 'no')
{
echo js::confirm($this->lang->dept->confirmDelete, $this->createLink('dept', 'delete', "deptID=$deptID&confirm=yes"));
exit;
}
else
{
$this->dept->delete($deptID);
die(js::reload('parent'));
}
}
}
<?php
/**
* The control file of dept module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
class dept extends control
{
const NEW_CHILD_COUNT = 5;
/**
* Construct function, set menu.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->loadModel('company')->setMenu();
}
/**
* Browse a department.
*
* @param int $deptID
* @access public
* @return void
*/
public function browse($deptID = 0)
{
$header['title'] = $this->lang->dept->manage . $this->lang->colon . $this->app->company->name;
$position[] = $this->lang->dept->manage;
$parentDepts = $this->dept->getParents($deptID);
$this->view->header = $header;
$this->view->position = $position;
$this->view->deptID = $deptID;
$this->view->depts = $this->dept->getTreeMenu($rooteDeptID = 0, array('deptmodel', 'createManageLink'));
$this->view->parentDepts = $parentDepts;
$this->view->sons = $this->dept->getSons($deptID);
$this->display();
}
/**
* Update the departments order.
*
* @access public
* @return void
*/
public function updateOrder()
{
if(!empty($_POST))
{
$this->dept->updateOrder($_POST['orders']);
die(js::reload('parent'));
}
}
/**
* Manage childs.
*
* @access public
* @return void
*/
public function manageChild()
{
if(!empty($_POST))
{
$this->dept->manageChild($_POST['parentDeptID'], $_POST['depts']);
die(js::reload('parent'));
}
}
/**
* Delete a department.
*
* @param int $deptID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function delete($deptID, $confirm = 'no')
{
if($confirm == 'no')
{
echo js::confirm($this->lang->dept->confirmDelete, $this->createLink('dept', 'delete', "deptID=$deptID&confirm=yes"));
exit;
}
else
{
$this->dept->delete($deptID);
die(js::reload('parent'));
}
}
}

View File

@@ -1,23 +1,23 @@
<?php
/**
* The dept module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
$lang->dept->common = 'Department';
$lang->dept->add = "Add";
$lang->dept->addChild = "Add child department";
$lang->dept->manageChild = "Child deprtment";
$lang->dept->delete = "Delete";
$lang->dept->browse = "Manage";
$lang->dept->manage = "Manage";
$lang->dept->updateOrder = "Update order";
$lang->dept->users = "Users";
$lang->dept->saveButton = " Save (S) ";
$lang->dept->confirmDelete = "Are you sure to delete this department?";
<?php
/**
* The dept module English file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
$lang->dept->common = 'Department';
$lang->dept->add = "Add";
$lang->dept->addChild = "Add child department";
$lang->dept->manageChild = "Child deprtment";
$lang->dept->delete = "Delete";
$lang->dept->browse = "Manage";
$lang->dept->manage = "Manage";
$lang->dept->updateOrder = "Update order";
$lang->dept->users = "Users";
$lang->dept->saveButton = " Save (S) ";
$lang->dept->confirmDelete = "Are you sure to delete this department?";

View File

@@ -1,23 +1,23 @@
<?php
/**
* The dept module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
$lang->dept->common = '部门结构';
$lang->dept->add = "添加";
$lang->dept->addChild = "添加下级部门";
$lang->dept->manageChild = "下级部门";
$lang->dept->delete = "删除部门";
$lang->dept->browse = "部门维护";
$lang->dept->manage = "维护部门结构";
$lang->dept->updateOrder = "更新排序";
$lang->dept->users = "成员列表";
$lang->dept->saveButton = " 保存 (S) ";
$lang->dept->confirmDelete = " 您确定删除该部门吗?";
<?php
/**
* The dept module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
$lang->dept->common = '部门结构';
$lang->dept->add = "添加";
$lang->dept->addChild = "添加下级部门";
$lang->dept->manageChild = "下级部门";
$lang->dept->delete = "删除部门";
$lang->dept->browse = "部门维护";
$lang->dept->manage = "维护部门结构";
$lang->dept->updateOrder = "更新排序";
$lang->dept->users = "成员列表";
$lang->dept->saveButton = " 保存 (S) ";
$lang->dept->confirmDelete = " 您确定删除该部门吗?";

View File

@@ -1,23 +1,23 @@
<?php
/**
* The dept module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->dept->common = '部門結構';
$lang->dept->add = "添加";
$lang->dept->addChild = "添加下級部門";
$lang->dept->manageChild = "下級部門";
$lang->dept->delete = "刪除部門";
$lang->dept->browse = "部門維護";
$lang->dept->manage = "維護部門結構";
$lang->dept->updateOrder = "更新排序";
$lang->dept->users = "成員列表";
$lang->dept->saveButton = " 保存 (S) ";
$lang->dept->confirmDelete = " 您確定刪除該部門嗎?";
<?php
/**
* The dept module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id: zh-tw.php 1914 2011-06-24 10:11:25Z yidong@cnezsoft.com $
* @link http://www.zentao.net
*/
$lang->dept->common = '部門結構';
$lang->dept->add = "添加";
$lang->dept->addChild = "添加下級部門";
$lang->dept->manageChild = "下級部門";
$lang->dept->delete = "刪除部門";
$lang->dept->browse = "部門維護";
$lang->dept->manage = "維護部門結構";
$lang->dept->updateOrder = "更新排序";
$lang->dept->users = "成員列表";
$lang->dept->saveButton = " 保存 (S) ";
$lang->dept->confirmDelete = " 您確定刪除該部門嗎?";

View File

@@ -1,302 +1,302 @@
<?php
/**
* The model file of dept dept of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class deptModel extends model
{
/**
* Get a department by id.
*
* @param int $deptID
* @access public
* @return object
*/
public function getByID($deptID)
{
return $this->dao->findById($deptID)->from(TABLE_DEPT)->fetch();
}
/**
* Build the query.
*
* @param int $rootDeptID
* @access private
* @return string
*/
private function buildMenuQuery($rootDeptID)
{
$rootDept = $this->getByID($rootDeptID);
if(!$rootDept) $rootDept->path = '';
return $this->dao->select('*')->from(TABLE_DEPT)
->beginIF($rootDeptID > 0)->where('path')->like($rootDept->path . '%')->fi()
->orderBy('grade desc, `order`')
->get();
}
/**
* Get option menu of departments.
*
* @param int $rootDeptID
* @access public
* @return array
*/
public function getOptionMenu($rootDeptID = 0)
{
$deptMenu = array();
$stmt = $this->dbh->query($this->buildMenuQuery($rootDeptID));
$depts = array();
while($dept = $stmt->fetch()) $depts[$dept->id] = $dept;
foreach($depts as $dept)
{
$parentDepts = explode(',', $dept->path);
$deptName = '/';
foreach($parentDepts as $parentDeptID)
{
if(empty($parentDeptID)) continue;
$deptName .= $depts[$parentDeptID]->name . '/';
}
$deptName = rtrim($deptName, '/');
$deptName .= "|$dept->id\n";
if(isset($deptMenu[$dept->id]) and !empty($deptMenu[$dept->id]))
{
if(isset($deptMenu[$dept->parent]))
{
$deptMenu[$dept->parent] .= $deptName;
}
else
{
$deptMenu[$dept->parent] = $deptName;;
}
$deptMenu[$dept->parent] .= $deptMenu[$dept->id];
}
else
{
if(isset($deptMenu[$dept->parent]) and !empty($deptMenu[$dept->parent]))
{
$deptMenu[$dept->parent] .= $deptName;
}
else
{
$deptMenu[$dept->parent] = $deptName;
}
}
}
$topMenu = @array_pop($deptMenu);
$topMenu = explode("\n", trim($topMenu));
$lastMenu[] = '/';
foreach($topMenu as $menu)
{
if(!strpos($menu, '|')) continue;
list($label, $deptID) = explode('|', $menu);
$lastMenu[$deptID] = $label;
}
return $lastMenu;
}
/**
* Get the treemenu of departments.
*
* @param int $rootDeptID
* @param string $userFunc
* @access public
* @return string
*/
public function getTreeMenu($rootDeptID = 0, $userFunc)
{
$deptMenu = array();
$stmt = $this->dbh->query($this->buildMenuQuery($rootDeptID));
while($dept = $stmt->fetch())
{
$linkHtml = call_user_func($userFunc, $dept);
if(isset($deptMenu[$dept->id]) and !empty($deptMenu[$dept->id]))
{
if(!isset($deptMenu[$dept->parent])) $deptMenu[$dept->parent] = '';
$deptMenu[$dept->parent] .= "<li>$linkHtml";
$deptMenu[$dept->parent] .= "<ul>".$deptMenu[$dept->id]."</ul>\n";
}
else
{
if(isset($deptMenu[$dept->parent]) and !empty($deptMenu[$dept->parent]))
{
$deptMenu[$dept->parent] .= "<li>$linkHtml\n";
}
else
{
$deptMenu[$dept->parent] = "<li>$linkHtml\n";
}
}
$deptMenu[$dept->parent] .= "</li>\n";
}
$lastMenu = "<ul id='tree'>" . @array_pop($deptMenu) . "</ul>\n";
return $lastMenu;
}
/**
* Create the manage link.
*
* @param int $dept
* @access public
* @return string
*/
public function createManageLink($dept)
{
$linkHtml = $dept->name;
$linkHtml .= ' ' . html::a(helper::createLink('dept', 'browse', "deptid={$dept->id}"), $this->lang->dept->manageChild);
$linkHtml .= ' ' . html::a(helper::createLink('dept', 'delete', "deptid={$dept->id}"), $this->lang->dept->delete, 'hiddenwin');
$linkHtml .= ' ' . html::input("orders[$dept->id]", $dept->order, 'style="width:30px;text-align:center"');
return $linkHtml;
}
/**
* Create the member link.
*
* @param int $dept
* @access public
* @return string
*/
public function createMemberLink($dept)
{
$linkHtml = html::a(helper::createLink('company', 'browse', "dept={$dept->id}"), $dept->name, '_self', "id='dept{$dept->id}'");
return $linkHtml;
}
/**
* Get sons of a department.
*
* @param int $deptID
* @access public
* @return array
*/
public function getSons($deptID)
{
return $this->dao->select('*')->from(TABLE_DEPT)->where('parent')->eq($deptID)->orderBy('`order`')->fetchAll();
}
/**
* Get all childs.
*
* @param int $deptID
* @access public
* @return array
*/
public function getAllChildId($deptID)
{
if($deptID == 0) return array();
$dept = $this->getById($deptID);
$childs = $this->dao->select('id')->from(TABLE_DEPT)->where('path')->like($dept->path . '%')->fetchPairs();
return array_keys($childs);
}
/**
* Get parents.
*
* @param int $deptID
* @access public
* @return array
*/
public function getParents($deptID)
{
if($deptID == 0) return array();
$path = $this->dao->select('path')->from(TABLE_DEPT)->where('id')->eq($deptID)->fetch('path');
$path = substr($path, 1, -1);
if(empty($path)) return array();
return $this->dao->select('*')->from(TABLE_DEPT)->where('id')->in($path)->orderBy('grade')->fetchAll();
}
/**
* Update order.
*
* @param int $orders
* @access public
* @return void
*/
public function updateOrder($orders)
{
foreach($orders as $deptID => $order) $this->dao->update(TABLE_DEPT)->set('`order`')->eq($order)->where('id')->eq($deptID)->exec();
}
/**
* Manage childs.
*
* @param int $parentDeptID
* @param string $childs
* @access public
* @return void
*/
public function manageChild($parentDeptID, $childs)
{
$parentDept = $this->getByID($parentDeptID);
if($parentDept)
{
$grade = $parentDept->grade + 1;
$parentPath = $parentDept->path;
}
else
{
$grade = 1;
$parentPath = ',';
}
foreach($childs as $deptID => $deptName)
{
if(empty($deptName)) continue;
if(is_numeric($deptID))
{
$dept->name = strip_tags($deptName);
$dept->parent = $parentDeptID;
$dept->grade = $grade;
$this->dao->insert(TABLE_DEPT)->data($dept)->exec();
$deptID = $this->dao->lastInsertID();
$childPath = $parentPath . "$deptID,";
$this->dao->update(TABLE_DEPT)->set('path')->eq($childPath)->where('id')->eq($deptID)->exec();
}
else
{
$deptID = str_replace('id', '', $deptID);
$this->dao->update(TABLE_DEPT)->set('name')->eq(strip_tags($deptName))->where('id')->eq($deptID)->exec();
}
}
}
/**
* Get users of a deparment.
*
* @param int $deptID
* @access public
* @return array
*/
public function getUsers($deptID)
{
return $this->dao->select('*')->from(TABLE_USER)
->where('deleted')->eq(0)
->beginIF($deptID)->andWhere('dept')->in($deptID)->fi()
->orderBy('id')
->fetchAll();
}
/**
* Delete a department.
*
* @param int $deptID
* @access public
* @return void
*/
public function delete($deptID)
{
$this->dao->delete()->from(TABLE_DEPT)->where('id')->eq($deptID)->exec();
}
}
<?php
/**
* The model file of dept dept of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php
class deptModel extends model
{
/**
* Get a department by id.
*
* @param int $deptID
* @access public
* @return object
*/
public function getByID($deptID)
{
return $this->dao->findById($deptID)->from(TABLE_DEPT)->fetch();
}
/**
* Build the query.
*
* @param int $rootDeptID
* @access private
* @return string
*/
private function buildMenuQuery($rootDeptID)
{
$rootDept = $this->getByID($rootDeptID);
if(!$rootDept) $rootDept->path = '';
return $this->dao->select('*')->from(TABLE_DEPT)
->beginIF($rootDeptID > 0)->where('path')->like($rootDept->path . '%')->fi()
->orderBy('grade desc, `order`')
->get();
}
/**
* Get option menu of departments.
*
* @param int $rootDeptID
* @access public
* @return array
*/
public function getOptionMenu($rootDeptID = 0)
{
$deptMenu = array();
$stmt = $this->dbh->query($this->buildMenuQuery($rootDeptID));
$depts = array();
while($dept = $stmt->fetch()) $depts[$dept->id] = $dept;
foreach($depts as $dept)
{
$parentDepts = explode(',', $dept->path);
$deptName = '/';
foreach($parentDepts as $parentDeptID)
{
if(empty($parentDeptID)) continue;
$deptName .= $depts[$parentDeptID]->name . '/';
}
$deptName = rtrim($deptName, '/');
$deptName .= "|$dept->id\n";
if(isset($deptMenu[$dept->id]) and !empty($deptMenu[$dept->id]))
{
if(isset($deptMenu[$dept->parent]))
{
$deptMenu[$dept->parent] .= $deptName;
}
else
{
$deptMenu[$dept->parent] = $deptName;;
}
$deptMenu[$dept->parent] .= $deptMenu[$dept->id];
}
else
{
if(isset($deptMenu[$dept->parent]) and !empty($deptMenu[$dept->parent]))
{
$deptMenu[$dept->parent] .= $deptName;
}
else
{
$deptMenu[$dept->parent] = $deptName;
}
}
}
$topMenu = @array_pop($deptMenu);
$topMenu = explode("\n", trim($topMenu));
$lastMenu[] = '/';
foreach($topMenu as $menu)
{
if(!strpos($menu, '|')) continue;
list($label, $deptID) = explode('|', $menu);
$lastMenu[$deptID] = $label;
}
return $lastMenu;
}
/**
* Get the treemenu of departments.
*
* @param int $rootDeptID
* @param string $userFunc
* @access public
* @return string
*/
public function getTreeMenu($rootDeptID = 0, $userFunc)
{
$deptMenu = array();
$stmt = $this->dbh->query($this->buildMenuQuery($rootDeptID));
while($dept = $stmt->fetch())
{
$linkHtml = call_user_func($userFunc, $dept);
if(isset($deptMenu[$dept->id]) and !empty($deptMenu[$dept->id]))
{
if(!isset($deptMenu[$dept->parent])) $deptMenu[$dept->parent] = '';
$deptMenu[$dept->parent] .= "<li>$linkHtml";
$deptMenu[$dept->parent] .= "<ul>".$deptMenu[$dept->id]."</ul>\n";
}
else
{
if(isset($deptMenu[$dept->parent]) and !empty($deptMenu[$dept->parent]))
{
$deptMenu[$dept->parent] .= "<li>$linkHtml\n";
}
else
{
$deptMenu[$dept->parent] = "<li>$linkHtml\n";
}
}
$deptMenu[$dept->parent] .= "</li>\n";
}
$lastMenu = "<ul id='tree'>" . @array_pop($deptMenu) . "</ul>\n";
return $lastMenu;
}
/**
* Create the manage link.
*
* @param int $dept
* @access public
* @return string
*/
public function createManageLink($dept)
{
$linkHtml = $dept->name;
$linkHtml .= ' ' . html::a(helper::createLink('dept', 'browse', "deptid={$dept->id}"), $this->lang->dept->manageChild);
$linkHtml .= ' ' . html::a(helper::createLink('dept', 'delete', "deptid={$dept->id}"), $this->lang->dept->delete, 'hiddenwin');
$linkHtml .= ' ' . html::input("orders[$dept->id]", $dept->order, 'style="width:30px;text-align:center"');
return $linkHtml;
}
/**
* Create the member link.
*
* @param int $dept
* @access public
* @return string
*/
public function createMemberLink($dept)
{
$linkHtml = html::a(helper::createLink('company', 'browse', "dept={$dept->id}"), $dept->name, '_self', "id='dept{$dept->id}'");
return $linkHtml;
}
/**
* Get sons of a department.
*
* @param int $deptID
* @access public
* @return array
*/
public function getSons($deptID)
{
return $this->dao->select('*')->from(TABLE_DEPT)->where('parent')->eq($deptID)->orderBy('`order`')->fetchAll();
}
/**
* Get all childs.
*
* @param int $deptID
* @access public
* @return array
*/
public function getAllChildId($deptID)
{
if($deptID == 0) return array();
$dept = $this->getById($deptID);
$childs = $this->dao->select('id')->from(TABLE_DEPT)->where('path')->like($dept->path . '%')->fetchPairs();
return array_keys($childs);
}
/**
* Get parents.
*
* @param int $deptID
* @access public
* @return array
*/
public function getParents($deptID)
{
if($deptID == 0) return array();
$path = $this->dao->select('path')->from(TABLE_DEPT)->where('id')->eq($deptID)->fetch('path');
$path = substr($path, 1, -1);
if(empty($path)) return array();
return $this->dao->select('*')->from(TABLE_DEPT)->where('id')->in($path)->orderBy('grade')->fetchAll();
}
/**
* Update order.
*
* @param int $orders
* @access public
* @return void
*/
public function updateOrder($orders)
{
foreach($orders as $deptID => $order) $this->dao->update(TABLE_DEPT)->set('`order`')->eq($order)->where('id')->eq($deptID)->exec();
}
/**
* Manage childs.
*
* @param int $parentDeptID
* @param string $childs
* @access public
* @return void
*/
public function manageChild($parentDeptID, $childs)
{
$parentDept = $this->getByID($parentDeptID);
if($parentDept)
{
$grade = $parentDept->grade + 1;
$parentPath = $parentDept->path;
}
else
{
$grade = 1;
$parentPath = ',';
}
foreach($childs as $deptID => $deptName)
{
if(empty($deptName)) continue;
if(is_numeric($deptID))
{
$dept->name = strip_tags($deptName);
$dept->parent = $parentDeptID;
$dept->grade = $grade;
$this->dao->insert(TABLE_DEPT)->data($dept)->exec();
$deptID = $this->dao->lastInsertID();
$childPath = $parentPath . "$deptID,";
$this->dao->update(TABLE_DEPT)->set('path')->eq($childPath)->where('id')->eq($deptID)->exec();
}
else
{
$deptID = str_replace('id', '', $deptID);
$this->dao->update(TABLE_DEPT)->set('name')->eq(strip_tags($deptName))->where('id')->eq($deptID)->exec();
}
}
}
/**
* Get users of a deparment.
*
* @param int $deptID
* @access public
* @return array
*/
public function getUsers($deptID)
{
return $this->dao->select('*')->from(TABLE_USER)
->where('deleted')->eq(0)
->beginIF($deptID)->andWhere('dept')->in($deptID)->fi()
->orderBy('id')
->fetchAll();
}
/**
* Delete a department.
*
* @param int $deptID
* @access public
* @return void
*/
public function delete($deptID)
{
$this->dao->delete()->from(TABLE_DEPT)->where('id')->eq($deptID)->exec();
}
}

View File

@@ -1,67 +1,67 @@
<?php
/**
* The browse view file of dept module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<table class="cont-lt4">
<tr valign='top'>
<td class='side'>
<form method='post' target='hiddenwin' action='<?php echo $this->createLink('dept', 'updateOrder');?>'>
<table class='table-1'>
<caption><?php echo $header->title;?></caption>
<tr>
<td>
<div id='main'><?php echo $depts;?></div>
<div class='a-center'><?php echo html::submitButton($lang->dept->updateOrder);?></div>
</td>
</tr>
</table>
</form>
</td>
<td class='divider'></td>
<td>
<form method='post' target='hiddenwin' action='<?php echo $this->createLink('dept', 'manageChild');?>'>
<table align='center' class='table-1'>
<caption><?php echo $lang->dept->manageChild;?></caption>
<tr>
<td width='10%'>
<nobr>
<?php
echo html::a($this->createLink('dept', 'browse'), $this->app->company->name);
echo $lang->arrow;
foreach($parentDepts as $dept)
{
echo html::a($this->createLink('dept', 'browse', "deptID=$dept->id"), $dept->name);
echo $lang->arrow;
}
?>
</nobr>
</td>
<td>
<?php
foreach($sons as $sonDept) echo html::input("depts[id$sonDept->id]", $sonDept->name) . '<br />';
for($i = 0; $i < DEPT::NEW_CHILD_COUNT ; $i ++) echo html::input("depts[]") . '<br />';
?>
</td>
</tr>
<tr>
<td class='a-center' colspan='2'>
<?php echo html::submitButton() . html::resetButton();?>
<input type='hidden' value='<?php echo $deptID;?>' name='parentDeptID' />
</td>
</tr>
</table>
</form>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The browse view file of dept module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package dept
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<table class="cont-lt4">
<tr valign='top'>
<td class='side'>
<form method='post' target='hiddenwin' action='<?php echo $this->createLink('dept', 'updateOrder');?>'>
<table class='table-1'>
<caption><?php echo $header->title;?></caption>
<tr>
<td>
<div id='main'><?php echo $depts;?></div>
<div class='a-center'><?php echo html::submitButton($lang->dept->updateOrder);?></div>
</td>
</tr>
</table>
</form>
</td>
<td class='divider'></td>
<td>
<form method='post' target='hiddenwin' action='<?php echo $this->createLink('dept', 'manageChild');?>'>
<table align='center' class='table-1'>
<caption><?php echo $lang->dept->manageChild;?></caption>
<tr>
<td width='10%'>
<nobr>
<?php
echo html::a($this->createLink('dept', 'browse'), $this->app->company->name);
echo $lang->arrow;
foreach($parentDepts as $dept)
{
echo html::a($this->createLink('dept', 'browse', "deptID=$dept->id"), $dept->name);
echo $lang->arrow;
}
?>
</nobr>
</td>
<td>
<?php
foreach($sons as $sonDept) echo html::input("depts[id$sonDept->id]", $sonDept->name) . '<br />';
for($i = 0; $i < DEPT::NEW_CHILD_COUNT ; $i ++) echo html::input("depts[]") . '<br />';
?>
</td>
</tr>
<tr>
<td class='a-center' colspan='2'>
<?php echo html::submitButton() . html::resetButton();?>
<input type='hidden' value='<?php echo $deptID;?>' name='parentDeptID' />
</td>
</tr>
</table>
</form>
</td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,420 +1,420 @@
<?php
/**
* The control file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: control.php 933 2010-07-06 06:53:40Z wwccss $
* @link http://www.zentao.net
*/
class doc extends control
{
/**
* Construct function, load user, tree, action auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->loadModel('user');
$this->loadModel('tree');
$this->loadModel('action');
$this->loadModel('product');
$this->loadModel('project');
$this->libs = $this->doc->getLibs();
}
/**
* Go to browse page.
*
* @access public
* @return void
*/
public function index()
{
$this->locate(inlink('browse'));
}
/**
* Browse docs.
*
* @param string|int $libID product|project or the int id of custom library
* @param int $moduleID
* @param int $productID
* @param int $projectID
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
public function browse($libID = 'product', $moduleID = 0, $productID = 0, $projectID = 0, $browseType = 'byModule', $param = 0, $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Set browseType.*/
$browseType = strtolower($browseType);
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Set menu, save session. */
$this->doc->setMenu($this->libs, $libID, 'doc');
$this->session->set('docList', $this->app->getURI(true));
/* Set header and position. */
$this->view->header->title = $this->lang->doc->index . $this->lang->colon . $this->libs[$libID];
$this->view->position[] = $this->libs[$libID];
/* Load pager. */
$this->app->loadClass('pager', $static = true);
$pager = new pager($recTotal, $recPerPage, $pageID);
/* Get docs. */
$modules = 0;
$docs=array();
if($browseType == "bymodule")
{
if($moduleID) $modules = $this->tree->getAllChildID($moduleID);
$docs = $this->doc->getDocs($libID, $productID, $projectID, $modules, $orderBy, $pager);
}
elseif($browseType == "bysearch")
{
if($queryID)
{
$query = $this->loadModel('search')->getQuery($queryID);
if($query)
{
$this->session->set('docQuery', $query->sql);
$this->session->set('docForm', $query->form);
}
else
{
$this->session->set('docQuery', ' 1 = 1');
}
}
else
{
if($this->session->docQuery == false) $this->session->set('docQuery', ' 1 = 1');
}
$docQuery = str_replace("`product` = 'all'", '1', $this->session->docQuery); // Search all producti.
$docQuery = str_replace("`project` = 'all'", '1', $docQuery); // Search all project.
$docs = $this->dao->select('*')->from(TABLE_DOC)->where($docQuery)
->andWhere('deleted')->eq(0)
->orderBy($orderBy)->page($pager)->fetchAll();
}
/* Get the tree menu. */
if($libID == 'product')
{
$moduleTree = $this->tree->getProductDocTreeMenu();
}
elseif($libID == 'project')
{
$moduleTree = $this->tree->getProjectDocTreeMenu();
}
else
{
$moduleTree = $this->tree->getTreeMenu($libID, $viewType = 'customdoc', $startModuleID = 0, array('treeModel', 'createDocLink'));
}
/* Build the search form. */
$this->config->doc->search['actionURL'] = $this->createLink('doc', 'browse', "libID=$libID&moduleID=$moduleID&procuctID=$productID&projectID=$projectID&browseType=bySearch&queryID=myQueryID");
$this->config->doc->search['queryID'] = $queryID;
$this->config->doc->search['params']['product']['values'] = array(''=>'') + $this->product->getPairs() + array('all'=>$this->lang->doc->allProduct);
$this->config->doc->search['params']['project']['values'] = array(''=>'') + $this->project->getPairs() + array('all'=>$this->lang->doc->allProject);
$this->config->doc->search['params']['lib']['values'] = array(''=>'') + $this->libs;
$this->config->doc->search['params']['type']['values'] = array(''=>'') + $this->config->doc->search['params']['type']['values'];
/* Get the modules. */
if($libID == 'product' or $libID == 'project')
{
$moduleOptionMenu = $this->tree->getOptionMenu(0, $libID . 'doc', $startModuleID = 0);
}
else
{
$moduleOptionMenu = $this->tree->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->config->doc->search['params']['module']['values'] = array(''=>'') + $moduleOptionMenu;
$this->view->searchForm = $this->fetch('search', 'buildForm', $this->config->doc->search);
$this->view->libID = $libID;
$this->view->libName = $this->libs[$libID];
$this->view->moduleID = $moduleID;
$this->view->moduleTree = $moduleTree;
$this->view->parentModules = $this->tree->getParents($moduleID);
$this->view->docs = $docs;
$this->view->pager = $pager;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->orderBy = $orderBy;
$this->view->productID = $productID;
$this->view->projectID = $projectID;
$this->view->browseType = $browseType;
$this->view->param = $param;
$this->display();
}
/**
* Create a library.
*
* @access public
* @return void
*/
public function createLib()
{
if(!empty($_POST))
{
$libID = $this->doc->createLib();
if(!dao::isError())
{
$this->loadModel('action')->create('docLib', $libID, 'Created');
die(js::locate($this->createLink($this->moduleName, 'browse', "libID=$libID"), 'parent'));
}
else
{
echo js::error(dao::getError());
}
}
die($this->display());
}
/**
* Edit a library.
*
* @param int $libID
* @access public
* @return void
*/
public function editLib($libID)
{
if(!empty($_POST))
{
$changes = $this->doc->updateLib($libID);
if(dao::isError()) die(js::error(dao::getError()));
if($changes)
{
$actionID = $this->loadModel('action')->create('docLib', $libID, 'edited');
$this->action->logHistory($actionID, $changes);
}
die(js::locate($this->createLink($this->moduleName, 'browse', "libID=$libID"), 'parent'));
}
$lib = $this->doc->getLibByID($libID);
$this->view->libName = empty($lib) ? $libID : $lib->name;
$this->view->libID = $libID;
die($this->display());
}
/**
* Delete a library.
*
* @param int $libID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function deleteLib($libID, $confirm = 'no')
{
if($libID == 'product' or $libID == 'project') die();
if($confirm == 'no')
{
die(js::confirm($this->lang->doc->confirmDeleteLib, $this->createLink('doc', 'deleteLib', "libID=$libID&confirm=yes")));
}
else
{
$this->doc->delete(TABLE_DOCLIB, $libID);
die(js::locate($this->createLink('doc', 'browse'), 'parent'));
}
}
/**
* Create a doc.
*
* @param int|string $libID
* @param int $moduleID
* @param int $productID
* @param int $projectID
* @param string $from
* @access public
* @return void
*/
public function create($libID, $moduleID = 0, $productID = 0, $projectID = 0, $from = 'doc')
{
$projectID = (int)$projectID;
if(!empty($_POST))
{
$docID = $this->doc->create();
if(dao::isError()) die(js::error(dao::getError()));
$this->action->create('doc', $docID, 'Created');
if($from == 'product') $link = $this->createLink('product', 'doc', "productID={$this->post->product}");
if($from == 'project') $link = $this->createLink('project', 'doc', "projectID={$this->post->project}");
if($from == 'doc')
{
$productID = intval($this->post->product);
$projectID = intval($this->post->project);
$vars = "libID=$libID&moduleID={$this->post->module}&productID=$productID&projectID=$projectID";
$link = $this->createLink('doc', 'browse', $vars);
}
die(js::locate($link, 'parent'));
}
$this->loadModel('product');
$this->loadModel('project');
/* According the from, set menus. */
if($from == 'product')
{
$this->lang->doc->menu = $this->lang->product->menu;
$this->product->setMenu($this->product->getPairs(), $productID);
$this->lang->set('menugroup.doc', 'product');
}
elseif($from == 'project')
{
$this->lang->doc->menu = $this->lang->project->menu;
$this->project->setMenu($this->project->getPairs('nocode'), $projectID);
$this->lang->set('menugroup.doc', 'project');
}
else
{
$this->doc->setMenu($this->libs, $libID);
}
/* Get the modules. */
if($libID == 'product' or $libID == 'project')
{
$moduleOptionMenu = $this->tree->getOptionMenu(0, $libID . 'doc', $startModuleID = 0);
}
else
{
$moduleOptionMenu = $this->tree->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->view->header->title = $this->libs[$libID] . $this->lang->colon . $this->lang->doc->create;
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$libID"), $this->libs[$libID]);
$this->view->position[] = $this->lang->doc->create;
$this->view->libID = $libID;
$this->view->moduleOptionMenu = $moduleOptionMenu;
$this->view->moduleID = $moduleID;
$this->view->productID = $productID;
$this->view->projectID = $projectID;
$this->view->products = $projectID == 0 ? $this->product->getPairs() : $this->project->getProducts($projectID);
$this->view->projects = $this->loadModel('project')->getPairs('all');
$this->display();
}
/**
* Edit a doc.
*
* @param int $docID
* @access public
* @return void
*/
public function edit($docID)
{
if(!empty($_POST))
{
$changes = $this->doc->update($docID);
if(dao::isError()) die(js::error(dao::getError()));
$files = $this->loadModel('file')->saveUpload('doc', $docID);
if($this->post->comment != '' or !empty($changes) or !empty($files))
{
$action = !empty($changes) ? 'Edited' : 'Commented';
$fileAction = '';
if(!empty($files)) $fileAction = $this->lang->addFiles . join(',', $files) . "\n" ;
$actionID = $this->action->create('doc', $docID, $action, $fileAction . $this->post->comment);
$this->action->logHistory($actionID, $changes);
}
die(js::locate($this->createLink('doc', 'view', "docID=$docID"), 'parent'));
}
/* Get doc and set menu. */
$doc = $this->doc->getById($docID);
$libID = $doc->lib;
$this->doc->setMenu($this->libs, $libID);
/* Get modules. */
if($libID == 'product' or $libID == 'project')
{
$moduleOptionMenu = $this->tree->getOptionMenu(0, $libID . 'doc', $startModuleID = 0);
}
else
{
$moduleOptionMenu = $this->tree->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->view->header->title = $this->libs[$libID] . $this->lang->colon . $this->lang->doc->create;
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$libID"), $this->libs[$libID]);
$this->view->position[] = $this->lang->doc->edit;
$this->view->doc = $doc;
$this->view->libID = $libID;
$this->view->users = $this->user->getPairs('noclosed,nodeleted');
$this->view->moduleOptionMenu = $moduleOptionMenu;
$this->display();
}
/**
* View a doc.
*
* @param int $docID
* @access public
* @return void
*/
public function view($docID)
{
/* Get doc. */
$doc = $this->doc->getById($docID);
if(!$doc) die(js::error($this->lang->notFound) . js::locate('back'));
if($doc->project != 0 and !$this->project->checkPriv($this->project->getById($doc->project)))
{
echo(js::alert($this->lang->error->accessDenied));
die(js::locate('back'));
}
/* Get library. */
$lib = $doc->libName;
if($doc->lib == 'product') $lib = $doc->productName;
if($doc->lib == 'project') $lib = $doc->productName . $this->lang->arrow . $doc->projectName;
/* Set menu. */
$this->doc->setMenu($this->libs, $doc->lib);
$this->view->header->title = $this->libs[$doc->lib] . $this->lang->colon . $this->lang->doc->view;
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$doc->lib"), $this->libs[$doc->lib]);
$this->view->position[] = $this->lang->doc->view;
$this->view->doc = $doc;
$this->view->lib = $lib;
$this->view->actions = $this->loadModel('action')->getList('doc', $docID);
$this->view->users = $this->user->getPairs('noclosed,nodeleted');
$this->display();
}
/**
* Delete a doc.
*
* @param int $docID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function delete($docID, $confirm = 'no')
{
if($confirm == 'no')
{
die(js::confirm($this->lang->doc->confirmDelete, inlink('delete', "docID=$docID&confirm=yes")));
}
else
{
$this->doc->delete(TABLE_DOC, $docID);
die(js::locate($this->session->docList, 'parent'));
}
}
}
<?php
/**
* The control file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: control.php 933 2010-07-06 06:53:40Z wwccss $
* @link http://www.zentao.net
*/
class doc extends control
{
/**
* Construct function, load user, tree, action auto.
*
* @access public
* @return void
*/
public function __construct()
{
parent::__construct();
$this->loadModel('user');
$this->loadModel('tree');
$this->loadModel('action');
$this->loadModel('product');
$this->loadModel('project');
$this->libs = $this->doc->getLibs();
}
/**
* Go to browse page.
*
* @access public
* @return void
*/
public function index()
{
$this->locate(inlink('browse'));
}
/**
* Browse docs.
*
* @param string|int $libID product|project or the int id of custom library
* @param int $moduleID
* @param int $productID
* @param int $projectID
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
public function browse($libID = 'product', $moduleID = 0, $productID = 0, $projectID = 0, $browseType = 'byModule', $param = 0, $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Set browseType.*/
$browseType = strtolower($browseType);
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Set menu, save session. */
$this->doc->setMenu($this->libs, $libID, 'doc');
$this->session->set('docList', $this->app->getURI(true));
/* Set header and position. */
$this->view->header->title = $this->lang->doc->index . $this->lang->colon . $this->libs[$libID];
$this->view->position[] = $this->libs[$libID];
/* Load pager. */
$this->app->loadClass('pager', $static = true);
$pager = new pager($recTotal, $recPerPage, $pageID);
/* Get docs. */
$modules = 0;
$docs=array();
if($browseType == "bymodule")
{
if($moduleID) $modules = $this->tree->getAllChildID($moduleID);
$docs = $this->doc->getDocs($libID, $productID, $projectID, $modules, $orderBy, $pager);
}
elseif($browseType == "bysearch")
{
if($queryID)
{
$query = $this->loadModel('search')->getQuery($queryID);
if($query)
{
$this->session->set('docQuery', $query->sql);
$this->session->set('docForm', $query->form);
}
else
{
$this->session->set('docQuery', ' 1 = 1');
}
}
else
{
if($this->session->docQuery == false) $this->session->set('docQuery', ' 1 = 1');
}
$docQuery = str_replace("`product` = 'all'", '1', $this->session->docQuery); // Search all producti.
$docQuery = str_replace("`project` = 'all'", '1', $docQuery); // Search all project.
$docs = $this->dao->select('*')->from(TABLE_DOC)->where($docQuery)
->andWhere('deleted')->eq(0)
->orderBy($orderBy)->page($pager)->fetchAll();
}
/* Get the tree menu. */
if($libID == 'product')
{
$moduleTree = $this->tree->getProductDocTreeMenu();
}
elseif($libID == 'project')
{
$moduleTree = $this->tree->getProjectDocTreeMenu();
}
else
{
$moduleTree = $this->tree->getTreeMenu($libID, $viewType = 'customdoc', $startModuleID = 0, array('treeModel', 'createDocLink'));
}
/* Build the search form. */
$this->config->doc->search['actionURL'] = $this->createLink('doc', 'browse', "libID=$libID&moduleID=$moduleID&procuctID=$productID&projectID=$projectID&browseType=bySearch&queryID=myQueryID");
$this->config->doc->search['queryID'] = $queryID;
$this->config->doc->search['params']['product']['values'] = array(''=>'') + $this->product->getPairs() + array('all'=>$this->lang->doc->allProduct);
$this->config->doc->search['params']['project']['values'] = array(''=>'') + $this->project->getPairs() + array('all'=>$this->lang->doc->allProject);
$this->config->doc->search['params']['lib']['values'] = array(''=>'') + $this->libs;
$this->config->doc->search['params']['type']['values'] = array(''=>'') + $this->config->doc->search['params']['type']['values'];
/* Get the modules. */
if($libID == 'product' or $libID == 'project')
{
$moduleOptionMenu = $this->tree->getOptionMenu(0, $libID . 'doc', $startModuleID = 0);
}
else
{
$moduleOptionMenu = $this->tree->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->config->doc->search['params']['module']['values'] = array(''=>'') + $moduleOptionMenu;
$this->view->searchForm = $this->fetch('search', 'buildForm', $this->config->doc->search);
$this->view->libID = $libID;
$this->view->libName = $this->libs[$libID];
$this->view->moduleID = $moduleID;
$this->view->moduleTree = $moduleTree;
$this->view->parentModules = $this->tree->getParents($moduleID);
$this->view->docs = $docs;
$this->view->pager = $pager;
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->orderBy = $orderBy;
$this->view->productID = $productID;
$this->view->projectID = $projectID;
$this->view->browseType = $browseType;
$this->view->param = $param;
$this->display();
}
/**
* Create a library.
*
* @access public
* @return void
*/
public function createLib()
{
if(!empty($_POST))
{
$libID = $this->doc->createLib();
if(!dao::isError())
{
$this->loadModel('action')->create('docLib', $libID, 'Created');
die(js::locate($this->createLink($this->moduleName, 'browse', "libID=$libID"), 'parent'));
}
else
{
echo js::error(dao::getError());
}
}
die($this->display());
}
/**
* Edit a library.
*
* @param int $libID
* @access public
* @return void
*/
public function editLib($libID)
{
if(!empty($_POST))
{
$changes = $this->doc->updateLib($libID);
if(dao::isError()) die(js::error(dao::getError()));
if($changes)
{
$actionID = $this->loadModel('action')->create('docLib', $libID, 'edited');
$this->action->logHistory($actionID, $changes);
}
die(js::locate($this->createLink($this->moduleName, 'browse', "libID=$libID"), 'parent'));
}
$lib = $this->doc->getLibByID($libID);
$this->view->libName = empty($lib) ? $libID : $lib->name;
$this->view->libID = $libID;
die($this->display());
}
/**
* Delete a library.
*
* @param int $libID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function deleteLib($libID, $confirm = 'no')
{
if($libID == 'product' or $libID == 'project') die();
if($confirm == 'no')
{
die(js::confirm($this->lang->doc->confirmDeleteLib, $this->createLink('doc', 'deleteLib', "libID=$libID&confirm=yes")));
}
else
{
$this->doc->delete(TABLE_DOCLIB, $libID);
die(js::locate($this->createLink('doc', 'browse'), 'parent'));
}
}
/**
* Create a doc.
*
* @param int|string $libID
* @param int $moduleID
* @param int $productID
* @param int $projectID
* @param string $from
* @access public
* @return void
*/
public function create($libID, $moduleID = 0, $productID = 0, $projectID = 0, $from = 'doc')
{
$projectID = (int)$projectID;
if(!empty($_POST))
{
$docID = $this->doc->create();
if(dao::isError()) die(js::error(dao::getError()));
$this->action->create('doc', $docID, 'Created');
if($from == 'product') $link = $this->createLink('product', 'doc', "productID={$this->post->product}");
if($from == 'project') $link = $this->createLink('project', 'doc', "projectID={$this->post->project}");
if($from == 'doc')
{
$productID = intval($this->post->product);
$projectID = intval($this->post->project);
$vars = "libID=$libID&moduleID={$this->post->module}&productID=$productID&projectID=$projectID";
$link = $this->createLink('doc', 'browse', $vars);
}
die(js::locate($link, 'parent'));
}
$this->loadModel('product');
$this->loadModel('project');
/* According the from, set menus. */
if($from == 'product')
{
$this->lang->doc->menu = $this->lang->product->menu;
$this->product->setMenu($this->product->getPairs(), $productID);
$this->lang->set('menugroup.doc', 'product');
}
elseif($from == 'project')
{
$this->lang->doc->menu = $this->lang->project->menu;
$this->project->setMenu($this->project->getPairs('nocode'), $projectID);
$this->lang->set('menugroup.doc', 'project');
}
else
{
$this->doc->setMenu($this->libs, $libID);
}
/* Get the modules. */
if($libID == 'product' or $libID == 'project')
{
$moduleOptionMenu = $this->tree->getOptionMenu(0, $libID . 'doc', $startModuleID = 0);
}
else
{
$moduleOptionMenu = $this->tree->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->view->header->title = $this->libs[$libID] . $this->lang->colon . $this->lang->doc->create;
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$libID"), $this->libs[$libID]);
$this->view->position[] = $this->lang->doc->create;
$this->view->libID = $libID;
$this->view->moduleOptionMenu = $moduleOptionMenu;
$this->view->moduleID = $moduleID;
$this->view->productID = $productID;
$this->view->projectID = $projectID;
$this->view->products = $projectID == 0 ? $this->product->getPairs() : $this->project->getProducts($projectID);
$this->view->projects = $this->loadModel('project')->getPairs('all');
$this->display();
}
/**
* Edit a doc.
*
* @param int $docID
* @access public
* @return void
*/
public function edit($docID)
{
if(!empty($_POST))
{
$changes = $this->doc->update($docID);
if(dao::isError()) die(js::error(dao::getError()));
$files = $this->loadModel('file')->saveUpload('doc', $docID);
if($this->post->comment != '' or !empty($changes) or !empty($files))
{
$action = !empty($changes) ? 'Edited' : 'Commented';
$fileAction = '';
if(!empty($files)) $fileAction = $this->lang->addFiles . join(',', $files) . "\n" ;
$actionID = $this->action->create('doc', $docID, $action, $fileAction . $this->post->comment);
$this->action->logHistory($actionID, $changes);
}
die(js::locate($this->createLink('doc', 'view', "docID=$docID"), 'parent'));
}
/* Get doc and set menu. */
$doc = $this->doc->getById($docID);
$libID = $doc->lib;
$this->doc->setMenu($this->libs, $libID);
/* Get modules. */
if($libID == 'product' or $libID == 'project')
{
$moduleOptionMenu = $this->tree->getOptionMenu(0, $libID . 'doc', $startModuleID = 0);
}
else
{
$moduleOptionMenu = $this->tree->getOptionMenu($libID, 'customdoc', $startModuleID = 0);
}
$this->view->header->title = $this->libs[$libID] . $this->lang->colon . $this->lang->doc->create;
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$libID"), $this->libs[$libID]);
$this->view->position[] = $this->lang->doc->edit;
$this->view->doc = $doc;
$this->view->libID = $libID;
$this->view->users = $this->user->getPairs('noclosed,nodeleted');
$this->view->moduleOptionMenu = $moduleOptionMenu;
$this->display();
}
/**
* View a doc.
*
* @param int $docID
* @access public
* @return void
*/
public function view($docID)
{
/* Get doc. */
$doc = $this->doc->getById($docID);
if(!$doc) die(js::error($this->lang->notFound) . js::locate('back'));
if($doc->project != 0 and !$this->project->checkPriv($this->project->getById($doc->project)))
{
echo(js::alert($this->lang->error->accessDenied));
die(js::locate('back'));
}
/* Get library. */
$lib = $doc->libName;
if($doc->lib == 'product') $lib = $doc->productName;
if($doc->lib == 'project') $lib = $doc->productName . $this->lang->arrow . $doc->projectName;
/* Set menu. */
$this->doc->setMenu($this->libs, $doc->lib);
$this->view->header->title = $this->libs[$doc->lib] . $this->lang->colon . $this->lang->doc->view;
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$doc->lib"), $this->libs[$doc->lib]);
$this->view->position[] = $this->lang->doc->view;
$this->view->doc = $doc;
$this->view->lib = $lib;
$this->view->actions = $this->loadModel('action')->getList('doc', $docID);
$this->view->users = $this->user->getPairs('noclosed,nodeleted');
$this->display();
}
/**
* Delete a doc.
*
* @param int $docID
* @param string $confirm yes|no
* @access public
* @return void
*/
public function delete($docID, $confirm = 'no')
{
if($confirm == 'no')
{
die(js::confirm($this->lang->doc->confirmDelete, inlink('delete', "docID=$docID&confirm=yes")));
}
else
{
$this->doc->delete(TABLE_DOC, $docID);
die(js::locate($this->session->docList, 'parent'));
}
}
}

View File

@@ -1,65 +1,65 @@
<?php
/**
* The doc module english file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: en.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
/* Fields. */
$lang->doc->common = 'Doc';
$lang->doc->id = 'ID';
$lang->doc->product = 'Product';
$lang->doc->project = 'Project';
$lang->doc->lib = 'Library';
$lang->doc->module = 'Module';
$lang->doc->title = 'Title';
$lang->doc->digest = 'Digest';
$lang->doc->comment = 'Comment';
$lang->doc->type = 'Type';
$lang->doc->content = 'Content';
$lang->doc->keywords = 'Keywords';
$lang->doc->url = 'URL';
$lang->doc->files = 'File';
$lang->doc->views = 'Views';
$lang->doc->addedBy = 'Added by';
$lang->doc->addedDate = 'Added date';
$lang->doc->editedBy = 'Edited by';
$lang->doc->editedDate = 'Edited date';
$lang->doc->moduleDoc = 'By module';
$lang->doc->searchDoc = 'By search';
//$lang->doc->allDoc = 'All document';
$lang->doc->moduleName = 'Module name';
$lang->doc->moduleOrder = 'Module order';
/* Actions. */
$lang->doc->index = 'Index';
$lang->doc->create = 'Create doc';
$lang->doc->edit = 'Edit doc';
$lang->doc->delete = 'Delete doc';
$lang->doc->browse = 'Browse doc';
$lang->doc->view = 'View doc';
$lang->doc->createLib = 'Create library';
$lang->doc->editLib = 'Edit library';
$lang->doc->deleteLib = 'Delete library';
$lang->doc->libName = 'Library name';
/* Browse tabs. */
$lang->doc->allProduct = 'All products';
$lang->doc->allProject = 'All projects';
$lang->doc->systemLibs['product'] = 'Product doc';
$lang->doc->systemLibs['project'] = 'Project doc';
$lang->doc->types['file'] = 'File';
$lang->doc->types['url'] = 'Link';
$lang->doc->types['text'] = 'Html';
$lang->doc->confirmDelete = "Are you sure to delete this doc?";
$lang->doc->confirmDeleteLib = " Are you sure to delete this doc library?";
$lang->doc->errorEditSystemDoc = "System doc library needn't edit";
<?php
/**
* The doc module english file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: en.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
/* Fields. */
$lang->doc->common = 'Doc';
$lang->doc->id = 'ID';
$lang->doc->product = 'Product';
$lang->doc->project = 'Project';
$lang->doc->lib = 'Library';
$lang->doc->module = 'Module';
$lang->doc->title = 'Title';
$lang->doc->digest = 'Digest';
$lang->doc->comment = 'Comment';
$lang->doc->type = 'Type';
$lang->doc->content = 'Content';
$lang->doc->keywords = 'Keywords';
$lang->doc->url = 'URL';
$lang->doc->files = 'File';
$lang->doc->views = 'Views';
$lang->doc->addedBy = 'Added by';
$lang->doc->addedDate = 'Added date';
$lang->doc->editedBy = 'Edited by';
$lang->doc->editedDate = 'Edited date';
$lang->doc->moduleDoc = 'By module';
$lang->doc->searchDoc = 'By search';
//$lang->doc->allDoc = 'All document';
$lang->doc->moduleName = 'Module name';
$lang->doc->moduleOrder = 'Module order';
/* Actions. */
$lang->doc->index = 'Index';
$lang->doc->create = 'Create doc';
$lang->doc->edit = 'Edit doc';
$lang->doc->delete = 'Delete doc';
$lang->doc->browse = 'Browse doc';
$lang->doc->view = 'View doc';
$lang->doc->createLib = 'Create library';
$lang->doc->editLib = 'Edit library';
$lang->doc->deleteLib = 'Delete library';
$lang->doc->libName = 'Library name';
/* Browse tabs. */
$lang->doc->allProduct = 'All products';
$lang->doc->allProject = 'All projects';
$lang->doc->systemLibs['product'] = 'Product doc';
$lang->doc->systemLibs['project'] = 'Project doc';
$lang->doc->types['file'] = 'File';
$lang->doc->types['url'] = 'Link';
$lang->doc->types['text'] = 'Html';
$lang->doc->confirmDelete = "Are you sure to delete this doc?";
$lang->doc->confirmDeleteLib = " Are you sure to delete this doc library?";
$lang->doc->errorEditSystemDoc = "System doc library needn't edit";

View File

@@ -1,65 +1,65 @@
<?php
/**
* The doc module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: zh-cn.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
/* 字段列表。*/
$lang->doc->common = '文档视图';
$lang->doc->id = '文档编号';
$lang->doc->product = '所属产品';
$lang->doc->project = '所属项目';
$lang->doc->lib = '所属文档库';
$lang->doc->module = '所属分类';
$lang->doc->title = '文档标题';
$lang->doc->digest = '文档摘要';
$lang->doc->comment = '文档备注';
$lang->doc->type = '文档类型';
$lang->doc->content = '文档正文';
$lang->doc->keywords = '关键字';
$lang->doc->url = '文档URL';
$lang->doc->files = '附件';
$lang->doc->views = '查阅次数';
$lang->doc->addedBy = '由谁添加';
$lang->doc->addedDate = '添加时间';
$lang->doc->editedBy = '由谁编辑';
$lang->doc->editedDate = '编辑时间';
$lang->doc->moduleDoc = '按模块浏览';
$lang->doc->searchDoc = '搜索';
//$lang->doc->allDoc = '所有文档';
$lang->doc->moduleName = '模块名称';
$lang->doc->moduleOrder = '模块排序';
/* 方法列表。*/
$lang->doc->index = '首页';
$lang->doc->create = '创建文档';
$lang->doc->edit = '编辑文档';
$lang->doc->delete = '删除文档';
$lang->doc->browse = '文档列表';
$lang->doc->view = '文档详情';
$lang->doc->createLib = '创建文档库';
$lang->doc->editLib = '编辑文档库';
$lang->doc->deleteLib = '删除文档库';
$lang->doc->libName = '文档库名称';
/* 查询条件列表 */
$lang->doc->allProduct = '所有产品';
$lang->doc->allProject = '所有项目';
$lang->doc->systemLibs['product'] = '产品文档库';
$lang->doc->systemLibs['project'] = '项目文档库';
$lang->doc->types['file'] = '文件';
$lang->doc->types['url'] = '链接';
$lang->doc->types['text'] = '网页';
$lang->doc->confirmDelete = "您确定删除该文档吗?";
$lang->doc->confirmDeleteLib = " 您确定删除该文档库吗?";
$lang->doc->errorEditSystemDoc = "系统文档库无需修改。";
<?php
/**
* The doc module zh-cn file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: zh-cn.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
/* 字段列表。*/
$lang->doc->common = '文档视图';
$lang->doc->id = '文档编号';
$lang->doc->product = '所属产品';
$lang->doc->project = '所属项目';
$lang->doc->lib = '所属文档库';
$lang->doc->module = '所属分类';
$lang->doc->title = '文档标题';
$lang->doc->digest = '文档摘要';
$lang->doc->comment = '文档备注';
$lang->doc->type = '文档类型';
$lang->doc->content = '文档正文';
$lang->doc->keywords = '关键字';
$lang->doc->url = '文档URL';
$lang->doc->files = '附件';
$lang->doc->views = '查阅次数';
$lang->doc->addedBy = '由谁添加';
$lang->doc->addedDate = '添加时间';
$lang->doc->editedBy = '由谁编辑';
$lang->doc->editedDate = '编辑时间';
$lang->doc->moduleDoc = '按模块浏览';
$lang->doc->searchDoc = '搜索';
//$lang->doc->allDoc = '所有文档';
$lang->doc->moduleName = '模块名称';
$lang->doc->moduleOrder = '模块排序';
/* 方法列表。*/
$lang->doc->index = '首页';
$lang->doc->create = '创建文档';
$lang->doc->edit = '编辑文档';
$lang->doc->delete = '删除文档';
$lang->doc->browse = '文档列表';
$lang->doc->view = '文档详情';
$lang->doc->createLib = '创建文档库';
$lang->doc->editLib = '编辑文档库';
$lang->doc->deleteLib = '删除文档库';
$lang->doc->libName = '文档库名称';
/* 查询条件列表 */
$lang->doc->allProduct = '所有产品';
$lang->doc->allProject = '所有项目';
$lang->doc->systemLibs['product'] = '产品文档库';
$lang->doc->systemLibs['project'] = '项目文档库';
$lang->doc->types['file'] = '文件';
$lang->doc->types['url'] = '链接';
$lang->doc->types['text'] = '网页';
$lang->doc->confirmDelete = "您确定删除该文档吗?";
$lang->doc->confirmDeleteLib = " 您确定删除该文档库吗?";
$lang->doc->errorEditSystemDoc = "系统文档库无需修改。";

View File

@@ -1,65 +1,65 @@
<?php
/**
* The doc module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: zh-tw.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
/* 欄位列表。*/
$lang->doc->common = '文檔視圖';
$lang->doc->id = '文檔編號';
$lang->doc->product = '所屬產品';
$lang->doc->project = '所屬項目';
$lang->doc->lib = '所屬文檔庫';
$lang->doc->module = '所屬分類';
$lang->doc->title = '文檔標題';
$lang->doc->digest = '文檔摘要';
$lang->doc->comment = '文檔備註';
$lang->doc->type = '文檔類型';
$lang->doc->content = '文檔正文';
$lang->doc->keywords = '關鍵字';
$lang->doc->url = '文檔URL';
$lang->doc->files = '附件';
$lang->doc->views = '查閲次數';
$lang->doc->addedBy = '由誰添加';
$lang->doc->addedDate = '添加時間';
$lang->doc->editedBy = '由誰編輯';
$lang->doc->editedDate = '編輯時間';
$lang->doc->moduleDoc = '按模組瀏覽';
$lang->doc->searchDoc = '搜索';
//$lang->doc->allDoc = '所有文檔';
$lang->doc->moduleName = '模組名稱';
$lang->doc->moduleOrder = '模組排序';
/* 方法列表。*/
$lang->doc->index = '首頁';
$lang->doc->create = '創建文檔';
$lang->doc->edit = '編輯文檔';
$lang->doc->delete = '刪除文檔';
$lang->doc->browse = '文檔列表';
$lang->doc->view = '文檔詳情';
$lang->doc->createLib = '創建文檔庫';
$lang->doc->editLib = '編輯文檔庫';
$lang->doc->deleteLib = '刪除文檔庫';
$lang->doc->libName = '文檔庫名稱';
/* 查詢條件列表 */
$lang->doc->allProduct = '所有產品';
$lang->doc->allProject = '所有項目';
$lang->doc->systemLibs['product'] = '產品文檔庫';
$lang->doc->systemLibs['project'] = '項目文檔庫';
$lang->doc->types['file'] = '檔案';
$lang->doc->types['url'] = '連結';
$lang->doc->types['text'] = '網頁';
$lang->doc->confirmDelete = "您確定刪除該文檔嗎?";
$lang->doc->confirmDeleteLib = " 您確定刪除該文檔庫嗎?";
$lang->doc->errorEditSystemDoc = "系統文檔庫無需修改。";
<?php
/**
* The doc module zh-tw file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青島易軟天創網絡科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: zh-tw.php 824 2010-05-02 15:32:06Z wwccss $
* @link http://www.zentao.net
*/
/* 欄位列表。*/
$lang->doc->common = '文檔視圖';
$lang->doc->id = '文檔編號';
$lang->doc->product = '所屬產品';
$lang->doc->project = '所屬項目';
$lang->doc->lib = '所屬文檔庫';
$lang->doc->module = '所屬分類';
$lang->doc->title = '文檔標題';
$lang->doc->digest = '文檔摘要';
$lang->doc->comment = '文檔備註';
$lang->doc->type = '文檔類型';
$lang->doc->content = '文檔正文';
$lang->doc->keywords = '關鍵字';
$lang->doc->url = '文檔URL';
$lang->doc->files = '附件';
$lang->doc->views = '查閲次數';
$lang->doc->addedBy = '由誰添加';
$lang->doc->addedDate = '添加時間';
$lang->doc->editedBy = '由誰編輯';
$lang->doc->editedDate = '編輯時間';
$lang->doc->moduleDoc = '按模組瀏覽';
$lang->doc->searchDoc = '搜索';
//$lang->doc->allDoc = '所有文檔';
$lang->doc->moduleName = '模組名稱';
$lang->doc->moduleOrder = '模組排序';
/* 方法列表。*/
$lang->doc->index = '首頁';
$lang->doc->create = '創建文檔';
$lang->doc->edit = '編輯文檔';
$lang->doc->delete = '刪除文檔';
$lang->doc->browse = '文檔列表';
$lang->doc->view = '文檔詳情';
$lang->doc->createLib = '創建文檔庫';
$lang->doc->editLib = '編輯文檔庫';
$lang->doc->deleteLib = '刪除文檔庫';
$lang->doc->libName = '文檔庫名稱';
/* 查詢條件列表 */
$lang->doc->allProduct = '所有產品';
$lang->doc->allProject = '所有項目';
$lang->doc->systemLibs['product'] = '產品文檔庫';
$lang->doc->systemLibs['project'] = '項目文檔庫';
$lang->doc->types['file'] = '檔案';
$lang->doc->types['url'] = '連結';
$lang->doc->types['text'] = '網頁';
$lang->doc->confirmDelete = "您確定刪除該文檔嗎?";
$lang->doc->confirmDeleteLib = " 您確定刪除該文檔庫嗎?";
$lang->doc->errorEditSystemDoc = "系統文檔庫無需修改。";

View File

@@ -1,281 +1,281 @@
<?php
/**
* The model file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: model.php 881 2010-06-22 06:50:32Z chencongzhi520 $
* @link http://www.zentao.net
*/
?>
<?php
class docModel extends model
{
/**
* Set menus
*
* @param array $libs
* @param int $libID
* @param string $extra
* @access public
* @return void
*/
public function setMenu($libs, $libID, $extra = '')
{
$currentModule = $this->app->getModuleName();
$currentMethod = $this->app->getMethodName();
$selectHtml = html::select('libID', $libs, $libID, "onchange=\"switchDocLib(this.value, '$currentModule', '$currentMethod', '$extra');\"");
common::setMenuVars($this->lang->doc->menu, 'list', $selectHtml . $this->lang->arrow);
foreach($this->lang->doc->menu as $key => $menu)
{
if($key != 'list') common::setMenuVars($this->lang->doc->menu, $key, $libID);
}
}
/**
* Get library by id.
*
* @param int $libID
* @access public
* @return object
*/
public function getLibById($libID)
{
return $this->dao->findByID($libID)->from(TABLE_DOCLIB)->fetch();
}
/**
* Get libraries.
*
* @access public
* @return array
*/
public function getLibs()
{
$libs = $this->dao->select('id, name')->from(TABLE_DOCLIB)->where('deleted')->eq(0)->fetchPairs();
return $this->lang->doc->systemLibs + $libs;
}
/**
* Create a library.
*
* @access public
* @return void
*/
public function createLib()
{
$lib = fixer::input('post')->stripTags('name')->get();
$this->dao->insert(TABLE_DOCLIB)
->data($lib)
->autoCheck()
->batchCheck('name', 'notempty')
->check('name', 'unique')
->exec();
return $this->dao->lastInsertID();
}
/**
* Update a library.
*
* @param int $libID
* @access public
* @return void
*/
public function updateLib($libID)
{
$libID = (int)$libID;
$oldLib = $this->getLibById($libID);
$lib = fixer::input('post')->stripTags('name')->get();
$this->dao->update(TABLE_DOCLIB)
->data($lib)
->autoCheck()
->batchCheck('name', 'notempty')
->check('name', 'unique', "id != $libID")
->where('id')->eq($libID)
->exec();
if(!dao::isError()) return common::createChanges($oldLib, $lib);
}
/**
* Get docs.
*
* @param int|string $libID
* @param int $productID
* @param int $projectID
* @param int $module
* @param string $orderBy
* @param object $pager
* @access public
* @return void
*/
public function getDocs($libID, $productID, $projectID, $module, $orderBy, $pager)
{
$products = $this->loadModel('product')->getPairs();
$projects = $this->loadModel('project')->getPairs();
$keysOfProducts = array_keys($products);
$keysOfProjects = array_keys($projects);
$allKeysOfProjects = $keysOfProjects;
$allKeysOfProjects[] = 0;
return $this->dao->select('*')->from(TABLE_DOC)
->where('deleted')->eq(0)
->beginIF(is_numeric($libID))->andWhere('lib')->eq($libID)->fi()
->beginIF($libID == 'product')->andWhere('product')->in($keysOfProducts)->andWhere('project')->in($allKeysOfProjects)->fi()
->beginIF($libID == 'project')->andWhere('project')->in($keysOfProjects)->fi()
->beginIF($productID > 0)->andWhere('product')->eq($productID)->fi()
->beginIF($projectID > 0)->andWhere('project')->eq($projectID)->fi()
->beginIF((string)$projectID == 'int')->andWhere('project')->gt(0)->fi()
->beginIF($module)->andWhere('module')->in($module)->fi()
->orderBy($orderBy)
->page($pager)
->fetchAll();
}
/**
* Get doc info by id.
*
* @param int $docID
* @access public
* @return void
*/
public function getById($docID)
{
$doc = $this->dao->select('*')
->from(TABLE_DOC)
->where('id')->eq((int)$docID)
->fetch();
if(!$doc) return false;
$doc->content = $this->loadModel('file')->setImgSize($doc->content);
$doc->files = $this->loadModel('file')->getByObject('doc', $docID);
$doc->libName = '';
$doc->productName = '';
$doc->projectName = '';
$doc->moduleName = '';
if($doc->lib) $doc->libName = $this->dao->findByID($doc->lib)->from(TABLE_DOCLIB)->fetch('name');
if($doc->product) $doc->productName = $this->dao->findByID($doc->product)->from(TABLE_PRODUCT)->fetch('name');
if($doc->project) $doc->projectName = $this->dao->findByID($doc->project)->from(TABLE_PROJECT)->fetch('name');
if($doc->module) $doc->moduleName = $this->dao->findByID($doc->module)->from(TABLE_MODULE)->fetch('name');
return $doc;
}
/**
* Create a doc.
*
* @access public
* @return void
*/
public function create()
{
$now = helper::now();
$doc = fixer::input('post')
->add('addedBy', $this->app->user->account)
->add('addedDate', $now)
->setDefault('product, project, module', 0)
->specialChars('title, digest, keywords')
->encodeURL('url')
->cleanInt('product, project, module')
->remove('files, labels')
->get();
$condition = "lib = '$doc->lib' AND module = $doc->module";
$this->dao->insert(TABLE_DOC)
->data($doc)
->autoCheck()
->batchCheck($this->config->doc->create->requiredFields, 'notempty')
->check('title', 'unique', $condition)
->exec();
if(!dao::isError())
{
$docID = $this->dao->lastInsertID();
$this->loadModel('file')->saveUpload('doc', $docID);
return $docID;
}
return false;
}
/**
* Update a doc.
*
* @param int $docID
* @access public
* @return void
*/
public function update($docID)
{
$oldDoc = $this->getById($docID);
$now = helper::now();
$doc = fixer::input('post')
->cleanInt('module')
->setDefault('module', 0)
->specialChars('title, digest, keywords')
->encodeURL('url')
->remove('comment,files, labels')
->add('editedBy', $this->app->user->account)
->add('editedDate', $now)
->get();
$condition = "lib = '$doc->lib' AND module = $doc->module AND id != $docID";
$this->dao->update(TABLE_DOC)->data($doc)
->autoCheck()
->batchCheck($this->config->doc->edit->requiredFields, 'notempty')
->check('title', 'unique', $condition)
->where('id')->eq((int)$docID)
->exec();
if(!dao::isError()) return common::createChanges($oldDoc, $doc);
}
/**
* Get docs of a product.
*
* @param int $productID
* @access public
* @return array
*/
public function getProductDocs($productID)
{
return $this->dao->select('t1.*, t2.name as module')
->from(TABLE_DOC)->alias('t1')
->leftjoin(TABLE_MODULE)->alias('t2')->on('t1.module = t2.id')
->where('t1.product')->eq($productID)
->andWhere('t1.deleted')->eq(0)
->orderBy('t1.id_desc')
->fetchAll();
}
/**
* Get docs of a project.
*
* @param int $projectID
* @access public
* @return array
*/
public function getProjectDocs($projectID)
{
return $this->dao->findByProject($projectID)->from(TABLE_DOC)->andWhere('deleted')->eq(0)->orderBy('id_desc')->fetchAll();
}
/**
* Get pairs of product modules.
*
* @access public
* @return array
*/
public function getProductModulePairs()
{
return $this->dao->findByType('productdoc')->from(TABLE_MODULE)->fetchPairs('id', 'name');
}
/**
* Get pairs of project modules.
*
* @access public
* @return array
*/
public function getProjectModulePairs()
{
return $this->dao->findByType('projectdoc')->from(TABLE_MODULE)->andWhere('type')->eq('projectdoc')->fetchPairs('id', 'name');
}
}
<?php
/**
* The model file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package doc
* @version $Id: model.php 881 2010-06-22 06:50:32Z chencongzhi520 $
* @link http://www.zentao.net
*/
?>
<?php
class docModel extends model
{
/**
* Set menus
*
* @param array $libs
* @param int $libID
* @param string $extra
* @access public
* @return void
*/
public function setMenu($libs, $libID, $extra = '')
{
$currentModule = $this->app->getModuleName();
$currentMethod = $this->app->getMethodName();
$selectHtml = html::select('libID', $libs, $libID, "onchange=\"switchDocLib(this.value, '$currentModule', '$currentMethod', '$extra');\"");
common::setMenuVars($this->lang->doc->menu, 'list', $selectHtml . $this->lang->arrow);
foreach($this->lang->doc->menu as $key => $menu)
{
if($key != 'list') common::setMenuVars($this->lang->doc->menu, $key, $libID);
}
}
/**
* Get library by id.
*
* @param int $libID
* @access public
* @return object
*/
public function getLibById($libID)
{
return $this->dao->findByID($libID)->from(TABLE_DOCLIB)->fetch();
}
/**
* Get libraries.
*
* @access public
* @return array
*/
public function getLibs()
{
$libs = $this->dao->select('id, name')->from(TABLE_DOCLIB)->where('deleted')->eq(0)->fetchPairs();
return $this->lang->doc->systemLibs + $libs;
}
/**
* Create a library.
*
* @access public
* @return void
*/
public function createLib()
{
$lib = fixer::input('post')->stripTags('name')->get();
$this->dao->insert(TABLE_DOCLIB)
->data($lib)
->autoCheck()
->batchCheck('name', 'notempty')
->check('name', 'unique')
->exec();
return $this->dao->lastInsertID();
}
/**
* Update a library.
*
* @param int $libID
* @access public
* @return void
*/
public function updateLib($libID)
{
$libID = (int)$libID;
$oldLib = $this->getLibById($libID);
$lib = fixer::input('post')->stripTags('name')->get();
$this->dao->update(TABLE_DOCLIB)
->data($lib)
->autoCheck()
->batchCheck('name', 'notempty')
->check('name', 'unique', "id != $libID")
->where('id')->eq($libID)
->exec();
if(!dao::isError()) return common::createChanges($oldLib, $lib);
}
/**
* Get docs.
*
* @param int|string $libID
* @param int $productID
* @param int $projectID
* @param int $module
* @param string $orderBy
* @param object $pager
* @access public
* @return void
*/
public function getDocs($libID, $productID, $projectID, $module, $orderBy, $pager)
{
$products = $this->loadModel('product')->getPairs();
$projects = $this->loadModel('project')->getPairs();
$keysOfProducts = array_keys($products);
$keysOfProjects = array_keys($projects);
$allKeysOfProjects = $keysOfProjects;
$allKeysOfProjects[] = 0;
return $this->dao->select('*')->from(TABLE_DOC)
->where('deleted')->eq(0)
->beginIF(is_numeric($libID))->andWhere('lib')->eq($libID)->fi()
->beginIF($libID == 'product')->andWhere('product')->in($keysOfProducts)->andWhere('project')->in($allKeysOfProjects)->fi()
->beginIF($libID == 'project')->andWhere('project')->in($keysOfProjects)->fi()
->beginIF($productID > 0)->andWhere('product')->eq($productID)->fi()
->beginIF($projectID > 0)->andWhere('project')->eq($projectID)->fi()
->beginIF((string)$projectID == 'int')->andWhere('project')->gt(0)->fi()
->beginIF($module)->andWhere('module')->in($module)->fi()
->orderBy($orderBy)
->page($pager)
->fetchAll();
}
/**
* Get doc info by id.
*
* @param int $docID
* @access public
* @return void
*/
public function getById($docID)
{
$doc = $this->dao->select('*')
->from(TABLE_DOC)
->where('id')->eq((int)$docID)
->fetch();
if(!$doc) return false;
$doc->content = $this->loadModel('file')->setImgSize($doc->content);
$doc->files = $this->loadModel('file')->getByObject('doc', $docID);
$doc->libName = '';
$doc->productName = '';
$doc->projectName = '';
$doc->moduleName = '';
if($doc->lib) $doc->libName = $this->dao->findByID($doc->lib)->from(TABLE_DOCLIB)->fetch('name');
if($doc->product) $doc->productName = $this->dao->findByID($doc->product)->from(TABLE_PRODUCT)->fetch('name');
if($doc->project) $doc->projectName = $this->dao->findByID($doc->project)->from(TABLE_PROJECT)->fetch('name');
if($doc->module) $doc->moduleName = $this->dao->findByID($doc->module)->from(TABLE_MODULE)->fetch('name');
return $doc;
}
/**
* Create a doc.
*
* @access public
* @return void
*/
public function create()
{
$now = helper::now();
$doc = fixer::input('post')
->add('addedBy', $this->app->user->account)
->add('addedDate', $now)
->setDefault('product, project, module', 0)
->specialChars('title, digest, keywords')
->encodeURL('url')
->cleanInt('product, project, module')
->remove('files, labels')
->get();
$condition = "lib = '$doc->lib' AND module = $doc->module";
$this->dao->insert(TABLE_DOC)
->data($doc)
->autoCheck()
->batchCheck($this->config->doc->create->requiredFields, 'notempty')
->check('title', 'unique', $condition)
->exec();
if(!dao::isError())
{
$docID = $this->dao->lastInsertID();
$this->loadModel('file')->saveUpload('doc', $docID);
return $docID;
}
return false;
}
/**
* Update a doc.
*
* @param int $docID
* @access public
* @return void
*/
public function update($docID)
{
$oldDoc = $this->getById($docID);
$now = helper::now();
$doc = fixer::input('post')
->cleanInt('module')
->setDefault('module', 0)
->specialChars('title, digest, keywords')
->encodeURL('url')
->remove('comment,files, labels')
->add('editedBy', $this->app->user->account)
->add('editedDate', $now)
->get();
$condition = "lib = '$doc->lib' AND module = $doc->module AND id != $docID";
$this->dao->update(TABLE_DOC)->data($doc)
->autoCheck()
->batchCheck($this->config->doc->edit->requiredFields, 'notempty')
->check('title', 'unique', $condition)
->where('id')->eq((int)$docID)
->exec();
if(!dao::isError()) return common::createChanges($oldDoc, $doc);
}
/**
* Get docs of a product.
*
* @param int $productID
* @access public
* @return array
*/
public function getProductDocs($productID)
{
return $this->dao->select('t1.*, t2.name as module')
->from(TABLE_DOC)->alias('t1')
->leftjoin(TABLE_MODULE)->alias('t2')->on('t1.module = t2.id')
->where('t1.product')->eq($productID)
->andWhere('t1.deleted')->eq(0)
->orderBy('t1.id_desc')
->fetchAll();
}
/**
* Get docs of a project.
*
* @param int $projectID
* @access public
* @return array
*/
public function getProjectDocs($projectID)
{
return $this->dao->findByProject($projectID)->from(TABLE_DOC)->andWhere('deleted')->eq(0)->orderBy('id_desc')->fetchAll();
}
/**
* Get pairs of product modules.
*
* @access public
* @return array
*/
public function getProductModulePairs()
{
return $this->dao->findByType('productdoc')->from(TABLE_MODULE)->fetchPairs('id', 'name');
}
/**
* Get pairs of project modules.
*
* @access public
* @return array
*/
public function getProjectModulePairs()
{
return $this->dao->findByType('projectdoc')->from(TABLE_MODULE)->andWhere('type')->eq('projectdoc')->fetchPairs('id', 'name');
}
}

View File

@@ -1,82 +1,82 @@
<?php
/**
* The browse view file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package lib
* @version $Id: browse.html.php 958 2010-07-22 08:09:42Z wwccss $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<script language='Javascript'>
var browseType = '<?php echo $browseType;?>';
</script>
<div id='featurebar'>
<div class='f-left'>
<span id='bymoduleTab' onclick='browseByModule()'><a href='#'><?php echo $lang->doc->moduleDoc;?></a></span>
<span id='bysearchTab'><a href='#'><?php echo $lang->doc->searchDoc;?></a></span>
</div>
<div class='f-right'>
<?php common::printLink('doc', 'create', "libID=$libID&moduleID=$moduleID&productID=$productID&projectID=$projectID&from=doc", $lang->doc->create);?>
</div>
</div>
<div id='querybox' class='<?php if($browseType !='bysearch') echo 'hidden';?>'><?php echo $searchForm;?></div>
<table class='cont-lt3'>
<tr valign='top'>
<td class='side' id='treebox'>
<div class='box-title'><?php echo $libName;?></div>
<div class='box-content'>
<?php echo $moduleTree;?>
<div class='a-right'>
<?php common::printLink('tree', 'browse', "rootID=$libID&view=doc", $lang->tree->docManage);?>
</div>
</div>
</td>
<td class='divider'></td>
<td>
<table class='table-1 fixed colored tablesorter datatable'>
<thead>
<tr class='colhead'>
<?php $vars = "libID=$libID&module=$moduleID&productID=$productID&projectID=$projectID&browseType=$browseType&param=$param&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";?>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th><?php common::printOrderLink('title', $orderBy, $vars, $lang->doc->title);?></th>
<th class='w-100px'><?php common::printOrderLink('type', $orderBy, $vars, $lang->doc->type);?></th>
<th class='w-100px'><?php common::printOrderLink('addedBy', $orderBy, $vars, $lang->doc->addedBy);?></th>
<th class='w-120px'><?php common::printOrderLink('addedDate', $orderBy, $vars, $lang->doc->addedDate);?></th>
<th class='w-100px {sorter:false}'><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($docs as $key => $doc):?>
<?php
$viewLink = $this->createLink('doc', 'view', "docID=$doc->id");
$canView = common::hasPriv('doc', 'view');
?>
<tr class='a-center'>
<td><?php if($canView) echo html::a($viewLink, sprintf('%03d', $doc->id)); else printf('%03d', $doc->id);?></td>
<td class='a-left nobr'><nobr><?php echo html::a($viewLink, $doc->title);?></nobr></td>
<td><?php echo $lang->doc->types[$doc->type];?></td>
<td><?php isset($users[$doc->addedBy]) ? print($users[$doc->addedBy]) : print($doc->addedBy);?></td>
<td><?php echo date("m-d H:i", strtotime($doc->addedDate));?></td>
<td>
<?php
$vars = "doc={$doc->id}";
if(!common::printLink('doc', 'edit', $vars, $lang->edit)) echo $lang->edit;
if(!common::printLink('doc', 'delete', $vars, $lang->delete, 'hiddenwin')) echo $lang->delete;
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot><tr><td colspan='6'><?php $pager->show();?></td></tr></tfoot>
</table>
</td>
</tr>
</table>
<?php include './footer.html.php';?>
<?php
/**
* The browse view file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package lib
* @version $Id: browse.html.php 958 2010-07-22 08:09:42Z wwccss $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<?php include '../../common/view/colorize.html.php';?>
<script language='Javascript'>
var browseType = '<?php echo $browseType;?>';
</script>
<div id='featurebar'>
<div class='f-left'>
<span id='bymoduleTab' onclick='browseByModule()'><a href='#'><?php echo $lang->doc->moduleDoc;?></a></span>
<span id='bysearchTab'><a href='#'><?php echo $lang->doc->searchDoc;?></a></span>
</div>
<div class='f-right'>
<?php common::printLink('doc', 'create', "libID=$libID&moduleID=$moduleID&productID=$productID&projectID=$projectID&from=doc", $lang->doc->create);?>
</div>
</div>
<div id='querybox' class='<?php if($browseType !='bysearch') echo 'hidden';?>'><?php echo $searchForm;?></div>
<table class='cont-lt3'>
<tr valign='top'>
<td class='side' id='treebox'>
<div class='box-title'><?php echo $libName;?></div>
<div class='box-content'>
<?php echo $moduleTree;?>
<div class='a-right'>
<?php common::printLink('tree', 'browse', "rootID=$libID&view=doc", $lang->tree->docManage);?>
</div>
</div>
</td>
<td class='divider'></td>
<td>
<table class='table-1 fixed colored tablesorter datatable'>
<thead>
<tr class='colhead'>
<?php $vars = "libID=$libID&module=$moduleID&productID=$productID&projectID=$projectID&browseType=$browseType&param=$param&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";?>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th><?php common::printOrderLink('title', $orderBy, $vars, $lang->doc->title);?></th>
<th class='w-100px'><?php common::printOrderLink('type', $orderBy, $vars, $lang->doc->type);?></th>
<th class='w-100px'><?php common::printOrderLink('addedBy', $orderBy, $vars, $lang->doc->addedBy);?></th>
<th class='w-120px'><?php common::printOrderLink('addedDate', $orderBy, $vars, $lang->doc->addedDate);?></th>
<th class='w-100px {sorter:false}'><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($docs as $key => $doc):?>
<?php
$viewLink = $this->createLink('doc', 'view', "docID=$doc->id");
$canView = common::hasPriv('doc', 'view');
?>
<tr class='a-center'>
<td><?php if($canView) echo html::a($viewLink, sprintf('%03d', $doc->id)); else printf('%03d', $doc->id);?></td>
<td class='a-left nobr'><nobr><?php echo html::a($viewLink, $doc->title);?></nobr></td>
<td><?php echo $lang->doc->types[$doc->type];?></td>
<td><?php isset($users[$doc->addedBy]) ? print($users[$doc->addedBy]) : print($doc->addedBy);?></td>
<td><?php echo date("m-d H:i", strtotime($doc->addedDate));?></td>
<td>
<?php
$vars = "doc={$doc->id}";
if(!common::printLink('doc', 'edit', $vars, $lang->edit)) echo $lang->edit;
if(!common::printLink('doc', 'delete', $vars, $lang->delete, 'hiddenwin')) echo $lang->delete;
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot><tr><td colspan='6'><?php $pager->show();?></td></tr></tfoot>
</table>
</td>
</tr>
</table>
<?php include './footer.html.php';?>

View File

@@ -1,70 +1,70 @@
<?php
/**
* The create view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: create.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->doc->create;?></caption>
<?php if($libID == 'product'):?>
<tr>
<th class='rowhead'><?php echo $lang->doc->product;?></th>
<td><?php echo html::select('product', $products, $productID, "class='select-3'");?></td>
</tr>
<?php elseif($libID == 'project'):?>
<tr>
<th class='rowhead'><?php echo $lang->doc->project;?></th>
<td><?php echo html::select('project', $projects, $projectID, "class='select-3' onchange=loadProducts(this.value);");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->product;?></th>
<td><span id='productBox'><?php echo html::select('product', $products, '', "class='select-3'");?></span></td>
</tr>
<?php endif;?>
<tr>
<th class='rowhead'><?php echo $lang->doc->module;?></th>
<td><?php echo html::select('module', $moduleOptionMenu, $moduleID, "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->type;?></th>
<td><?php echo html::radio('type', $lang->doc->types, 'file', "onclick=setType(this.value)");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td><?php echo html::input('title', '', "class='text-1'");?></td>
</tr>
<tr id='urlBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->url;?></th>
<td><?php echo html::input('url', '', "class='text-1'");?></td>
</tr>
<tr id='contentBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->content;?></th>
<td><?php echo html::textarea('content', '', "class='area-1' style='width:90%; height:200px'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->keywords;?></th>
<td><?php echo html::input('keywords', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->digest;?></th>
<td><?php echo html::textarea('digest', '', "class='text-1' rows=3");?></td>
</tr>
<tr id='fileBox'>
<th class='rowhead'><?php echo $lang->doc->files;?></th>
<td><?php echo $this->fetch('file', 'buildform', 'fileCount=2');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton() . html::resetButton() . html::hidden('lib', $libID);?></td>
</tr>
</table>
</form>
<?php include './footer.html.php';?>
<?php
/**
* The create view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: create.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->doc->create;?></caption>
<?php if($libID == 'product'):?>
<tr>
<th class='rowhead'><?php echo $lang->doc->product;?></th>
<td><?php echo html::select('product', $products, $productID, "class='select-3'");?></td>
</tr>
<?php elseif($libID == 'project'):?>
<tr>
<th class='rowhead'><?php echo $lang->doc->project;?></th>
<td><?php echo html::select('project', $projects, $projectID, "class='select-3' onchange=loadProducts(this.value);");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->product;?></th>
<td><span id='productBox'><?php echo html::select('product', $products, '', "class='select-3'");?></span></td>
</tr>
<?php endif;?>
<tr>
<th class='rowhead'><?php echo $lang->doc->module;?></th>
<td><?php echo html::select('module', $moduleOptionMenu, $moduleID, "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->type;?></th>
<td><?php echo html::radio('type', $lang->doc->types, 'file', "onclick=setType(this.value)");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td><?php echo html::input('title', '', "class='text-1'");?></td>
</tr>
<tr id='urlBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->url;?></th>
<td><?php echo html::input('url', '', "class='text-1'");?></td>
</tr>
<tr id='contentBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->content;?></th>
<td><?php echo html::textarea('content', '', "class='area-1' style='width:90%; height:200px'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->keywords;?></th>
<td><?php echo html::input('keywords', '', "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->digest;?></th>
<td><?php echo html::textarea('digest', '', "class='text-1' rows=3");?></td>
</tr>
<tr id='fileBox'>
<th class='rowhead'><?php echo $lang->doc->files;?></th>
<td><?php echo $this->fetch('file', 'buildform', 'fileCount=2');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton() . html::resetButton() . html::hidden('lib', $libID);?></td>
</tr>
</table>
</form>
<?php include './footer.html.php';?>

View File

@@ -1,26 +1,26 @@
<?php
/**
* The createlib view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: createlib.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<form method='post'>
<table class='table-1'>
<caption><?php echo $lang->doc->createLib;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->libName;?></th>
<td><?php echo html::input('name', '', "class='text-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton();?></td>
</tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>
<?php
/**
* The createlib view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: createlib.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<form method='post'>
<table class='table-1'>
<caption><?php echo $lang->doc->createLib;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->libName;?></th>
<td><?php echo html::input('name', '', "class='text-1'");?></td>
</tr>
<tr>
<td colspan='2' class='a-center'><?php echo html::submitButton();?></td>
</tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>

View File

@@ -1,68 +1,68 @@
<?php
/**
* The edit view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: edit.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<script language='javascript'>
var type = '<?php echo $doc->type;?>';
$(document).ready(function()
{
setType(type);
});
</script>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->doc->edit;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->module;?></th>
<td><?php echo html::select('module', $moduleOptionMenu, $doc->module, "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->type;?></th>
<td><?php echo $lang->doc->types[$doc->type];?></td>
</tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td><?php echo html::input('title', $doc->title, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->keywords;?></th>
<td><?php echo html::input('keywords', $doc->keywords, "class='text-1'");?></td>
</tr>
<tr id='urlBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->url;?></th>
<td><?php echo html::input('url', urldecode($doc->url), "class='text-1'");?></td>
</tr>
<tr id='contentBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->content;?></th>
<td><?php echo html::textarea('content', htmlspecialchars($doc->content), "class='text-1' rows='8' style='width:90%; height:200px'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->digest;?></th>
<td><?php echo html::textarea('digest', $doc->digest, "class='text-1' rows=3");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->comment;?></th>
<td><?php echo html::textarea('comment','', "class='text-1' rows=3");?></td>
</tr>
<tr id='fileBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->files;?></th>
<td><?php echo $this->fetch('file', 'buildform', 'fileCount=2');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton() . html::resetButton() . html::hidden('lib', $libID);?>
<?php echo html::hidden('product', $doc->product) . html::hidden('project', $doc->project);?>
</td>
</tr>
</table>
</form>
<?php include './footer.html.php';?>
<?php
/**
* The edit view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: edit.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<script language='javascript'>
var type = '<?php echo $doc->type;?>';
$(document).ready(function()
{
setType(type);
});
</script>
<form method='post' enctype='multipart/form-data' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->doc->edit;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->module;?></th>
<td><?php echo html::select('module', $moduleOptionMenu, $doc->module, "class='select-3'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->type;?></th>
<td><?php echo $lang->doc->types[$doc->type];?></td>
</tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td><?php echo html::input('title', $doc->title, "class='text-1'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->keywords;?></th>
<td><?php echo html::input('keywords', $doc->keywords, "class='text-1'");?></td>
</tr>
<tr id='urlBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->url;?></th>
<td><?php echo html::input('url', urldecode($doc->url), "class='text-1'");?></td>
</tr>
<tr id='contentBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->content;?></th>
<td><?php echo html::textarea('content', htmlspecialchars($doc->content), "class='text-1' rows='8' style='width:90%; height:200px'");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->digest;?></th>
<td><?php echo html::textarea('digest', $doc->digest, "class='text-1' rows=3");?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->comment;?></th>
<td><?php echo html::textarea('comment','', "class='text-1' rows=3");?></td>
</tr>
<tr id='fileBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->files;?></th>
<td><?php echo $this->fetch('file', 'buildform', 'fileCount=2');?></td>
</tr>
<tr>
<td colspan='2' class='a-center'>
<?php echo html::submitButton() . html::resetButton() . html::hidden('lib', $libID);?>
<?php echo html::hidden('product', $doc->product) . html::hidden('project', $doc->project);?>
</td>
</tr>
</table>
</form>
<?php include './footer.html.php';?>

View File

@@ -1,28 +1,28 @@
<?php
/**
* The editlib file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: editlib.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php if($libID == 'product' or $libID == 'project'):?>
<p class='a-center strong mt-10px'><?php echo $lang->doc->errorEditSystemDoc;?></p>
<?php else:?>
<form method='post'>
<table class='table-1'>
<caption><?php echo $lang->doc->editLib;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->libName;?></th>
<td><?php echo html::input('name', $libName, "class='text-1'");?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
</table>
</form>
<?php endif;?>
<?php include '../../common/view/footer.lite.html.php';?>
<?php
/**
* The editlib file of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: editlib.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php if($libID == 'product' or $libID == 'project'):?>
<p class='a-center strong mt-10px'><?php echo $lang->doc->errorEditSystemDoc;?></p>
<?php else:?>
<form method='post'>
<table class='table-1'>
<caption><?php echo $lang->doc->editLib;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->libName;?></th>
<td><?php echo html::input('name', $libName, "class='text-1'");?></td>
</tr>
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
</table>
</form>
<?php endif;?>
<?php include '../../common/view/footer.lite.html.php';?>

View File

@@ -1,75 +1,75 @@
<?php
/**
* The view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: view.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<script language='javascript'>
var type = '<?php echo $doc->type;?>';
$(document).ready(function()
{
setType(type);
});
</script>
<table class='table-1'>
<caption><?php echo $doc->title . $lang->colon . $lang->doc->view;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td <?php if($doc->deleted) echo "class='deleted'";?>><?php echo $doc->title;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->lib;?></th>
<td><?php echo $lib;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->module;?></th>
<td><?php echo $doc->moduleName;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->type;?></th>
<td><?php echo $lang->doc->types[$doc->type];?></td>
</tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td><?php echo $doc->title;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->keywords;?></th>
<td><?php echo $doc->keywords;?></td>
</tr>
<tr id='urlBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->url;?></th>
<td><?php echo html::a(urldecode($doc->url), '', '_blank');?></td>
</tr>
<tr id='contentBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->content;?></th>
<td class='content'><?php echo $doc->content;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->digest;?></th>
<td><?php echo nl2br($doc->digest);?></td>
</tr>
<tr id='fileBox' class='hidden'>
<th class='rowhead'><?php echo $lang->files;?></th>
<td><?php echo $this->fetch('file', 'printFiles', array('files' => $doc->files, 'fieldset' => 'false'));?></td>
</tr>
</table>
<div class='a-center f-16px strong'>
<?php
$browseLink = $this->session->docList ? $this->session->docList : inlink('browse');
if(!$doc->deleted)
{
common::printLink('doc', 'edit', "docID=$doc->id", $lang->edit);
common::printLink('doc', 'delete', "docID=$doc->id", $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
<?php include '../../common/view/action.html.php';?>
<?php include './footer.html.php';?>
<?php
/**
* The view of doc module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Jia Fu <fujia@cnezsoft.com>
* @package doc
* @version $Id: view.html.php 975 2010-07-29 03:30:25Z jajacn@126.com $
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<script language='javascript'>
var type = '<?php echo $doc->type;?>';
$(document).ready(function()
{
setType(type);
});
</script>
<table class='table-1'>
<caption><?php echo $doc->title . $lang->colon . $lang->doc->view;?></caption>
<tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td <?php if($doc->deleted) echo "class='deleted'";?>><?php echo $doc->title;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->lib;?></th>
<td><?php echo $lib;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->module;?></th>
<td><?php echo $doc->moduleName;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->type;?></th>
<td><?php echo $lang->doc->types[$doc->type];?></td>
</tr>
<th class='rowhead'><?php echo $lang->doc->title;?></th>
<td><?php echo $doc->title;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->keywords;?></th>
<td><?php echo $doc->keywords;?></td>
</tr>
<tr id='urlBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->url;?></th>
<td><?php echo html::a(urldecode($doc->url), '', '_blank');?></td>
</tr>
<tr id='contentBox' class='hidden'>
<th class='rowhead'><?php echo $lang->doc->content;?></th>
<td class='content'><?php echo $doc->content;?></td>
</tr>
<tr>
<th class='rowhead'><?php echo $lang->doc->digest;?></th>
<td><?php echo nl2br($doc->digest);?></td>
</tr>
<tr id='fileBox' class='hidden'>
<th class='rowhead'><?php echo $lang->files;?></th>
<td><?php echo $this->fetch('file', 'printFiles', array('files' => $doc->files, 'fieldset' => 'false'));?></td>
</tr>
</table>
<div class='a-center f-16px strong'>
<?php
$browseLink = $this->session->docList ? $this->session->docList : inlink('browse');
if(!$doc->deleted)
{
common::printLink('doc', 'edit', "docID=$doc->id", $lang->edit);
common::printLink('doc', 'delete', "docID=$doc->id", $lang->delete, 'hiddenwin');
}
echo html::a($browseLink, $lang->goback);
?>
</div>
<?php include '../../common/view/action.html.php';?>
<?php include './footer.html.php';?>

View File

@@ -1,164 +1,164 @@
<?php
/**
* The control file of editor of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
class editor extends control
{
/**
* Show module files and edit them.
*
* @access public
* @return void
*/
public function index()
{
$this->view->moduleList = $this->editor->getModules();
$this->display();
}
/**
* Show this module of files.
*
* @param string $moduleDir
* @access public
* @return void
*/
public function extend($moduleDir = '')
{
$moduleFiles = $this->editor->getModuleFiles($moduleDir);
$this->view->module = $moduleDir;
$this->view->tree = $this->editor->printTree($moduleFiles);
$this->display();
}
/**
* Edit extend.
*
* @param string $filePath
* @param string $action
* @param string $isExtends
* @access public
* @return void
*/
public function edit($filePath = '', $action = '', $isExtends = '')
{
$this->view->safeFilePath = $filePath;
$fileContent = '';
if($filePath)
{
$filePath = helper::safe64Decode($filePath);
if($action == 'extendOther' and file_exists($filePath))
{
$this->view->showContent = htmlspecialchars(file_get_contents($filePath));
}
if($action == 'edit' or $action == 'override')
{
if(file_exists($filePath))
{
$fileContent = file_get_contents($filePath);
if($action == 'override')
{
$fileContent = str_replace('../../', '../../../', $fileContent);
$fileContent = str_replace(array('\'./', '"./'), array('\'../../view/', '"../../view'), $fileContent);
}
}
else
{
$filePath = '';
}
}
elseif($action == 'extendModel')
{
$fileContent = $this->editor->extendModel($filePath);
}
elseif($action == 'extendControl')
{
$okUrl = $this->editor->getExtendLink($filePath, 'extendControl', 'yes');
$cancelUrl = $this->editor->getExtendLink($filePath, 'extendControl', 'no');
if(!$isExtends) die(js::confirm($this->lang->editor->extendConfirm, $okUrl, $cancelUrl));
$fileContent = $this->editor->extendControl($filePath, $isExtends);
}
elseif($action == 'newPage')
{
$fileContent = $this->editor->newControl($filePath);
}
elseif(strrpos(basename($filePath), '.php') !== false and empty($fileContent))
{
$fileContent = "<?php\n";
}
}
$this->view->fileContent = $fileContent;
$this->view->filePath = $filePath;
$this->view->action = $action;
$this->display();
}
/**
* Set Page name.
*
* @param string $filePath
* @access public
* @return void
*/
public function newPage($filePath)
{
$filePath = helper::safe64Decode($filePath);
if($_POST)
{
$saveFilePath = $this->editor->getSavePath($filePath, 'newMethod');
$extendLink = $this->editor->getExtendLink($saveFilePath, 'newPage');
if(file_exists($saveFilePath) and !$this->post->override) die(js::confirm($this->lang->editor->repeatPage, $extendLink, '', 'parent'));
die(js::locate($extendLink, 'parent'));
}
$this->view->filePath = $filePath;
$this->display();
}
/**
* Save file to extension.
*
* @param string $filePath
* @access public
* @return void
*/
public function save($filePath = '', $action = '')
{
if($filePath and $_POST)
{
$filePath = helper::safe64Decode($filePath);
if($action != 'edit' and $action != 'newPage') $filePath = $this->editor->getSavePath($filePath, $action);
if($action != 'edit' and $action != 'newPage' and file_exists($filePath) and !$this->post->override) die(js::error($this->lang->editor->repeatFile));
$this->editor->save($filePath);
echo js::reload('parent.parent.extendWin');
die(js::locate(inlink('edit', "filePath=" . helper::safe64Encode($filePath) . "&action=edit"), 'parent'));
}
}
/**
* Delete extension file.
*
* @param string $filePath
* @param string $confirm
* @access public
* @return void
*/
public function delete($filePath = '', $confirm = 'no')
{
if($confirm == 'no')
{
die(js::confirm($this->lang->editor->deleteConfirm, inlink('delete', "filePath=$filePath&confirm=yes")));
}
$filePath = helper::safe64Decode($filePath);
if(file_exists($filePath) and unlink($filePath)) die(js::reload('parent'));
die(js::alert($this->lang->editor->notDelete));
}
}
<?php
/**
* The control file of editor of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
class editor extends control
{
/**
* Show module files and edit them.
*
* @access public
* @return void
*/
public function index()
{
$this->view->moduleList = $this->editor->getModules();
$this->display();
}
/**
* Show this module of files.
*
* @param string $moduleDir
* @access public
* @return void
*/
public function extend($moduleDir = '')
{
$moduleFiles = $this->editor->getModuleFiles($moduleDir);
$this->view->module = $moduleDir;
$this->view->tree = $this->editor->printTree($moduleFiles);
$this->display();
}
/**
* Edit extend.
*
* @param string $filePath
* @param string $action
* @param string $isExtends
* @access public
* @return void
*/
public function edit($filePath = '', $action = '', $isExtends = '')
{
$this->view->safeFilePath = $filePath;
$fileContent = '';
if($filePath)
{
$filePath = helper::safe64Decode($filePath);
if($action == 'extendOther' and file_exists($filePath))
{
$this->view->showContent = htmlspecialchars(file_get_contents($filePath));
}
if($action == 'edit' or $action == 'override')
{
if(file_exists($filePath))
{
$fileContent = file_get_contents($filePath);
if($action == 'override')
{
$fileContent = str_replace('../../', '../../../', $fileContent);
$fileContent = str_replace(array('\'./', '"./'), array('\'../../view/', '"../../view'), $fileContent);
}
}
else
{
$filePath = '';
}
}
elseif($action == 'extendModel')
{
$fileContent = $this->editor->extendModel($filePath);
}
elseif($action == 'extendControl')
{
$okUrl = $this->editor->getExtendLink($filePath, 'extendControl', 'yes');
$cancelUrl = $this->editor->getExtendLink($filePath, 'extendControl', 'no');
if(!$isExtends) die(js::confirm($this->lang->editor->extendConfirm, $okUrl, $cancelUrl));
$fileContent = $this->editor->extendControl($filePath, $isExtends);
}
elseif($action == 'newPage')
{
$fileContent = $this->editor->newControl($filePath);
}
elseif(strrpos(basename($filePath), '.php') !== false and empty($fileContent))
{
$fileContent = "<?php\n";
}
}
$this->view->fileContent = $fileContent;
$this->view->filePath = $filePath;
$this->view->action = $action;
$this->display();
}
/**
* Set Page name.
*
* @param string $filePath
* @access public
* @return void
*/
public function newPage($filePath)
{
$filePath = helper::safe64Decode($filePath);
if($_POST)
{
$saveFilePath = $this->editor->getSavePath($filePath, 'newMethod');
$extendLink = $this->editor->getExtendLink($saveFilePath, 'newPage');
if(file_exists($saveFilePath) and !$this->post->override) die(js::confirm($this->lang->editor->repeatPage, $extendLink, '', 'parent'));
die(js::locate($extendLink, 'parent'));
}
$this->view->filePath = $filePath;
$this->display();
}
/**
* Save file to extension.
*
* @param string $filePath
* @access public
* @return void
*/
public function save($filePath = '', $action = '')
{
if($filePath and $_POST)
{
$filePath = helper::safe64Decode($filePath);
if($action != 'edit' and $action != 'newPage') $filePath = $this->editor->getSavePath($filePath, $action);
if($action != 'edit' and $action != 'newPage' and file_exists($filePath) and !$this->post->override) die(js::error($this->lang->editor->repeatFile));
$this->editor->save($filePath);
echo js::reload('parent.parent.extendWin');
die(js::locate(inlink('edit', "filePath=" . helper::safe64Encode($filePath) . "&action=edit"), 'parent'));
}
}
/**
* Delete extension file.
*
* @param string $filePath
* @param string $confirm
* @access public
* @return void
*/
public function delete($filePath = '', $confirm = 'no')
{
if($confirm == 'no')
{
die(js::confirm($this->lang->editor->deleteConfirm, inlink('delete', "filePath=$filePath&confirm=yes")));
}
$filePath = helper::safe64Decode($filePath);
if(file_exists($filePath) and unlink($filePath)) die(js::reload('parent'));
die(js::alert($this->lang->editor->notDelete));
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,70 +1,70 @@
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/colorbox.html.php';?>
<form method='post' target='hiddenwin' action='<?php echo inlink('save', "filePath=$safeFilePath&action=$action")?>'>
<table class='table-1'>
<?php if($filePath):?>
<caption>
<?php echo "<span class='strong'>{$lang->editor->filePath}</span>"?>
<?php echo $filePath?>
</caption>
<?php endif?>
<?php if(!empty($showContent)):?>
<tr>
<td>
<?php echo "<span class='strong'>" . $lang->editor->sourceFile . '</span>'?><br />
<textarea id='showContent' class="w-p100"> <?php echo $showContent?></textarea>
</td>
</tr>
<?php endif?>
<tr>
<td>
<?php echo html::textarea('fileContent', $fileContent, "class='w-p100'")?>
</td>
</tr>
<tr>
<td>
<?php if($action and $action != 'edit' and $action != 'newPage' and $action != 'override' and $action != 'extendControl'):?>
<?php echo "<span class='strong'>" . $lang->editor->fileName . '</span>'?>
<span>
<?php
echo html::input('fileName', '', "class=text-4");
if($action == 'newHook')
{
echo $lang->editor->exampleHook;
}
elseif($action and $action == 'extendOther' and strpos(basename($filePath), '.js') !== false or $action == 'newJS')
{
echo $lang->editor->exampleJs;
}
elseif($action and $action == 'extendOther' and strpos(basename($filePath), '.css') !== false or $action == 'newCSS')
{
echo $lang->editor->exampleCss;
}
else
{
echo $lang->editor->examplePHP;
}
?>
</span>
<?php endif;?>
<?php if($action and $action != 'edit' and $action != 'newPage'):?>
<span class='strong'><input type='checkbox' name='override' id='override' /> <?php echo $lang->editor->isOverride?></span>
<?php endif;?>
</td>
</tr>
<tr><td align='center'><?php echo html::submitButton()?><td></tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/colorbox.html.php';?>
<form method='post' target='hiddenwin' action='<?php echo inlink('save', "filePath=$safeFilePath&action=$action")?>'>
<table class='table-1'>
<?php if($filePath):?>
<caption>
<?php echo "<span class='strong'>{$lang->editor->filePath}</span>"?>
<?php echo $filePath?>
</caption>
<?php endif?>
<?php if(!empty($showContent)):?>
<tr>
<td>
<?php echo "<span class='strong'>" . $lang->editor->sourceFile . '</span>'?><br />
<textarea id='showContent' class="w-p100"> <?php echo $showContent?></textarea>
</td>
</tr>
<?php endif?>
<tr>
<td>
<?php echo html::textarea('fileContent', $fileContent, "class='w-p100'")?>
</td>
</tr>
<tr>
<td>
<?php if($action and $action != 'edit' and $action != 'newPage' and $action != 'override' and $action != 'extendControl'):?>
<?php echo "<span class='strong'>" . $lang->editor->fileName . '</span>'?>
<span>
<?php
echo html::input('fileName', '', "class=text-4");
if($action == 'newHook')
{
echo $lang->editor->exampleHook;
}
elseif($action and $action == 'extendOther' and strpos(basename($filePath), '.js') !== false or $action == 'newJS')
{
echo $lang->editor->exampleJs;
}
elseif($action and $action == 'extendOther' and strpos(basename($filePath), '.css') !== false or $action == 'newCSS')
{
echo $lang->editor->exampleCss;
}
else
{
echo $lang->editor->examplePHP;
}
?>
</span>
<?php endif;?>
<?php if($action and $action != 'edit' and $action != 'newPage'):?>
<span class='strong'><input type='checkbox' name='override' id='override' /> <?php echo $lang->editor->isOverride?></span>
<?php endif;?>
</td>
</tr>
<tr><td align='center'><?php echo html::submitButton()?><td></tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>

View File

@@ -1,29 +1,29 @@
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<table class='table-1'>
<caption><?php echo isset($lang->editor->modules[$module])? $lang->editor->modules[$module] : $module;?></caption>
<tr>
<td valign='top'><?php echo $tree?></td>
</tr>
</table>
<script type='text/javascript'>
$(function()
{
$("#extendTree").treeview();
});
</script>
<iframe frameborder='0' name='hiddenwin' id='hiddenwin' scrolling='no' class='hidden'></iframe>
<body>
</html>
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<?php include '../../common/view/treeview.html.php';?>
<table class='table-1'>
<caption><?php echo isset($lang->editor->modules[$module])? $lang->editor->modules[$module] : $module;?></caption>
<tr>
<td valign='top'><?php echo $tree?></td>
</tr>
</table>
<script type='text/javascript'>
$(function()
{
$("#extendTree").treeview();
});
</script>
<iframe frameborder='0' name='hiddenwin' id='hiddenwin' scrolling='no' class='hidden'></iframe>
<body>
</html>

View File

@@ -1,24 +1,24 @@
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<table class='table-1 bd-none'>
<tr valign='top'>
<td width='160'>
<div class='box-title'><?php echo $lang->editor->moduleList?></div>
<div class='box-content'><?php echo $moduleList?></div>
</td>
<td width='300'><iframe frameborder='0' name='extendWin' id='extendWin' width='100%'></iframe></td>
<td><iframe frameborder='0' name='editWin' id='editWin' width='100%'></iframe></td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<table class='table-1 bd-none'>
<tr valign='top'>
<td width='160'>
<div class='box-title'><?php echo $lang->editor->moduleList?></div>
<div class='box-content'><?php echo $moduleList?></div>
</td>
<td width='300'><iframe frameborder='0' name='extendWin' id='extendWin' width='100%'></iframe></td>
<td><iframe frameborder='0' name='editWin' id='editWin' width='100%'></iframe></td>
</tr>
</table>
<?php include '../../common/view/footer.html.php';?>

View File

@@ -1,33 +1,33 @@
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 <20><EFBFBD><E0B5BA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><ECB4B4><EFBFBD><EFBFBD><EFBFBD>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD>޹<EFBFBD>˾ (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->editor->newPage?></caption>
<tr>
<th class='w-70px'><?php echo $lang->editor->filePath?></th>
<td><?php echo $filePath?></td>
</tr>
<tr>
<th><?php echo $lang->editor->pageName?></th>
<td>
<?php
echo html::input('fileName', '', "class=text-5");
echo $lang->editor->examplePHP;
?>
</td>
</tr>
<tr><td colspan='2' align='center'><?php echo html::submitButton()?><td></tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>
<?php
/**
* The editor view file of dir module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 <20><EFBFBD><E0B5BA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><ECB4B4><EFBFBD><EFBFBD><EFBFBD>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD>޹<EFBFBD>˾ (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Yidong Wang <yidong@cnezsoft.com>
* @package editor
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.lite.html.php';?>
<form method='post' target='hiddenwin'>
<table class='table-1'>
<caption><?php echo $lang->editor->newPage?></caption>
<tr>
<th class='w-70px'><?php echo $lang->editor->filePath?></th>
<td><?php echo $filePath?></td>
</tr>
<tr>
<th><?php echo $lang->editor->pageName?></th>
<td>
<?php
echo html::input('fileName', '', "class=text-5");
echo $lang->editor->examplePHP;
?>
</td>
</tr>
<tr><td colspan='2' align='center'><?php echo html::submitButton()?><td></tr>
</table>
</form>
<?php include '../../common/view/footer.lite.html.php';?>

View File

@@ -1,353 +1,353 @@
<?php
/**
* The control file of extension module of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package extension
* @version $Id$
* @link http://www.zentao.net
*/
class extension extends control
{
/**
* Browse extensions.
*
* @param string $status
* @access public
* @return void
*/
public function browse($status = 'installed')
{
$extensions = $this->extension->getLocalExtensions($status);
$versions = array();
if($extensions and $status == 'installed')
{
/* Get latest release from remote. */
$extCodes = helper::safe64Encode(join(',', array_keys($extensions)));
$results = $this->extension->getExtensionsByAPI('bycode', $extCodes, $recTotal = 0, $recPerPage = 1000, $pageID = 1);
if(isset($results->extensions))
{
$remoteReleases = $results->extensions;
foreach($remoteReleases as $release)
{
if(!isset($extensions[$release->code])) continue;
$extension = $extensions[$release->code];
if($extension->version != $release->latestRelease->releaseVersion and $this->extension->checkVersion($release->latestRelease->zentaoVersion))
{
$extension->upgradeLink = inlink('upgrade', "extension=$release->code&downLink=" . helper::safe64Encode($release->downLink) . "&md5=$release->md5&type=$release->type");
}
}
}
}
$this->view->header->title = $this->lang->extension->browse;
$this->view->position[] = $this->lang->extension->browse;
$this->view->tab = $status;
$this->view->extensions = $extensions;
$this->view->versions = $versions;
$this->display();
}
/**
* Obtain extensions from the community.
*
* @param string $type
* @param string $param
* @access public
* @return void
*/
public function obtain($type = 'byUpdatedTime', $param = '', $recTotal = 0, $recPerPage = 10, $pageID = 1)
{
/* Init vars. */
$type = strtolower($type);
$moduleID = $type == 'bymodule' ? (int)$param : 0;
$extensions = array();
$pager = null;
/* Set the key. */
if($type == 'bysearch') $param = helper::safe64Encode($this->post->key);
/* Get results from the api. */
$results = $this->extension->getExtensionsByAPI($type, $param, $recTotal, $recPerPage, $pageID);
if($results)
{
$this->app->loadClass('pager', $static = true);
$pager = new pager($results->dbPager->recTotal, $results->dbPager->recPerPage, $results->dbPager->pageID);
$extensions = $results->extensions;
}
$this->view->moduleTree = $this->extension->getModulesByAPI();
$this->view->extensions = $extensions;
$this->view->installeds = $this->extension->getLocalExtensions('installed');
$this->view->pager = $pager;
$this->view->tab = 'obtain';
$this->view->type = $type;
$this->view->moduleID = $moduleID;
$this->display();
}
/**
* Install a extension
*
* @param string $extension
* @param string $downLink
* @param string $md5
* @param string $type
* @param string $overridePackage
* @param string $ignoreCompatible
* @param string $overrideFile
* @param string $agreeLicense
* @access public
* @return void
*/
public function install($extension, $downLink = '', $md5 = '', $type = '', $overridePackage = 'no', $ignoreCompatible = 'no', $overrideFile = 'no', $agreeLicense = 'no')
{
$this->view->error = '';
$this->view->header->title = $this->lang->extension->install . $this->lang->colon . $extension;
/* Get the package file name. */
$packageFile = $this->extension->getPackageFile($extension);
if($downLink)
{
/* Checking download path. */
$return = $this->extension->checkDownloadPath();
if($return->result != 'ok')
{
$this->view->error = $return->error;
die($this->display());
}
/* Check file exists or not. */
if(file_exists($packageFile) and $overridePackage == 'no')
{
$overrideLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=yes&ignoreCompatible=$ignoreCompatible&overrideFile=$overrideFile&agreeLicense=$agreeLicense");
$this->view->error = sprintf($this->lang->extension->errorPackageFileExists, $packageFile, $overrideLink);
die($this->display());
}
/* Download the package file. */
$this->extension->downloadPackage($extension, helper::safe64Decode($downLink));
if(!file_exists($packageFile))
{
$this->view->error = sprintf($this->lang->extension->errorDownloadFailed, $packageFile);
die($this->display());
}
elseif($md5 != '' and md5_file($packageFile) != $md5)
{
unlink($packageFile);
$this->view->error = sprintf($this->lang->extension->errorMd5Checking, $packageFile);
die($this->display());
}
}
/* Check the package file exists or not. */
if(!file_exists($packageFile))
{
$this->view->error = sprintf($this->lang->extension->errorPackageNotFound, $packageFile);
die($this->display());
}
/* Checking the extension pathes. */
$return = $this->extension->checkExtensionPathes($extension);
if($this->session->dirs2Created == false) $this->session->set('dirs2Created', $return->dirs2Created); // Save the dirs to be created.
if($return->result != 'ok')
{
$this->view->error = $return->errors;
die($this->display());
}
/* Extract the package. */
$return = $this->extension->extractPackage($extension);
if($return->result != 'ok')
{
$this->view->error = sprintf($this->lang->extension->errorExtracted, $packageFile, $return->error);
die($this->display());
}
/* Check version comptiable. */
$zentaoVersion = $this->extension->getZentaoVersion($extension);
if(!$this->extension->checkVersion($zentaoVersion) and $ignoreCompatible == 'no')
{
$ignoreLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=$overridePackage&ignoreCompatible=yes");
$returnLink = inlink('obtain');
$this->view->error = sprintf($this->lang->extension->errorCheckIncompatible, $ignoreLink, $returnLink);
die($this->display());
}
/* Check files in the package conflicts with exists files or not. */
if($overrideFile == 'no')
{
$return = $this->extension->checkFile($extension);
if($return->result != 'ok')
{
$overrideLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=$overridePackage&ignoreCompatible=$ignoreCompatible&overrideFile=yes");
$returnLink = inlink('obtain');
$this->view->error = sprintf($this->lang->extension->errorFileConflicted, $return->error, $overrideLink, $returnLink);
die($this->display());
}
}
/* Print the license form. */
if($agreeLicense == 'no')
{
$extensionInfo = $this->extension->getInfoFromPackage($extension);
$license = $this->extension->processLicense($extensionInfo->license);
$agreeLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=$overridePackage&ignoreCompatible=$ignoreCompatible&overrideFile=$overrideFile&agreeLicense=yes");
$this->view->license = $license;
$this->view->author = $extensionInfo->author;
$this->view->agreeLink = $agreeLink;
die($this->display());
}
/* The preInstall hook file. */
if($preInstallHook = $this->extension->getHookFile($extension, 'preinstall')) include $preInstallHook;
/* Save to database. */
$this->extension->saveExtension($extension, $type);
/* Copy files to target directory. */
$this->view->files = $this->extension->copyPackageFiles($extension);
/* Judge need execute db install or not. */
$data->status = 'installed';
$data->dirs = $this->session->dirs2Created;
$data->files = $this->view->files;
$data->installedTime = helper::now();
$this->session->set('dirs2Created', array()); // clean the session.
/* Execute the install.sql. */
if($this->extension->needExecuteDB($extension, 'install'))
{
$return = $this->extension->executeDB($extension, 'install');
if($return->result != 'ok')
{
$this->view->error = sprintf($this->lang->extension->errorInstallDB, $return->error);
die($this->display());
}
}
/* Update status, dirs, files and installed time. */
$this->extension->updateExtension($extension, $data);
$this->view->downloadedPackage = !empty($downLink);
/* The postInstall hook file. */
if($postInstallHook = $this->extension->getHookFile($extension, 'postinstall')) include $postInstallHook;
$this->display();
}
/**
* Uninstall an extension.
*
* @param string $extension
* @access public
* @return void
*/
public function uninstall($extension)
{
if($preUninstallHook = $this->extension->getHookFile($extension, 'preuninstall')) include $preUninstallHook;
$this->extension->executeDB($extension, 'uninstall');
$this->extension->updateExtension($extension, array('status' => 'available'));
$this->view->removeCommands = $this->extension->removePackage($extension);
$this->view->header->title = $this->lang->extension->uninstallFinished;
if($postUninstallHook = $this->extension->getHookFile($extension, 'postuninstall')) include $postUninstallHook;
$this->display();
}
/**
* Activate an extension;
*
* @param string $extension
* @access public
* @return void
*/
public function activate($extension, $ignore = 'no')
{
if($ignore == 'no')
{
$return = $this->extension->checkFile($extension);
if($return->result != 'ok')
{
$ignoreLink = inlink('activate', "extension=$extension&ignore=yes");
$resetLink = inlink('browse', 'type=deactivated');
$this->view->error = sprintf($this->lang->extension->errorFileConflicted, $return->error, $ignoreLink, $resetLink);
die($this->display());
}
}
$this->extension->copyPackageFiles($extension);
$this->extension->updateExtension($extension, array('status' => 'installed'));
$this->view->header->title = $this->lang->extension->activateFinished;
$this->display();
}
/**
* Deactivate an extension
*
* @param string $extension
* @access public
* @return void
*/
public function deactivate($extension)
{
$this->extension->updateExtension($extension, array('status' => 'deactivated'));
$this->view->removeCommands = $this->extension->removePackage($extension);
$this->view->header->title = $this->lang->extension->deactivateFinished;
$this->display();
}
/**
* Upload an extension
*
* @access public
* @return void
*/
public function upload()
{
if($_FILES)
{
$tmpName = $_FILES['file']['tmp_name'];
$fileName = $_FILES['file']['name'];
$extension = basename($fileName, '.zip');
move_uploaded_file($tmpName, $this->app->getTmpRoot() . "/extension/$fileName");
$this->locate(inlink('install', "extension=$extension"));
}
$this->display();
}
/**
* Erase an extension.
*
* @param string $extension
* @access public
* @return void
*/
public function erase($extension)
{
$this->view->removeCommands = $this->extension->erasePackage($extension);
$this->view->header->title = $this->lang->extension->eraseFinished;
$this->display();
}
/**
* Update extension.
*
* @param string $extension
* @param string $downLink
* @param string $md5
* @param string $type
* @access public
* @return void
*/
public function upgrade($extension, $downLink, $md5, $type)
{
$this->extension->removePackage($extension);
$this->locate(inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=no&ignoreCompatible=yes"));
}
}
<?php
/**
* The control file of extension module of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package extension
* @version $Id$
* @link http://www.zentao.net
*/
class extension extends control
{
/**
* Browse extensions.
*
* @param string $status
* @access public
* @return void
*/
public function browse($status = 'installed')
{
$extensions = $this->extension->getLocalExtensions($status);
$versions = array();
if($extensions and $status == 'installed')
{
/* Get latest release from remote. */
$extCodes = helper::safe64Encode(join(',', array_keys($extensions)));
$results = $this->extension->getExtensionsByAPI('bycode', $extCodes, $recTotal = 0, $recPerPage = 1000, $pageID = 1);
if(isset($results->extensions))
{
$remoteReleases = $results->extensions;
foreach($remoteReleases as $release)
{
if(!isset($extensions[$release->code])) continue;
$extension = $extensions[$release->code];
if($extension->version != $release->latestRelease->releaseVersion and $this->extension->checkVersion($release->latestRelease->zentaoVersion))
{
$extension->upgradeLink = inlink('upgrade', "extension=$release->code&downLink=" . helper::safe64Encode($release->downLink) . "&md5=$release->md5&type=$release->type");
}
}
}
}
$this->view->header->title = $this->lang->extension->browse;
$this->view->position[] = $this->lang->extension->browse;
$this->view->tab = $status;
$this->view->extensions = $extensions;
$this->view->versions = $versions;
$this->display();
}
/**
* Obtain extensions from the community.
*
* @param string $type
* @param string $param
* @access public
* @return void
*/
public function obtain($type = 'byUpdatedTime', $param = '', $recTotal = 0, $recPerPage = 10, $pageID = 1)
{
/* Init vars. */
$type = strtolower($type);
$moduleID = $type == 'bymodule' ? (int)$param : 0;
$extensions = array();
$pager = null;
/* Set the key. */
if($type == 'bysearch') $param = helper::safe64Encode($this->post->key);
/* Get results from the api. */
$results = $this->extension->getExtensionsByAPI($type, $param, $recTotal, $recPerPage, $pageID);
if($results)
{
$this->app->loadClass('pager', $static = true);
$pager = new pager($results->dbPager->recTotal, $results->dbPager->recPerPage, $results->dbPager->pageID);
$extensions = $results->extensions;
}
$this->view->moduleTree = $this->extension->getModulesByAPI();
$this->view->extensions = $extensions;
$this->view->installeds = $this->extension->getLocalExtensions('installed');
$this->view->pager = $pager;
$this->view->tab = 'obtain';
$this->view->type = $type;
$this->view->moduleID = $moduleID;
$this->display();
}
/**
* Install a extension
*
* @param string $extension
* @param string $downLink
* @param string $md5
* @param string $type
* @param string $overridePackage
* @param string $ignoreCompatible
* @param string $overrideFile
* @param string $agreeLicense
* @access public
* @return void
*/
public function install($extension, $downLink = '', $md5 = '', $type = '', $overridePackage = 'no', $ignoreCompatible = 'no', $overrideFile = 'no', $agreeLicense = 'no')
{
$this->view->error = '';
$this->view->header->title = $this->lang->extension->install . $this->lang->colon . $extension;
/* Get the package file name. */
$packageFile = $this->extension->getPackageFile($extension);
if($downLink)
{
/* Checking download path. */
$return = $this->extension->checkDownloadPath();
if($return->result != 'ok')
{
$this->view->error = $return->error;
die($this->display());
}
/* Check file exists or not. */
if(file_exists($packageFile) and $overridePackage == 'no')
{
$overrideLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=yes&ignoreCompatible=$ignoreCompatible&overrideFile=$overrideFile&agreeLicense=$agreeLicense");
$this->view->error = sprintf($this->lang->extension->errorPackageFileExists, $packageFile, $overrideLink);
die($this->display());
}
/* Download the package file. */
$this->extension->downloadPackage($extension, helper::safe64Decode($downLink));
if(!file_exists($packageFile))
{
$this->view->error = sprintf($this->lang->extension->errorDownloadFailed, $packageFile);
die($this->display());
}
elseif($md5 != '' and md5_file($packageFile) != $md5)
{
unlink($packageFile);
$this->view->error = sprintf($this->lang->extension->errorMd5Checking, $packageFile);
die($this->display());
}
}
/* Check the package file exists or not. */
if(!file_exists($packageFile))
{
$this->view->error = sprintf($this->lang->extension->errorPackageNotFound, $packageFile);
die($this->display());
}
/* Checking the extension pathes. */
$return = $this->extension->checkExtensionPathes($extension);
if($this->session->dirs2Created == false) $this->session->set('dirs2Created', $return->dirs2Created); // Save the dirs to be created.
if($return->result != 'ok')
{
$this->view->error = $return->errors;
die($this->display());
}
/* Extract the package. */
$return = $this->extension->extractPackage($extension);
if($return->result != 'ok')
{
$this->view->error = sprintf($this->lang->extension->errorExtracted, $packageFile, $return->error);
die($this->display());
}
/* Check version comptiable. */
$zentaoVersion = $this->extension->getZentaoVersion($extension);
if(!$this->extension->checkVersion($zentaoVersion) and $ignoreCompatible == 'no')
{
$ignoreLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=$overridePackage&ignoreCompatible=yes");
$returnLink = inlink('obtain');
$this->view->error = sprintf($this->lang->extension->errorCheckIncompatible, $ignoreLink, $returnLink);
die($this->display());
}
/* Check files in the package conflicts with exists files or not. */
if($overrideFile == 'no')
{
$return = $this->extension->checkFile($extension);
if($return->result != 'ok')
{
$overrideLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=$overridePackage&ignoreCompatible=$ignoreCompatible&overrideFile=yes");
$returnLink = inlink('obtain');
$this->view->error = sprintf($this->lang->extension->errorFileConflicted, $return->error, $overrideLink, $returnLink);
die($this->display());
}
}
/* Print the license form. */
if($agreeLicense == 'no')
{
$extensionInfo = $this->extension->getInfoFromPackage($extension);
$license = $this->extension->processLicense($extensionInfo->license);
$agreeLink = inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=$overridePackage&ignoreCompatible=$ignoreCompatible&overrideFile=$overrideFile&agreeLicense=yes");
$this->view->license = $license;
$this->view->author = $extensionInfo->author;
$this->view->agreeLink = $agreeLink;
die($this->display());
}
/* The preInstall hook file. */
if($preInstallHook = $this->extension->getHookFile($extension, 'preinstall')) include $preInstallHook;
/* Save to database. */
$this->extension->saveExtension($extension, $type);
/* Copy files to target directory. */
$this->view->files = $this->extension->copyPackageFiles($extension);
/* Judge need execute db install or not. */
$data->status = 'installed';
$data->dirs = $this->session->dirs2Created;
$data->files = $this->view->files;
$data->installedTime = helper::now();
$this->session->set('dirs2Created', array()); // clean the session.
/* Execute the install.sql. */
if($this->extension->needExecuteDB($extension, 'install'))
{
$return = $this->extension->executeDB($extension, 'install');
if($return->result != 'ok')
{
$this->view->error = sprintf($this->lang->extension->errorInstallDB, $return->error);
die($this->display());
}
}
/* Update status, dirs, files and installed time. */
$this->extension->updateExtension($extension, $data);
$this->view->downloadedPackage = !empty($downLink);
/* The postInstall hook file. */
if($postInstallHook = $this->extension->getHookFile($extension, 'postinstall')) include $postInstallHook;
$this->display();
}
/**
* Uninstall an extension.
*
* @param string $extension
* @access public
* @return void
*/
public function uninstall($extension)
{
if($preUninstallHook = $this->extension->getHookFile($extension, 'preuninstall')) include $preUninstallHook;
$this->extension->executeDB($extension, 'uninstall');
$this->extension->updateExtension($extension, array('status' => 'available'));
$this->view->removeCommands = $this->extension->removePackage($extension);
$this->view->header->title = $this->lang->extension->uninstallFinished;
if($postUninstallHook = $this->extension->getHookFile($extension, 'postuninstall')) include $postUninstallHook;
$this->display();
}
/**
* Activate an extension;
*
* @param string $extension
* @access public
* @return void
*/
public function activate($extension, $ignore = 'no')
{
if($ignore == 'no')
{
$return = $this->extension->checkFile($extension);
if($return->result != 'ok')
{
$ignoreLink = inlink('activate', "extension=$extension&ignore=yes");
$resetLink = inlink('browse', 'type=deactivated');
$this->view->error = sprintf($this->lang->extension->errorFileConflicted, $return->error, $ignoreLink, $resetLink);
die($this->display());
}
}
$this->extension->copyPackageFiles($extension);
$this->extension->updateExtension($extension, array('status' => 'installed'));
$this->view->header->title = $this->lang->extension->activateFinished;
$this->display();
}
/**
* Deactivate an extension
*
* @param string $extension
* @access public
* @return void
*/
public function deactivate($extension)
{
$this->extension->updateExtension($extension, array('status' => 'deactivated'));
$this->view->removeCommands = $this->extension->removePackage($extension);
$this->view->header->title = $this->lang->extension->deactivateFinished;
$this->display();
}
/**
* Upload an extension
*
* @access public
* @return void
*/
public function upload()
{
if($_FILES)
{
$tmpName = $_FILES['file']['tmp_name'];
$fileName = $_FILES['file']['name'];
$extension = basename($fileName, '.zip');
move_uploaded_file($tmpName, $this->app->getTmpRoot() . "/extension/$fileName");
$this->locate(inlink('install', "extension=$extension"));
}
$this->display();
}
/**
* Erase an extension.
*
* @param string $extension
* @access public
* @return void
*/
public function erase($extension)
{
$this->view->removeCommands = $this->extension->erasePackage($extension);
$this->view->header->title = $this->lang->extension->eraseFinished;
$this->display();
}
/**
* Update extension.
*
* @param string $extension
* @param string $downLink
* @param string $md5
* @param string $type
* @access public
* @return void
*/
public function upgrade($extension, $downLink, $md5, $type)
{
$this->extension->removePackage($extension);
$this->locate(inlink('install', "extension=$extension&downLink=$downLink&md5=$md5&type=$type&overridePackage=no&ignoreCompatible=yes"));
}
}

View File

@@ -1,93 +1,93 @@
<?php
/**
* The extension module en file of ZenTaoPMS.
*
* @copyright Copyright 2009-2011 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package extension
* @version $Id$
* @link http://www.zentao.net
*/
$lang->extension->common = 'Extension';
$lang->extension->browse = 'Browse';
$lang->extension->install = 'Install';
$lang->extension->installAuto = 'AutoInstall';
$lang->extension->installForce = 'ForceInstall';
$lang->extension->uninstall = 'Uninstall';
$lang->extension->activate = 'Activate';
$lang->extension->deactivate = 'Deactivate';
$lang->extension->obtain = 'Obtain';
$lang->extension->view = 'Info';
$lang->extension->download = 'Download';
$lang->extension->downloadAB = 'Down';
$lang->extension->upload = 'Upload and install';
$lang->extension->erase = 'Erase';
$lang->extension->upgrade = 'Upgrade';
$lang->extension->agreeLicense = 'I agree the license';
$lang->extension->installed = 'Installed';
$lang->extension->deactivated = 'Deactivated';
$lang->extension->available = 'Downloaded';
$lang->extension->id = 'ID';
$lang->extension->name = 'Name';
$lang->extension->code = 'Code';
$lang->extension->version = 'Version';
$lang->extension->compatible = 'Compatible';
$lang->extension->latest = '<small>Latest:<strong><a href="%s" target="_blank" class="extension">%s</a></strong>need zentao <a href="http://www.zentao.net/goto.php?item=latest" target="_blank"><strong>%s</strong></small>';
$lang->extension->author = 'Author';
$lang->extension->license = 'License';
$lang->extension->intro = 'Description';
$lang->extension->abstract = 'Abstract';
$lang->extension->site = 'Site';
$lang->extension->addedTime = 'Added Time';
$lang->extension->updatedTime = 'Updated Time';
$lang->extension->downloads = 'Downloads';
$lang->extension->public = 'Public';
$lang->extension->compatible = 'Compatible';
$lang->extension->grade = 'Grade';
$lang->extension->publicList[0] = 'Manually';
$lang->extension->publicList[1] = 'Auto';
$lang->extension->compatibleList[0] = 'Unknow';
$lang->extension->compatibleList[1] = 'Compatible';
$lang->extension->byDownloads = 'Downloads';
$lang->extension->byAddedTime = 'New added';
$lang->extension->byUpdatedTime = 'Last updated';
$lang->extension->bySearch = 'Search';
$lang->extension->byCategory = 'By Category';
$lang->extension->installFailed = 'Install failed, the reason is:';
$lang->extension->installFinished = 'Good, the extension has been installed successfully.';
$lang->extension->refreshPage = 'Refresh';
$lang->extension->uninstallFinished = 'Extension has been successfully uninstalled.';
$lang->extension->deactivateFinished = 'Extension has been successfully deactivated.';
$lang->extension->activateFinished = 'Extension has been successfully activated.';
$lang->extension->eraseFinished = 'Extension has been successfully erased.';
$lang->extension->unremovedFiles = 'There are some unremoved files, you need remove them manually';
$lang->extension->executeCommands = '<h3>Execute the following commands to fix them:</h3>';
$lang->extension->successDownloadedPackage = 'Successfully downloaded the package file.';
$lang->extension->successCopiedFiles = 'Successfully copied files. ';
$lang->extension->successInstallDB = 'Successfully installed database.';
$lang->extension->viewInstalled = 'View installed extensions.';
$lang->extension->viewAvailable = 'View available extensions';
$lang->extension->viewDeactivated = 'View deactivated extensions';
$lang->extension->errorOccurs = 'Error:';
$lang->extension->errorGetModules = "Get extensions' categories data from the www.zentao.net failed. ";
$lang->extension->errorGetExtensions = 'Get extensions from www.zentao.net failed. You can visit <a href="http://www.zentao.net/extension/" target="_blank">www.zentao.net</a> to find your extensions, download it manually and then upload to zentaopms to install it.';
$lang->extension->errorDownloadPathNotFound = 'The save path of package file <strong>%s</strong>does not exists.<br />For linux users, can execute <strong>mkdir -p %s</strong> to fix it.';
$lang->extension->errorDownloadPathNotWritable = 'The save path of package file <strong>%s</strong>is not writable.<br />For linux users, can execute <strong>sudo chmod 777 %s</strong> to fix it.';
$lang->extension->errorPackageFileExists = 'There is already a file with the same name <strong>%s</strong>.<h3> If you want to install again, <a href="%s">please click this link</a>.</h3>';
$lang->extension->errorDownloadFailed = 'Download failed, please try again. Or you can download it manually and upload it to install.';
$lang->extension->errorMd5Checking = 'The downloawd files checking failed, Please download it manually and upload it to install';
$lang->extension->errorExtracted = 'The package file <strong> %s </strong> extracted failed. The error is:<br />%s';
$lang->extension->errorCheckIncompatible = 'This extenion is not compatible with current zentao version. <h3>You can <a href="%s">force install</a> or <a href="#" onclick=parent.location.href="%s">cancel the installation</a></h3>.';
$lang->extension->errorFileConflicted = 'There are some files conflicted: <br />%s <h3>You can <a href="%s">Overide them</a> or <a href="#" onclick=parent.location.href="%s">Cancel the installation</a></h3>.';
$lang->extension->errorPackageNotFound = 'The package file <strong>%s </strong> not found, perhaps download failed, try again.';
$lang->extension->errorTargetPathNotWritable = 'Target path <strong>%s </strong>not writable.';
$lang->extension->errorTargetPathNotExists = 'Target path <strong>%s </strong>not exists';
$lang->extension->errorInstallDB = 'Execute database sql failed, the error is: %s';
<?php
/**
* The extension module en file of ZenTaoPMS.
*
* @copyright Copyright 2009-2012 青岛易软天创网络科技有限公司 (QingDao Nature Easy Soft Network Technology Co,LTD www.cnezsoft.com)
* @license LGPL (http://www.gnu.org/licenses/lgpl.html)
* @author Chunsheng Wang <chunsheng@cnezsoft.com>
* @package extension
* @version $Id$
* @link http://www.zentao.net
*/
$lang->extension->common = 'Extension';
$lang->extension->browse = 'Browse';
$lang->extension->install = 'Install';
$lang->extension->installAuto = 'AutoInstall';
$lang->extension->installForce = 'ForceInstall';
$lang->extension->uninstall = 'Uninstall';
$lang->extension->activate = 'Activate';
$lang->extension->deactivate = 'Deactivate';
$lang->extension->obtain = 'Obtain';
$lang->extension->view = 'Info';
$lang->extension->download = 'Download';
$lang->extension->downloadAB = 'Down';
$lang->extension->upload = 'Upload and install';
$lang->extension->erase = 'Erase';
$lang->extension->upgrade = 'Upgrade';
$lang->extension->agreeLicense = 'I agree the license';
$lang->extension->installed = 'Installed';
$lang->extension->deactivated = 'Deactivated';
$lang->extension->available = 'Downloaded';
$lang->extension->id = 'ID';
$lang->extension->name = 'Name';
$lang->extension->code = 'Code';
$lang->extension->version = 'Version';
$lang->extension->compatible = 'Compatible';
$lang->extension->latest = '<small>Latest:<strong><a href="%s" target="_blank" class="extension">%s</a></strong>need zentao <a href="http://www.zentao.net/goto.php?item=latest" target="_blank"><strong>%s</strong></small>';
$lang->extension->author = 'Author';
$lang->extension->license = 'License';
$lang->extension->intro = 'Description';
$lang->extension->abstract = 'Abstract';
$lang->extension->site = 'Site';
$lang->extension->addedTime = 'Added Time';
$lang->extension->updatedTime = 'Updated Time';
$lang->extension->downloads = 'Downloads';
$lang->extension->public = 'Public';
$lang->extension->compatible = 'Compatible';
$lang->extension->grade = 'Grade';
$lang->extension->publicList[0] = 'Manually';
$lang->extension->publicList[1] = 'Auto';
$lang->extension->compatibleList[0] = 'Unknow';
$lang->extension->compatibleList[1] = 'Compatible';
$lang->extension->byDownloads = 'Downloads';
$lang->extension->byAddedTime = 'New added';
$lang->extension->byUpdatedTime = 'Last updated';
$lang->extension->bySearch = 'Search';
$lang->extension->byCategory = 'By Category';
$lang->extension->installFailed = 'Install failed, the reason is:';
$lang->extension->installFinished = 'Good, the extension has been installed successfully.';
$lang->extension->refreshPage = 'Refresh';
$lang->extension->uninstallFinished = 'Extension has been successfully uninstalled.';
$lang->extension->deactivateFinished = 'Extension has been successfully deactivated.';
$lang->extension->activateFinished = 'Extension has been successfully activated.';
$lang->extension->eraseFinished = 'Extension has been successfully erased.';
$lang->extension->unremovedFiles = 'There are some unremoved files, you need remove them manually';
$lang->extension->executeCommands = '<h3>Execute the following commands to fix them:</h3>';
$lang->extension->successDownloadedPackage = 'Successfully downloaded the package file.';
$lang->extension->successCopiedFiles = 'Successfully copied files. ';
$lang->extension->successInstallDB = 'Successfully installed database.';
$lang->extension->viewInstalled = 'View installed extensions.';
$lang->extension->viewAvailable = 'View available extensions';
$lang->extension->viewDeactivated = 'View deactivated extensions';
$lang->extension->errorOccurs = 'Error:';
$lang->extension->errorGetModules = "Get extensions' categories data from the www.zentao.net failed. ";
$lang->extension->errorGetExtensions = 'Get extensions from www.zentao.net failed. You can visit <a href="http://www.zentao.net/extension/" target="_blank">www.zentao.net</a> to find your extensions, download it manually and then upload to zentaopms to install it.';
$lang->extension->errorDownloadPathNotFound = 'The save path of package file <strong>%s</strong>does not exists.<br />For linux users, can execute <strong>mkdir -p %s</strong> to fix it.';
$lang->extension->errorDownloadPathNotWritable = 'The save path of package file <strong>%s</strong>is not writable.<br />For linux users, can execute <strong>sudo chmod 777 %s</strong> to fix it.';
$lang->extension->errorPackageFileExists = 'There is already a file with the same name <strong>%s</strong>.<h3> If you want to install again, <a href="%s">please click this link</a>.</h3>';
$lang->extension->errorDownloadFailed = 'Download failed, please try again. Or you can download it manually and upload it to install.';
$lang->extension->errorMd5Checking = 'The downloawd files checking failed, Please download it manually and upload it to install';
$lang->extension->errorExtracted = 'The package file <strong> %s </strong> extracted failed. The error is:<br />%s';
$lang->extension->errorCheckIncompatible = 'This extenion is not compatible with current zentao version. <h3>You can <a href="%s">force install</a> or <a href="#" onclick=parent.location.href="%s">cancel the installation</a></h3>.';
$lang->extension->errorFileConflicted = 'There are some files conflicted: <br />%s <h3>You can <a href="%s">Overide them</a> or <a href="#" onclick=parent.location.href="%s">Cancel the installation</a></h3>.';
$lang->extension->errorPackageNotFound = 'The package file <strong>%s </strong> not found, perhaps download failed, try again.';
$lang->extension->errorTargetPathNotWritable = 'Target path <strong>%s </strong>not writable.';
$lang->extension->errorTargetPathNotExists = 'Target path <strong>%s </strong>not exists';
$lang->extension->errorInstallDB = 'Execute database sql failed, the error is: %s';

Some files were not shown because too many files have changed in this diff Show More