Browse Source

bug:员工技能不能重复

lupeng 10 tháng trước cách đây
mục cha
commit
27b651ccee
1 tập tin đã thay đổi với 4 bổ sung9 xóa
  1. 4 9
      src/views/base/skill/components/edit-skill.vue

+ 4 - 9
src/views/base/skill/components/edit-skill.vue

@@ -253,14 +253,6 @@ option2.value = {
       disabled: true,
       dicUrl: dictDataUtil.post_list_url,
       dicMethod: "post",
-      change: ({ value, column }) => {
-        if (value !== undefined) {
-          props.postId = value;
-          skillValue.value = null;
-          optionSkill.value = null;
-          dataList();
-        }
-      },
       props: { label: "postName", value: "id" },
     },
     { label: "所属机构", prop: "deptName", overHidden: true, disabled: true },
@@ -328,7 +320,10 @@ option.value = Object.assign(option.value, {
       blur: function (row) {
         if (
           data.value
-            .map((item) => {
+            .filter((value, index) => {
+              return index != row.index;
+            })
+            .map((item, index) => {
               return item.skillDictValue;
             })
             .includes(row.value)