detailsShipDetDrawer.vue 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225
  1. <template>
  2. <!-- 详情 发运明细 -->
  3. <div id="detailsShipDetDrawer">
  4. <a-drawer title="详情" width="89%" placement="right" :closable="true" :visible="visible" @close="onClose">
  5. <!-- 主表信息 -->
  6. <a-card :bordered="true">
  7. <div class="table-page-search-wrapper">
  8. <a-form-model layout="inline" ref="form">
  9. <a-row :gutter="24">
  10. <a-col :md="6" :sm="8">
  11. <a-form-model-item label="单据号" prop="documentNo">
  12. {{ detailsShipDet.documentNo }}
  13. </a-form-model-item>
  14. </a-col>
  15. <a-col :md="6" :sm="8">
  16. <a-form-model-item label="单据日期" prop="documentDate">
  17. {{ detailsShipDet.documentDate }}
  18. </a-form-model-item>
  19. </a-col>
  20. <a-col :md="6" :sm="8">
  21. <a-form-model-item label="客户" prop="customer" :title="detailsShipDet.customer">
  22. {{ detailsShipDet.customer | ellipsis}}
  23. </a-form-model-item>
  24. </a-col>
  25. <!-- <a-col :md="6" :sm="8">
  26. <a-form-model-item label="订单类型" prop="orderType">
  27. {{ detailsShipDet.orderType }}
  28. </a-form-model-item>
  29. </a-col>
  30. <! -- U8系统适用 -->
  31. <!-- <a-col :md="12" :sm="12">
  32. <a-form-model-item label="备注" prop="memo">
  33. {{ detailsShipDet.memo }}
  34. </a-form-model-item>
  35. </a-col> -->
  36. </a-row>
  37. </a-form-model>
  38. </div>
  39. </a-card>
  40. <!-- 子表 :model="form" -->
  41. <a-card :bordered="true" style="margin:10px 0">
  42. <a-spin :spinning="confirmLoading">
  43. <a-form-model ref="formRef">
  44. <a-table
  45. bordered
  46. rowKey="id"
  47. size="middle"
  48. :columns="columns"
  49. :data-source="syShippingDetailsItemList"
  50. :loading="loading"
  51. :pagination="ipagination"
  52. :scroll="{x: 1500 ,y:500 }"
  53. @change="handleTableChange"
  54. >
  55. </a-table>
  56. </a-form-model>
  57. </a-spin>
  58. </a-card>
  59. </a-drawer>
  60. </div>
  61. </template>
  62. <script>
  63. import { JeecgListMixin } from '@/mixins/JeecgListMixin'
  64. import JEllipsis from '@/components/jeecg/JEllipsis'
  65. import moment from 'moment'
  66. export default {
  67. name: 'DetailsShipDetDrawer', // 详情 发运明细 抽屉
  68. mixins: [JeecgListMixin],
  69. components: { JEllipsis, moment },
  70. data() {
  71. // let ellipsis = (v, l = 20) => <j-ellipsis value={v} length={l} />
  72. return {
  73. id: '',
  74. detailsShipDet: [], // 主表信息
  75. // 表头
  76. columns: [
  77. {
  78. title: '账套',
  79. dataIndex: 'account',
  80. width: 80,
  81. // fixed: 'left',
  82. className: 'replacecolor',
  83. ellipsis: true,
  84. },
  85. {
  86. title: '订单号',
  87. dataIndex: 'orderNumber',
  88. width: 160,
  89. // fixed: 'left',
  90. className: 'replacecolor',
  91. ellipsis: true,
  92. },
  93. {
  94. title: '款号',
  95. dataIndex: 'itemNumber',
  96. // fixed: 'left',
  97. width: 90,
  98. className: 'replacecolor',
  99. ellipsis: true,
  100. },
  101. {
  102. title: '小po',
  103. dataIndex: 'smallPo',
  104. width: 100,
  105. className: 'replacecolor',
  106. ellipsis: true,
  107. },
  108. {
  109. title: 'Pack Id',
  110. dataIndex: 'packId',
  111. width: 100,
  112. className: 'replacecolor',
  113. ellipsis: true,
  114. },
  115. {
  116. title: '分销点',
  117. dataIndex: 'distributionPoint',
  118. width: 120,
  119. className: 'replacecolor',
  120. ellipsis: true,
  121. },
  122. {
  123. title: '存货编码',
  124. dataIndex: 'inventoryCode',
  125. width: 120,
  126. className: 'replacecolor',
  127. ellipsis: true,
  128. },
  129. {
  130. title: '存货名称',
  131. dataIndex: 'inventoryName',
  132. width: 160,
  133. className: 'replacecolor',
  134. ellipsis: true,
  135. },
  136. {
  137. title: '颜色',
  138. dataIndex: 'colour',
  139. width: 100,
  140. className: 'replacecolor',
  141. ellipsis: true,
  142. },
  143. {
  144. title: '尺码',
  145. dataIndex: 'size',
  146. width: 100,
  147. className: 'replacecolor',
  148. ellipsis: true,
  149. },
  150. {
  151. title: '配码规格',
  152. dataIndex: 'codingRules',
  153. width: 120,
  154. className: 'replacecolor',
  155. ellipsis: true,
  156. },
  157. {
  158. title: '订单数量',
  159. dataIndex: 'orderQuantity',
  160. width: 80,
  161. className: 'replacecolor',
  162. ellipsis: true,
  163. },
  164. {
  165. title: '发货数量',
  166. dataIndex: 'shipmentQuantity',
  167. scopedSlots: { customRender: 'shipmentQuantity' },
  168. width: 80,
  169. ellipsis: true,
  170. },
  171. ],
  172. syShippingDetailsItemList: [], // 子表信息
  173. visible: false,
  174. confirmLoading: false,
  175. dateFormat: 'YYYY-MM-DD'
  176. }
  177. },
  178. created() {},
  179. methods: {
  180. onClose() {
  181. this.$emit('close')
  182. this.visible = false
  183. }
  184. }
  185. }
  186. </script>
  187. <style lang="less" scoped>
  188. @import '~@assets/less/common.less';
  189. /deep/ .ant-table-thead > tr > th {
  190. text-align: center;
  191. // font-weight: 700;
  192. }
  193. /deep/ .ant-table-tbody {
  194. text-align: center;
  195. }
  196. // /deep/ th.replacecolor {
  197. // background-color: #ccc;
  198. // }
  199. // 抽屉里的card样式
  200. /deep/ .ant-drawer-content {
  201. background-color: #f0f2f5;
  202. }
  203. /deep/ .ant-drawer-body {
  204. padding: 10px;
  205. }
  206. // 回显label文字
  207. /deep/.ant-form-item-label > label {
  208. font-weight: 700;
  209. }
  210. </style>