[FIX] website_event_meet: Allow room creation for unpublished events
Allow creation of room for unpublished events for base users so that they can prepare all their rooms before releasing their event in the wild. LINKS: TaskID:2339835 closes odoo/odoo#58141 Pr: #57799 X-original-commit: 4cecd66821a1f4493fe321b9886df51d946fd779 Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
This commit is contained in:
@@ -77,7 +77,7 @@ class WebsiteEventMeetController(EventCommunityController):
|
||||
@http.route("/event/<model('event.event'):event>/meeting_room_create",
|
||||
type="http", auth="public", methods=["POST"], website=True)
|
||||
def create_meeting_room(self, event, **post):
|
||||
if not event or not event.can_access_from_current_website() or not event.is_published or not event.meeting_room_allow_creation:
|
||||
if not event or not event.can_access_from_current_website() or (not event.is_published and not request.env.user.user_has_groups('base.group_user')) or not event.meeting_room_allow_creation:
|
||||
raise Forbidden()
|
||||
|
||||
name = post.get("name")
|
||||
|
||||
Reference in New Issue
Block a user