This commit is contained in:
parent
8bf449d2da
commit
803aa4f28e
|
|
@ -4,9 +4,9 @@ import request from '@/request/index.js'
|
|||
// 以下 api 为博主项目示例,实际与项目相匹配
|
||||
|
||||
// 查询服务类型
|
||||
export const getServiceTree0 = () => {
|
||||
export const getServiceTree0 = (insTags) => {
|
||||
return request({
|
||||
url: `${uni.getStorageSync('serverUrl')}/api/pad/care/directive/getServiceTree`,
|
||||
url: `${uni.getStorageSync('serverUrl')}/api/pad/care/directive/getServiceTree?insTags=${insTags}`,
|
||||
method: 'get',
|
||||
})
|
||||
}
|
||||
|
|
|
|||
|
|
@ -886,8 +886,8 @@
|
|||
uni.setStorageSync('rulerbase', "care")
|
||||
getInstructionTag().then((res)=>{
|
||||
typearray.value = res.result;
|
||||
init()
|
||||
})
|
||||
init()
|
||||
})
|
||||
|
||||
const typearray = ref(["护理", "医疗", "后勤", "占位", "占位", "占位"])
|
||||
|
|
@ -1858,7 +1858,7 @@
|
|||
// console.log("有老人吗",uni.getStorageSync('elderId'))
|
||||
if (uni.getStorageSync('nuId') && uni.getStorageSync('elderId')) {
|
||||
getNclist(uni.getStorageSync('nuId'), uni.getStorageSync('elderId'),typearray.value[whitchtype.value]?.instructionType).then((res : any) => {
|
||||
console.log("通了吗", res,uni.getStorageSync('nuId'),typearray.value[whitchtype.value]?.instructionType)
|
||||
console.log( res )
|
||||
timearr.value = Array.from({ length: 24 }, (_, hour) => ({
|
||||
positioning: hour.toString(),
|
||||
children: minuteArr.map(time => ({
|
||||
|
|
@ -1914,8 +1914,10 @@
|
|||
|
||||
|
||||
const init = () => {
|
||||
geteverything()
|
||||
// savePackagelist.value = uni.getStorageSync('Packagelist') || []
|
||||
let res = uni.getStorageSync(`saveTree${whitchtype.value}`)
|
||||
let res = uni.getStorageSync(`saveTree${typearray.value[whitchtype.value]?.instructionType}`)
|
||||
console.log(res,typearray.value[whitchtype.value]?.instructionType)
|
||||
let goodArray = []
|
||||
myArray.forEach((element : any) => {
|
||||
element?.children.forEach((element1 : any) => {
|
||||
|
|
@ -1927,7 +1929,7 @@
|
|||
})
|
||||
secondtemp.value = goodArray
|
||||
|
||||
let data0 = res.result.fwzl
|
||||
let data0 = res
|
||||
// console.log("0000", data0)
|
||||
if (data0) {
|
||||
data0.forEach((element : any) => {
|
||||
|
|
@ -1978,33 +1980,33 @@
|
|||
})
|
||||
bigArray.value = data0;
|
||||
}
|
||||
let data1 = res.result.jszl
|
||||
if (data1) {
|
||||
data1.forEach((element : any) => {
|
||||
if (element.netFlag == '0') {
|
||||
doctorsayList.value.forEach((res : any) => {
|
||||
if (res.name == element.title) {
|
||||
element.url = res.url
|
||||
}
|
||||
})
|
||||
} else {
|
||||
element.url = element.animationPath
|
||||
}
|
||||
element?.children.forEach((res1 : any) => {
|
||||
if (res1.netFlag == '0') {
|
||||
secondtemp.value.forEach((res2 : any) => {
|
||||
if (res2.name == res1.title) {
|
||||
res1.url = res2.url
|
||||
}
|
||||
})
|
||||
} else {
|
||||
res1.url = res1.animationPath
|
||||
}
|
||||
// let data1 = res.result.jszl
|
||||
// if (data1) {
|
||||
// data1.forEach((element : any) => {
|
||||
// if (element.netFlag == '0') {
|
||||
// doctorsayList.value.forEach((res : any) => {
|
||||
// if (res.name == element.title) {
|
||||
// element.url = res.url
|
||||
// }
|
||||
// })
|
||||
// } else {
|
||||
// element.url = element.animationPath
|
||||
// }
|
||||
// element?.children.forEach((res1 : any) => {
|
||||
// if (res1.netFlag == '0') {
|
||||
// secondtemp.value.forEach((res2 : any) => {
|
||||
// if (res2.name == res1.title) {
|
||||
// res1.url = res2.url
|
||||
// }
|
||||
// })
|
||||
// } else {
|
||||
// res1.url = res1.animationPath
|
||||
// }
|
||||
|
||||
})
|
||||
})
|
||||
smallArray.value = data1;
|
||||
}
|
||||
// })
|
||||
// })
|
||||
// smallArray.value = data1;
|
||||
// }
|
||||
upmenuIndex.value = 1;
|
||||
downmenuIndex.value = 1;
|
||||
thirdmenuIndex.value = 1;
|
||||
|
|
@ -2014,7 +2016,6 @@
|
|||
thirdmenuIndex.value = 0;
|
||||
}, 50)
|
||||
downdonghua.value = 0;
|
||||
geteverything()
|
||||
nextTick(() => {
|
||||
timeNowMove()
|
||||
})
|
||||
|
|
|
|||
|
|
@ -270,17 +270,14 @@
|
|||
|
||||
onMounted(() => {
|
||||
// 矩阵的菜单大量数据
|
||||
getServiceTree0().then((res : any) => {
|
||||
getServiceTree0('1,2,3,4,5').then((res : any) => {
|
||||
console.log(res.result)
|
||||
uni.setStorageSync("saveTree1", res.result.fwzl[1])
|
||||
uni.setStorageSync("saveTree2", res.result.fwzl[2])
|
||||
uni.setStorageSync("saveTree3", res.result.fwzl[3])
|
||||
uni.setStorageSync("saveTree4", res.result.fwzl[4])
|
||||
uni.setStorageSync("saveTree5", res.result.fwzl[5])
|
||||
//缓存护嘱菜单
|
||||
uni.setStorageSync("saveTree0", res)
|
||||
getServiceTree1().then((res : any) => {
|
||||
//缓存护嘱菜单
|
||||
uni.setStorageSync("saveTree1", res)
|
||||
})
|
||||
getServiceTree2().then((res : any) => {
|
||||
//缓存护嘱菜单
|
||||
uni.setStorageSync("saveTree2", res)
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -221,6 +221,7 @@
|
|||
// 缓存表格编辑右侧菜单的功能
|
||||
getServiceTree0().then((res : any) => {
|
||||
//缓存护嘱菜单
|
||||
console.log(res)
|
||||
uni.setStorageSync("saveTree0", res)
|
||||
getServiceTree1().then((res : any) => {
|
||||
//缓存护嘱菜单
|
||||
|
|
|
|||
Loading…
Reference in New Issue