NavigationController.java 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736
  1. package cn.hnthyy.thmz.controller;
  2. import cn.hnthyy.thmz.Utils.TokenUtil;
  3. import cn.hnthyy.thmz.entity.thmz.*;
  4. import cn.hnthyy.thmz.service.thmz.MenuService;
  5. import cn.hnthyy.thmz.service.thmz.RoleMenuRelationService;
  6. import cn.hnthyy.thmz.service.thmz.UserMenuRelationService;
  7. import cn.hnthyy.thmz.service.thmz.UserRoleRelationService;
  8. import lombok.extern.slf4j.Slf4j;
  9. import org.springframework.beans.factory.annotation.Autowired;
  10. import org.springframework.stereotype.Controller;
  11. import org.springframework.web.bind.annotation.RequestMapping;
  12. import javax.servlet.http.HttpServletRequest;
  13. import java.util.ArrayList;
  14. import java.util.HashSet;
  15. import java.util.List;
  16. import java.util.Set;
  17. import java.util.stream.Collectors;
  18. /**
  19. * 导航控制层,负责路由功能
  20. */
  21. @Controller
  22. @Slf4j
  23. public class NavigationController {
  24. @Autowired
  25. private MenuService menuService;
  26. @Autowired
  27. private RoleMenuRelationService roleMenuRelationService;
  28. @Autowired
  29. private UserRoleRelationService userRoleRelationService;
  30. /**
  31. * 打开登录页面
  32. *
  33. * @return
  34. */
  35. @RequestMapping("/login/view")
  36. public String loginView() {
  37. return "login";
  38. }
  39. /**
  40. * 打开导航页面
  41. *
  42. * @return
  43. */
  44. @RequestMapping("/menu/view")
  45. public String menuView() {
  46. return "menu";
  47. }
  48. /**
  49. * 打开主页面
  50. *
  51. * @return
  52. */
  53. @RequestMapping("/index")
  54. public String index(HttpServletRequest httpServletRequest) throws Exception {
  55. List<String> urls = getRoleUrls(httpServletRequest);
  56. if (!urls.contains("/thmz/index")) {
  57. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  58. }
  59. return "index";
  60. }
  61. /**
  62. * 打开科室列表页面
  63. *
  64. * @return
  65. */
  66. @RequestMapping("/unit-code")
  67. public String unitCode(HttpServletRequest httpServletRequest) throws Exception {
  68. List<String> urls = getRoleUrls(httpServletRequest);
  69. if (!urls.contains("/thmz/unit-code")) {
  70. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  71. }
  72. return "mz/unit_code";
  73. }
  74. /**
  75. * 打开挂号管理页面
  76. *
  77. * @return
  78. */
  79. @RequestMapping("/registration")
  80. public String registration(HttpServletRequest httpServletRequest) throws Exception {
  81. List<String> urls = getRoleUrls(httpServletRequest);
  82. if (!urls.contains("/thmz/registration")) {
  83. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  84. }
  85. return "mz/registration";
  86. }
  87. /**
  88. * 打开挂号列表页面
  89. *
  90. * @return
  91. */
  92. @RequestMapping("/registration-list")
  93. public String registrationList(HttpServletRequest httpServletRequest) throws Exception {
  94. List<String> urls = getRoleUrls(httpServletRequest);
  95. if (!urls.contains("/thmz/registration-list")) {
  96. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  97. }
  98. return "mz/registration_list";
  99. }
  100. // private List<String> getUrls(HttpServletRequest httpServletRequest) throws Exception {
  101. // User tokenUser = TokenUtil.getUser(httpServletRequest);
  102. // List<UserMenuRelation> userMenuRelationList = userMenuRelationService.queryByUserId(tokenUser.getId());
  103. // List<Long> menuIds = userMenuRelationList.stream().map(UserMenuRelation::getMenuId).collect(Collectors.toList());
  104. // if (menuIds == null || menuIds.size() == 0) {
  105. // throw new Exception("您没有此模块的权限,请联系管理员开通!");
  106. // }
  107. // List<Menu> menuList = menuService.queryByIds(menuIds);
  108. // return menuList.stream().map(Menu::getMenuUrl).collect(Collectors.toList());
  109. // }
  110. private List<String> getRoleUrls(HttpServletRequest httpServletRequest) throws Exception {
  111. User tokenUser = TokenUtil.getUser(httpServletRequest);
  112. List<UserRoleRelation> userRoleRelations = userRoleRelationService.queryByUserId(tokenUser.getId());
  113. Set<RoleMenuRelation> roleMenuRelationSet = new HashSet<RoleMenuRelation>();
  114. for (UserRoleRelation userRoleRelation : userRoleRelations) {
  115. List<RoleMenuRelation> list = roleMenuRelationService.queryByRoleId(userRoleRelation.getRoleId());
  116. roleMenuRelationSet.addAll(list);
  117. }
  118. List<Long> menuIdsNew = roleMenuRelationSet.stream().map(RoleMenuRelation::getMenuId).collect(Collectors.toList());
  119. List<Long> menuIds=new ArrayList<>(new HashSet(menuIdsNew));//利用Set去重多个角色相同的菜单权限
  120. if (menuIds == null || menuIds.size() == 0) {
  121. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  122. }
  123. List<Menu> menuList = menuService.queryByIds(menuIds);
  124. return menuList.stream().map(Menu::getMenuUrl).collect(Collectors.toList());
  125. }
  126. /**
  127. * 打开收费管理页面
  128. *
  129. * @return
  130. */
  131. @RequestMapping({"/toll-administration"})
  132. public String tollAdministration(HttpServletRequest httpServletRequest) throws Exception {
  133. List<String> urls = getRoleUrls(httpServletRequest);
  134. if (!urls.contains("/thmz/toll-administration")) {
  135. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  136. }
  137. return "mz/toll_administration";
  138. }
  139. // /**
  140. // * 打开收费管理页面,带参数跳转
  141. // *
  142. // * @return
  143. // */
  144. // @RequestMapping({"/toll-administration/{patientId}"})
  145. // public String tollAdministration(@PathVariable String patientId, HttpServletRequest httpServletRequest) throws Exception {
  146. // List<String> urls = getUrls(httpServletRequest);
  147. // httpServletRequest.setAttribute("patientId",patientId);
  148. // if (!urls.contains("/thmz/toll-administration")) {
  149. // throw new Exception("您没有此模块的权限,请联系管理员开通!");
  150. // }
  151. // return "toll_administration";
  152. // }
  153. /**
  154. * 打开收费员基础设置页面
  155. *
  156. * @return
  157. */
  158. @RequestMapping("/sfy-config")
  159. public String sfyConfig(HttpServletRequest httpServletRequest) throws Exception {
  160. List<String> urls = getRoleUrls(httpServletRequest);
  161. if (!urls.contains("/thmz/sfy-config")) {
  162. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  163. }
  164. return "sfy_config";
  165. }
  166. /**
  167. * 打开发药员基础设置页面
  168. *
  169. * @return
  170. */
  171. @RequestMapping("/fy-config")
  172. public String fyConfig(HttpServletRequest httpServletRequest) throws Exception {
  173. List<String> urls = getRoleUrls(httpServletRequest);
  174. if (!urls.contains("/thmz/fy-config")) {
  175. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  176. }
  177. return "fy_config";
  178. }
  179. /**
  180. * 打印机设置页面
  181. *
  182. * @return
  183. */
  184. @RequestMapping("/print-config")
  185. public String printConfig(HttpServletRequest httpServletRequest) throws Exception {
  186. List<String> urls = getRoleUrls(httpServletRequest);
  187. if (!urls.contains("/thmz/print-config")) {
  188. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  189. }
  190. return "mz/print_config";
  191. }
  192. /**
  193. * 打开发票管理页面
  194. *
  195. * @return
  196. */
  197. @RequestMapping("/receipt")
  198. public String receipt(HttpServletRequest httpServletRequest) throws Exception {
  199. List<String> urls = getRoleUrls(httpServletRequest);
  200. if (!urls.contains("/thmz/receipt")) {
  201. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  202. }
  203. return "receipt";
  204. }
  205. /**
  206. * 打开日结处理页面
  207. *
  208. * @return
  209. */
  210. @RequestMapping("/daily")
  211. public String daily(HttpServletRequest httpServletRequest) throws Exception {
  212. List<String> urls = getRoleUrls(httpServletRequest);
  213. if (!urls.contains("/thmz/daily")) {
  214. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  215. }
  216. return "mz/daily";
  217. }
  218. /**
  219. * 打开重打日结报表页面
  220. *
  221. * @return
  222. */
  223. @RequestMapping("/daily-repeat-print")
  224. public String dailyRepeatPrint(HttpServletRequest httpServletRequest) throws Exception {
  225. List<String> urls = getRoleUrls(httpServletRequest);
  226. if (!urls.contains("/thmz/daily-repeat-print")) {
  227. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  228. }
  229. return "mz/daily_repeat_print";
  230. }
  231. /**
  232. * 日结汇总页面
  233. *
  234. * @return
  235. */
  236. @RequestMapping("/daily-collect")
  237. public String dailyCollect(HttpServletRequest httpServletRequest) throws Exception {
  238. List<String> urls = getRoleUrls(httpServletRequest);
  239. if (!urls.contains("/thmz/daily-collect")) {
  240. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  241. }
  242. return "mz/daily_collect";
  243. }
  244. /**
  245. * 病人费用清单
  246. *
  247. * @return
  248. */
  249. @RequestMapping("/charge-list")
  250. public String chargeList(HttpServletRequest httpServletRequest) throws Exception {
  251. List<String> urls = getRoleUrls(httpServletRequest);
  252. if (!urls.contains("/thmz/charge-list")) {
  253. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  254. }
  255. return "mz/charge_list";
  256. }
  257. /**
  258. * 退药申请
  259. *
  260. * @return
  261. */
  262. @RequestMapping("/refund-medicine")
  263. public String refundMedicine(HttpServletRequest httpServletRequest) throws Exception {
  264. List<String> urls = getRoleUrls(httpServletRequest);
  265. if (!urls.contains("/thmz/refund-medicine")) {
  266. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  267. }
  268. return "mz/refund_medicine";
  269. }
  270. /**
  271. * 门诊收入明细
  272. *
  273. * @return
  274. */
  275. @RequestMapping("/mzsrmx")
  276. public String mzsrmx(HttpServletRequest httpServletRequest) throws Exception {
  277. List<String> urls = getRoleUrls(httpServletRequest);
  278. if (!urls.contains("/thmz/mzsrmx")) {
  279. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  280. }
  281. return "mz/mzsrmx";
  282. }
  283. /**
  284. * 门诊号别统计
  285. *
  286. * @return
  287. */
  288. @RequestMapping("/mzhbtj")
  289. public String mzhbtj(HttpServletRequest httpServletRequest) throws Exception {
  290. List<String> urls = getRoleUrls(httpServletRequest);
  291. if (!urls.contains("/thmz/mzhbtj")) {
  292. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  293. }
  294. return "mz/mzhbtj";
  295. }
  296. /**
  297. * 门诊应收核算报表
  298. *
  299. * @return
  300. */
  301. @RequestMapping("/bissinessReport")
  302. public String bissinessReport(HttpServletRequest httpServletRequest) throws Exception {
  303. List<String> urls = getRoleUrls(httpServletRequest);
  304. if (!urls.contains("/thmz/bissinessReport")) {
  305. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  306. }
  307. return "mz/bissinessReport";
  308. }
  309. /**
  310. * 号表字典维护
  311. *
  312. * @return
  313. */
  314. @RequestMapping("/request")
  315. public String request(HttpServletRequest httpServletRequest) throws Exception {
  316. List<String> urls = getRoleUrls(httpServletRequest);
  317. if (!urls.contains("/thmz/request")) {
  318. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  319. }
  320. return "mz/request";
  321. }
  322. /**
  323. * 收费员工作量统计
  324. *
  325. * @return
  326. */
  327. @RequestMapping("/cash-work-count")
  328. public String cashWorkCount(HttpServletRequest httpServletRequest) throws Exception {
  329. List<String> urls = getRoleUrls(httpServletRequest);
  330. if (!urls.contains("/thmz/cash-work-count")) {
  331. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  332. }
  333. return "mz/cash_work_count";
  334. }
  335. /**
  336. * 菜单管理页面
  337. *
  338. * @return
  339. */
  340. @RequestMapping("/menu-manage")
  341. public String menuManage(HttpServletRequest httpServletRequest) throws Exception {
  342. List<String> urls = getRoleUrls(httpServletRequest);
  343. if (!urls.contains("/thmz/menu-manage")) {
  344. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  345. }
  346. return "menu_manage";
  347. }
  348. /**
  349. * 菜单权限设置管理页面
  350. *
  351. * @return
  352. */
  353. @RequestMapping("/user-menu-relation")
  354. public String userMenuRelation(HttpServletRequest httpServletRequest) throws Exception {
  355. List<String> urls = getRoleUrls(httpServletRequest);
  356. if (!urls.contains("/thmz/user-menu-relation")) {
  357. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  358. }
  359. return "user_menu_relation";
  360. }
  361. /**
  362. * 号表预警设置页面
  363. *
  364. * @return
  365. */
  366. @RequestMapping("/request-config")
  367. public String requestConfig(HttpServletRequest httpServletRequest) throws Exception {
  368. List<String> urls = getRoleUrls(httpServletRequest);
  369. if (!urls.contains("/thmz/request-config")) {
  370. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  371. }
  372. return "mz/request-config";
  373. }
  374. /**
  375. * 医技预约科室设置页面
  376. *
  377. * @return
  378. */
  379. @RequestMapping("/schedule-of-medical")
  380. public String scheduleOfMedical(HttpServletRequest httpServletRequest) throws Exception {
  381. List<String> urls = getRoleUrls(httpServletRequest);
  382. if (!urls.contains("/thmz/schedule-of-medical")) {
  383. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  384. }
  385. return "mz/schedule-of-medical";
  386. }
  387. /**
  388. * 医技预约科室预约页面
  389. *
  390. * @return
  391. */
  392. @RequestMapping("/schedule-of-medical-apply")
  393. public String scheduleOfMedicalApply(HttpServletRequest httpServletRequest) throws Exception {
  394. List<String> urls = getRoleUrls(httpServletRequest);
  395. if (!urls.contains("/thmz/schedule-of-medical-apply")) {
  396. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  397. }
  398. return "mz/schedule-of-medical-apply";
  399. }
  400. /**
  401. * 文件上传页面
  402. *
  403. * @return
  404. */
  405. @RequestMapping("/profile-common")
  406. public String profileCommon(HttpServletRequest httpServletRequest) throws Exception {
  407. List<String> urls = getRoleUrls(httpServletRequest);
  408. if (!urls.contains("/thmz/profile-common")) {
  409. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  410. }
  411. return "profile_common";
  412. }
  413. /**
  414. * 入院登记
  415. *
  416. * @return
  417. */
  418. @RequestMapping("/hospitalized")
  419. public String hospitalized(HttpServletRequest httpServletRequest) throws Exception {
  420. List<String> urls = getRoleUrls(httpServletRequest);
  421. if (!urls.contains("/thmz/hospitalized")) {
  422. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  423. }
  424. return "zy/hospitalized";
  425. }
  426. /**
  427. * 节假日配置挂号
  428. *
  429. * @return
  430. */
  431. @RequestMapping("/request-holidays-config")
  432. public String requestHolidaysConfig(HttpServletRequest httpServletRequest) throws Exception {
  433. List<String> urls = getRoleUrls(httpServletRequest);
  434. if (!urls.contains("/thmz/request-holidays-config")) {
  435. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  436. }
  437. return "mz/request_holidays_config";
  438. }
  439. /**
  440. * 预交金处理
  441. *
  442. * @return
  443. */
  444. @RequestMapping("/accepting")
  445. public String accepting(HttpServletRequest httpServletRequest) throws Exception {
  446. List<String> urls = getRoleUrls(httpServletRequest);
  447. if (!urls.contains("/thmz/accepting")) {
  448. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  449. }
  450. return "zy/accepting";
  451. }
  452. /**
  453. * 病人列表
  454. *
  455. * @return
  456. */
  457. @RequestMapping("/actpatient")
  458. public String actpatient(HttpServletRequest httpServletRequest) throws Exception {
  459. List<String> urls = getRoleUrls(httpServletRequest);
  460. if (!urls.contains("/thmz/actpatient")) {
  461. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  462. }
  463. return "zy/actpatient";
  464. }
  465. /**
  466. * 号别类型
  467. *
  468. * @return
  469. */
  470. @RequestMapping("/request-type")
  471. public String requestType(HttpServletRequest httpServletRequest) throws Exception {
  472. List<String> urls = getRoleUrls(httpServletRequest);
  473. if (!urls.contains("/thmz/request-type")) {
  474. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  475. }
  476. return "mz/request_type";
  477. }
  478. /**
  479. * 收费项目字典维护
  480. *
  481. * @return
  482. */
  483. @RequestMapping("/charge-detail")
  484. public String chargeDetail(HttpServletRequest httpServletRequest) throws Exception {
  485. List<String> urls = getRoleUrls(httpServletRequest);
  486. if (!urls.contains("/thmz/charge-detail")) {
  487. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  488. }
  489. return "mz/charge_detail";
  490. }
  491. /**
  492. * 发药提醒
  493. *
  494. * @return
  495. */
  496. @RequestMapping("/to-medicine")
  497. public String toMedicine(HttpServletRequest httpServletRequest) throws Exception {
  498. List<String> urls = getRoleUrls(httpServletRequest);
  499. if (!urls.contains("/thmz/to-medicine")) {
  500. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  501. }
  502. return "mz/to-medicine";
  503. }
  504. /**
  505. * 发药提醒测试
  506. *
  507. * @return
  508. */
  509. @RequestMapping("/pharmacy-cell-number")
  510. public String toMedicineTest(HttpServletRequest httpServletRequest) throws Exception {
  511. List<String> urls = getRoleUrls(httpServletRequest);
  512. if (!urls.contains("/thmz/pharmacy-cell-number")) {
  513. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  514. }
  515. return "mz/pharmacy-cell-number";
  516. }
  517. /**
  518. * 手机自助缴费查询
  519. *
  520. * @return
  521. */
  522. @RequestMapping("/paid-from-zz")
  523. public String paidFromZz(HttpServletRequest httpServletRequest) throws Exception {
  524. List<String> urls = getRoleUrls(httpServletRequest);
  525. if (!urls.contains("/thmz/paid-from-zz")) {
  526. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  527. }
  528. return "charge/paid_from_zz";
  529. }
  530. /**
  531. * 数据修复工具
  532. *
  533. * @return
  534. */
  535. @RequestMapping("/data-util")
  536. public String dataUtil(HttpServletRequest httpServletRequest) throws Exception {
  537. List<String> urls = getRoleUrls(httpServletRequest);
  538. if (!urls.contains("/thmz/data-util")) {
  539. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  540. }
  541. return "mz/data_util";
  542. }
  543. /**
  544. * 惠民活动
  545. *
  546. * @return
  547. */
  548. @RequestMapping("/discount")
  549. public String discount(HttpServletRequest httpServletRequest) throws Exception {
  550. List<String> urls = getRoleUrls(httpServletRequest);
  551. if (!urls.contains("/thmz/discount")) {
  552. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  553. }
  554. return "charge/discount";
  555. }
  556. /**
  557. * 角色管理
  558. * @param httpServletRequest
  559. * @return
  560. * @throws Exception
  561. */
  562. @RequestMapping("/role-manage")
  563. public String roleManage(HttpServletRequest httpServletRequest) throws Exception {
  564. List<String> urls = getRoleUrls(httpServletRequest);
  565. if (!urls.contains("/thmz/role-manage")) {
  566. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  567. }
  568. return "role_manage";
  569. }
  570. /**
  571. * 用户管理
  572. * @param httpServletRequest
  573. * @return
  574. * @throws Exception
  575. */
  576. @RequestMapping("/user-manage")
  577. public String userManage(HttpServletRequest httpServletRequest) throws Exception {
  578. List<String> urls = getRoleUrls(httpServletRequest);
  579. if (!urls.contains("/thmz/user-manage")) {
  580. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  581. }
  582. return "user_manage";
  583. }
  584. /**
  585. * 药房库字典管理
  586. * @param httpServletRequest
  587. * @return
  588. * @throws Exception
  589. */
  590. @RequestMapping("/group-name")
  591. public String groupName(HttpServletRequest httpServletRequest) throws Exception {
  592. List<String> urls = getRoleUrls(httpServletRequest);
  593. if (!urls.contains("/thmz/group-name")) {
  594. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  595. }
  596. return "mz/group_name";
  597. }
  598. /**
  599. * 发药窗口字典管理
  600. * @param httpServletRequest
  601. * @return
  602. * @throws Exception
  603. */
  604. @RequestMapping("/drug-win")
  605. public String drugWin(HttpServletRequest httpServletRequest) throws Exception {
  606. List<String> urls = getRoleUrls(httpServletRequest);
  607. if (!urls.contains("/thmz/drug-win")) {
  608. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  609. }
  610. return "mz/drug_win";
  611. }
  612. /**
  613. * 住院日结
  614. * @param httpServletRequest
  615. * @return
  616. * @throws Exception
  617. */
  618. @RequestMapping("/zy-daily")
  619. public String zyDaily(HttpServletRequest httpServletRequest) throws Exception {
  620. List<String> urls = getRoleUrls(httpServletRequest);
  621. if (!urls.contains("/thmz/zy-daily")) {
  622. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  623. }
  624. return "zy/zy_daily";
  625. }
  626. /**
  627. * 门诊西药房配药
  628. *
  629. * @return
  630. */
  631. @RequestMapping("/west-pharmacy-dispensing")
  632. public String westPharmacyDispensing(HttpServletRequest httpServletRequest) throws Exception {
  633. List<String> urls = getRoleUrls(httpServletRequest);
  634. if (!urls.contains("/thmz/west-pharmacy-dispensing")) {
  635. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  636. }
  637. return "mz/west_pharmacy_dispensing";
  638. }
  639. /**
  640. * 门诊西药房发退药
  641. *
  642. * @return
  643. */
  644. @RequestMapping("/west-pharmacy-send")
  645. public String westPharmacySend(HttpServletRequest httpServletRequest) throws Exception {
  646. List<String> urls = getRoleUrls(httpServletRequest);
  647. if (!urls.contains("/thmz/west-pharmacy-send")) {
  648. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  649. }
  650. return "mz/west_pharmacy_send";
  651. }
  652. /**
  653. * 门诊医生就诊
  654. *
  655. * @return
  656. */
  657. @RequestMapping("/clinic")
  658. public String clinic(HttpServletRequest httpServletRequest) throws Exception {
  659. List<String> urls = getRoleUrls(httpServletRequest);
  660. if (!urls.contains("/thmz/clinic")) {
  661. throw new Exception("您没有此模块的权限,请联系管理员开通!");
  662. }
  663. return "mz/clinic";
  664. }
  665. }