商店:一般购物流程

This commit is contained in:
luying
2021-03-31 17:52:34 +08:00
parent e487d07bfd
commit 8c8adacfdc
21 changed files with 1631 additions and 327 deletions
+26
View File
@@ -0,0 +1,26 @@
// 商店表
import { readJsonFile, parseNumberList } from '../util'
import { FILENAME } from '../../consts'
export interface DicShopList {
// 商店id
readonly shopid: number;
// 商店名
readonly shopname: number;
// 商店内标签,小分类
readonly type: number[];
// 使用的货币
readonly money: number[];
}
const str = readJsonFile(FILENAME.DIC_SHOP_LIST);
let arr = JSON.parse(str);
export const dicShopList = new Map<number, DicShopList>();
arr.forEach(o => {
o.type = parseNumberList(o.typeid);
o.money = parseNumberList(o.moneyid);
dicShopList.set(o.shopid, o);
});