131 lines
5.2 KiB
JavaScript
131 lines
5.2 KiB
JavaScript
|
|
"use strict";
|
||
|
|
const common_vendor = require("../../common/vendor.js");
|
||
|
|
if (!Array) {
|
||
|
|
const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
|
||
|
|
const _easycom_hs_button2 = common_vendor.resolveComponent("hs-button");
|
||
|
|
const _easycom_up_divider2 = common_vendor.resolveComponent("up-divider");
|
||
|
|
const _easycom_up_keyboard2 = common_vendor.resolveComponent("up-keyboard");
|
||
|
|
(_easycom_uni_icons2 + _easycom_hs_button2 + _easycom_up_divider2 + _easycom_up_keyboard2)();
|
||
|
|
}
|
||
|
|
const _easycom_uni_icons = () => "../../uni_modules/uni-icons/components/uni-icons/uni-icons.js";
|
||
|
|
const _easycom_hs_button = () => "../../components/hs-button/hs-button.js";
|
||
|
|
const _easycom_up_divider = () => "../../node-modules/uview-plus/components/u-divider/u-divider.js";
|
||
|
|
const _easycom_up_keyboard = () => "../../node-modules/uview-plus/components/u-keyboard/u-keyboard.js";
|
||
|
|
if (!Math) {
|
||
|
|
(_easycom_uni_icons + _easycom_hs_button + _easycom_up_divider + _easycom_up_keyboard)();
|
||
|
|
}
|
||
|
|
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
|
||
|
|
__name: "index",
|
||
|
|
setup(__props) {
|
||
|
|
const jinGangQu = [
|
||
|
|
{ label: "缴费记录", icon: "calendar", url: "/INDEX/parking_payment_record/index" },
|
||
|
|
{ label: "我的车辆", icon: "car", url: "/ME/vehicle_management/list/index" },
|
||
|
|
{ label: "开具发票", icon: "red-packet", url: "/ME/issue_invoice/index" }
|
||
|
|
];
|
||
|
|
const licensePlateNumber = common_vendor.ref(["粤", "B", "F", "R", "2", "3", "2", "3"]);
|
||
|
|
const licensePlateNumberValue = common_vendor.ref("粤BFR2323");
|
||
|
|
const isFocus = common_vendor.ref(false);
|
||
|
|
const ketMode = common_vendor.ref("car");
|
||
|
|
const showKeyboard = common_vendor.ref(false);
|
||
|
|
const handleProvinceClick = () => {
|
||
|
|
showKeyboard.value = true;
|
||
|
|
ketMode.value = "car";
|
||
|
|
isFocus.value = false;
|
||
|
|
};
|
||
|
|
const handleInputChange = (e) => {
|
||
|
|
var _a, _b;
|
||
|
|
if (((_a = licensePlateNumberValue == null ? void 0 : licensePlateNumberValue.value) == null ? void 0 : _a.length) < 8) {
|
||
|
|
licensePlateNumberValue.value += e;
|
||
|
|
for (let i = 0; i < 8; i++) {
|
||
|
|
licensePlateNumber.value[i] = licensePlateNumberValue.value[i] || "";
|
||
|
|
console.log(licensePlateNumberValue.value[i]);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
if (((_b = licensePlateNumberValue == null ? void 0 : licensePlateNumberValue.value) == null ? void 0 : _b.length) === 8) {
|
||
|
|
showKeyboard.value = false;
|
||
|
|
isFocus.value = false;
|
||
|
|
}
|
||
|
|
};
|
||
|
|
const handleBackspaceChange = () => {
|
||
|
|
var _a;
|
||
|
|
licensePlateNumberValue.value = (_a = licensePlateNumberValue.value) == null ? void 0 : _a.slice(0, -1);
|
||
|
|
for (let i = 0; i < 8; i++) {
|
||
|
|
licensePlateNumber.value[i] = licensePlateNumberValue.value[i] || "";
|
||
|
|
console.log(licensePlateNumberValue.value[i]);
|
||
|
|
}
|
||
|
|
};
|
||
|
|
const toPage = (url) => {
|
||
|
|
common_vendor.index.navigateTo({ url });
|
||
|
|
};
|
||
|
|
const handleQueryClick = () => {
|
||
|
|
var _a;
|
||
|
|
if (((_a = licensePlateNumberValue == null ? void 0 : licensePlateNumberValue.value) == null ? void 0 : _a.length) < 7) {
|
||
|
|
common_vendor.index.showToast({
|
||
|
|
title: "请输入完整的车牌号!",
|
||
|
|
icon: "none"
|
||
|
|
});
|
||
|
|
return;
|
||
|
|
}
|
||
|
|
common_vendor.index.navigateTo({
|
||
|
|
url: "/ME/parking_fee/index"
|
||
|
|
});
|
||
|
|
};
|
||
|
|
return (_ctx, _cache) => {
|
||
|
|
return {
|
||
|
|
a: common_vendor.f(licensePlateNumber.value, (i, index, i0) => {
|
||
|
|
return common_vendor.e({
|
||
|
|
a: !i && index === 7
|
||
|
|
}, !i && index === 7 ? {
|
||
|
|
b: "6d6f18c6-0-" + i0,
|
||
|
|
c: common_vendor.p({
|
||
|
|
type: "plusempty",
|
||
|
|
color: "#2A7EFB",
|
||
|
|
size: "13"
|
||
|
|
})
|
||
|
|
} : {
|
||
|
|
d: common_vendor.t(i)
|
||
|
|
}, {
|
||
|
|
e: index === 1
|
||
|
|
}, index === 1 ? {} : {}, {
|
||
|
|
f: `iten_${index}`
|
||
|
|
});
|
||
|
|
}),
|
||
|
|
b: common_vendor.o(handleProvinceClick),
|
||
|
|
c: common_vendor.o(handleQueryClick),
|
||
|
|
d: common_vendor.p({
|
||
|
|
label: "查询停车费",
|
||
|
|
size: "md"
|
||
|
|
}),
|
||
|
|
e: common_vendor.f(3, (i, index, i0) => {
|
||
|
|
return {
|
||
|
|
a: `item_${index}`
|
||
|
|
};
|
||
|
|
}),
|
||
|
|
f: common_vendor.f(jinGangQu, (i, index, i0) => {
|
||
|
|
return {
|
||
|
|
a: `/static/svg/${i == null ? void 0 : i.icon}.svg`,
|
||
|
|
b: common_vendor.t(i == null ? void 0 : i.label),
|
||
|
|
c: `item_${index}`,
|
||
|
|
d: common_vendor.o(($event) => toPage(i == null ? void 0 : i.url), `item_${index}`)
|
||
|
|
};
|
||
|
|
}),
|
||
|
|
g: common_vendor.p({
|
||
|
|
text: "会员停车权益说明"
|
||
|
|
}),
|
||
|
|
h: common_vendor.sr("uKeyboard", "6d6f18c6-3"),
|
||
|
|
i: common_vendor.o(($event) => showKeyboard.value = false),
|
||
|
|
j: common_vendor.o(handleInputChange),
|
||
|
|
k: common_vendor.o(handleBackspaceChange),
|
||
|
|
l: common_vendor.o(($event) => showKeyboard.value = false),
|
||
|
|
m: common_vendor.o(($event) => showKeyboard.value = false),
|
||
|
|
n: common_vendor.p({
|
||
|
|
mode: ketMode.value,
|
||
|
|
show: showKeyboard.value
|
||
|
|
})
|
||
|
|
};
|
||
|
|
};
|
||
|
|
}
|
||
|
|
});
|
||
|
|
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__file", "/Users/zsq/Sources/github/2025property-pay/pay-customer/src/INDEX/parking_payment/index.vue"]]);
|
||
|
|
wx.createPage(MiniProgramPage);
|