瀏覽代碼

前端孟祥旭

mxx 4 年之前
父節點
當前提交
54aad99327

+ 8 - 6
src/views/warehouse/warehouseManagementDelete.vue

@@ -2,9 +2,6 @@
 <template>
 
   <div class="homepage"> 
-     <el-row>
-
-  <div>
     <el-row>
 
       <el-col :span="20">
@@ -48,7 +45,7 @@
         <el-table-column prop="personCharge;" label="负责人"> </el-table-column>
 
         <el-table-column prop="address" label="操作" width="200">
-          <template slot-scope="scope">
+          <!-- <template slot-scope="scope">
             <ws-button
               type="primary"
               @click="handleHide(scope.row)"
@@ -69,13 +66,18 @@
             >
             <ws-button
               type="primary"
-              @click="handleDelete(scope.row)"
+              @click="handleDelete(sv-ifcope.row)"
               v-hasPermission="
                 `${$permission('PERMISSIONS.PURSPAPPLINFO_CREATEINSTORE')}`
               "
               >删除</ws-button
             >
-          </template>
+          </template> -->
+           <template slot-scope="scope">
+            <div class="" v-if="scope.row.showFlag == 0" @click="handleHide(scope.row)">显示</div>
+            <div class="" v-if="scope.row.showFlag == 1" @click="handleHide(scope.row)">隐藏</div>
+            <div class=""  @click="handleDelete(scope.row)">删除</div>
+          </template><v-if></v-if>
         </el-table-column>
       </el-table>
     </div>

+ 0 - 4
src/views/warehouse/warehouseManagementDelivery.vue

@@ -238,11 +238,7 @@
           class="bg-bottom-up"
           type="primary"
           size="small"
-<<<<<<< HEAD
-          @click="returnWarehouse()"
-=======
           @click="temporaryStorage()"
->>>>>>> 41d88bb42d0ea473ee1ccee04976060fbd8bbb5d
           >暂存</el-button
         >
         <el-button

+ 7 - 2
src/views/warehouse/warehouseManagementList.vue

@@ -303,10 +303,15 @@ export default {
     },
     //待完成//传参
     nocomplete(row) {
-      console.log(row)
       this.$router.push({
         path: 'warehouseManagementNoComplete',
-        query: { baseId: row.warehouseId, positionId: row.binNumberId },
+        query: { baseId: row.warehouseId,
+         positionId: row.binNumberId,
+         warehouseName: row.warehouseName,
+          binNumber : row.binNumber
+              
+
+        },
       })
     },
     //记录

+ 172 - 16
src/views/warehouse/warehouseManagementNoComplete.vue

@@ -9,14 +9,30 @@
           class="bg-bottom"
           type="primary"
           size="small"
-          @click="returnWarehouse"
-          >返回</el-button
+          @click="returnWarehouse()"
+          ><img
+            width="6"
+            height="10"
+            style="vertical-align: bottom; margin-right: 3px"
+            src="../../../public/img/lujing.png"
+            alt=""
+          />返回</el-button
         >
       </el-col>
     </el-row>
+<ws-form ref="deptBudgetList" :v-model="deptBudgetList">
     <div class="center">
-      <h2>鲅鱼圈一号库 102仓位(容量100吨)</h2>
-      <!-- <ws-form ref="deptBudgetList" :v-model="deptBudgetList"> -->
+     <h2 style="padding-left: 20px">
+        <img
+          style="position: relative; top: 2px"
+          width="19"
+          height="19"
+          src="../../../public/img/cangku.png"
+          alt=""
+        />
+        {{ this.$route.query.warehouseName}}库
+          {{ this.$route.query.binNumber }}仓位
+      </h2>
         <el-table
         :data="improved.records"
         >
@@ -30,17 +46,34 @@
           <el-table-column prop="tare" label="毛重(吨)"></el-table-column>
           <el-table-column prop="grossWeight" label="皮重(吨)"> </el-table-column>
           <el-table-column prop="netWeight" label="净重(吨)"></el-table-column>   
-          <el-table-column prop="grade" label="品级"> </el-table-column>
+          <el-table-column prop="grade" label="品级">
+            <template slot-scope="scope">
+          <span v-if="scope.row.grade == '一等品'" class="top-grade">{{
+            scope.row.grade
+          }}</span>
+          <span v-if="scope.row.grade == '二等品'" class="second-class">{{
+            scope.row.grade
+          }}</span>
+          <span v-if="scope.row.grade == '三等品'" class="third-class">{{
+            scope.row.grade
+          }}</span>
+          <span v-if="scope.row.grade == '等外'" class="substandard">{{
+            scope.row.grade
+          }}</span>
+        </template>
+            
+             </el-table-column>
           <el-table-column prop="inOutDate" label="出入库日期"> </el-table-column>
-          <el-table-column prop="inOutType" label="类型"> </el-table-column>
+          <el-table-column prop="inOutType" label="类型">
+             </el-table-column>
           <el-table-column prop="contractNo" label="合同编号"> </el-table-column>
           <el-table-column prop="carNo" label="车牌号"> </el-table-column>
           <el-table-column prop="agent" label="经办人"> </el-table-column>
           <el-table-column prop="backOffice" label="内勤"> </el-table-column>
           <el-table-column prop="updateDate" label="保存时间"> </el-table-column>
           <el-table-column prop="address" label="操作" width="200">
-            <template scope="scope">
-          <ws-button
+            <!-- <template scope="scope"> -->
+          <!-- <ws-button
             type="primary"
              @click="edits(scope.row)"
             v-hasPermission="
@@ -48,18 +81,23 @@
             "
            
             >编辑</ws-button
-          >
-          <ws-button
+          > -->
+          <!-- <ws-button
             type="primary"
             @click="handleDelete(scope.row)"
             v-hasPermission="
               `${$permission('PERMISSIONS.PURSPAPPLINFO_CREATEINSTORE')}`
             "
             >删除</ws-button
-          >
+          > -->
+          <!-- </template> -->
+          <template slot-scope="scope">
+            <div class="record" @click="edits(scope.row)">编辑</div>
+            <div class="adjustment" @click="handleDelete(scope.row)">删除</div>
           </template>
         </el-table-column>
         </el-table>
+        
         <div style="text-align: right; padding: 10px">
           <el-button
             class="bg-bottom-up"
@@ -70,10 +108,11 @@
           >
           
         </div>
-      <!-- </ws-form> -->
+     
     </div>
+     </ws-form>
   </div>
-  
+
 </template>
 <script>
 import {
@@ -83,6 +122,7 @@ import {
   editstatus,
   billoperatehis,
   deletewarehouse,
+  warehouseName,
 } from '@/model/warehouse/index'
 import { downloadFile } from '@/utils/batchDown'
 import Pagination from '@/components/Pagination'
@@ -128,6 +168,7 @@ export default {
       currentPage:'1',
       improved:[],
       row:[],
+      deptBudgetList1:[],
 
       // 提交类型
       submitType: true,
@@ -157,6 +198,8 @@ export default {
     //cg.viewBudget
     //cg.viewSpareMoney
     // this.getVesselData();
+     this.deptBudgetList1.warehouseName = this.$route.query.warehouseName
+     this.binNumber = this.$route.params.binNumber
     
     //接参
     this.getList(this.$route.query.baseId,this.$route.query.positionId)
@@ -176,12 +219,22 @@ export default {
       if(row.inOutFlag==2){
          this.$router.push({
            path:'warehouseManagementPerfectput',
-          
+           query:{
+             warehouseName:row.warehouseName,
+            binNumber:row.binNumber,
+            baseId: row.warehouseId,
+            positionId: row.binNumberId,
+           }
            })
       }else if(row.inOutFlag==1){
         this.$router.push({
           path:'warehouseManagementPerfectDelivery',
-
+          query:{
+            warehouseName:row.warehouseName,
+            binNumber:row.binNumber,
+            baseId: row.warehouseId,
+            positionId: row.binNumberId,
+          }
           })
         
       }
@@ -230,6 +283,7 @@ export default {
           positionId:id1,
           pageSize:this.pageSize,
           currentPage:this.currentPage,
+          
           // inOutDate:this.inOutDate
     })
     .toPromise()
@@ -346,5 +400,107 @@ export default {
 /deep/.el-form-item {
   width: 33%;
 }
-
+.winseaview-main{
+  
+  // box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.5), 0px 0px 8px 0px rgba(0, 0, 0, 0.1);
+}
+.el-row{
+  background: #F6F7FC;
+  box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.5);
+  border-radius: 4px 4px 1px 1px;
+}
+.container .bg-left{
+  
+}
+.container .bg-bottom{
+  width: 74px;
+  height: 32px;
+  background: #5473E8;
+  border-radius: 4px;
+}
+.bg-bottom {
+    margin-top: 5px 0px;
+}
+.el-table .el-table__header tr{
+  width: 1091px;
+  height: 50px;
+  background: #F6F7FC;
+  border: 1px solid #E8ECF6;
+  text-align: center;
+}
+.el-table .cell{
+  text-align: center;
+  width: 29px;
+height: 20px;
+font-size: 14px;
+font-family: PingFangSC-Regular, PingFang SC;
+font-weight: 400;
+color: #5878E8;
+line-height: 20px;
+}
+.default .winseaview-main .el-table th>.cell{
+  color: #8890B1;
+}
+.record, .adjustment {
+    display: inline-block;
+    color: #5878e8;
+    padding: 0 4px !important;
+    position: relative;
+}
+/deep/.el-table td, .el-table th {
+  text-align: center;
+}
+/deep/.el-table .el-table__header th {
+    border-bottom-width: 0px;
+    text-align: center;
+}
+.top-grade {
+  background: linear-gradient(90deg, #5678e9, #7993f6);
+  color: #fff;
+  padding: 3px;
+  border-radius: 2px;
+}
+.second-class {
+  background: linear-gradient(90deg, #50cdd9, #82e2ea);
+  color: #fff;
+  padding: 3px;
+  border-radius: 2px;
+}
+.third-class {
+  background: linear-gradient(90deg, #ffa735, #ffbf70);
+  color: #fff;
+  padding: 3px;
+  border-radius: 2px;
+}
+.substandard {
+  background: linear-gradient(90deg, #b2b4bb, #ced0d5);
+  color: #fff;
+  padding: 3px;
+  border-radius: 2px;
+}
+// .container .bg-left{
+// width: 663px;
+// height: 28px;
+// font-size: 18px;
+// font-family: PingFangSC-Medium, PingFang SC;
+// font-weight: 500;
+// color: #262626;
+// line-height: 28px;
+// text-shadow: 0px 2px 4px rgba(0, 0, 0, 0.5);
+// }
+.a{
+  width: 19px;
+height: 19px;
+background: #AFB5CB;
+margin-left: 10px;
+}
+.container .bg-left{
+  width: 140px;
+height: 29px;
+font-size: 21px;
+font-family: PingFangSC-Semibold, PingFang SC;
+font-weight: 600;
+color: #323233;
+line-height: 29px;
+}
 </style>

+ 435 - 261
src/views/warehouse/warehouseManagementPerfectDelivery.vue

@@ -1,246 +1,259 @@
-// 完善入库信息
+
+// 完善出库信息
 <template>
   <div class="container">
     <el-row>
       <el-col :span="20">
-        <h2 class="bg-left title">完善出库信息</h2>
+        <h2 class="bg-left title">完善出库登记</h2>
       </el-col>
       <el-col :span="4" class="bg-right">
         <el-button
           class="bg-bottom"
           type="primary"
           size="small"
-          @click="returnNoComplete()"
+          @click="returnWarehouse()"
           >返回</el-button
         >
       </el-col>
     </el-row>
-    <div class="center">
-      <h2>鲅鱼圈一号库 102仓位</h2>
-      <ws-form ref="deptBudgetList" :model="deptBudgetList">
-        
-        <!--毛重(吨)-->
-        <ws-form-item label="毛重(吨)" span="1" prop="shippingType">
+
+    <ws-form ref="deptBudgetList" :model="deptBudgetList" :rules="rules">
+      <div class="basicInformation">
+        <h2>
+          {{ this.deptBudgetList1.warehouseName}}库
+           <span class="position">
+          {{this.deptBudgetList1.binNumber }}仓位
+          </span>
+        </h2>
+       <div class="small-title">基本信息</div>
+        <ws-info-table>
+          <!-- 货名 -->
+          <ws-form-item label="货名" span="1">
+            <ws-select
+              v-model="deptBudgetList.goodsName"
+              placeholder=""
+              class="typeselect"
+              @change="selectgoodsName"
+            >
+              <ws-option
+                v-for="item in goodnameList"
+                :key="item.constKey"
+                :label="item.constValue"
+                :value="item.constValue"
+              />
+            </ws-select>
+          </ws-form-item>
+          <!--毛重(吨)-->
+          <ws-form-item label="毛重(吨)" span="1" prop="grossWeight">
+            <ws-input
+              @input="grossWeightchange"
+              v-model="deptBudgetList.grossWeight"
+              placeholder="请输入毛重"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+
+          <!--皮重(吨)-->
+          <ws-form-item
+            label="皮重(吨)"
+            span="1"
+            prop="tare"
+            class="readonly"
+          >
+            <ws-input
+              @input="tarechange"
+              v-model="deptBudgetList.tare"
+              placeholder="请输入皮重"
+              maxlength="100"
+              size="small"
+            />
+          </ws-form-item>
+
+          <!--净重(吨)-->
+          <ws-form-item label="净重(吨)" span="1" prop="netWeight">
+            <ws-input
+              v-model.number="deptBudgetList.netWeight"
+              placeholder="不可编辑,自动计算"
+              type="number"
+              maxlength="120"
+              size="small"
+            />
+          </ws-form-item>
+          <!-- 品级 -->
+          <ws-form-item label="品级" span="1" class="readonly">
+            <ws-select
+              v-model="deptBudgetList.grade"
+              placeholder=""
+              class="typeselect"
+              @change="selectpackingMethod"
+            >
+              <ws-option
+                v-for="item in gradeList"
+                :key="item.constKey"
+                :label="item.constValue"
+                :value="item.constValue"
+              />
+            </ws-select>
+          </ws-form-item>
+
+          <!--经办人-->
+          <ws-form-item label="经办人" span="1" prop="agent">
+            <ws-input
+              v-model="deptBudgetList.agent"
+              placeholder="请输入出库经办人姓名"
+              maxlength="100"
+              size="small"
+            />
+          </ws-form-item>
+          <!--出库日期-->
+          <ws-form-item label="出库日期" span="1" prop="inOutDate" class="deliverydate">
+            <ws-date-picker
+              v-model="deptBudgetList.inOutDate"
+              type="date"
+              placeholder="请选择出库日期"
+              value-format="yyyy-MM-dd"
+            />
+          </ws-form-item>
+          <!-- 入库类型 -->
+          <ws-form-item label="出库类型" span="1">
+            <ws-select
+              v-model="deptBudgetList.inOutType"
+              placeholder=""
+              class="typeselect"
+              @change="selectstorageType"
+            >
+              <ws-option
+                v-for="item in storageType"
+                :key="item.constKey"
+                :label="item.constValue"
+                :value="item.constValue"
+              />
+            </ws-select>
+          </ws-form-item>
+
+          <!--车牌号-->
+          <ws-form-item label="车牌号" span="1" prop="sourceGoods">
+            <ws-input
+              v-model="deptBudgetList.carNo"
+              placeholder="请输入车牌号"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+
+          <!--合同编号-->
+          <ws-form-item label="合同编号" span="1" prop="contractNo">
+            <ws-input
+              v-model="deptBudgetList.contractNo"
+              placeholder="请输入合同编号"
+              maxlength="100"
+              size="small"
+            />
+          </ws-form-item>
+        </ws-info-table>
+      </div>
+       <div class="small-title">上传仓库照片</div>
+      <ws-upload
+        ref="upload"
+        table-name="maintain_work_order"
+        oss-key="mainPlan"
+        :comp-id="compId"
+        :appendix-ids="appendixIdsAdd"
+        :vesselId="deptBudgetList.addressUrl"
+        :size-limit="size"
+        @uploadSuccess="uploadSuccess"
+        @onChange="onChange"
+        accept=".jpg, .jpeg, .png, .pdf, .doc, .zip, .rar"
+      />
+     <div class="small-title">化验数据(选填)</div>
+      <div class="inspector">
+       <!--自检员-->
+        <ws-form-item label="质检员" span="1" prop="qualityInspector" >
           <ws-input
-            v-model="deptBudgetList.shippingType"
-            placeholder="请输入毛重"
-            maxlength="20"
+            v-model="deptBudgetList.warehouseInOutDetail.qualityInspector"
+            placeholder="请输入质检员姓名"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <!--皮重(吨)-->
-        <ws-form-item label="皮重(吨)" span="1" prop="buyer" class="readonly">
+        </div>
+        <div class="neifor">
+      <ws-info-table>
+        <!--水分(%)<=-->
+        <ws-form-item label="水分(%)<=" span="1" prop="waterContent">
           <ws-input
-            v-model="deptBudgetList.buyer"
-            placeholder="请输入皮重"
-            maxlength="100"
+            v-model="deptBudgetList.warehouseInOutDetail.waterContent"
+            placeholder="请输入水分占比"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <!--净重(吨)-->
-        <ws-form-item label="净重(吨)" span="1" prop="settlementMethod">
+        <!--杂质(%)<=-->
+        <ws-form-item label="杂质(%)<=" span="1" prop="impurity">
           <ws-input
-            v-model="deptBudgetList.settlementMethod"
-            placeholder="不可编辑,自动计算"
+            v-model="deptBudgetList.warehouseInOutDetail.impurity"
+            placeholder="请输入杂质占比"
             maxlength="120"
             size="small"
           />
         </ws-form-item>
-        <!-- 品级 -->
-        <ws-form-item label="品级" span="1" class="readonly">
-          <ws-select
-          v-model="deptBudgetList.grade"
-            placeholder=""
-            class="typeselect"
-            @change="selectpackingMethod"
-          >
-            <ws-option
-              v-for="item in gradeList"
-              :key="item.constKey"
-              :label="item.constValue"
-              :value="item.constValue"
-            />
-          </ws-select>
-        </ws-form-item>
-
-        <!--经办人-->
-        <ws-form-item label="经办人" span="1" prop="seller" class="readonly">
+        <!--容重(克/升)>=-->
+        <ws-form-item label="容重(克/升)>=" span="1" prop="bulkDensity">
           <ws-input
-            v-model="deptBudgetList.seller"
-            placeholder="请输入出库经办人姓名"
-            maxlength="100"
+            v-model="deptBudgetList.warehouseInOutDetail.bulkDensity"
+            placeholder="请输入容重"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-        <!--出库日期-->
-        <ws-form-item
-          label="出库日期"
-          span="1"
-          prop="signingDate"
-          class="deliverydate"
-        >
-          <ws-date-picker
-            v-model="deptBudgetList.signingDate"
-            type="date"
-            placeholder="请选择出库日期"
-            value-format="yyyy-MM-dd"
+        <!--霉变粒(%)<=-->
+        <ws-form-item label="霉变粒(%)<=" span="1" prop="mildewGrain">
+          <ws-input
+            v-model="deptBudgetList.warehouseInOutDetail.mildewGrain"
+            placeholder="请输入霉变粒占比"
+            maxlength="120"
+            size="small"
           />
         </ws-form-item>
-        <!-- 出库类型 -->
-        <ws-form-item label="出库类型" span="1" class="readonly">
-          <ws-select
-            placeholder=""
-            class="typeselect"
-            @change="selectpackingMethod"
-          >
-            <ws-option
-              v-for="item in goodnameList"
-              :key="item.constKey"
-              :label="item.constValue"
-              :value="item.constValue"
-            />
-          </ws-select>
-        </ws-form-item>
-
-        <!--车牌号-->
-        <ws-form-item label="车牌号" span="1" prop="sourceGoods">
+        <!--热损伤(%)<=-->
+        <ws-form-item label="热损伤(%)<=" span="1" prop="jiaorenli">
           <ws-input
-            v-model="deptBudgetList.sourceGoods"
-            placeholder="请输入车牌号"
-            maxlength="20"
+            v-model="deptBudgetList.warehouseInOutDetail.jiaorenli"
+            placeholder="请输入热损伤占比"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <!--合同编号-->
-        <ws-form-item label="合同编号" span="1" prop="contractNo">
+        <!--不完整粒(%)<=-->
+        <ws-form-item label="不完整粒(%)<=" span="1" prop="imperfectGrain">
           <ws-input
-            v-model.number="deptBudgetList.buyerPhone"
-            placeholder="请输入合同编号"
-            maxlength="100"
+            v-model="deptBudgetList.warehouseInOutDetail.imperfectGrain"
+            placeholder="请输入不完整粒占比"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <ws-upload
-          ref="upload"
-          table-name="maintain_work_order"
-          oss-key="mainPlan"
-          :comp-id="compId"
-          :appendix-ids="appendixIdsAdd"
-          :vesselId="deptBudgetList.addressUrl"
-          :size-limit="size"
-          @uploadSuccess="uploadSuccess"
-          @onChange="onChange"
-          accept=".jpg, .jpeg, .png, .pdf, .doc, .zip, .rar"
-        />
-
-        <div class="choice">
-          <h2>化验数据(选填)</h2>
-          <ws-info-table>
-            <!--自检员-->
-            <ws-form-item label="自检员" span="1" prop="settlementMethod">
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入自检员姓名"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-
-            <!--水分(%)<=-->
-            <ws-form-item label="水分(%)<=" span="1" prop="settlementMethod">
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入水分占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--杂质(%)<=-->
-            <ws-form-item label="杂质(%)<=" span="1" prop="settlementMethod">
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入杂质占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--容重(克/升)>=-->
-            <ws-form-item
-              label="容重(克/升)>="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入容重"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--霉变粒(%)<=-->
-            <ws-form-item
-              label="霉变粒(%)<="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入霉变粒占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--热损伤(%)<=-->
-            <ws-form-item
-              label="热损伤(%)<="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入热损伤占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--不完整粒(%)<=-->
-            <ws-form-item
-              label="不完整粒(%)<="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入不完整粒占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-          </ws-info-table>
-        </div>
-
-        <div style="text-align: right; padding: 10px">
-          <el-button
-            class="bg-bottom-up"
-            type="primary"
-            size="small"
-            @click="returnWarehouse()"
-            >暂存</el-button
-          >
-          <el-button
-            class="bg-bottom-up"
-            type="primary"
-            size="small"
-            @click="submit()"
-            >提交</el-button
-          >
-        </div>
-      </ws-form>
-    </div>
+       
+      </ws-info-table>
+      </div>
+      <div style="text-align: right; padding: 10px">
+        <el-button
+          class="bg-bottom-up"
+          type="primary"
+          size="small"
+          @click="temporaryStorage()"
+          >暂存</el-button
+        >
+        <el-button
+          class="bg-bottom-up"
+          type="primary"
+          size="small"
+          @click="submit()"
+          >提交</el-button
+        >
+      </div>
+    </ws-form>
   </div>
 </template>
 <script>
@@ -257,9 +270,9 @@ export default {
     Pagination,
   },
   watch: {
-    vesselId(val) {
-      this.getList()
-    },
+    // vesselId(val) {
+    //   this.getList()
+    // },
     isShow(val) {
       this.showType = val
     },
@@ -288,12 +301,22 @@ export default {
       goodnameList: {},
       // 提交类型
       submitType: true,
-      selectpackingMethod: {},
-
-      appendixIdsAdd: {},
+      storageType: [],
+      appendixIdsAdd: '',
       uploadSuccess: {},
       onChange: {},
-
+      deptBudgetList1:[],
+      gradeList: [],
+      rules: {
+        netWeight: [
+          {
+            required: true,
+            type: 'number',
+            message: '请输入活动名称',
+            trigger: 'blur',
+          },
+        ],
+      },
       size: 10,
       compId: sessionStorage.getItem('ws-pf_compId'),
       deptCircularPage: {},
@@ -303,7 +326,9 @@ export default {
         month: dayjs().format('MM'),
       },
       contractList: [],
-      deptBudgetList: {},
+      deptBudgetList: {
+        warehouseInOutDetail: {},
+      },
       historyList: [],
 
       pickerBeginDateBefore: {
@@ -314,27 +339,74 @@ export default {
       accessoryTFs: false,
     }
   },
-  activated() {
-    //cg.viewBudget
-    //cg.viewSpareMoney
-    // this.getVesselData();
-    // this.getList()
-    this.showType = this.isShow
-  },
-  mounted(){
+  mounted() {
+    this.deptBudgetList.baseId = this.$route.query.baseId
+    this.deptBudgetList.positionId = this.$route.query.positionId
+    this.deptBudgetList1.warehouseName = this.$route.query.warehouseName
+    this.deptBudgetList1.binNumber = this.$route.query.binNumber
     this.getList()
   },
   methods: {
     //返回按钮
-    returnNoComplete() {
+    returnWarehouse() {
       this.$router.push({ path: 'warehouseManagementNoComplete' })
     },
+    //暂存按钮
+    temporaryStorage() {
+      this.$confirm(`暂存后可在待完成页面查看,确定暂存`, {
+        cancelButtonText: '取消',
+        confirmButtonText: '确定',
+        type: 'warning',
+      })
+        .then(() => {
+          this.$refs.deptBudgetList.validate((valid) => {
+            if (valid) {
+              this.deptBudgetList.compId = sessionStorage.getItem(
+                'ws-pf_compId'
+              )
+              this.deptBudgetList.inOutFlag = 1
+              this.deptBudgetList.statusFlag = 1
+              addstorageputList(this.deptBudgetList)
+                .toPromise()
+                .then((response) => {
+                  this.$message.success('暂存成功')
+                  this.$router.push({ path: 'warehouseManagementList' })
+                })
+            } else {
+              EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
+              return false
+            }
+          })
+        })
+        .catch(() => {
+          return false
+        })
+    },
     //提交按钮
     submit() {
-     this.$refs.deptBudgetList.validate((valid) => {
+     if (this.deptBudgetList.warehouseInOutDetail.qualityInspector.length<2 || deptBudgetList.warehouseInOutDetail.qualityInspector > 10
+      ) {
+        this.$message({
+          message: '质检员姓名长度错误!',
+          type: 'warning',
+        })
+        return
+      }
+      if (this.deptBudgetList.warehouseInOutDetail.qualityInspector.length<2 || deptBudgetList.warehouseInOutDetail.qualityInspector > 10
+      ) {
+        this.$message({
+          message: '质检员姓名长度错误!',
+          type: 'warning',
+        })
+        return
+      }
+
+
+      this.$refs.deptBudgetList.validate((valid) => {
         if (valid) {
           this.deptBudgetList.compId = sessionStorage.getItem('ws-pf_compId')
           this.deptBudgetList.inOutFlag = 1
+          this.deptBudgetList.statusFlag = 3
           addstorageputList(this.deptBudgetList)
             .toPromise()
             .then((response) => {
@@ -349,15 +421,15 @@ export default {
     },
     //暂存按钮
     returnWarehouse() {
-       this.$refs.deptBudgetList.validate((valid) => {
+      this.$refs.deptBudgetList.validate((valid) => {
         if (valid) {
           this.deptBudgetList.compId = sessionStorage.getItem('ws-pf_compId')
           this.deptBudgetList.statusFlag = 1
           addstorageputList(this.deptBudgetList)
             .toPromise()
             .then((response) => {
-              this.$message.success('暂存成功')
-              this.$router.push({ path: 'warehouseManagementNoComplete' })
+              this.$message.success('添加成功')
+              this.$router.push({ path: 'warehouseManagementList' })
             })
         } else {
           EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
@@ -365,27 +437,40 @@ export default {
         }
       })
     },
-    dateFormat(fmt, date) {
-      let ret
-      const opt = {
-        'Y+': date.getFullYear().toString(), // 年
-        'm+': (date.getMonth() + 1).toString(), // 月
-        'd+': date.getDate().toString(), // 日
-        'H+': date.getHours().toString(), // 时
-        // "M+": date.getMinutes().toString(),         // 分
-        // "S+": date.getSeconds().toString()          // 秒
-        // 有其他格式化字符需求可以继续添加,必须转化成字符串
+    tarechange(e) {
+      if (this.deptBudgetList.grossWeight && this.deptBudgetList.tare) {
+        this.deptBudgetList.netWeight = Number(
+          this.deptBudgetList.grossWeight - this.deptBudgetList.tare
+        )
+      }
+    },
+    grossWeightchange(e) {
+      if (this.deptBudgetList.grossWeight && this.deptBudgetList.tare) {
+        this.deptBudgetList.netWeight = Number(
+          this.deptBudgetList.grossWeight - this.deptBudgetList.tare
+        )
+      }
+    },
+    selectgoodsName(e) {
+      for (var i = 0; i < this.goodnameList.length; i++) {
+        if (this.goodnameList[i].constValue == e) {
+          this.deptBudgetList.goodsNameKey = this.goodnameList[i].constKey
+        }
+      }
+    },
+    selectpackingMethod(e) {
+      for (var i = 0; i < this.packtypeList.length; i++) {
+        if (this.packtypeList[i].constValue == e) {
+          this.deptBudgetList.packingMethodKey = this.packtypeList[i].constKey
+        }
       }
-      for (let k in opt) {
-        ret = new RegExp('(' + k + ')').exec(fmt)
-        if (ret) {
-          fmt = fmt.replace(
-            ret[1],
-            ret[1].length == 1 ? opt[k] : opt[k].padStart(ret[1].length, '0')
-          )
+    },
+    selectstorageType(e) {
+      for (var i = 0; i < this.storageType.length; i++) {
+        if (this.storageType[i].constValue == e) {
+          this.deptBudgetList.inOutTypeKey = this.storageType[i].constKey
         }
       }
-      return fmt
     },
     handleClose() {
       this.accessoryTFs = false
@@ -401,7 +486,7 @@ export default {
       this.getList()
     },
     getList() {
-     // 货名
+      // 货名
       pullDown({ constId: 'CON2' })
         .toPromise()
         .then((response) => {
@@ -419,7 +504,6 @@ export default {
         .then((response) => {
           this.storageType = response
         })
-    
     },
     selecttaskType(e) {
       for (var i = 0; i < this.taskTypeList.length; i++) {
@@ -461,12 +545,7 @@ export default {
           this.historyList = response
         })
     },
-    find() {
-      this.startDate = this.dateFormat('YYYY-mm-dd', this.value2[0])
-      this.endDate = this.dateFormat('YYYY-mm-dd', this.value2[1])
-      this.currentPage = 1
-      this.getList()
-    },
+
     async exportlist() {
       const { data } = await export1(
         {
@@ -501,6 +580,49 @@ export default {
 }
 </script>
 <style lang="scss" scoped>
+/deep/.basicInformation {
+  .ws-info-table {
+    border: none;
+  }
+  .el-form-item {
+    width: 33.3333%;
+    border: none;
+    .el-form-item__label {
+      background: transparent;
+      border: none;
+    }
+    .el-form-item__content {
+      border: none;
+    }
+  }
+}
+.title {
+  position: relative;
+  padding-left: 10px;
+}
+.title::before {
+  content: '';
+  display: inline-block;
+  width: 5px;
+  height: 30px;
+  background: #5473e8;
+  position: absolute;
+  left: 0;
+}
+.el-form {
+  padding: 0 10%;
+}
+.el-button--primary {
+  background-color: #5878e8;
+  border-color: #5878e8;
+}
+.el-col {
+  background: #f6f7fc;
+}
+.bg-right {
+  text-align: right;
+  padding: 16px 20px;
+}
 .center {
   position: relative;
   top: 50px;
@@ -511,15 +633,7 @@ export default {
 /deep/.el-form-item__label {
   width: 160px;
 }
-/deep/.el-input--small {
-  width: 70%;
-}
-.container .bg-bottom {
-  position: absolute;
-  float: right;
-  top: 15px;
-  right: 20px;
-}
+
 //选填
 /deep/.el-form-item {
   width: 50%;
@@ -528,13 +642,73 @@ export default {
   overflow: scroll;
   height: 120vh;
 }
-/deep/.ws-info-table[data-v-850a44a6] .el-form-item .el-form-item__label {
+/deep/.ws-info-table .el-form-item .el-form-item__label {
   text-align: center;
 }
 .deliverydate {
-  width: 35%;
+  display: inline-block;
+  width: 10%;
 }
-.center[data-v-32a9842f] {
+.center {
   margin-top: -60px;
+    width: 80%;
+}
+//仓位
+.position{
+ width: 52px;
+height: 20px;
+background: #AFB5CB;
+border-radius: 2px;
+font-size: 12px;
+font-family: PingFangSC-Medium, PingFang SC;
+color: #FFFFFF;
+line-height: 20px;
+}
+//表格文字
+/deep/.ws-info-table .el-form-item .el-form-item__label{
+  text-align: left;
+font-size: 14px;
+font-family: PingFangSC-Regular, PingFang SC;
+font-weight: 400;
+color: #8890B1;
+line-height: 16px;
+}
+//质检员
+.inspector .el-form-item__content{
+  text-align: left;
+  margin-left: 0px;
+}
+.small-title {
+  position: relative;
+  padding: 10px;
+}
+.small-title::before {
+  position: absolute;
+  content: '';
+  display: block;
+  background: #5473e8;
+  width: 4px;
+  height: 14px;
+  left: 0px;
+  top: 13px;
+}
+//下面列表
+.neifor{
+  width: 80%;
+  background-color: #F6F7FC;
+}
+/deep/.neifor .ws-info-table .el-form-item .el-form-item__label{
+  width: 35%;
+  text-align: center;
+}
+/deep/.neifor .ws-info-table .el-form-item .el-form-item__content{
+  width: 60%;
+  background-color: #F6F7FC;
+}
+/deep/.neifor .el-input--small .el-input__inner{
+  width: 120%;
+}
+.el-input__inner{
+  width: 150px;
 }
 </style>

+ 432 - 268
src/views/warehouse/warehouseManagementPerfectput.vue

@@ -3,258 +3,256 @@
   <div class="container">
     <el-row>
       <el-col :span="20">
-        <h2 class="bg-left title">完善入库信息</h2>
+        <h2 class="bg-left title">完善入库登记</h2>
       </el-col>
       <el-col :span="4" class="bg-right">
         <el-button
           class="bg-bottom"
           type="primary"
           size="small"
-          @click="returnNoComplete()"
+          @click="returnWarehouse()"
           >返回</el-button
         >
       </el-col>
     </el-row>
-    <div class="center">
-      <h2>鲅鱼圈一号库 102仓位</h2>
-      <ws-form ref="deptBudgetList" :model="deptBudgetList">
-        <!-- 货名 -->
-        <ws-form-item label="货名" span="1" class="readonly">
-          <ws-select
-            placeholder=""
-            class="typeselect"
-            @change="selectpackingMethod"
+
+    <ws-form ref="deptBudgetList" :model="deptBudgetList" :rules="rules">
+      <div class="basicInformation">
+        <h2>
+          {{ deptBudgetList1.warehouseName }}库
+           <span class="position">
+          {{deptBudgetList1.binNumber }}仓位
+          </span>
+        </h2>
+       <div class="small-title">基本信息</div>
+        <ws-info-table>
+          <!-- 货名 -->
+          <ws-form-item label="货名" span="1">
+            <ws-select
+              v-model="deptBudgetList.goodsName"
+              placeholder=""
+              class="typeselect"
+              @change="selectgoodsName"
+            >
+              <ws-option
+                v-for="item in goodnameList"
+                :key="item.constKey"
+                :label="item.constValue"
+                :value="item.constValue"
+              />
+            </ws-select>
+          </ws-form-item>
+          <!--毛重(吨)-->
+          <ws-form-item label="毛重(吨)" span="1" prop="grossWeight">
+            <ws-input
+              @input="grossWeightchange"
+              v-model="deptBudgetList.grossWeight"
+              placeholder="请输入毛重"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+
+          <!--皮重(吨)-->
+          <ws-form-item
+            label="皮重(吨)"
+            span="1"
+            prop="tare"
+            class="readonly"
           >
-            <ws-option
-              v-for="item in goodnameList"
-              :key="item.constKey"
-              :label="item.constValue"
-              :value="item.constValue"
+            <ws-input
+              @input="tarechange"
+              v-model="deptBudgetList.tare"
+              placeholder="请输入皮重"
+              maxlength="100"
+              size="small"
             />
-          </ws-select>
-        </ws-form-item>
-        <!--毛重(吨)-->
-        <ws-form-item label="毛重(吨)" span="1" prop="shippingType">
+          </ws-form-item>
+
+          <!--净重(吨)-->
+          <ws-form-item label="净重(吨)" span="1" prop="netWeight">
+            <ws-input
+              v-model.number="deptBudgetList.netWeight"
+              placeholder="不可编辑,自动计算"
+              type="number"
+              maxlength="120"
+              size="small"
+            />
+          </ws-form-item>
+          <!-- 品级 -->
+          <ws-form-item label="品级" span="1" class="readonly">
+            <ws-select
+              v-model="deptBudgetList.grade"
+              placeholder=""
+              class="typeselect"
+              @change="selectpackingMethod"
+            >
+              <ws-option
+                v-for="item in gradeList"
+                :key="item.constKey"
+                :label="item.constValue"
+                :value="item.constValue"
+              />
+            </ws-select>
+          </ws-form-item>
+
+          <!--经办人-->
+          <ws-form-item label="经办人" span="1" prop="agent">
+            <ws-input
+              v-model="deptBudgetList.agent"
+              placeholder="请输入出库经办人姓名"
+              maxlength="100"
+              size="small"
+            />
+          </ws-form-item>
+          <!--出库日期-->
+          <ws-form-item label="出库日期" span="1" prop="inOutDate" class="deliverydate">
+            <ws-date-picker
+              v-model="deptBudgetList.inOutDate"
+              type="date"
+              placeholder="请选择出库日期"
+              value-format="yyyy-MM-dd"
+            />
+          </ws-form-item>
+          <!-- 入库类型 -->
+          <ws-form-item label="出库类型" span="1">
+            <ws-select
+              v-model="deptBudgetList.inOutType"
+              placeholder=""
+              class="typeselect"
+              @change="selectstorageType"
+            >
+              <ws-option
+                v-for="item in storageType"
+                :key="item.constKey"
+                :label="item.constValue"
+                :value="item.constValue"
+              />
+            </ws-select>
+          </ws-form-item>
+
+          <!--车牌号-->
+          <ws-form-item label="车牌号" span="1" prop="sourceGoods">
+            <ws-input
+              v-model="deptBudgetList.carNo"
+              placeholder="请输入车牌号"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+
+          <!--合同编号-->
+          <ws-form-item label="合同编号" span="1" prop="contractNo">
+            <ws-input
+              v-model="deptBudgetList.contractNo"
+              placeholder="请输入合同编号"
+              maxlength="100"
+              size="small"
+            />
+          </ws-form-item>
+        </ws-info-table>
+      </div>
+       <div class="small-title">上传仓库照片</div>
+      <ws-upload
+        ref="upload"
+        table-name="maintain_work_order"
+        oss-key="mainPlan"
+        :comp-id="compId"
+        :appendix-ids="appendixIdsAdd"
+        :vesselId="deptBudgetList.addressUrl"
+        :size-limit="size"
+        @uploadSuccess="uploadSuccess"
+        @onChange="onChange"
+        accept=".jpg, .jpeg, .png, .pdf, .doc, .zip, .rar"
+      />
+     <div class="small-title">化验数据(选填)</div>
+      <div class="inspector">
+       <!--自检员-->
+        <ws-form-item label="质检员" span="1" prop="qualityInspector" >
           <ws-input
-            v-model="deptBudgetList.shippingType"
-            placeholder="请输入毛重"
-            maxlength="20"
+            v-model="deptBudgetList.warehouseInOutDetail.qualityInspector"
+            placeholder="请输入质检员姓名"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <!--皮重(吨)-->
-        <ws-form-item label="皮重(吨)" span="1" prop="buyer" class="readonly">
+        </div>
+        <div class="neifor">
+      <ws-info-table>
+        <!--水分(%)<=-->
+        <ws-form-item label="水分(%)<=" span="1" prop="waterContent">
           <ws-input
-            v-model="deptBudgetList.buyer"
-            placeholder="请输入皮重"
-            maxlength="100"
+            v-model="deptBudgetList.warehouseInOutDetail.waterContent"
+            placeholder="请输入水分占比"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <!--净重(吨)-->
-        <ws-form-item label="净重(吨)" span="1" prop="settlementMethod">
+        <!--杂质(%)<=-->
+        <ws-form-item label="杂质(%)<=" span="1" prop="impurity">
           <ws-input
-            v-model="deptBudgetList.settlementMethod"
-            placeholder="不可编辑,自动计算"
+            v-model="deptBudgetList.warehouseInOutDetail.impurity"
+            placeholder="请输入杂质占比"
             maxlength="120"
             size="small"
           />
         </ws-form-item>
-        <!-- 品级 -->
-        <ws-form-item label="品级" span="1" class="readonly">
-          <ws-select
-            placeholder=""
-            class="typeselect"
-            @change="selectpackingMethod"
-          >
-            <ws-option
-              v-for="item in goodnameList"
-              :key="item.constKey"
-              :label="item.constValue"
-              :value="item.constValue"
-            />
-          </ws-select>
-        </ws-form-item>
-
-        <!--经办人-->
-        <ws-form-item label="经办人" span="1" prop="seller" class="readonly">
+        <!--容重(克/升)>=-->
+        <ws-form-item label="容重(克/升)>=" span="1" prop="bulkDensity">
           <ws-input
-            v-model="deptBudgetList.seller"
-            placeholder="请输入出库经办人姓名"
-            maxlength="100"
+            v-model="deptBudgetList.warehouseInOutDetail.bulkDensity"
+            placeholder="请输入容重"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-        <!--出库日期-->
-        <ws-form-item
-          label="出库日期"
-          span="1"
-          prop="signingDate"
-          class="deliverydate"
-        >
-          <ws-date-picker
-            v-model="deptBudgetList.signingDate"
-            type="date"
-            placeholder="请选择出库日期"
-            value-format="yyyy-MM-dd"
+        <!--霉变粒(%)<=-->
+        <ws-form-item label="霉变粒(%)<=" span="1" prop="mildewGrain">
+          <ws-input
+            v-model="deptBudgetList.warehouseInOutDetail.mildewGrain"
+            placeholder="请输入霉变粒占比"
+            maxlength="120"
+            size="small"
           />
         </ws-form-item>
-        <!-- 入库类型 -->
-        <ws-form-item label="入库类型" span="1" class="readonly">
-          <ws-select
-            placeholder=""
-            class="typeselect"
-            @change="selectpackingMethod"
-          >
-            <ws-option
-              v-for="item in goodnameList"
-              :key="item.constKey"
-              :label="item.constValue"
-              :value="item.constValue"
-            />
-          </ws-select>
-        </ws-form-item>
-
-        <!--车牌号-->
-        <ws-form-item label="车牌号" span="1" prop="sourceGoods">
+        <!--热损伤(%)<=-->
+        <ws-form-item label="热损伤(%)<=" span="1" prop="jiaorenli">
           <ws-input
-            v-model="deptBudgetList.sourceGoods"
-            placeholder="请输入车牌号"
-            maxlength="20"
+            v-model="deptBudgetList.warehouseInOutDetail.jiaorenli"
+            placeholder="请输入热损伤占比"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <!--合同编号-->
-        <ws-form-item label="合同编号" span="1" prop="contractNo">
+        <!--不完整粒(%)<=-->
+        <ws-form-item label="不完整粒(%)<=" span="1" prop="imperfectGrain">
           <ws-input
-            v-model.number="deptBudgetList.buyerPhone"
-            placeholder="请输入合同编号"
-            maxlength="100"
+            v-model="deptBudgetList.warehouseInOutDetail.imperfectGrain"
+            placeholder="请输入不完整粒占比"
+            maxlength="120"
             size="small"
           />
         </ws-form-item>
-
-        <ws-upload
-          ref="upload"
-          table-name="maintain_work_order"
-          oss-key="mainPlan"
-          :comp-id="compId"
-          :appendix-ids="appendixIdsAdd"
-          :vesselId="deptBudgetList.addressUrl"
-          :size-limit="size"
-          @uploadSuccess="uploadSuccess"
-          @onChange="onChange"
-          accept=".jpg, .jpeg, .png, .pdf, .doc, .zip, .rar"
-        />
-
-        <div class="choice">
-          <h2>化验数据(选填)</h2>
-          <ws-info-table>
-            <!--自检员-->
-            <ws-form-item label="自检员" span="1" prop="settlementMethod">
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入自检员姓名"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-
-            <!--水分(%)<=-->
-            <ws-form-item label="水分(%)<=" span="1" prop="settlementMethod">
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入水分占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--杂质(%)<=-->
-            <ws-form-item label="杂质(%)<=" span="1" prop="settlementMethod">
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入杂质占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--容重(克/升)>=-->
-            <ws-form-item
-              label="容重(克/升)>="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入容重"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--霉变粒(%)<=-->
-            <ws-form-item
-              label="霉变粒(%)<="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入霉变粒占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--热损伤(%)<=-->
-            <ws-form-item
-              label="热损伤(%)<="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入热损伤占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-            <!--不完整粒(%)<=-->
-            <ws-form-item
-              label="不完整粒(%)<="
-              span="1"
-              prop="settlementMethod"
-            >
-              <ws-input
-                v-model="deptBudgetList.settlementMethod"
-                placeholder="请输入不完整粒占比"
-                maxlength="120"
-                size="small"
-              />
-            </ws-form-item>
-          </ws-info-table>
-        </div>
-
-        <div style="text-align: right; padding: 10px">
-          <el-button
-            class="bg-bottom-up"
-            type="primary"
-            size="small"
-            @click="returnWarehouse()"
-            >暂存</el-button
-          >
-          <el-button
-            class="bg-bottom-up"
-            type="primary"
-            size="small"
-            @click="submit()"
-            >提交</el-button
-          >
-          
-        </div>
-      </ws-form>
-    </div>
+       
+      </ws-info-table>
+      </div>
+      <div style="text-align: right; padding: 10px">
+        <el-button
+          class="bg-bottom-up"
+          type="primary"
+          size="small"
+          @click="temporaryStorage()"
+          >暂存</el-button
+        >
+        <el-button
+          class="bg-bottom-up"
+          type="primary"
+          size="small"
+          @click="submit()"
+          >提交</el-button
+        >
+      </div>
+    </ws-form>
   </div>
 </template>
 <script>
@@ -271,9 +269,9 @@ export default {
     Pagination,
   },
   watch: {
-    vesselId(val) {
-      this.getList()
-    },
+    // vesselId(val) {
+    //   this.getList()
+    // },
     isShow(val) {
       this.showType = val
     },
@@ -302,12 +300,22 @@ export default {
       goodnameList: {},
       // 提交类型
       submitType: true,
-      selectpackingMethod: {},
-
-      appendixIdsAdd: {},
+      storageType: [],
+      appendixIdsAdd: '',
       uploadSuccess: {},
       onChange: {},
-
+      deptBudgetList1:[],
+      gradeList: [],
+      rules: {
+        netWeight: [
+          {
+            required: true,
+            type: 'number',
+            message: '请输入活动名称',
+            trigger: 'blur',
+          },
+        ],
+      },
       size: 10,
       compId: sessionStorage.getItem('ws-pf_compId'),
       deptCircularPage: {},
@@ -317,7 +325,9 @@ export default {
         month: dayjs().format('MM'),
       },
       contractList: [],
-      deptBudgetList: {},
+      deptBudgetList: {
+        warehouseInOutDetail: {},
+      },
       historyList: [],
 
       pickerBeginDateBefore: {
@@ -328,24 +338,75 @@ export default {
       accessoryTFs: false,
     }
   },
-  activated() {
-    //cg.viewBudget
-    //cg.viewSpareMoney
-    // this.getVesselData();
+  mounted() {
+    console.log(this.$route.query)
+    this.deptBudgetList.baseId = this.$route.query.baseId
+    this.deptBudgetList.positionId = this.$route.query.positionId
+    this.deptBudgetList1.warehouseName = this.$route.query.warehouseName
+    this.deptBudgetList1.binNumber = this.$route.query.binNumber
     this.getList()
-    this.showType = this.isShow
   },
   methods: {
     //返回按钮
-    returnNoComplete() {
+    returnWarehouse() {
       this.$router.push({ path: 'warehouseManagementNoComplete' })
     },
+    //暂存按钮
+    temporaryStorage() {
+      this.$confirm(`暂存后可在待完成页面查看,确定暂存`, {
+        cancelButtonText: '取消',
+        confirmButtonText: '确定',
+        type: 'warning',
+      })
+        .then(() => {
+          this.$refs.deptBudgetList.validate((valid) => {
+            if (valid) {
+              this.deptBudgetList.compId = sessionStorage.getItem(
+                'ws-pf_compId'
+              )
+              this.deptBudgetList.inOutFlag = 1
+              this.deptBudgetList.statusFlag = 1
+              addstorageputList(this.deptBudgetList)
+                .toPromise()
+                .then((response) => {
+                  this.$message.success('暂存成功')
+                  this.$router.push({ path: 'warehouseManagementList' })
+                })
+            } else {
+              EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
+              return false
+            }
+          })
+        })
+        .catch(() => {
+          return false
+        })
+    },
     //提交按钮
     submit() {
-       this.$refs.deptBudgetList.validate((valid) => {
+     if (this.deptBudgetList.warehouseInOutDetail.qualityInspector.length<2 || deptBudgetList.warehouseInOutDetail.qualityInspector > 10
+      ) {
+        this.$message({
+          message: '质检员姓名长度错误!',
+          type: 'warning',
+        })
+        return
+      }
+      if (this.deptBudgetList.warehouseInOutDetail.qualityInspector.length<2 || deptBudgetList.warehouseInOutDetail.qualityInspector > 10
+      ) {
+        this.$message({
+          message: '质检员姓名长度错误!',
+          type: 'warning',
+        })
+        return
+      }
+
+
+      this.$refs.deptBudgetList.validate((valid) => {
         if (valid) {
           this.deptBudgetList.compId = sessionStorage.getItem('ws-pf_compId')
           this.deptBudgetList.inOutFlag = 1
+          this.deptBudgetList.statusFlag = 3
           addstorageputList(this.deptBudgetList)
             .toPromise()
             .then((response) => {
@@ -358,16 +419,16 @@ export default {
         }
       })
     },
-    // 暂存按钮
+    //暂存按钮
     returnWarehouse() {
-       this.$refs.deptBudgetList.validate((valid) => {
+      this.$refs.deptBudgetList.validate((valid) => {
         if (valid) {
           this.deptBudgetList.compId = sessionStorage.getItem('ws-pf_compId')
           this.deptBudgetList.statusFlag = 1
           addstorageputList(this.deptBudgetList)
             .toPromise()
             .then((response) => {
-              this.$message.success('暂存成功')
+              this.$message.success('添加成功')
               this.$router.push({ path: 'warehouseManagementList' })
             })
         } else {
@@ -376,27 +437,40 @@ export default {
         }
       })
     },
-    dateFormat(fmt, date) {
-      let ret
-      const opt = {
-        'Y+': date.getFullYear().toString(), // 年
-        'm+': (date.getMonth() + 1).toString(), // 月
-        'd+': date.getDate().toString(), // 日
-        'H+': date.getHours().toString(), // 时
-        // "M+": date.getMinutes().toString(),         // 分
-        // "S+": date.getSeconds().toString()          // 秒
-        // 有其他格式化字符需求可以继续添加,必须转化成字符串
+    tarechange(e) {
+      if (this.deptBudgetList.grossWeight && this.deptBudgetList.tare) {
+        this.deptBudgetList.netWeight = Number(
+          this.deptBudgetList.grossWeight - this.deptBudgetList.tare
+        )
+      }
+    },
+    grossWeightchange(e) {
+      if (this.deptBudgetList.grossWeight && this.deptBudgetList.tare) {
+        this.deptBudgetList.netWeight = Number(
+          this.deptBudgetList.grossWeight - this.deptBudgetList.tare
+        )
       }
-      for (let k in opt) {
-        ret = new RegExp('(' + k + ')').exec(fmt)
-        if (ret) {
-          fmt = fmt.replace(
-            ret[1],
-            ret[1].length == 1 ? opt[k] : opt[k].padStart(ret[1].length, '0')
-          )
+    },
+    selectgoodsName(e) {
+      for (var i = 0; i < this.goodnameList.length; i++) {
+        if (this.goodnameList[i].constValue == e) {
+          this.deptBudgetList.goodsNameKey = this.goodnameList[i].constKey
+        }
+      }
+    },
+    selectpackingMethod(e) {
+      for (var i = 0; i < this.packtypeList.length; i++) {
+        if (this.packtypeList[i].constValue == e) {
+          this.deptBudgetList.packingMethodKey = this.packtypeList[i].constKey
+        }
+      }
+    },
+    selectstorageType(e) {
+      for (var i = 0; i < this.storageType.length; i++) {
+        if (this.storageType[i].constValue == e) {
+          this.deptBudgetList.inOutTypeKey = this.storageType[i].constKey
         }
       }
-      return fmt
     },
     handleClose() {
       this.accessoryTFs = false
@@ -411,7 +485,7 @@ export default {
       console.log(`当前页: ${val}`)
       this.getList()
     },
-     getList() {
+    getList() {
       // 货名
       pullDown({ constId: 'CON2' })
         .toPromise()
@@ -471,12 +545,7 @@ export default {
           this.historyList = response
         })
     },
-    find() {
-      this.startDate = this.dateFormat('YYYY-mm-dd', this.value2[0])
-      this.endDate = this.dateFormat('YYYY-mm-dd', this.value2[1])
-      this.currentPage = 1
-      this.getList()
-    },
+
     async exportlist() {
       const { data } = await export1(
         {
@@ -511,6 +580,49 @@ export default {
 }
 </script>
 <style lang="scss" scoped>
+/deep/.basicInformation {
+  .ws-info-table {
+    border: none;
+  }
+  .el-form-item {
+    width: 33.3333%;
+    border: none;
+    .el-form-item__label {
+      background: transparent;
+      border: none;
+    }
+    .el-form-item__content {
+      border: none;
+    }
+  }
+}
+.title {
+  position: relative;
+  padding-left: 10px;
+}
+.title::before {
+  content: '';
+  display: inline-block;
+  width: 5px;
+  height: 30px;
+  background: #5473e8;
+  position: absolute;
+  left: 0;
+}
+.el-form {
+  padding: 0 10%;
+}
+.el-button--primary {
+  background-color: #5878e8;
+  border-color: #5878e8;
+}
+.el-col {
+  background: #f6f7fc;
+}
+.bg-right {
+  text-align: right;
+  padding: 16px 20px;
+}
 .center {
   position: relative;
   top: 50px;
@@ -521,15 +633,7 @@ export default {
 /deep/.el-form-item__label {
   width: 160px;
 }
-/deep/.el-input--small {
-  width: 70%;
-}
-.container .bg-bottom {
-  position: absolute;
-  float: right;
-  top: 15px;
-  right: 20px;
-}
+
 //选填
 /deep/.el-form-item {
   width: 50%;
@@ -538,13 +642,73 @@ export default {
   overflow: scroll;
   height: 120vh;
 }
-/deep/.ws-info-table[data-v-850a44a6] .el-form-item .el-form-item__label {
+/deep/.ws-info-table .el-form-item .el-form-item__label {
   text-align: center;
 }
 .deliverydate {
-  width: 35%;
+  display: inline-block;
+  width: 10%;
 }
-.center[data-v-32a9842f] {
+.center {
   margin-top: -60px;
+    width: 80%;
+}
+//仓位
+.position{
+ width: 52px;
+height: 20px;
+background: #AFB5CB;
+border-radius: 2px;
+font-size: 12px;
+font-family: PingFangSC-Medium, PingFang SC;
+color: #FFFFFF;
+line-height: 20px;
+}
+//表格文字
+/deep/.ws-info-table .el-form-item .el-form-item__label{
+  text-align: left;
+font-size: 14px;
+font-family: PingFangSC-Regular, PingFang SC;
+font-weight: 400;
+color: #8890B1;
+line-height: 16px;
+}
+//质检员
+.inspector .el-form-item__content{
+  text-align: left;
+  margin-left: 0px;
+}
+.small-title {
+  position: relative;
+  padding: 10px;
+}
+.small-title::before {
+  position: absolute;
+  content: '';
+  display: block;
+  background: #5473e8;
+  width: 4px;
+  height: 14px;
+  left: 0px;
+  top: 13px;
+}
+//下面列表
+.neifor{
+  width: 80%;
+  background-color: #F6F7FC;
+}
+/deep/.neifor .ws-info-table .el-form-item .el-form-item__label{
+  width: 35%;
+  text-align: center;
+}
+/deep/.neifor .ws-info-table .el-form-item .el-form-item__content{
+  width: 60%;
+  background-color: #F6F7FC;
+}
+/deep/.neifor .el-input--small .el-input__inner{
+  width: 120%;
+}
+.el-input__inner{
+  width: 150px;
 }
 </style>

+ 1 - 1
vue.config.js

@@ -144,7 +144,7 @@ module.exports = {
         // target: 'http://standard-dev.winsea.com/', //目标地址
         // target: 'http://localhost:8090/',
         // target: 'http://192.168.1.124:8090/',
-        target: 'http://192.168.1.115:8090/',
+        target: 'http://192.168.1.119:8090/',
         // target: 'http://192.168.24.5:8098',//目标地址
         // target: 'http://product-server.winsea.com/',
         // target: 'http://192.168.24.5:8098',//目标地址