浏览代码

开放科研专责合同编辑权限

梁世豪 5 月之前
父节点
当前提交
99d2b1ef55

+ 6 - 6
src/main/resources/templates/prjcontract/list.html

@@ -175,7 +175,7 @@
175
                 ]
175
                 ]
176
             ],
176
             ],
177
             autoSort: false,
177
             autoSort: false,
178
-            limits: [10, 15, 20, 25, 50, 100],
178
+            limits: [10, 15, 20, 25, 50, 100,200,500],
179
             limit: 10,
179
             limit: 10,
180
             page: true,
180
             page: true,
181
             skin: 'grid',
181
             skin: 'grid',
@@ -282,7 +282,7 @@
282
                     Message.warning("请选择要编辑的合同!", 1500);
282
                     Message.warning("请选择要编辑的合同!", 1500);
283
                 } else if (data[0].length > 1) {
283
                 } else if (data[0].length > 1) {
284
                     Message.warning("请选择一条记录进行编辑操作!", 1500);
284
                     Message.warning("请选择一条记录进行编辑操作!", 1500);
285
-                } else if (data[0].spzt =='已锁定'){
285
+                } else if (data[0].spzt =='已锁定'&& userId !=42){
286
                     Message.warning("该合同已锁定不能编辑!")
286
                     Message.warning("该合同已锁定不能编辑!")
287
                 }else {
287
                 }else {
288
                     xmApproval = {
288
                     xmApproval = {
@@ -480,14 +480,14 @@
480
                     Message.warning("请选择要删除的合同!", 1500);
480
                     Message.warning("请选择要删除的合同!", 1500);
481
                     return;
481
                     return;
482
                 }
482
                 }
483
-                else if (data[0].cjr != userId){
483
+                else if (data[0].cjr != userId&&userPostName !='科技项目管理专责'&&userPostName !='科技项目管理专责2'){
484
                     Message.warning('你不是当前合同创建人,不能删除!',1500);
484
                     Message.warning('你不是当前合同创建人,不能删除!',1500);
485
                     return;
485
                     return;
486
                 }
486
                 }
487
-                else if (data[0].spzt !== '未锁定'){
487
+                else if (data[0].spzt !== '未锁定'&&userPostName !='科技项目管理专责'&&userPostName !='科技项目管理专责2'){
488
                     Message.warning('当前合同已锁定,不能删除',1500);
488
                     Message.warning('当前合同已锁定,不能删除',1500);
489
                     return;
489
                     return;
490
-                }else if (num !=0){
490
+                }else if (num !=0&&userPostName !='科技项目管理专责'&&userPostName !='科技项目管理专责2'){
491
                     Message.warning("当前合同仍关联"+num+"条付款申请,请先处理关联项!",2000)
491
                     Message.warning("当前合同仍关联"+num+"条付款申请,请先处理关联项!",2000)
492
                 }else {
492
                 }else {
493
                 layer.confirm('确定删除合同吗?', function (index) {
493
                 layer.confirm('确定删除合同吗?', function (index) {
@@ -513,7 +513,7 @@
513
                 }
513
                 }
514
                     }
514
                     }
515
                 })
515
                 })
516
-            }else  if (obj.event ="viewXgsq"){
516
+            }else  if (obj.event ==="viewXgsq"){
517
                 var index = layer.open({
517
                 var index = layer.open({
518
                     title: '修改申请',
518
                     title: '修改申请',
519
                     type: 2,
519
                     type: 2,

+ 3 - 1
src/main/resources/templates/prjcontract/update.html

@@ -232,6 +232,8 @@
232
         var rwsId = $("#rws").val();
232
         var rwsId = $("#rws").val();
233
         var xmApproval = parent.getXmApproval();
233
         var xmApproval = parent.getXmApproval();
234
         var spzt =xmApproval.spzt;
234
         var spzt =xmApproval.spzt;
235
+        var userPostName = [[${userPostName}]]
236
+
235
         console.log(spzt)
237
         console.log(spzt)
236
         //申请时间
238
         //申请时间
237
         laydate.render({
239
         laydate.render({
@@ -424,7 +426,7 @@
424
 
426
 
425
         // 监听确认按钮(常规)
427
         // 监听确认按钮(常规)
426
         form.on('submit(saveBtn)', function (data) {
428
         form.on('submit(saveBtn)', function (data) {
427
-            if (spzt !=='未锁定'){
429
+            if (spzt !=='未锁定'&&userPostName !='科技项目管理专责'&&userPostName !='科技项目管理专责2'){
428
                 Message.warning("该合同状态为锁定中,只能修改付款计划,不可修改常规信息!", 2000);
430
                 Message.warning("该合同状态为锁定中,只能修改付款计划,不可修改常规信息!", 2000);
429
                 return false;
431
                 return false;
430
             }
432
             }