Přejít na obsah
Odoo Menu
  • Přihlásit se
  • Vyzkoušejte zdarma
  • Aplikace
    Finance
    • Účetnictví
    • Fakturace
    • Výdaje
    • Spreadsheet (BI)
    • Dokumenty
    • Podpisy
    Prodej
    • CRM
    • Prodej
    • POS Obchod
    • POS Restaurace
    • Předplatné
    • Pronájem
    Webové stránky
    • Webové stránky
    • E-shop
    • Blog
    • Fórum
    • Živý chat
    • eLearning
    Dodavatelský řetězec
    • Sklad
    • Výroba
    • PLM
    • Nákup
    • Údržba
    • Kvalita
    Lidské zdroje
    • Zaměstnanci
    • Nábor
    • Volno
    • Hodnocení zaměstnanců
    • Doporučení
    • Vozový park
    Marketing
    • Marketing sociálních sítí
    • Emailový marketing
    • SMS Marketing
    • Události
    • Marketingová automatizace
    • Dotazníky
    Služby
    • Projekt
    • Časové výkazy
    • Práce v terénu
    • Helpdesk
    • Plánování
    • Schůzky
    Produktivita
    • Diskuze
    • Schvalování
    • IoT
    • VoIP
    • Znalosti
    • WhatsApp
    Aplikace třetích stran Odoo Studio Odoo cloudová platforma
  • Branže
    Maloobchod
    • Knihkupectví
    • Obchod s oblečením
    • Obchod s nábytkem
    • Potraviny
    • Obchod s hardwarem
    • Hračkářství
    Food & Hospitality
    • Bar a Pub
    • Restaurace
    • Fast Food
    • Guest House
    • Distributor nápojů
    • Hotel
    Real Estate
    • Real Estate Agency
    • Architektonická firma
    • Stavba
    • Správa nemovitostí
    • Zahradnictví
    • Asociace vlastníků nemovitosti
    Consulting
    • Accounting Firm
    • Odoo Partner
    • Marketingová agentura
    • Právník
    • Akvizice talentů
    • Audit a certifikace
    Výroba
    • Textile
    • Metal
    • Furnitures
    • Food
    • Brewery
    • Korporátní dárky
    Zdraví a fitness
    • Sportovní klub
    • Prodejna brýli
    • Fitness Centrum
    • Wellness praktikové
    • Lékárna
    • Kadeřnictví
    Trades
    • Údržbář
    • IT hardware a podpora
    • Solar Energy Systems
    • Výrobce obuvi
    • Úklidové služby
    • HVAC Services
    Others
    • Nonprofit Organization
    • Agentura pro životní prostředí
    • Pronájem billboardů
    • Fotografování
    • Leasing jízdních kol
    • Prodejce softwaru
    Browse all Industries
  • Komunita
    Edukační program
    • Tutoriály
    • Dokumentace
    • Certifikace
    • Vzdělávání
    • Blog
    • Podcast
    Podpora vzdělávání
    • Vzdělávací program
    • Scale Up! Hra na firmu
    • Navštivte Odoo
    Získat software
    • Stáhnout
    • Porovnejte edice
    • Verze
    Spolupráce
    • Github
    • Fórum
    • Události
    • Překlady
    • Stát se partnerem
    • Services for Partners
    • Registrujte svou účetní firmu
    Získat služby
    • Najít partnera
    • Najít účetní
    • Setkejte se s poradcem
    • Implementační služby
    • Zákaznické reference
    • Podpora
    • Upgrady
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Dohodnout demo
  • Ceník
  • Pomoc

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Účetnictví
  • Sklad
  • PoS
  • Projekty
  • MRP
All apps
You need to be registered to interact with the community.
All Posts Lidé Odznaky
Štítky (View all)
odoo accounting v14 pos v15
O tomto fóru
You need to be registered to interact with the community.
All Posts Lidé Odznaky
Štítky (View all)
odoo accounting v14 pos v15
O tomto fóru
Pomoc

How to setup Field Level Access Rights in an Object in Odoo 13

Odebírat

Get notified when there's activity on this post

This question has been flagged
securityfieldsusersgroupaccessrights
1 Odpovědět
10679 Zobrazení
Avatar
Bienvenido Villabroza

I am using Odoo 13 and I need to set field level access rights on the object level.

I have a Driver group and a Car object.

The Car object has three attributes: door_number, tire_brand, and bank_id.
I need the following:

1) door_number to be read only

2) tire_brand to be read and write only

3) band_id to be inaccessible to the Driver group.


I know I can edit the view as seen here: https://www.odoo.com/forum/help-1/question/how-to-apply-field-level-access-rights-for-user-19481
This would make the appropriate changes on the view level but the object access rights will not be affected. That would be a security risk.

I also know that I can set the accessible fields on the model itself as seen here: https://www.odoo.com/documentation/13.0/reference/security.html#field-access

However, that would take away both the read and write access rights of all groups unstated in the groups attribute. That will make my previously stated "1) door_number to be read only" impossible to do.

Is there a way to achieve my needs using Odoo 13? I need field level access rights.


1
Avatar
Zrušit
Avatar
Ray Carnes (ray)
Nejlepší odpověď

Did you try adding base.group_user to the groups attribute for each field that you want to be accessed by Internal Users (everyone)?

Every internal user is a member.

Then, set your read-only fields and add other groups where you only want specific groups to have access.

0
Avatar
Zrušit
Bienvenido Villabroza
Autor

I have not tried doing that. I was not aware that was an option. Thank you for sharing. However, what do you mean by "set your read-only fields?" Do you mean set them from my views? I would like the field (not just the form) to be secure from unauthorized access.

Ray Carnes (ray)

I mean use the READONLY (or STATES) attribute at the field level.

Bienvenido Villabroza
Autor

According to the documentation, "this only has an impact on the UI." https://www.odoo.com/documentation/13.0/reference/orm.html#fields

Is there a way of securing the system in the database level (not just the form level).

Ray Carnes (ray)

The documentation is meaning to convey that users have no way to set values for these fields directly (even by importing) but the API can still be used to give them a value - programatically. Odoo users don't have direct access to PostgreSQL. You only have to control database level access for users YOU give access to the database. If you mean the Odoo business object level, then GROUPS (which can be assigned at the field level) provide what you ask. See the "FIELD ACCESS" section of https://www.odoo.com/documentation/13.0/reference/security.html

Bienvenido Villabroza
Autor

You said that "the API can still be used to give them a value - programatically." I thought anyone can access the API? Or do they have to be a PostgreSQL user?

Also, for the link you sent, the documentation says "attempts to (explicitly) read from or write to restricted fields results in an access error." I can't distinguish from read and write with the groups attribute. I need that distinction.

Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Přihlásit se
Related Posts Odpovědi Zobrazení Aktivita
Keep Getting "The user cannot have more than one user types." Vyřešeno
security users group
Avatar
1
lis 21
6675
How to hide field from the specific user Vyřešeno
security fields hide group odoo12.0
Avatar
Avatar
1
úno 21
12997
Cannot save the custom group for users in user access rights in Odoo 13 Vyřešeno
security users group record_rules Odoo13.0
Avatar
Avatar
1
pro 19
4554
How to identify which access should give to the specific user as per below error?
security users operation odoo10 accessrights
Avatar
Avatar
1
srp 17
4717
Users & Group
users group
Avatar
Avatar
2
zář 22
4758
Komunita
  • Tutoriály
  • Dokumentace
  • Fórum
Open Source
  • Stáhnout
  • Github
  • Runbot
  • Překlady
Služby
  • Odoo.sh hostování
  • Podpora
  • Upgrade
  • Nestandardní vývoj
  • Edukační program
  • Najít účetní
  • Najít partnera
  • Stát se partnerem
O nás
  • Naše společnost
  • Podklady značky
  • Kontakujte nás
  • Práce
  • Události
  • Podcast
  • Blog
  • Zákazníci
  • Právní dokumenty • Soukromí
  • Zabezpečení
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo je balíček open-source aplikací, které pokrývají všechny potřeby vaší společnosti: CRM, e-shop, účetnictví, sklady, kasy, projektové řízení a další.

Unikátní nabídka od Odoo poskytuje velmi jednoduché uživatelské rozhraní a vše je integrované na jednom místě.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now