|
@@ -12,6 +12,7 @@
|
|
|
</template>
|
|
</template>
|
|
|
</avue-crud>
|
|
</avue-crud>
|
|
|
<reportContainer ref="reportContainer"></reportContainer>
|
|
<reportContainer ref="reportContainer"></reportContainer>
|
|
|
|
|
+ <mail-component ref="mailComponentRef" />
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
@@ -22,10 +23,11 @@ import { mapGetters } from "vuex";
|
|
|
import { billsDetail } from '@/api/iosBasicData/bills'
|
|
import { billsDetail } from '@/api/iosBasicData/bills'
|
|
|
import { bbusinesstypeList } from "@/api/iosBasicData/bbusinesstype";
|
|
import { bbusinesstypeList } from "@/api/iosBasicData/bbusinesstype";
|
|
|
import reportContainer from "@/views/iosBasicData/report-container/report-container.vue"
|
|
import reportContainer from "@/views/iosBasicData/report-container/report-container.vue"
|
|
|
-
|
|
|
|
|
|
|
+import mailComponent from "@/components/iosbasic-data/mail-component.vue";
|
|
|
export default {
|
|
export default {
|
|
|
components: {
|
|
components: {
|
|
|
- reportContainer
|
|
|
|
|
|
|
+ reportContainer,
|
|
|
|
|
+ mailComponent
|
|
|
},
|
|
},
|
|
|
props: {
|
|
props: {
|
|
|
id: {
|
|
id: {
|
|
@@ -35,10 +37,10 @@ export default {
|
|
|
type: Boolean,
|
|
type: Boolean,
|
|
|
default: false,
|
|
default: false,
|
|
|
},
|
|
},
|
|
|
- classifycode:{
|
|
|
|
|
- type: String,
|
|
|
|
|
- default: '',
|
|
|
|
|
- },
|
|
|
|
|
|
|
+ classifycode: {
|
|
|
|
|
+ type: String,
|
|
|
|
|
+ default: '',
|
|
|
|
|
+ },
|
|
|
},
|
|
},
|
|
|
data() {
|
|
data() {
|
|
|
return {
|
|
return {
|
|
@@ -142,27 +144,27 @@ export default {
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
async created() {
|
|
async created() {
|
|
|
- if(!!this.classifycode) {
|
|
|
|
|
- this.query.classifyCode = this.classifycode;
|
|
|
|
|
- this.classifyCodeReadonly = true;
|
|
|
|
|
- let col = this.optionBack.column.find(c=>c.prop=="classifyCode")
|
|
|
|
|
- if(col){
|
|
|
|
|
- col.search = false;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ if (!!this.classifycode) {
|
|
|
|
|
+ this.query.classifyCode = this.classifycode;
|
|
|
|
|
+ this.classifyCodeReadonly = true;
|
|
|
|
|
+ let col = this.optionBack.column.find(c => c.prop == "classifyCode")
|
|
|
|
|
+ if (col) {
|
|
|
|
|
+ col.search = false;
|
|
|
}
|
|
}
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
- this.option = await this.getColumnData(this.getColumnName(312.4), this.optionBack);
|
|
|
|
|
- console.log('report.create', this.option)
|
|
|
|
|
|
|
+ this.option = await this.getColumnData(this.getColumnName(312.4), this.optionBack);
|
|
|
|
|
+ console.log('report.create', this.option)
|
|
|
|
|
|
|
|
- getUserApprovalList().then(res => {
|
|
|
|
|
- this.findObject(this.option.column, "authorizedUsersId").dicData = res.data.data
|
|
|
|
|
- })
|
|
|
|
|
- // 获取业务类型
|
|
|
|
|
- bbusinesstypeList(1, 20).then(res => {
|
|
|
|
|
- this.findObject(this.option.column, "businessType").dicData = res.data.data.records
|
|
|
|
|
- })
|
|
|
|
|
|
|
+ getUserApprovalList().then(res => {
|
|
|
|
|
+ this.findObject(this.option.column, "authorizedUsersId").dicData = res.data.data
|
|
|
|
|
+ })
|
|
|
|
|
+ // 获取业务类型
|
|
|
|
|
+ bbusinesstypeList(1, 20).then(res => {
|
|
|
|
|
+ this.findObject(this.option.column, "businessType").dicData = res.data.data.records
|
|
|
|
|
+ })
|
|
|
},
|
|
},
|
|
|
- async mounted () {
|
|
|
|
|
|
|
+ async mounted() {
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
|
...mapGetters(["permission"]),
|
|
...mapGetters(["permission"]),
|
|
@@ -542,6 +544,13 @@ export default {
|
|
|
this.handleReportPreview(url, res.data.data.data)
|
|
this.handleReportPreview(url, res.data.data.data)
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
+ testMail(e) {
|
|
|
|
|
+ console.info('eeeeeeeeeeeeeeeeeeee----', e)
|
|
|
|
|
+ this.$refs.mailComponentRef.dialogVisible = true
|
|
|
|
|
+ this.$refs.mailComponentRef.formData.attachments = e.fileName
|
|
|
|
|
+ this.$refs.mailComponentRef.formData.fileType = e.formatName
|
|
|
|
|
+ this.$refs.mailComponentRef.formData.fileContent = e.data
|
|
|
|
|
+ },
|
|
|
// 预览报表
|
|
// 预览报表
|
|
|
handleReportPreview(url, row) {
|
|
handleReportPreview(url, row) {
|
|
|
Stimulsoft.Base.StiLicense.key = '6vJhGtLLLz2GNviWmUTrhSqnOItdDwjBylQzQcAOiHn0s4gy0Fr5YoUZ9V00Y0igCSFQzwEqYBh/N77k4f0fWXTHW5rqeBNLkaurJDenJ9o97TyqHs9HfvINK18Uwzsc/bG01Rq+x3H3Rf+g7AY92gvWmp7VA2Uxa30Q97f61siWz2dE5kdBVcCnSFzC6awE74JzDcJMj8OuxplqB1CYcpoPcOjKy1PiATlC3UsBaLEXsok1xxtRMQ283r282tkh8XQitsxtTczAJBxijuJNfziYhci2jResWXK51ygOOEbVAxmpflujkJ8oEVHkOA/CjX6bGx05pNZ6oSIu9H8deF94MyqIwcdeirCe60GbIQByQtLimfxbIZnO35X3fs/94av0ODfELqrQEpLrpU6FNeHttvlMc5UVrT4K+8lPbqR8Hq0PFWmFrbVIYSi7tAVFMMe2D1C59NWyLu3AkrD3No7YhLVh7LV0Tttr/8FrcZ8xirBPcMZCIGrRIesrHxOsZH2V8t/t0GXCnLLAWX+TNvdNXkB8cF2y9ZXf1enI064yE5dwMs2fQ0yOUG/xornE'
|
|
Stimulsoft.Base.StiLicense.key = '6vJhGtLLLz2GNviWmUTrhSqnOItdDwjBylQzQcAOiHn0s4gy0Fr5YoUZ9V00Y0igCSFQzwEqYBh/N77k4f0fWXTHW5rqeBNLkaurJDenJ9o97TyqHs9HfvINK18Uwzsc/bG01Rq+x3H3Rf+g7AY92gvWmp7VA2Uxa30Q97f61siWz2dE5kdBVcCnSFzC6awE74JzDcJMj8OuxplqB1CYcpoPcOjKy1PiATlC3UsBaLEXsok1xxtRMQ283r282tkh8XQitsxtTczAJBxijuJNfziYhci2jResWXK51ygOOEbVAxmpflujkJ8oEVHkOA/CjX6bGx05pNZ6oSIu9H8deF94MyqIwcdeirCe60GbIQByQtLimfxbIZnO35X3fs/94av0ODfELqrQEpLrpU6FNeHttvlMc5UVrT4K+8lPbqR8Hq0PFWmFrbVIYSi7tAVFMMe2D1C59NWyLu3AkrD3No7YhLVh7LV0Tttr/8FrcZ8xirBPcMZCIGrRIesrHxOsZH2V8t/t0GXCnLLAWX+TNvdNXkB8cF2y9ZXf1enI064yE5dwMs2fQ0yOUG/xornE'
|
|
@@ -563,6 +572,9 @@ export default {
|
|
|
options.exports.showExportToDocument = false // 显示导出到文档
|
|
options.exports.showExportToDocument = false // 显示导出到文档
|
|
|
options.toolbar.showParametersButton = true // 显示参数按钮
|
|
options.toolbar.showParametersButton = true // 显示参数按钮
|
|
|
options.appearance.bookmarksPrint = true // 书签打印
|
|
options.appearance.bookmarksPrint = true // 书签打印
|
|
|
|
|
+ options.toolbar.showSendEmailButton = true // 显示发送邮件按钮
|
|
|
|
|
+ options.email.showEmailDialog = false
|
|
|
|
|
+ options.email.showExportDialog = false
|
|
|
// options.toolbar.showPrintButton = false // 打印按钮是否显示 下面直接自定义控制打印弹窗是否开启
|
|
// options.toolbar.showPrintButton = false // 打印按钮是否显示 下面直接自定义控制打印弹窗是否开启
|
|
|
|
|
|
|
|
// printDestination 参数:用于指定报表打印的目标位置,可以是打印机、PDF 文件或者直接打印到浏览器等。
|
|
// printDestination 参数:用于指定报表打印的目标位置,可以是打印机、PDF 文件或者直接打印到浏览器等。
|
|
@@ -573,7 +585,7 @@ export default {
|
|
|
options.appearance.htmlRenderMode = Stimulsoft.Report.Export.StiHtmlExportMode.Table
|
|
options.appearance.htmlRenderMode = Stimulsoft.Report.Export.StiHtmlExportMode.Table
|
|
|
// 是创建一个 Stimulsoft 报表查看器的实例的代码
|
|
// 是创建一个 Stimulsoft 报表查看器的实例的代码
|
|
|
let viewer = new Stimulsoft.Viewer.StiViewer(options, 'StiViewer', false)
|
|
let viewer = new Stimulsoft.Viewer.StiViewer(options, 'StiViewer', false)
|
|
|
-
|
|
|
|
|
|
|
+ viewer.onEmailReport = this.testMail
|
|
|
// 报表
|
|
// 报表
|
|
|
console.log("创建一个报表实例");
|
|
console.log("创建一个报表实例");
|
|
|
let report = new window.Stimulsoft.Report.StiReport();
|
|
let report = new window.Stimulsoft.Report.StiReport();
|