|
- <template>
- <div style="width: 100%;">
- <div id = "pro_main">
- <div style="margin-top: 10px;">
- <b class="pro_item">云脑分析</b> <span class="update_time">数据更新时间:</span> <span style="font-size: 12px;">{{lastUpdatedTime}} / 从有记录起开始统计</span>
- </div>
-
- <bar-label :width="'95%'" :height="'500px'"></bar-label>
- <div style="margin-top: 20px;">
- <span class="sta_iterm">统计周期:</span>
- <button type="button" class='btnLast' id = "all" v-bind:class="{colorChange:7==dynamic}" @click="resetPage(),getAllProList('all',7)">所有</button>
- <span style="float:right; margin-right: 20px;">
- <div style="display:inline-block;margin-left: 40px; ">
- <a class="el-icon-download" v-if="tableData!=''" :href= "'../api/v1/cloudbrainboard/downloadAll'"></a>
- <i class="el-icon-download" v-else="tableData=''" href="#" style="color:rgba(187, 187, 187, 100);" @click='popMark()'></i>
- <!-- <span ><a id = "download_file" :href= "'../api/v1/projectboard/downloadAll'" >下载报告</a> </span> -->
- <span >
- <a id = "download_file" v-if="tableData!=''" :href= "'../api/v1/cloudbrainboard/downloadAll'">下载报告</a>
- <a id = "download_file" v-else="tableData=''" href= "#" style="color:rgba(187, 187, 187, 100);" @click='popMark()'>下载报告</a>
- </span>
- </div>
- </span>
- </div>
-
- </div>
-
- </div>
- </template>
-
- <script>
- // import barLabel from './basic/barLabel.vue';
- const {AppSubUrl, StaticUrlPrefix, csrf} = window.config;
-
- import { export2Excel } from '../excel/util.js'
- export default{
- name:'ProAnalysis',
- components: {
- // barLabel,
- },
- methods: {
- popMark(){
- alert("数据为空时,不能下载!")
- },
- exportData(){
-
- // this.getOneProList(this.pro_id,'all',true,7)
- // this.getOneProList(this.pro_id,'all',false,7)
- // this.fileName()
- if (this.tableDataID!=''){
- this.currentPage=1
- var saveFileName = this.getFileName()
- export2Excel(this.columns,this.tableDataID,saveFileName)
- }else{
- alert("数据为空时,不能下载!")
- }
-
- },
- },
- }
- </script>
-
- <style scoped>
- .pro_item{
- font-size: 16px;
- color: rgba(16, 16, 16, 100);
- font-family: SourceHanSansSC-bold;
- }
- .update_time{
- line-height: 17px;
- font-size: 12px;
- color:rgba(187, 187, 187, 100);
- margin-left: 10px;
- }
- .btnLast{
- line-height: 1.5;
- margin: -3.5px;
- border: 1px solid rgba(22, 132, 252, 100);
- /* border-right: none; */
- background: #FFFF;
- color: #1684FC;
- width: 60px;
- height: 30px;
- border-radius:0px 4px 4px 0px;
- }
-
- </style>
|