> For the complete documentation index, see [llms.txt](https://docs.snapfix.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.snapfix.com/how-the-apps-work/screens/staff/task-move.md).

# Task move

{% hint style="info" %}
Draft, written by an agent and not yet checked by a person ([how to read these docs](https://docs.snapfix.com/how-to-read.md)). Platforms: web. [Source on GitHub](https://github.com/snapfix/docs/blob/main/spec/screens/staff/task-move.md).
{% endhint %}

Staff pick a user, then a site and two of the user's groups in it, and drag the user's tasks from one group to the other. Before each move the server compares the groups; a move copies the task into the target group and marks the original deleted.

* **Where:** admin app `/task-move`; menu "Task Move".
* **Who:** any signed-in staff user. The route checks only that a session exists. The check and the move check no staff flag and tie the caller to neither group, so any signed-in user can move any task by its ID.
* **Feature:** [Customer administration](https://docs.snapfix.com/product/features/staff/customer-admin.md)

## Layout

1. The title "Task Move".
2. A top row:
   * The user picker, labelled "Users (search type - )": a search select ("Type to search user") and a "Search type" select with "UUID", "Username", "Name", "Country Code", "Mobile", "First Name" and "Last Name", "Username" at first. Each user shows as " - ".
   * "Accounts", a select (placeholder "Account") with the sites of the user's groups. It is disabled until the chosen user has a group.
   * Three colour buttons, red, amber and green; red is chosen at first.
3. Two columns with a swap icon between them. Each column has a "Select group" select above its task list.

Each task is a card with its image (or a placeholder), its title on up to two lines, and its creation time as "LLL dd HH:mm". A task created after a fixed date in September 2022 that has large text shows that text instead of the image, as HTML that Angular sanitizes (`src/app/pages/task-move/components/task-move-jobs/task-move-jobs.component.ts:82-86`, `src/app/services/task-move/task-move.service.ts:22`; webadmin\_angular @ db972390b8).

## Inputs

| Field                      | Type          | Required               | Default | Rules and messages                                                                                                                                                                                                                                                     |
| -------------------------- | ------------- | ---------------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| User                       | Search select | Yes, to show any task  | Empty   | Searches all users on the server by the search type, 1 second after typing; blank text is ignored. 50 users at a time, more on scrolling down. Only live users are asked for, and a user shows only when the legacy name is set. Clearing the select reloads the list. |
| Accounts                   | Select        | Yes, to show any group | Empty   | The sites of the user's memberships in groups that are not deleted; deleted sites are not left out.                                                                                                                                                                    |
| Colour                     | Three buttons | Yes                    | Red     | Both lists show only tasks of that colour; amber also matches yellow.                                                                                                                                                                                                  |
| Select group (each column) | Select        | Yes, to show that list | Empty   | The user's groups in the chosen site. The group chosen in the other column is disabled. Changing the site clears both.                                                                                                                                                 |

## Actions

| Action                          | Who   | What happens                                                                                                                                                                                                                                                                                                                                                                                  | API                                                                                                                                      |
| ------------------------------- | ----- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| Search for a user               | Staff | Lists the matching users.                                                                                                                                                                                                                                                                                                                                                                     | [`GET /v4/users`](https://docs.snapfix.com/engineering-reference/api/staff.md#get-v4users)                                               |
| Choose a user                   | Staff | Fills "Accounts" from the user's group list, with no further request.                                                                                                                                                                                                                                                                                                                         | None                                                                                                                                     |
| Choose a group or a colour      | Staff | Loads that group's tasks as the chosen user sees them, in the chosen colour, most recently active first, 20 at a time; scrolling near the bottom loads more. Archived tasks are left out.                                                                                                                                                                                                     | [`POST ?action=webcust_list_jobs`](https://docs.snapfix.com/engineering-reference/api/tasks.md#post-actionwebcust_list_jobs)             |
| Drag a task to the other column | Staff | The card moves at once, to the top of the other list, with a spinner on it; no card can be dragged until the move ends. Cards cannot be reordered within a list. Then the move is checked: a clean check moves the task, warnings open [Move confirmation](#move-confirmation), and an error without warnings shows the server's message, or "Internal serve rerror", and the card goes back. | [`POST ?action=migrate_job_v1_validate`](https://docs.snapfix.com/engineering-reference/api/staff.md#post-actionmigrate_job_v1_validate) |
| Move                            | Staff | Runs after a clean check or after "Confirm". Without the dialog it adds no tags and no people. The server copies the task into the target group under a new ID and marks the original deleted; the card takes the new ID and "Success" shows. A failure shows the server's message and the card goes back.                                                                                    | [`POST ?action=migrate_job_v1`](https://docs.snapfix.com/engineering-reference/api/staff.md#post-actionmigrate_job_v1)                   |

## States

* **Loading:** a list shows a spinner while its tasks load and while more load on scroll; the user picker shows "Loading Data..." while it searches.
* **Empty:** a column with no group, or a group with no tasks of the colour, shows an empty placeholder, hidden while a card is dragged.
* **Error:** a failed task list shows no message and an empty column. A check that fails as a request shows "Internal serve rerror"; a failed move shows the server's message. In both cases the card goes back.
* **No permission:** none in the app.

## Dialogs and sheets

### Move confirmation

"Move confirmation", 600 px wide, with no close button. It lists each warning from the check by its message.

* For a warning about people or tags: "Please check the checkbox below if you want to move all users" (or "tags") and a checkbox "Move users" (or "Move tags"). Each box starts ticked.
* When a warning is about a tag heading ("tagheader"), the dialog shows only those messages, with no checkboxes and no "Confirm": the move cannot go on. The customer apps' move offers to add the missing tag folders instead ([Copy or move a task](https://docs.snapfix.com/how-the-apps-work/screens/tasks/copy-move.md)) \[[ASK-21](https://github.com/snapfix/docs/blob/main/ASK.md#ask-21-who-may-copy-or-move-a-task-and-what-should-the-tag-options-do)].

| Action                       | Who   | What happens                                                                                                                                                                                                                                                                 | API                                                                                                                    |
| ---------------------------- | ----- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
| "Confirm"                    | Staff | Moves the task, adding the missing tags and people only for the ticked boxes. With both boxes cleared the move still goes ahead, without them \[[ASK-220](https://github.com/snapfix/docs/blob/main/ASK.md#ask-220-should-a-task-move-go-ahead-when-neither-box-is-ticked)]. | [`POST ?action=migrate_job_v1`](https://docs.snapfix.com/engineering-reference/api/staff.md#post-actionmigrate_job_v1) |
| "Cancel", or a click outside | Staff | Puts the card back in its own column, with no request.                                                                                                                                                                                                                       | None                                                                                                                   |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.snapfix.com/how-the-apps-work/screens/staff/task-move.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
