Преглед изворни кода

更新 创建船东-央视

王智慧 пре 3 година
родитељ
комит
3d87c11d61

+ 1 - 1
miniprogram/pages/shipOwnerManage/addShipOnwer/addShipOnwer.js

@@ -163,7 +163,7 @@ Page({
     } else {
       wx.showToast({
         title: res.data.msg,
-        icon: "error"
+        icon: "none"
       })
     }
   }

+ 53 - 44
miniprogram/pages/shipOwnerManage/addShipOnwer/addShipOnwer.wxml

@@ -1,52 +1,61 @@
 <view class="box">
   <block wx:if="{{step==1}}">
-    <view style="margin-bottom: 5vw;">请输入船东手机号</view>
-    <input model:value="{{userPhone}}" class="ship-owner-phone" type="number" placeholder-style="text-align:left" placeholder="必填" />
-    <view bindtap="checkShipOwner" class="next">新建</view>
+    <view class="df aic new-line">
+      <view class="title">船东电话<text style="color: #ff182b;">*</text></view>
+      <input model:value="{{userPhone}}" class="ship-owner-phone" type="number" placeholder-style="text-align:left" placeholder="请输入船东手机号" />
+    </view>
+    <view bindtap="checkShipOwner" class="new-next">新建</view>
   </block>
   <block wx:if="{{step==2}}">
-    <view>船东信息</view>
-    <view class="df jcsb line">
-      <view>姓名</view>
-      <view><input disabled="{{userId}}" model:value="{{userName}}" type="text" placeholder="必填" /></view>
-    </view>
-    <view class="df jcsb line">
-      <view>手机号</view>
-      <view><input disabled="{{userId}}" model:value="{{userPhone}}" type="text" placeholder="必填" /></view>
-    </view>
-    <view class="df jcsb line">
-      <view>身份证号</view>
-      <view><input model:value="{{idcardNo}}" type="idcard" /></view>
-    </view>
-    <view>
-      <view>身份证人像面</view>
-      <image wx:if="{{idcardFrontViewUrl}}" class="upload-image" bindtap="uploadId" data-type="head" src="{{idcardFrontViewUrl}}"></image>
-      <view wx:else="" class="upload" bindtap="uploadId" data-type="head">点击上传</view>
-    </view>
-    <view>
-      <view>身份证国徽面</view>
-      <image wx:if="{{idcardBackViewUrl}}" class="upload-image" bindtap="uploadId" data-type="emblem" src="{{idcardBackViewUrl}}"></image>
-      <view wx:else="" class="upload" bindtap="uploadId" data-type="emblem">点击上传</view>
-    </view>
-    <view bindtap="step2next" class="next">下一步</view>
+    <view class="df aic new-line">
+      <view class="title">姓名<text style="color: #ff182b;">*</text></view>
+      <input disabled="{{userId}}" model:value="{{userName}}" type="text" placeholder="请输入船东姓名" />
+    </view>
+    <view class="df aic new-line">
+      <view class="title">手机号<text style="color: #ff182b;">*</text></view>
+      <input disabled="{{userId}}" model:value="{{userPhone}}" type="number" placeholder="请输入船东手机号" />
+    </view>
+    <view class="df aic new-line">
+      <view class="title">身份证号</view>
+      <input model:value="{{idcardNo}}" type="idcard" type="idcard" placeholder="请输入身份证号" />
+    </view>
+    <view class="id-title">
+      身份证人像面
+    </view>
+    <image wx:if="{{idcardFrontViewUrl}}" class="id-uploader" bindtap="uploadId" data-type="head" src="{{idcardFrontViewUrl}}"></image>
+    <view wx:else="" class="id-uploader" bindtap="uploadId" data-type="head">
+      <view class="uploader-icon">+</view>
+      <view class="uploader-text">上传照片</view>
+    </view>
+    <view class="id-title">
+      身份证国徽面
+    </view>
+    <image wx:if="{{idcardBackViewUrl}}" class="id-uploader" bindtap="uploadId" data-type="emblem" src="{{idcardBackViewUrl}}"></image>
+    <view wx:else="" class="id-uploader" bindtap="uploadId" data-type="emblem">
+      <view class="uploader-icon">+</view>
+      <view class="uploader-text">上传照片</view>
+    </view>
+    <view bindtap="step2next" class="next-2">下一步</view>
   </block>
   <block wx:if="{{step==3}}">
-    <view>船舶信息</view>
-    <view class="df jcsb line">
-      <view>船舶名称</view>
-      <view><input disabled="{{shipId}}" model:value="{{shipName}}" type="text" placeholder="必填" /></view>
-    </view>
-    <view class="df jcsb line">
-      <view>MMSI</view>
-      <view><input disabled="{{shipId}}" model:value="{{shipMmsi}}" type="number" placeholder="必填" /></view>
-    </view>
-    <view>
-      <view>船舶证书</view>
-      <block wx:if="{{shipCerts.length}}">
-        <image bindtap="uploadShipCerts" wx:for="{{shipCerts}}" data-index="{{index}}" class="upload-image" src="{{item.viewUrl}}"></image>
-      </block>
-      <view data-type="push" class="upload" bindtap="uploadShipCerts">上传</view>
-    </view>
-    <view bindtap="submit" class="next">确定</view>
+    <view class="df aic new-line">
+      <view class="title">船舶名称<text style="color: #ff182b;">*</text></view>
+      <input disabled="{{shipId}}" model:value="{{shipName}}" type="text" placeholder="请输入船舶名称" />
+    </view>
+    <view class="df aic new-line">
+      <view class="title">MMSI<text style="color: #ff182b;">*</text></view>
+      <input disabled="{{shipId}}" model:value="{{shipMmsi}}" type="number" placeholder="请输入MMSI" />
+    </view>
+    <view class="id-title">
+      船舶证书
+    </view>
+    <block wx:if="{{shipCerts.length}}">
+      <image bindtap="uploadShipCerts" wx:for="{{shipCerts}}" data-index="{{index}}" class="id-uploader" src="{{item.viewUrl}}"></image>
+    </block>
+    <view data-type="push" class="id-uploader" bindtap="uploadShipCerts">
+      <view class="uploader-icon">+</view>
+      <view class="uploader-text">上传证书</view>
+    </view>
+    <view bindtap="submit" class="next-2">确定</view>
   </block>
 </view>

+ 65 - 50
miniprogram/pages/shipOwnerManage/addShipOnwer/addShipOnwer.wxss

@@ -1,68 +1,83 @@
 /* pages/shipOwnerManage/addShipOnwer/addShipOnwer.wxss */
-.box {
-  width: 80vw;
-  border: 2rpx solid grey;
-  border-radius: 10rpx;
-  text-align: center;
-  margin: 0 auto;
-  padding: 5vw 0;
+.new-line {
+  width: 690rpx;
+  border-bottom: 1px solid #EBEBEB;
+  height: 105rpx;
+  margin-left: 30rpx;
 }
 
-.ship-owner-phone {
-  width: 400rpx;
-  height: 60rpx;
-  border: 1rpx solid grey;
-  margin: 0 auto;
-  border-radius: 6rpx;
-  padding-left: 20rpx;
+.title {
+  width: 160rpx;
+  font-size: 30rpx;
+  font-family: PingFangSC-Regular, PingFang SC;
+  font-weight: 400;
+  color: #20252E;
+  margin-right: 60rpx;
 }
 
-.line {
-  width: 80%;
-  margin: 30rpx auto;
-  font-size: 28rpx;
+.new-next {
+  width: 590rpx;
+  height: 96rpx;
+  background: linear-gradient(270deg, #0089FD 0%, #43A9FF 100%);
+  border-radius: 20rpx;
+  font-size: 34rpx;
+  font-family: PingFangSC-Medium, PingFang SC;
+  font-weight: 500;
+  color: #FFFFFF;
+  text-align: center;
+  line-height: 96rpx;
+  margin: 365rpx auto;
 }
 
-.line view {
-  line-height: 48rpx;
-
+.id-title {
+  font-size: 30rpx;
+  font-family: PingFangSC-Regular, PingFang SC;
+  font-weight: 400;
+  color: #20252E;
+  margin: 30rpx;
 }
 
-.line input {
-  border: 1px solid grey;
-  height: 48rpx;
+.id-uploader {
+  margin: 30rpx auto;
+  width: 666rpx;
+  height: 194rpx;
+  background: rgba(12, 143, 253, 0.1);
+  border-radius: 4rpx;
+  border: 2rpx dashed #028AFD;
+  display: block;
 }
 
-.upload {
-  width: 68vw;
-  height: 32vw;
-  line-height: 32vw;
+.uploader-icon {
+  width: 40rpx;
+  height: 40rpx;
+  line-height: 30rpx;
+  border-radius: 40rpx;
   font-size: 40rpx;
-  color: rgb(214, 211, 211);
-  border: 1px solid grey;
-  margin: 3vw auto;
-  border-radius: 10rpx;
-
-}
-
-page {
-  padding-top: 5vw;
+  border: 2rpx solid #028AFD;
+  color: #028AFD;
+  text-align: center;
+  margin: 30rpx auto;
 }
 
-.upload-image {
-  width: 68vw;
-  height: 32vw;
-  border: 1px solid grey;
-  margin: 3vw auto;
+.uploader-text {
+  font-size: 30rpx;
+  font-family: PingFangSC-Regular, PingFang SC;
+  font-weight: 400;
+  color: #666666;
+  text-align: center;
 }
 
-.next {
-  width: 300rpx;
-  height: 80rpx;
-  line-height: 80rpx;
-  color: #fff;
-  background: #0094FE;
-  border-radius: 10rpx;
+.next-2 {
+  width: 590rpx;
+  height: 96rpx;
+  background: linear-gradient(270deg, #0089FD 0%, #43A9FF 100%);
+  border-radius: 20rpx;
   margin: 0 auto;
-  margin-top: 8vw;
+  margin-top: 128rpx;
+  text-align: center;
+  font-size: 34rpx;
+  font-family: PingFangSC-Medium, PingFang SC;
+  font-weight: 500;
+  color: #FFFFFF;
+  line-height: 96rpx;
 }

+ 7 - 0
project.private.config.json

@@ -29,6 +29,13 @@
           "query": "",
           "launchMode": "default",
           "scene": null
+        },
+        {
+          "name": "",
+          "pathName": "pages/shipOwnerManage/addShipOnwer/addShipOnwer",
+          "query": "",
+          "launchMode": "default",
+          "scene": null
         }
       ]
     }