* finish task #5271.

This commit is contained in:
wangyidong
2019-02-25 08:43:53 +08:00
parent 344ed8f38b
commit 3e7caa0da1
20 changed files with 174 additions and 144 deletions
+4
View File
@@ -1,3 +1,7 @@
update `zt_build` set `deleted`='1' where `project`='0' and `id` in (select `build` from `zt_release` where `deleted`='1');
ALTER TABLE `zt_productplan` ADD `parent` mediumint(9) NOT NULL DEFAULT '0' AFTER `branch`;
ALTER TABLE `zt_action` CHANGE `actor` `actor` varchar(100) COLLATE 'utf8_general_ci' NOT NULL DEFAULT '' AFTER `project`;
ALTER TABLE `zt_user` ADD `weixin` varchar(90) COLLATE 'utf8_general_ci' NOT NULL AFTER `phone`;
ALTER TABLE `zt_user` ADD `dingtalk` varchar(90) COLLATE 'utf8_general_ci' NOT NULL AFTER `weixin`;
ALTER TABLE `zt_user` ADD `slack` varchar(90) COLLATE 'utf8_general_ci' NOT NULL AFTER `dingtalk`;
ALTER TABLE `zt_user` ADD `whatsapp` varchar(90) COLLATE 'utf8_general_ci' NOT NULL AFTER `slack`;
+4 -2
View File
@@ -815,11 +815,13 @@ CREATE TABLE IF NOT EXISTS `zt_user` (
`email` char(90) NOT NULL default '',
`skype` char(90) NOT NULL default '',
`qq` char(20) NOT NULL default '',
`yahoo` char(90) NOT NULL default '',
`gtalk` char(90) NOT NULL default '',
`wangwang` char(90) NOT NULL default '',
`mobile` char(11) NOT NULL default '',
`phone` char(20) NOT NULL default '',
`weixin` varchar(90) NOT NULL default '',
`dingtalk` varchar(90) NOT NULL default '',
`slack` varchar(90) NOT NULL default '',
`whatsapp` varchar(90) NOT NULL default '',
`address` char(120) NOT NULL default '',
`zipcode` char(10) NOT NULL default '',
`join` date NOT NULL default '0000-00-00',
+8 -4
View File
@@ -38,9 +38,11 @@ $config->company->browse->search['fields']['commiter'] = $lang->user->commiter;
$config->company->browse->search['fields']['gender'] = $lang->user->gender;
$config->company->browse->search['fields']['qq'] = $lang->user->qq;
$config->company->browse->search['fields']['skype'] = $lang->user->skype;
$config->company->browse->search['fields']['yahoo'] = $lang->user->yahoo;
$config->company->browse->search['fields']['dingtalk'] = $lang->user->dingtalk;
$config->company->browse->search['fields']['gtalk'] = $lang->user->gtalk;
$config->company->browse->search['fields']['wangwang'] = $lang->user->wangwang;
$config->company->browse->search['fields']['weixin'] = $lang->user->weixin;
$config->company->browse->search['fields']['slack'] = $lang->user->slack;
$config->company->browse->search['fields']['whatsapp'] = $lang->user->whatsapp;
$config->company->browse->search['fields']['address'] = $lang->user->address;
$config->company->browse->search['fields']['zipcode'] = $lang->user->zipcode;
@@ -56,8 +58,10 @@ $config->company->browse->search['params']['commiter'] = array('operator' => 'in
$config->company->browse->search['params']['gender'] = array('operator' => '=', 'control' => 'select', 'values' => $lang->user->genderList);
$config->company->browse->search['params']['qq'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['skype'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['yahoo'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['dingtalk'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['gtalk'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['wangwang'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['weixin'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['slack'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['whatsapp'] = array('operator' => '=', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['address'] = array('operator' => 'include', 'control' => 'input', 'values' => '');
$config->company->browse->search['params']['zipcode'] = array('operator' => '=', 'control' => 'input', 'values' => '');
+1 -1
View File
@@ -55,4 +55,4 @@ $config->custom->fieldList['testreport'] = 'begin,end,members,report
$config->custom->fieldList['testtask'] = 'owner,pri,status,desc,comment';
$config->custom->fieldList['doc'] = 'keywords,content';
$config->custom->fieldList['user']['create'] = 'dept,role,email,commiter';
$config->custom->fieldList['user']['edit'] = 'dept,role,email,commiter,skype,qq,mobile,phone,address,zipcode,wangwang,gtalk';
$config->custom->fieldList['user']['edit'] = 'dept,role,email,commiter,skype,qq,mobile,phone,address,zipcode,dingtalk,gtalk,slack,whatsapp,weixin';
+5
View File
@@ -107,6 +107,11 @@ class custom extends control
$data = fixer::input('post')->join('closed', ',')->get();
$this->loadModel('setting')->setItem('system.block.closed', zget($data, 'closed', ''));
}
elseif($module == 'user' and $field == 'contactField')
{
$data = fixer::input('post')->join('contactField', ',')->get();
$this->loadModel('setting')->setItem('system.user.contactField', $data->contactField);
}
elseif($module == 'user' and $field == 'deleted')
{
$data = fixer::input('post')->get();
+4 -3
View File
@@ -72,9 +72,10 @@ $lang->custom->todo->fields['typeList'] = '类型';
$lang->custom->todo->fields['statusList'] = '状态';
$lang->custom->user = new stdClass();
$lang->custom->user->fields['roleList'] = '职位';
$lang->custom->user->fields['statusList'] = '状态';
$lang->custom->user->fields['deleted'] = '列出已删除用户';
$lang->custom->user->fields['roleList'] = '职位';
$lang->custom->user->fields['statusList'] = '状态';
$lang->custom->user->fields['contactField'] = '可用联系方式';
$lang->custom->user->fields['deleted'] = '列出已删除用户';
$lang->custom->block->fields['closed'] = '关闭的区块';
+2
View File
@@ -440,8 +440,10 @@ class customModel extends model
$fieldList = isset($customFields[$moduleName][$method]) ? $customFields[$moduleName][$method] : $customFields[$moduleName];
if(!is_string($fieldList)) return $fields;
if($moduleName == 'user' and $method == 'edit') $this->app->loadConfig('user');
foreach(explode(',', $fieldList) as $fieldName)
{
if($moduleName == 'user' and $method == 'edit' and strpos($this->config->user->contactField, $fieldName) === false) continue;
if($fieldName == 'comment') $fields[$fieldName] = $this->lang->comment;
if(isset($moduleLang->$fieldName) and is_string($moduleLang->$fieldName)) $fields[$fieldName] = $moduleLang->$fieldName;
}
+15
View File
@@ -113,6 +113,21 @@ EOT;
<td colspan='2' class='text-center'><?php echo html::submitButton();?></td>
</tr>
</table>
<?php elseif($module == 'user' and $field == 'contactField'):?>
<?php
$this->app->loadConfig('user');
$this->app->loadLang('user');
?>
<table class='table table-form mw-800px'>
<tr>
<th class='w-150px'><?php echo $lang->custom->user->fields['contactField'];?></th>
<td><?php echo html::select('contactField[]', $lang->user->contactFieldList, $config->user->contactField, "class='form-control chosen' multiple");?></td>
</tr>
<tr>
<td></td>
<td><?php echo html::submitButton();?></td>
</tr>
</table>
<?php elseif($module == 'user' and $field == 'deleted'):?>
<table class='table table-form mw-600px'>
<tr>
+1 -1
View File
@@ -1,7 +1,7 @@
$(function()
{
toggleAcl($('[name=acl]').val(), 'doc');
setTimeout(function(){initPage(docType)}, 100);
setTimeout(function(){initPage(docType)}, 50);
$('input[name="type"]').change(function()
{
var type = $(this).val();
+7 -7
View File
@@ -165,17 +165,17 @@ $lang->doc->noEditedDoc = '您还没有编辑任何文档。';
$lang->doc->noOpenedDoc = '您还没有创建任何文档。';
$lang->doc->noCollectedDoc = '您还没有收藏任何文档。';
$lang->doc->noticeAcl['lib']['product']['open'] = '所有人都可以访问,除非用户没有权限访问的关联产品。';
$lang->doc->noticeAcl['lib']['product']['custom'] = '白名单和有权限访问的关联产品的用户可以访问。';
$lang->doc->noticeAcl['lib']['product']['private'] = '创建人和有权限访问的关联产品的用户可以访问。';
$lang->doc->noticeAcl['lib']['project']['open'] = '所有人都可以访问,除非用户没有权限访问的关联项目。';
$lang->doc->noticeAcl['lib']['project']['custom'] = '白名单和有权限访问的关联项目的用户可以访问。';
$lang->doc->noticeAcl['lib']['project']['private'] = '创建人和有权限访问的关联项目的用户可以访问。';
$lang->doc->noticeAcl['lib']['product']['open'] = '除了没有关联产品权限的用户,都可以访问。';
$lang->doc->noticeAcl['lib']['product']['custom'] = '白名单和有关联产品权限的用户可以访问。';
$lang->doc->noticeAcl['lib']['product']['private'] = '创建人和有关联产品权限的用户可以访问。';
$lang->doc->noticeAcl['lib']['project']['open'] = '除了没有关联项目权限的用户,都可以访问。';
$lang->doc->noticeAcl['lib']['project']['custom'] = '白名单和有关联项目权限的用户可以访问。';
$lang->doc->noticeAcl['lib']['project']['private'] = '创建人和有关联项目权限的用户可以访问。';
$lang->doc->noticeAcl['lib']['custom']['open'] = '所有人都可以访问。';
$lang->doc->noticeAcl['lib']['custom']['custom'] = '白名单的用户可以访问。';
$lang->doc->noticeAcl['lib']['custom']['private'] = '只有创建人可以访问。';
$lang->doc->noticeAcl['doc']['open'] = '所有人都可以访问,除非用户没有所属文档库权限。';
$lang->doc->noticeAcl['doc']['open'] = '除了没有所属文档库权限的用户,都可以访问。';
$lang->doc->noticeAcl['doc']['custom'] = '白名单的用户可以访问。';
$lang->doc->noticeAcl['doc']['private'] = '只有自己可以访问。';
+8 -23
View File
@@ -63,34 +63,19 @@
</table>
<table class='table table-form'>
<caption><?php echo $lang->my->form->lblContact;?></caption>
<?php $i = 0;?>
<?php foreach(explode(',', $config->user->contactField) as $field):?>
<?php if($i % 2 == 0) echo '<tr>';?>
<?php $i++;?>
<th class='w-90px'><?php echo $lang->user->$field;?></th>
<td><?php echo html::input($field, $user->$field, "class='form-control'");?></td>
<?php if($i % 2 == 0) echo '</tr>';?>
<?php endforeach;?>
<tr>
<th class='w-90px'><?php echo $lang->user->skype;?></th>
<td><?php echo html::input('skype', $user->skype, "class='form-control'");?></td>
<th class='w-90px'><?php echo $lang->user->qq;?></th>
<td><?php echo html::input('qq', $user->qq, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->yahoo;?></th>
<td><?php echo html::input('yahoo', $user->yahoo, "class='form-control'");?></td>
<th><?php echo $lang->user->gtalk;?></th>
<td><?php echo html::input('gtalk', $user->gtalk, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->wangwang;?></th>
<td><?php echo html::input('wangwang', $user->wangwang, "class='form-control'");?></td>
<th><?php echo $lang->user->mobile;?></th>
<td><?php echo html::input('mobile', $user->mobile, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->phone;?></th>
<td><?php echo html::input('phone', $user->phone, "class='form-control'");?></td>
<th><?php echo $lang->user->address;?></th>
<td><?php echo html::input('address', $user->address, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->zipcode;?></th>
<td><?php echo html::input('zipcode', $user->zipcode, "class='form-control'");?></td>
<td></td>
</tr>
</table>
<table class='table table-form'>
+19 -26
View File
@@ -83,34 +83,27 @@
<th><?php echo $lang->user->last;?></th>
<td><?php echo $user->last;?></td>
</tr>
<?php foreach(explode(',', $config->user->contactField) as $field):?>
<tr>
<th><?php echo $lang->user->skype;?></th>
<td><?php if($user->skype) echo html::a("callto://$user->skype", $user->skype);?></td>
</tr>
<tr>
<th><?php echo $lang->user->qq;?></th>
<td><?php if($user->qq) echo html::a("tencent://message/?uin=$user->qq", $user->qq);?></td>
</tr>
<tr>
<th><?php echo $lang->user->yahoo;?></th>
<td><?php echo $user->yahoo;?></td>
</tr>
<tr>
<th><?php echo $lang->user->gtalk;?></th>
<td><?php echo $user->gtalk;?></td>
</tr>
<tr>
<th><?php echo $lang->user->wangwang;?></th>
<td><?php echo $user->wangwang;?></td>
</tr>
<tr>
<th><?php echo $lang->user->mobile;?></th>
<td><?php echo $user->mobile;?></td>
</tr>
<tr>
<th><?php echo $lang->user->phone;?></th>
<td><?php echo $user->phone;?></td>
<th><?php echo $lang->user->$field;?></th>
<td>
<?php
if($field == 'skype' and $user->$field)
{
echo html::a("callto://$user->skype", $user->skype);
}
elseif($field == 'qq' and $user->$field)
{
echo html::a("tencent://message/?uin=$user->qq", $user->qq);
}
else
{
echo $user->$field;
}
?>
</td>
</tr>
<?php endforeach;?>
<tr>
<th><?php echo $lang->user->address;?></th>
<td><?php echo $user->address;?></td>
+6 -5
View File
@@ -6,13 +6,14 @@ $config->user->edit = new stdclass();
$config->user->create->requiredFields = 'account,realname,password,password1,password2';
$config->user->edit->requiredFields = 'account,realname';
$config->user->customBatchCreateFields = 'dept,email,gender,commiter,join,skype,qq,yahoo,gtalk,wangwang,mobile,phone,address,zipcode';
$config->user->customBatchEditFields = 'dept,email,commiter,skype,qq,yahoo,gtalk,wangwang,mobile,phone,address,zipcode';
$config->user->customBatchCreateFields = 'dept,email,gender,commiter,join,skype,qq,dingtalk,gtalk,weixin,mobile,slack,whatsapp,phone,address,zipcode';
$config->user->customBatchEditFields = 'dept,email,commiter,skype,qq,dingtalk,gtalk,weixin,mobile,slack,whatsapp,phone,address,zipcode';
$config->user->custom = new stdclass();
$config->user->custom->batchCreateFields = 'dept,join,email,gender';
$config->user->custom->batchEditFields = 'dept,join,email,commiter';
$config->user->failTimes = 6;
$config->user->lockMinutes = 10;
$config->user->batchCreate = 10;
$config->user->contactField = 'skype,qq,dingtalk,gtalk,weixin,mobile,slack,whatsapp,phone';
$config->user->failTimes = 6;
$config->user->lockMinutes = 10;
$config->user->batchCreate = 10;
+18 -4
View File
@@ -456,9 +456,16 @@ class user extends control
}
/* Set custom. */
foreach(explode(',', $this->config->user->customBatchCreateFields) as $field) $customFields[$field] = $this->lang->user->$field;
foreach(explode(',', $this->config->user->customBatchCreateFields) as $field)
{
if(!isset($this->lang->user->contactFieldList[$field]) or strpos($this->config->user->contactField, $field) !== false) $customFields[$field] = $this->lang->user->$field;
}
foreach(explode(',', $this->config->user->custom->batchCreateFields) as $field)
{
if(!isset($this->lang->user->contactFieldList[$field]) or strpos($this->config->user->contactField, $field) !== false) $showFields[$field] = $field;
}
$this->view->customFields = $customFields;
$this->view->showFields = $this->config->user->custom->batchCreateFields;
$this->view->showFields = join(',', $showFields);
$title = $this->lang->company->common . $this->lang->colon . $this->lang->user->batchCreate;
$position[] = $this->lang->user->batchCreate;
@@ -533,9 +540,16 @@ class user extends control
$this->lang->user->menuOrder = $this->lang->company->menuOrder;
/* Set custom. */
foreach(explode(',', $this->config->user->customBatchEditFields) as $field) $customFields[$field] = $this->lang->user->$field;
foreach(explode(',', $this->config->user->customBatchEditFields) as $field)
{
if(!isset($this->lang->user->contactFieldList[$field]) or strpos($this->config->user->contactField, $field) !== false) $customFields[$field] = $this->lang->user->$field;
}
foreach(explode(',', $this->config->user->custom->batchEditFields) as $field)
{
if(!isset($this->lang->user->contactFieldList[$field]) or strpos($this->config->user->contactField, $field) !== false) $showFields[$field] = $field;
}
$this->view->customFields = $customFields;
$this->view->showFields = $this->config->user->custom->batchEditFields;
$this->view->showFields = join(',', $showFields);
$this->view->title = $this->lang->company->common . $this->lang->colon . $this->lang->user->batchEdit;
$this->view->position[] = $this->lang->user->batchEdit;
+14 -1
View File
@@ -30,11 +30,14 @@ $lang->user->verify = '安全验证';
$lang->user->contactInfo = '联系信息';
$lang->user->skype = 'Skype';
$lang->user->qq = 'QQ';
$lang->user->yahoo = '雅虎通';
$lang->user->gtalk = 'GTalk';
$lang->user->wangwang = '旺旺';
$lang->user->mobile = '手机';
$lang->user->phone = '电话';
$lang->user->weixin = '微信';
$lang->user->dingtalk = '钉钉';
$lang->user->slack = 'Slack';
$lang->user->whatsapp = 'WhatsApp';
$lang->user->address = '通讯地址';
$lang->user->zipcode = '邮编';
$lang->user->join = '入职日期';
@@ -151,6 +154,16 @@ $lang->user->error->reserved = "【ID %s】的用户名已被系统预留";
$lang->user->error->verifyPassword = "验证失败,请检查您的系统登录密码是否正确";
$lang->user->error->originalPassword = "原密码不正确";
$lang->user->contactFieldList['skype'] = $lang->user->skype;
$lang->user->contactFieldList['qq'] = $lang->user->qq;
$lang->user->contactFieldList['dingtalk'] = $lang->user->dingtalk;
$lang->user->contactFieldList['gtalk'] = $lang->user->gtalk;
$lang->user->contactFieldList['weixin'] = $lang->user->weixin;
$lang->user->contactFieldList['mobile'] = $lang->user->mobile;
$lang->user->contactFieldList['slack'] = $lang->user->slack;
$lang->user->contactFieldList['whatsapp'] = $lang->user->whatsapp;
$lang->user->contactFieldList['phone'] = $lang->user->phone;
$lang->user->contacts = new stdclass();
$lang->user->contacts->common = '联系人';
$lang->user->contacts->listName = '列表名称';
+15 -5
View File
@@ -300,10 +300,12 @@ class userModel extends model
$data[$i]->join = empty($users->join[$i]) ? '0000-00-00' : ($users->join[$i]);
$data[$i]->skype = $users->skype[$i];
$data[$i]->qq = $users->qq[$i];
$data[$i]->yahoo = $users->yahoo[$i];
$data[$i]->dingtalk = $users->dingtalk[$i];
$data[$i]->gtalk = $users->gtalk[$i];
$data[$i]->wangwang = $users->wangwang[$i];
$data[$i]->weixin = $users->weixin[$i];
$data[$i]->mobile = $users->mobile[$i];
$data[$i]->slack = $users->slack[$i];
$data[$i]->whatsapp = $users->whatsapp[$i];
$data[$i]->phone = $users->phone[$i];
$data[$i]->address = $users->address[$i];
$data[$i]->zipcode = $users->zipcode[$i];
@@ -387,10 +389,16 @@ class userModel extends model
dao::$errors['verifyPassword'][] = $this->lang->user->error->verifyPassword;
return false;
}
$requiredFields = array();
foreach(explode(',', $this->config->user->edit->requiredFields) as $field)
{
if(!isset($this->lang->user->contactFieldList[$field]) or strpos($this->config->user->contactField, $field) !== false) $requiredFields[$field] = $field;
}
$requiredFields = join(',', $requiredFields);
$this->dao->update(TABLE_USER)->data($user)
->autoCheck()
->batchCheck($this->config->user->edit->requiredFields, 'notempty')
->batchCheck($requiredFields, 'notempty')
->check('account', 'unique', "id != '$userID'")
->check('account', 'account')
->checkIF($this->post->email != '', 'email', 'email')
@@ -474,10 +482,12 @@ class userModel extends model
$users[$id]['join'] = $data->join[$id];
$users[$id]['skype'] = $data->skype[$id];
$users[$id]['qq'] = $data->qq[$id];
$users[$id]['yahoo'] = $data->yahoo[$id];
$users[$id]['dingtalk'] = $data->dingtalk[$id];
$users[$id]['gtalk'] = $data->gtalk[$id];
$users[$id]['wangwang'] = $data->wangwang[$id];
$users[$id]['weixin'] = $data->weixin[$id];
$users[$id]['mobile'] = $data->mobile[$id];
$users[$id]['slack'] = $data->slack[$id];
$users[$id]['whatsapp'] = $data->whatsapp[$id];
$users[$id]['phone'] = $data->phone[$id];
$users[$id]['address'] = $data->address[$id];
$users[$id]['zipcode'] = $data->zipcode[$id];
+8 -4
View File
@@ -47,10 +47,12 @@
<th class='w-120px<?php echo zget($visibleFields, 'join', ' hidden')?>'> <?php echo $lang->user->join;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'skype', ' hidden')?>'> <?php echo $lang->user->skype;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'qq', ' hidden')?>'> <?php echo $lang->user->qq;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'yahoo', ' hidden')?>'> <?php echo $lang->user->yahoo;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'dingtalk', ' hidden')?>'><?php echo $lang->user->dingtalk;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'gtalk', ' hidden')?>'> <?php echo $lang->user->gtalk;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'wangwang', ' hidden')?>'><?php echo $lang->user->wangwang;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'weixin', ' hidden')?>'> <?php echo $lang->user->weixin;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'mobile', ' hidden')?>'> <?php echo $lang->user->mobile;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'slack', ' hidden')?>'> <?php echo $lang->user->slack;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'whatsapp', ' hidden')?>'><?php echo $lang->user->whatsapp;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'phone', ' hidden')?>'> <?php echo $lang->user->phone;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'address', ' hidden')?>'> <?php echo $lang->user->address;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'zipcode', ' hidden')?>'> <?php echo $lang->user->zipcode;?></th>
@@ -82,10 +84,12 @@
<td class='<?php echo zget($visibleFields, 'join', 'hidden')?>'> <?php echo html::input("join[$i]", '', "class='form-control form-date'");?></td>
<td class='<?php echo zget($visibleFields, 'skype', 'hidden')?>'> <?php echo html::input("skype[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'qq', 'hidden')?>'> <?php echo html::input("qq[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'yahoo', 'hidden')?>'> <?php echo html::input("yahoo[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'dingtalk', 'hidden')?>'><?php echo html::input("dingtalk[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'gtalk', 'hidden')?>'> <?php echo html::input("gtalk[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'wangwang', 'hidden')?>'><?php echo html::input("wangwang[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'weixin', 'hidden')?>'> <?php echo html::input("weixin[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'mobile', 'hidden')?>'> <?php echo html::input("mobile[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'slack', 'hidden')?>'> <?php echo html::input("slack[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'whatsapp', 'hidden')?>'><?php echo html::input("whatsapp[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'phone', 'hidden')?>'> <?php echo html::input("phone[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'address', 'hidden')?>'> <?php echo html::input("address[$i]", '', "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'zipcode', 'hidden')?>'> <?php echo html::input("zipcode[$i]", '', "class='form-control'");?></td>
+8 -4
View File
@@ -43,10 +43,12 @@
<th class='w-120px<?php echo zget($visibleFields, 'join', ' hidden')?>'> <?php echo $lang->user->join;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'skype', ' hidden')?>'> <?php echo $lang->user->skype;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'qq', ' hidden')?>'> <?php echo $lang->user->qq;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'yahoo', ' hidden')?>'> <?php echo $lang->user->yahoo;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'dingtalk', ' hidden')?>'> <?php echo $lang->user->dingtalk;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'gtalk', ' hidden')?>'> <?php echo $lang->user->gtalk;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'wangwang', ' hidden')?>'> <?php echo $lang->user->wangwang;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'weixin', ' hidden')?>'> <?php echo $lang->user->weixin;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'mobile', ' hidden')?>'> <?php echo $lang->user->mobile;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'slack', ' hidden')?>'> <?php echo $lang->user->slack;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'whatsapp', ' hidden')?>'> <?php echo $lang->user->whatsapp;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'phone', ' hidden')?>'> <?php echo $lang->user->phone;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'address', ' hidden')?>'> <?php echo $lang->user->address;?></th>
<th class='w-120px<?php echo zget($visibleFields, 'zipcode', ' hidden')?>'> <?php echo $lang->user->zipcode;?></th>
@@ -73,10 +75,12 @@
<td class='<?php echo zget($visibleFields, 'join', 'hidden')?>'> <?php echo html::input("join[$user->id]", $user->join, "class='form-control form-date'");?></td>
<td class='<?php echo zget($visibleFields, 'skype', 'hidden')?>'> <?php echo html::input("skype[$user->id]", $user->skype, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'qq', 'hidden')?>'> <?php echo html::input("qq[$user->id]", $user->qq, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'yahoo', 'hidden')?>'> <?php echo html::input("yahoo[$user->id]", $user->yahoo, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'dingtalk', 'hidden')?>'><?php echo html::input("dingtalk[$user->id]", $user->dingtalk, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'gtalk', 'hidden')?>'> <?php echo html::input("gtalk[$user->id]", $user->gtalk, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'wangwang', 'hidden')?>'><?php echo html::input("wangwang[$user->id]", $user->wangwang, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'weixin', 'hidden')?>'> <?php echo html::input("weixin[$user->id]", $user->weixin, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'mobile', 'hidden')?>'> <?php echo html::input("mobile[$user->id]", $user->mobile, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'slack', 'hidden')?>'> <?php echo html::input("slack[$user->id]", $user->slack, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'whatsapp', 'hidden')?>'><?php echo html::input("whatsapp[$user->id]", $user->whatsapp, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'phone', 'hidden')?>'> <?php echo html::input("phone[$user->id]", $user->phone, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'address', 'hidden')?>'> <?php echo html::input("address[$user->id]", $user->address, "class='form-control'");?></td>
<td class='<?php echo zget($visibleFields, 'zipcode', 'hidden')?>'> <?php echo html::input("zipcode[$user->id]", $user->zipcode, "class='form-control'");?></td>
+8 -22
View File
@@ -76,31 +76,17 @@
</table>
<table align='center' class='table table-form'>
<caption class='text-left text-muted'><?php echo $lang->user->contactInfo;?></caption>
<?php $i = 0;?>
<?php foreach(explode(',', $config->user->contactField) as $field):?>
<?php if($i % 2 == 0) echo '<tr>';?>
<?php $i++;?>
<th class='w-90px'><?php echo $lang->user->$field;?></th>
<td><?php echo html::input($field, $user->$field, "class='form-control'");?></td>
<?php if($i % 2 == 0) echo '</tr>';?>
<?php endforeach;?>
<tr>
<th class='w-90px'><?php echo $lang->user->skype;?></th>
<td class='w-p40'><?php echo html::input('skype', $user->skype, "class='form-control'");?></td>
<th class='w-90px'><?php echo $lang->user->qq;?></th>
<td><?php echo html::input('qq', $user->qq, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->yahoo;?></th>
<td><?php echo html::input('yahoo', $user->yahoo, "class='form-control'");?></td>
<th><?php echo $lang->user->gtalk;?></th>
<td><?php echo html::input('gtalk', $user->gtalk, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->wangwang;?></th>
<td><?php echo html::input('wangwang', $user->wangwang, "class='form-control'");?></td>
<th><?php echo $lang->user->mobile;?></th>
<td><?php echo html::input('mobile', $user->mobile, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->phone;?></th>
<td><?php echo html::input('phone', $user->phone, "class='form-control'");?></td>
<th><?php echo $lang->user->address;?></th>
<td><?php echo html::input('address', $user->address, "class='form-control'");?></td>
</tr>
<tr>
<th><?php echo $lang->user->zipcode;?></th>
<td><?php echo html::input('zipcode', $user->zipcode, "class='form-control'");?></td>
</tr>
+19 -32
View File
@@ -69,12 +69,6 @@
<th><?php echo $lang->user->commiter;?></th>
<td><?php echo $user->commiter;?></td>
</tr>
<!--
<tr>
<?php // echo $lang->user->nickname;?>
<?php // echo $user->nickname;?>
</tr>
-->
<tr>
<th><?php echo $lang->user->email;?></th>
<td><?php echo $user->email;?></td>
@@ -91,34 +85,27 @@
<th><?php echo $lang->user->last;?></th>
<td><?php echo $user->last;?></td>
</tr>
<?php foreach(explode(',', $config->user->contactField) as $field):?>
<tr>
<th><?php echo $lang->user->skype;?></th>
<td><?php if($user->skype) echo html::a("callto://$user->skype", $user->skype);?></td>
</tr>
<tr>
<th><?php echo $lang->user->qq;?></th>
<td><?php if($user->qq) echo html::a("tencent://message/?uin=$user->qq", $user->qq);?></td>
</tr>
<tr>
<th><?php echo $lang->user->yahoo;?></th>
<td><?php echo $user->yahoo;?></td>
</tr>
<tr>
<th><?php echo $lang->user->gtalk;?></th>
<td><?php echo $user->gtalk;?></td>
</tr>
<tr>
<th><?php echo $lang->user->wangwang;?></th>
<td><?php echo $user->wangwang;?></td>
</tr>
<tr>
<th><?php echo $lang->user->mobile;?></th>
<td><?php echo $user->mobile;?></td>
</tr>
<tr>
<th><?php echo $lang->user->phone;?></th>
<td><?php echo $user->phone;?></td>
<th><?php echo $lang->user->$field;?></th>
<td>
<?php
if($field == 'skype' and $user->$field)
{
echo html::a("callto://$user->skype", $user->skype);
}
elseif($field == 'qq' and $user->$field)
{
echo html::a("tencent://message/?uin=$user->qq", $user->qq);
}
else
{
echo $user->$field;
}
?>
</td>
</tr>
<?php endforeach;?>
<tr>
<th><?php echo $lang->user->address;?></th>
<td><?php echo $user->address;?></td>