打印修改,发布修改

This commit is contained in:
霍尔 committed 2023-09-17 18:53:57 +08:00
1 parent 85b6d3a0ee
commit c494b7b1ef
6 files changed
+26 -15

No files matched your search

+4
View File
@@ -295,6 +295,10 @@ namespace HHWMS.Web
} }
_unitwork.Update(task); _unitwork.Update(task);
if (task.Status == TaskStatusEnum.完成)
{
_unitwork.Delete(task);
}
} }
} }
@@ -54,13 +54,20 @@ namespace HHWMS.Web.Controllers
} }
else else
{ {
if (string.IsNullOrEmpty(material.UniqueCode))
var prefix = code.Split("@")[1].Substring(2); {
var unique = _unitwork.GetSerialNumber(prefix, 8); var prefix = code.Split("@")[1].Substring(2);
var uniqueCode = prefix + unique; var unique = _unitwork.GetSerialNumber(prefix, 8);
var uniqueCode = prefix + unique;
material.UniqueCode = uniqueCode; material.UniqueCode = uniqueCode;
return JsonMore(uniqueCode); _unitwork.Update(material);
return JsonMore(uniqueCode);
}
else
{
return JsonMore(material.UniqueCode);
}
} }
} }
} }
@@ -30,7 +30,7 @@
{ {
"options": { "options": {
"left": 0, "left": 0,
"top": 0, "top": 2,
"height": 38, "height": 38,
"width": 84, "width": 84,
"field": "code", "field": "code",
@@ -39,10 +39,10 @@
"printElements": [ "printElements": [
{ {
"options": { "options": {
"left": 15, "left": 0,
"top": 5, "top": 2,
"height": 44, "height": 52,
"width": 54, "width": 81,
"title": "", "title": "",
"field": "uniqueCode", "field": "uniqueCode",
"testData": "", "testData": "",
@@ -53,9 +53,9 @@ namespace HHWMS.Web
// 调用wcs任务下发接口 // 调用wcs任务下发接口
try try
{ {
//var res = Wtm.CallAPI<ApiJsonResult<dynamic>>("WCS", "TaskAssign", HttpMethodEnum.POST, item).Result.Data; var res = Wtm.CallAPI<ApiJsonResult<dynamic>>("WCS", "TaskAssign", HttpMethodEnum.POST, item).Result.Data;
if (true) //if (true)
//if (res.Success) if (res.Success)
{ {
var locationList = _unitwork.Find<Location>(x => task.FromLocation.Equals(x.Code) || task.ToLocation.Equals(x.Code)).ToList(); 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)); var begin = locationList.FirstOrDefault(x => x.Code.Equals(task.FromLocation));
+1 -1
View File
@@ -24,7 +24,7 @@
"Connections": [ "Connections": [
{ {
"Key": "default", "Key": "default",
"Value": "Server=localhost;Port=3306;Database=8357wms;Uid=root;Password=abc123*;Character Set=utf8mb4;", "Value": "Server=127.0.0.1;Port=3306;Database=8357wms;Uid=root;Password=abc123*;Character Set=utf8mb4;",
"DBType": "mysql" "DBType": "mysql"
} }
//{ //{