修改首页样式和手动绑定字段名

This commit is contained in:
qiaomu 2024-06-25 11:16:38 +08:00
parent 9ca94479fa
commit e6edf6e3d1
5 changed files with 22 additions and 7 deletions

View File

@ -68,7 +68,7 @@ Page({
return return
} }
if (!phone) { if (!phone) {
alertInfo("请输入联系人手机号") alertInfo("请输入预留手机号")
return return
} }
if (!name) { if (!name) {

View File

@ -25,8 +25,8 @@
<van-field <van-field
required required
value="{{ phone }}" value="{{ phone }}"
label="联系人手机号" label="预留手机号"
placeholder="请输入联系人手机号" placeholder="请输入预留手机号"
border="{{ true }}" border="{{ true }}"
bind:change="onChangePhone" bind:change="onChangePhone"
/> />

View File

@ -24,7 +24,10 @@
<view class="logined" wx:else> <view class="logined" wx:else>
<avatar text="{{ user.nickName }}" /> <avatar text="{{ user.nickName }}" />
<view> <view>
<van-button type="info" size="small" plain="{{true}}" class="loginBtn" custom-style="font-size: 32rpx; max-width:300rpx; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;" bind:click="chooseTenement">{{tenement.name}} <van-icon name="arrow-down" style="margin-left: 16rpx;" /></van-button> <view class="company" bind:tap="chooseTenement">
<view class="companyName"> {{tenement.name}} </view>
<van-icon name="arrow-down" style="margin-left: 16rpx;" />
</view>
<view class="welcome"> 欢迎使用华昌宝能用电管理系统! </view> <view class="welcome"> 欢迎使用华昌宝能用电管理系统! </view>
</view> </view>
</view> </view>

View File

@ -41,10 +41,24 @@
align-items: center; align-items: center;
} }
.loginBtn { .loginBtn, .company {
margin-left: 30rpx; margin-left: 30rpx;
} }
.company {
font-size: 32rpx;
display: flex;
color: #fff;
}
.companyName {
max-width:300rpx;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.rechargeWrapper { .rechargeWrapper {
background: linear-gradient(to bottom, var(--middle-green), #fff ); background: linear-gradient(to bottom, var(--middle-green), #fff );
overflow: hidden; overflow: hidden;

View File

@ -230,8 +230,6 @@
data-name="address" data-name="address"
/> />
<van-field <van-field
value="{{formData.remark}}" value="{{formData.remark}}"
label="备注" label="备注"