تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
4 الردود
6094 أدوات العرض

I have tried Access control and record rules. It works perfectly.

But i cant control field level access.

For example i want to control access to product name field alone.

And is it possible from UI like access control and record rules. ?

i refereed here https://www.odoo.com/documentation/8.0/reference/security.html

الصورة الرمزية
إهمال
أفضل إجابة

I think this example will helpful to you

<field name="company_id" groups="base.group_multi_company"> 
<field name="groups_id" eval="[(4, ref('event.group_event_user'))]"/>
الصورة الرمزية
إهمال
الكاتب أفضل إجابة

Thanks for your reply . let me try. how set access like read,write,create,delete.


  Is it possible control from UI like access control and record rules. ?


Instead Editing code. i need in UI just like ACL or Record Rules

Thanks @ Ankit Gauri . But this is not im asking . . asking UI like adding ACL to some group.

Let say. the group should list all fields . i have to assign which field are read only and write only from  UI

الصورة الرمزية
إهمال

yes, enable developer mode and edit your form view such that you can change the form view at UI itself

أفضل إجابة

hello Sankar

you can make a field readonnly for particular group of user like this in Ui


<record id="view_readonly" model="ir.ui.view">

<field name="name">model.form.readonly manager</field>

<field name="model">model.name</field> 

<field name="groups_id" eval="[(6, 0, [ref(groups')])]"/>

<field name="arch" type="xml">

<field name="field" position="attributes">

<attribute name="readonly" >0</attribute>

</field>

</field>

</record>

it works perfectly i have used in my Ui and make a field readonly for user


Thank you

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
Prevent Deletion تم الحل
2
مايو 24
2507
1
يوليو 17
5354
2
أغسطس 25
2547
1
يوليو 25
961
1
أغسطس 25
1151