回写商品信息修改

dev
cjy 2 months ago
parent e160115653
commit d166f870cc

@ -510,11 +510,19 @@ public partial class SeaExportService : ISeaExportService
GoodName = seaExport.GoodsName,
HSCode = seaExport.HSCode
};
var checkInfo = sqlSugarScope.Queryable<CodeGoods>().Where(x => x.HSCode == seaExport.HSCode && x.GoodName ==seaExport.GoodsName).First();
if (checkInfo.IsNotNull())
{
return checkInfo.Id;
}
else
{
var entity = sqlSugarScope.Insertable(data).RemoveDataCache($"{SqlSugarCacheConst.Goods}{user.TenantId}").ExecuteReturnEntityAsync();
var entity = sqlSugarScope.Insertable(data).RemoveDataCache($"{SqlSugarCacheConst.Goods}{user.TenantId}").ExecuteReturnEntityAsync();
seaExport.GoodsId = entity.Id;
return entity.Id;
seaExport.GoodsId = entity.Id;
return entity.Id;
}
}
else
{

Loading…
Cancel
Save