fix: update tenancy failed

This commit is contained in:
2024-06-25 17:06:04 +08:00
parent 0faeb1e0ca
commit 267904be29
5 changed files with 10 additions and 5 deletions

View File

@@ -26,7 +26,7 @@ type ISysTenant interface {
CheckUniqueTenantName(tenantName, parentId, tenantId string) bool
// check unique tenancy_type and tenancy_key
IsUniqueTenancy(tenancyType, tenancyKey string) bool
IsUniqueTenancy(tenantID, tenancyType, tenancyKey string) bool
// InsertTenant 新增租户信息
InsertTenant(sysTenant model.SysTenant) string

View File

@@ -74,8 +74,9 @@ func (r *SysTenantImpl) CheckUniqueTenantName(tenantName, parentId, tenantId str
}
// CheckUniqueTenantName 校验同级部门名称是否唯一
func (r *SysTenantImpl) IsUniqueTenancy(tenancyType, tenancyKey string) bool {
func (r *SysTenantImpl) IsUniqueTenancy(tenantID, tenancyType, tenancyKey string) bool {
return r.sysTenantRepository.IsUniqueTenancy(model.SysTenant{
TenantID: tenantID,
TenancyType: tenancyType,
TenancyKey: tenancyKey,
})