1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- <?php
- namespace app\controller;
- use app\model\XySickNess;
- use think\facade\Request;
- class Graph extends CommonTwoController
- {
- public function index()
- {
- $tag = Request::param('tag') ?? '';
- $name = Request::param('name') ?? '';
- if( ! $tag || ! $name) {
- return $this->_json_error('请求参数有误!');
- }
- switch($tag)
- {
- case "SickNess":
- $xySickNess = XySickNess::where('name' , $name)->find();
- $aboutMedicine = $xySickNess->
- $data = [
- 'sickness_name' => ['name' => '名称' , 'text' => $xySickNess['name'] ??''],
- 'alias' => ['name' => '疾病别名' , 'text' => $xySickNess['alias'] ?? ''],
- 'ICD10' => ['name' => 'ICD10' , 'text' => $xySickNess['ICD10'] ?? ''],
- 'department' => ['name' => '疾病类别' , 'text' => $xySickNess['department'] ?? ''],
- //'complication' => ['name' => '并发症' , 'text' => $this->getSicknessComplication($sickness , 'sickness') ?? ''],
- //'medicine' => ['name' => '相关药品' , 'text' => $medicine ?? ''] ,
- 'introduction' => ['name' => '疾病概述' , 'text' => $xySickNess['introduction'] ?? ''],
- 'epidemiology' => ['name' => '流行病学' , 'text' => $xySickNess['epidemiology'] ?? ''],
- 'suitableFood' => ['name' => '宜吃食物' , 'text' => $xySickNess['suitableFood'] ?? ''],
- 'notEat' => ['name' => '忌吃食物' , 'text' => $xySickNess['notEat'] ?? ''],
- 'diagnostiCtriage' => ['name' => '诊断鉴别' , 'text' => $xySickNess['diagnostiCtriage'] ?? ''],
- 'precaution' => ['name' => '预防' , 'text' => $xySickNess['precaution'] ?? ''],
- 'nursingInfo' => ['name' => '护理信息' , 'text' => $xySickNess['nursingInfo'] ?? ''],
- 'warmPrompt' => ['name' => '温馨提示' , 'text' => $xySickNess['warmPrompt'] ?? ''],
- 'recommendedRecipe' => ['name' => '推荐食谱' , 'text' => $xySickNess['recommendedRecipe'] ?? ''],
- 'treatmentOverview' => ['name' => '治疗概述' , 'text' => $xySickNess['treatmentOverview'] ?? ''],
- 'inspection' => ['name' => '检查' , 'text' => $xySickNess['inspection'] ?? ''],
- 'treatmenCommonSense' => ['name' => '治疗常识' , 'text' => $xySickNess['treatmenCommonSense'] ?? ''],
- 'pathogenesis' => ['name' => '病因' , 'text' => $xySickNess['pathogenesis'] ?? ''],
- 'basicKnowledgel' => ['name' => '基本常识' , 'text' => $xySickNess['basicKnowledgel'] ?? ''],
- 'dietHealth' => ['name' => '饮食保健' , 'text' => $xySickNess['dietHealth'] ?? ''],
- 'symptom' => ['name' => '证型' , 'text' => $xySickNess['symptom'] ?? ''],
- 'complicationsOverview' => ['name' => '并发症概述', 'text' => $xySickNess['complicationsOverview'] ?? ''],
- 'treatmentInfo' => ['name' => '治疗信息' , 'text' => $xySickNess['treatmentInfo'] ?? '']
- ];
- break;
- }
- }
- }
|