mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-15 18:31:41 +00:00
fix: generar un rol dentro del sitio
This commit is contained in:
parent
ee10e170ec
commit
670d6063e5
1 changed files with 1 additions and 6 deletions
|
@ -13,7 +13,7 @@ SiteService = Struct.new(:site, :usuarie, :params, keyword_init: true) do
|
|||
def create
|
||||
self.site = Site.new params
|
||||
|
||||
role = add_role temporal: false, rol: 'usuarie'
|
||||
role = site.roles.build(usuarie: usuarie, temporal: false, rol: 'usuarie')
|
||||
site.deploys.build type: 'DeployLocal'
|
||||
# Los sitios de testing no se sincronizan
|
||||
sync_nodes unless site.name.end_with? '.testing'
|
||||
|
@ -106,11 +106,6 @@ SiteService = Struct.new(:site, :usuarie, :params, keyword_init: true) do
|
|||
GitPushJob.perform_later(site)
|
||||
end
|
||||
|
||||
def add_role(temporal: true, rol: 'invitade')
|
||||
site.roles << Rol.new(site: site, usuarie: usuarie,
|
||||
temporal: temporal, rol: rol)
|
||||
end
|
||||
|
||||
# Crea la licencia del sitio para cada locale disponible en el sitio
|
||||
#
|
||||
# @return [Boolean]
|
||||
|
|
Loading…
Reference in a new issue