index.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556
  1. <template>
  2. <zj-page-container>
  3. <zj-page-fill>
  4. <zj-tab-page ref="tabPage" :defaultActives="[{ key: 'list', label: $route.meta.title + '-列表', essential: true }]">
  5. <template slot-scope="{activeKey, data}">
  6. <div :style="{height:activeKey == 'list'?'100%':'0px'}" style="width:100%; height:100%; overflow: hidden;">
  7. <div style="width:100%; height:100%;box-sizing: border-box; padding:10px;">
  8. <zj-page-container>
  9. <div class="screen-container">
  10. <el-form ref="screenForm" :model="screenForm" label-width="70px" size="small" label-position="left">
  11. <el-row :gutter="20">
  12. <el-col :xs="24" :sm="12" :lg="6">
  13. <el-form-item label="订单号" prop="orderId">
  14. <el-input v-model="screenForm.orderId" placeholder="请输入订单号"></el-input>
  15. </el-form-item>
  16. </el-col>
  17. <el-col :xs="24" :sm="12" :lg="6">
  18. <el-form-item label="商品名称" prop="esGoodsName">
  19. <el-input v-model="screenForm.esGoodsName" placeholder="请输入商品名称"></el-input>
  20. </el-form-item>
  21. </el-col>
  22. <el-col :xs="24" :sm="12" :lg="6">
  23. <el-form-item label="会员昵称" prop="userName">
  24. <el-input v-model="screenForm.userName" placeholder="请输入会员昵称"></el-input>
  25. </el-form-item>
  26. </el-col>
  27. <el-col :xs="24" :sm="12" :lg="6">
  28. <el-form-item label="手机号" prop="userMobile">
  29. <el-input v-model="screenForm.userMobile" placeholder="请输入手机号"></el-input>
  30. </el-form-item>
  31. </el-col>
  32. <el-col :xs="24" :sm="12" :lg="6">
  33. <el-form-item label="创建时间" prop="createDate" style="height: 33px;">
  34. <el-date-picker v-model="screenForm.createDate" type="datetimerange"
  35. value-format="yyyy-MM-dd HH:mm:ss" range-separator="至" start-placeholder="开始日期"
  36. end-placeholder="结束日期">
  37. </el-date-picker>
  38. </el-form-item>
  39. </el-col>
  40. <el-col :xs="24" :sm="12" :lg="6">
  41. <el-form-item label="支付时间" prop="payDate" style="height: 33px;">
  42. <el-date-picker v-model="screenForm.payDate" type="datetimerange" value-format="yyyy-MM-dd HH:mm:ss"
  43. range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
  44. </el-date-picker>
  45. </el-form-item>
  46. </el-col>
  47. <el-col :xs="24" :sm="12" :lg="6" class="tr">
  48. <el-form-item label="" label-width="0px">
  49. <div style="text-align: left;">
  50. <el-button size="small" type="primary" @click="submitScreenForm">搜索</el-button>
  51. <el-button size="small" @click="resetScreenForm">清空</el-button>
  52. </div>
  53. </el-form-item>
  54. </el-col>
  55. </el-row>
  56. </el-form>
  57. </div>
  58. <div class="tabs-container order-tabs-container clearfix" style="margin: 10px 0!important;">
  59. <div class="fl">
  60. <el-tabs v-model="tabCurrent" type="card" @tab-click="changeTabs" class="fl" size="small" style="margin-right: 10px">
  61. <el-tab-pane label="全部" name="ALL"></el-tab-pane>
  62. <el-tab-pane label="待付款" name="SAVE"></el-tab-pane>
  63. <el-tab-pane label="待确认" name="WAIT"></el-tab-pane>
  64. <el-tab-pane label="待发货" name="PAID"></el-tab-pane>
  65. <el-tab-pane label="已发货" name="SEND"></el-tab-pane>
  66. <el-tab-pane label="已完成" name="OVER"></el-tab-pane>
  67. <el-tab-pane label="已退货/取消" name="CANCEL"></el-tab-pane>
  68. <el-tab-pane label="已超时" name="TIME_OUT"></el-tab-pane>
  69. </el-tabs>
  70. <el-button class="fl" type="primary" size="small" @click="add(1)">新增</el-button>
  71. </div>
  72. <div class="fr">
  73. <el-button size="small" type="primary" @click="handleExport">导出</el-button>
  74. </div>
  75. </div>
  76. <zj-page-fill>
  77. <div class="order-main-container">
  78. <div class="table-top">
  79. <el-row style="width:100%">
  80. <el-col :span="3">
  81. <span class="item product">商品信息</span>
  82. </el-col>
  83. <el-col :span="3" style="text-align: right"><span class="item">单价(元)/数量</span></el-col>
  84. <el-col :span="4" style="text-align: center"><span class="item">买家信息</span></el-col>
  85. <el-col :span="4" style="text-align: center"><span class="item">收货信息</span></el-col>
  86. <el-col :span="4" style="text-align: center"><span class="item">实付金额</span></el-col>
  87. <el-col :span="3" style="text-align: center"><span class="item">订单状态</span></el-col>
  88. <el-col :span="3" style="text-align: center"><span class="item">操作</span></el-col>
  89. </el-row>
  90. </div>
  91. <div class="order-item" v-for="order in dataList" :key="order.orderId">
  92. <div class="order-top">
  93. <span><b>订单号</b>:{{ order.esOrderId }}</span>
  94. <span><b>下单时间</b>:{{ order.createTime }}</span>
  95. <el-tag v-if="~[2,'2'].indexOf(order.saleType)">线下销售</el-tag>
  96. <el-tag v-if="~[1,'1'].indexOf(order.saleType)">线上销售</el-tag>
  97. <el-tag v-if="~['TRANSFER','WECHAT'].indexOf(order.payType)">在线支付</el-tag>
  98. <el-tag v-if="~['CASH'].indexOf(order.payType)">到店支付</el-tag>
  99. <el-tag v-if="~[0].indexOf(order.totalAmount)">面议</el-tag>
  100. <div class="fr"></div>
  101. </div>
  102. <div class="order-content">
  103. <el-row style="width:100%;">
  104. <el-col :span="6" style="height: 100%;">
  105. <div class="col-item-pro">
  106. <div class="pro-item">
  107. <div class="left">
  108. <div class="image">
  109. <img :src="order.goodsUrl" style="height:80px;width: 80px;">
  110. </div>
  111. <div class="main">
  112. <span>{{ order.esGoodsName }}</span>
  113. </div>
  114. </div>
  115. <div class="right">
  116. <span>¥{{ order.goodsPrice }}</span>
  117. <span>x{{ order.num }}</span>
  118. </div>
  119. </div>
  120. </div>
  121. </el-col>
  122. <el-col :span="4" style="height: 100%;">
  123. <div class="col-item">
  124. <div>{{ order.wechatUserName }}</div>
  125. <div>{{ order.wechatUserMobile }}</div>
  126. </div>
  127. </el-col>
  128. <el-col :span="4" style="height: 100%;">
  129. <div class="col-item">
  130. <div>{{ order.userName }}/{{ order.userMobile }}</div>
  131. <div class="ellipsis-2">{{ order.province + order.city + order.area + order.street + order.receAddress }}</div>
  132. </div>
  133. </el-col>
  134. <el-col :span="4" style="height: 100%;">
  135. <div class="col-item">
  136. <div class="totalprice">¥{{ order.totalAmount }}</div>
  137. </div>
  138. </el-col>
  139. <el-col :span="3" style="height: 100%;">
  140. <div class="col-item">
  141. <div style="display: flex; align-items: center;">
  142. <span style="margin-left: 4px">{{ ({SAVE: "待支付", WAIT: "待确认", PAID: "待发货", SEND: "卖家发货", OVER: "已完成", TIME_OUT: "超时", CANCEL: "取消", WAIT_REFUND: "售后中", REFUND: "已退"})[order.status] }}</span>
  143. </div>
  144. </div>
  145. </el-col>
  146. <el-col :span="3" style="height: 100%;">
  147. <div class="col-item">
  148. <div class="operate">
  149. <el-popconfirm v-if="~['WAIT'].indexOf(order.status)" title="确认订单吗?" @confirm="quedingesOrderPayOk(order)">
  150. <el-button slot="reference" type="text" size="small">确认订单</el-button>
  151. </el-popconfirm>
  152. <el-popconfirm v-if="~['SAVE','WAIT'].indexOf(order.status)" title="确认取消订单吗?" @confirm="quedingesOrderCancel(order)">
  153. <el-button slot="reference" type="text" size="small">取消订单</el-button>
  154. </el-popconfirm>
  155. <el-button v-if="~['SEND','OVER'].indexOf(order.status)" @click="viewMaterialFlow(order)" type="text" size="small">查看物流</el-button>
  156. <el-button v-if="~['SAVE', 'WAIT', 'PAID', 'SEND', 'OVER', 'CANCEL', 'TIME_OUT'].indexOf(order.status)" @click="viewDetails(order, 0)" type="text" size="small">查看详情</el-button>
  157. <el-button v-if="~['SAVE'].indexOf(order.status)" @click="viewDetails(order, 1)" type="text" size="small">确认收款</el-button>
  158. <el-button v-if="~['SEND','OVER'].indexOf(order.status)" @click="viewDetails(order, 2)" type="text" size="small">发起退货</el-button>
  159. <el-button v-if="~['PAID'].indexOf(order.status)" type="text" @click="gofahuo(order)" size="small">发货</el-button>
  160. <el-button v-if="~['PAID','SEND'].indexOf(order.status)" type="text" size="small" @click="toPrint(order)">打印</el-button>
  161. </div>
  162. </div>
  163. </el-col>
  164. </el-row>
  165. </div>
  166. </div>
  167. <div class="no-data" v-if="dataList.length <= 0">暂无订单</div>
  168. </div>
  169. </zj-page-fill>
  170. <div class="pagination clearfix" style="margin-top:10px;">
  171. <div class="fr">
  172. <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
  173. :current-page="currentPage" :page-sizes="[10, 20, 30, 50]" :page-size="10"
  174. layout="total, sizes, prev, pager, next, jumper" :total="listTotal">
  175. </el-pagination>
  176. </div>
  177. </div>
  178. </zj-page-container>
  179. </div>
  180. </div>
  181. <!-- 新增 -->
  182. <div v-if="activeKey == 'add'" style="width:100%;height:100%;">
  183. <add :detailsId="detailsId" :detailsType="detailsType" @removeTab="()=>{
  184. getList()
  185. data.removeTab()
  186. }"/>
  187. </div>
  188. <!-- 查看详情 / 确认收款 / 退货-->
  189. <div v-if="~activeKey.indexOf('details_')" style="width:100%;height:100%;">
  190. <detailsV :detailsId="detailsId" :detailsType="detailsType" @viewMaterialFlow="viewMaterialFlow" @removeTab="()=>{
  191. getList()
  192. data.removeTab()
  193. }"/>
  194. </div>
  195. <!-- 查看物流 -->
  196. <div v-if="activeKey == 'materialFlow'" style="width:100%;height:100%;">
  197. <materialFlow :detailsId="detailsId"/>
  198. </div>
  199. <!-- 发货 -->
  200. <div v-if="activeKey == 'fahuo'" style="width:100%;height:100%;">
  201. <deliverGoods :detailsId="detailsId" @removeTab="()=>{
  202. getList()
  203. data.removeTab()
  204. }"/>
  205. </div>
  206. </template>
  207. </zj-tab-page>
  208. </zj-page-fill>
  209. <print-preview ref="preView" @initPrint="handleInitPrint" @refreshList="handleRefreshList" />
  210. </zj-page-container>
  211. </template>
  212. <script>
  213. import { esOrderList, esOrderListExcel, esOrderPayOk, esOrderCancel, esOrderDetail } from "@/api/orderManagement";
  214. import add from "./add.vue"
  215. import detailsV from "./details.vue"
  216. import materialFlow from "./materialFlow.vue"
  217. import deliverGoods from "./deliverGoods.vue"
  218. import '@/styles/order-list.scss'
  219. import { downloadFiles } from '@/utils/util'
  220. import { disAutoConnect, hiprint } from 'vue-plugin-hiprint'
  221. import printPreview from '../components/preview.vue'
  222. export default {
  223. components: {add, detailsV, materialFlow, deliverGoods, printPreview},
  224. data() {
  225. return {
  226. pageType:this?.$route?.params?.pageType,
  227. pageCode:this?.$route?.params?.pageCode,
  228. pagePam:this?.$route?.params?.pagePam,
  229. screenForm: { // 筛选表单数据
  230. orderId: '', // 订单号
  231. esGoodsName: '', // 商品名称
  232. userName: '', // 会员昵称
  233. userMobile: '', // 手机号
  234. websitId: '', // 网点名称
  235. status: '', // 状态
  236. createDate: '', // 创建时间
  237. payDate: '', // 支付时间
  238. exchangeCode: '', // 兑换码
  239. evaluateStatus: '', // 评价状态
  240. sendStatus: '', // 派单异常
  241. workerOrderNo: '', // 信息编号
  242. },
  243. tabCurrent: 'ALL',
  244. currentPage: 1, // 当前页码
  245. pageSize: 10, // 每页数量
  246. listTotal: 0, // 列表总数
  247. dataList: [],
  248. detailsId: "",
  249. detailsType: "",
  250. }
  251. },
  252. created() {
  253. this.getList();
  254. if(this.pageType==="detail" && this.pageCode){
  255. this.$nextTick(()=>{
  256. this.viewDetails({esOrderId:this.pageCode},0)
  257. })
  258. }
  259. if(this.pageType==="materialFlow" && this.pageCode){
  260. this.$nextTick(()=>{
  261. this.viewMaterialFlow({esOrderId:this.pageCode})
  262. })
  263. }
  264. if(this.pageType==="add" && this.pageCode){
  265. this.$nextTick(()=>{
  266. this.add(0)
  267. })
  268. }
  269. },
  270. methods: {
  271. quedingesOrderPayOk(row){
  272. esOrderPayOk({
  273. esOrderId:row.esOrderId
  274. }).then(res=>{
  275. this.$message({ type: 'success', message: `确定成功!` })
  276. this.getList();
  277. })
  278. },
  279. quedingesOrderCancel(row){
  280. esOrderCancel({
  281. esOrderId:row.esOrderId
  282. }).then(res=>{
  283. this.$message({ type: 'success', message: `取消成功!` })
  284. this.getList();
  285. })
  286. },
  287. add(type){
  288. this.$refs.tabPage.addTab({
  289. // 对应显示的模块
  290. activeKey: "add",
  291. // 唯一标识
  292. key: "add",
  293. // 页签名称
  294. label: "新增订单",
  295. // 打开时事件
  296. triggerEvent: () => {
  297. this.detailsType = type
  298. },
  299. // 关闭时事件
  300. closeEvent: () => {
  301. }
  302. })
  303. },
  304. viewDetails(row, type){
  305. this.$refs.tabPage.addTab({
  306. // 对应显示的模块
  307. activeKey: "details_"+type,
  308. // 唯一标识
  309. key: "details_"+type,
  310. // 页签名称
  311. label: ["订单详情", "确认收款", "退货退款"][type],
  312. // 打开时事件
  313. triggerEvent: () => {
  314. this.detailsId = row.esOrderId
  315. this.detailsType = type
  316. },
  317. // 关闭时事件
  318. closeEvent: () => {
  319. }
  320. })
  321. },
  322. viewMaterialFlow(row){
  323. this.$refs.tabPage.addTab({
  324. // 对应显示的模块
  325. activeKey: "materialFlow",
  326. // 唯一标识
  327. key: "materialFlow",
  328. // 页签名称
  329. label: "查看物流",
  330. // 打开时事件
  331. triggerEvent: () => {
  332. this.detailsId = row.esOrderId
  333. },
  334. // 关闭时事件
  335. closeEvent: () => {
  336. }
  337. })
  338. },
  339. gofahuo (row) {
  340. this.$refs.tabPage.addTab({
  341. // 对应显示的模块
  342. activeKey: "fahuo",
  343. // 唯一标识
  344. key: "fahuo",
  345. // 页签名称
  346. label: "发货",
  347. // 打开时事件
  348. triggerEvent: () => {
  349. this.detailsId = row.esOrderId
  350. },
  351. // 关闭时事件
  352. closeEvent: () => {
  353. }
  354. })
  355. },
  356. changeTabs(tab, event) {
  357. this.screenForm.status = this.tabCurrent === 'ALL' ? '' : tab.$options.propsData.name
  358. this.currentPage = 1;
  359. this.getList();
  360. },
  361. // 获取数据列表
  362. getList() {
  363. let params = {
  364. orderId: this.screenForm.orderId, // 订单号
  365. esGoodsName: this.screenForm.esGoodsName, // 商品名称
  366. userName: this.screenForm.userName, // 会员昵称
  367. userMobile: this.screenForm.userMobile, // 手机号
  368. status: this.screenForm.status, // 状态
  369. startCreateTime: this.screenForm.createDate[0] ? this.screenForm.createDate[0] : null, // 创建时间
  370. endCreateTime: this.screenForm.createDate[1] ? this.screenForm.createDate[1] : null, // 创建时间
  371. startPayTime: this.screenForm.payDate[0] ? this.screenForm.payDate[0] : null, // 支付时间
  372. endPayTime: this.screenForm.payDate[1] ? this.screenForm.payDate[1] : null, // 支付时间
  373. pageNum: this.currentPage,
  374. pageSize: this.pageSize
  375. };
  376. esOrderList(params).then(res => {
  377. res.data.records.forEach(item => {
  378. item.selected = false;
  379. });
  380. this.dataList = res.data.records;
  381. this.listTotal = res.data.total;
  382. })
  383. },
  384. // 更改每页数量
  385. handleSizeChange(val) {
  386. this.pageSize = val;
  387. this.currentPage = 1;
  388. this.getList();
  389. },
  390. // 更改当前页
  391. handleCurrentChange(val) {
  392. this.currentPage = val;
  393. this.getList();
  394. },
  395. // 提交筛选表单
  396. submitScreenForm() {
  397. this.currentPage = 1;
  398. this.getList();
  399. },
  400. // 重置筛选表单
  401. resetScreenForm() {
  402. this.$refs.screenForm.resetFields();
  403. this.currentPage = 1;
  404. this.getList();
  405. },
  406. // 导出
  407. handleExport() {
  408. let params = {
  409. orderId: this.screenForm.orderId, // 订单号
  410. esGoodsName: this.screenForm.esGoodsName, // 商品名称
  411. userName: this.screenForm.userName, // 会员昵称
  412. userMobile: this.screenForm.userMobile, // 手机号
  413. status: this.screenForm.status, // 状态
  414. startCreateTime: this.screenForm.createDate[0] ? this.screenForm.createDate[0] : null, // 创建时间
  415. endCreateTime: this.screenForm.createDate[1] ? this.screenForm.createDate[1] : null, // 创建时间
  416. startPayTime: this.screenForm.payDate[0] ? this.screenForm.payDate[0] : null, // 支付时间
  417. endPayTime: this.screenForm.payDate[1] ? this.screenForm.payDate[1] : null, // 支付时间
  418. pageNum: this.currentPage,
  419. pageSize: this.pageSize
  420. };
  421. downloadFiles('esOrder/listExcel', params);
  422. },
  423. // 点击打印
  424. async toPrint(row) {
  425. const { data } = await esOrderDetail({
  426. esOrderId: row.esOrderId
  427. })
  428. // 初始化模板,否则生成的模板叠加
  429. hiprint.init()
  430. this.hiprintTemplate = new hiprint.PrintTemplate()
  431. // 使用 i-- 提升for效率
  432. this.$startLoading()
  433. try {
  434. let num = data.num
  435. let totalAmount = Number(data.num) * Number(data.goodsPrice)
  436. let html = `
  437. <tr align="center">
  438. <td>${data.esGoodsName || ''}</td>
  439. <td>${data.unit||''}</td>
  440. <td>${data.num}</td>
  441. <td>${data.goodsPrice}</td>
  442. <td>${totalAmount}</td>
  443. <td>${data.remark || ''}</td>
  444. </tr>
  445. `
  446. // 模板基础配置
  447. this.panel = this.hiprintTemplate.addPrintPanel({
  448. height: 140,
  449. width: 241,
  450. fontFamily: '黑体',
  451. fontSize: 13,
  452. paperFooter: 340,
  453. paperHeader: 10,
  454. paperNumberDisabled: true
  455. })
  456. // 获取收款单模板和基础配置
  457. this.panel.addPrintHtml({
  458. options: {
  459. width: 633,
  460. top: 30,
  461. left: 20,
  462. fontFamily: '黑体',
  463. fontSize: 13,
  464. content: this.setTableDom(data, html, totalAmount, num, 1, 0)
  465. }
  466. })
  467. } catch (error) {
  468. this.$endLoading()
  469. return
  470. }
  471. this.$endLoading()
  472. // 预览打印内容
  473. this.$refs.preView.show(this.hiprintTemplate, this.panel)
  474. },
  475. // 打印模板
  476. setTableDom(data, html, totalAmount, num, length, page) {
  477. let now = new Date();
  478. let year = now.getFullYear();
  479. let month = now.getMonth() + 1; // 月份是从 0 开始计数的,所以要加 1
  480. let day = now.getDate();
  481. let hours = now.getHours();
  482. let minutes = now.getMinutes();
  483. let seconds = now.getSeconds();
  484. let nowTime = `${year}-${month < 10 ? '0'+month : month}-${day < 10 ? '0'+day : day} ${hours < 10 ? '0'+hours : hours}:${minutes < 10 ? '0'+minutes : minutes}:${seconds < 10 ? '0'+seconds : seconds}`
  485. let showpPrintCount = `打印日期: ${nowTime}`;
  486. return `
  487. <div style="font-family:'黑体';font-size: 16px;">
  488. <div style="display: flex;justify-content: center;align-items: center;position: relative;">
  489. <h1 style="text-align:center;margin: 10px 0;">${JSON.parse(localStorage.getItem('greemall_user'))?.billTitle || data.companyWechatName}销售单</h1>
  490. <div style="position: absolute;right:0;">共 ${length}页 第 ${page + 1} 页</div>
  491. </div>
  492. <div style="display: flex;justify-content: space-between;">
  493. <div>${showpPrintCount}</div>
  494. <div>单据日期: ${data.createTime}</div>
  495. <div>单据编号: ${data.esOrderId}</div>
  496. </div>
  497. <div style="display: flex;justify-content: space-between;font-size: 16px;margin: 10px 0;">
  498. <div>客户: ${data.userName}</div>
  499. <div>摘要: ${({TRANSFER:"在线支付",WECHAT:"在线支付",CASH:"到店支付"})[data.payType]}</div>
  500. </div>
  501. <div style="display: flex;font-size: 16px;margin-bottom: 10px;">
  502. <div style="flex-shrink: 0;">联系电话: ${data.userMobile}</div>
  503. <div style="margin-left: 50px;">收货地址: ${data.province}${data.city}${data.area}${data.street}${data.receAddress}</div>
  504. </div>
  505. <div >
  506. <table border=".5" cellspacing="0" width="856" style="border-color: rgb(0,0,0);border-collapse: collapse;border-style: none;border: 1px solid rgb(0,0,0);font-weight: normal;text-decoration: none;vertical-align: middle;box-sizing: border-box;word-wrap: break-word;word-break: break-all;">
  507. <tr align="center">
  508. <td>商品名称</td>
  509. <td>单位</td>
  510. <td>数量</td>
  511. <td>单价</td>
  512. <td>金额</td>
  513. <td>备注</td>
  514. </tr>
  515. ${html}
  516. <tr align="center" align="center">
  517. <td>小计: </td>
  518. <td></td>
  519. <td>${num}</td>
  520. <td>${totalAmount}</td>
  521. <td>金额总计: ${totalAmount}</td>
  522. <td></td>
  523. </tr>
  524. </table>
  525. </div>
  526. <div style="display: flex;justify-content: space-between;font-size: 16px;margin: 10px 0;">
  527. <div>制单人: ${data.createBy || ''}</div>
  528. <div>审核人: ${JSON.parse(localStorage.getItem('greemall_user'))?.nickName || ''}</div>
  529. <div>业务员: ${data.saleName || ''}</div>
  530. <div>签收人: </div>
  531. </div>
  532. <div style="display: flex;justify-content: flex-end;">
  533. </div>
  534. <div style="margin:100px 0 0 0">
  535. <div></div>
  536. </div>
  537. </div>
  538. `
  539. },
  540. handleRefreshList() {
  541. this.getList();
  542. },
  543. handleInitPrint() {
  544. this.$nextTick(() => {
  545. this?.initPrint()
  546. })
  547. },
  548. }
  549. }
  550. </script>