2.2提交
This commit is contained in:
+10
-1
@@ -110,6 +110,7 @@ const name=ref('');
|
||||
const showInnerSort=ref(false);
|
||||
const innerSortTitle=ref('上传时间');
|
||||
import downloadStore from "@/store/downloadStoreFile.js";
|
||||
import isAndroid from '@/utils/platform';
|
||||
const downloadTasks=ref([]);
|
||||
const downLoadtaskList=computed(()=>{
|
||||
return downloadTasks.value.filter((item)=>item.status == "completed" && item.type == "zhinan").map((item)=>item.id);
|
||||
@@ -405,7 +406,8 @@ const viewGuideline = (cell) => {
|
||||
console.log(downloadTasks.value);
|
||||
downloadTasks.value.forEach(item => {
|
||||
if(item.id == cell.uuid) {
|
||||
plus.runtime.openFile(item.localPath, function(e) {
|
||||
// if(isAndroid){
|
||||
plus.runtime.openFile(item.localPath, function(e) {
|
||||
console.log('打开成功');
|
||||
}, function(e) {
|
||||
uni.showToast({
|
||||
@@ -415,6 +417,13 @@ const viewGuideline = (cell) => {
|
||||
});
|
||||
console.log('打开失败:' + e.message);
|
||||
});
|
||||
// }else{
|
||||
// uni.sendNativeEvent('openDocument', {
|
||||
// msg: item.localPath.replaceAll('_doc/uniapp_save/',''),
|
||||
// }, ret => {
|
||||
// console.log(ret);
|
||||
// });
|
||||
// }
|
||||
// uni.openDocument({
|
||||
// filePath: item.localPath,
|
||||
// fileType: 'pdf',
|
||||
|
||||
Reference in New Issue
Block a user