fixed
This commit is contained in:
@@ -27,6 +27,7 @@ class Reporttt extends BaseHttpApi
|
||||
* desc:疼痛科-数字人-生成听诊报告(同时提交固定问答聊天记录)
|
||||
*
|
||||
* api/Reporttt/createReport
|
||||
* username 用户名
|
||||
*
|
||||
* name 病人姓名
|
||||
gender 病人性别
|
||||
@@ -45,6 +46,12 @@ class Reporttt extends BaseHttpApi
|
||||
wechat_no 微信号
|
||||
ticket 对话票据
|
||||
hdrdepartment_id 科室
|
||||
*
|
||||
* content 对话内容;格式:
|
||||
* $content = [
|
||||
["role" => "user", "content" => '医生说:xxxxx'],
|
||||
["role" => "user", "content" => '患者说:xxxxx'],
|
||||
];
|
||||
* author:wh
|
||||
*/
|
||||
function createReport(){
|
||||
@@ -68,11 +75,13 @@ class Reporttt extends BaseHttpApi
|
||||
if(empty($ticket)){
|
||||
return json(Tools::set_fail('对话票据ticket必须(用于隔离用户聊天历史记录),登陆时返回票据,每次诊断结束重新生成票据!'));
|
||||
}
|
||||
$username = input('username');
|
||||
if(empty($username)){
|
||||
return json(Tools::set_fail('username不存在'));
|
||||
}
|
||||
$user = Db::table('fa_tt_users')->where('username',$username)->find();
|
||||
|
||||
//$username = input('username');
|
||||
//if(empty($username)){
|
||||
// return json(Tools::set_fail('username不存在'));
|
||||
//}
|
||||
|
||||
$user = Db::table('fa_tt_users')->where('ticket',$ticket)->find();
|
||||
if(empty($user)){
|
||||
return json(Tools::set_res(530,'用户不存在'));
|
||||
}
|
||||
|
||||
@@ -106,17 +106,17 @@ class Userstt extends BaseHttpApi
|
||||
|
||||
unset($user['password']);
|
||||
|
||||
$expires = 7*86400+time();//报告完成之后重新获取票据
|
||||
//$expires = 7*86400+time();//报告完成之后重新获取票据
|
||||
|
||||
|
||||
//返回票据
|
||||
$ticketstr = md5($user['username'].$expires);
|
||||
$ticketstr = md5($user['username']);
|
||||
|
||||
//修改有效期
|
||||
Db::table('fa_tt_users')
|
||||
->data([
|
||||
'ticket'=>$ticketstr,
|
||||
'expires'=>$expires,//7天
|
||||
//'expires'=>$expires,//7天
|
||||
//'clientid'=>$clientid,
|
||||
])
|
||||
->where('username',$username)
|
||||
|
||||
@@ -181,6 +181,219 @@
|
||||
</div>
|
||||
<div class="api_hdrregister_getHdrregisterList_response_result"></div>
|
||||
|
||||
</div><div id="api_reporttt_createReport">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:疼痛科-数字人-生成听诊报告(同时提交固定问答聊天记录)
|
||||
*
|
||||
* api/Reporttt/createReport
|
||||
*
|
||||
* name 病人姓名
|
||||
gender 病人性别
|
||||
age 病人年龄
|
||||
edu 教育程度
|
||||
career_year 职业及年限
|
||||
power 体力要求
|
||||
satisfaction 经济满意度
|
||||
old_career_year 过往职业及年限
|
||||
support 社会支持度
|
||||
marriage 婚姻状况
|
||||
live 居住情况
|
||||
home 家庭关系
|
||||
address 地址
|
||||
phone 联系方式
|
||||
wechat_no 微信号
|
||||
ticket 对话票据
|
||||
hdrdepartment_id 科室
|
||||
* author:wh
|
||||
* api/reporttt/createReport
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reporttt_createReport_textarea" cols="100" rows="3">/api/reporttt/createReport</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reporttt_createReport()">测试</a>
|
||||
</div>
|
||||
<div class="api_reporttt_createReport_response_result"></div>
|
||||
|
||||
</div><div id="api_reporttt_getReportById">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告详情
|
||||
*
|
||||
* api/Reporttt/getReportById
|
||||
* 参数:dataid 报告id
|
||||
* ticket:用户ticket
|
||||
* author:wh
|
||||
* api/reporttt/getReportById
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reporttt_getReportById_textarea" cols="100" rows="3">/api/reporttt/getReportById</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reporttt_getReportById()">测试</a>
|
||||
</div>
|
||||
<div class="api_reporttt_getReportById_response_result"></div>
|
||||
|
||||
</div><div id="api_reporttt_getReportList">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告列表
|
||||
*
|
||||
* api/Reporttt/getReportList
|
||||
* 参数:username
|
||||
* ticket:用户ticket
|
||||
*
|
||||
* author:wh
|
||||
* api/reporttt/getReportList
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reporttt_getReportList_textarea" cols="100" rows="3">/api/reporttt/getReportList</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reporttt_getReportList()">测试</a>
|
||||
</div>
|
||||
<div class="api_reporttt_getReportList_response_result"></div>
|
||||
|
||||
</div><div id="api_reporttt_editReport">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* 修改报告
|
||||
* api/Reporttt/editReport
|
||||
* 参数:dataid 报告数据id
|
||||
name 病人姓名
|
||||
gender 病人性别: M=男性, F=女性
|
||||
age 病人年龄
|
||||
main_complaint 主诉
|
||||
medical_history 病史
|
||||
past_history 既往史
|
||||
allergy_history 过敏史
|
||||
family_history 家族史
|
||||
personal_history 个人史
|
||||
menstrual_marital_history 月经婚育史
|
||||
diagnosis 诊断
|
||||
treatment 医嘱
|
||||
* api/reporttt/editReport
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reporttt_editReport_textarea" cols="100" rows="3">/api/reporttt/editReport</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reporttt_editReport()">测试</a>
|
||||
</div>
|
||||
<div class="api_reporttt_editReport_response_result"></div>
|
||||
|
||||
</div><div id="api_reportty_createReport">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:听译-生成听诊报告
|
||||
*
|
||||
* api/Reportty/createReport
|
||||
*
|
||||
* author:wh
|
||||
* api/reportty/createReport
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reportty_createReport_textarea" cols="100" rows="3">/api/reportty/createReport</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reportty_createReport()">测试</a>
|
||||
</div>
|
||||
<div class="api_reportty_createReport_response_result"></div>
|
||||
|
||||
</div><div id="api_reportty_getReportById">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告详情
|
||||
*
|
||||
* api/Reportty/getReportById
|
||||
* 参数:dataid 报告id
|
||||
* ticket:用户ticket
|
||||
* author:wh
|
||||
* api/reportty/getReportById
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reportty_getReportById_textarea" cols="100" rows="3">/api/reportty/getReportById</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reportty_getReportById()">测试</a>
|
||||
</div>
|
||||
<div class="api_reportty_getReportById_response_result"></div>
|
||||
|
||||
</div><div id="api_reportty_getReportList">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告列表
|
||||
*
|
||||
* api/Reportty/getReportList
|
||||
* 参数:username
|
||||
* ticket:用户ticket
|
||||
*
|
||||
* author:wh
|
||||
* api/reportty/getReportList
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reportty_getReportList_textarea" cols="100" rows="3">/api/reportty/getReportList</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reportty_getReportList()">测试</a>
|
||||
</div>
|
||||
<div class="api_reportty_getReportList_response_result"></div>
|
||||
|
||||
</div><div id="api_reportty_editReport">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
```
|
||||
/**
|
||||
* 修改报告
|
||||
* api/Reportty/editReport
|
||||
* 参数:dataid 报告数据id
|
||||
name 病人姓名
|
||||
gender 病人性别: M=男性, F=女性
|
||||
age 病人年龄
|
||||
main_complaint 主诉
|
||||
medical_history 病史
|
||||
past_history 既往史
|
||||
allergy_history 过敏史
|
||||
family_history 家族史
|
||||
personal_history 个人史
|
||||
menstrual_marital_history 月经婚育史
|
||||
diagnosis 诊断
|
||||
treatment 医嘱
|
||||
ticket 对话票据
|
||||
hdrdepartment_id 科室
|
||||
* api/reportty/editReport
|
||||
*/
|
||||
```
|
||||
</div>
|
||||
<div>
|
||||
按需填写其它接口参数:
|
||||
<textarea name="" id="api_reportty_editReport_textarea" cols="100" rows="3">/api/reportty/editReport</textarea>
|
||||
<a href='JavaScript:;' onclick="DocObject.api_reportty_editReport()">测试</a>
|
||||
</div>
|
||||
<div class="api_reportty_editReport_response_result"></div>
|
||||
|
||||
</div><div id="api_ttchathistory_getTtchathistoryList">
|
||||
<div class="markdown_content">
|
||||
***
|
||||
@@ -441,6 +654,54 @@
|
||||
$('.api_hdrregister_getHdrregisterList_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_hdrregister_getHdrregisterList_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reporttt_createReport(){
|
||||
let url = $('#api_reporttt_createReport_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reporttt_createReport_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reporttt_createReport_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reporttt_getReportById(){
|
||||
let url = $('#api_reporttt_getReportById_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reporttt_getReportById_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reporttt_getReportById_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reporttt_getReportList(){
|
||||
let url = $('#api_reporttt_getReportList_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reporttt_getReportList_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reporttt_getReportList_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reporttt_editReport(){
|
||||
let url = $('#api_reporttt_editReport_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reporttt_editReport_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reporttt_editReport_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reportty_createReport(){
|
||||
let url = $('#api_reportty_createReport_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reportty_createReport_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reportty_createReport_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reportty_getReportById(){
|
||||
let url = $('#api_reportty_getReportById_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reportty_getReportById_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reportty_getReportById_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reportty_getReportList(){
|
||||
let url = $('#api_reportty_getReportList_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reportty_getReportList_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reportty_getReportList_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_reportty_editReport(){
|
||||
let url = $('#api_reportty_editReport_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
$('.api_reportty_editReport_response_result').html(JSON.stringify(res, null, "\t"));
|
||||
$('.api_reportty_editReport_response_result').attr('style','color:green');
|
||||
},'json');
|
||||
}, api_ttchathistory_getTtchathistoryList(){
|
||||
let url = $('#api_ttchathistory_getTtchathistoryList_textarea').val();
|
||||
$.post(url,{},function(res) {
|
||||
|
||||
@@ -134,6 +134,147 @@
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:疼痛科-数字人-生成听诊报告(同时提交固定问答聊天记录)
|
||||
*
|
||||
* api/Reporttt/createReport
|
||||
*
|
||||
* name 病人姓名
|
||||
gender 病人性别
|
||||
age 病人年龄
|
||||
edu 教育程度
|
||||
career_year 职业及年限
|
||||
power 体力要求
|
||||
satisfaction 经济满意度
|
||||
old_career_year 过往职业及年限
|
||||
support 社会支持度
|
||||
marriage 婚姻状况
|
||||
live 居住情况
|
||||
home 家庭关系
|
||||
address 地址
|
||||
phone 联系方式
|
||||
wechat_no 微信号
|
||||
ticket 对话票据
|
||||
hdrdepartment_id 科室
|
||||
* author:wh
|
||||
* api/reporttt/createReport
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告详情
|
||||
*
|
||||
* api/Reporttt/getReportById
|
||||
* 参数:dataid 报告id
|
||||
* ticket:用户ticket
|
||||
* author:wh
|
||||
* api/reporttt/getReportById
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告列表
|
||||
*
|
||||
* api/Reporttt/getReportList
|
||||
* 参数:username
|
||||
* ticket:用户ticket
|
||||
*
|
||||
* author:wh
|
||||
* api/reporttt/getReportList
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* 修改报告
|
||||
* api/Reporttt/editReport
|
||||
* 参数:dataid 报告数据id
|
||||
name 病人姓名
|
||||
gender 病人性别: M=男性, F=女性
|
||||
age 病人年龄
|
||||
main_complaint 主诉
|
||||
medical_history 病史
|
||||
past_history 既往史
|
||||
allergy_history 过敏史
|
||||
family_history 家族史
|
||||
personal_history 个人史
|
||||
menstrual_marital_history 月经婚育史
|
||||
diagnosis 诊断
|
||||
treatment 医嘱
|
||||
* api/reporttt/editReport
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:听译-生成听诊报告
|
||||
*
|
||||
* api/Reportty/createReport
|
||||
*
|
||||
* author:wh
|
||||
* api/reportty/createReport
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告详情
|
||||
*
|
||||
* api/Reportty/getReportById
|
||||
* 参数:dataid 报告id
|
||||
* ticket:用户ticket
|
||||
* author:wh
|
||||
* api/reportty/getReportById
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* desc:查询报告列表
|
||||
*
|
||||
* api/Reportty/getReportList
|
||||
* 参数:username
|
||||
* ticket:用户ticket
|
||||
*
|
||||
* author:wh
|
||||
* api/reportty/getReportList
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
* 修改报告
|
||||
* api/Reportty/editReport
|
||||
* 参数:dataid 报告数据id
|
||||
name 病人姓名
|
||||
gender 病人性别: M=男性, F=女性
|
||||
age 病人年龄
|
||||
main_complaint 主诉
|
||||
medical_history 病史
|
||||
past_history 既往史
|
||||
allergy_history 过敏史
|
||||
family_history 家族史
|
||||
personal_history 个人史
|
||||
menstrual_marital_history 月经婚育史
|
||||
diagnosis 诊断
|
||||
treatment 医嘱
|
||||
ticket 对话票据
|
||||
hdrdepartment_id 科室
|
||||
* api/reportty/editReport
|
||||
*/
|
||||
```
|
||||
|
||||
***
|
||||
```
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user