3c43a32f8a7cb6d7bdcd7d0c69116c02.json 15 KB

1
  1. {"remainingRequest":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\src\\pages\\marketing\\lottery\\recordingList.vue?vue&type=style&index=0&id=f7d26428&lang=scss&scoped=true","dependencies":[{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\src\\pages\\marketing\\lottery\\recordingList.vue","mtime":1761185180120},{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\css-loader\\index.js","mtime":499162500000},{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\vue-loader\\lib\\loaders\\stylePostLoader.js","mtime":499162500000},{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\postcss-loader\\src\\index.js","mtime":499162500000},{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\sass-loader\\dist\\cjs.js","mtime":499162500000},{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"C:\\Users\\Administrator\\Desktop\\crmeb5.0\\template\\admin\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":[{"type":"Buffer","data":"base64:DQoudGFiQm94X2ltZyB7DQogIHdpZHRoOiAzNnB4Ow0KICBoZWlnaHQ6IDM2cHg7DQogIGJvcmRlci1yYWRpdXM6IDRweDsNCiAgY3Vyc29yOiBwb2ludGVyOw0KDQogIGltZyB7DQogICAgd2lkdGg6IDEwMCU7DQogICAgaGVpZ2h0OiAxMDAlOw0KICB9DQp9DQoucHJpemUgew0KICBkaXNwbGF5OiBmbGV4Ow0KICBhbGlnbi1pdGVtczogY2VudGVyOw0KfQ0KLnByaXplIGltZyB7DQogIHdpZHRoOiAzNnB4Ow0KICBoZWlnaHQ6IDM2cHg7DQogIGJvcmRlci1yYWRpdXM6IDRweDsNCiAgY3Vyc29yOiBwb2ludGVyOw0KICBtYXJnaW4tcmlnaHQ6IDVweDsNCn0NCi50cmlwcyB7DQogIGNvbG9yOiAjY2NjOw0KfQ0KLnc0MTQgew0KICB3aWR0aDogNDE0cHg7DQp9DQo="},{"version":3,"sources":["recordingList.vue"],"names":[],"mappings":";AA8VA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","file":"recordingList.vue","sourceRoot":"src/pages/marketing/lottery","sourcesContent":["<template>\r\n <div>\r\n <div class=\"i-layout-page-header header-title\">\r\n <div class=\"fl_header\">\r\n <el-button\r\n class=\"btn-back\"\r\n icon=\"el-icon-arrow-left\"\r\n size=\"small\"\r\n type=\"text\"\r\n v-db-click\r\n @click=\"$router.go(-1)\"\r\n >返回</el-button\r\n >\r\n <el-divider direction=\"vertical\"></el-divider>\r\n <span class=\"ivu-page-header-title\">{{ $route.meta.title }}</span>\r\n </div>\r\n </div>\r\n <el-card :bordered=\"false\" shadow=\"never\" class=\"ivu-mt\" :body-style=\"{ padding: 0 }\">\r\n <div class=\"padding-add\">\r\n <el-form\r\n ref=\"tableFrom\"\r\n :model=\"tableFrom\"\r\n :label-width=\"labelWidth\"\r\n label-position=\"right\"\r\n @submit.native.prevent\r\n inline\r\n >\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=\"奖品类型:\">\r\n <el-select type=\"button\" v-model=\"tableFrom.type\" @change=\"selectType\" class=\"form_content_width\" clearable>\r\n <el-option v-for=\"(item, i) in typeList\" :key=\"i\" :label=\"item.text\" :value=\"item.val\"></el-option>\r\n </el-select>\r\n </el-form-item>\r\n <el-form-item label=\"搜索用户:\" label-for=\"store_name\">\r\n <el-input clearable placeholder=\"请输入用户信息\" v-model=\"tableFrom.keyword\" class=\"form_content_width\" />\r\n </el-form-item>\r\n <el-form-item>\r\n <el-button type=\"primary\" v-db-click @click=\"userSearchs\">查询</el-button>\r\n </el-form-item>\r\n </el-form>\r\n </div>\r\n </el-card>\r\n <el-card :bordered=\"false\" shadow=\"never\" class=\"ivu-mt mt16\">\r\n <el-table\r\n :data=\"tableList\"\r\n v-loading=\"loading\"\r\n highlight-current-row\r\n no-userFrom-text=\"暂无数据\"\r\n no-filtered-userFrom-text=\"暂无筛选结果\"\r\n >\r\n <el-table-column label=\"ID\" width=\"80\">\r\n <template slot-scope=\"scope\">\r\n <div>{{ scope.row.id }}</div>\r\n </template>\r\n </el-table-column>\r\n <el-table-column label=\"用户信息\" min-width=\"90\">\r\n <template slot-scope=\"scope\">\r\n <span>{{ scope.row.user.nickname }} </span>\r\n </template>\r\n </el-table-column>\r\n <el-table-column label=\"奖品信息\" min-width=\"130\">\r\n <template slot-scope=\"scope\">\r\n <div class=\"prize\">\r\n <img :src=\"scope.row.prize.image\" alt=\"\" />\r\n <span>{{ scope.row.prize.name }}</span>\r\n </div>\r\n </template>\r\n </el-table-column>\r\n <el-table-column label=\"抽奖时间\" min-width=\"100\">\r\n <template slot-scope=\"scope\">\r\n <div>{{ scope.row.add_time }}</div>\r\n </template>\r\n </el-table-column>\r\n <el-table-column label=\"收货信息\" min-width=\"100\">\r\n <template slot-scope=\"scope\">\r\n <div v-if=\"scope.row.receive_info.name\">\r\n <div>姓名:{{ scope.row.receive_info.name }}</div>\r\n <div>电话:{{ scope.row.receive_info.phone }}</div>\r\n <div>地址:{{ scope.row.receive_info.address }}</div>\r\n <div v-if=\"scope.row.receive_info.mark\">备注:{{ scope.row.receive_info.mark }}</div>\r\n </div>\r\n </template>\r\n </el-table-column>\r\n <el-table-column label=\"备注\" min-width=\"100\">\r\n <template slot-scope=\"scope\">\r\n <span>{{ scope.row.deliver_info.mark }}</span>\r\n </template>\r\n </el-table-column>\r\n <el-table-column label=\"操作\" fixed=\"right\" width=\"120\">\r\n <template slot-scope=\"scope\">\r\n <a v-db-click @click=\"deliver(scope.row, 1)\" v-if=\"scope.row.type == 6 && scope.row.is_deliver === 0\"\r\n >发货</a\r\n >\r\n <a v-else-if=\"scope.row.type == 6 && scope.row.is_deliver === 1\" v-db-click @click=\"isDeliver(scope.row)\"\r\n >配送信息</a\r\n >\r\n <el-divider direction=\"vertical\" v-if=\"scope.row.type == 6\" />\r\n <a v-db-click @click=\"deliver(scope.row, 2)\">备注</a>\r\n </template>\r\n </el-table-column>\r\n </el-table>\r\n <div class=\"acea-row row-right page\">\r\n <pagination\r\n v-if=\"total\"\r\n :total=\"total\"\r\n :page.sync=\"tableFrom.page\"\r\n :limit.sync=\"tableFrom.limit\"\r\n @pagination=\"getList\"\r\n />\r\n </div>\r\n </el-card>\r\n <!-- 发货-->\r\n <el-dialog\r\n :visible.sync=\"shipModel\"\r\n width=\"540px\"\r\n :title=\"!modelTitle ? (modelType === 1 ? '发货' : '备注') : modelTitle\"\r\n :close-on-click-modal=\"false\"\r\n >\r\n <el-form\r\n v-model=\"shipModel\"\r\n :ref=\"modelType === 1 ? 'shipForm' : 'markForm'\"\r\n :model=\"modelType === 1 ? shipForm : markForm\"\r\n :rules=\"modelType === 1 ? ruleShip : ruleMark\"\r\n label-width=\"90px\"\r\n >\r\n <el-form-item v-if=\"modelType === 1\" label=\"快递公司:\" prop=\"deliver_name\">\r\n <el-select v-model=\"shipForm.deliver_name\" class=\"w100\">\r\n <el-option v-for=\"item in locationList\" :value=\"item.value\" :key=\"item.id\" :label=\"item.value\"></el-option>\r\n </el-select>\r\n </el-form-item>\r\n <el-form-item v-if=\"modelType === 1\" label=\"快递单号:\" prop=\"deliver_number\">\r\n <el-input v-model=\"shipForm.deliver_number\" placeholder=\"请输入快递单号\" class=\"w100\"></el-input>\r\n <div class=\"tips-info\" v-if=\"shipForm.deliver_name == '顺丰速运'\">\r\n <p>顺丰请输入单号 :收件人或寄件人手机号后四位</p>\r\n <p>例如:SF000000000000:3941</p>\r\n </div>\r\n </el-form-item>\r\n <el-form-item v-if=\"modelType === 2\" label=\"备注:\">\r\n <el-input v-model=\"markForm.mark\" placeholder=\"请输入备注\" class=\"w100\"></el-input>\r\n </el-form-item>\r\n <el-form-item>\r\n <div class=\"acea-row row-right\">\r\n <el-button v-db-click @click=\"cancel('formValidate')\">关闭</el-button>\r\n <el-button type=\"primary\" v-db-click @click=\"ok(modelType === 1 ? 'shipForm' : 'markForm')\">提交</el-button>\r\n </div>\r\n </el-form-item>\r\n </el-form>\r\n </el-dialog>\r\n </div>\r\n</template>\r\n\r\n<script>\r\nimport { mapState } from 'vuex';\r\nimport { lotteryRecordList, lotteryRecordDeliver } from '@/api/lottery';\r\nimport { formatDate } from '@/utils/validate';\r\nimport { getExpressData } from '@/api/order';\r\nimport { ruleShip, ruleMark } from './formRule/ruleShip';\r\nexport default {\r\n name: 'lotteryRecordList',\r\n filters: {\r\n formatDate(time) {\r\n if (time !== 0) {\r\n let date = new Date(time * 1000);\r\n return formatDate(date, 'yyyy-MM-dd hh:mm');\r\n }\r\n },\r\n },\r\n data() {\r\n return {\r\n shipModel: false,\r\n loading: false,\r\n locationList: [],\r\n shipForm: {\r\n id: '',\r\n deliver_name: '',\r\n deliver_number: null,\r\n },\r\n markForm: {\r\n id: '',\r\n mark: '',\r\n },\r\n ruleShip: ruleShip,\r\n ruleMark: ruleMark,\r\n pickerOptions: this.$timeOptions,\r\n typeList: [\r\n { text: '全部', val: '' },\r\n { text: '未中奖', val: '1' },\r\n { text: '积分', val: '2' },\r\n { text: '余额', val: '3' },\r\n { text: '红包', val: '4' },\r\n { text: '优惠券', val: '5' },\r\n { text: '商品', val: '6' },\r\n ],\r\n tableList: [],\r\n grid: {\r\n xl: 7,\r\n lg: 10,\r\n md: 12,\r\n sm: 24,\r\n xs: 24,\r\n },\r\n tableFrom: {\r\n keyword: '',\r\n time: [],\r\n page: 1,\r\n limit: 15,\r\n lottery_id: 0,\r\n },\r\n total: 0,\r\n timeVal: [],\r\n modelType: 1,\r\n lottery_id: '',\r\n modelTitle: '',\r\n };\r\n },\r\n computed: {\r\n ...mapState('admin/layout', ['isMobile']),\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 },\r\n created() {\r\n this.tableFrom.lottery_id = this.$route.query.id;\r\n this.lottery_id = this.$route.query.id;\r\n this.getList();\r\n this.getExpressData();\r\n },\r\n methods: {\r\n deliver(row, type) {\r\n this.markForm.id = row.id;\r\n this.shipForm.id = row.id;\r\n this.shipForm.deliver_name = '';\r\n this.shipForm.deliver_number = '';\r\n this.markForm.mark = row.deliver_info.mark;\r\n this.modelType = type;\r\n this.shipModel = true;\r\n },\r\n isDeliver(row) {\r\n this.markForm.id = row.id;\r\n this.shipForm.id = row.id;\r\n this.modelType = 1;\r\n this.modelTitle = '配送信息';\r\n this.shipModel = true;\r\n this.shipForm.deliver_name = row.deliver_info.deliver_name;\r\n this.shipForm.deliver_number = row.deliver_info.deliver_number;\r\n },\r\n ok(name) {\r\n this.$refs[name].validate((valid) => {\r\n lotteryRecordDeliver(this.modelType == 1 ? this.shipForm : this.markForm)\r\n .then((res) => {\r\n this.$message.success('操作成功');\r\n this.shipModel = false;\r\n this.getList();\r\n this.shipForm = {\r\n id: '',\r\n deliver_name: '',\r\n deliver_number: null,\r\n };\r\n this.modelTitle = '';\r\n this.markForm = {\r\n id: '',\r\n mark: '',\r\n };\r\n })\r\n .catch((err) => {\r\n this.$message.error(err.msg);\r\n });\r\n });\r\n },\r\n cancel() {\r\n this.modelType = 1;\r\n this.modelTitle = '';\r\n this.shipModel = false;\r\n },\r\n // 物流公司列表\r\n getExpressData() {\r\n getExpressData()\r\n .then(async (res) => {\r\n this.locationList = res.data;\r\n })\r\n .catch((res) => {\r\n this.$message.error(res.msg);\r\n });\r\n },\r\n // 具体日期\r\n onchangeTime(e) {\r\n this.timeVal = e || [];\r\n this.tableFrom.time = this.timeVal[0] ? (this.timeVal ? this.timeVal.join('-') : '') : '';\r\n this.tableFrom.page = 1;\r\n this.getList();\r\n },\r\n // 选择时间\r\n selectChange(tab) {\r\n this.tableFrom.page = 1;\r\n this.tableFrom.time = tab;\r\n this.timeVal = [];\r\n this.getList();\r\n },\r\n selectType(type) {\r\n this.tableFrom.page = 1;\r\n this.timeVal = [];\r\n this.getList();\r\n },\r\n selectChangeFactor() {\r\n this.tableFrom.page = 1;\r\n this.timeVal = [];\r\n this.getList();\r\n },\r\n // 列表\r\n getList() {\r\n this.loading = true;\r\n lotteryRecordList(this.tableFrom)\r\n .then(async (res) => {\r\n let data = res.data;\r\n this.tableList = data.list;\r\n this.total = res.data.count;\r\n this.loading = false;\r\n })\r\n .catch((res) => {\r\n this.loading = false;\r\n this.$message.error(res.msg);\r\n });\r\n },\r\n // 表格搜索\r\n userSearchs() {\r\n this.tableFrom.page = 1;\r\n this.getList();\r\n },\r\n },\r\n};\r\n</script>\r\n\r\n<style lang=\"scss\" scoped>\r\n.tabBox_img {\r\n width: 36px;\r\n height: 36px;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 100%;\r\n height: 100%;\r\n }\r\n}\r\n.prize {\r\n display: flex;\r\n align-items: center;\r\n}\r\n.prize img {\r\n width: 36px;\r\n height: 36px;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n margin-right: 5px;\r\n}\r\n.trips {\r\n color: #ccc;\r\n}\r\n.w414 {\r\n width: 414px;\r\n}\r\n</style>\r\n"]}]}