Pārlūkot izejas kodu

解决冲突文件

695593266@qq.com 10 mēneši atpakaļ
vecāks
revīzija
7e75970ac1

+ 33 - 19
src/views/classifyManage/treeClassify/details.vue

@@ -39,7 +39,6 @@
                 :disabled="!current.id || current.id == rootId"
                 @click="deleteCategory"
                 v-if="$hasPermission('main:categorylevel:delete')"
-
               >
                 删除
               </el-button>
@@ -54,7 +53,11 @@
               :highlight-current="true"
               node-key="id"
               @node-click="handleNodeClick"
-            ></el-tree>
+            >
+              <span class="custom-tree-node" slot-scope="{ node, data }">
+                {{ (isCode == 1 ? data.code : '') + ' ' + data.name }}
+              </span>
+            </el-tree>
           </div>
         </div>
         <template v-slot:content>
@@ -104,7 +107,7 @@
                   <el-col v-bind="styleResponsive ? { sm: 12 } : { span: 12 }">
                     <el-form-item label="状态:">
                       <div class="ele-text-secondary">
-                        {{ current.isEnabled===0?'停用':'启用' }}
+                        {{ current.isEnabled === 0 ? '停用' : '启用' }}
                       </div>
                     </el-form-item>
                   </el-col>
@@ -148,7 +151,7 @@
                   <el-col v-bind="styleResponsive ? { sm: 12 } : { span: 12 }">
                     <el-form-item label="状态:">
                       <div class="ele-text-secondary">
-                        {{ current.isEnabled===0?'停用':'启用' }}
+                        {{ current.isEnabled === 0 ? '停用' : '启用' }}
                       </div>
                     </el-form-item>
                   </el-col>
@@ -178,19 +181,22 @@
     getInfoById,
     deleteCategory
   } from '@/api/classifyManage';
+  import { parameterGetByCode } from '@/api/system/dictionary/index.js';
+
   export default {
     components: {
       classifyManageEdit,
       ListEdit
     },
     mixins: [dictMixins],
-    data () {
+    data() {
       return {
         loading: false,
         current: {},
         curNode: {},
         treeData: [],
         formData: {},
+        isCode: 0,
         defaultProps: {
           children: 'children',
           label: 'name'
@@ -200,13 +206,13 @@
 
     computed: {
       // 是否开启响应式布局
-      styleResponsive () {
+      styleResponsive() {
         return this.$store.state.theme.styleResponsive;
       },
-      rootId () {
+      rootId() {
         return this.$route.query.id;
       },
-      fullName () {
+      fullName() {
         let str = '';
         let codeStr = '';
         let node = this.curNode;
@@ -222,7 +228,7 @@
         );
       }
     },
-    created () {
+    created() {
       this.requestDict('类型用途');
       this.requestDict('分隔符');
       this.getTree().then(() => {
@@ -230,9 +236,17 @@
           this.getDetail(this.treeData[0]?.id);
         });
       });
+      //是否显示code
+      parameterGetByCode({
+        code: 'mian_treeClassify_code'
+      }).then((res) => {
+        if (res.value) {
+          this.isCode = res.value;
+        }
+      });
     },
     methods: {
-      async reload (isEdit) {
+      async reload(isEdit) {
         if (isEdit) {
           this.getTree().then(() => {
             this.getDetail(this.current.id);
@@ -241,13 +255,13 @@
           this.getTree();
         }
       },
-      back(){
-        this.$router.push('/treeClassify')
+      back() {
+        this.$router.push('/treeClassify');
       },
-      handlOpen () {
+      handlOpen() {
         this.$refs.addDialog.open();
       },
-      deleteCategory () {
+      deleteCategory() {
         this.$confirm('确定要删除选中节点吗?', '提示', {
           type: 'warning'
         }).then(async () => {
@@ -262,7 +276,7 @@
           }
         });
       },
-      async getTree () {
+      async getTree() {
         const res = await getTreeByPid(this.rootId);
 
         if (res.code == '0') {
@@ -272,7 +286,7 @@
 
         return Promise.reject();
       },
-      async getDetail (id) {
+      async getDetail(id) {
         this.loading = true;
         const res = await getInfoById(id);
         this.loading = false;
@@ -283,10 +297,10 @@
           });
         }
       },
-      openEdit (isAdd = true) {
+      openEdit(isAdd = true) {
         this.$refs.editRef.open(isAdd ? null : this.current, this.current);
       },
-      handleNodeClick (data, node) {
+      handleNodeClick(data, node) {
         this.curNode = node;
         this.getDetail(data.id);
       }
@@ -318,7 +332,7 @@
   .form-wrapper {
     padding: 24px;
   }
-  .ele-toolbar-actions :deep(.ele-table-tool-title-content){
+  .ele-toolbar-actions :deep(.ele-table-tool-title-content) {
     display: flex;
     justify-content: space-between;
   }

+ 140 - 139
src/views/codeManagement/businessCode/codeValueList.vue

@@ -73,7 +73,6 @@
             title="确定要删除此码值吗?"
             @confirm="remove(scoped.$index)"
             v-if="$hasPermission('mian:businessCode:delete')"
-
           >
             <template v-slot:reference>
               <el-button type="danger"> 删除 </el-button>
@@ -90,7 +89,10 @@
         <template v-slot:remark="{ row }">
           <el-input v-model="row.remark" @change="valueChange(row)"></el-input>
         </template>
-        <template v-slot:toolbar v-if="form.roughRule != 4&&$hasPermission('mian:businessCode:save')">
+        <template
+          v-slot:toolbar
+          v-if="form.roughRule != 4 && $hasPermission('mian:businessCode:save')"
+        >
           <el-button type="primary" @click.native="openEdit('add')">
             增加
           </el-button>
@@ -102,148 +104,147 @@
 </template>
 
 <script>
-  import { roughRule, fineRule } from '@/enum/dict.js';
-  import { saveSegment } from '@/api/businessCode';
+import { roughRule, fineRule } from '@/enum/dict.js';
+import { saveSegment } from '@/api/businessCode';
 
-  export default {
-    props: {
-      // 上级
-      parentData: {
-        type: Object,
-        default: () => {}
-      }
-    },
+export default {
+  props: {
+    // 上级
+    parentData: {
+      type: Object,
+      default: () => {}
+    }
+  },
 
-    data() {
-      return {
-        form: {
-          roughRuleName: '',
-          fineRuleName: '',
-          name: '', //码段名称
-          businessCodeCategoryId: '', //分类id
-          length: '', //长度
-          delimiter: '', //间隔符
-          roughRule: '', //粗规则
-          fineRule: '', //细规则
-          value: [],
-          remark: '' //描述
-        },
-        tableList: [],
-        // 表格列配置
-        columns: []
-      };
-    },
-    created() {},
-    // watch: {
-    //   parentData(){
-    //     this.init()
-    //   }
-    // },
-    methods: {
-      reload() {
-        this.form = JSON.parse(JSON.stringify(this.parentData));
-        this.tableList = this.form.value;
-        this.form['roughRuleName'] = roughRule.find(
-          (item) => item.value == this.form.roughRule
-        )?.label;
-        let _fineRule = fineRule.filter(
-          (item) => item.pid == this.form.roughRule
-        );
-        this.form['fineRuleName'] = _fineRule.find(
-          (item) => item.value == this.form.fineRule
-        )?.label;
-        this.setColumns();
-      },
-      setColumns() {
-        this.columns = [
-          {
-            width: 45,
-            type: 'selection',
-            columnKey: 'selection',
-            align: 'center'
-          },
-          {
-            label:
-              '编码值' +
-              '(规则:' +
-              this.form.fineRuleName +
-              ',长度:' +
-              (this.form.length || '') +
-              ')',
-            prop: 'value',
-            width: 240,
-            slot: 'value',
-            showOverflowTooltip: true,
-            fixed: 'left'
-          },
-          {
-            prop: 'remark',
-            slot: 'remark',
-            label: '描述',
-            showOverflowTooltip: true
-          },
-          {
-            columnKey: 'action',
-            label: '操作',
-            width: 200,
-            align: 'center',
-            resizable: false,
-            slot: 'action',
-            showOverflowTooltip: true,
-            fixed: 'right'
-          }
-        ];
+  data() {
+    return {
+      form: {
+        roughRuleName: '',
+        fineRuleName: '',
+        name: '', //码段名称
+        businessCodeCategoryId: '', //分类id
+        length: '', //长度
+        delimiter: '', //间隔符
+        roughRule: '', //粗规则
+        fineRule: '', //细规则
+        value: [],
+        remark: '' //描述
       },
-      valueChange(row) {
-        console.log(this.isReg(row), 'this.isReg(row)');
-        if (this.isReg(row)) {
-          this.save();
-        }
-      },
-      isReg(row) {
-        if (this.form.roughRule == 6) {
-          if (row.value.length == this.form.length) {
-            return true;
-          } else {
-            return false;
-          }
+      tableList: [],
+      // 表格列配置
+      columns: []
+    };
+  },
+  created() {},
+  // watch: {
+  //   parentData(){
+  //     this.init()
+  //   }
+  // },
+  //1111
+  methods: {
+    reload() {
+      this.form = JSON.parse(JSON.stringify(this.parentData));
+      this.tableList = this.form.value;
+      this.form['roughRuleName'] = roughRule.find(
+        (item) => item.value == this.form.roughRule
+      )?.label;
+      let _fineRule = fineRule.filter(
+        (item) => item.pid == this.form.roughRule
+      );
+      this.form['fineRuleName'] = _fineRule.find(
+        (item) => item.value == this.form.fineRule
+      )?.label;
+      this.setColumns();
+    },
+    setColumns() {
+      this.columns = [
+        {
+          width: 45,
+          type: 'selection',
+          columnKey: 'selection',
+          align: 'center'
+        },
+        {
+          label:
+            '编码值' +
+            '(规则:' +
+            this.form.fineRuleName +
+            ',长度:' +
+            (this.form.length || '') +
+            ')',
+          prop: 'value',
+          width: 240,
+          slot: 'value',
+          showOverflowTooltip: true,
+          fixed: 'left'
+        },
+        {
+          prop: 'remark',
+          slot: 'remark',
+          label: '描述',
+          showOverflowTooltip: true
+        },
+        {
+          columnKey: 'action',
+          label: '操作',
+          width: 200,
+          align: 'center',
+          resizable: false,
+          slot: 'action',
+          showOverflowTooltip: true,
+          fixed: 'right'
         }
-        let _fineRule = fineRule.filter(
-          (item) => item.pid == this.form.roughRule
-        );
-        let reg = _fineRule.find(
-          (item) => item.value == this.form.fineRule
-        )?.reg;
-        let regexp = '/^' + reg + '{' + this.form.length + '}$/';
-        return RegExp(eval(regexp)).test(row.value);
-      },
-      /* 显示编辑 */
-      openEdit() {
-        this.tableList.push({
-          value: '',
-          remark: ''
-        });
-      },
-      /* 保存编辑 */
-      save() {
-        this.form.value = this.tableList;
-        saveSegment(this.form)
-          .then((msg) => {
-            this.$message.success('操作成功');
-            this.$emit('done', this.form);
-          })
-          .catch((e) => {
-            this.loading = false;
-          });
-      },
-      /* 删除 */
-      remove(index) {
-        this.tableList.splice(index, 1);
+      ];
+    },
+    valueChange(row) {
+      console.log(this.isReg(row), 'this.isReg(row)');
+      if (this.isReg(row)) {
         this.save();
-      },
-      done() {
-        this.$emit('done', this.parentData);
       }
+    },
+    isReg(row) {
+      if (this.form.roughRule == 6) {
+        if (row.value.length == this.form.length) {
+          return true;
+        } else {
+          return false;
+        }
+      }
+      let _fineRule = fineRule.filter(
+        (item) => item.pid == this.form.roughRule
+      );
+      let reg = _fineRule.find((item) => item.value == this.form.fineRule)?.reg;
+      let regexp = '/^' + reg + '{' + this.form.length + '}$/';
+      return RegExp(eval(regexp)).test(row.value);
+    },
+    /* 显示编辑 */
+    openEdit() {
+      this.tableList.push({
+        value: '',
+        remark: ''
+      });
+    },
+    /* 保存编辑 */
+    save() {
+      this.form.value = this.tableList;
+      saveSegment(this.form)
+        .then((msg) => {
+          this.$message.success('操作成功');
+          this.$emit('done', this.form);
+        })
+        .catch((e) => {
+          this.loading = false;
+        });
+    },
+    /* 删除 */
+    remove(index) {
+      this.tableList.splice(index, 1);
+      this.save();
+    },
+    done() {
+      this.$emit('done', this.parentData);
     }
-  };
+  }
+};
 </script>

+ 19 - 1
src/views/material/product/components/index-data.vue

@@ -139,6 +139,14 @@
       </template>
 
       <template v-slot:action="{ row }">
+        <!-- <el-link
+          type="primary"
+          :underline="false"
+          @click="openEdit(row, 1)"
+          v-if="$hasPermission('main:category:update')"
+        >
+          {{ row.isEnabled == 1 ? '停用' : '启用' }}
+        </el-link> -->
         <el-link
           type="primary"
           :underline="false"
@@ -464,6 +472,16 @@
             align: 'center',
             showOverflowTooltip: true
           },
+          {
+            prop: 'bomStatus',
+            label: 'BOM状态',
+            align: 'center',
+            minWidth: 120,
+            formatter: (row, column) => {
+              return row.bomStatus == 1 ? '有' : '无';
+            },
+            showOverflowTooltip: true
+          },
           {
             prop: 'isUnpack',
             label: '是否允许拆包',
@@ -806,7 +824,7 @@
             {
               columnKey: 'action',
               label: '操作',
-              width: 220,
+              width: 260,
               align: 'center',
               resizable: false,
               slot: 'action',

+ 12 - 3
src/views/material/product/components/index-search.vue

@@ -44,7 +44,14 @@
           />
         </el-form-item>
       </el-col>
-
+      <el-col v-bind="styleResponsive ? { lg: 5, md: 10 } : { span: 5 }">
+        <el-form-item label="BOM状态">
+          <el-select v-model="where.bomStatus" style="width: 100%" clearable>
+            <el-option :value="1" label="有"></el-option>
+            <el-option :value="0" label="无"></el-option>
+          </el-select>
+        </el-form-item>
+      </el-col>
       <!-- <el-col v-bind="styleResponsive ? { lg: 5, md: 10 } : { span: 5 }">
         <el-form-item label="BOM状态">
           <el-input
@@ -109,7 +116,8 @@
       const defaultWhere = {
         name: '',
         code: '',
-        modelType: ''
+        modelType: '',
+        bomStatus: ''
       };
       return {
         defaultWhere,
@@ -125,7 +133,8 @@
             id: 0,
             label: '无'
           }
-        ]
+        ],
+        loading: false
       };
     },
     computed: {

+ 8 - 2
src/views/rulesManagement/releaseRules/index.vue

@@ -158,14 +158,20 @@
             label: '启用日期',
             align: 'center',
             showOverflowTooltip: true,
-            minWidth: 110
+            minWidth: 110,
+            formatter: (row) => {
+              return this.$util.toDateString(row.startDate, 'yyyy-MM-dd');
+            }
           },
           {
             prop: 'stopDate',
             label: '停用日期',
             align: 'center',
             showOverflowTooltip: true,
-            minWidth: 110
+            minWidth: 110,
+            formatter: (row) => {
+              return this.$util.toDateString(row.stopDate, 'yyyy-MM-dd');
+            }
           },
           {
             prop: '',

+ 1 - 1
src/views/system/organization/components/org-user-search.vue

@@ -40,7 +40,7 @@
       </el-col>
       <el-col v-bind="styleResponsive ? { md: 6 } : { span: 6 }">
         <DictSelection
-          dictName="岗位"
+          dictName="岗位"   placeholder="请选择岗位"
           clearable
           filterable
           v-model="where.postId"

+ 1 - 0
vue.config.js

@@ -42,6 +42,7 @@ module.exports = {
         // target: 'http://192.168.1.251:18186',
 
         // target: 'http://192.168.1.251:18087',
+        target: 'http://192.168.1.251:18086',
 
         // target: 'http://192.168.1.116:18086',