文旅景点,资讯, 商家店铺,旅游团
This commit is contained in:
@@ -12,6 +12,19 @@ export const getList = (current, size, params) => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const getTourOrderList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/order/tour-order-page',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
export const getDetail = (id) => {
|
export const getDetail = (id) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/common/order/detail',
|
url: '/common/order/detail',
|
||||||
@@ -63,3 +76,21 @@ export const fillExpress = (id, expressNo) => {
|
|||||||
data: {id, expressNo}
|
data: {id, expressNo}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
export const confirmGuideInfo = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-order-detail/confirm-guide-info',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
export const fillContractUrl = (id, contractUrl) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-order-detail/fill-contractUrl',
|
||||||
|
method: 'post',
|
||||||
|
data: {id, contractUrl}
|
||||||
|
});
|
||||||
|
};
|
||||||
50
src/api/common/culturalTourismSpot.js
Normal file
50
src/api/common/culturalTourismSpot.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tourism-spot/page',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tourism-spot/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tourism-spot/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tourism-spot/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tourism-spot/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
50
src/api/common/merchantFlagshipStore.js
Normal file
50
src/api/common/merchantFlagshipStore.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/merchant-store/page',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/merchant-store/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/merchant-store/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/merchant-store/save',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/merchant-store/update',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
50
src/api/common/newsCategory.js
Normal file
50
src/api/common/newsCategory.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-category/list',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-category/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-category/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-category/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-category/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
50
src/api/common/newsContent.js
Normal file
50
src/api/common/newsContent.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-content/page',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-content/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-content/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-content/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/news-content/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
50
src/api/common/tourProduct.js
Normal file
50
src/api/common/tourProduct.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-product/list',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-product/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-product/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-product/save',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/common/tour-product/update',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
50
src/api/mall/directMall.js
Normal file
50
src/api/mall/directMall.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/directMall/page',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/directMall/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/directMall/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/directMall/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/directMall/update',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
50
src/api/mall/ecosystemProduct.js
Normal file
50
src/api/mall/ecosystemProduct.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import request from '@/axios';
|
||||||
|
|
||||||
|
export const getList = (current, size, params) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/ecosystemProduct/page',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
...params,
|
||||||
|
current,
|
||||||
|
size,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getDetail = (id) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/ecosystemProduct/detail',
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const remove = (ids) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/ecosystemProduct/remove',
|
||||||
|
method: 'post',
|
||||||
|
params: {
|
||||||
|
ids,
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const add = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/ecosystemProduct/submit',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const update = (row) => {
|
||||||
|
return request({
|
||||||
|
url: '/mall/ecosystemProduct/update',
|
||||||
|
method: 'post',
|
||||||
|
data: row
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
268
src/option/common/commonUserTourOrder.js
Normal file
268
src/option/common/commonUserTourOrder.js
Normal file
@@ -0,0 +1,268 @@
|
|||||||
|
export default {
|
||||||
|
height:'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
addBtn: false,
|
||||||
|
editBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
viewBtn: false,
|
||||||
|
selection: true,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "订单号",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
search: true,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "下单账号",
|
||||||
|
prop: "account",
|
||||||
|
type: "input",
|
||||||
|
search: true,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "电话",
|
||||||
|
prop: "consigneePhone",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "收件人",
|
||||||
|
prop: "consignee",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "订单类型",
|
||||||
|
prop: "orderType",
|
||||||
|
type: "input",
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "商品编号",
|
||||||
|
prop: "itemCode",
|
||||||
|
type: "input",
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "商品名称",
|
||||||
|
prop: "itemName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "图片",
|
||||||
|
prop: "imageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-img',
|
||||||
|
dataType: 'string',
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "数量",
|
||||||
|
prop: "quantity",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "订单号",
|
||||||
|
prop: "orderDetailId",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "出行人详情",
|
||||||
|
prop: "travelerDetail",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "商品详情",
|
||||||
|
prop: "productSnapshot",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "电子合同",
|
||||||
|
prop: "contractUrl",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "是否签合同",
|
||||||
|
prop: "contractStatus",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
width: "120",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "导游名",
|
||||||
|
prop: "guideName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "导游电话",
|
||||||
|
prop: "guidePhone",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "出行开始时间",
|
||||||
|
prop: "tourStartDate",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "出行结束时间",
|
||||||
|
prop: "tourEndDate",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
width: "120",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "备注",
|
||||||
|
prop: "remark",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "订单状态",
|
||||||
|
prop: "orderStatus",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_order_status',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
search: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "订单金额",
|
||||||
|
prop: "totalAmount",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "实际支付",
|
||||||
|
prop: "actualAmount",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "支付方式",
|
||||||
|
prop: "paymentType",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_pay_type',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
search: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "支付时间",
|
||||||
|
prop: "paymentTime",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "支付状态",
|
||||||
|
prop: "paymentStatus",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_pay_status',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
search: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "下单时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "下单时间",
|
||||||
|
prop: "searchDateRange", // 关键点:这个prop将绑定一个数组
|
||||||
|
type: 'datetimerange',
|
||||||
|
format: 'YYYY-MM-DD hh:mm:ss',
|
||||||
|
valueFormat: 'YYYY-MM-DD hh:mm:ss',
|
||||||
|
search: true,
|
||||||
|
searchRange: true,
|
||||||
|
hide: true,
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
187
src/option/common/culturalTourismSpot.js
Normal file
187
src/option/common/culturalTourismSpot.js
Normal file
@@ -0,0 +1,187 @@
|
|||||||
|
export default {
|
||||||
|
height:'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
addBtn: true,
|
||||||
|
editBtn: true,
|
||||||
|
selection: false,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键ID,自增bigint",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "景点名称",
|
||||||
|
prop: "spotName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "评分",
|
||||||
|
prop: "rating",
|
||||||
|
type: "number",
|
||||||
|
value: 5.0,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "出行人数",
|
||||||
|
prop: "visitCount",
|
||||||
|
type: "number",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "缩略图",
|
||||||
|
prop: "thumbnailUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
dataType: 'string',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "主图",
|
||||||
|
prop: "mainImageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "详情图",
|
||||||
|
prop: "detailImages",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "宣传视频",
|
||||||
|
prop: "videoUrl",
|
||||||
|
type: "upload",
|
||||||
|
dataType: 'string',
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "是否推荐",
|
||||||
|
prop: "isRecommended",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 0,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "简短摘要",
|
||||||
|
prop: "summary",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "详细介绍",
|
||||||
|
prop: "description",
|
||||||
|
type: "textarea",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
240
src/option/common/merchantFlagshipStore.js
Normal file
240
src/option/common/merchantFlagshipStore.js
Normal file
@@ -0,0 +1,240 @@
|
|||||||
|
export default {
|
||||||
|
height:'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
selection: false,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键 ID",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "店铺名字",
|
||||||
|
prop: "storeName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "联系电话",
|
||||||
|
prop: "contactPhone",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "缩略图",
|
||||||
|
prop: "thumbnailUrl",
|
||||||
|
type: "upload",
|
||||||
|
dataType: 'string',
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "主图",
|
||||||
|
prop: "mainImageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "详情图",
|
||||||
|
prop: "detailImages",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "营业时间",
|
||||||
|
prop: "businessHours",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "商家详细",
|
||||||
|
prop: "storeDescription",
|
||||||
|
type: "textarea",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '省份',
|
||||||
|
prop: 'province',
|
||||||
|
type: 'select',
|
||||||
|
hide: true,
|
||||||
|
props: {
|
||||||
|
label: 'name',
|
||||||
|
value: 'code'
|
||||||
|
},
|
||||||
|
cascader: ['city'],
|
||||||
|
dicUrl: `/common/region/selectProvinceAndCity/1`,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请选择省份',
|
||||||
|
trigger: 'blur'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '城市',
|
||||||
|
prop: 'city',
|
||||||
|
type: 'select',
|
||||||
|
hide: true,
|
||||||
|
cascader:['area'],
|
||||||
|
props: {
|
||||||
|
label: 'name',
|
||||||
|
value: 'code'
|
||||||
|
},
|
||||||
|
dicUrl: `/common/region/selectProvinceAndCity/{{province}}`,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请选择城市',
|
||||||
|
trigger: 'blur'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '地区',
|
||||||
|
prop: 'area',
|
||||||
|
type: 'select',
|
||||||
|
hide: true,
|
||||||
|
props: {
|
||||||
|
label: 'name',
|
||||||
|
value: 'code'
|
||||||
|
},
|
||||||
|
dicUrl: `/common/region/selectProvinceAndCity/{{city}}`,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请选择地区',
|
||||||
|
trigger: 'blur'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "详细地址",
|
||||||
|
prop: "fullAddress",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "详细地址",
|
||||||
|
prop: "addressDetail",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
hide: true,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请填写详细地址',
|
||||||
|
trigger: 'blur'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
111
src/option/common/newsCategory.js
Normal file
111
src/option/common/newsCategory.js
Normal file
@@ -0,0 +1,111 @@
|
|||||||
|
export default {
|
||||||
|
height:'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
addBtn: true,
|
||||||
|
editBtn: true,
|
||||||
|
selection: false,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键ID",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "分类名称",
|
||||||
|
prop: "categoryName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "排序",
|
||||||
|
prop: "sortOrder",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否置顶",
|
||||||
|
prop: "isTop",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
221
src/option/common/newsContent.js
Normal file
221
src/option/common/newsContent.js
Normal file
@@ -0,0 +1,221 @@
|
|||||||
|
export default {
|
||||||
|
height:'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
addBtn: true,
|
||||||
|
editBtn: true,
|
||||||
|
selection: false,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键ID",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "资讯标题",
|
||||||
|
prop: "title",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "简短摘要",
|
||||||
|
prop: "summary",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "内容类型",
|
||||||
|
prop: "contentType",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_news_type',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 0,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "所属分类",
|
||||||
|
prop: "categoryId",
|
||||||
|
type: 'select',
|
||||||
|
dicUrl: '/common/news-category/dictionary',
|
||||||
|
props: {
|
||||||
|
label: 'categoryName',
|
||||||
|
value: 'id'
|
||||||
|
},
|
||||||
|
dataType: 'string',
|
||||||
|
search: true,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "视频",
|
||||||
|
prop: "videoUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
dataType: 'string',
|
||||||
|
multiple: false,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "视频播放次数",
|
||||||
|
prop: "playCount",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "缩略图",
|
||||||
|
prop: "thumbnailUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
dataType: 'string',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "主图",
|
||||||
|
prop: "mainImageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
},
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "详情图",
|
||||||
|
prop: "detailImages",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
},
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "正文内容",
|
||||||
|
prop: "articleContent",
|
||||||
|
type: "textarea",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "评论数量",
|
||||||
|
prop: "commentCount",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否置顶",
|
||||||
|
prop: "isFeatured",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 0,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "排序",
|
||||||
|
prop: "sortOrder",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "浏览次数",
|
||||||
|
prop: "viewCount",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态 0=下架,1=上架",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
308
src/option/common/tourProduct.js
Normal file
308
src/option/common/tourProduct.js
Normal file
@@ -0,0 +1,308 @@
|
|||||||
|
export default {
|
||||||
|
height:'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
addBtn: true,
|
||||||
|
editBtn: true,
|
||||||
|
selection: false,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键ID",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "产品名称",
|
||||||
|
prop: "productName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "副标题/亮点",
|
||||||
|
prop: "subTitle",
|
||||||
|
type: "input",
|
||||||
|
width : 120,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "缩略图",
|
||||||
|
prop: "thumbnailUrl",
|
||||||
|
type: "upload",
|
||||||
|
dataType: 'string',
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "主图",
|
||||||
|
prop: "mainImageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "详情图",
|
||||||
|
prop: "detailImages",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "目的地",
|
||||||
|
prop: "cityName",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "行程天数",
|
||||||
|
prop: "durationDays",
|
||||||
|
type: "number",
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "住宿晚数",
|
||||||
|
prop: "durationNights",
|
||||||
|
type: "number",
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "起售价",
|
||||||
|
prop: "basePrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "成人单价",
|
||||||
|
prop: "adultPrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "儿童单价",
|
||||||
|
prop: "childPrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "老年人单价",
|
||||||
|
prop: "elderlyPrice",
|
||||||
|
type: "input",
|
||||||
|
width: 120,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "最小成团人数",
|
||||||
|
prop: "minPeople",
|
||||||
|
type: "number",
|
||||||
|
width: 120,
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "最大接待人数",
|
||||||
|
prop: "maxPeople",
|
||||||
|
type: "number",
|
||||||
|
width: 120,
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "是否推荐",
|
||||||
|
prop: "isRecommended",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 0,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "是否填身份证",
|
||||||
|
prop: "requireIdCard",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 1,
|
||||||
|
width: 160,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否填护照",
|
||||||
|
prop: "requirePassport",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 0,
|
||||||
|
width: 160,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否填港澳通行证",
|
||||||
|
prop: "requireHkMacauPass",
|
||||||
|
type: 'radio',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_yes_no',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey',
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
value : 0,
|
||||||
|
width: 160,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "产品详情",
|
||||||
|
prop: "description",
|
||||||
|
type: "input",
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "销量",
|
||||||
|
prop: "visitCount",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "评分",
|
||||||
|
prop: "rating",
|
||||||
|
type: "number",
|
||||||
|
value: 5.0,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '省份',
|
||||||
|
prop: 'province',
|
||||||
|
type: 'select',
|
||||||
|
hide: true,
|
||||||
|
props: {
|
||||||
|
label: 'name',
|
||||||
|
value: 'code'
|
||||||
|
},
|
||||||
|
cascader: ['city'],
|
||||||
|
dicUrl: `/common/region/selectProvinceAndCity/1`,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请选择省份',
|
||||||
|
trigger: 'blur'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '城市',
|
||||||
|
prop: 'city',
|
||||||
|
type: 'select',
|
||||||
|
hide: true,
|
||||||
|
props: {
|
||||||
|
label: 'name',
|
||||||
|
value: 'code'
|
||||||
|
},
|
||||||
|
dicUrl: `/common/region/selectProvinceAndCity/{{province}}`,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请选择城市',
|
||||||
|
trigger: 'blur'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: "创建人ID",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门ID",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人ID",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态:0=下架,1=上架",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除:0=未删除,1=已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
219
src/option/mall/directMall.js
Normal file
219
src/option/mall/directMall.js
Normal file
@@ -0,0 +1,219 @@
|
|||||||
|
export default {
|
||||||
|
height: 'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
selection: true,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "编码",
|
||||||
|
prop: "serialNumber",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "名称",
|
||||||
|
prop: "productName",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "缩略图",
|
||||||
|
prop: "thumbImageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-img',
|
||||||
|
dataType: 'string',
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "主图",
|
||||||
|
prop: "mainImageUrls",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "详情图",
|
||||||
|
prop: "detailImageUrls",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "规格",
|
||||||
|
prop: "specs",
|
||||||
|
type: "dynamic",
|
||||||
|
span: 24,
|
||||||
|
children:{
|
||||||
|
rowAdd: (done)=>{
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
rowDel: (row, done) => {
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "名称",
|
||||||
|
prop: "attr",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "值",
|
||||||
|
prop: "value",
|
||||||
|
}
|
||||||
|
],
|
||||||
|
},
|
||||||
|
formatter: (row, value, cellValue) => {
|
||||||
|
if (!Array.isArray(value)) return '';
|
||||||
|
return value.map(s => `${s.attr} : ${s.value}`).join('; ');
|
||||||
|
},
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "单位",
|
||||||
|
prop: "unit",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "分类",
|
||||||
|
prop: "categoryId",
|
||||||
|
type: 'select',
|
||||||
|
dicUrl: '/mall/category/dictionary',
|
||||||
|
props: {
|
||||||
|
label: 'categoryName',
|
||||||
|
value: 'id'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "分类路径",
|
||||||
|
prop: "categoryPath",
|
||||||
|
type: "input",
|
||||||
|
hide: true,
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "原价",
|
||||||
|
prop: "originalPrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "销售价",
|
||||||
|
prop: "retailPrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "销量",
|
||||||
|
prop: "sales",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "库存",
|
||||||
|
prop: "stock",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "标签",
|
||||||
|
prop: "tags",
|
||||||
|
type: "tag",
|
||||||
|
formatter: (row, value, cellValue) => {
|
||||||
|
if (!Array.isArray(value)) return '';
|
||||||
|
return value.map(s => `${s}`).join('; ');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态(0=下架,1=上架,3=删除)",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
219
src/option/mall/ecosystemProduct.js
Normal file
219
src/option/mall/ecosystemProduct.js
Normal file
@@ -0,0 +1,219 @@
|
|||||||
|
export default {
|
||||||
|
height: 'auto',
|
||||||
|
calcHeight: 30,
|
||||||
|
tip: false,
|
||||||
|
searchShow: true,
|
||||||
|
searchMenuSpan: 6,
|
||||||
|
border: true,
|
||||||
|
index: true,
|
||||||
|
viewBtn: false,
|
||||||
|
delBtn: false,
|
||||||
|
selection: true,
|
||||||
|
dialogClickModal: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "主键",
|
||||||
|
prop: "id",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "编码",
|
||||||
|
prop: "serialNumber",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "名称",
|
||||||
|
prop: "productName",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "缩略图",
|
||||||
|
prop: "thumbImageUrl",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-img',
|
||||||
|
dataType: 'string',
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "主图",
|
||||||
|
prop: "mainImageUrls",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "详情图",
|
||||||
|
prop: "detailImageUrls",
|
||||||
|
type: "upload",
|
||||||
|
listType: 'picture-card',
|
||||||
|
multiple: true,
|
||||||
|
action: '/blade-resource/oss/endpoint/put-file',
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
url: 'link'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "规格",
|
||||||
|
prop: "specs",
|
||||||
|
type: "dynamic",
|
||||||
|
span: 24,
|
||||||
|
children:{
|
||||||
|
rowAdd: (done)=>{
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
rowDel: (row, done) => {
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: "名称",
|
||||||
|
prop: "attr",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "值",
|
||||||
|
prop: "value",
|
||||||
|
}
|
||||||
|
],
|
||||||
|
},
|
||||||
|
formatter: (row, value, cellValue) => {
|
||||||
|
if (!Array.isArray(value)) return '';
|
||||||
|
return value.map(s => `${s.attr} : ${s.value}`).join('; ');
|
||||||
|
},
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "单位",
|
||||||
|
prop: "unit",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "分类",
|
||||||
|
prop: "categoryId",
|
||||||
|
type: 'select',
|
||||||
|
dicUrl: '/mall/category/dictionary',
|
||||||
|
props: {
|
||||||
|
label: 'categoryName',
|
||||||
|
value: 'id'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "分类路径",
|
||||||
|
prop: "categoryPath",
|
||||||
|
type: "input",
|
||||||
|
hide: true,
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "原价",
|
||||||
|
prop: "originalPrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "销售价",
|
||||||
|
prop: "retailPrice",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "销量",
|
||||||
|
prop: "sales",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "库存",
|
||||||
|
prop: "stock",
|
||||||
|
type: "input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "标签",
|
||||||
|
prop: "tags",
|
||||||
|
type: "tag",
|
||||||
|
formatter: (row, value, cellValue) => {
|
||||||
|
if (!Array.isArray(value)) return '';
|
||||||
|
return value.map(s => `${s}`).join('; ');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "状态(0=下架,1=上架,3=删除)",
|
||||||
|
prop: "status",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建人",
|
||||||
|
prop: "createUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建部门",
|
||||||
|
prop: "createDept",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "创建时间",
|
||||||
|
prop: "createTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改人",
|
||||||
|
prop: "updateUser",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "修改时间",
|
||||||
|
prop: "updateTime",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "是否已删除",
|
||||||
|
prop: "isDeleted",
|
||||||
|
type: "input",
|
||||||
|
addDisplay: false,
|
||||||
|
editDisplay: false,
|
||||||
|
viewDisplay: false,
|
||||||
|
hide: true,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -8,6 +8,7 @@ export default {
|
|||||||
index: true,
|
index: true,
|
||||||
viewBtn: true,
|
viewBtn: true,
|
||||||
selection: false,
|
selection: false,
|
||||||
|
delBtn: false,
|
||||||
dialogClickModal: false,
|
dialogClickModal: false,
|
||||||
column: [
|
column: [
|
||||||
{
|
{
|
||||||
|
|||||||
651
src/views/common/commonTourProductOrder.vue
Normal file
651
src/views/common/commonTourProductOrder.vue
Normal file
@@ -0,0 +1,651 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.order_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<el-button type="warning"
|
||||||
|
plain
|
||||||
|
icon="el-icon-download"
|
||||||
|
@click="openExportBox">导 出 订 单
|
||||||
|
</el-button>
|
||||||
|
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<template #menu="{ row }">
|
||||||
|
<el-button type="text"
|
||||||
|
icon="el-icon-circle-check"
|
||||||
|
v-if="row.paymentStatus === 1 && row.guidePhone === '' && row.guideName === ''"
|
||||||
|
@click.stop="openGuideInfo(row)">添加导游
|
||||||
|
</el-button>
|
||||||
|
|
||||||
|
<el-button type="text"
|
||||||
|
icon="el-icon-circle-check"
|
||||||
|
v-if="row.paymentStatus === 1 && row.contractStatus === 0 "
|
||||||
|
@click.stop="handleContractUrl(row)">添加合同
|
||||||
|
</el-button>
|
||||||
|
|
||||||
|
<el-button type="text"
|
||||||
|
icon="el-icon-circle-check"
|
||||||
|
@click.stop="openUserTourInfo(row)">出行人详情
|
||||||
|
</el-button>
|
||||||
|
|
||||||
|
<el-button type="text"
|
||||||
|
icon="el-icon-circle-check"
|
||||||
|
@click.stop="openTourProductInfo(row)">产品详情
|
||||||
|
</el-button>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
|
||||||
|
<el-dialog :title="`导出用户订单`" append-to-body v-model="exportOrderBox" width="1000px">
|
||||||
|
<avue-form
|
||||||
|
:option="exportOrderOption"
|
||||||
|
:data="exportOrderData"
|
||||||
|
v-model="exportOrderFrom"
|
||||||
|
@submit="exportOrderSubmit"
|
||||||
|
ref="stateCrud"
|
||||||
|
/>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-dialog title="批量导入补单" append-to-body v-model="excelBox" width="555px">
|
||||||
|
<avue-form :option="excelOption" v-model="excelForm" :upload-after="excelUploadAfter">
|
||||||
|
<template #excelTemplate>
|
||||||
|
<el-button type="primary" @click="handleTemplate">
|
||||||
|
点击下载<i class="el-icon-download el-icon--right"></i>
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
|
</avue-form>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-dialog :title="`添加导游信息`" append-to-body v-model="guideInfoBox" width="1000px">
|
||||||
|
<avue-form
|
||||||
|
:option="guideInfoOption"
|
||||||
|
:data="guideInfoData"
|
||||||
|
v-model="guideInfoFrom"
|
||||||
|
@submit="guideInfoSubmit"
|
||||||
|
ref="stateCrud"
|
||||||
|
/>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-drawer :title="`账户 [${userAccount}] 出行信息`" v-model="userTourInfoBox" :direction="direction" append-to-body
|
||||||
|
size="850px">
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="userTourInfoOption"
|
||||||
|
:data="userTourInfoData"
|
||||||
|
ref="crudSub"
|
||||||
|
>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</el-drawer>
|
||||||
|
|
||||||
|
<el-drawer :title="`账户 [${userAccount}] 旅游团信息`" v-model="tourProductInfoBox" :direction="direction" append-to-body
|
||||||
|
size="850px">
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="tourProductInfoOption"
|
||||||
|
:data="tourProductInfoData"
|
||||||
|
ref="crudSub"
|
||||||
|
>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</el-drawer>
|
||||||
|
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {
|
||||||
|
getTourOrderList,
|
||||||
|
getDetail,
|
||||||
|
add,
|
||||||
|
update,
|
||||||
|
remove,
|
||||||
|
confirmGuideInfo,
|
||||||
|
fillExpress,
|
||||||
|
fillContractUrl
|
||||||
|
} from '@/api/common/commonUserOrder';
|
||||||
|
import option from "@/option/common/commonUserTourOrder";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: [],
|
||||||
|
|
||||||
|
|
||||||
|
exportOrderBox: false,
|
||||||
|
exportOrderOption: {
|
||||||
|
addBtn: false,
|
||||||
|
editBtn: true,
|
||||||
|
delBtn: false,
|
||||||
|
menu: false,
|
||||||
|
labelWidth: 200,
|
||||||
|
column: [
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '用户账号',
|
||||||
|
prop: 'account',
|
||||||
|
type: 'input',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "订单状态",
|
||||||
|
prop: "orderStatus",
|
||||||
|
type: 'select',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_order_status',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "时间范围",
|
||||||
|
prop: "searchDateRange", // 关键点:这个prop将绑定一个数组
|
||||||
|
type: 'datetimerange',
|
||||||
|
format: 'YYYY-MM-DD hh:mm:ss',
|
||||||
|
valueFormat: 'YYYY-MM-DD hh:mm:ss',
|
||||||
|
searchRange: true,
|
||||||
|
rules: [
|
||||||
|
{ required: true, message: "时间范围不能为空", trigger: "blur" }
|
||||||
|
],
|
||||||
|
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
exportOrderData: '',
|
||||||
|
exportOrderFrom: {},
|
||||||
|
|
||||||
|
excelBox: false,
|
||||||
|
excelForm: {},
|
||||||
|
excelOption: {
|
||||||
|
submitBtn: false,
|
||||||
|
emptyBtn: false,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: '上传补单',
|
||||||
|
labelWidth: 200,
|
||||||
|
prop: 'excelFile',
|
||||||
|
type: 'upload',
|
||||||
|
drag: true,
|
||||||
|
loadText: '模板上传中,请稍等',
|
||||||
|
span: 24,
|
||||||
|
propsHttp: {
|
||||||
|
res: 'data',
|
||||||
|
},
|
||||||
|
tip: '请上传 .xls,.xlsx 标准格式文件',
|
||||||
|
action: '/common/order/import-user-back-order',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
guideInfoBox: false,
|
||||||
|
guideInfoOption: {
|
||||||
|
addBtn: false,
|
||||||
|
editBtn: true,
|
||||||
|
delBtn: false,
|
||||||
|
menu: false,
|
||||||
|
labelWidth: 200,
|
||||||
|
column: [
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '导游名字',
|
||||||
|
prop: 'guideName',
|
||||||
|
type: 'input',
|
||||||
|
rules: [
|
||||||
|
{ required: true, message: "导游名字不能为空", trigger: "blur" }
|
||||||
|
],
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '导游手机号',
|
||||||
|
prop: 'guidePhone',
|
||||||
|
type: 'input',
|
||||||
|
rules: [
|
||||||
|
{ required: true, message: "导游手机号不能为空", trigger: "blur" }
|
||||||
|
],
|
||||||
|
},
|
||||||
|
|
||||||
|
],
|
||||||
|
},
|
||||||
|
guideInfoData: '',
|
||||||
|
guideInfoFrom: {
|
||||||
|
orderDetailId: '',
|
||||||
|
},
|
||||||
|
|
||||||
|
userAccount : "",
|
||||||
|
|
||||||
|
direction : "rtl",
|
||||||
|
userTourInfoBox: false,
|
||||||
|
userTourInfoOption : {
|
||||||
|
addBtn: false,
|
||||||
|
editBtn: true,
|
||||||
|
delBtn: false,
|
||||||
|
menu: false,
|
||||||
|
labelWidth: 200,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: '姓名',
|
||||||
|
prop: 'userName',
|
||||||
|
type: 'input',
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '手机号',
|
||||||
|
prop: 'contactPhone',
|
||||||
|
type: 'input',
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '身份证',
|
||||||
|
prop: 'idCardNo',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '护照',
|
||||||
|
prop: 'passportNo',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '港澳通行证号码',
|
||||||
|
prop: 'hkMacauPassNo',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '备注偏好',
|
||||||
|
prop: 'remark',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
],
|
||||||
|
},
|
||||||
|
userTourInfoData : [],
|
||||||
|
|
||||||
|
tourProductInfoBox: false,
|
||||||
|
tourProductInfoOption : {
|
||||||
|
addBtn: false,
|
||||||
|
editBtn: true,
|
||||||
|
delBtn: false,
|
||||||
|
menu: false,
|
||||||
|
labelWidth: 200,
|
||||||
|
column: [
|
||||||
|
{
|
||||||
|
label: '产品名',
|
||||||
|
prop: 'productName',
|
||||||
|
type: 'input',
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '标题',
|
||||||
|
prop: 'subTitle',
|
||||||
|
type: 'input',
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '略缩图',
|
||||||
|
prop: 'thumbnailUrl',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
overHidden: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '基础价',
|
||||||
|
prop: 'basePrice',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
label: '成人价',
|
||||||
|
prop: 'adultPrice',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '儿童价',
|
||||||
|
prop: 'childPrice',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '老年价',
|
||||||
|
prop: 'elderlyPrice',
|
||||||
|
type: 'input',
|
||||||
|
width : 140,
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
],
|
||||||
|
},
|
||||||
|
tourProductInfoData : [],
|
||||||
|
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.order_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.order_view, false),
|
||||||
|
delBtn: this.validData(this.permission.order_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.order_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/user-order/order/export-order?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `用户订单${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
getTourOrderList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
openExportBox(){
|
||||||
|
this.exportOrderBox = true;
|
||||||
|
},
|
||||||
|
|
||||||
|
exportOrderSubmit(form, done){
|
||||||
|
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(
|
||||||
|
`/common/order/export-tour-order-to-excel?${
|
||||||
|
this.website.tokenHeader
|
||||||
|
}=${getToken()}&orderStatus=${form.orderStatus != null ? form.orderStatus : ''}&searchDateRange=${form.searchDateRange}&account=${form.account != null ? form.account : ''}`
|
||||||
|
).then(res => {
|
||||||
|
console.log("打印:" , res)
|
||||||
|
downloadXls(res.data, `用户订单表${this.$dayjs().format('YYYY-MM-DD')}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
done();
|
||||||
|
this.exportOrderBox = false;
|
||||||
|
},
|
||||||
|
|
||||||
|
openImportOrderBox(){
|
||||||
|
this.excelBox = true;
|
||||||
|
},
|
||||||
|
|
||||||
|
excelUploadAfter(res, done, loading, column) {
|
||||||
|
window.console.log(column);
|
||||||
|
|
||||||
|
if (res.length) {
|
||||||
|
const errMsg = res
|
||||||
|
.map(
|
||||||
|
(item, idx) =>
|
||||||
|
`${idx + 1}. ${item.errorMsg} 订单号: ${item.orderNo} 金额: ${item.amount}`
|
||||||
|
)
|
||||||
|
.join('<br><br>');
|
||||||
|
|
||||||
|
this.$alert(errMsg, '导入失败', {
|
||||||
|
confirmButtonText: '我知道了',
|
||||||
|
type: 'error',
|
||||||
|
dangerouslyUseHTMLString: true, //
|
||||||
|
customClass: 'alert-error-list', //
|
||||||
|
});
|
||||||
|
}
|
||||||
|
this.excelBox = false;
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
|
||||||
|
openGuideInfo(row){
|
||||||
|
this.guideInfoBox = true;
|
||||||
|
this.guideInfoFrom.orderDetailId = row.orderDetailId;
|
||||||
|
},
|
||||||
|
|
||||||
|
guideInfoSubmit(form, done){
|
||||||
|
|
||||||
|
const data = {
|
||||||
|
id: form.orderDetailId,
|
||||||
|
guideName: form.guideName,
|
||||||
|
guidePhone: form.guidePhone,
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
confirmGuideInfo(data).then(
|
||||||
|
() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: 'success',
|
||||||
|
message: '操作成功!',
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
this.guideInfoBox = false;
|
||||||
|
this.guideInfoFrom = {
|
||||||
|
orderDetailId: '',
|
||||||
|
guideName: '',
|
||||||
|
guidePhone: '',
|
||||||
|
|
||||||
|
};
|
||||||
|
},
|
||||||
|
error => {
|
||||||
|
done();
|
||||||
|
this.guideInfoBox = false;
|
||||||
|
console.log(error);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
},
|
||||||
|
|
||||||
|
handleContractUrl(row) {
|
||||||
|
this.$prompt('请输入合同连接', '合同信息', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
inputPlaceholder: '例如:https://qian.tencent.com',
|
||||||
|
// inputPattern: /^[a-zA-Z0-9]{8,20}$/, // 可选:正则校验
|
||||||
|
// inputErrorMessage: '快递单号格式不正确'
|
||||||
|
}).then(({ value }) => {
|
||||||
|
fillContractUrl(row.orderDetailId, value)
|
||||||
|
// 用户点击“确定”
|
||||||
|
console.log('用户输入:', value);
|
||||||
|
// 在这里处理你的逻辑,比如调用 API
|
||||||
|
}).catch(() => {
|
||||||
|
// 用户点击“取消”或关闭弹窗
|
||||||
|
this.$message.info('已取消输入');
|
||||||
|
});
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
openUserTourInfo(row){
|
||||||
|
this.userTourInfoBox = true;
|
||||||
|
this.userAccount = row.account;
|
||||||
|
this.userTourInfoData = row.travelerDetail;
|
||||||
|
},
|
||||||
|
|
||||||
|
openTourProductInfo(row){
|
||||||
|
this.tourProductInfoBox = true;
|
||||||
|
this.userAccount = row.account;
|
||||||
|
this.tourProductInfoData = row.productSnapshot;
|
||||||
|
},
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
@@ -116,13 +116,23 @@ import {getList, getDetail, add, update, remove, confirmPayment, fillExpress} fr
|
|||||||
menu: false,
|
menu: false,
|
||||||
labelWidth: 200,
|
labelWidth: 200,
|
||||||
column: [
|
column: [
|
||||||
|
|
||||||
{
|
{
|
||||||
label: '账号',
|
label: '用户账号',
|
||||||
prop: 'account',
|
prop: 'account',
|
||||||
type: 'input',
|
type: 'input',
|
||||||
rules: [
|
},
|
||||||
{ required: true, message: "账号不能为空", trigger: "blur" }
|
{
|
||||||
],
|
label: "订单状态",
|
||||||
|
prop: "orderStatus",
|
||||||
|
type: 'select',
|
||||||
|
dicUrl: '/blade-system/dict/dictionary?code=app_order_status',
|
||||||
|
props: {
|
||||||
|
label: 'dictValue',
|
||||||
|
value: 'dictKey'
|
||||||
|
},
|
||||||
|
dataType: 'number',
|
||||||
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "时间范围",
|
label: "时间范围",
|
||||||
@@ -353,11 +363,12 @@ import {getList, getDetail, add, update, remove, confirmPayment, fillExpress} fr
|
|||||||
},
|
},
|
||||||
|
|
||||||
exportOrderSubmit(form, done){
|
exportOrderSubmit(form, done){
|
||||||
|
|
||||||
NProgress.start();
|
NProgress.start();
|
||||||
exportBlob(
|
exportBlob(
|
||||||
`/common/order/export-order-to-excel?${
|
`/common/order/export-order-to-excel?${
|
||||||
this.website.tokenHeader
|
this.website.tokenHeader
|
||||||
}=${getToken()}&account=${form.account}&searchDateRange=${form.searchDateRange}`
|
}=${getToken()}&orderStatus=${form.orderStatus != null ? form.orderStatus : ''}&searchDateRange=${form.searchDateRange}&account=${form.account != null ? form.account : ''}`
|
||||||
).then(res => {
|
).then(res => {
|
||||||
console.log("打印:" , res)
|
console.log("打印:" , res)
|
||||||
downloadXls(res.data, `用户订单表${this.$dayjs().format('YYYY-MM-DD')}.xlsx`);
|
downloadXls(res.data, `用户订单表${this.$dayjs().format('YYYY-MM-DD')}.xlsx`);
|
||||||
|
|||||||
225
src/views/common/culturalTourismSpot.vue
Normal file
225
src/views/common/culturalTourismSpot.vue
Normal file
@@ -0,0 +1,225 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.culturalTourismSpot_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/common/culturalTourismSpot";
|
||||||
|
import option from "@/option/common/culturalTourismSpot";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.culturalTourismSpot_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.culturalTourismSpot_view, false),
|
||||||
|
delBtn: this.validData(this.permission.culturalTourismSpot_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.culturalTourismSpot_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/common/tourism-spot/culturalTourismSpot/export-culturalTourismSpot?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `文旅景点信息${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
226
src/views/common/merchantFlagshipStore.vue
Normal file
226
src/views/common/merchantFlagshipStore.vue
Normal file
@@ -0,0 +1,226 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.merchantFlagshipStore_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/common/merchantFlagshipStore";
|
||||||
|
import option from "@/option/common/merchantFlagshipStore";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.merchantFlagshipStore_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.merchantFlagshipStore_view, false),
|
||||||
|
delBtn: this.validData(this.permission.merchantFlagshipStore_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.merchantFlagshipStore_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/common/merchant-store/merchantFlagshipStore/export-merchantFlagshipStore?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `商家旗舰店信息${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
225
src/views/common/newsCategory.vue
Normal file
225
src/views/common/newsCategory.vue
Normal file
@@ -0,0 +1,225 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.newsCategory_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/common/newsCategory";
|
||||||
|
import option from "@/option/common/newsCategory";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.newsCategory_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.newsCategory_view, false),
|
||||||
|
delBtn: this.validData(this.permission.newsCategory_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.newsCategory_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/common/news-category/newsCategory/export-newsCategory?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `资讯分类${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
263
src/views/common/newsContent.vue
Normal file
263
src/views/common/newsContent.vue
Normal file
@@ -0,0 +1,263 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.newsContent_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/common/newsContent";
|
||||||
|
import option from "@/option/common/newsContent";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
|
||||||
|
watch: {
|
||||||
|
'form.contentType'(val) {
|
||||||
|
let videoUrl = this.findObject(this.option.column, "videoUrl");
|
||||||
|
let playCount = this.findObject(this.option.column, "playCount");
|
||||||
|
|
||||||
|
let thumbnailUrl = this.findObject(this.option.column, "thumbnailUrl");
|
||||||
|
let mainImageUrl = this.findObject(this.option.column, "mainImageUrl");
|
||||||
|
let detailImages = this.findObject(this.option.column, "detailImages");
|
||||||
|
let articleContent = this.findObject(this.option.column, "articleContent");
|
||||||
|
let viewCount = this.findObject(this.option.column, "viewCount");
|
||||||
|
if (val === 0) {
|
||||||
|
videoUrl.display = false;
|
||||||
|
this.form.videoUrl = ""
|
||||||
|
playCount.display = false;
|
||||||
|
|
||||||
|
thumbnailUrl.display = true;
|
||||||
|
mainImageUrl.display = true;
|
||||||
|
detailImages.display = true;
|
||||||
|
articleContent.display = true;
|
||||||
|
viewCount.display = true;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
if (val === 1) {
|
||||||
|
videoUrl.display = true;
|
||||||
|
this.form.videoUrl = ""
|
||||||
|
playCount.display = true;
|
||||||
|
|
||||||
|
thumbnailUrl.display = false;
|
||||||
|
mainImageUrl.display = false;
|
||||||
|
detailImages.display = false;
|
||||||
|
articleContent.display = false;
|
||||||
|
viewCount.display = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.newsContent_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.newsContent_view, false),
|
||||||
|
delBtn: this.validData(this.permission.newsContent_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.newsContent_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/common/news-content/newsContent/export-newsContent?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `资讯内容${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
225
src/views/common/tourProduct.vue
Normal file
225
src/views/common/tourProduct.vue
Normal file
@@ -0,0 +1,225 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.tourProduct_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/common/tourProduct";
|
||||||
|
import option from "@/option/common/tourProduct";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.tourProduct_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.tourProduct_view, false),
|
||||||
|
delBtn: this.validData(this.permission.tourProduct_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.tourProduct_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/common/tour-product/tourProduct/export-tourProduct?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `旅游产品${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
225
src/views/mall/directMall.vue
Normal file
225
src/views/mall/directMall.vue
Normal file
@@ -0,0 +1,225 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.mallProduct_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/mall/directMall";
|
||||||
|
import option from "@/option/mall/directMall";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.mallProduct_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.mallProduct_view, false),
|
||||||
|
delBtn: this.validData(this.permission.mallProduct_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.mallProduct_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/blade-mallproduct/mallProduct/export-mallProduct?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `商城商品${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
225
src/views/mall/ecosystemProduct.vue
Normal file
225
src/views/mall/ecosystemProduct.vue
Normal file
@@ -0,0 +1,225 @@
|
|||||||
|
<template>
|
||||||
|
<basic-container>
|
||||||
|
<avue-crud :option="option"
|
||||||
|
v-model:search="search"
|
||||||
|
v-model:page="page"
|
||||||
|
v-model="form"
|
||||||
|
:table-loading="loading"
|
||||||
|
:data="data"
|
||||||
|
:permission="permissionList"
|
||||||
|
:before-open="beforeOpen"
|
||||||
|
ref="crud"
|
||||||
|
@row-update="rowUpdate"
|
||||||
|
@row-save="rowSave"
|
||||||
|
@row-del="rowDel"
|
||||||
|
@search-change="searchChange"
|
||||||
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
|
@current-change="currentChange"
|
||||||
|
@size-change="sizeChange"
|
||||||
|
@refresh-change="refreshChange"
|
||||||
|
@on-load="onLoad">
|
||||||
|
<template #menu-left>
|
||||||
|
<!-- <el-button type="danger"-->
|
||||||
|
<!-- icon="el-icon-delete"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- v-if="permission.mallProduct_delete"-->
|
||||||
|
<!-- @click="handleDelete">删 除-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
<!-- <el-button type="warning"-->
|
||||||
|
<!-- plain-->
|
||||||
|
<!-- icon="el-icon-download"-->
|
||||||
|
<!-- @click="handleExport">导 出-->
|
||||||
|
<!-- </el-button>-->
|
||||||
|
</template>
|
||||||
|
</avue-crud>
|
||||||
|
</basic-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getList, getDetail, add, update, remove} from "@/api/mall/ecosystemProduct";
|
||||||
|
import option from "@/option/mall/ecosystemProduct";
|
||||||
|
import {mapGetters} from "vuex";
|
||||||
|
import {exportBlob} from "@/api/common";
|
||||||
|
import {getToken} from '@/utils/auth';
|
||||||
|
import {downloadXls} from "@/utils/util";
|
||||||
|
import {dateNow} from "@/utils/date";
|
||||||
|
import NProgress from 'nprogress';
|
||||||
|
import 'nprogress/nprogress.css';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {},
|
||||||
|
query: {},
|
||||||
|
search: {},
|
||||||
|
loading: true,
|
||||||
|
page: {
|
||||||
|
pageSize: 10,
|
||||||
|
currentPage: 1,
|
||||||
|
total: 0
|
||||||
|
},
|
||||||
|
selectionList: [],
|
||||||
|
option: option,
|
||||||
|
data: []
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters(["permission"]),
|
||||||
|
permissionList() {
|
||||||
|
return {
|
||||||
|
addBtn: this.validData(this.permission.mallProduct_add, false),
|
||||||
|
viewBtn: this.validData(this.permission.mallProduct_view, false),
|
||||||
|
delBtn: this.validData(this.permission.mallProduct_delete, false),
|
||||||
|
editBtn: this.validData(this.permission.mallProduct_edit, false)
|
||||||
|
};
|
||||||
|
},
|
||||||
|
ids() {
|
||||||
|
let ids = [];
|
||||||
|
this.selectionList.forEach(ele => {
|
||||||
|
ids.push(ele.id);
|
||||||
|
});
|
||||||
|
return ids.join(",");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
rowSave(row, done, loading) {
|
||||||
|
add(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
window.console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowUpdate(row, index, done, loading) {
|
||||||
|
update(row).then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
done();
|
||||||
|
}, error => {
|
||||||
|
loading();
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
rowDel(row) {
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(row.id);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleDelete() {
|
||||||
|
if (this.selectionList.length === 0) {
|
||||||
|
this.$message.warning("请选择至少一条数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.$confirm("确定将选择数据删除?", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
return remove(this.ids);
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
this.onLoad(this.page);
|
||||||
|
this.$message({
|
||||||
|
type: "success",
|
||||||
|
message: "操作成功!"
|
||||||
|
});
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handleExport() {
|
||||||
|
let downloadUrl = `/blade-mallproduct/mallProduct/export-mallProduct?${this.website.tokenHeader}=${getToken()}`;
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
this.$confirm("是否导出数据?", "提示", {
|
||||||
|
confirmButtonText: "确定",
|
||||||
|
cancelButtonText: "取消",
|
||||||
|
type: "warning"
|
||||||
|
}).then(() => {
|
||||||
|
NProgress.start();
|
||||||
|
exportBlob(downloadUrl, values).then(res => {
|
||||||
|
downloadXls(res.data, `商城商品${dateNow()}.xlsx`);
|
||||||
|
NProgress.done();
|
||||||
|
})
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeOpen(done, type) {
|
||||||
|
if (["edit", "view"].includes(type)) {
|
||||||
|
getDetail(this.form.id).then(res => {
|
||||||
|
this.form = res.data.data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
searchReset() {
|
||||||
|
this.query = {};
|
||||||
|
this.onLoad(this.page);
|
||||||
|
},
|
||||||
|
searchChange(params, done) {
|
||||||
|
this.query = params;
|
||||||
|
this.page.currentPage = 1;
|
||||||
|
this.onLoad(this.page, params);
|
||||||
|
done();
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
|
},
|
||||||
|
selectionClear() {
|
||||||
|
this.selectionList = [];
|
||||||
|
this.$refs.crud.toggleSelection();
|
||||||
|
},
|
||||||
|
currentChange(currentPage){
|
||||||
|
this.page.currentPage = currentPage;
|
||||||
|
},
|
||||||
|
sizeChange(pageSize){
|
||||||
|
this.page.pageSize = pageSize;
|
||||||
|
},
|
||||||
|
refreshChange() {
|
||||||
|
this.onLoad(this.page, this.query);
|
||||||
|
},
|
||||||
|
onLoad(page, params = {}) {
|
||||||
|
this.loading = true;
|
||||||
|
|
||||||
|
const {
|
||||||
|
} = this.query;
|
||||||
|
|
||||||
|
let values = {
|
||||||
|
};
|
||||||
|
|
||||||
|
getList(page.currentPage, page.pageSize, values).then(res => {
|
||||||
|
const data = res.data.data;
|
||||||
|
this.page.total = data.total;
|
||||||
|
this.data = data.records;
|
||||||
|
this.loading = false;
|
||||||
|
this.selectionClear();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
@@ -372,6 +372,16 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
allocatePackageSubmit(form, done) {
|
allocatePackageSubmit(form, done) {
|
||||||
|
|
||||||
|
console.log("备注长度:",form.remark.length);
|
||||||
|
if (form.remark.length < 5){
|
||||||
|
this.$message({
|
||||||
|
type: 'warning',
|
||||||
|
message: '备注不少于5个字',
|
||||||
|
});
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
const data = {
|
const data = {
|
||||||
packId: form.packId,
|
packId: form.packId,
|
||||||
phone: form.userPhone,
|
phone: form.userPhone,
|
||||||
|
|||||||
Reference in New Issue
Block a user