2021-11-11 11:23:49 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
module CustomerRelations
|
|
|
|
module Organizations
|
|
|
|
class BaseService < ::BaseGroupService
|
|
|
|
private
|
|
|
|
|
|
|
|
def allowed?
|
2021-12-11 22:18:48 +05:30
|
|
|
current_user&.can?(:admin_crm_organization, group)
|
2021-11-11 11:23:49 +05:30
|
|
|
end
|
|
|
|
|
|
|
|
def error(message)
|
2021-11-18 22:05:49 +05:30
|
|
|
ServiceResponse.error(message: Array(message))
|
2021-11-11 11:23:49 +05:30
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|