Explorar el Código

Merge remote-tracking branch 'origin/demo_' into demo_

hfxc226 hace 2 años
padre
commit
a687600508

+ 2 - 2
src/views/repair/application-form/modules/BaseForm.vue

@@ -85,7 +85,7 @@
         </row-item>
         <row-item>
           <a-form-item
-            label="工作类型"
+            label="特殊作业类型"
             :labelCol="BaseTool.Constant.labelCol"
             :wrapperCol="BaseTool.Constant.wrapperCol"
           >
@@ -120,7 +120,7 @@
             :labelCol="BaseTool.Constant.labelCol"
             :wrapperCol="BaseTool.Constant.wrapperCol"
           >
-            <a-select v-decorator="['category', {rules: [{required: true, message: '计划性维修不能为空'}]}]" placeholder="请选择">
+            <a-select @change="changePlanFlag" v-decorator="['category', {rules: [{required: true, message: '计划性维修不能为空'}]}]" placeholder="请选择">
               <a-select-option
                 v-for="(label,value) in categoryMap"
                 :key="value"

+ 1 - 1
src/views/repair/application-form/modules/TicketForm.vue

@@ -249,8 +249,8 @@
     </div>
   </div>
 </template>
-
 <script>
+import { stringify } from 'qs'
 export default {
   data () {
     return {

+ 20 - 7
src/views/sb/info/modules/SbInfoSelectModal.vue

@@ -42,6 +42,20 @@
                 </a-select>
               </a-form-item>
             </a-col>
+            <a-col :md="6" :sm="24">
+              <a-form-item label="设备类型">
+                <a-tree-select
+                  style="width: 100%"
+                  :dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }"
+                  :treeData="treeData"
+                  :treeNodeFilterProp="'title'"
+                  :showSearch="true"
+                  v-model="queryParam.typeId"
+                  placeholder="请选择"
+                >
+                </a-tree-select>
+              </a-form-item>
+            </a-col>
             <a-col :md="8 || 24" :sm="24">
               <span class="table-page-search-submitButtons">
                 <a-button type="primary" @click="$refs.table.refresh(true)">查询</a-button>
@@ -88,6 +102,7 @@
 import { STable, Ellipsis } from '@/components'
 import { getSbInfoPage, fetchSbInfo, getSbInfoTree } from '@/api/sb/info'
 import { querySbPosition } from '@/api/sb/position'
+import { fetchSbTypeTree } from '@/api/sb/type'
 
 export default {
   name: 'SbInfoSelectModal',
@@ -234,10 +249,13 @@ export default {
     querySbPosition().then(res => {
       this.sbPositionData = res.data
     })
+    fetchSbTypeTree().then(res => {
+      this.treeData = res.data
+    })
   },
   methods: {
     tableOption () {
-      this.setTree()
+      //this.setTree()
       if (!this.optionAlertShow) {
         this.options = {
           alert: { show: true, clear: () => { this.selectedRowKeys = [] } },
@@ -277,7 +295,7 @@ export default {
       }
     },
     handleOk () {
-      this.setTree()
+      //this.setTree()
       this.$refs.table.refresh()
     },
     onSelectChange (selectedRowKeys, selectedRows) {
@@ -292,11 +310,6 @@ export default {
     /**
      * 设置设备类型树
      */
-    setTree (record = {}) {
-      getSbInfoTree({ id: record.id }).then(res => {
-        this.treeData = res.data
-      })
-    },
     base (record, queryParam = {}) {
       this.visible = true
       this.modalTitle = '选择设备'