修改基础数据国家保存方法

optimize
jianghaiqing 2 years ago
parent 504b642ba2
commit 239e9a7210

@ -1177,7 +1177,7 @@ public class CommonDBService : ICommonDBService, IDynamicApiController, ITransie
if (model != null)
{
var checkModel = _codeCountryRep.AsQueryable().Where(t => t.Code == entity.Code && t.GID != entity.GID);
var checkModel = _codeCountryRep.AsQueryable().Where(t => t.Code == entity.Code && t.GID != entity.GID).First();
if (checkModel != null)
throw Oops.Bah(ErrorCode.D1006);
@ -1194,7 +1194,7 @@ public class CommonDBService : ICommonDBService, IDynamicApiController, ITransie
}
else
{
var model = _codeCountryRep.AsQueryable().Where(t => t.Code == entity.Code);
var model = _codeCountryRep.AsQueryable().Where(t => t.Code == entity.Code).First();
if (model != null)
throw Oops.Bah(ErrorCode.D1006);

Loading…
Cancel
Save