150 lines
6.2 KiB
JavaScript
150 lines
6.2 KiB
JavaScript
"use strict";
|
|
const common_vendor = require("../../common/vendor.js");
|
|
const common_assets = require("../../common/assets.js");
|
|
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
|
|
__name: "index",
|
|
props: {
|
|
isshow: {
|
|
type: Boolean,
|
|
required: true
|
|
},
|
|
darkFans: {
|
|
type: Boolean,
|
|
required: true
|
|
},
|
|
canmove: {
|
|
type: Boolean,
|
|
required: true
|
|
}
|
|
},
|
|
emits: ["darkchange", "savename"],
|
|
setup(__props, { emit: __emit }) {
|
|
const props = __props;
|
|
const downList = common_vendor.ref([
|
|
"口腔清洁啊",
|
|
"头部清洁",
|
|
"面部清洁",
|
|
"躯干清洁",
|
|
"四肢清洁",
|
|
"会阴清洁",
|
|
"肛周清洁",
|
|
"手清洁",
|
|
"足清洁",
|
|
"剃须",
|
|
"口腔清洁",
|
|
"头部清洁",
|
|
"面部清洁",
|
|
"躯干清洁",
|
|
"四肢清洁",
|
|
"会阴清洁",
|
|
"肛周清洁",
|
|
"手清洁",
|
|
"足清洁",
|
|
"剃须"
|
|
]);
|
|
const undericonList = common_vendor.ref([
|
|
{ url: "/static/index/undericons/alarm.png", targetUrl: "/static/index/undericons/alarmdark.png", name: "服务考核" },
|
|
{ url: "/static/index/undericons/linshitime.png", targetUrl: "/static/index/undericons/linshitimedark.png", name: "护理流程" },
|
|
{ url: "/static/index/darkicon/zhaomingdark.png", targetUrl: "/static/index/roomicons/zhaomingtar.png", name: "电子医嘱" },
|
|
{ url: "/static/index/darkicon/kontiaodark.png", targetUrl: "/static/index/roomicons/kongtiaotar.png", name: "进销存" },
|
|
{ url: "/static/index/darkicon/nuanfengdark.png", targetUrl: "/static/index/roomicons/nuanfengtar.png", name: "实时监控" },
|
|
{ url: "/static/index/darkicon/dianqidark.png", targetUrl: "/static/index/roomicons/dianqitar.png", name: "我的指令" }
|
|
]);
|
|
const doctorsayList = common_vendor.ref([
|
|
{ url: "/static/index/doctorsay/light/clean.png", targetUrl: "/static/index/doctorsay/dark/clean.png", name: "清洁" },
|
|
{ url: "/static/index/doctorsay/light/drink.png", targetUrl: "/static/index/doctorsay/dark/drink.png", name: "饮食" },
|
|
{ url: "/static/index/doctorsay/light/bed.png", targetUrl: "/static/index/doctorsay/dark/bed.png", name: "睡眠" },
|
|
{ url: "/static/index/doctorsay/light/shi.png", targetUrl: "/static/index/doctorsay/dark/shi.png", name: "排便" },
|
|
{ url: "/static/index/doctorsay/light/use.png", targetUrl: "/static/index/doctorsay/dark/use.png", name: "日常" }
|
|
]);
|
|
const undermenuIndex = common_vendor.ref(0);
|
|
const upmenuIndex = common_vendor.ref(0);
|
|
const downmenuIndex = common_vendor.ref(0);
|
|
common_vendor.ref(false);
|
|
common_vendor.ref([]);
|
|
const emit = __emit;
|
|
const darkFanschange = () => {
|
|
emit("darkchange", !props.darkFans);
|
|
};
|
|
const changeMenuUnder = (index) => {
|
|
undermenuIndex.value = index;
|
|
};
|
|
const timer = common_vendor.ref(null);
|
|
const handleTouchStart = (item, index) => {
|
|
timer.value = setTimeout(() => {
|
|
downmenuIndex.value = index;
|
|
emit("savename", item);
|
|
}, 500);
|
|
};
|
|
const handleTouchEnd = () => {
|
|
if (timer.value) {
|
|
clearTimeout(timer.value);
|
|
timer.value = null;
|
|
}
|
|
};
|
|
return (_ctx, _cache) => {
|
|
return {
|
|
a: common_vendor.n(__props.darkFans ? `right-container-title-no-dark` : `right-container-title-no`),
|
|
b: common_vendor.n(__props.darkFans ? `right-container-title-no-dark` : `right-container-title-no`),
|
|
c: `/static/index/undericons/man.png`,
|
|
d: common_vendor.n(__props.darkFans ? `right-icons-font-dark` : `right-icons-font`),
|
|
e: __props.darkFans ? `/static/index/undericons/face.png` : `/static/index/undericons/facelight.png`,
|
|
f: __props.darkFans ? `/static/index/undericons/hand.png` : `/static/index/undericons/handlight.png`,
|
|
g: __props.darkFans ? `/static/index/undericons/out.png` : `/static/index/undericons/outlight.png`,
|
|
h: common_vendor.o(($event) => darkFanschange()),
|
|
i: !__props.darkFans,
|
|
j: common_vendor.s(__props.darkFans ? {
|
|
color: "black"
|
|
} : {}),
|
|
k: common_vendor.s(__props.darkFans ? {
|
|
backgroundColor: "#fff"
|
|
} : {}),
|
|
l: common_vendor.o(($event) => darkFanschange()),
|
|
m: __props.darkFans,
|
|
n: common_vendor.f(doctorsayList.value, (item, index, i0) => {
|
|
return {
|
|
a: index === upmenuIndex.value ? item.targetUrl : item.url,
|
|
b: common_vendor.t(item.name),
|
|
c: common_vendor.n(index === upmenuIndex.value ? `doctorsay-container-card-font-dark` : `doctorsay-container-card-font`),
|
|
d: common_vendor.s(index === upmenuIndex.value ? {
|
|
backgroundColor: `#0184db`
|
|
} : {}),
|
|
e: index,
|
|
f: common_vendor.o(($event) => upmenuIndex.value = index, index)
|
|
};
|
|
}),
|
|
o: common_vendor.f(downList.value, (item, index, i0) => {
|
|
return {
|
|
a: downmenuIndex.value === index,
|
|
b: common_vendor.t(item),
|
|
c: common_vendor.n(downmenuIndex.value === index ? `doctorsay-container-text-target` : `doctorsay-container-text`),
|
|
d: index,
|
|
e: common_vendor.o(($event) => handleTouchStart(item, index), index),
|
|
f: common_vendor.o(handleTouchEnd, index)
|
|
};
|
|
}),
|
|
p: __props.canmove,
|
|
q: common_vendor.f(undericonList.value, (item, index, i0) => {
|
|
return {
|
|
a: index === undermenuIndex.value,
|
|
b: index === undermenuIndex.value ? item.targetUrl : item.url,
|
|
c: common_vendor.t(item.name),
|
|
d: index,
|
|
e: common_vendor.o(($event) => changeMenuUnder(index), index)
|
|
};
|
|
}),
|
|
r: common_assets._imports_0$1,
|
|
s: common_vendor.n(__props.darkFans ? `under-father-img-font-dark` : `under-father-img-font`),
|
|
t: common_vendor.s(__props.isshow ? {
|
|
opacity: `1`
|
|
} : {
|
|
opacity: `0`
|
|
})
|
|
};
|
|
};
|
|
}
|
|
});
|
|
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-337bb5da"]]);
|
|
wx.createComponent(Component);
|
|
//# sourceMappingURL=../../../.sourcemap/mp-weixin/component/rightItemssecond/index.js.map
|