Compare commits
17 Commits
e0660046c2
...
develop-20
| Author | SHA1 | Date | |
|---|---|---|---|
| 0e66e4765b | |||
| 83be612c27 | |||
| 604665cd71 | |||
| 105f15ae3c | |||
| 187c583291 | |||
| c196898fa2 | |||
| 676c93cc6b | |||
| bc2adcd8f2 | |||
|
|
9f9ed2dd73 | ||
|
|
2b10f1d563 | ||
|
|
0c4218ad93 | ||
| d5faa38c7e | |||
|
|
26ee0e00b0 | ||
|
|
64d9d6d1c3 | ||
|
|
f00ead8849 | ||
| 875f6713a7 | |||
| 7c4168a813 |
BIN
public/static/your-word-document.docx
Normal file
BIN
public/static/your-word-document.docx
Normal file
Binary file not shown.
5
src/assets/images/j-icon1.svg
Normal file
5
src/assets/images/j-icon1.svg
Normal file
@@ -0,0 +1,5 @@
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<rect x="1" y="1" width="14" height="14" rx="2" fill="#233A82"/>
|
||||
<path d="M10.6625 3.56079H5.26806C4.32646 3.56079 3.56006 4.32719 3.56006 5.26879V10.7288C3.56006 11.6704 4.32646 12.4368 5.26806 12.4368H10.6625C11.6041 12.4368 12.3705 11.6704 12.3705 10.7288V5.26879C12.3713 4.32719 11.6049 3.56079 10.6625 3.56079ZM6.07926 10.4432C5.42886 10.4432 4.89926 9.91359 4.89926 9.26319C4.89926 8.61279 5.42886 8.08319 6.07926 8.08319C6.72966 8.08319 7.25926 8.61279 7.25926 9.26319C7.25926 9.91439 6.72966 10.4432 6.07926 10.4432ZM7.43286 6.07519L6.25286 7.22159C6.17046 7.30159 6.06086 7.34639 5.94646 7.34639H5.93926C5.88126 7.34555 5.82401 7.33316 5.77085 7.30995C5.7177 7.28673 5.6697 7.25316 5.62966 7.21119L4.94006 6.49359C4.85925 6.4094 4.81513 6.29659 4.81738 6.17991C4.81963 6.06323 4.86806 5.95221 4.95206 5.87119C5.03625 5.79038 5.14906 5.74626 5.26574 5.74851C5.38242 5.75076 5.49344 5.79919 5.57446 5.88319L5.95766 6.28159L6.82006 5.44399C6.86149 5.40367 6.91046 5.37192 6.96417 5.35054C7.01788 5.32916 7.07528 5.31858 7.13308 5.31939C7.19089 5.32021 7.24796 5.33241 7.30105 5.3553C7.35413 5.37819 7.40218 5.41132 7.44246 5.45279C7.52325 5.53684 7.56757 5.6494 7.56577 5.76597C7.56397 5.88253 7.5162 5.99367 7.43286 6.07519ZM10.7977 9.78159H8.25446C7.98966 9.78159 7.77446 9.56639 7.77446 9.30159C7.77446 9.03679 7.98966 8.82159 8.25446 8.82159H10.7977C11.0625 8.82159 11.2777 9.03679 11.2777 9.30159C11.2777 9.56639 11.0625 9.78159 10.7977 9.78159ZM10.7977 6.90559H8.25446C7.98966 6.90559 7.77446 6.69039 7.77446 6.42559C7.77446 6.16079 7.98966 5.94559 8.25446 5.94559H10.7977C11.0625 5.94559 11.2777 6.16079 11.2777 6.42559C11.2777 6.69039 11.0625 6.90559 10.7977 6.90559Z" fill="white"/>
|
||||
<path d="M6.00159 8.87109C5.77919 8.87109 5.59839 9.05189 5.59839 9.27429C5.59839 9.49669 5.77919 9.67749 6.00159 9.67749C6.22399 9.67749 6.40479 9.49669 6.40479 9.27429C6.40479 9.05189 6.22399 8.87109 6.00159 8.87109Z" fill="white"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.0 KiB |
4
src/assets/images/j-icon2.svg
Normal file
4
src/assets/images/j-icon2.svg
Normal file
@@ -0,0 +1,4 @@
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<rect x="1" y="1" width="14" height="14" rx="2" fill="#3491FA"/>
|
||||
<path d="M7.99326 2.81006C5.13086 2.81006 2.81006 5.13086 2.81006 7.99326C2.81006 10.8557 5.13086 13.1765 7.99326 13.1765C10.8557 13.1765 13.1765 10.8557 13.1765 7.99326C13.1765 5.13086 10.8557 2.81006 7.99326 2.81006ZM10.0005 8.98046H7.54686C7.40873 8.98046 7.27627 8.92559 7.1786 8.82792C7.08093 8.73025 7.02606 8.59778 7.02606 8.45966V5.61166C7.02606 5.47353 7.08093 5.34107 7.1786 5.2434C7.27627 5.14573 7.40873 5.09086 7.54686 5.09086C7.68498 5.09086 7.81745 5.14573 7.91512 5.2434C8.01279 5.34107 8.06766 5.47353 8.06766 5.61166V7.93886H10.0005C10.1386 7.93886 10.2711 7.99373 10.3687 8.0914C10.4664 8.18907 10.5213 8.32153 10.5213 8.45966C10.5213 8.74766 10.2885 8.98046 10.0005 8.98046Z" fill="white"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 879 B |
4
src/assets/images/j-icon3.svg
Normal file
4
src/assets/images/j-icon3.svg
Normal file
@@ -0,0 +1,4 @@
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<rect x="1" y="1" width="14" height="14" rx="2" fill="#F53F3F"/>
|
||||
<path d="M7.71483 3.27373C6.72523 2.95373 5.76843 3.31693 5.10843 3.70653C4.99243 3.32333 4.63323 3.05453 4.22363 3.10653C3.85483 3.15293 3.55403 3.46813 3.50683 3.85933C3.46603 4.20093 3.61163 4.50973 3.85003 4.68813V12.6521C3.85003 12.9273 4.05003 13.1673 4.31003 13.1761C4.57883 13.1849 4.79883 12.9561 4.79883 12.6737V9.94893C7.47963 8.18173 9.11003 9.41773 10.2492 9.69533C11.1788 9.92173 11.9716 9.55853 12.2732 9.38813C12.354 9.34253 12.4036 9.25293 12.4036 9.15613V4.21773C12.4036 4.02013 12.2076 3.89693 12.0412 3.98413C10.6996 4.69053 9.35963 3.80573 7.71483 3.27373ZM9.92043 6.09693C9.52043 6.00733 8.99403 5.81853 8.35083 5.43693C7.21963 4.76653 6.23403 5.39693 6.19323 5.42413C5.97643 5.56653 5.69003 5.49773 5.55403 5.26813C5.41803 5.03933 5.48123 4.73773 5.69643 4.59213C5.75643 4.55213 7.17803 3.61293 8.80443 4.57773C9.36923 4.91213 9.80763 5.06573 10.114 5.13453C10.3276 5.18253 10.4788 5.38413 10.4788 5.61533C10.478 5.92653 10.2084 6.16093 9.92043 6.09693Z" fill="white"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
4
src/assets/images/j-icon4.svg
Normal file
4
src/assets/images/j-icon4.svg
Normal file
@@ -0,0 +1,4 @@
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<rect x="1" y="1" width="14" height="14" rx="2" fill="#F77234"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M13.3488 7.76984L12.036 6.45704C11.9757 6.39681 11.9417 6.31509 11.9416 6.22984V4.37224C11.9416 4.19464 11.7976 4.05144 11.6208 4.05144H9.76399C9.67919 4.05144 9.59679 4.01784 9.53679 3.95704L8.22399 2.64424C8.19417 2.61438 8.15875 2.59069 8.11977 2.57453C8.08078 2.55837 8.03899 2.55005 7.99679 2.55005C7.95459 2.55005 7.9128 2.55837 7.87382 2.57453C7.83483 2.59069 7.79942 2.61438 7.76959 2.64424L6.45599 3.95704C6.39576 4.01737 6.31404 4.05133 6.22879 4.05144H4.37199C4.32986 4.05144 4.28815 4.05973 4.24923 4.07586C4.21031 4.09198 4.17494 4.11561 4.14515 4.1454C4.11536 4.17519 4.09173 4.21055 4.07561 4.24947C4.05949 4.28839 4.05119 4.33011 4.05119 4.37224V6.22904C4.05119 6.31384 4.01759 6.39624 3.95679 6.45624L2.64399 7.76984C2.61413 7.79966 2.59045 7.83508 2.57428 7.87406C2.55812 7.91305 2.5498 7.95483 2.5498 7.99704C2.5498 8.03924 2.55812 8.08103 2.57428 8.12001C2.59045 8.159 2.61413 8.19441 2.64399 8.22424L3.95679 9.53704C4.01713 9.59726 4.05108 9.67898 4.05119 9.76424V11.621C4.05119 11.7986 4.19519 11.9418 4.37199 11.9418H6.22879C6.31359 11.9418 6.39599 11.9754 6.45599 12.0362L7.76879 13.349C7.79862 13.3789 7.83403 13.4026 7.87302 13.4187C7.912 13.4349 7.95379 13.4432 7.99599 13.4432C8.03819 13.4432 8.07998 13.4349 8.11897 13.4187C8.15795 13.4026 8.19337 13.3789 8.22319 13.349L9.53599 12.0362C9.59622 11.9759 9.67794 11.9419 9.76319 11.9418H11.62C11.7976 11.9418 11.9408 11.7978 11.9408 11.621V9.76424C11.9408 9.67944 11.9744 9.59704 12.0352 9.53704L13.348 8.22424C13.378 8.19451 13.4018 8.15915 13.4181 8.12019C13.4344 8.08123 13.4428 8.03943 13.4429 7.9972C13.443 7.95497 13.4347 7.91315 13.4185 7.87413C13.4024 7.83511 13.3787 7.79966 13.3488 7.76984ZM5.44559 6.59864C5.44559 5.83624 5.90959 5.23944 6.50239 5.23944C7.09519 5.23944 7.55919 5.83624 7.55919 6.59864C7.55919 7.36104 7.09519 7.95784 6.50239 7.95784C5.90959 7.95784 5.44559 7.36104 5.44559 6.59864ZM7.29919 10.6354C7.26265 10.7068 7.20706 10.7668 7.13859 10.8086C7.07011 10.8503 6.99141 10.8724 6.91119 10.8722C6.83657 10.8722 6.7632 10.8531 6.69812 10.8165C6.63305 10.78 6.57845 10.7274 6.53958 10.6637C6.5007 10.6 6.47885 10.5274 6.47612 10.4528C6.47339 10.3782 6.48988 10.3042 6.52399 10.2378L8.79679 5.80344C8.8228 5.75245 8.85863 5.7071 8.90221 5.66999C8.9458 5.63288 8.99628 5.60475 9.05077 5.58721C9.10525 5.56966 9.16267 5.56306 9.21972 5.56776C9.27676 5.57247 9.33232 5.5884 9.38319 5.61464C9.43412 5.64072 9.4794 5.67658 9.51645 5.72018C9.55351 5.76377 9.5816 5.81424 9.59914 5.8687C9.61667 5.92316 9.6233 5.98055 9.61864 6.03757C9.61399 6.0946 9.59813 6.15014 9.57199 6.20104L7.29919 10.6354ZM9.88399 10.6098C9.29119 10.6098 8.82719 10.013 8.82719 9.25064C8.82719 8.48824 9.29119 7.89144 9.88399 7.89144C10.4768 7.89144 10.9408 8.48824 10.9408 9.25064C10.9408 10.013 10.476 10.6098 9.88399 10.6098ZM9.83644 8.79917C9.77912 8.86492 9.69824 9.01737 9.69824 9.2507C9.69824 9.5603 9.84064 9.7283 9.88544 9.7387C9.9002 9.73464 9.92826 9.71018 9.95806 9.66594C10.0154 9.60092 10.0972 9.44762 10.0972 9.213C10.0972 8.9034 9.95481 8.7354 9.91001 8.725C9.89509 8.72909 9.86659 8.75404 9.83644 8.79917ZM6.49961 6.1106C6.54441 6.121 6.68681 6.289 6.68681 6.5986C6.68681 6.9082 6.54521 7.0754 6.50361 7.0866C6.45881 7.0762 6.31641 6.9082 6.31641 6.5986C6.31641 6.289 6.45881 6.1218 6.49961 6.1106Z" fill="white"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.4 KiB |
@@ -171,13 +171,23 @@ body .hasTagsView .app-main .el-card{
|
||||
border: 0;
|
||||
border-radius: 0;
|
||||
}
|
||||
body .el-card.box-card.is-always-shadow,
|
||||
body .hasTagsView .app-main .el-card.box-card.is-always-shadow{
|
||||
box-shadow: none;
|
||||
}
|
||||
body .el-card .el-card__header,
|
||||
body .hasTagsView .app-main .el-card .el-card__header{
|
||||
border-bottom: 1px solid #E5E6EB;
|
||||
padding: 10px 20px;
|
||||
}
|
||||
body .el-card .el-card__header .clearfix::before,
|
||||
body .el-card .el-card__header .clearfix::after{
|
||||
content: "";
|
||||
display: table;
|
||||
}
|
||||
body .el-card .el-card__header .clearfix::after{
|
||||
clear: both;
|
||||
}
|
||||
body .hasTagsView .app-main .el-card .el-card__header>.clearfix>span{
|
||||
line-height: 29px;
|
||||
font-weight: bold;
|
||||
@@ -403,9 +413,28 @@ body .el-table--medium .el-table__cell {
|
||||
body .el-table--border {
|
||||
border: 0;
|
||||
}
|
||||
body .el-table--border::after,
|
||||
body .el-table--group::after,
|
||||
body .el-table::before {
|
||||
background-color: #e5e6eb;
|
||||
}
|
||||
body .el-table--border::after {
|
||||
content: none;
|
||||
}
|
||||
body .el-table--border.btable::after {
|
||||
content: "";
|
||||
}
|
||||
body .el-table--border .el-table__cell {
|
||||
border-right: 0;
|
||||
}
|
||||
body .el-table.btable{
|
||||
border-top: 1px solid #e5e6eb !important;
|
||||
border-left: 1px solid #e5e6eb !important;
|
||||
}
|
||||
body .el-table.btable .el-table__cell {
|
||||
border-right: 1px solid #EBEEF5;
|
||||
}
|
||||
|
||||
|
||||
/*el-tree*/
|
||||
body .el-tree {
|
||||
@@ -531,6 +560,12 @@ body .el-form-item .el-form-item__label {
|
||||
body .el-progress-bar__inner {
|
||||
background-color: #233A82 !important;
|
||||
}
|
||||
body .pro1 .el-progress-bar__inner {
|
||||
background-color: #F53F3F !important;
|
||||
}
|
||||
body .el-progress-bar__inner .el-progress-bar__innerText{
|
||||
color: #fff !important;
|
||||
}
|
||||
|
||||
/*modellist*/
|
||||
.modellist{
|
||||
@@ -670,3 +705,189 @@ body ,html{
|
||||
.login-page .loright .locont .el-button{
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
* {
|
||||
--color: #233A82;
|
||||
--color_shallow: #233A82;
|
||||
--count_number: #233A82;
|
||||
--count_number_shallow: #233A82;
|
||||
--primary_color: #233A82;
|
||||
--aside_color: #233A82;
|
||||
}
|
||||
|
||||
|
||||
.ftitle{
|
||||
display: block;
|
||||
text-align: center;
|
||||
font-size: 20px;
|
||||
line-height: 28px;
|
||||
font-weight: bold;
|
||||
color: #1D2129;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.stitle{
|
||||
display: block;
|
||||
text-align: left;
|
||||
color: #1D2129;
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
line-height: 24px;
|
||||
padding: 0 0 8px 0;
|
||||
margin: 30px 0 0 0;
|
||||
border-bottom: 1px solid #e5e6eb;
|
||||
}
|
||||
.ttitle{
|
||||
display: block;
|
||||
text-align: left;
|
||||
color: #1D2129;
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
line-height: 22px;
|
||||
padding: 0 0 8px 0;
|
||||
margin: 24px 0 0 0;
|
||||
}
|
||||
|
||||
/*test-list*/
|
||||
.test-list{
|
||||
display: flex;
|
||||
}
|
||||
.test-list .list{
|
||||
display: block;
|
||||
flex: 1;
|
||||
padding: 24px 24px 0 24px;
|
||||
}
|
||||
.test-list .list+.list{
|
||||
margin-left: 24px;
|
||||
}
|
||||
.test-list .list .title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.test-list .list .title img{
|
||||
display: block;
|
||||
width: 16px;
|
||||
margin: 0 4px 0 0;
|
||||
}
|
||||
.test-list .list .title .tit{
|
||||
display: block;
|
||||
color: #86909C;
|
||||
font-size: 14px;
|
||||
line-height: 22px;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.test-list .list .figure{
|
||||
display: block;
|
||||
margin: 12px 0 0 0;
|
||||
padding: 0;
|
||||
color: #1D2129;
|
||||
font-size: 24px;
|
||||
line-height: 32px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/*badge*/
|
||||
body .el-badge.newbadge{
|
||||
display: inline-flex;
|
||||
flex-direction: row-reverse;
|
||||
align-items: center;
|
||||
}
|
||||
body .el-badge.newbadge+.el-badge.newbadge{
|
||||
margin-left: 20px;
|
||||
}
|
||||
body .el-badge.newbadge .sz{
|
||||
color: #1D2129;
|
||||
font-size: 14px;
|
||||
font-weight: 300;
|
||||
line-height: 22px;
|
||||
margin: 0 0 0 10px;
|
||||
}
|
||||
body .el-badge.newbadge .el-badge__content.is-fixed{
|
||||
position: inherit;
|
||||
transform: inherit;
|
||||
right: 0;
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
line-height: 18px;
|
||||
text-align: center;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-size: 12px;
|
||||
}
|
||||
body .el-badge__content{
|
||||
background-color: #F53F3F;
|
||||
}
|
||||
body .el-badge__content--warning {
|
||||
background-color: #F7BA1E;
|
||||
}
|
||||
body .el-badge__content--primary {
|
||||
background-color: #0FC6C2;
|
||||
}
|
||||
|
||||
|
||||
/*ncoll*/
|
||||
body .ncoll{
|
||||
margin: 5px 0 0 0;
|
||||
}
|
||||
body .ncoll.el-collapse{
|
||||
border: 0;
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item>div:first-child{
|
||||
text-align: center;
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__header{
|
||||
border-bottom: 0;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
justify-content: center;
|
||||
display: inline-flex;
|
||||
color: #233A82;
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__header:hover{
|
||||
color: #2B50C4;
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__header .tit{
|
||||
display: block;
|
||||
margin: 0;
|
||||
display: block;
|
||||
text-align: left;
|
||||
font-size: 12px;
|
||||
font-weight: normal;
|
||||
line-height: 20px;
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__header .el-collapse-item__arrow{
|
||||
display: block;
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
text-align: center;
|
||||
line-height: 18px;
|
||||
padding: 0;
|
||||
font-size: 14px;
|
||||
margin: 0;
|
||||
-webkit-transform: rotate(90deg);
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__arrow.is-active {
|
||||
-webkit-transform: rotate(-90deg);
|
||||
transform: rotate(-90deg);
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__wrap{
|
||||
border-bottom: 0;
|
||||
}
|
||||
body .ncoll.el-collapse .el-collapse-item__wrap .el-collapse-item__content{
|
||||
padding: 5px 0;
|
||||
}
|
||||
|
||||
.dbox{
|
||||
border: 1px dashed #e5e6eb;
|
||||
padding: 10px;
|
||||
box-sizing: border-box;
|
||||
margin: 10px 0 0 0;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.dbox .ttitle:first-child{
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,15 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<iframe src="http://192.168.1.217:8001/model/modelChildren?hideInMenu=true" width="100%" height="850px" frameborder="0" />
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<iframe src="http://192.168.1.217:8001/model/modelChildren?hideInMenu=true" width="100%" height="850px" frameborder="0" />
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -9,6 +18,16 @@ export default {
|
||||
name: 'DataModel',
|
||||
data() {
|
||||
return {
|
||||
projectsOptions: [
|
||||
{id: '1111', projectName: '演示项目'}
|
||||
],
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
fileName: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
@@ -9,14 +9,14 @@
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<el-steps :active="active" finish-status="success" align-center>
|
||||
<div class="body-wrapper" style="padding-left: 20%">
|
||||
<el-steps :active="active" finish-status="success" align-center style="width: 900px">
|
||||
<el-step title="填写数据源信息" />
|
||||
<el-step title="选择数据库类型" />
|
||||
<el-step title="填写连接信息" />
|
||||
</el-steps>
|
||||
<el-form v-if="active == 1" ref="form" :model="form" :rules="rules" label-width="120px">
|
||||
<div style="padding: 20px 200px">
|
||||
<el-form v-if="active == 1" ref="form" :model="form" :rules="rules" label-width="120px" style="width: 900px">
|
||||
<div style="padding: 20px 0px">
|
||||
<el-form-item label="数据源名称" prop="sourceName">
|
||||
<el-input v-model="form.sourceName" placeholder="请输入数据源名称" />
|
||||
</el-form-item>
|
||||
@@ -34,8 +34,8 @@
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
<el-form v-if="active == 2" ref="form" :model="form" :rules="rules" label-width="120px">
|
||||
<div class="modellist" style="padding: 20px 200px">
|
||||
<el-form v-if="active == 2" ref="form" :model="form" :rules="rules" label-width="120px" style="width: 900px">
|
||||
<div class="modellist" style="padding: 20px 0px">
|
||||
<div :class="[form.dbType =='1' ? 'choosedDbType' : '','list']" @click="chooseDbType('1')">
|
||||
<div class="limg"><img :src="databaseImg.imgMySQL"></div>
|
||||
<div class="ltitle">
|
||||
@@ -119,8 +119,8 @@
|
||||
</div><!--modellist 模型监控列表-->
|
||||
|
||||
</el-form>
|
||||
<el-form v-if="active == 3" ref="form2" :model="form2" :rules="rules2" label-width="80px">
|
||||
<div style="padding: 20px 200px">
|
||||
<el-form v-if="active == 3" ref="form2" :model="form2" :rules="rules2" label-width="80px" style="width: 900px">
|
||||
<div style="padding: 20px 0px">
|
||||
<el-form-item label="主机" prop="host">
|
||||
<el-input v-model="form2.host" placeholder="请输入主机" />
|
||||
</el-form-item>
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<template>
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="数据源名称" prop="sourceName">
|
||||
<el-input
|
||||
v-model="queryParams.sourceName"
|
||||
@@ -175,6 +180,9 @@ export default {
|
||||
},
|
||||
{ prop: 'createTime', label: '创建时间', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
tableSize: 'medium',
|
||||
@@ -189,6 +197,7 @@ export default {
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
sourceName: ''
|
||||
}
|
||||
}
|
||||
|
||||
40
src/views/metadata/offlinedata/OfflineDataDetail.vue
Normal file
40
src/views/metadata/offlinedata/OfflineDataDetail.vue
Normal file
@@ -0,0 +1,40 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<iframe src="http://192.168.1.217:8001/model/modelChildren?hideInMenu=true&projectId=1" width="100%" height="850px" frameborder="0" />
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'OfflineDataDetail',
|
||||
data() {
|
||||
return {
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
fileName: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
@@ -1,6 +1,11 @@
|
||||
<template>
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-card v-loading="boxCardLoading" class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="离线文件名称" prop="sourceName">
|
||||
<el-input
|
||||
v-model="queryParams.fileName"
|
||||
@@ -23,8 +28,9 @@
|
||||
class="upload-demo"
|
||||
action="#"
|
||||
:show-file-list="false"
|
||||
:http-request="uploadOfflineFile">
|
||||
<el-button size="mini" type="primary" icon="el-icon-upload2">上传</el-button>
|
||||
:http-request="uploadOfflineFile"
|
||||
>
|
||||
<el-button size="mini" type="primary" icon="el-icon-upload2">上传</el-button>
|
||||
</el-upload>
|
||||
</el-button-group>
|
||||
</el-col>
|
||||
@@ -96,17 +102,19 @@
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="300">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
v-if="scope.row.isSwitch != 'jrcg'"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-sort"
|
||||
@click="handleEdit(scope.row)"
|
||||
@click="handleSwitch(scope.row)"
|
||||
>执行接入</el-button>
|
||||
<el-button
|
||||
v-if="scope.row.isSwitch == 'jrcg'"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-view"
|
||||
@click="handleEdit(scope.row)"
|
||||
>接入详情</el-button>
|
||||
@click="handleDetail(scope.row)"
|
||||
>查看接入数据</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
@@ -153,6 +161,7 @@
|
||||
},
|
||||
// 遮罩层
|
||||
loading: true,
|
||||
boxCardLoading: false,
|
||||
// 表格头
|
||||
tableColumns: [
|
||||
{ prop: 'fileName', label: '离线文件名称', show: true },
|
||||
@@ -171,6 +180,9 @@
|
||||
{ prop: 'createTime', label: '上传时间', show: true },
|
||||
{ prop: 'switchTime', label: '接入时间', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
tableSize: 'medium',
|
||||
@@ -185,6 +197,7 @@
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
fileName: ''
|
||||
}
|
||||
}
|
||||
@@ -221,6 +234,21 @@
|
||||
initCols() {
|
||||
this.checkedTableColumns = this.tableColumns.map(col => col.prop)
|
||||
},
|
||||
handleSwitch(row) {
|
||||
this.boxCardLoading = true
|
||||
setTimeout(() => {
|
||||
row.isSwitch = 'jrcg'
|
||||
this.boxCardLoading = false
|
||||
this.$message.success('接入成功')
|
||||
}, 2000)
|
||||
},
|
||||
/** 详情按钮操作 */
|
||||
handleDetail(row) {
|
||||
this.showOptions.data.id = row.id
|
||||
this.showOptions.showList = false
|
||||
this.showOptions.showDetail = true
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
handleCheckedColsChange(val) {
|
||||
this.tableColumns.forEach(col => {
|
||||
if (!this.checkedTableColumns.includes(col.prop)) {
|
||||
@@ -300,7 +328,7 @@
|
||||
return <el-tag type='error'>接入失败</el-tag>
|
||||
}
|
||||
},
|
||||
uploadOfflineFile(file){
|
||||
uploadOfflineFile(file) {
|
||||
this.formData = new FormData()
|
||||
this.formData.append('file', file.file)
|
||||
// 请求接口
|
||||
|
||||
@@ -2,21 +2,24 @@
|
||||
<div class="app-container">
|
||||
<transition name="el-zoom-in-center">
|
||||
<offline-data-list v-if="options.showList" @showCard="showCard" />
|
||||
<offline-data-detail v-if="options.showDetail" @showCard="showCard" />
|
||||
</transition>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import OfflineDataList from './OfflineDataList'
|
||||
import OfflineDataDetail from './OfflineDataDetail'
|
||||
|
||||
export default {
|
||||
name: 'OfflineData',
|
||||
components: { OfflineDataList },
|
||||
components: { OfflineDataList, OfflineDataDetail },
|
||||
data() {
|
||||
return {
|
||||
options: {
|
||||
data: {},
|
||||
showList: true
|
||||
showList: true,
|
||||
showDetail: true
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
<template>
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="数据源名称" prop="sourceName">
|
||||
<el-form-item label="项目名称" prop="sourceName">
|
||||
<el-input
|
||||
v-model="queryParams.sourceName"
|
||||
placeholder="请输入数据源名称"
|
||||
v-model="queryParams.projectName"
|
||||
placeholder="请输入项目名称"
|
||||
clearable
|
||||
size="small"
|
||||
@keyup.enter.native="handleQuery"
|
||||
@@ -152,7 +152,7 @@ export default {
|
||||
label: '项目名称',
|
||||
show: true, width: '90px'
|
||||
},
|
||||
{ prop: 'createAt', label: '创建时间', show: false }
|
||||
{ prop: 'projectDescription', label: '项目描述', show: true }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
|
||||
@@ -3,35 +3,43 @@
|
||||
<div slot="header" class="clearfix">
|
||||
<span>{{ title }}</span>
|
||||
<el-button-group style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-finished" :loading="loadingOptions.loading" :disabled="loadingOptions.isDisabled" @click="submitForm">{{ loadingOptions.loadingText }}</el-button>
|
||||
<el-button v-if="active == 2" type="primary" size="mini" icon="el-icon-finished" :loading="loadingOptions.loading" :disabled="loadingOptions.isDisabled" @click="submitForm">{{ loadingOptions.loadingText }}</el-button>
|
||||
<el-button v-if="active == 1" size="mini" type="primary" @click="handleNextStep">下一步</el-button>
|
||||
<el-button v-if="active == 2" size="mini" type="primary" @click="handleLastStep">上一步</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="规则名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入规则名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="核查类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择核查类型" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
:label="item.itemExplain"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<div class="body-wrapper" style="padding-left: 20%">
|
||||
<el-steps :active="active" finish-status="success" align-center style="width: 900px">
|
||||
<el-step title="填写检测用例信息" />
|
||||
<el-step title="选择检测数据源" />
|
||||
</el-steps>
|
||||
<!--<el-form ref="form" :model="form" :rules="rules" label-width="80px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入用例名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="检测类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择检测类型" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
:label="item.itemExplain"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="用例级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择用例级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</div>
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
@@ -54,8 +62,8 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="核查字段" prop="ruleColumnId">
|
||||
<el-select v-model="form.ruleColumnId" placeholder="请选择核查字段" @change="columnSelectChanged">
|
||||
<el-form-item label="检测字段" prop="ruleColumnId">
|
||||
<el-select v-model="form.ruleColumnId" placeholder="请选择检测字段" @change="columnSelectChanged">
|
||||
<el-option
|
||||
v-for="column in columnOptions"
|
||||
:key="column.id"
|
||||
@@ -66,7 +74,7 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-divider content-position="left">核查配置</el-divider>
|
||||
<el-divider content-position="left">检测配置</el-divider>
|
||||
<el-row v-if="form.ruleConfig.ruleItemCode === 'timeliness_key'">
|
||||
<el-col :span="24">
|
||||
<el-form-item label="判定阀值">
|
||||
@@ -137,7 +145,7 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<!-- 正则表达式规则-->
|
||||
<!– 正则表达式规则–>
|
||||
<el-row v-if="form.ruleConfig.ruleItemCode === 'regular_key'">
|
||||
<el-col :span="24">
|
||||
<el-form-item label="正则表达">
|
||||
@@ -170,6 +178,81 @@
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</el-form>-->
|
||||
|
||||
<el-form v-if="active == 1" ref="form" :model="form" :rules="rules" label-width="120px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入用例名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="检测类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择检测类型" style="width: 100%" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
:label="item.itemExplain"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="用例级别" prop="ruleLevelId">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId" placeholder="请选择用例级别" style="width: 100%">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
</div>
|
||||
</el-form>
|
||||
<el-form v-if="active == 2" ref="form" :model="form" :rules="rules" label-width="80px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" style="width: 100%" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
v-for="source in sourceOptions"
|
||||
:key="source.id"
|
||||
:label="source.sourceName"
|
||||
:value="source.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-row v-if="form.ruleConfig.ruleItemCode === 'regular_key'">
|
||||
<el-col :span="24">
|
||||
<el-form-item label="正则表达">
|
||||
<el-input v-model="form.ruleConfig.regular.regular" placeholder="请输入正则规则" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row v-if="form.ruleConfig.ruleItemCode === 'regular_key'">
|
||||
<el-form-item label="常用正则">
|
||||
<el-radio-group v-model="form.zzStatus" @change="handleZzStatusRadioChange">
|
||||
<el-radio label="1">手机号码</el-radio>
|
||||
<el-radio label="2">邮箱</el-radio>
|
||||
<el-radio label="3">整数</el-radio>
|
||||
<el-radio label="4">负数</el-radio>
|
||||
<el-radio label="5">身份证</el-radio>
|
||||
<el-radio label="6">日期格式yyyy-mm-dd</el-radio>
|
||||
<el-radio label="7">IP</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-radio-group v-model="form.status">
|
||||
<el-radio
|
||||
v-for="dict in statusOptions"
|
||||
:key="dict.id"
|
||||
:label="dict.itemText"
|
||||
>{{ dict.itemValue }}
|
||||
</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
</el-card>
|
||||
@@ -194,7 +277,8 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
title: '核查规则新增',
|
||||
title: '检测用例新增',
|
||||
active: 1,
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
@@ -310,6 +394,18 @@ export default {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
/** 步骤条下一步 */
|
||||
handleNextStep() {
|
||||
this.$refs['form'].validate(valid => {
|
||||
if (valid) {
|
||||
this.active++
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 步骤条上一步 */
|
||||
handleLastStep() {
|
||||
this.active--
|
||||
},
|
||||
getRuleLevelList() {
|
||||
listRuleLevel().then(response => {
|
||||
if (response.success) {
|
||||
@@ -415,6 +511,8 @@ export default {
|
||||
this.loadingOptions.loading = true
|
||||
this.loadingOptions.loadingText = '保存中...'
|
||||
this.loadingOptions.isDisabled = true
|
||||
this.form.ruleTableId = 'all'
|
||||
this.form.ruleTable = '全表'
|
||||
addCheckRule(this.form).then(response => {
|
||||
if (response.success) {
|
||||
this.$message.success('保存成功')
|
||||
@@ -442,6 +540,16 @@ export default {
|
||||
this.form.ruleConfig.regular.regular = '^[1-9][0-9]{10}$'
|
||||
} else if (value === '2') {
|
||||
this.form.ruleConfig.regular.regular = '^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\\.[a-zA-Z0-9_-]+)+$'
|
||||
} else if (value === '3') {
|
||||
this.form.ruleConfig.regular.regular = '[0-9]*[1-9][0-9]*'
|
||||
} else if (value === '4') {
|
||||
this.form.ruleConfig.regular.regular = '-[0-9]*[1-9][0-9]*'
|
||||
} else if (value === '5') {
|
||||
this.form.ruleConfig.regular.regular = '\\d{15}(\\d\\d[0-9xX])?'
|
||||
} else if (value === '6') {
|
||||
this.form.ruleConfig.regular.regular = '(\\d{4}|\\d{2})-((1[0-2])|(0?[1-9]))-(([12][0-9])|(3[01])|(0?[1-9]))'
|
||||
} else if (value === '7') {
|
||||
this.form.ruleConfig.regular.regular = '((2[0-4]\\d|25[0-5]|[01]?\\d\\d?)\\.){3}(2[0-4]\\d|25[0-5]|[01]?\\d\\d?)'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -21,16 +21,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别">
|
||||
<el-select v-model="form.ruleLevelId">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="规则级别">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="数据源">
|
||||
<el-select v-model="form.ruleSourceId">
|
||||
<el-option
|
||||
|
||||
@@ -22,16 +22,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="规则级别" prop="ruleLevelId">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
@@ -218,9 +218,6 @@ export default {
|
||||
ruleItemId: [
|
||||
{ required: true, message: '核查类型不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleLevelId: [
|
||||
{ required: true, message: '规则级别不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleSourceId: [
|
||||
{ required: true, message: '数据源不能为空', trigger: 'change' }
|
||||
],
|
||||
|
||||
@@ -26,6 +26,11 @@
|
||||
<el-col :span="18">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="数据源" prop="ruleName">
|
||||
<el-input
|
||||
v-model="queryParams.ruleSource"
|
||||
@@ -46,10 +51,10 @@
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="规则名称" prop="ruleName">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input
|
||||
v-model="queryParams.ruleName"
|
||||
placeholder="请输入规则名称"
|
||||
placeholder="请输入用例名称"
|
||||
clearable
|
||||
size="small"
|
||||
@keyup.enter.native="handleQuery"
|
||||
@@ -197,11 +202,11 @@ export default {
|
||||
// 表格头
|
||||
tableColumns: [
|
||||
{ prop: 'ruleSource', label: '数据源', show: true },
|
||||
{ prop: 'ruleTable', label: '数据表', show: true, formatter: this.ruleTableFormatter },
|
||||
{ prop: 'ruleColumn', label: '核查字段', show: true, formatter: this.ruleColumnFormatter },
|
||||
{ prop: 'ruleName', label: '规则名称', show: true },
|
||||
{ prop: 'ruleType', label: '规则类型', show: true },
|
||||
{ prop: 'ruleLevel', label: '规则级别', width: 100, show: true },
|
||||
/* { prop: 'ruleTable', label: '数据表', show: true, formatter: this.ruleTableFormatter },*/
|
||||
/* { prop: 'ruleColumn', label: '检测字段', show: true, formatter: this.ruleColumnFormatter },*/
|
||||
{ prop: 'ruleName', label: '用例名称', show: true },
|
||||
{ prop: 'ruleType', label: '用例类型', show: true },
|
||||
// { prop: 'ruleLevel', label: '用例级别', width: 100, show: true },
|
||||
{
|
||||
prop: 'status',
|
||||
label: '状态',
|
||||
@@ -211,6 +216,9 @@ export default {
|
||||
},
|
||||
{ prop: 'createTime', label: '创建时间', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
tableSize: 'medium',
|
||||
@@ -224,6 +232,7 @@ export default {
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
ruleTypeId: '',
|
||||
ruleName: ''
|
||||
},
|
||||
@@ -253,10 +262,10 @@ export default {
|
||||
if (response.success) {
|
||||
const { data } = response
|
||||
const tree = {}
|
||||
tree.name = '规则类型'
|
||||
tree.name = '用例类型'
|
||||
const children = []
|
||||
data.forEach(e => {
|
||||
if (e.code === 'unique' || e.code === 'integrity' || e.code === 'accuracy' ||
|
||||
if (e.code === 'integrity' || e.code === 'accuracy' ||
|
||||
e.code === 'consistent' || e.code === 'regular') {
|
||||
children.push(e)
|
||||
}
|
||||
@@ -324,7 +333,7 @@ export default {
|
||||
handleAdd() {
|
||||
this.showOptions.data = {}
|
||||
if (!this.queryParams.ruleTypeId) {
|
||||
this.$message.warning('请先选择核查规则类型')
|
||||
this.$message.warning('请先选择核查用例类型')
|
||||
return
|
||||
}
|
||||
this.showOptions.data.ruleTypeId = this.queryParams.ruleTypeId
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -7,13 +7,13 @@
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
||||
<div class="body-wrapper" style="padding-left: 25%">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="100px" style="width: 700px">
|
||||
<el-form-item label="任务名称" prop="jobName">
|
||||
<el-input v-model="form.jobName" placeholder="任务名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="任务类型" prop="jobType">
|
||||
<el-select v-model="form.jobType" placeholder="请选择任务类型" @change="ruleItemSelectChanged">
|
||||
<el-select v-model="form.jobType" placeholder="请选择任务类型" @change="ruleItemSelectChanged" style="width: 100%">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.typeId"
|
||||
@@ -22,7 +22,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-divider content-position="left">任务配置</el-divider>
|
||||
<el-form-item label="检测用例" prop="checkCase">
|
||||
<el-select v-model="form.checkCase" multiple placeholder="检测用例" style="width: 100%">
|
||||
<el-option
|
||||
v-for="item in checkCaseOptions"
|
||||
:key="item.id"
|
||||
:label="item.ruleName"
|
||||
:value="item.id">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="cron表达式" prop="cronExpression">
|
||||
<el-input v-model="form.cronExpression" placeholder="cron表达式" />
|
||||
</el-form-item>
|
||||
@@ -37,7 +46,7 @@
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务概述" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
<el-input v-model="form.remark" type="textarea" :rows="8" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
@@ -46,6 +55,7 @@
|
||||
|
||||
<script>
|
||||
import { updateCheckJob, getScheduleJobById } from '@/api/quality/checkjob'
|
||||
import { pageCheckRule } from '@/api/quality/checkrule'
|
||||
|
||||
export default {
|
||||
name: 'CheckJobEdit',
|
||||
@@ -88,6 +98,7 @@ export default {
|
||||
{ required: true, message: 'cron表达式不能为空', trigger: 'blur' }
|
||||
]
|
||||
},
|
||||
checkCaseOptions: [],
|
||||
// 状态数据字典
|
||||
statusOptions: [],
|
||||
// 规则级别数据字典
|
||||
@@ -112,6 +123,7 @@ export default {
|
||||
this.statusOptions = response.data
|
||||
}
|
||||
})
|
||||
this.getCheckRule()
|
||||
},
|
||||
mounted() {
|
||||
this.getCheckJob(this.data.id)
|
||||
@@ -135,6 +147,29 @@ export default {
|
||||
})
|
||||
this.form.jobType = item.typeId
|
||||
},
|
||||
getCheckRule() {
|
||||
let ruleType = 'nr'
|
||||
if(this.form.jobType == 'structure'){
|
||||
ruleType = 'jg'
|
||||
} else if(this.form.jobType == 'relevance'){
|
||||
ruleType = 'gl'
|
||||
}
|
||||
let params = {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
ruleTypeId: '',
|
||||
ruleName: '',
|
||||
ruleType: ruleType
|
||||
}
|
||||
this.checkCaseOptions = []
|
||||
pageCheckRule(params).then(response => {
|
||||
if (response.success) {
|
||||
const { data } = response
|
||||
this.checkCaseOptions = data.data
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm: function () {
|
||||
this.$refs['form'].validate(valid => {
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<template>
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务名称" prop="sourceName">
|
||||
<el-input
|
||||
v-model="queryParams.sourceName"
|
||||
@@ -92,7 +97,7 @@
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
</template>
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="400px">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
@@ -101,7 +106,6 @@
|
||||
@click="handleDetail(scope.row)"
|
||||
>详情</el-button>
|
||||
<el-button
|
||||
v-hasPerm="['quality:rule:edit']"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-edit-outline"
|
||||
@@ -121,12 +125,18 @@
|
||||
icon="el-icon-refresh-left"
|
||||
@click="handleResume(scope.row)"
|
||||
>任务恢复</el-button>
|
||||
<el-button
|
||||
<!--<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-s-promotion"
|
||||
@click="handleRun(scope.row)"
|
||||
>立即执行</el-button>
|
||||
>立即执行</el-button>-->
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"
|
||||
>删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -169,12 +179,22 @@ export default {
|
||||
// { prop: 'methodParams', label: '方法参数', show: true },
|
||||
{ prop: 'cronExpression', label: 'cron表达式', show: true },
|
||||
{ prop: 'afterDate', label: '最近完成时间', show: true },
|
||||
{
|
||||
prop: 'schedule',
|
||||
label: '任务进度',
|
||||
show: true,
|
||||
formatter: this.scheduleFormatter
|
||||
},
|
||||
{
|
||||
prop: 'status',
|
||||
label: '状态',
|
||||
label: '定时状态',
|
||||
show: true,
|
||||
formatter: this.statusFormatter
|
||||
}
|
||||
},
|
||||
{ prop: 'remark', label: '任务概述', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
tableSize: 'medium',
|
||||
// 默认选择中表格头
|
||||
@@ -189,6 +209,7 @@ export default {
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
sourceName: ''
|
||||
}
|
||||
}
|
||||
@@ -295,6 +316,9 @@ export default {
|
||||
return <el-tag type='warning'>{dictLabel}</el-tag>
|
||||
}
|
||||
},
|
||||
scheduleFormatter(row, column, cellValue, index){
|
||||
return '100%'
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
this.queryParams.pageNum = 1
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<template>
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="规则类型" prop="ruleTypeId">
|
||||
<el-select v-model="queryParams.ruleTypeId" clearable placeholder="请选择规则类型">
|
||||
<el-form-item label="用例类型" prop="ruleTypeId">
|
||||
<el-select v-model="queryParams.ruleTypeId" clearable placeholder="请选择用例类型">
|
||||
<el-option
|
||||
v-for="item in ruleTypeOptions"
|
||||
:key="item.id"
|
||||
@@ -75,8 +75,8 @@ export default {
|
||||
// 表格头
|
||||
tableColumns: [
|
||||
{ prop: 'executeJobName', label: '任务名称', show: true },
|
||||
{ prop: 'executeRuleTypeName', label: '规则类型', show: true },
|
||||
{ prop: 'executeRuleName', label: '规则名称', show: true },
|
||||
{ prop: 'executeRuleTypeName', label: '用例类型', show: true },
|
||||
{ prop: 'executeRuleName', label: '用例名称', show: true },
|
||||
{ prop: 'executeBatch', label: '执行批次', show: true },
|
||||
{
|
||||
prop: 'status',
|
||||
|
||||
@@ -3,17 +3,23 @@
|
||||
<div slot="header" class="clearfix">
|
||||
<span>{{ title }}</span>
|
||||
<el-button-group style="float: right;">
|
||||
<el-button v-hasPerm="['quality:rule:add']" type="primary" size="mini" icon="el-icon-finished" :loading="loadingOptions.loading" :disabled="loadingOptions.isDisabled" @click="submitForm">{{ loadingOptions.loadingText }}</el-button>
|
||||
<el-button v-if="active == 2" type="primary" size="mini" icon="el-icon-finished" :loading="loadingOptions.loading" :disabled="loadingOptions.isDisabled" @click="submitForm">{{ loadingOptions.loadingText }}</el-button>
|
||||
<el-button v-if="active == 1" size="mini" type="primary" @click="handleNextStep">下一步</el-button>
|
||||
<el-button v-if="active == 2" size="mini" type="primary" @click="handleLastStep">上一步</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="规则名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入规则名称" />
|
||||
<div class="body-wrapper" style="padding-left: 20%">
|
||||
<el-steps :active="active" finish-status="success" align-center style="width: 900px">
|
||||
<el-step title="填写检测用例信息" />
|
||||
<el-step title="选择检测数据源" />
|
||||
</el-steps>
|
||||
<!--<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入用例名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="核查类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择核查类型" @change="ruleItemSelectChanged">
|
||||
<el-form-item label="检测类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择检测类型" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
@@ -22,8 +28,8 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">
|
||||
<el-form-item label="用例级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择用例级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
@@ -54,8 +60,8 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="核查字段" prop="ruleColumnId">
|
||||
<el-select v-model="form.ruleColumnId" placeholder="请选择核查字段" @change="columnSelectChanged">
|
||||
<el-form-item label="检测字段" prop="ruleColumnId">
|
||||
<el-select v-model="form.ruleColumnId" placeholder="请选择检测字段" @change="columnSelectChanged">
|
||||
<el-option
|
||||
v-for="column in columnOptions"
|
||||
:key="column.id"
|
||||
@@ -66,7 +72,7 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-divider content-position="left">核查配置</el-divider>
|
||||
<el-divider content-position="left">检测配置</el-divider>
|
||||
<el-row v-if="form.ruleConfig.ruleItemCode === 'timeliness_key'">
|
||||
<el-col :span="24">
|
||||
<el-form-item label="判定阀值">
|
||||
@@ -137,7 +143,7 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<!-- 正则表达式规则-->
|
||||
<!– 正则表达式规则–>
|
||||
<el-row v-if="form.ruleConfig.ruleItemCode === 'regular_key'">
|
||||
<el-col :span="24">
|
||||
<el-form-item label="正则表达">
|
||||
@@ -170,6 +176,61 @@
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</el-form>-->
|
||||
|
||||
<el-form v-if="active == 1" ref="form" :model="form" :rules="rules" label-width="120px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入用例名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="检测类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择检测类型" style="width: 100%" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
:label="item.itemExplain"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="用例级别" prop="ruleLevelId">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId" placeholder="请选择用例级别" style="width: 100%">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
</div>
|
||||
</el-form>
|
||||
<el-form v-if="active == 2" ref="form" :model="form" :rules="rules" label-width="80px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" style="width: 100%" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
v-for="source in sourceOptions"
|
||||
:key="source.id"
|
||||
:label="source.sourceName"
|
||||
:value="source.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-radio-group v-model="form.status">
|
||||
<el-radio
|
||||
v-for="dict in statusOptions"
|
||||
:key="dict.id"
|
||||
:label="dict.itemText"
|
||||
>{{ dict.itemValue }}
|
||||
</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
</el-card>
|
||||
@@ -194,7 +255,8 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
title: '核查规则新增',
|
||||
title: '检测用例新增',
|
||||
active: 1,
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
@@ -259,9 +321,6 @@ export default {
|
||||
ruleItemId: [
|
||||
{ required: true, message: '核查类型不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleLevelId: [
|
||||
{ required: true, message: '规则级别不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleSourceId: [
|
||||
{ required: true, message: '数据源不能为空', trigger: 'change' }
|
||||
],
|
||||
@@ -310,6 +369,18 @@ export default {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
/** 步骤条下一步 */
|
||||
handleNextStep() {
|
||||
this.$refs['form'].validate(valid => {
|
||||
if (valid) {
|
||||
this.active++
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 步骤条上一步 */
|
||||
handleLastStep() {
|
||||
this.active--
|
||||
},
|
||||
getRuleLevelList() {
|
||||
listRuleLevel().then(response => {
|
||||
if (response.success) {
|
||||
@@ -415,6 +486,8 @@ export default {
|
||||
this.loadingOptions.loading = true
|
||||
this.loadingOptions.loadingText = '保存中...'
|
||||
this.loadingOptions.isDisabled = true
|
||||
this.form.ruleTableId = 'all'
|
||||
this.form.ruleTable = '全表'
|
||||
addCheckRule(this.form).then(response => {
|
||||
if (response.success) {
|
||||
this.$message.success('保存成功')
|
||||
|
||||
@@ -21,16 +21,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别">
|
||||
<el-select v-model="form.ruleLevelId">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="规则级别">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="数据源">
|
||||
<el-select v-model="form.ruleSourceId">
|
||||
<el-option
|
||||
|
||||
@@ -22,16 +22,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="规则级别" prop="ruleLevelId">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
@@ -218,9 +218,6 @@ export default {
|
||||
ruleItemId: [
|
||||
{ required: true, message: '核查类型不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleLevelId: [
|
||||
{ required: true, message: '规则级别不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleSourceId: [
|
||||
{ required: true, message: '数据源不能为空', trigger: 'change' }
|
||||
],
|
||||
|
||||
@@ -26,6 +26,11 @@
|
||||
<el-col :span="18">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="数据源" prop="ruleName">
|
||||
<el-input
|
||||
v-model="queryParams.ruleSource"
|
||||
@@ -46,10 +51,10 @@
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="规则名称" prop="ruleName">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input
|
||||
v-model="queryParams.ruleName"
|
||||
placeholder="请输入规则名称"
|
||||
placeholder="请输入用例名称"
|
||||
clearable
|
||||
size="small"
|
||||
@keyup.enter.native="handleQuery"
|
||||
@@ -65,7 +70,6 @@
|
||||
<el-col :span="12">
|
||||
<el-button-group>
|
||||
<el-button
|
||||
v-hasPerm="['quality:rule:add']"
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@@ -142,21 +146,18 @@
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
v-hasPerm="['quality:rule:edit']"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-edit-outline"
|
||||
@click="handleEdit(scope.row)"
|
||||
>修改</el-button>
|
||||
<el-button
|
||||
v-hasPerm="['quality:rule:detail']"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-view"
|
||||
@click="handleDetail(scope.row)"
|
||||
>详情</el-button>
|
||||
<el-button
|
||||
v-hasPerm="['quality:rule:remove']"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@@ -201,11 +202,11 @@ export default {
|
||||
// 表格头
|
||||
tableColumns: [
|
||||
{ prop: 'ruleSource', label: '数据源', show: true },
|
||||
{ prop: 'ruleTable', label: '数据表', show: true, formatter: this.ruleTableFormatter },
|
||||
{ prop: 'ruleColumn', label: '核查字段', show: true, formatter: this.ruleColumnFormatter },
|
||||
{ prop: 'ruleName', label: '规则名称', show: true },
|
||||
{ prop: 'ruleType', label: '规则类型', show: true },
|
||||
{ prop: 'ruleLevel', label: '规则级别', width: 100, show: true },
|
||||
/* { prop: 'ruleTable', label: '数据表', show: true, formatter: this.ruleTableFormatter },
|
||||
{ prop: 'ruleColumn', label: '检测字段', show: true, formatter: this.ruleColumnFormatter },*/
|
||||
{ prop: 'ruleName', label: '用例名称', show: true },
|
||||
{ prop: 'ruleType', label: '用例类型', show: true },
|
||||
// { prop: 'ruleLevel', label: '用例级别', width: 100, show: true },
|
||||
{
|
||||
prop: 'status',
|
||||
label: '状态',
|
||||
@@ -215,6 +216,9 @@ export default {
|
||||
},
|
||||
{ prop: 'createTime', label: '创建时间', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
tableSize: 'medium',
|
||||
@@ -228,6 +232,7 @@ export default {
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
ruleTypeId: '',
|
||||
ruleName: '',
|
||||
ruleType: 'gl'
|
||||
@@ -258,7 +263,7 @@ export default {
|
||||
if (response.success) {
|
||||
const { data } = response
|
||||
const tree = {}
|
||||
tree.name = '规则类型'
|
||||
tree.name = '用例类型'
|
||||
const children = []
|
||||
data.forEach(e => {
|
||||
if (e.code === 'relevance') {
|
||||
@@ -329,7 +334,7 @@ export default {
|
||||
handleAdd() {
|
||||
this.showOptions.data = {}
|
||||
if (!this.queryParams.ruleTypeId) {
|
||||
this.$message.warning('请先选择核查规则类型')
|
||||
this.$message.warning('请先选择核查用例类型')
|
||||
return
|
||||
}
|
||||
this.showOptions.data.ruleTypeId = this.queryParams.ruleTypeId
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<template>
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="时间">
|
||||
<el-date-picker
|
||||
v-model="queryParams.checkDate"
|
||||
@@ -142,7 +147,11 @@
|
||||
formatter: this.checkResultFormatter
|
||||
},
|
||||
{ prop: 'checkTotalCount', label: '检测数量', show: true },
|
||||
{ prop: 'checkErrorCount', label: '不合规数量', show: true }
|
||||
{ prop: 'checkErrorCount', label: '不合规数量', show: true },
|
||||
{ prop: 'checkTimeConsuming', label: '耗时(毫秒)', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
@@ -157,6 +166,7 @@
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
checkDate: moment(moment().add(0, 'days').startOf('day').valueOf()).format('YYYY-MM-DD')
|
||||
},
|
||||
pickerOption: {
|
||||
@@ -190,6 +200,7 @@
|
||||
pageCheckReport(this.queryParams).then(response => {
|
||||
this.loading = false
|
||||
if (response.success) {
|
||||
console.log('response',response)
|
||||
const { data } = response
|
||||
this.tableDataList = data.data
|
||||
this.total = data.total
|
||||
@@ -199,7 +210,16 @@
|
||||
handleReport(row) {
|
||||
this.showOptions.data = row
|
||||
this.showOptions.showList = false
|
||||
this.showOptions.showDetail = true
|
||||
if (row.checkReportType === 'relevance') {
|
||||
// 关联符合性
|
||||
this.showOptions.showDetail_relevance = true
|
||||
} else if (row.checkReportType === 'content') {
|
||||
// 内容符合性
|
||||
this.showOptions.showDetail_content = true
|
||||
} else {
|
||||
// 结构符合性
|
||||
this.showOptions.showDetail = true
|
||||
}
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
handleSizeChange(val) {
|
||||
@@ -216,8 +236,10 @@
|
||||
checkReportTypeFormatter(row, column, cellValue, index) {
|
||||
if (cellValue === 'structure') {
|
||||
return '结构符合性检测报告'
|
||||
} else {
|
||||
} else if (cellValue === 'content') {
|
||||
return '内容符合性检测报告'
|
||||
} else {
|
||||
return '关联符合性检测报告'
|
||||
}
|
||||
},
|
||||
checkResultFormatter(row, column, cellValue, index) {
|
||||
|
||||
@@ -1,248 +1,219 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<div slot="header" class="clearfix">
|
||||
<el-button-group style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-download">导出</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<h4 style="text-align: center;">{{ date }}{{ data.checkReportType === 'structure' ? '结构符合性' : '内容符合性' }}检测结果报告</h4>
|
||||
<el-divider content-position="left"><h3>检测指标统计分析</h3></el-divider>
|
||||
<el-row :gutter="20">
|
||||
<div>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic
|
||||
group-separator=","
|
||||
:precision="0"
|
||||
:value="data.checkTotalCount"
|
||||
title="检测表总数"
|
||||
></el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic title="检测总耗时(毫秒)">
|
||||
<template slot="formatter">
|
||||
{{ data.checkTimeConsuming }}
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic
|
||||
group-separator=","
|
||||
:precision="0"
|
||||
decimal-separator="."
|
||||
:value="data.checkErrorCount"
|
||||
title="不合规总数"
|
||||
>
|
||||
<template slot="prefix">
|
||||
<i class="el-icon-s-flag" style="color: red"></i>
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic title="不合规率">
|
||||
<template slot="prefix">
|
||||
<span class="like">
|
||||
<i class="el-icon-star-on" style="color:red"></i>
|
||||
</span>
|
||||
</template>
|
||||
<template slot="formatter">
|
||||
{{ (data.checkErrorCount / data.checkTotalCount * 100) + '%' }}
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-divider content-position="left"><h3>不合规统计分析</h3></el-divider>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="10">
|
||||
<h5>按数据源统计不合规数量</h5>
|
||||
<el-table
|
||||
:data="reportTableData1"
|
||||
:span-method="objectSpanMethod1"
|
||||
border
|
||||
default-expand-all
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<div class="hasTagsView">
|
||||
<div class="app-main">
|
||||
|
||||
<el-card class="box-card">
|
||||
<div slot="header" class="clearfix">
|
||||
<div style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-download" @click="exportWord">导出</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</div>
|
||||
</div><!--header-->
|
||||
|
||||
|
||||
|
||||
<h4 class="ftitle">结构符合性检测结果报告</h4><!--ftitle 一级标题-->
|
||||
|
||||
<div class="stitle">检测指标统计分析</div><!--stitle 二级标题-->
|
||||
<div class="test-list">
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon1.svg"><span class="tit">检测表总数</span></div>
|
||||
<!-- <div class="figure">{{ data.checkTotalCount_new }}</div>-->
|
||||
<div class="figure" >{{ checkTotalCount_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon2.svg"><span class="tit">检测总耗时(毫秒)</span></div>
|
||||
<!-- <div class="figure">{{ data.checkTimeConsuming_new }}</div>-->
|
||||
<div class="figure">{{ checkTimeConsuming_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon3.svg"><span class="tit">不合规总数</span></div>
|
||||
<!-- <div class="figure">{{ data.checkErrorCount_new }}</div>-->
|
||||
<div class="figure">{{ checkErrorCount_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon4.svg"><span class="tit">不合规率</span></div>
|
||||
<div class="figure">{{ (checkErrorCount_new / checkTotalCount_new * 100).toFixed(2) + '%' }}</div>
|
||||
<!-- <div class="figure">{{ data.checkTotalCount_new }}</div>-->
|
||||
|
||||
</div>
|
||||
</div><!--test-list-->
|
||||
|
||||
<div class="stitle">不合规统计分析</div><!--stitle 二级标题-->
|
||||
<el-row :gutter="24">
|
||||
<el-col :span="12">
|
||||
<div class="ttitle">按数据源统计不合规数量</div><!--ttitle 三级标题-->
|
||||
<el-table :data="reportTableData1" border style="width: 100%" class="btable"><!--加上btable-->
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleLevelName" label="数据源版本" align="center" />
|
||||
<el-table-column prop="tableSum" label="检测表数" align="center" />
|
||||
<el-table-column prop="tableTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-progress :percentage="scope.row.checkErrorCount" :stroke-width="20" :text-inside="true" :color="colorFormat(scope.row.ruleLevelName)" :format="cellFormat" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<div class="ttitle">按用例类型统计不合规数量</div><!--ttitle 三级标题-->
|
||||
<el-table :data="reportTableData2" border style="width: 100%" class="btable"><!--加上btable-->
|
||||
<!-- <el-table-column prop="ta1" label="数据源">数据平台</el-table-column>-->
|
||||
<el-table-column prop="ruleName" label="用例类型"></el-table-column>
|
||||
<el-table-column prop="checkErrorCount" label="不合规数">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<div class="stitle">用例类型统计分析</div><!--stitle 二级标题-->
|
||||
|
||||
<div class="dbox">
|
||||
<div class="ttitle">表字段标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="table_key" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleLevelName" label="规则级别" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-progress :percentage="scope.row.checkErrorCount" :stroke-width="20" :text-inside="true" :color="colorFormat(scope.row.ruleLevelName)" :format="cellFormat" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<h5>按规则类型统计不合规数量</h5>
|
||||
<el-table
|
||||
:data="reportTableData2"
|
||||
:span-method="objectSpanMethod2"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleTypeName" label="规则类型" align="center" />
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-badge :value="scope.row.ruleLevelName" :type="typeFormat(scope.row.ruleLevelName)">
|
||||
{{ scope.row.checkErrorCount }}
|
||||
</el-badge>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-divider content-position="left"><h3>规则类型统计分析</h3></el-divider>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>唯一性分析</h5>
|
||||
<el-table
|
||||
:data="uniqueTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>完整性分析</h5>
|
||||
<el-table
|
||||
:data="integrityTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_table_key" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueTableName" label="实际表名" align="center" />
|
||||
<el-table-column prop="standardTableName" label="标准表名" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
<div class="dbox">
|
||||
<div class="ttitle">长度标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="length_key" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>一致性分析</h5>
|
||||
<el-table
|
||||
:data="consistentTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_length_key" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardLength" label="标准长度" align="center" />
|
||||
<el-table-column prop="trueLength" label="实际长度" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
<div class="dbox">
|
||||
<div class="ttitle">空值标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="null_key" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>关联性分析</h5>
|
||||
<el-table
|
||||
:data="relevanceTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_null_key" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardNull" label="标准字段是否空值" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="trueNull" label="实际字段是否空值" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
<div class="dbox">
|
||||
<div class="ttitle">主键标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="pk_key" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>及时性分析</h5>
|
||||
<el-table
|
||||
:data="timelinessTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_pk_key" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardPk" label="标准字段是否主键" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="truePk" label="实际字段是否主键" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
|
||||
<div class="dbox">
|
||||
<div class="ttitle">外键标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="fk_key" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>准确性分析</h5>
|
||||
<el-table
|
||||
:data="accuracyTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_fk_key" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardFk" label="标准字段是否外键" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="trueFk" label="实际字段是否外键" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
|
||||
</el-card><!--el-card-->
|
||||
|
||||
</div><!--app-main-->
|
||||
</div><!--hasTagsView-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getReportBySource, getReportByType, getReportDetail } from '@/api/quality/checkreport'
|
||||
import moment from 'moment'
|
||||
|
||||
import dataJson from './Data.json'
|
||||
export default {
|
||||
name: 'CheckReportStructure',
|
||||
props: {
|
||||
@@ -288,6 +259,48 @@
|
||||
relevanceTableData: [],
|
||||
// 及时性核查数据
|
||||
timelinessTableData: [],
|
||||
|
||||
// 表字段标准检测
|
||||
table_key: [],
|
||||
no_table_key: [],
|
||||
// 长度标准检测
|
||||
length_key: [],
|
||||
no_length_key: [],
|
||||
// 空值标准检测
|
||||
null_key: [],
|
||||
no_null_key: [],
|
||||
// 主键标准检测
|
||||
pk_key: [],
|
||||
no_pk_key: [],
|
||||
// 外键标准检测
|
||||
fk_key: [],
|
||||
no_fk_key: [],
|
||||
// 完整性标准检测
|
||||
integrity: [],
|
||||
no_integrity: [],
|
||||
// 准确性标准检测
|
||||
accuracy: [],
|
||||
no_accuracy: [],
|
||||
// 一致性标准检测
|
||||
consistent: [],
|
||||
no_consistent: [],
|
||||
// 正则表达式标准检测
|
||||
regular: [],
|
||||
no_regular: [],
|
||||
// 检测表总数
|
||||
checkTotalCount: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming: null,
|
||||
// 不合规总数
|
||||
checkErrorCount: null,
|
||||
|
||||
// 检测表总数
|
||||
checkTotalCount_new: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming_new: null,
|
||||
// 不合规总数
|
||||
checkErrorCount_new: null,
|
||||
|
||||
like: true,
|
||||
value1: 4154.564,
|
||||
totalTables: 1314,
|
||||
@@ -298,6 +311,47 @@
|
||||
this.queryParams.checkDate = moment(this.data.checkDate).format('YYYY-MM-DD')
|
||||
this.handleQuery()
|
||||
},
|
||||
mounted () {
|
||||
// 表字段标准检测
|
||||
this.table_key = dataJson.caseType.table_key
|
||||
this.no_table_key = dataJson.caseType.no_table_key
|
||||
// 长度标准检测
|
||||
this.length_key = dataJson.caseType.length_key
|
||||
this.no_length_key = dataJson.caseType.no_length_key
|
||||
// 空值标准检测
|
||||
this.null_key = dataJson.caseType.null_key
|
||||
this.no_null_key = dataJson.caseType.no_null_key
|
||||
// 主键标准检测
|
||||
this.pk_key = dataJson.caseType.pk_key
|
||||
this.no_pk_key = dataJson.caseType.no_pk_key
|
||||
// 外键标准检测
|
||||
this.fk_key = dataJson.caseType.fk_key
|
||||
this.no_fk_key = dataJson.caseType.no_fk_key
|
||||
// 完整性标准检测
|
||||
this.integrity = dataJson.caseType.integrity
|
||||
this.no_integrity = dataJson.caseType.no_integrity
|
||||
// 准确性标准检测
|
||||
this.accuracy = dataJson.caseType.accuracy
|
||||
this.no_accuracy = dataJson.caseType.no_accuracy
|
||||
// 一致性标准检测
|
||||
this.consistent = dataJson.caseType.consistent
|
||||
this.no_consistent = dataJson.caseType.no_consistent
|
||||
// 正则表达式标准检测
|
||||
this.regular = dataJson.caseType.regular
|
||||
this.no_regular = dataJson.caseType.no_regular
|
||||
|
||||
// 初始化按数据源统计不合规数量
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
this.reportTableData1 = dataJson.dataReport.reportTableData1
|
||||
this.reportTableData2 = dataJson.dataReport.reportTableData2
|
||||
this.rowspan1()
|
||||
this.rowspan2()
|
||||
|
||||
this.checkTotalCount_new = dataJson.checkTotalCount
|
||||
this.checkTimeConsuming_new = dataJson.checkTimeConsuming
|
||||
this.checkErrorCount_new = dataJson.checkErrorCount
|
||||
},
|
||||
methods: {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
@@ -305,27 +359,29 @@
|
||||
handleQuery() {
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
this.getReportData1()
|
||||
this.getReportData2()
|
||||
this.getReportData3()
|
||||
this.date = moment(this.queryParams.checkDate).format('YYYY年MM月DD日')
|
||||
},
|
||||
getReportData1() {
|
||||
getReportBySource({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
if (response.success) {
|
||||
this.reportTableData1 = response.data
|
||||
this.rowspan1()
|
||||
}
|
||||
})
|
||||
},
|
||||
getReportData2() {
|
||||
getReportByType({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
if (response.success) {
|
||||
this.reportTableData2 = response.data
|
||||
this.rowspan2()
|
||||
}
|
||||
})
|
||||
// this.getReportData1()
|
||||
// this.getReportData2()
|
||||
// this.getReportData3()
|
||||
// this.date = moment(this.queryParams.checkDate).format('YYYY年MM月DD日')
|
||||
},
|
||||
// getReportData1() {
|
||||
// getReportBySource({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData1 = response.data
|
||||
// console.log('reportTableData1==', this.reportTableData1)
|
||||
// this.rowspan1()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
// getReportData2() {
|
||||
// getReportByType({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData2 = response.data
|
||||
// console.log('this.reportTableData2===', this.reportTableData2)
|
||||
// this.rowspan2()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
rowspan1() {
|
||||
this.reportTableData1.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
@@ -410,6 +466,15 @@
|
||||
this.timelinessTableData = response.data.timeliness
|
||||
}
|
||||
})
|
||||
},
|
||||
exportWord() {
|
||||
const filePath = './static/your-word-document.docx'
|
||||
const link = document.createElement('a')
|
||||
link.href = filePath
|
||||
link.download = '测结果报告.docx'
|
||||
document.body.appendChild(link)
|
||||
link.click()
|
||||
document.body.removeChild(link)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
435
src/views/quality/checkreport/CheckReportStructure_bak.vue
Normal file
435
src/views/quality/checkreport/CheckReportStructure_bak.vue
Normal file
@@ -0,0 +1,435 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<div slot="header" class="clearfix">
|
||||
<el-button-group style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-download">导出</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<h4 style="text-align: center;">{{ date }}{{ data.checkReportType === 'structure' ? '结构符合性' : '内容符合性' }}检测结果报告</h4>
|
||||
<el-divider content-position="left"><h3>检测指标统计分析</h3></el-divider>
|
||||
<el-row :gutter="20">
|
||||
<div>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic
|
||||
group-separator=","
|
||||
:precision="0"
|
||||
:value="data.checkTotalCount"
|
||||
title="检测表总数"
|
||||
></el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic title="检测总耗时(毫秒)">
|
||||
<template slot="formatter">
|
||||
{{ data.checkTimeConsuming }}
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic
|
||||
group-separator=","
|
||||
:precision="0"
|
||||
decimal-separator="."
|
||||
:value="data.checkErrorCount"
|
||||
title="不合规总数"
|
||||
>
|
||||
<template slot="prefix">
|
||||
<i class="el-icon-s-flag" style="color: red"></i>
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic title="不合规率">
|
||||
<template slot="prefix">
|
||||
<span class="like">
|
||||
<i class="el-icon-star-on" style="color:red"></i>
|
||||
</span>
|
||||
</template>
|
||||
<template slot="formatter">
|
||||
{{ (data.checkErrorCount / data.checkTotalCount * 100) + '%' }}
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-divider content-position="left"><h3>不合规统计分析</h3></el-divider>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="10">
|
||||
<h5>按数据源统计不合规数量</h5>
|
||||
<el-table
|
||||
:data="reportTableData1"
|
||||
:span-method="objectSpanMethod1"
|
||||
border
|
||||
default-expand-all
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleLevelName" label="规则级别" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-progress :percentage="scope.row.checkErrorCount" :stroke-width="20" :text-inside="true" :color="colorFormat(scope.row.ruleLevelName)" :format="cellFormat" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<h5>按用例类型统计不合规数量</h5>
|
||||
<el-table
|
||||
:data="reportTableData2"
|
||||
:span-method="objectSpanMethod2"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleTypeName" label="用例类型" align="center" />
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-badge :value="scope.row.ruleLevelName" :type="typeFormat(scope.row.ruleLevelName)">
|
||||
{{ scope.row.checkErrorCount }}
|
||||
</el-badge>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-divider content-position="left"><h3>用例类型统计分析</h3></el-divider>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>唯一性分析</h5>
|
||||
<el-table
|
||||
:data="uniqueTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>完整性分析</h5>
|
||||
<el-table
|
||||
:data="integrityTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>一致性分析</h5>
|
||||
<el-table
|
||||
:data="consistentTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>关联性分析</h5>
|
||||
<el-table
|
||||
:data="relevanceTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>及时性分析</h5>
|
||||
<el-table
|
||||
:data="timelinessTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>准确性分析</h5>
|
||||
<el-table
|
||||
:data="accuracyTableData"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="规则名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleTableName" label="数据表(英文)" align="center" />
|
||||
<el-table-column prop="ruleTableComment" label="数据表(中文)" align="center" />
|
||||
<el-table-column prop="ruleColumnName" label="核查字段(英文)" align="center" />
|
||||
<el-table-column prop="ruleColumnComment" label="核查字段(中文)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="核查数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getReportBySource, getReportByType, getReportDetail } from '@/api/quality/checkreport'
|
||||
import moment from 'moment'
|
||||
|
||||
export default {
|
||||
name: 'CheckReportStructure',
|
||||
props: {
|
||||
data: {
|
||||
type: Object,
|
||||
default: function() {
|
||||
return {}
|
||||
}
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
queryParams: {
|
||||
checkDate: ''
|
||||
},
|
||||
pickerOption: {
|
||||
disabledDate(date) {
|
||||
return date.getTime() > Date.now()
|
||||
}
|
||||
},
|
||||
date: '',
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
showList: true,
|
||||
showDetail: false
|
||||
},
|
||||
spanArr1: [],
|
||||
position1: 0,
|
||||
reportTableData1: [],
|
||||
spanArr2: [],
|
||||
position2: 0,
|
||||
reportTableData2: [],
|
||||
// 唯一性核查数据
|
||||
uniqueTableData: [],
|
||||
// 完整性核查数据
|
||||
integrityTableData: [],
|
||||
// 准确性核查数据
|
||||
accuracyTableData: [],
|
||||
// 一致性核查数据
|
||||
consistentTableData: [],
|
||||
// 关联性核查数据
|
||||
relevanceTableData: [],
|
||||
// 及时性核查数据
|
||||
timelinessTableData: [],
|
||||
like: true,
|
||||
value1: 4154.564,
|
||||
totalTables: 1314,
|
||||
title: '增长人数'
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.queryParams.checkDate = moment(this.data.checkDate).format('YYYY-MM-DD')
|
||||
this.handleQuery()
|
||||
},
|
||||
methods: {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
handleQuery() {
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
this.getReportData1()
|
||||
this.getReportData2()
|
||||
this.getReportData3()
|
||||
this.date = moment(this.queryParams.checkDate).format('YYYY年MM月DD日')
|
||||
},
|
||||
getReportData1() {
|
||||
getReportBySource({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
if (response.success) {
|
||||
this.reportTableData1 = response.data
|
||||
this.rowspan1()
|
||||
}
|
||||
})
|
||||
},
|
||||
getReportData2() {
|
||||
getReportByType({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
if (response.success) {
|
||||
this.reportTableData2 = response.data
|
||||
this.rowspan2()
|
||||
}
|
||||
})
|
||||
},
|
||||
rowspan1() {
|
||||
this.reportTableData1.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = 0
|
||||
} else {
|
||||
if (this.reportTableData1[index].ruleSourceId === this.reportTableData1[index - 1].ruleSourceId) {
|
||||
this.spanArr1[this.position1] += 1
|
||||
this.spanArr1.push(0)
|
||||
} else {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod1({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr1[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
rowspan2() {
|
||||
this.reportTableData2.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = 0
|
||||
} else {
|
||||
if (this.reportTableData2[index].ruleTypeId === this.reportTableData2[index - 1].ruleTypeId) {
|
||||
this.spanArr2[this.position2] += 1
|
||||
this.spanArr2.push(0)
|
||||
} else {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod2({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr2[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
colorFormat(level) {
|
||||
if (level === '低') {
|
||||
return '#409eff'
|
||||
} else if (level === '中') {
|
||||
return '#e6a23c'
|
||||
} else {
|
||||
return '#f56c6c'
|
||||
}
|
||||
},
|
||||
cellFormat(percentage) {
|
||||
return `${percentage}`
|
||||
},
|
||||
typeFormat(level) {
|
||||
if (level === '低') {
|
||||
return 'primary'
|
||||
} else if (level === '中') {
|
||||
return 'warning'
|
||||
} else {
|
||||
return 'danger'
|
||||
}
|
||||
},
|
||||
getReportData3() {
|
||||
getReportDetail({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
if (response.success) {
|
||||
this.uniqueTableData = response.data.unique
|
||||
this.integrityTableData = response.data.integrity
|
||||
this.accuracyTableData = response.data.accuracy
|
||||
this.consistentTableData = response.data.consistent
|
||||
this.relevanceTableData = response.data.relevance
|
||||
this.timelinessTableData = response.data.timeliness
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-card ::v-deep .el-card__body {
|
||||
height: calc(100vh - 230px);
|
||||
overflow-y: auto;
|
||||
}
|
||||
.form-inline {
|
||||
::v-deep .el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
}
|
||||
::v-deep .el-badge__content {
|
||||
margin-top: 10px;
|
||||
right: 0px;
|
||||
}
|
||||
::v-deep .el-table__header th {
|
||||
background-color: #f5f5f5 !important;
|
||||
}
|
||||
</style>
|
||||
750
src/views/quality/checkreport/CheckReportStructure_bak1.vue
Normal file
750
src/views/quality/checkreport/CheckReportStructure_bak1.vue
Normal file
@@ -0,0 +1,750 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<div slot="header" class="clearfix">
|
||||
<div style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-download" @click="exportWord">导出</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<h4 style="text-align: center;">{{ date }}{{ data.checkReportType === 'structure' ? '结构符合性' : '内容符合性' }}检测结果报告</h4>
|
||||
<el-divider content-position="left"><h3>检测指标统计分析</h3></el-divider>
|
||||
<el-row :gutter="20">
|
||||
<div>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic
|
||||
group-separator=","
|
||||
:precision="0"
|
||||
:value="data.checkTotalCount"
|
||||
title="检测表总数"
|
||||
></el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic title="检测总耗时(毫秒)">
|
||||
<template slot="formatter">
|
||||
{{ data.checkTimeConsuming }}
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic
|
||||
group-separator=","
|
||||
:precision="0"
|
||||
decimal-separator="."
|
||||
:value="data.checkErrorCount"
|
||||
title="不合规总数"
|
||||
>
|
||||
<template slot="prefix">
|
||||
<i class="el-icon-s-flag" style="color: red"></i>
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div>
|
||||
<el-statistic title="不合规率">
|
||||
<template slot="prefix">
|
||||
<span class="like">
|
||||
<i class="el-icon-star-on" style="color:red"></i>
|
||||
</span>
|
||||
</template>
|
||||
<template slot="formatter">
|
||||
{{ (data.checkErrorCount / data.checkTotalCount * 100) + '%' }}
|
||||
</template>
|
||||
</el-statistic>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-divider content-position="left"><h3>不合规统计分析</h3></el-divider>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="10">
|
||||
<h5>按数据源统计不合规数量</h5>
|
||||
<el-table
|
||||
:data="reportTableData1"
|
||||
:span-method="objectSpanMethod1"
|
||||
border
|
||||
default-expand-all
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleLevelName" label="规则级别" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-progress :percentage="scope.row.checkErrorCount" :stroke-width="20" :text-inside="true" :color="colorFormat(scope.row.ruleLevelName)" :format="cellFormat" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
<el-col :span="10" :offset="4">
|
||||
<h5>按用例类型统计不合规数量</h5>
|
||||
<el-table
|
||||
:data="reportTableData2"
|
||||
:span-method="objectSpanMethod2"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleTypeName" label="用例类型" align="center" />
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-badge :value="scope.row.ruleLevelName" :type="typeFormat(scope.row.ruleLevelName)">
|
||||
{{ scope.row.checkErrorCount }}
|
||||
</el-badge>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-divider content-position="left"><h3>用例类型统计分析</h3></el-divider>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>表字段标准检测</h5>
|
||||
<el-table
|
||||
:data="table_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_table_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueTableName" label="实际表名" align="center" />
|
||||
<el-table-column prop="standardTableName" label="标准表名" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>长度标准检测</h5>
|
||||
<el-table
|
||||
:data="length_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_length_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardLength" label="标准长度" align="center" />
|
||||
<el-table-column prop="trueLength" label="实际长度" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>空值标准检测</h5>
|
||||
<el-table
|
||||
:data="null_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_null_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardNull" label="标准字段是否空值" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="trueNull" label="实际字段是否空值" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>主键标准检测</h5>
|
||||
<el-table
|
||||
:data="pk_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_pk_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardPk" label="标准字段是否主键" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="truePk" label="实际字段是否主键" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>外键标准检测</h5>
|
||||
<el-table
|
||||
:data="fk_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_fk_key"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardFk" label="标准字段是否外键" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="trueFk" label="实际字段是否外键" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>完整性标准检测</h5>
|
||||
<el-table
|
||||
:data="integrity"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_integrity"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>准确性标准检测</h5>
|
||||
<el-table
|
||||
:data="accuracy"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_accuracy"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>一致性标准检测</h5>
|
||||
<el-table
|
||||
:data="consistent"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_consistent"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<h5>正则表达式标准检测</h5>
|
||||
<el-table
|
||||
:data="regular"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="版本" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse accordion>
|
||||
<el-collapse-item>
|
||||
<template slot="title">
|
||||
<i class="el-icon-document"></i> 不合规明细
|
||||
</template>
|
||||
<el-table
|
||||
:data="no_regular"
|
||||
border
|
||||
tooltip-effect="dark"
|
||||
:max-height="250"
|
||||
style="width: 100%; margin: 15px 0;"
|
||||
>
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="dataColumn" label="字段值" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getReportBySource, getReportByType, getReportDetail } from '@/api/quality/checkreport'
|
||||
import moment from 'moment'
|
||||
import dataJson from './Data.json'
|
||||
export default {
|
||||
name: 'CheckReportStructure',
|
||||
props: {
|
||||
data: {
|
||||
type: Object,
|
||||
default: function() {
|
||||
return {}
|
||||
}
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
queryParams: {
|
||||
checkDate: ''
|
||||
},
|
||||
pickerOption: {
|
||||
disabledDate(date) {
|
||||
return date.getTime() > Date.now()
|
||||
}
|
||||
},
|
||||
date: '',
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
showList: true,
|
||||
showDetail: false
|
||||
},
|
||||
spanArr1: [],
|
||||
position1: 0,
|
||||
reportTableData1: [],
|
||||
spanArr2: [],
|
||||
position2: 0,
|
||||
reportTableData2: [],
|
||||
// 唯一性核查数据
|
||||
uniqueTableData: [],
|
||||
// 完整性核查数据
|
||||
integrityTableData: [],
|
||||
// 准确性核查数据
|
||||
accuracyTableData: [],
|
||||
// 一致性核查数据
|
||||
consistentTableData: [],
|
||||
// 关联性核查数据
|
||||
relevanceTableData: [],
|
||||
// 及时性核查数据
|
||||
timelinessTableData: [],
|
||||
|
||||
// 表字段标准检测
|
||||
table_key: [],
|
||||
no_table_key: [],
|
||||
// 长度标准检测
|
||||
length_key: [],
|
||||
no_length_key: [],
|
||||
// 空值标准检测
|
||||
null_key: [],
|
||||
no_null_key: [],
|
||||
// 主键标准检测
|
||||
pk_key: [],
|
||||
no_pk_key: [],
|
||||
// 外键标准检测
|
||||
fk_key: [],
|
||||
no_fk_key: [],
|
||||
// 完整性标准检测
|
||||
integrity: [],
|
||||
no_integrity: [],
|
||||
// 准确性标准检测
|
||||
accuracy: [],
|
||||
no_accuracy: [],
|
||||
// 一致性标准检测
|
||||
consistent: [],
|
||||
no_consistent: [],
|
||||
// 正则表达式标准检测
|
||||
regular: [],
|
||||
no_regular: [],
|
||||
// 检测表总数
|
||||
checkTotalCount: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming: null,
|
||||
// 不合规总数
|
||||
checkErrorCount: null,
|
||||
|
||||
like: true,
|
||||
value1: 4154.564,
|
||||
totalTables: 1314,
|
||||
title: '增长人数'
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.queryParams.checkDate = moment(this.data.checkDate).format('YYYY-MM-DD')
|
||||
this.handleQuery()
|
||||
},
|
||||
mounted () {
|
||||
// 表字段标准检测
|
||||
this.table_key = dataJson.caseType.table_key
|
||||
this.no_table_key = dataJson.caseType.no_table_key
|
||||
// 长度标准检测
|
||||
this.length_key = dataJson.caseType.length_key
|
||||
this.no_length_key = dataJson.caseType.no_length_key
|
||||
// 空值标准检测
|
||||
this.null_key = dataJson.caseType.null_key
|
||||
this.no_null_key = dataJson.caseType.no_null_key
|
||||
// 主键标准检测
|
||||
this.pk_key = dataJson.caseType.pk_key
|
||||
this.no_pk_key = dataJson.caseType.no_pk_key
|
||||
// 外键标准检测
|
||||
this.fk_key = dataJson.caseType.fk_key
|
||||
this.no_fk_key = dataJson.caseType.no_fk_key
|
||||
// 完整性标准检测
|
||||
this.integrity = dataJson.caseType.integrity
|
||||
this.no_integrity = dataJson.caseType.no_integrity
|
||||
// 准确性标准检测
|
||||
this.accuracy = dataJson.caseType.accuracy
|
||||
this.no_accuracy = dataJson.caseType.no_accuracy
|
||||
// 一致性标准检测
|
||||
this.consistent = dataJson.caseType.consistent
|
||||
this.no_consistent = dataJson.caseType.no_consistent
|
||||
// 正则表达式标准检测
|
||||
this.regular = dataJson.caseType.regular
|
||||
this.no_regular = dataJson.caseType.no_regular
|
||||
|
||||
// 初始化按数据源统计不合规数量
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
this.reportTableData1 = dataJson.dataReport.reportTableData1
|
||||
this.reportTableData2 = dataJson.dataReport.reportTableData2
|
||||
this.rowspan1()
|
||||
this.rowspan2()
|
||||
},
|
||||
methods: {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
handleQuery() {
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
// this.getReportData1()
|
||||
this.getReportData2()
|
||||
this.getReportData3()
|
||||
this.date = moment(this.queryParams.checkDate).format('YYYY年MM月DD日')
|
||||
},
|
||||
// getReportData1() {
|
||||
// getReportBySource({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData1 = response.data
|
||||
// console.log('reportTableData1==', this.reportTableData1)
|
||||
// this.rowspan1()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
// getReportData2() {
|
||||
// getReportByType({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData2 = response.data
|
||||
// console.log('this.reportTableData2===', this.reportTableData2)
|
||||
// this.rowspan2()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
rowspan1() {
|
||||
this.reportTableData1.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = 0
|
||||
} else {
|
||||
if (this.reportTableData1[index].ruleSourceId === this.reportTableData1[index - 1].ruleSourceId) {
|
||||
this.spanArr1[this.position1] += 1
|
||||
this.spanArr1.push(0)
|
||||
} else {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod1({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr1[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
rowspan2() {
|
||||
this.reportTableData2.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = 0
|
||||
} else {
|
||||
if (this.reportTableData2[index].ruleTypeId === this.reportTableData2[index - 1].ruleTypeId) {
|
||||
this.spanArr2[this.position2] += 1
|
||||
this.spanArr2.push(0)
|
||||
} else {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod2({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr2[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
colorFormat(level) {
|
||||
if (level === '低') {
|
||||
return '#409eff'
|
||||
} else if (level === '中') {
|
||||
return '#e6a23c'
|
||||
} else {
|
||||
return '#f56c6c'
|
||||
}
|
||||
},
|
||||
cellFormat(percentage) {
|
||||
return `${percentage}`
|
||||
},
|
||||
typeFormat(level) {
|
||||
if (level === '低') {
|
||||
return 'primary'
|
||||
} else if (level === '中') {
|
||||
return 'warning'
|
||||
} else {
|
||||
return 'danger'
|
||||
}
|
||||
},
|
||||
getReportData3() {
|
||||
getReportDetail({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
if (response.success) {
|
||||
this.uniqueTableData = response.data.unique
|
||||
this.integrityTableData = response.data.integrity
|
||||
this.accuracyTableData = response.data.accuracy
|
||||
this.consistentTableData = response.data.consistent
|
||||
this.relevanceTableData = response.data.relevance
|
||||
this.timelinessTableData = response.data.timeliness
|
||||
}
|
||||
})
|
||||
},
|
||||
exportWord() {
|
||||
const filePath = './static/your-word-document.docx'
|
||||
const link = document.createElement('a')
|
||||
link.href = filePath
|
||||
link.download = '测结果报告.docx'
|
||||
document.body.appendChild(link)
|
||||
link.click()
|
||||
document.body.removeChild(link)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-card ::v-deep .el-card__body {
|
||||
height: calc(100vh - 230px);
|
||||
overflow-y: auto;
|
||||
}
|
||||
.form-inline {
|
||||
::v-deep .el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
}
|
||||
::v-deep .el-badge__content {
|
||||
margin-top: 10px;
|
||||
right: 0px;
|
||||
}
|
||||
::v-deep .el-table__header th {
|
||||
background-color: #f5f5f5 !important;
|
||||
}
|
||||
</style>
|
||||
465
src/views/quality/checkreport/CheckReportStructure_content.vue
Normal file
465
src/views/quality/checkreport/CheckReportStructure_content.vue
Normal file
@@ -0,0 +1,465 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<div class="hasTagsView">
|
||||
<div class="app-main">
|
||||
|
||||
<el-card class="box-card">
|
||||
<div slot="header" class="clearfix">
|
||||
<div style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-download" @click="exportWord">导出</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</div>
|
||||
</div><!--header-->
|
||||
<h4 class="ftitle">内容符合性检测结果报告</h4><!--ftitle 一级标题-->
|
||||
|
||||
<div class="stitle">检测指标统计分析</div><!--stitle 二级标题-->
|
||||
<div class="test-list">
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon1.svg"><span class="tit">检测内容条数</span></div>
|
||||
<!-- <div class="figure">{{ data.checkTotalCount_new }}</div>-->
|
||||
<div class="figure" >{{ checkTotalCount_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon2.svg"><span class="tit">检测总耗时(毫秒)</span></div>
|
||||
<!-- <div class="figure">{{ data.checkTimeConsuming_new }}</div>-->
|
||||
<div class="figure">{{ checkTimeConsuming_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon3.svg"><span class="tit">不合规总数</span></div>
|
||||
<!-- <div class="figure">{{ data.checkErrorCount_new }}</div>-->
|
||||
<div class="figure">{{ checkErrorCount_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon4.svg"><span class="tit">不合规率</span></div>
|
||||
<div class="figure">{{ (checkErrorCount_new / checkTotalCount_new * 100).toFixed(2) + '%' }}</div>
|
||||
<!-- <div class="figure">{{ data.checkTotalCount_new }}</div>-->
|
||||
|
||||
</div>
|
||||
</div><!--test-list-->
|
||||
|
||||
<div class="stitle">不合规统计分析</div><!--stitle 二级标题-->
|
||||
<el-row :gutter="24">
|
||||
<el-col :span="12">
|
||||
<div class="ttitle">按数据源统计不合规数量</div><!--ttitle 三级标题-->
|
||||
<el-table :data="reportTableData1" border style="width: 100%" class="btable"><!--加上btable-->
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleLevelName" label="数据源版本" align="center" />
|
||||
<el-table-column prop="tableSum" label="检测条数" align="center" />
|
||||
<el-table-column prop="tableTime" label="总耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-progress :percentage="scope.row.checkErrorCount" :stroke-width="20" :text-inside="true" :color="colorFormat(scope.row.ruleLevelName)" :format="cellFormat" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<div class="ttitle">按用例类型统计不合规数量</div><!--ttitle 三级标题-->
|
||||
<el-table :data="reportTableData2" border style="width: 100%" class="btable"><!--加上btable-->
|
||||
<!-- <el-table-column prop="ta1" label="数据源">数据平台</el-table-column>-->
|
||||
<el-table-column prop="ruleName" label="用例类型"></el-table-column>
|
||||
<el-table-column prop="checkErrorCount" label="不合规数">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<div class="stitle">用例类型统计分析</div><!--stitle 二级标题-->
|
||||
<div class="dbox" >
|
||||
<div class="ttitle">完整性标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="integrity" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_integrity" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="tableErrorCount" label="不合规数" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
<div class="dbox" >
|
||||
<div class="ttitle">准确性标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="accuracy" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_accuracy" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="tableErrorCount" label="不合规数" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
<div class="dbox" >
|
||||
<div class="ttitle">一致性标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="consistent" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_consistent" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="tableErrorCount" label="不合规数" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
<div class="dbox" >
|
||||
<div class="ttitle">正则表达式标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="regular" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_regular" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="trueColumn" label="字段名称" align="center" />
|
||||
<el-table-column prop="tableErrorCount" label="不合规数" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
|
||||
</el-card><!--el-card-->
|
||||
|
||||
</div><!--app-main-->
|
||||
</div><!--hasTagsView-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import { getReportBySource, getReportByType, C } from '@/api/quality/checkreport'
|
||||
import moment from 'moment'
|
||||
import dataJson from './Data_content.json'
|
||||
export default {
|
||||
name: 'CheckReportStructureontent',
|
||||
props: {
|
||||
data: {
|
||||
type: Object,
|
||||
default: function() {
|
||||
return {}
|
||||
}
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
queryParams: {
|
||||
checkDate: ''
|
||||
},
|
||||
pickerOption: {
|
||||
disabledDate(date) {
|
||||
return date.getTime() > Date.now()
|
||||
}
|
||||
},
|
||||
date: '',
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
showList: true,
|
||||
showDetail_content: false
|
||||
},
|
||||
spanArr1: [],
|
||||
position1: 0,
|
||||
reportTableData1: [],
|
||||
spanArr2: [],
|
||||
position2: 0,
|
||||
reportTableData2: [],
|
||||
// 唯一性核查数据
|
||||
uniqueTableData: [],
|
||||
// 完整性核查数据
|
||||
integrityTableData: [],
|
||||
// 准确性核查数据
|
||||
accuracyTableData: [],
|
||||
// 一致性核查数据
|
||||
consistentTableData: [],
|
||||
// 关联性核查数据
|
||||
relevanceTableData: [],
|
||||
// 及时性核查数据
|
||||
timelinessTableData: [],
|
||||
|
||||
// 表字段标准检测
|
||||
table_key: [],
|
||||
no_table_key: [],
|
||||
// 长度标准检测
|
||||
length_key: [],
|
||||
no_length_key: [],
|
||||
// 空值标准检测
|
||||
null_key: [],
|
||||
no_null_key: [],
|
||||
// 主键标准检测
|
||||
pk_key: [],
|
||||
no_pk_key: [],
|
||||
// 外键标准检测
|
||||
fk_key: [],
|
||||
no_fk_key: [],
|
||||
// 完整性标准检测
|
||||
integrity: [],
|
||||
no_integrity: [],
|
||||
// 准确性标准检测
|
||||
accuracy: [],
|
||||
no_accuracy: [],
|
||||
// 一致性标准检测
|
||||
consistent: [],
|
||||
no_consistent: [],
|
||||
// 正则表达式标准检测
|
||||
regular: [],
|
||||
no_regular: [],
|
||||
// 检测表总数
|
||||
checkTotalCount: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming: null,
|
||||
// 不合规总数
|
||||
checkErrorCount: null,
|
||||
|
||||
// 检测表总数
|
||||
checkTotalCount_new: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming_new: null,
|
||||
// 不合规总数
|
||||
checkErrorCount_new: null,
|
||||
|
||||
like: true,
|
||||
value1: 4154.564,
|
||||
totalTables: 1314,
|
||||
title: '增长人数'
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.queryParams.checkDate = moment(this.data.checkDate).format('YYYY-MM-DD')
|
||||
this.handleQuery()
|
||||
},
|
||||
mounted () {
|
||||
// 表字段标准检测
|
||||
this.table_key = dataJson.caseType.table_key
|
||||
this.no_table_key = dataJson.caseType.no_table_key
|
||||
// 长度标准检测
|
||||
this.length_key = dataJson.caseType.length_key
|
||||
this.no_length_key = dataJson.caseType.no_length_key
|
||||
// 空值标准检测
|
||||
this.null_key = dataJson.caseType.null_key
|
||||
this.no_null_key = dataJson.caseType.no_null_key
|
||||
// 主键标准检测
|
||||
this.pk_key = dataJson.caseType.pk_key
|
||||
this.no_pk_key = dataJson.caseType.no_pk_key
|
||||
// 外键标准检测
|
||||
this.fk_key = dataJson.caseType.fk_key
|
||||
this.no_fk_key = dataJson.caseType.no_fk_key
|
||||
// 完整性标准检测
|
||||
this.integrity = dataJson.caseType.integrity
|
||||
this.no_integrity = dataJson.caseType.no_integrity
|
||||
// 准确性标准检测
|
||||
this.accuracy = dataJson.caseType.accuracy
|
||||
this.no_accuracy = dataJson.caseType.no_accuracy
|
||||
// 一致性标准检测
|
||||
this.consistent = dataJson.caseType.consistent
|
||||
this.no_consistent = dataJson.caseType.no_consistent
|
||||
// 正则表达式标准检测
|
||||
this.regular = dataJson.caseType.regular
|
||||
this.no_regular = dataJson.caseType.no_regular
|
||||
|
||||
// 初始化按数据源统计不合规数量
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
this.reportTableData1 = dataJson.dataReport.reportTableData1
|
||||
this.reportTableData2 = dataJson.dataReport.reportTableData2
|
||||
this.rowspan1()
|
||||
this.rowspan2()
|
||||
|
||||
this.checkTotalCount_new = dataJson.checkTotalCount
|
||||
this.checkTimeConsuming_new = dataJson.checkTimeConsuming
|
||||
this.checkErrorCount_new = dataJson.checkErrorCount
|
||||
},
|
||||
methods: {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
handleQuery() {
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
// this.getReportData1()
|
||||
// this.getReportData2()
|
||||
// this.getReportData3()
|
||||
// this.date = moment(this.queryParams.checkDate).format('YYYY年MM月DD日')
|
||||
},
|
||||
// getReportData1() {
|
||||
// getReportBySource({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData1 = response.data
|
||||
// console.log('reportTableData1==', this.reportTableData1)
|
||||
// this.rowspan1()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
// getReportData2() {
|
||||
// getReportByType({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData2 = response.data
|
||||
// console.log('this.reportTableData2===', this.reportTableData2)
|
||||
// this.rowspan2()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
rowspan1() {
|
||||
this.reportTableData1.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = 0
|
||||
} else {
|
||||
if (this.reportTableData1[index].ruleSourceId === this.reportTableData1[index - 1].ruleSourceId) {
|
||||
this.spanArr1[this.position1] += 1
|
||||
this.spanArr1.push(0)
|
||||
} else {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod1({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr1[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
rowspan2() {
|
||||
this.reportTableData2.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = 0
|
||||
} else {
|
||||
if (this.reportTableData2[index].ruleTypeId === this.reportTableData2[index - 1].ruleTypeId) {
|
||||
this.spanArr2[this.position2] += 1
|
||||
this.spanArr2.push(0)
|
||||
} else {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod2({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr2[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
colorFormat(level) {
|
||||
if (level === '低') {
|
||||
return '#409eff'
|
||||
} else if (level === '中') {
|
||||
return '#e6a23c'
|
||||
} else {
|
||||
return '#f56c6c'
|
||||
}
|
||||
},
|
||||
cellFormat(percentage) {
|
||||
return `${percentage}`
|
||||
},
|
||||
typeFormat(level) {
|
||||
if (level === '低') {
|
||||
return 'primary'
|
||||
} else if (level === '中') {
|
||||
return 'warning'
|
||||
} else {
|
||||
return 'danger'
|
||||
}
|
||||
},
|
||||
// getReportData3() {
|
||||
// getReportDetail({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.uniqueTableData = response.data.unique
|
||||
// this.integrityTableData = response.data.integrity
|
||||
// this.accuracyTableData = response.data.accuracy
|
||||
// this.consistentTableData = response.data.consistent
|
||||
// this.relevanceTableData = response.data.relevance
|
||||
// this.timelinessTableData = response.data.timeliness
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
exportWord() {
|
||||
const filePath = './static/your-word-document.docx'
|
||||
const link = document.createElement('a')
|
||||
link.href = filePath
|
||||
link.download = '测结果报告.docx'
|
||||
document.body.appendChild(link)
|
||||
link.click()
|
||||
document.body.removeChild(link)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-card ::v-deep .el-card__body {
|
||||
height: calc(100vh - 230px);
|
||||
overflow-y: auto;
|
||||
}
|
||||
.form-inline {
|
||||
::v-deep .el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
}
|
||||
::v-deep .el-badge__content {
|
||||
margin-top: 10px;
|
||||
right: 0px;
|
||||
}
|
||||
::v-deep .el-table__header th {
|
||||
background-color: #f5f5f5 !important;
|
||||
}
|
||||
</style>
|
||||
402
src/views/quality/checkreport/CheckReportStructure_relevance.vue
Normal file
402
src/views/quality/checkreport/CheckReportStructure_relevance.vue
Normal file
@@ -0,0 +1,402 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<div class="hasTagsView">
|
||||
<div class="app-main">
|
||||
|
||||
<el-card class="box-card">
|
||||
<div slot="header" class="clearfix">
|
||||
<div style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-download" @click="exportWord">导出</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</div>
|
||||
</div><!--header-->
|
||||
|
||||
|
||||
|
||||
<h4 class="ftitle">关联符合性检测结果报告</h4><!--ftitle 一级标题-->
|
||||
|
||||
<div class="stitle">检测指标统计分析</div><!--stitle 二级标题-->
|
||||
<div class="test-list">
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon1.svg"><span class="tit">检测表总数</span></div>
|
||||
<!-- <div class="figure">{{ data.checkTotalCount_new }}</div>-->
|
||||
<div class="figure" >{{ checkTotalCount_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon2.svg"><span class="tit">检测总耗时(毫秒)</span></div>
|
||||
<!-- <div class="figure">{{ data.checkTimeConsuming_new }}</div>-->
|
||||
<div class="figure">{{ checkTimeConsuming_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon3.svg"><span class="tit">不合规总数</span></div>
|
||||
<!-- <div class="figure">{{ data.checkErrorCount_new }}</div>-->
|
||||
<div class="figure">{{ checkErrorCount_new }}</div>
|
||||
|
||||
</div>
|
||||
<div class="list">
|
||||
<div class="title"><img src="../../../assets/images/j-icon4.svg"><span class="tit">不合规率</span></div>
|
||||
<div class="figure">{{ (checkErrorCount_new / checkTotalCount_new * 100).toFixed(2) + '%' }}</div>
|
||||
<!-- <div class="figure">{{ data.checkTotalCount_new }}</div>-->
|
||||
|
||||
</div>
|
||||
</div><!--test-list-->
|
||||
|
||||
<div class="stitle">不合规统计分析</div><!--stitle 二级标题-->
|
||||
<el-row :gutter="24">
|
||||
<el-col :span="12">
|
||||
<div class="ttitle">按数据源统计不合规数量</div><!--ttitle 三级标题-->
|
||||
<el-table :data="reportTableData1" border style="width: 100%" class="btable"><!--加上btable-->
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="ruleLevelName" label="数据源版本" align="center" />
|
||||
<el-table-column prop="tableSum" label="检测表数" align="center" />
|
||||
<el-table-column prop="tableTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-progress :percentage="scope.row.checkErrorCount" :stroke-width="20" :text-inside="true" :color="colorFormat(scope.row.ruleLevelName)" :format="cellFormat" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<div class="ttitle">按用例类型统计不合规数量</div><!--ttitle 三级标题-->
|
||||
<el-table :data="reportTableData2" border style="width: 100%" class="btable"><!--加上btable-->
|
||||
<!-- <el-table-column prop="ta1" label="数据源">数据平台</el-table-column>-->
|
||||
<el-table-column prop="ruleName" label="用例类型"></el-table-column>
|
||||
<el-table-column prop="checkErrorCount" label="不合规数">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<div class="stitle">用例类型统计分析</div><!--stitle 二级标题-->
|
||||
<div class="dbox">
|
||||
<div class="ttitle">关联性标准检测用例</div><!--ttitle 三级标题-->
|
||||
<el-table :data="relevancData" border style="width: 100%">
|
||||
<el-table-column prop="ruleName" label="用例名称" align="center" />
|
||||
<el-table-column prop="ruleSourceName" label="数据源" align="center" />
|
||||
<el-table-column prop="version" label="数据源版本" align="center" />
|
||||
<el-table-column prop="checkTotalTime" label="耗时(毫秒)" align="center" />
|
||||
<el-table-column prop="checkTotalCount" label="检测数" align="center" />
|
||||
<el-table-column prop="checkErrorCount" label="不合规数" align="center" />
|
||||
</el-table>
|
||||
<el-collapse @change="handleChange" class="ncoll"><!--加上ncoll-->
|
||||
<el-collapse-item name="1">
|
||||
<template slot="title"><span class="tit">不合规明细</span></template>
|
||||
<el-table :data="no_relevancData" border style="width: 100%">
|
||||
<el-table-column prop="caseName" label="用例名称" align="center" />
|
||||
<el-table-column prop="source" label="数据源" align="center" />
|
||||
<el-table-column prop="tableName" label="数据表" align="center" />
|
||||
<el-table-column prop="standardColumn" label="标准字段" align="center" />
|
||||
<el-table-column prop="standardPk" label="标准字段是否主键" align="center" />
|
||||
<el-table-column prop="standardFk" label="标准字段是否外键" align="center" />
|
||||
<el-table-column prop="trueColumn" label="实际字段" align="center" />
|
||||
<el-table-column prop="truePk" label="实际字段是否主键" align="center" />
|
||||
<el-table-column prop="trueFk" label="实际字段是否外键" align="center" />
|
||||
<el-table-column prop="notDetail" label="不合规原因" align="center" width="200px" />
|
||||
</el-table>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
</div><!--dbox-->
|
||||
</el-card><!--el-card-->
|
||||
|
||||
</div><!--app-main-->
|
||||
</div><!--hasTagsView-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import { getReportBySource, getReportByType, getReportDetail } from '@/api/quality/checkreport'
|
||||
import moment from 'moment'
|
||||
import dataJson from './Data_relevance.json'
|
||||
export default {
|
||||
name: 'CheckReportStructureRelevance',
|
||||
props: {
|
||||
data: {
|
||||
type: Object,
|
||||
default: function() {
|
||||
return {}
|
||||
}
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
queryParams: {
|
||||
checkDate: ''
|
||||
},
|
||||
pickerOption: {
|
||||
disabledDate(date) {
|
||||
return date.getTime() > Date.now()
|
||||
}
|
||||
},
|
||||
date: '',
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
showList: true,
|
||||
showDetail_relevance: false
|
||||
},
|
||||
spanArr1: [],
|
||||
position1: 0,
|
||||
reportTableData1: [],
|
||||
spanArr2: [],
|
||||
position2: 0,
|
||||
reportTableData2: [],
|
||||
// 唯一性核查数据
|
||||
uniqueTableData: [],
|
||||
// 完整性核查数据
|
||||
integrityTableData: [],
|
||||
// 准确性核查数据
|
||||
accuracyTableData: [],
|
||||
// 一致性核查数据
|
||||
consistentTableData: [],
|
||||
// 关联性核查数据
|
||||
relevanceTableData: [],
|
||||
// 及时性核查数据
|
||||
timelinessTableData: [],
|
||||
|
||||
// 表字段标准检测
|
||||
table_key: [],
|
||||
no_table_key: [],
|
||||
// 长度标准检测
|
||||
length_key: [],
|
||||
no_length_key: [],
|
||||
// 空值标准检测
|
||||
null_key: [],
|
||||
no_null_key: [],
|
||||
// 主键标准检测
|
||||
pk_key: [],
|
||||
no_pk_key: [],
|
||||
// 外键标准检测
|
||||
fk_key: [],
|
||||
no_fk_key: [],
|
||||
// 完整性标准检测
|
||||
integrity: [],
|
||||
no_integrity: [],
|
||||
// 准确性标准检测
|
||||
accuracy: [],
|
||||
no_accuracy: [],
|
||||
// 一致性标准检测
|
||||
consistent: [],
|
||||
no_consistent: [],
|
||||
// 正则表达式标准检测
|
||||
regular: [],
|
||||
no_regular: [],
|
||||
// 关联符合性校验
|
||||
relevancData: [],
|
||||
no_relevanceData: [],
|
||||
// 检测表总数
|
||||
checkTotalCount: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming: null,
|
||||
// 不合规总数
|
||||
checkErrorCount: null,
|
||||
|
||||
// 检测表总数
|
||||
checkTotalCount_new: null,
|
||||
// 检测总耗时
|
||||
checkTimeConsuming_new: null,
|
||||
// 不合规总数
|
||||
checkErrorCount_new: null,
|
||||
|
||||
like: true,
|
||||
value1: 4154.564,
|
||||
totalTables: 1314,
|
||||
title: '增长人数'
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.queryParams.checkDate = moment(this.data.checkDate).format('YYYY-MM-DD')
|
||||
this.handleQuery()
|
||||
},
|
||||
mounted () {
|
||||
// 表字段标准检测
|
||||
this.table_key = dataJson.caseType.table_key
|
||||
this.no_table_key = dataJson.caseType.no_table_key
|
||||
// 长度标准检测
|
||||
this.length_key = dataJson.caseType.length_key
|
||||
this.no_length_key = dataJson.caseType.no_length_key
|
||||
// 空值标准检测
|
||||
this.null_key = dataJson.caseType.null_key
|
||||
this.no_null_key = dataJson.caseType.no_null_key
|
||||
// 主键标准检测
|
||||
this.pk_key = dataJson.caseType.pk_key
|
||||
this.no_pk_key = dataJson.caseType.no_pk_key
|
||||
// 外键标准检测
|
||||
this.fk_key = dataJson.caseType.fk_key
|
||||
this.no_fk_key = dataJson.caseType.no_fk_key
|
||||
// 完整性标准检测
|
||||
this.integrity = dataJson.caseType.integrity
|
||||
this.no_integrity = dataJson.caseType.no_integrity
|
||||
// 准确性标准检测
|
||||
this.accuracy = dataJson.caseType.accuracy
|
||||
this.no_accuracy = dataJson.caseType.no_accuracy
|
||||
// 一致性标准检测
|
||||
this.consistent = dataJson.caseType.consistent
|
||||
this.no_consistent = dataJson.caseType.no_consistent
|
||||
// 正则表达式标准检测
|
||||
this.regular = dataJson.caseType.regular
|
||||
this.no_regular = dataJson.caseType.no_regular
|
||||
|
||||
this.relevancData = dataJson.caseType.relevancData
|
||||
this.no_relevancData = dataJson.caseType.no_relevancData
|
||||
|
||||
// 初始化按数据源统计不合规数量
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
this.reportTableData1 = dataJson.dataReport.reportTableData1
|
||||
this.reportTableData2 = dataJson.dataReport.reportTableData2
|
||||
this.rowspan1()
|
||||
this.rowspan2()
|
||||
|
||||
this.checkTotalCount_new = dataJson.checkTotalCount
|
||||
this.checkTimeConsuming_new = dataJson.checkTimeConsuming
|
||||
this.checkErrorCount_new = dataJson.checkErrorCount
|
||||
},
|
||||
methods: {
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
handleQuery() {
|
||||
this.spanArr1 = []
|
||||
this.spanArr2 = []
|
||||
// this.getReportData1()
|
||||
// this.getReportData2()
|
||||
// this.getReportData3()
|
||||
// this.date = moment(this.queryParams.checkDate).format('YYYY年MM月DD日')
|
||||
},
|
||||
// getReportData1() {
|
||||
// getReportBySource({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData1 = response.data
|
||||
// console.log('reportTableData1==', this.reportTableData1)
|
||||
// this.rowspan1()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
// getReportData2() {
|
||||
// getReportByType({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.reportTableData2 = response.data
|
||||
// console.log('this.reportTableData2===', this.reportTableData2)
|
||||
// this.rowspan2()
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
rowspan1() {
|
||||
this.reportTableData1.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = 0
|
||||
} else {
|
||||
if (this.reportTableData1[index].ruleSourceId === this.reportTableData1[index - 1].ruleSourceId) {
|
||||
this.spanArr1[this.position1] += 1
|
||||
this.spanArr1.push(0)
|
||||
} else {
|
||||
this.spanArr1.push(1)
|
||||
this.position1 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod1({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr1[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
rowspan2() {
|
||||
this.reportTableData2.forEach((item, index) => {
|
||||
if (index === 0) {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = 0
|
||||
} else {
|
||||
if (this.reportTableData2[index].ruleTypeId === this.reportTableData2[index - 1].ruleTypeId) {
|
||||
this.spanArr2[this.position2] += 1
|
||||
this.spanArr2.push(0)
|
||||
} else {
|
||||
this.spanArr2.push(1)
|
||||
this.position2 = index
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
objectSpanMethod2({ row, column, rowIndex, columnIndex }) {
|
||||
if (columnIndex === 0) {
|
||||
const _row = this.spanArr2[rowIndex]
|
||||
const _col = _row > 0 ? 1 : 0
|
||||
return {
|
||||
rowspan: _row,
|
||||
colspan: _col
|
||||
}
|
||||
}
|
||||
},
|
||||
colorFormat(level) {
|
||||
if (level === '低') {
|
||||
return '#409eff'
|
||||
} else if (level === '中') {
|
||||
return '#e6a23c'
|
||||
} else {
|
||||
return '#f56c6c'
|
||||
}
|
||||
},
|
||||
cellFormat(percentage) {
|
||||
return `${percentage}`
|
||||
},
|
||||
typeFormat(level) {
|
||||
if (level === '低') {
|
||||
return 'primary'
|
||||
} else if (level === '中') {
|
||||
return 'warning'
|
||||
} else {
|
||||
return 'danger'
|
||||
}
|
||||
},
|
||||
// getReportData3() {
|
||||
// getReportDetail({ checkDate: this.queryParams.checkDate }).then(response => {
|
||||
// if (response.success) {
|
||||
// this.uniqueTableData = response.data.unique
|
||||
// this.integrityTableData = response.data.integrity
|
||||
// this.accuracyTableData = response.data.accuracy
|
||||
// this.consistentTableData = response.data.consistent
|
||||
// this.relevanceTableData = response.data.relevance
|
||||
// this.timelinessTableData = response.data.timeliness
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
exportWord() {
|
||||
const filePath = './static/your-word-document.docx'
|
||||
const link = document.createElement('a')
|
||||
link.href = filePath
|
||||
link.download = '测结果报告.docx'
|
||||
document.body.appendChild(link)
|
||||
link.click()
|
||||
document.body.removeChild(link)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-card ::v-deep .el-card__body {
|
||||
height: calc(100vh - 230px);
|
||||
overflow-y: auto;
|
||||
}
|
||||
.form-inline {
|
||||
::v-deep .el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
}
|
||||
::v-deep .el-badge__content {
|
||||
margin-top: 10px;
|
||||
right: 0px;
|
||||
}
|
||||
::v-deep .el-table__header th {
|
||||
background-color: #f5f5f5 !important;
|
||||
}
|
||||
</style>
|
||||
523
src/views/quality/checkreport/Data.json
Normal file
523
src/views/quality/checkreport/Data.json
Normal file
@@ -0,0 +1,523 @@
|
||||
{
|
||||
"caseType": {
|
||||
"table_key": [
|
||||
{
|
||||
"ruleName": "检测表字段是否一致",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "78",
|
||||
"checkErrorCount": "1"
|
||||
},
|
||||
{
|
||||
"ruleName": "检测表字段名是否与标准一致",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "449",
|
||||
"checkErrorCount": "4"
|
||||
}
|
||||
],
|
||||
"no_table_key": [
|
||||
{
|
||||
"caseName": "检测表字段是否一致",
|
||||
"source": "综合服务",
|
||||
"tableName": "TABLE_A",
|
||||
"trueTableName": "TABLE_A",
|
||||
"standardTableName": "TABLE_A",
|
||||
"trueColumn": "column_AAA",
|
||||
"standardColumn": "column_AAC",
|
||||
"notDetail": "字段名与标准不一致"
|
||||
},
|
||||
{
|
||||
"caseName": "检测表字段是否一致",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_D",
|
||||
"trueTableName": "TABLE_D",
|
||||
"standardTableName": "TABLE_K",
|
||||
"trueColumn": "",
|
||||
"standardColumn": "",
|
||||
"notDetail": "表名与标准不一致"
|
||||
},
|
||||
{
|
||||
"caseName": "检测表字段名是否与标准一致",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_E",
|
||||
"trueTableName": "TABLE_E",
|
||||
"standardTableName": "TABLE_E",
|
||||
"trueColumn": "columnE",
|
||||
"standardColumn": "column_E",
|
||||
"notDetail": "字段名与标准不一致"
|
||||
},
|
||||
{
|
||||
"caseName": "表字段标准检测用例",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_F",
|
||||
"trueTableName": "TABLE_F",
|
||||
"standardTableName": "TABLE_F",
|
||||
"trueColumn": "columnF",
|
||||
"standardColumn": "column_F",
|
||||
"notDetail": "字段名与标准不一致"
|
||||
},
|
||||
{
|
||||
"caseName": "表字段标准检测用例",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_G",
|
||||
"trueTableName": "TABLE_G",
|
||||
"standardTableName": "TABLE_G",
|
||||
"trueColumn": "columnG",
|
||||
"standardColumn": "column_G",
|
||||
"notDetail": "字段名与标准不一致"
|
||||
}
|
||||
],
|
||||
"length_key": [
|
||||
{
|
||||
"ruleName": "检测字段长度是否符合约束",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "78",
|
||||
"checkErrorCount": "0"
|
||||
},{
|
||||
"ruleName": "检测字段长度是否符合标准约束",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "449",
|
||||
"checkErrorCount": "10"
|
||||
}
|
||||
],
|
||||
"no_length_key": [
|
||||
{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_A",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "2000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_B",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "100",
|
||||
"trueLength": "150",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_C",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "4000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_D",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "2000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_E",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "2000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_F",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "2000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_G",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "2000",
|
||||
"trueLength": "4000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_H",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "100",
|
||||
"trueLength": "150",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_I",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "2000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
},{
|
||||
"caseName": "检测字段长度是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_J",
|
||||
"standardColumn": "column_C",
|
||||
"standardLength": "200",
|
||||
"trueLength": "2000",
|
||||
"notDetail": "字段长度不符合标准约束"
|
||||
}
|
||||
],
|
||||
"pk_key": [
|
||||
{
|
||||
"ruleName": "检测字段是否主键符合标准约束",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "78",
|
||||
"checkErrorCount": "8"
|
||||
},{
|
||||
"ruleName": "检测字段是否主键符合标准约束",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "449",
|
||||
"checkErrorCount": "5"
|
||||
}
|
||||
|
||||
],
|
||||
"no_pk_key": [
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_A",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_W",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "否",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是"
|
||||
},{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_Q",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_E",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "否",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是"
|
||||
},{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_R",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_A",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "否",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是"
|
||||
},{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_D",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_W",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "否",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是"
|
||||
},{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_G",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_L",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "否",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是"
|
||||
},{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_P",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_U",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "否",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是"
|
||||
},{
|
||||
"caseName": "检测字段是否主键符合标准约束",
|
||||
"source": "数据平台",
|
||||
"tableName": "TABLE_M",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"truePk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否"
|
||||
}
|
||||
],
|
||||
"null_key": [
|
||||
{
|
||||
"ruleName": "检测字段空值是否符合标准约束",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "449",
|
||||
"checkErrorCount": "9"
|
||||
},{
|
||||
"ruleName": "检测字段空值是否符合标准约束",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "78",
|
||||
"checkErrorCount": "0"
|
||||
}
|
||||
],
|
||||
"no_null_key": [
|
||||
{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_A",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"trueNull": "是",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_B",
|
||||
"standardColumn": "column_BBB",
|
||||
"trueColumn": "column_BBB",
|
||||
"trueNull": "否",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "是"
|
||||
},{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_Y",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"trueNull": "是",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_W",
|
||||
"standardColumn": "column_BBB",
|
||||
"trueColumn": "column_BBB",
|
||||
"trueNull": "否",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "是"
|
||||
},{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_H",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"trueNull": "是",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_UU",
|
||||
"standardColumn": "column_BBB",
|
||||
"trueColumn": "column_BBB",
|
||||
"trueNull": "否",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "是"
|
||||
},{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_QQ",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"trueNull": "是",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_PP",
|
||||
"standardColumn": "column_BBB",
|
||||
"trueColumn": "column_BBB",
|
||||
"trueNull": "否",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "是"
|
||||
},{
|
||||
"caseName": "检测字段空值是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_K",
|
||||
"standardColumn": "column_BBB",
|
||||
"trueColumn": "column_BBB",
|
||||
"trueNull": "否",
|
||||
"notDetail": "表字段不符合空值校验",
|
||||
"standardNull": "是"
|
||||
}
|
||||
],
|
||||
"fk_key": [
|
||||
{
|
||||
"ruleName": "检测字段外键是否符合标准约束",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "449",
|
||||
"checkErrorCount": "2"
|
||||
},
|
||||
{
|
||||
"ruleName": "检测字段是否外键符合标准约束",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalCount": "78",
|
||||
"checkErrorCount": "0"
|
||||
}
|
||||
],
|
||||
"no_fk_key": [
|
||||
{
|
||||
"caseName": "检测字段外键是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_A",
|
||||
"standardColumn": "column_AAA",
|
||||
"trueColumn": "column_AAA",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardFk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "检测字段外键是否符合标准约束",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "TABLE_B",
|
||||
"standardColumn": "column_BBB",
|
||||
"trueColumn": "column_BBB",
|
||||
"trueFk": "否",
|
||||
"notDetail": "表字段不符合外键标准约束",
|
||||
"standardFk": "是"
|
||||
}
|
||||
]
|
||||
},
|
||||
"dataReport": {
|
||||
"reportTableData1": [
|
||||
{
|
||||
"ruleSourceId": 1,
|
||||
"ruleSourceName": "综合服务",
|
||||
"tableSum": "78",
|
||||
"tableTime": "3879",
|
||||
"ruleLevelName": "1.0",
|
||||
"checkErrorCount": 9
|
||||
},
|
||||
{
|
||||
"ruleSourceId": 1,
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"tableSum": "449",
|
||||
"tableTime": "15264",
|
||||
"ruleLevelName": "1.0",
|
||||
"checkErrorCount": 30
|
||||
}
|
||||
],
|
||||
"reportTableData2": [
|
||||
{
|
||||
"checkErrorCount": 5,
|
||||
"ruleTypeId": "1",
|
||||
"ruleTypeName": "数据平台",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "表字段标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 10,
|
||||
"ruleTypeId": "1",
|
||||
"ruleTypeName": "数据平台",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "长度标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 9,
|
||||
"ruleTypeId": "1",
|
||||
"ruleTypeName": "数据平台",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "空值标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 13,
|
||||
"ruleTypeId": "1",
|
||||
"ruleTypeName": "数据平台",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "主键标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 2,
|
||||
"ruleTypeId": "1",
|
||||
"ruleTypeName": "数据平台",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "外键标准检测"
|
||||
}
|
||||
]
|
||||
},
|
||||
"checkTotalCount": "527",
|
||||
"checkTimeConsuming": "19,143",
|
||||
"checkErrorCount": "39"
|
||||
}
|
||||
448
src/views/quality/checkreport/Data_content.json
Normal file
448
src/views/quality/checkreport/Data_content.json
Normal file
@@ -0,0 +1,448 @@
|
||||
{
|
||||
"caseType": {
|
||||
"integrity": [
|
||||
{
|
||||
"ruleName": "数据非空验证",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "13026",
|
||||
"checkTotalCount": "130264",
|
||||
"checkErrorCount": "689"
|
||||
},
|
||||
{
|
||||
"ruleName": "数据非空验证",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "1496",
|
||||
"checkTotalCount": "15621",
|
||||
"checkErrorCount": "152"
|
||||
}
|
||||
],
|
||||
"no_integrity":[
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_actinst",
|
||||
"trueColumn": "act_name_",
|
||||
"tableErrorCount": "23",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_attachment",
|
||||
"trueColumn": "url_",
|
||||
"tableErrorCount": "89",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_free_audit",
|
||||
"trueColumn": "name_",
|
||||
"tableErrorCount": "56",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_ru_variable",
|
||||
"trueColumn": "name_",
|
||||
"tableErrorCount": "147",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_ru_identitylink",
|
||||
"trueColumn": "proc_inst_id_",
|
||||
"tableErrorCount": "254",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_taskinst",
|
||||
"trueColumn": "user_id_",
|
||||
"tableErrorCount": "129",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_config",
|
||||
"trueColumn": "config_name",
|
||||
"tableErrorCount": "56",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据非空验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_model",
|
||||
"trueColumn": "model_name",
|
||||
"tableErrorCount": "96",
|
||||
"notDetail": "数据不符合标准表字段非空约束"
|
||||
}
|
||||
],
|
||||
"accuracy": [
|
||||
{
|
||||
"ruleName": "数据长度验证",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "14036",
|
||||
"checkTotalCount": "130264",
|
||||
"checkErrorCount": "2071"
|
||||
},
|
||||
{
|
||||
"ruleName": "数据长度验证",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "1698",
|
||||
"checkTotalCount": "15621",
|
||||
"checkErrorCount": "311"
|
||||
}
|
||||
],
|
||||
"no_accuracy": [
|
||||
{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_procdef_info",
|
||||
"trueColumn": "task_id_",
|
||||
"tableErrorCount": "145",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_varinst",
|
||||
"trueColumn": "group_id_",
|
||||
"tableErrorCount": "126",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_comment",
|
||||
"trueColumn": "message_",
|
||||
"tableErrorCount": "547",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_actinst",
|
||||
"trueColumn": "full_msg_",
|
||||
"tableErrorCount": "365",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_free_audit",
|
||||
"trueColumn": "type_",
|
||||
"tableErrorCount": "259",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_detail",
|
||||
"trueColumn": "var_type_",
|
||||
"tableErrorCount": "196",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_ge_property",
|
||||
"trueColumn": "name_",
|
||||
"tableErrorCount": "246",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_activity_info_config",
|
||||
"trueColumn": "idea_display_area",
|
||||
"tableErrorCount": "187",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_model",
|
||||
"trueColumn": "model_custom_type",
|
||||
"tableErrorCount": "126",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据长度验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_model",
|
||||
"trueColumn": "model_table_name",
|
||||
"tableErrorCount": "185",
|
||||
"notDetail": "数据不符合标准表字段长度约束"
|
||||
}
|
||||
],
|
||||
"consistent": [
|
||||
{
|
||||
"ruleName": "数据值域验证",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "12096",
|
||||
"checkTotalCount": "130264",
|
||||
"checkErrorCount": "2054"
|
||||
},
|
||||
{
|
||||
"ruleName": "数据值域验证",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "1465",
|
||||
"checkTotalCount": "15621",
|
||||
"checkErrorCount": "1229"
|
||||
}
|
||||
],
|
||||
"no_consistent": [
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_activity_info_config",
|
||||
"trueColumn": "jump_type",
|
||||
"tableErrorCount": "145",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_activity_info_config",
|
||||
"trueColumn": "activity_def_type",
|
||||
"tableErrorCount": "269",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_activity_rule",
|
||||
"trueColumn": "rule_type",
|
||||
"tableErrorCount": "63",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_application",
|
||||
"trueColumn": "type_",
|
||||
"tableErrorCount": "126",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_dict",
|
||||
"trueColumn": "status",
|
||||
"tableErrorCount": "329",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_doc_audit_apply",
|
||||
"trueColumn": "audit_type",
|
||||
"tableErrorCount": "296",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_doc_audit_apply",
|
||||
"trueColumn": "biz_type",
|
||||
"tableErrorCount": "191",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_doc_audit_detail",
|
||||
"trueColumn": "doc_type",
|
||||
"tableErrorCount": "394",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_doc_share_strategy_auditor",
|
||||
"trueColumn": "auditor_type",
|
||||
"tableErrorCount": "241",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "cms_content",
|
||||
"trueColumn": "content_type",
|
||||
"tableErrorCount": "249",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "cms_content",
|
||||
"trueColumn": "cms_type",
|
||||
"tableErrorCount": "196",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "manager",
|
||||
"trueColumn": "manager_type",
|
||||
"tableErrorCount": "246",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_dict",
|
||||
"trueColumn": "dict_type",
|
||||
"tableErrorCount": "329",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
},
|
||||
{
|
||||
"caseName": "数据值域验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_model",
|
||||
"trueColumn": "model_type",
|
||||
"tableErrorCount": "209",
|
||||
"notDetail": "数据不符合标准值域范围"
|
||||
}
|
||||
],
|
||||
"regular": [
|
||||
{
|
||||
"ruleName": "数据正则表达式验证",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "14989",
|
||||
"checkTotalCount": "130264",
|
||||
"checkErrorCount": "8441"
|
||||
},
|
||||
{
|
||||
"ruleName": "数据正则表达式验证",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "1699",
|
||||
"checkTotalCount": "15621",
|
||||
"checkErrorCount": "848"
|
||||
}
|
||||
],
|
||||
"no_regular": [
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_comment",
|
||||
"trueColumn": "action_",
|
||||
"tableErrorCount": "1269",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_detail",
|
||||
"trueColumn": "duration_",
|
||||
"tableErrorCount": "2156",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_actinst",
|
||||
"trueColumn": "proc_title",
|
||||
"tableErrorCount": "2497",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_taskinst",
|
||||
"trueColumn": "proc_title",
|
||||
"tableErrorCount": "2519",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_model",
|
||||
"trueColumn": "model_name",
|
||||
"tableErrorCount": "339",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_tag",
|
||||
"trueColumn": "tag_class",
|
||||
"tableErrorCount": "212",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
},
|
||||
{
|
||||
"caseName": "数据正则表达式验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "role_model",
|
||||
"trueColumn": "role_name",
|
||||
"tableErrorCount": "297",
|
||||
"notDetail": "数据不符合标准正则表达式约束"
|
||||
}
|
||||
]
|
||||
},
|
||||
"dataReport": {
|
||||
"reportTableData1": [
|
||||
{
|
||||
"ruleSourceId": 1,
|
||||
"ruleSourceName": "综合服务",
|
||||
"tableSum": "15621",
|
||||
"tableTime": "6,358",
|
||||
"ruleLevelName": "1.0",
|
||||
"checkErrorCount": "2,540"
|
||||
},
|
||||
{
|
||||
"ruleSourceId": 1,
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"tableSum": "130264",
|
||||
"tableTime": "54,147",
|
||||
"ruleLevelName": "1.0",
|
||||
"checkErrorCount": "13,255"
|
||||
}
|
||||
],
|
||||
"reportTableData2": [
|
||||
{
|
||||
"checkErrorCount": 841,
|
||||
"ruleTypeId": "1",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "完整性标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 2382,
|
||||
"ruleTypeId": "1",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "准确性标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 3283,
|
||||
"ruleTypeId": "1",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "一致性标准检测"
|
||||
},
|
||||
{
|
||||
"checkErrorCount": 9289,
|
||||
"ruleTypeId": "1",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "正则表达式标准检测"
|
||||
}
|
||||
]
|
||||
},
|
||||
"checkTotalCount": "145885",
|
||||
"checkTimeConsuming": "60505",
|
||||
"checkErrorCount": "15795"
|
||||
}
|
||||
|
||||
231
src/views/quality/checkreport/Data_relevance.json
Normal file
231
src/views/quality/checkreport/Data_relevance.json
Normal file
@@ -0,0 +1,231 @@
|
||||
{
|
||||
"caseType": {
|
||||
"relevancData": [
|
||||
{
|
||||
"ruleName": "关系符合性验证",
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "13965",
|
||||
"checkTotalCount": "449",
|
||||
"checkErrorCount": "8"
|
||||
},
|
||||
{
|
||||
"ruleName": "数据关系符合性验证",
|
||||
"ruleSourceName": "综合服务",
|
||||
"ruleTableName": "全表",
|
||||
"version": "1.0",
|
||||
"checkTotalTime": "3169",
|
||||
"checkTotalCount": "78",
|
||||
"checkErrorCount": "7"
|
||||
}
|
||||
],
|
||||
"no_relevancData":[
|
||||
{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_doc_audit_apply",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "否",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "是"
|
||||
},
|
||||
{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_free_audit",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
},{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_free_audit",
|
||||
"standardColumn": "department_id",
|
||||
"trueColumn": "department_id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_ge_property",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
},{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_identitylink",
|
||||
"standardColumn": "id_",
|
||||
"trueColumn": "id_",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
},
|
||||
{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_identitylink",
|
||||
"standardColumn": "group_id_",
|
||||
"trueColumn": "group_id_",
|
||||
"truePk": "否",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "否"
|
||||
},{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_procinst",
|
||||
"standardColumn": "id_",
|
||||
"trueColumn": "id_",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
},
|
||||
{
|
||||
"caseName": "关系符合性验证",
|
||||
"source": "智瑞服务",
|
||||
"tableName": "t_wf_hi_procinst",
|
||||
"standardColumn": "proc_inst_id_",
|
||||
"trueColumn": "proc_inst_id_",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "否"
|
||||
},
|
||||
{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "cms_category",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
},
|
||||
{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "cms_category",
|
||||
"standardColumn": "category_id",
|
||||
"trueColumn": "category_id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "否"
|
||||
},{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "cms_content",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "否"
|
||||
},{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "manager",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "否"
|
||||
},{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "model",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
},{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "model",
|
||||
"standardColumn": "model_id",
|
||||
"trueColumn": "model_id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "是",
|
||||
"standardFk": "否"
|
||||
},{
|
||||
"caseName": "数据关系符合性验证",
|
||||
"source": "综合服务",
|
||||
"tableName": "mdiy_page",
|
||||
"standardColumn": "id",
|
||||
"trueColumn": "id",
|
||||
"truePk": "是",
|
||||
"trueFk": "是",
|
||||
"notDetail": "表字段不符合主键标准约束",
|
||||
"standardPk": "否",
|
||||
"standardFk": "是"
|
||||
}
|
||||
]
|
||||
},
|
||||
"dataReport": {
|
||||
"reportTableData1": [
|
||||
{
|
||||
"ruleSourceId": 1,
|
||||
"ruleSourceName": "智瑞服务",
|
||||
"tableSum": "449",
|
||||
"tableTime": "13965",
|
||||
"ruleLevelName": "1.0",
|
||||
"checkErrorCount": "7"
|
||||
},
|
||||
{
|
||||
"ruleSourceId": 1,
|
||||
"ruleSourceName": "综合服务",
|
||||
"tableSum": "78",
|
||||
"tableTime": "3169",
|
||||
"ruleLevelName": "1.0",
|
||||
"checkErrorCount": "8"
|
||||
}
|
||||
],
|
||||
"reportTableData2": [
|
||||
{
|
||||
"checkErrorCount": 15,
|
||||
"ruleTypeId": "1",
|
||||
"ruleTypeName": "数据平台",
|
||||
"ruleLevelName": "中",
|
||||
"ruleName": "字段关联性检测用例"
|
||||
}
|
||||
]
|
||||
},
|
||||
"checkTotalCount": "527",
|
||||
"checkTimeConsuming": "17134",
|
||||
"checkErrorCount": "15"
|
||||
}
|
||||
|
||||
@@ -6,16 +6,25 @@
|
||||
<transition name="el-zoom-in-bottom">
|
||||
<check-report-structure v-if="options.showDetail" :data="options.data" @showCard="showCard" />
|
||||
</transition>
|
||||
|
||||
<transition name="el-zoom-in-bottom">
|
||||
<check-report-structure-content v-if="options.showDetail_content" :data="options.data" @showCard="showCard" />
|
||||
</transition>
|
||||
<transition name="el-zoom-in-bottom">
|
||||
<check-report-structure-relevance v-if="options.showDetail_relevance" :data="options.data" @showCard="showCard" />
|
||||
</transition>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import CheckReportList from './CheckReportList'
|
||||
import CheckReportStructure from './CheckReportStructure'
|
||||
import CheckReportStructureContent from './CheckReportStructure_content'
|
||||
import CheckReportStructureRelevance from './CheckReportStructure_relevance'
|
||||
|
||||
export default {
|
||||
name: 'CheckReport',
|
||||
components: { CheckReportList, CheckReportStructure },
|
||||
components: { CheckReportList, CheckReportStructure, CheckReportStructureContent, CheckReportStructureRelevance },
|
||||
data() {
|
||||
return {
|
||||
options: {
|
||||
@@ -26,7 +35,6 @@
|
||||
},
|
||||
methods: {
|
||||
showCard(data) {
|
||||
console.log('ffffffffff', data)
|
||||
Object.assign(this.options, data)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,68 +3,79 @@
|
||||
<div slot="header" class="clearfix">
|
||||
<span>{{ title }}</span>
|
||||
<el-button-group style="float: right;">
|
||||
<el-button type="primary" size="mini" icon="el-icon-finished" :loading="loadingOptions.loading" :disabled="loadingOptions.isDisabled" @click="submitForm">{{ loadingOptions.loadingText }}</el-button>
|
||||
<el-button v-if="active == 2" type="primary" size="mini" icon="el-icon-finished" :loading="loadingOptions.loading" :disabled="loadingOptions.isDisabled" @click="submitForm">{{ loadingOptions.loadingText }}</el-button>
|
||||
<el-button v-if="active == 1" size="mini" type="primary" @click="handleNextStep">下一步</el-button>
|
||||
<el-button v-if="active == 2" size="mini" type="primary" @click="handleLastStep">上一步</el-button>
|
||||
<el-button size="mini" icon="el-icon-back" @click="showCard">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<div class="body-wrapper">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="规则名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入规则名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="核查类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择核查类型" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
:label="item.itemExplain"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
v-for="source in sourceOptions"
|
||||
:key="source.id"
|
||||
:label="source.sourceName"
|
||||
:value="source.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<div>
|
||||
<el-transfer
|
||||
<div class="body-wrapper" style="padding-left: 20%">
|
||||
<el-steps :active="active" finish-status="success" align-center style="width: 900px">
|
||||
<el-step title="填写检测用例信息" />
|
||||
<el-step title="选择检测数据源" />
|
||||
</el-steps>
|
||||
<el-form v-if="active == 1" ref="form" :model="form" :rules="rules" label-width="120px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input v-model="form.ruleName" placeholder="请输入用例名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="检测类型" prop="ruleItemId">
|
||||
<el-select v-model="form.ruleItemId" placeholder="请选择检测类型" style="width: 100%" @change="ruleItemSelectChanged">
|
||||
<el-option
|
||||
v-for="item in ruleItemOptions"
|
||||
:key="item.id"
|
||||
:label="item.itemExplain"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="用例级别" prop="ruleLevelId">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId" placeholder="请选择用例级别" style="width: 100%">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
</div>
|
||||
</el-form>
|
||||
<el-form v-if="active == 2" ref="form" :model="form" :rules="rules" label-width="80px" style="width: 800px">
|
||||
<div style="padding: 20px 100px">
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" style="width: 100%" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
v-for="source in sourceOptions"
|
||||
:key="source.id"
|
||||
:label="source.sourceName"
|
||||
:value="source.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!--<el-transfer
|
||||
v-model="form.transferValue"
|
||||
filterable
|
||||
:titles="['备选', '已选']"
|
||||
:filter-method="filterMethod"
|
||||
:format="formatTransfer"
|
||||
filter-placeholder="请输入表名"
|
||||
:data="transferData"
|
||||
/>
|
||||
/>-->
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-radio-group v-model="form.status">
|
||||
<el-radio
|
||||
v-for="dict in statusOptions"
|
||||
:key="dict.id"
|
||||
:label="dict.itemText"
|
||||
>{{ dict.itemValue }}
|
||||
</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</div>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-radio-group v-model="form.status">
|
||||
<el-radio
|
||||
v-for="dict in statusOptions"
|
||||
:key="dict.id"
|
||||
:label="dict.itemText"
|
||||
>{{ dict.itemValue }}
|
||||
</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
</el-card>
|
||||
@@ -95,7 +106,8 @@ export default {
|
||||
// eslint-disable-next-line vue/no-dupe-keys
|
||||
transferData: [],
|
||||
|
||||
title: '核查规则新增',
|
||||
title: '检测用例新增',
|
||||
active: 1,
|
||||
// 展示切换
|
||||
showOptions: {
|
||||
data: {},
|
||||
@@ -152,7 +164,8 @@ export default {
|
||||
},
|
||||
status: '1',
|
||||
zzStatus: '0', // 状态正则
|
||||
transferValue: []
|
||||
transferValue: [],
|
||||
transferValueName: []
|
||||
},
|
||||
// 表单校验
|
||||
rules: {
|
||||
@@ -162,9 +175,6 @@ export default {
|
||||
ruleItemId: [
|
||||
{ required: true, message: '核查类型不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleLevelId: [
|
||||
{ required: true, message: '规则级别不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleSourceId: [
|
||||
{ required: true, message: '数据源不能为空', trigger: 'change' }
|
||||
],
|
||||
@@ -207,24 +217,39 @@ export default {
|
||||
|
||||
methods: {
|
||||
filterMethod(query, item) {
|
||||
return item.pinyin.indexOf(query) > -1
|
||||
return item.tableNameStr.indexOf(query) > -1
|
||||
},
|
||||
formatTransfer(item) {
|
||||
return item.label
|
||||
},
|
||||
generateData(tableData) {
|
||||
const data = []
|
||||
const tableName = tableData
|
||||
const pinyin = tableData
|
||||
tableName.forEach((tableData, index) => {
|
||||
const tableName = tableData // 确保 tableData 是数组,包含有 label 属性的对象
|
||||
tableName.forEach((tableItem) => {
|
||||
data.push({
|
||||
label: tableData,
|
||||
key: tableData,
|
||||
pinyin: pinyin[index]
|
||||
label: tableItem.label,
|
||||
key: tableItem.key,
|
||||
tableNameStr: tableItem.label // 直接使用 tableItem.label
|
||||
})
|
||||
})
|
||||
this.transferData = data
|
||||
console.log('this.transferData==', this.transferData)
|
||||
},
|
||||
showCard() {
|
||||
this.$emit('showCard', this.showOptions)
|
||||
},
|
||||
/** 步骤条下一步 */
|
||||
handleNextStep() {
|
||||
this.$refs['form'].validate(valid => {
|
||||
if (valid) {
|
||||
this.active++
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 步骤条上一步 */
|
||||
handleLastStep() {
|
||||
this.active--
|
||||
},
|
||||
getRuleLevelList() {
|
||||
listRuleLevel().then(response => {
|
||||
if (response.success) {
|
||||
@@ -256,7 +281,7 @@ export default {
|
||||
async sourceSelectChanged(val) {
|
||||
// this.inspectSourceId(val)
|
||||
// const tableNameOldList = []
|
||||
const tableNameOldList = await listSourceIdBytable(val, this.form.ruleConfig.id).then(response => {
|
||||
/* const tableNameOldList = await listSourceIdBytable(val, this.form.ruleConfig.id).then(response => {
|
||||
const result = []
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
const tableName = response.data[i].ruleTable
|
||||
@@ -270,8 +295,12 @@ export default {
|
||||
const tableNameList = []
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
const tableName = response.data[i].tableName
|
||||
const tableId = response.data[i].id
|
||||
const map = {}
|
||||
if (!tableNameOldList.some((str) => str === tableName)) {
|
||||
tableNameList.push(tableName)
|
||||
map.key = tableId
|
||||
map.label = tableName
|
||||
tableNameList.push(map)
|
||||
}
|
||||
}
|
||||
await this.generateData(tableNameList)
|
||||
@@ -292,7 +321,20 @@ export default {
|
||||
|
||||
// console.log('tableNameOldList=', tableNameOldList)
|
||||
// this.form.transferValue = tableNameOldList
|
||||
}
|
||||
}*/
|
||||
|
||||
const source = this.sourceOptions.find(function (item) {
|
||||
return item.id === val
|
||||
})
|
||||
this.form.transferValue = ['全表']
|
||||
this.form.ruleSource = source.sourceName
|
||||
this.form.ruleDbType = source.dbType
|
||||
this.form.ruleTableId = 'all'
|
||||
this.form.ruleTable = '全表'
|
||||
this.form.ruleTableComment = ''
|
||||
this.form.ruleColumnId = ''
|
||||
this.form.ruleColumn = ''
|
||||
this.form.ruleColumnComment = ''
|
||||
},
|
||||
// 根据来源数据获取已有表
|
||||
inspectSourceId(val) {
|
||||
@@ -359,6 +401,7 @@ export default {
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm: function () {
|
||||
console.log('transferValue', this.form.transferValue)
|
||||
this.$refs['form'].validate(valid => {
|
||||
if (valid) {
|
||||
this.loadingOptions.loading = true
|
||||
|
||||
@@ -21,16 +21,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别">
|
||||
<el-select v-model="form.ruleLevelId">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="规则级别">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="数据源">
|
||||
<el-select v-model="form.ruleSourceId">
|
||||
<el-option
|
||||
|
||||
@@ -22,16 +22,16 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则级别" prop="ruleLevelId">
|
||||
<el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">
|
||||
<el-option
|
||||
v-for="item in ruleLevelOptions"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="规则级别" prop="ruleLevelId">-->
|
||||
<!-- <el-select v-model="form.ruleLevelId" placeholder="请选择规则级别">-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in ruleLevelOptions"-->
|
||||
<!-- :key="item.id"-->
|
||||
<!-- :label="item.name"-->
|
||||
<!-- :value="item.id"-->
|
||||
<!-- />-->
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="数据源" prop="ruleSourceId">
|
||||
<el-select v-model="form.ruleSourceId" placeholder="请选择数据源" @change="sourceSelectChanged">
|
||||
<el-option
|
||||
@@ -116,9 +116,6 @@ export default {
|
||||
ruleItemId: [
|
||||
{ required: true, message: '核查类型不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleLevelId: [
|
||||
{ required: true, message: '规则级别不能为空', trigger: 'change' }
|
||||
],
|
||||
ruleSourceId: [
|
||||
{ required: true, message: '数据源不能为空', trigger: 'change' }
|
||||
],
|
||||
|
||||
@@ -26,6 +26,11 @@
|
||||
<el-col :span="18">
|
||||
<el-card class="box-card" shadow="always">
|
||||
<el-form ref="queryForm" :model="queryParams" :inline="true">
|
||||
<el-form-item label="项目" prop="projectId">
|
||||
<el-select v-model="queryParams.projectId" clearable size="small" placeholder="项目" class="filter-item" @change="handleQuery">
|
||||
<el-option v-for="item in projectsOptions" :key="item.id" :label="item.projectName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="数据源" prop="ruleName">
|
||||
<el-input
|
||||
v-model="queryParams.ruleSource"
|
||||
@@ -46,10 +51,10 @@
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="规则名称" prop="ruleName">
|
||||
<el-form-item label="用例名称" prop="ruleName">
|
||||
<el-input
|
||||
v-model="queryParams.ruleName"
|
||||
placeholder="请输入规则名称"
|
||||
placeholder="请输入用例名称"
|
||||
clearable
|
||||
size="small"
|
||||
@keyup.enter.native="handleQuery"
|
||||
@@ -72,12 +77,12 @@
|
||||
>新增</el-button>
|
||||
</el-button-group>
|
||||
<el-button-group>
|
||||
<el-button
|
||||
type="danger"
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
@click="deleteSelected"
|
||||
>删除</el-button>
|
||||
<el-button
|
||||
type="danger"
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
@click="deleteSelected"
|
||||
>删除</el-button>
|
||||
</el-button-group>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
@@ -129,7 +134,7 @@
|
||||
style="width: 100%;margin: 15px 0;"
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="序号" width="55" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.$index +1 }}</span>
|
||||
@@ -206,11 +211,11 @@ export default {
|
||||
// 表格头
|
||||
tableColumns: [
|
||||
{ prop: 'ruleSource', label: '数据源', show: true },
|
||||
{ prop: 'ruleTable', label: '数据表', show: true, formatter: this.ruleTableFormatter },
|
||||
{ prop: 'ruleName', label: '规则名称', show: true },
|
||||
{ prop: 'ruleType', label: '规则类型', show: true },
|
||||
/* { prop: 'ruleTable', label: '数据表', show: true, formatter: this.ruleTableFormatter },*/
|
||||
{ prop: 'ruleName', label: '用例名称', show: true },
|
||||
{ prop: 'ruleType', label: '用例类型', show: true },
|
||||
// { prop: 'ruleColumn', label: '核查字段', show: true, formatter: this.ruleColumnFormatter },
|
||||
{ prop: 'ruleLevel', label: '规则级别', width: 100, show: true },
|
||||
// { prop: 'ruleLevel', label: '用例级别', width: 100, show: true },
|
||||
{
|
||||
prop: 'status',
|
||||
label: '状态',
|
||||
@@ -220,6 +225,9 @@ export default {
|
||||
},
|
||||
{ prop: 'createTime', label: '创建时间', show: true }
|
||||
],
|
||||
projectsOptions: [
|
||||
{ id: '1111', projectName: '演示项目' }
|
||||
],
|
||||
// 默认选择中表格头
|
||||
checkedTableColumns: [],
|
||||
tableSize: 'medium',
|
||||
@@ -233,6 +241,7 @@ export default {
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
projectId: '1111',
|
||||
ruleTypeId: '',
|
||||
ruleName: '',
|
||||
ruleType: 'jg'
|
||||
@@ -264,7 +273,7 @@ export default {
|
||||
if (response.success) {
|
||||
const { data } = response
|
||||
const tree = {}
|
||||
tree.name = '规则类型'
|
||||
tree.name = '用例类型'
|
||||
const children = []
|
||||
data.forEach(e => {
|
||||
if (e.code === 'table_jc' || e.code === 'length_jc' || e.code === 'null_jc' ||
|
||||
@@ -336,7 +345,7 @@ export default {
|
||||
handleAdd() {
|
||||
this.showOptions.data = {}
|
||||
if (!this.queryParams.ruleTypeId) {
|
||||
this.$message.warning('请先选择核查规则类型')
|
||||
this.$message.warning('请先选择核查用例类型')
|
||||
return
|
||||
}
|
||||
this.showOptions.data.ruleTypeId = this.queryParams.ruleTypeId
|
||||
|
||||
@@ -67,15 +67,15 @@
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
</template><el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-view"
|
||||
@click="handleDetail(scope.row)"
|
||||
>检验报告</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-view"
|
||||
@click="handleDetail(scope.row)"
|
||||
>检验报告</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
</el-table>
|
||||
|
||||
@@ -111,7 +111,7 @@ export default {
|
||||
// 表格头
|
||||
tableColumns: [
|
||||
{ prop: 'ruleName', label: '规则名称', show: true },
|
||||
{ prop: 'ruleType', label: '规则类型', show: true },
|
||||
{ prop: 'ruleType', label: '用例类型', show: true },
|
||||
{ prop: 'ruleSource', label: '数据源', show: true },
|
||||
{ prop: 'ruleTable', label: '数据表', show: true },
|
||||
{ prop: 'ruleColumn', label: '核查字段', show: true },
|
||||
@@ -148,7 +148,7 @@ export default {
|
||||
if (response.success) {
|
||||
const { data } = response
|
||||
// const tree = {}
|
||||
// tree.name = '核查规则类型'
|
||||
// tree.name = '核查用例类型'
|
||||
// tree.children = data
|
||||
// this.ruleTypeOptions = []
|
||||
// this.ruleTypeOptions.push(tree)
|
||||
|
||||
Reference in New Issue
Block a user