Merge branch 'master' of github.com:easysoft/zentaopms
This commit is contained in:
@@ -337,7 +337,6 @@ class bug extends control
|
||||
$this->view->projectMembers = $projectMembers;
|
||||
$this->view->assignedTo = $assignedTo;
|
||||
$this->view->mailto = $mailto;
|
||||
$this->view->contactLists = $this->user->getContactLists($this->app->user->account, 'withnote');
|
||||
$this->view->keywords = $keywords;
|
||||
$this->view->severity = $severity;
|
||||
$this->view->type = $type;
|
||||
|
||||
@@ -69,7 +69,11 @@ js::set('bugBrowseType', ($browseType == 'bymodule' and $this->session->bugBrows
|
||||
{
|
||||
$wizardParams = helper::safe64Encode("productID=$productID&branch=$branch&extra=moduleID=$moduleID");
|
||||
common::printIcon('tutorial', 'wizard', "module=bug&method=create¶ms=$wizardParams", 'btn', 'button', 'plus', '', 'btn-bug-create', '', false, $lang->bug->create);
|
||||
} else common::printIcon('bug', 'create', "productID=$productID&branch=$branch&extra=moduleID=$moduleID", 'btn', 'button', 'plus', '', 'btn-bug-create');
|
||||
}
|
||||
else
|
||||
{
|
||||
common::printIcon('bug', 'create', "productID=$productID&branch=$branch&extra=moduleID=$moduleID", 'btn', 'button', 'plus', '', 'btn-bug-create');
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -214,14 +214,7 @@ js::set('refresh', $lang->refresh);
|
||||
<div class='input-group' id='contactListGroup'>
|
||||
<?php
|
||||
echo html::select('mailto[]', $users, str_replace(' ', '', $mailto), "class='form-control chosen' multiple");
|
||||
if($contactLists) echo html::select('', $contactLists, '', "class='form-control' style='min-width: 100px; margin-left: -1px' onchange=\"setMailto('mailto', this.value)\"");
|
||||
if(empty($contactLists))
|
||||
{
|
||||
echo '<span class="input-group-btn">';
|
||||
echo '<a href="' . $this->createLink('my', 'managecontacts', "listID=0&mode=new") . '" target="_blank" data-toggle="tooltip" class="btn" title="' . $lang->user->contacts->manage . '"><i class="icon icon-cog"></i></a>';
|
||||
echo '<a href="###" onclick="ajaxGetContacts(this)" data-toggle="tooltip" class="btn" title="' . $lang->refresh . '"><i class="icon icon-refresh"></i></a>';
|
||||
echo '</span>';
|
||||
}
|
||||
echo $this->fetch('my', 'buildContactLists');
|
||||
?>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
+14
-4
@@ -420,17 +420,27 @@ class my extends control
|
||||
{
|
||||
if($confirm == 'no')
|
||||
{
|
||||
echo js::confirm($this->lang->user->contacts->confirmDelete, inlink('deleteContacts', "listID=$listID&confirm=yes"));
|
||||
exit;
|
||||
die(js::confirm($this->lang->user->contacts->confirmDelete, inlink('deleteContacts', "listID=$listID&confirm=yes")));
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->user->deleteContactList($listID);
|
||||
echo js::locate(inlink('manageContacts'), 'parent');
|
||||
exit;
|
||||
die(js::locate(inlink('manageContacts'), 'parent'));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Build contact lists.
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function buildContactLists()
|
||||
{
|
||||
$this->view->contactLists = $this->user->getContactLists($this->app->user->account, 'withnote');
|
||||
$this->display();
|
||||
}
|
||||
|
||||
/**
|
||||
* View my profile.
|
||||
*
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
/**
|
||||
* The build contact lists view file of my 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 Fei Chen<chenfei@cnezsoft.com>
|
||||
* @package my
|
||||
* @version $Id$
|
||||
* @link http://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<?php
|
||||
if($contactLists)
|
||||
{
|
||||
echo html::select('', $contactLists, '', "class='form-control chosen' onchange=\"setMailto('mailto', this.value)\"");
|
||||
}
|
||||
else
|
||||
{
|
||||
echo '<span class="input-group-btn">';
|
||||
echo '<a data-toggle="tooltip" title="' . $lang->user->contacts->manage . '" href="' . $this->createLink('my', 'managecontacts', "listID=0&mode=new") . '" target="_blank" class="btn"><i class="icon icon-cog"></i></a>';
|
||||
echo '<a data-toggle="tooltip" title="' . $lang->refresh . '" href="###" class="btn" onclick="ajaxGetContacts(this)"><i class="icon icon-refresh"></i></a>';
|
||||
echo '</span>';
|
||||
}
|
||||
?>
|
||||
@@ -12,23 +12,24 @@
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<div class='row'>
|
||||
<?php if($mode == 'edit'):?>
|
||||
<div class='col-md-3 col-lg-2'>
|
||||
<div class='panel panel-sm with-list'>
|
||||
<div class='panel-heading'>
|
||||
<i class='icon-list-ul'></i> <strong><?php echo $lang->user->contacts->contactsList;?></strong>
|
||||
</div>
|
||||
<ul class='list-group'>
|
||||
<?php
|
||||
foreach($lists as $id => $listName)
|
||||
{
|
||||
$class = ($id == $listID) ? 'list-group-item active' : 'list-group-item';
|
||||
echo html::a(inlink('managecontacts', "listID=$id&mode=edit"), $listName, '', "class='{$class}'");
|
||||
$listClass = ($id == $listID) ? 'list-group-item active' : 'list-group-item';
|
||||
echo html::a(inlink('managecontacts', "listID=$id&mode=edit"), $listName, '', "class='{$listClass}'");
|
||||
}
|
||||
echo html::a(inlink('managecontacts', "listID=0&mode=new"), $lang->user->contacts->createList, '', "class='list-group-item'");
|
||||
?>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class='col-md-9 col-lg-10'>
|
||||
<?php endif;?>
|
||||
<?php $class = $mode == 'edit' ? 'col-md-9 col-lg-10' : 'col-md-12 col-lg-12';?>
|
||||
<div class='<?php echo $class?>'>
|
||||
<form class='form-condensed' method='post' target='hiddenwin' id='dataform'>
|
||||
<div class='panel panel-sm'>
|
||||
<div class='panel-heading'>
|
||||
@@ -37,18 +38,25 @@
|
||||
<?php else:?>
|
||||
<i class='icon-cogs'></i> <strong><?php echo $lang->user->contacts->manage;?></strong>
|
||||
<?php endif;?>
|
||||
<div class='panel-actions pull-right'>
|
||||
<?php
|
||||
if($mode == 'edit')
|
||||
{
|
||||
echo html::a(inlink('managecontacts', "listID=0&mode=new"), $lang->user->contacts->createList, '', "class='btn'");
|
||||
echo html::a(inlink('deleteContacts', "listID=$listID"), $lang->delete, 'hiddenwin', "class='btn btn-danger'");
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class='panel-body'>
|
||||
<table class='table table-form'>
|
||||
<tr>
|
||||
<th><?php echo $lang->user->contacts->listName;?></th>
|
||||
<td>
|
||||
<?php
|
||||
if($mode == 'new')
|
||||
{
|
||||
echo html::input('newList', '', "class='form-control'");
|
||||
}
|
||||
else
|
||||
{
|
||||
echo html::input('listName', $list->listName, "class='form-control'");
|
||||
echo html::hidden('listID', $list->id);
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='w-80px'><?php echo $lang->user->contacts->selectedUsers;?></th>
|
||||
<td>
|
||||
@@ -65,22 +73,12 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->user->contacts->listName;?></th>
|
||||
<td></td>
|
||||
<td>
|
||||
<?php
|
||||
if($mode == 'new')
|
||||
{
|
||||
echo html::input('newList', '', "class='form-control'");
|
||||
}
|
||||
else
|
||||
{
|
||||
echo html::input('listName', $list->listName, "class='form-control'");
|
||||
echo html::hidden('listID', $list->id);
|
||||
}
|
||||
?>
|
||||
<?php echo html::submitButton() . html::hidden('mode', $mode);?>
|
||||
<?php if($mode == 'edit') echo html::a(inlink('deleteContacts', "listID=$listID"), $lang->delete, 'hiddenwin', "class='btn btn-danger'");?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr><td></td><td><?php echo html::submitButton() . html::hidden('mode', $mode);?></td></tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -63,7 +63,11 @@
|
||||
{
|
||||
$wizardParams = helper::safe64Encode("productID=$productID&branch=$branch&moduleID=$moduleID");
|
||||
common::printIcon('tutorial', 'wizard', "module=story&method=create¶ms=$wizardParams", 'btn', 'button', 'plus', '', 'create-story-btn', false, '', $lang->story->create);
|
||||
} else common::printIcon('story', 'create', "productID=$productID&branch=$branch&moduleID=$moduleID", 'btn', 'button', 'plus', '', 'create-story-btn');
|
||||
}
|
||||
else
|
||||
{
|
||||
common::printIcon('story', 'create', "productID=$productID&branch=$branch&moduleID=$moduleID", 'btn', 'button', 'plus', '', 'create-story-btn');
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -27,7 +27,11 @@
|
||||
{
|
||||
$wizardParams = helper::safe64Encode("project=$project->id");
|
||||
common::printIcon('tutorial', 'wizard', "module=project&method=linkStory¶ms=$wizardParams", '', 'button', 'link', '', 'link-story-btn', false, '', $lang->project->linkStory);
|
||||
} else common::printIcon('project', 'linkStory', "project=$project->id", '', 'button', 'link', '', 'link-story-btn');
|
||||
}
|
||||
else
|
||||
{
|
||||
common::printIcon('project', 'linkStory', "project=$project->id", '', 'button', 'link', '', 'link-story-btn');
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -105,7 +109,11 @@
|
||||
{
|
||||
$wizardParams = helper::safe64Encode($param);
|
||||
common::printIcon('tutorial', 'wizard', "module=task&method=create¶ms=$wizardParams", '', 'list', 'list-ul', '', 'btn-task-create', false, '', $lang->project->wbs);
|
||||
} else common::printIcon('task', 'create', $param, '', 'list', 'list-ul', '', 'btn-task-create');
|
||||
}
|
||||
else
|
||||
{
|
||||
common::printIcon('task', 'create', $param, '', 'list', 'list-ul', '', 'btn-task-create');
|
||||
}
|
||||
|
||||
$lang->task->batchCreate = $lang->project->batchWBS;
|
||||
common::printIcon('task', 'batchCreate', "projectID={$project->id}&story={$story->id}", '', 'list', 'stack');
|
||||
|
||||
@@ -172,7 +172,6 @@ class story extends control
|
||||
$this->view->position[] = $this->lang->story->create;
|
||||
$this->view->products = $products;
|
||||
$this->view->users = $users;
|
||||
$this->view->contactLists = $this->user->getContactLists($this->app->user->account, 'withnote');
|
||||
$this->view->moduleID = $moduleID;
|
||||
$this->view->moduleOptionMenu = $moduleOptionMenu;
|
||||
$this->view->plans = $this->loadModel('productplan')->getPairs($productID, $branch, 'unexpired');
|
||||
|
||||
@@ -151,14 +151,7 @@
|
||||
<div class='input-group' id='mailtoGroup'>
|
||||
<?php
|
||||
echo html::select('mailto[]', $users, str_replace(' ' , '', $mailto), "multiple");
|
||||
if($contactLists) echo html::select('', $contactLists, '', "class='form-control chosen' onchange=\"setMailto('mailto', this.value)\"");
|
||||
if(empty($contactLists))
|
||||
{
|
||||
echo '<span class="input-group-btn">';
|
||||
echo '<a data-toggle="tooltip" title="' . $lang->user->contacts->manage . '" href="' . $this->createLink('my', 'managecontacts', "listID=0&mode=new") . '" target="_blank" class="btn"><i class="icon icon-cog"></i></a>';
|
||||
echo '<a data-toggle="tooltip" title="' . $lang->refresh . '" href="###" class="btn" onclick="ajaxGetContacts(this)"><i class="icon icon-refresh"></i></a>';
|
||||
echo '</span>';
|
||||
}
|
||||
echo $this->fetch('my', 'buildContactLists');
|
||||
?>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
@@ -134,7 +134,6 @@ class task extends control
|
||||
$users = $this->loadModel('user')->getPairs('nodeleted|noclosed');
|
||||
$stories = $this->story->getProjectStoryPairs($projectID);
|
||||
$members = $this->project->getTeamMemberPairs($projectID, 'nodeleted');
|
||||
$contactLists = $this->user->getContactLists($this->app->user->account, 'withnote');
|
||||
$moduleOptionMenu = $this->tree->getTaskOptionMenu($projectID);
|
||||
|
||||
$title = $project->name . $this->lang->colon . $this->lang->task->create;
|
||||
@@ -154,7 +153,6 @@ class task extends control
|
||||
$this->view->users = $users;
|
||||
$this->view->stories = $stories;
|
||||
$this->view->members = $members;
|
||||
$this->view->contactLists = $contactLists;
|
||||
$this->view->moduleOptionMenu = $moduleOptionMenu;
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -132,16 +132,7 @@
|
||||
<span class='input-group-addon'><?php echo $lang->task->mailto;?></span>
|
||||
<?php endif;?>
|
||||
<?php echo html::select('mailto[]', $project->acl == 'private' ? $members : $users, str_replace(' ', '', $task->mailto), "multiple class='form-control'");?>
|
||||
<?php if($contactLists) echo html::select('', $contactLists, '', "class='form-control chosen' onchange=\"setMailto('mailto', this.value)\"");?>
|
||||
<?php
|
||||
if(empty($contactLists))
|
||||
{
|
||||
echo '<span class="input-group-btn">';
|
||||
echo '<a data-toggle="tooltip" title="' . $lang->user->contacts->manage . '" href="' . $this->createLink('my', 'managecontacts', "listID=0&mode=new") . '" target="_blank" class="btn"><i class="icon icon-cog"></i></a>';
|
||||
echo '<a data-toggle="tooltip" title="' . $lang->refresh . '" href="###" class="btn" onclick="ajaxGetContacts(this)"><i class="icon icon-refresh"></i></a>';
|
||||
echo '</span>';
|
||||
}
|
||||
?>
|
||||
<?php echo $this->fetch('my', 'buildContactLists');?>
|
||||
</div>
|
||||
</td>
|
||||
<?php endif;?>
|
||||
|
||||
@@ -154,7 +154,6 @@ class testtask extends control
|
||||
$this->view->productID = $productID;
|
||||
$this->view->builds = $builds;
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noclosed|nodeleted|qdfirst');
|
||||
$this->view->contactLists = $this->user->getContactLists($this->app->user->account, 'withnote');
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -74,17 +74,10 @@
|
||||
<th><?php echo $lang->testtask->mailto;?></th>
|
||||
<td colspan='2'>
|
||||
<div id='mailtoGroup' class='input-group'>
|
||||
<?php echo html::select('mailto[]', $users, '', "multiple class='form-control'");?>
|
||||
<?php if($contactLists) echo html::select('', $contactLists, '', "class='form-control chosen' onchange=\"setMailto('mailto', this.value)\"");?>
|
||||
<?php
|
||||
if(empty($contactLists))
|
||||
{
|
||||
echo '<span class="input-group-btn">';
|
||||
echo '<a href="' . $this->createLink('my', 'managecontacts', "listID=0&mode=new") . '" target="_blank" data-toggle="tooltip" class="btn" title="' . $lang->user->contacts->manage . '"><i class="icon icon-cog"></i></a>';
|
||||
echo '<a href="###" onclick="ajaxGetContacts(this)" data-toggle="tooltip" class="btn" title="' . $lang->refresh . '"><i class="icon icon-refresh"></i></a>';
|
||||
echo '</span>';
|
||||
}
|
||||
?>
|
||||
<?php
|
||||
echo html::select('mailto[]', $users, '', "multiple class='form-control'");
|
||||
echo $this->fetch('my', 'buildContactLists');
|
||||
?>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
Reference in New Issue
Block a user