|
@ -52,7 +52,8 @@ namespace BBWYB.Server.Business |
|
|
if (string.IsNullOrEmpty(shopSettingRequest.PurchaseAccountId) || shopSettingRequest.PurchaseAccountId == "0") |
|
|
if (string.IsNullOrEmpty(shopSettingRequest.PurchaseAccountId) || shopSettingRequest.PurchaseAccountId == "0") |
|
|
{ |
|
|
{ |
|
|
var isRepeat = fsqlManager.MDSfsql.Select<Purchaseaccount>().Where(pa => pa.AppKey == shopSettingRequest.AppKey && |
|
|
var isRepeat = fsqlManager.MDSfsql.Select<Purchaseaccount>().Where(pa => pa.AppKey == shopSettingRequest.AppKey && |
|
|
pa.AppToken == shopSettingRequest.AppToken).Any(); |
|
|
pa.AppToken == shopSettingRequest.AppToken && |
|
|
|
|
|
pa.ShopId == mdsShop.ShopId).Any(); |
|
|
if (isRepeat) |
|
|
if (isRepeat) |
|
|
throw new BusinessException($"采购账号重复"); |
|
|
throw new BusinessException($"采购账号重复"); |
|
|
shopSettingRequest.PurchaseAccountId = idGenerator.NewLong().ToString(); |
|
|
shopSettingRequest.PurchaseAccountId = idGenerator.NewLong().ToString(); |
|
|