|
|
@@ -40,6 +40,7 @@ import { ImagePreview } from 'vant';
|
|
|
import { removePhotoBatch } from '@/api/index';
|
|
|
import uploadVNormalTaskPhoto from '@/components/uploadVNormalTaskPhoto';
|
|
|
import { mapState } from 'vuex';
|
|
|
+import { getTicketFun } from '@/utils/TXApiFun';
|
|
|
export default {
|
|
|
name: 'deleteUploadImgTaskPhoto',
|
|
|
components: { uploadVNormalTaskPhoto },
|
|
|
@@ -119,17 +120,20 @@ export default {
|
|
|
// },
|
|
|
// },
|
|
|
created() {
|
|
|
- this.imgArr = [];
|
|
|
- // <!-- 0=企业微信,1=H5相机 -->
|
|
|
- if (this.formData) {
|
|
|
- if (this.userInfo.photoMethod == '1') {
|
|
|
- this.imgArr = this.formData.collectionItemList[0].fileInfoList || [];
|
|
|
- } else {
|
|
|
- if (this.formData.mediaInfos) {
|
|
|
- this.downloadImage(this.formData.mediaInfos);
|
|
|
+ // 授权
|
|
|
+ getTicketFun(['downloadImage']).then(() => {
|
|
|
+ this.imgArr = [];
|
|
|
+ // <!-- 0=企业微信,1=H5相机 -->
|
|
|
+ if (this.formData) {
|
|
|
+ if (this.userInfo.photoMethod == '1') {
|
|
|
+ this.imgArr = this.formData.collectionItemList[0].fileInfoList || [];
|
|
|
+ } else {
|
|
|
+ if (this.formData.mediaInfos) {
|
|
|
+ this.downloadImage(this.formData.mediaInfos);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
- }
|
|
|
+ });
|
|
|
},
|
|
|
data() {
|
|
|
return {
|