# Assign a role to a user

> Add a role to or remove a role from an existing user, change their organizational unit; the segregation of duties warning.

URL: https://erpdocs.corexlogic.com/en/yonetim/islemler/kullaniciya-rol-atama

- **Type:** Task
- **Module:** Administration
- **Menu path:** Yönetim › Kullanıcı ve Roller › Kullanıcılar (Administration › Users and Roles › Users)
- **Screen route:** `/users`
- **Required permission:** `users.edit`
- **Prerequisites:**
  - The user is active (a disabled account cannot be edited).
  - `roles.view` for the role list.

## Steps

1. On the **Yönetim › Kullanıcı ve Roller › Kullanıcılar** (Administration › Users and Roles › Users) screen, find the user with the **Ara** (Search) box.
   <!-- action: navigate · target: "/users" · value: "temsilcisi" -->
2. Select **Kullanıcıyı Düzenle** (Edit User) from the row's **İşlemler** (Actions) menu.
   <!-- action: click · target: "Kullanıcıyı Düzenle" -->

   ![User row Actions menu](https://erpdocs.corexlogic.com/en/en/img/screens/yonetim/kullanici-islemler.png)
   1. Name, phone, roles and org unit
   2. Personal permissions on top of roles
   3. Narrows rights to warehouses and work centers
   4. Reset link or manual password
   5. Disables the account — record is kept

3. Switch to the **Roller** (Roles) tab. Check the role you want to assign and uncheck the one you want to remove. The tab name shows the number of selected roles.
   <!-- action: choose · target: "Roller" · value: "Demo — Satış Temsilcisi" -->

   ![Edit User](https://erpdocs.corexlogic.com/en/en/img/screens/yonetim/kullanici-duzenle.png)
   1. Roles — add or remove roles
   2. Account and login lock status
   3. Save — disabled when nothing changed

4. If a **Görevler ayrılığı uyarısı** (Segregation of duties warning) appears, read the conflicting roles and the reason. The warning does not block saving; if you are assigning the role knowingly, continue.
   <!-- action: verify · target: "Görevler ayrılığı uyarısı" -->

   ![Segregation of duties warning](https://erpdocs.corexlogic.com/en/en/img/screens/yonetim/gorevler-ayriligi.png)
   1. Conflicting roles and why — saving is not blocked

5. If the person's unit changes, select the new unit on the **Organizasyon Birimi** (Organizational Unit) tab.
   <!-- action: open · target: "Organizasyon Birimi" -->
6. Click **Kaydet** (Save; the button is disabled if there are no changes).
   <!-- action: click · target: "Kaydet" · expect: "The window closes; the Roller (Roles) column in the list is updated" -->

**Result:** The user's permissions are calculated according to the new roles on their next request; signing in again is not required. For checks that look at the role name, such as approval steps and document history, the user should refresh the page.

## What you need to know

- Effective permissions = the user's roles ∪ the roles of their unit ∪ their extra permissions. Roles that come from the
  unit do not appear on this tab; see [Organization chart](https://erpdocs.corexlogic.com/en/yonetim/ekranlar/organizasyon-semasi).
- A role cannot be removed from the last active account that holds the **Yönetici** (Administrator) role: "… Yönetici
  rolünü taşıyan son etkin hesap. Rolü kaldırmadan önce başka bir kullanıcıya Yönetici rolü verin." (… is the last
  active account holding the Administrator role. Give another user the Administrator role before removing the role.)
- If you change your own roles, your menu is refreshed immediately after saving.
- If saving is only partially completed (e.g. the roles were saved but the unit could not be saved), a message remains
  in the window and the list is refreshed; save the missing part again.

## Related

- [Role examples](https://erpdocs.corexlogic.com/en/yonetim/rol-ornekleri)
- [Permission model — segregation of duties](https://erpdocs.corexlogic.com/en/yonetim/yetki-modeli#gorevler-ayriligi)
