3ea38831fea318daad248b9d56244833.json 18 KB

1
  1. {"remainingRequest":"D:\\front\\item\\zyAdmin\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\front\\item\\zyAdmin\\src\\pages\\marketing\\storeIntegralOrder\\components\\tableFrom.vue?vue&type=style&index=0&id=561479d0&lang=scss&scoped=true","dependencies":[{"path":"D:\\front\\item\\zyAdmin\\src\\pages\\marketing\\storeIntegralOrder\\components\\tableFrom.vue","mtime":1761614939038},{"path":"D:\\front\\item\\zyAdmin\\node_modules\\css-loader\\index.js","mtime":1761614929364},{"path":"D:\\front\\item\\zyAdmin\\node_modules\\vue-loader\\lib\\loaders\\stylePostLoader.js","mtime":1761614937403},{"path":"D:\\front\\item\\zyAdmin\\node_modules\\postcss-loader\\src\\index.js","mtime":1761614935133},{"path":"D:\\front\\item\\zyAdmin\\node_modules\\sass-loader\\dist\\cjs.js","mtime":1761614936391},{"path":"D:\\front\\item\\zyAdmin\\node_modules\\cache-loader\\dist\\cjs.js","mtime":1761614927801},{"path":"D:\\front\\item\\zyAdmin\\node_modules\\vue-loader\\lib\\index.js","mtime":1761614937402}],"contextDependencies":[],"result":[{"type":"Buffer","data":"base64:DQoudGFiX2RhdGEgOjp2LWRlZXAgLml2dS1mb3JtLWl0ZW0tY29udGVudCB7DQogIG1hcmdpbi1sZWZ0OiAwICFpbXBvcnRhbnQ7DQp9DQoudGFibGVfYm94IDo6di1kZWVwIC5pdnUtZGl2aWRlci1ob3Jpem9udGFsIHsNCiAgbWFyZ2luLXRvcDogMHB4ICFpbXBvcnRhbnQ7DQp9DQoudGFibGVfYm94IDo6di1kZWVwIC5pdnUtZm9ybS1pdGVtIHsNCiAgbWFyZ2luLWJvdHRvbTogMTVweCAhaW1wb3J0YW50Ow0KfQ0KLnRhYmZvcm0gew0KICBtYXJnaW4tYm90dG9tOiAxMHB4Ow0KfQ0KLlJlZnJlc2ggew0KICBmb250LXNpemU6IDEycHg7DQogIGNvbG9yOiB2YXIoLS1wcmV2LWNvbG9yLXByaW1hcnkpOw0KICBjdXJzb3I6IHBvaW50ZXI7DQp9DQoub3JkZXItd3JhcHBlciB7DQogIG1hcmdpbi10b3A6IDEwcHg7DQogIHBhZGRpbmc6IDEwcHg7DQogIGJvcmRlcjogMXB4IHNvbGlkICNkZGQ7DQogIC50aXRsZSB7DQogICAgZm9udC1zaXplOiAxNnB4Ow0KICB9DQogIC5vcmRlci1ib3ggew0KICAgIG1hcmdpbi10b3A6IDEwcHg7DQogICAgYm9yZGVyOiAxcHggc29saWQgI2RkZDsNCiAgICAuaXRlbSB7DQogICAgICBkaXNwbGF5OiBmbGV4Ow0KICAgICAgYWxpZ24taXRlbXM6IGNlbnRlcjsNCiAgICAgIGJvcmRlci1ib3R0b206IDFweCBzb2xpZCAjZGRkOw0KICAgICAgJjpsYXN0LWNoaWxkIHsNCiAgICAgICAgYm9yZGVyLWJvdHRvbTogMDsNCiAgICAgIH0NCiAgICAgIC5sYWJlbCB7DQogICAgICAgIHdpZHRoOiAxMDBweDsNCiAgICAgICAgcGFkZGluZzogMTBweCAwIDEwcHggMTBweDsNCiAgICAgICAgYm9yZGVyLXJpZ2h0OiAxcHggc29saWQgI2RkZDsNCiAgICAgIH0NCiAgICAgIC5jb24gew0KICAgICAgICBmbGV4OiAxOw0KICAgICAgICBwYWRkaW5nOiAxMHB4IDAgMTBweCAxMHB4Ow0KICAgICAgfQ0KICAgIH0NCiAgfQ0KfQ0KLm1hbnVhbC1tb2RhbCB7DQogIGRpc3BsYXk6IGZsZXg7DQogIGFsaWduLWl0ZW1zOiBjZW50ZXI7DQp9DQouZGYgew0KICBkaXNwbGF5OiBmbGV4Ow0KfQ0K"},{"version":3,"sources":["tableFrom.vue"],"names":[],"mappings":";AAuaA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","file":"tableFrom.vue","sourceRoot":"src/pages/marketing/storeIntegralOrder/components","sourcesContent":["<template>\r\n <div class=\"table_box\">\r\n <el-form\r\n ref=\"orderData\"\r\n :model=\"orderData\"\r\n :label-width=\"labelWidth\"\r\n :label-position=\"labelPosition\"\r\n @submit.native.prevent\r\n inline\r\n >\r\n <el-form-item label=\"订单状态:\">\r\n <el-select\r\n placeholder=\"请选择\"\r\n clearable\r\n v-model=\"orderData.is_show\"\r\n @change=\"selectChange2\"\r\n class=\"form_content_width\"\r\n >\r\n <el-option value=\"\" label=\"全部\"></el-option>\r\n <el-option value=\"1\" label=\"未发货\"></el-option>\r\n <el-option value=\"2\" label=\"待收货\"></el-option>\r\n <el-option value=\"3\" label=\"交易完成\"></el-option>\r\n </el-select>\r\n </el-form-item>\r\n <el-form-item label=\"创建时间:\">\r\n <el-date-picker\r\n clearable\r\n v-model=\"timeVal\"\r\n type=\"daterange\"\r\n :editable=\"false\"\r\n @change=\"onchangeTime\"\r\n format=\"yyyy/MM/dd\"\r\n value-format=\"yyyy/MM/dd\"\r\n start-placeholder=\"开始日期\"\r\n end-placeholder=\"结束日期\"\r\n :picker-options=\"pickerOptions\"\r\n style=\"width: 250px\"\r\n ></el-date-picker>\r\n </el-form-item>\r\n <el-form-item label=\"订单搜索:\" prop=\"real_name\" label-for=\"real_name\">\r\n <el-input clearable v-model=\"orderData.real_name\" placeholder=\"请输入\" class=\"form_content_width\">\r\n <el-select v-model=\"orderData.field_key\" slot=\"prepend\" style=\"width: 100px\">\r\n <el-option value=\"all\" label=\"全部\"></el-option>\r\n <el-option value=\"order_id\" label=\"订单号\"></el-option>\r\n <el-option value=\"uid\" label=\"UID\"></el-option>\r\n <el-option value=\"real_name\" label=\"用户姓名\"></el-option>\r\n <el-option value=\"user_phone\" label=\"用户电话\"></el-option>\r\n <el-option value=\"store_name\" label=\"商品名称(模糊)\"></el-option>\r\n </el-select>\r\n </el-input>\r\n </el-form-item>\r\n <el-form-item>\r\n <el-button type=\"primary\" v-db-click @click=\"orderSearch\">查询</el-button>\r\n </el-form-item>\r\n </el-form>\r\n </div>\r\n</template>\r\n\r\n<script>\r\nimport { mapState, mapMutations } from 'vuex';\r\nimport { integralGetOrdes } from '@/api/marketing';\r\n\r\nimport {\r\n putWrite,\r\n storeOrderApi,\r\n handBatchDelivery,\r\n otherBatchDelivery,\r\n exportExpressList,\r\n storeIntegralOrder,\r\n} from '@/api/order';\r\nimport autoSend from '../handle/autoSend';\r\nimport queueList from '../handle/queueList';\r\nimport Setting from '@/setting';\r\nimport QueueList from '../handle/queueList.vue';\r\nexport default {\r\n name: 'table_from',\r\n components: {\r\n autoSend,\r\n queueList,\r\n },\r\n props: ['formSelection', 'autoDisabled', 'isAll'],\r\n data() {\r\n return {\r\n currentTab: '',\r\n // 搜索条件\r\n orderData: {\r\n status: '',\r\n data: '',\r\n real_name: '',\r\n field_key: 'all',\r\n pay_type: '',\r\n },\r\n modalTitleSs: '',\r\n statusType: '',\r\n time: '',\r\n value2: [],\r\n isDelIdList: [],\r\n modals2: false,\r\n timeVal: [],\r\n payList: [\r\n { label: '全部', val: '' },\r\n { label: '微信支付', val: '1' },\r\n { label: '支付宝支付', val: '4' },\r\n { label: '余额支付', val: '2' },\r\n { label: '线下支付', val: '3' },\r\n ],\r\n manualModal: false,\r\n uploadAction: `${Setting.apiBaseURL}/file/upload/1`,\r\n uploadHeaders: {},\r\n file: '',\r\n autoModal: false,\r\n isShow: false,\r\n recordModal: false,\r\n sendOutValue: '',\r\n exportList: [\r\n {\r\n name: '1',\r\n label: '导出发货单',\r\n },\r\n {\r\n name: '0',\r\n label: '导出订单',\r\n },\r\n ],\r\n exportListOn: 0,\r\n fileList: [],\r\n orderChartType: {},\r\n pickerOptions: this.$timeOptions,\r\n };\r\n },\r\n computed: {\r\n ...mapState('media', ['isMobile']),\r\n ...mapState('integralOrder', ['isDels', 'delIdList']),\r\n labelWidth() {\r\n return this.isMobile ? undefined : '80px';\r\n },\r\n labelPosition() {\r\n return this.isMobile ? 'top' : 'right';\r\n },\r\n today() {\r\n const end = new Date();\r\n const start = new Date();\r\n var datetimeStart = start.getFullYear() + '/' + (start.getMonth() + 1) + '/' + start.getDate();\r\n var datetimeEnd = end.getFullYear() + '/' + (end.getMonth() + 1) + '/' + end.getDate();\r\n return [datetimeStart, datetimeEnd];\r\n },\r\n },\r\n watch: {\r\n $route() {\r\n if (this.$route.fullPath === this.$routeProStr + '/order/list?status=1') {\r\n this.getPath();\r\n }\r\n },\r\n },\r\n created() {\r\n // this.timeVal = this.today;\r\n // this.orderData.data = this.timeVal ? this.timeVal.join('-') : '';\r\n if (this.$route.fullPath === this.$routeProStr + '/order/list?status=1') {\r\n this.getPath();\r\n }\r\n // this.getToken();\r\n this.$parent.$emit('add');\r\n let searchData = {\r\n status: this.orderData.status,\r\n product_id: this.$route.query.product_id || '',\r\n };\r\n this.integralGetOrdes(searchData);\r\n },\r\n methods: {\r\n ...mapMutations('integralOrder', ['getOrderStatus', 'getOrderType', 'getOrderTime', 'getOrderNum', 'getfieldKey']),\r\n integralGetOrdes(searchData) {\r\n integralGetOrdes(searchData)\r\n .then((res) => {\r\n this.$set(this, 'orderChartType', res.data);\r\n })\r\n .catch((err) => {});\r\n },\r\n getPath() {\r\n this.orderData.status = this.$route.query.status.toString();\r\n this.getOrderStatus(this.orderData.status);\r\n this.$emit('getList', 1);\r\n this.$emit('order-data', this.orderData);\r\n },\r\n // 导出\r\n // exports(value) {\r\n // this.exportListOn = this.exportList.findIndex(\r\n // (item) => item.name === value\r\n // );\r\n // let formValidate = this.orderData;\r\n // let data = {\r\n // status: formValidate.status,\r\n // data: formValidate.data,\r\n // real_name: formValidate.real_name,\r\n // type: value,\r\n // };\r\n // storeOrderApi(data)\r\n // .then((res) => {\r\n // location.href = res.data[0];\r\n // })\r\n // .catch((res) => {\r\n // this.$message.error(res.msg);\r\n // });\r\n // },\r\n // 数据导出;\r\n async exports() {\r\n let [th, filekey, data, fileName] = [[], [], [], ''];\r\n let excelData = JSON.parse(JSON.stringify(this.orderData));\r\n excelData.page = 1;\r\n excelData.product_id = this.$route.query.product_id || '';\r\n for (let i = 0; i < excelData.page + 1; i++) {\r\n let lebData = await this.getExcelData(excelData);\r\n if (!fileName) fileName = lebData.filename;\r\n if (!filekey.length) {\r\n filekey = lebData.filekey;\r\n }\r\n if (!th.length) th = lebData.header;\r\n if (lebData.export.length) {\r\n data = data.concat(lebData.export);\r\n excelData.page++;\r\n }\r\n }\r\n exportExcel(th, filekey, fileName, data);\r\n },\r\n getExcelData(excelData) {\r\n return new Promise((resolve, reject) => {\r\n storeIntegralOrder(excelData).then((res) => {\r\n return resolve(res.data);\r\n });\r\n });\r\n },\r\n // 具体日期\r\n onchangeTime(e) {\r\n this.timeVal = e || [];\r\n this.orderData.data = this.timeVal[0] ? (this.timeVal ? this.timeVal.join('-') : '') : '';\r\n this.$store.dispatch('integralOrder/getOrderTabs', {\r\n data: this.orderData.data,\r\n });\r\n this.getOrderTime(this.orderData.data);\r\n this.$emit('getList', 1);\r\n this.$emit('order-data', this.orderData);\r\n },\r\n // 选择时间\r\n selectChange(tab) {\r\n this.$store.dispatch('integralOrder/getOrderTabs', { data: tab });\r\n this.orderData.data = tab;\r\n this.getOrderTime(this.orderData.data);\r\n this.timeVal = [];\r\n this.$emit('getList');\r\n this.$emit('order-data', this.orderData);\r\n },\r\n // 订单选择状态\r\n selectChange2(tab) {\r\n this.getOrderStatus(tab);\r\n this.$emit('getList', 1);\r\n },\r\n userSearchs(type) {\r\n this.getOrderType(type);\r\n this.$emit('getList', 1);\r\n },\r\n // 时间状态\r\n timeChange(time) {\r\n this.getOrderTime(time);\r\n this.$emit('getList');\r\n },\r\n // 订单号搜索\r\n orderSearch() {\r\n this.getOrderNum(this.orderData.real_name);\r\n this.getfieldKey(this.orderData.field_key);\r\n this.$emit('getList', 1);\r\n },\r\n // 点击订单类型\r\n onClickTab() {\r\n this.$emit('onChangeType', this.currentTab);\r\n },\r\n // 批量删除\r\n delAll() {\r\n if (this.delIdList.length === 0) {\r\n this.$message.error('请先选择删除的订单!');\r\n } else {\r\n if (this.isDels) {\r\n this.delIdList.filter((item) => {\r\n this.isDelIdList.push(item.id);\r\n });\r\n let idss = {\r\n ids: this.isDelIdList,\r\n all: this.isAll,\r\n where: this.orderData,\r\n };\r\n let delfromData = {\r\n title: '删除订单',\r\n url: `/order/dels`,\r\n method: 'post',\r\n ids: idss,\r\n };\r\n this.$modalSure(delfromData)\r\n .then((res) => {\r\n this.$message.success(res.msg);\r\n this.tabList();\r\n })\r\n .catch((res) => {\r\n this.$message.error(res.msg);\r\n });\r\n } else {\r\n this.$message.error('您选择的的订单存在用户未删除的订单,无法删除用户未删除的订单!');\r\n }\r\n }\r\n },\r\n del(name) {\r\n // this.orderInfo = ''\r\n this.modals2 = false;\r\n this.writeOffFrom.confirm = 0;\r\n this.$refs[name].resetFields();\r\n },\r\n handleSubmit() {\r\n this.$emit('on-submit', this.data);\r\n },\r\n // 刷新\r\n Refresh() {\r\n this.$emit('getList');\r\n },\r\n //\r\n handleReset() {\r\n this.$refs.form.resetFields();\r\n this.$emit('on-reset');\r\n },\r\n // 上传头部token\r\n // getToken() {\r\n // this.uploadHeaders[\"Authori-zation\"] =\r\n // \"Bearer \" + util.cookies.get(\"token\");\r\n // },\r\n // beforeUpload(file){\r\n // /* Boilerplate to set up FileReader */\r\n // \tconst reader = new FileReader();\r\n // \treader.onload = (e) => {\r\n // \t\t/* Parse data */\r\n // \t\tconst bstr = e.target.result;\r\n // \t\tconst wb = XLSX.read(bstr, {type:'binary'});\r\n // \t\t/* Get first worksheet */\r\n // \t\tconst wsname = wb.SheetNames[0];\r\n // \t\tconst ws = wb.Sheets[wsname];\r\n // \t\t/* Convert array of arrays */\r\n // \t\tconst data = XLSX.utils.sheet_to_json(ws, {header:1});\r\n // \t\t/* Update state */\r\n // \t\tthis.data5 = data;\r\n // this.cols5 = make_cols(ws['!ref']);\r\n // this.modal5 = true;\r\n // \t};\r\n // \treader.readAsBinaryString(file);\r\n // },\r\n // 上传成功\r\n uploadSuccess(res, file, fileList) {\r\n if (res.status === 200) {\r\n this.$message.success(res.msg);\r\n this.file = res.data.src;\r\n this.fileList = fileList;\r\n } else {\r\n this.$message.error(res.msg);\r\n }\r\n },\r\n //移除文件\r\n removeFile(file, fileList) {\r\n this.file = '';\r\n this.fileList = fileList;\r\n },\r\n // 手动批量发货-确定\r\n manualModalOk() {\r\n this.$refs.upload.clearFiles();\r\n handBatchDelivery({\r\n file: this.file,\r\n })\r\n .then((res) => {\r\n this.$message.success(res.msg);\r\n this.fileList = [];\r\n })\r\n .catch((err) => {\r\n this.$message.error(err.msg);\r\n this.fileList = [];\r\n });\r\n },\r\n // 手动批量发货-取消\r\n manualModalCancel() {\r\n this.fileList = [];\r\n this.$refs.upload.clearFiles();\r\n },\r\n // 自动批量发货-取消\r\n autoModalOk() {\r\n if (this.isAll == '全部' || this.formSelection.length) {\r\n this.$refs.send.modals = true;\r\n this.$refs.send.getList();\r\n this.$refs.send.getDeliveryList();\r\n } else {\r\n this.$message.error('请选择本页订单');\r\n }\r\n },\r\n // 自动批量发货-取消\r\n autolModalCancel() {},\r\n submitFail() {\r\n otherBatchDelivery();\r\n },\r\n queuemModal() {\r\n // this.$router.push({ path: 'queue/list' });\r\n this.$refs.queue.modal = true;\r\n },\r\n onAuto() {\r\n this.$refs.sends.modals = true;\r\n this.$refs.sends.getList();\r\n this.$refs.sends.getDeliveryList();\r\n },\r\n // 下载物流公司对照表\r\n getExpressList() {\r\n exportExpressList()\r\n .then((res) => {\r\n window.open(res.data[0]);\r\n })\r\n .catch((err) => {\r\n this.$message.error(err.msg);\r\n });\r\n },\r\n },\r\n};\r\n</script>\r\n\r\n<style lang=\"scss\" scoped>\r\n.tab_data ::v-deep .ivu-form-item-content {\r\n margin-left: 0 !important;\r\n}\r\n.table_box ::v-deep .ivu-divider-horizontal {\r\n margin-top: 0px !important;\r\n}\r\n.table_box ::v-deep .ivu-form-item {\r\n margin-bottom: 15px !important;\r\n}\r\n.tabform {\r\n margin-bottom: 10px;\r\n}\r\n.Refresh {\r\n font-size: 12px;\r\n color: var(--prev-color-primary);\r\n cursor: pointer;\r\n}\r\n.order-wrapper {\r\n margin-top: 10px;\r\n padding: 10px;\r\n border: 1px solid #ddd;\r\n .title {\r\n font-size: 16px;\r\n }\r\n .order-box {\r\n margin-top: 10px;\r\n border: 1px solid #ddd;\r\n .item {\r\n display: flex;\r\n align-items: center;\r\n border-bottom: 1px solid #ddd;\r\n &:last-child {\r\n border-bottom: 0;\r\n }\r\n .label {\r\n width: 100px;\r\n padding: 10px 0 10px 10px;\r\n border-right: 1px solid #ddd;\r\n }\r\n .con {\r\n flex: 1;\r\n padding: 10px 0 10px 10px;\r\n }\r\n }\r\n }\r\n}\r\n.manual-modal {\r\n display: flex;\r\n align-items: center;\r\n}\r\n.df {\r\n display: flex;\r\n}\r\n</style>\r\n"]}]}