|
@@ -443,7 +443,10 @@ export default {
|
|
|
},
|
|
|
computed: {
|
|
|
showList() {
|
|
|
- return this.list.filter((i) => i.status === 3);
|
|
|
+ if (this.materialTypeAlias === "pano") {
|
|
|
+ return this.list.filter((i) => i.status === 3);
|
|
|
+ }
|
|
|
+ return this.list;
|
|
|
},
|
|
|
materialTypeAlias() {
|
|
|
if (this.materialType === "3D") {
|
|
@@ -624,35 +627,37 @@ export default {
|
|
|
},
|
|
|
preProessData(newData) {
|
|
|
this.list = this.list.concat(newData);
|
|
|
+ //全景图
|
|
|
+ if (this.materialTypeAlias === "pano") {
|
|
|
+ const uploadlist = this.list
|
|
|
+ .filter((i) => i.status < 3)
|
|
|
+ .map((item) => {
|
|
|
+ let itemInUploadList = {
|
|
|
+ title: item.name,
|
|
|
+ ifKnowProgress: false,
|
|
|
+ progress: 0,
|
|
|
+ status: "LOADING",
|
|
|
+ statusText: this.$i18n.t(`gather.cutting`),
|
|
|
+ uid: `u_${this.$randomWord(true, 8, 8)}`,
|
|
|
+ abortHandler: null,
|
|
|
+ backendId: item.id, // 只用于全景图上传
|
|
|
+ parentFolderId: item.dirId,
|
|
|
+ };
|
|
|
+ return itemInUploadList;
|
|
|
+ });
|
|
|
|
|
|
- const uploadlist = this.list
|
|
|
- .filter((i) => i.status < 3)
|
|
|
- .map((item) => {
|
|
|
- let itemInUploadList = {
|
|
|
- title: item.name,
|
|
|
- ifKnowProgress: false,
|
|
|
- progress: 0,
|
|
|
- status: "LOADING",
|
|
|
- statusText: this.$i18n.t(`gather.cutting`),
|
|
|
- uid: `u_${this.$randomWord(true, 8, 8)}`,
|
|
|
- abortHandler: null,
|
|
|
- backendId: item.id, // 只用于全景图上传
|
|
|
- parentFolderId: item.dirId,
|
|
|
- };
|
|
|
- return itemInUploadList;
|
|
|
- });
|
|
|
-
|
|
|
- const res = new Map();
|
|
|
+ const res = new Map();
|
|
|
|
|
|
- const latestUploadlist = this.uploadStatusList
|
|
|
- .concat(uploadlist)
|
|
|
- .filter((a) => !res.has(a.backendId) && res.set(a.backendId, 1));
|
|
|
- console.log("latestUploadlist", latestUploadlist);
|
|
|
- const capitalizedMaterialType = capitalize(this.materialType);
|
|
|
- this.$store.commit(
|
|
|
- `setUploadStatusList${capitalizedMaterialType}`,
|
|
|
- latestUploadlist
|
|
|
- );
|
|
|
+ const latestUploadlist = this.uploadStatusList
|
|
|
+ .concat(uploadlist)
|
|
|
+ .filter((a) => !res.has(a.backendId) && res.set(a.backendId, 1));
|
|
|
+ console.log("latestUploadlist", latestUploadlist);
|
|
|
+ const capitalizedMaterialType = capitalize(this.materialType);
|
|
|
+ this.$store.commit(
|
|
|
+ `setUploadStatusList${capitalizedMaterialType}`,
|
|
|
+ latestUploadlist
|
|
|
+ );
|
|
|
+ }
|
|
|
},
|
|
|
refreshMaterialList: debounce(
|
|
|
function (type) {
|