yanzai 1 year ago
commit 37f6e84c94

@ -13,27 +13,29 @@ class FenzhenController extends Controller
// 这里放 弃检逻辑
return \Yz::Return(true, "弃检成功");
}
public function check()
{
// 这里放 检查是否有 体检引导的数据
$id_number =request('id_number');
$list=DB::table('orders')->where(['id_number'=>$id_number])->whereIn('status',[2,4])->get();
return \Yz::Return(true, "弃检成功",['list'=>$list]);
$id_number = request('id_number');
$list = DB::table('orders')->where(['id_number' => $id_number])->whereIn('status', [2, 4])->get();
return \Yz::Return(true, "弃检成功", ['list' => $list]);
}
public function list()
{
$id =request('id');
$info=DB::table('orders')->where(['id'=>$id])->whereIn('status',[2,4])->get();
if(!$info) return \Yz::echoError1("查询就诊人订单失败");
$id = request('id');
$info = DB::table('orders')->where(['id' => $id])->whereIn('status', [2, 4])->first();
if (!$info) return \Yz::echoError1("查询就诊人订单失败");
$end_time = date('H:i', strtotime($info->appointment_date . ' ' . $info->appointment_time) + (60 * 60 * 0.54));
return \Yz::Return(true, "获取成功", [
'info' => [
'name' => $info->name,
'sex' => $info->sex,
'combo_name' => $info->title,
'check_date' => $info->appointment_date,
'start_time' => $info->appointment_time,
'end_time' => '10:25',
'start_time' => $info->appointment_time,
'end_time' => $end_time,
'qrcode' => '',
'code' => $info->appointment_number, // 体检条码
],
@ -43,18 +45,21 @@ class FenzhenController extends Controller
'status' => 4,
'desc' => '已完成',
'tip' => '体检登记 2024-08-09 08:25:30',
'more' => 0
], [
'time' => '08:30',
'name' => '体格检查',
'status' => 4,
'desc' => '已完成',
'tip' => '体格检查 2024-08-09 08:30:33',
'more' => 0
], [
'time' => '08:50',
'name' => '超声科',
'status' => 2,
'desc' => '第5位预计等待 11 分钟',
'tip' => '腹部彩超',
'more' => 0
], [
'time' => '09:20',
'name' => '心电图',
@ -63,36 +68,42 @@ class FenzhenController extends Controller
'tip' => '剩余5项正在排队中',
'more' => 1
], [
'time' => '10:03',
'time' => $end_time,
'name' => '体检结束',
'status' => -1,
'desc' => '早餐时间 10:03'
'desc' => '用餐时间 ' . $end_time,
'tip' => '',
'more' => 0
], [
'time' => '',
'name' => '出具报告',
'status' => -1,
'desc' => '预计 9月23日 出具体检报告'
'desc' => '预计 9月23日 出具体检报告',
'tip' => '',
'more' => 0
], [
'time' => '',
'name' => '报告解读',
'status' => -1,
'desc' => '预计 9月24日 可以预约报告解读'
'desc' => '预计 9月24日 可以预约报告解读',
'tip' => '',
'more' => 0
]],
]);
}
public function info()
{
$id =request('id');
$info=DB::table('orders')->where(['id'=>$id])->whereIn('status',[2,4])->get();
if(!$info) return \Yz::echoError1("查询就诊人订单失败");
$id = request('id');
$info = DB::table('orders')->where(['id' => $id])->whereIn('status', [2, 4])->get();
if (!$info) return \Yz::echoError1("查询就诊人订单失败");
return \Yz::Return(true, "获取成功", [
'info' => [
'name' => $info->name,
'sex' => $info->sex,
'combo_name' => $info->title,
'check_date' => $info->appointment_date,
'start_time' => $info->appointment_time,
'start_time' => $info->appointment_time,
'end_time' => '10:25',
'qrcode' => '',
'code' => $info->appointment_number, // 体检条码

@ -1,5 +1,6 @@
{
"pages": [{
"pages": [
{
"path": "pages/main/index/index",
"style": {
"navigationBarTitleText": "海南现代妇女儿童医院",
@ -13,6 +14,13 @@
"navigationStyle": "custom"
}
},
{
"path": "pages/main/combo/tcdb",
"style": {
"navigationBarTitleText": "套餐对比",
"navigationStyle": "custom"
}
},
{
"path": "pages/main/order/order",
"style": {
@ -83,7 +91,7 @@
{
"path": "pages/main/questionnaire/index",
"style": {
"navigationBarTitleText": "问卷调查",
"navigationBarTitleText": "满意度调查",
"navigationBarBackgroundColor": "#239EA3",
"navigationBarTextStyle": "white"
}
@ -115,6 +123,12 @@
"navigationBarTitleText": "报告查询"
}
},
{
"path": "pages/main/bgcx/bgdb/xzbg/xzbg",
"style": {
"navigationBarTitleText": "选择体检报告"
}
},
{
"path": "pages/main/bgcx/bgjd/bgjd",
"style": {
@ -139,6 +153,12 @@
"navigationBarTitleText": "趋势分析"
}
},
{
"path": "pages/main/bgcx/qsfx/qsfxxq",
"style": {
"navigationBarTitleText": ""
}
},
{
"path": "pages/main/selectDoctor/selectDoctor",
"style": {
@ -158,21 +178,21 @@
}
},
{
"path": "pages/buy/contrast/contrast",
"path": "pages/user/pick/pick",
"style": {
"navigationBarTitleText": "数据对比"
"navigationBarTitleText": "体检引导"
}
},
{
"path": "pages/user/pick/pick",
"path": "pages/user/fenzhen/fenzhen",
"style": {
"navigationBarTitleText": "体检引导"
}
},
{
"path": "pages/user/fenzhen/fenzhen",
"path": "pages/buy/contrast/contrast",
"style": {
"navigationBarTitleText": "体检引导"
"navigationBarTitleText": "数据对比"
}
}
],

@ -29,8 +29,8 @@ const gettjbgInfo = async (index) => {
console.log(tabIndex.value);
console.log($store, "store");
let obj = {
hospital_id:$store.config.hospital[0].id
tj_status: tabIndex.value
tj_status: tabIndex.value,
hospital_id: $store.save.hospital
};
const response = await $api("GetReportList", obj);
$response(response, () => {
@ -57,6 +57,7 @@ const routesDeatils = (val) => {
const tzroutes = (url) => {
//
$store.setTjbgInfo([]);
uni.navigateTo({
url: `/pages/main/bgcx/${url}/${url}`,
});
@ -113,6 +114,12 @@ onShow(() => {
@click="gettjbgInfo(1)"
:class="tabIndex == 1 ? 'bgcx_fullReport_query_button_active' : ''"
class="bgcx_fullReport_query_button"
>已出报告</view
>
<view
@click="gettjbgInfo(2)"
:class="tabIndex == 2 ? 'bgcx_fullReport_query_button_active' : ''"
class="bgcx_fullReport_query_button"
>未出报告</view
>
</view>

@ -1,49 +1,265 @@
<script setup>
/**
* name
* usersa0ChunLuyu
* date2024年9月11日 19:24:50
*/
import {
ref
} from 'vue'
import {
$api,
$response
} from '@/api'
import {
onShow
} from '@dcloudio/uni-app'
import {
useStore
} from '@/store'
const $store = useStore()
const mountedAction = () => {
}
const config_ref = ref(null)
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e
mountedAction()
}
}
onShow(() => {
if (!!config_ref.value) {
mountedAction()
}
})
</script>
<template>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
</view>
</template>
<style scoped>
</style>
<script setup>
/**
* name
* userbgdb
* date2024年9月26日 19:26:00
*/
import { ref } from "vue";
import { $api, $response } from "@/api";
import { onShow } from "@dcloudio/uni-app";
import { useStore } from "@/store";
const $store = useStore();
const dbList = ref([]);
let data = ref({});
const mountedAction = () => {
// uni.showLoading({
// title: "",
// });
let obj = $store.getTjbgInfo();
if (obj.length) {
dbList.value = obj;
console.log($store.getTjbgInfo(), "体检报告");
}
};
const dbResList = ref([]);
let tabIndex = ref(0); //
const getBtn = async (e) => {
tabIndex.value = e;
//dbResList
if (e == 0) {
dbResList.value = data.value?.report_type1_content;
} else {
dbResList.value = data.value?.report_type2_content;
}
};
const duibiclick = async () => {
//
if (dbList.value && dbList.value.length == 2) {
let obj = {
tj_numbers: [dbList.value[0]["体检号"], dbList.value[0]["体检号"]],
};
const response = await $api("ReportContrast", obj);
$response(response, () => {
data.value = response.data;
dbResList.value = data.value?.report_type1_content;
});
} else {
uni.$lu.toast("选择两份报告后在进行对比");
}
};
const delObj = (i) => {
dbList.value.splice(i, 1);
$store.setTjbgInfo(dbList.value);
};
const selectBg = () => {
//
uni.navigateTo({
url: `/pages/main/bgcx/bgdb/xzbg/xzbg`,
});
};
const config_ref = ref(null);
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e;
mountedAction();
}
};
onShow(() => {
if (!!config_ref.value) {
mountedAction();
}
});
</script>
<template>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
<view class="p-20rpx">
<view
class="bg-#EEA61E text-#CF911C bg-op-20 rounded-10rpx p-20rpx flex flex-items-center"
>
<image
class="w-26rpx h-26rpx mr-20rpx"
src="@/static/assets/slices/bgjdtb.png"
></image>
<span class="text-24rpx"
>由于手机上显示体检报告最多选择两份报告对比!</span
>
</view>
<view class="bg-#fff rounded-15rpx p-20rpx mt-20rpx mb-20rpx pb-50rpx">
<!-- list -->
<view class="pb-30rpx">
<view v-for="(item, index) in dbList" :key="index">
<view
style="border-bottom: 1px solid #e6e9e9"
class="flex flex-justify-between text-#101010 text-30rpx pb-20rpx pt-20rpx"
>
<view class="line-clamp-1 flex-1">
{{ item["检前签到时间"]?.split("T").join(" ") }} 体检报告
</view>
<view
@click="delObj(index)"
class="w-48rpx h-48rpx rounded-15rpx flex flex-items-center flex-justify-center right-50rpx top-30px"
>
<uni-icons
type="trash-filled"
color="#E55224"
size="20"
></uni-icons>
</view>
</view>
</view>
</view>
<view
v-if="dbList && dbList.length == 0"
@click="selectBg"
class="bg-#F0F0F0 rounded-10rpx w-477rpx h-242rpx ma flex flex-justify-center mt-20rpx mb-40rpx"
>
<image
class="w-91rpx h-101rpx mt-50rpx"
src="@/static/assets/slices/bgdbadd.png"
></image>
</view>
<view
@click="selectBg"
v-if="dbList && dbList.length == 1"
class="w-520rpx ma bg-#239EA3 rounded-40rpx text-#fff text-26rpx font-500 flex flex-justify-center line-height-[3]"
>
选择报告
</view>
<view
@click="duibiclick"
v-if="dbList.length != 1"
class="w-520rpx ma bg-#239EA3 rounded-40rpx text-#fff text-26rpx font-500 flex flex-justify-center line-height-[3]"
>
报告对比
</view>
</view>
<view
class="bg-#fff rounded-15rpx p-20rpx mt-20rpx mb-20rpx pb-50rpx"
v-if="dbResList && dbResList.length > 0"
>
<view
class="mt-20rpx flex rounded-8rpx w-428rpx h-66rpx ma b-0 b-1 b-solid b-#239EA3"
>
<view
@click="getBtn(0)"
:class="tabIndex == 0 ? 'ckjg_active' : ''"
class="text-#239EA3 flex-1 text-#26rpx bg-#D9F3F2 flex flex-items-center flex-justify-center rounded-l-8rpx"
>
结论对比
</view>
<view
@click="getBtn(1)"
:class="tabIndex == 1 ? 'ckjg_active' : ''"
class="text-#239EA3 flex-1 flex flex-items-center flex-justify-center bg-#D9F3F2 rounded-r-8rpx"
>详情对比
</view>
</view>
<uni-collapse id="collapse-bgdb">
<view
class="mt-35rpx"
v-for="(item, index) in dbResList"
:key="index"
>
<uni-collapse-item
:name="item.id"
:open="true"
:title="item.title"
thumb=""
>
<view class="p-20rpx py-0">
<!-- <view class="p-20rpx pl-30rpx pr-30rpx" v-if="item && item.details"> -->
<view class="flex text-#343434 text-center">
<view
style="border-bottom: 1px solid #d2d2d2"
class="line-height-[2.8] flex-1 mr-25rpx text-#343434 text-24rpx"
>
{{ item.r1.date?.split("T")[0] }}
</view>
<view
style="border-bottom: 1px solid #d2d2d2"
class="line-height-[2.8] flex-1 ml-25rpx text-#343434 text-24rpx"
>
{{ item.r2.date?.split("T")[0] }}
</view>
</view>
<view class="center text-#343434 items-stretch">
<view class="flex-1 mr-20rpx pt-20rpx">
<view v-show="tabIndex == 0" class="whitespace-pre-wrap text-28rpx">
{{ item.r1?.content }}
</view>
<view v-show="tabIndex == 1" class="text-center">
<view class="text-32rpx">
<text class="text-#D01615 text-28rpx">{{
item.r2?.icoin
}}</text
>{{ item.r1?.content }}
</view>
<view class="text-#999999">
*正常范围{{ item.r1?.desc }}
</view>
</view>
</view>
<view class="bg-#D2D2D2 w-1rpx mt-20rpx" />
<view class="flex-1 ml-20rpx pt-20rpx">
<view v-show="tabIndex == 0" class="whitespace-pre-wrap text-28rpx">
{{ item.r2?.content }}
</view>
<view v-show="tabIndex == 1" class="text-center">
<view class="text-32rpx">
<text class="text-#D01615 text-28rpx">{{
item.r2?.icoin
}}</text
>{{ item.r2?.content }}
</view>
<view class="text-#999999">
*正常范围{{ item.r2?.desc }}
</view>
</view>
</view>
</view>
</view>
</uni-collapse-item>
</view>
</uni-collapse>
</view>
</view>
</view>
</template>
<style scoped lang="scss">
::v-deep .uni-collapse-item__title-wrap {
width: 80% !important;
}
::v-deep #collapse-bgdb .uni-collapse-item__title-box,
::v-deep .uni-collapse-item__title {
background: #239ea3 !important;
color: #fff !important;
.uni-icons {
color: #fff !important;
}
}
::v-deep #collapse-bgdb .uni-collapse-item__title.uni-collapse-item-border {
border: none !important;
}
::v-deep
#collapse-bgdb
.uni-collapse-item__wrap
.uni-collapse-item__wrap-content.open {
border: none !important;
}
.ckjg_active {
background: #239ea3;
color: #fff;
}
</style>

@ -0,0 +1,113 @@
<script setup>
/**
* name
* userxzbg
* date2024年9月27日 16:01:08
*/
import { ref } from "vue";
import { $api, $response } from "@/api";
import { onShow } from "@dcloudio/uni-app";
import { useStore } from "@/store";
const $store = useStore();
let bgcx_list = ref([]); //
const mountedAction = () => {
gettjbgInfo();
};
const gettjbgInfo = async () => {
//
console.log($store, "store");
let obj = {
tj_status: 1,
hospital_id: $store.save.hospital,
};
const response = await $api("GetReportList", obj);
$response(response, () => {
console.log(response, "response");
bgcx_list.value = response.data.list;
uni.hideLoading();
});
};
// const bgList = ref([1, 2, 3, 4])
const selectdbObj = async (item) => {
let tjbgList = $store.getTjbgInfo();
if($store.setTjbgInfo?.length < 2){
tjbgList.push(item);
}
$store.setTjbgInfo(tjbgList);
// console.log(item.name)
// item.name
uni.navigateBack({
delta: 1,
});
};
const config_ref = ref(null);
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e;
mountedAction();
}
};
onShow(() => {
if (!!config_ref.value) {
mountedAction();
}
});
</script>
<template>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
<view class="">
<view
style="box-shadow: 0rpx 0rpx 10rpx 0rpx rgba(0, 0, 0, 0.05)"
class="text-24rpx text-#333 m-20rpx p-24rpx bg-#fff rounded-10rpx"
v-for="(item, index) in bgcx_list"
:key="index"
>
<view
class="pb-30rpx text-#0E0E0E text-34rpx flex flex-justify-between"
>
<text class="line-clamp-1">{{ item["套餐名称"] }}</text>
<text
class="w-90rpx h-42rpx bg-#32A8D9 text-#fff text-24rpx rounded-rb-20rpx rounded-lt-20rpx text-center line-height-[1.6]"
>{{ item["团检"] ? "团检" : "个检" }}</text
>
</view>
<view class="pb-15rpx">
<text class="text-#8B8B8B">体检人</text>
<text class="ml-25rpx">{{ item["姓名"] }}</text>
</view>
<view class="pb-15rpx">
<text class="text-#8B8B8B">体检时间</text>
<text>{{ item["检前签到时间"]?.split("T").join(" ") }}</text>
</view>
<view class="pb-15rpx">
<text class="text-#8B8B8B">报告编号</text>
<text>{{ item["体检号"] }}</text>
</view>
<view class="pb-20rpx">
<text class="text-#8B8B8B">报告日期</text>
<text>{{ item["报告日期"]?.split("T").join(" ") }}</text>
</view>
<view
style="border-top: 1px solid #e6e9e9"
class="pt-20rpx flex flex-justify-end"
>
<view
@click="selectdbObj(item)"
class="bg-#33ACB5 w-200rpx rounded-5rpx text-#fff text-center line-height-[2.5]"
>报告对比</view
>
</view>
</view>
</view>
</view>
</template>
<style scoped></style>

@ -28,7 +28,7 @@ const $props = defineProps({
const bgjl_obj = ref(false);
const wzbg_list = ref(null);
let tabIndex = ref(0); //
let tabIndex = ref(1); //
let currentIndex = ref(0); //
const getBtn = (e) => {
@ -40,7 +40,7 @@ const getList = async () => {
console.log(tabIndex.value, "tabIndex");
let obj = {
tijian_num: tjhNum.value, //
hospital_id:$store.config.hospital[0].id
hospital_id: $store.save.hospital,
};
let url = "GetReportJieLunJianYi";
if (tabIndex.value == 1) {
@ -50,7 +50,11 @@ const getList = async () => {
$response(response, () => {
console.log(response.data, "response");
if (tabIndex.value == 1) {
for (let key in response.data.list) {
response.data.list[key].isopen = false;
}
wzbg_list.value = response.data.list;
console.log(response.data.list);
} else {
bgjl_obj.value = response.data.info;
}
@ -74,15 +78,9 @@ const configRef = (e) => {
};
const dqArr = ref([]);
const collapseClick = async (e) => {
console.log(e);
let id = ""; //id
let itemWithId120 = null; //iditemWithId120['details']
if (e && e.length > 0) {
id = e[e.length - 1];
let isHas = dqArr.value.includes(id);
if (isHas) {
return;
}
let id = e; //id
let itemWithId120 = null; //id itemWithId120['details']
if (e) {
for (let key in wzbg_list.value) {
if (
wzbg_list.value.hasOwnProperty(key) &&
@ -92,7 +90,11 @@ const collapseClick = async (e) => {
break; // 退
}
}
console.log(wzbg_list.value, "wzbg_list", itemWithId120, "itemWithId120");
// return
if(itemWithId120.hasOwnProperty("details")){
console.log(itemWithId120["details"], "itemWithId120");
return
}
uni.showLoading({
title: "加载中",
});
@ -102,44 +104,49 @@ const collapseClick = async (e) => {
const response = await $api("GetReportDetai", obj);
console.log(response);
$response(response, () => {
console.log(response.data, "详情");
if (response.data.list) {
response.data.list.forEach((item) => {
let range = item["结果值范围"].split("-");
if (range.length === 2) {
item.minNum = parseFloat(range[0]);
item.maxNum = parseFloat(range[1]);
}
});
}
itemWithId120["details"] = response.data;
itemWithId120.isopen = itemWithId120.isopen
? !itemWithId120.isopen
: true;
console.log(itemWithId120["details"], "itemWithId120");
// itemWithId120.isopen = itemWithId120.isopen
// ? !itemWithId120.isopen
// : true;
itemWithId120.isopen = true;
});
uni.hideLoading();
dqArr.value = e;
}
};
const getOpenClick = () => {
isopen.value = !isopen.value;
console.log(wzbg_list.value);
for (let key in wzbg_list.value) {
wzbg_list.value[key].isopen = !wzbg_list.value[key].isopen;
}
console.log(wzbg_list.value);
// open
};
const calculatePercentage = (value, start, end) => {
//
const rangeLength = end - start;
const widthFull = rangeLength * 2;
let num = (value / widthFull).toFixed(2);
console.log(num);
if (num < 0) {
num = 0;
const calculatePercentage = (value, start, end, maxNum) => {
if (value >= start && value <= end) {
const rangeLength = end - start;
const distanceFromStart = value - start;
const proportion = distanceFromStart / rangeLength;
const percentage = proportion * 50 + 25;
return percentage.toFixed(2);
}
if (num > 1) {
num = 1;
if (value < start) {
const rangeLength = start;
const distanceFromStart = value;
const proportion = distanceFromStart / rangeLength;
const percentage = proportion * 25;
return percentage.toFixed(2);
}
if (value > end) {
const rangeLength = maxNum - end;
const distanceFromStart = value - end;
const proportion = distanceFromStart / rangeLength;
const percentage = proportion * 25 + 75;
return percentage.toFixed(2);
}
return num * 100;
};
onShow(() => {
@ -269,13 +276,15 @@ onShow(() => {
<view class="rounded-15rpx bg-#fff pt-22rpx pb-22rpx">
<view
class="w-154rpx h-60rpx rounded-r-30rpx text-center line-height-[2.3] text-#123531 text-25rpx font-500"
class="w-154rpx h-60rpx rounded-r-30rpx text-center center text-#123531 text-25rpx font-500"
style="background: linear-gradient(90deg, #edf6f5 0%, #bbdfe1 99%)"
>
总检建议
</view>
<view class="pl-15rpx pr-25rpx pt-45rpx box-border">
<text>{{ bgjl_obj.content }}</text>
<text class="text-#0B0B0B line-height-[2] text-26rpx">{{
bgjl_obj.content
}}</text>
<!-- <view class=" flex flex-justify-between line-height-[2]">
@ -322,144 +331,173 @@ onShow(() => {
</view>
<!-- 展开全部 -->
</view>
<uni-collapse
class="collapse-w"
@change="collapseClick($event)"
v-model="currentIndex"
>
<view
class="position-relative"
v-for="(item, index) in wzbg_list"
:key="index"
<view v-for="(item, index) in wzbg_list">
<uni-collapse
class="collapse-w"
@change="collapseClick"
v-model="currentIndex"
accordion
>
<view
v-if="item && item.error_count > 0"
class="position-absolute top-10px right-40px text-#6D6D6D text-15px"
>
<span class="text-#E46B1A">{{ item.error_count }}</span> 项异常
</view>
<uni-collapse-item
:name="item.id"
:open="item.isopen"
:title="index"
thumb=""
>
<view class="position-relative" :key="index">
<view
class="p-20rpx pl-30rpx pr-30rpx"
v-if="item && item.details"
v-if="item && item.error_count > 0"
class="position-absolute line-height-[96rpx] right-40px text-#6D6D6D text-15px"
>
<span class="text-#E46B1A">{{ item.error_count }}</span>
项异常
</view>
<uni-collapse-item
:name="item.id"
:open="item.isopen"
thumb=""
:title="index"
>
<view
class="bg-#FBF0EE b-0 b-1 b-solid b-#EADEDB rounded-15rpx pb-10rpx"
:class="item.error_count == 0 ? 'greenClor' : ''"
class="p-20rpx pl-30rpx pr-30rpx"
v-if="item && item.details"
>
<view
:class="item.error_count == 0 ? 'greenTextClor' : ''"
class="w-141rpx line-height-[2] text-center text-#fff bg-#F6725B rounded-lt-15rpx rounded-rb-15rpx text-22rpx"
class="bg-#FBF0EE b-0 b-1 b-solid b-#EADEDB rounded-15rpx pb-10rpx"
:class="item.error_count == 0 ? 'greenClor' : ''"
>
初步意见
</view>
<template v-if="item.error_count > 0">
<view
class="text-#E33939 text-22rpx line-height-[2] pl-20rpx pr-20rpx"
v-for="(text, i) in item.details.error_items"
:key="i"
:class="item.error_count == 0 ? 'greenTextClor' : ''"
class="w-141rpx line-height-[2] text-center text-#fff bg-#F6725B rounded-lt-15rpx rounded-rb-15rpx text-22rpx"
>
{{ text }}
初步意见
</view>
</template>
<view
class="text-#239EA3 text-22rpx line-height-[2] pl-20rpx pr-20rpx"
v-else
>
<!-- {{item.details.error_items.length}} -->
<text
v-if="
!item.details.suojian || !item.details.error_items
"
>
未见明显异常</text
<template v-if="item.error_count > 0">
<view
class="text-#E33939 text-22rpx line-height-[2] pl-20rpx pr-20rpx"
v-for="(text, i) in item.details.error_items"
:key="i"
>
{{ text }}
</view>
</template>
<view
class="text-#239EA3 text-22rpx line-height-[2] pl-20rpx pr-20rpx"
v-else
>
<template v-else>
<!-- {{item.details.error_items.length}} -->
<text
v-for="(text, i) in item.details.suojian"
:key="i"
v-if="
!item.details.suojian?.length && !item.details.error_items?.length
"
>
{{ text }}</text
未见明显异常</text
>
</template>
</view>
</view>
<view v-if="1 < 0" class="flex flex-justify-around m-20rpx">
<view>
<view class="text-36rpx font-500"> 162.0 </view>
<view class="text-20rpx"> 身高cm </view>
</view>
<view>
<view class="text-40rpx font-500"> 58.8 </view>
<view class="text-20rpx"> 体重Kg </view>
<template v-else>
<text
v-for="(text, i) in item.details.suojian"
:key="i"
>
{{ text }}</text
>
</template>
</view>
</view>
</view>
<view class="p-10rpx pt-20rpx pb-20rpx">
<view v-for="(obj, i) in item.details.list" :key="i">
<view class="font-500 text-24rpx line-height-[2]">
{{ obj["基础项目名称"] }}
<span class="text-#737373 text-18rpx"
>( {{ obj["结果值单位"] }})</span
>
<!-- <view v-if="1 < 0" class="flex flex-justify-around m-20rpx">
<view>
<view class="text-36rpx font-500"> 162.0 </view>
<view class="text-20rpx"> 身高cm </view>
</view>
<view class="pt-80rpx pb-30rpx">
<view class="h-4rpx bg-#E2E2E2 rounded-2rpx relative">
<view
class="bg-#239EA3 h-3rpx w-50% rounded-2rpx ma flex text-24rpx text-#7B7B7B flex-justify-between"
>
<!-- {{obj['结果值范围']}} -->
<text>{{ obj.minNum }}</text>
<text>正常</text>
<text>{{ obj.maxNum }}</text>
</view>
<view
class="center flex-col absolute"
:style="{
left:
calculatePercentage(
obj['结果值'],
obj.minNum,
obj.maxNum
) + '%',
}"
<view>
<view class="text-40rpx font-500"> 58.8 </view>
<view class="text-20rpx"> 体重Kg </view>
</view>
</view> -->
<view class="p-10rpx pt-20rpx pb-20rpx">
<view v-for="(obj, k) in item.details.list" :key="k">
<view class="font-500 text-24rpx line-height-[2]">
{{ obj["基础项目名称"] }}
<span class="text-#737373 text-18rpx"
>( {{ obj["结果值单位"] }})</span
>
</view>
<view class="pt-80rpx pb-30rpx">
<view class="h-4rpx bg-#E2E2E2 rounded-2rpx relative">
<view
class="text-#239EA3 text-34rpx absolute top--50rpx"
class="bg-#239EA3 h-4rpx w-50% rounded-2rpx ma flex text-24rpx text-#7B7B7B flex-justify-between"
>
<text>{{ obj["结果值"] }}</text>
<uni-icons
v-if="obj['结果值'] < obj.minNum"
type="arrow-down"
:size="18"
></uni-icons>
<uni-icons
v-if="obj['结果值'] > obj.maxNum"
type="arrow-up"
:size="18"
></uni-icons>
<!-- {{obj['结果值范围']}} -->
<text>{{ obj["结果值范围"][0] }}</text>
<text>正常</text>
<text>{{ obj["结果值范围"][1] }}</text>
</view>
<view
class="w-8rpx h-8rpx rounded-50% bg-#fff b-4rpx b-solid b-#1F8F94 absolute -top-8rpx"
v-if="
obj['结果值'] < obj['结果值范围'][0] ||
obj['结果值'] > obj['结果值范围'][1]
"
class="bg-#F8C9C7 h-4rpx w-25% rounded-2rpx ma absolute bottom-0"
:class="{
'left-0': obj['结果值'] < obj['结果值范围'][0],
'right-0': obj['结果值'] > obj['结果值范围'][1],
}"
></view>
<view
class="center flex-col absolute"
:style="{
left:
calculatePercentage(
obj['结果值'],
obj['结果值范围'][0],
obj['结果值范围'][1],
obj['最大范围'][1]
) + '%',
}"
>
<view
class="text-34rpx absolute top--50rpx"
:class="{
'text-#239EA3':
obj['结果值'] >= obj['结果值范围'][0] &&
obj['结果值'] <= obj['结果值范围'][1],
'text-#F34932':
obj['结果值'] < obj['结果值范围'][0] ||
obj['结果值'] > obj['结果值范围'][1],
}"
>
<text>{{ obj["结果值"] }}</text>
<uni-icons
v-if="obj['结果值'] < obj['结果值范围'][0]"
type="arrow-down"
:size="16"
color="#F34932"
></uni-icons>
<uni-icons
v-if="obj['结果值'] > obj['结果值范围'][1]"
type="arrow-up"
:size="16"
color="#F34932"
></uni-icons>
</view>
<view
class="w-8rpx h-8rpx rounded-50% bg-#fff b-4rpx b-solid absolute -top-8rpx"
:class="{
'b-#1F8F94':
obj['结果值'] >= obj['结果值范围'][0] &&
obj['结果值'] <= obj['结果值范围'][1],
'b-#F34932':
obj['结果值'] < obj['结果值范围'][0] ||
obj['结果值'] > obj['结果值范围'][1],
}"
>
</view>
</view>
</view>
</view>
</view>
<view class=""> </view>
</view>
<view class=""> </view>
</view>
</view>
</uni-collapse-item>
</view>
</uni-collapse>
</uni-collapse-item>
</view>
</uni-collapse>
</view>
</view>
</view>
</view>

@ -1,49 +1,74 @@
<script setup>
/**
* name
* usersa0ChunLuyu
* date2024年9月11日 19:24:50
*/
import {
ref
} from 'vue'
import {
$api,
$response
} from '@/api'
import {
onShow
} from '@dcloudio/uni-app'
import {
useStore
} from '@/store'
const $store = useStore()
/**
* name
* usersa0ChunLuyu
* date2024年9月11日 19:24:50
*/
import { ref } from "vue";
import { $api, $response } from "@/api";
import { onShow } from "@dcloudio/uni-app";
import { useStore } from "@/store";
const $store = useStore();
const mountedAction = () => {
let list = ref([]);
const mountedAction = () => {
AnalysisTypeGetList();
};
}
const AnalysisTypeGetList = async () => {
const response = await $api("AnalysisTypeGetList");
$response(response, () => {
console.log(response)
list.value = response.data.list;
});
};
const config_ref = ref(null)
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e
mountedAction()
}
}
const toRouter = (index, i) => {
uni.navigateTo({
url: "/pages/main/bgcx/qsfx/qsfxxq?i=" + i + "&index=" + index,
});
};
onShow(() => {
if (!!config_ref.value) {
mountedAction()
}
})
const config_ref = ref(null);
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e;
mountedAction();
}
};
onShow(() => {
if (!!config_ref.value) {
mountedAction();
}
});
</script>
<template>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
</view>
</template>
<style scoped>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
</style>
<view>
<view v-for="(item, index) in list" :key="index" class="flex flex-col mt-25rpx">
<view
class="w-180rpx rounded-r-full text-#0E0E0E text-25rpx px-40rpx center justify-start h-60rpx box-border bg-gradient-to-r from-#edf6f5 to-#bbdfe2"
>
{{ item.title }}
</view>
<view class="p-20rpx">
<view v-for="(val, i) in item.list" :key="i" class="mb-10rpx p-[25rpx_20rpx_0rpx_10rpx] box-border between bg-#F1F7F7 rounded-10rpx" @click="toRouter(index, i)">
<view :style="{'background-color': val.color}" class="w-60rpx h-60rpx rounded-full mr-30rpx"></view>
<view class="flex flex-col mr-auto">
<text class="text-#222222 text-28rpx">{{ val.name }}</text>
<text class="text-#939898 text-22rpx">{{ val.desc }}</text>
</view>
<uni-icons type="right" size="15" color="#6A6A6A"></uni-icons>
</view>
</view>
</view>
</view>
</view>
</template>
<style scoped></style>

@ -0,0 +1,59 @@
<script setup>
/**
* name
* usersa0ChunLuyu
* date2024年9月11日 19:24:50
*/
import { ref } from "vue";
import { $api, $response } from "@/api";
import { onShow } from "@dcloudio/uni-app";
import { useStore } from "@/store";
const $store = useStore();
const $props = defineProps({
index: {
type: String,
default: ''
},
i: {
type: String,
default: ''
}
});
let details = ref({});
const mountedAction = () => {
AnalysisTypeGetList();
};
const AnalysisTypeGetList = async () => {
const response = await $api("AnalysisTypeGetList");
$response(response, () => {
details.value = response.data.list[$props.index].list[$props.i];
console.log(details.value);
});
};
const config_ref = ref(null);
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e;
mountedAction();
}
};
onShow(() => {
if (!!config_ref.value) {
mountedAction();
}
});
</script>
<template>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
</view>
</template>
<style scoped></style>

@ -19,46 +19,96 @@ const $props = defineProps({
const combo_active = ref("");
const person_active = ref("");
const selectItemClick = (type, value) => {
select_active.value[type] = value;
};
const selectDone = () => {
combo_active.value = select_active.value.combo;
person_active.value = select_active.value.person;
select_drawer_ref.value.close();
};
const clearSelectClick = () => {
combo_active.value = "";
person_active.value = "";
};
const combo_select = ref({
combo: [],
person: [],
});
const comboActiveName = () => {
for (let i in combo_select.value.combo) {
if (combo_select.value.combo[i].value === combo_active.value) {
return combo_select.value.combo[i].label;
let popup = ref(null);
let selectKey = ref(""); // key
let sortIndex = ref(0); //
let comboIndex = ref(null); //
let crowdIndex = ref(null); //
let priceIndex = ref(null); //
let projectIds = ref([]); // id
let screenObj = ref({}); //
let combo_select = ref({}); //
let comboIds = ref([]); //
const selectItemClick = async (index, key) => {
//
let data = combo_select.value;
if (selectKey.value == "sort_list") {
if (sortIndex.value == index) {
sortIndex.value = 0;
} else {
sortIndex.value = index;
}
screenObj.value.combo_sort = data[selectKey.value][index]?.id;
} else if (selectKey.value == "combo_type") {
if (comboIndex.value == index) {
comboIndex.value = null;
delete screenObj.value.combo_type;
} else {
comboIndex.value = index;
screenObj.value.combo_type = data[selectKey.value][index]?.id;
}
} else if (selectKey.value == "combo_crowd") {
if (crowdIndex.value == index) {
crowdIndex.value = null;
delete screenObj.value.combo_crowd;
} else {
crowdIndex.value = index;
screenObj.value.combo_crowd = data[selectKey.value][index]?.id;
}
} else {
if (key == "combo_price") {
if (priceIndex.value == index) {
priceIndex.value = null;
return;
}
priceIndex.value = index;
} else {
if (projectIds.value.includes(index)) {
projectIds.value.splice(projectIds.value.indexOf(index), 1);
} else {
projectIds.value.push(index);
}
}
return;
}
return "套餐类型";
await getComboList();
popup.value.close();
};
const personActiveName = () => {
for (let i in combo_select.value.person) {
if (combo_select.value.person[i].value === person_active.value) {
return combo_select.value.person[i].label;
}
const selectDone = async () => {
if (priceIndex.value === null) {
delete screenObj.value.combo_price;
} else {
screenObj.value.combo_price =
combo_select.value["combo_price"][priceIndex.value]?.id;
}
if (projectIds.value.length) {
screenObj.value.combo_item = projectIds.value;
} else {
delete screenObj.value.combo_item;
}
return "适用人群";
await getComboList();
select_drawer_ref.value.close();
};
const remake = () => {
//
delete screenObj.value.combo_price;
delete screenObj.value.combo_item;
priceIndex.value = null;
projectIds.value = [];
};
const getComboSelect = async () => {
uni.showLoading();
const response = await $api("ComboSelect");
const response = await $api("GetComboSort");
uni.hideLoading();
$response(response, () => {
$response(response, async () => {
combo_select.value = response.data;
getComboList();
if ("sort_list" in combo_select.value) {
selectKey.value = "sort_list";
sortIndex.value = 0;
}
await getComboList();
});
};
@ -74,6 +124,7 @@ const combo_list = ref({
name: "",
},
});
const combo_list_computed = computed(() => {
let list = [];
for (let i in combo_list.value.list) {
@ -104,19 +155,33 @@ const combo_list_computed = computed(() => {
});
const getComboList = async () => {
uni.showLoading();
const response = await $api("ComboList", {
let obj = {
doctor: $store.save.doctor,
hospital: hospital_active.value,
});
};
if (screenObj.value) {
obj = Object.assign(obj, screenObj.value);
}
const response = await $api("ComboList", obj);
uni.hideLoading();
$response(response, () => {
combo_list.value = response.data;
});
};
const contrastClick = async (item) => {
if (comboIds.value.includes(item.combo_id)) {
comboIds.value.splice(comboIds.value.indexOf(item.combo_id), 1);
} else {
comboIds.value.push(item.combo_id);
}
$store.setComboContrast(comboIds.value);
};
const hospital_active = ref(0);
const checkHospital = () => {
let hospital_id = $store.save.hospital;
comboIds.value = $store.getComboContrast() || [];
if (!hospital_id) {
hospital_id = $store.config.hospital[0].id;
}
@ -127,6 +192,29 @@ const checkHospital = () => {
getComboSelect();
};
const tabPatients = () => {
uni.navigateTo({
url: "/pages/user/choose/choose",
});
};
const open = (key) => {
if (key) {
//
selectKey.value = key;
popup.value.close();
let time = setTimeout(() => {
popup.value.open("top");
clearTimeout(time);
}, 400);
} else {
//
popup.value.close();
selectKey.value = "screen";
select_drawer_ref.value.open();
}
};
const config_ref = ref(null);
const configRef = (e) => {
if (!config_ref.value) {
@ -139,17 +227,6 @@ const select_drawer_ref = ref(null);
const selectDrawerRef = (e) => {
select_drawer_ref.value = e;
};
const select_active = ref({
combo: "",
person: "",
});
const selectShow = () => {
select_active.value = {
combo: combo_active.value,
person: person_active.value,
};
select_drawer_ref.value.open();
};
onShow(() => {
if (!!config_ref.value) {
@ -160,25 +237,26 @@ onShow(() => {
const buyClick = async (item) => {
let query = "?comboId=" + item.combo_id;
if ($props.groupId) {
// ID
// ID
query += "&groupId=" + $props.groupId;
}
// ID
// ID
// /
uni.navigateTo({
url: "/pages/main/tj/tjxq" + query,
});
};
const toComboCompare = async (item) => {
for(let i in $store.combo_compare){
if(!$store.combo_compare[Number(i)]){
$store.combo_compare[Number(i)] = item.combo_id;
break;
}
}
const toRouter = () => {
if(!comboIds.value.length){
uni.showToast({
title: "请先选择套餐",
icon: "none",
});
return
}
uni.navigateTo({
url: "/pages/buy/contrast/contrast"
url: "/pages/main/combo/tcdb",
});
};
</script>
@ -189,6 +267,24 @@ const toComboCompare = async (item) => {
</view>
<view class="header_wrapper">
<view
@click="toRouter"
class="center fixed pt-10rpx box-border left-40rpx bottom-5% rounded-full w-110rpx h-110rpx bg-#239EA3 flex-col"
>
<uni-badge
:text="comboIds.length"
absolute="rightTop"
size="small"
>
<image
src="@/static/assets/slices/duibi.png"
mode="widthFix"
class="w-42rpx"
/>
</uni-badge>
<text class="text-22rpx text-#fff -mt-5rpx">对比</text>
</view>
<view v-if="!!combo_list.hospital.id" class="hospital_wrapper">
<view class="hospital_icon_wrapper">
<image src="@/static/assets/dingwei@2x.png"></image>
@ -200,7 +296,11 @@ const toComboCompare = async (item) => {
<image src="@/static/assets/gengduo@2x.png"></image>
</view>
</view>
<view v-if="!!combo_list.info.name" class="user_wrapper">
<view
v-if="!!combo_list.info.name"
class="user_wrapper"
@click="tabPatients()"
>
<view class="user_title_wrapper">就诊人</view>
<view class="user_name_wrapper">{{ combo_list.info.name }}</view>
<view v-if="combo_list.info.count > 1" class="user_choose_wrapper">
@ -208,56 +308,50 @@ const toComboCompare = async (item) => {
</view>
</view>
</view>
<view class="doctor_wrapper">
<view class="doctor_tip_wrapper">
<text v-if="!!combo_list.doctor.id"></text>
<text v-else></text>
</view>
<view class="doctor_name_wrapper">
{{ !!combo_list.doctor.id ? combo_list.doctor.name : "前往选择" }}
</view>
<view class="doctor_tip_wrapper">自动筛选匹配套餐</view>
</view>
<view class="select_wrapper">
<view
@click="clearSelectClick()"
class="select_item_wrapper"
:class="[!combo_active && !person_active ? 'active' : '']"
>
<view class="select_item_name_wrapper">综合排序</view>
<view class="select_item_icon_wrapper">
<image src="@/static/assets/xuanzegengduo@2x.png"></image>
<view class="relative z-999 pt-10rpx center">
<view class="doctor_wrapper">
<view class="doctor_tip_wrapper">
<text v-if="!!combo_list.doctor.id"></text>
<text v-else></text>
</view>
<view class="select_item_line_wrapper"></view>
</view>
<view
@click="selectShow()"
class="select_item_wrapper"
:class="[!!combo_active ? 'active' : '']"
>
<view class="select_item_name_wrapper">{{
!!combo_active ? comboActiveName() : "套餐类型"
}}</view>
<view class="select_item_icon_wrapper">
<image src="@/static/assets/xuanzegengduo@2x.png"></image>
<view class="doctor_name_wrapper">
{{ !!combo_list.doctor.id ? combo_list.doctor.name : "前往选择" }}
</view>
<view class="select_item_line_wrapper"></view>
<view class="doctor_tip_wrapper">自动筛选匹配套餐</view>
</view>
</view>
<view class="select_wrapper flex" v-if="selectKey">
<template v-for="(value, key, index) in combo_select" :key="index">
<view
@click="open(key)"
class="flex-1 center text-#2f2f2f text-26rpx line-height-[1]"
v-if="key != 'combo_price' && key != 'combo_item'"
:class="{
'!text-#239EA3': selectKey == key,
}"
>
<view v-if="key == 'sort_list'">
{{ value[sortIndex]?.name || "综合排序" }}
</view>
<view v-if="key == 'combo_type'">
{{ value[comboIndex]?.name || "套餐类型" }}
</view>
<view v-if="key == 'combo_crowd'">
{{ value[crowdIndex]?.name || "适用人群" }}
</view>
<view class="select_item_icon_wrapper">
<image src="@/static/assets/xuanzegengduo@2x.png"></image>
</view>
</view>
</template>
<view
@click="selectShow()"
class="select_item_wrapper"
:class="[!!person_active ? 'active' : '']"
@click="open()"
:class="{
'!text-#239EA3': selectKey == 'screen',
}"
class="mx-20rpx center text-#2f2f2f text-26rpx"
>
<view class="select_item_name_wrapper">{{
!!person_active ? personActiveName() : "适用人群"
}}</view>
<view class="select_item_icon_wrapper">
<image src="@/static/assets/xuanzegengduo@2x.png"></image>
</view>
<view class="select_item_line_wrapper"></view>
</view>
<view @click="selectShow()" class="select_item_wrapper">
<view class="select_item_name_wrapper">筛选</view>
<view>筛选</view>
<view class="select_item_icon2_wrapper">
<image src="@/static/assets/shaixuan@2x.png"></image>
</view>
@ -308,7 +402,9 @@ const toComboCompare = async (item) => {
</view>
</view>
<view class="combo_button_wrapper">
<view @click="toComboCompare(i)" class="combo_pick_button_wrapper">对比</view>
<view @click="contrastClick(i)" class="combo_pick_button_wrapper">{{
comboIds.includes(i.combo_id) ? "已加入" : "对比"
}}</view>
<view class="combo_buy_button_wrapper" @click="buyClick(i)"
>预约</view
>
@ -316,54 +412,114 @@ const toComboCompare = async (item) => {
<view class="combo_line_wrapper"></view>
</view>
</view>
<uni-popup ref="popup" mask-background-color="transparent">
<view class="pt-260rpx w-full h-100vh" @click="popup.close()">
<view class="bg-[rgba(0,0,0,0.3)] h-100%">
<view
class="bg-#fff"
:class="
selectKey != 'sort_list'
? 'flex pt20rpx px10rpx pb0 box-border flex-wrap'
: ''
"
>
<view
v-for="(val, index) in combo_select[selectKey]"
:key="index"
@click.stop="selectItemClick(index)"
:class="{
'min-w-23% mx-1% mb-20rpx': selectKey != 'sort_list',
}"
>
<uni-list-item v-if="selectKey == 'sort_list'">
<template v-slot:body>
<text
class="text-26rpx"
:class="{
'!text-#239EA3': sortIndex == index,
}"
>{{ val.name }}</text
>
</template>
</uni-list-item>
<view
v-else
class="box-border px-28rpx py-20rpx text-26rpx center line-height-[1] rounded-5rpx"
:class="{
'!bg-#239EA3 !text-#fff':
(selectKey == 'combo_type' && comboIndex == index) ||
(selectKey == 'combo_crowd' && crowdIndex == index),
'!text-#747474 !bg-#e0e0e0':
(selectKey == 'combo_type' && comboIndex != index) ||
(selectKey == 'combo_crowd' && crowdIndex != index),
}"
>{{ val.name }}</view
>
</view>
</view>
</view>
</view>
</uni-popup>
<uni-drawer :ref="selectDrawerRef" mode="right" :mask-click="false">
<view>
<scroll-view scroll-y="true">
<view>
<view class="select_group_wrapper">
<view class="select_group_title_wrapper">套餐类型</view>
<view class="select_group_line_wrapper">
<view class="text-30rpx bold">套餐价格</view>
<view class="select_group_line_wrapper mt-20rpx">
<view
@click="selectItemClick('combo', '')"
class="select_group_item_wrapper"
:class="[select_active.combo === '' ? 'active' : '']"
v-for="(val, index) in combo_select['combo_price']"
:key="index"
@click.stop="selectItemClick(index, 'combo_price')"
class="min-w-31% mx-1% mb-20rpx"
>
全部
</view>
<view
@click="selectItemClick('combo', i.value)"
class="select_group_item_wrapper"
v-for="(i, k) in combo_select.combo"
:key="k"
:class="[select_active.combo === i.value ? 'active' : '']"
>
{{ i.label }}
<view
class="box-border px-20rpx py-20rpx text-22rpx center line-height-[1] rounded-5rpx"
:class="{
'!bg-#239EA3 !text-#fff':
selectKey == 'screen' && priceIndex == index,
'!text-#747474 !bg-#e0e0e0':
selectKey == 'screen' && priceIndex != index,
}"
>{{ val.name }}</view
>
</view>
</view>
</view>
<view class="select_group_wrapper">
<view class="select_group_title_wrapper">适用人群</view>
<view class="select_group_line_wrapper">
<view
@click="selectItemClick('person', '')"
class="select_group_item_wrapper"
:class="[select_active.person === '' ? 'active' : '']"
>
全部
</view>
<view class="text-30rpx bold">适用人群</view>
<view class="select_group_line_wrapper mt-20rpx">
<view
@click="selectItemClick('person', i.value)"
class="select_group_item_wrapper"
v-for="(i, k) in combo_select.person"
:key="k"
:class="[select_active.person === i.value ? 'active' : '']"
v-for="(val, index) in combo_select['combo_item']"
:key="index"
@click.stop="selectItemClick(val.id, 'combo_item')"
class="min-w-31% mx-1% mb-20rpx"
>
{{ i.label }}
<view
class="box-border px-20rpx py-20rpx text-22rpx center line-height-[1] rounded-5rpx"
:class="{
'!bg-#239EA3 !text-#fff':
selectKey == 'screen' && projectIds.includes(val.id),
'!text-#747474 !bg-#e0e0e0':
selectKey == 'screen' && !projectIds.includes(val.id),
}"
>{{ val.name }}</view
>
</view>
</view>
</view>
<view class="select_done_wrapper" @click="selectDone()"></view>
<view class="around">
<view
class="w-40% text-26rpx h-60rpx center rounded-full bg-#239EA3 text-#fff"
@click="remake()"
>重制</view
>
<view
class="w-40% text-26rpx h-60rpx center rounded-full bg-#239EA3 text-#fff"
@click="selectDone()"
>确定</view
>
</view>
</view>
</scroll-view>
</view>
@ -402,11 +558,6 @@ const toComboCompare = async (item) => {
flex-wrap: wrap;
}
.select_group_title_wrapper {
font-size: 30rpx;
font-weight: bold;
}
.select_group_wrapper {
margin: 20rpx;
}
@ -593,6 +744,8 @@ const toComboCompare = async (item) => {
background: #f1f7f7;
box-shadow: 0rpx -1rpx 1rpx 0rpx rgba(0, 0, 0, 0.1);
margin: 0 auto;
position: relative;
z-index: 999;
}
.select_item_icon_wrapper {
@ -671,10 +824,9 @@ const toComboCompare = async (item) => {
align-items: center;
width: 710rpx;
height: 70rpx;
background: #28b7c1;
background: #239ea3;
border-radius: 15rpx 15rpx 0rpx 0rpx;
padding-left: 24rpx;
margin: 10rpx auto 0;
}
.user_choose_wrapper {
@ -723,6 +875,8 @@ const toComboCompare = async (item) => {
height: 100rpx;
background: #d8edf2;
margin: 0 auto;
position: relative;
z-index: 999;
}
.hospital_wrapper {

@ -0,0 +1,161 @@
<script setup>
/**
* name
* usertcdb
* date2024年9月26日 19:26:00
*/
import { ref } from "vue";
import { $api, $response, $image } from "@/api";
import { onShow } from "@dcloudio/uni-app";
import { useStore } from "@/store";
const $store = useStore();
let comboIds = ref([]);
const mountedAction = () => {
comboIds.value = $store.getComboContrast() || [];
getdbAxios();
};
const comboInfo = ref(false);
const getdbAxios = async () => {
uni.showLoading({
title: "加载中",
});
let obj = {
combo_ids: $store.getComboContrast(),
};
const response = await $api("ComboCompare", obj);
$response(response, () => {
comboInfo.value = response.data.list || false;
console.log(response.data, "response.data");
uni.hideLoading();
});
};
const clickdb = async () => {
uni.navigateTo({
url: "/pages/buy/contrast/contrast",
});
};
const config_ref = ref(null);
const configRef = (e) => {
if (!config_ref.value) {
config_ref.value = e;
mountedAction();
}
};
const selectClick = (id, status) => {
if (status) {
comboIds.value.splice(comboIds.value.indexOf(id), 1);
$store.setComboContrast(comboIds.value);
getdbAxios();
return
}
if (comboIds.value.includes(id)) {
comboIds.value.splice(comboIds.value.indexOf(id), 1);
} else {
comboIds.value.push(id);
}
};
onShow(() => {
if (!!config_ref.value) {
mountedAction();
}
});
</script>
<template>
<view>
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
<view class="p-20rpx">
<view
style="border-bottom: 1px solid #e1ecee"
class="flex w-full pb-50rpx mt-50rpx relative"
v-for="(obj, f) in comboInfo"
:key="f"
>
<view class="flex flex-items-center pl-10rpx pr-10rpx pt-10rpx">
<uni-icons
@click="selectClick(obj.combo_id)"
:type="
comboIds.includes(obj.combo_id) ? 'checkbox-filled' : 'circle'
"
color="#239EA3"
size="30"
></uni-icons>
</view>
<view
class="w-48rpx h-48rpx rounded-15rpx bg-#F9E7E7 absolute flex flex-items-center flex-justify-center right-50rpx top-30px"
>
<uni-icons
@click="selectClick(obj.combo_id, 1)"
type="trash-filled"
color="#D70F0F"
size="25"
></uni-icons>
</view>
<!-- 1个检套餐 显示套餐信息 -->
<image
v-if="obj.cover"
:src="$image(obj.cover)"
class="w-190rpx h-190rpx mr-37rpx"
mode="widthFix"
/>
<view class="flex flex-col grow">
<text>{{ obj.name }}</text>
<view class="mt-13rpx mb-18rpx">
<uni-tag
v-for="(val, i) in obj.tag"
:key="i"
size="small"
:inverted="true"
:text="val.text"
class="mr-8rpx"
:custom-style="
'background-color:' +
val.color +
';border-color:' +
val.color +
'; color:' +
val.text_color +
';'
"
/>
</view>
<view v-if="obj.tags2?.length">
<text
v-for="(val, i) in obj.tags2"
:key="i"
class="text-#8B8B8B text-20rpx line-height-[1] px-5rpx b-0 b-solid b-#8B8B8B"
:class="i == obj.tags2?.length - 1 ? 'b-r-0' : 'b-r-2'"
>{{ val }}</text
>
</view>
<view class="mt-20rpx w-full flex items-end">
<text class="text-18rpx text-#EC3D15">¥</text>
<text class="text-38rpx text-#EC3D15 mx-10rpx -mb-8rpx">{{
obj.price
}}</text>
<text class="text-18rpx text-#878787 line-through">{{
obj.original_price
}}</text>
<text class="text-18rpx text-#878787 ml-auto mr-55rpx"
>已售{{ obj.saleCount }}</text
>
</view>
</view>
</view>
</view>
<view
@click="clickdb"
class="h-110rpx bg-#239EA3 text-#fff text-32rpx flex flex-justify-center flex-items-center absolute bottom-0 w-100%"
>
开始对比
</view>
</view>
</template>
<style scoped></style>

File diff suppressed because it is too large Load Diff

@ -18,9 +18,27 @@
useStore
} from '@/store'
const $store = useStore()
const $props = defineProps({
id: {
type: String,
default: '0'
}
});
const mountedAction = () => {
const fenzhen_list = ref(false)
const getFenzhenList = async () => {
uni.showLoading()
const response = await $api('FenzhenList', {
id: $props.id
})
uni.hideLoading()
$response(response, () => {
fenzhen_list.value = response.data
})
}
const mountedAction = () => {
getFenzhenList()
}
const config_ref = ref(null)
@ -31,6 +49,30 @@
}
}
const timeShow = (time) => {
let time_array = time.split(':')
return `${time_array[0]}:${time_array[1]}`
}
const tip_show = ref(false)
const tip_content = ref("")
const getTipContent = async () => {
uni.showLoading()
const response = await $api('GetReadme')
uni.hideLoading()
$response(response, () => {
tip_content.value = response.data.content
tip_show.value = true
})
}
const tipShowClick = () => {
if (!!tip_content.value) {
tip_show.value = true
} else {
getTipContent()
}
}
onShow(() => {
if (!!config_ref.value) {
mountedAction()
@ -42,8 +84,466 @@
<view v-if="!!$store.config">
<view :ref="configRef"></view>
</view>
<view class="tip_dialog_wrapper" v-if="!!tip_show">
<view class="tip_dialog_box_wrapper">
<view @click="tip_show = !tip_show" class="tip_dialog_close_wrapper">
<image src="@/static/assets/contrast/close@2x.png"></image>
</view>
<view class="tip_dialog_text_wrapper" v-html="tip_content"></view>
</view>
</view>
<view v-if="!!fenzhen_list">
<view class="order_info_wrapper">
<view class="person_name_wrapper">
<view class="person_name_text_wrapper">{{ fenzhen_list.info.name }}</view>
<view class="person_sex_wrapper">{{ fenzhen_list.info.sex === 1 ? '男士' : '女士' }}</view>
</view>
<view class="info_box_wrapper">
<view class="info_wrapper">
<view class="info_title_wrapper">体检套餐</view>
<view class="info_text_wrapper">{{ fenzhen_list.info.combo_name }}</view>
</view>
<view class="info_wrapper info2_wrapper">
<view class="info_title_wrapper">体检日期</view>
<view class="info_text_wrapper">{{ fenzhen_list.info.check_date }}</view>
</view>
</view>
<view class="button_wrapper">
<view @click="tipShowClick()" class="desc_wrapper">体检注意事项</view>
</view>
</view>
<view class="tip_wrapper">
<view class="tip_time_wrapper">
<view class="tip_time_text_wrapper">开始体检时间</view>
<view class="tip_time_value_wrapper">{{ timeShow(fenzhen_list.info.start_time) }}</view>
<view class="tip_time_text_wrapper"> 预计结束时间</view>
<view class="tip_time_value_wrapper">{{ timeShow(fenzhen_list.info.end_time) }}</view>
</view>
<view class="tip_box_wrapper">
<view class="tip_icon_wrapper">
<image src="@/static/assets/fenzhen/tip@2x.png"></image>
</view>
<view class="tip_text_wrapper">尊敬的客户为了使您的体检流程更加顺畅请按以下步骤提 示顺序逐项完成体检</view>
</view>
</view>
<view class="time_line_wrapper">
<view class="time_line_title_wrapper">自助导检</view>
<view class="time_line_box_wrapper">
<view class="time_line_item_wrapper" :class="[
`time_line_item-${i.status}_wrapper`
]" v-for="(i,k) in fenzhen_list.list" :key="k">
<view class="time_line_item_time_wrapper">
<view v-if="!!i.time" class="time_line_item_time_value_wrapper">{{ i.time }}</view>
<view class="time_line_item_time_dot_wrapper">
<view class="time_line_item_time_dot_in_wrapper"></view>
</view>
<view v-if="!!i.time" class="time_line_item_time_line_wrapper"></view>
<view v-if="!i.time" class="time_line_item_time_cover_wrapper"></view>
</view>
<view class="time_line_item_content_wrapper">
<view class="time_line_item_triangle_wrapper"></view>
<view class="time_line_item_flex_wrapper">
<view class="time_line_item_title_wrapper">{{ k + 1 }}.{{ i.name }}</view>
<view class="time_line_item_box_wrapper">{{ i.desc }}</view>
</view>
<view v-if="!!i.time && !!i.tip" class="time_line_item_line_wrapper"></view>
<view v-if="!!i.time && !!i.tip" class="time_line_item_flex_wrapper">
<view class="time_line_item_text_wrapper">{{ i.tip }}</view>
<view v-if="i.more > 0" class="time_line_item_more_wrapper">>></view>
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<style scoped>
.tip_dialog_text_wrapper {
max-height: calc(100vh - 600rpx);
overflow-y: auto;
}
.tip_dialog_wrapper {
position: fixed;
top: 0;
bottom: 0;
left: 0;
right: 0;
width: 750rpx;
background: #00000060;
margin: 0 auto;
z-index: 9999;
}
.tip_dialog_close_wrapper {
position: absolute;
top: 30rpx;
right: 40rpx;
width: 26rpx;
height: 26rpx;
}
.tip_dialog_close_wrapper image {
width: 26rpx;
height: 26rpx;
display: block;
object-fit: contain;
}
.tip_dialog_box_wrapper {
position: absolute;
width: 610rpx;
background: #FFFFFF;
border-radius: 15rpx;
padding-left: 50rpx;
padding-right: 50rpx;
padding-bottom: 90rpx;
padding-top: 130rpx;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
.time_line_item_more_wrapper {
font-size: 22rpx;
color: #239EA3;
line-height: 1;
text-decoration-line: underline;
margin-right: 19rpx;
}
.time_line_item_text_wrapper {
font-weight: 500;
font-size: 24rpx;
color: #6E6E6E;
line-height: 1;
margin-left: 42rpx;
}
.time_line_item_line_wrapper {
width: 550rpx;
height: 1rpx;
background: #E8E8E8;
border-radius: 1rpx;
margin: 13rpx auto 5rpx;
}
.time_line_item_box_wrapper {
width: 400rpx;
height: 40rpx;
background: #5A75CA30;
border-radius: 5rpx;
font-weight: 500;
font-size: 24rpx;
color: #5A75CA;
line-height: 40rpx;
text-align: center;
margin-right: 17rpx;
}
.time_line_item_title_wrapper {
width: 140rpx;
font-weight: bold;
font-size: 28rpx;
color: #0D0D0D;
line-height: 40rpx;
height: 40rpx;
margin-left: 22rpx;
}
.time_line_item_flex_wrapper {
margin-top: 15rpx;
display: flex;
align-items: center;
justify-content: space-between;
}
.time_line_item_time_cover_wrapper {
position: absolute;
width: 2rpx;
top: -36rpx;
height: 100rpx;
left: 50%;
background: #ffffff;
transform: translateX(-50%);
z-index: 99;
}
.time_line_item_time_line_wrapper {
position: absolute;
width: 2rpx;
top: 0;
bottom: 0;
left: 50%;
background: #DEDEDE;
transform: translateX(-50%);
}
.time_line_item_time_dot_wrapper {
position: absolute;
width: 16rpx;
height: 16rpx;
background: #CFCECE60;
border-radius: 50%;
left: 50%;
top: 50%;
transform: translate(-50%, calc(-50% + 26rpx));
z-index: 999;
}
.time_line_item_time_dot_in_wrapper {
width: 8rpx;
height: 8rpx;
background: #CFCECE;
border-radius: 50%;
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
.time_line_box_wrapper {
margin-top: 28rpx;
}
.time_line_item_triangle_wrapper {
width: 16rpx;
height: 16rpx;
border-left: 1rpx #E8E8E8 solid;
border-bottom: 1rpx #E8E8E8 solid;
background: #F8F8F8;
position: absolute;
top: 50%;
left: -10rpx;
transform: rotate(45deg);
}
.time_line_item_content_wrapper {
width: 590rpx;
background: #F8F8F8;
border-radius: 5rpx;
margin-left: 12rpx;
position: relative;
border: 1rpx #E8E8E8 solid;
margin-top: 36rpx;
padding-bottom: 15rpx;
}
.time_line_item_time_value_wrapper {
width: 90rpx;
height: 55rpx;
background: #E4E4E4;
border-radius: 28rpx;
font-weight: 500;
font-size: 28rpx;
color: #212121;
line-height: 55rpx;
text-align: center;
position: relative;
z-index: 99;
}
.time_line_item_time_wrapper {
width: 90rpx;
position: absolute;
left: 6rpx;
right: 0;
top: 0;
bottom: 0;
}
.time_line_item_wrapper {
width: calc(90rpx + 12rpx + 590rpx);
display: flex;
justify-content: end;
margin: 0 auto;
position: relative;
}
.time_line_title_wrapper {
width: 180rpx;
height: 60rpx;
background: linear-gradient(90deg, #EDF6F5 0%, #BBDFE1 99%);
border-radius: 0rpx 30rpx 30rpx 0rpx;
font-weight: bold;
font-size: 25rpx;
color: #123531;
text-align: center;
line-height: 60rpx;
margin-top: 26rpx;
overflow: hidden;
}
.time_line_wrapper {
width: 710rpx;
background: #FFFFFF;
box-shadow: 0rpx 0rpx 10rpx 0rpx rgba(0, 0, 0, 0.04);
border-radius: 15rpx;
margin: 53rpx auto 0;
overflow: hidden;
position: relative;
padding-bottom: 30rpx;
}
.tip_text_wrapper {
font-weight: 400;
font-size: 22rpx;
color: #E95515;
line-height: 36rpx;
margin-left: 10rpx;
}
.tip_icon_wrapper {
width: 24rpx;
height: 24rpx;
margin-top: 5rpx;
}
.tip_icon_wrapper image {
width: 24rpx;
height: 24rpx;
display: block;
object-fit: contain;
}
.tip_box_wrapper {
display: flex;
margin-top: 20rpx;
}
.tip_time_value_wrapper {
font-size: 36rpx;
color: #239EA3;
margin: 0 10rpx;
}
.tip_time_text_wrapper {
font-size: 22rpx;
color: #161616;
}
.tip_time_wrapper {
display: flex;
align-items: end;
line-height: 1;
}
.tip_wrapper {
width: calc(100% - 50px);
margin: 32rpx auto 0;
}
.info2_wrapper {
margin-top: 30rpx;
}
.info_box_wrapper {
margin-top: 60rpx;
margin-left: 29rpx;
}
.button_wrapper {
display: flex;
justify-content: end;
}
.desc_wrapper {
width: 160rpx;
height: 48rpx;
background: #239EA3;
border-radius: 5rpx;
font-size: 20rpx;
color: #FFFFFF;
line-height: 48rpx;
text-align: center;
margin-right: 29rpx;
margin-top: 24rpx;
}
.info_wrapper {
display: flex;
align-items: center;
}
.info_text_wrapper {
font-size: 24rpx;
color: #0F0F0F;
line-height: 1;
}
.info_title_wrapper {
font-size: 24rpx;
color: #8B8B8B;
line-height: 1;
}
.order_info_wrapper {
width: 710rpx;
height: 360rpx;
background: #FFFFFF;
box-shadow: 0rpx 0rpx 10rpx 0rpx rgba(0, 0, 0, 0.04);
border-radius: 15rpx;
margin: 20rpx auto 0;
overflow: hidden;
}
.person_name_wrapper {
display: flex;
align-items: end;
margin-top: 72rpx;
margin-left: 29rpx;
}
.person_name_text_wrapper {
font-weight: bold;
font-size: 34rpx;
color: #171717;
}
.person_sex_wrapper {
font-size: 24rpx;
color: #7E7E7E;
margin-left: 15rpx;
}
.time_line_item-2_wrapper .time_line_item_time_value_wrapper,
.time_line_item-1_wrapper .time_line_item_time_value_wrapper {
background: #239EA3;
color: #F8F8F8;
}
.time_line_item-2_wrapper .time_line_item_time_dot_wrapper,
.time_line_item-1_wrapper .time_line_item_time_dot_wrapper {
background: #239EA360;
}
.time_line_item-2_wrapper .time_line_item_time_dot_in_wrapper,
.time_line_item-1_wrapper .time_line_item_time_dot_in_wrapper {
background: #239EA3;
}
.time_line_item-2_wrapper .time_line_item_box_wrapper,
.time_line_item-1_wrapper .time_line_item_box_wrapper {
background: #6CAFB230;
color: #239EA3;
}
.time_line_item--1_wrapper .time_line_item_time_value_wrapper {
background: #239EA3;
color: #F8F8F8;
}
.time_line_item--1_wrapper .time_line_item_time_dot_wrapper {
background: #239EA360;
}
.time_line_item--1_wrapper .time_line_item_time_dot_in_wrapper {
background: #239EA3;
}
.time_line_item--1_wrapper .time_line_item_box_wrapper {
background: #E1AF6830;
color: #CC913E;
}
</style>

@ -39,12 +39,33 @@
getPersonList();
}
};
const choosePersonClick = async (info) => {
uni.navigateTo({
url: '/pages/user/fenzhen/fenzhen'
uni.showLoading()
const response = await $api('FenzhenCheck', {
id_number: info.id_number
})
};
uni.hideLoading()
$response(response, () => {
if (response.data.list.length > 0) {
let id = 0
for (let i in response.data.list) {
let datetime = `${response.data.list[i].appointment_date} ${response.data.list[i].appointment_time}`
if (id === 0 && (new Date(datetime) / 1) > (new Date() / 1)) {
id = response.data.list[i].id
break
}
}
if (id === 0) {
id = response.data.list[response.data.list.length - 1].id
}
uni.navigateTo({
url: `/pages/user/fenzhen/fenzhen?id=${id}`
})
} else {
uni.$lu.toast('暂无体检信息')
}
})
}
onShow(() => {
if (!!config_ref.value) {

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

@ -5,10 +5,11 @@ import {
export const useStore = defineStore('counter', {
state: () => ({
user: {},
tjbgInfo: [],
yytjInfo: {},
config: false,
groupInfo: {}, // 团检信息
combo_compare: [null, null, null], // 套餐对比
combo_compare: [], // 套餐对比
save: {
hospital: 1,
doctor: 1,
@ -22,6 +23,21 @@ export const useStore = defineStore('counter', {
buyInfo: {}, // 购买信息接口配置 预约页面使用 别的地方最好不要用
}),
actions: {
setComboContrast(comboContrast) {
this.combo_compare = comboContrast;
uni.setStorageSync('COMBO_CONTRAST', JSON.stringify(this.comboContrast));
},
getComboContrast(){
return JSON.parse(uni.getStorageSync('COMBO_CONTRAST') || '[]') || this.combo_compare;
},
setTjbgInfo(tjbgInfo) {
this.tjbgInfo = tjbgInfo;
uni.setStorageSync('TJBG_INFO', JSON.stringify(tjbgInfo));
},
getTjbgInfo() {
console.log(uni.getStorageSync('TJBG_INFO'))
return JSON.parse(uni.getStorageSync('TJBG_INFO') || '[]') || this.tjbgInfo;
},
getCheckupTypeId() {
return JSON.parse(uni.getStorageSync('CHECKUP_TYPE') || '{}') || this.checkup_type;
},

@ -15,6 +15,7 @@ export default {
'border-base': 'border border-gray-500_10',
'center': 'flex justify-center items-center',
'between': 'flex justify-between items-center',
'around': 'flex justify-around items-center',
},
],

Loading…
Cancel
Save