tangning 1 год назад
Родитель
Сommit
be75206f12
1 измененных файлов с 4 добавлено и 6 удалено
  1. 4 6
      src/views/productOperation/modal/detailModal.vue

+ 4 - 6
src/views/productOperation/modal/detailModal.vue

@@ -171,7 +171,6 @@
             options: getOptionList('editAuth', 1),
             onChange: async (value) => {
               let params = await getFieldsValue();
-              console.log('params', params, value);
               isEdit.value = value.target.value == 0 ? true : false;
               if (value.target.value == 1) {
                 params.lookAuth = 1;
@@ -196,7 +195,7 @@
                 {
                   field: 'isEmpower',
                   componentProps: {
-                    options: isEdit.value?[
+                    options: (isEdit.value ||!isEdit.value)?[
                       { label: '查看权限', value: 0, disabled: true },
                       { label: '编辑权限', value: 1, disabled: true },
                     ]:setOption(),
@@ -385,13 +384,12 @@
           modelRef.value = data.id ? true : false;
           setFieldsValue({
             ...setData,
-            editAuth: setData.editAuth?setData.editAuth:data.qxType ? 0 : 1,
+            editAuth: data.qxType ? 0 : setData.editAuth ? setData.editAuth : 1,
             isAuthor: 0,
           });
         } else {
           title.value = '新增客户';
         }
-        alert(isEdit.value)
         updateSchema([
           {
             field: 'isEmpower',
@@ -413,10 +411,10 @@
             field: 'editAuth',
             defaultValue: 1,
             componentProps: {
-              options: fileFlow.qxType
+              options: fileFlow.qxType 
                 ? getOptionList('editAuth', setData.editAuth)
                 : [
-                    { label: '不限时编辑', value: 1 },
+                    { label: '不限时编辑', value: 1 ,disabled: setData.editAuth == 2},
                     { label: '限时编辑', value: 2 },
                   ],
             },