This commit is contained in:
sgm0422
2017-08-28 17:06:13 +08:00
145 changed files with 889 additions and 379 deletions
+10
View File
@@ -33,6 +33,13 @@ $lang->action->confirmHideAll = 'Do you want to hide all the records?';
$lang->action->needEdit = '%s you want to restore has already existed. Please edit it.';
$lang->action->historyEdit = 'The history editor cannot be empty.';
$lang->action->history = new stdclass();
$lang->action->history->action = 'Bound action';
$lang->action->history->field = 'Field';
$lang->action->history->old = 'Old value';
$lang->action->history->new = 'New value';
$lang->action->history->diff = 'Diff';
$lang->action->dynamic = new stdclass();
$lang->action->dynamic->today = 'Today';
$lang->action->dynamic->yesterday = 'Yesterday';
@@ -106,6 +113,7 @@ $lang->action->desc->paused = '$date, paused by <strong>$actor</strong>.
$lang->action->desc->diff1 = '<strong><i>%s</i></strong> has been changed. Its value was "%s" and the new value is "%s".<br />' . "\n";
$lang->action->desc->diff2 = '<strong><i>%s</i></strong> has been changed. The difference is ' . "\n" . "<blockquote>%s</blockquote>" . "\n<div class='hidden'>%s</div>";
$lang->action->desc->diff3 = 'File Name %s was changed to %s .' . "\n";
$lang->action->desc->linked2bug = '$date Link to build <strong>$extra</strong> by <strong>$actor</strong>';
/* 关联用例和移除用例时的历史操作记录。*/
$lang->action->desc->linkrelatedcase = '$date, <strong>$actor</strong> linked relevant use case <strong>$extra</strong>.' . "\n";
@@ -168,6 +176,8 @@ $lang->action->label->suspended = 'Suspended';
$lang->action->label->login = 'Login';
$lang->action->label->logout = "Logout";
$lang->action->label->deleteestimate = "Deleted Man-Hour";
$lang->action->label->linked2build = "Linked";
$lang->action->label->linked2bug = "Linked";
/* 用来生成相应对象的链接。*/
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
+10 -2
View File
@@ -33,6 +33,13 @@ $lang->action->confirmHideAll = '您确定要全部隐藏这些记录吗?';
$lang->action->needEdit = '要还原%s的名称或代号已经存在,请编辑更改。';
$lang->action->historyEdit = '历史记录编辑不能为空。';
$lang->action->history = new stdclass();
$lang->action->history->action = '关联日志';
$lang->action->history->field = '字段';
$lang->action->history->old = '旧值';
$lang->action->history->new = '新值';
$lang->action->history->diff = '不同';
$lang->action->dynamic = new stdclass();
$lang->action->dynamic->today = '今天';
$lang->action->dynamic->yesterday = '昨天';
@@ -106,6 +113,7 @@ $lang->action->desc->paused = '$date, 由 <strong>$actor</strong> 暂停
$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<div class='hidden'>%s</div>";
$lang->action->desc->diff3 = '将文件名 %s 改为 %s 。' . "\n";
$lang->action->desc->linked2bug = '$date 由 <strong>$actor</strong> 关联到版本 <strong>$extra</strong>';
/* 关联用例和移除用例时的历史操作记录。*/
$lang->action->desc->linkrelatedcase = '$date, 由 <strong>$actor</strong> 关联相关用例 <strong>$extra</strong>。' . "\n";
@@ -168,8 +176,8 @@ $lang->action->label->suspended = '挂起';
$lang->action->label->login = '登录系统';
$lang->action->label->logout = "退出登录";
$lang->action->label->deleteestimate = "删除了工时";
$lang->action->label->linked2build = "关联版本";
$lang->action->label->linked2bug = "关联BUG";
$lang->action->label->linked2build = "关联了";
$lang->action->label->linked2bug = "关联了";
/* 用来生成相应对象的链接。*/
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
+10
View File
@@ -33,6 +33,13 @@ $lang->action->confirmHideAll = '您確定要全部隱藏這些記錄嗎?';
$lang->action->needEdit = '要還原%s的名稱或代號已經存在,請編輯更改。';
$lang->action->historyEdit = '歷史記錄編輯不能為空。';
$lang->action->history = new stdclass();
$lang->action->history->action = '關聯日誌';
$lang->action->history->field = '欄位';
$lang->action->history->old = '舊值';
$lang->action->history->new = '新值';
$lang->action->history->diff = '不同';
$lang->action->dynamic = new stdclass();
$lang->action->dynamic->today = '今天';
$lang->action->dynamic->yesterday = '昨天';
@@ -106,6 +113,7 @@ $lang->action->desc->paused = '$date, 由 <strong>$actor</strong> 暫停
$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<div class='hidden'>%s</div>";
$lang->action->desc->diff3 = '將檔案名 %s 改為 %s 。' . "\n";
$lang->action->desc->linked2bug = '$date 由 <strong>$actor</strong> 關聯到版本 <strong>$extra</strong>';
/* 關聯用例和移除用例時的歷史操作記錄。*/
$lang->action->desc->linkrelatedcase = '$date, 由 <strong>$actor</strong> 關聯相關用例 <strong>$extra</strong>。' . "\n";
@@ -168,6 +176,8 @@ $lang->action->label->suspended = '掛起';
$lang->action->label->login = '登錄系統';
$lang->action->label->logout = "退出登錄";
$lang->action->label->deleteestimate = "刪除了工時";
$lang->action->label->linked2build = "關聯了";
$lang->action->label->linked2bug = "關聯了";
/* 用來生成相應對象的連結。*/
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
+5
View File
@@ -242,6 +242,11 @@ class actionModel extends model
$name = $this->dao->select('name')->from(TABLE_BUILD)->where('id')->eq($action->extra)->fetch('name');
if($name) $action->extra = html::a(helper::createLink('build', 'view', "builID=$action->extra&type={$action->objectType}"), $name);
}
elseif($actionName == 'linked2bug')
{
$name = $this->dao->select('name')->from(TABLE_BUILD)->where('id')->eq($action->extra)->fetch('name');
if($name) $action->extra = html::a(helper::createLink('build', 'view', "builID=$action->extra&type={$action->objectType}"), $name);
}
elseif($actionName == 'linked2release')
{
$name = $this->dao->select('name')->from(TABLE_RELEASE)->where('id')->eq($action->extra)->fetch('name');
+4 -4
View File
@@ -21,7 +21,7 @@ class block extends control
{
parent::__construct($moduleName, $methodName);
/* Mark the call from zentao or ranzhi. */
$this->selfCall = strpos($this->server->http_referer, common::getSysURL()) === 0 || $this->session->blockModule;
$this->selfCall = strpos($this->server->http_referer, common::getSysURL() . $this->config->webRoot) === 0 || $this->session->blockModule;
if($this->methodName != 'admin' and $this->methodName != 'dashboard' and !$this->selfCall and !$this->loadModel('sso')->checkKey()) die('');
}
@@ -197,7 +197,7 @@ class block extends control
*/
public function dashboard($module)
{
$this->session->set('blockModule', $module);
if($this->loadModel('user')->isLogon()) $this->session->set('blockModule', $module);
$blocks = $this->block->getBlockList($module);
$inited = empty($this->config->$module->common->blockInited) ? '' : $this->config->$module->common->blockInited;
@@ -605,7 +605,7 @@ class block extends control
public function printProductBlock()
{
$this->app->loadClass('pager', $static = true);
if(preg_match('/[^a-zA-Z0-9_]/', $this->params->type)) die();
if(!empty($this->params->type) and preg_match('/[^a-zA-Z0-9_]/', $this->params->type)) die();
$num = isset($this->params->num) ? (int)$this->params->num : 0;
$type = isset($this->params->type) ? $this->params->type : '';
$pager = pager::init(0, $num , 1);
@@ -621,7 +621,7 @@ class block extends control
public function printProjectBlock()
{
$this->app->loadClass('pager', $static = true);
if(preg_match('/[^a-zA-Z0-9_]/', $this->params->type)) die();
if(!empty($this->params->type) and preg_match('/[^a-zA-Z0-9_]/', $this->params->type)) die();
$num = isset($this->params->num) ? (int)$this->params->num : 0;
$type = isset($this->params->type) ? $this->params->type : 'all';
$pager = pager::init(0, $num, 1);
+8
View File
@@ -16,6 +16,14 @@ $lang->block->style = 'Style';
$lang->block->grid = 'Grid';
$lang->block->color = 'Color';
$lang->block->account = 'Account';
$lang->block->module = 'Module';
$lang->block->title = 'Title';
$lang->block->source = 'Source module';
$lang->block->block = 'Source block';
$lang->block->order = 'Order';
$lang->block->height = 'Height';
$lang->block->lblModule = 'Module';
$lang->block->lblBlock = 'Widget';
$lang->block->lblNum = 'Number';
+8
View File
@@ -16,6 +16,14 @@ $lang->block->style = '外观';
$lang->block->grid = '宽度';
$lang->block->color = '颜色';
$lang->block->account = '所属用户';
$lang->block->module = '所属模块';
$lang->block->title = '区块名称';
$lang->block->source = '来源模块';
$lang->block->block = '来源区块';
$lang->block->order = '排序';
$lang->block->height = '高度';
$lang->block->lblModule = '模块';
$lang->block->lblBlock = '区块';
$lang->block->lblNum = '条数';
+8
View File
@@ -16,6 +16,14 @@ $lang->block->style = '外觀';
$lang->block->grid = '寬度';
$lang->block->color = '顏色';
$lang->block->account = '所屬用戶';
$lang->block->module = '所屬模組';
$lang->block->title = '區塊名稱';
$lang->block->source = '來源模組';
$lang->block->block = '來源區塊';
$lang->block->order = '排序';
$lang->block->height = '高度';
$lang->block->lblModule = '模組';
$lang->block->lblBlock = '區塊';
$lang->block->lblNum = '條數';
+5
View File
@@ -7,5 +7,10 @@ $lang->branch->delete = 'Delete Branch';
$lang->branch->manageTitle = '%s Management';
$lang->branch->all = 'All';
$lang->branch->id = 'ID';
$lang->branch->product = 'Product';
$lang->branch->name = 'Name';
$lang->branch->order = 'Order';
$lang->branch->confirmDelete = 'Do you want to delete this @branch@?';
$lang->branch->canNotDelete = 'There is data in @branch@. It cannot be deleted.';
+5
View File
@@ -7,5 +7,10 @@ $lang->branch->delete = '分支删除';
$lang->branch->manageTitle = '%s管理';
$lang->branch->all = '所有';
$lang->branch->id = '编号';
$lang->branch->product = '所属产品';
$lang->branch->name = '名称';
$lang->branch->order = '排序';
$lang->branch->confirmDelete = '是否删除该@branch@?';
$lang->branch->canNotDelete = '该@branch@下已经有数据,不能删除!';
+5
View File
@@ -7,5 +7,10 @@ $lang->branch->delete = '分支刪除';
$lang->branch->manageTitle = '%s管理';
$lang->branch->all = '所有';
$lang->branch->id = '編號';
$lang->branch->product = '所屬產品';
$lang->branch->name = '名稱';
$lang->branch->order = '排序';
$lang->branch->confirmDelete = '是否刪除該@branch@?';
$lang->branch->canNotDelete = '該@branch@下已經有數據,不能刪除!';
+31 -28
View File
@@ -513,18 +513,18 @@ class bug extends control
}
$bug = $this->bug->getById($bugID);
if($bug->toTask != 0)
if($bug->toTask != 0)
{
foreach($changes as $change)
{
if($change['field'] == 'status')
if($change['field'] == 'status')
{
$confirmURL = $this->createLink('task', 'view', "taskID=$bug->toTask");
$cancelURL = $this->server->HTTP_REFERER;
die(js::confirm(sprintf($this->lang->bug->remindTask, $bug->Task), $confirmURL, $cancelURL, 'parent', 'parent'));
}
}
}
}
die(js::locate($this->createLink('bug', 'view', "bugID=$bugID"), 'parent'));
}
@@ -587,8 +587,8 @@ class bug extends control
/**
* Batch edit bug.
*
* @param int $productID
*
* @param int $productID
* @access public
* @return void
*/
@@ -618,7 +618,7 @@ class bug extends control
die(js::confirm(sprintf($this->lang->bug->remindTask, $bug->task), $confirmURL, $cancelURL, 'parent', 'parent'));
}
}
}
}
}
die(js::locate($this->session->bugList, 'parent'));
}
@@ -933,8 +933,8 @@ class bug extends control
/**
* Activate a bug.
*
* @param int $bugID
*
* @param int $bugID
* @access public
* @return void
*/
@@ -1122,36 +1122,39 @@ class bug extends control
}
/**
* Batch activate bugs.
*
* Batch activate bugs.
*
* @access public
* @return void
*/
public function batchActivate()
public function batchActivate($productID, $branch = 0)
{
if($this->post->bugIDList)
if($this->post->statusList)
{
$bugIDList = $this->post->bugIDList;
/* Reset $_POST. Do not unset that because the function of close need that in model. */
$_POST = array();
$bugs = $this->bug->getByList($bugIDList);
foreach($bugs as $bugID => $bug)
$activateBugs = $this->bug->batchActivate();
foreach($activateBugs as $bugID => $bug)
{
if($bug->status == 'active')
{
continue;
}
$this->bug->activate($bugID);
$actionID = $this->action->create('bug', $bugID, 'Activated');
$actionID = $this->action->create('bug', $bugID, 'Activated', $bug['comment']);
$this->bug->sendmail($bugID, $actionID);
}
die(js::locate($this->session->bugList, 'parent'));
}
die(js::reload('parent'));
$bugIDList = $this->post->bugIDList ? $this->post->bugIDList : die(js::locate($this->session->bugList, 'parent'));
$bugs = $this->dao->select('id, title, status, resolvedBy, openedBuild')->from(TABLE_BUG)->where('id')->in($bugIDList)->fetchAll('id');
$this->bug->setMenu($this->products, $productID, $branch);
$this->view->title = $this->products[$productID] . $this->lang->colon . $this->lang->bug->batchActivate;
$this->view->position[] = html::a($this->createLink('bug', 'browse', "productID=$productID"), $this->products[$productID]);
$this->view->position[] = $this->lang->bug->batchActivate;
$this->view->bugs = $bugs;
$this->view->users = $this->user->getPairs();
$this->view->builds = $this->loadModel('build')->getProductBuildPairs($productID, $branch, 'noempty');
$this->display();
}
/**
+1 -1
View File
@@ -1,4 +1,4 @@
$(function()
$(function()
{
setModal4List('iframe', 'bugList');
+3 -3
View File
@@ -342,9 +342,9 @@ $lang->bug->report->bugHistories->graph->xAxisName = '处理步骤';
/* 操作记录。*/
$lang->bug->action = new stdclass();
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解决,方案为 <strong>$extra</strong> $appendLink。', 'extra' => '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>。');
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解决,方案为 <strong>$extra</strong> $appendLink。', 'extra' => '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>。');
$lang->bug->action->linked2plan = array('main' => '$date, 由 <strong>$actor</strong> 关联到计划 <strong>$extra</strong>。');
$lang->bug->action->unlinkedfromplan = array('main' => '$date, 由 <strong>$actor</strong> 从计划 <strong>$extra</strong> 移除。');
$lang->bug->action->linked2build = array('main' => '$date, 由 <strong>$actor</strong> 关联到版本 <strong>$extra</strong>。');
+6 -6
View File
@@ -150,9 +150,9 @@ $lang->bug->applyTemplate = '應用模板';
$lang->bug->confirmDeleteTemplate = '您確認要刪除該模板嗎?';
/* 模板。*/
$lang->bug->tplStep = "<p>[步驟]</p>\n";
$lang->bug->tplResult = "<p>[結果]</p>\n";
$lang->bug->tplExpect = "<p>[期望]</p>";
$lang->bug->tplStep = "<p>[步驟]</p>";
$lang->bug->tplResult = "</br><p>[結果]</p>";
$lang->bug->tplExpect = "</br><p>[期望]</p>";
/* 各個欄位取值列表。*/
$lang->bug->severityList[3] = '3';
@@ -342,9 +342,9 @@ $lang->bug->report->bugHistories->graph->xAxisName = '處理步驟';
/* 操作記錄。*/
$lang->bug->action = new stdclass();
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解決,方案為 <strong>$extra</strong> $appendLink。', 'extra' => '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>。');
$lang->bug->action->resolved = array('main' => '$date, 由 <strong>$actor</strong> 解決,方案為 <strong>$extra</strong> $appendLink。', 'extra' => '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>。');
$lang->bug->action->linked2plan = array('main' => '$date, 由 <strong>$actor</strong> 關聯到計劃 <strong>$extra</strong>。');
$lang->bug->action->unlinkedfromplan = array('main' => '$date, 由 <strong>$actor</strong> 從計劃 <strong>$extra</strong> 移除。');
$lang->bug->action->linked2build = array('main' => '$date, 由 <strong>$actor</strong> 關聯到版本 <strong>$extra</strong>。');
+53 -2
View File
@@ -658,6 +658,57 @@ class bugModel extends model
return $allChanges;
}
/**
* Batch active bugs.
*
* @access public
* @return array
*/
public function batchActivate()
{
$now = helper::now();
$data = fixer::input('post')->get();
$activateBugs = array();
$bugIDList = $data->bugIDList ? $data->bugIDList : array();
if(empty($bugIDList)) return $activateBugs;
foreach($bugIDList as $bugID)
{
if($data->statusList[$bugID] == 'active') continue;
$activateBugs[$bugID]['assignedTo'] = $data->assignedToList[$bugID];
$activateBugs[$bugID]['openedBuild'] = $data->openedBuildList[$bugID];
$activateBugs[$bugID]['comment'] = $data->commentList[$bugID];
$activateBugs[$bugID]['assignedDate'] = $now;
$activateBugs[$bugID]['resolution'] = '';
$activateBugs[$bugID]['status'] = 'active';
$activateBugs[$bugID]['resolvedDate'] = '0000-00-00';
$activateBugs[$bugID]['resolvedBy'] = '';
$activateBugs[$bugID]['resolvedBuild'] = '';
$activateBugs[$bugID]['closedBy'] = '';
$activateBugs[$bugID]['closedDate'] = '0000-00-00';
$activateBugs[$bugID]['duplicateBug'] = 0;
$activateBugs[$bugID]['toTask'] = 0;
$activateBugs[$bugID]['toStory'] = 0;
$activateBugs[$bugID]['lastEditedBy'] = $this->app->user->account;
$activateBugs[$bugID]['lastEditedDate'] = $now;
}
/* Update bugs. */
foreach($activateBugs as $bugID => $bug)
{
$this->dao->update(TABLE_BUG)->data($bug, $skipFields = 'comment')->autoCheck()->where('id')->eq((int)$bugID)->exec();
if(dao::isError()) die(js::error('bug#' . $bugID . dao::getError(true)));
$this->dao->update(TABLE_BUG)->set('activatedCount = activatedCount + 1')->where('id')->eq((int)$bugID)->exec();
}
return $activateBugs;
}
/**
* Assign a bug to a user again.
*
@@ -1506,7 +1557,7 @@ class bugModel extends model
{
foreach($openBuildIDList as $buildID)
{
if(isset($datas[$buildID]))
if(isset($datas[$buildID]))
{
$datas[$buildID]->value += $data->value;
}
@@ -1538,7 +1589,7 @@ class bugModel extends model
{
$datas = $this->dao->select('module as name, count(module) as value')->from(TABLE_BUG)->where($this->reportCondition())->groupBy('module')->orderBy('value DESC')->fetchAll('name');
if(!$datas) return array();
$modules = $this->loadModel('tree')->getModulesName(array_keys($datas),true,true);
$modules = $this->loadModel('tree')->getModulesName(array_keys($datas), true, true);
foreach($datas as $moduleID => $data) $data->name = isset($modules[$moduleID]) ? $modules[$moduleID] : '/';
return $datas;
}
+1 -1
View File
@@ -37,7 +37,7 @@
<tr>
<th><?php echo $lang->bug->files;?></th>
<td colspan='2' class='text-left'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
</tr>
<tr>
<th></th><td colspan='2'><?php echo html::submitButton() . html::linkButton($lang->goback, $this->session->bugList);?></td>
</tr>
+46
View File
@@ -0,0 +1,46 @@
<?php
/**
* The batch activate view of bug module of ZenTaoPMS.
*
* @copyright Copyright 2009-2015 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
* @license ZPL (http://zpl.pub/page/zplv12.html)
* @author Congzhi Chen <congzhi@cnezsoft.com>
* @package bug
* @version $Id$
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='titlebar'>
<div class='heading'>
<strong><small class='text-muted'></small> <?php echo $lang->bug->common . $lang->colon . $lang->bug->batchActivate;?></strong>
</div>
</div>
<form class='form-condensed' method='post' target='hiddenwin' action="<?php echo inLink('batchActivate', "productID=$productID");?>">
<table class='table table-fixed with-border'>
<thead>
<tr>
<th class='w-20px'><?php echo $lang->idAB;?></th>
<th class='w-50px'><?php echo $lang->bug->title;?></th>
<th class='w-70px'><?php echo $lang->bug->assignedTo;?></th>
<th class='w-70px'><?php echo $lang->bug->openedBuild;?></th>
<th class='w-150px'><?php echo $lang->bug->legendComment;?></th>
</tr>
</thead>
<tbody class='text-left'>
<?php foreach($bugs as $bug):?>
<tr>
<td class='text-center'><?php echo $bug->id . html::hidden("bugIDList[$bug->id]", $bug->id);?></td>
<td><?php echo $bug->title . html::hidden("statusList[$bug->id]", $bug->status);?></td>
<td style='overflow:visible'><?php echo html::select("assignedToList[$bug->id]", $users, $bug->resolvedBy, "class='form-control chosen'");?></td>
<td style='overflow:visible'><?php echo html::select("openedBuildList[$bug->id]", $builds, $bug->openedBuild, 'size=4 multiple=multiple class="form-control chosen"');?></td>
<td><?php echo html::input("commentList[$bug->id]", '', "class='form-control'");?></td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr><td colspan='5' class='text-center'><?php echo html::submitButton();?></td></tr>
</tfoot>
</table>
</form>
<?php include '../../common/view/footer.html.php';?>
+4 -4
View File
@@ -193,15 +193,15 @@ js::set('branch', $branch);
<?php
$class = "class='disabled'";
$actionLink = $this->createLink('bug', 'batchConfirm');
$misc = common::hasPriv('bug', 'batchConfirm') ? "onclick=\"setFormAction('$actionLink','hiddenwin')\"" : $class;
$misc = common::hasPriv('bug', 'batchConfirm') ? "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"" : $class;
if($misc) echo "<li>" . html::a('javascript:;', $lang->bug->confirmBug, '', $misc) . "</li>";
$actionLink = $this->createLink('bug', 'batchClose');
$misc = common::hasPriv('bug', 'batchClose') ? "onclick=\"setFormAction('$actionLink','hiddenwin')\"" : $class;
$misc = common::hasPriv('bug', 'batchClose') ? "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"" : $class;
if($misc) echo "<li>" . html::a('javascript:;', $lang->bug->close, '', $misc) . "</li>";
$actionLink = $this->createLink('bug', 'batchActivate');
$misc = common::hasPriv('bug', 'batchActivate') ? "onclick=\"setFormAction('$actionLink','hiddenwin')\"" : $class;
$actionLink = $this->createLink('bug', 'batchActivate', "productID=$productID&branch=$branch");
$misc = common::hasPriv('bug', 'batchActivate') ? "onclick=\"setFormAction('$actionLink')\"" : $class;
if($misc) echo "<li>" . html::a('javascript:;', $lang->bug->activate, '', $misc) . "</li>";
if(common::hasPriv('bug', 'batchChangeModule'))
+1 -1
View File
@@ -1,4 +1,4 @@
<?php
<?php
/**
* The create view of bug module of ZenTaoPMS.
*
+3
View File
@@ -39,6 +39,7 @@ class build extends control
$product = $this->loadModel('product')->getByID($projectID);
$products = $this->product->getPairs();
$this->product->setMenu($products, $projectID);
$this->lang->build->menu = $this->lang->product->menu;
$productGroups = array();
$product->branch = 0;
@@ -112,6 +113,7 @@ class build extends control
$product = $this->loadModel('product')->getById($build->product);
$products = $this->product->getPairs();
$this->product->setMenu($products, $build->product);
$this->lang->build->menu = $this->lang->product->menu;
$productGroups = array();
$product->branch = 0;
@@ -193,6 +195,7 @@ class build extends control
{
$products = $this->loadModel('product')->getPairs();
$this->product->setMenu($products, $build->product);
$this->lang->build->menu = $this->lang->product->menu;
$this->view->title = "BUILD #$build->id $build->name - " . $build->productName;
$this->view->position[] = html::a($this->createLink('product', 'build', "productID=$build->product"), $build->productName);
+13 -10
View File
@@ -14,15 +14,18 @@ function showLink(buildID, type, param)
}
$(function()
{
if(link == 'true') showLink(buildID, type, param);
fixedTfootAction($('#' + type + 'List').closest('form'));
$('.nav.nav-tabs a[data-toggle="tab"]').on('shown.zui.tab', function(e)
if(flow != 'onlyTest')
{
var href = $(e.target).attr('href');
var tabPane = $(href + '.tab-pane');
if(tabPane.size() == 0) return;
var formID = tabPane.find('.linkBox').find('form:last');
if(formID.size() == 0) formID = tabPane.find('form:last');
setTimeout(function(){fixedTfootAction(formID)}, 100);
});
if(link == 'true') showLink(buildID, type, param);
fixedTfootAction($('#' + type + 'List').closest('form'));
$('.nav.nav-tabs a[data-toggle="tab"]').on('shown.zui.tab', function(e)
{
var href = $(e.target).attr('href');
var tabPane = $(href + '.tab-pane');
if(tabPane.size() == 0) return;
var formID = tabPane.find('.linkBox').find('form:last');
if(formID.size() == 0) formID = tabPane.find('form:last');
setTimeout(function(){fixedTfootAction(formID)}, 100);
});
}
})
+2 -1
View File
@@ -13,7 +13,6 @@ $lang->build->common = "Build";
$lang->build->create = "Create";
$lang->build->edit = "Edit";
$lang->build->linkStory = "Link Story";
$lang->build->linked2build = "Link build";
$lang->build->linkBug = "Link Bug";
$lang->build->delete = "Delete Build";
$lang->build->deleted = "Deleted";
@@ -30,6 +29,7 @@ $lang->build->basicInfo = 'Basic Info';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = 'Platform/Branch';
$lang->build->project = $lang->projectCommon;
$lang->build->name = 'Name';
$lang->build->date = 'Date';
@@ -39,6 +39,7 @@ $lang->build->filePath = 'File Path';
$lang->build->desc = 'Description';
$lang->build->files = 'Upload Files';
$lang->build->last = 'Last Build';
$lang->build->packageType = 'Package Type';
$lang->build->unlinkStory = 'Unlink Story';
$lang->build->unlinkBug = 'Unlink Bug';
$lang->build->stories = 'Finished Story';
+2
View File
@@ -29,6 +29,7 @@ $lang->build->basicInfo = '基本信息';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = '平台/分支';
$lang->build->project = '所属' . $lang->projectCommon;
$lang->build->name = '名称编号';
$lang->build->date = '打包日期';
@@ -38,6 +39,7 @@ $lang->build->filePath = '下载地址';
$lang->build->desc = '描述';
$lang->build->files = '上传发行包';
$lang->build->last = '上个版本';
$lang->build->packageType = '包类型';
$lang->build->unlinkStory = '移除需求';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
+2 -1
View File
@@ -13,7 +13,6 @@ $lang->build->common = "版本";
$lang->build->create = "創建版本";
$lang->build->edit = "編輯版本";
$lang->build->linkStory = "關聯需求";
$lang->build->linked2build = "关联關聯版本";
$lang->build->linkBug = "關聯Bug";
$lang->build->delete = "刪除版本";
$lang->build->deleted = "已刪除";
@@ -30,6 +29,7 @@ $lang->build->basicInfo = '基本信息';
$lang->build->id = 'ID';
$lang->build->product = $lang->productCommon;
$lang->build->branch = '平台/分支';
$lang->build->project = '所屬' . $lang->projectCommon;
$lang->build->name = '名稱編號';
$lang->build->date = '打包日期';
@@ -39,6 +39,7 @@ $lang->build->filePath = '下載地址';
$lang->build->desc = '描述';
$lang->build->files = '上傳發行包';
$lang->build->last = '上個版本';
$lang->build->packageType = '包類型';
$lang->build->unlinkStory = '移除需求';
$lang->build->unlinkBug = '移除Bug';
$lang->build->stories = '完成的需求';
+2 -1
View File
@@ -66,7 +66,7 @@ class buildModel extends model
->where('t1.project')->eq((int)$projectID)
->andWhere('t1.deleted')->eq(0)
->orderBy('t1.date DESC, t1.id desc')
->fetchAll();
->fetchAll('id');
}
/**
@@ -200,6 +200,7 @@ class buildModel extends model
->stripTags($this->config->build->editor->create['id'], $this->config->allowedTags)
->remove('resolvedBy,allchecker,files,labels,uid')
->get();
if($this->config->global->flow == 'onlyTest') $build->project = 0;
$build = $this->loadModel('file')->processImgURL($build, $this->config->build->editor->create['id'], $this->post->uid);
$this->dao->insert(TABLE_BUILD)->data($build)
+1
View File
@@ -13,6 +13,7 @@
<?php include '../../common/view/header.html.php';?>
<?php js::set('confirmUnlinkStory', $lang->build->confirmUnlinkStory)?>
<?php js::set('confirmUnlinkBug', $lang->build->confirmUnlinkBug)?>
<?php js::set('flow', $this->config->global->flow)?>
<?php if(isonlybody()):?>
<style>
#stories .action{display:none;}
+12 -12
View File
@@ -124,7 +124,7 @@ $lang->searchObjects['release'] = 'Release';
$lang->searchObjects['productplan'] = $lang->productCommon . 'Plan';
$lang->searchObjects['testtask'] = 'Test Task';
$lang->searchObjects['doc'] = 'Document';
$lang->searchObjects['caselib'] = 'Case Library';
$lang->searchObjects['testcase'] = 'Case Library';
$lang->searchObjects['testreport'] = 'Test Report';
$lang->searchTips = 'ID (ctrl+g)';
@@ -249,7 +249,7 @@ $lang->bug = new stdclass();
$lang->bug->menu = new stdclass();
$lang->bug->menu->product = array('link' => '%s', 'fixed' => true);
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit,resolve,close,activate,report,batchedit,confirmbug,assignto', 'subModule' => 'tree');
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit,resolve,close,activate,report,batchedit,batchactivate,confirmbug,assignto', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => 'Case|testcase|browse|productID=%s');
$lang->bug->menu->testtask = array('link' => 'Build|testtask|browse|productID=%s');
$lang->bug->menu->testsuite = array('link' => 'Suite|testsuite|browse|productID=%s');
@@ -449,16 +449,16 @@ $lang->browserNotice = 'Your current browser might not show the best effect
$lang->noticePasteImg = "Paste image to editor.";
/* 时间格式设置。*/
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', 'M 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');
if(!defined('DT_DATETIME1')) define('DT_DATETIME1', 'Y-m-d H:i:s');
if(!defined('DT_DATETIME2')) define('DT_DATETIME2', 'y-m-d H:i');
if(!defined('DT_MONTHTIME1'))define('DT_MONTHTIME1', 'n/d H:i');
if(!defined('DT_MONTHTIME2'))define('DT_MONTHTIME2', 'n月d日 H:i');
if(!defined('DT_DATE1')) define('DT_DATE1', 'Y-m-d');
if(!defined('DT_DATE2')) define('DT_DATE2', 'Ymd');
if(!defined('DT_DATE3')) define('DT_DATE3', 'Y年m月d日');
if(!defined('DT_DATE4')) define('DT_DATE4', 'n月j日');
if(!defined('DT_TIME1')) define('DT_TIME1', 'H:i:s');
if(!defined('DT_TIME2')) define('DT_TIME2', 'H:i');
/* datepicker 时间*/
$lang->datepicker = new stdclass();
+11 -11
View File
@@ -249,7 +249,7 @@ $lang->bug = new stdclass();
$lang->bug->menu = new stdclass();
$lang->bug->menu->product = array('link' => '%s', 'fixed' => true);
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit,resolve,close,activate,report,batchedit,confirmbug,assignto', 'subModule' => 'tree');
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit,resolve,close,activate,report,batchedit,batchactivate,confirmbug,assignto', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => '用例|testcase|browse|productID=%s');
$lang->bug->menu->testtask = array('link' => '版本|testtask|browse|productID=%s');
$lang->bug->menu->testsuite = array('link' => '套件|testsuite|browse|productID=%s');
@@ -449,16 +449,16 @@ $lang->browserNotice = '你目前使用的浏览器可能无法得到最佳
$lang->noticePasteImg = "可以在编辑器直接贴图。";
/* 时间格式设置。*/
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');
if(!defined('DT_DATETIME1')) define('DT_DATETIME1', 'Y-m-d H:i:s');
if(!defined('DT_DATETIME2')) define('DT_DATETIME2', 'y-m-d H:i');
if(!defined('DT_MONTHTIME1'))define('DT_MONTHTIME1', 'n/d H:i');
if(!defined('DT_MONTHTIME2'))define('DT_MONTHTIME2', 'n月d日 H:i');
if(!defined('DT_DATE1')) define('DT_DATE1', 'Y-m-d');
if(!defined('DT_DATE2')) define('DT_DATE2', 'Ymd');
if(!defined('DT_DATE3')) define('DT_DATE3', 'Y年m月d日');
if(!defined('DT_DATE4')) define('DT_DATE4', 'n月j日');
if(!defined('DT_TIME1')) define('DT_TIME1', 'H:i:s');
if(!defined('DT_TIME2')) define('DT_TIME2', 'H:i');
/* datepicker 时间*/
$lang->datepicker = new stdclass();
+12 -12
View File
@@ -124,7 +124,7 @@ $lang->searchObjects['release'] = '發佈';
$lang->searchObjects['productplan'] = $lang->productCommon . '計劃';
$lang->searchObjects['testtask'] = '測試版本';
$lang->searchObjects['doc'] = '文檔';
$lang->searchObjects['caselib'] = '用例庫';
$lang->searchObjects['testcase'] = '用例庫';
$lang->searchObjects['testreport'] = '測試報告';
$lang->searchTips = '編號(ctrl+g)';
@@ -249,7 +249,7 @@ $lang->bug = new stdclass();
$lang->bug->menu = new stdclass();
$lang->bug->menu->product = array('link' => '%s', 'fixed' => true);
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit,resolve,close,activate,report,batchedit,confirmbug,assignto', 'subModule' => 'tree');
$lang->bug->menu->bug = array('link' => 'Bug|bug|browse|productID=%s', 'alias' => 'view,create,batchcreate,edit,resolve,close,activate,report,batchedit,batchactivate,confirmbug,assignto', 'subModule' => 'tree');
$lang->bug->menu->testcase = array('link' => '用例|testcase|browse|productID=%s');
$lang->bug->menu->testtask = array('link' => '版本|testtask|browse|productID=%s');
$lang->bug->menu->testsuite = array('link' => '套件|testsuite|browse|productID=%s');
@@ -449,16 +449,16 @@ $lang->browserNotice = '你目前使用的瀏覽器可能無法得到最佳
$lang->noticePasteImg = "可以在編輯器直接貼圖。";
/* 時間格式設置。*/
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');
if(!defined('DT_DATETIME1')) define('DT_DATETIME1', 'Y-m-d H:i:s');
if(!defined('DT_DATETIME2')) define('DT_DATETIME2', 'y-m-d H:i');
if(!defined('DT_MONTHTIME1'))define('DT_MONTHTIME1', 'n/d H:i');
if(!defined('DT_MONTHTIME2'))define('DT_MONTHTIME2', 'n月d日 H:i');
if(!defined('DT_DATE1')) define('DT_DATE1', 'Y-m-d');
if(!defined('DT_DATE2')) define('DT_DATE2', 'Ymd');
if(!defined('DT_DATE3')) define('DT_DATE3', 'Y年m月d日');
if(!defined('DT_DATE4')) define('DT_DATE4', 'n月j日');
if(!defined('DT_TIME1')) define('DT_TIME1', 'H:i:s');
if(!defined('DT_TIME2')) define('DT_TIME2', 'H:i');
/* datepicker 時間*/
$lang->datepicker = new stdclass();
+3 -5
View File
@@ -249,9 +249,7 @@ class commonModel extends model
echo "<li class='divider'></li>";
}
$isLeft = ($app->company->website and $app->company->backyard) ? '' : ' left';
echo "<li class='dropdown-submenu{$isLeft}'>";
echo "<li class='dropdown-submenu left'>";
echo "<a href='javascript:;'>" . $lang->theme . "</a><ul class='dropdown-menu'>";
foreach ($app->lang->themes as $key => $value)
{
@@ -259,7 +257,7 @@ class commonModel extends model
}
echo '</ul></li>';
echo "<li class='dropdown-submenu{$isLeft}'>";
echo "<li class='dropdown-submenu left'>";
echo "<a href='javascript:;'>" . $lang->lang . "</a><ul class='dropdown-menu'>";
foreach ($app->config->langs as $key => $value)
{
@@ -1132,7 +1130,7 @@ class commonModel extends model
global $app, $lang;
/* Check is the super admin or not. */
if($app->user->admin) return true;
if(!empty($app->user->admin)) return true;
/* If not super admin, check the rights. */
$rights = $app->user->rights['rights'];
+1
View File
@@ -25,6 +25,7 @@ $lang->company->zipcode = 'Zip Code';
$lang->company->website = 'Website';
$lang->company->backyard = 'Intranet';
$lang->company->guest = 'Guest Login';
$lang->company->admins = 'Administrators';
$lang->company->product = $lang->productCommon;
$lang->company->project = $lang->projectCommon;
+1
View File
@@ -25,6 +25,7 @@ $lang->company->zipcode = '邮政编码';
$lang->company->website = '官网';
$lang->company->backyard = '内网';
$lang->company->guest = '匿名登录';
$lang->company->admins = '管理员';
$lang->company->product = $lang->productCommon;
$lang->company->project = $lang->projectCommon;
+1
View File
@@ -25,6 +25,7 @@ $lang->company->zipcode = '郵政編碼';
$lang->company->website = '官網';
$lang->company->backyard = '內網';
$lang->company->guest = '匿名登錄';
$lang->company->admins = '管理員';
$lang->company->product = $lang->productCommon;
$lang->company->project = $lang->projectCommon;
+8 -8
View File
@@ -12,8 +12,8 @@
class custom extends control
{
/**
* Index
*
* Index
*
* @access public
* @return void
*/
@@ -23,11 +23,11 @@ class custom extends control
}
/**
* Custom
*
* @param string $module
* @param string $field
* @param string $lang
* Custom
*
* @param string $module
* @param string $field
* @param string $lang
* @access public
* @return void
*/
@@ -107,7 +107,7 @@ class custom extends control
/* Fix bug #942. */
if($field == 'priList' and !is_numeric($key)) die(js::alert($this->lang->custom->notice->priListKey));
if($module == 'bug' and $field == 'severityList' and !is_numeric($key)) die(js::alert($this->lang->custom->notice->severityListKey));
if($module == 'bug' and $field == 'resolutionList' and !empty($key) and !validater::checkCode($key)) die(js::alert($this->lang->custom->notice->resolutionList));
if(!empty($key) and !validater::checkCode($key)) die(js::alert($this->lang->custom->notice->keyList));
/* the length of role is 20, check it when save. */
if($module == 'user' and $field == 'roleList' and strlen($key) > 20) die(js::alert($this->lang->custom->notice->userRole));
+5 -1
View File
@@ -9,6 +9,10 @@ $lang->custom->flow = 'Process';
$lang->custom->working = 'Working';
$lang->custom->select = 'Select Process';
$lang->custom->branch = 'Multi Branch';
$lang->custom->owner = 'Owner';
$lang->custom->module = 'Module';
$lang->custom->section = 'Section';
$lang->custom->lang = 'Language';
$lang->custom->object['story'] = 'Story';
$lang->custom->object['task'] = 'Task';
@@ -79,7 +83,7 @@ $lang->custom->notice->canNotAdd = 'This item will be processed, so c
$lang->custom->notice->forceReview = 'Review is required for %s submitted by certain assignee.';
$lang->custom->notice->longlife = 'List "Undone" bugs that are older than hold days from "Longlife" bugs.';
$lang->custom->notice->priListKey = 'Priority list key should be numbers!';
$lang->custom->notice->resolutionList = 'Solution list key should be English or digital!';
$lang->custom->notice->keyList = 'key should be English or digital!';
$lang->custom->notice->severityListKey = 'Bug severity list key should be numbers.';
$lang->custom->notice->indexPage['product'] = "ZenTao 8.2+ has Product Homepage. Do you want to enter Product Homepage?";
$lang->custom->notice->indexPage['project'] = "ZenTao 8.2+ has Project Homepage. Do you want to enter Project Homepage?";
+5 -1
View File
@@ -9,6 +9,10 @@ $lang->custom->flow = '流程';
$lang->custom->working = '工作方式';
$lang->custom->select = '请选择流程:';
$lang->custom->branch = '多分支';
$lang->custom->owner = '所有者';
$lang->custom->module = '模块';
$lang->custom->section = '附加部分';
$lang->custom->lang = '所属语言';
$lang->custom->object['story'] = '需求';
$lang->custom->object['task'] = '任务';
@@ -79,7 +83,7 @@ $lang->custom->notice->canNotAdd = '该项参与运算,不提供自
$lang->custom->notice->forceReview = "指定人提交的%s必须评审。";
$lang->custom->notice->longlife = 'Bug列表页面的久未处理标签中,列出设置天数之前未处理的Bug。';
$lang->custom->notice->priListKey = '优先级的键应当为数字!';
$lang->custom->notice->resolutionList = '解决方案的键值应当为英文或数字';
$lang->custom->notice->keyList = '键值应当为英文或数字';
$lang->custom->notice->severityListKey = 'Bug严重程度的键应当为数字!';
$lang->custom->notice->indexPage['product'] = "从8.2版本起增加了产品主页视图,是否默认进入产品主页?";
$lang->custom->notice->indexPage['project'] = "从8.2版本起增加了项目主页视图,是否默认进入项目主页?";
+5 -1
View File
@@ -9,6 +9,10 @@ $lang->custom->flow = '流程';
$lang->custom->working = '工作方式';
$lang->custom->select = '請選擇流程:';
$lang->custom->branch = '多分支';
$lang->custom->owner = '所有者';
$lang->custom->module = '模組';
$lang->custom->section = '附加部分';
$lang->custom->lang = '所屬語言';
$lang->custom->object['story'] = '需求';
$lang->custom->object['task'] = '任務';
@@ -79,7 +83,7 @@ $lang->custom->notice->canNotAdd = '該項參與運算,不提供自
$lang->custom->notice->forceReview = "指定人提交的%s必須評審。";
$lang->custom->notice->longlife = 'Bug列表頁面的久未處理標籤中,列出設置天數之前未處理的Bug。';
$lang->custom->notice->priListKey = '優先順序的鍵應當為數字!';
$lang->custom->notice->resolutionList = '解決方案的鍵值應當為英文或數字';
$lang->custom->notice->keyList = '鍵值應當為英文或數字';
$lang->custom->notice->severityListKey = 'Bug嚴重程度的鍵應當為數字!';
$lang->custom->notice->indexPage['product'] = "從8.2版本起增加了產品主頁視圖,是否預設進入產品主頁?";
$lang->custom->notice->indexPage['project'] = "從8.2版本起增加了項目主頁視圖,是否預設進入項目主頁?";
+26
View File
@@ -25,6 +25,7 @@ $config->dev->group['testreport'] = 'qa';
$config->dev->group['testsuite'] = 'qa';
$config->dev->group['testresult'] = 'qa';
$config->dev->group['testrun'] = 'qa';
$config->dev->group['suitecase'] = 'qa';
$config->dev->group['doc'] = 'doc';
$config->dev->group['doccontent'] = 'doc';
$config->dev->group['doclib'] = 'doc';
@@ -48,3 +49,28 @@ $config->dev->group['mail'] = 'admin';
$config->dev->group['backup'] = 'admin';
$config->dev->group['cron'] = 'admin';
$config->dev->group['dev'] = 'admin';
$config->dev->tableMap['storyspec'] = 'story';
$config->dev->tableMap['storystage'] = 'story';
$config->dev->tableMap['burn'] = 'task';
$config->dev->tableMap['projectproduct'] = 'project';
$config->dev->tableMap['projectstory'] = 'story';
$config->dev->tableMap['taskestimate'] = 'task';
$config->dev->tableMap['team'] = 'project';
$config->dev->tableMap['case'] = 'testcase';
$config->dev->tableMap['casestep'] = 'testcase';
$config->dev->tableMap['testresult'] = 'testtask';
$config->dev->tableMap['testrun'] = 'testtask';
$config->dev->tableMap['doccontent'] = 'doc';
$config->dev->tableMap['doclib'] = 'doc';
$config->dev->tableMap['grouppriv'] = 'group';
$config->dev->tableMap['usercontact'] = 'user-contacts';
$config->dev->tableMap['usergroup'] = 'user';
$config->dev->tableMap['userquery'] = 'search';
$config->dev->tableMap['usertpl'] = 'user-tpl';
$config->dev->tableMap['history'] = 'action-history';
$config->dev->tableMap['lang'] = 'custom';
$config->dev->tableMap['config'] = 'custom';
$config->dev->tableMap['mailqueue'] = 'mail';
$config->dev->tableMap['module'] = 'tree';
$config->dev->tableMap['suitecase'] = 'testcase';
+6 -6
View File
@@ -1,10 +1,10 @@
<?php
/**
* The control file of dev module of ZenTaoPMS.
*
*
* @copyright Copyright 2009-2010 QingDao Nature Easy Soft Network Technology Co,LTD (www.cnezsoft.com)
* @author chunsheng wang <chunsheng@cnezsoft.com>
* @package
* @package
* @uses control
* @license LGPL
* @version $Id$
@@ -14,7 +14,7 @@ class dev extends control
{
/**
* Get API of system.
*
*
* @access public
* @return void
*/
@@ -31,11 +31,11 @@ class dev extends control
$this->view->modules = $this->dev->getModules();
$this->display();
}
/**
* Get schema of database.
*
* @param string $table
*
* @param string $table
* @access public
* @return void
*/
+1 -1
View File
@@ -89,13 +89,13 @@ $lang->dev->tableList['branch'] = 'Branch';
$lang->dev->tableList['doccontent'] = 'Doc Content';
$lang->dev->tableList['storystage'] = 'Story Stage';
$lang->dev->tableList['tutorial'] = 'Tutorial';
$lang->dev->tableList['suitecase'] = 'Suite Case';
$lang->dev->groupList['my'] = 'Dashboard';
$lang->dev->groupList['product'] = $lang->productCommon;
$lang->dev->groupList['project'] = $lang->projectCommon;
$lang->dev->groupList['qa'] = 'Testing';
$lang->dev->groupList['doc'] = 'Document';
$lang->dev->groupList['report'] = 'Report';
$lang->dev->groupList['company'] = 'Company';
$lang->dev->groupList['admin'] = 'Admin';
$lang->dev->groupList['other'] = 'Others';
+1 -1
View File
@@ -89,13 +89,13 @@ $lang->dev->tableList['branch'] = '平台/分支';
$lang->dev->tableList['doccontent'] = '文档内容';
$lang->dev->tableList['storystage'] = '需求阶段';
$lang->dev->tableList['tutorial'] = '新手教程';
$lang->dev->tableList['suitecase'] = '套件用例';
$lang->dev->groupList['my'] = '我的地盘';
$lang->dev->groupList['product'] = $lang->productCommon;
$lang->dev->groupList['project'] = $lang->projectCommon;
$lang->dev->groupList['qa'] = '测试';
$lang->dev->groupList['doc'] = '文档';
$lang->dev->groupList['report'] = '统计';
$lang->dev->groupList['company'] = '组织';
$lang->dev->groupList['admin'] = '后台';
$lang->dev->groupList['other'] = '其他模块';
+1 -1
View File
@@ -89,13 +89,13 @@ $lang->dev->tableList['branch'] = '平台/分支';
$lang->dev->tableList['doccontent'] = '文檔內容';
$lang->dev->tableList['storystage'] = '需求階段';
$lang->dev->tableList['tutorial'] = '新手教程';
$lang->dev->tableList['suitecase'] = '套件用例';
$lang->dev->groupList['my'] = '我的地盤';
$lang->dev->groupList['product'] = $lang->productCommon;
$lang->dev->groupList['project'] = $lang->projectCommon;
$lang->dev->groupList['qa'] = '測試';
$lang->dev->groupList['doc'] = '文檔';
$lang->dev->groupList['report'] = '統計';
$lang->dev->groupList['company'] = '組織';
$lang->dev->groupList['admin'] = '後台';
$lang->dev->groupList['other'] = '其他模組';
+12 -6
View File
@@ -35,11 +35,13 @@ class devModel extends model
*/
public function getFields($table)
{
$module = substr($table, strpos($table, '_') + 1);
$module = substr($table, strpos($table, '_') + 1);
$aliasModule = $subLang = '';
try
{
if($module == 'case') $module = 'testcase';
$this->app->loadLang($module);
if(isset($this->config->dev->tableMap[$module])) $aliasModule = $this->config->dev->tableMap[$module];
if(strpos($aliasModule, '-') !== false) list($aliasModule, $subLang) = explode('-', $aliasModule);
$this->app->loadLang($aliasModule ? $aliasModule : $module);
}
catch(PDOException $e)
{
@@ -57,6 +59,7 @@ class devModel extends model
{
$this->sqlError($e);
}
foreach($rawFields as $rawField)
{
$firstPOS = strpos($rawField->type, '(');
@@ -64,6 +67,9 @@ class devModel extends model
$type = str_replace(array('big', 'small', 'medium', 'tiny'), '', $type);
$field = array();
$field['name'] = isset($this->lang->$module->{$rawField->field}) ? $this->lang->$module->{$rawField->field} : '';
if(empty($field['name']) and $aliasModule) $field['name'] = isset($this->lang->$aliasModule->{$rawField->field}) ? $this->lang->$aliasModule->{$rawField->field} : '';
if($subLang) $field['name'] = isset($this->lang->$aliasModule->$subLang->{$rawField->field}) ? $this->lang->$aliasModule->$subLang->{$rawField->field} : $field['name'];
if(!is_string($field['name'])) $field['name'] = '';
$field['null'] = $rawField->null;
if($type == 'enum' or $type == 'set')
@@ -226,18 +232,18 @@ class devModel extends model
/**
* Get all modules.
*
*
* @access public
* @return void
*/
public function getModules()
{
{
$moduleList = glob($this->app->getModuleRoot() . '*');
$modules = array();
foreach($moduleList as $module)
{
$module = basename($module);
if($module == 'editor' or $module == 'help' or $module == 'setting') continue;
if($module == 'editor' or $module == 'help' or $module == 'setting' or $module == 'common') continue;
$group = zget($this->config->dev->group, $module, 'other');
$modules[$group][] = $module;
}
+3 -3
View File
@@ -5,7 +5,7 @@
<?php foreach($lang->dev->groupList as $group => $groupName):?>
<div class='modulegroup'><?php echo $groupName?></div>
<?php foreach($modules[$group] as $module):?>
<?php
<?php
$active = ($module == $selectedModule) ? 'active' : '';
$moduleName = zget($lang->dev->tableList, $module, $module);
?>
@@ -18,7 +18,7 @@
<?php if($selectedModule):?>
<?php foreach($apis as $api):?>
<table class='table table-condensed table-striped table-bordered tablesorter table-fixed active-disabled' id="api">
<?php
<?php
$params = array();
if(isset($api['param']))
{
@@ -28,7 +28,7 @@
?>
<tr>
<th colspan="3">
<?php
<?php
echo $api['post'] ? 'GET/POST' : 'GET';
echo '&nbsp;&nbsp;' . $this->createLink($selectedModule, $api['name'], $params, 'json');
?>
-2
View File
@@ -655,8 +655,6 @@ class doc extends control
$this->view->viewType = $viewType;
$this->view->orderBy = $orderBy;
$this->view->objectID = $objectID;
$this->view->recTotal = $recTotal;
$this->view->recPerPage = $recPerPage;
$this->display();
}
+4
View File
@@ -40,6 +40,9 @@ $lang->doc->filePath = 'File Path';
$lang->doc->extension = 'Extension';
$lang->doc->size = 'Size';
$lang->doc->download = 'Download';
$lang->doc->acl = 'Right';
$lang->doc->groups = 'Groups';
$lang->doc->users = 'Users';
$lang->doc->moduleDoc = 'By Module';
$lang->doc->searchDoc = 'By Search';
@@ -107,6 +110,7 @@ $lang->doc->browseType = 'Categories';
$lang->doc->browseTypeList['list'] = 'List';
$lang->doc->browseTypeList['menu'] = 'Menu';
$lang->doc->browseTypeList['tree'] = 'Tree';
$lang->doc->browseTypeList['card'] = 'Card';
$lang->doc->confirmDelete = "Do you want to delete this document?";
$lang->doc->confirmDeleteLib = "Do you want to delete this Doc Lib?";
+4
View File
@@ -40,6 +40,9 @@ $lang->doc->filePath = '地址';
$lang->doc->extension = '类型';
$lang->doc->size = '大小';
$lang->doc->download = '下载';
$lang->doc->acl = '权限';
$lang->doc->groups = '分组';
$lang->doc->users = '用户';
$lang->doc->moduleDoc = '按模块浏览';
$lang->doc->searchDoc = '搜索';
@@ -107,6 +110,7 @@ $lang->doc->browseType = '浏览方式';
$lang->doc->browseTypeList['list'] = '列表';
$lang->doc->browseTypeList['menu'] = '目录';
$lang->doc->browseTypeList['tree'] = '树状图';
$lang->doc->browseTypeList['card'] = '卡片';
$lang->doc->confirmDelete = "您确定删除该文档吗?";
$lang->doc->confirmDeleteLib = "您确定删除该文档库吗?";
+4
View File
@@ -40,6 +40,9 @@ $lang->doc->filePath = '地址';
$lang->doc->extension = '類型';
$lang->doc->size = '大小';
$lang->doc->download = '下載';
$lang->doc->acl = '權限';
$lang->doc->groups = '分組';
$lang->doc->users = '用戶';
$lang->doc->moduleDoc = '按模組瀏覽';
$lang->doc->searchDoc = '搜索';
@@ -107,6 +110,7 @@ $lang->doc->browseType = '瀏覽方式';
$lang->doc->browseTypeList['list'] = '列表';
$lang->doc->browseTypeList['menu'] = '目錄';
$lang->doc->browseTypeList['tree'] = '樹狀圖';
$lang->doc->browseTypeList['card'] = '卡片';
$lang->doc->confirmDelete = "您確定刪除該文檔嗎?";
$lang->doc->confirmDeleteLib = "您確定刪除該文檔庫嗎?";
+48 -53
View File
@@ -28,72 +28,67 @@
echo html::hidden('pageID', isset($this->get->pageID) ? $this->get->pageID : 0);
}
?>
<div class='input-group input-group-sm'>
<div class='input-group input-group-sm w-200px'>
<?php echo html::input('title', $this->get->title, "class='form-control search-query' placeholder='{$lang->doc->fileTitle}'");?>
<span class='input-group-btn'>
<?php echo html::submitButton($lang->doc->search);?>
</span>
</div>
</form>
<?php echo html::backButton();?>
<div class='text-right pull-right'>
<?php
$changeType = "type=$type&objectID=$objectID&viewType=" . ($viewType == 'list' ? 'card' : 'list');
echo html::a(inLink('showFiles', $changeType), "<i class='icon icon-th-list icon-4x'></i> 切换界面布局");
?>
<div class="btn-group">
<button type="button" class="btn dropdown-toggle" data-toggle="dropdown"><i class='icon <?php echo $viewType == 'list' ? 'icon-list' : 'icon-th'?>'></i> <?php echo $lang->doc->browseTypeList[$viewType]?> <span class="caret"></span></button>
<ul class="dropdown-menu" role="menu">
<li><?php echo html::a(inlink('showFiles', "type=$type&objectID=$objectID&viewType=card"), "<i class='icon icon-th'></i> {$lang->doc->browseTypeList['card']}");?></li>
<li><?php echo html::a(inlink('showFiles', "type=$type&objectID=$objectID&viewType=list"), "<i class='icon icon-list'></i> {$lang->doc->browseTypeList['list']}");?></li>
</ul>
</div>
<?php echo html::backButton();?>
</div>
</div>
<?php if($viewType == 'list'):?>
<form method='post' id='ajaxForm'>
<table class='table table-hover table-striped tablesorter table-fixed' id='orderList'>
<thead>
<?php $vars = "type=$type&objectID=$objectID&viewType=list&orderBy=%s&recTotal=$recTotal&recPerPage=$recPerPage";?>
<tr class='text-center'>
<th class='w-80px'> <?php common::printOrderLink('t1.id', $orderBy, $vars, $lang->doc->id);?> </th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->doc->fileTitle);?> </th>
<th> <?php common::printOrderLink('pathname', $orderBy, $vars, $lang->doc->filePath);?> </th>
<th class='w-60px'> <?php common::printOrderLink('extension', $orderBy, $vars, $lang->doc->extension);?> </th>
<th class='w-80px'> <?php common::printOrderLink('size', $orderBy, $vars, $lang->doc->size);?> </th>
<th class='w-100px'> <?php common::printOrderLink('addedBy', $orderBy, $vars, $lang->doc->addedBy);?> </th>
<th class='w-160px'> <?php common::printOrderLink('addedDate', $orderBy, $vars, $lang->doc->addedDate);?> </th>
<th class='w-80px'> <?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($files as $file):?>
<?php if(empty($file->pathname)) continue;?>
<tr class='text-center text-middle'>
<td>
<?php echo $file->id;?>
</td>
<td class='text-left'>
<?php echo $file->title;?>
</td>
<td class='text-left'> <?php echo $file->pathname;?> </td>
<td><?php echo $file->extension;?></td>
<td><?php echo number_format($file->size / 1024 , 1) . 'K';?></td>
<td><?php echo isset($file->addedBy) ? $file->addedBy : '';?></td>
<td><?php echo isset($file->addedDate) ? substr($file->addedDate, 0, 10) : '';?></td>
<td class='text-center'>
<?php
common::printLink('file', 'download', "fileID=$file->id", $lang->doc->download, "data-toggle='modal'");
common::printLink('file', 'delete', "fileID=$file->id", $lang->delete, 'hiddenwin');
?>
</td>
</tr>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='8'>
<?php $pager->show();?>
<table class='table table-hover table-striped tablesorter table-fixed' id='orderList'>
<thead>
<?php $vars = "type=$type&objectID=$objectID&viewType=list&orderBy=%s&recTotal=$pager->recTotal&recPerPage=$pager->recPerPage";?>
<tr class='text-center'>
<th class='w-80px'> <?php common::printOrderLink('t1.id', $orderBy, $vars, $lang->doc->id);?> </th>
<th> <?php common::printOrderLink('title', $orderBy, $vars, $lang->doc->fileTitle);?> </th>
<th> <?php common::printOrderLink('pathname', $orderBy, $vars, $lang->doc->filePath);?> </th>
<th class='w-60px'> <?php common::printOrderLink('extension', $orderBy, $vars, $lang->doc->extension);?> </th>
<th class='w-80px'> <?php common::printOrderLink('size', $orderBy, $vars, $lang->doc->size);?> </th>
<th class='w-100px'> <?php common::printOrderLink('addedBy', $orderBy, $vars, $lang->doc->addedBy);?> </th>
<th class='w-160px'> <?php common::printOrderLink('addedDate', $orderBy, $vars, $lang->doc->addedDate);?> </th>
<th class='w-80px'> <?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody>
<?php foreach($files as $file):?>
<?php if(empty($file->pathname)) continue;?>
<tr class='text-center text-middle'>
<td><?php echo $file->id;?></td>
<td class='text-left'>
<a href='<?php echo $this->createLink($file->objectType, 'view', "objectID=$file->objectID");?>'><?php echo $file->title . '.' . $file->extension . ' [' . strtoupper($file->objectType) . ' #' . $file->objectID . ']';?></a>
</td>
<td class='text-left'> <?php echo $file->pathname;?> </td>
<td><?php echo $file->extension;?></td>
<td><?php echo number_format($file->size / 1024 , 1) . 'K';?></td>
<td><?php echo isset($file->addedBy) ? $file->addedBy : '';?></td>
<td><?php echo isset($file->addedDate) ? substr($file->addedDate, 0, 10) : '';?></td>
<td class='text-center'>
<?php
common::printLink('file', 'download', "fileID=$file->id", $lang->doc->download, "data-toggle='modal'");
common::printLink('file', 'delete', "fileID=$file->id", $lang->delete, 'hiddenwin');
?>
</td>
</tr>
</tfoot>
</table>
</form>
<?php endforeach;?>
</tbody>
<tfoot>
<tr>
<td colspan='8'> <?php $pager->show();?> </td>
</tr>
</tfoot>
</table>
<?php else:?>
<div class='lib-files cards'>
<?php foreach($files as $file):?>
+9 -1
View File
@@ -30,8 +30,14 @@ $lang->extension->installed = 'Installed';
$lang->extension->deactivated = 'Deactivated';
$lang->extension->available = 'Downloaded';
$lang->extension->name = 'Extension Name';
$lang->extension->code = 'Code';
$lang->extension->desc = 'Describe';
$lang->extension->type = 'Type';
$lang->extension->dirs = 'Directories';
$lang->extension->files = 'Files';
$lang->extension->status = 'Status';
$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://api.zentao.net/goto.php?item=latest" target="_blank"><strong>%s</strong></small>';
$lang->extension->author = 'Author';
$lang->extension->license = 'License';
@@ -40,6 +46,8 @@ $lang->extension->downloads = 'Downloads';
$lang->extension->compatible = 'Compatibility';
$lang->extension->grade = 'Score';
$lang->extension->depends = 'Dependent';
$lang->extension->zentaoCompatible = 'Compatible Version';
$lang->extension->installedTime = 'Installed Time';
$lang->extension->publicList[0] = 'Manually';
$lang->extension->publicList[1] = 'Auto';
+9 -1
View File
@@ -30,8 +30,14 @@ $lang->extension->installed = '已安装';
$lang->extension->deactivated = '被禁用';
$lang->extension->available = '已下载';
$lang->extension->name = '插件名称';
$lang->extension->code = '代号';
$lang->extension->desc = '描述';
$lang->extension->type = '类型';
$lang->extension->dirs = '安装目录';
$lang->extension->files = '安装文件';
$lang->extension->status = '状态';
$lang->extension->version = '版本';
$lang->extension->compatible = '适用版本';
$lang->extension->latest = '<small>最新版本<strong><a href="%s" target="_blank" class="extension">%s</a></strong>,兼容禅道<a href="http://api.zentao.net/goto.php?item=latest" target="_blank" class="alert-link"><strong>%s</strong></a></small>';
$lang->extension->author = '作者';
$lang->extension->license = '授权';
@@ -40,6 +46,8 @@ $lang->extension->downloads = '下载量';
$lang->extension->compatible = '兼容性';
$lang->extension->grade = '评分';
$lang->extension->depends = '依赖';
$lang->extension->zentaoCompatible = '适用版本';
$lang->extension->installedTime = '安装时间';
$lang->extension->publicList[0] = '手工下载';
$lang->extension->publicList[1] = '直接下载';
+9 -1
View File
@@ -30,8 +30,14 @@ $lang->extension->installed = '已安裝';
$lang->extension->deactivated = '被禁用';
$lang->extension->available = '已下載';
$lang->extension->name = '插件名稱';
$lang->extension->code = '代號';
$lang->extension->desc = '描述';
$lang->extension->type = '類型';
$lang->extension->dirs = '安裝目錄';
$lang->extension->files = '安裝檔案';
$lang->extension->status = '狀態';
$lang->extension->version = '版本';
$lang->extension->compatible = '適用版本';
$lang->extension->latest = '<small>最新版本<strong><a href="%s" target="_blank" class="extension">%s</a></strong>,兼容禪道<a href="http://api.zentao.net/goto.php?item=latest" target="_blank" class="alert-link"><strong>%s</strong></a></small>';
$lang->extension->author = '作者';
$lang->extension->license = '授權';
@@ -40,6 +46,8 @@ $lang->extension->downloads = '下載量';
$lang->extension->compatible = '兼容性';
$lang->extension->grade = '評分';
$lang->extension->depends = '依賴';
$lang->extension->zentaoCompatible = '適用版本';
$lang->extension->installedTime = '安裝時間';
$lang->extension->publicList[0] = '手工下載';
$lang->extension->publicList[1] = '直接下載';
+9
View File
@@ -30,6 +30,15 @@ $lang->file->addFile = 'Add File';
$lang->file->beginUpload = 'Start uploading';
$lang->file->uploadSuccess = 'uploaded Successfully';
$lang->file->pathname = 'Path Name';
$lang->file->title = 'Title';
$lang->file->extension = 'Extension';
$lang->file->size = 'Size';
$lang->file->addedBy = 'Added By';
$lang->file->addedDate = 'Added Date';
$lang->file->downloads = 'Downloads';
$lang->file->extra = 'Extra';
$lang->file->dragFile = 'Please drag here.';
$lang->file->errorNotExists = "<span class='red'>'%s' is not found.</span>";
$lang->file->errorCanNotWrite = "<span class='red'>'%s' is not writable. Please change its permission. Enter sudo chmod -R 777 '%s'</span> in Linux.";
+9
View File
@@ -30,6 +30,15 @@ $lang->file->addFile = '添加文件';
$lang->file->beginUpload = '开始上传';
$lang->file->uploadSuccess = '上传成功';
$lang->file->pathname = '路径';
$lang->file->title = '标题';
$lang->file->extension = '扩展名';
$lang->file->size = '大小';
$lang->file->addedBy = '由谁添加';
$lang->file->addedDate = '添加时间';
$lang->file->downloads = '下载次数';
$lang->file->extra = '备注';
$lang->file->dragFile = '请拖拽文件到此处';
$lang->file->errorNotExists = "<span class='red'>文件夹 '%s' 不存在</span>";
$lang->file->errorCanNotWrite = "<span class='red'>文件夹 '%s' 不可写,请改变文件夹的权限。在linux中输入指令:sudo chmod -R 777 %s</span>";
+11 -2
View File
@@ -30,9 +30,18 @@ $lang->file->addFile = '添加檔案';
$lang->file->beginUpload = '開始上傳';
$lang->file->uploadSuccess = '上傳成功';
$lang->file->pathname = '路徑';
$lang->file->title = '標題';
$lang->file->extension = '副檔名';
$lang->file->size = '大小';
$lang->file->addedBy = '由誰添加';
$lang->file->addedDate = '添加時間';
$lang->file->downloads = '下載次數';
$lang->file->extra = '備註';
$lang->file->dragFile = '請拖拽檔案到此處';
$lang->file->errorNotExists = "<span class='red'>檔案夾 '%s' 不存在</span>";
$lang->file->errorCanNotWrite = "<span class='red'>檔案夾 '%s' 不可寫,請改變檔案夾的權限。在linux中輸入指令:sudo chmod -R 777 '%s'</span>";
$lang->file->errorCanNotWrite = "<span class='red'>檔案夾 '%s' 不可寫,請改變檔案夾的權限。在linux中輸入指令:sudo chmod -R 777 %s</span>";
$lang->file->confirmDelete = " 您確定刪除該附件嗎?";
$lang->file->errorFileSize = " 檔案大小已經超過限制,可能不能成功上傳!";
$lang->file->errorFileUpload = " 檔案上傳失敗,檔案大小可能超出限制";
@@ -41,4 +50,4 @@ $lang->file->errorFileMove = " 檔案上傳失敗,移動檔案時出錯";
$lang->file->dangerFile = " 您選擇的檔案存在安全風險,系統將不予上傳。";
$lang->file->errorSuffix = '壓縮包格式錯誤,只能上傳zip壓縮包!';
$lang->file->errorExtract = '解壓縮失敗!可能檔案已經損壞,或壓縮包裡含有非法上傳檔案。';
$lang->file->uploadImagesExplain = '註:請上傳"jpg|jpeg|gif|png"格式的圖片,程序會以檔案名作為標題,以圖片作為內容。';
$lang->file->uploadImagesExplain = '註:請上傳"jpg, jpeg, gif, png"格式的圖片,程序會以檔案名作為標題,以圖片作為內容。';
+2
View File
@@ -627,6 +627,8 @@ class fileModel extends model
public function processImgURL($data, $editorList, $uid = '')
{
if(is_string($editorList)) $editorList = explode(',', str_replace(' ', '', $editorList));
if(empty($editorList)) return $data;
$readLinkReg = helper::createLink('file', 'read', 'fileID=(%fileID%)', '(%viewType%)');
$readLinkReg = str_replace(array('%fileID%', '%viewType%', '?', '/'), array('[0-9]+', '\w+', '\?', '\/'), $readLinkReg);
$imageIdList = array();
+2 -1
View File
@@ -18,7 +18,8 @@ $config->git->encodings = 'utf-8';
$config->git->client = '';
$i = 1;
$config->git->repos[$i]['path'] = '';
$config->git->repos[$i]['path'] = '';
$config->git->repos[$i]['encoding'] = 'utf-8';
/*
$i ++;
+26 -6
View File
@@ -426,13 +426,23 @@ class gitModel extends model
exec("{$this->client} config core.quotepath false");
$subPath = substr($path, strlen($repo->path));
if($subPath{0} == '/' or $subPath{0} == '\\') $subPath = substr($subPath, 1);
$encodings = explode(',', $this->config->git->encodings);
foreach($encodings as $encoding)
{
$encoding = trim($encoding);
if($encoding == 'utf-8') continue;
$subPath = helper::convertEncoding($subPath, 'utf-8', $encoding);
if($subPath) break;
}
exec("$this->client rev-list -n 2 $revision -- $subPath", $lists);
if(count($lists) == 2) list($nowRevision, $preRevision) = $lists;
$cmd = "$this->client diff $preRevision $nowRevision -- $subPath";
$cmd = "$this->client diff $preRevision $nowRevision -- $subPath 2>&1";
$diff = `$cmd`;
$encodings = isset($repo->encodings) ? $repo->encodings : $this->config->svn->encodings;
if($encodings or $encodings != 'utf-8') $diff = helper::convertEncoding($diff, $encodings);
$encoding = isset($repo->encoding) ? $repo->encoding : 'utf-8';
if($encoding and $encoding != 'utf-8') $diff = helper::convertEncoding($diff, $encoding);
return $diff;
}
@@ -457,13 +467,23 @@ class gitModel extends model
$subPath = substr($path, strlen($repo->path));
if($subPath{0} == '/' or $subPath{0} == '\\') $subPath = substr($subPath, 1);
$encodings = explode(',', $this->config->git->encodings);
foreach($encodings as $encoding)
{
$encoding = trim($encoding);
if($encoding == 'utf-8') continue;
$subPath = helper::convertEncoding($subPath, 'utf-8', $encoding);
if($subPath) break;
}
chdir($repo->path);
exec("{$this->client} config core.quotepath false");
$cmd = "$this->client show $revision:$subPath";
$cmd = "$this->client show $revision:$subPath 2>&1";
$code = `$cmd`;
$encodings = isset($repo->encodings) ? $repo->encodings : $this->config->git->encodings;
if($encodings or $encodings != 'utf-8') $code = helper::convertEncoding($code, $encodings);
$encoding = isset($repo->encoding) ? $repo->encoding : 'utf-8';
if($encoding and $encoding != 'utf-8') $code = helper::convertEncoding($code, $encoding);
return $code;
}
+2
View File
@@ -32,6 +32,8 @@ $lang->group->noticeVisit = 'N/A means access is not restricted.';
$lang->group->id = 'ID';
$lang->group->name = 'Name';
$lang->group->desc = 'Description';
$lang->group->role = 'Role';
$lang->group->acl = 'Right';
$lang->group->users = 'Users';
$lang->group->module = 'Module';
$lang->group->method = 'Method';
+2
View File
@@ -32,6 +32,8 @@ $lang->group->noticeVisit = '空代表访问没有访问限制';
$lang->group->id = '编号';
$lang->group->name = '分组名称';
$lang->group->desc = '分组描述';
$lang->group->role = '角色';
$lang->group->acl = '权限';
$lang->group->users = '用户列表';
$lang->group->module = '模块';
$lang->group->method = '方法';
+2
View File
@@ -32,6 +32,8 @@ $lang->group->noticeVisit = '空代表訪問沒有訪問限制';
$lang->group->id = '編號';
$lang->group->name = '分組名稱';
$lang->group->desc = '分組描述';
$lang->group->role = '角色';
$lang->group->acl = '權限';
$lang->group->users = '用戶列表';
$lang->group->module = '模組';
$lang->group->method = '方法';
+7 -6
View File
@@ -375,16 +375,17 @@ class groupModel extends model
}
/**
* Check menu have module
*
* @param string $menu
* @param string $moduleName
* Check menu have module
*
* @param string $menu
* @param string $moduleName
* @access public
* @return void
*/
public function checkMenuModule($menu, $moduleName)
{
if(empty($menu)) return true;
if($menu == 'caselib' and $moduleName == 'testsuite') return true;
if($menu == 'other' and (isset($this->lang->menugroup->$moduleName) or isset($this->lang->menu->$moduleName))) return false;
if($menu != 'other' and !($moduleName == $menu or (isset($this->lang->menugroup->$moduleName) and $this->lang->menugroup->$moduleName == $menu))) return false;
return true;
@@ -392,8 +393,8 @@ class groupModel extends model
/**
* Get modules in menu
*
* @param string $menu
*
* @param string $menu
* @access public
* @return void
*/
+2 -2
View File
@@ -60,7 +60,7 @@
}
?>
<tr class='<?php echo cycle('even, bg-gray');?>'>
<th class='text-right w-150px'><?php echo $this->lang->$moduleName->common;?><?php echo html::selectAll($moduleName, 'checkbox')?></th>
<th class='text-right w-150px'><?php echo $lang->$moduleName->common;?><?php echo html::selectAll($moduleName, 'checkbox')?></th>
<td id='<?php echo $moduleName;?>' class='pv-10px'>
<?php $i = 1;?>
<?php if($moduleName == 'caselib') $moduleName = 'testsuite';?>
@@ -77,7 +77,7 @@
<tr>
<th class='text-right'><?php echo $lang->selectAll . html::selectAll('', 'checkbox')?></th>
<td>
<?php
<?php
echo html::submitButton($lang->save, "onclick='setNoChecked()'");
echo html::linkButton($lang->goback, $this->createLink('group', 'browse'));
echo html::hidden('foo'); // Just a hidden var, to make sure $_POST is not empty.
+1 -1
View File
@@ -265,7 +265,7 @@ class mail extends control
}
}
$this->mail->send($this->post->to, $this->lang->mail->subject, $this->lang->mail->content, "", true);
$this->mail->send($this->post->to, $this->lang->mail->testSubject, $this->lang->mail->testContent, "", true);
if($this->mail->isError())
{
$this->view->error = $this->mail->getError();
+4 -3
View File
@@ -42,7 +42,8 @@ $lang->mail->sync = 'Synchronize';
$lang->mail->remove = 'Remove';
$lang->mail->toList = 'Addressee';
$lang->mail->subjectName = 'Subject';
$lang->mail->ccList = 'Copy to';
$lang->mail->subject = 'Subject';
$lang->mail->addedBy = 'Sender';
$lang->mail->addedDate = 'Added Date';
$lang->mail->sendTime = 'Send Date';
@@ -74,8 +75,8 @@ $lang->mail->noticeResend = 'Sent it again!';
$lang->mail->inputFromEmail = 'Enter Email Address';
$lang->mail->nextStep = 'Next';
$lang->mail->successSaved = 'Configuration has been saved.';
$lang->mail->subject = 'Testing Email';
$lang->mail->content = 'Email configured!';
$lang->mail->testSubject = 'Testing Email';
$lang->mail->testContent = 'Email configured!';
$lang->mail->successSended = 'Sent!';
$lang->mail->confirmDelete = 'Do you want to delete it?';
$lang->mail->sendmailTips = 'Note: Email author will not receive this email.';
+4 -3
View File
@@ -42,7 +42,8 @@ $lang->mail->sync = '同步';
$lang->mail->remove = '移除';
$lang->mail->toList = '收信人';
$lang->mail->subjectName = '主题';
$lang->mail->ccList = '抄送给';
$lang->mail->subject = '主题';
$lang->mail->addedBy = '发送者';
$lang->mail->addedDate = '创建时间';
$lang->mail->sendTime = '发送时间';
@@ -74,8 +75,8 @@ $lang->mail->noticeResend = '已经重新发信!';
$lang->mail->inputFromEmail = '请输入发信邮箱:';
$lang->mail->nextStep = '下一步';
$lang->mail->successSaved = '配置信息已经成功保存。';
$lang->mail->subject = '测试邮件';
$lang->mail->content = '邮箱设置成功';
$lang->mail->testSubject = '测试邮件';
$lang->mail->testContent = '邮箱设置成功';
$lang->mail->successSended = '成功发送!';
$lang->mail->confirmDelete = '是否删除邮件?';
$lang->mail->sendmailTips = '提示:系统不会为当前操作者发信。';
+4 -3
View File
@@ -42,7 +42,8 @@ $lang->mail->sync = '同步';
$lang->mail->remove = '移除';
$lang->mail->toList = '收信人';
$lang->mail->subjectName = '主題';
$lang->mail->ccList = '抄送給';
$lang->mail->subject = '主題';
$lang->mail->addedBy = '發送者';
$lang->mail->addedDate = '創建時間';
$lang->mail->sendTime = '發送時間';
@@ -74,8 +75,8 @@ $lang->mail->noticeResend = '已經重新發信!';
$lang->mail->inputFromEmail = '請輸入發信郵箱:';
$lang->mail->nextStep = '下一步';
$lang->mail->successSaved = '配置信息已經成功保存。';
$lang->mail->subject = '測試郵件';
$lang->mail->content = '郵箱設置成功';
$lang->mail->testSubject = '測試郵件';
$lang->mail->testContent = '郵箱設置成功';
$lang->mail->successSended = '成功發送!';
$lang->mail->confirmDelete = '是否刪除郵件?';
$lang->mail->sendmailTips = '提示:系統不會為當前操作者發信。';
+1 -1
View File
@@ -22,7 +22,7 @@
<tr>
<th class='w-id'> <?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?></th>
<th class='w-80px'> <?php common::printOrderLink('toList', $orderBy, $vars, $lang->mail->toList);?></th>
<th class='w-150px'> <?php common::printOrderLink('subject', $orderBy, $vars, $lang->mail->subjectName);?></th>
<th class='w-150px'> <?php common::printOrderLink('subject', $orderBy, $vars, $lang->mail->subject);?></th>
<th class='w-80px'> <?php common::printOrderLink('addedBy', $orderBy, $vars, $lang->mail->addedBy);?></th>
<th class='w-150px'> <?php common::printOrderLink('addedDate', $orderBy, $vars, $lang->mail->addedDate);?></th>
<th class='w-150px'> <?php common::printOrderLink('sendTime', $orderBy, $vars, $lang->mail->sendTime);?></th>
+1 -1
View File
@@ -62,7 +62,7 @@ $lang->misc->tableName = "Table Name";
$lang->misc->tableStatus = "Status";
$lang->misc->novice = "First time to ZenTao? Do you want to start rookie mode?";
$lang->user->noticeResetFile = "<h5>If you are not Administrator, please contact Administrator to repair table.</h5>
$lang->misc->noticeRepair = "<h5>If you are not Administrator, please contact Administrator to repair table.</h5>
<h5>If you are, please login into your Zentao host and create the <span>%s</span> file.</h5>
<p>Note:</p>
<ol>
+2 -2
View File
@@ -62,13 +62,13 @@ $lang->misc->tableName = "表名";
$lang->misc->tableStatus = "狀態";
$lang->misc->novice = "您可能初次使用禪道,是否進入新手模式?";
$lang->user->noticeResetFile = "<h5>普通用戶請聯繫管理員進行修復</h5>
$lang->misc->noticeRepair = "<h5>普通用戶請聯繫管理員進行修復</h5>
<h5>管理員請登錄禪道所在的伺服器,創建<span>%s</span>檔案。</h5>
<p>注意:</p>
<ol>
<li>檔案內容為空。</li>
<li>如果之前檔案存在,刪除之後重新創建。</li>
</ol>";
</ol>";
$lang->misc->feature = new stdclass();
$lang->misc->feature->lastest = '最新版本';
+15 -9
View File
@@ -53,9 +53,12 @@ class my extends control
{
/* Save session. */
$uri = $this->app->getURI(true);
$this->session->set('todoList', $uri);
$this->session->set('bugList', $uri);
$this->session->set('taskList', $uri);
if($this->app->viewType != 'json')
{
$this->session->set('todoList', $uri);
$this->session->set('bugList', $uri);
$this->session->set('taskList', $uri);
}
/* Load pager. */
$this->app->loadClass('pager', $static = true);
@@ -98,7 +101,7 @@ class my extends control
public function story($type = 'assignedTo', $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Save session. */
$this->session->set('storyList', $this->app->getURI(true));
if($this->app->viewType != 'json') $this->session->set('storyList', $this->app->getURI(true));
/* Load pager. */
$this->app->loadClass('pager', $static = true);
@@ -136,8 +139,11 @@ class my extends control
public function task($type = 'assignedTo', $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Save session. */
$this->session->set('taskList', $this->app->getURI(true));
$this->session->set('storyList', $this->app->getURI(true));
if($this->app->viewType != 'json')
{
$this->session->set('taskList', $this->app->getURI(true));
$this->session->set('storyList', $this->app->getURI(true));
}
/* Load pager. */
$this->app->loadClass('pager', $static = true);
@@ -176,7 +182,7 @@ class my extends control
public function bug($type = 'assignedTo', $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Save session. load Lang. */
$this->session->set('bugList', $this->app->getURI(true));
if($this->app->viewType != 'json') $this->session->set('bugList', $this->app->getURI(true));
$this->app->loadLang('bug');
/* Load pager. */
@@ -219,7 +225,7 @@ class my extends control
$pager = pager::init($recTotal, $recPerPage, $pageID);
/* Save session. */
$this->session->set('testtaskList', $this->app->getURI(true));
if($this->app->viewType != 'json') $this->session->set('testtaskList', $this->app->getURI(true));
$this->app->loadLang('testcase');
@@ -254,7 +260,7 @@ class my extends control
public function testcase($type = 'assigntome', $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1)
{
/* Save session, load lang. */
$this->session->set('caseList', $this->app->getURI(true));
if($this->app->viewType != 'json') $this->session->set('caseList', $this->app->getURI(true));
$this->app->loadLang('testcase');
$this->app->loadLang('testtask');
+18
View File
@@ -4,3 +4,21 @@ function changeDate(date)
link = createLink('my', 'todo', 'type=' + date);
location.href=link;
}
$(function()
{
// Support hash start with todo-1
var hash = window.location.hash.toLowerCase();
if(hash.indexOf('#todo-') === 0)
{
var todoId = hash.substr(6);
var url = createLink('todo', 'view', 'id=1&from=my&onlybody=yes');
var $a = $('<a/>');
$a.attr({href: url}).modalTrigger(
{
'data-toggle': 'modal',
type: 'iframe'
}).trigger('click');
}
});
+10 -10
View File
@@ -99,14 +99,14 @@ class product extends control
/**
* Browse a product.
*
* @param int $productID
* @param string $browseType
* @param int $param
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
*
* @param int $productID
* @param string $browseType
* @param int $param
* @param string $orderBy
* @param int $recTotal
* @param int $recPerPage
* @param int $pageID
* @access public
* @return void
*/
@@ -136,8 +136,8 @@ class product extends control
if($browseType == 'bymodule') setcookie('storyModule', (int)$param, $this->config->cookieLife, $this->config->webRoot);
if($browseType != 'bymodule') $this->session->set('storyBrowseType', $browseType);
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->storyModule ? $this->cookie->storyModule : 0));
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
$moduleID = ($browseType == 'bymodule') ? (int)$param : ($browseType == 'bysearch' ? 0 : ($this->cookie->storyModule ? $this->cookie->storyModule : 0));
$queryID = ($browseType == 'bysearch') ? (int)$param : 0;
/* Set menu. */
$this->product->setMenu($this->products, $productID, $branch);
+1 -1
View File
@@ -41,7 +41,7 @@
<td><?php echo $users[$build->builder]?></td>
<td class='text-right'>
<?php
common::printIcon('testtask', 'create', "product=0&product=$product->id&build=$build->id", '', 'list', 'check');
common::printIcon('testtask', 'create', "product=$product->id&project=0&build=$build->id", '', 'list', 'check');
common::printIcon('build', 'edit', "buildID=$build->id", '', 'list');
if(common::hasPriv('build', 'delete'))
{
+2 -1
View File
@@ -39,6 +39,7 @@ $lang->productplan->confirmUnlinkBug = "Do you want to unlink this Bug?";
$lang->productplan->id = 'ID';
$lang->productplan->product = $lang->productCommon;
$lang->productplan->branch = 'Platform/Branch';
$lang->productplan->title = 'Title';
$lang->productplan->desc = 'Description';
$lang->productplan->begin = 'Begin';
@@ -58,6 +59,6 @@ $lang->productplan->errorNoBegin = 'ID %s begin time should not be empty.';
$lang->productplan->errorNoEnd = 'ID %s end time should not be empty.';
$lang->productplan->beginGeEnd = 'ID %s begin time value should not be greater than t.';
$lang->productplan->featureBar['browse']['unexpired'] = 'On Time';
$lang->productplan->featureBar['browse']['all'] = 'All';
$lang->productplan->featureBar['browse']['unexpired'] = 'On Time';
$lang->productplan->featureBar['browse']['overdue'] = 'Overdue';
+1
View File
@@ -39,6 +39,7 @@ $lang->productplan->confirmUnlinkBug = "您确认移除该Bug吗?";
$lang->productplan->id = '编号';
$lang->productplan->product = $lang->productCommon;
$lang->productplan->branch = '平台/分支';
$lang->productplan->title = '名称';
$lang->productplan->desc = '描述';
$lang->productplan->begin = '开始日期';
+2 -1
View File
@@ -39,6 +39,7 @@ $lang->productplan->confirmUnlinkBug = "您確認移除該Bug嗎?";
$lang->productplan->id = '編號';
$lang->productplan->product = $lang->productCommon;
$lang->productplan->branch = '平台/分支';
$lang->productplan->title = '名稱';
$lang->productplan->desc = '描述';
$lang->productplan->begin = '開始日期';
@@ -58,6 +59,6 @@ $lang->productplan->errorNoBegin = 'ID %s 開始時間不能為空';
$lang->productplan->errorNoEnd = 'ID %s 結束時間不能為空';
$lang->productplan->beginGeEnd = 'ID %s 開始時間不能大於結束時間';
$lang->productplan->featureBar['browse']['unexpired'] = '未過期';
$lang->productplan->featureBar['browse']['all'] = '全部';
$lang->productplan->featureBar['browse']['unexpired'] = '未過期';
$lang->productplan->featureBar['browse']['overdue'] = '已過期';
+2 -2
View File
@@ -140,7 +140,7 @@ class productplanModel extends model
public function create()
{
$plan = fixer::input('post')->stripTags($this->config->productplan->editor->create['id'], $this->config->allowedTags)->remove('delta,uid')->get();
$plan = $this->loadModel('file')->processImgURL($plan, $this->config->plan->editor->create['id'], $this->post->uid);
$plan = $this->loadModel('file')->processImgURL($plan, $this->config->productplan->editor->create['id'], $this->post->uid);
$this->dao->insert(TABLE_PRODUCTPLAN)
->data($plan)
->autoCheck()
@@ -166,7 +166,7 @@ class productplanModel extends model
{
$oldPlan = $this->dao->findByID((int)$planID)->from(TABLE_PRODUCTPLAN)->fetch();
$plan = fixer::input('post')->stripTags($this->config->productplan->editor->edit['id'], $this->config->allowedTags)->remove('delta,uid')->get();
$plan = $this->loadModel('file')->processImgURL($plan, $this->config->plan->editor->edit['id'], $this->post->uid);
$plan = $this->loadModel('file')->processImgURL($plan, $this->config->productplan->editor->edit['id'], $this->post->uid);
$this->dao->update(TABLE_PRODUCTPLAN)
->data($plan)
->autoCheck()
+6 -5
View File
@@ -18,7 +18,7 @@ table th.col-closed {width:15%}
#kanbanWrapper tbody tr.dragging td.col-droppable.drop-to .board-task + .board-shadow {margin-top: 6px;}
#kanbanWrapper tbody tr.dragging td.col-droppable.drop-to .board-shadow {height: 28px; background: #999; background: rgba(0,0,0,0.35); opacity: 1;}
#kanbanWrapper tbody tr.dragging td.col-droppable.drop-to.drag-from .board-shadow {display: none}
#kanbanWrapper .board.drag-from {opacity: 0.8}
#kanbanWrapper .board.drag-from.dragging {opacity: 0.8;}
#kanban.dragging, .drag-shadow {cursor: move!important;}
@@ -34,10 +34,11 @@ table th.col-closed {width:15%}
.board-actions .btn:active, .board-actions .btn:focus, .board-actions .btn:hover {background: #999; color: inherit; background: rgba(255,255,255,.2);}
.ie-8 .board-actions .btn {min-width: 10px}
.board-actions > .dropdown {display: inline-block; margin-left: -5px;}
.dropdown .caret {border-top-color: #999}
.dropdown-menu > a {display: block; padding: 3px 15px; color: #333; font-size: 12px}
.dropdown-menu > a:hover {background: #f1f1f1; color: #1a53ff; text-decoration: none}
.dropdown-menu > a.disabled, .dropdown-menu > a.disabled:hover, .dropdown-menu > a.active {color: #aaa; background: none}
.board .dropdown-menu {min-width: 60px;}
.board .dropdown .caret {border-top-color: #999}
.board .dropdown-menu > a {display: block; padding: 3px 15px; color: #333; font-size: 12px}
.board .dropdown-menu > a:hover {background: #f1f1f1; color: #1a53ff; text-decoration: none}
.board .dropdown-menu > a.disabled, .board .dropdown-menu > a.disabled:hover, .board .dropdown-menu > a.active {color: #aaa; background: none}
.board .board-footer {display: none; opacity: 0.9}
.board.show-info .board-footer {display: block; margin: 0 -6px -3px -6px; padding: 5px; background: rgba(0,0,0,0.07);}
.board-footer .board-id {display: inline-block; border: 1px solid #aaa; font-weight: normal; padding: 0px 4px; text-align: center; min-width: 20px; line-height: 16px; height: 17px; margin-right: 10px; font-size: 12px;}
+2
View File
@@ -51,6 +51,7 @@ $lang->project->mine = 'My Responsibility: ';
$lang->project->other = 'Other:';
$lang->project->deleted = 'Deleted';
$lang->project->delayed = 'Delayed';
$lang->project->product = $lang->project->products;
$lang->project->start = 'Start';
$lang->project->activate = 'Activate';
@@ -197,6 +198,7 @@ $lang->project->confirmDelete = "Do you want to delete {$lang->projectCo
$lang->project->confirmUnlinkMember = "Do you want to unlink this User from {$lang->projectCommon}?";
$lang->project->confirmUnlinkStory = "Do you want to unlink this Story from {$lang->projectCommon}?";
$lang->project->errorNoLinkedProducts = "No linked {$lang->productCommon} found in {$lang->projectCommon}. You will be directed to {$lang->productCommon}linked page.";
$lang->project->errorSameProducts = "{$lang->projectCommon} cannot be associated with multiple identical {$lang->productCommon}。";
$lang->project->accessDenied = "Access to {$lang->projectCommon} denied!";
$lang->project->tips = 'Note';
$lang->project->afterInfo = "{$lang->projectCommon} is created. Next you can ";
+1
View File
@@ -51,6 +51,7 @@ $lang->project->mine = '我负责:';
$lang->project->other = '其他:';
$lang->project->deleted = '已删除';
$lang->project->delayed = '已延期';
$lang->project->product = $lang->project->products;
$lang->project->start = '开始';
$lang->project->activate = '激活';
+2
View File
@@ -51,6 +51,7 @@ $lang->project->mine = '我負責:';
$lang->project->other = '其他:';
$lang->project->deleted = '已刪除';
$lang->project->delayed = '已延期';
$lang->project->product = $lang->project->products;
$lang->project->start = '開始';
$lang->project->activate = '激活';
@@ -197,6 +198,7 @@ $lang->project->confirmDelete = "您確定刪除{$lang->projectCommon}[%
$lang->project->confirmUnlinkMember = "您確定從該{$lang->projectCommon}中移除該用戶嗎?";
$lang->project->confirmUnlinkStory = "您確定從該{$lang->projectCommon}中移除該需求嗎?";
$lang->project->errorNoLinkedProducts = "該{$lang->projectCommon}沒有關聯的{$lang->productCommon},系統將轉到{$lang->productCommon}關聯頁面";
$lang->project->errorSameProducts = "{$lang->projectCommon}不能關聯多個相同的{$lang->productCommon}。";
$lang->project->accessDenied = "您無權訪問該{$lang->projectCommon}!";
$lang->project->tips = '提示';
$lang->project->afterInfo = "{$lang->projectCommon}添加成功,您現在可以進行以下操作:";
+1 -1
View File
@@ -60,7 +60,7 @@
<td class='text-left' title="<?php echo $task->name?>">
<?php if(isset($branchGroups[$task->product][$task->branch])) echo "<span title='{$lang->product->branchName[$task->productType]}' class='label label-branch label-badge'>" . $branchGroups[$task->product][$task->branch] . '</span>';?>
<?php if($modulePairs and $task->module) echo "<span title='{$lang->task->module}' class='label label-info label-badge'>" . $modulePairs[$task->module] . '</span>';?>
<?php
<?php
if(!common::printLink('task', 'view', "task=$task->id", $task->name, null, "style='color: $task->color'")) echo $task->name;
if($task->fromBug) echo html::a($this->createLink('bug', 'view', "id=$task->fromBug"), "[BUG#$task->fromBug]", '_blank', "class='bug'");
?>
+2
View File
@@ -31,6 +31,7 @@ $lang->release->basicInfo = 'Basic Info';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = 'Platform/Branch';
$lang->release->build = 'Build';
$lang->release->name = 'Name';
$lang->release->date = 'Date';
@@ -41,6 +42,7 @@ $lang->release->unlinkStory = 'Unlink Story';
$lang->release->unlinkBug = 'Unlink Bug';
$lang->release->stories = 'Finished Story';
$lang->release->bugs = 'Solved Bug';
$lang->release->leftBugs = 'Remained Bug';
$lang->release->generatedBugs = 'Remained Bug';
$lang->release->finishStories = 'Finished %s Story';
$lang->release->resolvedBugs = 'Solved %s Bug';
+2
View File
@@ -31,6 +31,7 @@ $lang->release->basicInfo = '基本信息';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = '平台/分支';
$lang->release->build = '版本';
$lang->release->name = '发布名称';
$lang->release->date = '发布日期';
@@ -41,6 +42,7 @@ $lang->release->unlinkStory = '移除需求';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解决的Bug';
$lang->release->leftBugs = '遗留的Bug';
$lang->release->generatedBugs = '遗留的Bug';
$lang->release->finishStories = '本次共完成 %s 个需求';
$lang->release->resolvedBugs = '本次共解决 %s 个Bug';
+2
View File
@@ -31,6 +31,7 @@ $lang->release->basicInfo = '基本信息';
$lang->release->id = 'ID';
$lang->release->product = $lang->productCommon;
$lang->release->branch = '平台/分支';
$lang->release->build = '版本';
$lang->release->name = '發佈名稱';
$lang->release->date = '發佈日期';
@@ -41,6 +42,7 @@ $lang->release->unlinkStory = '移除需求';
$lang->release->unlinkBug = '移除Bug';
$lang->release->stories = '完成的需求';
$lang->release->bugs = '解決的Bug';
$lang->release->leftBugs = '遺留的Bug';
$lang->release->generatedBugs = '遺留的Bug';
$lang->release->finishStories = '本次共完成 %s 個需求';
$lang->release->resolvedBugs = '本次共解決 %s 個Bug';
+1
View File
@@ -80,6 +80,7 @@ $lang->report->bugTitle = 'Bug標題';
$lang->report->taskName = '任務名稱';
$lang->report->todoName = '待辦名稱';
$lang->report->testTaskName = '版本名稱';
$lang->report->deadline = '截止日期';
$lang->report->mailTitle = new stdclass();
$lang->report->mailTitle->begin = '提醒:您有';
+7
View File
@@ -25,6 +25,13 @@ $lang->search->me = 'Me';
$lang->search->noQuery = 'No query saved!';
$lang->search->onMenuBar = 'Show in Menu';
$lang->search->account = 'Account';
$lang->search->module = 'Module';
$lang->search->title = 'Title';
$lang->search->form = 'Form Field';
$lang->search->sql = 'SQL Condition';
$lang->search->shortcut = $lang->search->onMenuBar;
$lang->search->operators['='] = '=';
$lang->search->operators['!='] = '!=';
$lang->search->operators['>'] = '>';
+7
View File
@@ -25,6 +25,13 @@ $lang->search->me = '自己';
$lang->search->noQuery = '还没有保存查询!';
$lang->search->onMenuBar = '显示在菜单栏';
$lang->search->account = '用户名';
$lang->search->module = '模块';
$lang->search->title = '名称';
$lang->search->form = '表单字段';
$lang->search->sql = 'SQL条件';
$lang->search->shortcut = $lang->search->onMenuBar;
$lang->search->operators['='] = '=';
$lang->search->operators['!='] = '!=';
$lang->search->operators['>'] = '>';
+7
View File
@@ -25,6 +25,13 @@ $lang->search->me = '自己';
$lang->search->noQuery = '還沒有保存查詢!';
$lang->search->onMenuBar = '顯示在菜單欄';
$lang->search->account = '用戶名';
$lang->search->module = '模組';
$lang->search->title = '名稱';
$lang->search->form = '表單欄位';
$lang->search->sql = 'SQL條件';
$lang->search->shortcut = $lang->search->onMenuBar;
$lang->search->operators['='] = '=';
$lang->search->operators['!='] = '!=';
$lang->search->operators['>'] = '>';
+7 -3
View File
@@ -22,7 +22,6 @@ class sso extends control
{
$referer = empty($_GET['referer']) ? '' : $this->get->referer;
$locate = empty($referer) ? getWebRoot() : base64_decode($referer);
if($this->loadModel('user')->isLogon()) die($this->locate($locate));
$this->app->loadConfig('sso');
if(!$this->config->sso->turnon) die($this->locate($locate));
@@ -40,9 +39,9 @@ class sso extends control
if(strpos($location, '&') !== false)
{
$location = rtrim($location, '&') . "&token=$token&auth=$auth&userIP=$userIP&callback=$callback&referer=$referer";
}
}
else
{
{
$location = rtrim($location, '?') . "?token=$token&auth=$auth&userIP=$userIP&callback=$callback&referer=$referer";
}
$this->locate($location);
@@ -63,6 +62,11 @@ class sso extends control
$this->locate($this->createLink('sso', 'bind', "referer=" . helper::safe64Encode($locate)));
}
if($this->loadModel('user')->isLogon())
{
if($this->session->user && $this->session->user->account == $user->account) die($this->locate($locate));
}
$this->user->cleanLocked($user->account);
/* Authorize him and save to session. */
$user->rights = $this->user->authorize($user->account);
+1 -1
View File
@@ -12,7 +12,7 @@
$lang->sso = new stdclass();
$lang->sso->settings = '配置';
$lang->sso->turnon = '是否打開';
$lang->sso->redirect = '自動跳回然之';
$lang->sso->redirect = '自動跳迥然之';
$lang->sso->code = '代號';
$lang->sso->key = '密鑰';
$lang->sso->addr = '介面地址';
+7 -3
View File
@@ -1,4 +1,4 @@
<?php
<?php
/**
* The model file of story module of ZenTaoPMS.
*
@@ -372,6 +372,11 @@ class storyModel extends model
{
$specChanged = false;
$oldStory = $this->dao->findById((int)$storyID)->from(TABLE_STORY)->fetch();
$oldSpec = $this->dao->select('title,spec,verify')->from(TABLE_STORYSPEC)->where('story')->eq((int)$storyID)->andWhere('version')->eq($oldStory->version)->fetch();
$oldStory->title = isset($oldSpec->title) ? $oldSpec->title : '';
$oldStory->spec = isset($oldSpec->spec) ? $oldSpec->spec : '';
$oldStory->verify = isset($oldSpec->verify) ? $oldSpec->verify : '';
if(!empty($_POST['lastEditedDate']) and $oldStory->lastEditedDate != $this->post->lastEditedDate)
{
dao::$errors[] = $this->lang->error->editedByOther;
@@ -1991,10 +1996,9 @@ class storyModel extends model
foreach($datas as $key => $project)
{
if(!$project->branch) continue;
$branchIDList[] = $project->branch;
$branchIDList[$project->branch] = $project->branch;
}
$branchIDList = array_unique($branchIDList);
$branchs = $this->dao->select('id, name')->from(TABLE_BRANCH)->where('id')->in($branchIDList)->andWhere('deleted')->eq(0)->fetchALL('id');
$modules = $this->loadModel('tree')->getModulesName(array_keys($datas));
+1
View File
@@ -21,6 +21,7 @@ $config->svn->client = '';
$i = 1;
$config->svn->repos[$i]['path'] = '';
$config->svn->repos[$i]['encoding'] = 'utf-8';
$config->svn->repos[$i]['username'] = '';
$config->svn->repos[$i]['password'] = '';
+7 -7
View File
@@ -388,7 +388,7 @@ class svnModel extends model
foreach($encodings as $encoding)
{
if($encoding == 'utf-8') continue;
$result = @iconv($encoding, 'utf-8', $comment);
$result = helper::convertEncoding($comment, $encoding)
if($result) return $result;
}
@@ -417,11 +417,11 @@ class svnModel extends model
$url = str_replace('%2F', '/', urlencode($url));
$url = str_replace('%3A', ':', $url);
$cmd = $this->client . " diff -r $oldRevision:$revision $url";
$cmd = $this->client . " diff -r $oldRevision:$revision $url 2>&1";
$diff = `$cmd`;
$encodings = isset($repo->encodings) ? $repo->encodings : $this->config->svn->encodings;
if($encodings or $encodings != 'utf-8') $diff = helper::convertEncoding($diff, $encodings);
$encoding = isset($repo->encoding) ? $repo->encoding : 'utf-8';
if($encoding and $encoding != 'utf-8') $diff = helper::convertEncoding($diff, $encoding);
return $diff;
}
@@ -447,11 +447,11 @@ class svnModel extends model
$url = str_replace('%2F', '/', urlencode($url));
$url = str_replace('%3A', ':', $url);
$cmd = $this->client . " cat $url@$revision";
$cmd = $this->client . " cat $url@$revision 2>&1";
$code = `$cmd`;
$encodings = isset($repo->encodings) ? $repo->encodings : $this->config->svn->encodings;
if($encodings or $encodings != 'utf-8') $code = helper::convertEncoding($code, $encodings);
$encoding = isset($repo->encoding) ? $repo->encoding : 'utf-8';
if($encoding and $encoding != 'utf-8') $code = helper::convertEncoding($code, $encoding);
return $code;
}
+3
View File
@@ -1,2 +1,5 @@
.col-side .chosen-container .chosen-drop {width: 216px!important}
.col-side .chosen-container {width: 218px!important}
#finishedDate.form-control.form-date {width: 218px!important}
#canceledDate.form-control.form-date {width: 218px!important}
#closedDate.form-control.form-date {width: 218px!important}
+1 -1
View File
@@ -939,7 +939,7 @@ class taskModel extends model
/**
* Get project tasks pairs.
*
*
* @param int $projectID
* @param string $status
* @param string $orderBy
+13 -13
View File
@@ -80,7 +80,7 @@
<tr>
<th><?php echo $lang->task->assignedTo;?></th>
<td><span id="assignedToIdBox"><?php echo html::select('assignedTo', $members, $task->assignedTo, "class='form-control chosen'");?></span></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->type;?></th>
<td><?php echo html::select('type', $lang->task->typeList, $task->type, 'class=form-control');?></td>
@@ -88,7 +88,7 @@
<tr>
<th><?php echo $lang->task->status;?></th>
<td><?php echo html::select('status', (array)$lang->task->statusList, $task->status, 'class=form-control');?></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->pri;?></th>
<td><?php echo html::select('pri', $lang->task->priList, $task->pri, 'class=form-control');?> </td>
@@ -101,27 +101,27 @@
</fieldset>
<fieldset>
<legend><?php echo $lang->task->legendEffort;?></legend>
<table class='table table-form'>
<table class='table table-form'>
<tr>
<th class='w-70px'><?php echo $lang->task->estStarted;?></th>
<td><?php echo html::input('estStarted', $task->estStarted, "class='form-control form-date'");?></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->realStarted;?></th>
<td><?php echo html::input('realStarted', $task->realStarted, "class='form-control form-date'");?></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->deadline;?></th>
<td><?php echo html::input('deadline', $task->deadline, "class='form-control form-date'");?></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->estimate;?></th>
<td><?php echo html::input('estimate', $task->estimate, "class='form-control' autocomplete='off'");?></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->consumed;?></th>
<td><?php echo $task->consumed . ' '; common::printIcon('task', 'recordEstimate', "taskID=$task->id", $task, 'list', '', '', 'iframe', true);?></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->task->left;?></th>
<td><?php echo html::input('left', $task->left, "class='form-control' autocomplete='off'");?></td>
@@ -130,14 +130,14 @@
</fieldset>
<fieldset>
<legend><?php echo $lang->task->legendLife;?></legend>
<table class='table table-form'>
<table class='table table-form'>
<tr>
<th class='w-70px'><?php echo $lang->task->openedBy;?></th>
<td><?php echo $users[$task->openedBy];?></td>
</tr>
<tr>
<th><?php echo $lang->task->finishedBy;?></th>
<td><?php echo html::select('finishedBy', $members, $task->finishedBy, "class='form-control'");?></td>
<td><?php echo html::select('finishedBy', $members, $task->finishedBy, "class='form-control chosen'");?></td>
</tr>
<tr>
<th><?php echo $lang->task->finishedDate;?></th>
@@ -145,7 +145,7 @@
</tr>
<tr>
<th><?php echo $lang->task->canceledBy;?></th>
<td><?php echo html::select('canceledBy', $users, $task->canceledBy, 'class="form-control"');?></td>
<td><?php echo html::select('canceledBy', $users, $task->canceledBy, 'class="form-control chosen"');?></td>
</tr>
<tr>
<th><?php echo $lang->task->canceledDate;?></th>
@@ -153,11 +153,11 @@
</tr>
<tr>
<th><?php echo $lang->task->closedBy;?></th>
<td><?php echo html::select('closedBy', $users, $task->closedBy, 'class="form-control"');?></td>
<td><?php echo html::select('closedBy', $users, $task->closedBy, 'class="form-control chosen"');?></td>
</tr>
<tr>
<th><?php echo $lang->task->closedReason;?></th>
<td><?php echo html::select('closedReason', $lang->task->reasonList, $task->closedReason, 'class="form-control"');?></td>
<td><?php echo html::select('closedReason', $lang->task->reasonList, $task->closedReason, 'class="form-control chosen"');?></td>
</tr>
<tr>
<th><?php echo $lang->task->closedDate;?></th>
+1 -1
View File
@@ -1342,7 +1342,7 @@ class testcase extends control
if(empty($libID) or !isset($libraries[$libID])) $libID = key($libraries);
/* Build the search form. */
$actionURL = $this->createLink('testcase', 'importFromLib', "productID=$productID&branch=$branch&libID=$libID&browseType=bySearch&queryID=myQueryID");
$actionURL = $this->createLink('testcase', 'importFromLib', "productID=$productID&branch=$branch&libID=$libID&orderBy=$orderBy&browseType=bySearch&queryID=myQueryID");
$this->config->testcase->search['module'] = 'testsuite';
$this->config->testcase->search['onMenuBar'] = 'no';
$this->config->testcase->search['actionURL'] = $actionURL;

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