| | |
| | | string uplen = ""; |
| | | switch (_Warehouse.WarehouseCode) |
| | | { |
| | | "HA57" => "B", |
| | | "HA58" => "P", |
| | | "HA152" => "G", |
| | | "HA64" => "S", |
| | | "é»çä»" => "Z", |
| | | "HA153" => "Y", |
| | | "HA71" => "C", |
| | | "HA60" => "F", |
| | | _ => "N" |
| | | case "HA57": |
| | | uplen = "B"; |
| | | break; |
| | | case "HA58": |
| | | uplen = "P"; |
| | | break; |
| | | case "HA152": |
| | | uplen = "G"; |
| | | break; |
| | | case "HA64": |
| | | uplen = "S"; |
| | | break; |
| | | case "é»çä»": |
| | | uplen = "Z"; |
| | | break; |
| | | case "HA153": |
| | | uplen = "Y"; |
| | | break; |
| | | case "HA71": |
| | | uplen = "C"; |
| | | break; |
| | | case "HA60": |
| | | uplen = "F"; |
| | | break; |
| | | default: |
| | | uplen = "N"; |
| | | break; |
| | | }; |
| | | for (int i = 0; i < count; i++) |
| | | { |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | public WebResponseContent AddData(int warehouseId, int count, int palletTypeId) |
| | | { |
| | | try |
| | |
| | | [Description("æå¨ç»çå
¥åºç¡®è®¤")] |
| | | æå¨ç»çå
¥åºç¡®è®¤ = 13, |
| | | |
| | | [Description("æ£é宿")] |
| | | æ£é宿 =14, |
| | | |
| | | [Description("ç»çæ¤é")] |
| | | ç»çæ¤é = 99, |
| | | |
| | |
| | | public interface IOutboundOrderDetailService : IService<Dt_OutboundOrderDetail> |
| | | { |
| | | IOutboundOrderDetailRepository Repository { get; } |
| | | |
| | | WebResponseContent GetOutboundOrderDetails(SaveModel saveModel); |
| | | /// <summary> |
| | | /// éå®åºåºåºå |
| | | /// </summary> |
| | |
| | | { |
| | | IOutboundOrderRepository Repository { get; } |
| | | |
| | | WebResponseContent GetOutboundOrders(SaveModel saveModel); |
| | | WebResponseContent ReceiveOutOrder(ErpOutOrderDTO model); |
| | | WebResponseContent TestOutUpload(int id,List<Dt_OutStockLockInfo>? outStockLockInfos=null); |
| | | } |
| | |
| | | _basicService = basicService; |
| | | _recordService = recordService; |
| | | } |
| | | |
| | | public WebResponseContent GetOutboundOrderDetails(SaveModel saveModel) |
| | | { |
| | | WebResponseContent content = new WebResponseContent(); |
| | | try |
| | | { |
| | | string orderNo = saveModel.MainData["orderNo"].ToString(); |
| | | Dt_OutboundOrder inboundOrder = Db.Queryable<Dt_OutboundOrder>().Where(x => x.OrderNo == orderNo).Includes(x => x.Details).First(); |
| | | content.OK(data: inboundOrder.Details); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | content.Error(ex.Message); |
| | | } |
| | | return content; |
| | | } |
| | | /// <summary> |
| | | /// éå®åºåï¼ç±ç³»ç»åé
(ä»
é»è¾è¿ç®ï¼ä¸çæä»»å¡ï¼ä¸ä¿®æ¹æ°æ®åºæ°æ®) |
| | | /// </summary> |
| | |
| | | saveModel.DetailData[0].Add("orderDetailStatus", OrderDetailStatusEnum.New.ObjToInt()); |
| | | return base.AddData(saveModel); |
| | | } |
| | | public WebResponseContent GetOutboundOrders(SaveModel saveModel) |
| | | { |
| | | WebResponseContent content = new WebResponseContent(); |
| | | try |
| | | { |
| | | int pageNo = saveModel.MainData["pageNo"].ObjToInt(); |
| | | string? orderNo = saveModel.MainData["orderNo"].ToString(); |
| | | int warehouseId = saveModel.MainData["warehouseId"].ObjToInt(); |
| | | List<Dt_OutboundOrder> dt_ReceiveOrders = new List<Dt_OutboundOrder>(); |
| | | if (string.IsNullOrEmpty(orderNo)) |
| | | { |
| | | dt_ReceiveOrders = Db.Queryable<Dt_OutboundOrder>().Where(x => x.OrderStatus < OutLockStockStatusEnum.åºåºå®æ.ObjToInt() && x.WarehouseId == warehouseId).ToPageList(pageNo, 5); |
| | | } |
| | | else |
| | | { |
| | | dt_ReceiveOrders = Db.Queryable<Dt_OutboundOrder>().Where(x => (x.OrderNo.Contains(orderNo)) && x.OrderStatus < OutLockStockStatusEnum.åºåºå®æ.ObjToInt() && x.WarehouseId == warehouseId).ToPageList(pageNo, 5); |
| | | } |
| | | |
| | | content.OK(data: dt_ReceiveOrders); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | content.Error(ex.Message); |
| | | } |
| | | return content; |
| | | } |
| | | public WebResponseContent ReceiveOutOrder(ErpOutOrderDTO model) |
| | | { |
| | | try |
| | |
| | | using MailKit.Search; |
| | | using OrderByType = SqlSugar.OrderByType; |
| | | using System.Drawing.Printing; |
| | | using WIDESEA_Core.HostedService; |
| | | |
| | | namespace WIDESEA_SystemService |
| | | { |
| | |
| | | { |
| | | return Service.TestOutUpload(id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååºåºå |
| | | /// </summary> |
| | | /// <param name="saveModel"></param> |
| | | /// <returns></returns> |
| | | [HttpPost, Route("GetOutboundOrders"), AllowAnonymous] |
| | | public WebResponseContent GetOutboundOrders([FromBody]SaveModel saveModel) |
| | | { |
| | | return Service.GetOutboundOrders(saveModel); |
| | | } |
| | | } |
| | | } |
| | |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Authorization; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | using WIDESEA_Core; |
| | | using WIDESEA_Core.BaseController; |
| | |
| | | public OutboundOrderDetailController(IOutboundOrderDetailService service) : base(service) |
| | | { |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååºåºå详æ
|
| | | /// </summary> |
| | | /// <param name="saveModel"></param> |
| | | /// <returns></returns> |
| | | [HttpPost, Route("GetOutboundOrderDetails"), AllowAnonymous] |
| | | public WebResponseContent GetOutboundOrderDetails([FromBody] SaveModel saveModel) |
| | | { |
| | | return Service.GetOutboundOrderDetails(saveModel); |
| | | } |
| | | } |
| | | } |
| | |
| | | }) |
| | | return; |
| | | } |
| | | this.$u.post('http://127.0.0.1:9291/api/CTU_AGV/AGVFinish?&barcode=' + this.barcode).then( |
| | | this.$u.post('http://10.30.4.92:9291/api/CTU_AGV/AGVFinish?barcode=' + this.barcode).then( |
| | | res => { |
| | | if (res.status) { |
| | | this.$refs.uToast.show({ |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <view> |
| | | <u-sticky> |
| | | <view style="background-color: #ffffff;"> |
| | | <uni-search-bar @confirm="search" v-model="searchValue"></uni-search-bar> |
| | | </view> |
| | | </u-sticky> |
| | | <uni-list :border="true"> |
| | | <uni-list-item direction="column" clickable @click="groupClick(item.orderNo)" link |
| | | :to="page+item.orderNo" v-for="item in allReceivingOrders" :key="item.orderNo"> |
| | | <template v-slot:body> |
| | | <uni-group margin-top="20"> |
| | | <view> åå·:{{item.orderNo}} </view> |
| | | <view> å建人:{{item.creater}} </view> |
| | | <view> æ¥æ:{{item.createDate}} </view> |
| | | </uni-group> |
| | | </template> |
| | | </uni-list-item> |
| | | |
| | | </uni-list> |
| | | <uni-load-more :status="status" v-if="loadVisible"></uni-load-more> |
| | | |
| | | <u-back-top :scroll-top="scrollTop" top="400"></u-back-top> |
| | | </view> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data() { |
| | | return { |
| | | page: "/pages/stash/outraworderboxing?", |
| | | loadVisible: false, |
| | | searchValue: "", |
| | | status: "more", |
| | | allReceivingOrders: [], |
| | | pageNo: 1, |
| | | scrollTop: 0, |
| | | warehouseId: "" |
| | | } |
| | | }, |
| | | onLoad(res) { |
| | | this.warehouseId = res.warehouseId; |
| | | this.page = this.page + "warehouseId=" + this.warehouseId + "&orderNo="; |
| | | this.getData(); |
| | | }, |
| | | onReachBottom() { |
| | | this.pageNo += 1; |
| | | this.getData(); |
| | | }, |
| | | onPageScroll(e) { |
| | | this.scrollTop = e.scrollTop; |
| | | }, |
| | | methods: { |
| | | search(res) { |
| | | this.getData(); |
| | | }, |
| | | groupClick() { |
| | | |
| | | }, |
| | | getData() { |
| | | var postData = { |
| | | MainData: { |
| | | warehouseId: this.warehouseId, |
| | | orderNo: this.searchValue, |
| | | pageNo: this.pageNo |
| | | }, |
| | | } |
| | | this.$u.post('/api/OutboundOrder/GetOutboundOrders', postData).then((res) => { |
| | | if (res.status) { |
| | | if (res.data.length > 0) { |
| | | if (this.searchValue == '') { |
| | | this.allReceivingOrders = this.allReceivingOrders.concat(res.data); |
| | | // this.allReceivingOrders = res.data; |
| | | if (this.allReceivingOrders.length > 3) { |
| | | this.loadVisible = true; |
| | | } else { |
| | | this.loadVisible = false; |
| | | } |
| | | } else { |
| | | this.allReceivingOrders = res.data; |
| | | if (this.allReceivingOrders.length > 3) { |
| | | this.loadVisible = true; |
| | | } else { |
| | | this.loadVisible = false; |
| | | } |
| | | } |
| | | } else { |
| | | this.status = 'noMore'; |
| | | //this.allReceivingOrders = []; |
| | | this.loadVisible = true; |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="scss"> |
| | | @import '@/common/uni-ui.scss'; |
| | | |
| | | page { |
| | | display: flex; |
| | | flex-direction: column; |
| | | box-sizing: border-box; |
| | | background-color: #efeff4; |
| | | min-height: 100%; |
| | | height: auto; |
| | | } |
| | | |
| | | .tips { |
| | | color: #67c23a; |
| | | font-size: 14px; |
| | | line-height: 40px; |
| | | text-align: center; |
| | | background-color: #f0f9eb; |
| | | height: 0; |
| | | opacity: 0; |
| | | transform: translateY(-100%); |
| | | transition: all 0.3s; |
| | | } |
| | | |
| | | .tips-ani { |
| | | transform: translateY(0); |
| | | height: 40px; |
| | | opacity: 1; |
| | | } |
| | | |
| | | .content { |
| | | width: 100%; |
| | | display: flex; |
| | | } |
| | | |
| | | .list-picture { |
| | | width: 100%; |
| | | height: 145px; |
| | | } |
| | | |
| | | .thumb-image { |
| | | width: 100%; |
| | | height: 100%; |
| | | } |
| | | |
| | | .ellipsis { |
| | | display: flex; |
| | | overflow: hidden; |
| | | } |
| | | |
| | | .uni-ellipsis-1 { |
| | | overflow: hidden; |
| | | white-space: nowrap; |
| | | text-overflow: ellipsis; |
| | | } |
| | | |
| | | .uni-ellipsis-2 { |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | display: -webkit-box; |
| | | -webkit-line-clamp: 2; |
| | | -webkit-box-orient: vertical; |
| | | } |
| | | |
| | | .customcss { |
| | | display: flex; |
| | | position: fixed; |
| | | width: 100%; |
| | | top: 10px; |
| | | text-align: center; |
| | | z-index: 999; |
| | | left: 30px; |
| | | height: 20%; |
| | | } |
| | | |
| | | .footer { |
| | | padding-top: 50%; |
| | | } |
| | | </style> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <view> |
| | | <uni-segmented-control :current="current" :values="items" @clickItem="onClickItem"> |
| | | </uni-segmented-control> |
| | | <view class="content"> |
| | | <view v-if="current === 0" class="headerstyle"> |
| | | <view class="itemstyle"> |
| | | <uni-forms style="margin-left: 2%;margin-top: 20px;" label-width="180"> |
| | | <uni-forms-item :label="label" style="margin-top: -20px;"></uni-forms-item> |
| | | <!-- <uni-forms-item label="åæ®ç±»åï¼çäº§é¢æå" style="margin-top: -20px;"></uni-forms-item> --> |
| | | <uni-forms-item label="ç©æç ï¼" style="margin-top: -20px;"> |
| | | <uni-easyinput type="text" placeholder="è¯·æ«æç©æç " ref='midInput' :focus="focus" |
| | | v-model="innerCode" @input="snInput" /> |
| | | </uni-forms-item> |
| | | <!-- <uni-forms-item :label="PurchaseOrderNo" style="margin-top: -20px;"></uni-forms-item> |
| | | <uni-forms-item :label="matCode" style="margin-top: -20px;"></uni-forms-item> |
| | | <uni-forms-item :label="LotNo" style="margin-top: -20px;"></uni-forms-item> |
| | | <uni-forms-item :label="ProductionDate" style="margin-top: -20px;"></uni-forms-item> |
| | | <uni-forms-item :label="EffectiveDate" style="margin-top: -20px;"></uni-forms-item> |
| | | <uni-forms-item :label="orderQty" style="margin-top: -20px;"></uni-forms-item> |
| | | <uni-forms-item :label="remaindQty" style="margin-top: -20px;"> --> |
| | | <uni-list> |
| | | <uni-list-item direction="column" v-for="item in matInfos" :key="item.palletCode"> |
| | | <template v-slot:body> |
| | | <view class="uni-content"> |
| | | <view>åæ®ç¼å·ï¼{{item.orderNo}}</view> |
| | | <view>æçç¼å·ï¼{{item.palletCode}}</view> |
| | | <view>ç©ææ¹æ¬¡ï¼{{item.batchNo}}</view> |
| | | <view>ç©æç¼ç ï¼{{item.materielCode}}</view> |
| | | <view>ç©æåç§°ï¼{{item.materielName}}</view> |
| | | <view>åæ®æ°éï¼{{item.orderQuantity}}</view> |
| | | <view>åå§åºåï¼{{item.originalQuantity}}</view> |
| | | <view>åé
åºåï¼{{item.assignQuantity}}</view> |
| | | <view>å©ä½åºåï¼{{item.originalQuantity-item.assignQuantity}}</view> |
| | | </view> |
| | | </template> |
| | | </uni-list-item> |
| | | </uni-list> |
| | | <uni-forms-item label="åºåºæ°éï¼" style="margin-top: -20px;"> |
| | | <uni-easyinput type="text" placeholder="请è¾å
¥åºåºæ°é" ref='midInput' :focus="focus" |
| | | v-model="outQty" /> |
| | | </uni-forms-item> |
| | | </uni-forms-item> |
| | | </uni-forms> |
| | | <uni-forms-item> |
| | | <button @click="submit" type="primary" size="default" style="margin-top: 2%;">确认åºåº</button> |
| | | </uni-forms-item> |
| | | </view> |
| | | </view> |
| | | <view v-if="current === 1" class="headerstyle"> |
| | | <view class="itemstyle"> |
| | | <uni-list :border="true"> |
| | | <uni-list-item direction="column" v-for="(item,index) in orderInfo" :key="index"> |
| | | <template v-slot:body> |
| | | <view class="uni-list-box"> |
| | | <view class="uni-content"> |
| | | <view>åæ®å·ï¼{{orderNo}}</view> |
| | | <view>ç©æç¼ç ï¼{{item.materielCode}}</view> |
| | | <view>ç©æåç§°ï¼{{item.materielName}}</view> |
| | | <view>æ°éï¼{{item.orderQuantity+item.unit}}</view> |
| | | <view>åºåºæ°éï¼{{item.orderQuantity}}</view> |
| | | <view>å·²åºæ°éï¼{{item.overOutQuantity}}</view> |
| | | </view> |
| | | </view> |
| | | </template> |
| | | </uni-list-item> |
| | | </uni-list> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <u-toast ref="uToast" /> |
| | | </view> |
| | | </template> |
| | | |
| | | <script> |
| | | const innerAudioContext = uni.createInnerAudioContext(); |
| | | export default { |
| | | data() { |
| | | return { |
| | | items: ['ç©æä¿¡æ¯', 'åæ®ä¿¡æ¯'], |
| | | current: 0, |
| | | matTotal: [], |
| | | matInfos: [], |
| | | orderNo: "", |
| | | label: "", |
| | | outQty: "", |
| | | orderInfo: [], |
| | | focus: false, |
| | | pkfocus: false, |
| | | barcode: "", |
| | | materSn: "", |
| | | Initiallife: 1000, |
| | | sns: [], |
| | | pksns: [], |
| | | addressFocus: false, |
| | | inboundBarcode: "", |
| | | address: "", |
| | | check: true, |
| | | value: "", |
| | | matInfo: [], |
| | | value2: "", |
| | | matTotals: [], |
| | | warehouseId: "", |
| | | Test: false, |
| | | Testlabel: "", |
| | | Testplaceholder: "", |
| | | Testcheck: false, |
| | | pkmaterSn: "", |
| | | pkmatInfos: [] |
| | | } |
| | | }, |
| | | onShow() {}, |
| | | onLoad(res) { |
| | | this.focus = false; |
| | | this.addressFocus = false; |
| | | this.orderNo = res.orderNo; |
| | | this.warehouseId = res.warehouseId; |
| | | this.label = "åæ®ç¼å·ï¼" + this.orderNo; |
| | | this.getData(); |
| | | }, |
| | | methods: { |
| | | voiceSpeech(src) { |
| | | innerAudioContext.src = src; // '../../static/success.mp3'; |
| | | innerAudioContext.play(); |
| | | }, |
| | | getData() { |
| | | var postData = { |
| | | MainData: { |
| | | orderNo: this.orderNo |
| | | }, |
| | | } |
| | | this.$u.post('/api/OutboundOrderDetail/GetOutboundOrderDetails', postData).then((res) => { |
| | | if (res.status) { |
| | | this.orderInfo = res.data; |
| | | if (this.orderInfo.length > 3) { |
| | | this.loadVisible = true; |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | onClickItem(e) { |
| | | this.focus = false; |
| | | this.addressFocus = false; |
| | | if (this.current !== e.currentIndex) { |
| | | this.current = e.currentIndex; |
| | | if (this.current == 2) { |
| | | this.getData(); |
| | | } |
| | | } |
| | | }, |
| | | //æ«ç |
| | | snInput() { |
| | | this.$nextTick(() => { |
| | | if (this.materSn != "") { |
| | | this.focus = false; |
| | | var matSn = this.materSn; |
| | | setTimeout(() => { |
| | | this.materSn = ""; |
| | | }, 10); |
| | | this.$u.post('/api/MaterielInfo/CodeAnalysis?serNum=' + matSn, {}).then((res) => { |
| | | this.Testcheck = false; |
| | | if (res.status) { |
| | | this.sns.push(res.data.serialNumber); |
| | | |
| | | this.matInfos.push(res.data); |
| | | if (res.message) { |
| | | this.$refs.uToast.show({ |
| | | title: res.message, |
| | | type: "error" |
| | | }) |
| | | setTimeout(() => { |
| | | this.voiceSpeech('../../static/fail.mp3'); |
| | | }, 100); |
| | | return; |
| | | } |
| | | setTimeout(() => { |
| | | this.voiceSpeech('../../static/success.mp3'); |
| | | }, 100); |
| | | } else { |
| | | this.$refs.uToast.show({ |
| | | title: res.message, |
| | | type: "error" |
| | | }) |
| | | setTimeout(() => { |
| | | this.voiceSpeech('../../static/fail.mp3'); |
| | | }, 100); |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | deleteList(res) { |
| | | this.matInfos.splice(res, 1); |
| | | this.sns.splice(res, 1); |
| | | }, |
| | | submit() { |
| | | if (this.barcode == "") { |
| | | this.$refs.uToast.show({ |
| | | title: "è¯·æ«ææçæ¡ç ", |
| | | type: 'error' |
| | | }) |
| | | return; |
| | | } |
| | | if (this.matInfos.length == 0) { |
| | | this.$refs.uToast.show({ |
| | | title: "è¯·æ«æå
ç®±æ ç¾", |
| | | type: 'error' |
| | | }) |
| | | return; |
| | | } |
| | | if (this.Test) { |
| | | if (!this.Testcheck) { |
| | | this.Testcheck = true; |
| | | this.$refs.uToast.show({ |
| | | title: "请确认åå§å¯¿å½", |
| | | type: 'error' |
| | | }) |
| | | return; |
| | | } |
| | | } |
| | | this.$u.post('/api/InboundOrder/MaterielGroup', { |
| | | MainData: { |
| | | "palletCode": this.barcode, |
| | | "orderNo": this.orderNo, |
| | | "initiallife": this.Initiallife, |
| | | // "isFull": this.check |
| | | "warehouseId": this.warehouseId |
| | | }, |
| | | DelKeys: this.sns |
| | | }).then(res => { |
| | | this.Testcheck = false; |
| | | if (res.status) { |
| | | this.$refs.uToast.show({ |
| | | title: "åºåºæå", |
| | | type: "success" |
| | | }) |
| | | this.focus = false; |
| | | this.barcode = ""; |
| | | this.matInfos = []; |
| | | this.sns = []; |
| | | this.matTotal = []; |
| | | } else { |
| | | this.$refs.uToast.show({ |
| | | title: res.message, |
| | | type: "error" |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="scss"> |
| | | @import '@/common/uni-ui.scss'; |
| | | |
| | | .content { |
| | | display: flex; |
| | | height: 150px; |
| | | } |
| | | |
| | | .content-text { |
| | | font-size: 14px; |
| | | color: #666; |
| | | } |
| | | |
| | | .itemstyle { |
| | | margin-top: 30px; |
| | | margin-left: 5%; |
| | | } |
| | | |
| | | .headerstyle { |
| | | width: 90%; |
| | | } |
| | | </style> |