处理订单
This commit is contained in:
153
unpackage/dist/dev/mp-weixin/pages/order/index.js
vendored
153
unpackage/dist/dev/mp-weixin/pages/order/index.js
vendored
@@ -5,15 +5,17 @@ if (!Array) {
|
||||
const _easycom_nut_tabs2 = common_vendor.resolveComponent("nut-tabs");
|
||||
const _easycom_nut_sticky2 = common_vendor.resolveComponent("nut-sticky");
|
||||
const _easycom_nut_tag2 = common_vendor.resolveComponent("nut-tag");
|
||||
const _easycom_nut_price2 = common_vendor.resolveComponent("nut-price");
|
||||
const _easycom_z_paging2 = common_vendor.resolveComponent("z-paging");
|
||||
(_easycom_nut_tabs2 + _easycom_nut_sticky2 + _easycom_nut_tag2 + _easycom_z_paging2)();
|
||||
(_easycom_nut_tabs2 + _easycom_nut_sticky2 + _easycom_nut_tag2 + _easycom_nut_price2 + _easycom_z_paging2)();
|
||||
}
|
||||
const _easycom_nut_tabs = () => "../../uni_modules/nutui-uni/components/tabs/tabs.js";
|
||||
const _easycom_nut_sticky = () => "../../uni_modules/nutui-uni/components/sticky/sticky.js";
|
||||
const _easycom_nut_tag = () => "../../uni_modules/nutui-uni/components/tag/tag.js";
|
||||
const _easycom_nut_price = () => "../../uni_modules/nutui-uni/components/price/price.js";
|
||||
const _easycom_z_paging = () => "../../uni_modules/z-paging/components/z-paging/z-paging.js";
|
||||
if (!Math) {
|
||||
(_easycom_nut_tabs + _easycom_nut_sticky + _easycom_nut_tag + _easycom_z_paging)();
|
||||
(_easycom_nut_tabs + _easycom_nut_sticky + _easycom_nut_tag + _easycom_nut_price + _easycom_z_paging)();
|
||||
}
|
||||
const _sfc_main = {
|
||||
__name: "index",
|
||||
@@ -39,34 +41,19 @@ const _sfc_main = {
|
||||
];
|
||||
const dataList = common_vendor.ref([]);
|
||||
const paging = common_vendor.ref(null);
|
||||
common_vendor.ref(false);
|
||||
common_vendor.ref(0);
|
||||
common_vendor.ref(false);
|
||||
common_vendor.ref(0);
|
||||
common_vendor.ref("");
|
||||
const onChangeTab = (item, idx) => {
|
||||
current_tab_idx.value = idx;
|
||||
paging.value.reload();
|
||||
};
|
||||
const navigateToDetail = (id) => {
|
||||
common_vendor.index.__f__("log", "at pages/order/index.vue:277", id);
|
||||
if (!id) {
|
||||
common_vendor.index.__f__("warn", "at pages/order/index.vue:279", "导航ID不能为空");
|
||||
return;
|
||||
}
|
||||
common_vendor.index.navigateTo({
|
||||
url: `/pages/config/shopOrder/detail?id=${encodeURIComponent(id)}`
|
||||
});
|
||||
};
|
||||
const queryList = (pageNo = 1, pageSize = 10) => {
|
||||
common_vendor.index.__f__("log", "at pages/order/index.vue:317", tabs_config[current_tab_idx.value]["status"]);
|
||||
common_vendor.index.__f__("log", "at pages/order/index.vue:164", tabs_config[current_tab_idx.value]["status"]);
|
||||
const params = {
|
||||
page: pageNo,
|
||||
pageSize: 10,
|
||||
status: tabs_config[current_tab_idx.value]["status"]
|
||||
};
|
||||
api_index.fetchOrderList(params).then((res) => {
|
||||
common_vendor.index.__f__("log", "at pages/order/index.vue:324", res);
|
||||
common_vendor.index.__f__("log", "at pages/order/index.vue:171", res);
|
||||
paging.value.complete(res.list);
|
||||
}).catch((res) => {
|
||||
paging.value.complete(false);
|
||||
@@ -96,38 +83,124 @@ const _sfc_main = {
|
||||
modelValue: current_tab_idx.value
|
||||
}),
|
||||
d: common_vendor.f(dataList.value, (order, index, i0) => {
|
||||
var _a;
|
||||
return {
|
||||
a: common_vendor.t(order.create_time),
|
||||
b: common_vendor.t((_a = order == null ? void 0 : order.status) == null ? void 0 : _a.text),
|
||||
c: "17a44f9d-3-" + i0 + ",17a44f9d-2",
|
||||
d: common_vendor.f(order.goods, (goods, iidx, i1) => {
|
||||
var _a2;
|
||||
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C;
|
||||
return common_vendor.e({
|
||||
a: order.order_type == 1
|
||||
}, order.order_type == 1 ? {
|
||||
b: "17a44f9d-3-" + i0 + ",17a44f9d-2",
|
||||
c: common_vendor.p({
|
||||
plain: true,
|
||||
type: "primary"
|
||||
})
|
||||
} : {
|
||||
e: "17a44f9d-4-" + i0 + ",17a44f9d-2",
|
||||
f: common_vendor.p({
|
||||
plain: true,
|
||||
type: "warning"
|
||||
})
|
||||
}, {
|
||||
d: order.order_type == 2,
|
||||
g: order.order_type == 1
|
||||
}, order.order_type == 1 ? {
|
||||
h: common_vendor.t((_a = order == null ? void 0 : order.rooms) == null ? void 0 : _a.room_name),
|
||||
i: "17a44f9d-5-" + i0 + ",17a44f9d-2",
|
||||
j: common_vendor.p({
|
||||
["custom-color"]: "#ffc209"
|
||||
})
|
||||
} : {}, {
|
||||
k: ((_b = order == null ? void 0 : order.status) == null ? void 0 : _b.value) == 1
|
||||
}, ((_c = order == null ? void 0 : order.status) == null ? void 0 : _c.value) == 1 ? {
|
||||
l: common_vendor.t((_d = order == null ? void 0 : order.status) == null ? void 0 : _d.text),
|
||||
m: "17a44f9d-6-" + i0 + ",17a44f9d-2",
|
||||
n: common_vendor.p({
|
||||
plain: true,
|
||||
type: "danger"
|
||||
})
|
||||
} : ((_e = order == null ? void 0 : order.status) == null ? void 0 : _e.value) == 2 ? {
|
||||
p: common_vendor.t((_f = order == null ? void 0 : order.status) == null ? void 0 : _f.text),
|
||||
q: "17a44f9d-7-" + i0 + ",17a44f9d-2",
|
||||
r: common_vendor.p({
|
||||
plain: true,
|
||||
type: "success"
|
||||
})
|
||||
} : {}, {
|
||||
o: ((_g = order == null ? void 0 : order.status) == null ? void 0 : _g.value) == 2,
|
||||
s: order.order_type == 1 && ((_h = order == null ? void 0 : order.fee_type) == null ? void 0 : _h.value) != 0
|
||||
}, order.order_type == 1 && ((_i = order == null ? void 0 : order.fee_type) == null ? void 0 : _i.value) != 0 ? common_vendor.e({
|
||||
t: common_vendor.t((_j = order == null ? void 0 : order.fee_type) == null ? void 0 : _j.text),
|
||||
v: "17a44f9d-8-" + i0 + ",17a44f9d-2",
|
||||
w: common_vendor.p({
|
||||
plain: true,
|
||||
["custom-color"]: "#fa2400"
|
||||
}),
|
||||
x: ((_k = order == null ? void 0 : order.fee_type) == null ? void 0 : _k.value) == 0 || ((_l = order == null ? void 0 : order.fee_type) == null ? void 0 : _l.value) == 3
|
||||
}, ((_m = order == null ? void 0 : order.fee_type) == null ? void 0 : _m.value) == 0 || ((_n = order == null ? void 0 : order.fee_type) == null ? void 0 : _n.value) == 3 ? {} : ((_o = order == null ? void 0 : order.fee_type) == null ? void 0 : _o.value) == 1 || ((_p = order == null ? void 0 : order.fee_type) == null ? void 0 : _p.value) == 2 ? {
|
||||
z: common_vendor.t(order == null ? void 0 : order.fee_combo_name)
|
||||
} : {}, {
|
||||
y: ((_q = order == null ? void 0 : order.fee_type) == null ? void 0 : _q.value) == 1 || ((_r = order == null ? void 0 : order.fee_type) == null ? void 0 : _r.value) == 2,
|
||||
A: ((_s = order == null ? void 0 : order.fee_type) == null ? void 0 : _s.value) == 0 || ((_t = order == null ? void 0 : order.fee_type) == null ? void 0 : _t.value) == 3
|
||||
}, ((_u = order == null ? void 0 : order.fee_type) == null ? void 0 : _u.value) == 0 || ((_v = order == null ? void 0 : order.fee_type) == null ? void 0 : _v.value) == 3 ? {
|
||||
B: common_vendor.t(order == null ? void 0 : order.fee_amount)
|
||||
} : ((_w = order == null ? void 0 : order.fee_type) == null ? void 0 : _w.value) == 1 || ((_x = order == null ? void 0 : order.fee_type) == null ? void 0 : _x.value) == 2 ? {
|
||||
D: common_vendor.t(order == null ? void 0 : order.fee_combo_price)
|
||||
} : {}, {
|
||||
C: ((_y = order == null ? void 0 : order.fee_type) == null ? void 0 : _y.value) == 1 || ((_z = order == null ? void 0 : order.fee_type) == null ? void 0 : _z.value) == 2,
|
||||
E: common_vendor.t((_A = order == null ? void 0 : order.fee_pay_status) == null ? void 0 : _A.text)
|
||||
}) : {}, {
|
||||
F: order.over_often > 0
|
||||
}, order.over_often > 0 ? {
|
||||
G: "17a44f9d-9-" + i0 + ",17a44f9d-2",
|
||||
H: common_vendor.p({
|
||||
plain: true,
|
||||
["custom-color"]: "#fa2400"
|
||||
}),
|
||||
I: common_vendor.t(order == null ? void 0 : order.over_often),
|
||||
J: common_vendor.t(order == null ? void 0 : order.over_amount),
|
||||
K: common_vendor.t((_B = order == null ? void 0 : order.over_pay_status) == null ? void 0 : _B.text)
|
||||
} : {}, {
|
||||
L: common_vendor.f(order.goods, (goods, iidx, i1) => {
|
||||
return {
|
||||
a: common_vendor.t(goods.goods_type_name),
|
||||
b: "17a44f9d-4-" + i0 + "-" + i1 + ",17a44f9d-2",
|
||||
b: "17a44f9d-10-" + i0 + "-" + i1 + ",17a44f9d-2",
|
||||
c: common_vendor.t(goods.goods_name),
|
||||
d: common_vendor.t(goods == null ? void 0 : goods.goods_price),
|
||||
e: common_vendor.t((_a2 = goods == null ? void 0 : goods.goods_pay_status) == null ? void 0 : _a2.text),
|
||||
f: iidx,
|
||||
g: common_vendor.o(($event) => navigateToDetail(order.order_id), iidx)
|
||||
e: common_vendor.t(goods == null ? void 0 : goods.goods_pay_status_txt),
|
||||
f: iidx
|
||||
};
|
||||
}),
|
||||
e: index
|
||||
};
|
||||
M: "17a44f9d-11-" + i0 + ",17a44f9d-2",
|
||||
N: common_vendor.p({
|
||||
price: order.discount_amount,
|
||||
size: "normal",
|
||||
["need-symbol"]: true
|
||||
}),
|
||||
O: "17a44f9d-12-" + i0 + ",17a44f9d-2",
|
||||
P: common_vendor.p({
|
||||
price: order.total_price,
|
||||
size: "normal",
|
||||
["need-symbol"]: true
|
||||
}),
|
||||
Q: order.remarks
|
||||
}, order.remarks ? {} : {}, {
|
||||
R: order.remarks
|
||||
}, order.remarks ? {
|
||||
S: common_vendor.t(order.remarks)
|
||||
} : {}, {
|
||||
T: common_vendor.t(order.create_time),
|
||||
U: common_vendor.t((_C = order == null ? void 0 : order.user) == null ? void 0 : _C.staff_name),
|
||||
V: index
|
||||
});
|
||||
}),
|
||||
e: common_vendor.p({
|
||||
["custom-color"]: "#1a1a1a"
|
||||
plain: true,
|
||||
["custom-color"]: "#fa2400"
|
||||
}),
|
||||
f: common_vendor.p({
|
||||
["custom-color"]: "#1a1a1a"
|
||||
}),
|
||||
g: common_vendor.sr(paging, "17a44f9d-2", {
|
||||
f: common_vendor.sr(paging, "17a44f9d-2", {
|
||||
"k": "paging"
|
||||
}),
|
||||
h: common_vendor.o(queryList),
|
||||
i: common_vendor.o(($event) => dataList.value = $event),
|
||||
j: common_vendor.p({
|
||||
g: common_vendor.o(queryList),
|
||||
h: common_vendor.o(($event) => dataList.value = $event),
|
||||
i: common_vendor.p({
|
||||
fixed: false,
|
||||
modelValue: dataList.value
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user