Commit b5559d19 by xin.yang

fix bug

parent 1f028664
...@@ -1199,6 +1199,15 @@ namespace Siger.ApiWMS.Controllers ...@@ -1199,6 +1199,15 @@ namespace Siger.ApiWMS.Controllers
status = req.status == (int)RowState.Valid ? (int)RowState.Valid : (int)RowState.Invalid, status = req.status == (int)RowState.Valid ? (int)RowState.Valid : (int)RowState.Invalid,
locationid = Location.id == locationTypeId ? req.storeID.ToInt() : 0 locationid = Location.id == locationTypeId ? req.storeID.ToInt() : 0
}; };
if (Location.id == locationTypeId)
{
var locationIdExist = location.Get(q => q.projectid == ProjectId && q.status == (int)RowState.Valid && q.typeid == locationTypeId &&
q.locationid == req.storeID.ToInt() && q.storageid == req.warehouseid);
if (locationIdExist != null)
{
throw new BadRequestException(RequestEnum.IDExist);
}
}
parentid = InsertLocation(tmp, waveHouse.name); parentid = InsertLocation(tmp, waveHouse.name);
if (parentid > 0) if (parentid > 0)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment