修改显示内容处理
parent
f7e5086381
commit
0e49b5d993
|
|
@ -1,5 +1,14 @@
|
|||
<template>
|
||||
<view class="flex-row align-c wh-auto pr" :style="propStyle">
|
||||
<view class="bg-white wh-auto ht-auto flex-row align-c" @tap="data_time_change">
|
||||
<template v-if="isEmpty(form_value)">
|
||||
<view class="datetime-placeholder flex-1">{{ com_data.placeholder }}</view>
|
||||
</template>
|
||||
<template v-else>
|
||||
<view class="datetime-value flex-1">{{ form_value }}</view>
|
||||
</template>
|
||||
<iconfont :name="'icon-'+ com_data.icon_name" class="ml-5" size="28rpx" color="#333333" />
|
||||
</view>
|
||||
<template v-if="['option1', 'option2'].includes(date_type)">
|
||||
<myDatetime ref="option4" dataType="time" :shownum="date_type == 'option1' ? 2 : 3" @timeSubmit="data_date_change"></myDatetime>
|
||||
</template>
|
||||
|
|
@ -11,15 +20,6 @@
|
|||
<uni-datetime-picker ref="option4" :value="form_value" :border="false" :type="date_type == 'option4' ? 'date' : 'datetime'" :hideSecond="date_type !== 'option4'" @change="data_date_change" />
|
||||
</view>
|
||||
</template>
|
||||
<view class="bg-white wh-auto ht-auto flex-row align-c" @tap="data_time_change">
|
||||
<template v-if="isEmpty(form_value)">
|
||||
<view class="datetime-placeholder flex-1">{{ com_data.placeholder }}</view>
|
||||
</template>
|
||||
<template v-else>
|
||||
<view class="datetime-value flex-1">{{ form_value }}</view>
|
||||
</template>
|
||||
<iconfont :name="'icon-'+ com_data.icon_name" class="ml-5" size="28rpx" color="#333333" />
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,22 +1,33 @@
|
|||
<template>
|
||||
<view class="flex-col gap-10">
|
||||
<!-- 定位 -->
|
||||
<view class="pc-disable flex-row align-c jc-c w h" :style="com_data.common_style" @tap="choose_user_location">
|
||||
<view class="flex-row align-c jc-c gap-10 pa-5">
|
||||
<iconfont name="icon-latitude-location" size="24rpx" color="#666" propContainerDisplay="flex" ></iconfont>
|
||||
获取定位
|
||||
<view :class="propDirection == 'row' ? '' : 'flex-col gap-10'" >
|
||||
<template v-if="propDirection == 'row'">
|
||||
<view class="flex-row gap-10 align-c" @tap="choose_user_location">
|
||||
<view class="flex-1 flex-row align-c" :style="propStyle">
|
||||
<view v-if="isEmpty(form_value)" class="placeholder">获取定位</view>
|
||||
<view>{{ form_value.address }}</view>
|
||||
</view>
|
||||
<iconfont name="icon-latitude-location" size="32rpx" color="#666" propContainerDisplay="flex" ></iconfont>
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="!isEmpty(form_value)" class="flex-col gap-10 jc-c">
|
||||
<view class="flex-row align-c gap-5">
|
||||
<iconfont name="icon-location" size="24rpx" color="#666" propContainerDisplay="flex" ></iconfont>
|
||||
<view class="nowrap">{{ form_value.address }}</view>
|
||||
</template>
|
||||
<template v-else>
|
||||
<!-- 定位 -->
|
||||
<view class="pc-disable flex-row align-c jc-c w h" :style="com_data.common_style + propStyle" @tap="choose_user_location">
|
||||
<view class="flex-row align-c jc-c gap-10 pa-5">
|
||||
<iconfont name="icon-latitude-location" size="32rpx" color="#666" propContainerDisplay="flex" ></iconfont>
|
||||
获取定位
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="com_data.is_longitude_and_latitude == '1'" class="flex-row align-c gap-10">
|
||||
<view>经度坐标:{{ form_value.lng }}</view>
|
||||
<view>纬度坐标:{{ form_value.lat }}</view>
|
||||
<view v-if="!isEmpty(form_value)" class="flex-col gap-10 jc-c" :style="propStyle + 'height: 100%;'">
|
||||
<view class="flex-row align-c gap-5">
|
||||
<iconfont name="icon-location" size="32rpx" color="#666" propContainerDisplay="flex" ></iconfont>
|
||||
<view class="nowrap">{{ form_value.address }}</view>
|
||||
</view>
|
||||
<view v-if="com_data.is_longitude_and_latitude == '1'" class="flex-row align-c gap-10">
|
||||
<view>经度坐标:{{ form_value.lng }}</view>
|
||||
<view>纬度坐标:{{ form_value.lat }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
|
@ -44,6 +55,10 @@
|
|||
propIsCustom: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
propDirection: {
|
||||
type: String,
|
||||
default: 'row',
|
||||
}
|
||||
},
|
||||
data() {
|
||||
|
|
@ -110,4 +125,8 @@
|
|||
.gap-5 {
|
||||
gap: 10rpx;
|
||||
}
|
||||
.placeholder {
|
||||
color: #606266;
|
||||
opacity: 0.6;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
Loading…
Reference in New Issue