| | |
| | | </el-table> |
| | | </div> |
| | | </div> |
| | | <div :class="form.serviceType == 2 ? 'Followuserinfo' : 'Followuserinfos'"> |
| | | <div :class="form.serviceType ? 'Followuserinfo' : 'Followuserinfos'"> |
| | | <div> |
| | | <el-form ref="form" :model="form" label-width="120px"> |
| | | <div class="headline"> |
| | |
| | | </el-form> |
| | | </div> |
| | | </div> |
| | | <div v-if="form.serviceType == 2"> |
| | | <div> |
| | | <el-tabs v-model="activeName" type="border-card"> |
| | | <el-tab-pane name="wj"> |
| | | <span class="mulsz" slot="label" |
| | |
| | | total: 0, |
| | | // 用药记录数据 |
| | | medicationList: [ |
| | | { |
| | | id: 1, |
| | | patientId: 'P1001', |
| | | patientName: '张清扬', |
| | | patientAge: 65, |
| | | patientGender: '1', |
| | | patientNo: '20241209001', |
| | | allergyHistory: '青霉素过敏', |
| | | drugId: 'D1001', |
| | | drugName: '阿司匹林肠溶片', |
| | | drugSpecification: '100mg*30片/盒', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-01 08:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '饭后服用,注意胃肠道反应。长期服用需定期检查血常规。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '李成白', |
| | | stopReason: '', |
| | | stopDescription: '' |
| | | }, |
| | | { |
| | | id: 2, |
| | | patientId: 'P1001', |
| | | patientName: '张清扬', |
| | | patientAge: 65, |
| | | patientGender: '1', |
| | | patientNo: '20241209001', |
| | | allergyHistory: '青霉素过敏', |
| | | drugId: 'D1002', |
| | | drugName: '阿托伐他汀钙片', |
| | | drugSpecification: '20mg*7片/盒', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-11-20 20:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '每晚睡前服用。注意监测肝功能,如有肌肉酸痛请及时就医。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '李成白', |
| | | stopReason: '', |
| | | stopDescription: '' |
| | | }, |
| | | { |
| | | id: 3, |
| | | patientId: 'P2001', |
| | | patientName: '王芳', |
| | | patientAge: 33, |
| | | patientGender: '0', |
| | | patientNo: '20241115002', |
| | | allergyHistory: '无', |
| | | drugId: 'D1003', |
| | | drugName: '泼尼松片', |
| | | drugSpecification: '5mg*100片/瓶', |
| | | dosage: 2, |
| | | dosageUnit: '片', |
| | | frequency: '3', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-05 09:00:00', |
| | | endTime: '2024-12-20 09:00:00', |
| | | durationType: '2', |
| | | instructions: '早、中、晚餐后服用。需严格遵医嘱逐渐减量,不可突然停药。', |
| | | medicationStatus: '0', |
| | | prescribingDoctor: '刘翊惠', |
| | | stopReason: '疗程结束', |
| | | stopDescription: '标准疗程用药完毕,血小板计数已恢复正常范围。' |
| | | }, |
| | | { |
| | | id: 4, |
| | | patientId: 'P2001', |
| | | patientName: '王芳', |
| | | patientAge: 33, |
| | | patientGender: '0', |
| | | patientNo: '20241115002', |
| | | allergyHistory: '无', |
| | | drugId: 'D1004', |
| | | drugName: '多糖铁复合物胶囊', |
| | | drugSpecification: '150mg*10粒/盒', |
| | | dosage: 1, |
| | | dosageUnit: '粒', |
| | | frequency: '2', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-05 09:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '餐后服用,可减轻胃肠道刺激。服药后可能出现黑便,属正常现象。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '刘翊惠', |
| | | stopReason: '', |
| | | stopDescription: '' |
| | | }, |
| | | { |
| | | id: 5, |
| | | patientId: 'P3001', |
| | | patientName: '李伟', |
| | | patientAge: 58, |
| | | patientGender: '1', |
| | | patientNo: '20241022005', |
| | | allergyHistory: '磺胺类药物过敏', |
| | | drugId: 'D1005', |
| | | drugName: '盐酸二甲双胍片', |
| | | drugSpecification: '0.5g*20片/板', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '2', |
| | | usageMethod: '口服', |
| | | startTime: '2024-10-22 08:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '随餐或餐后立即服用,以减少胃肠道不适。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '张孟涵', |
| | | stopReason: '', |
| | | stopDescription: '' |
| | | }, |
| | | { |
| | | id: 6, |
| | | patientId: 'P4001', |
| | | patientName: '赵磊', |
| | | patientAge: 70, |
| | | patientGender: '1', |
| | | patientNo: '20241202011', |
| | | allergyHistory: '海鲜过敏', |
| | | drugId: 'D1006', |
| | | drugName: '呋塞米片', |
| | | drugSpecification: '20mg*100片/瓶', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-02 07:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '晨起服用,避免夜间多次起夜。注意监测电解质水平。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '吴思翰', |
| | | stopReason: '', |
| | | stopDescription: '' |
| | | }, |
| | | { |
| | | id: 7, |
| | | patientId: 'P5001', |
| | | patientName: '周华', |
| | | patientAge: 52, |
| | | patientGender: '0', |
| | | patientNo: '20241128009', |
| | | allergyHistory: '无', |
| | | drugId: 'D1007', |
| | | drugName: '硝苯地平控释片', |
| | | drugSpecification: '30mg*7片/盒', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-11-28 08:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '整片吞服,不可嚼碎或掰开。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '陈政倩', |
| | | stopReason: '', |
| | | stopDescription: '' |
| | | } |
| | | ], |
| | | { |
| | | id: 1, |
| | | patientId: 'C1001', |
| | | patientName: '李俊宝', |
| | | patientAge: 2, |
| | | ageGroup: '婴幼儿(0-3岁)', |
| | | patientGender: '1', |
| | | patientNo: 'P202412001', |
| | | allergyHistory: '青霉素过敏、鸡蛋过敏', |
| | | drugId: 'D1001', |
| | | drugName: '布洛芬混悬滴剂', |
| | | drugSpecification: '100mg:5ml*15ml/瓶', |
| | | drugCategory: '解热镇痛药', |
| | | dosage: 2.5, |
| | | dosageUnit: 'ml', |
| | | frequency: '3', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-10 08:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '用于发热,体重10kg,按体重计算剂量。饭后服用,注意观察有无胃肠道反应。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '王医生', |
| | | guardianName: '李爸爸' |
| | | }, |
| | | { |
| | | id: 2, |
| | | patientId: 'C1002', |
| | | patientName: '张萌', |
| | | patientAge: 4, |
| | | ageGroup: '学龄前(3-6岁)', |
| | | patientGender: '0', |
| | | patientNo: 'P202411002', |
| | | allergyHistory: '无', |
| | | drugId: 'D1002', |
| | | drugName: '阿莫西林颗粒', |
| | | drugSpecification: '125mg*12袋/盒', |
| | | drugCategory: '抗生素', |
| | | dosage: 1, |
| | | dosageUnit: '袋', |
| | | frequency: '3', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-08 09:00:00', |
| | | endTime: '2024-12-18 09:00:00', |
| | | durationType: '2', |
| | | instructions: '治疗急性中耳炎,需连续服用10天,不可自行停药。注意观察有无过敏反应。', |
| | | medicationStatus: '0', |
| | | prescribingDoctor: '刘医生', |
| | | guardianName: '张妈妈', |
| | | stopReason: '疗程结束', |
| | | stopDescription: '完成10天抗生素疗程,中耳炎症状完全缓解。' |
| | | }, |
| | | { |
| | | id: 3, |
| | | patientId: 'C1003', |
| | | patientName: '王青宇', |
| | | patientAge: 8, |
| | | ageGroup: '学龄期(7-12岁)', |
| | | patientGender: '1', |
| | | patientNo: 'P202412003', |
| | | allergyHistory: '海鲜过敏', |
| | | drugId: 'D1003', |
| | | drugName: '孟鲁司特钠咀嚼片', |
| | | drugSpecification: '5mg*5片/盒', |
| | | drugCategory: '抗过敏药', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-11-15 20:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '每晚睡前咀嚼服用,用于控制哮喘症状。注意监测身高体重变化。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '陈医生', |
| | | guardianName: '王妈妈' |
| | | }, |
| | | { |
| | | id: 4, |
| | | patientId: 'C1004', |
| | | patientName: '刘驰欣', |
| | | patientAge: 14, |
| | | ageGroup: '青少年(13-18岁)', |
| | | patientGender: '0', |
| | | patientNo: 'P202410004', |
| | | allergyHistory: '磺胺类药物过敏', |
| | | drugId: 'D1004', |
| | | drugName: '异维A酸软胶囊', |
| | | drugSpecification: '10mg*20粒/盒', |
| | | drugCategory: '皮肤科用药', |
| | | dosage: 1, |
| | | dosageUnit: '粒', |
| | | frequency: '2', |
| | | usageMethod: '口服', |
| | | startTime: '2024-10-20 08:00:00', |
| | | endTime: '2025-01-20 08:00:00', |
| | | durationType: '2', |
| | | instructions: '治疗重度痤疮,需定期检查肝功能。服药期间及停药后1个月内避免怀孕。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '赵医生', |
| | | guardianName: '刘爸爸' |
| | | }, |
| | | { |
| | | id: 5, |
| | | patientId: 'C1005', |
| | | patientName: '陈浩', |
| | | patientAge: 1, |
| | | ageGroup: '婴幼儿(0-3岁)', |
| | | patientGender: '1', |
| | | patientNo: 'P202412005', |
| | | allergyHistory: '牛奶蛋白过敏', |
| | | drugId: 'D1005', |
| | | drugName: '盐酸西替利嗪滴剂', |
| | | drugSpecification: '10mg:1ml*5ml/瓶', |
| | | drugCategory: '抗过敏药', |
| | | dosage: 0.25, |
| | | dosageUnit: 'ml', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-12-05 08:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '用于过敏性鼻炎,体重8kg,按体重精确计算剂量。注意观察有无嗜睡副作用。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '孙医生', |
| | | guardianName: '陈妈妈' |
| | | }, |
| | | { |
| | | id: 6, |
| | | patientId: 'C1006', |
| | | patientName: '杨芷悦', |
| | | patientAge: 16, |
| | | ageGroup: '青少年(13-18岁)', |
| | | patientGender: '0', |
| | | patientNo: 'P202409006', |
| | | allergyHistory: '无', |
| | | drugId: 'D1006', |
| | | drugName: '左甲状腺素钠片', |
| | | drugSpecification: '50μg*100片/盒', |
| | | drugCategory: '内分泌用药', |
| | | dosage: 1, |
| | | dosageUnit: '片', |
| | | frequency: '1', |
| | | usageMethod: '口服', |
| | | startTime: '2024-09-01 07:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '治疗甲状腺功能减退症,每日清晨空腹服用,需终身服药。定期复查甲状腺功能。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '周医生', |
| | | guardianName: '杨爸爸' |
| | | }, |
| | | { |
| | | id: 7, |
| | | patientId: 'C1007', |
| | | patientName: '黄铭轩', |
| | | patientAge: 5, |
| | | ageGroup: '学龄前(3-6岁)', |
| | | patientGender: '1', |
| | | patientNo: 'P202412007', |
| | | allergyHistory: '花粉过敏', |
| | | drugId: 'D1007', |
| | | drugName: '沙丁胺醇气雾剂', |
| | | drugSpecification: '100μg*200揿/瓶', |
| | | drugCategory: '平喘药', |
| | | dosage: 1, |
| | | dosageUnit: '揿', |
| | | frequency: '0', |
| | | usageMethod: '吸入', |
| | | startTime: '2024-11-20 08:00:00', |
| | | endTime: '', |
| | | durationType: '1', |
| | | instructions: '用于哮喘急性发作时缓解症状,按需使用。教导正确吸入方法。', |
| | | medicationStatus: '1', |
| | | prescribingDoctor: '吴医生', |
| | | guardianName: '黄妈妈' |
| | | } |
| | | ], |
| | | // 分配用药弹出层 |
| | | assignOpen: false, |
| | | assignTitle: "", |
| | |
| | | <el-form :model="queryParams" ref="queryForm" :inline="true" label-width="100px"> |
| | | <el-row :gutter="20"> |
| | | <el-col :span="6"> |
| | | <el-form-item label="患者姓名" prop="patientName"> |
| | | <el-form-item label="儿童姓名" prop="patientName"> |
| | | <el-input |
| | | v-model="queryParams.patientName" |
| | | placeholder="请输入患者姓名" |
| | | placeholder="请输入儿童姓名" |
| | | clearable |
| | | @keyup.enter="handleQuery" |
| | | /> |
| | |
| | | style="width: 100%" |
| | | :default-sort="{prop: 'applyTime', order: 'descending'}" |
| | | > |
| | | <el-table-column label="患者信息" min-width="200" fixed> |
| | | <el-table-column label="儿童信息" min-width="200" fixed> |
| | | <template slot-scope="scope"> |
| | | <div class="patient-info"> |
| | | <div class="patient-name">{{ scope.row.patientName }}</div> |
| | | <div class="patient-detail"> |
| | | {{ scope.row.gender }} | {{ scope.row.age }}岁 | {{ scope.row.phone }} |
| | | <div style="color: #909399; font-size: 12px; margin-top: 2px;"> |
| | | {{ scope.row.applicableAge }} |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </template> |
| | |
| | | </el-table-column> |
| | | <el-table-column label="申请时间" prop="applyTime" width="160" sortable /> |
| | | <el-table-column label="期望医生" prop="expectDoctor" width="120" /> |
| | | <el-table-column label="特殊要求" min-width="200"> |
| | | <el-table-column label="监护人要求" min-width="200"> |
| | | <template slot-scope="scope"> |
| | | <span v-if="scope.row.specialRequirements" :title="scope.row.specialRequirements"> |
| | | {{ scope.row.specialRequirements.substring(0, 30) }}... |
| | |
| | | type="textarea" |
| | | :rows="3" |
| | | v-model="reviewForm.rejectReason" |
| | | placeholder="请输入驳回的具体原因,便于患者了解情况" |
| | | placeholder="请输入驳回的具体原因,便于监护人了解情况" |
| | | maxlength="200" |
| | | show-word-limit |
| | | /> |
| | |
| | | rejected: 0 |
| | | }, |
| | | availableDoctors: [ |
| | | { id: '1', name: '王医生', department: '内科' }, |
| | | { id: '2', name: '李医生', department: '老年科' }, |
| | | { id: '3', name: '张医生', department: '妇产科' }, |
| | | { id: '4', name: '刘医生', department: '儿科' }, |
| | | { id: '1', name: '王医生', department: '儿科' }, |
| | | { id: '2', name: '李医生', department: '儿童保健科' }, |
| | | { id: '3', name: '张医生', department: '儿科' }, |
| | | { id: '4', name: '刘医生', department: '儿童营养科' }, |
| | | { id: '5', name: '陈医生', department: '全科' } |
| | | ], |
| | | // 儿童服务套餐配置 |
| | | servicePackages: { |
| | | '1': { name: '基础健康管理包', color: 'info' }, |
| | | '2': { name: '慢性病管理包', color: 'success' }, |
| | | '3': { name: '老年人健康包', color: 'warning' }, |
| | | '4': { name: '孕产妇保健包', color: 'danger' }, |
| | | '5': { name: '儿童保健包', color: 'primary' } |
| | | '1': { |
| | | name: '婴幼儿健康基础包', |
| | | color: 'primary', |
| | | applicableAge: '0-3岁' |
| | | }, |
| | | '2': { |
| | | name: '学龄前儿童健康包', |
| | | color: 'success', |
| | | applicableAge: '3-6岁' |
| | | }, |
| | | '3': { |
| | | name: '学龄儿童综合健康包', |
| | | color: 'warning', |
| | | applicableAge: '7-12岁' |
| | | }, |
| | | '4': { |
| | | name: '青少年健康支持包', |
| | | color: 'danger', |
| | | applicableAge: '13-18岁' |
| | | }, |
| | | '5': { |
| | | name: '儿童营养与生长发育增值包', |
| | | color: 'info', |
| | | applicableAge: '3-18岁' |
| | | }, |
| | | '6': { |
| | | name: '儿童中医特色保健包', |
| | | color: 'primary', |
| | | applicableAge: '0-6岁' |
| | | } |
| | | }, |
| | | rules: { |
| | | rejectReason: [ |
| | |
| | | this.calculateStats() |
| | | }, |
| | | methods: { |
| | | //优化后的模拟数据生成方法 |
| | | generateMockData() { |
| | | const mockData = [] |
| | | // 生成模拟数据 |
| | | generateMockData() { |
| | | const mockData = [] |
| | | |
| | | // 使用您提供的真实姓名列表 |
| | | const patientNames = [ |
| | | '李肇芬', '卢木仲', '李成白', '方兆玉', '刘翊惠', '丁汉臻', '吴佳瑞', '舒绿珮', |
| | | '周白芷', '张姿妤', '张虹伦', '周琼玟', '倪怡芳', '郭贵妃', '杨佩芳', '黄文旺', |
| | | '黄盛玫', '郑丽青', '许智云', '张孟涵', '李小爱', '王恩龙', '朱政廷', '邓诗涵', |
| | | '陈政倩', '吴俊伯', '阮馨学', '翁惠珠', '吴思翰', '林佩玲' |
| | | ] |
| | | // 使用儿童姓名列表 |
| | | const patientNames = [ |
| | | '李小宝', '张小明', '王雨欣', '刘浩然', '陈思琪', '杨宇航', '黄诗涵', '赵天宇', |
| | | '周小萌', '吴俊杰', '郑雅雯', '孙沐辰', '朱雨萱', '马浩宇', '胡可馨', '林俊熙', |
| | | '郭子轩', '何欣怡', '高天佑', '梁静怡', '罗浩然', '宋雨泽', '唐语嫣', '许博文', |
| | | '谢欣妍', '冯子默', '董雨桐', '萧天乐', '曹心怡', '袁嘉豪' |
| | | ] |
| | | |
| | | const specialReqs = [ |
| | | '希望医生能定期上门检查', |
| | | '需要周末时间段的服务', |
| | | '对药物有过敏史,需特别注意', |
| | | '行动不便,需要上门服务', |
| | | '无特殊要求', |
| | | '需要英语服务支持', |
| | | '有高血压病史,需重点关注', |
| | | '需要定期血糖监测服务', |
| | | '希望有固定的家庭医生', |
| | | '需要心理疏导服务' |
| | | ] |
| | | const specialReqs = [ |
| | | '希望医生能定期上门检查', |
| | | '需要周末时间段的服务', |
| | | '对药物有过敏史,需特别注意', |
| | | '行动不便,需要上门服务', |
| | | '无特殊要求', |
| | | '需要英语服务支持', |
| | | '有哮喘病史,需重点关注', |
| | | '需要定期生长发育监测', |
| | | '希望有固定的儿科医生', |
| | | '需要疫苗接种提醒服务' |
| | | ] |
| | | |
| | | const rejectReasons = [ |
| | | '资料不完整,请补充健康档案', |
| | | '不符合当前签约条件', |
| | | '选择的医生档期已满', |
| | | '服务套餐与病情不匹配', |
| | | '年龄不符合套餐要求', |
| | | '请补充完整的病史资料' |
| | | ] |
| | | const rejectReasons = [ |
| | | '监护人资料不完整,请补充身份证明', |
| | | '儿童年龄不符合套餐要求', |
| | | '选择的医生专长与儿童需求不匹配', |
| | | '服务套餐与儿童健康状况不匹配', |
| | | '请补充完整的儿童健康档案', |
| | | '疫苗接种记录不完整' |
| | | ] |
| | | |
| | | // 生成约30条数据(与姓名数量匹配) |
| | | for (let i = 0; i < patientNames.length; i++) { |
| | | const packageId = (i % 5) + 1 + '' |
| | | const reviewStatus = i % 3 // 0:待审核, 1:通过, 2:驳回 |
| | | const applyDate = this.generateRandomDate('2024-10-01', '2024-12-08') |
| | | for (let i = 0; i < patientNames.length; i++) { |
| | | const packageId = (i % 6) + 1 + '' |
| | | const packageInfo = this.servicePackages[packageId] |
| | | const reviewStatus = i % 3 // 0:待审核, 1:通过, 2:驳回 |
| | | const applyDate = this.generateRandomDate('2024-10-01', '2024-12-08') |
| | | |
| | | // 生成更真实的电话号码 |
| | | const phonePrefix = ['138', '139', '150', '151', '152', '186', '187', '188'] |
| | | const phone = `${phonePrefix[i % phonePrefix.length]}${this.padNumber(1000 + i * 37, 4)}${this.padNumber(i % 100, 2)}` |
| | | // 根据套餐适用年龄生成合理的实际年龄 |
| | | let age |
| | | switch(packageInfo.applicableAge) { |
| | | case '0-3岁': |
| | | age = Math.floor(Math.random() * 3) + 1 |
| | | break |
| | | case '3-6岁': |
| | | age = Math.floor(Math.random() * 3) + 3 |
| | | break |
| | | case '7-12岁': |
| | | age = Math.floor(Math.random() * 6) + 7 |
| | | break |
| | | case '13-18岁': |
| | | age = Math.floor(Math.random() * 6) + 13 |
| | | break |
| | | default: |
| | | age = Math.floor(Math.random() * 18) + 1 |
| | | } |
| | | |
| | | // 生成合理的年龄(0-80岁) |
| | | const age = i % 80 |
| | | const gender = i % 2 === 0 ? '男' : '女' |
| | | // 生成监护人电话号码 |
| | | const phonePrefix = ['138', '139', '150', '151', '152', '186', '187', '188'] |
| | | const phone = `${phonePrefix[i % phonePrefix.length]}${this.padNumber(1000 + i * 37, 4)}${this.padNumber(i % 100, 2)}` |
| | | |
| | | mockData.push({ |
| | | id: `A${2024000 + i}`, |
| | | patientName: patientNames[i], |
| | | gender: gender, |
| | | age: age, |
| | | phone: phone, |
| | | servicePackageId: packageId, |
| | | servicePackage: this.servicePackages[packageId].name, |
| | | services: this.getServicesByPackage(packageId), |
| | | contractPeriod: [1, 2][i % 2], |
| | | applyTime: `${applyDate} ${this.padNumber(8 + (i % 10), 2)}:${this.padNumber(i % 60, 2)}:${this.padNumber(i % 60, 2)}`, |
| | | expectDoctor: ['王医生', '李医生', '张医生', '刘医生', '陈医生'][i % 5], |
| | | specialRequirements: specialReqs[i % specialReqs.length], |
| | | reviewStatus: reviewStatus, |
| | | reviewer: reviewStatus !== 0 ? ['管理员', '系统管理员', '审核专员'][i % 3] : '', |
| | | reviewTime: reviewStatus !== 0 ? |
| | | `${this.addDays(applyDate, 1 + (i % 3))} 14:${this.padNumber(i % 60, 2)}:00` : '', |
| | | rejectReason: reviewStatus === 2 ? rejectReasons[i % rejectReasons.length] : '' |
| | | }) |
| | | } |
| | | mockData.push({ |
| | | id: `A${2024000 + i}`, |
| | | patientName: patientNames[i], |
| | | gender: i % 2 === 0 ? '男' : '女', |
| | | age: age, |
| | | phone: phone, |
| | | servicePackageId: packageId, |
| | | servicePackage: packageInfo.name, |
| | | services: this.getServicesByPackage(packageId), |
| | | contractPeriod: [1, 2][i % 2], |
| | | applicableAge: packageInfo.applicableAge, |
| | | applyTime: `${applyDate} ${this.padNumber(8 + (i % 10), 2)}:${this.padNumber(i % 60, 2)}:${this.padNumber(i % 60, 2)}`, |
| | | expectDoctor: ['王医生', '李医生', '张医生', '刘医生', '陈医生'][i % 5], |
| | | specialRequirements: specialReqs[i % specialReqs.length], |
| | | reviewStatus: reviewStatus, |
| | | reviewer: reviewStatus !== 0 ? ['管理员', '系统管理员', '审核专员'][i % 3] : '', |
| | | reviewTime: reviewStatus !== 0 ? |
| | | `${this.addDays(applyDate, 1 + (i % 3))} 14:${this.padNumber(i % 60, 2)}:00` : '', |
| | | rejectReason: reviewStatus === 2 ? rejectReasons[i % rejectReasons.length] : '' |
| | | }) |
| | | } |
| | | |
| | | return mockData |
| | | }, |
| | | return mockData |
| | | }, |
| | | |
| | | // 根据套餐获取服务列表 |
| | | getServicesByPackage(packageId) { |
| | | const servicesMap = { |
| | | '1': ['年度健康评估', '在线健康咨询', '健康档案管理', '定期健康提醒'], |
| | | '2': ['专属医生服务', '用药指导管理', '定期随访监测', '个性化康复计划', '紧急医疗咨询'], |
| | | '3': ['跌倒风险评估', '康复训练指导', '用药安全管理', '定期上门访视', '紧急联系服务', '心理健康关怀'], |
| | | '4': ['孕期健康管理', '产后康复指导', '新生儿护理咨询', '营养膳食建议', '心理情绪支持'], |
| | | '5': ['生长发育监测', '疫苗接种管理', '常见病防治', '营养指导', '早期教育咨询'] |
| | | } |
| | | return servicesMap[packageId] || [] |
| | | }, |
| | | // 根据套餐获取服务列表 |
| | | getServicesByPackage(packageId) { |
| | | const servicesMap = { |
| | | '1': ['新生儿家庭访视', '定期体格检查与发育评估', '血常规检测', '听力筛查', '喂养与护理指导', '预防接种服务', '中医保健指导'], |
| | | '2': ['生长发育评估', '视力筛查与口腔保健', '血常规检查', '合理膳食与行为指导', '疾病预防与健康干预', '中医饮食调养指导'], |
| | | '3': ['年度健康检查', '心理行为发育评估', '科学用眼与口腔保健', '合理膳食指导', '健康生活方式干预', '专家转诊绿色通道'], |
| | | '4': ['青春期健康教育', '年度健康评估', '心理健康支持', '健康风险行为干预', '个性化健康方案', '优先预约检查服务'], |
| | | '5': ['微量元素测定', '骨密度检测', '个性化膳食方案', '生长发育专项评估', '运动处方指导', '定期营养监测'], |
| | | '6': ['中医体质辨识', '三伏贴服务', '小儿推拿', '耳穴治疗', '防感香囊', '食疗指导'] |
| | | } |
| | | return servicesMap[packageId] || [] |
| | | }, |
| | | |
| | | // 辅助方法:生成随机日期 |
| | | generateRandomDate(start, end) { |
| | | const startDate = new Date(start).getTime() |
| | | const endDate = new Date(end).getTime() |
| | | const randomTime = startDate + Math.random() * (endDate - startDate) |
| | | return new Date(randomTime).toISOString().split('T')[0] |
| | | }, |
| | | // 辅助方法:生成随机日期 |
| | | generateRandomDate(start, end) { |
| | | const startDate = new Date(start).getTime() |
| | | const endDate = new Date(end).getTime() |
| | | const randomTime = startDate + Math.random() * (endDate - startDate) |
| | | return new Date(randomTime).toISOString().split('T')[0] |
| | | }, |
| | | |
| | | // 辅助方法:添加天数 |
| | | addDays(date, days) { |
| | | const result = new Date(date) |
| | | result.setDate(result.getDate() + days) |
| | | return result.toISOString().split('T')[0] |
| | | }, |
| | | // 辅助方法:添加天数 |
| | | addDays(date, days) { |
| | | const result = new Date(date) |
| | | result.setDate(result.getDate() + days) |
| | | return result.toISOString().split('T')[0] |
| | | }, |
| | | |
| | | // 辅助方法:数字补零 |
| | | padNumber(num, length) { |
| | | return num.toString().padStart(length, '0') |
| | | }, |
| | | // 辅助方法:数字补零 |
| | | padNumber(num, length) { |
| | | return num.toString().padStart(length, '0') |
| | | }, |
| | | |
| | | // 获取审核列表 [1](@ref) |
| | | // 获取审核列表 |
| | | async getList() { |
| | | this.loading = true |
| | | try { |
| | |
| | | this.stats.rejected = allData.filter(item => item.reviewStatus === 2).length |
| | | }, |
| | | |
| | | // 获取审核状态文本 [2](@ref) |
| | | // 获取审核状态文本 |
| | | getReviewStatusText(status) { |
| | | const statusMap = { 0: '待审核', 1: '审核通过', 2: '审核驳回' } |
| | | return statusMap[status] || '未知' |
| | |
| | | |
| | | // 获取套餐类型 |
| | | getPackageType(packageId) { |
| | | const typeMap = { '1': 'info', '2': 'success', '3': 'warning', '4': 'danger', '5': 'primary' } |
| | | const typeMap = { |
| | | '1': 'primary', '2': 'success', '3': 'warning', |
| | | '4': 'danger', '5': 'info', '6': 'primary' |
| | | } |
| | | return typeMap[packageId] || 'info' |
| | | }, |
| | | |
| | | // 搜索操作 [1](@ref) |
| | | // 搜索操作 |
| | | handleQuery() { |
| | | this.queryParams.pageNum = 1 |
| | | this.getList() |
| | |
| | | this.handleQuery() |
| | | }, |
| | | |
| | | // 处理审核操作 [2](@ref) |
| | | // 处理审核操作 |
| | | handleReview(row, status) { |
| | | this.currentRow = row |
| | | this.reviewForm = { |
| | |
| | | } |
| | | this.reviewDialogVisible = true |
| | | |
| | | // 清除表单验证 |
| | | this.$nextTick(() => { |
| | | if (this.$refs.reviewFormRef) { |
| | | this.$refs.reviewFormRef.clearValidate() |
| | |
| | | }) |
| | | }, |
| | | |
| | | // 提交审核 [2,6](@ref) |
| | | // 提交审核 |
| | | async submitReview() { |
| | | try { |
| | | // 表单验证 |
| | | if (this.reviewForm.reviewStatus === 2) { |
| | | if (!this.reviewForm.rejectReason) { |
| | | this.$message.error('请填写驳回原因') |
| | |
| | | return |
| | | } |
| | | |
| | | // 模拟API调用 |
| | | await new Promise(resolve => setTimeout(resolve, 1000)) |
| | | |
| | | // 更新当前行的状态 |
| | | const currentIndex = this.reviewList.findIndex(item => item.id === this.currentRow.id) |
| | | if (currentIndex !== -1) { |
| | | this.reviewList[currentIndex].reviewStatus = this.reviewForm.reviewStatus |
| | |
| | | this.reviewList[currentIndex].reviewTime = new Date().toLocaleString() |
| | | this.reviewList[currentIndex].rejectReason = this.reviewForm.rejectReason |
| | | |
| | | // 如果审核通过,分配医生 |
| | | if (this.reviewForm.reviewStatus === 1) { |
| | | const doctor = this.availableDoctors.find(d => d.id === this.reviewForm.assignDoctor) |
| | | this.reviewList[currentIndex].expectDoctor = doctor ? doctor.name : this.reviewList[currentIndex].expectDoctor |
| | |
| | | |
| | | this.$message.success(this.reviewForm.reviewStatus === 1 ? '审核通过成功' : '审核驳回成功') |
| | | this.reviewDialogVisible = false |
| | | this.calculateStats() // 重新计算统计信息 |
| | | this.calculateStats() |
| | | } catch (error) { |
| | | console.error('审核操作失败:', error) |
| | | this.$message.error('审核操作失败') |
| | |
| | | |
| | | // 查看详情 |
| | | handleView(row) { |
| | | this.$message.info(`查看患者 ${row.patientName} 的申请详情`) |
| | | // 实际开发中跳转到详情页 |
| | | // this.$router.push({ path: '/patient/contract/apply-detail', query: { id: row.id } }) |
| | | }, |
| | | |
| | | // 批量审核通过 |
| | | handleBatchApprove() { |
| | | const pendingItems = this.reviewList.filter(item => item.reviewStatus === 0) |
| | | if (pendingItems.length === 0) { |
| | | this.$message.warning('没有待审核的申请') |
| | | return |
| | | } |
| | | |
| | | this.$confirm(`确定要批量通过 ${pendingItems.length} 个待审核申请吗?`, '批量审核', { |
| | | type: 'warning' |
| | | }).then(async () => { |
| | | try { |
| | | this.loading = true |
| | | // 模拟批量审核API调用 |
| | | await new Promise(resolve => setTimeout(resolve, 2000)) |
| | | |
| | | // 更新所有待审核项的状态 |
| | | pendingItems.forEach(item => { |
| | | item.reviewStatus = 1 |
| | | item.reviewer = '当前用户' |
| | | item.reviewTime = new Date().toLocaleString() |
| | | }) |
| | | |
| | | this.$message.success(`批量审核通过成功,共处理 ${pendingItems.length} 个申请`) |
| | | this.calculateStats() |
| | | } catch (error) { |
| | | this.$message.error('批量审核失败') |
| | | } finally { |
| | | this.loading = false |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | // 导出审核数据 |
| | | handleExport() { |
| | | const exportData = this.generateMockData() |
| | | // 实际开发中这里应该调用导出API |
| | | console.log('导出数据:', exportData) |
| | | this.$message.info('导出功能开发中,数据已打印到控制台') |
| | | this.$message.info(`查看儿童 ${row.patientName} 的申请详情`) |
| | | } |
| | | }, |
| | | watch: { |
| | | // 监听审核状态变化,动态设置验证规则 [6](@ref) |
| | | 'reviewForm.reviewStatus': function(newVal) { |
| | | this.$nextTick(() => { |
| | | if (this.$refs.reviewFormRef) { |
| | |
| | | .patient-detail { |
| | | font-size: 12px; |
| | | color: #909399; |
| | | line-height: 1.4; |
| | | } |
| | | } |
| | | |
| | | // 审核状态样式 |
| | | .review-status { |
| | | padding: 4px 8px; |
| | | border-radius: 4px; |
| | | font-size: 12px; |
| | | font-weight: 500; |
| | | |
| | | &.status-pending { |
| | | background: #fdf6ec; |
| | | color: #e6a23c; |
| | | } |
| | | |
| | | &.status-approved { |
| | | background: #f0f9e8; |
| | | color: #67c23a; |
| | | } |
| | | |
| | | &.status-rejected { |
| | | background: #fef0f0; |
| | | color: #f56c6c; |
| | | } |
| | | } |
| | | |
| | | // 特殊要求文本样式 |
| | | .special-requirements { |
| | | max-width: 200px; |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | white-space: nowrap; |
| | | |
| | | &:hover { |
| | | white-space: normal; |
| | | overflow: visible; |
| | | background: white; |
| | | box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1); |
| | | padding: 8px; |
| | | border-radius: 4px; |
| | | position: absolute; |
| | | z-index: 1000; |
| | | max-width: 300px; |
| | | } |
| | | } |
| | | |
| | | // 表格样式 |
| | | // 表格样式优化 |
| | | ::v-deep .el-table { |
| | | .el-table__header-wrapper { |
| | | th { |
| | |
| | | } |
| | | } |
| | | |
| | | // 审核对话框样式 |
| | | .review-dialog { |
| | | ::v-deep .el-dialog { |
| | | border-radius: 8px; |
| | | box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); |
| | | } |
| | | |
| | | .dialog-footer { |
| | | text-align: right; |
| | | margin-top: 20px; |
| | | } |
| | | } |
| | | |
| | | // 操作按钮样式 |
| | | .action-buttons { |
| | | display: flex; |
| | | gap: 8px; |
| | | |
| | | .el-button { |
| | | padding: 7px 12px; |
| | | border-radius: 4px; |
| | | font-size: 12px; |
| | | |
| | | &.approve-btn { |
| | | background: #67c23a; |
| | | border-color: #67c23a; |
| | | color: white; |
| | | |
| | | &:hover { |
| | | background: #5daf34; |
| | | border-color: #5daf34; |
| | | } |
| | | } |
| | | |
| | | &.reject-btn { |
| | | background: #f56c6c; |
| | | border-color: #f56c6c; |
| | | color: white; |
| | | |
| | | &:hover { |
| | | background: #e65c5c; |
| | | border-color: #e65c5c; |
| | | } |
| | | } |
| | | |
| | | &.detail-btn { |
| | | color: #409eff; |
| | | border-color: #409eff; |
| | | |
| | | &:hover { |
| | | background: #ecf5ff; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | // 批量操作栏 |
| | | .batch-actions { |
| | | background: #ecf5ff; |
| | | padding: 12px 20px; |
| | | margin-bottom: 16px; |
| | | border-radius: 4px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | |
| | | .batch-info { |
| | | color: #409eff; |
| | | font-size: 14px; |
| | | } |
| | | } |
| | | |
| | | // 空状态样式 |
| | | .empty-state { |
| | | text-align: center; |
| | | padding: 40px 20px; |
| | | color: #909399; |
| | | |
| | | .empty-icon { |
| | | font-size: 48px; |
| | | margin-bottom: 16px; |
| | | opacity: 0.5; |
| | | } |
| | | |
| | | .empty-text { |
| | | font-size: 14px; |
| | | } |
| | | } |
| | | |
| | | // 响应式设计 |
| | | @media (max-width: 768px) { |
| | | padding: 10px; |
| | |
| | | .el-col { |
| | | margin-bottom: 10px; |
| | | } |
| | | } |
| | | |
| | | .action-buttons { |
| | | flex-direction: column; |
| | | } |
| | | |
| | | .batch-actions { |
| | | flex-direction: column; |
| | | gap: 10px; |
| | | align-items: stretch; |
| | | } |
| | | } |
| | | } |
| | |
| | | <el-col :span="6"> |
| | | <el-form-item label="服务套餐" prop="servicePackage"> |
| | | <el-select v-model="queryParams.servicePackage" placeholder="请选择套餐" clearable> |
| | | <el-option label="基础健康管理包" value="1" /> |
| | | <el-option label="慢性病管理包" value="2" /> |
| | | <el-option label="老年人健康包" value="3" /> |
| | | <el-option label="孕产妇保健包" value="4" /> |
| | | <el-option label="儿童保健包" value="5" /> |
| | | <el-option |
| | | v-for="pkg in packageOptions" |
| | | :key="pkg.id" |
| | | :label="pkg.name" |
| | | :value="pkg.id" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <el-card class="stats-card" shadow="hover"> |
| | | <div class="stats-content"> |
| | | <div class="stats-number">{{ stats.total }}</div> |
| | | <div class="stats-label">总签约患者</div> |
| | | <div class="stats-label">总签约儿童</div> |
| | | </div> |
| | | </el-card> |
| | | </el-col> |
| | |
| | | :default-sort="{prop: 'signDate', order: 'descending'}" |
| | | > |
| | | <el-table-column type="selection" width="55" /> |
| | | <el-table-column label="患者信息" min-width="180" fixed> |
| | | <el-table-column label="儿童信息" min-width="180" fixed> |
| | | <template slot-scope="scope"> |
| | | <div class="patient-info"> |
| | | <div class="patient-name">{{ scope.row.patientName }}</div> |
| | | <div class="patient-detail"> |
| | | {{ scope.row.gender }} | {{ scope.row.age }}岁 | {{ scope.row.phone }} |
| | | <div style="color: #909399; font-size: 12px; margin-top: 2px;"> |
| | | {{ scope.row.applicableAge }} |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </template> |
| | |
| | | }, |
| | | total: 0, |
| | | patientList: [], |
| | | // 服务套餐配置 |
| | | // 儿童服务套餐配置 [1,3,5](@ref) |
| | | servicePackages: { |
| | | '1': { |
| | | name: '基础健康管理包', |
| | | services: ['年度健康评估', '在线健康咨询', '健康档案管理', '定期健康提醒'], |
| | | name: '婴幼儿健康基础包', |
| | | description: '为0-3岁婴幼儿提供全面的健康监测与发育指导', |
| | | services: ['新生儿家庭访视', '定期体格检查与发育评估', '血常规检测', '听力筛查', '喂养与护理指导', '预防接种服务', '中医保健指导'], |
| | | price: 0, |
| | | color: 'info' |
| | | color: 'primary', |
| | | applicableAge: '0-3岁' |
| | | }, |
| | | '2': { |
| | | name: '慢性病管理包', |
| | | services: ['专属医生服务', '用药指导管理', '定期随访监测', '个性化康复计划', '紧急医疗咨询'], |
| | | price: 299, |
| | | color: 'success' |
| | | name: '学龄前儿童健康包', |
| | | description: '关注3-6岁儿童生长发育、常见病预防及习惯养成', |
| | | services: ['生长发育评估', '视力筛查与口腔保健', '血常规检查', '合理膳食与行为指导', '疾病预防与健康干预', '中医饮食调养指导'], |
| | | price: 0, |
| | | color: 'success', |
| | | applicableAge: '3-6岁' |
| | | }, |
| | | '3': { |
| | | name: '老年人健康包', |
| | | services: ['跌倒风险评估', '康复训练指导', '用药安全管理', '定期上门访视', '紧急联系服务', '心理健康关怀'], |
| | | price: 499, |
| | | color: 'warning' |
| | | name: '学龄儿童综合健康包', |
| | | description: '为7-12岁儿童提供学习期健康保障与发展支持', |
| | | services: ['年度健康检查', '心理行为发育评估', '科学用眼与口腔保健', '合理膳食指导', '健康生活方式干预', '专家转诊绿色通道'], |
| | | price: 0, |
| | | color: 'warning', |
| | | applicableAge: '7-12岁' |
| | | }, |
| | | '4': { |
| | | name: '孕产妇保健包', |
| | | services: ['孕期健康管理', '产后康复指导', '新生儿护理咨询', '营养膳食建议', '心理情绪支持'], |
| | | price: 399, |
| | | color: 'danger' |
| | | name: '青少年健康支持包', |
| | | description: '针对13-18岁青少年青春期特点的健康管理', |
| | | services: ['青春期健康教育', '年度健康评估', '心理健康支持', '健康风险行为干预', '个性化健康方案', '优先预约检查服务'], |
| | | price: 0, |
| | | color: 'danger', |
| | | applicableAge: '13-18岁' |
| | | }, |
| | | '5': { |
| | | name: '儿童保健包', |
| | | services: ['生长发育监测', '疫苗接种管理', '常见病防治', '营养指导', '早期教育咨询'], |
| | | price: 199, |
| | | color: 'primary' |
| | | name: '儿童营养与生长发育增值包', |
| | | description: '针对肥胖、营养不良等问题的专项管理', |
| | | services: ['微量元素测定', '骨密度检测', '个性化膳食方案', '生长发育专项评估', '运动处方指导', '定期营养监测'], |
| | | price: 150, |
| | | color: 'info', |
| | | applicableAge: '3-18岁' |
| | | }, |
| | | '6': { |
| | | name: '儿童中医特色保健包', |
| | | description: '运用中医药方法增强儿童体质', |
| | | services: ['中医体质辨识', '三伏贴服务', '小儿推拿', '耳穴治疗', '防感香囊', '食疗指导'], |
| | | price: 200, |
| | | color: 'primary', |
| | | applicableAge: '0-6岁' |
| | | } |
| | | } |
| | | }, |
| | | packageOptions: [] |
| | | } |
| | | }, |
| | | created() { |
| | | this.initPackageOptions() |
| | | this.getList() |
| | | this.calculateStats() |
| | | }, |
| | | methods: { |
| | | // 生成更真实的模拟数据 |
| | | // 精简后的模拟数据生成方法 |
| | | // 优化后的模拟数据生成方法 |
| | | generateMockData() { |
| | | const mockData = [] |
| | | // 初始化套餐选项 |
| | | initPackageOptions() { |
| | | this.packageOptions = Object.keys(this.servicePackages).map(key => ({ |
| | | id: key, |
| | | name: this.servicePackages[key].name |
| | | })) |
| | | }, |
| | | |
| | | // 使用您提供的真实姓名列表 |
| | | const patientNames = [ |
| | | '李肇芬', '卢木仲', '李成白', '方兆玉', '刘翊惠', '丁汉臻', '吴佳瑞', '舒绿珮', |
| | | '周白芷', '张姿妤', '张虹伦', '周琼玟', '倪怡芳', '郭贵妃', '杨佩芳', '黄文旺', |
| | | '黄盛玫', '郑丽青', '许智云', '张孟涵', '李小爱', '王恩龙', '朱政廷', '邓诗涵', |
| | | '陈政倩', '吴俊伯', '阮馨学', '翁惠珠', '吴思翰', '林佩玲' |
| | | ] |
| | | // 生成模拟数据 |
| | | generateMockData() { |
| | | const mockData = [] |
| | | |
| | | const doctors = ['王医生', '李医生', '张医生', '刘医生', '陈医生'] |
| | | const cities = ['北京市', '上海市', '广州市', '深圳市', '杭州市', '南京市', '成都市'] |
| | | const areas = ['朝阳区', '海淀区', '浦东新区', '黄浦区', '天河区', '福田区', '西湖区'] |
| | | // 使用儿童姓名列表 |
| | | const patientNames = [ |
| | | '李小宝', '张小明', '王雨欣', '刘浩然', '陈思琪', '杨宇航', '黄诗涵', '赵天宇', |
| | | '周小萌', '吴俊杰', '郑雅雯', '孙沐辰', '朱雨萱', '马浩宇', '胡可馨', '林俊熙', |
| | | '郭子轩', '何欣怡', '高天佑', '梁静怡', '罗浩然', '宋雨泽', '唐语嫣', '许博文', |
| | | '谢欣妍', '冯子默', '董雨桐', '萧天乐', '曹心怡', '袁嘉豪' |
| | | ] |
| | | |
| | | // 生成约20条数据 |
| | | for (let i = 0; i < patientNames.length; i++) { |
| | | const packageId = (i % 5) + 1 + '' |
| | | const packageInfo = this.servicePackages[packageId] |
| | | const doctors = ['王医生', '李医生', '张医生', '刘医生', '陈医生'] |
| | | const cities = ['北京市', '上海市', '广州市', '深圳市', '杭州市', '南京市', '成都市'] |
| | | const areas = ['朝阳区', '海淀区', '浦东新区', '黄浦区', '天河区', '福田区', '西湖区'] |
| | | |
| | | // 生成更合理的签约时间(过去1年内) |
| | | const signDate = this.generateRandomDate('2023-12-01', '2024-11-30') |
| | | const contractPeriod = [1, 2][i % 2] // 1年或2年合同 |
| | | const expireDate = this.addYears(signDate, contractPeriod) |
| | | const remainingDays = this.calculateRemainingDays(expireDate) |
| | | const contractStatus = this.getContractStatus(expireDate, remainingDays) |
| | | for (let i = 0; i < patientNames.length; i++) { |
| | | const packageId = (i % 6) + 1 + '' |
| | | const packageInfo = this.servicePackages[packageId] |
| | | |
| | | // 生成更真实的电话号码和身份证号 |
| | | const phonePrefix = ['138', '139', '150', '151', '152', '186', '187', '188'] |
| | | const phone = `${phonePrefix[i % phonePrefix.length]}${this.padNumber(1000 + i * 37, 4)}${this.padNumber(i % 100, 2)}` |
| | | // 根据套餐适用年龄生成合理的实际年龄 |
| | | let age |
| | | switch(packageInfo.applicableAge) { |
| | | case '0-3岁': |
| | | age = Math.floor(Math.random() * 3) + 1 |
| | | break |
| | | case '3-6岁': |
| | | age = Math.floor(Math.random() * 3) + 3 |
| | | break |
| | | case '7-12岁': |
| | | age = Math.floor(Math.random() * 6) + 7 |
| | | break |
| | | case '13-18岁': |
| | | age = Math.floor(Math.random() * 6) + 13 |
| | | break |
| | | default: |
| | | age = Math.floor(Math.random() * 18) + 1 |
| | | } |
| | | |
| | | // 生成合理的年龄(20-80岁) |
| | | const age = 20 + (i % 60) |
| | | const birthYear = new Date().getFullYear() - age |
| | | const idCard = `11010${birthYear}${this.padNumber(1 + (i % 12), 2)}${this.padNumber(1 + (i % 28), 2)}${this.padNumber(i % 1000, 3)}X` |
| | | // 生成签约时间(过去1年内) |
| | | const signDate = this.generateRandomDate('2023-12-01', '2024-11-30') |
| | | const contractPeriod = [1, 2][i % 2] // 1年或2年合同 |
| | | const expireDate = this.addYears(signDate, contractPeriod) |
| | | const remainingDays = this.calculateRemainingDays(expireDate) |
| | | const contractStatus = this.getContractStatus(expireDate, remainingDays) |
| | | |
| | | mockData.push({ |
| | | id: `P${2024000 + i}`, |
| | | patientName: patientNames[i], |
| | | gender: i % 2 === 0 ? '男' : '女', |
| | | age: age, |
| | | phone: phone, |
| | | idCard: idCard, |
| | | doctorName: doctors[i % doctors.length], |
| | | servicePackageId: packageId, |
| | | servicePackage: packageInfo.name, |
| | | services: packageInfo.services, |
| | | contractPeriod: contractPeriod, |
| | | signDate: signDate, |
| | | expireDate: expireDate, |
| | | remainingDays: remainingDays, |
| | | contractStatus: contractStatus, |
| | | address: `${cities[i % cities.length]}${areas[i % areas.length]}${this.generateStreet(i)}` // 新增地址字段 |
| | | }) |
| | | } |
| | | // 生成电话号码(使用家长电话) |
| | | const phonePrefix = ['138', '139', '150', '151', '152', '186', '187', '188'] |
| | | const phone = `${phonePrefix[i % phonePrefix.length]}${this.padNumber(1000 + i * 37, 4)}${this.padNumber(i % 100, 2)}` |
| | | |
| | | return mockData |
| | | }, |
| | | // 生成儿童身份证号 |
| | | const birthYear = new Date().getFullYear() - age |
| | | const idCard = `11010${birthYear}${this.padNumber(1 + (i % 12), 2)}${this.padNumber(1 + (i % 28), 2)}${this.padNumber(i % 1000, 3)}X` |
| | | |
| | | // 新增辅助方法:生成街道地址 |
| | | generateStreet(index) { |
| | | const streets = [ |
| | | '中山路123号', '人民路456号', '解放路789号', '建设路101号', '和平路202号', |
| | | '新华路303号', '光明路404号', '幸福路505号', '团结路606号', '文明路707号' |
| | | ] |
| | | return streets[index % streets.length] |
| | | }, |
| | | mockData.push({ |
| | | id: `C${2024000 + i}`, |
| | | patientName: patientNames[i], |
| | | gender: i % 2 === 0 ? '男' : '女', |
| | | age: age, |
| | | phone: phone, |
| | | idCard: idCard, |
| | | doctorName: doctors[i % doctors.length], |
| | | servicePackageId: packageId, |
| | | servicePackage: packageInfo.name, |
| | | services: packageInfo.services, |
| | | contractPeriod: contractPeriod, |
| | | signDate: signDate, |
| | | expireDate: expireDate, |
| | | remainingDays: remainingDays, |
| | | contractStatus: contractStatus, |
| | | applicableAge: packageInfo.applicableAge, |
| | | address: `${cities[i % cities.length]}${areas[i % areas.length]}${this.generateStreet(i)}` |
| | | }) |
| | | } |
| | | |
| | | // 辅助方法 |
| | | return mockData |
| | | }, |
| | | |
| | | // 辅助方法保持不变 |
| | | generateStreet(index) { |
| | | const streets = [ |
| | | '中山路123号', '人民路456号', '解放路789号', '建设路101号', '和平路202号', |
| | | '新华路303号', '光明路404号', '幸福路505号', '团结路606号', '文明路707号' |
| | | ] |
| | | return streets[index % streets.length] |
| | | }, |
| | | |
| | | generateRandomDate(start, end) { |
| | | const startDate = new Date(start).getTime() |
| | | const endDate = new Date(end).getTime() |
| | |
| | | async getList() { |
| | | this.loading = true |
| | | try { |
| | | // 模拟API调用延迟 |
| | | await new Promise(resolve => setTimeout(resolve, 500)) |
| | | |
| | | const allData = this.generateMockData() |
| | | // 简单的本地筛选 |
| | | // 筛选逻辑 |
| | | let filteredData = allData.filter(item => { |
| | | if (this.queryParams.patientName && |
| | | !item.patientName.includes(this.queryParams.patientName)) { |
| | |
| | | }, |
| | | |
| | | getPackageType(packageId) { |
| | | const typeMap = { '1': 'info', '2': 'success', '3': 'warning', '4': 'danger', '5': 'primary' } |
| | | const typeMap = { |
| | | '1': 'primary', '2': 'success', '3': 'warning', |
| | | '4': 'danger', '5': 'info', '6': 'primary' |
| | | } |
| | | return typeMap[packageId] || 'info' |
| | | }, |
| | | |
| | |
| | | }, |
| | | |
| | | handleView(row) { |
| | | this.$message.info(`查看患者 ${row.patientName} 的详情`) |
| | | this.$message.info(`查看儿童 ${row.patientName} 的详情`) |
| | | // 实际开发中跳转到详情页 |
| | | // this.$router.push({ path: '/patient/contract/detail', query: { id: row.id } }) |
| | | }, |
| | | |
| | | handleRenew(row) { |
| | | this.$confirm(`确定要为患者 ${row.patientName} 办理续约吗?`, '提示', { |
| | | this.$confirm(`确定要为儿童 ${row.patientName} 办理续约吗?`, '提示', { |
| | | type: 'warning' |
| | | }).then(() => { |
| | | this.$message.success('续约操作成功') |
| | |
| | | |
| | | .search-card { |
| | | margin-bottom: 20px; |
| | | |
| | | ::v-deep .el-form-item { |
| | | margin-bottom: 0; |
| | | } |
| | | } |
| | | |
| | | .stats-row { |
| | |
| | | .patient-name { |
| | | font-weight: 600; |
| | | margin-bottom: 4px; |
| | | color: #2c3e50; |
| | | } |
| | | |
| | | .patient-detail { |
| | | font-size: 12px; |
| | | color: #666; |
| | | line-height: 1.4; |
| | | } |
| | | } |
| | | |
| | |
| | | color: #67C23A; |
| | | } |
| | | } |
| | | |
| | | // 响应式设计 |
| | | @media (max-width: 768px) { |
| | | .signed-patient-page { |
| | | padding: 10px; |
| | | |
| | | .search-card { |
| | | ::v-deep .el-col { |
| | | margin-bottom: 10px; |
| | | } |
| | | } |
| | | |
| | | .stats-row { |
| | | .el-col { |
| | | margin-bottom: 10px; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </style> |
| | |
| | | v-model="tempContractData.servicePackage" |
| | | style="width: 100%" |
| | | > |
| | | <el-row :gutter="16"> |
| | | <el-col :span="8" v-for="pkg in servicePackages" :key="pkg.id"> |
| | | <el-row :gutter="10"> |
| | | <el-col :span="7" v-for="pkg in servicePackages" :key="pkg.id"> |
| | | <el-card |
| | | :class="[ |
| | | 'package-card', |
| | |
| | | servicePackages: [ |
| | | { |
| | | id: 1, |
| | | name: "基础健康管理包", |
| | | description: "包含定期健康评估、基本咨询", |
| | | name: "婴幼儿健康基础包", |
| | | description: "为0-3岁婴幼儿提供全面的健康监测与发育指导", |
| | | price: 0, |
| | | features: ["年度健康评估", "在线咨询"], |
| | | features: [ |
| | | "新生儿家庭访视", |
| | | "定期体格检查与发育评估", |
| | | "血常规检测", |
| | | "听力筛查", |
| | | "喂养与护理指导", |
| | | "预防接种服务", |
| | | "中医保健指导(如摩腹、捏脊)", |
| | | ], |
| | | applicableAge: "0-3岁", |
| | | }, |
| | | { |
| | | id: 2, |
| | | name: "慢性病管理包", |
| | | description: "专为慢性病患者设计", |
| | | price: 299, |
| | | features: ["专属医生", "用药提醒", "定期随访"], |
| | | name: "学龄前儿童健康包", |
| | | description: "关注3-6岁儿童生长发育、常见病预防及习惯养成", |
| | | price: 0, |
| | | features: [ |
| | | "生长发育评估", |
| | | "视力筛查与口腔保健", |
| | | "血常规检查", |
| | | "合理膳食与行为指导", |
| | | "疾病预防与健康干预", |
| | | "中医饮食调养指导", |
| | | ], |
| | | applicableAge: "3-6岁", |
| | | }, |
| | | { |
| | | id: 3, |
| | | name: "老年人健康包", |
| | | description: "关注老年人健康问题", |
| | | price: 499, |
| | | features: ["跌倒风险评估", "康复指导", "紧急联系"], |
| | | name: "学龄儿童综合健康包", |
| | | description: "为7-12岁儿童提供学习期健康保障与发展支持", |
| | | price: 0, |
| | | features: [ |
| | | "年度健康检查", |
| | | "心理行为发育评估", |
| | | "科学用眼与口腔保健", |
| | | "合理膳食指导", |
| | | "健康生活方式干预", |
| | | "专家转诊绿色通道", |
| | | ], |
| | | applicableAge: "7-12岁", |
| | | }, |
| | | { |
| | | id: 4, |
| | | name: "青少年健康支持包", |
| | | description: "针对13-18岁青少年青春期特点的健康管理", |
| | | price: 0, |
| | | features: [ |
| | | "青春期健康教育", |
| | | "年度健康评估", |
| | | "心理健康支持", |
| | | "健康风险行为干预", |
| | | "个性化健康方案", |
| | | "优先预约检查服务", |
| | | ], |
| | | applicableAge: "13-18岁", |
| | | }, |
| | | { |
| | | id: 5, |
| | | name: "儿童营养与生长发育增值包", |
| | | description: "针对肥胖、营养不良等问题的专项管理", |
| | | price: 150, |
| | | features: [ |
| | | "微量元素测定", |
| | | "骨密度检测", |
| | | "个性化膳食方案", |
| | | "生长发育专项评估", |
| | | "运动处方指导", |
| | | "定期营养监测", |
| | | ], |
| | | applicableAge: "3-18岁", |
| | | }, |
| | | |
| | | ], |
| | | taskoptions: [ |
| | | // { |
| | |
| | | } |
| | | } |
| | | .package-card.active { |
| | | border-color: #409EFF; |
| | | border-color: #409eff; |
| | | background-color: #f0f9ff; |
| | | } |
| | | |
| | |
| | | > |
| | | |
| | | <el-tabs v-model="sontwoactiveName"> |
| | | <!-- <el-tab-pane name="blood" |
| | | ><span class="mulsz" slot="label" |
| | | ><i class="el-icon-s-operation"></i> 血压</span |
| | | ></el-tab-pane |
| | | > |
| | | <el-tab-pane name="glucose" |
| | | ><span class="mulsz" slot="label" |
| | | ><i class="el-icon-odometer"></i>血糖 |
| | | </span></el-tab-pane |
| | | > --> |
| | | |
| | | <el-tab-pane name="weight" |
| | | ><span class="mulsz" slot="label" |
| | | ><i class="el-icon-s-data"></i>身长头围趋势 |
| | | </span></el-tab-pane |
| | | > |
| | | <!-- <el-tab-pane name="heartrate" |
| | | ><span class="mulsz" slot="label" |
| | | ><i class="el-icon-s-operation"></i>心率 |
| | | </span></el-tab-pane |
| | | > |
| | | <el-tab-pane name="bloodoxygen" |
| | | ><span class="mulsz" slot="label" |
| | | ><i class="el-icon-s-data"></i>血氧 |
| | | </span></el-tab-pane |
| | | > |
| | | <el-tab-pane name="animalheat" |
| | | ><span class="mulsz" slot="label" |
| | | ><i class="el-icon-s-opportunity"></i>体温 |
| | | </span></el-tab-pane |
| | | > --> |
| | | |
| | | </el-tabs> |
| | | </el-tab-pane> |
| | | <el-tab-pane name="serve"> |
| | |
| | | </div> |
| | | <!-- 健康监测 --> |
| | | <div class="medical-record" v-show="activeName == 'monitor'"> |
| | | <!-- <div v-show="sontwoactiveName == 'blood'" style="display: flex"> |
| | | <div |
| | | id="xyeCharts" |
| | | class="sontwoactiveName" |
| | | style="width: 880px; height: 560px" |
| | | ></div> |
| | | <div style="width: 400px"> |
| | | <el-card class="box-card"> |
| | | <SFtable |
| | | :currentList="tableDatalist" |
| | | :tableLabel="tableLabelxy" |
| | | :center="false" |
| | | :multiplechoice="false" |
| | | /> |
| | | </el-card> |
| | | </div> |
| | | </div> --> |
| | | <!-- <div v-show="sontwoactiveName == 'glucose'" style="display: flex"> |
| | | <div |
| | | id="xteCharts" |
| | | class="sontwoactiveName" |
| | | style="width: 880px; height: 560px" |
| | | ></div> |
| | | <div style="width: 400px"> |
| | | <el-card class="box-card"> |
| | | <SFtable |
| | | :currentList="tableDatalist" |
| | | :tableLabel="tableLabelxt" |
| | | :center="false" |
| | | :multiplechoice="false" |
| | | /> |
| | | </el-card> |
| | | </div> |
| | | </div> --> |
| | | |
| | | <div v-show="sontwoactiveName == 'weight'" style="display: flex"> |
| | | <div |
| | | id="tzeCharts" |
| | |
| | | <span v-if="!scope.row.editing">{{ |
| | | scope.row.generatedTime |
| | | }}</span> |
| | | <!-- <el-date-picker |
| | | v-else |
| | | v-model="scope.row.generatedTime" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | value-format="yyyy-MM-dd" |
| | | size="small" |
| | | ></el-date-picker> --> |
| | | |
| | | <el-date-picker |
| | | v-else |
| | | v-model="scope.row.generatedTime" |
| | |
| | | </el-card> |
| | | </div> |
| | | </div> |
| | | <!-- <div v-show="sontwoactiveName == 'heartrate'" style="display: flex"> |
| | | <div |
| | | id="xleCharts" |
| | | class="sontwoactiveName" |
| | | style="width: 880px; height: 560px" |
| | | ></div> |
| | | <div style="width: 400px"> |
| | | <el-card class="box-card"> |
| | | <SFtable |
| | | :currentList="tableDatalist" |
| | | :tableLabel="tableLabelxl" |
| | | :center="false" |
| | | :multiplechoice="false" |
| | | /> |
| | | </el-card> |
| | | </div> |
| | | </div> --> |
| | | <!-- <div v-show="sontwoactiveName == 'bloodoxygen'" style="display: flex"> |
| | | <div |
| | | id="xueyangeCharts" |
| | | class="sontwoactiveName" |
| | | style="width: 880px; height: 560px" |
| | | ></div> |
| | | <div style="width: 400px"> |
| | | <el-card class="box-card"> |
| | | <SFtable |
| | | :currentList="tableDatalist" |
| | | :tableLabel="tableLabelxueyang" |
| | | :center="false" |
| | | :multiplechoice="false" |
| | | /> |
| | | </el-card> |
| | | </div> |
| | | </div> --> |
| | | <!-- <div v-show="sontwoactiveName == 'animalheat'" style="display: flex"> |
| | | <div |
| | | id="tweCharts" |
| | | class="sontwoactiveName" |
| | | style="width: 880px; height: 560px" |
| | | ></div> |
| | | <div style="width: 400px"> |
| | | <el-card class="box-card"> |
| | | <SFtable |
| | | :currentList="tableDatalist" |
| | | :tableLabel="tableLabeltw" |
| | | :center="false" |
| | | :multiplechoice="false" |
| | | /> |
| | | </el-card> |
| | | </div> |
| | | </div> --> |
| | | |
| | | </div> |
| | | <!-- 筛查摘要编辑对话框 --> |
| | | <el-dialog |
| | |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="记录日期" prop="generatedTime"> |
| | | <!-- <el-date-picker |
| | | v-model="borninfoform.generatedTime" |
| | | type="date" |
| | | placeholder="选择日期" |
| | | > |
| | | </el-date-picker> --> |
| | | |
| | | <el-date-picker |
| | | v-model="borninfoform.generatedTime" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | |
| | | ], |
| | | }, |
| | | record: [ |
| | | { |
| | | name: "宣教任务", |
| | | serviceType: "4", |
| | | templatename: "管饲宣教一期", |
| | | createTime: "2024-11-10", |
| | | finishtime: "2024-11-12", |
| | | createBy: "王政", |
| | | drname: "刘明", |
| | | nurseName: "张淑琴", |
| | | excep: "0", |
| | | deptname: "呼吸科", |
| | | leavehospitaldistrictname: "五病区", |
| | | }, |
| | | { |
| | | name: "随访任务", |
| | | serviceType: "2", |
| | | templatename: "心血管随访一期", |
| | | createTime: "2024-11-11", |
| | | finishtime: "2024-11-14", |
| | | createBy: "章程", |
| | | drname: "刘明", |
| | | nurseName: "李丽", |
| | | excep: "0", |
| | | deptname: "呼吸科", |
| | | leavehospitaldistrictname: "五病区", |
| | | }, |
| | | |
| | | // { |
| | | // name: "问卷调查", |
| | | // }, |