diff --git a/ZR.Admin.WebApi/appsettings.development.json b/ZR.Admin.WebApi/appsettings.development.json
index b2849816..62b9f040 100644
--- a/ZR.Admin.WebApi/appsettings.development.json
+++ b/ZR.Admin.WebApi/appsettings.development.json
@@ -14,9 +14,9 @@
// "Conn": "Data Source=localhost;User ID=root;Password=123456;Initial Catalog=ZrAdmin;",
//外网连接服务器
- //"Conn": "Data Source=47.116.122.230;Port=3307;User ID=root;Password=123456;Initial Catalog=ZrAdmin;",
+ "Conn": "Data Source=47.116.122.230;Port=3307;User ID=root;Password=123456;Initial Catalog=ZrAdmin;",
// 干巷服务器
- "Conn": "Data Source=192.168.60.251;Port=3306;User ID=root;Password=123456;Initial Catalog=ZrAdmin;",
+ // "Conn": "Data Source=192.168.60.251;Port=3306;User ID=root;Password=123456;Initial Catalog=ZrAdmin;",
//内网连接服务器
//"Conn": "Data Source=192.168.0.36;Port=3306;User ID=root;Password=123456;Initial Catalog=ZrAdmin;",
"Type": 0, //数据库类型 MySql = 0, SqlServer = 1, Oracle = 3,PgSql = 4,
@@ -28,7 +28,7 @@
//代码生成数据库配置
"CodeGenDbConfig": {
//代码生成连接字符串,注意{dbName}为固定格式,不要填写数据库名
- "Conn": "Data Source=192.168.0.36;Port=3306;User ID=root;Password=123456;Initial Catalog={dbName};",
+ "Conn": "Data Source=47.116.122.230;Port=3307;User ID=root;Password=123456;Initial Catalog={dbName};",
"DbType": 0,
"IsAutoCloseConnection": true,
"DbName": "ZrAdmin" //代码生成默认连接数据库
diff --git a/ZR.Admin.WebApi/wwwroot/Generatecode/ZrAdmin.NET-盘点记录-0326150209.zip b/ZR.Admin.WebApi/wwwroot/Generatecode/ZrAdmin.NET-盘点记录-0326150209.zip
new file mode 100644
index 00000000..f51977ea
Binary files /dev/null and b/ZR.Admin.WebApi/wwwroot/Generatecode/ZrAdmin.NET-盘点记录-0326150209.zip differ
diff --git a/ZR.Model/MES/wms/Dto/WmGoodsNowProductionDto.cs b/ZR.Model/MES/wms/Dto/WmGoodsNowProductionDto.cs
index 0d99bbd1..26b84106 100644
--- a/ZR.Model/MES/wms/Dto/WmGoodsNowProductionDto.cs
+++ b/ZR.Model/MES/wms/Dto/WmGoodsNowProductionDto.cs
@@ -44,7 +44,7 @@ namespace ZR.Model.MES.wms.Dto
///
public class WmGoodsNowProductionDto
{
- [Required(ErrorMessage = "雪花id不能为空")]
+
public string Id { get; set; }
diff --git a/ZR.Model/MES/wms/Dto/WmGoodsOutProductionDto.cs b/ZR.Model/MES/wms/Dto/WmGoodsOutProductionDto.cs
index 8701623d..a12160a8 100644
--- a/ZR.Model/MES/wms/Dto/WmGoodsOutProductionDto.cs
+++ b/ZR.Model/MES/wms/Dto/WmGoodsOutProductionDto.cs
@@ -49,22 +49,22 @@ namespace ZR.Model.MES.wms.Dto
///
public class WmGoodsOutProductionDto
{
- [Required(ErrorMessage = "雪花id不能为空")]
+
public string Id { get; set; }
public string FkNowProductionId { get; set; }
public string FkOutOrderId { get; set; }
- [Required(ErrorMessage = "箱子编号(MES)不能为空")]
+
public string PackageCode { get; set; }
- [Required(ErrorMessage = "箱子编号(客户)不能为空")]
+
public string PackageCodeClient { get; set; }
public string PackageCodeOriginal { get; set; }
- [Required(ErrorMessage = "库位编号不能为空")]
+
public string LocationCode { get; set; }
public string Partnumber { get; set; }
diff --git a/ZR.Service/mes/wms/WmGoodsNowProductionService.cs b/ZR.Service/mes/wms/WmGoodsNowProductionService.cs
index 70dfaeec..0819f86f 100644
--- a/ZR.Service/mes/wms/WmGoodsNowProductionService.cs
+++ b/ZR.Service/mes/wms/WmGoodsNowProductionService.cs
@@ -60,6 +60,10 @@ namespace ZR.Service.mes.wms
///
public WmGoodsNowProduction AddWmGoodsNowProduction(WmGoodsNowProduction model)
{
+ if (string.IsNullOrEmpty(model.Id))
+ {
+ model.Id = SnowFlakeSingle.Instance.NextId().ToString();//也可以在程序中直接获取ID
+ }
return Context.Insertable(model).ExecuteReturnEntity();
}
diff --git a/ZR.Service/mes/wms/WmGoodsOutProductionService.cs b/ZR.Service/mes/wms/WmGoodsOutProductionService.cs
index 78ada568..ffe0c5b3 100644
--- a/ZR.Service/mes/wms/WmGoodsOutProductionService.cs
+++ b/ZR.Service/mes/wms/WmGoodsOutProductionService.cs
@@ -62,6 +62,10 @@ namespace ZR.Service.mes.wms
///
public WmGoodsOutRecord AddWmGoodsOutProduction(WmGoodsOutRecord model)
{
+ if (string.IsNullOrEmpty(model.Id))
+ {
+ model.Id= SnowFlakeSingle.Instance.NextId().ToString();//也可以在程序中直接获取ID
+ }
return Context.Insertable(model).ExecuteReturnEntity();
}