imageWhiteStore.vue 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202
  1. <template>
  2. <div class="imageAIVerifyErr imageWhiteStore">
  3. <el-dialog
  4. title="图像识别结果"
  5. :visible.sync="vanPopup"
  6. width="80%"
  7. :append-to-body="true"
  8. :close-on-click-modal="false"
  9. @close="close"
  10. custom-class="AIVerifyErrdialog">
  11. <div class="AIVerifyErrMask">
  12. <div class="errorImg">
  13. <img
  14. v-if="imageWhiteStoreData.url"
  15. :src="imageWhiteStoreData.url"
  16. fit="contain"
  17. @click="previewsImg(imageWhiteStoreData.url)" />
  18. <img v-else :src="imageEmpty" width="100%" height="300px" />
  19. </div>
  20. <div class="AIVerifyWhite" v-html="imageWhiteStoreData.whiteMsg || ''"></div>
  21. <div class="uploadBtnAIVerify" :style="{ 'justify-content': 'center' }">
  22. <div class="changeImageAIVerify" @click="normalFlow">确认</div>
  23. </div>
  24. </div>
  25. </el-dialog>
  26. </div>
  27. </template>
  28. <script>
  29. import { ImagePreview } from 'vant';
  30. import imageEmpty from '@/assets/imageEmpty.png';
  31. export default {
  32. props: {
  33. imageWhiteStoreFlag: {
  34. type: Boolean,
  35. default: false,
  36. },
  37. imageWhiteStoreData: {
  38. type: Object,
  39. },
  40. },
  41. watch: {
  42. imageAIVerifyFlag: {
  43. handler(val) {
  44. console.log('imageAIVerifyFlag=' + val);
  45. if (val) this.initData();
  46. },
  47. immediate: true,
  48. },
  49. },
  50. data() {
  51. return {
  52. imageEmpty: imageEmpty,
  53. contentMessage: '', //提示内容
  54. vanPopup: true,
  55. url: '', // 本次图片路径
  56. };
  57. },
  58. methods: {
  59. initData() {},
  60. normalFlow() {
  61. this.$emit('close');
  62. let res = {
  63. data: [this.imageWhiteStoreData],
  64. };
  65. this.$emit('normalFlow', res);
  66. },
  67. close() {
  68. this.$emit('close');
  69. },
  70. previewsImg(url) {
  71. ImagePreview({
  72. images: [url],
  73. className: 'AIImageItem',
  74. getContainer: 'el-dialog__wrapper',
  75. });
  76. },
  77. },
  78. };
  79. </script>
  80. <style lang="scss">
  81. .el-dialog__wrapper {
  82. z-index: 3333 !important;
  83. display: flex;
  84. justify-content: center;
  85. align-items: center;
  86. background: rgba(0, 0, 0, 0.5) !important;
  87. .el-dialog__body {
  88. padding: 0px !important;
  89. }
  90. .el-dialog__header {
  91. text-align: center;
  92. }
  93. .AIVerifyErrdialog {
  94. width: vw(690) !important;
  95. margin-top: 1vh !important;
  96. border-radius: 8px !important;
  97. font-size: vw(32) !important;
  98. .el-dialog__headerbtn {
  99. width: vw(44);
  100. height: vw(44);
  101. background-color: #e1e1e1;
  102. border-radius: 50%;
  103. margin-top: -3px;
  104. }
  105. }
  106. .AIVerifyErrMask {
  107. width: 100%;
  108. padding: vw(30) vw(30) 0 vw(30);
  109. overflow: hidden;
  110. /* min-height: 180px; */
  111. .errorImg {
  112. width: 100%;
  113. display: flex;
  114. align-items: center;
  115. justify-content: center;
  116. min-height: vw(303);
  117. img {
  118. width: vw(235);
  119. height: vw(303);
  120. border-radius: vw(10);
  121. }
  122. }
  123. .AIVerifyWhite {
  124. font-size: vw(32);
  125. margin-top: vw(45);
  126. justify-content: center;
  127. text-align: left;
  128. // color: #9e0202;
  129. display: block;
  130. text-indent: 2em;
  131. b {
  132. color: #9e0202;
  133. }
  134. }
  135. }
  136. .van-popup {
  137. width: 90%;
  138. padding: 8px;
  139. border-radius: 8px;
  140. overflow: hidden;
  141. }
  142. .van-f-red-AIVerify {
  143. color: red;
  144. width: 8px;
  145. display: inline-block;
  146. line-height: 26px;
  147. }
  148. .photoAIVerify {
  149. /*margin-top: 9px;*/
  150. float: right;
  151. }
  152. .title {
  153. font-size: 16px;
  154. font-weight: 600;
  155. text-align: center;
  156. padding: 5px;
  157. }
  158. .uploadBtnAIVerify {
  159. display: flex;
  160. align-items: center;
  161. margin: vw(30) 0;
  162. div {
  163. display: flex;
  164. justify-content: center;
  165. align-items: center;
  166. font-size: vw(28);
  167. color: #fff;
  168. border-radius: 10px;
  169. /* margin: 0 6px; */
  170. width: vw(298);
  171. height: vw(68);
  172. background-blend-mode: normal, normal;
  173. }
  174. .confirmUploadAIVerify {
  175. background-image: linear-gradient(180deg, #ffa1a1 0%, #f6695f 35%, #ed301d 100%),
  176. linear-gradient(#aed0f9, #aed0f9);
  177. box-shadow: 0px 3px 6px 0px rgba(183, 30, 14, 0.35);
  178. margin-right: 6px;
  179. }
  180. .changeImageAIVerify {
  181. background-image: linear-gradient(180deg, #3b89e6 0%, #1e6acb 35%, #014baf 100%),
  182. linear-gradient(#0356b9, #0356b9);
  183. box-shadow: 0px 3px 6px 0px rgba(6, 60, 131, 0.35);
  184. margin-left: 6px;
  185. }
  186. .stillUploadAIVerify {
  187. background-image: linear-gradient(180deg, #3b89e6 0%, #1e6acb 35%, #014baf 100%),
  188. linear-gradient(#0356b9, #0356b9);
  189. box-shadow: 0px 3px 6px 0px rgba(6, 60, 131, 0.35);
  190. margin-left: 6px;
  191. }
  192. }
  193. }
  194. .van-overlay {
  195. /* z-index: 3334 !important; */
  196. }
  197. .van-image-preview {
  198. z-index: 3335 !important;
  199. background: rgba(0, 0, 0, 0.8) !important;
  200. }
  201. </style>