scanning_djInfo.vue 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828
  1. <template>
  2. <view class="Scanning_djInfo">
  3. <view class="Scanning_top" v-if="res.status == 200">
  4. <view class="Scanning_top_icon">
  5. <view v-if="type == 'specimenPlan' || type == 'specimen'">
  6. <view class="fweight speNum" style="color: red;"> {{ speNum }} </view>
  7. </view>
  8. <text v-else class="cubeic-ok icon_transport transport-duigou"></text>
  9. </view>
  10. <view class="Scanning_top_text">
  11. <view class="text1">操作成功</view>
  12. </view>
  13. </view>
  14. <view class="Scanning_top" v-if="res.status == 11111">
  15. <view class="Scanning_top_icon">
  16. <text class="cubeic-close icon_transport transport-shibai"></text>
  17. </view>
  18. <view class="Scanning_top_text">
  19. <view class="text1" style="color: red;">操作失败</view>
  20. </view>
  21. </view>
  22. <view class="Scanning_top" v-if="
  23. res.status == 10005 ||
  24. res.status == 100018 ||
  25. res.status == 500 ||
  26. res.status == 10004 ||
  27. res.status == 100021 ||
  28. res.status == 100020 ||
  29. res.status == 100019 ||
  30. res.status == 100031
  31. ">
  32. <view class="Scanning_top_icon">
  33. <text class="cubeic-close icon_transport transport-shibai"></text>
  34. </view>
  35. <view class="Scanning_top_text">
  36. <view class="text1">操作失败</view>
  37. <view class="text1 f30" v-if="queryObj.qrcode !== undefined">扫描内容:{{queryObj.qrcode}}</view>
  38. </view>
  39. </view>
  40. <view class="Scanning_cont" v-if="(res.status != 200 || res.msg != '成功!') && res.status != 11111">
  41. <view>{{ res.msg }}</view>
  42. </view>
  43. <view class="Scanning_cont" v-if="
  44. (res.status == 200 && type == 'specimenPlan') ||
  45. (res.status == 200 && type == 'specimen')
  46. ">
  47. <view>{{ infoDATA.data.stype.name }}({{infoDATA.data.scode}})</view>
  48. <view>检验项目 : {{ infoDATA.data.specimenDesc || "-" }}</view>
  49. <view>
  50. {{ infoDATA.data.sickRoom ? infoDATA.data.sickRoom.dept : "" }}
  51. <text style="width: 4em;text-align: center;margin-left: 1em;margin-right: 1em;" class="icon_transport transport-arrow-right-full"></text>
  52. {{ infoDATA.data.checkDept ? infoDATA.data.checkDept.dept : "" }}
  53. </view>
  54. <view>患者姓名 : {{ infoDATA.data.patientName}}({{infoDATA.data.bedNum}})</view>
  55. <view>住院号 : {{ infoDATA.data.residenceNo || '-' }}</view>
  56. </view>
  57. <view class="Scanning_cont" v-if="
  58. (res.status == 11111 && type == 'specimenPlan') ||
  59. (res.status == 11111 && type == 'specimen')
  60. ">
  61. <view>{{ infoDATA.data.stype.name }}({{infoDATA.data.scode}})</view>
  62. <view>检验项目 : {{ infoDATA.data.specimenDesc || "-" }}</view>
  63. <view>标本状态 : <text style="color: red">{{ infoDATA.data.speState ? infoDATA.data.speState.name : '' }}</text></view>
  64. <view>
  65. {{ infoDATA.data.sickRoom ? infoDATA.data.sickRoom.dept : "" }}
  66. <text style="width: 4em;text-align: center;margin-left: 1em;margin-right: 1em;" class="icon_transport transport-arrow-right-full"></text>
  67. {{ infoDATA.data.checkDept ? infoDATA.data.checkDept.dept : "" }}
  68. </view>
  69. <view>患者姓名 : {{ infoDATA.data.patientName}}({{infoDATA.data.bedNum}})</view>
  70. <view>住院号 : {{ infoDATA.data.residenceNo || '-' }}</view>
  71. </view>
  72. <view class="Scanning_cont" v-if="
  73. (res.status == 200 && type == 'inspect') || type == 'patientTransport'
  74. ">
  75. <view v-if="infoDATA.patient">患者姓名 : {{ infoDATA.patient || "-" }}</view>
  76. <view v-if="infoDATA.patient">住院号 : {{ infoDATA.residenceNo || "-" }}</view>
  77. <view v-if="infoDATA.patient">住院科室 : {{ infoDATA.deptName || "-" }}</view>
  78. <view v-if="infoDATA.patient">床号 : {{ infoDATA.bedNum || "-" }}</view>
  79. <view v-if="infoDATA.data">
  80. 检查项目 :
  81. <text v-for="(data, i) in infoDATA.data" :key="i">{{ data.inspectName }},</text>
  82. </view>
  83. <view v-if="
  84. infoType == 'ins-dsd-1' ||
  85. infoType == 'trans-dsd-1' ||
  86. infoDATA.type == 'trans-dsd-1'
  87. ">工单已完成</view>
  88. <view v-if="infoDATA.type == 'ins-half-ok'">已到达检查科室,工单已完成。</view>
  89. </view>
  90. <view class="Scanning_cont" v-if="
  91. (res.status == 200 && type == 'drugsBag') ||
  92. (res.status == 200 && type == 'jPBag')
  93. ">
  94. <view> 药包类型 : {{(infoDATA.data.packType && infoDATA.data.packType !== 0) ? DRUGSBAG_TYPE[infoDATA.data.packType] : "-"}} </view>
  95. <view v-if="type == 'drugsBag'">药包编码 : #{{ infoDATA.data.packid }}</view>
  96. <view v-if="type == 'jPBag'">静配编码 : #{{ infoDATA.data.packid }}</view>
  97. <view>所属科室 : {{ infoDATA.data.target.dept }}</view>
  98. <view v-if="
  99. accountObj && (infoType === 'drug-ddd-2' || infoType === 'drug-dsd-2')
  100. ">
  101. 交接人工号 : {{ accountObj.account }}
  102. </view>
  103. <view v-if="
  104. accountObj && (infoType === 'drug-ddd-2' || infoType === 'drug-dsd-2')
  105. ">
  106. 交接人姓名 : {{ accountObj.accountName }}
  107. </view>
  108. <text v-if="infoType == 'drug-dsd-2' || infoType == 'jp-dsd-2'">工单已完成。</text>
  109. <view class="red"> 如果您当前科室还有药包需要扫描,请点击“继续扫描”! </view>
  110. </view>
  111. <view class="foot_btn_spe" v-if="
  112. res.status == 100018 || type == 'specimen' || type == 'specimenPlan'
  113. ">
  114. <view class="btn1" @click="Scanning_again()">继续扫描</view>
  115. <view class="btn3" @click="hand_again()" v-if="type == 'specimen' || type == 'specimenPlan'">手动录入</view>
  116. <view class="btn3" @click="getNoScanSpecimen(false)" v-if="type == 'specimen' || type == 'specimenPlan'">未扫描标本</view>
  117. <view class="btn3" @click="getNoScanSpecimen(true)" v-if="type == 'specimen' || type == 'specimenPlan'">已扫描标本</view>
  118. <view class="btn2" @click="Scanning_complete(ids)">完成扫描</view>
  119. </view>
  120. <view class="foot_btn" v-if="
  121. type != 'specimen' &&
  122. res.status != 200 &&
  123. type != 'specimenPlan' &&
  124. type !== 'drugsBag' &&
  125. type !== 'jPBag' &&
  126. type !== 'patientTransport'
  127. ">
  128. <view class="btn3" @click="showAlert()">知道了</view>
  129. </view>
  130. <view class="foot_btn" v-if="
  131. (res.status != 200 && type == 'drugsBag') ||
  132. (res.status != 200 && type == 'jPBag') ||
  133. (res.status != 200 && type == 'patientTransport')
  134. ">
  135. <view class="btn3" @click="Scanning_again()">继续扫描</view>
  136. <view class="btn3" @click="showAlert()" v-if="type == 'drugsBag'">知道了</view>
  137. </view>
  138. <view class="foot_btn" v-if="
  139. res.status == 200 &&
  140. type != 'specimen' &&
  141. type != 'specimenPlan'
  142. ">
  143. <view class="btn3" @click="Scanning_again()" v-if="
  144. (res.status == 200 && type == 'drugsBag') ||
  145. (res.status == 200 && type == 'jPBag')
  146. ">继续扫描</view>
  147. <view class="btn3" @click="showAlert()">知道了</view>
  148. </view>
  149. <!-- 弹窗 -->
  150. <showModel :title="models.title" :icon="models.icon" :disjunctor="models.disjunctor" :content="models.content"
  151. @ok="ok" @cancel="cancel" :operate="models.operate"></showModel>
  152. <!-- 弹窗 -->
  153. <showModel :title="models2.title" :icon="models2.icon" :disjunctor="models2.disjunctor" :content="models2.content"
  154. @ok="ok2" @know="know2" @cancel="cancel2" :operate="models2.operate">
  155. </showModel>
  156. <!-- 手动查询标本弹窗 -->
  157. <handViewSpecimen v-if="speModels.disjunctor" :title="speModels.title" :disjunctor="speModels.disjunctor"
  158. @ok="speOk" @cancel="speCancel">
  159. </handViewSpecimen>
  160. </view>
  161. </template>
  162. <script>
  163. import showModel from "../../components/showModel/showModel.vue";
  164. import {
  165. get,
  166. post,
  167. SM,
  168. webHandle
  169. } from "../../http/http.js";
  170. import {
  171. DRUGSBAG_TYPE
  172. } from '../../tools/enum.drugsbagType.js';
  173. export default {
  174. data() {
  175. return {
  176. DRUGSBAG_TYPE,
  177. currentCode: '', //当前小扫描的科室二维码
  178. // 手动查询标本弹窗model
  179. speModels: {
  180. disjunctor: false,
  181. },
  182. // 交接人信息
  183. accountObj: undefined,
  184. //传给后端查询是否继续扫描
  185. deptId: undefined,
  186. SMFlag: true,
  187. // 弹窗model
  188. models: {
  189. disjunctor: false,
  190. },
  191. // 完成扫描弹窗model1
  192. models2: {
  193. disjunctor: false,
  194. },
  195. wcId: "", //工单完成ID
  196. wcFlag: false,
  197. infoDATA: [],
  198. res: {
  199. status: "",
  200. msg: "",
  201. },
  202. infoType: "",
  203. DEPTCode: "",
  204. RESData: {},
  205. DEPT: "",
  206. dataId: "",
  207. type: "",
  208. model: {},
  209. idsType: 1,
  210. packid: "",
  211. speNum: 0,
  212. queryObj: {}, //路由传递过来的参数
  213. gotoFlag: true,
  214. content: "",
  215. };
  216. },
  217. methods: {
  218. // 手动查询标本-确认
  219. speOk(data) {
  220. console.log(data);
  221. if (!data.id) {
  222. //没有查询到标本
  223. uni.showModal({
  224. title: '提示',
  225. content: "没有查询到标本!",
  226. showCancel: false,
  227. success: function(res) {
  228. if (res.confirm) {
  229. console.log('用户点击确定');
  230. } else if (res.cancel) {
  231. console.log('用户点击取消');
  232. }
  233. }
  234. });
  235. return;
  236. }
  237. this.speModels.disjunctor = false;
  238. this.hand_scanning_common(data.scode, 'hand');
  239. },
  240. // 手动查询标本-取消
  241. speCancel() {
  242. this.speModels.disjunctor = false;
  243. },
  244. // 手动查询标本弹窗
  245. showHandViewSpecimen() {
  246. this.speModels = {
  247. title: '填写标本编码',
  248. disjunctor: true,
  249. }
  250. },
  251. // 手动录入标本
  252. hand_again() {
  253. this.showHandViewSpecimen();
  254. },
  255. // 手动输入标本和扫码公共方法
  256. hand_scanning_common(ress1, type) {
  257. let list = [];
  258. let postType = "";
  259. let ids = [];
  260. if (this.ids && this.ids[0]) {
  261. ids = this.ids;
  262. } else if (this.dataId) {
  263. ids = [];
  264. ids.push(this.dataId);
  265. }
  266. let data = {
  267. ids: ids,
  268. deptCode: this.DEPTCode,
  269. code: "", // 2
  270. };
  271. // ----------------
  272. uni.showLoading({
  273. title: "加载中",
  274. mask: true,
  275. });
  276. //检验二维码的有效性
  277. post("/dept/scanning", {
  278. content: ress1,
  279. }).then((result) => {
  280. this.SMFlag = true;
  281. this.currentCode = result.code;
  282. if (result.state == 200 || result.state == 201) {
  283. let ress = result.code;
  284. if (ress) {
  285. data.code = ress;
  286. if (this.type == "inspect") {
  287. postType = "handleIns";
  288. list = data;
  289. }
  290. if (this.type == "jPBag" || this.type == "drugsBag") {
  291. postType = "handleDrugsAndJp";
  292. data["type"] = this.infoType;
  293. list = data;
  294. if (this.accountObj) {
  295. list.handover = this.accountObj.accountId;
  296. }
  297. list.deptId = this.deptId;
  298. delete list.ids;
  299. }
  300. if (this.type == "specimen") {
  301. postType = "handleSpes";
  302. data["speCode"] = data.code;
  303. delete data.code;
  304. data["type"] = this.infoType;
  305. list = data;
  306. if (this.accountObj) {
  307. list.handover = this.accountObj.accountId;
  308. }
  309. }
  310. if (this.type == "specimenPlan") {
  311. postType = "handlePlanSpes";
  312. data["speCode"] = data.code;
  313. delete data.code;
  314. data["type"] = this.infoType;
  315. list = data;
  316. if (this.accountObj) {
  317. list.handover = this.accountObj.accountId;
  318. }
  319. }
  320. if (this.type == "patientTransport") {
  321. postType = "handleTrans";
  322. list = data;
  323. }
  324. post("/workerOrder/" + postType, list).then((res) => {
  325. uni.hideLoading();
  326. if (res.status == 200 || res.status == 11111) {
  327. //标本和标本轮巡工单,扫描标本后会自动调用摄像头,继续扫描,直到status不是200
  328. if ((this.type == "specimenPlan" || this.type == "specimen") && res.status != 11111) {
  329. if (type === 'scan') {
  330. setTimeout(()=>{
  331. this.Scanning_again();
  332. },500)
  333. } else if (type === 'hand') {
  334. this.hand_again();
  335. }
  336. }
  337. if (
  338. this.type == "inspect" ||
  339. this.type == "patientTransport"
  340. ) {
  341. if (res.ids) {
  342. for (var i = 0; i < this.ids.length; i++) {
  343. if (this.ids[i] == res.ids[0]) {
  344. this.ids.splice(i, 1);
  345. }
  346. }
  347. if (this.ids.length > 1) {
  348. this.idsType = 1;
  349. } else {
  350. this.idsType = 2;
  351. }
  352. }
  353. this.infoDATA = res;
  354. this.type = this.type;
  355. this.DEPTCode = this.DEPTCode;
  356. } else if (this.type == "drugsBag") {
  357. // this.infoDATA.data.packid = res.data.packid;
  358. this.infoDATA = res;
  359. this.res["status"] = res.status;
  360. this.res["msg"] = res.msg;
  361. } else if (
  362. this.type == "specimenPlan" ||
  363. this.type == "specimen"
  364. ) {
  365. this.infoDATA = res;
  366. this.speNum = res.specimenCount;
  367. // --------------------------
  368. this.res["status"] = res.status;
  369. this.res["msg"] = res.msg;
  370. // --------------------------
  371. } else if (this.type == "jPBag") {
  372. // this.infoDATA.data.packid = res.data.packid;
  373. this.infoDATA = res;
  374. this.res["status"] = res.status;
  375. this.res["msg"] = res.msg;
  376. } else {
  377. uni.navigateTo({
  378. url: `../scanning_djEnd/scanning_djEnd?type=${
  379. this.queryObj.type
  380. }&type1=${this.queryObj.type1}&code=${
  381. this.queryObj.deptCode
  382. }&dept=${this.queryObj.dept}&ids=${encodeURIComponent(
  383. JSON.stringify(this.ids)
  384. )}&model=${encodeURIComponent(
  385. JSON.stringify(res)
  386. )}&accountObj=${encodeURIComponent(
  387. JSON.stringify(this.accountObj)
  388. )}&deptId=${this.deptId}`,
  389. });
  390. }
  391. } else {
  392. uni.navigateTo({
  393. url: `../scanning_djEnd/scanning_djEnd?type=${
  394. this.queryObj.type
  395. }&type1=${this.queryObj.type1}&code=${
  396. this.queryObj.deptCode
  397. }&dept=${this.queryObj.dept}&ids=${encodeURIComponent(
  398. JSON.stringify(this.ids)
  399. )}&model=${encodeURIComponent(
  400. JSON.stringify(res)
  401. )}&speNum=${this.speNum}&accountObj=${encodeURIComponent(
  402. JSON.stringify(this.accountObj)
  403. )}&deptId=${this.deptId}&scanOrHand=${type}&qrcode=${this.currentCode}`,
  404. });
  405. }
  406. });
  407. }
  408. } else {
  409. uni.hideLoading();
  410. uni.showToast({
  411. icon: "none",
  412. title: result.info || "接口获取数据失败!",
  413. });
  414. }
  415. });
  416. // ------------------------------
  417. },
  418. // 查看未扫描标本
  419. // isScan true已扫描标本,false未扫描标本
  420. getNoScanSpecimen(isScan) {
  421. if (!this.gotoFlag) {
  422. return;
  423. }
  424. this.gotoFlag = false;
  425. if(isScan){
  426. uni.navigateTo({
  427. url: `../noScanSpecimen/noScanSpecimen?deptName=${this.queryObj.dept}&workOrderId=${encodeURIComponent(JSON.stringify(this.queryObj.ids))}&deptCode=${this.queryObj.deptCode}&isScan=1`,
  428. });
  429. }else{
  430. uni.navigateTo({
  431. url: `../noScanSpecimen/noScanSpecimen?deptName=${this.queryObj.dept}&workOrderId=${encodeURIComponent(JSON.stringify(this.queryObj.ids))}&deptCode=${this.queryObj.deptCode}`,
  432. });
  433. }
  434. },
  435. overFinish() {
  436. let postType = "";
  437. if (
  438. this.queryObj.type1 === "plan-spe-ddd-2" ||
  439. this.queryObj.type1 === "plan-spe-dsd-2" ||
  440. this.queryObj.type1 === "plan-spe-dsd-3"
  441. ) {
  442. postType = "finishPlanSpes";
  443. } else if (this.queryObj.type1 == "spe-ddd-2") {
  444. postType = "finishSpes";
  445. }
  446. let data = {
  447. type: this.queryObj.type1,
  448. ids: this.wcId,
  449. };
  450. post("/workerOrder/" + postType, data).then((res) => {
  451. if (res.status == 200) {
  452. this.models2 = {
  453. disjunctor: true,
  454. title: "提示",
  455. content: `完成扫描成功`,
  456. icon: "success",
  457. operate: {
  458. know: "知道了",
  459. },
  460. };
  461. } else {
  462. uni.showToast({
  463. icon: "none",
  464. title: res.msg || "接口获取数据失败!",
  465. });
  466. }
  467. });
  468. },
  469. // 确定
  470. ok() {
  471. this.models.disjunctor = false;
  472. let postData = {
  473. ids: this.queryObj.ids,
  474. sign: true,
  475. deptQrCode: this.queryObj.deptCode,
  476. };
  477. uni.showLoading({
  478. title: "加载中",
  479. mask: true,
  480. });
  481. post("/workerOrder/expectedAndActual", postData).then((ress) => {
  482. uni.hideLoading();
  483. if (ress.status == 200) {
  484. if (this.wcFlag) {
  485. //正常完成扫描
  486. this.overFinish();
  487. } else {
  488. this.gotoOver();
  489. }
  490. } else if (ress.status == 1000035) {
  491. let content = "";
  492. if (
  493. this.queryObj.type1 === "spe-ddd-2" ||
  494. this.queryObj.type1 === "plan-spe-ddd-2"
  495. ) {
  496. //待到达
  497. content =
  498. `系统内预计标本<strong class="red">${ress.expectReceiveNum}</strong>只,您扫描收取标本<strong class="red">${ress.actualReceiveNum}</strong>只,其中<strong class="red">${ress.notReceiveNum}</strong>只未扫描;`;
  499. } else {
  500. //待送达
  501. this.content = `本工单已签到<strong class="red">${
  502. ress.scanSet ? ress.scanSet.join("、") : ""
  503. }</strong>,剩余需签到科室<strong class="red">${
  504. ress.notScanSet ? ress.notScanSet.join("、") : ""
  505. }</strong>,总签收<strong class="red">${
  506. ress.totalAcceptance
  507. }</strong>只,剩余<strong class="red">${
  508. ress.notAcceptance
  509. }</strong>只未签收,您确定完成工单吗?`;
  510. content =
  511. `您在<strong class="red">${ress.deptName}</strong>检验科扫描了<strong class="red">${ress.deptScanNum}</strong>个标本,还需扫描<strong class="red">${ress.deptNotScanNum}</strong>标本。`;
  512. }
  513. // 取消弹窗 2022年10月10日
  514. this.ok2();
  515. // this.models2 = {
  516. // disjunctor: true,
  517. // title: "提示",
  518. // content,
  519. // icon: "warn",
  520. // operate: {
  521. // ok: "确定",
  522. // cancel: "取消",
  523. // },
  524. // };
  525. } else {
  526. uni.showToast({
  527. icon: "none",
  528. title: ress.msg || "接口获取数据失败!",
  529. });
  530. }
  531. });
  532. },
  533. // 取消
  534. cancel() {
  535. this.models.disjunctor = false;
  536. },
  537. // 确定
  538. ok2() {
  539. this.models2.disjunctor = false;
  540. let postData = {
  541. ids: this.queryObj.ids,
  542. deptQrCode: this.queryObj.deptCode,
  543. };
  544. uni.showLoading({
  545. title: "加载中",
  546. mask: true,
  547. });
  548. post("/workerOrder/expectedAndActual", postData).then((ress) => {
  549. uni.hideLoading();
  550. if (ress.status == 200) {
  551. if (this.wcFlag) {
  552. this.overFinish();
  553. } else {
  554. this.gotoOver();
  555. }
  556. } else {
  557. uni.showToast({
  558. icon: "none",
  559. title: ress.msg || "接口获取数据失败!",
  560. });
  561. }
  562. });
  563. },
  564. // 取消
  565. cancel2() {
  566. this.models2.disjunctor = false;
  567. },
  568. know2() {
  569. this.models2.disjunctor = false;
  570. uni.navigateTo({
  571. url: "../receiptpage/receiptpage",
  572. });
  573. },
  574. //完成扫描
  575. Scanning_complete(id) {
  576. // 如果是标本配送和标本轮巡,则进入标本核对页面
  577. if((this.type === 'specimen' || this.type === 'specimenPlan') && this.queryObj.type1.includes('ddd')){
  578. uni.navigateTo({
  579. url: `../checkAfterScanning/checkAfterScanning?id=${id}&type=${this.queryObj.type}&type1=${this.queryObj.type1}&dept=${this.queryObj.dept}&deptId=${this.queryObj.deptId}&deptCode=${this.queryObj.deptCode}&speNum=${this.speNum}&content=${this.content}`,
  580. });
  581. return;
  582. }
  583. this.wcId = id;
  584. if (
  585. this.queryObj.type1 == "plan-spe-ddd-2" ||
  586. this.queryObj.type1 == "spe-ddd-2"
  587. ) {
  588. this.wcFlag = true;
  589. this.models = {
  590. disjunctor: true,
  591. title: "提示",
  592. content: "是否确定标本已扫描完成?",
  593. icon: "warn",
  594. operate: {
  595. ok: "确定",
  596. cancel: "取消",
  597. },
  598. };
  599. } else if (
  600. this.queryObj.type1 == "plan-spe-dsd-2" ||
  601. this.queryObj.type1 == "plan-spe-dsd-3" ||
  602. this.queryObj.type1 == "spe-dsd-2" ||
  603. this.queryObj.type1 == "spe-dsd-3"
  604. ) {
  605. this.wcFlag = false;
  606. this.models = {
  607. disjunctor: true,
  608. title: "提示",
  609. content: "是否确定标本已扫描完成?",
  610. icon: "warn",
  611. operate: {
  612. ok: "确定",
  613. cancel: "取消",
  614. },
  615. };
  616. } else {
  617. this.gotoOver();
  618. }
  619. },
  620. // 跳转完成工单页面
  621. gotoOver() {
  622. if(this.queryObj.type === 'specimenPlan'){
  623. uni.navigateTo({
  624. url: `../specimenCheckingEnd/specimenCheckingEnd?type=${this.queryObj.type}&type1=${
  625. this.queryObj.type1
  626. }&id=${encodeURIComponent(JSON.stringify(this.wcId))}&deptCode=${
  627. this.queryObj.deptCode
  628. }&dept=${this.queryObj.dept}&content=${this.content}`,
  629. });
  630. }else{
  631. uni.navigateTo({
  632. url: `../scanning/scanning?type=${this.queryObj.type}&type1=${
  633. this.queryObj.type1
  634. }&id=${encodeURIComponent(JSON.stringify(this.wcId))}&deptCode=${
  635. this.queryObj.deptCode
  636. }&dept=${this.queryObj.dept}&content=${this.content}`,
  637. });
  638. }
  639. },
  640. // 继续扫描
  641. Scanning_again() {
  642. if (!this.SMFlag) {
  643. return;
  644. }
  645. this.SMFlag = false;
  646. SM()
  647. .then((ress1) => {
  648. this.hand_scanning_common(ress1, 'scan');
  649. })
  650. .catch((err) => {
  651. this.SMFlag = true;
  652. });
  653. },
  654. // 知道了
  655. showAlert() {
  656. uni.navigateTo({
  657. url: "../receiptpage/receiptpage",
  658. });
  659. },
  660. },
  661. onShow() {
  662. this.SMFlag = true;
  663. this.gotoFlag = true;
  664. },
  665. onLoad(options) {
  666. if (options.status == 200&&options.scanOrHand === 'hand'&&(options.type === "specimen"||options.type === "specimenPlan")) {
  667. this.hand_again();
  668. }
  669. console.log(options, "options");
  670. if (options.speNum) {
  671. this.speNum = options.speNum;
  672. }
  673. if (options.accountObj && options.accountObj != "undefined") {
  674. this.accountObj = JSON.parse(options.accountObj);
  675. }
  676. if (options.deptId && options.deptId != "undefined") {
  677. this.deptId = options.deptId;
  678. }
  679. this.queryObj = options;
  680. if (this.queryObj.model) {
  681. let list = JSON.parse(this.queryObj.model);
  682. this.infoDATA = list;
  683. } else {
  684. this.infoDATA = this.queryObj.infoData;
  685. }
  686. this.RESData = this.queryObj.resData;
  687. this.res["status"] = this.queryObj.status;
  688. this.res["msg"] = this.queryObj.msg;
  689. this.res["patient"] = this.queryObj.patient;
  690. this.infoType = this.queryObj.type1;
  691. if (this.queryObj.dept) {
  692. this.DEPT = this.queryObj.dept;
  693. }
  694. this.queryObj.ids = JSON.parse(this.queryObj.ids);
  695. if (this.queryObj.ids) {
  696. this.ids = this.queryObj.ids;
  697. if (this.ids.length > 1) {
  698. this.idsType = 1;
  699. } else {
  700. this.idsType = 2;
  701. }
  702. }
  703. this.DEPTCode = this.queryObj.deptCode;
  704. this.type = this.queryObj.type;
  705. // #ifdef APP-PLUS
  706. webHandle("no", "app");
  707. // #endif
  708. // #ifdef H5
  709. webHandle("no", "wx");
  710. // #endif
  711. },
  712. };
  713. </script>
  714. <style lang="less">
  715. .Scanning_djInfo {
  716. padding: 0 20rpx;
  717. .Scanning_top {
  718. min-height: 270rpx;
  719. .red {
  720. background-color: #ff3b53 !important;
  721. }
  722. .Scanning_top_icon {
  723. width: 140rpx;
  724. height: 140rpx;
  725. margin: 0 auto;
  726. margin-top: 116rpx;
  727. border-radius: 50%;
  728. line-height: 140rpx;
  729. .speNum{
  730. text-align: center;
  731. font-size: 140rpx;
  732. }
  733. .cubeic-ok {
  734. font-size: 140rpx;
  735. color: #35b34a;
  736. }
  737. .cubeic-close {
  738. font-size: 140rpx;
  739. color: #ff3b53;
  740. }
  741. }
  742. .Scanning_top_text {
  743. .text1 {
  744. margin-top: 40rpx;
  745. font-size: 48rpx;
  746. text-align: center;
  747. }
  748. }
  749. }
  750. .Scanning_cont {
  751. font-size: 32rpx;
  752. text-align: center;
  753. view {
  754. margin-bottom: 16rpx;
  755. }
  756. .text {
  757. margin-top: 24rpx;
  758. color: #35b34a;
  759. }
  760. .text1 {
  761. margin-top: 24rpx;
  762. color: #ff3b53;
  763. }
  764. }
  765. .foot_btn {
  766. line-height: 88rpx;
  767. height: 100rpx;
  768. margin-top: 40rpx;
  769. text-align: center;
  770. display: flex;
  771. .btn1,
  772. .btn2,
  773. .btn3 {
  774. height: 88rpx;
  775. margin: 0 1%;
  776. flex: 1;
  777. background-image: linear-gradient(to right, #72c172, #3bb197);
  778. color: #fff;
  779. border-radius: 8rpx;
  780. font-size: 32rpx;
  781. margin-top: 16rpx;
  782. }
  783. }
  784. .foot_btn_spe {
  785. line-height: 88rpx;
  786. height: 100rpx;
  787. margin-top: 40rpx;
  788. text-align: center;
  789. display: flex;
  790. justify-content: space-between;
  791. flex-wrap: wrap;
  792. &::after {
  793. content: '';
  794. flex: 1;
  795. }
  796. view {
  797. height: 88rpx;
  798. width: 48%;
  799. margin: 0 1%;
  800. background-image: linear-gradient(to right, #72c172, #3bb197);
  801. color: #fff;
  802. border-radius: 8rpx;
  803. font-size: 32rpx;
  804. margin-top: 16rpx;
  805. }
  806. }
  807. }
  808. </style>