index.vue 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. <template>
  2. <zj-page-container>
  3. <zj-page-fill class="neibuview">
  4. <zj-form-container ref="formRef" :form-data="orderInfo" :form-rules="formRules" :form-attributes="{ size: 'mini' }">
  5. <!-- 派工信息 创建不需要 -->
  6. <zj-form-module title="派工信息" label-width="68px" :form-data="orderInfo" :form-items="dispatchInfo">
  7. <div slot="internal-bottom">
  8. <copy-info text="复制工单信息" :info="dispatchInfo" :order-info="orderInfo" />
  9. </div>
  10. <div slot="right" style="width: 55%; position: relative">
  11. <div class="pgxxTable">
  12. <zj-table key="paigongxinxitable" :columns="pgxxColumns" :table-data="pgxxTableData" :table-attributes="{
  13. height: '100%',
  14. border: true
  15. }" />
  16. </div>
  17. </div>
  18. </zj-form-module>
  19. <!-- 基本信息 -->
  20. <zj-form-module title="基本信息" label-width="100px" :form-data="orderInfo" :form-items="basicInfo" />
  21. <!-- 服务信息 -->
  22. <zj-form-module title="服务信息" label-width="100px" :form-data="orderInfo" :form-items="serviceInfo" />
  23. <!-- 产品信息 -->
  24. <zj-form-module :title="`<span style='color:red'>*</span> ${orderInfo.serviceCategoryId == 1 ? '产品信息' : '服务内容'}`"
  25. :form-data="orderInfo" :form-items="product">
  26. </zj-form-module>
  27. <!-- 其它信息 -->
  28. <zj-form-module title="其它信息" label-width="80px" :form-data="orderInfo" :form-items="otherInfo" />
  29. <!-- 派单信息 -->
  30. <zj-form-module label-width="100px" title="派单信息" :form-data="orderInfo" :form-items="pandanxinxi" />
  31. </zj-form-container>
  32. </zj-page-fill>
  33. <!-- 操作按钮 -->
  34. <div>
  35. <div style="box-sizing: border-box;padding: 10px 10px 0;" v-if="id">
  36. <!-- 关闭 -->
  37. <close-button />
  38. <!-- 临时保存 -->
  39. <commit-temp-save v-if="~btnRestrict.indexOf(25)" :order-info="orderInfo" :order-type="orderType"
  40. @upoptions="upoptions" />
  41. <!-- 关闭工单 -->
  42. <close-order v-if="~btnRestrict.indexOf(1)" :order-info="{ ...orderInfo }" :order-type="orderType"
  43. @upoptions="upoptions" />
  44. <!-- 过程反馈 -->
  45. <process-feedback v-if="~btnRestrict.indexOf(11)" :order-info="orderInfo" :order-type="orderType"
  46. @upoptions="upoptions" />
  47. <!-- 驳回 -->
  48. <div class="withinLine">
  49. <rejectOrder v-if="~btnRestrict.indexOf(13)" :order-info="orderInfo" @upoptions="upoptions" />
  50. </div>
  51. <!-- 备注 -->
  52. <process-feedback v-if="~btnRestrict.indexOf(14)" :order-info="orderInfo" :order-type="orderType"
  53. resultCode_="999" resultCodeName="备注" @upoptions="upoptions" />
  54. <!-- 作废 -->
  55. <void-view v-if="~btnRestrict.indexOf(15)" :order-info="orderInfo" :order-type="orderType"
  56. @upoptions="upoptions" />
  57. <!-- 激活工单 -->
  58. <activate v-if="~btnRestrict.indexOf(16)" :order-info="orderInfo" :order-type="orderType"
  59. @upoptions="upoptions" />
  60. </div>
  61. <div style="box-sizing: border-box;padding: 10px 10px 0;" v-else>
  62. <!-- 关闭 -->
  63. <close-button />
  64. <!-- 临时保存 -->
  65. <commit-temp-save :order-info="orderInfo" :order-type="orderType" @upoptions="upoptions" />
  66. <!-- 下派工单 -->
  67. <commit-save :order-info="orderInfo" :order-type="orderType" :cp_gpsAddress="cp_gpsAddress"
  68. @upoptions="upoptions" />
  69. </div>
  70. </div>
  71. </zj-page-container>
  72. </template>
  73. <script>
  74. import workOrderSelectData from './mixins/workOrderSelectData.js'
  75. import workOrderLogic from './mixins/workOrderLogic.js'
  76. import basicInfo from './mixins/basicInfo.js'
  77. import dispatchInfo from './mixins/dispatchInfo.js'
  78. import otherInfo from './mixins/otherInfo.js'
  79. import productColumns from './mixins/productColumns.js'
  80. import serviceInfo from './mixins/serviceInfo.js'
  81. import pandanxinxi from './mixins/pandanxinxi.js'
  82. import commitSave from './buttons/commitSave.vue'
  83. import commitTempSave from './buttons/commitTempSave.vue'
  84. import voidView from './buttons/void.vue'
  85. import processFeedback from './buttons/processFeedback.vue'
  86. import closeButton from './buttons/closeButton.vue'
  87. import copyInfo from './buttons/copyInfo.vue'
  88. import closeOrder from './buttons/closeOrder.vue'
  89. import activate from './buttons/activate.vue'
  90. import rejectOrder from './buttons/rejectOrder.vue'
  91. export default {
  92. components: {
  93. activate,
  94. closeOrder,
  95. commitSave,
  96. commitTempSave,
  97. voidView,
  98. processFeedback,
  99. closeButton,
  100. copyInfo,
  101. rejectOrder,
  102. },
  103. mixins: [
  104. workOrderSelectData,
  105. workOrderLogic,
  106. basicInfo,
  107. dispatchInfo,
  108. otherInfo,
  109. productColumns,
  110. serviceInfo,
  111. pandanxinxi,
  112. ],
  113. methods: {
  114. upoptions() {
  115. },
  116. allVerify(cb) {
  117. this.$refs.formRef.validate((valid, invalidFields, errLabels) => {
  118. if (valid) {
  119. cb && cb()
  120. }
  121. })
  122. },
  123. appointVerify(arr, cb) {
  124. this.$refs.formRef.validateField_fx(arr, (valid, invalidFields, errLabels) => {
  125. if (valid) {
  126. cb && cb()
  127. }
  128. }
  129. )
  130. }
  131. }
  132. }
  133. </script>
  134. <style lang="scss" scoped>
  135. .neibuview {
  136. box-sizing: border-box;
  137. padding-left: 16px;
  138. ::v-deep .zj-page-fill-scroll {
  139. box-sizing: border-box;
  140. padding-right: 16px;
  141. &>div:nth-child(1) {
  142. margin-top: 20px;
  143. }
  144. }
  145. }
  146. .pgxxTable {
  147. position: absolute;
  148. top: 0;
  149. bottom: 0;
  150. left: 0;
  151. right: 0;
  152. }
  153. .withinLine {
  154. display: inline-block;
  155. ::v-deep .el-button {
  156. margin-left: 0;
  157. margin-right: 10px;
  158. margin-bottom: 10px;
  159. }
  160. }
  161. </style>