版本结束
This commit is contained in:
@@ -42,7 +42,7 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
return ToResponse(new ApiResult(200, "success", data));
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
|
||||
|
||||
[HttpGet("getWorkoderList_piliang")]
|
||||
@@ -66,6 +66,9 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
return ExportExcel(result.Item2, result.Item1);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 导入
|
||||
/// </summary>
|
||||
@@ -82,10 +85,10 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
int year = 0;
|
||||
int week = 0;
|
||||
int date = 0;
|
||||
if (!Directory.Exists(target))
|
||||
if (!Directory.Exists(Path.Combine(webHostEnvironment.WebRootPath, "workorder")))
|
||||
{
|
||||
// 如果目录不存在就创建
|
||||
Directory.CreateDirectory(target);
|
||||
Directory.CreateDirectory(Path.Combine(webHostEnvironment.WebRootPath, "workorder"));
|
||||
|
||||
}
|
||||
using (var stream = formFile.OpenReadStream())
|
||||
@@ -100,8 +103,6 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//读取列表数据
|
||||
try
|
||||
{
|
||||
@@ -236,7 +237,7 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 更新生产计划
|
||||
/// 更新生产计划
|
||||
/// </summary>
|
||||
/// <param name="proWorkplan">生产计划对象</param>
|
||||
/// <returns></returns>
|
||||
@@ -256,7 +257,7 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 删除本周所有计划
|
||||
/// 根据工单顺序 排序
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
@@ -268,6 +269,8 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
{
|
||||
|
||||
data = proWorkorderService.UpdateworkorderSort(id, (int)sort);
|
||||
|
||||
|
||||
}
|
||||
|
||||
return ToResponse(new ApiResult(200, "success", data));
|
||||
|
||||
@@ -169,9 +169,9 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
IWebHostEnvironment webHostEnvironment = (IWebHostEnvironment)App.ServiceProvider.GetService(typeof(IWebHostEnvironment));
|
||||
string sFileName = DateTime.Now.ToString("yyyyMMddHHmmss") + formFile.FileName;
|
||||
string target = Path.Combine(webHostEnvironment.WebRootPath, "workplan", sFileName);
|
||||
if (!Directory.Exists(target))
|
||||
if (!Directory.Exists(Path.Combine(webHostEnvironment.WebRootPath, "workplan")))
|
||||
{
|
||||
Directory.CreateDirectory(target);
|
||||
Directory.CreateDirectory(Path.Combine(webHostEnvironment.WebRootPath, "workplan"));
|
||||
}
|
||||
int year = 0;
|
||||
int week = 0;
|
||||
@@ -196,7 +196,6 @@ namespace ZR.Admin.WebApi.Controllers.mes.pro
|
||||
//读取第一行 解析 年和月
|
||||
var row = stream.Query().Take(1).First();
|
||||
year = Convert.ToInt32(row.A);
|
||||
|
||||
week = Convert.ToInt32(row.B);
|
||||
var list = stream.Query<ProWorklplan_v2>(sheetName: "Sheet1", startCell: "B3")
|
||||
.Where(it => it.Partnumber != null)
|
||||
|
||||
Reference in New Issue
Block a user