feat: 全系统优化 — 并发控制 + 冗余清理 + 数据流修复 + 全面测试
核心修复: - 状态机加 SELECT FOR UPDATE 行锁,消除并发竞态 - hss_md_staff 加 role 列,登录从数据库读取真实角色 - 申请重复校验排除自身,全流程 20 步闭环通过 - 派单 SQL 修复 + 支付状态机过渡 + 完成服务 plan_item_id 修复 并发控制新增: - RedisLockService (SET NX PX + Lua 安全解锁) - RateLimiterService (Redis 滑动窗口 + API 拦截器) - TransactionIsolationConfig (SERIALIZABLE for 支付回调) - MqttPublisher (异步队列 + JDK TCP 探测) - ObjectStorageService (AWS SigV4 预签名, 纯 JDK) 冗余清理: - 删除 6 个死代码文件 (~620 行) - hutool-all → JDK MessageDigest, 去 MapStruct, 去 jsr310 - haversine 提取到 GeoUtil, count/round 提取到 JdbcUtil - 创建 platform layout 组件 前端修复: - 登录页移除角色选择器, 由后端 JWT 返回 - 移除 ClientOnly 包裹, 页面正常渲染 - SPA fallback Nginx 配置修复 Docker: 运行时镜像 eclipse-temurin:17-jre-jammy (缩小 ~300MB) 文档: 新增系统实现与修复报告.md Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted } from 'vue'
|
||||
import { usePlatformAuth } from '~/composables/usePlatformAuth'
|
||||
const { isLoggedIn } = usePlatformAuth()
|
||||
|
||||
const apps = ref<any[]>([])
|
||||
const loading = ref(true)
|
||||
const ready = ref(false)
|
||||
const showCreate = ref(false)
|
||||
const submitting = ref(false)
|
||||
const form = ref({ patientId: '', serviceType: 'HOME_CARE', channel: 'WECHAT', contactName: '', contactPhone: '', address: '', regionCode: '441402001', notes: '' })
|
||||
@@ -39,13 +40,12 @@ async function doAction(id: number, action: string, body?: any) {
|
||||
catch(e: any) { alert(e?.data?.message || e?.message || '操作失败') }
|
||||
}
|
||||
|
||||
onMounted(() => { ready.value = true; loadApps().finally(() => loading.value = false) })
|
||||
onMounted(() => { loadApps().finally(() => loading.value = false) })
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<ClientOnly>
|
||||
<div v-if="!ready" class="min-h-screen bg-surface flex items-center justify-center"><p class="text-text-secondary">加载中...</p></div>
|
||||
<div v-else class="min-h-screen bg-surface flex">
|
||||
<div v-if="loading" class="min-h-screen bg-surface flex items-center justify-center"><p class="text-text-secondary">加载中...</p></div>
|
||||
<div v-else class="min-h-screen bg-surface flex">
|
||||
<aside class="hidden lg:flex flex-col w-56 bg-white border-r shrink-0">
|
||||
<div class="p-4 border-b"><a href="/platform" class="font-bold text-primary text-sm">← 返回工作台</a></div>
|
||||
<div class="p-3"><div class="text-xs text-text-secondary">角色: {{ getAuthHeaders()['X-User-Role'] }}</div></div>
|
||||
@@ -82,6 +82,5 @@ onMounted(() => { ready.value = true; loadApps().finally(() => loading.value = f
|
||||
</table>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
</ClientOnly>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user