Browse Source

修改零件号查询

hella_online_20240911
lijuncheng 1 week ago
parent
commit
0956aee5cc
  1. 3
      .gitignore
  2. 4
      src/api/request2.js
  3. 46
      src/pages/query/coms/comItemDetailCard.vue
  4. 12
      src/pages/query/coms/comLocationDetailCard.vue
  5. 31
      src/pages/query/item.vue
  6. 4
      src/pages/query/location.vue

3
.gitignore

@ -18,4 +18,5 @@ dist
*.ntvs*
*.njsproj
*.sln
*.sw?
*.sw?
/.env.development

4
src/api/request2.js

@ -273,11 +273,11 @@ export function getExpectoutByItemcode(params) {
}
/**
* 按库位查询库存事务
* 查询库存事务
* @param {*}
*
*/
export function getTransactionByLocationcode(params) {
export function getTransaction(params) {
return request({
url: baseApi + "/wms/transaction/senior",
method: "post",

46
src/pages/query/coms/comItemDetailCard.vue

@ -7,15 +7,21 @@
<pack v-if=" dataContent.packingNumber" :packingCode="dataContent.packingNumber"></pack>
<batch v-if="isShowBatch && dataContent.batch" :batch="dataContent.batch"></batch>
<location :locationCode="dataContent.locationCode"></location>
<view class="" v-if="dataContent.warehouseCode"
style="font-size: 32rpx; margin-left: 15rpx ; padding-bottom: 10rpx; font-weight: bold;">
<text style="">仓库</text>
{{dataContent.warehouseCode}}
</view>
<view class="" v-if="dataContent.jobNumber"
style="font-size: 30rpx; padding-left: 10rpx ; padding-bottom: 10rpx;">
style="font-size: 32rpx; padding-left: 10rpx ; padding-bottom: 10rpx;">
<text style="color: coral; ">任务号</text>
{{dataContent.jobNumber}}
</view>
<view class="" v-if="dataContent.businessType"
style="font-size: 30rpx; padding-left: 10rpx ; padding-bottom: 10rpx;">
<text style="color:green; ">业务类型</text>
{{businessTypeDesc(dataContent.businessType)}}
style="font-size: 32rpx; padding-left: 10rpx ; padding-bottom: 10rpx;">
<text style="color:green; ">业务类型 </text>
<text v-if="hasChinese(dataContent.businessType)">{{dataContent.businessType}}</text>
<text v-else> {{businessTypeDesc(dataContent.businessType)}}</text>
</view>
</view>
<view class="uni-flex" style="flex-direction: column;">
@ -26,6 +32,24 @@
</view>
</view>
<view v-if="dataContent.transactionType" class="" style="margin-left: 10rpx; font-size: 32rpx;">
事务类型{{dataContent.transactionType}}
</view>
<view v-if="dataContent.inventoryAction" class="" style="margin-left: 10rpx; font-size: 32rpx;">
库存动作{{inventoryActionName(dataContent.inventoryAction)}}
</view>
<view v-if="dataContent.recordNumber" class="" style="margin-left: 10rpx; font-size: 32rpx;">
业务记录号{{dataContent.recordNumber}}
</view>
<view v-if="dataContent.number" class="" style="margin-left: 10rpx; font-size: 32rpx;">
事务号{{dataContent.number}}
</view>
<view v-if="dataContent.worker" class="" style="margin-left: 10rpx; font-size: 32rpx;">
操作人{{dataContent.worker}}
</view>
<view class="" style="margin-left: 10rpx; font-size: 32rpx;">
创建时间{{dateFormat(dataContent.createTime)}}
</view>
@ -44,6 +68,9 @@
import {
getBusinessTypeName,
} from '@/common/directory.js';
import {
dateFormat
} from '@/common/basic.js';
export default {
components: {
itemQty,
@ -88,6 +115,17 @@
businessTypeDesc(type){
return getBusinessTypeName(type)
},
dateFormat(times){
return dateFormat(times)
},
hasChinese(str){
var reg = /[\u4e00-\u9fa5]/g;
return reg.test(str);
},
inventoryActionName(value){
return value=="IN"?"入库":"出库"
}
}
}

12
src/pages/query/coms/comLocationDetailCard.vue

@ -31,22 +31,22 @@
</view>
</view>
<view v-if="dataContent.transactionType" class="" style="margin-left: 10rpx; font-size: 30rpx;">
<view v-if="dataContent.transactionType" class="" style="margin-left: 10rpx; font-size: 32rpx;">
事务类型{{dataContent.transactionType}}
</view>
<view v-if="dataContent.inventoryAction" class="" style="margin-left: 10rpx; font-size: 30rpx;">
<view v-if="dataContent.inventoryAction" class="" style="margin-left: 10rpx; font-size: 32rpx;">
库存动作{{inventoryActionName(dataContent.inventoryAction)}}
</view>
<view v-if="dataContent.recordNumber" class="" style="margin-left: 10rpx; font-size: 30rpx;">
<view v-if="dataContent.recordNumber" class="" style="margin-left: 10rpx; font-size: 32rpx;">
业务记录号{{dataContent.recordNumber}}
</view>
<view v-if="dataContent.number" class="" style="margin-left: 10rpx; font-size: 30rpx;">
<view v-if="dataContent.number" class="" style="margin-left: 10rpx; font-size: 32rpx;">
事务号{{dataContent.number}}
</view>
<view v-if="dataContent.worker" class="" style="margin-left: 10rpx; font-size: 30rpx;">
<view v-if="dataContent.worker" class="" style="margin-left: 10rpx; font-size: 32rpx;">
操作人{{dataContent.worker}}
</view>
<view class="" style="margin-left: 10rpx; font-size: 30rpx;">
<view class="" style="margin-left: 10rpx; font-size: 32rpx;">
创建时间{{dateFormat(dataContent.createTime)}}
</view>

31
src/pages/query/item.vue

@ -39,7 +39,7 @@
getExpectinByItemcode,
getBalanceByItemCode,
getBasicItemByCode,
getBalanceSummary
getTransaction
} from '@/api/request2.js';
import {
goHome
@ -51,7 +51,7 @@
import comItemDetailCard from '@/pages/query/coms/comItemDetailCard.vue'
import itemFilter from '@/mycomponents/item/itemFilter.vue'
import comEmptyView from '@/mycomponents/common/comEmptyView.vue'
import { nextTick } from 'vue';
import { nextTick } from 'vue';
export default {
components: {
@ -67,7 +67,7 @@ import { nextTick } from 'vue';
return {
//v-model
dataList: [],
tabList: ['汇总', '明细', '预计入', '预计出'],
tabList: ['库存余额', '预计入', '预计出', '库存事务'],
tabIndex: 0,
itemDetail: undefined,
itemCode: '',
@ -154,7 +154,7 @@ import { nextTick } from 'vue';
},
//
getSummary(pageNo, pageSize, type) {
getBalanceItem(pageNo, pageSize, type) {
uni.showLoading({
title: "加载中...",
mask: true
@ -190,7 +190,9 @@ import { nextTick } from 'vue';
var params = {
filters: filters,
pageNo: this.pageNo,
pageSize: pageSize
pageSize: pageSize,
sort:"createTime",
by: "ASC"
}
getBalanceByItemCode(params).then(res => {
uni.hideLoading();
@ -205,9 +207,6 @@ import { nextTick } from 'vue';
this.loadingType = "nomore";
return;
}
list.forEach(item=>{
item.packingNumber=""
})
this.dataList = type === "refresh" ? list : this.dataList.concat(list);
this.pageNo++;
@ -218,7 +217,7 @@ import { nextTick } from 'vue';
})
},
//
getDetailList(pageNo, pageSize, type) {
getTransactionByItemCode(pageNo, pageSize, type) {
uni.showLoading({
title: "加载中...",
mask: true
@ -254,9 +253,11 @@ import { nextTick } from 'vue';
var params = {
filters: filters,
pageNo: this.pageNo,
pageSize: pageSize
pageSize: pageSize,
sort:"createTime",
by: "DESC"
}
getBalanceByItemCode(params).then(res => {
getTransaction(params).then(res => {
uni.hideLoading();
if (type === "refresh") {
@ -280,12 +281,12 @@ import { nextTick } from 'vue';
},
getContentByTab(index, pageNo, pageSize, type) {
if (index === 0) this.getSummary(pageNo, pageSize, type);
else if (index === 1) this.getDetailList(pageNo, pageSize, type);
if (index === 0) this.getBalanceItem(pageNo, pageSize, type);
else if (index === 1) this.getExpectin(pageNo, pageSize, type);
else if (index === 2) {
this.getExpectin(pageNo, pageSize, type);
} else if (index == 3) {
this.getExpectout(pageNo, pageSize, type);
} else if (index == 3) {
this.getTransactionByItemCode(pageNo, pageSize, type);
}
},
//

4
src/pages/query/location.vue

@ -36,7 +36,7 @@
<script>
import {
getBalanceByLocationcode,
getTransactionByLocationcode,
getTransaction,
getExpectInByLocationCode,
getExpectOutByLocationCode
} from '@/api/request2.js';
@ -206,7 +206,7 @@
sort:"createTime",
by: "DESC"
}
getTransactionByLocationcode(params).then(res => {
getTransaction(params).then(res => {
uni.hideLoading();
if (type === "refresh") {
uni.stopPullDownRefresh();

Loading…
Cancel
Save