70 lines
2.3 KiB
JavaScript
70 lines
2.3 KiB
JavaScript
"use strict";
|
|
const common_vendor = require("../../common/vendor.js");
|
|
require("../../common/libraries/day.js");
|
|
if (!Array) {
|
|
const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
|
|
_easycom_uni_icons2();
|
|
}
|
|
const _easycom_uni_icons = () => "../../uni_modules/uni-icons/components/uni-icons/uni-icons.js";
|
|
if (!Math) {
|
|
_easycom_uni_icons();
|
|
}
|
|
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
|
|
__name: "hs-year-picker",
|
|
props: [
|
|
"Enums",
|
|
"title",
|
|
"pickerIndex",
|
|
"value",
|
|
"borderTop",
|
|
"required",
|
|
"valueModel",
|
|
"icon",
|
|
"iconSize"
|
|
],
|
|
emits: ["change", "update:valueModel"],
|
|
setup(__props, { emit }) {
|
|
const selectValue = common_vendor.ref("全部账单");
|
|
const onChange = (e) => {
|
|
var _a, _b, _c;
|
|
selectValue.value = (_a = e == null ? void 0 : e.detail) == null ? void 0 : _a.value;
|
|
emit("update:valueModel", (_b = e == null ? void 0 : e.detail) == null ? void 0 : _b.value);
|
|
emit("change", (_c = e == null ? void 0 : e.detail) == null ? void 0 : _c.value);
|
|
};
|
|
const handleClose = () => {
|
|
selectValue.value = "全部账单";
|
|
emit("update:valueModel", void 0);
|
|
emit("change", void 0);
|
|
};
|
|
return (_ctx, _cache) => {
|
|
return common_vendor.e({
|
|
a: selectValue.value === "全部账单"
|
|
}, selectValue.value === "全部账单" ? {
|
|
b: common_vendor.t(selectValue.value)
|
|
} : {
|
|
c: common_vendor.t(selectValue.value)
|
|
}, {
|
|
d: selectValue.value === "全部账单"
|
|
}, selectValue.value === "全部账单" ? {
|
|
e: common_vendor.p({
|
|
type: "down",
|
|
color: "#333",
|
|
size: "12"
|
|
})
|
|
} : {}, {
|
|
f: common_vendor.o(onChange),
|
|
g: selectValue.value !== "全部账单"
|
|
}, selectValue.value !== "全部账单" ? {
|
|
h: common_vendor.p({
|
|
type: "close",
|
|
color: "#666",
|
|
size: "18"
|
|
}),
|
|
i: common_vendor.o(handleClose)
|
|
} : {});
|
|
};
|
|
}
|
|
});
|
|
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-2966563c"], ["__file", "/Users/zsq/Sources/github/2025property-pay/pay-customer/src/components/hs-year-picker/hs-year-picker.vue"]]);
|
|
wx.createComponent(Component);
|