Commit 017d643b by 张立顺

fix(venus-usedcar-quality): 样式问题

1 parent 8a2258fb
...@@ -94,9 +94,10 @@ function extractLeafData(leaf: InspectionNodeDetail): { ...@@ -94,9 +94,10 @@ function extractLeafData(leaf: InspectionNodeDetail): {
/** /**
* 将单个叶子节点(nodeType=3)转换为 InspectItem * 将单个叶子节点(nodeType=3)转换为 InspectItem
*/ */
function leafToItem(leaf: InspectionNodeDetail): InspectItem { function leafToItem(leaf: InspectionNodeDetail): InspectItem | null {
const vo = leaf.inspectionResultVO; const vo = leaf.inspectionResultVO;
const resultStatus = vo?.resultStatus ?? 1; const resultStatus = vo?.resultStatus ?? 1;
if (resultStatus === 3) return null;
const { descriptions, images, videos } = extractLeafData(leaf); const { descriptions, images, videos } = extractLeafData(leaf);
return { return {
name: leaf.nodeName, name: leaf.nodeName,
...@@ -127,15 +128,15 @@ function buildCategories(nodes: InspectionNodeDetail[]): InspectCategory[] { ...@@ -127,15 +128,15 @@ function buildCategories(nodes: InspectionNodeDetail[]): InspectCategory[] {
const items: InspectItem[] = []; const items: InspectItem[] = [];
for (const child of children) { for (const child of children) {
if (child.nodeType === 3) { if (child.nodeType === 3) {
// 情况②:nodeType=1 直接挂 nodeType=3,无中间层 const item = leafToItem(child);
items.push(leafToItem(child)); if (item) items.push(item);
} else { } else {
// 情况①:nodeType=2 中间分组,展开其 nodeType=3 子节点
const leafNodes = (child.childrenNodes ?? []).sort( const leafNodes = (child.childrenNodes ?? []).sort(
(a, b) => a.sortOrder - b.sortOrder (a, b) => a.sortOrder - b.sortOrder
); );
for (const leaf of leafNodes) { for (const leaf of leafNodes) {
items.push(leafToItem(leaf)); const item = leafToItem(leaf);
if (item) items.push(item);
} }
} }
} }
...@@ -437,6 +438,7 @@ onUnmounted(() => { ...@@ -437,6 +438,7 @@ onUnmounted(() => {
} }
.inspect-detail-scroll { .inspect-detail-scroll {
position: relative;
box-sizing: border-box; box-sizing: border-box;
flex: 1; flex: 1;
min-height: 0; min-height: 0;
...@@ -449,8 +451,8 @@ onUnmounted(() => { ...@@ -449,8 +451,8 @@ onUnmounted(() => {
} }
.sticky-header { .sticky-header {
flex-shrink: 0;
z-index: 99; z-index: 99;
flex-shrink: 0;
background: #fff; background: #fff;
:deep(.van-tabs__content) { :deep(.van-tabs__content) {
...@@ -458,16 +460,6 @@ onUnmounted(() => { ...@@ -458,16 +460,6 @@ onUnmounted(() => {
} }
} }
.inspect-detail-scroll {
position: relative;
flex: 1;
min-height: 0;
overflow-x: hidden;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
padding-bottom: calc(40vh + env(safe-area-inset-bottom));
}
.filter-bar { .filter-bar {
display: flex; display: flex;
justify-content: flex-end; justify-content: flex-end;
......
...@@ -544,12 +544,12 @@ onMounted(() => { ...@@ -544,12 +544,12 @@ onMounted(() => {
</ul> </ul>
</div> </div>
<div class="score-link" @click="goToInspectDetail"> <!-- <div class="score-link" @click="goToInspectDetail">
查看完整报告和损伤照片 查看完整报告和损伤照片
<img alt="" <img alt=""
class="score-link__arrow" class="score-link__arrow"
:src="CDN.rightArrow" /> :src="CDN.rightArrow" />
</div> </div> -->
</div> </div>
<!-- 检测详情 --> <!-- 检测详情 -->
...@@ -590,15 +590,6 @@ onMounted(() => { ...@@ -590,15 +590,6 @@ onMounted(() => {
class="score-link__arrow" class="score-link__arrow"
:src="CDN.rightArrow" /> :src="CDN.rightArrow" />
</div> </div>
<!-- <div class="inspect-more">
<van-button plain
round
size="small"
type="default"
@click="goToInspectDetail">
查看完整检测详情
</van-button>
</div> -->
</div> </div>
<!-- 检测视频 --> <!-- 检测视频 -->
...@@ -705,11 +696,10 @@ onMounted(() => { ...@@ -705,11 +696,10 @@ onMounted(() => {
height: 100vh; height: 100vh;
height: 100dvh; height: 100dvh;
max-height: 100dvh; max-height: 100dvh;
overflow-x: hidden;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
padding-bottom: calc(20px + env(safe-area-inset-bottom)); padding-bottom: calc(20px + env(safe-area-inset-bottom));
overflow: hidden auto;
background: #f2f3f7; background: #f2f3f7;
-webkit-overflow-scrolling: touch;
} }
.report-scroll { .report-scroll {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!