Merge branch 'develop' into release-test
Showing
3 changed files
with
69 additions
and
50 deletions
| ... | @@ -89,3 +89,26 @@ export const setFileName = (name) => { | ... | @@ -89,3 +89,26 @@ export const setFileName = (name) => { |
| 89 | return name || '--'; | 89 | return name || '--'; |
| 90 | } | 90 | } |
| 91 | } | 91 | } |
| 92 | |||
| 93 | // 已任意长度分割数组 | ||
| 94 | export const chunk = (array, size) => { | ||
| 95 | //获取数组的长度,如果你传入的不是数组,那么获取到的就是undefined | ||
| 96 | const length = array.length; | ||
| 97 | //判断不是数组,或者size没有设置,size小于1,就返回空数组 | ||
| 98 | if (!length || !size || size < 1) { | ||
| 99 | return []; | ||
| 100 | } | ||
| 101 | //核心部分 | ||
| 102 | var index = 0; //用来表示切割元素的范围start | ||
| 103 | var resIndex = 0; //用来递增表示输出数组的下标 | ||
| 104 | |||
| 105 | //根据length和size算出输出数组的长度,并且创建它。 | ||
| 106 | var result = new Array(Math.ceil(length / size)); | ||
| 107 | //进行循环 | ||
| 108 | while (index < length) { | ||
| 109 | //循环过程中设置result[0]和result[1]的值。该值根据array.slice切割得到。 | ||
| 110 | result[resIndex++] = array.slice(index, (index += size)); | ||
| 111 | } | ||
| 112 | //输出新数组 | ||
| 113 | return result; | ||
| 114 | } | ... | ... |
| ... | @@ -1360,7 +1360,7 @@ const formattedDate = (dateVal) => { | ... | @@ -1360,7 +1360,7 @@ const formattedDate = (dateVal) => { |
| 1360 | </div> | 1360 | </div> |
| 1361 | </span> | 1361 | </span> |
| 1362 | </div> | 1362 | </div> |
| 1363 | <div class="list_item is_block isFile" :style="{ width: '40%' }" | 1363 | <div class="list_item is_block isFile" :style="{ width: '40%', 'margin-right': '28px' }" |
| 1364 | v-if="((detailType != 'asset' || assetDetailInfo.isEvaluationAssessment == 'Y') && assetDetailInfo.registerAttachment?.qualityEvaluationFile?.length) || (evaDetailInfo?.qualityEvaluationFile?.length > 0)"> | 1364 | v-if="((detailType != 'asset' || assetDetailInfo.isEvaluationAssessment == 'Y') && assetDetailInfo.registerAttachment?.qualityEvaluationFile?.length) || (evaDetailInfo?.qualityEvaluationFile?.length > 0)"> |
| 1365 | <span class="item_label" :style="{ width: 'auto', 'text-align': 'left' }">数据质量评价收集</span> | 1365 | <span class="item_label" :style="{ width: 'auto', 'text-align': 'left' }">数据质量评价收集</span> |
| 1366 | <span | 1366 | <span |
| ... | @@ -1475,7 +1475,7 @@ const formattedDate = (dateVal) => { | ... | @@ -1475,7 +1475,7 @@ const formattedDate = (dateVal) => { |
| 1475 | </div> | 1475 | </div> |
| 1476 | </span> | 1476 | </span> |
| 1477 | </div> | 1477 | </div> |
| 1478 | <div class="list_item is_block isFile" :style="{ width: '40%' }" | 1478 | <div class="list_item is_block isFile" :style="{ width: '40%', 'margin-right': '28px' }" |
| 1479 | v-if="(detailType == 'asset' && assetDetailInfo.isQualityAssessment == 'Y') && assetDetailInfo.registerAttachment?.evaluationFile?.length"> | 1479 | v-if="(detailType == 'asset' && assetDetailInfo.isQualityAssessment == 'Y') && assetDetailInfo.registerAttachment?.evaluationFile?.length"> |
| 1480 | <span class="item_label" :style="{ width: 'auto', 'text-align': 'left' }">质量评估报告</span> | 1480 | <span class="item_label" :style="{ width: 'auto', 'text-align': 'left' }">质量评估报告</span> |
| 1481 | <span v-for="(item) in (assetDetailInfo.registerAttachment?.evaluationFile || [])" class="item_value" | 1481 | <span v-for="(item) in (assetDetailInfo.registerAttachment?.evaluationFile || [])" class="item_value" |
| ... | @@ -1592,7 +1592,7 @@ const formattedDate = (dateVal) => { | ... | @@ -1592,7 +1592,7 @@ const formattedDate = (dateVal) => { |
| 1592 | <!-- <span | 1592 | <!-- <span |
| 1593 | v-if="tenantDetail.businessLicense?.length || assetDetailInfo.registerAttachment?.commitmentLetter?.length" | 1593 | v-if="tenantDetail.businessLicense?.length || assetDetailInfo.registerAttachment?.commitmentLetter?.length" |
| 1594 | class="small-title" :style="{ marginTop: '10px' }">公司信息</span> --> | 1594 | class="small-title" :style="{ marginTop: '10px' }">公司信息</span> --> |
| 1595 | <div class="list_item is_block isFile" :style="{ width: '40%' }" | 1595 | <div class="list_item is_block isFile" :style="{ width: '40%', 'margin-right': '28px' }" |
| 1596 | v-if="tenantDetail.businessLicense?.length"> | 1596 | v-if="tenantDetail.businessLicense?.length"> |
| 1597 | <span class="item_label" :style="{ width: 'auto', 'text-align': 'left' }">营业执照</span> | 1597 | <span class="item_label" :style="{ width: 'auto', 'text-align': 'left' }">营业执照</span> |
| 1598 | <span v-for="(item) in (tenantDetail?.businessLicense || [])" class="item_value" | 1598 | <span v-for="(item) in (tenantDetail?.businessLicense || [])" class="item_value" | ... | ... |
| ... | @@ -9,7 +9,8 @@ import { ElMessage, ElMessageBox } from 'element-plus'; | ... | @@ -9,7 +9,8 @@ import { ElMessage, ElMessageBox } from 'element-plus'; |
| 9 | import { CarouselPanel } from '@/components/CarouselPanel'; | 9 | import { CarouselPanel } from '@/components/CarouselPanel'; |
| 10 | import { useRouter, useRoute } from "vue-router"; | 10 | import { useRouter, useRoute } from "vue-router"; |
| 11 | import { MoreFilled } from "@element-plus/icons-vue"; | 11 | import { MoreFilled } from "@element-plus/icons-vue"; |
| 12 | import { changeNum, tagMethod, tagType, } from "@/utils/common"; | 12 | import { changeNum } from "@/utils/common"; |
| 13 | import { chunk } from "@/api/modules/common"; | ||
| 13 | import { getRegisterList, registerDelete, getExchangeList } from "@/api/modules/dataAsset"; | 14 | import { getRegisterList, registerDelete, getExchangeList } from "@/api/modules/dataAsset"; |
| 14 | import { passFlowData, rejectFlowData, revokeFlowData } from "@/api/modules/workFlowService"; | 15 | import { passFlowData, rejectFlowData, revokeFlowData } from "@/api/modules/workFlowService"; |
| 15 | import useDataAssetStore from "@/store/modules/dataAsset"; | 16 | import useDataAssetStore from "@/store/modules/dataAsset"; |
| ... | @@ -29,7 +30,7 @@ const loading = ref(false); | ... | @@ -29,7 +30,7 @@ const loading = ref(false); |
| 29 | const defaultItemLogo = new URL('@/assets/images/home-finance-product.png', import.meta.url).href | 30 | const defaultItemLogo = new URL('@/assets/images/home-finance-product.png', import.meta.url).href |
| 30 | const carouselInfo: any = ref({ | 31 | const carouselInfo: any = ref({ |
| 31 | list: [], | 32 | list: [], |
| 32 | height: '176px', | 33 | height: '172px', |
| 33 | loop: false, | 34 | loop: false, |
| 34 | autoplay: false, | 35 | autoplay: false, |
| 35 | arrow: 'hover', | 36 | arrow: 'hover', |
| ... | @@ -344,9 +345,7 @@ const getExchangeData = () => { | ... | @@ -344,9 +345,7 @@ const getExchangeData = () => { |
| 344 | getExchangeList().then((res: any) => { | 345 | getExchangeList().then((res: any) => { |
| 345 | if (res.code == proxy.$passCode) { | 346 | if (res.code == proxy.$passCode) { |
| 346 | const data = res.data || []; | 347 | const data = res.data || []; |
| 347 | while (data.length) { | 348 | exchangeList.value = chunk(data, 4); |
| 348 | exchangeList.value.push(data.splice(0, 4)); | ||
| 349 | } | ||
| 350 | carouselInfo.value.list = exchangeList.value; | 349 | carouselInfo.value.list = exchangeList.value; |
| 351 | carouselInfo.value.arrow = exchangeList.value.length > 1 ? 'hover' : 'never'; | 350 | carouselInfo.value.arrow = exchangeList.value.length > 1 ? 'hover' : 'never'; |
| 352 | } else { | 351 | } else { |
| ... | @@ -538,13 +537,13 @@ const rejectDialogBtnClick = (btn, info) => { | ... | @@ -538,13 +537,13 @@ const rejectDialogBtnClick = (btn, info) => { |
| 538 | <CarouselPanel :carousel-info="carouselInfo"> | 537 | <CarouselPanel :carousel-info="carouselInfo"> |
| 539 | <template v-slot:default="{ carousel }"> | 538 | <template v-slot:default="{ carousel }"> |
| 540 | <div class="card-content" v-for="(item, i) in carousel" :key="'item-' + i" | 539 | <div class="card-content" v-for="(item, i) in carousel" :key="'item-' + i" |
| 541 | :class="{ active: exchangGuid == item.exchangeGuid, mr8: i < carousel.length - 1 && (i + 1) % 4 !== 0 }"> | 540 | :class="{ active: exchangGuid == item.exchangeGuid, mr16: i < carousel.length - 1 && (i + 1) % 4 !== 0 }" |
| 542 | <div class="header"> | 541 | @click="btnClick({ value: 'search', ...item })" v-preReClick> |
| 542 | <div class="title" :class="{ active: exchangGuid == item.exchangeGuid }"> | ||
| 543 | <img class="left-img" | 543 | <img class="left-img" |
| 544 | :src="(item.picUrl && typeof item.picUrl == 'string') ? item.picUrl : defaultItemLogo" alt="" /> | 544 | :src="(item.picUrl && typeof item.picUrl == 'string') ? item.picUrl : defaultItemLogo" alt="" /> |
| 545 | <div class="right-main"> | 545 | <span>{{ item.exchangeName ?? '--' }}</span> |
| 546 | <div class="title" :class="{ active: exchangGuid == item.exchangeGuid }" | 546 | </div> |
| 547 | @click="btnClick({ value: 'search', ...item })" v-preReClick>{{ item.exchangeName ?? '--' }}</div> | ||
| 548 | <div class="count-group"> | 547 | <div class="count-group"> |
| 549 | <div class="count-item"> | 548 | <div class="count-item"> |
| 550 | <div class="item-label">已登记产品数</div> | 549 | <div class="item-label">已登记产品数</div> |
| ... | @@ -555,11 +554,9 @@ const rejectDialogBtnClick = (btn, info) => { | ... | @@ -555,11 +554,9 @@ const rejectDialogBtnClick = (btn, info) => { |
| 555 | <div class="item-num">{{ changeNum(item.underReviewNum || 0) }}</div> | 554 | <div class="item-num">{{ changeNum(item.underReviewNum || 0) }}</div> |
| 556 | </div> | 555 | </div> |
| 557 | </div> | 556 | </div> |
| 558 | </div> | ||
| 559 | </div> | ||
| 560 | <div class="operator-btn"> | 557 | <div class="operator-btn"> |
| 561 | <!-- <div class="left-btn borderRight" @click="btnClick(item)">更新模板</div> --> | 558 | <!-- <div class="left-btn borderRight" @click.stop="btnClick(item)">更新模板</div> --> |
| 562 | <div class="left-btn is_block" @click="btnClick({ value: 'create', ...item })">资产登记</div> | 559 | <div class="left-btn is_block" @click.stop="btnClick({ value: 'create', ...item })">资产登记</div> |
| 563 | </div> | 560 | </div> |
| 564 | </div> | 561 | </div> |
| 565 | </template> | 562 | </template> |
| ... | @@ -590,7 +587,7 @@ const rejectDialogBtnClick = (btn, info) => { | ... | @@ -590,7 +587,7 @@ const rejectDialogBtnClick = (btn, info) => { |
| 590 | } | 587 | } |
| 591 | 588 | ||
| 592 | .table_panel_wrap { | 589 | .table_panel_wrap { |
| 593 | height: calc(100% - 176px); | 590 | height: calc(100% - 188px); |
| 594 | } | 591 | } |
| 595 | } | 592 | } |
| 596 | 593 | ||
| ... | @@ -661,7 +658,7 @@ const rejectDialogBtnClick = (btn, info) => { | ... | @@ -661,7 +658,7 @@ const rejectDialogBtnClick = (btn, info) => { |
| 661 | width: 22%; | 658 | width: 22%; |
| 662 | min-width: 220px; | 659 | min-width: 220px; |
| 663 | height: auto; | 660 | height: auto; |
| 664 | padding: 16px; | 661 | padding: 12px; |
| 665 | border: 1px solid var(--el-border-color-regular); | 662 | border: 1px solid var(--el-border-color-regular); |
| 666 | border-radius: 4px; | 663 | border-radius: 4px; |
| 667 | cursor: pointer; | 664 | cursor: pointer; |
| ... | @@ -731,76 +728,75 @@ const rejectDialogBtnClick = (btn, info) => { | ... | @@ -731,76 +728,75 @@ const rejectDialogBtnClick = (btn, info) => { |
| 731 | position: relative; | 728 | position: relative; |
| 732 | } | 729 | } |
| 733 | 730 | ||
| 734 | .list-content { | 731 | :deep(.el-carousel__container) { |
| 735 | width: 100%; | 732 | margin-bottom: 16px; |
| 736 | height: 176px; | ||
| 737 | overflow: hidden; | ||
| 738 | 733 | ||
| 739 | .card-content { | 734 | .card-content { |
| 740 | width: calc(25% - 6px); | 735 | width: calc(25% - 12px); |
| 741 | padding: 16px; | 736 | height: 100%; |
| 742 | margin-bottom: 8px; | 737 | margin-bottom: 8px; |
| 743 | min-width: 325px; | 738 | min-width: 325px; |
| 744 | max-width: 400px; | 739 | max-width: 400px; |
| 745 | border: 1px solid var(--el-border-color-regular); | 740 | border: 1px solid var(--el-border-color-regular); |
| 746 | float: left; | 741 | float: left; |
| 747 | 742 | ||
| 748 | &.active { | 743 | &:hover { |
| 749 | box-shadow: 0 0 0 1px var(--el-color-primary); | 744 | border-color: #44ABB4; |
| 750 | } | 745 | } |
| 751 | 746 | ||
| 752 | &.mr8 { | 747 | &.active { |
| 753 | margin-right: 8px; | 748 | border-color: #44ABB4; |
| 749 | background: #edf6f7; | ||
| 754 | } | 750 | } |
| 755 | 751 | ||
| 756 | .header { | 752 | &.mr16 { |
| 757 | display: flex; | 753 | margin-right: 16px; |
| 758 | margin-bottom: 16px; | 754 | } |
| 759 | 755 | ||
| 760 | img { | 756 | img { |
| 761 | width: 80px; | 757 | width: 20px; |
| 762 | margin-right: 16px; | 758 | margin-right: 16px; |
| 763 | } | 759 | } |
| 764 | 760 | ||
| 765 | .title { | 761 | .title { |
| 762 | height: 48px; | ||
| 763 | padding: 0 12px; | ||
| 766 | font-size: 16px; | 764 | font-size: 16px; |
| 767 | color: #212121; | 765 | color: #212121; |
| 768 | font-weight: 600; | 766 | font-weight: 600; |
| 769 | margin-bottom: 8px; | ||
| 770 | cursor: pointer; | 767 | cursor: pointer; |
| 771 | 768 | display: flex; | |
| 772 | &:hover, | 769 | align-items: center; |
| 773 | &.active { | ||
| 774 | color: var(--el-color-primary); | ||
| 775 | } | ||
| 776 | } | 770 | } |
| 777 | 771 | ||
| 778 | .right-main { | 772 | .count-group { |
| 779 | width: calc(100% - 96px); | 773 | height: 80px; |
| 780 | display: flex; | 774 | display: flex; |
| 781 | flex-direction: column; | ||
| 782 | justify-content: space-between; | 775 | justify-content: space-between; |
| 783 | 776 | ||
| 784 | .count-group { | 777 | .count-item { |
| 778 | width: 50%; | ||
| 779 | padding: 8px 0; | ||
| 785 | display: flex; | 780 | display: flex; |
| 786 | justify-content: space-between; | 781 | flex-direction: column; |
| 782 | align-items: center; | ||
| 783 | } | ||
| 787 | 784 | ||
| 788 | .item-num { | 785 | .item-num { |
| 786 | line-height: 36px; | ||
| 789 | font-size: 20px; | 787 | font-size: 20px; |
| 790 | font-weight: 600; | 788 | font-weight: 600; |
| 791 | color: #212121; | 789 | color: #44ABB4; |
| 792 | margin-top: 8px; | 790 | margin-top: 8px; |
| 793 | } | 791 | } |
| 794 | } | 792 | } |
| 795 | } | ||
| 796 | } | ||
| 797 | 793 | ||
| 798 | .operator-btn { | 794 | .operator-btn { |
| 799 | display: flex; | 795 | display: flex; |
| 800 | justify-content: space-between; | 796 | justify-content: space-between; |
| 801 | align-items: center; | 797 | align-items: center; |
| 802 | box-shadow: 0 0 0 1px #4fa1a4; | ||
| 803 | position: relative; | 798 | position: relative; |
| 799 | border-top: 1px solid #d9d9d9; | ||
| 804 | 800 | ||
| 805 | // &::after { | 801 | // &::after { |
| 806 | // content: ''; | 802 | // content: ''; |
| ... | @@ -817,8 +813,8 @@ const rejectDialogBtnClick = (btn, info) => { | ... | @@ -817,8 +813,8 @@ const rejectDialogBtnClick = (btn, info) => { |
| 817 | height: 40px; | 813 | height: 40px; |
| 818 | line-height: 40px; | 814 | line-height: 40px; |
| 819 | text-align: center; | 815 | text-align: center; |
| 820 | background: #4fa1a4; | 816 | background: #FAFAFA; |
| 821 | color: #fff; | 817 | color: #666; |
| 822 | cursor: pointer; | 818 | cursor: pointer; |
| 823 | 819 | ||
| 824 | &.is_block { | 820 | &.is_block { | ... | ... |
-
Please register or sign in to post a comment