Commit 75ff7267 by chenwq

积分管理开发,联调,样式

1 parent 1019384a
...@@ -1895,6 +1895,51 @@ ...@@ -1895,6 +1895,51 @@
"integrity": "sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A==", "integrity": "sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A==",
"dev": true "dev": true
}, },
"ansi-styles": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true,
"optional": true,
"requires": {
"color-convert": "^2.0.1"
}
},
"chalk": {
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
"dev": true,
"optional": true,
"requires": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
}
},
"color-convert": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
"dev": true,
"optional": true,
"requires": {
"color-name": "~1.1.4"
}
},
"color-name": {
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
"dev": true,
"optional": true
},
"has-flag": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
"dev": true,
"optional": true
},
"ssri": { "ssri": {
"version": "8.0.1", "version": "8.0.1",
"resolved": "https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz", "resolved": "https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz",
...@@ -1903,6 +1948,28 @@ ...@@ -1903,6 +1948,28 @@
"requires": { "requires": {
"minipass": "^3.1.1" "minipass": "^3.1.1"
} }
},
"supports-color": {
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
"dev": true,
"optional": true,
"requires": {
"has-flag": "^4.0.0"
}
},
"vue-loader-v16": {
"version": "npm:vue-loader@16.8.3",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-16.8.3.tgz",
"integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==",
"dev": true,
"optional": true,
"requires": {
"chalk": "^4.1.0",
"hash-sum": "^2.0.0",
"loader-utils": "^2.0.0"
}
} }
} }
}, },
...@@ -6448,9 +6515,9 @@ ...@@ -6448,9 +6515,9 @@
} }
}, },
"glsx-common": { "glsx-common": {
"version": "2.0.8", "version": "2.1.0",
"resolved": "https://registry.npmjs.org/glsx-common/-/glsx-common-2.0.8.tgz", "resolved": "https://registry.npmjs.org/glsx-common/-/glsx-common-2.1.0.tgz",
"integrity": "sha512-hKt/SNFu+NslOHWvDLxmRwUkINBrnATTYIkOj+jmcx5RqfXIbMgEipzFGbCICWMlYYoecwRiJ6341sstPCCHLQ==", "integrity": "sha512-wlUFgrZkJODh5MNpnVaT2zswkep1BUnvRgyhUABp2mDrt7d8yemnrdDYCfuBSWT7LCn+httSEieOEtm2XSlc0Q==",
"requires": { "requires": {
"axios": "^0.21.3", "axios": "^0.21.3",
"md5": "^2.3.0", "md5": "^2.3.0",
...@@ -6459,9 +6526,9 @@ ...@@ -6459,9 +6526,9 @@
} }
}, },
"glsx-components": { "glsx-components": {
"version": "1.5.4", "version": "1.5.7",
"resolved": "https://registry.npmjs.org/glsx-components/-/glsx-components-1.5.4.tgz", "resolved": "https://registry.npmjs.org/glsx-components/-/glsx-components-1.5.7.tgz",
"integrity": "sha512-TemXhzs6giPF7idPHNhrpeMNvP4O6hbm6q/aKPNJSldZB7o+MbmPxeYXKZydvvz6V53tk+KBLbgVhcSv1F8FIA==", "integrity": "sha512-WEWt1Ev7uf8VgILrEr15ZHxOreqWEVEY2WRP5EmZKzYKTVF/7dQU/oI84+Xo4vSmlz7ltblaATyrwm1U1LDnHg==",
"requires": { "requires": {
"@amap/amap-jsapi-loader": "^1.0.1", "@amap/amap-jsapi-loader": "^1.0.1",
"core-js": "^3.6.5", "core-js": "^3.6.5",
...@@ -10669,9 +10736,9 @@ ...@@ -10669,9 +10736,9 @@
"dev": true "dev": true
}, },
"qs": { "qs": {
"version": "6.11.1", "version": "6.11.2",
"resolved": "https://registry.npmjs.org/qs/-/qs-6.11.1.tgz", "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.2.tgz",
"integrity": "sha512-0wsrzgTz/kAVIeuxSjnpGC56rzYtr6JT/2BwEvMaPhFIoYa1aGO8LbzuU1R0uUYQkLpWBTOj0l/CLAJB64J6nQ==", "integrity": "sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA==",
"requires": { "requires": {
"side-channel": "^1.0.4" "side-channel": "^1.0.4"
} }
...@@ -13347,75 +13414,6 @@ ...@@ -13347,75 +13414,6 @@
} }
} }
}, },
"vue-loader-v16": {
"version": "npm:vue-loader@16.8.3",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-16.8.3.tgz",
"integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==",
"dev": true,
"optional": true,
"requires": {
"chalk": "^4.1.0",
"hash-sum": "^2.0.0",
"loader-utils": "^2.0.0"
},
"dependencies": {
"ansi-styles": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true,
"optional": true,
"requires": {
"color-convert": "^2.0.1"
}
},
"chalk": {
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
"dev": true,
"optional": true,
"requires": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
}
},
"color-convert": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
"dev": true,
"optional": true,
"requires": {
"color-name": "~1.1.4"
}
},
"color-name": {
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
"dev": true,
"optional": true
},
"has-flag": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
"dev": true,
"optional": true
},
"supports-color": {
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
"dev": true,
"optional": true,
"requires": {
"has-flag": "^4.0.0"
}
}
}
},
"vue-router": { "vue-router": {
"version": "3.6.5", "version": "3.6.5",
"resolved": "https://registry.npmjs.org/vue-router/-/vue-router-3.6.5.tgz", "resolved": "https://registry.npmjs.org/vue-router/-/vue-router-3.6.5.tgz",
......
import { http } from '@/main'
const path = 'dj.api.smarcarlife.'
// 获取所属分类
const getTypeList = params => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = 'dj.api.goods.type.list'
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 发货单分页查询
const getDeliveryList = params => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
// params.routerMethod = `${path}purchaseOrder.delivery.page`
params.routerMethod = 'dj.api.smarcarlife.purchaseOrder.deliveryDetail.page'
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 发货单导出
export function exportExcel(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
// params.routerMethod = `${path}purchaseOrder.delivery.export`
params.routerMethod = 'dj.api.smarcarlife.purchaseOrder.deliveryDetail.export'
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
export default { getTypeList, getDeliveryList, exportExcel }
import { http } from '@/main'
const path = 'dj.api.smarcarlife.'
// 积分核销订单列表
const getList = params => {
params.method = `scrm.api.shopmall.integralorder.all.page`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 积分核销订单列表-积分订单详情
const getOrderDetail = params => {
params.method = `scrm.api.shopmall.integralorder.detail`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 积分核销订单列表-导出
const orderExport = params => {
params.method = `scrm.api.shopmall.integralorder.all.export`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 积分核销订单列表-导入
const orderImport = params => {
params.method = `scrm.api.shopmall.integralorder.settlement.import`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
// 结算/取消结算
const integralorderSettle = params => {
params.method = `scrm.api.shopmall.integralorder.settlement`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
// 用户积分明细列表
const getIntegralCustomerList = params => {
params.method = `scrm.api.shopmall.integralcustomer.page`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 用户积分明细列表-导出
const getIntegralCustomerExport = params => {
params.method = `scrm.api.shopmall.integralcustomer.export`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 用户积分明细详情-分页查询用户积分明细列表
const getIntegralDetailList = params => {
params.method = `scrm.api.shopmall.integraldetail.page`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 用户积分明细详情-客户积分详情
const customerDetail = params => {
params.method = `scrm.api.shopmall.integralcustomer.detail`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
// 用户积分明细详情-导出用户积分明细数据
const getIntegralDetailExport = params => {
params.method = `scrm.api.shopmall.integraldetail.export`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
export default { getList, getOrderDetail, orderExport, orderImport, integralorderSettle, getIntegralCustomerList, getIntegralCustomerExport, getIntegralDetailList, customerDetail, getIntegralDetailExport }
import { http } from '@/main'
const path = 'dj.api.smarcarlife.'
const path2 = 'dj.api.goodsInfo.'
const path3 = 'dj.api.smartcarlife.'
// 分页查询采购订单
const getPurchaseOrderList = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseOrder.page`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 采购订单取消/审核
const purchaseOrderCancelOrCheck = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseOrder.cancelOrCheck`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
const purchaseOrderDelete = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `dj.api.smarcarlife.purchaseOrder.deleteByOrderCode`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
// 查看采购订单
const purchaseOrderDetail = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseOrder.view`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 分页查询采购商城素材信息
const listWithPagePurchaseInfo = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path2}listWithPage.purchaseInfo`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 获取当前登录园区店商户收货地址
const addressGet = (params = {}) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}yqMerchantDeliveryAddress.get`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 保存园区店商户收货地址
const addressSave = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}yqMerchantDeliveryAddress.save`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 按商品类目分组获取购物车列表
const listGroupByGoodsType = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseShoppingCar.listGroupByGoodsType`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 更新购物车商品选中标识
const updateSelectedFlag = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseShoppingCar.updateSelectedFlag`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 移除购物车商品
const shoppingCarRemove = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseShoppingCar.remove`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 添加到购物车
const shoppingCarAdd = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseShoppingCar.add`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 修改购物车商品数量
export function shoppingCarUpdateNumber(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseShoppingCar.updateNumber`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params
})
}
// 添加采购订单
export function purchaseOrderAdd(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseOrder.add`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
export function exportExcel(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `dj.api.smarcarlife.purchaseOrder.export`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 采购订单入库
export function purchaseOrderPutIn(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path}purchaseOrder.putIn`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 获取下单/入库门店
export function getMerchantList(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `${path3}permission.yqMerchant.list`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
//查询园区店关联的4s店列表 -入库门店
const get4SRefByYqShopList = (params) => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `dj.api.scenemerchantref.query4SRefByYqShop`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
//编辑
export function selectByOrderCode(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `dj.api.smarcarlife.purchaseOrder.selectByOrderCode`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
// 是否有发货主体
export function checkShipper(params) {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `dj.api.smarcarlife.purchaseOrder.checkShipper`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true,
returnAll:true
})
}
// 确认发货
// export function purchaseOrderConfirmDelivery(data) {
// params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
// data.routerMethod = `${path}purchaseOrder.confirmDelivery`
// return http(data)
// }
export default {checkShipper,get4SRefByYqShopList, selectByOrderCode,purchaseOrderDelete, getMerchantList, purchaseOrderPutIn, exportExcel, shoppingCarUpdateNumber, purchaseOrderAdd, shoppingCarAdd, shoppingCarRemove, updateSelectedFlag, listGroupByGoodsType, getPurchaseOrderList, purchaseOrderCancelOrCheck, purchaseOrderDetail, listWithPagePurchaseInfo, addressGet, addressSave }
\ No newline at end of file \ No newline at end of file
...@@ -5,15 +5,40 @@ html { ...@@ -5,15 +5,40 @@ html {
margin: 0; margin: 0;
padding: 0; padding: 0;
overflow: hidden; overflow: hidden;
background-color: #F4F5FA; background-color: #f4f5fa;
}
.flex {
display: flex;
} }
.points .container { .points .container {
background: #ffffff; background: #ffffff;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
padding: 20px; padding: 20px;
} }
.points.edit-box .container.all-page {
min-height: calc(100vh - 204px);
}
.points.edit-box .container {
padding: 0 0 20px;
}
.points .table-header {
display: flex;
justify-content: space-between;
line-height: 32px;
margin-bottom: 10px;
}
.points .page-title {
padding-left: 20px;
height: 55px;
line-height: 55px;
border-bottom: 1px solid #e5e5e5;
}
.points .m-b-20 { .points .m-b-20 {
margin-bottom: 20px; margin-bottom: 20px;
} }
...@@ -21,8 +46,8 @@ html { ...@@ -21,8 +46,8 @@ html {
.points .p-t-20 { .points .p-t-20 {
padding-top: 20px; padding-top: 20px;
} }
.pointer{ .pointer {
cursor: pointer; cursor: pointer;
} }
.carIcon { .carIcon {
display: inline-block; display: inline-block;
...@@ -32,6 +57,6 @@ cursor: pointer; ...@@ -32,6 +57,6 @@ cursor: pointer;
background-size: 100% 100%; background-size: 100% 100%;
margin-right: 4px; margin-right: 4px;
} }
.el-cascader-menu__wrap{ .el-cascader-menu__wrap {
height: 204px!important; height: 204px !important;
} }
<template>
<div>
<div class="input-number-range" :class="{ 'is-disabled': disabled }">
<div class="flex">
<div class="from">
<el-input ref="input_from" v-model="formData[keyObj.from]" :disabled="disabled" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')" placeholder="请输入" @change="handleInputChangeFrom"></el-input>
</div>
<div class="center">
<span>至</span>
</div>
<div class="to">
<el-input ref="input_to" v-model="formData[keyObj.to]" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')" :disabled="disabled" placeholder="请输入" @change="handleInputChangeTo"></el-input>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
name: 'InputNumberRange',
props: {
// 是否禁用
disabled: {
type: Boolean,
default: false
},
formData: {
type: Object,
default: () => {
return {}
}
},
keyObj: {
type: Object,
default: () => {
return {
from: 'a',
to: 'b'
}
}
}
},
data() {
return {}
},
methods: {
// from输入框change事件
handleInputChangeFrom(value) {
let from = this.formData[this.keyObj.from]
let to = this.formData[this.keyObj.to]
if (+from > +to) {
this.formData[this.keyObj.to] = from
}
},
// to输入框change事件
handleInputChangeTo(value) {
let from = this.formData[this.keyObj.from]
let to = this.formData[this.keyObj.to]
if (+from > +to) {
this.formData[this.keyObj.to] = from
}
}
}
}
</script>
<style lang="scss" scoped>
.input-number-range {
background-color: #fff;
border: 1px solid #dcdfe6;
border-radius: 4px;
}
.flex {
display: flex;
flex-direction: row;
width: 100%;
justify-content: center;
align-items: center;
/deep/ .el-input .el-input__inner {
border: 0px;
margin: 0;
padding: 0 10px;
background-color: transparent;
}
.center {
margin-top: 1px;
}
.unit {
margin-right: 10px;
}
}
.is-disabled {
background-color: #eef0f6;
border-color: #e4e7ed;
color: #c0c4cc;
cursor: not-allowed;
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -9,5 +9,7 @@ ...@@ -9,5 +9,7 @@
*/ */
import Vue from 'vue' import Vue from 'vue'
import glsxDialog from '@/components/glsx-dialog/index.vue' import glsxDialog from '@/components/glsx-dialog/index.vue'
import InputNumRange from '@/components/InputNumRange/index.vue'
Vue.component('glsx-dialog', glsxDialog) Vue.component('glsx-dialog', glsxDialog)
Vue.component('input-num-range', InputNumRange)
...@@ -12,11 +12,13 @@ import apis from './api' ...@@ -12,11 +12,13 @@ import apis from './api'
import './public-path' import './public-path'
import '@/assets/css/public.scss' import '@/assets/css/public.scss'
import '@/components' import '@/components'
import utils from './utils/index'
// import 'glsx-components/dist/glsx-components.css' // import 'glsx-components/dist/glsx-components.css'
import { start } from '@/setup' import { start } from '@/setup'
Vue.config.productionTip = false Vue.config.productionTip = false
Vue.prototype.$apis = apis Vue.prototype.$apis = apis
Vue.prototype.size = 'small' Vue.prototype.size = 'small'
Vue.prototype.$utils = utils
Vue.prototype.$EventBus = new Vue() Vue.prototype.$EventBus = new Vue()
start() start()
export { bootstrap, mount, unmount } from '@/setup' export { bootstrap, mount, unmount } from '@/setup'
......
...@@ -4,9 +4,27 @@ const staticRoutes = Object.freeze([ ...@@ -4,9 +4,27 @@ const staticRoutes = Object.freeze([
path: '/' path: '/'
}, },
{ {
name: 'DeliverList', name: 'pointsList',
path: '/DeliverList/index', path: '/pointsList/index',
component: resolve => require([`@/views/DeliverList/index.vue`], resolve), component: resolve => require([`@/views/pointsList/index.vue`], resolve),
meta: {}
},
{
name: 'orderDetail',
path: '/pointsList/orderDetail',
component: resolve => require([`@/views/pointsList/orderDetail.vue`], resolve),
meta: {}
},
{
name: 'detailList',
path: '/pointsList/detailList',
component: resolve => require([`@/views/pointsList/detailList.vue`], resolve),
meta: {}
},
{
name: 'detail',
path: '/pointsList/detail',
component: resolve => require([`@/views/pointsList/detail.vue`], resolve),
meta: {} meta: {}
} }
]) ])
......
export function debounce(func, wait = 200) { function debounce(func, wait = 200) {
let timeout let timeout
return function(event) { return function(event) {
clearTimeout(timeout) clearTimeout(timeout)
...@@ -8,7 +8,7 @@ export function debounce(func, wait = 200) { ...@@ -8,7 +8,7 @@ export function debounce(func, wait = 200) {
} }
} }
export function dateFormat(dateTime, format = 'YYYY-MM-DD HH:mm') { function dateFormat(dateTime, format = 'YYYY-MM-DD HH:mm') {
const date = new Date(dateTime) const date = new Date(dateTime)
const config = { const config = {
YYYY: date.getFullYear(), YYYY: date.getFullYear(),
...@@ -26,7 +26,80 @@ export function dateFormat(dateTime, format = 'YYYY-MM-DD HH:mm') { ...@@ -26,7 +26,80 @@ export function dateFormat(dateTime, format = 'YYYY-MM-DD HH:mm') {
/** /**
* 校验手机号码格式 * 校验手机号码格式
*/ */
export function checkPhone(mobile) { function checkPhone(mobile) {
const myreg = /^(13[0-9]|15[0-9]|16[0-9]|17[0-9]|18[0-9]|19[0-9]|14[0-9])[0-9]{8}$/ const myreg = /^(13[0-9]|15[0-9]|16[0-9]|17[0-9]|18[0-9]|19[0-9]|14[0-9])[0-9]{8}$/
return myreg.test(mobile) return myreg.test(mobile)
} }
/**
* 用于glsx-combi-form的select写入options
* formName String FormData的属性名
* hasAll Boolean 是否需要添加“全部”属性
* refreshSigle String 更新特定的属性的options
*/
function getOptionsList(that, formName, hasAll = true, refreshSigle) {
if (refreshSigle) {
var item = that[formName].find(k => k.name == refreshSigle)
var index = that[formName].findIndex(k => k.name == refreshSigle)
that.$set(that[formName][index], 'optionList', that.$common.utils.deepClone(that.baseData[item.optionsName]))
if (hasAll && that.baseData[item.optionsName].length && that.baseData[item.optionsName][0][that[formName][index].optionLabel] !== '全部') {
const temp = {}
temp[that[formName][index].optionId] = ''
temp[that[formName][index].optionLabel] = '全部'
that[formName][index].optionList.unshift(temp)
}
} else {
that[formName].forEach((item, index) => {
if (item.type === 'select' && that.baseData[item.optionsName]?.length) {
that.$set(that[formName][index], 'optionList', that.$common.utils.deepClone(that.baseData[item.optionsName]))
if (hasAll && that.baseData[item.optionsName].length && that.baseData[item.optionsName][0][that[formName][index].optionLabel] !== '全部') {
const temp = {}
temp[that[formName][index].optionId] = ''
temp[that[formName][index].optionLabel] = '全部'
that[formName][index].optionList.unshift(temp)
}
}
})
}
}
/** 二次确认封装 */
function secondConfirm(that, title, txt, apiModule, apiName, apiParams, type = 'warning', fn) {
that.$confirm(txt, title, {
confirmButtonText: '确定',
cancelButtonText: '取消',
type,
callback: action => {
if (action == 'confirm') {
that.$apis[apiModule][apiName](apiParams).then(res => {
that.$message({
message: res.code == '0' ? '操作成功' : res.message,
type: res.code == '0' ? 'success' : 'error'
})
if (res.code == '0') {
fn && fn()
that.handleSearch()
}
})
}
}
})
}
function aToExport(url) {
var a = document.createElement('a')
a.setAttribute('id', 'exportToExport')
a.setAttribute('href', url)
a.setAttribute('target', '_blank')
document.body.appendChild(a)
a.click()
}
export default {
debounce,
dateFormat,
checkPhone,
getOptionsList,
secondConfirm,
aToExport
}
<template>
<div class="points">
<div class="points edit-box">
<div class="container m-b-20 top">
<div class="page-title">积分详情</div>
<div class="flex box">
<div class="flex block" v-for="(item, index) in detailFormData" :key="index">
<img class="icon" :src="require(`@/assets/point-custom-${index}.png`)" />
<div>
<div>{{ item.title }}</div>
<div class="num">{{ detailData[item.name] || 0 }}</div>
</div>
</div>
</div>
</div>
</div>
<div class="container">
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="showFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="table-header">
<h2>客户积分明细</h2>
<el-button size="small" @click="exportExcel" type="primary" plain>导出</el-button>
</div>
<!-- 表格区域 开始 -->
<GLTable ref="pointRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"></GLTable>
<!-- 表格区域 end -->
</div>
</div>
</template>
<script>
import url from '@/assets/empty.png'
export default {
data() {
//这里存放数据
return {
size: 'small',
url: url,
routeInfo: {},
searchForm: {
ruleType: ''
},
showFormData: [
{
label: '消费类型',
name: 'ruleType',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confLabel',
optionsName: 'ruleTypeList'
}
],
detailData: {},
detailFormData: [
{
title: '当前积分',
name: 'availableIntegral'
},
{
title: '积分累计收入',
name: 'totalIntegral'
},
{
title: '积分累计支出',
name: 'usedIntegral'
}
],
// 表格
getListApi: this.$apis.points.getIntegralDetailList,
tableParams: {
listName: 'list',
tableOption: false,
tableColumns: [
{
label: '类型',
prop: 'direct',
formatter: cellValue => {
const obj = {
ADD: '收入',
DEDUCT: '支出'
}
return obj[cellValue.direct]
}
},
{
label: '数量',
prop: 'integralValue'
},
{
label: '消费类型',
prop: 'ruleDesc'
},
{
label: '消费名称',
prop: 'integralValue'
},
{
label: '消费时间',
prop: 'createdDate'
}
]
},
pageConf: { pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total' },
// 基本数据
baseData: {
ruleTypeList: [
{
confId: 'SHOPPING_GIVE',
confLabel: '购物赠送'
},
{
confId: 'SHOPPING_DEDUCT',
confLabel: '购物抵扣'
},
{
confId: 'SHOP_VERIFY',
confLabel: '门店核销'
},
{
confId: 'GIVE_BACK',
confLabel: '退还积分'
}
]
}
}
},
created() {
this.routeInfo = this.$route.query
},
mounted() {
this.$utils.getOptionsList(this, 'showFormData')
this.customerDetail()
},
methods: {
customerDetail() {
const params = {
customerId: this.routeInfo.id
}
this.$apis.points.customerDetail(params).then(res => {
this.detailData = res || {}
})
},
dealParams() {
this.searchForm.customerId = this.routeInfo.id
return this.searchForm
},
beforeSearchFn() {
return new Promise(resolve => {
this.searchForm = this.dealParams()
resolve()
})
},
handleSearch() {
this.$refs.pointRef.refreshTable()
},
handleReset() {
this.searchForm = {
ruleType: ''
}
this.handleSearch()
},
exportExcel() {
var params = this.dealParams()
this.$apis.points.getIntegralDetailExport(params).then(res => {
this.$utils.aToExport(res)
})
}
}
}
</script>
<style scoped>
.top .icon {
width: 44px;
height: 44px;
margin-right: 16px;
}
.top .box {
padding: 20px 20px 0;
}
.top .block {
box-sizing: border-box;
width: 271px;
height: 100px;
font-size: 14px;
color: #333333;
background: #f9fafc;
margin-right: 20px;
padding: 24px 16px 20px;
}
.top .num {
font-weight: 700;
font-size: 26px;
color: #333333;
margin-top: 10px;
}
</style>
<template>
<div class="points">
<div class="container">
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="showFormData" @handleOk="handleSearch" @handleRest="handleReset">
<div slot="jifen">
<input-num-range :formData="searchForm" :keyObj="{ from: 'minIntegral', to: 'maxIntegral' }"></input-num-range>
</div>
</GLCombiForm>
<div class="table-header">
<div> </div>
<div>
<el-button size="small" @click="exportExcel" type="primary" plain>导出</el-button>
</div>
</div>
<!-- 表格区域 开始 -->
<GLTable ref="pointRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<div class="table-btns" slot="auth-button" slot-scope="scope">
<GLTableButton :buttonList="tableButtonList" :buttonItem="scope.scope" :buttonNum="3"></GLTableButton>
</div>
</GLTable>
<!-- 表格区域 end -->
</div>
</div>
</template>
<script>
import url from '@/assets/empty.png'
export default {
data() {
//这里存放数据
return {
size: 'small',
url: url,
searchForm: {},
showFormData: [
{
label: '搜索',
name: 'term',
type: 'input',
placeholder: '请输入昵称、手机号',
isClear: true,
maxlength: 100
},
{
label: '当前积分',
name: '',
addHtml: 'jifen'
}
],
tableButtonList: [
{
type: 'GLButton',
name: '详情',
attrs: {
type: 'text',
fn: '详情'
},
listeners: {
click: this.handleDetail
}
}
],
// 表格
getListApi: this.$apis.points.getIntegralCustomerList,
tableParams: {
listName: 'list',
tableOption: true,
tableColumns: [
{
label: '昵称',
prop: 'customerWechatName'
},
{
label: '手机号',
prop: 'customerPhone'
},
{
label: '当前积分',
prop: 'availableIntegral'
},
{
label: '累计收入',
prop: 'totalIntegral'
},
{
label: '累计支出',
prop: 'usedIntegral'
}
]
},
pageConf: { pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total' },
// 基本数据
baseData: {
statusList: []
}
}
},
mounted() { },
methods: {
handleDetail(row) {
this.$router.push({
path: '/pointsList/detail',
query: {
id: row.id
}
})
},
handleSearch() {
this.$refs.pointRef.refreshTable()
},
handleReset() {
this.searchForm = {}
this.handleSearch()
},
exportExcel() {
this.$apis.points.getIntegralCustomerExport(this.searchForm).then(res => {
this.$utils.aToExport(res)
})
}
}
};
</script>
<style scoped>
</style>
<template>
<div class="points">
<div class="container">
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="showFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="table-header">
<h2>积分核销列表</h2>
<div>
<!-- <el-button size="small" @click="handleImport" type="primary">批量结算导入</el-button> -->
<div class="flex">
<div class="import-btn">
批量结算导入
<input id="fileUpload" type="file" style="opacity: 0;" ref="file" class="import-input" accept="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,application/vnd.ms-excel" @change="e => handleImport(e)" />
</div>
<el-button size="small" @click="exportExcel" type="primary" plain>导出</el-button>
</div>
</div>
</div>
<!-- 表格区域 开始 -->
<GLTable ref="pointRef" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<div class="table-btns" slot="auth-button" slot-scope="scope">
<GLTableButton :buttonList="tableButtonList" :buttonItem="scope.scope" :buttonNum="3"></GLTableButton>
</div>
</GLTable>
<!-- 表格区域 end -->
</div>
</div>
</template>
<script>
import * as dayjs from 'dayjs'
import url from '@/assets/empty.png'
export default {
data() {
//这里存放数据
return {
size: 'small',
url: url,
searchForm: {
settlementStatus: ''
},
tableSearchForm: {},
showFormData: [
{
label: '项目名称',
name: 'bizRelName',
type: 'input',
isClear: true,
maxlength: 100
},
{
label: '商户名称',
name: 'merchantName',
type: 'input',
isClear: true,
maxlength: 100
},
{
label: '结算状态',
name: 'settlementStatus',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confLabel',
optionsName: 'settlementStatusList'
},
{
label: '核销日期',
name: 'verificationTimeStr',
type: 'datePicker',
isClear: true,
pickerOptions: 'beforeRangePickerOptions'
}
],
tableButtonList: [
{
type: 'GLButton',
name: '查看',
attrs: {
type: 'text',
fn: '查看'
},
listeners: {
click: this.handleDetail
}
},
{
type: 'GLButton',
name: row => {
return row.settlementStatus ? '取消结算' : '去结算'
},
attrs: {
type: 'text',
fn: '去结算'
},
listeners: {
click: this.handleSettlement
}
}
],
// 表格
getListApi: this.$apis.points.getList,
tableParams: {
listName: 'list',
tableOption: true,
tableColumns: [
{
label: '项目名称',
prop: 'bizRelName'
},
{
label: '消费积分',
prop: 'bizRelName'
},
{
label: '客户昵称',
prop: 'customerWechatName'
},
{
label: '手机号',
prop: 'customerPhone',
width: '120px'
},
{
label: '核销员工',
prop: 'verificationStaffName'
},
{
label: '商户名称',
prop: 'merchantName'
},
{
label: '核算状态',
prop: 'settlementStatusStr',
width: '90px'
},
{
label: '核销日期',
prop: 'verificationTime',
width: '180px'
},
{
label: '操作人',
prop: 'updatedBy'
},
{
label: '订单编号',
prop: 'orderCode',
width: '200px'
}
]
},
pageConf: { pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total' },
// 基本数据
baseData: {
settlementStatusList: [
{
confId: '0',
confLabel: '未结算'
},
{
confId: '1',
confLabel: '已结算'
}
]
}
}
},
mounted() {
this.$utils.getOptionsList(this, 'showFormData')
},
methods: {
getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm))
if (this.searchForm.verificationTimeStr) {
params.verificationStartTime = dayjs(this.searchForm.verificationTimeStr[0]).format('YYYY-MM-DD') + ' 00:00:00'
params.verificationStartTime = dayjs(this.searchForm.verificationTimeStr[1]).format('YYYY-MM-DD') + ' 23:59:59'
}
delete params.verificationTimeStr
return params
},
beforeSearchFn() {
return new Promise(resolve => {
this.tableSearchForm = this.getParams()
delete this.tableSearchForm.verificationTimeStr
resolve()
})
},
handleSearch() {
this.$refs.pointRef.refreshTable()
},
handleReset() {
this.searchForm = {
settlementStatus: ''
}
this.handleSearch()
},
handleSettlement(row) {
const params = {
id: row.id,
settlementStatus: row.settlementStatus ? 0 : 1
}
this.$utils.secondConfirm(this, '结算', '是否要' + (row.settlementStatus ? '取消结算' : '结算') + '?', 'points', 'integralorderSettle', params)
},
handleDetail(row) {
console.log(row)
this.$router.push({
path: '/pointsList/orderDetail',
query: {
id: row.id
}
})
},
handleImport(e) {
var reader = new FileReader()
var file = e.srcElement.files[0]
const isLt = file.size / 1024 / 1024 < 10
if (isLt > 10) {
this.$message({
message: '文件大小不能超过10M',
type: 'error'
})
return true
}
reader.readAsDataURL(file)
reader.onload = e => {
const imgFile = e.target.result
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.$apis.points.orderImport({ file: base64 }).then(res => {
this.$message({
message: res.code == '0' ? '操作成功' : res.message,
type: res.code == '0' ? 'success' : 'error'
})
document.getElementById('fileUpload').value = ''
this.handleSearch()
})
}
},
exportExcel() {
const params = this.getParams()
this.$apis.points.orderExport(params).then(res => {
this.$utils.aToExport(res)
})
}
}
}
</script>
<style scoped>
.import-btn {
position: relative;
width: 116px;
height: 32px;
text-align: center;
background: #5850ff;
border-radius: 4px;
color: #ffffff;
font-size: 14px;
margin-right: 8px;
}
.import-input {
opacity: 0;
position: absolute;
right: 0;
top: 0;
width: 98px;
height: 36px;
cursor: pointer;
font-size: 0;
}
</style>
<!-- 核销订单详情 -->
<template>
<div class="order-detail">
<div class="edit-box points">
<div class="container m-b-20 all-page">
<p class="page-title">订单信息</p>
<el-form label-width="100px" class="m-t-12" :inline="true">
<el-row v-for="(item, index) in detailFormDataRow" :key="index">
<el-form-item v-for="(subItem, subIndex) in item.rowList" :key="subIndex" :label="subItem.label" class="row-item">
<span class="detail-txt ellipsis-1" :title="detailForm[subItem.name]">{{ detailForm[subItem.name] ? detailForm[subItem.name] + (subItem.suffix || '') : '-' }}</span>
</el-form-item>
</el-row>
</el-form>
</div>
</div>
<GLFooter>
<el-button @click="handleCancel" size="medium" type="primary">取消</el-button>
</GLFooter>
</div>
</template>
<script>
export default {
name: 'orderDetail',
data() {
return {
size: 'small',
title: '查看订单',
editChildRef: 'editChildRef',
routeInfo: {
orderCode: ''
},
detailForm: {},
orderRefund: null,
orderGoods: [],
// 订单信息
detailFormDataRow: [],
detailFormData: [
{
label: '项目名称',
name: 'bizRelName'
},
{
label: '消费积分',
name: 'integralValue'
},
{
label: '客户昵称',
name: 'customerWechatName'
},
{
label: '手机号',
name: 'customerPhone'
},
{
label: '核销员工',
name: 'verificationStaff'
},
{
label: '结算状态',
name: 'settlementStatusTxt'
},
{
label: '核算日期',
name: 'verificationTime'
},
{
label: '订单编号',
name: 'orderCode'
},
{
label: '操作人',
name: 'updatedBy'
},
{
label: '商户名称',
name: 'merchantName'
}
],
// 基本数据
baseData: {
refundTypeList: [
{ confId: '1', confName: '退款退货' },
{ confId: '2', confName: '退款不退货' },
{ confId: '3', confName: '众筹订单退款' }
],
shareStaffTypeList: [
{ confId: '1', confName: '个微' },
{ confId: '2', confName: '企微' }
]
}
}
},
created() {
this.formToRow('detailFormData')
},
mounted() {
// this.setMinHeight('.edit-box')
this.routeInfo = this.$route.query
this.getInfo()
},
methods: {
formToRow(formName, numOfRow = 3) {
var rowNum = Math.ceil(this[formName].length / numOfRow)
for (var i = 0; i < rowNum; i++) {
for (var j = 0; j < numOfRow; j++) {
if (j == 0) {
this[formName + 'Row'][i] = {
rowList: []
}
}
if (i * numOfRow + j < this[formName].length) {
this[formName + 'Row'][i].rowList.push(this[formName][i * numOfRow + j])
}
}
}
console.log(this.detailFormDataRow)
},
getInfo() {
this.$apis.points.getOrderDetail({ id: this.routeInfo.id }).then(res => {
this.detailForm = res
this.detailForm.settlementStatusTxt = this.detailForm.settlementStatus ? '已结算' : '未结算'
})
},
handleCancel() {
this.$router.push({
path: '/pointsList/index'
})
}
}
}
</script>
<style>
.order-detail .el-form--inline .el-form-item {
margin: 0;
}
.order-detail .el-form--inline .el-form-item__content {
height: 30px;
}
.order-detail .form-img .el-form--inline .el-form-item__content {
height: auto !important;
}
.m-t-12 {
margin-top: 12px;
}
.order-detail .flex {
justify-content: flex-start;
}
.order-detail .row-item {
width: 33%;
}
.detail-txt {
display: inline-block;
width: 220px;
}
</style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!