XzDao.php 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285
  1. <?php
  2. namespace app\api\dao\xz;
  3. use app\api\actions\ZskkCache;
  4. use app\api\dao\ZskkDefaultDao;
  5. use app\api\model\exam\ExamModel;
  6. use app\api\model\monitor\MonitorexamModel;
  7. use app\api\model\xz\XzModel;
  8. /**
  9. * 后台控制器基类
  10. * 接口方法权限 必传参数 接口返回 错误抛出 通用参数处理
  11. */
  12. class XzDao extends ZskkDefaultDao {
  13. protected $flag = true;
  14. protected $logName = "XzDao";
  15. protected $xz = null;
  16. protected $exam = null;
  17. protected $monitorexamModel = null;
  18. public function __construct(XzModel $xzModel,MonitorexamModel $monitorexamModel,ExamModel $examModel)
  19. {
  20. parent::__construct();
  21. $this->xz = $xzModel;
  22. $this->exam = $examModel;
  23. $this->monitorexamModel = $monitorexamModel;
  24. }
  25. public function insertXz($data)
  26. {
  27. $info = $this->xz->insertXz($data);
  28. return $info;
  29. }
  30. public function checkXz($where)
  31. {
  32. $info = $this->xz->checkXz($where);
  33. return $info;
  34. }
  35. public function insertStudies($data)
  36. {
  37. $info = $this->xz->insertStudies($data);
  38. return $info;
  39. }
  40. public function insertPatient($data)
  41. {
  42. $info = $this->xz->insertPatient($data);
  43. return $info;
  44. }
  45. public function insertExam($data)
  46. {
  47. $info = $this->xz->insertExam($data);
  48. return $info;
  49. }
  50. public function updateStudies($id,$examId)
  51. {
  52. $info = $this->xz->updateStudies($id,$examId);
  53. return $info;
  54. }
  55. public function saveMoneyWater($data)
  56. {
  57. $info = $this->xz->saveMoneyWater($data);
  58. return $info;
  59. }
  60. public function updateXz($where,$updateXz)
  61. {
  62. $info = $this->xz->updateXz($where,$updateXz);
  63. return $info;
  64. }
  65. public function updateStatus($where,$status)
  66. {
  67. $info = $this->xz->updateStatus($where,$status);
  68. return $info;
  69. }
  70. public function getXzData($id)
  71. {
  72. $info = $this->xz->getXzData($id);
  73. return $info;
  74. }
  75. public function getExamData($id)
  76. {
  77. $info = $this->xz->getExamData($id);
  78. return $info;
  79. }
  80. public function getExamDataById($id)
  81. {
  82. $info = $this->xz->getExamDataById($id);
  83. return $info;
  84. }
  85. public function getImageInfo($study)
  86. {
  87. $info = $this->xz->getImageInfo($study);
  88. return $info;
  89. }
  90. public function getReport($id)
  91. {
  92. $info = $this->xz->getReport($id);
  93. return $info;
  94. }
  95. public function getDoctorName($id)
  96. {
  97. $info = $this->xz->getDoctorName($id);
  98. return $info;
  99. }
  100. public function getUid($id)
  101. {
  102. $uid = $this->xz->getUid($id);
  103. return $uid;
  104. }
  105. public function getAccession($id)
  106. {
  107. $info = $this->xz->getAccession($id);
  108. return $info;
  109. }
  110. public function checkIsSet($studyId,$studyUid='',$institution='')
  111. {
  112. $id = $this->xz->check($studyId,$studyUid,$institution);
  113. return $id;
  114. }
  115. public function checkExam($where)
  116. {
  117. return $this->exam->where($where)->order('createdAt desc')->find();
  118. }
  119. public function getWaterLog($examId,$insId)
  120. {
  121. $id = $this->xz->getWaterLog($examId,$insId);
  122. return $id;
  123. }
  124. public function getPushInfo($id)
  125. {
  126. $data = $this->xz->getPushInfo($id);
  127. return $data;
  128. }
  129. public function getOpenId($ids)
  130. {
  131. $data = $this->xz->getOpenId($ids);
  132. return $data;
  133. }
  134. public function getInsFilmInfo($id)
  135. {
  136. $info = $this->xz->getInsFilmInfo($id);
  137. return $info;
  138. }
  139. public function getBodyText($body)
  140. {
  141. $info = $this->xz->getBodyText($body);
  142. return $info;
  143. }
  144. public function getExam($key,$value,$institutionId)
  145. {
  146. $id = $this->xz->getExam($key,$value,$institutionId);
  147. return $id;
  148. }
  149. public function updateExam($id,$update)
  150. {
  151. $info = $this->xz->updateExam($update,$id);
  152. return $info;
  153. }
  154. public function getStudyUid($id)
  155. {
  156. $id = $this->xz->getStudyUid($id);
  157. return $id;
  158. }
  159. public function getApiAction($id,$action)
  160. {
  161. $info = $this->xz->getApiAction($id,$action);
  162. return $info;
  163. }
  164. public function checkDoctor($name)
  165. {
  166. $info = $this->xz->checkDoctor($name);
  167. return $info;
  168. }
  169. public function getApi($id)
  170. {
  171. $info = $this->xz->getApi($id);
  172. return $info;
  173. }
  174. public function getInterface($ids)
  175. {
  176. $info = $this->xz->getInterface($ids);
  177. return $info;
  178. }
  179. public function getApis($institution,$action)
  180. {
  181. $info = $this->xz->getApis($institution,$action);
  182. return $info;
  183. }
  184. public function getInstitutionName($id)
  185. {
  186. $name = $this->xz->getInstitutionName($id);
  187. return $name;
  188. }
  189. public function getInsValue($id,$value)
  190. {
  191. $info = $this->xz->getInsValue($id,$value);
  192. return $info;
  193. }
  194. public function saveImageNode($info)
  195. {
  196. $info = $this->xz->saveImageNode($info);
  197. return $info;
  198. }
  199. public function getImageNode($where)
  200. {
  201. $info = $this->xz->getImageNode($where);
  202. return $info;
  203. }
  204. public function getWjwData()
  205. {
  206. $data = $this->xz->getWjwData();
  207. return $data;
  208. }
  209. public function getRemoteCount()
  210. {
  211. $data = $this->xz->getRemoteCount();
  212. return $data;
  213. }
  214. public function getYjRemote($page,$num)
  215. {
  216. $data = $this->xz->getYjRemote($page,$num);
  217. return $data;
  218. }
  219. public function getYjDoctor()
  220. {
  221. $data = $this->xz->getYjDoctor();
  222. return $data;
  223. }
  224. public function saveSms($data)
  225. {
  226. $data = $this->xz->saveSms($data);
  227. return $data;
  228. }
  229. public function insertSpecialLog($time, $diff)
  230. {
  231. $data = $this->xz->insertSpecialLog($time, $diff);
  232. return $data;
  233. }
  234. public function saveMonitorExam($arr)
  235. {
  236. $this->monitorexamModel->insert($arr);
  237. }
  238. }