|
@@ -65,6 +65,14 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<script>
|
|
|
+ //2021.11.19
|
|
|
+ var managerLevel = JSON.parse(window.sessionStorage.userInfo).managerLevel
|
|
|
+ window.onload = function(){
|
|
|
+ if(managerLevel <= '1'){
|
|
|
+ $('#saves').hide()
|
|
|
+ $('#updates').hide()
|
|
|
+ }
|
|
|
+ }
|
|
|
var date = new Date();
|
|
|
var month = date.getMonth()
|
|
|
if (month >= 1 && month <= 9) {
|
|
@@ -316,6 +324,8 @@
|
|
|
view: false, // 打印视图
|
|
|
zoom: false, // 缩放
|
|
|
},
|
|
|
+ // 2021.11.19
|
|
|
+ enableAddRow: managerLevel <= '1' ? false : true, //允许添加行(表格底部添加按钮)
|
|
|
showinfobar: true,
|
|
|
functionButton: '<button id="updates" class="btn btn-primary" style="padding:3px 6px;font-size: 12px;margin-right: 10px;">开启编辑</button> <button id="saves" class="btn btn-primary btn-danger" style=" padding:3px 6px; font-size: 12px; margin-right: 10px;display:none">保存</button>',
|
|
|
cellRightClickConfig: {
|
|
@@ -346,12 +356,20 @@
|
|
|
},
|
|
|
hook: {
|
|
|
cellMousedown: function (a, b, c) {
|
|
|
+ //2021.11.19
|
|
|
+ if(managerLevel <= '1' ){
|
|
|
+ window.top.$vm.$message({
|
|
|
+ message: '您没有编辑权限',
|
|
|
+ type: 'info'
|
|
|
+ })
|
|
|
+ }else
|
|
|
if (flag == false) {
|
|
|
window.top.$vm.$message({
|
|
|
message: '请先点击开启编辑按钮',
|
|
|
type: 'info'
|
|
|
})
|
|
|
}
|
|
|
+
|
|
|
},//绑定鼠标事件
|
|
|
},
|
|
|
})
|
|
@@ -405,6 +423,7 @@
|
|
|
});
|
|
|
})
|
|
|
}
|
|
|
+
|
|
|
</script>
|
|
|
</body>
|
|
|
|