智能排查

main
limingtao 11 months ago
parent 1bdf777e9c
commit c941cf4300
  1. 39
      pages/index/detail.vue

@ -114,35 +114,36 @@
</u-checkbox> </u-checkbox>
</u-checkbox-group> </u-checkbox-group>
</view> </view>
<view <view
v-if="item.answerOptions && item.answerOptions.length > 0 && item.optionType == 0" v-if="item.answerOptions && item.answerOptions.length > 0 && item.optionType == 0"
:style="item.answerOptions.length > 1 ? 'display: flex; flex-wrap: wrap;' : ''" :style="item.answerOptions.length > 1 ? 'display: flex; flex-wrap: wrap;' : ''"
:class="item.answerOptions.length > 1 ? '' : 'btnBox'" :class="item.answerOptions.length > 1 ? '' : 'btnBox'"
> >
<view v-for="(item, index) in item.answerOptions" :key="index" <view v-for="(it, ind) in item.answerOptions" :key="ind"
:style="item.answerOptions.length > 1 ? 'padding: 8px 8px;margin:0 0 8px 8px;background-color: #ededed;' : ''" :style="it.length > 1 ? 'padding: 8px 8px;margin:0 0 8px 8px;background-color: #ededed;' : ''"
:class="item.answerOptions.length > 1 ? '' : 'btn'" :class="it.length > 1 ? '' : 'btn'"
@click="handleGroup(item)"> @click="handleGroup(it)">
{{ item }} {{ it }}
</view> </view>
<!-- <u-radio-group <!-- <u-radio-group
v-model="item.radiovalue1" v-model="it.radiovalue1"
placement="column" placement="column"
iconPlacement="right" iconPlacement="right"
style="width: 100%; padding: 0 15px; box-sizing: border-box" style="width: 100%; padding: 0 15px; box-sizing: border-box"
v-if="item.optionType == 0" v-if="it.optionType == 0"
> >
<u-radio <u-radio
:customStyle="{ marginBottom: '8px' }" :customStyle="{ marginBottom: '8px' }"
v-for="(item, index) in item.answerOptions" v-for="(it, index) in it.answerOptions"
:key="index" :key="index"
:label="item" :label="it"
:name="item" :name="it"
> >
</u-radio> </u-radio>
</u-radio-group> --> </u-radio-group> -->
</view>
</view>
<view <view
class="btnBox" class="btnBox"
v-if="item.answerOptions && item.answerOptions.length > 0 && item.optionType == 1" v-if="item.answerOptions && item.answerOptions.length > 0 && item.optionType == 1"
@ -157,6 +158,9 @@
<view class="bounce-dot"></view> <view class="bounce-dot"></view>
<view class="bounce-dot"></view> <view class="bounce-dot"></view>
</view> </view>
<view class="loading-animation2" v-if="loading">
</view>
</scroll-view> </scroll-view>
<view <view
class="input-wrapper" class="input-wrapper"
@ -345,7 +349,7 @@ export default {
answerId, answerId,
data: res.result.data.content, data: res.result.data.content,
optionType: res.result.data?.optionType, optionType: res.result.data?.optionType,
answerOptions: res.result.data?.answerOptions || [], answerOptions: res.result.data?res.result.data.answerOptions : [],
}, },
]; ];
} else { } else {
@ -358,7 +362,7 @@ export default {
this.msgList[this.msgList.length - 1].optionType = this.msgList[this.msgList.length - 1].optionType =
res.result.data?.optionType; res.result.data?.optionType;
this.msgList[this.msgList.length - 1].answerOptions = this.msgList[this.msgList.length - 1].answerOptions =
res.result.data?.answerOptions || []; res.result.data?res.result.data.answerOptions : [];
} else { } else {
// //
this.msgList = [ this.msgList = [
@ -367,7 +371,7 @@ export default {
answerId: "1", answerId: "1",
data: res.result.data.content, data: res.result.data.content,
optionType: res.result.data?.optionType, optionType: res.result.data?.optionType,
answerOptions: res.result.data?.answerOptions || [], answerOptions: res.result.data?res.result.data.answerOptions : [],
}, },
]; ];
} }
@ -942,6 +946,11 @@ console.log({
animation-delay: 0.4s; animation-delay: 0.4s;
} }
} }
.loading-animation2 {
width: 100%;
height: 120rpx;
}
} }
} }

Loading…
Cancel
Save