Merge branch 'master' of github.com:easysoft/zentaopms

This commit is contained in:
wangyidong
2019-03-18 16:56:38 +08:00
9 changed files with 24 additions and 4 deletions
+1 -1
View File
@@ -18,7 +18,7 @@ $config->doc->officeTypes = 'word,ppt,excel';
$config->doc->custom = new stdclass();
$config->doc->custom->objectLibs = $config->doc->customObjectLibs;
$config->doc->custom->showLibs = 'zero';
$config->doc->custom->showLibs = 'zero,children';
$config->doc->editor = new stdclass();
$config->doc->editor->create = array('id' => 'content', 'tools' => 'fullTools');
+1
View File
@@ -152,6 +152,7 @@ $lang->doc->customObjectLibs['customFiles'] = 'Show Custom Library';
$lang->doc->orderLib = 'Library order settings';
$lang->doc->customShowLibs = 'Library display settings';
$lang->doc->customShowLibsList['zero'] = 'Display empty library';
$lang->doc->customShowLibsList['children'] = 'Display sub-category documents';
$lang->doc->customShowLibsList['unclosed'] = 'Only display projects that are not closed';
$lang->doc->confirmDelete = "Do you want to delete this document?";
+1
View File
@@ -152,6 +152,7 @@ $lang->doc->customObjectLibs['customFiles'] = '显示自定义文档库';
$lang->doc->orderLib = '文档库排序';
$lang->doc->customShowLibs = '显示设置';
$lang->doc->customShowLibsList['zero'] = '显示空文档的库';
$lang->doc->customShowLibsList['children'] = '显示子分类的文档';
$lang->doc->customShowLibsList['unclosed'] = '只显示未关闭的项目';
$lang->doc->confirmDelete = "您确定删除该文档吗?";
+1 -1
View File
@@ -10,7 +10,7 @@
* @link http://www.zentao.net
*/
?>
<?php if(strpos($config->doc->officeTypes, $docType) !== false):?>
<?php if($docType != '' and strpos($config->doc->officeTypes, $docType) !== false):?>
<?php include '../../common/view/header.lite.html.php';?>
<div id="mainContent" class="main-content">
<div class='center-block'>
+1
View File
@@ -106,6 +106,7 @@ $lang->task->team = 'Team';
$lang->task->transfer = 'Transfer';
$lang->task->transferTo = 'Transfer To';
$lang->task->children = 'Child Task';
$lang->task->unlinkParent = 'Unlink Parent';
$lang->task->childrenAB = 'Child';
$lang->task->parent = 'Parent Task';
$lang->task->parentAB = 'Parent Task';
+1
View File
@@ -106,6 +106,7 @@ $lang->task->team = '团队';
$lang->task->transfer = '转交';
$lang->task->transferTo = '转交给';
$lang->task->children = '子任务';
$lang->task->unlinkParent = '取消子任务';
$lang->task->childrenAB = '子';
$lang->task->parent = '父任务';
$lang->task->parentAB = '父';
+10 -1
View File
@@ -79,6 +79,8 @@ class taskModel extends model
}
$requiredFields = trim($requiredFields, ',');
/* Fix Bug #2466 */
if($this->post->multiple) $task->assignedTo = '';
$this->dao->insert(TABLE_TASK)->data($task)
->autoCheck()
->batchCheck($requiredFields, 'notempty')
@@ -653,12 +655,13 @@ class taskModel extends model
->setIF($this->post->assignedTo != $oldTask->assignedTo, 'assignedDate', $now)
->setIF($this->post->status == 'wait' and $this->post->left == $oldTask->left and $this->post->consumed == 0 and $this->post->estimate, 'left', $this->post->estimate)
->setIF(isset($_POST['unlinkParent']), 'parent', 0)
->setDefault('lastEditedBy', $this->app->user->account)
->add('lastEditedDate', $now)
->stripTags($this->config->task->editor->edit['id'], $this->config->allowedTags)
->join('mailto', ',')
->remove('comment,files,labels,uid,multiple,team,teamEstimate,teamConsumed,teamLeft,contactListMenu')
->remove('comment,files,labels,uid,multiple,team,teamEstimate,teamConsumed,teamLeft,contactListMenu,unlinkParent')
->get();
if($task->consumed < $oldTask->consumed) die(js::error($this->lang->task->error->consumedSmall));
@@ -734,6 +737,7 @@ class taskModel extends model
if($oldTask->parent > 0)
{
if($task->parent == 0) $this->computeWorkingHours($oldTask->parent);
$this->updateParentStatus($taskID);
$this->computeBeginAndEnd($oldTask->parent);
}
@@ -1688,6 +1692,11 @@ class taskModel extends model
->andWhere('project')->eq($projectID)
->fetchPairs();
foreach($tasks as $id => $name)
{
$taskTeam = $this->dao->select('*')->from(TABLE_TEAM)->where('root')->eq($id)->andWhere('type')->eq('task')->fetch();
if(!empty($taskTeam)) unset($tasks[$id]);
}
return array('' => '') + $tasks ;
}
+6
View File
@@ -109,6 +109,12 @@
<td><?php echo html::select('parent', $tasks, $task->parent, "class='form-control chosen'");?></td>
</tr>
<?php endif;?>
<?php if($task->parent > 0):?>
<tr>
<th><?php echo $lang->task->unlinkParent;?></th>
<td><?php echo html::checkbox('unlinkParent', '');?></td>
</tr>
<?php endif;?>
<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>
+2 -1
View File
@@ -832,7 +832,8 @@ class testtask extends control
$caseResult = $this->testtask->createResult($runID);
if(dao::isError()) die(js::error(dao::getError()));
if($caseResult == 'fail') {
if($caseResult == 'fail')
{
$response['result'] = 'success';
$response['locate'] = $this->createLink('testtask', 'results',"runID=$runID&caseID=$caseID&version=$version");