Commit 284f3cdc authored by spc's avatar spc

fixed

parent 78b2ce82
No preview for this file type
...@@ -368,10 +368,17 @@ const handleViewActivity = (activity, index) => { ...@@ -368,10 +368,17 @@ const handleViewActivity = (activity, index) => {
console.warn('活动没有跳转地址') console.warn('活动没有跳转地址')
return return
} }
jump({ if (uri.includes('http')) {
type: JumpType.H5, jump({
url: uri type: JumpType.H5,
}) url: uri
})
} else {
jump({
type: JumpType.INNER,
url: uri
})
}
} else { } else {
jump({ jump({
type: JumpType.INNER, type: JumpType.INNER,
......
...@@ -226,7 +226,8 @@ onShow(async()=> { ...@@ -226,7 +226,8 @@ onShow(async()=> {
console.log(isShare.value,'onShow') console.log(isShare.value,'onShow')
if(isShare.value == 'true'){ if(isShare.value == 'true'){
await userStore.loadUserInfo() await userStore.loadUserInfo()
if (userStore.userInfo?.memberId !== "not_login") { console.log(userStore.userInfo,'userStore.userInfo?.memberId')
if ((userStore?.userInfo?.memberId && userStore?.userInfo?.memberId == "not_login") || !userStore.userInfo) {
//非会员 未登录,跳转到登录注册页面 //非会员 未登录,跳转到登录注册页面
uni.navigateTo({ uni.navigateTo({
url: `/pages/activity/register` url: `/pages/activity/register`
...@@ -317,7 +318,7 @@ onShow(async()=> { ...@@ -317,7 +318,7 @@ onShow(async()=> {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
padding: 24rpx 40rpx; padding: 22rpx 40rpx;
box-sizing: border-box; box-sizing: border-box;
position: absolute; position: absolute;
bottom: 0; bottom: 0;
...@@ -352,7 +353,7 @@ onShow(async()=> { ...@@ -352,7 +353,7 @@ onShow(async()=> {
.left-two { .left-two {
font-size: 24rpx; font-size: 24rpx;
font-weight: 500; font-weight: 500;
height: 72rpx; height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
...@@ -393,7 +394,7 @@ onShow(async()=> { ...@@ -393,7 +394,7 @@ onShow(async()=> {
} }
.name { .name {
padding: 0rpx 12rpx; padding: 0rpx 5rpx;
border-radius: 4rpx; border-radius: 4rpx;
font-size: 18rpx; font-size: 18rpx;
line-height: 26rpx; line-height: 26rpx;
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
:class="isView ? 'form-input view-bg' : fieldItem.error ? 'error-border form-input' : 'form-input'" :class="isView ? 'form-input view-bg' : fieldItem.error ? 'error-border form-input' : 'form-input'"
:disabled="isView" /> :disabled="isView" />
<view v-if="fieldItem.error || fieldItem.noInt" class="error"> <view v-if="fieldItem.error || fieldItem.noInt" class="error">
{{ fieldItem.error ? `请维护${fieldItem.fieldName}` : `请输入整数后提交`}} {{ fieldItem.error ? `请维护${fieldItem.fieldName}` : `请输入整数后提交` }}
</view> </view>
</view> </view>
<!-- 长文本输入框类型 --> <!-- 长文本输入框类型 -->
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
:class="isView ? 'form-textarea view-bg' : fieldItem.error ? 'error-border form-textarea' : 'form-textarea'" :class="isView ? 'form-textarea view-bg' : fieldItem.error ? 'error-border form-textarea' : 'form-textarea'"
:disabled="isView" /> :disabled="isView" />
<view v-if="fieldItem.error || fieldItem.noInt" class="error"> <view v-if="fieldItem.error || fieldItem.noInt" class="error">
{{ fieldItem.error ? `请维护${fieldItem.fieldName}` : `请输入整数后提交`}} {{ fieldItem.error ? `请维护${fieldItem.fieldName}` : `请输入整数后提交` }}
</view> </view>
</view> </view>
...@@ -43,7 +43,8 @@ ...@@ -43,7 +43,8 @@
@blur="(e) => emit('mobileInput', { subIndex: '', fieldIndex, e })" @blur="(e) => emit('mobileInput', { subIndex: '', fieldIndex, e })"
:class="isView ? 'form-input view-bg' : fieldItem.error ? 'error-border form-input' : 'form-input'" :class="isView ? 'form-input view-bg' : fieldItem.error ? 'error-border form-input' : 'form-input'"
:disabled="isView" /> :disabled="isView" />
<view v-if="fieldItem.fieldValue && !isView" @click="emit('updateMobile', { subIndex: '', fieldIndex })" class="btn">更换手机号 <view v-if="fieldItem.fieldValue && !isView"
@click="emit('updateMobile', { subIndex: '', fieldIndex })" class="btn">更换手机号
</view> </view>
<view v-if="fieldItem.error" class="error"> <view v-if="fieldItem.error" class="error">
请维护{{ fieldItem.fieldName }} 请维护{{ fieldItem.fieldName }}
...@@ -123,7 +124,7 @@ ...@@ -123,7 +124,7 @@
<view v-for="opt in fieldItem.options" :key="opt.value" class="check-item"> <view v-for="opt in fieldItem.options" :key="opt.value" class="check-item">
<checkbox :value="opt.optionValue" :style="{ opacity: 0 }" <checkbox :value="opt.optionValue" :style="{ opacity: 0 }"
:checked="fieldItem.fieldValue?.includes(opt.optionValue)" class="check-icon">{{ :checked="fieldItem.fieldValue?.includes(opt.optionValue)" class="check-icon">{{
opt.optionLabel }}</checkbox> opt.optionLabel }}</checkbox>
<view class="custom-check"> <view class="custom-check">
<view <view
:class="fieldItem.fieldValue?.includes(opt.optionValue) ? 'check-text check-bg' : 'check-text nocheck-bg'"> :class="fieldItem.fieldValue?.includes(opt.optionValue) ? 'check-text check-bg' : 'check-text nocheck-bg'">
...@@ -143,8 +144,8 @@ ...@@ -143,8 +144,8 @@
:class="isView ? 'form-input date-display view-bg' : fieldItem.error ? 'error-border form-input date-display' : 'form-input date-display'"> :class="isView ? 'form-input date-display view-bg' : fieldItem.error ? 'error-border form-input date-display' : 'form-input date-display'">
<text v-if="fieldItem.fieldValue">{{ <text v-if="fieldItem.fieldValue">{{
fieldItem.fieldValue.provinceName }}-{{ fieldItem.fieldValue.provinceName }}-{{
fieldItem.fieldValue.cityName }}-{{ fieldItem.fieldValue.cityName }}-{{
fieldItem.fieldValue.regionName }}</text> fieldItem.fieldValue.regionName }}</text>
<text v-else class="date-text">{{ fieldItem.placeholder }}</text> <text v-else class="date-text">{{ fieldItem.placeholder }}</text>
<image :src="$baseUrl + 'sign-up/union.png'" class="union-icon" /> <image :src="$baseUrl + 'sign-up/union.png'" class="union-icon" />
</view> </view>
...@@ -154,12 +155,14 @@ ...@@ -154,12 +155,14 @@
</view> </view>
</view> </view>
</view> </view>
<view :class="((!isView && item.subFormList && item.subFormList.length > 0) || (isView && hasFilledOutList(item?.subFormList))) ? 'line-dash' : ''"></view> <view
:class="((!isView && item.subFormList && item.subFormList.length > 0) || (isView && hasFilledOutList(item?.subFormList))) ? 'line-dash' : ''">
</view>
<view v-if="item.subFormList && item.subFormList.length > 0" class="sub-box"> <view v-if="item.subFormList && item.subFormList.length > 0" class="sub-box">
<view v-if="!isView" <view v-if="!isView"
:class="item.subFormList.length === 1 ? 'sub-warp-one' : item.subFormList.length === 2 ? 'sub-warp-two' : 'sub-warp-three'"> :class="item.subFormList.length === 1 ? 'sub-warp-one' : item.subFormList.length === 2 ? 'sub-warp-two' : 'sub-warp-three'">
<view v-for="(subItm, subIndex) in item.subFormList" :key="subIndex" <view v-for="(subItm, subIndex) in item.subFormList" :key="subIndex"
:class="subItm.isShow ? 'gray sub-item sub-item-one sub-item-two sub-item-three' : 'sub-item sub-item-one sub-item-two sub-item-three' "> :class="subItm.isShow ? 'gray sub-item sub-item-one sub-item-two sub-item-three' : 'sub-item sub-item-one sub-item-two sub-item-three'">
<view @click="emit('addSubForm', subIndex)" class="sub-title"> <view @click="emit('addSubForm', subIndex)" class="sub-title">
{{ subItm.formButtonName }} {{ subItm.formButtonName }}
</view> </view>
...@@ -168,7 +171,9 @@ ...@@ -168,7 +171,9 @@
<view v-if="item.subFormList && item.subFormList.length > 0" v-for="(subItm, subIndex) in item.subFormList" <view v-if="item.subFormList && item.subFormList.length > 0" v-for="(subItm, subIndex) in item.subFormList"
:key="subIndex"> :key="subIndex">
<view v-if="(!isView && subItm.isShow) || (isView && subItm.hasFilledOut)"> <view v-if="(!isView && subItm.isShow) || (isView && subItm.hasFilledOut)">
<view v-if="(!isView && subItm.isShow && !subItm.isFirstFound) || (isView && subItm.hasFilledOut)" class='line-dash'></view> <view
v-if="(!isView && subItm.isShow && !subItm.isFirstFound) || (isView && subItm.hasFilledOut && !subItm.isFirstFound)"
class='line-dash'></view>
<form-tree v-bind="{ item: subItm, index, visible, areaVisible, formData, isView }" <form-tree v-bind="{ item: subItm, index, visible, areaVisible, formData, isView }"
@addSubForm="() => emit('addSubForm', subIndex)" @addSubForm="() => emit('addSubForm', subIndex)"
@delSubForm="() => emit('delSubForm', subIndex)" @delSubForm="() => emit('delSubForm', subIndex)"
...@@ -220,8 +225,8 @@ const props = defineProps({ ...@@ -220,8 +225,8 @@ const props = defineProps({
}) })
const { visible, areaVisible, item, index, formData, isView } = toRefs(props) const { visible, areaVisible, item, index, formData, isView } = toRefs(props)
const emit = defineEmits(['textInput', 'mobileInput', 'updateMobile', 'cardInput', 'onUpload', 'onPreviewImage', 'onImageDel', 'openAddressPicker', 'openDatePicker', 'addSubForm', 'delSubForm', 'onRadioChange', 'onCheckChange']) const emit = defineEmits(['textInput', 'mobileInput', 'updateMobile', 'cardInput', 'onUpload', 'onPreviewImage', 'onImageDel', 'openAddressPicker', 'openDatePicker', 'addSubForm', 'delSubForm', 'onRadioChange', 'onCheckChange'])
const hasFilledOutList = (list)=>{ const hasFilledOutList = (list) => {
return list && list.some(itm=>itm.hasFilledOut) return list && list.some(itm => itm.hasFilledOut)
} }
</script> </script>
...@@ -290,11 +295,12 @@ const hasFilledOutList = (list)=>{ ...@@ -290,11 +295,12 @@ const hasFilledOutList = (list)=>{
.form-textarea { .form-textarea {
border-radius: 8rpx; border-radius: 8rpx;
width: 100%; width: 100%;
height: 136rpx; height: 130rpx;
padding: 10rpx; padding: 10rpx;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid #A8A8A8; border: 1px solid #A8A8A8;
} }
.form-radio { .form-radio {
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -395,14 +401,16 @@ const hasFilledOutList = (list)=>{ ...@@ -395,14 +401,16 @@ const hasFilledOutList = (list)=>{
.date-text { .date-text {
color: #808080; color: #808080;
} }
.arrow-icon { .arrow-icon {
width: 48rpx; width: 48rpx;
height: 48rpx; height: 48rpx;
} }
.union-icon { .union-icon {
width: 29rpx; width: 29rpx;
height: 36rpx; height: 36rpx;
} }
} }
} }
...@@ -459,6 +467,7 @@ const hasFilledOutList = (list)=>{ ...@@ -459,6 +467,7 @@ const hasFilledOutList = (list)=>{
.error-border { .error-border {
border: 1px solid red; border: 1px solid red;
} }
.view-bg { .view-bg {
border: none; border: none;
background-color: #F5F5F5; background-color: #F5F5F5;
...@@ -472,26 +481,30 @@ const hasFilledOutList = (list)=>{ ...@@ -472,26 +481,30 @@ const hasFilledOutList = (list)=>{
} }
.sub-box { .sub-box {
.sub-warp-one{ .sub-warp-one {
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
color: #B27C1E; color: #B27C1E;
margin-bottom: 20rpx; margin-bottom: 20rpx;
.sub-item-one { .sub-item-one {
width: 520rpx; width: 520rpx;
} }
} }
.sub-warp-two { .sub-warp-two {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
color: #B27C1E; color: #B27C1E;
margin-bottom: 20rpx; margin-bottom: 20rpx;
.sub-item-two { .sub-item-two {
width: 320rpx; width: 320rpx;
} }
} }
.sub-warp-three { .sub-warp-three {
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -499,18 +512,23 @@ const hasFilledOutList = (list)=>{ ...@@ -499,18 +512,23 @@ const hasFilledOutList = (list)=>{
color: #B27C1E; color: #B27C1E;
width: calc(100vw - 59rpx); width: calc(100vw - 59rpx);
margin-bottom: 20rpx; margin-bottom: 20rpx;
.sub-item-three { .sub-item-three {
width: 208rpx; width: 208rpx;
margin-right: 17rpx; margin-right: 17rpx;
.sub-title{
.sub-title {
padding: 0 20rpx; padding: 0 20rpx;
white-space: nowrap; /* 禁止文本换行 */ white-space: nowrap;
overflow: hidden; /* 隐藏溢出内容 */ /* 禁止文本换行 */
overflow: hidden;
/* 隐藏溢出内容 */
text-overflow: ellipsis; text-overflow: ellipsis;
} }
} }
} }
.sub-item { .sub-item {
height: 60rpx; height: 60rpx;
border-radius: 50rpx; border-radius: 50rpx;
...@@ -522,6 +540,7 @@ const hasFilledOutList = (list)=>{ ...@@ -522,6 +540,7 @@ const hasFilledOutList = (list)=>{
margin-top: 20rpx; margin-top: 20rpx;
margin-bottom: 20rpx; margin-bottom: 20rpx;
} }
.gray { .gray {
opacity: 0.2; opacity: 0.2;
} }
......
...@@ -188,22 +188,26 @@ defineExpose({ ...@@ -188,22 +188,26 @@ defineExpose({
} }
} }
.content-box{ .content-box{
height: 740rpx; height: 747rpx;
overflow: scroll; overflow: scroll;
margin: 30rpx 0rpx; margin: 30rpx 0rpx;
line-height: 30rpx;
.sub-title{ .sub-title{
font-size: 24rpx; font-size: 24rpx;
font-weight: 600;
} }
.sub-two-title{ .sub-two-title{
font-size: 22rpx; font-size: 22rpx;
font-weight: 600;
} }
.sub-content{ .sub-content{
color: #A8A8A8; // color: #A8A8A8;
font-size: 20rpx; font-size: 20rpx;
text-align: justify; text-align: justify;
margin: 30rpx 0rpx; margin: 30rpx 0rpx;
.sub-tips{ .sub-tips{
color: #000000; // color: #000000;
font-weight: 600;
} }
} }
.read-complete{ .read-complete{
......
...@@ -31,7 +31,9 @@ ...@@ -31,7 +31,9 @@
<view v-for="(itm, index) in activityInfo.addressList" :key="index" class="text"> <view v-for="(itm, index) in activityInfo.addressList" :key="index" class="text">
<view v-if="index < 2" class="mark"> <view v-if="index < 2" class="mark">
<image :src="$baseUrl + 'sign-up/vector.png'" mode="aspectFit" /> <image :src="$baseUrl + 'sign-up/vector.png'" mode="aspectFit" />
{{ itm.provinceName }}{{ itm.cityName }}{{ itm.addressDetail }} <view class="mark-text">
{{ itm.provinceName }}{{ itm.cityName }}{{ itm.addressDetail }}
</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -297,16 +299,21 @@ defineExpose({ ...@@ -297,16 +299,21 @@ defineExpose({
font-weight: 600; font-weight: 600;
line-height: 40rpx; line-height: 40rpx;
font-size: 24rpx; font-size: 24rpx;
width: 450rpx;
.mark { .mark {
display: flex; display: flex;
justify-content: center; justify-content: center;
width: 100%;
image { image {
width: 16rpx; width: 16rpx;
height: 20rpx; height: 20rpx;
margin-right: 8rpx; margin-right: 8rpx;
} }
.mark-text{
max-width: 426rpx;
}
} }
} }
} }
......
...@@ -391,7 +391,8 @@ onShow(async()=> { ...@@ -391,7 +391,8 @@ onShow(async()=> {
} }
if(query.value.share == 'true'){ if(query.value.share == 'true'){
await userStore.loadUserInfo() await userStore.loadUserInfo()
if (userStore.userInfo?.memberId !== "not_login") { console.log(userStore.userInfo,'userStore.userInfo?.memberId')
if ((userStore?.userInfo?.memberId && userStore?.userInfo?.memberId == "not_login") || !userStore.userInfo) {
//非会员 未登录,跳转到登录注册页面 //非会员 未登录,跳转到登录注册页面
uni.navigateTo({ uni.navigateTo({
url: `/pages/activity/register` url: `/pages/activity/register`
...@@ -490,7 +491,7 @@ onShareAppMessage(() => { ...@@ -490,7 +491,7 @@ onShareAppMessage(() => {
max-height: 840rpx; max-height: 840rpx;
min-height: 320rpx; min-height: 320rpx;
width: calc(100vw - 150rpx); width: calc(100vw - 150rpx);
padding: 40rpx 28rpx 70rpx; padding: 40rpx 28rpx 50rpx;
background: linear-gradient(180.16deg, #FFE9C5 -4.61%, #FFFFFF 26.4%); background: linear-gradient(180.16deg, #FFE9C5 -4.61%, #FFFFFF 26.4%);
border-radius: 38rpx; border-radius: 38rpx;
position: relative; position: relative;
...@@ -511,7 +512,8 @@ onShareAppMessage(() => { ...@@ -511,7 +512,8 @@ onShareAppMessage(() => {
overflow: auto; overflow: auto;
margin-top: 40rpx; margin-top: 40rpx;
text-align: justify; text-align: justify;
max-height: 655rpx; max-height: 635rpx;
line-height: 35rpx;
} }
.close { .close {
......
...@@ -145,6 +145,10 @@ const validateFormComponent = ({ required, fieldValue, placeholder, componentTyp ...@@ -145,6 +145,10 @@ const validateFormComponent = ({ required, fieldValue, placeholder, componentTyp
isEmpty = !fieldValue || !Object.keys(fieldValue).length; isEmpty = !fieldValue || !Object.keys(fieldValue).length;
} else if (componentType === 'MULTI_SELECT' || componentType === 'IMG') { } else if (componentType === 'MULTI_SELECT' || componentType === 'IMG') {
isEmpty = !fieldValue?.length; isEmpty = !fieldValue?.length;
}else if (componentType === 'MOBILE') {
isEmpty = !fieldValue || (fieldValue && fieldValue.length != 11);
} else if (componentType === 'ID_CARD') {
isEmpty = !fieldValue || (fieldValue && fieldValue.length != 18);
} else { } else {
isEmpty = !fieldValue; isEmpty = !fieldValue;
} }
...@@ -502,7 +506,7 @@ watch(() => formData.value, (newVal) => { ...@@ -502,7 +506,7 @@ watch(() => formData.value, (newVal) => {
if (item.subFormList && item.subFormList.length > 0) { if (item.subFormList && item.subFormList.length > 0) {
let flag = false; let flag = false;
item.subFormList.forEach(subItem => { item.subFormList.forEach(subItem => {
if (subItem.isShow) { if (subItem.isShow || subItem.hasFilledOut) {
if (!flag) { if (!flag) {
subItem.isFirstFound = true; subItem.isFirstFound = true;
flag = true; flag = true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment