🔒

Feature Restrictions

Introduction

Through the

and
🎐
experience.json
configuration files, there are different permutations on how features could be restricted for different user roles in the Venue Editor.

The sections below gives some examples.

Restricting Widgets

Restricting to Manager Users Only

If you would like to restrict widgets to be editable by Manager user role only, you can use the following code in template.json:

"widgets": {
  "hide": {
        "SPONSOR": true,
        "MANAGER": false
  },
  "enabledWidgets": "*" 
}

Enabling Only Header Widget for All Users

If you would like to enable only the Header widget for all users, you can use the following code in template.json:

"widgets": {
  "enabledWidgets": ["header"] 
}

Note that the above code did not include the hide key. If it is excluded, that means by default the enabledWidgets will be shown to all user roles.

Restricting Blocks

Restrict Available Blocks to Users

To simplify the experience for users of your venue in the Venue Editor, you might want to restrict the available content blocks - removing the complex ones. This is particularly useful for sponsor booths. You can do so as such:

"blocks": {
    "preventAdd": false, // All users can add content blocks
    "enabledBlocks": ["RichText", "LiveStream", "Image", "ImageList", "ImageSlideshow", "Pdf", "Resources", "Link"], 
    "predefinedBlocks": {
        // Predefined blocks configuration goes here
    }
}

Preventing Sponsors to Add Blocks & Restricting Available Blocks

The code snippet below shows how you can:

  • Prevent sponsors to add blocks
  • Allow managers to add blocks
  • Restrict the available blocks to managers
"blocks": {
    "preventAdd": {
        "SPONSOR": true, // Add Block button not available to sponsors
        "MANAGER": false
	  },
    "enabledBlocks": ["RichText", "LiveStream", "Image", "ImageList", "ImageSlideshow", "Pdf", "Resources", "Link"],
    "predefinedBlocks": {
		     // Predefined blocks configuration goes here
    }
}

Prevent Editing of Block Settings and the Changing of Block Type

💡

The following example is a common use case for 3D venues

The following code snippet shows the case where:

  • 1 predefined block is configured.
  • All users are able to add new blocks
  • New blocks are restricted only to specific lists of content blocks
  • 1 predefined block is configured
    • Sponsors cannot change the block settings, but managers can
    • Sponsors cannot change the type of the block, but managers can
    • Sponsors and managers cannot delete the block

"blocks": {
    "preventAdd": true,
    "enabledBlocks": ["RichText", "LiveStream", "Image", "ImageList", "ImageSlideshow", "Pdf", "Resources", "Link"],
    "predefinedBlocks": {
        "vertical-cover-image": {
            "preventBlockSettings": {
                "SPONSOR": true,
                "MANAGER": false
            },
            "preventChangeType": {
                "SPONSOR": true,
                "MANAGER": false
            },
            "preventEdit": {
                "SPONSOR": true,
                "MANAGER": false
            },
            "preventDelete": {
                "SPONSOR": true,
                "MANAGER": true
            },
            "type": "Image",
            "title": "Cover Image",
					  "data": {
										"heading": "Middle Panel", 
										"headingVisibility": false,
										"headingAlignment": "left",
										"livestreamTitle": "Livestream",
										"livestreamTitleVisibility": true,
										"streamingService": "customstream",
										"livestreamUrl": "https://sample-videos.com/video123/mp4/720/big_buck_bunny_720p_10mb.mp4",
										"displaySomethingWhenNotLive": "video",
										"displayImageWhenNotLive": null,
										"displayVideoWhenNotLive": null,
										"disableVideoQualityOptions": false,
										"disableAutoplay": true,
										"order": 1,
										"alignment": "left",
										"backgroundCoverImage": "https://venues.gevme.com/c8e2767b-e553-4349-b722-2e8424e09ee4/main-stage/media/panel_image.png",
										"backgroundCoverImageDimension": { "width": 1000, "height": 640 },
										"backgroundCoverImageDistortion": {
											"topLeft": ["0, 0", "10, 8"],
											"bottomLeft": ["0, 640", "6, 403"],
											"bottomRight": ["1000, 640", "429, 374"],
											"topRight": ["1000, 0", "423, 81"]
										},
										"blockWidth": "100%",
										"blockHeight": "100%",
										"widthType": "full",
										"fitHeightToContent": false,
										"boundingBox": true,
										"contentPadding": "0px"
									}
        }
    }
}