Mr.Zhang
2023-08-28 78db0230942f69ffb1eeaaca8afd7f849942df97
minipro_standard/pages/index/index.vue
@@ -46,9 +46,18 @@
      <u-popup :show="show" @close="close" :round="8" zIndex="20000">
         <view class="rp p40 contanir">
            <view class="c2 b">类型</view>
            <view class="content">
               <u-grid col="2" :border="false">
                  <u-grid-item v-for="item in types" :key="item.id">
                     <view class="ptb20 c9 type-style tc rd10"
                        :class="searchForm.type===item.id?'sbtn_green':'sbtn_gray'"
                        @click="searchForm.type=item.id">{{ item.name }}</view>
                  </u-grid-item>
               </u-grid>
            </view>
            <view class="flex ap tc bottom-view">
               <view class="fx1 ptb20 sbtn_gray c9">重置</view>
               <view class="fx1 ml20 ptb20 sbtn_green">确定</view>
               <view class="fx1 ptb20 sbtn_gray c9" @click="resetType">重置</view>
               <view class="fx1 ml20 ptb20 sbtn_green" @click="confirm">确定</view>
            </view>
         </view>
      </u-popup>
@@ -109,7 +118,8 @@
            ],
            searchForm: {
               name: '',
               status: 0
               status: 0,
               type: ''
            },
            projectList: [{
                  title: '212132',
@@ -150,7 +160,6 @@
            success: function(loginRes) {
               // console.log(loginRes);
               that.code = loginRes.code
               that.show = true
            }
         });
      },
@@ -165,12 +174,115 @@
            this.searchForm.status = status
            this.scrolltoupper()
         },
         selectProject(item) {},
         jump(item) {
            if ((item.type === 0 || item.type === 2 || item.type === 5) && item.status === 0) { // 跳转出库(转库单)
               router.push({
                  name: 'issueOperation',
                  query: {
                     id: item.objId,
                     dbid: item.id,
                     type: 7
                  }
               })
            } else if ((item.type === 0 || item.type === 2 || item.type === 5) && item.status === 1) {
               router.push({
                  name: 'wTransferDetail',
                  query: {
                     id: item.objId,
                     status: item.status,
                     type: item.type,
                     dbid: item.id
                  }
               })
               // router.push({ name: 'wTransferDetail', query: { id: item.objId, status: 0, type: item.type, dbid: item.id } })
            } else if ((item.type === 1 || item.type === 4 || item.type === 6) && item.status === 0) { // 跳转入库(转库单)
               if (item.type === 4) { // 跳转完工入库详情
                  router.push({
                     name: 'completionDetails',
                     query: {
                        id: item.objId,
                        dbid: item.id,
                        type: 7,
                        isShow: 1,
                        Type: item.type
                     }
                  })
                  return
               }
               router.push({
                  name: 'warehousing',
                  query: {
                     id: item.objId,
                     dbid: item.id,
                     type: 7
                  }
               })
            } else if ((item.type === 1 || item.type === 4 || item.type === 6) && item.status === 1) {
               if (item.type === 4) { // 跳蛛完工入库详情
                  router.push({
                     name: 'completionDetails',
                     query: {
                        id: item.objId,
                        dbid: item.id,
                        type: 7,
                        isShow: 2
                     }
                  })
                  return
               }
               router.push({
                  name: 'wTransferDetail',
                  query: {
                     id: item.objId
                  }
               })
            } else if (item.type === 3 && item.status === 0) { // 确认备料
               router.push({
                  name: 'orderStock',
                  query: {
                     id: item.objId,
                     dbid: item.id
                  }
               })
            } else if (item.type === 3 && item.status === 1) { // 备料(转库单详情)
               // router.push({ name: 'wInboundDetail', query: { id: item.objId } })
               router.push({
                  name: 'wTransferDetail',
                  query: {
                     id: item.objId
                  }
               })
            } else if (item.type === 9 && item.status === 0) { // 调整入库(入库单)
               router.push({
                  name: 'warehousing',
                  query: {
                     id: item.objId,
                     dbid: item.id,
                     type: 9
                  }
               })
            } else if (item.type === 9 && item.status === 1) {
               router.push({
                  name: 'wInboundDetail',
                  query: {
                     id: item.objId
                  }
               })
            }
         },
         filterAction() {
            this.show = true
         },
         close() {
            this.show = false
         },
         resetType() {
            this.searchForm.type = ''
            this.confirm()
         },
         confirm() {
            this.show = false
            this.scrolltoupper()
         }
      }
   }
@@ -272,12 +384,23 @@
         }
      }
   }
   .contanir {
      min-height: calc(env(safe-area-inset-bottom) + 120rpx);
      height: calc(env(safe-area-inset-bottom) + 720rpx);
      .content {
         margin-top: 20rpx;
         .type-style {
            width: 325rpx;
            margin-bottom: 20rpx;
   }
      }
   }
   .bottom-view {
      left: 40rpx;
      right: 40rpx;
      bottom: env(safe-area-inset-bottom);
      bottom: 0
   }
</style>