Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
赵增煜
/
tzt-admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
b73ab9cd
authored
Dec 12, 2024
by
lujunyi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' of
http://git.imohe.com/zhaozengyu/tzt-admin
into develop
parents
ffd8c050
90f2b164
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
5 deletions
+8
-5
app/Admin/Controllers/DrugController.php
+1
-1
app/Admin/Renderable/DrugTable.php
+1
-1
app/Api/Controllers/PrescriptionController.php
+4
-1
app/Models/DoctorModel.php
+2
-2
No files found.
app/Admin/Controllers/DrugController.php
View file @
b73ab9cd
...
...
@@ -137,7 +137,7 @@ protected function form()
$form
->
switch
(
'is_foreign'
);
$form
->
switch
(
'is_rx'
);
$form
->
switch
(
'is_si'
);
$array
=
range
(
0
,
10
);
$array
=
range
(
0
,
10
0
);
$limitOption
=
array_combine
(
$array
,
$array
);
$form
->
select
(
'limit_buy_7'
)
->
placeholder
(
'请选择限购数量'
)
->
options
(
$limitOption
)
->
help
(
'限购数量'
)
->
required
()
->
default
(
0
);
$form
->
multipleSelect
(
'tag'
,
'标签'
)
...
...
app/Admin/Renderable/DrugTable.php
View file @
b73ab9cd
...
...
@@ -44,7 +44,7 @@ public function grid(): Grid
});
// 行按钮控制
$grid
->
paginate
(
10
);
$grid
->
paginate
(
10
0
);
$grid
->
disableActions
();
});
}
...
...
app/Api/Controllers/PrescriptionController.php
View file @
b73ab9cd
...
...
@@ -152,18 +152,21 @@ public function create(Request $request)
// 问诊问题
$inquiry_info
=
[];
$is_abnormal
=
0
;
// 是否异常处方单,只有一个问题回答是就是异常
// Log::info('inquirys:'.json_encode($inquirys));
foreach
(
$inquirys
as
$inquiry
)
{
$answer
=
intval
(
$inquiry
[
'answer'
]);
$inquiry
=
InquiryModel
::
find
(
$inquiry
[
'inquiry_id'
]);
$inquiry_info
[]
=
[
'inquiry_id'
=>
$inquiry
[
'inquiry_id'
],
'question'
=>
$inquiry
->
question
,
'answer'
=>
$inquiry
[
'answer'
]
==
1
?
1
:
0
,
// [1 => '是', 0 => '否']
'answer'
=>
$answer
=
==
1
?
1
:
0
,
// [1 => '是', 0 => '否']
];
// 检查是否有一个answer是1
if
(
$inquiry
[
'answer'
]
==
1
)
{
$is_abnormal
=
1
;
// 如果有一个answer是1,设置$is_abnormal为1
}
}
// Log::info('inquiry_info'.json_encode($inquiry_info));
$prescription
->
inquiry_info
=
$inquiry_info
;
// 用药信息
$drug_info
=
[];
...
...
app/Models/DoctorModel.php
View file @
b73ab9cd
...
...
@@ -52,8 +52,8 @@ class DoctorModel extends Model
// 性别-文字映射
const
DOCTOR_TYPE_MAP
=
[
self
::
DOCTOR_TYPE_ALL
=>
'全部'
,
self
::
DOCTOR_TYPE_WM
=>
'西
药
'
,
self
::
DOCTOR_TYPE_TCM
=>
'中
药
'
,
self
::
DOCTOR_TYPE_WM
=>
'西
医
'
,
self
::
DOCTOR_TYPE_TCM
=>
'中
医
'
,
];
// 医师所属于的用户,一对一
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment