index.vue 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. <template>
  2. <zj-page-container v-if="orderInfo">
  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 v-if="id" title="派工信息" label-width="90px" :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 :columns="logColumns" :table-data="logList"
  13. :table-attributes="{ height: '100%', border: true }" />
  14. </div>
  15. </div>
  16. </zj-form-module>
  17. <!-- 基本信息 -->
  18. <zj-form-module title="基本信息" :form-data="orderInfo" :form-items="basicInfo" />
  19. <!-- 服务信息 -->
  20. <zj-form-module title="服务信息" label-width="110px" :form-data="orderInfo" :form-items="serviceInfo" />
  21. <!-- 产品信息 -->
  22. <zj-form-module title="产品信息" :form-data="orderInfo" :form-items="workOrderType == 1 ? product_wb : product" />
  23. <!-- 其它信息 -->
  24. <zj-form-module title="其它信息" :form-data="orderInfo" :form-items="otherInfo" />
  25. <!-- 派单信息 -->
  26. <zj-form-module title="派单信息" label-width="100px" :form-data="orderInfo" :form-items="pandanxinxi" />
  27. </zj-form-container>
  28. </zj-page-fill>
  29. <!-- 操作按钮 -->
  30. <div>
  31. <div style="box-sizing: border-box;padding: 10px 10px 0;" v-if="id">
  32. <!-- 关闭 -->
  33. <close-button />
  34. <!-- 1,保存 -->
  35. <commitSave v-if="~btnRestrict.indexOf(1)" :orderInfo="orderInfo" :orderType="orderType" />
  36. <!-- 2,过程反馈 -->
  37. <processFeedback v-if="~btnRestrict.indexOf(2)" resultCodeName="过程反馈" :orderInfo="orderInfo"
  38. :orderType="orderType" />
  39. <!-- 3,设为异常 -->
  40. <abnormal v-if="~btnRestrict.indexOf(3)" :orderInfo="orderInfo" :orderType="orderType" />
  41. <!-- 4,加急 -->
  42. <urgent v-if="~btnRestrict.indexOf(4)" :orderInfo="orderInfo" :orderType="orderType" />
  43. <!-- 5,不加急 -->
  44. <unurgent v-if="~btnRestrict.indexOf(5)" :orderInfo="orderInfo" :orderType="orderType" />
  45. <!-- 6,取消工单 -->
  46. <cancelOrder v-if="~btnRestrict.indexOf(6)" :orderInfo="orderInfo" :orderType="orderType" />
  47. <!-- 7,回访 -->
  48. <processFeedback v-if="~btnRestrict.indexOf(7)" resultCodeName="回访" resultCode="回访" :orderInfo="orderInfo"
  49. :orderType="orderType" />
  50. <!-- 8,新建工单 -->
  51. </div>
  52. <div style="box-sizing: border-box;padding: 10px 10px 0;" v-else>
  53. <!-- 关闭 -->
  54. <close-button />
  55. <!-- 1,下派服务单 -->
  56. <commitSave :orderInfo="orderInfo" :orderType="orderType" />
  57. </div>
  58. </div>
  59. </zj-page-container>
  60. </template>
  61. <script>
  62. import workOrderLogic from './mixins/workOrderLogic.js'
  63. import basicInfo from './mixins/basicInfo.js'
  64. import dispatchInfo from './mixins/dispatchInfo.js'
  65. import otherInfo from './mixins/otherInfo.js'
  66. import productColumns from './mixins/productColumns.js'
  67. import wb_productColumns from './mixins/wb_productColumns.js'
  68. import serviceInfo from './mixins/serviceInfo.js'
  69. import pandanxinxi from './mixins/pandanxinxi.js'
  70. import copyInfo from './buttons/copyInfo.vue'
  71. import closeButton from './buttons/closeButton.vue'
  72. import commitSave from './buttons/commitSave.vue'
  73. import urgent from './buttons/urgent.vue'
  74. import unurgent from './buttons/unurgent.vue'
  75. import abnormal from './buttons/abnormal.vue'
  76. import processFeedback from './buttons/processFeedback.vue'
  77. import cancelOrder from './buttons/cancelOrder.vue'
  78. export default {
  79. components: {
  80. copyInfo,
  81. closeButton,
  82. commitSave,
  83. urgent,
  84. unurgent,
  85. abnormal,
  86. processFeedback,
  87. cancelOrder
  88. },
  89. mixins: [
  90. workOrderLogic,
  91. basicInfo,
  92. dispatchInfo,
  93. otherInfo,
  94. productColumns,
  95. wb_productColumns,
  96. serviceInfo,
  97. pandanxinxi,
  98. ],
  99. methods: {
  100. allVerify(cb) {
  101. this.$refs.formRef.validate((valid, invalidFields, errLabels) => {
  102. cb && cb(valid, invalidFields, errLabels)
  103. })
  104. },
  105. appointVerify(arr, cb) {
  106. this.$refs.formRef.validateField(arr, (valid, invalidFields, errLabels) => {
  107. cb && cb(valid, invalidFields, errLabels)
  108. })
  109. }
  110. }
  111. }
  112. </script>
  113. <style lang="scss" scoped>
  114. .neibuview {
  115. box-sizing: border-box;
  116. padding-left: 16px;
  117. ::v-deep &>.zj-page-fill-scroll {
  118. box-sizing: border-box;
  119. padding-right: 16px;
  120. &>div:nth-child(1) {
  121. margin-top: 20px;
  122. }
  123. }
  124. }
  125. .pgxxTable {
  126. position: absolute;
  127. top: 0;
  128. bottom: 0;
  129. left: 0;
  130. right: 0;
  131. }
  132. .withinLine {
  133. display: inline-block;
  134. ::v-deep .el-button {
  135. margin-left: 0;
  136. margin-right: 10px;
  137. margin-bottom: 10px;
  138. }
  139. }
  140. .redbordererr {
  141. ::v-deep .el-form-item {
  142. margin: 0 !important;
  143. overflow: hidden;
  144. }
  145. }
  146. </style>