Commit 07f856dd authored by agping's avatar agping

黑名单 权限

parent b02fc627
...@@ -184,7 +184,7 @@ ...@@ -184,7 +184,7 @@
<div class="form-group full-width-100 full-pic-area"> <div class="form-group full-width-100 full-pic-area">
<!--input上传图片--> <!--input上传图片-->
<div id="container_body"> <div id="container_body">
<label>&nbsp;&nbsp;简历等附件(选填):</label> <label>&nbsp;&nbsp;简历等文件(选填:图片格式):</label>
<button type="button btn2" class="btn btn-default">上传图片</button> <button type="button btn2" class="btn btn-default">上传图片</button>
<input type="file" id="file_input"/> <input type="file" id="file_input"/>
<div id="container_body_img_area"></div> <div id="container_body_img_area"></div>
...@@ -197,7 +197,7 @@ ...@@ -197,7 +197,7 @@
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button type="button btn2" class="btn btn-primary" id="saveBtn" data-dismiss="modal"> <button type="button btn2" class="btn btn-primary" id="saveBtn">
保存 保存
</button> </button>
</div> </div>
......
...@@ -685,7 +685,7 @@ ...@@ -685,7 +685,7 @@
<div class="form-group full-width-100 full-pic-area"> <div class="form-group full-width-100 full-pic-area">
<!--input上传图片--> <!--input上传图片-->
<div id="container_body"> <div id="container_body">
<label>&nbsp;&nbsp;简历等附件(选填):</label> <label>&nbsp;&nbsp;简历等文件(选填:图片格式):</label>
<button type="button btn2" class="btn btn-default">上传图片</button> <button type="button btn2" class="btn btn-default">上传图片</button>
<input type="file" id="file_input"/> <input type="file" id="file_input"/>
<div id="container_body_img_area"></div> <div id="container_body_img_area"></div>
...@@ -698,7 +698,7 @@ ...@@ -698,7 +698,7 @@
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button type="button btn2" class="btn btn-primary" id="saveBtn" data-dismiss="modal"> <button type="button btn2" class="btn btn-primary" id="saveBtn">
保存 保存
</button> </button>
</div> </div>
......
...@@ -359,6 +359,10 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'text!temp/phoneBinding_temp ...@@ -359,6 +359,10 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'text!temp/phoneBinding_temp
}; };
console.log(imgname.join(',')); console.log(imgname.join(','));
_data['img_info'] = imgname.join(','); _data['img_info'] = imgname.join(',');
if($.trim($('.black-list-text').val()) == ''){
alert('违反公司事项内容未填写!');
return;
};
$.ajax({ $.ajax({
type: 'GET', type: 'GET',
url: '/index/addAgentsBlackList', url: '/index/addAgentsBlackList',
...@@ -367,8 +371,16 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'text!temp/phoneBinding_temp ...@@ -367,8 +371,16 @@ define(['doT', 'text!temp/agent_template_tpl.html', 'text!temp/phoneBinding_temp
beforeSend: function() {}, beforeSend: function() {},
success: function(_data) { success: function(_data) {
if(typeof _data === 'object') { if(typeof _data === 'object') {
if(_data.code == 200){
alert('保存成功'); alert('保存成功');
$("#modal-blackList").modal('hide');//提交成功后 关闭弹窗
agent.getList(0); agent.getList(0);
}else{
alert(_data.msg);
$("#modal-blackList").modal('hide');//提交成功后 关闭弹窗
agent.getList(0);
}
} else { } else {
alert('数据错误'); alert('数据错误');
}; };
......
...@@ -97,7 +97,10 @@ define(['doT', 'text!temp/black_list_template_tpl.html', 'css!style/home.css', ' ...@@ -97,7 +97,10 @@ define(['doT', 'text!temp/black_list_template_tpl.html', 'css!style/home.css', '
} }
_data['content']=$('.black-list-text').val(); _data['content']=$('.black-list-text').val();
_data['agents_black_list_id']=adjustment.agent_id; _data['agents_black_list_id']=adjustment.agent_id;
if($.trim($('.black-list-text').val()) == ''){
alert('违反公司事项内容未填写!');
return;
};
$.ajax({ $.ajax({
type: 'GET', type: 'GET',
url: '/index/addAgentsBlackList', url: '/index/addAgentsBlackList',
...@@ -107,6 +110,7 @@ define(['doT', 'text!temp/black_list_template_tpl.html', 'css!style/home.css', ' ...@@ -107,6 +110,7 @@ define(['doT', 'text!temp/black_list_template_tpl.html', 'css!style/home.css', '
success: function(_data) { success: function(_data) {
if(typeof _data === 'object') { if(typeof _data === 'object') {
alert('保存成功'); alert('保存成功');
$("#modal-blackList").modal('hide');//提交成功后 关闭弹窗
adjustment.getList(0); adjustment.getList(0);
} else { } else {
alert('数据错误'); alert('数据错误');
......
...@@ -50,23 +50,25 @@ ...@@ -50,23 +50,25 @@
[% }else{ %] [% }else{ %]
<a class="btn1 btn-info yetai_checkbox" data-toggle="modal" data-id='[%= it[item]["id"] %]' data-status='[%= it[item]["status"] %]'>长假</a> <a class="btn1 btn-info yetai_checkbox" data-toggle="modal" data-id='[%= it[item]["id"] %]' data-status='[%= it[item]["status"] %]'>长假</a>
[% } %] [% } %]
<a class="btn1 btn-default btn-default-show-caozuo">>>></a> <a class="btn1 btn-default btn-default-show-caozuo">>>></a>
[% if(check_auth('index/updateRole')) {%] [% if(check_auth('index/updateRole')) {%]
<a href="#modal-user" class="btn1 btn-danger btn-default-hide-display" id='role' href="#modal-edit" data-toggle="modal" data-id='[%= it[item]["id"] %]'>角色设置</a> <a href="#modal-user" class="btn1 btn-danger btn-default-hide-display" id='role' href="#modal-edit" data-toggle="modal" data-id='[%= it[item]["id"] %]'>角色设置</a>
[% } %] [% } %]
<!--绑定手机权限--> <!--绑定手机权限-->
[% if(check_auth('index/updateDevice')) {%] [% if(check_auth('index/updateDevice')) {%]
<a class="btn1 btn-success phone-bundling btn-default-hide-display" href="#modal-phonebundling" data-toggle="modal" data-id='[%= it[item]["id"] %]'>绑定手机/电脑</a> <a class="btn1 btn-success phone-bundling btn-default-hide-display" href="#modal-phonebundling" data-toggle="modal" data-id='[%= it[item]["id"] %]'>绑定手机/电脑</a>
<a class="btn1 btn-success btn-default-hide-display state-record" href="#modal-stateRecord" data-toggle="modal" data-id='[%= it[item]["id"] %]'>状态记录</a> <a class="btn1 btn-success btn-default-hide-display state-record" href="#modal-stateRecord" data-toggle="modal" data-id='[%= it[item]["id"] %]'>状态记录</a>
[% } %]
[% if(check_auth('index/updateDevice')) {%]
[% if(it[item]["status"] == 4) {%] [% if(it[item]["status"] == 4) {%]
<a class="btn1 btn-default btn-default-hide-display" href="" data-toggle="modal" data-id='[%= it[item]["id"] %]'>已黑化</a> <a class="btn1 btn-default btn-default-hide-display" href="" data-toggle="modal" data-id='[%= it[item]["id"] %]'>已黑化</a>
[% }else{ %] [% }else{ %]
<a class="btn1 btn-success btn-default-hide-display black-list" href="#modal-blackList" data-toggle="modal" data-id='[%= it[item]["id"] %]'>加黑名单</a> <a class="btn1 btn-success btn-default-hide-display black-list" href="#modal-blackList" data-toggle="modal" data-id='[%= it[item]["id"] %]'>加黑名单</a>
[% } %] [% } %]
[% } %] [% } %]
<a class="btn1 btn-default btn-default-hide-caozuo btn-default-hide-display"><<<</a> <a class="btn1 btn-default btn-default-hide-caozuo btn-default-hide-display"><<<</a>
[% } %] [% } %]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment