库存回传
入库扫描逻辑
添加物料二维码和唯一码对应表
This commit is contained in:
zgf 2023-11-09 17:17:05 +08:00
parent f9bf7be066
commit da78422528
19 changed files with 1684 additions and 115 deletions

View File

@ -6,6 +6,7 @@ using AutoMapper;
using HHWMS.Web.Models;
using Microsoft.AspNetCore.Mvc;
using Microsoft.EntityFrameworkCore;
using Newtonsoft.Json;
using WalkingTec.Mvvm.Core;
namespace HHWMS.Web
@ -36,6 +37,27 @@ namespace HHWMS.Web
[HttpPost]
public IActionResult RequestIn(WcsRequest request)
{
var inv = _unitwork.Find<Inventory>(x => x.ID > 0).FirstOrDefault();
var bizData = new InStore
{
INWMS = new INWMS
{
INITEMS = new INITEMS
{
INITEM = new List<INITEMItem>()
{
new INITEMItem()
{
ERPSN = inv.MaterialCode,
WMSSN = inv.UniqueCode,
QTY = ((int?)inv.Qty).ToString(),
TYPE = "2"
}
}
}
}
};
var str = JsonConvert.SerializeObject(bizData);
// 参数判断
if (request.RoadWay == null || request.Size == null)
{

View File

@ -1,3 +1,4 @@
using System;
using System.Collections.Generic;
using System.Linq;
using HHWMS.Web.Models;
@ -45,7 +46,7 @@ namespace HHWMS.Web.Controllers
}
[HttpPost]
public ActionResult GenCode(string code)
public ActionResult GenCode(string code, int num = 1)
{
var material = _unitwork.FindSingle<Material>(x => x.QRCode.Equals(code));
if (material == null)
@ -54,20 +55,23 @@ namespace HHWMS.Web.Controllers
}
else
{
if (string.IsNullOrEmpty(material.UniqueCode))
var materialQrList = new List<MaterialQr>();
for (int i = 0; i < num; i++)
{
var prefix = code.Split("@")[1].Substring(2);
var unique = _unitwork.GetSerialNumber(prefix, 8);
var uniqueCode = prefix + unique;
var uniqueCode = _unitwork.GetSerialNumber(prefix, length: 8);
//var uniqueCode = prefix + unique;
material.UniqueCode = uniqueCode;
_unitwork.Update(material);
return JsonMore(uniqueCode);
}
else
{
return JsonMore(material.UniqueCode);
materialQrList.Add(new MaterialQr
{
QRCode = code,
UniqueCode = uniqueCode,
CreateTime = DateTime.Now,
CreateBy = Wtm.LoginUserInfo.ITCode
});
}
_unitwork.BatchAdd(materialQrList.ToArray());
return JsonMore(materialQrList);
}
}
}

View File

@ -32,7 +32,7 @@ namespace HHWMS.Web
protected override IEnumerable<IGridColumn<Material_View>> InitGridHeader()
{
return new List<GridColumn<Material_View>>{
this.MakeGridHeader(x => x.UniqueCode).SetWidth(220),
this.MakeGridHeader(x => x.UniqueCode).SetHide(),
this.MakeGridHeader(x => x.QRCode),
this.MakeGridHeader(x => x.SourceCode).SetHide(),
this.MakeGridHeader(x => x.MaterialCode),

View File

@ -1,12 +1,17 @@
<el-row id="print">
<el-row>
<el-col :span="16">
<el-col :span="12">
<el-input v-model="qrcode"
placeholder="请扫描二维码"
@@change="scanCode" ref="QrCode">
</el-input>
</el-col>
<el-col :span="8">
<el-input v-model.number="num"
placeholder="请输入数量">
</el-input>
</el-col>
<el-col :span="4">
<el-button type="primary" @@click="genCode">生成</el-button>
</el-col>
</el-row>
@ -28,6 +33,7 @@
printData:[],
gendCode: '',
qrcode: '',
num: 1,
template: {
"panels": [
{
@ -80,38 +86,6 @@
duration: "10000",
});
}
else{
$.ajax({
type: "post",
dataType: "json",
data: { code: _this.qrcode },
url: "/configs/Print/GenCode",
success: function (json) {
if (json.Code != 200) {
_this.$message({
message: "生成失败!" + json.Msg,
type: "warning",
duration: "10000",
});
return;
}
else {
_this.gendCode += json.Data + '\n';
_this.printData.push({ uniqueCode: json.Data });
//清空
_this.qrcode = '';
}
},
error: function (json) {
_this.$message({
message: "生成失败!",
type: "error",
duration: "10000",
});
},
});
}
},
error: function (json) {
_this.$message({
@ -124,11 +98,27 @@
},
genCode() {
var _this = this;
if (_this.qrcode == "") {
_this.$message({
message: "请扫描二维码后再操作!",
type: "warning",
duration: "500",
});
return;
}
if (_this.num == "") {
_this.$message({
message: "请输入数量后再操作!",
type: "warning",
duration: "500",
});
return;
}
// 调用后台方法,生成唯一码,(流水号)
$.ajax({
type: "post",
dataType: "json",
data: { code: _this.qrcode },
data: { code: _this.qrcode, num: _this.num },
url: "/configs/Print/GenCode",
success: function (json) {
if (json.Code != 200) {
@ -140,8 +130,12 @@
return;
}
else{
_this.gendCode += json.Data + '\n';
_this.printData.push({ uniqueCode: json.Data });
console.log(json);
json.Data.forEach(function (item) {
_this.gendCode += item.UniqueCode + '\n';
_this.printData.push({ uniqueCode: item.UniqueCode });
});
}
},
error: function (json) {
@ -152,8 +146,7 @@
});
},
});
//清空
_this.qrcode = '';
_this.unm = 1;
},
print() {
var _this = this;
@ -164,6 +157,9 @@
})
hiprintTemplate.print(this.printData);
_this.printData = [];
//清空
_this.qrcode = '';
_this.unm = 1;
}
}
});

View File

@ -5,6 +5,9 @@ using WalkingTec.Mvvm.Core;
using WalkingTec.Mvvm.Mvc;
using WalkingTec.Mvvm.Core.Extensions;
using HHWMS.Web;
using HHWMS.Web.Models;
using System.Collections.Generic;
using Newtonsoft.Json;
namespace HHWMS.Web.Controllers
{
@ -222,5 +225,52 @@ namespace HHWMS.Web.Controllers
}
#endregion
[ActionDescription("Inventory.ReturnToMes")]
public ActionResult ReturnToMes(string id)
{
var inv = _unitwork.FindById<Inventory>(int.Parse(id));
var qr = _unitwork.FindSingle<MaterialQr>(x => x.UniqueCode.Equals(inv.UniqueCode))?.QRCode;
var bizData = new InStore
{
INWMS = new INWMS
{
INITEMS = new INITEMS
{
INITEM = new List<INITEMItem>()
{
new INITEMItem()
{
ERPSN = qr,
WMSSN = inv?.UniqueCode,
QTY = ((int?)inv?.Qty).ToString(),
TYPE = "2"
}
}
}
}
};
var str = JsonConvert.SerializeObject(bizData);
var request = new ServiceReference1.bizOperationV1Request
{
fromUnit = "8357S",
toUnit = "8357TEST",
fromSys = "WMSTEST",
toSys = "MES",
bizOperation = "InStore",
bizData = str
};
var client = new ServiceReference1.portTypeClient();
var result = client.bizOperationV1Async(request).Result;
if (result.Status == "Y")
{
Wtm.DoLog("", ActionLogTypesEnum.Normal, "mes", request: JsonConvert.SerializeObject(request), result: "success");
return FFResult().Message("库存回传成功").RefreshGrid();
}
else
{
Wtm.DoLog("", ActionLogTypesEnum.Normal, "mes", request: JsonConvert.SerializeObject(request), result: "error");
return FFResult().Message($"{result.Message}").RefreshGrid();
}
}
}
}

View File

@ -24,6 +24,7 @@ namespace HHWMS.Web
return new List<GridAction>
{
this.MakeStandardAction("Inventory", GridActionStandardTypesEnum.Create, Localizer["Sys.Create"],"inventory", dialogWidth: 800),
this.MakeAction("Inventory","ReturnToMes",Localizer["Inventory.ReturnToMes"],Localizer["Inventory.ReturnToMes"],GridActionParameterTypesEnum.SingleId,"inventory"),
this.MakeStandardAction("Inventory", GridActionStandardTypesEnum.Edit, Localizer["Sys.Edit"], "inventory", dialogWidth: 800),
this.MakeStandardAction("Inventory", GridActionStandardTypesEnum.Delete, Localizer["Sys.Delete"], "inventory", dialogWidth: 800),
this.MakeStandardAction("Inventory", GridActionStandardTypesEnum.Details, Localizer["Sys.Details"], "inventory", dialogWidth: 800),

View File

@ -5,6 +5,7 @@ using WalkingTec.Mvvm.Mvc;
using WalkingTec.Mvvm.Core.Extensions;
using HHWMS.Web.Models;
using System.Collections.Generic;
using System;
namespace HHWMS.Web.Controllers
{
@ -141,7 +142,7 @@ namespace HHWMS.Web.Controllers
{
UniqueCode = item,
Status = 0,
MaterialType = "PL",
ZoneCode = ZoneCodeEnum.盘料库,
ReceiptHeaderId = vm.Entity.ReceiptHeaderId
});
}
@ -154,12 +155,29 @@ namespace HHWMS.Web.Controllers
detailList.Add(new ReceiptDetail
{
UniqueCode = item,
MaterialType = "SL",
ZoneCode = ZoneCodeEnum.散料库,
Status = 0,
ReceiptHeaderId = vm.Entity.ReceiptHeaderId
});
}
}
// 补充物料明细
foreach(var item in detailList)
{
var materialqr = _unitwork.FindSingle<MaterialQr>(x => x.UniqueCode.Equals(item.UniqueCode));
var material = _unitwork.FindSingle<Material>(x => x.QRCode.Equals(materialqr.QRCode));
item.MaterialCode = material.MaterialCode;
item.MaterialName = material.MaterialName;
item.MaterialSpec = material.MaterialSpec;
item.MaterialType = material.MaterialType;
item.MaterialUnit = material.MaterialUnit;
item.Batch = material.Batch;
item.Qty = material.Qty;
item.SupplierCode = material.SupplierCode;
item.CreateBy = Wtm.LoginUserInfo.ITCode;
item.CreateTime = DateTime.Now;
}
_unitwork.BatchAdd(detailList.ToArray());
return FFResult().CloseDialog().RefreshGrid(index: 1);
}

View File

@ -35,15 +35,15 @@ namespace HHWMS.Web
this.MakeGridHeader(x => x.UniqueCode).SetWidth(230),
this.MakeGridHeader(x => x.MaterialCode),
//this.MakeGridHeader(x => x.MaterialType),
//this.MakeGridHeader(x => x.MaterialName),
this.MakeGridHeader(x => x.MaterialName),
//this.MakeGridHeader(x => x.MaterialSpec),
//this.MakeGridHeader(x => x.MaterialUnit),
this.MakeGridHeader(x => x.MaterialUnit),
this.MakeGridHeader(x => x.Batch),
//this.MakeGridHeader(x => x.Lot).SetHide(),
//this.MakeGridHeader(x => x.ManufactureDate),
//this.MakeGridHeader(x => x.ExpirationDate),
//this.MakeGridHeader(x => x.CompanyCode),
//this.MakeGridHeader(x => x.SupplierCode),
this.MakeGridHeader(x => x.SupplierCode),
this.MakeGridHeader(x => x.CompletedQty),
this.MakeGridHeader(x => x.Qty),
//this.MakeGridHeader(x => x.InventoryStatus),

View File

@ -201,36 +201,29 @@
var _this = this;
_this.form.size = '';
_this.form.boxSize = [];
if (Box == "L02") {
_this.form.boxSize = [{ label: "24mm", value: "24" }, { label: "16mm", value: "16" }, { label: "10mm", value: "10" }]
_this.dataIndex = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16];
}
else if (Box == "L01") {
_this.form.boxSize = [{ label: "8mm", value: "8" }];
_this.form.size = _this.form.boxSize[0].value;
_this.dataIndex = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20];
}
else {
_this.$message({
message: '输入周转箱编码不正确!',
if (this.form.code == '') {
this.$message({
message: '请先选择单据!',
type: 'warning'
});
return;
}
console.log(Box);
$.ajax({
type: "post",
dataType: "json",
data: { boxCode: Box },
url: "/receipt/ReceiptIn/ScanBox",
success: function (json) {
console.log(json);
if (json.Code != 200) {
_this.$message({
message: "扫描失败!" + json.Msg,
type: "warning",
duration: "10000",
});
_this.form.boxCode = "";
return false;
}
else {
_this.$message({
@ -239,6 +232,23 @@
duration: "10000",
});
_this.$refs.uniqueCode.focus();
if (Box == "L02") {
_this.form.boxSize = [{ label: "24mm", value: "24" }, { label: "16mm", value: "16" }, { label: "10mm", value: "10" }]
_this.dataIndex = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16];
}
else if (Box == "L01") {
_this.form.boxSize = [{ label: "8mm", value: "8" }];
_this.form.size = _this.form.boxSize[0].value;
_this.dataIndex = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20];
}
else {
_this.$message({
message: '输入周转箱编码不正确!',
type: 'warning'
});
return;
}
}
},
error: function (json) {
@ -250,6 +260,8 @@
return;
},
});
// 重新扫描箱号后,待绑定列表清空
_this.bindingData = [];
_this.changeselect(_this.value);
@ -262,6 +274,13 @@
},
// 扫描唯一码
scanUniqueCode(data) {
if (this.form.code == '') {
this.$message({
message: '请先选择单据!',
type: 'warning'
});
return;
}
if (this.dataIndex.length == 0) {
this.$message({
message: '该周转箱已放满!',

View File

@ -55,50 +55,23 @@
},
methods: {
handleSelectionChange(val) {
console.log(22);
val.forEach(row => {
if (row.station == '') {
this.$refs.multipleTable.toggleRowSelection(row);
this.$message({
message: "此周转箱没有选择站台!",
type: "warning",
duration: "5000",
});
}
});
this.selectData = val;
let names = this.selectData.map(item => item["station"]);
let nameSet = new Set(names);
if (nameSet.size != names.length) {
this.$message({
message: "站台不能重复!",
type: "warning",
duration: "5000",
});
this.$refs.multipleTable.clearSelection();
this.selectData = [];
}
console.log(this.selectData);
},
// 启动入库
inOperation() {
console.log(this.tableData)
var _this = this;
for (var i = 0; i < _this.tableData.length; i++) {
if (_this.tableData[i].station == null || _this.tableData[i].station == "") {
this.$message({
message: "必须全部选择!",
type: "warning",
duration: "5000",
});
return;
}
if (_this.selectData.length < 1) {
this.$message({
message: "至少选择一个站台!",
type: "warning",
duration: "5000",
});
return;
}
$.ajax({
type: "post",
dataType: "json",
data: { data: _this.tableData },
data: { data: _this.selectData },
url: "/receipt/ReceiptInOperation/InOperation",
success: function (json) {
if (json.Code == 200) {
@ -107,6 +80,13 @@
type: "success",
});
}
else {
_this.$message({
message: json.Msg,
type: "warning",
duration: "1000",
});
}
},
error: function (json) {
alert("加载失败");

View File

@ -67,9 +67,9 @@ namespace HHWMS.Web
// 调用wcs任务下发接口
try
{
//var res = Wtm.CallAPI<ApiJsonResult<dynamic>>("WCS", "TaskAssign", HttpMethodEnum.POST, item).Result.Data;
if (true)
//if (res.Success)
var res = Wtm.CallAPI<ApiJsonResult<dynamic>>("WCS", "TaskAssign", HttpMethodEnum.POST, item).Result.Data;
//if (true)
if (res.Success)
{
var locationList = _unitwork.Find<Location>(x => task.FromLocation.Equals(x.Code) || task.ToLocation.Equals(x.Code)).ToList();
var begin = locationList.FirstOrDefault(x => x.Code.Equals(task.FromLocation));

View File

@ -0,0 +1,217 @@
{
"ExtendedData": {
"inputs": [
"E:/ZGF/Desktop/8357/intfBizOperation-service.serviceagent.wsdl"
],
"collectionTypes": [
"System.Array",
"System.Collections.Generic.Dictionary`2"
],
"namespaceMappings": [
"*, ServiceReference1"
],
"references": [
"Aliyun.OSS.Core, {Aliyun.OSS.SDK.NetCore, 2.13.0}",
"AutoMapper, {AutoMapper, 12.0.0}",
"AutoMapper.Extensions.Microsoft.DependencyInjection, {AutoMapper.Extensions.Microsoft.DependencyInjection, 12.0.0}",
"EfSchemaCompare, {EfCore.SchemaCompare, 6.0.0}",
"F:\\Repo\\8357WMS\\HHWMS.Web\\bin\\Debug\\net6.0\\WalkingTec.Mvvm.Core.dll",
"F:\\Repo\\8357WMS\\HHWMS.Web\\bin\\Debug\\net6.0\\WalkingTec.Mvvm.Mvc.dll",
"F:\\Repo\\8357WMS\\HHWMS.Web\\bin\\Debug\\net6.0\\WalkingTec.Mvvm.TagHelpers.LayUI.dll",
"Fare, {Fare, 2.1.2}",
"Google.Protobuf, {Google.Protobuf, 3.19.1}",
"Humanizer, {Humanizer.Core, 2.8.26}",
"ICSharpCode.SharpZipLib, {SharpZipLib, 1.2.0}",
"Microsoft.AspNetCore.Antiforgery, {Microsoft.AspNetCore.Antiforgery, 2.2.0}",
"Microsoft.AspNetCore.Authentication, {Microsoft.AspNetCore.Authentication, 2.2.0}",
"Microsoft.AspNetCore.Authentication.Abstractions, {Microsoft.AspNetCore.Authentication.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Authentication.Cookies, {Microsoft.AspNetCore.Authentication.Cookies, 2.2.0}",
"Microsoft.AspNetCore.Authentication.Core, {Microsoft.AspNetCore.Authentication.Core, 2.2.0}",
"Microsoft.AspNetCore.Authentication.JwtBearer, {Microsoft.AspNetCore.Authentication.JwtBearer, 6.0.0}",
"Microsoft.AspNetCore.Authorization, {Microsoft.AspNetCore.Authorization, 6.0.0}",
"Microsoft.AspNetCore.Authorization.Policy, {Microsoft.AspNetCore.Authorization.Policy, 2.2.0}",
"Microsoft.AspNetCore.Cryptography.Internal, {Microsoft.AspNetCore.Cryptography.Internal, 2.2.0}",
"Microsoft.AspNetCore.DataProtection, {Microsoft.AspNetCore.DataProtection, 2.2.0}",
"Microsoft.AspNetCore.DataProtection.Abstractions, {Microsoft.AspNetCore.DataProtection.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Diagnostics.Abstractions, {Microsoft.AspNetCore.Diagnostics.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Hosting.Abstractions, {Microsoft.AspNetCore.Hosting.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Hosting.Server.Abstractions, {Microsoft.AspNetCore.Hosting.Server.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Html.Abstractions, {Microsoft.AspNetCore.Html.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Http, {Microsoft.AspNetCore.Http, 2.2.0}",
"Microsoft.AspNetCore.Http.Abstractions, {Microsoft.AspNetCore.Http.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Http.Extensions, {Microsoft.AspNetCore.Http.Extensions, 2.2.0}",
"Microsoft.AspNetCore.Http.Features, {Microsoft.AspNetCore.Http.Features, 2.2.0}",
"Microsoft.AspNetCore.JsonPatch, {Microsoft.AspNetCore.JsonPatch, 2.2.0}",
"Microsoft.AspNetCore.Metadata, {Microsoft.AspNetCore.Metadata, 6.0.0}",
"Microsoft.AspNetCore.Mvc.Abstractions, {Microsoft.AspNetCore.Mvc.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Mvc.Core, {Microsoft.AspNetCore.Mvc.Core, 2.2.0}",
"Microsoft.AspNetCore.Mvc.DataAnnotations, {Microsoft.AspNetCore.Mvc.DataAnnotations, 2.2.0}",
"Microsoft.AspNetCore.Mvc.Formatters.Json, {Microsoft.AspNetCore.Mvc.Formatters.Json, 2.2.0}",
"Microsoft.AspNetCore.Mvc.Razor.Extensions, {Microsoft.AspNetCore.Mvc.Razor.Extensions, 6.0.0}",
"Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation, {Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation, 6.0.0}",
"Microsoft.AspNetCore.Mvc.ViewFeatures, {Microsoft.AspNetCore.Mvc.ViewFeatures, 2.2.0}",
"Microsoft.AspNetCore.Razor, {Microsoft.AspNetCore.Razor, 2.2.0}",
"Microsoft.AspNetCore.Razor.Language, {Microsoft.AspNetCore.Razor.Language, 6.0.0}",
"Microsoft.AspNetCore.Razor.Runtime, {Microsoft.AspNetCore.Razor.Runtime, 2.2.0}",
"Microsoft.AspNetCore.ResponseCaching.Abstractions, {Microsoft.AspNetCore.ResponseCaching.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.Routing, {Microsoft.AspNetCore.Routing, 2.2.0}",
"Microsoft.AspNetCore.Routing.Abstractions, {Microsoft.AspNetCore.Routing.Abstractions, 2.2.0}",
"Microsoft.AspNetCore.SpaServices.Extensions, {Microsoft.AspNetCore.SpaServices.Extensions, 6.0.0}",
"Microsoft.AspNetCore.WebUtilities, {Microsoft.AspNetCore.WebUtilities, 2.2.0}",
"Microsoft.CodeAnalysis, {Microsoft.CodeAnalysis.Common, 4.0.0}",
"Microsoft.CodeAnalysis.CSharp, {Microsoft.CodeAnalysis.CSharp, 4.0.0}",
"Microsoft.CodeAnalysis.Razor, {Microsoft.CodeAnalysis.Razor, 6.0.0}",
"Microsoft.Data.SqlClient, {Microsoft.Data.SqlClient, 2.1.4}",
"Microsoft.Data.Sqlite, {Microsoft.Data.Sqlite.Core, 6.0.0}",
"Microsoft.EntityFrameworkCore, {Microsoft.EntityFrameworkCore, 6.0.11}",
"Microsoft.EntityFrameworkCore.Abstractions, {Microsoft.EntityFrameworkCore.Abstractions, 6.0.11}",
"Microsoft.EntityFrameworkCore.InMemory, {Microsoft.EntityFrameworkCore.InMemory, 6.0.0}",
"Microsoft.EntityFrameworkCore.Relational, {Microsoft.EntityFrameworkCore.Relational, 6.0.11}",
"Microsoft.EntityFrameworkCore.Sqlite, {Microsoft.EntityFrameworkCore.Sqlite.Core, 6.0.0}",
"Microsoft.EntityFrameworkCore.SqlServer, {Microsoft.EntityFrameworkCore.SqlServer, 6.0.0}",
"Microsoft.Extensions.Caching.Abstractions, {Microsoft.Extensions.Caching.Abstractions, 6.0.0}",
"Microsoft.Extensions.Caching.Memory, {Microsoft.Extensions.Caching.Memory, 6.0.1}",
"Microsoft.Extensions.Configuration, {Microsoft.Extensions.Configuration, 6.0.0}",
"Microsoft.Extensions.Configuration.Abstractions, {Microsoft.Extensions.Configuration.Abstractions, 6.0.0}",
"Microsoft.Extensions.Configuration.Binder, {Microsoft.Extensions.Configuration.Binder, 6.0.0}",
"Microsoft.Extensions.Configuration.EnvironmentVariables, {Microsoft.Extensions.Configuration.EnvironmentVariables, 6.0.0}",
"Microsoft.Extensions.Configuration.FileExtensions, {Microsoft.Extensions.Configuration.FileExtensions, 6.0.0}",
"Microsoft.Extensions.Configuration.Json, {Microsoft.Extensions.Configuration.Json, 6.0.0}",
"Microsoft.Extensions.DependencyInjection, {Microsoft.Extensions.DependencyInjection, 6.0.1}",
"Microsoft.Extensions.DependencyInjection.Abstractions, {Microsoft.Extensions.DependencyInjection.Abstractions, 6.0.0}",
"Microsoft.Extensions.DependencyModel, {Microsoft.Extensions.DependencyModel, 6.0.0}",
"Microsoft.Extensions.FileProviders.Abstractions, {Microsoft.Extensions.FileProviders.Abstractions, 6.0.0}",
"Microsoft.Extensions.FileProviders.Physical, {Microsoft.Extensions.FileProviders.Physical, 6.0.0}",
"Microsoft.Extensions.FileSystemGlobbing, {Microsoft.Extensions.FileSystemGlobbing, 6.0.0}",
"Microsoft.Extensions.Hosting.Abstractions, {Microsoft.Extensions.Hosting.Abstractions, 6.0.0}",
"Microsoft.Extensions.Http, {Microsoft.Extensions.Http, 6.0.0}",
"Microsoft.Extensions.Localization, {Microsoft.Extensions.Localization, 6.0.0}",
"Microsoft.Extensions.Localization.Abstractions, {Microsoft.Extensions.Localization.Abstractions, 6.0.0}",
"Microsoft.Extensions.Logging, {Microsoft.Extensions.Logging, 6.0.0}",
"Microsoft.Extensions.Logging.Abstractions, {Microsoft.Extensions.Logging.Abstractions, 6.0.0}",
"Microsoft.Extensions.Logging.Configuration, {Microsoft.Extensions.Logging.Configuration, 6.0.0}",
"Microsoft.Extensions.Logging.Console, {Microsoft.Extensions.Logging.Console, 6.0.0}",
"Microsoft.Extensions.Logging.Debug, {Microsoft.Extensions.Logging.Debug, 6.0.0}",
"Microsoft.Extensions.ObjectPool, {Microsoft.Extensions.ObjectPool, 2.2.0}",
"Microsoft.Extensions.Options, {Microsoft.Extensions.Options, 6.0.0}",
"Microsoft.Extensions.Options.ConfigurationExtensions, {Microsoft.Extensions.Options.ConfigurationExtensions, 6.0.0}",
"Microsoft.Extensions.Primitives, {Microsoft.Extensions.Primitives, 6.0.0}",
"Microsoft.Extensions.WebEncoders, {Microsoft.Extensions.WebEncoders, 2.2.0}",
"Microsoft.IdentityModel.JsonWebTokens, {Microsoft.IdentityModel.JsonWebTokens, 6.10.0}",
"Microsoft.IdentityModel.Logging, {Microsoft.IdentityModel.Logging, 6.10.0}",
"Microsoft.IdentityModel.Protocols, {Microsoft.IdentityModel.Protocols, 6.10.0}",
"Microsoft.IdentityModel.Protocols.OpenIdConnect, {Microsoft.IdentityModel.Protocols.OpenIdConnect, 6.10.0}",
"Microsoft.IdentityModel.Tokens, {Microsoft.IdentityModel.Tokens, 6.10.0}",
"Microsoft.Net.Http.Headers, {Microsoft.Net.Http.Headers, 2.2.0}",
"Microsoft.OpenApi, {Microsoft.OpenApi, 1.2.3}",
"Microsoft.Win32.Primitives, {Microsoft.Win32.Primitives, 4.3.0}",
"Microsoft.Win32.Registry, {Microsoft.Win32.Registry, 4.7.0}",
"Microsoft.Win32.SystemEvents, {Microsoft.Win32.SystemEvents, 6.0.0}",
"MySqlConnector, {MySqlConnector, 2.0.0}",
"Newtonsoft.Json, {Newtonsoft.Json, 13.0.1}",
"Newtonsoft.Json.Bson, {Newtonsoft.Json.Bson, 1.0.1}",
"Npgsql, {Npgsql, 6.0.1}",
"Npgsql.EntityFrameworkCore.PostgreSQL, {Npgsql.EntityFrameworkCore.PostgreSQL, 6.0.1}",
"NPOI, {DotNetCore.NPOI.Core, 1.2.3}",
"NPOI.OOXML, {DotNetCore.NPOI, 1.2.3}",
"NPOI.OpenXml4Net, {DotNetCore.NPOI.OpenXml4Net, 1.2.3}",
"NPOI.OpenXmlFormats, {DotNetCore.NPOI.OpenXmlFormats, 1.2.3}",
"Oracle.EntityFrameworkCore, {Oracle.EntityFrameworkCore, 6.21.4}",
"Oracle.ManagedDataAccess, {Oracle.ManagedDataAccess.Core, 3.21.41}",
"Pomelo.EntityFrameworkCore.MySql, {Pomelo.EntityFrameworkCore.MySql, 6.0.0}",
"protobuf-net, {protobuf-net, 3.2.26}",
"protobuf-net.Core, {protobuf-net.Core, 3.2.26}",
"Quartz, {Quartz, 3.4.0}",
"SixLabors.Fonts, {SixLabors.Fonts, 1.0.0-beta16}",
"SixLabors.ImageSharp, {SixLabors.ImageSharp, 2.1.0}",
"SixLabors.ImageSharp.Drawing, {SixLabors.ImageSharp.Drawing, 1.0.0-beta14}",
"SoapCore, {SoapCore, 1.1.0.38}",
"SQLitePCLRaw.batteries_v2, {SQLitePCLRaw.bundle_e_sqlite3, 2.0.6}",
"SQLitePCLRaw.core, {SQLitePCLRaw.core, 2.0.6}",
"SQLitePCLRaw.provider.e_sqlite3, {SQLitePCLRaw.provider.e_sqlite3, 2.0.6}",
"Swashbuckle.AspNetCore.Swagger, {Swashbuckle.AspNetCore.Swagger, 6.4.0}",
"Swashbuckle.AspNetCore.SwaggerGen, {Swashbuckle.AspNetCore.SwaggerGen, 6.4.0}",
"Swashbuckle.AspNetCore.SwaggerUI, {Swashbuckle.AspNetCore.SwaggerUI, 6.4.0}",
"System.AppContext, {System.AppContext, 4.3.0}",
"System.CodeDom, {System.CodeDom, 6.0.0}",
"System.Collections, {System.Collections, 4.3.0}",
"System.Collections.Concurrent, {System.Collections.Concurrent, 4.3.0}",
"System.Collections.Immutable, {System.Collections.Immutable, 7.0.0}",
"System.Collections.NonGeneric, {System.Collections.NonGeneric, 4.3.0}",
"System.Configuration.ConfigurationManager, {System.Configuration.ConfigurationManager, 6.0.0}",
"System.Console, {System.Console, 4.3.0}",
"System.Data.Common, {System.Data.Common, 4.3.0}",
"System.Diagnostics.Debug, {System.Diagnostics.Debug, 4.3.0}",
"System.Diagnostics.DiagnosticSource, {System.Diagnostics.DiagnosticSource, 6.0.0}",
"System.Diagnostics.PerformanceCounter, {System.Diagnostics.PerformanceCounter, 6.0.0}",
"System.Diagnostics.Tools, {System.Diagnostics.Tools, 4.3.0}",
"System.Diagnostics.Tracing, {System.Diagnostics.Tracing, 4.3.0}",
"System.DirectoryServices, {System.DirectoryServices, 5.0.0}",
"System.DirectoryServices.Protocols, {System.DirectoryServices.Protocols, 5.0.1}",
"System.Drawing.Common, {System.Drawing.Common, 6.0.0}",
"System.Globalization, {System.Globalization, 4.3.0}",
"System.Globalization.Calendars, {System.Globalization.Calendars, 4.3.0}",
"System.IdentityModel.Tokens.Jwt, {System.IdentityModel.Tokens.Jwt, 6.10.0}",
"System.IO, {System.IO, 4.3.0}",
"System.IO.Compression, {System.IO.Compression, 4.3.0}",
"System.IO.Compression.ZipFile, {System.IO.Compression.ZipFile, 4.3.0}",
"System.IO.FileSystem, {System.IO.FileSystem, 4.3.0}",
"System.IO.FileSystem.AccessControl, {System.IO.FileSystem.AccessControl, 5.0.0}",
"System.IO.FileSystem.Primitives, {System.IO.FileSystem.Primitives, 4.3.0}",
"System.Linq, {System.Linq, 4.3.0}",
"System.Linq.Expressions, {System.Linq.Expressions, 4.3.0}",
"System.Linq.Queryable, {System.Linq.Queryable, 4.3.0}",
"System.Net.Http, {System.Net.Http, 4.3.0}",
"System.Net.Primitives, {System.Net.Primitives, 4.3.0}",
"System.Net.Sockets, {System.Net.Sockets, 4.3.0}",
"System.ObjectModel, {System.ObjectModel, 4.3.0}",
"System.Reflection, {System.Reflection, 4.3.0}",
"System.Reflection.DispatchProxy, {System.Reflection.DispatchProxy, 4.7.1}",
"System.Reflection.Extensions, {System.Reflection.Extensions, 4.3.0}",
"System.Reflection.Metadata, {System.Reflection.Metadata, 5.0.0}",
"System.Reflection.Primitives, {System.Reflection.Primitives, 4.3.0}",
"System.Resources.ResourceManager, {System.Resources.ResourceManager, 4.3.0}",
"System.Runtime, {System.Runtime, 4.3.0}",
"System.Runtime.CompilerServices.Unsafe, {System.Runtime.CompilerServices.Unsafe, 6.0.0}",
"System.Runtime.Extensions, {System.Runtime.Extensions, 4.3.0}",
"System.Runtime.Handles, {System.Runtime.Handles, 4.3.0}",
"System.Runtime.InteropServices, {System.Runtime.InteropServices, 4.3.0}",
"System.Runtime.InteropServices.RuntimeInformation, {System.Runtime.InteropServices.RuntimeInformation, 4.3.0}",
"System.Runtime.Loader, {System.Runtime.Loader, 4.3.0}",
"System.Runtime.Numerics, {System.Runtime.Numerics, 4.3.0}",
"System.Security.AccessControl, {System.Security.AccessControl, 6.0.0}",
"System.Security.Cryptography.Algorithms, {System.Security.Cryptography.Algorithms, 4.3.0}",
"System.Security.Cryptography.Cng, {System.Security.Cryptography.Cng, 4.7.0}",
"System.Security.Cryptography.Encoding, {System.Security.Cryptography.Encoding, 4.3.0}",
"System.Security.Cryptography.Primitives, {System.Security.Cryptography.Primitives, 4.3.0}",
"System.Security.Cryptography.ProtectedData, {System.Security.Cryptography.ProtectedData, 6.0.0}",
"System.Security.Cryptography.X509Certificates, {System.Security.Cryptography.X509Certificates, 4.3.0}",
"System.Security.Cryptography.Xml, {System.Security.Cryptography.Xml, 4.7.0}",
"System.Security.Permissions, {System.Security.Permissions, 6.0.0}",
"System.Security.Principal.Windows, {System.Security.Principal.Windows, 5.0.0}",
"System.ServiceModel, {System.ServiceModel.Primitives, 4.8.1}",
"System.ServiceModel.Http, {System.ServiceModel.Http, 4.8.1}",
"System.ServiceModel.Primitives, {System.ServiceModel.Primitives, 4.8.1}",
"System.Text.Encoding, {System.Text.Encoding, 4.3.0}",
"System.Text.Encoding.CodePages, {System.Text.Encoding.CodePages, 5.0.0}",
"System.Text.Encoding.Extensions, {System.Text.Encoding.Extensions, 4.3.0}",
"System.Text.Encodings.Web, {System.Text.Encodings.Web, 6.0.0}",
"System.Text.Json, {System.Text.Json, 6.0.0}",
"System.Text.RegularExpressions, {System.Text.RegularExpressions, 4.3.0}",
"System.Threading, {System.Threading, 4.3.0}",
"System.Threading.Tasks, {System.Threading.Tasks, 4.3.0}",
"System.Threading.Timer, {System.Threading.Timer, 4.3.0}",
"System.Windows.Extensions, {System.Windows.Extensions, 6.0.0}",
"System.Xml.ReaderWriter, {System.Xml.ReaderWriter, 4.3.0}",
"System.Xml.XDocument, {System.Xml.XDocument, 4.3.0}",
"System.Xml.XPath, {System.Xml.XPath, 4.3.0}",
"VueCliMiddleware, {VueCliMiddleware, 6.0.0}",
"Z.EntityFramework.Extensions.EFCore, {Z.EntityFramework.Extensions.EFCore, 6.16.1}",
"Z.EntityFramework.Plus.EFCore, {Z.EntityFramework.Plus.EFCore, 6.16.1}",
"Z.Expressions.Eval, {Z.Expressions.Eval, 4.0.89}"
],
"sync": true,
"targetFramework": "net6.0",
"typeReuseMode": "All"
}
}

File diff suppressed because it is too large Load Diff

View File

@ -53,6 +53,7 @@ namespace HHWMS.Web
public DbSet<ShipmentDetailHistory> ShipmentDetailHistories { get; set; }
public DbSet<ReportDesign> ReportDesigns { get; set; }
public DbSet<Material> Materials { get; set; }
public DbSet<MaterialQr> MaterialQrs { get; set; }
public override async Task<bool> DataInit(object allModules, bool IsSpa)
{
var state = await base.DataInit(allModules, IsSpa);

View File

@ -44,6 +44,11 @@
</PackageReference>
<PackageReference Include="protobuf-net" Version="3.2.26" />
<PackageReference Include="SoapCore" Version="1.1.0.38" />
<PackageReference Include="System.ServiceModel.Duplex" Version="4.10.*" />
<PackageReference Include="System.ServiceModel.Federation" Version="4.10.*" />
<PackageReference Include="System.ServiceModel.Http" Version="4.10.*" />
<PackageReference Include="System.ServiceModel.NetTcp" Version="4.10.*" />
<PackageReference Include="System.ServiceModel.Security" Version="4.10.*" />
<PackageReference Include="Z.EntityFramework.Plus.EFCore" Version="6.16.1" />
</ItemGroup>

View File

@ -81,14 +81,14 @@ namespace MESTOWMSService
var detail = new ShipmentDetail
{
UniqueCode = item.SN,
MaterialCode = material.MaterialCode,
MaterialName = material.MaterialName,
MaterialSpec = material.MaterialSpec,
MaterialType = material.MaterialType,
MaterialUnit = material.MaterialUnit,
Batch = material.Batch,
Qty = material.Qty,
CompanyCode = item.FACTORY,
MaterialCode = material?.MaterialCode,
MaterialName = material?.MaterialName,
MaterialSpec = material?.MaterialSpec,
MaterialType = material?.MaterialType,
MaterialUnit = material?.MaterialUnit,
Batch = material?.Batch,
Qty = material?.Qty,
CompanyCode = item?.FACTORY,
ManufactureDate = Convert.ToDateTime(item.MESDATE),
Status = ShipStatusEnum.新建,
CreateTime = DateTime.Now

View File

@ -0,0 +1,25 @@
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using WalkingTec.Mvvm.Core;
namespace HHWMS.Web.Models
{
/// <summary>
/// 物料二维码 唯一码对照表
/// </summary>
[Table("Materialqr")]
public class MaterialQr : BasePoco
{
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public new int ID { get; set; }
[Display(Name = "Inventory.QRCode", Description = "二维码")]
[StringLength(50, ErrorMessage = "Validate.{0}stringmax{1}")]
public string QRCode { get; set; }
[Display(Name = "Inventory.UniqueCode", Description = "唯一码")]
[StringLength(50, ErrorMessage = "Validate.{0}stringmax{1}")]
public string UniqueCode { get; set; }
}
}

View File

@ -148,6 +148,48 @@ namespace HHWMS.Web
/// </summary>
public OUTWMS OUTWMS { get; set; }
}
public class INITEMItem
{
/// <summary>
///
/// </summary>
public string ERPSN { get; set; }
/// <summary>
///
/// </summary>
public string QTY { get; set; }
/// <summary>
///
/// </summary>
public string TYPE { get; set; }
/// <summary>
///
/// </summary>
public string WMSSN { get; set; }
}
public class INITEMS
{
/// <summary>
///
/// </summary>
public List<INITEMItem> INITEM { get; set; }
}
public class INWMS
{
/// <summary>
///
/// </summary>
public INITEMS INITEMS { get; set; }
}
public class InStore
{
/// <summary>
///
/// </summary>
public INWMS INWMS { get; set; }
}
}

View File

@ -1371,4 +1371,7 @@
<data name="ShipmentHeader.StartOut" xml:space="preserve">
<value>启动出库</value>
</data>
<data name="Inventory.ReturnToMes" xml:space="preserve">
<value>回传</value>
</data>
</root>