|
@@ -319,8 +319,16 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
clickCard(event, { value }) {
|
|
|
- event.preventDefault();
|
|
|
- callDesktopAppMethods.downloadResource(this.blobContainerName, value.blob);
|
|
|
+ event.preventDefault();
|
|
|
+ let url = value.url;
|
|
|
+ let sas;
|
|
|
+
|
|
|
+ if (value.extension === 'HTEX') {
|
|
|
+ url = url.replace('/index.json', '');
|
|
|
+ }
|
|
|
+ [url, sas] = url.split('?');
|
|
|
+ sas ??= '';
|
|
|
+ callDesktopAppMethods.downloadResource(url, sas);
|
|
|
},
|
|
|
onWxtClick() {
|
|
|
this.$api.auth.xkwOauth({
|
|
@@ -795,12 +803,6 @@ export default {
|
|
|
this.fileColumns.splice(2, 0, ...arr)
|
|
|
}
|
|
|
this.contentTypeList = [
|
|
|
- //{
|
|
|
- // label: this.$t('teachContent.recent'),
|
|
|
- // type: 'recent',
|
|
|
- // icon: 'md-time',
|
|
|
- // tips: this.$t('teachContent.recentTips')
|
|
|
- //},
|
|
|
{
|
|
|
label: this.$t('teachContent.filterRes'),
|
|
|
type: 'res',
|
|
@@ -1129,7 +1131,16 @@ export default {
|
|
|
},
|
|
|
|
|
|
handleResource(row) {
|
|
|
- callDesktopAppMethods.downloadResource(this.blobContainerName, row.blob);
|
|
|
+ let url = row.url;
|
|
|
+ let sas;
|
|
|
+ console.log(sas)
|
|
|
+
|
|
|
+ if (row.extension === 'HTEX') {
|
|
|
+ url = url.replace('/index.json', '');
|
|
|
+ }
|
|
|
+ [url, sas] = url.split('?');
|
|
|
+ sas ??= '';
|
|
|
+ callDesktopAppMethods.downloadResource(url, sas);
|
|
|
},
|
|
|
|
|
|
formatDate(timestamp) {
|
|
@@ -1230,11 +1241,7 @@ export default {
|
|
|
this.extFilter = []
|
|
|
this.selections.length = 0
|
|
|
this.activeType = this.contentTypeList[index].type
|
|
|
- //最近上传文件读取本地storage
|
|
|
- if (this.activeType == 'recent') {
|
|
|
- this.getCacheFiles()
|
|
|
- return
|
|
|
- }
|
|
|
+
|
|
|
if (this.isFirst[this.activeType]) {
|
|
|
this.fileListShow.length = 0
|
|
|
this.findFileList()
|
|
@@ -1376,7 +1383,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
$route: {
|
|
|
- handler: function (to, from) {
|
|
|
+ handler: async function (to, from) {
|
|
|
this.initData()
|
|
|
if (this.$route.fullPath.includes('school')) {
|
|
|
this.routerScope = 'school'
|
|
@@ -1384,7 +1391,8 @@ export default {
|
|
|
this.routerScope = 'private'
|
|
|
}
|
|
|
|
|
|
- this.getSasStr()
|
|
|
+ await this.getSasStr()
|
|
|
+ this.findFileList()
|
|
|
},
|
|
|
immediate: true
|
|
|
},
|