Merge branch 'dunhuang-dev' of http://192.168.34.160:8023/admin/zhgdyunapp into dunhuang-cs
This commit is contained in:
commit
15a269f820
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<view class="areaTreePage">
|
||||
<scroll-view scroll-y="true" class="pageContent">
|
||||
<headers :showBack="pageType=='video'?false:true">
|
||||
<headers :showBack="pageType=='video'|| pageType=='backend'?false:true">
|
||||
<view class="headerName">
|
||||
{{headerName}}
|
||||
</view>
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
<scroll-view class="" :class="accountType == 5 || accountType == 6 || accountType == 10 ? 'smallHeight' : ''"
|
||||
scroll-y>
|
||||
<headers :showBack="accountType == 5 || accountType == 6 || accountType == 10 ? false : true"
|
||||
:themeType="true">
|
||||
:themeType="true">
|
||||
<view class="headerName" @click="toDept">
|
||||
{{ projectDetail.projectName }}
|
||||
</view>
|
||||
@ -278,11 +278,32 @@
|
||||
if (!this.userInfo.personMail && options.fromPage && options.fromPage == 'loginPage') {
|
||||
this.checkInfoComplete()
|
||||
}
|
||||
if(options.sn) {
|
||||
this.getDetailInfo(options.sn)
|
||||
}
|
||||
// #ifdef APP-PLUS
|
||||
// this.viewVersionInfo()
|
||||
// #endif
|
||||
},
|
||||
methods: {
|
||||
getDetailInfo(projectSn) {
|
||||
let data = {
|
||||
// enterpriseId: this.id,
|
||||
projectSn: projectSn || this.projectDetail.projectSn,
|
||||
}
|
||||
let that = this
|
||||
this.sendRequest({
|
||||
url: 'xmgl/project/getProjectInfoBySn',
|
||||
method: 'post',
|
||||
data: data,
|
||||
success: res => {
|
||||
console.log("enterpriseInfo", res.result.layoutImage);
|
||||
if(res.result.layoutImage) {
|
||||
that.loginBackgroundImage = res.result.layoutImage;
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
checkInfoComplete() {
|
||||
uni.showModal({
|
||||
title: '温馨提示',
|
||||
@ -472,7 +493,6 @@
|
||||
success(res) {
|
||||
console.log(res.result.iconType)
|
||||
that.iconType = res.result.iconType ? res.result.iconType : '1';
|
||||
that.loginBackgroundImage = res.result.loginBackgroundImage ? res.result.loginBackgroundImage : dunhuangIndex;
|
||||
}
|
||||
})
|
||||
},
|
||||
@ -868,7 +888,8 @@
|
||||
},
|
||||
method: 'POST',
|
||||
success(res) {
|
||||
that.projectDetail = res.result
|
||||
that.projectDetail = res.result;
|
||||
that.getDetailInfo();
|
||||
uni.setStorageSync('projectDetail', JSON.stringify(res.result))
|
||||
// that.loadWeather()
|
||||
}
|
||||
@ -992,6 +1013,7 @@
|
||||
background-size: 100% 100%;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.qrcodeItem {
|
||||
padding: 40rpx 30rpx;
|
||||
width: 480rpx;
|
||||
|
||||
@ -135,7 +135,7 @@
|
||||
<u-icon name="file-text"></u-icon>
|
||||
<view>{{item.name}}</view>
|
||||
</view>
|
||||
<view @click.stop="deleteImg(item,3)">
|
||||
<view @click.stop="downloadReport(item,3)">
|
||||
下载
|
||||
</view>
|
||||
</view>
|
||||
@ -526,6 +526,55 @@
|
||||
type: type,
|
||||
})
|
||||
},
|
||||
downloadReport(row) {
|
||||
console.log(1111111111111, row);
|
||||
const url = row.url.includes("http") ? row.url : this.url_config +
|
||||
'image/' + row.url;
|
||||
if (!url) {
|
||||
uni.showToast({
|
||||
title: "暂无下载文件!",
|
||||
icon: "none"
|
||||
})
|
||||
return
|
||||
}
|
||||
// #ifdef APP-PLUS
|
||||
uni.showLoading({
|
||||
title: "保存中..."
|
||||
})
|
||||
uni.downloadFile({
|
||||
url: url, //网络路径,下载下来
|
||||
success: (res) => {
|
||||
if (res.statusCode === 200) {
|
||||
uni.saveImageToPhotosAlbum({ // 然后调用这个方法
|
||||
filePath: res.tempFilePath,
|
||||
success: (res) => {
|
||||
uni.hideLoading(); //关闭提示
|
||||
uni.showToast({
|
||||
title: '保存成功'
|
||||
})
|
||||
},
|
||||
fail: (e) => {
|
||||
console.log(e);
|
||||
},
|
||||
})
|
||||
}
|
||||
},
|
||||
});
|
||||
// #endif
|
||||
|
||||
// #ifdef H5
|
||||
fetch(url)
|
||||
.then(response => response.blob())
|
||||
.then(blob => {
|
||||
const link = document.createElement('a');
|
||||
link.href = URL.createObjectURL(blob);
|
||||
// link.download = fileName;
|
||||
link.target = "_blank"; // 可选,如果希望在新窗口中下载文件,请取消注释此行
|
||||
link.click();
|
||||
});
|
||||
// #endif
|
||||
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
itemListUp() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user