|
|
|
@ -61,15 +61,18 @@ |
|
|
|
|
that.itemList = res.data.list; |
|
|
|
|
that.itemList.map(item => { |
|
|
|
|
if (item.child.length > 0) { |
|
|
|
|
if (parseInt(item.child.length % 4) == 1) { |
|
|
|
|
if (parseInt(item.child.length % 4) == 1 && item.child.length < 3) { |
|
|
|
|
item.child.push({}, {}, {}) |
|
|
|
|
} |
|
|
|
|
if (parseInt(item.child.length % 4) == 2) { |
|
|
|
|
if (parseInt(item.child.length % 4) == 2 && item.child.length < 3) { |
|
|
|
|
item.child.push({}, {}) |
|
|
|
|
} |
|
|
|
|
if (parseInt(item.child.length % 4) == 3) { |
|
|
|
|
item.child.push({}) |
|
|
|
|
} |
|
|
|
|
if (parseInt(item.child.length % 4) == 1 && item.child.length > 4) { |
|
|
|
|
item.child.push({}) |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
item.childArr = [] |
|
|
|
|
item.childArr = item.child.slice(0, 9) |
|
|
|
@ -111,6 +114,7 @@ |
|
|
|
|
color: #000000; |
|
|
|
|
padding: 20upx 0; |
|
|
|
|
font-weight: bold; |
|
|
|
|
// border-bottom: 3upx solid #dfdbdb; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.border { |
|
|
|
@ -135,6 +139,7 @@ |
|
|
|
|
align-items: center; |
|
|
|
|
flex-direction: column; |
|
|
|
|
position: relative; |
|
|
|
|
// border-bottom: 1px solid #dfdbdb; |
|
|
|
|
|
|
|
|
|
.titleIcon { |
|
|
|
|
width: 50upx; |
|
|
|
@ -164,6 +169,7 @@ |
|
|
|
|
.mainItem { |
|
|
|
|
display: flex; |
|
|
|
|
flex-wrap: wrap; |
|
|
|
|
// align-items: center; |
|
|
|
|
width: calc(100% - 90px); |
|
|
|
|
margin: 20rpx 20rpx 20rpx 40rpx; |
|
|
|
|
|
|
|
|
@ -173,6 +179,7 @@ |
|
|
|
|
overflow: hidden; |
|
|
|
|
text-overflow: ellipsis; |
|
|
|
|
text-align: center; |
|
|
|
|
// padding: 24upx 16upx; |
|
|
|
|
height: 90upx; |
|
|
|
|
line-height: 90upx; |
|
|
|
|
padding: 0 10upx; |
|
|
|
@ -187,11 +194,37 @@ |
|
|
|
|
.itemText:nth-child(1) { |
|
|
|
|
border-top: 0; |
|
|
|
|
padding-right: 1px; |
|
|
|
|
// border-right: 1px solid #dfdbdb; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.itemText:nth-child(2) { |
|
|
|
|
border-top: 0; |
|
|
|
|
// border-left: none; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// .itemText:nth-last-child(odd):last-of-type { |
|
|
|
|
// border-bottom: none; |
|
|
|
|
// border-right: 1px solid #dfdbdb; |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
// .itemText:nth-last-child(2){ |
|
|
|
|
// border-bottom: none; |
|
|
|
|
// } |
|
|
|
|
// :first-child { |
|
|
|
|
// border-right: 1px solid #dfdbdb; |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
// :nth-child(2n) { |
|
|
|
|
// border-left: 1px solid #dfdbdb; |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
// :last-child { |
|
|
|
|
// border-left: 1px solid #dfdbdb; |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
// :nth-child(3) { |
|
|
|
|
// border-right: 1px solid #dfdbdb; |
|
|
|
|
// } |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|