Skip ke Konten
Odoo Menu
  • Login
  • Uji coba gratis
  • Aplikasi
    Keuangan
    • Akuntansi
    • Faktur
    • Pengeluaran
    • Spreadsheet (BI)
    • Dokumen
    • Tanda Tangan
    Sales
    • CRM
    • Sales
    • POS Toko
    • POS Restoran
    • Langganan
    • Rental
    Website
    • Website Builder
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Rantai Pasokan
    • Inventaris
    • Manufaktur
    • PLM
    • Purchase
    • Maintenance
    • Kualitas
    Sumber Daya Manusia
    • Karyawan
    • Rekrutmen
    • Cuti
    • Appraisal
    • Referensi
    • Armada
    Marketing
    • Social Marketing
    • Email Marketing
    • SMS Marketing
    • Acara
    • Otomatisasi Marketing
    • Survei
    Layanan
    • Project
    • Timesheet
    • Layanan Lapangan
    • Meja Bantuan
    • Planning
    • Appointment
    Produktivitas
    • Diskusi
    • Approval
    • IoT
    • VoIP
    • Pengetahuan
    • WhatsApp
    Aplikasi pihak ketiga Odoo Studio Platform Odoo Cloud
  • Industri-Industri
    Retail
    • Toko Buku
    • Toko Baju
    • Toko Furnitur
    • Toko Kelontong
    • Toko Hardware
    • Toko Mainan
    Makanan & Hospitality
    • Bar dan Pub
    • Restoran
    • Fast Food
    • Rumah Tamu
    • Distributor Minuman
    • Hotel
    Real Estate
    • Agensi Real Estate
    • Firma Arsitektur
    • Konstruksi
    • Estate Management
    • Perkebunan
    • Asosiasi Pemilik Properti
    Konsultansi
    • Firma Akuntansi
    • Mitra Odoo
    • Agensi Marketing
    • Firma huku
    • Talent Acquisition
    • Audit & Sertifikasi
    Manufaktur
    • Tekstil
    • Logam
    • Perabotan
    • Makanan
    • Brewery
    • Corporate Gift
    Kesehatan & Fitness
    • Sports Club
    • Toko Kacamata
    • Fitness Center
    • Wellness Practitioners
    • Farmasi
    • Salon Rambut
    Perdagangan
    • Handyman
    • IT Hardware & Support
    • Sistem-Sistem Energi Surya
    • Pembuat Sepatu
    • Cleaning Service
    • Layanan HVAC
    Lainnya
    • Organisasi Nirlaba
    • Agen Lingkungan
    • Rental Billboard
    • Fotografi
    • Penyewaan Sepeda
    • Reseller Software
    Browse semua Industri
  • Komunitas
    Belajar
    • Tutorial-tutorial
    • Dokumentasi
    • Sertifikasi
    • Pelatihan
    • Blog
    • Podcast
    Empower Education
    • Program Edukasi
    • Game Bisnis 'Scale Up!'
    • Kunjungi Odoo
    Dapatkan Softwarenya
    • Download
    • Bandingkan Edisi
    • Daftar Rilis
    Kolaborasi
    • Github
    • Forum
    • Acara
    • Terjemahan
    • Menjadi Partner
    • Layanan untuk Partner
    • Daftarkan perusahaan Akuntansi Anda.
    Dapatkan Layanan
    • Temukan Mitra
    • Temukan Akuntan
    • Temui penasihat
    • Layanan Implementasi
    • Referensi Pelanggan
    • Bantuan
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Dapatkan demo
  • Harga
  • Bantuan

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

  • CRM
  • e-Commerce
  • Akuntansi
  • Inventaris
  • PoS
  • Project
  • MRP
All apps
Anda harus terdaftar untuk dapat berinteraksi di komunitas.
Semua Post Orang Lencana-Lencana
Label (Lihat semua)
odoo accounting v14 pos v15
Mengenai forum ini
Anda harus terdaftar untuk dapat berinteraksi di komunitas.
Semua Post Orang Lencana-Lencana
Label (Lihat semua)
odoo accounting v14 pos v15
Mengenai forum ini
Help

Beginner question about functional fields and property fields?

Langganan

Dapatkan notifikasi saat terdapat aktivitas pada post ini

Pertanyaan ini telah diberikan tanda
function_fieldproperty.fields
2 Replies
13636 Tampilan
Avatar
odooopenerp

Anyone tell me what is fnct_search, fnct_inv in fucntion field and what is prorperty field? 

0
Avatar
Buang
Avatar
Dhinesh
Jawaban Terbai

Property Fields:
A property is a special field declared as fields.property. It is also called as multi-company field. In database it will not be stored as normal field in respective object table. It will be stored in separate special table called ir_property table.

The fields.property class inherits from fields.function and overrides the read and write method.

When to use it?
Consider 2 companies Company A and Company B.

Company A (US chart of account) - User1
Company B (Indian chart of account) - User2

Each company has its own chart of account. In this case we will use AR and AP as property fields in partner object.

When user1 login and create a customer, he will have AR (Account receivable) and AP (Account payable) as default based on Company A chart of account.

When user2 login and create a customer, he will have AR (Deptors) and AP (Creditors) as default based on Company B chart of account.

The same field acts as different based on the users company. If no value is specified it will return the default value if specified.

The same partner may have different account receivable values depending on the company the user belongs to. When you read a property, the program gives you the property attached to the instance of object you are reading. If this object has no value, the system will give you the default property.

You can ask we can use many2one field. But many2one field values are static and it will not change based on user company.

One interesting thing is:
Properties avoid "spaghetti" code. That means the account module depends on the partner (base) module. But you can install the partner (base) module without the accounting module. If you add a normal field that points to an account in the partner object, both objects will depend on each other. It's much more difficult to maintain and code (for instance, try to remove a table when both tables are pointing to each others.)

One more thing:
In v8, property fields has been deprecated. It was no more called fields.property. Now we can pass it as a boolean parameter for all the fields. company_dependent – whether the field is company-dependent (boolean)

Important columns in db:
name: By convention fields are named as property_field_name. Eg. "property_account_receivable",
type: Eg. "many2one",
company_id: company id,
fields_id: id of field from ir_model_fields,
value_reference: Eg. "account.account,72" (Object relation with id. Stores reference, Different from usual many2one which saves the id only)
res_id: Eg. "res.partner,86" (Object where the field is declared with id). If it is not set, this property will be used as default for all.

For Detailed description link.

Functional Fields:

A functional field is a field whose value is calculated by a function (rather than being stored in the database).

Parameters:

fnct, arg=None, fnct_inv=None, fnct_inv_arg=None, type="float", fnct_search=None, obj=None, method=False, store=False, multi=False

where

  • fnct is the function or method that will compute the field value. It must have been declared before declaring the functional field.

  • fnct_inv is the function or method that will allow writing values in that field.

  • type is the field type name returned by the function. It can be any field type name except function.

  • fnct_search allows you to define the searching behaviour on that field.

  • method whether the field is computed by a method (of an object) or a global function

  • store If you want to store field in database or not. Default is False.

  • multi is a group name. All fields with the same multi parameter will be calculated in a single function call.

5
Avatar
Buang
LaoThai

So how can we get the value of property field? ex: standard_price of product?

Avatar
Zbik
Jawaban Terbai

The best answer can be found in the documentation.

0
Avatar
Buang
Menikmati diskusi? Jangan hanya membaca, ikuti!

Buat akun sekarang untuk menikmati fitur eksklufi dan agar terlibat dengan komunitas kami!

Daftar
Post Terkait Replies Tampilan Aktivitas
Extracting Customer price lists cross reference
property.fields
Avatar
0
Jun 16
4184
Property Field: You need edit access on the parent document to update these property fields
crm property.fields
Avatar
0
Des 24
1853
Onchange function
onchange function_field
Avatar
Avatar
1
Agu 22
3113
How to check changed compute fields ?(store=True)
onchange function_field
Avatar
0
Des 20
3884
Calculate two fields with on function
method function_field
Avatar
Avatar
1
Apr 19
8014
Komunitas
  • Tutorial-tutorial
  • Dokumentasi
  • Forum
Open Source
  • Download
  • Github
  • Runbot
  • Terjemahan
Layanan
  • Odoo.sh Hosting
  • Bantuan
  • Peningkatan
  • Custom Development
  • Pendidikan
  • Temukan Akuntan
  • Temukan Mitra
  • Menjadi Partner
Tentang Kami
  • Perusahaan kami
  • Aset Merek
  • Hubungi kami
  • Tugas
  • Acara
  • Podcast
  • Blog
  • Pelanggan
  • Hukum • Privasi
  • Keamanan
الْعَرَبيّة 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 adalah rangkaian aplikasi bisnis open source yang mencakup semua kebutuhan perusahaan Anda: CRM, eCommerce, akuntansi, inventaris, point of sale, manajemen project, dan seterusnya.

Mudah digunakan dan terintegrasi penuh pada saat yang sama adalah value proposition unik Odoo.

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