diff --git a/pages/case/archive-detail.vue b/pages/case/archive-detail.vue index e5766e8..628ef24 100644 --- a/pages/case/archive-detail.vue +++ b/pages/case/archive-detail.vue @@ -2,18 +2,12 @@ - - - - {{ archive.name || '-' }} {{ sexOrAge }} - {{ archive.mobile }} - {{ row.label }}: @@ -296,7 +290,7 @@ function normalizeArchiveFromApi(raw) { name: r.name || '', sex: r.sex || r.gender || '', age: r.age ?? '', - avatar: r.avatar || '', + avatar: r.avatar || r.avatarUrl || r.headImgUrl || r.headimgurl || r.headImageUrl || r.profilePhoto || r.photoUrl || r.photo || '', mobile: r.mobile || r.phone1 || r.phone || '', outpatientNo: r.outpatientNo || '', inpatientNo: r.inpatientNo || '', @@ -778,25 +772,10 @@ const saveAddGroup = async () => { border-bottom: 2rpx solid #f2f2f2; } -.avatar { - width: 112rpx; - height: 112rpx; - border-radius: 12rpx; - border: 2rpx solid #e8e8e8; - background: #fafafa; - overflow: hidden; - flex-shrink: 0; -} - -.avatar-img { - width: 112rpx; - height: 112rpx; -} - .header-main { flex: 1; min-width: 0; - padding: 0 20rpx; + padding: 0 20rpx 0 0; } .name-row { diff --git a/pages/case/batch-transfer.vue b/pages/case/batch-transfer.vue index 0f9c7f9..31ea4aa 100644 --- a/pages/case/batch-transfer.vue +++ b/pages/case/batch-transfer.vue @@ -1,37 +1,18 @@  diff --git a/pages/case/components/archive-detail/customer-profile-tab.vue b/pages/case/components/archive-detail/customer-profile-tab.vue index a3f0609..3e6472e 100644 --- a/pages/case/components/archive-detail/customer-profile-tab.vue +++ b/pages/case/components/archive-detail/customer-profile-tab.vue @@ -40,13 +40,6 @@ - - 院内来源 - - {{ latestTransferRecord?.executeTeamName || '点击查看' }} - - - (Array.isArray(props.baseItems) && props.baseItems.length ? props.baseItems : fallbackBaseItems)); -const effectiveInternalItems = computed(() => (Array.isArray(props.internalItems) && props.internalItems.length ? props.internalItems : fallbackInternalItems)); +function isInHospitalSourceItem(item) { + const title = String(item?.title || ''); + const name = String(item?.name || ''); + return title === 'inHospitalSource' || title === 'hospitalSource' || name.includes('院内来源'); +} +const effectiveInternalItems = computed(() => { + const raw = Array.isArray(props.internalItems) && props.internalItems.length ? props.internalItems : fallbackInternalItems; + return raw.filter((i) => i && !isInHospitalSourceItem(i)); +}); const filterRule = { reference(formModel) { diff --git a/pages/case/components/archive-detail/health-profile-tab.vue b/pages/case/components/archive-detail/health-profile-tab.vue index f0374cb..a26a5c4 100644 --- a/pages/case/components/archive-detail/health-profile-tab.vue +++ b/pages/case/components/archive-detail/health-profile-tab.vue @@ -49,18 +49,28 @@ 暂无数据 - - - + + + + + - - diff --git a/pages/case/patient-inner-info.vue b/pages/case/patient-inner-info.vue index 8fd86c1..328e394 100644 --- a/pages/case/patient-inner-info.vue +++ b/pages/case/patient-inner-info.vue @@ -267,6 +267,12 @@ function isTagItem(i) { return title === 'tagIds' || title === 'tag' || type === 'tag' || name.includes('标签'); } +function isInHospitalSourceItem(i) { + const title = String(i?.title || ''); + const name = String(i?.name || ''); + return title === 'inHospitalSource' || title === 'hospitalSource' || name.includes('院内来源'); +} + async function loadInternalTemplate() { const corpId = String(account.value?.corpId || doctorInfo.value?.corpId || '') || ''; if (!corpId) return; @@ -304,6 +310,7 @@ async function loadInternalTemplate() { items.value = list .filter((i) => i && i.fieldStatus !== 'disable') .filter((i) => i.operateType !== 'onlyRead') + .filter((i) => !isInHospitalSourceItem(i)) .map(normalizeTemplateItem); const debugStage = items.value.find(isStageItem); @@ -392,6 +399,20 @@ function buildPayload(base, inner) { return { payload, team }; } +function getCreatedCustomerId(res) { + const root = res && typeof res === 'object' ? res : {}; + const d = root.data && typeof root.data === 'object' ? root.data : {}; + return String( + d._id || + d.id || + d.customerId || + d.memberId || + root.customerId || + root.memberId || + '' + ) || ''; +} + async function save() { if (formRef.value?.verify && !formRef.value.verify()) return; @@ -420,10 +441,23 @@ async function save() { } toast('新增成功'); + const createdId = getCreatedCustomerId(res); uni.removeStorageSync(BASE_KEY); uni.removeStorageSync(INNER_KEY); uni.setStorageSync(NEED_RELOAD_STORAGE_KEY, 1); - uni.navigateBack({ delta: 2 }); + uni.navigateBack({ + delta: 2, + success: () => { + if (!createdId) return; + setTimeout(() => { + uni.navigateTo({ url: `/pages/case/archive-detail?id=${encodeURIComponent(createdId)}` }); + }, 30); + }, + fail: () => { + if (!createdId) return; + uni.redirectTo({ url: `/pages/case/archive-detail?id=${encodeURIComponent(createdId)}` }); + }, + }); } catch (e) { hideLoading(); toast('新增失败'); diff --git a/pages/case/service-record-detail.vue b/pages/case/service-record-detail.vue index cf686e3..6fe1b31 100644 --- a/pages/case/service-record-detail.vue +++ b/pages/case/service-record-detail.vue @@ -1,7 +1,7 @@