lisy 4 dagar sedan
förälder
incheckning
85a6f02a5e

+ 11 - 5
src/plant/port/port-create/index.vue

@@ -455,10 +455,10 @@
                         </up-form-item>
                         <up-form-item :borderBottom="false" label="具体位置" prop="landLayers" id="landLayerspppp">
                             <Go_button @click="openLaboratory" title="请选择具体位置" style="flex: 1" />
-                            <view class="w-100%" v-for="(it, indexs) in form?.landLayers" :key="indexs">
-                                <view class="">{{ it?.layers }}</view>
-                                <view class="">{{ stringifyCheckedList(it?.checkedList, Number(it?.capacityAmount || 0)) }}</view>
-                                <view class="" @click="deleteLayer(indexs)">删除</view>
+                            <view class="w-100% p-rtv" v-for="(it, indexs) in form?.landLayers" :key="indexs" style="border: 1px solid #afddbb">
+                                <view class="c-#333 f-s-34 f-w-5">{{ it?.landName }}</view>
+                                <view class="c-#666 f-s-24">{{ stringifyCheckedList(it?.checkedList, Number(it?.capacityAmount || 0)) }}</view>
+                                <view class="c-#F81242 h-20 w-20" style="position: absolute; right: 4rpx; top: 4rpx" @click="deleteLayer(indexs)">x</view>
                             </view>
                         </up-form-item>
                     </view>
@@ -1005,7 +1005,7 @@ const validateBreedingTime = (rule: any, value: any, callback: any) => {
 
 // 自定义校验函数:养殖量校验
 const validateBreedingAmount = (rule: any, value: any, callback: any) => {
-    if (+deawerData.value?.data[0]?.landType == 3) {
+    if (+deawerData.value?.data?.[0]?.landType == 3) {
         callback();
         return;
     }
@@ -1408,6 +1408,12 @@ function handleLaboratoryClose() {
 }
 // 处理实验室的打开
 function openLaboratory() {
+    uni.$once('cultivationLocationSelected', function (data) {
+        console.log(data);
+        if (data) {
+            form.value.landLayers = data;
+        }
+    });
     uni.navigateTo({
         url: `/tools/select-cultivation-location/index`,
         success: (res) => {

+ 3 - 3
src/plant/port/port-listinfo/models/task_card.vue

@@ -17,7 +17,7 @@
                 <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
                     {{ data?.baseRef?.baseInfo?.address }}基地
                     <!-- <text v-if="+data?.landFlag">全部地块</text> -->
-                    <view>
+                    <view class="tx-ov w-s-no ov-hd">
                         <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"><text v-if="index != 0">、</text> {{ item?.landName }}</text>
                     </view>
                 </view>
@@ -52,7 +52,7 @@
                 <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
                     {{ data?.baseRef?.baseInfo?.address }}基地
                     <!-- <text v-if="+data?.landFlag">全部地块</text> -->
-                    <view>
+                    <view class="tx-ov w-s-no ov-hd">
                         <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"><text v-if="index != 0">、</text> {{ item?.landName }}</text>
                     </view>
                 </view>
@@ -87,7 +87,7 @@
                 <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
                     {{ data?.baseRef?.baseInfo?.address }}基地
                     <!-- <text v-if="+data?.landFlag">全部地块</text> -->
-                    <view>
+                    <view class="tx-ov w-s-no ov-hd">
                         <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"><text v-if="index != 0">、</text> {{ item?.landName }}</text>
                     </view>
                 </view>