1.导入时默认所有物料为启用状态
This commit is contained in:
@ -305,6 +305,7 @@
|
|||||||
if (typeIndex + 1 < this.shelfTypeOptions.length) {
|
if (typeIndex + 1 < this.shelfTypeOptions.length) {
|
||||||
this.selectedShelfTypeIndex = typeIndex;
|
this.selectedShelfTypeIndex = typeIndex;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
this.shelfAreaOptions = res.data.data.locationArea;
|
this.shelfAreaOptions = res.data.data.locationArea;
|
||||||
var index = getConfig("bindSelectedShelfAreaIndex", 0);
|
var index = getConfig("bindSelectedShelfAreaIndex", 0);
|
||||||
|
@ -164,7 +164,7 @@ namespace WCS.BLL.Services.Service
|
|||||||
MatUnit = mat.单位,
|
MatUnit = mat.单位,
|
||||||
MatCustomer = mat.客户,
|
MatCustomer = mat.客户,
|
||||||
ModifyUser = userName,
|
ModifyUser = userName,
|
||||||
IsEnable = mat.状态 == "启用" ? true : false,
|
IsEnable = true,//导入的数据默认启用
|
||||||
};
|
};
|
||||||
matBaseInfos.Add(matBaseInfo);
|
matBaseInfos.Add(matBaseInfo);
|
||||||
}
|
}
|
||||||
|
@ -84,6 +84,8 @@ namespace WCS.WebApi.Controllers
|
|||||||
var list = MiniExcelLibs.MiniExcel.Query<MatBaseInfoImportModel>(stream, "物料管理", ExcelType.XLSX).ToList();
|
var list = MiniExcelLibs.MiniExcel.Query<MatBaseInfoImportModel>(stream, "物料管理", ExcelType.XLSX).ToList();
|
||||||
//去除空白行
|
//去除空白行
|
||||||
list.RemoveAll(x => string.IsNullOrWhiteSpace(x.物料编码));
|
list.RemoveAll(x => string.IsNullOrWhiteSpace(x.物料编码));
|
||||||
|
//去掉重复项
|
||||||
|
list = list.Distinct().ToList();
|
||||||
|
|
||||||
return await _matBaseInfoService.importMatBaseInfo(list, userName, deviceType);
|
return await _matBaseInfoService.importMatBaseInfo(list, userName, deviceType);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user