/panel/sistema/promociones) lets administrators create and manage promotional banners displayed to users inside the platform. Each promotion consists of an image, an internal title, a call-to-action button with a link, and visibility and audience settings.
Data is stored in the promotions table; only records where deleted = false are shown.
Promotion fields
| Field | Description |
|---|---|
title | Internal identifier title — visible only in the panel (max 140 characters) |
btn_text | Button label shown to users (max 80 characters) |
btn_url | Full valid URL the button links to |
image | Banner background image (converted to WebP at quality 0.78, max 1600×1600 px) |
roles | Array of user types that can see the promotion: Maestro, Tutor, Alumno |
visible | Boolean controlling whether the promotion is active (true) or hidden (false) |
Creating a promotion
Open the form
Click the Add button in the top-right corner of the Promotions page. A modal with the creation form opens.
Fill in the details
- Visibility: toggle the eye switch to control whether the promotion will be shown to users.
- Available for: select one or more roles (Teachers, Tutors, Students) that will see the promotion.
- Title: enter an internal identifier name.
- Button text: the label users will see on the action button.
- Button URL: the full link the button should open.
- Image: upload a PNG, JPEG, or WebP image. A real-time preview is shown.
Create/update endpoint
| Field | Type | Description |
|---|---|---|
promo | JSON string | Promotion object |
image | File (optional) | Image file to upload |
promo JSON:
Editing a promotion
Click the gear icon on a promotion row. The same modal opens with the current data pre-filled. On save, the row updates in real time.When editing, if no new image is selected the existing image is kept. It is only replaced when a new file is uploaded.
Deleting a promotion
Click the trash icon on a row and confirm in the alert dialog. Deletion is permanent and cannot be reversed from the interface.Delete endpoint
| Field | Type | Description |
|---|---|---|
record | string (UUID) | ID of the promotion to delete |
Visibility and audience
- A promotion with
visible: falseis not shown to users even if it is configured for certain roles. Use this to prepare promotions in advance. - If the
rolesarray is empty, the promotion will not be shown to any user type. - The three available roles are: Maestros, Tutores, and Alumnos.
Required permissions
The administrator must have thesystem:promotions area enabled in their role to access this section.