Your Name 6d31441e12 Merge branch 'develop' of ssh://code.juyouwu.cn:2222/pay/pay-customer into develop
* 'develop' of ssh://code.juyouwu.cn:2222/pay/pay-customer:
  fix:更新

# Conflicts:
#	.env.development
#	ci/project.config.json
#	dist/build/mp-weixin/INDEX/bill/list/index.wxml
#	dist/build/mp-weixin/INDEX/invitation/index.js
#	dist/build/mp-weixin/INDEX/invitation/index.json
#	dist/build/mp-weixin/INDEX/invitation/index.wxml
#	dist/build/mp-weixin/INDEX/invitation/index.wxss
#	dist/build/mp-weixin/INDEX/parking_payment/index.js
#	dist/build/mp-weixin/INDEX/parking_payment/index.wxml
#	dist/build/mp-weixin/INDEX/parking_payment/index.wxss
#	dist/build/mp-weixin/INDEX/parking_payment_record/index.js
#	dist/build/mp-weixin/INDEX/parking_payment_record/index.json
#	dist/build/mp-weixin/INDEX/parking_payment_record/index.wxml
#	dist/build/mp-weixin/INDEX/parking_payment_record/index.wxss
#	dist/build/mp-weixin/INDEX/pay/method.js
#	dist/build/mp-weixin/INDEX/pay/success.js
#	dist/build/mp-weixin/INDEX/pay/success.wxml
#	dist/build/mp-weixin/INDEX/pay/success.wxss
#	dist/build/mp-weixin/ME/payment_pre_stored/index.js
#	dist/build/mp-weixin/ME/payment_pre_stored/index.wxml
#	dist/build/mp-weixin/ME/payment_pre_stored/index.wxss
#	dist/build/mp-weixin/ME/pre_stored_form/index.js
#	dist/build/mp-weixin/ME/pre_stored_form/index.wxml
#	dist/build/mp-weixin/ME/vehicle_management/add/index.js
#	dist/build/mp-weixin/ME/vehicle_management/add/index.wxml
#	dist/build/mp-weixin/ME/vehicle_management/add/index.wxss
#	dist/build/mp-weixin/WORKORDER/add/index.js
#	dist/build/mp-weixin/WORKORDER/add/index.json
#	dist/build/mp-weixin/WORKORDER/add/index.wxml
#	dist/build/mp-weixin/WORKORDER/add/method.js
#	dist/build/mp-weixin/WORKORDER/list/index.js
#	dist/build/mp-weixin/WORKORDER/list/index.wxml
#	dist/build/mp-weixin/WORKORDER/list/index.wxss
#	dist/build/mp-weixin/WORKORDER/show/index.js
#	dist/build/mp-weixin/WORKORDER/show/index.json
#	dist/build/mp-weixin/WORKORDER/show/index.wxml
#	dist/build/mp-weixin/WORKORDER/show/index.wxss
#	dist/build/mp-weixin/WORKORDER/show/method.js
#	dist/build/mp-weixin/WORKORDER/show/model.js
#	dist/build/mp-weixin/common/components/cc-scroll-loading/cc-scroll-loading.js
#	dist/build/mp-weixin/common/components/cc-scroll-loading/cc-scroll-loading.wxml
#	dist/build/mp-weixin/common/components/cc-scroll-loading/cc-scroll-loading.wxss
#	dist/build/mp-weixin/common/libraries/day.js
#	dist/build/mp-weixin/common/vendor.js
#	dist/build/mp-weixin/components/hs-button/hs-button.js
#	dist/build/mp-weixin/components/hs-button/hs-button.wxml
#	dist/build/mp-weixin/components/hs-button/hs-button.wxss
#	dist/build/mp-weixin/components/hs-popup-evaluate/hs-popup-evaluate.js
#	dist/build/mp-weixin/components/hs-popup-evaluate/hs-popup-evaluate.wxml
#	dist/build/mp-weixin/components/hs-popup-evaluate/hs-popup-evaluate.wxss
#	dist/build/mp-weixin/components/hs-reservation-picker/hs-reservation-picker.js
#	dist/build/mp-weixin/components/hs-reservation-picker/hs-reservation-picker.wxml
#	dist/build/mp-weixin/components/hs-reservation-picker/hs-reservation-picker.wxss
#	dist/build/mp-weixin/gen/Apis.js
#	dist/build/mp-weixin/gen/Enums.js
#	dist/build/mp-weixin/node-modules/uview-plus/components/u-keyboard/u-keyboard.js
#	dist/build/mp-weixin/pages/index/components/Classification.js
#	dist/build/mp-weixin/pages/index/components/Classification.wxml
#	dist/build/mp-weixin/pages/index/components/Classification.wxss
#	dist/build/mp-weixin/pages/index/components/ConvenienceServices.js
#	dist/build/mp-weixin/pages/index/components/ConvenienceServices.json
#	dist/build/mp-weixin/pages/index/components/ConvenienceServices.wxml
#	dist/build/mp-weixin/pages/index/components/ConvenienceServices.wxss
#	dist/build/mp-weixin/pages/index/index.wxss
#	dist/build/mp-weixin/pages/me/components/AreaFunctional.js
#	dist/build/mp-weixin/pages/me/components/AreaFunctional.json
#	dist/build/mp-weixin/pages/me/components/AreaFunctional.wxml
#	dist/build/mp-weixin/pages/me/components/AreaFunctional.wxss
#	dist/build/mp-weixin/pages/transfer/index.js
#	dist/dev/mp-weixin/INDEX/pay/method.js
#	dist/dev/mp-weixin/INDEX/pay/success.wxml
#	dist/dev/mp-weixin/WORKORDER/add/index.js
#	dist/dev/mp-weixin/WORKORDER/list/index.js
#	dist/dev/mp-weixin/WORKORDER/list/index.json
#	dist/dev/mp-weixin/WORKORDER/list/index.wxml
#	dist/dev/mp-weixin/WORKORDER/list/index.wxss
#	dist/dev/mp-weixin/WORKORDER/show/index.js
#	dist/dev/mp-weixin/WORKORDER/show/index.json
#	dist/dev/mp-weixin/WORKORDER/show/index.wxml
#	dist/dev/mp-weixin/WORKORDER/show/index.wxss
#	dist/dev/mp-weixin/WORKORDER/show/model.js
#	dist/dev/mp-weixin/app.js
#	dist/dev/mp-weixin/common/libraries/day.js
#	dist/dev/mp-weixin/common/libraries/request.js
#	dist/dev/mp-weixin/common/vendor.js
#	dist/dev/mp-weixin/components/hs-popup-evaluate/hs-popup-evaluate.js
#	dist/dev/mp-weixin/components/hs-reservation-picker/hs-reservation-picker.js
#	dist/dev/mp-weixin/components/hs-reservation-picker/hs-reservation-picker.wxss
#	dist/dev/mp-weixin/gen/Enums.js
#	dist/dev/mp-weixin/node-modules/uview-plus/components/u-keyboard/u-keyboard.js
#	dist/dev/mp-weixin/pages/transfer/index.js
#	dist/dev/mp-weixin/project.private.config.json
#	src/INDEX/pay/method.ts
#	src/INDEX/pay/success.vue
#	src/WORKORDER/add/index.vue
#	src/WORKORDER/list/index.vue
#	src/WORKORDER/list/style.scss
#	src/WORKORDER/show/index.vue
#	src/WORKORDER/show/model.ts
#	src/WORKORDER/show/style.scss
#	src/common/libraries/day.ts
#	src/components/hs-popup-evaluate/hs-popup-evaluate.vue
#	src/components/hs-reservation-picker/hs-reservation-picker.vue
#	src/gen/ApiTypes.d.ts
#	src/gen/Enums.ts
#	src/pages/transfer/index.vue
2025-12-15 18:26:08 +08:00

154 lines
7.3 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

"use strict";
const common_vendor = require("../../common/vendor.js");
const WORKORDER_show_model = require("./model.js");
const common_libraries_apiLoading = require("../../common/libraries/apiLoading.js");
const gen_Apis = require("../../gen/Apis.js");
const common_libraries_day = require("../../common/libraries/day.js");
const getShow = (id) => {
common_libraries_apiLoading.getApiLoading(gen_Apis.Apis.WorkOrder.HouseWorkOrders.Show, { id }).then((res) => {
WORKORDER_show_model.useModel.dataShow.value = res == null ? void 0 : res.data;
});
};
const getHouseWorkLogs = (id) => {
common_libraries_apiLoading.getApiLoading(gen_Apis.Apis.WorkOrder.HouseWorkLogs.List, { house_work_orders_id: id }).then((res) => {
WORKORDER_show_model.useModel.logsData.value = res == null ? void 0 : res.data;
});
};
const method = {
getShow,
handleEvaluate() {
WORKORDER_show_model.useModel.showEvaluate.value = true;
},
handleClosed() {
var _a, _b, _c;
if (common_libraries_day.specificTime((_c = (_b = (_a = WORKORDER_show_model.useModel) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.expect_start_time)) {
common_vendor.index.showModal({
title: "提示",
content: "距离工单开始时间小于2小时无法关闭工单若需取消请联系处理人员操作。",
cancelText: "点错了",
success: function(res) {
if (res.confirm) {
console.log("用户点击确定");
} else if (res.cancel) {
console.log("用户点击取消");
}
}
});
return false;
}
common_vendor.index.showModal({
title: "提示",
content: "关闭工单后无法继续操作,如需继续需要重新提交,您是否确认关闭",
cancelText: "点错了",
success: function(res) {
var _a2, _b2, _c2;
if (res.confirm) {
common_libraries_apiLoading.getApiLoading(gen_Apis.Apis.WorkOrder.HouseWorkOrders.Close, {
id: (_c2 = (_b2 = (_a2 = WORKORDER_show_model.useModel) == null ? void 0 : _a2.dataShow) == null ? void 0 : _b2.value) == null ? void 0 : _c2.id
}).then((res2) => {
var _a3, _b3, _c3, _d, _e, _f;
getShow((_c3 = (_b3 = (_a3 = WORKORDER_show_model.useModel) == null ? void 0 : _a3.dataShow) == null ? void 0 : _b3.value) == null ? void 0 : _c3.id);
getHouseWorkLogs((_f = (_e = (_d = WORKORDER_show_model.useModel) == null ? void 0 : _d.dataShow) == null ? void 0 : _e.value) == null ? void 0 : _f.id);
});
console.log("用户点击确定");
} else if (res.cancel) {
console.log("用户点击取消");
}
}
});
},
handlepopupClose() {
WORKORDER_show_model.useModel.showEvaluate.value = false;
common_vendor.index.showToast({
title: "评价已提交",
icon: "none"
});
},
getHouseWorkLogs,
handlePhoneCall() {
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;
if (((_c = (_b = (_a = WORKORDER_show_model.useModel) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.status) === "PendingAcceptance") {
common_vendor.index.navigateTo({
url: `/WORKORDER/acceptance/index?id=${(_f = (_e = (_d = WORKORDER_show_model.useModel) == null ? void 0 : _d.dataShow) == null ? void 0 : _e.value) == null ? void 0 : _f.id}`
});
return false;
}
if (((_i = (_h = (_g = WORKORDER_show_model.useModel) == null ? void 0 : _g.dataShow) == null ? void 0 : _h.value) == null ? void 0 : _i.status) === "PendingPayment") {
common_vendor.index.navigateTo({
url: `/WORKORDER/pay/index?id=${(_l = (_k = (_j = WORKORDER_show_model.useModel) == null ? void 0 : _j.dataShow) == null ? void 0 : _k.value) == null ? void 0 : _l.id}`
});
return false;
}
if (((_o = (_n = (_m = WORKORDER_show_model.useModel) == null ? void 0 : _m.dataShow) == null ? void 0 : _n.value) == null ? void 0 : _o.status) === "Completed") {
WORKORDER_show_model.useModel.showEvaluate.value = true;
return false;
}
if (((_r = (_q = (_p = WORKORDER_show_model.useModel) == null ? void 0 : _p.dataShow) == null ? void 0 : _q.value) == null ? void 0 : _r.status) === "Processing") {
if ((_v = (_u = (_t = (_s = WORKORDER_show_model.useModel) == null ? void 0 : _s.dataShow) == null ? void 0 : _t.value) == null ? void 0 : _u.assign_employee) == null ? void 0 : _v.phone) {
common_vendor.index.makePhoneCall({
phoneNumber: (_z = (_y = (_x = (_w = WORKORDER_show_model.useModel) == null ? void 0 : _w.dataShow) == null ? void 0 : _x.value) == null ? void 0 : _y.assign_employee) == null ? void 0 : _z.phone
//仅为示例,并非真实的电话号码
});
} else {
common_vendor.index.showToast({
title: "暂无电话号码",
icon: "none"
});
}
return false;
}
},
hadnleUpdateTime() {
var _a, _b, _c, _d, _e, _f, _g, _h, _i;
if (common_libraries_day.specificTime((_c = (_b = (_a = WORKORDER_show_model.useModel) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.expect_start_time)) {
common_vendor.index.showModal({
title: "提示",
content: "距离工单开始时间小于2小时不能修改处理时间若需要请联系处理人员操作。",
cancelText: "点错了",
success: function(res) {
if (res.confirm) {
console.log("用户点击确定");
} else if (res.cancel) {
console.log("用户点击取消");
}
}
});
return false;
}
common_vendor.index.navigateTo({
url: `/WORKORDER/update_work_time/index?id=${(_f = (_e = (_d = WORKORDER_show_model.useModel) == null ? void 0 : _d.dataShow) == null ? void 0 : _e.value) == null ? void 0 : _f.id}&day=${(_i = (_h = (_g = WORKORDER_show_model.useModel) == null ? void 0 : _g.dataShow) == null ? void 0 : _h.value) == null ? void 0 : _i.expect_start_time}`
});
},
handleRework() {
var _a, _b, _c;
common_vendor.index.navigateTo({
url: `/WORKORDER/update_work_rework/index?id=${(_c = (_b = (_a = WORKORDER_show_model.useModel) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.id}`
});
},
handleEvaluate() {
WORKORDER_show_model.useModel.showEvaluate.value = true;
},
handlepopupClose() {
WORKORDER_show_model.useModel.showEvaluate.value = false;
common_vendor.index.showToast({
title: "评价已提交",
icon: "none"
});
},
handlePhoneCall() {
var _a, _b, _c, _d, _e, _f, _g, _h;
if ((_d = (_c = (_b = (_a = WORKORDER_show_model.useModel) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.assign_employee) == null ? void 0 : _d.phone) {
common_vendor.index.makePhoneCall({
phoneNumber: (_h = (_g = (_f = (_e = WORKORDER_show_model.useModel) == null ? void 0 : _e.dataShow) == null ? void 0 : _f.value) == null ? void 0 : _g.assign_employee) == null ? void 0 : _h.phone
//仅为示例,并非真实的电话号码
});
} else {
common_vendor.index.showToast({
title: "暂无电话号码",
icon: "none"
});
}
}
};
exports.method = method;