更新版本20201013(出院浏览科室条件搜索按权限、处理登录跳转明文、解决待审批搜索bug)

master
zengwh 5 years ago
parent 618e118395
commit 30f0e2d0f1

@ -81,22 +81,24 @@ public class LoginController {
UsernamePasswordToken userToken = new UsernamePasswordToken(userName, "123456");
Subject subject = SecurityUtils.getSubject();
subject.login(userToken);
model.addAttribute("POWER_URLHEAD", POWER_URLHEAD);
model.addAttribute("POWER_JSP", POWER_JSP);
request.getSession().setAttribute("POWER_URLHEAD", POWER_URLHEAD);
request.getSession().setAttribute("POWER_JSP", POWER_JSP);
//传递通知需要的数据
model.addAttribute("WEBSOCKET_URLHEAD", WEBSOCKET_URLHEAD);
model.addAttribute("STR_SPLIT", STR_SPLIT);
request.getSession().setAttribute("WEBSOCKET_URLHEAD", WEBSOCKET_URLHEAD);
request.getSession().setAttribute("STR_SPLIT", STR_SPLIT);
//设置进session
ActionScopeUtils.setSessionAttribute("token",token,Integer.valueOf(String.valueOf(TOKEN_EXPIRE_TIME)));
ActionScopeUtils.setSessionAttribute("CURRENT_USER",powerUser,Integer.valueOf(String.valueOf(TOKEN_EXPIRE_TIME)));
}else{
return "redirect:"+POWER_URLHEAD+"/login";
}
return "index";
String contextPath = request.getScheme()+"://"+request.getServerName()+":"
+request.getServerPort() + request.getContextPath();
return "redirect:"+contextPath+"/index";
}
@RequestMapping(value = "/index")
public String Login() {
public String index() {
return "index";
}

@ -38,6 +38,8 @@ public class Archive_Master_Vo extends Archive_Master{
private Integer role;//操作角色1,2,4
private Integer operRole;//操作角色1,2,4
private String roles;//操作角色字符串
private Integer infoId;//流转流程的id

@ -228,7 +228,8 @@ public class Archive_MasterServiceImpl implements Archive_MasterService {
"and freg_date is not null";
try{
//执行查询
List<String> selectList = OracleConnect.selectList(sql);
List<String> selectList = new ArrayList<>();
selectList = OracleConnect.selectList(sql);
for (Archive_Master_Vo masterVo : list) {
masterVo.setRemark("未签收");
//赋值

@ -285,7 +285,16 @@
<sql id="selectByApproveRole">
<if test="infoId != null">
<if test="infoId == 1">
LEFT JOIN ( SELECT master_id, COUNT( id ) approveCount FROM archive_flow_info WHERE step_index = 1 GROUP BY master_id HAVING ( COUNT( id )) = 2 ) temp3 ON m.id = temp3.master_id
LEFT JOIN (
<if test="operRole != null">
<if test="operRole == 4">
select master_id,master_id approveCount from ( select master_id,step_index from archive_flow_info where step_index in (1,2) group by master_id,step_index) temp group by master_id having(COUNT(master_id)) = 2
</if>
<if test="operRole != 4">
SELECT master_id,master_id approveCount FROM archive_flow_info WHERE step_index = 1 and oper_role = ${operRole}
</if>
</if>
) temp3 ON m.id = temp3.master_id
</if>
<if test="infoId != 1">
INNER JOIN
@ -316,7 +325,7 @@
<!---出院-->
<select id="selectByColumn" parameterType="com.emr.entity.Archive_Master_Vo" resultMap="BaseResultMap2">
select m.id,m.patient_id,m.inp_no,m.visit_id,m.name,m.sex,m.
select * from (select m.id,m.patient_id,m.inp_no,m.visit_id,m.name,m.sex,m.
dept_name,m.discharge_date_time,m.ArchiveState,m.admission_date_time,m.
dept_admission_to,m.LockInfo,m.DOCTOR_IN_CHARGE
from archive_master m
@ -332,17 +341,25 @@
inner join
(select archive_flow_info.master_id from archive_flow_info
inner join
(select MAX(createtime) createtime,master_id from archive_flow_info group by master_id) temp
on archive_flow_info.master_id = temp.master_id and archive_flow_info.createtime = temp.createtime and
archive_flow_info.target_step_id in (${status})) archive_flow_info
on archive_flow_info.master_id = m.id
(
<if test="role != 4">
select MAX(createtime) createtime,master_id from archive_flow_info
<if test="operRole != null">
where oper_role = ${operRole}
</if>
group by master_id) temp
on archive_flow_info.master_id = temp.master_id and archive_flow_info.createtime = temp.createtime and
archive_flow_info.target_step_id in (${status})) archive_flow_info
on archive_flow_info.master_id = m.id
</if>
/**护士长*/
<if test="role == 4">
inner join
(select master_id from archive_flow_info where target_step_id in (${status}) group by master_id
having COUNT(master_id) =
2) temp1
on archive_flow_info.master_id = temp1.master_id
SELECT master_id,MAX( createtime ) createtime FROM archive_flow_info group by master_id,oper_role) temp
on archive_flow_info.master_id = temp.master_id and archive_flow_info.createtime = temp.createtime
where archive_flow_info.target_step_id = 7
group by archive_flow_info.master_id having(COUNT( archive_flow_info.master_id)) = 2
) archive_flow_info
on archive_flow_info.master_id = m.id and m.ArchiveState != '64'
</if>
</if>
/**已审批*/
@ -359,19 +376,16 @@
master_id
FROM
archive_flow_info
<if test="operRole != null">
where oper_role = ${operRole}
</if>
GROUP BY
master_id
) temp ON archive_flow_info.master_id = temp.master_id
AND archive_flow_info.createtime = temp.createtime
AND archive_flow_info.target_step_id != #{status}
INNER JOIN (
SELECT
master_id
FROM
archive_flow_info
WHERE
start_step_id = #{status}
) temp1 ON archive_flow_info.master_id = temp1.master_id) archive_flow_info
AND start_step_id >= ${status}
and target_step_id != 9 and target_step_id != 10
) archive_flow_info
on archive_flow_info.master_id = m.id
</if>
</if>
@ -389,7 +403,14 @@
dept_admission_to,m.LockInfo,m.DOCTOR_IN_CHARGE
from archive_master m
/**带状态查询*/
left join (select master_id from archive_flow_info where start_step_id in(${status}) group by master_id)
left join (select archive_flow_info.master_id from archive_flow_info
inner join
(select MAX(createtime) createtime,master_id from archive_flow_info
<if test="operRole != null">
where oper_role = ${operRole}
</if>
group by master_id) temp
on archive_flow_info.master_id = temp.master_id and archive_flow_info.createtime = temp.createtime where target_step_id != 9 and target_step_id != 10)
archive_flow_info
on m.id = archive_flow_info.master_id
/**带完整性查询*/
@ -406,7 +427,9 @@
and archive_flow_info.master_id is null
<include refid="beHospitalSeach"></include>
</if>
) m
ORDER BY m.discharge_date_time desc
</select>
<!--终审-->

@ -56,4 +56,4 @@
<script src="${path}/static/bootstrap-3.3.7/bower_components/bootstrap/dist/js/fileinput.min.js"></script>
<script type="text/javascript" src="${path}/static/js/hospitalCommom/pinying.js"></script>
<script type="text/javascript" src="${path}/static/js/comm.js?t=2020-08-18"></script>
<script type="text/javascript" src="${path}/static/js/comm.js?t=2020-10-12"></script>

@ -750,7 +750,7 @@
</div>
</div>
</body>
<script src="${path}/static/js/beHospList/beHospList.js?time=2020-10-09"></script>
<script src="${path}/static/js/beHospList/beHospList.js?time=2020-10-12"></script>
<script src="${path}/static/js/hospitalCommom/hospitalCommom.js?time=2020-10-09_1"></script>
<script src="${path}/static/js/hospitalLoadPdf/loadPdf.js?time=2020-10-09"></script>
</html>

@ -354,7 +354,7 @@
</div>
<footer class="main-footer">
<div class="pull-right">
<b>Version</b> 20201009
<b>Version</b> 20201012
</div>
<strong>Copyright &copy; 2019-2090 厦门嘉时软件.</strong> All rights
reserved.

@ -69,7 +69,8 @@ function initTable() {
role:$("#currentRole").val(),
roles:$("#searchOperRole").val(),
isSuccess:$("#isSuccessSearch").val(),
infoId:$("#infoId").val()
infoId:$("#infoId").val(),
operRole:$("#checker").val()
};
return temp;
},
@ -778,7 +779,8 @@ $("#excelBtn").click(function () {
"role":role,
"roles":$("#searchOperRole").val(),
"isSuccess":$("#isSuccessSearch").val(),
"infoId":$("#infoId").val()
"infoId":$("#infoId").val(),
"operRole":$("#checker").val()
});
});

@ -23,11 +23,23 @@ function getDept() {
success: function (result) {
if (result != null) {
var html = '';
var deptNameForQuery = getDeptNameForQuery();
for (var i = 0; i < result.length; i++) {
var name = result[i].name;
var py = makePy(name);
var pingyin = ConvertPinyin(name);
html += '<option data-tokens="' + name + '|' + py[0] + '|' + pingyin + '" value="' + result[i].code + '">' + name + '</option>';
var flag = 0;
if(deptNameForQuery != ''){
var deptNameForQueryArr = deptNameForQuery.split(",");
for (var j = 0; j < deptNameForQueryArr.length; j++) {
if(result[i].code == deptNameForQueryArr[j]){
flag = 1;
}
}
}
if(flag == 1 || deptNameForQuery == '') {
var name = result[i].name;
var py = makePy(name);
var pingyin = ConvertPinyin(name);
html += '<option data-tokens="' + name + '|' + py[0] + '|' + pingyin + '" value="' + result[i].code + '">' + name + '</option>';
}
}
$("#deptName").append(html);
$("#deptAdmissionTo").append(html);

Loading…
Cancel
Save