cashier_app/commons/goodsData.js

86 lines
1.2 KiB
JavaScript

import dayjs from "dayjs";
export const $types = [{
title: "计量商品",
desc: '单价购买',
value: 'normal'
},
{
title: "多规格",
desc: '多种不同规格',
value: 'sku'
},
{
title: "套餐组合",
desc: '选择多种组合',
value: 'group'
},
{
title: "称重商品",
desc: '按重量售卖',
value: 'weight'
},
{
title: "时价商品",
desc: '收银端可更改价格',
value: 'currentPrice'
}
]
// 商品默认sku
export const $defaultSku = {
originPrice: '',
costPrice: '',
salePrice: '',
memberPrice: '',
suitNum: '',
barCode: `${uni.getStorageSync("shopId")}${dayjs().valueOf()}`,
}
// 库存记录筛选类型
export const $invoicingType = [{
text: '全部',
value: ''
},
{
text: '手动入库',
value: 'manual-in'
},
{
text: '手动出库',
value: 'manual-out'
},
{
text: '盘盈入库',
value: 'win-in'
},
{
text: '盘亏出库',
value: 'loss-out'
},
{
text: '订单退款入库',
value: 'other-out'
},
{
text: '订单消费出库',
value: 'order-out'
},
{
text: '损耗出库',
value: 'damage-out'
}
]
// 页面常用数据
export const $pageData = {
query: {
page: 0,
size: 10
},
totalElements: 0,
list: [],
hasAjax: false,
}