Compare commits

..

No commits in common. "ea51cee22ae66239e143de4a9000433ee8831614" and "9b2e8e9b1ed7f9e253afba065f353929748e39f5" have entirely different histories.

19 changed files with 211 additions and 370 deletions

View File

@ -1,7 +1,7 @@
MP_API_BASE_URL=https://patient.youcan365.com
MP_IMAGE_URL=https://patient.youcan365.com
MP_CACHE_PREFIX=development
MP_WX_APP_ID=wx6ee11733526b4f04
MP_WX_APP_ID=wx1d8337a40c11d66c
MP_CORP_ID=wwe3fb2faa52cf9dfb
MP_TIM_SDK_APP_ID=1600123876
MP_INVITE_TEAMMATE_QRCODE=https://patient.youcan365.com/invite-teammate

View File

@ -1,7 +1,7 @@
MP_API_BASE_URL=http://192.168.60.2:8080
MP_IMAGE_URL=https://patient.youcan365.com
MP_CACHE_PREFIX=development
MP_WX_APP_ID=wx6ee11733526b4f04
MP_WX_APP_ID=wx1d8337a40c11d66c
MP_CORP_ID=wwe3fb2faa52cf9dfb
MP_TIM_SDK_APP_ID=1600123876
MP_INVITE_TEAMMATE_QRCODE=https://patient.youcan365.com/invite-teammate

View File

@ -1,7 +1,7 @@
MP_API_BASE_URL=http://localhost:8080
MP_IMAGE_URL=https://patient.youcan365.com
MP_CACHE_PREFIX=development
MP_WX_APP_ID=wx6ee11733526b4f04
MP_WX_APP_ID=wx1d8337a40c11d66c
MP_CORP_ID=wwe3fb2faa52cf9dfb
MP_TIM_SDK_APP_ID=1600123876
MP_INVITE_TEAMMATE_QRCODE=https://patient.youcan365.com/invite-teammate

View File

@ -18,7 +18,7 @@ const emits = defineEmits(['cancel', 'confirm']);
const props = defineProps({
hidedenShadow: {
type: Boolean,
default: false
dfault: true
},
cancelText: {
type: String,

View File

@ -1,5 +1,5 @@
<template>
<view :class="fullCenter ? 'flex flex-col justify-center h-full w-full ' : ''">
<view>
<image class="block mx-auto" :style="style" src="/static/empty.svg"></image>
<view v-if="showText" class="mt-10 text-base text-center text-gray">{{ text }}</view>
</view>
@ -7,10 +7,6 @@
<script setup>
import { computed } from 'vue';
const props = defineProps({
fullCenter: {
type: Boolean,
default: false
},
showText: {
type: Boolean,
default: true

View File

@ -107,12 +107,6 @@
"navigationBarTitleText": "选择科室"
}
},
{
"path": "hospital-select",
"style": {
"navigationBarTitleText": "选择医院"
}
},
{
"path": "verify/assistant",
"style": {

View File

@ -62,29 +62,17 @@
}}</view>
</view>
<view class="content">{{ i.taskContent || "暂无内容" }}</view>
<view
v-if="i.sendContent || (i.fileList && i.fileList.length > 0)"
class="send-content-wrapper"
>
<view v-if="i.sendContent || (i.fileList && i.fileList.length > 0)" class="send-content-wrapper">
<view class="send-content-section">
<view class="send-content-label">发送内容:</view>
<view class="send-content-body">
<view v-if="i.sendContent" class="send-text">{{
i.sendContent
}}</view>
<view
v-if="i.fileList && i.fileList.length > 0"
class="file-list"
>
<view
v-for="(file, idx) in i.fileList"
:key="idx"
class="file-item"
:class="`file-type-${file.type}`"
>
<view class="file-name">{{
file.file?.name || file.name
}}</view>
<view v-if="i.sendContent" class="send-text">{{ i.sendContent }}</view>
<view v-if="i.fileList && i.fileList.length > 0" class="file-list">
<view v-for="(file, idx) in i.fileList" :key="idx" class="file-item" :class="`file-type-${file.type}`">
<view v-if="file.type === 'image'" class="file-icon">🖼</view>
<view v-else-if="file.type === 'article'" class="file-icon">📄</view>
<view v-else-if="file.type === 'questionnaire'" class="file-icon">📋</view>
<view class="file-name">{{ file.file?.name || file.name }}</view>
</view>
</view>
</view>
@ -528,7 +516,6 @@ async function sendFollowUp(todo) {
}
// 2.
debugger;
if (Array.isArray(todo.fileList)) {
for (const file of todo.fileList) {
if (file.type === "image" && file.URL) {

View File

@ -10,7 +10,7 @@ $primary-color: #0877F1;
top: 0;
left: 0;
right: 0;
bottom: 0;
bottom: 20rpx;
display: flex;
flex-direction: column;
background-color: #f5f5f5;
@ -357,35 +357,30 @@ $primary-color: #0877F1;
background: #fff;
border-top: 1rpx solid #e0e0e0;
position: relative;
z-index: 200;
padding-bottom: env(safe-area-inset-bottom);
z-index: 200; // 确保输入区域在评价卡片之上但在弹窗之下
// padding: 32rpx 16rpx 28rpx 16rpx;
}
.input-toolbar {
display: flex;
align-items: center;
padding: 16rpx 20rpx;
gap: 12rpx;
padding: 28rpx 0 28rpx 0;
}
.voice-toggle-btn {
width: 56rpx;
.voice-toggle-btn{
height: 56rpx;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
padding: 0;
}
flex: none;
padding-left: 20rpx;
}
.plus-btn {
width: 56rpx;
height: 56rpx;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
padding: 0;
flex: none;
padding-right: 20rpx;
}
.send-btn {
@ -395,16 +390,16 @@ $primary-color: #0877F1;
font-weight: 600;
border: none;
border-radius: 40rpx;
height: 56rpx;
height: 64rpx;
min-width: 112rpx;
padding: 0 32rpx;
margin-left: 16rpx;
box-shadow: 0 2rpx 8rpx rgba(56, 118, 246, 0.08);
display: flex;
align-items: center;
justify-content: center;
transition: background 0.2s;
flex-shrink: 0;
white-space: nowrap;
flex: none;
}
.send-btn:active {
@ -423,9 +418,10 @@ $primary-color: #0877F1;
.text-input,
.voice-input-btn {
flex: 1;
padding: 16rpx;
padding: 16rpx 46rpx;
background-color: #f3f5fa;
border-radius: 10rpx;
border-radius: 20rpx;
margin: 0 16rpx;
font-size: 28rpx;
min-height: 80rpx;
max-height: 200rpx;
@ -440,10 +436,9 @@ $primary-color: #0877F1;
}
.text-input {
padding: 20rpx;
padding: 16rpx 46rpx;
display: block;
line-height: 1.5;
height: 80rpx;
}
.voice-input-btn {

View File

@ -8,7 +8,7 @@
<view class="input-area">
<textarea v-if="!showVoiceInput" class="text-input" v-model="inputText" placeholder="我来说两句..."
@confirm="sendTextMessage" @focus="handleInputFocus" @input="handleInput"
:auto-height="true" :show-confirm-bar="false" :adjust-position="true" :cursor-spacing="40"
:auto-height="true" :show-confirm-bar="false" :adjust-position="true"
/>
<input v-else class="voice-input-btn" :class="{ recording: isRecording }" @touchstart="startRecord"
@touchmove="onRecordTouchMove" @touchend="stopRecord" @touchcancel="cancelRecord" :placeholder="isRecording ? '松开发送' : '按住说话'" disabled>
@ -83,12 +83,7 @@ const props = defineProps({
});
// Emits
const emit = defineEmits([
"messageSent",
"scrollToBottom",
"endConsult",
"openConsult",
]);
const emit = defineEmits(["messageSent", "scrollToBottom", "endConsult", "openConsult"]);
//
const inputText = ref("");
@ -431,11 +426,7 @@ const handleOpenConsult = () => {
const morePanelButtons = computed(() => {
const buttons = [
{
text: "照片",
icon: "/static/icon/zhaopian.png",
action: showImagePicker,
},
{ text: "照片", icon: "/static/icon/zhaopian.png", action: showImagePicker },
{
text: "回访任务",
icon: "/static/icon/huifangrenwu.png",

View File

@ -11,7 +11,7 @@
:key="conversation.groupID || conversation.conversationID" class="message-item"
@click="handleClickConversation(conversation)">
<view class="avatar-container">
<image class="avatar" :src="conversation.avatar || '/static/default-patient-avatar.png'"
<image class="avatar" :src="conversation.avatar || '/static/default-avatar.png'"
mode="aspectFill" />
<view v-if="conversation.unreadCount > 0" class="unread-badge">
<text class="unread-text">{{

View File

@ -1,84 +1,80 @@
<template>
<full-page :customScroll="true">
<template #header>
<view class="flex items-center px-15 py-12 bg-white border-b">
<view class="w-0 flex-grow mr-10 border py-5 px-15 rounded-full">
<input v-model="keyword" class="w-full text-dark text-base" type="text" placeholder="搜索科室"
placeholder-class="text-base text-gray" />
<view class="dept-page">
<view class="dept-container bg-white">
<view class="sidebar">
<view class="sidebar-search">
<input
v-model="keyword"
class="search-input"
type="text"
confirm-type="search"
placeholder="搜索一级科室"
placeholder-class="search-placeholder"
/>
<view v-if="keyword" class="clear-btn" @click="keyword = ''"
>清空</view
>
</view>
<view class="text-primary text-base" @click="keyword = ''">
清空
</view>
</view>
</template>
<scroll-view v-if="filteredList.length" class="h-full bg-white" scroll-y="true">
<view v-for="i in filteredList" :key="`filter-${i.deptId}`" class="px-15 py-12 text-base text-dark border-b"
@click="select(i)">
{{ i.deptName }}
</view>
</scroll-view>
<view v-else-if="level1List.length" class="flex w-full h-full">
<view class="flex-shrink-0 sidebar h-full bg-white">
<scroll-view scroll-y="true" class="h-full" :scroll-into-view="anchor">
<view v-for="item in level1List" :key="item.deptId" :id="item.deptId"
class="relative p-10 text-center text-base border-b"
:class="item.deptId === selectedParentId ? 'text-primary active' : 'text-dark'" @click="selectParent(item)">
{{ item.hlwDeptName || item.deptName }}
<scroll-view class="sidebar-list" scroll-y>
<view
v-for="item in filteredLevel1List"
:key="item.deptId"
:class="[
'sidebar-item',
item.deptId === selectedParentId ? 'active' : '',
]"
@click="selectParent(item)"
>
<text class="sidebar-text">{{
item.hlwDeptName || item.deptName
}}</text>
</view>
</scroll-view>
</view>
<view class="flex-grow h-full bg-white">
<scroll-view v-if="contentList.length" scroll-y="true" class="h-full" :scroll-into-view="anchor2">
<view v-for="child in contentList" :key="child.deptId" :id="child.deptId"
class="flex justify-between items-center p-10 border-b"
:class="selectedMap[child.deptId] ? 'text-primary ' : 'text-dark'" @click="selectDept(child)">
<view class="flex-shrink-0 mr-10 text-base">
{{ child.deptName }}
</view>
<image v-if="selectedMap[child.deptId]" class="flex-shrink-0 icon-checked" src="/static/form/checked.svg" />
</view>
</scroll-view>
<empty-data v-else fullCenter />
</view>
</view>
<empty-data v-else fullCenter />
<template #footer>
<view class="relative z-2 shadow-up bg-white">
<view class="pt-12 px-15 text-center" @click="toService()">
<text class="mr-5 text-base text-gray">如没有符合的内容</text>
<text class="text-base text-primary">联系客服</text>
</view>
<button-footer :showCancel="false" @confirm="save()" />
</view>
</template>
</full-page>
<scroll-view class="content" scroll-y>
<view v-if="contentList.length" class="content-list">
<view
v-for="child in contentList"
:key="child.deptId"
:class="['dept-item', isSelected(child) ? 'selected' : '']"
@click="selectDept(child)"
>
<view class="dept-name-row">
<view class="dept-name">{{ child.deptName }}</view>
<text v-if="isSelected(child)" class="check-tag">已选</text>
</view>
</view>
</view>
<view v-else class="empty-wrapper">
<empty-data text="暂无科室" />
</view>
</scroll-view>
</view>
<view class="footer-tip">
如没有符合的内容请联系客服
<text class="link" @click="contactService">点击添加客服</text>
</view>
</view>
</template>
<script setup>
import { computed, ref, nextTick } from "vue";
import { computed, ref, watch } from "vue";
import { onLoad } from "@dcloudio/uni-app";
import { storeToRefs } from "pinia";
import useGuard from "@/hooks/useGuard.js";
import useAccountStore from "@/store/account.js";
import EmptyData from "@/components/empty-data.vue";
import api from "@/utils/api";
import { toast } from "@/utils/widget";
import buttonFooter from "@/components/button-footer.vue";
import EmptyData from "@/components/empty-data.vue";
import fullPage from "@/components/full-page.vue";
const { useLoad } = useGuard();
const deptList = ref([]);
const selectedParentId = ref("");
const selectedDeptIds = ref([]);
const selectedDeptId = ref("");
const keyword = ref("");
const anchor = ref('');
const anchor2 = ref('');
const eventName = ref('')
const selectedMap = computed(() => selectedDeptIds.value.reduce((acc, cur) => {
acc[cur] = true;
return acc
}, {}))
const sorter = (a, b) => {
const sortA = typeof a.sort === "number" ? a.sort : 0;
@ -92,18 +88,13 @@ const sorter = (a, b) => {
const level1List = computed(() =>
deptList.value.filter((i) => i.level === 1).sort(sorter)
);
const level2List = computed(() =>
deptList.value.filter((i) => i.level === 2).sort(sorter)
);
const filteredList = computed(() => {
const target = keyword.value.trim();
if (target.trim()) {
const list1 = level1List.value.filter(i => i.deptName.includes(target));
const list2 = level2List.value.filter(i => i.deptName.includes(target));
return [...list1, ...list2];
}
return []
const filteredLevel1List = computed(() => {
const key = keyword.value.trim().toLowerCase();
if (!key) return level1List.value;
return level1List.value.filter((i) =>
i.deptName.toString().toLowerCase().includes(key)
);
});
const contentList = computed(() => {
@ -116,114 +107,114 @@ const contentList = computed(() => {
return children;
});
function select(i) {
if (i.level === 1) {
selectedParentId.value = i.deptId;
scrollTo(i.deptId);
} else if (i.level === 2) {
selectedParentId.value = i.parentId;
scrollTo(i.parentId, i.deptId);
}
keyword.value = '';
}
function scrollTo(parentId, deptId) {
if (parentId) anchor.value = '';
if (deptId) anchor2.value = '';
setTimeout(() => {
if (parentId) anchor.value = parentId;
if (deptId) anchor2.value = deptId;
}, 600);
function isSelected(item) {
const targetId = selectedDeptId.value;
return !!targetId && (item.deptId === targetId || item.deptId === targetId);
}
async function fetchDeptList() {
uni.showLoading({ title: "加载中..." });
try {
const res = await api("getAllHlwDeptList");
const res = await api("getDeptList");
if (res && res.success && Array.isArray(res.data)) {
deptList.value = res.data.map(i=>({
deptId:i.hlwDeptId,
deptName:i.hlwDeptName,
level:i.level,
parentId:i.parentId,
sort:i.sort,
createTime:i.createTime
}));
deptList.value = res.data;
hydrateSelectedParent();
} else {
toast(res?.message || "获取科室失败");
}
} catch (error) {
console.error("获取科室失败", error);
toast("获取科室失败");
} finally {
uni.hideLoading();
}
}
function hydrateSelectedParent() {
//
if (selectedDeptId.value) {
const match =
deptList.value.find(
(i) =>
i.deptId === selectedDeptId.value || i.deptId === selectedDeptId.value
) || null;
if (match?.parentId) {
selectedParentId.value = match.parentId;
return;
}
}
// 使 parentId
if (selectedParentId.value) return;
//
const first = level1List.value[0];
if (first) {
selectedParentId.value = first.deptId;
}
}
watch(
filteredLevel1List,
(list) => {
if (!list.length) return;
const exists = list.some((i) => i.deptId === selectedParentId.value);
if (!exists) {
selectedParentId.value = list[0].deptId;
}
},
{ immediate: false }
);
function selectParent(item) {
selectedParentId.value = item.deptId;
console.log("selectedParentId", selectedParentId.value);
}
function emitSelection(item) {
const eventChannel =
typeof getOpenerEventChannel === "function"
? getOpenerEventChannel()
: null;
eventChannel?.emit("deptSelected", {
id: item.deptId,
deptId: item.deptId || item.deptId,
name: item.deptName,
level: item.level,
parentId: item.parentId,
});
}
function selectDept(item) {
if (selectedDeptIds.value.includes(item.deptId)) {
selectedDeptIds.value = selectedDeptIds.value.filter(i => i !== item.deptId);
} else {
selectedDeptIds.value.push(item.deptId)
}
selectedDeptId.value = item.deptId || item.deptId;
emitSelection(item);
uni.navigateBack();
}
function toService() {
uni.navigateTo({
url: '/pages/work/service/contact-service'
})
function contactService() {
uni.showToast({
title: "请联系客服添加科室",
icon: "none",
});
}
function save() {
const depts = selectedDeptIds.value.map(i => {
const dept = level2List.value.find(j => j.deptId === i);
return dept ? { deptId: dept.deptId, deptName: dept.deptName } : null;
}).filter(Boolean);
if (depts.length) {
uni.$emit(eventName.value, depts);
uni.navigateBack();
} else {
toast('请选择科室');
}
}
useLoad((opt) => {
eventName.value = opt.eventName;
const deptIds = typeof opt.deptIds === 'string' ? opt.deptIds.split(',').filter(Boolean) : [];
selectedDeptIds.value = deptIds;
useLoad(() => {
fetchDeptList();
});
onLoad((opts) => {
//
if (opts.parentId) {
selectedParentId.value = opts.parentId;
}
const passedDeptId = opts.deptId || opts.departmentId || opts.id;
if (passedDeptId) {
selectedDeptId.value = passedDeptId;
}
});
</script>
<style lang="scss" scoped>
.sidebar {
width: 280rpx;
border-right: 1px solid #eee;
}
.active::before {
content: "";
position: absolute;
left: 0;
top: 0;
height: 100%;
width: 8rpx;
background: #0074ff;
}
.pt-12 {
padding-top: 24rpx;
}
.icon-checked {
width: 40rpx;
height: 40rpx;
}
.dept-page {
min-height: 100vh;
background: #f5f5f5;
@ -240,6 +231,22 @@ useLoad((opt) => {
height: 88vh;
}
.sidebar {
width: 230rpx;
background: #f8f9fb;
border-right: 1px solid #eef0f5;
display: flex;
flex-direction: column;
overflow-y: auto;
}
.sidebar-search {
padding: 16rpx 14rpx 12rpx;
display: flex;
align-items: center;
gap: 10rpx;
}
.search-input {
flex: 1;
height: 64rpx;
@ -392,3 +399,4 @@ useLoad((opt) => {
color: #2a6ff2;
}
</style>

View File

@ -1,99 +0,0 @@
<template>
<full-page :customScroll="true" @reachBottom="getMore()">
<template #header>
<view class="flex items-center px-15 py-12 bg-white border-b">
<view class="w-0 flex-grow mr-10 border py-5 px-15 rounded-full">
<input v-model="keyword" class="w-full text-dark text-base" type="text" placeholder="搜索科室"
placeholder-class="text-base text-gray" />
</view>
<view class="text-primary text-base" @click="keyword = ''">
清空
</view>
</view>
</template>
<scroll-view v-if="list.length" class="h-full bg-white" scroll-y="true">
<view v-for="i in list" :key="`filter-${i.hospitalId}`" class="flex items-center px-15 py-12 border-b"
@click="select(i)">
<view class="mr-10 w-0 flex-grow text-base text-dark">{{ i.name }}</view>
<image v-if="hospital && hospital.hospitalId === i.hospitalId" class="flex-shrink-0 icon-checked"
src="/static/form/checked.svg" />
</view>
</scroll-view>
<empty-data v-else fullCenter />
<template #footer>
<view class="relative z-2 shadow-up bg-white">
<view class="pt-12 px-15 text-center" @click="toService()">
<text class="mr-5 text-base text-gray">如没有符合的内容</text>
<text class="text-base text-primary">联系客服</text>
</view>
<button-footer :showCancel="false" @confirm="save()" />
</view>
</template>
</full-page>
</template>
<script setup>
import { computed, ref } from "vue";
import { onLoad } from "@dcloudio/uni-app";
import usePageList from "@/hooks/usePageList"
import api from "@/utils/api";
import { toast } from "@/utils/widget";
import buttonFooter from "@/components/button-footer.vue";
import EmptyData from "@/components/empty-data.vue";
import fullPage from "@/components/full-page.vue";
const { total, list, loading, hasMore, page, pages, pageSize, keyword, changePage } = usePageList(getList)
const eventName = ref('');
const hospital = ref();
function select(i) {
hospital.value = i;
}
function getMore() {
if (hasMore.value && !loading.value) {
changePage(page.value + 1)
}
}
function save() {
if (hospital.value) {
uni.$emit(eventName.value, hospital.value.name)
uni.navigateBack()
} else {
toast('请选择医院')
}
}
function toService() {
uni.navigateTo({
url: '/pages/work/service/contact-service'
})
}
async function getList() {
const res = await api('getHlwHospitalList', { page: page.value, pageSize: pageSize.value, name: keyword.value })
const arr = res && Array.isArray(res.data) ? res.data : [];
list.value = page.value === 1 ? arr : list.value.concat(arr);
total.value = res && typeof res.total === 'number' ? res.total : 0;
pages.value = res && typeof res.pages === 'number' ? res.pages : 0;
if (!res || !res.success) {
toast(res?.message || '获取数据失败');
}
}
onLoad((opt) => {
eventName.value = opt.eventName;
changePage(1);
});
</script>
<style lang="scss" scoped>
.icon-checked {
width: 40rpx;
height: 40rpx;
}
</style>

View File

@ -27,7 +27,8 @@
</picker>
</common-cell>
<common-cell title="title" :name="rule.title.name">
<picker mode="selector" :disable="rule.title.disable" :range="titleOptions" @change="changeTitle($event)">
<picker mode="selector" :disable="rule.title.disable" :range="titleOptions"
@change="changeTitle($event)">
<view class="flex-grow flex items-center justify-end">
<view class="text-base text-base">{{ formData.title }}</view>
<uni-icons color="#999" type="right" size="16" />
@ -35,8 +36,7 @@
</picker>
</common-cell>
<common-cell title="dept" :name="rule.dept.name">
<view class="flex-grow flex items-center justify-end" @click="selectDept()">
<view class="text-base text-base">{{ deptNames }}</view>
<view class="flex-grow flex items-center justify-end">
<uni-icons color="#999" type="right" size="16" />
</view>
</common-cell>
@ -115,10 +115,6 @@ const rule = computed(() => {
dept: { name: "科室", disabled: false },
};
});
const deptNames = computed(() => {
const hlwDepts = formData.value.hlwDepts || [];
return hlwDepts.map(i => i && i.deptName ? i.deptName : '').filter(Boolean).join(',')
})
//
const genderOptions = [
@ -194,17 +190,6 @@ function toCert() {
}
}
function selectDept() {
const eventName = `selectDept_${Date.now()}`
const deptIds = (formData.value.hlwDepts || []).map(i => i.deptId).filter(Boolean).join(',')
uni.navigateTo({
url: `/pages/work/department-select?eventName=${eventName}&deptIds=${deptIds}`
})
uni.$once(eventName, data => {
form.value.hlwDepts = data
})
}
async function save() {
if (
typeof formData.value.anotherName !== "string" ||
@ -232,7 +217,7 @@ async function save() {
}
const res = await api(apiName, data);
if (res && res.success) {
await getDoctorInfo({ withHlwDeptInfo: true });
await getDoctorInfo();
form.value = {};
if (type.value === "cert") {
toCert();
@ -253,7 +238,7 @@ useLoad((opts) => {
});
useShow(() => {
getDoctorInfo({ withHlwDeptInfo: true });
getDoctorInfo();
});
</script>

View File

@ -1,17 +1,17 @@
<template>
<full-page pageClass="bg-white">
<view class="p-15">
<view class="title-bar relative text-dark text-base font-semibold">请填写执业医院</view>
<view class="mt-12 p-10 flex items-center justify-between border rounded" @click="selectHospital()">
<view class="title-bar relative text-dark text-base font-semibold" @click="log()">请填写执业医院</view>
<!-- <view class="mt-12 p-10 flex items-center justify-between border rounded">
<view class="w-0 flex-grow truncate text-base mr-10" :class="formData.hospitalName ? 'text-dark' : 'text-gray'">
{{ formData.hospitalName || '请填写执业医院' }}
</view>
<uni-icons class="flex-shrink-0" color="#666" type="right" size="16" />
</view>
<!-- <view class="mt-12 p-10 flex items-center justify-between border rounded">
</view> -->
<view class="mt-12 p-10 flex items-center justify-between border rounded">
<input class="w-0 flex-grow text-base mr-10" :value="formData.hospitalName" @change="inputHospitalName($event)"
placeholder="请填写执业医院" />
</view> -->
</view>
<view class="mt-15 title-bar relative font-semibold">
<text class="mr-5 text-dark text-base">请上传</text>
<text class="text-primary text-base">医师执业资格证</text>
@ -72,16 +72,6 @@ function inputHospitalName(e) {
form.value.hospitalName = e.detail.value
}
function selectHospital() {
const eventName = `selectHospital_${Date.now()}`;
uni.navigateTo({
url: `/pages/work/hospital-select?eventName=${eventName}`
})
uni.$once(eventName, data => {
form.value.hospitalName = data
})
}
function uploadLicense(type) {
uni.chooseImage({
count: 1,

View File

@ -141,10 +141,6 @@ export default [
path: 'pages/work/department-select',
meta: { title: '选择科室' }
},
{
path: 'pages/work/hospital-select',
meta: { title: '选择医院' }
},
{
path: 'pages/work/verify/assistant',
meta: { title: '上传证照', login: true }

View File

@ -80,10 +80,9 @@ export default defineStore("accountStore", () => {
return Promise.reject()
}
async function getDoctorInfo(data = {}) {
async function getDoctorInfo() {
try {
const res = await api('getCorpMemberData', {
...data,
weChatOpenId: account.value.openid,
});
doctorInfo.value = res?.data || null;

View File

@ -30,7 +30,7 @@ export default defineStore("teamStore", () => {
const corpId = account.value?.corpId;
const mateId = doctorInfo.value?.userid;
if (!corpId || !mateId) return;
const res = await api('getJoinedTeams', { corpId, mateId }, false);
const res = await api('getJoinedTeams', { corpId, mateId });
teams.value = res && Array.isArray(res.data) ? res.data : [];
}

View File

@ -26,10 +26,7 @@ const urlsConfig = {
removeTeammate: "removeTeammate",
toggleTeamLeaderRole: "toggleTeamLeaderRole",
joinTheInvitedTeam: 'joinTheInvitedTeam',
getTeamMemberAvatarsAndName: 'getTeamMemberAvatarsAndName',
getHlwDeptTree: 'getHlwDeptTree',
getAllHlwDeptList: "getAllHlwDeptList",
getHlwHospitalList: 'getHlwHospitalList'
getTeamMemberAvatarsAndName: 'getTeamMemberAvatarsAndName'
},
knowledgeBase: {

View File

@ -1,10 +1,12 @@
export default function useDebounce(callback, delay = 1000) {
let timer = null;
let cd = false;
return (...args) => {
if (timer) clearTimeout(timer)
timer = setTimeout(() => {
callback(...args);
if (cd) return;
cd = true;
callback(...args);
setTimeout(() => {
cd = false;
}, delay);
}
}