Merge branch 'sprint/master_zhouxudong_56918' into 'master'

* Finish task #56918.

See merge request easycorp/zentaopms!3929
This commit is contained in:
王怡栋
2022-06-15 05:33:58 +00:00
5 changed files with 18 additions and 13 deletions
+3 -4
View File
@@ -1169,7 +1169,7 @@ EOF;
* @access public
* @return void
*/
public function manageContacts($listID = 0, $mode = '')
public function manageContacts($listID = 0, $mode = 'new')
{
if($_POST)
{
@@ -1191,7 +1191,7 @@ EOF;
}
$this->user->setGlobalContacts($listID, isset($data->share));
if(isonlybody()) return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.parent.ajaxGetContacts('#mailto')"));
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => inlink('manageContacts', "listID=$listID")));
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => inlink('manageContacts', "listID=$listID&mode=edit")));
}
elseif($data->mode == 'edit')
{
@@ -1208,7 +1208,7 @@ EOF;
return $this->send($response);
}
$response['locate'] = inlink('manageContacts', "listID=$listID");
$response['locate'] = inlink('manageContacts', "listID=$listID&mode=edit");
return $this->send($response);
}
}
@@ -1231,7 +1231,6 @@ EOF;
}
$listID = $listID ? $listID : key($lists);
if(!$listID) $mode = 'new';
/* Create or manage list according to mode. */
if($mode == 'new')
+4 -1
View File
@@ -1,3 +1,6 @@
body.body-modal {padding-bottom: 20px; min-height: 400px;}
.side-col {padding-right: 40px; padding-top: 25px;}
.side-col {padding-right: 40px;}
.btn-block {display: block; width: 100%; text-overflow: ellipsis; white-space: nowrap; overflow: hidden;}
.contactListTitle {margin-left: 45px !important;}
.createBtn {width: 100%; margin-bottom: 5px;}
.main-col .main-header .title {margin-left: 17px !important;}
+1
View File
@@ -45,6 +45,7 @@ $lang->my->pri = 'Priority';
$lang->my->alert = 'You can click on your profile at the top right and select "Preference" to modify your information. ';
$lang->my->assignedToMe = 'AssignedToMe';
$lang->my->byQuery = 'Search';
$lang->my->contactList = 'Contact List';
$lang->my->indexAction = 'My Index';
$lang->my->calendarAction = 'My Calendar';
+1
View File
@@ -45,6 +45,7 @@ $lang->my->pri = '优先级';
$lang->my->alert = '后续您可以点击右上方的头像,选择“个性化设置”修改信息。';
$lang->my->assignedToMe = '指派给我';
$lang->my->byQuery = '搜索';
$lang->my->contactList = '联系人列表';
$lang->my->indexAction = '地盘仪表盘';
$lang->my->calendarAction = '我的日程';
+9 -8
View File
@@ -11,27 +11,28 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<div id='mainContent' class='main-content <?php if($mode == 'edit') echo ' main-row';?>'>
<?php if($mode == 'edit'):?>
<div id='mainContent' class='main-content main-row'>
<div class='side-col'>
<div class='main-header'><h2 class='contactListTitle'><?php echo $lang->my->contactList;?></h2></div>
<div>
<?php echo html::a(inlink('managecontacts', "listID=0&mode=new"), '<i class="icon icon-plus"></i> ' . $lang->user->contacts->createList, '', "class='btn btn-secondary createBtn'"); ?>
<?php
foreach($lists as $id => $listName)
{
$listClass = ($id == $listID) ? 'btn btn-block active' : 'btn btn-block';
$listClass = ($id == $listID and $mode == 'edit') ? 'btn btn-block active' : 'btn btn-block';
$shareIcon = in_array($id, $globalContacts) ? '<i class="icon icon-share-sign"></i> ' : '';
echo html::a(inlink('managecontacts', "listID=$id&mode=edit"), $shareIcon . $listName, '', "class='{$listClass}' title='$listName'");
}
?>
<?php echo html::a(inlink('managecontacts', "listID=0&mode=new"), '<i class="icon icon-plus"></i> ' . $lang->user->contacts->createList, '', "class='btn btn-block'"); ?>
</div>
</div>
<div class='main-col'>
<?php endif;?>
<div class='main-header'>
<h2>
<h2 class='title'>
<?php if($mode == 'new'):?>
<i class='icon-plus'></i> <strong><?php echo $lang->user->contacts->createList;?></strong>
<strong><?php echo $lang->user->contacts->createList;?></strong>
<?php else:?>
<i class='icon-cogs'></i> <strong><?php echo $lang->user->contacts->manage;?></strong>
<strong><?php echo $lang->user->contacts->manage;?></strong>
<?php endif;?>
</h2>
</div>