Commit 2bb042d71cd0b93a9491a6bb87e845cc0d87608a
1 parent
d44c348c
1
Showing
3 changed files
with
213 additions
and
161 deletions
admin-web-master/src/components/fujianUpload/fujianList.vue
| ... | ... | @@ -16,7 +16,7 @@ |
| 16 | 16 | </div> |
| 17 | 17 | </div> |
| 18 | 18 | <div v-if="islist" v-for="(file, i) in localValue" :key="'upload-BaseImage' + i" style="display: flex;justify-content: space-between;width: 100%;"> |
| 19 | - <div>文件{{i+1}}</div> | |
| 19 | + <div>{{ file.address }}</div> | |
| 20 | 20 | <div title="删除" class="delete-box" |
| 21 | 21 | @click="handleDeleteImg(file, i)"> |
| 22 | 22 | <i class="el-icon-close"></i> | ... | ... |
admin-web-master/src/views/detect/analyse.vue
| 1 | 1 | <template> |
| 2 | 2 | <div style="background-color:#f7f7f7;padding:10px 10px;"> |
| 3 | - <div class="zhuti"> | |
| 3 | + <div class="zhuti "> | |
| 4 | 4 | <div style="height:58px;line-height:58px;"> |
| 5 | 5 | <div style="color:#0006"> <span>招商资源监测</span> <span style="padding:0 5px;">></span> <span |
| 6 | 6 | style="color:#000000e6">统计分析</span></div> |
| ... | ... | @@ -8,8 +8,8 @@ |
| 8 | 8 | <div style="width: 100%;margin-bottom:30px;"> |
| 9 | 9 | <div style="display:flex;justify-content: space-between"> |
| 10 | 10 | <div style="display:flex;"> |
| 11 | - <div style="margin-right: 10px;line-height:35px;">商铺/广告位资源统计</div> | |
| 12 | - <!-- <el-select v-model="formSel.createDate" placeholder="所属区域" style="width: 150px;margin-right: 10px"> | |
| 11 | + <!-- <div style="margin-right: 10px;line-height:35px;">商铺/广告位资源统计</div> --> | |
| 12 | + <!-- <el-select v-model="formSel.createDate" placeholder="所属区域" style="width: 150px;margin-right: 10px"> | |
| 13 | 13 | <el-option label="1" value="1" /> |
| 14 | 14 | <el-option label="2" value="2" /> |
| 15 | 15 | </el-select> |
| ... | ... | @@ -17,10 +17,11 @@ |
| 17 | 17 | <el-option label="1" value="1" /> |
| 18 | 18 | <el-option label="2" value="2" /> |
| 19 | 19 | </el-select> --> |
| 20 | - <el-date-picker v-model="FormTime" value-format="yyyy-MM-dd" type="daterange" range-separator="-" start-placeholder="开始日期" | |
| 21 | - end-placeholder="结束日期" style="width: 300px;margin-right: 10px;" prefix-icon="none"> | |
| 20 | + <el-date-picker v-model="FormTime" value-format="yyyy-MM-dd" type="daterange" range-separator="-" | |
| 21 | + start-placeholder="开始日期" end-placeholder="结束日期" style="width: 300px;margin-right: 10px;" | |
| 22 | + prefix-icon="none"> | |
| 22 | 23 | </el-date-picker> |
| 23 | - <el-button @click="onSubmit" style="background-color: #3F9B6A;color: #fff;">检索 | |
| 24 | + <el-button @click="onSubmit" style="background-color: #3F9B6A;color: #fff;">查询 | |
| 24 | 25 | </el-button> |
| 25 | 26 | <el-button @click="resetting" class="buttonHover" |
| 26 | 27 | style="color: #000;border: 1px solid #DBDBDB;background-color: #fff;">重置 |
| ... | ... | @@ -31,45 +32,49 @@ |
| 31 | 32 | </el-button> |
| 32 | 33 | </div> |
| 33 | 34 | </div> |
| 34 | - <div style="display:flex;margin-top:10px;"> | |
| 35 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 36 | - <div style="display: flex;justify-content: space-between;"> | |
| 37 | - <div style="line-height:35px;">资源数量增长趋势</div> | |
| 38 | - <!-- <div> | |
| 39 | - <el-select v-model="formSel.createDate" placeholder="状态" style="width: 100px;margin-right: 10px"> | |
| 40 | - <el-option label="1" value="1" /> | |
| 41 | - <el-option label="2" value="2" /> | |
| 42 | - </el-select> | |
| 43 | - <el-select v-model="formSel.createDate" placeholder="类型" style="width: 100px;margin-right: 10px"> | |
| 44 | - <el-option label="1" value="1" /> | |
| 45 | - <el-option label="2" value="2" /> | |
| 46 | - </el-select> | |
| 47 | - </div> --> | |
| 48 | - </div> | |
| 49 | - <div ref="shop1ZX" style="width:100%;height: 400px;"></div> | |
| 35 | + | |
| 36 | + </div> | |
| 37 | + <div ref="contentToConvert"> | |
| 38 | + <TitleWithCircle title="商铺/广告位资源统计" style="margin: 20px 0;" /> | |
| 39 | + <div style="display:flex;"> | |
| 40 | + <div style="width:48%;height: 400px;"> | |
| 41 | + <div style="display: flex;justify-content: space-between;"> | |
| 42 | + <div style="line-height:35px;">资源数量增长趋势</div> | |
| 43 | + <!-- <div> | |
| 44 | + <el-select v-model="formSel.createDate" placeholder="状态" style="width: 100px;margin-right: 10px"> | |
| 45 | + <el-option label="1" value="1" /> | |
| 46 | + <el-option label="2" value="2" /> | |
| 47 | + </el-select> | |
| 48 | + <el-select v-model="formSel.createDate" placeholder="类型" style="width: 100px;margin-right: 10px"> | |
| 49 | + <el-option label="1" value="1" /> | |
| 50 | + <el-option label="2" value="2" /> | |
| 51 | + </el-select> | |
| 52 | + </div> --> | |
| 50 | 53 | </div> |
| 51 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 52 | - <div style="display: flex;justify-content: space-between;"> | |
| 53 | - <div style="line-height:35px;">各资源数量统计</div> | |
| 54 | - <!-- <div> | |
| 55 | - <el-select v-model="formSel.createDate" placeholder="状态" style="width: 100px;margin-right: 10px"> | |
| 56 | - <el-option label="1" value="1" /> | |
| 57 | - <el-option label="2" value="2" /> | |
| 58 | - </el-select> | |
| 59 | - <el-select v-model="formSel.createDate" placeholder="类型" style="width: 100px;margin-right: 10px"> | |
| 60 | - <el-option label="1" value="1" /> | |
| 61 | - <el-option label="2" value="2" /> | |
| 62 | - </el-select> | |
| 63 | - </div> --> | |
| 64 | - </div> | |
| 65 | - <div ref="shop1TJ" style="width:100%;height: 400px;"></div> | |
| 54 | + <div ref="shop1ZX" style="width:100%;height: 400px;"></div> | |
| 55 | + </div> | |
| 56 | + <div style="width:48%;height: 400px;"> | |
| 57 | + <div style="display: flex;justify-content: space-between;"> | |
| 58 | + <div style="line-height:35px;">各资源数量统计</div> | |
| 59 | + <!-- <div> | |
| 60 | + <el-select v-model="formSel.createDate" placeholder="状态" style="width: 100px;margin-right: 10px"> | |
| 61 | + <el-option label="1" value="1" /> | |
| 62 | + <el-option label="2" value="2" /> | |
| 63 | + </el-select> | |
| 64 | + <el-select v-model="formSel.createDate" placeholder="类型" style="width: 100px;margin-right: 10px"> | |
| 65 | + <el-option label="1" value="1" /> | |
| 66 | + <el-option label="2" value="2" /> | |
| 67 | + </el-select> | |
| 68 | + </div> --> | |
| 66 | 69 | </div> |
| 70 | + <div ref="shop1TJ" style="width:100%;height: 400px;"></div> | |
| 67 | 71 | </div> |
| 68 | 72 | </div> |
| 69 | - <div style="width: 100%;margin-bottom:20px;"> | |
| 73 | + <TitleWithCircle title="商铺/广告位意向统计" style="margin: 20px 0;" /> | |
| 74 | + <div style="width: 100%;"> | |
| 70 | 75 | <div style="display:flex;justify-content: space-between"> |
| 71 | 76 | <div style="display:flex;"> |
| 72 | - <div style="margin-right: 10px;line-height:35px;">商铺/广告位意向统计</div> | |
| 77 | + <!-- <div style="margin-right: 10px;line-height:35px;">商铺/广告位意向统计</div> --> | |
| 73 | 78 | <!-- <el-date-picker v-model="value1" type="datetimerange" range-separator="-" start-placeholder="开始日期" |
| 74 | 79 | end-placeholder="结束日期" style="width: 200px;margin-right: 10px;margin-top:0px;" prefix-icon="none"> |
| 75 | 80 | </el-date-picker> |
| ... | ... | @@ -130,7 +135,7 @@ |
| 130 | 135 | </div> |
| 131 | 136 | </div> |
| 132 | 137 | <div style="display:flex;margin-top:10px;"> |
| 133 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 138 | + <div style="width:48%;height: 400px;"> | |
| 134 | 139 | <div style="display: flex;justify-content: space-between;"> |
| 135 | 140 | <div style="line-height:35px;">经营趋势统计</div> |
| 136 | 141 | <div> |
| ... | ... | @@ -142,7 +147,7 @@ |
| 142 | 147 | </div> |
| 143 | 148 | <div ref="shop3ZX" style="width:100%;height: 400px;"></div> |
| 144 | 149 | </div> |
| 145 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 150 | + <div style="width:48%;height: 400px;"> | |
| 146 | 151 | <div style="display: flex;justify-content: space-between;"> |
| 147 | 152 | <div style="line-height:35px;">营业收入情况</div> |
| 148 | 153 | <div> |
| ... | ... | @@ -238,7 +243,7 @@ |
| 238 | 243 | </div> |
| 239 | 244 | </div> |
| 240 | 245 | <div style="display:flex;margin-top:10px;"> |
| 241 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 246 | + <div style="width:48%;height: 400px;"> | |
| 242 | 247 | <div style="display: flex;justify-content: space-between;"> |
| 243 | 248 | <div style="line-height:35px;">租赁趋势统计</div> |
| 244 | 249 | <div> |
| ... | ... | @@ -250,7 +255,7 @@ |
| 250 | 255 | </div> |
| 251 | 256 | <div ref="shop4ZX" style="width:100%;height: 400px;"></div> |
| 252 | 257 | </div> |
| 253 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 258 | + <div style="width:48%;height: 400px;"> | |
| 254 | 259 | <div style="display: flex;justify-content: space-between;"> |
| 255 | 260 | <div style="line-height:35px;">租赁商户top5</div> |
| 256 | 261 | <div> |
| ... | ... | @@ -264,11 +269,11 @@ |
| 264 | 269 | </div> |
| 265 | 270 | </div> |
| 266 | 271 | </div> --> |
| 267 | - | |
| 268 | - <div style="width: 100%;margin-bottom:20px;"> | |
| 272 | + <TitleWithCircle title="合同情况统计" style="margin: 20px 0;" /> | |
| 273 | + <div style="width: 100%;"> | |
| 269 | 274 | <div style="display:flex;justify-content: space-between"> |
| 270 | 275 | <div style="display:flex;"> |
| 271 | - <div style="margin-right: 10px;line-height:35px;">合同情况统计</div> | |
| 276 | + <!-- <div style="margin-right: 10px;line-height:35px;">合同情况统计</div> --> | |
| 272 | 277 | <!-- <el-select v-model="formSel.createDate" placeholder="所属区域" style="width: 150px;margin-right: 10px"> |
| 273 | 278 | <el-option label="1" value="1" /> |
| 274 | 279 | <el-option label="2" value="2" /> |
| ... | ... | @@ -292,7 +297,7 @@ |
| 292 | 297 | </div> --> |
| 293 | 298 | </div> |
| 294 | 299 | <div style="display:flex;margin-top:10px;"> |
| 295 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 300 | + <div style="width:48%;height: 400px;"> | |
| 296 | 301 | <div style="display: flex;justify-content: space-between;"> |
| 297 | 302 | <div style="line-height:35px;">合同签约数量趋势</div> |
| 298 | 303 | <!-- <div> |
| ... | ... | @@ -304,7 +309,7 @@ |
| 304 | 309 | </div> |
| 305 | 310 | <div ref="shop5ZX" style="width:100%;height: 400px;"></div> |
| 306 | 311 | </div> |
| 307 | - <div style="width:48%;height: 400px;marigin-right:20px;"> | |
| 312 | + <div style="width:48%;height: 400px;"> | |
| 308 | 313 | <div style="display: flex;justify-content: space-between;"> |
| 309 | 314 | <div style="line-height:35px;">签约数量占比</div> |
| 310 | 315 | <!-- <div> |
| ... | ... | @@ -318,18 +323,27 @@ |
| 318 | 323 | </div> |
| 319 | 324 | </div> |
| 320 | 325 | </div> |
| 321 | - | |
| 326 | + </div> | |
| 322 | 327 | </div> |
| 323 | 328 | |
| 324 | 329 | </div> |
| 325 | 330 | </template> |
| 326 | 331 | |
| 327 | 332 | <script> |
| 333 | + import html2canvas from 'html2canvas' | |
| 334 | + import jsPDF from 'jspdf' | |
| 335 | + import TitleWithCircle from '@/components/top/index'; | |
| 328 | 336 | import { |
| 329 | 337 | statistical, |
| 330 | 338 | } from '@/api/information' |
| 331 | 339 | import * as echarts from 'echarts' |
| 340 | + import { | |
| 341 | + async | |
| 342 | + } from 'q'; | |
| 332 | 343 | export default { |
| 344 | + components: { | |
| 345 | + TitleWithCircle, | |
| 346 | + }, | |
| 333 | 347 | name: 'atmosphereGl', |
| 334 | 348 | data() { |
| 335 | 349 | return { |
| ... | ... | @@ -339,10 +353,10 @@ |
| 339 | 353 | flag: false, |
| 340 | 354 | pageSize: 10, |
| 341 | 355 | tableData: [], |
| 342 | - FormTime:[], | |
| 356 | + FormTime: [], | |
| 343 | 357 | pageindex: { |
| 344 | - startTime: "1990-09-11", | |
| 345 | - endTime: "2024-11-09" | |
| 358 | + startTime: "1990-09-11", | |
| 359 | + endTime: "2024-11-09" | |
| 346 | 360 | }, |
| 347 | 361 | formSel: { |
| 348 | 362 | |
| ... | ... | @@ -359,8 +373,8 @@ |
| 359 | 373 | this.pageindex.startTime = monthAgo.toISOString().slice(0, 10); |
| 360 | 374 | this.pageindex.endTime = today.toISOString().slice(0, 10); |
| 361 | 375 | this.FormTime = [ |
| 362 | - this.pageindex.startTime, | |
| 363 | - this.pageindex.endTime | |
| 376 | + this.pageindex.startTime, | |
| 377 | + this.pageindex.endTime | |
| 364 | 378 | ] |
| 365 | 379 | console.error(this.pageindex) |
| 366 | 380 | this.getAll() |
| ... | ... | @@ -391,7 +405,7 @@ |
| 391 | 405 | tooltip: {}, |
| 392 | 406 | xAxis: { |
| 393 | 407 | type: 'category', |
| 394 | - data:processedData.map(item => item.name), | |
| 408 | + data: processedData.map(item => item.name), | |
| 395 | 409 | }, |
| 396 | 410 | yAxis: { |
| 397 | 411 | type: 'value', |
| ... | ... | @@ -407,8 +421,7 @@ |
| 407 | 421 | type: 'bar', |
| 408 | 422 | color: '#3f9b6a', |
| 409 | 423 | data: processedData.map(item => item.value), |
| 410 | - } | |
| 411 | - ] | |
| 424 | + }] | |
| 412 | 425 | }; |
| 413 | 426 | option && myChart.setOption(option); |
| 414 | 427 | }, |
| ... | ... | @@ -420,11 +433,14 @@ |
| 420 | 433 | name: item.trendDate || '11', |
| 421 | 434 | value: item.trendQuantity |
| 422 | 435 | })) |
| 423 | - processedData.push({name:'',value:0}) | |
| 436 | + processedData.push({ | |
| 437 | + name: '', | |
| 438 | + value: 0 | |
| 439 | + }) | |
| 424 | 440 | let option = { |
| 425 | 441 | xAxis: { |
| 426 | 442 | type: 'category', |
| 427 | - data: ['商铺','场地','广告位'], | |
| 443 | + data: ['商铺', '场地', '广告位'], | |
| 428 | 444 | }, |
| 429 | 445 | yAxis: { |
| 430 | 446 | type: 'value', |
| ... | ... | @@ -489,7 +505,7 @@ |
| 489 | 505 | show: false |
| 490 | 506 | }, |
| 491 | 507 | color: ['#3f9b6a', 'rgb(61,182,211)'], |
| 492 | - data:processedData, | |
| 508 | + data: processedData, | |
| 493 | 509 | }] |
| 494 | 510 | } |
| 495 | 511 | option && myChart.setOption(option); |
| ... | ... | @@ -505,10 +521,10 @@ |
| 505 | 521 | let option = { |
| 506 | 522 | legend: {}, |
| 507 | 523 | tooltip: {}, |
| 508 | - xAxis: { | |
| 509 | - type: 'category', | |
| 510 | - data: ['商铺','场地','广告位'], | |
| 511 | - }, | |
| 524 | + xAxis: { | |
| 525 | + type: 'category', | |
| 526 | + data: ['商铺', '场地', '广告位'], | |
| 527 | + }, | |
| 512 | 528 | yAxis: { |
| 513 | 529 | type: 'value', |
| 514 | 530 | max: 50 |
| ... | ... | @@ -525,8 +541,7 @@ |
| 525 | 541 | color: '#3f9b6a', |
| 526 | 542 | data: processedData.map(item => item.value), |
| 527 | 543 | type: 'line' |
| 528 | - }, | |
| 529 | - ] | |
| 544 | + }, ] | |
| 530 | 545 | }; |
| 531 | 546 | option && myChart.setOption(option); |
| 532 | 547 | }, |
| ... | ... | @@ -607,7 +622,7 @@ |
| 607 | 622 | let option = { |
| 608 | 623 | xAxis: { |
| 609 | 624 | type: 'category', |
| 610 | - data:processedData.map(item => item.name), | |
| 625 | + data: processedData.map(item => item.name), | |
| 611 | 626 | }, |
| 612 | 627 | yAxis: { |
| 613 | 628 | type: 'value' |
| ... | ... | @@ -624,7 +639,7 @@ |
| 624 | 639 | color: '#3f9b6a', // 这里设置为红色 |
| 625 | 640 | width: 2, // 线条宽度 |
| 626 | 641 | }, |
| 627 | - data: processedData.map(item => item.value), | |
| 642 | + data: processedData.map(item => item.value), | |
| 628 | 643 | type: 'line' |
| 629 | 644 | }] |
| 630 | 645 | } |
| ... | ... | @@ -643,82 +658,80 @@ |
| 643 | 658 | |
| 644 | 659 | // processedData.push({name:'签约数',value:0}) |
| 645 | 660 | let option = { |
| 646 | - tooltip: { | |
| 647 | - trigger: 'item' | |
| 648 | - }, | |
| 649 | - legend: { | |
| 650 | - top: '5%', | |
| 651 | - left: 'center' | |
| 652 | - }, | |
| 653 | - series: [ | |
| 654 | - { | |
| 655 | - type: 'pie', | |
| 656 | - radius: ['40%', '70%'], | |
| 657 | - avoidLabelOverlap: false, | |
| 658 | - itemStyle: { | |
| 659 | - borderRadius: 10, | |
| 660 | - borderColor: '#fff', | |
| 661 | - borderWidth: 2 | |
| 662 | - }, | |
| 663 | - label: { | |
| 664 | - show: false, | |
| 665 | - position: 'center' | |
| 666 | - }, | |
| 667 | - emphasis: { | |
| 668 | - label: { | |
| 669 | - show: true, | |
| 670 | - fontSize: 40, | |
| 671 | - fontWeight: 'bold' | |
| 661 | + tooltip: { | |
| 662 | + trigger: 'item' | |
| 663 | + }, | |
| 664 | + legend: { | |
| 665 | + top: '5%', | |
| 666 | + left: 'center' | |
| 667 | + }, | |
| 668 | + series: [{ | |
| 669 | + type: 'pie', | |
| 670 | + radius: ['40%', '70%'], | |
| 671 | + avoidLabelOverlap: false, | |
| 672 | + itemStyle: { | |
| 673 | + borderRadius: 10, | |
| 674 | + borderColor: '#fff', | |
| 675 | + borderWidth: 2 | |
| 676 | + }, | |
| 677 | + label: { | |
| 678 | + show: false, | |
| 679 | + position: 'center' | |
| 680 | + }, | |
| 681 | + emphasis: { | |
| 682 | + label: { | |
| 683 | + show: true, | |
| 684 | + fontSize: 40, | |
| 685 | + fontWeight: 'bold' | |
| 686 | + } | |
| 687 | + }, | |
| 688 | + labelLine: { | |
| 689 | + show: false | |
| 690 | + }, | |
| 691 | + data: processedData | |
| 692 | + }] | |
| 672 | 693 | } |
| 673 | - }, | |
| 674 | - labelLine: { | |
| 675 | - show: false | |
| 676 | - }, | |
| 677 | - data:processedData | |
| 678 | - } | |
| 679 | - ] | |
| 680 | -} | |
| 681 | 694 | option && myChart.setOption(option); |
| 682 | 695 | }, |
| 683 | 696 | |
| 684 | -// charDam9(){ | |
| 685 | - | |
| 686 | -// let Dom = this.$refs.shop3TJ | |
| 687 | -// let myChart = echarts.init(Dom); | |
| 688 | -// let option = { | |
| 689 | -// tooltip: { | |
| 690 | -// trigger: 'axis', | |
| 691 | -// axisPointer: { | |
| 692 | -// type: 'shadow' | |
| 693 | -// } | |
| 694 | -// }, | |
| 695 | -// grid: { | |
| 696 | -// left: '3%', | |
| 697 | -// right: '4%', | |
| 698 | -// bottom: '3%', | |
| 699 | -// containLabel: true | |
| 700 | -// }, | |
| 701 | -// xAxis: { | |
| 702 | -// type: 'value', | |
| 703 | -// boundaryGap: [0, 0.01] | |
| 704 | -// }, | |
| 705 | -// yAxis: { | |
| 706 | -// type: 'category', | |
| 707 | -// data: ['商户A', '商户B', '商户C', '商户D', '商户E', ] | |
| 708 | -// }, | |
| 709 | -// series: [{ | |
| 710 | -// lineStyle: { | |
| 711 | -// color: '#3f9b6a', // 这里设置为红色 | |
| 712 | -// width: 2, // 线条宽度 | |
| 713 | -// }, | |
| 714 | -// name: '2011', | |
| 715 | -// type: 'bar', | |
| 716 | -// data: [1, 2, 3, 4, 5, 10] | |
| 717 | -// }] | |
| 718 | -// }; | |
| 719 | -// option && myChart.setOption(option); | |
| 720 | - | |
| 721 | -// }, | |
| 697 | + // charDam9(){ | |
| 698 | + | |
| 699 | + // let Dom = this.$refs.shop3TJ | |
| 700 | + // let myChart = echarts.init(Dom); | |
| 701 | + // let option = { | |
| 702 | + // tooltip: { | |
| 703 | + // trigger: 'axis', | |
| 704 | + // axisPointer: { | |
| 705 | + // type: 'shadow' | |
| 706 | + // } | |
| 707 | + // }, | |
| 708 | + // grid: { | |
| 709 | + // left: '3%', | |
| 710 | + // right: '4%', | |
| 711 | + // bottom: '3%', | |
| 712 | + // containLabel: true | |
| 713 | + // }, | |
| 714 | + // xAxis: { | |
| 715 | + // type: 'value', | |
| 716 | + // boundaryGap: [0, 0.01] | |
| 717 | + // }, | |
| 718 | + // yAxis: { | |
| 719 | + // type: 'category', | |
| 720 | + // data: ['商户A', '商户B', '商户C', '商户D', '商户E', ] | |
| 721 | + // }, | |
| 722 | + // series: [{ | |
| 723 | + // lineStyle: { | |
| 724 | + // color: '#3f9b6a', // 这里设置为红色 | |
| 725 | + // width: 2, // 线条宽度 | |
| 726 | + // }, | |
| 727 | + // name: '2011', | |
| 728 | + // type: 'bar', | |
| 729 | + // data: [1, 2, 3, 4, 5, 10] | |
| 730 | + // }] | |
| 731 | + // }; | |
| 732 | + // option && myChart.setOption(option); | |
| 733 | + | |
| 734 | + // }, | |
| 722 | 735 | |
| 723 | 736 | async getAll() { |
| 724 | 737 | const res = await statistical(this.pageindex) |
| ... | ... | @@ -728,10 +741,10 @@ |
| 728 | 741 | this.charDam6(res.data.contractTrend) |
| 729 | 742 | |
| 730 | 743 | this.charDam7(res.data.basicQueryTrends) |
| 731 | - let trends=[...res.data.shopTrend,...res.data.venueTrend,...res.data.advertisingTrend] | |
| 744 | + let trends = [...res.data.shopTrend, ...res.data.venueTrend, ...res.data.advertisingTrend] | |
| 732 | 745 | |
| 733 | 746 | this.charDam1(trends) |
| 734 | - this.charDam3(trends) | |
| 747 | + this.charDam3(trends) | |
| 735 | 748 | }, |
| 736 | 749 | handleSizeChange() { |
| 737 | 750 | |
| ... | ... | @@ -739,29 +752,56 @@ |
| 739 | 752 | handleCurrentChange() { |
| 740 | 753 | |
| 741 | 754 | }, |
| 742 | - resetting(){ | |
| 743 | - this.FormTime = [] | |
| 744 | - this.getAll() | |
| 755 | + resetting() { | |
| 756 | + let today = new Date(); | |
| 757 | + let monthAgo = new Date(); | |
| 758 | + monthAgo.setMonth(monthAgo.getMonth() - 1); | |
| 759 | + monthAgo.setDate(monthAgo.getDate() + 1); | |
| 760 | + this.pageindex.startTime = monthAgo.toISOString().slice(0, 10); | |
| 761 | + this.pageindex.endTime = today.toISOString().slice(0, 10); | |
| 762 | + this.FormTime = [ | |
| 763 | + this.pageindex.startTime, | |
| 764 | + this.pageindex.endTime | |
| 765 | + ] | |
| 766 | + this.getAll() | |
| 745 | 767 | }, |
| 746 | - async onSubmit(){ | |
| 768 | + async onSubmit() { | |
| 747 | 769 | |
| 748 | - let Msg ={ | |
| 770 | + let Msg = { | |
| 749 | 771 | startTime: this.FormTime[0], |
| 750 | - endTime:this.FormTime[1] | |
| 772 | + endTime: this.FormTime[1] | |
| 751 | 773 | } |
| 752 | 774 | const res = await statistical(Msg) |
| 753 | 775 | this.charDam(res.data.seekingIntentionStatistics) |
| 754 | 776 | this.charDam2(res.data.seekingIntentionStatistics) |
| 755 | 777 | this.charDam6(res.data.contractTrend) |
| 756 | -this.charDam7(res.data.basicQueryTrends) | |
| 757 | - let trends=[...res.data.shopTrend,...res.data.venueTrend,...res.data.advertisingTrend] | |
| 778 | + this.charDam7(res.data.basicQueryTrends) | |
| 779 | + let trends = [...res.data.shopTrend, ...res.data.venueTrend, ...res.data.advertisingTrend] | |
| 758 | 780 | |
| 759 | 781 | this.charDam1(trends) |
| 760 | - this.charDam3(trends) | |
| 782 | + this.charDam3(trends) | |
| 761 | 783 | |
| 762 | 784 | }, |
| 763 | - gitOut(){ | |
| 785 | + async gitOut() { | |
| 786 | + const content = this.$refs.contentToConvert; | |
| 787 | + | |
| 788 | + // 使用 html2canvas 将 div 渲染为画布 | |
| 789 | + const canvas = await html2canvas(content); | |
| 764 | 790 | |
| 791 | + // 获取画布的图像数据 | |
| 792 | + const imgData = canvas.toDataURL('image/png'); | |
| 793 | + | |
| 794 | + // 创建一个新的 PDF 文档 | |
| 795 | + const pdf = new jsPDF('p', 'mm', 'a4'); | |
| 796 | + | |
| 797 | + // 添加图像到 PDF,第二个参数是图像格式,第三个参数是缩放比例 | |
| 798 | + const imgWidth = 190; // 图像的宽度(mm) | |
| 799 | + const imgHeight = (canvas.height * imgWidth) / canvas.width; // 保持图像的宽高比 | |
| 800 | + | |
| 801 | + pdf.addImage(imgData, 'PNG', 10, 10, imgWidth, imgHeight); // 10, 10 是图像在 PDF 中的位置(mm) | |
| 802 | + | |
| 803 | + // 保存 PDF 文件 | |
| 804 | + pdf.save('downloaded.pdf'); | |
| 765 | 805 | }, |
| 766 | 806 | } |
| 767 | 807 | } |
| ... | ... | @@ -779,7 +819,7 @@ this.charDam7(res.data.basicQueryTrends) |
| 779 | 819 | line-height: 0; |
| 780 | 820 | } |
| 781 | 821 | |
| 782 | - | |
| 822 | + | |
| 783 | 823 | |
| 784 | 824 | .formSearch { |
| 785 | 825 | position: relative; | ... | ... |
admin-web-master/src/views/detect/examine/index.vue
| 1 | 1 | <template> |
| 2 | - <div style="background-color:#f7f7f7;padding:10px 10px;"> | |
| 3 | - <div class="zhuti" v-if="onaction == '1'"> | |
| 2 | + <div style="background-color:#f7f7f7;padding:10px 10px;" > | |
| 3 | + <div class="zhuti boxqw" v-if="onaction == '1'"> | |
| 4 | 4 | <div style="height:58px;line-height:58px;"> |
| 5 | 5 | <div style="color:#0006"> <span>招商资源监测</span> <span style="padding:0 5px;">></span> <span |
| 6 | 6 | style="color:#000000e6">资源发布审核</span></div> |
| ... | ... | @@ -42,7 +42,7 @@ |
| 42 | 42 | </div> |
| 43 | 43 | </div> |
| 44 | 44 | <!-- 表格 --> |
| 45 | - <el-table v-if="ontype=='1'" :span-method="tableSpanMethod" :data="tableData" | |
| 45 | + <el-table v-if="ontype=='1' && ishow" :span-method="tableSpanMethod" :data="tableData" | |
| 46 | 46 | :header-cell-style="{fontSize: '14px',color:'#0009',fontWeight: 'normal',backgroundColor:'#F2F3F5'}"> |
| 47 | 47 | <el-table-column label="商铺名称" prop="shopName" show-overflow-tooltip> |
| 48 | 48 | <template slot-scope="scope"> |
| ... | ... | @@ -89,7 +89,7 @@ |
| 89 | 89 | </template> |
| 90 | 90 | </el-table-column> |
| 91 | 91 | </el-table> |
| 92 | - <el-table v-if="ontype=='2'" :span-method="tableSpanMethod" :data="tableData" | |
| 92 | + <el-table v-if="ontype=='2' && ishow" :span-method="tableSpanMethod" :data="tableData" | |
| 93 | 93 | :header-cell-style="{fontSize: '14px',color:'#0009',fontWeight: 'normal',backgroundColor:'#F2F3F5'}"> |
| 94 | 94 | <el-table-column label="广告位名称" prop="advertisingName" show-overflow-tooltip> |
| 95 | 95 | <template slot-scope="scope"> |
| ... | ... | @@ -134,7 +134,7 @@ |
| 134 | 134 | </template> |
| 135 | 135 | </el-table-column> |
| 136 | 136 | </el-table> |
| 137 | - <el-table v-if="ontype=='3'" :span-method="tableSpanMethod" :data="tableData" | |
| 137 | + <el-table v-if="ontype=='3' && ishow" :span-method="tableSpanMethod" :data="tableData" | |
| 138 | 138 | :header-cell-style="{fontSize: '14px',color:'#0009',fontWeight: 'normal',backgroundColor:'#F2F3F5'}"> |
| 139 | 139 | <el-table-column label="场地名称" prop="venueName" show-overflow-tooltip> |
| 140 | 140 | <template slot-scope="scope"> |
| ... | ... | @@ -297,6 +297,7 @@ |
| 297 | 297 | export default { |
| 298 | 298 | data() { |
| 299 | 299 | return { |
| 300 | + ishow:true, | |
| 300 | 301 | issp: '1', |
| 301 | 302 | publishStatus: '', |
| 302 | 303 | clName: '', |
| ... | ... | @@ -536,6 +537,12 @@ |
| 536 | 537 | this.onaction = '4' |
| 537 | 538 | }, |
| 538 | 539 | async getAll() { |
| 540 | + this.ishow = false | |
| 541 | + const loading = this.$loading({ | |
| 542 | + target: document.querySelector('.boxqw'), | |
| 543 | + fullscreen: true | |
| 544 | + }) | |
| 545 | + | |
| 539 | 546 | this.tableData = [] |
| 540 | 547 | let list = [] |
| 541 | 548 | if (this.ontype == '1') { |
| ... | ... | @@ -556,7 +563,7 @@ |
| 556 | 563 | cereBasicInformationShop: element.cereBasicInformationShop, |
| 557 | 564 | num: element.cereRentalPolicies.length, |
| 558 | 565 | shopinfo: element1, |
| 559 | - typeid:'sp'+element.cereBasicInformationShop.id | |
| 566 | + typeid:'sp'+element.cereBasicInformationShop.id, | |
| 560 | 567 | }; |
| 561 | 568 | c1.push(obj); |
| 562 | 569 | } |
| ... | ... | @@ -694,9 +701,14 @@ |
| 694 | 701 | // } |
| 695 | 702 | list = [...list, ...c2] |
| 696 | 703 | this.tableData = list |
| 704 | + | |
| 697 | 705 | console.log(this.tableData); |
| 698 | 706 | } |
| 699 | - | |
| 707 | + setTimeout(() => { | |
| 708 | + this.ishow = true | |
| 709 | + loading.close(); | |
| 710 | + this.$forceUpdate(); | |
| 711 | + }, 100) | |
| 700 | 712 | }, |
| 701 | 713 | removeonaction(e) { |
| 702 | 714 | console.error(e) | ... | ... |