tanxue hace 1 día
padre
commit
8db70c3fd0

+ 9 - 4
common/styles/global/pages.scss

@@ -1347,7 +1347,7 @@
 		}
 		.fwnr-label-input{
 			width: 100%;display: flex;justify-content: space-between;align-items: center;
-			font-size: 30rpx;color: #333;
+			font-size: 30rpx;color: #333;position: relative;
 			padding: 20rpx 50rpx 20rpx 20rpx;box-sizing: border-box;margin-bottom: 2rpx;
 			.form-label-require{color: #ff0101;margin-right: 6rpx;width:16rpx;display: inline-block;}
 			.fwnr-form-label{min-width: 180rpx;}
@@ -1357,9 +1357,6 @@
 			.uni-input-placeholder{overflow: unset;}
 			.uni-easyinput__placeholder-class{font-size: 28rpx!important;}
 			.content-clear-icon{color: rgb(192, 196, 204)!important;}
-			icon{width: 30rpx;height: 30rpx;@include ezy-no-repeat-cover;flex-shrink: 0;
-				background-image: url("@/static/images/common/nav-bar-jt-bottom.svg");
-				transform: rotate(270deg);margin-left: 4rpx;}
 			// 文字行
 			.input-text-row{height:60rpx;display: flex;align-items: center;flex: 1;justify-content: flex-end;}
 			// 文字 超出省略
@@ -1367,6 +1364,14 @@
 			.text-ellipsis{@include single-line-ellipsis();margin-left: 24rpx;}
 		}
 		
+		// 新增删除按钮
+		.fwnr-add-btn,.fwnr-del-btn{
+			width: 60rpx;height: 60rpx;display: flex;align-items: center;justify-content: center;
+			position: absolute;right: -8rpx;top: 22rpx;flex-shrink: 0;
+			icon{@include ezy-no-repeat-cover;display: block;flex-shrink: 0;}
+		}
+		.fwnr-add-btn icon{width: 35rpx;height: 35rpx;background-image: url("@/static/images/common/add-icon.svg");}
+		.fwnr-del-btn icon{width: 32rpx;height: 32rpx;background-image: url("@/static/images/common/jh-icon.svg");}
 	}
 	
 	// 底部footer

+ 8 - 6
pages/admin/Hetong/components/haiziNianling.vue

@@ -1,11 +1,13 @@
 <template>
-	<view v-for="(item,index) in myData.children" :key="item.timer">
-		<view><text v-if="index == 0">孩子年龄</text></view>
+	<view v-for="(item,index) in myData.children" :key="item.timer" class="fwnr-label-input">
+		<view class="fwnr-form-label"><text class="form-label-require"></text><template v-if="index == 0">孩子年龄</template></view>
 		<uni-easyinput v-model="item.age" placeholder="请输入孩子年龄" @change="onChange" />
-		<button @click="handleAdd" v-if="myData.children.length == 1">+</button>
-		<button @click="handleAdd"
-			v-else-if="myData.children.length-1 == index && myData.children.length != 1 && myData.children.length<3">+</button>
-		<button @click="handleDelete(item.timer)" v-else>-</button>
+		<view @click="handleAdd" v-if="myData.children.length == 1" class="fwnr-add-btn"><icon></icon></view>
+		<view @click="handleAdd" class="fwnr-add-btn"
+			v-else-if="myData.children.length-1 == index && myData.children.length != 1 && myData.children.length<3">
+			<icon></icon>
+		</view>
+		<view @click="handleDelete(item.timer)" v-else class="fwnr-del-btn"><icon></icon></view>
 	</view>
 </template>
 

+ 1 - 0
static/images/common/jh-icon.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1764123288075" class="icon" viewBox="0 0 1026 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="5577" data-spm-anchor-id="a313x.search_index.0.i1.7ea23a81aGzUav" xmlns:xlink="http://www.w3.org/1999/xlink" width="60.1171875" height="60"><path d="M511.602721 1023.001027a511.474051 511.474051 0 1 1 360.629164-148.84694 509.476105 509.476105 0 0 1-360.629164 149.845913z m0-941.032335c-109.887003 0-220.772979 41.956856-304.686691 125.870567-167.827423 168.826396-167.827423 441.545958 0 609.373381s440.546985 167.827423 609.373381 0c167.827423-167.827423 167.827423-440.546985 0-609.373381-83.913711-82.914739-194.799687-124.871594-304.68669-124.871595z m332.657927 763.215185z" fill="#3fd2a1" p-id="5578"></path><path d="M780.326392 552.484859H241.880077a39.95891 39.95891 0 0 1 0-79.91782h538.446315a39.95891 39.95891 0 0 1 0 79.91782z" fill="#3fd2a1" p-id="5579"></path></svg>