> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getray.info/llms.txt
> Use this file to discover all available pages before exploring further.

# Service categories and forms

> How an admin sets up a service in the RAY admin portal: the Categories tab, the forms inside each category, form settings (statuses, audience, viewers, assignees, managers, reopening), the form's questions, and duplicating, importing, exporting, activating and deleting forms.

## Summary

A service in the RAY admin portal is set up in its **Categories** tab. A **category** groups forms,
and a **form** holds the questions tenants answer, plus settings that decide who can use the form and
who handles its submissions. Only users with an **Admin** role for the service see the **Categories**
tab. See [Services](/services/overview) for how services are organized.

## Where to find service categories and forms

* Categories: **Services → `<service name>`**, then the **Categories** tab.
* Forms: click a category in the **Categories** tab. The page lists the category's **Forms**.
* A form's page: click the form in the category's **Forms** list.

## Categories tab columns

| Column          | Meaning                                                                                    |
| --------------- | ------------------------------------------------------------------------------------------ |
| (drag handle)   | Drag a row to change the order of the categories. The new order is saved immediately.      |
| **Image**       | The category's image.                                                                      |
| **External ID** | Optional reference to the category in another system.                                      |
| **Name**        | Name of the category.                                                                      |
| **Description** | Description of the category.                                                               |
| **Status**      | **Activated** or **Deactivated**. Click it to **Activate** or **Deactivate** the category. |
| Actions         | **Edit** and **Delete**.                                                                   |

The Categories tab can be searched by name.

## Category fields

| Field           | Required | Meaning and rules                                                                                         |
| --------------- | -------- | --------------------------------------------------------------------------------------------------------- |
| **Name**        | Yes      | Name of the category, per language. Required in the language the portal is being used in.                 |
| **Description** | Yes      | Description of the category, per language. Required in the language the portal is being used in.          |
| **External ID** | No       | Reference to the category in another system.                                                              |
| **Image**       | No       | JPG, JPEG or PNG. The portal advises: "For optimal clarity, upload images with a transparent background". |

## How to create a service category

1. Open **Services → `<service name>`** and select the **Categories** tab.
2. Click **Add**.
3. Enter the **Name** and **Description**, and optionally the **External ID** and **Image**.
4. Click **Save**.

## Forms list columns

The **Forms** list of a category shows:

| Column               | Meaning                                                                                |
| -------------------- | -------------------------------------------------------------------------------------- |
| (drag handle)        | Drag a row to change the order of the forms.                                           |
| **Image**            | The form's icon.                                                                       |
| **External ID**      | Optional reference to the form in another system.                                      |
| **Name**             | Name of the form.                                                                      |
| **Description**      | Description of the form.                                                               |
| **Last Modified at** | When the form was last changed.                                                        |
| **Status**           | **Activated** or **Deactivated**. Click it to **Activate** or **Deactivate** the form. |
| Actions              | **Duplicate** and **Delete**. Clicking a row opens the form's page.                    |

## Form settings

Form settings are entered when the form is created, and changed later with **Edit** on the form's
page.

| Setting                   | Arabic label                   | Required | Meaning and rules                                                                                                                                                                                                                                                                |
| ------------------------- | ------------------------------ | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Name**                  | الإسم                          | Yes      | Name of the form.                                                                                                                                                                                                                                                                |
| **Category**              | الفئة                          | Yes      | The category the form is listed in.                                                                                                                                                                                                                                              |
| **Description**           | الوصف                          | Yes      | Description of the form.                                                                                                                                                                                                                                                         |
| **External ID**           | المعرّف الخارجي                | No       | Reference to the form in another system.                                                                                                                                                                                                                                         |
| **Allow users to reopen** | السماح للمستخدمين بإعادة الفتح | No       | Lets the person who submitted the form reopen it.                                                                                                                                                                                                                                |
| **Reopening Period**      | فترة إعادة الفتح               | No       | Number of **Days**, 1 or more, during which reopening is allowed. Available only when **Allow users to reopen** is ticked.                                                                                                                                                       |
| **Icon**                  | الأيقونة                       | No       | JPG, JPEG or PNG. The portal recommends a transparent background and 80x80 px.                                                                                                                                                                                                   |
| **Banner Image**          | صورة الشعار                    | No       | JPG, JPEG or PNG. The portal recommends a 16:9 ratio (750x422 px).                                                                                                                                                                                                               |
| **Status** list           | الحالة                         | No       | The form's own statuses, for example "Technician assigned" or "Waiting for parts". Add a status with **+** and remove it with **−**. Each status needs a name. These statuses are used while a submission is **Acknowledged**; see [Service submissions](/services/submissions). |
| **Audience**              | الجمهور                        | Yes      | **All Users**, or **Specific Users and Groups** followed by the users and/or groups. **All Users** is selected by default. At least one user or group is needed for **Specific Users and Groups**.                                                                               |
| **Viewers**               | المشاهدون                      | No       | Users added as viewers of every submission of this form, plus email addresses. Emails must be comma-separated.                                                                                                                                                                   |
| **Assignees**             | المكلّفون                      | No       | Users added as assignees of every submission of this form.                                                                                                                                                                                                                       |
| **Managers**              | المدراء                        | No       | Users added as managers of every submission of this form.                                                                                                                                                                                                                        |

## How to create a form

1. Open **Services → `<service name>`**, select the **Categories** tab and click the category.
2. Click **Add**.
3. Fill in the form settings, at least **Name**, **Category**, **Description** and **Audience**.
4. Click **Save**. **Save** stays disabled until the required settings are filled in.
5. Open the new form from the **Forms** list and add its questions. See *How to add questions to a
   form*.

## Form page

A form's page shows the form's name at the top, its **Status** (**Activated** or **Deactivated**, with
**Activate** or **Deactivate**), and the buttons **Edit**, **Duplicate**, **Export** and **Delete**.
Below are the form's details (**External ID**, **Category**, **Description**, **Statuses**,
**Audience**, **Viewers**, **Assignees** and **Managers**) and the list of the form's questions.
**External ID** and **Category** can be changed directly on the page; the other settings are changed
with **Edit**.

## How to add questions to a form

1. Open the form's page.
2. Click **Add Field**. A new question card is added.
3. Choose the question type, for example **Short Text**, **Long Text**, **Number**, **Multiple
   selection**, **Date**, **Time**, **Date & Time**, **Location**, **Photos**, **Files**, **Videos**,
   **Title** or **Description**.
4. Enter the **Entry Name** (the question) in each language, and optionally a **Placeholder** for
   **Short Text**, **Long Text** and **Number** questions.
5. Tick **Required** if the question must be answered.
6. For **Multiple selection**, enter at least two **Choices**, and tick **Allow Multiple** to allow
   several answers. For **Photos** and **Files**, set the maximum number of uploads; for **Files**,
   also the maximum size per file (5 MB to 50 MB).
7. Drag question cards by their handle to reorder them, and use the bin button to remove one.
8. Click **Save**. All changes to the questions are saved together.

A **Title** question is a section heading and a **Description** question is a block of text; neither
has **Required**.

## How to duplicate a form

Click **Duplicate** on the form's row in the **Forms** list, or on the form's page. A copy of the form,
with its questions and settings, is added to the same category. The copy has no **External ID**.

## How to export and import forms

* To export, tick one or more forms in the **Forms** list and choose **Export**, or click **Export** on
  a form's page. The portal downloads `forms-export.zip`, with one JSON file per form. **Export** stays
  disabled until at least one form is ticked.
* To import, choose **Import** in the **Forms** list, add one or more of those JSON files in the
  **Import Forms** dialog, and click **Import**. A file that is not a valid form shows "Uploaded files
  do not contain a valid form JSON".

An imported form has " - EXPORTED" added to its name, has no **External ID**, and has no viewers,
assignees or managers. Review its settings with **Edit** after importing.

## How to activate, deactivate or delete a form

* Click the form's **Status** in the **Forms** list, or on the form's page, and choose **Activate** or
  **Deactivate**.
* Click **Delete** on the form's row or on the form's page and confirm.

Categories are activated, deactivated and deleted the same way from the **Categories** tab.

## Common questions about service forms

### How do I make a form available to only some tenants?

Edit the form and set **Audience** to **Specific Users and Groups**, then choose the users and/or
groups.

### How do I make sure a supervisor is involved in every request from a form?

Add the supervisor to the form's **Managers** (or **Assignees** or **Viewers**) in the form settings.
They are then added to every submission of that form.

### How do I add my own statuses such as "In progress" or "Waiting for parts"?

Edit the form and add the statuses under the **Status** list. They become available on submissions
that are **Acknowledged**.

### How do I let tenants reopen a request after it is closed?

Edit the form, tick **Allow users to reopen**, and set the **Reopening Period** in days.

### How do I copy a form to another portal?

Export the form from the **Forms** list, then import the JSON file with **Import** in the other
portal's **Forms** list.

## Related pages

* [Services](/services/overview): how services, categories, forms and submissions fit together.
* [Service submissions](/services/submissions): handling the submissions of a form.
* [Submission details](/services/submission-details): one submission's page.
