补充
This commit is contained in:
parent
30e6d44f51
commit
7eb0d12edc
14
App.vue
14
App.vue
@ -124,13 +124,13 @@
|
|||||||
// });
|
// });
|
||||||
|
|
||||||
// // #endif
|
// // #endif
|
||||||
// #ifdef APP-PLUS
|
// // #ifdef APP-PLUS
|
||||||
let osname = plus.os.name
|
// let osname = plus.os.name
|
||||||
if (osname == "Android") {
|
// if (osname == "Android") {
|
||||||
var activity = plus.android.runtimeMainActivity()
|
// var activity = plus.android.runtimeMainActivity()
|
||||||
plus.android.invoke(plus.android.invoke(activity, "getWindow"), "addFlags", 0x00002000)
|
// plus.android.invoke(plus.android.invoke(activity, "getWindow"), "addFlags", 0x00002000)
|
||||||
}
|
// }
|
||||||
// #endif
|
// // #endif
|
||||||
// #ifdef H5
|
// #ifdef H5
|
||||||
// 禁止长按或右键保存
|
// 禁止长按或右键保存
|
||||||
document.oncontextmenu = new Function("event.returnValue=false");
|
document.oncontextmenu = new Function("event.returnValue=false");
|
||||||
|
@ -21,7 +21,8 @@ const install = (Vue, vm) => {
|
|||||||
header: {
|
header: {
|
||||||
'content-type': 'application/json; charset=utf-8'
|
'content-type': 'application/json; charset=utf-8'
|
||||||
},
|
},
|
||||||
originalData: true
|
originalData: true,
|
||||||
|
showLoading: false
|
||||||
});
|
});
|
||||||
// 请求拦截,配置Token等参数
|
// 请求拦截,配置Token等参数
|
||||||
Vue.prototype.$u.http.interceptor.request = (config) => {
|
Vue.prototype.$u.http.interceptor.request = (config) => {
|
||||||
|
@ -519,6 +519,7 @@ export default {
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
z-index: 81;
|
z-index: 81;
|
||||||
|
top: 0;
|
||||||
}
|
}
|
||||||
// #endif
|
// #endif
|
||||||
.wd-top{
|
.wd-top{
|
||||||
|
@ -66,6 +66,24 @@ export const tools = {
|
|||||||
longPressActions: {
|
longPressActions: {
|
||||||
itemList: itemList,
|
itemList: itemList,
|
||||||
success: function(data) {
|
success: function(data) {
|
||||||
|
if(data.tapIndex === 1){
|
||||||
|
//先下载到本地获取临时路径
|
||||||
|
uni.downloadFile({
|
||||||
|
url: imagesList[data.index],
|
||||||
|
success: (res) => {
|
||||||
|
//将临时路径保存到相册,即可在相册中查看图片
|
||||||
|
uni.saveImageToPhotosAlbum({
|
||||||
|
filePath: res.tempFilePath, //不支持网络地址
|
||||||
|
success: function () {
|
||||||
|
uni.showToast({icon:"none",title: '保存图片到相册成功',position: 'bottom'});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
fail: (err) => {
|
||||||
|
uni.showToast({icon:"none",title: '保存图片失败',position: 'bottom'});
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
console.log(data)
|
console.log(data)
|
||||||
},
|
},
|
||||||
fail: function(err) {
|
fail: function(err) {
|
||||||
|
Loading…
Reference in New Issue
Block a user