@@ -126,6 +132,9 @@ export default {
name: 'ReportDetail',
data() {
return {
+ showText:false,
+ pointNum:0,
+ file:{},
isAdmin: false, //是否是管理员
report: {},
formatDate2,
@@ -144,6 +153,7 @@ export default {
},
userId: this.$store.getters.userInfo.usid,
userName: this.$store.getters.userInfo.usname,
+ isExcel:false
}
},
methods: {
@@ -248,13 +258,26 @@ export default {
}
},
// 预览
- previewRow() {
+ previewRow(fileId,reportId) {
// this.watermarkText = `${this.$store.state.userInfo.usname} ${formatDate(+new Date(), 'yyyy年MM月dd日 hh:mm:ss')}`
// this.row = JSON.parse(this.$route.query.row)
- this.$api.report.reportGetReportHtmlId({id: this.row.id}).then(({data}) => {
+ this.$api.report.reportGetReportHtmlId({fileId: fileId,reportId:reportId}).then(({data}) => {
this.content = data.content
})
},
+ handleFile(row){
+ this.file=row
+
+ let lastName=row.fileName.split('.')
+ let list=['xls','xlsx','XLS','XLSX']
+ if(list.indexOf(lastName[lastName.length-1])>-1){
+ this.showText=true
+ }else{
+ this.showText=false
+ this.previewRow(this.file.fileId,this.row.id)
+
+ }
+ },
// 下载
downloadRow(row) {
// this.$confirm('此操作将下载所选数据文件, 是否继续?', '提示', {
@@ -262,9 +285,16 @@ export default {
// cancelButtonText: '取消',
// type: 'warning'
// }).then(() => {
- this.$api.report.reportDownload({fileId: row.fileId, repostId: row.id}).then(res => {
- downloadFile(res)
- })
+ if(this.isExcel){
+ this.$api.report.reportDownloadALL({ reportId: this.row.id}).then(res => {
+ downloadFile(res)
+ })
+ }else{
+ this.$api.report.reportDownload({ reportId: this.row.id}).then(res => {
+ downloadFile(res)
+ })
+ }
+
// })
},
// 获取详情
@@ -273,13 +303,17 @@ export default {
this.row = res.data
this.isAdmin = this.$store.getters.userInfo.usid==this.row.createUserId
// 需要给分数/2
- this.previewRow()
+ this.handleFile(this.row.fileList[0])
})
},
},
mounted() {
this.reportId = this.$route.query.reportId
-
+ if(this.$route.query.isExecel){
+ this.isExcel=true
+ }else{
+ this.isExcel=false
+ }
// this.previewRow()
this.getComment()
this.getReportDetail()
@@ -291,6 +325,7 @@ export default {
diff --git a/src/views/Report/ReportList.vue b/src/views/Report/ReportList.vue
index 5abce49..cc6d310 100644
--- a/src/views/Report/ReportList.vue
+++ b/src/views/Report/ReportList.vue
@@ -77,6 +77,7 @@
@@ -122,6 +123,8 @@
+ {{ row.collect==0?'收藏':'取消收藏' }}
+
预览
下载
申请权限
@@ -168,7 +171,7 @@
+
+
diff --git a/src/views/userCenter/mail/index.vue b/src/views/userCenter/mail/index.vue
new file mode 100644
index 0000000..b477ef0
--- /dev/null
+++ b/src/views/userCenter/mail/index.vue
@@ -0,0 +1,499 @@
+
+
+
+ 站内信
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 查询
+ 重置
+
+
+
+
+
+ 全部标注已读
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{formatDate2(row.createDate)}}
+
+
+
+
+ {{row.readType=='0'?'未读':'已读'}}
+
+
+
+
+ 查看
+
+
+
+
+
+
+
+
+
+
+
+
+
{{detail.messageTitle}}
+
+
+ 发布时间: {{formatDate2(detail.createDate)}}
+
+
+
+
+ {{detail.messageTypeDesc}}
+
+
+ 通知内容:{{detail.content}}
+
+
+
+
+
+
+
+
+
+
+