فهرست منبع

森语OA-质量事故单

jbb 2 سال پیش
والد
کامیت
3a95d4e84a

+ 13 - 0
src/views/oa/IncidentTicketList.vue

@@ -95,6 +95,12 @@
             下载
           </a-button>
         </template>
+        <span slot="state" slot-scope="text, record">
+          <span v-if="record.state =='5'">已完结</span>
+          <span v-if="record.state =='4'">已推送</span>
+          <span v-if="record.state =='3'">已反馈通知</span>
+          <span v-if="record.state =='2'">已通知</span>
+        </span>
 
         <span slot="action" slot-scope="text, record">
           <a @click="handleEdit(record,'edit')">编辑</a>
@@ -114,6 +120,7 @@
           </a-dropdown> -->
         </span>
 
+
       </a-table>
     </div>
 
@@ -175,6 +182,12 @@
             align:"center",
             dataIndex: 'businessType'
           },
+          {
+            title:'状态',
+            align:"center",
+            dataIndex: 'state',
+            scopedSlots: { customRender: 'state' },
+          },
           {
             title: '操作',
             dataIndex: 'action',

+ 9 - 1
src/views/oa/modules/IncidentTicketModal.vue

@@ -57,7 +57,8 @@
           <a-row :gutter="24">
             <a-col :span="8">
             <a-form-model-item label="添加附件" prop="accessory2">
-              <a-input v-model="formState.accessory2"  placeholder="请输入"></a-input>
+              <j-upload  v-model="formState.accessory2"  ></j-upload>
+              <!-- <a-input v-model="formState.accessory2"  placeholder="请输入"></a-input> -->
             </a-form-model-item>
           </a-col>
           <a-col :span="8">
@@ -101,12 +102,14 @@
   import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
   import { validateDuplicateValue } from '@/utils/util'
   import JDictSelectTag from "@/components/dict/JDictSelectTag"
+  import JUpload from '@/components/jeecg/JUpload'
   import { putAction,getAction } from '@/api/manage'
   export default {
     name: 'IncidentTicketModal',
     mixins: [JEditableTableMixin],
     components: {
       JDictSelectTag,
+      JUpload
     },
     data() {
       return {
@@ -210,6 +213,7 @@
         refKeys: ['incidentTicketChildren', ],
         tableKeys:['incidentTicketChildren', ],
         activeKey: 'incidentTicketChildren',
+        accessory2:'',
         // 森_工厂质量事故单-子表
         incidentTicketChildrenTable: {
           loading: false,
@@ -290,6 +294,8 @@
           if(res.success){
             var zhuId = '' //主表id
              this.formState=res.result //详情
+             this.formState.accessory2 = JSON.parse(this.formState.accessory2)
+             this.formState.accessory2=this.formState.accessory2[0].name
              zhuId = res.result.id
              this.getTable(zhuId)
              this.getNotifier(zhuId)
@@ -323,6 +329,8 @@
       handleOk(){
         this.$refs.form.validate(async valid => {
          if(valid){
+          this.formState.accessory2 = [{"type":"file","name":this.formState.accessory2,"status":"done","uid":1673507319016,"url":"http://220.191.168.86:18087/jeecg-boot/sys/common/static/"+this.formState.accessory2}]
+          this.formState.accessory2 = JSON.stringify(this.formState.accessory2)
             var obj = this.formState
             obj.incidentTicketChildrenList =  this.incidentTicketChildrenTable.dataSource 
                 putAction('/oa/incidentTicket/edit', obj).then((res) => {

+ 20 - 9
src/views/oa/modules/IncidentTicketModalDetail.vue

@@ -11,14 +11,14 @@
     <template #footer>
         <a-button  @click="handleCancel" style="margin-left: 8px;">取消</a-button>
         <a-button  type="primary"  @click="addNotice" style="margin-left: 8px;" :disabled="!(formState.state=='1')">通知</a-button>
-        <a-popconfirm title="确定反馈通知吗?" ok-text="是" cancel-text="否" @confirm="feedbackNotice">
-          <a-button  type="primary"   style="margin-left: 8px;" :disabled="!(formState.state=='2')">反馈通知</a-button>
+        <a-popconfirm title="确定反馈通知吗?" ok-text="是" cancel-text="否" @confirm="feedbackNotice" :visible="visibleFk">
+          <a-button  type="primary"   style="margin-left: 8px;" :disabled="!(formState.state=='2')" @click="()=>visibleFk = true">反馈通知</a-button>
         </a-popconfirm>
-        <a-popconfirm title="确定推送吗?" ok-text="是" cancel-text="否" @confirm="push">
-          <a-button  type="primary"   style="margin-left: 8px;" :disabled="!(formState.state=='3')">推送</a-button>
+        <a-popconfirm title="确定推送吗?" ok-text="是" cancel-text="否" @confirm="push" :visible="visibleTs">
+          <a-button  type="primary"   style="margin-left: 8px;" :disabled="!(formState.state=='3')" @click="()=>visibleTs = true">推送</a-button>
         </a-popconfirm>
-        <a-popconfirm title="确定完结吗?" ok-text="是" cancel-text="否" @confirm="end">
-          <a-button  type="primary"   style="margin-left: 8px;" :disabled="!(formState.state=='4')">完结</a-button>
+        <a-popconfirm title="确定完结吗?" ok-text="是" cancel-text="否" @confirm="end"  :visible="visibleWj">
+          <a-button  type="primary"   style="margin-left: 8px;" :disabled="!(formState.state=='4')" @click="()=>visibleWj = true">完结</a-button>
         </a-popconfirm>
       </template>
     <a-spin :spinning="confirmLoading">
@@ -67,8 +67,9 @@
           </a-row>
           <a-row :gutter="24">
             <a-col :span="8">
-            <a-form-model-item label="添加附件" prop="accessory2">
-              <a-input v-model="formState.accessory2"  placeholder="请输入" readOnly></a-input>
+              <a-form-model-item label="添加附件" prop="accessory2">
+              <j-upload  v-model="formState.accessory2"  ></j-upload>
+              <!-- <a-input v-model="formState.accessory2"  placeholder="请输入"></a-input> -->
             </a-form-model-item>
           </a-col>
           <a-col :span="8">
@@ -93,12 +94,14 @@
   import { validateDuplicateValue } from '@/utils/util'
   import JDictSelectTag from "@/components/dict/JDictSelectTag"
   import { putAction,getAction } from '@/api/manage'
+  import JUpload from '@/components/jeecg/JUpload'
   export default {
     name: 'IncidentTicketModalDetail',
     mixins: [JEditableTableMixin],
     components: {
       JDictSelectTag,
-      JSelectBizComponent
+      JSelectBizComponent,
+      JUpload
     },
     data() {
       return {
@@ -115,6 +118,9 @@
           span: 20
         },
         formState:{},
+        visibleFk:false,
+        visibleTs:false,
+        visibleWj:false,
         columns: [
           { title: '姓名', align: 'center', width: '20%', widthRight: '70%', dataIndex: 'realname' },
           { title: '账号', align: 'center', width: '20%', dataIndex: 'username' },
@@ -336,6 +342,8 @@
           if(res.success){
             var zhuId = '' //主表id
              this.formState=res.result //详情
+             this.formState.accessory2 = JSON.parse(this.formState.accessory2)
+             this.formState.accessory2=this.formState.accessory2[0].name
              zhuId = res.result.id
              this.getTable(zhuId)
              this.getNotifier(zhuId)
@@ -370,6 +378,9 @@
         this.incidentTicketChildrenTable.dataSource =[]
         this.formState = {}
         this.visible = false
+        this.visibleWj = false
+        this.visibleTs = false
+        this.visibleFk = false
         this.$emit('close')
       },
       // getAllTable() {