Overslaan naar inhoud
Odoo Menu
  • Aanmelden
  • Probeer het gratis
  • Apps
    Financiën
    • Boekhouding
    • Facturatie
    • Onkosten
    • Spreadsheet (BI)
    • Documenten
    • Ondertekenen
    Verkoop
    • CRM
    • Verkoop
    • Kassasysteem winkel
    • Kassasysteem Restaurant
    • Abonnementen
    • Verhuur
    Websites
    • Websitebouwer
    • E-commerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Bevoorradingsketen
    • Voorraad
    • Productie
    • PLM
    • Inkoop
    • Onderhoud
    • Kwaliteit
    Personeelsbeheer
    • Werknemers
    • Werving & Selectie
    • Verlof
    • Evaluaties
    • Aanbevelingen
    • Wagenpark
    Marketing
    • Social media Marketing
    • E-mailmarketing
    • SMS Marketing
    • Evenementen
    • Marketingautomatisering
    • Enquêtes
    Diensten
    • Project
    • Urenstaten
    • Buitendienst
    • Helpdesk
    • Planning
    • Afspraken
    Productiviteit
    • Chat
    • Goedkeuringen
    • IoT
    • VoIP
    • Kennis
    • WhatsApp
    Apps van derden Odoo Studio Odoo Cloud Platform
  • Bedrijfstakken
    Detailhandel
    • Boekhandel
    • kledingwinkel
    • Meubelzaak
    • Supermarkt
    • Bouwmarkt
    • Speelgoedwinkel
    Food & Hospitality
    • Bar en Pub
    • Restaurant
    • Fastfood
    • Gastenverblijf
    • Drankenhandelaar
    • Hotel
    Vastgoed
    • Makelaarskantoor
    • Architectenbureau
    • Bouw
    • Vastgoedbeheer
    • Tuinieren
    • Vereniging van eigenaren
    Consulting
    • Accountantskantoor
    • Odoo Partner
    • Marketingbureau
    • Advocatenkantoor
    • Talentenwerving
    • Audit & Certificering
    Productie
    • Textiel
    • Metaal
    • Meubels
    • Eten
    • Brewery
    • Relatiegeschenken
    Gezondheid & Fitness
    • Sportclub
    • Opticien
    • Fitnesscentrum
    • Wellness-medewerkers
    • Apotheek
    • Kapper
    Trades
    • Klusjesman
    • IT-hardware & support
    • Zonne-energiesystemen
    • Schoenmaker
    • Schoonmaakdiensten
    • HVAC-diensten
    Andere
    • Non-profit organisatie
    • Milieuagentschap
    • Verhuur van Billboards
    • Fotograaf
    • Fietsleasing
    • Softwareverkoper
    Browse all Industries
  • Community
    Leren
    • Tutorials
    • Documentatie
    • Certificeringen
    • Training
    • Blog
    • Podcast
    Versterk het onderwijs
    • Onderwijs- programma
    • Scale Up! Business Game
    • Bezoek Odoo
    Download de Software
    • Downloaden
    • Vergelijk edities
    • Releases
    Werk samen
    • Github
    • Forum
    • Evenementen
    • Vertalingen
    • Word een Partner
    • Services for Partners
    • Registreer je accountantskantoor
    Diensten
    • Vind een partner
    • Vind een boekhouder
    • Een adviseur ontmoeten
    • Implementatiediensten
    • Klantreferenties
    • Ondersteuning
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Vraag een demo aan
  • Prijzen
  • Help

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

  • CRM
  • e-Commerce
  • Boekhouding
  • Voorraad
  • PoS
  • Project
  • MRP
All apps
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Alle posts Personen Badges
Labels (Bekijk alle)
odoo accounting v14 pos v15
Over dit forum
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Alle posts Personen Badges
Labels (Bekijk alle)
odoo accounting v14 pos v15
Over dit forum
Help

add field in kanban view, account_invoice_line

Inschrijven

Ontvang een bericht wanneer er activiteit is op deze post

Deze vraag is gerapporteerd
1 Beantwoorden
4781 Weergaven
Avatar
GiancaFTx

Good night,

I am trying to replace the view: (o_kanban_mobil) but the change is not applied, it is installed without error but it is not visualized that it may be missing?

release: odoo12, column you want to add: (new_field)

thanks,

   <record model="ir.ui.view" id="e.view_account_invoice_events">

            <field name="name">Cambios en al vista de formulario de Invoice</field>

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

            <field name="inherit_id" ref="account.invoice_form"/>

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

                       

                <xpath expr="//kanban[@class='o_kanban_mobile']" position="replace">       

                                    <field name="name"/>

                                    <field name="product_id"/>

                                    <field name="price_subtotal" groups="account.group_show_line_subtotals_tax_excluded"/>

                                    <field name="price_total" groups="account.group_show_line_subtotals_tax_included"/>

                                    <field name="quantity"/>

                                    <field name="uom_id" groups="uom.group_uom"/>

                                    <field name="price_unit"/>

                                    <field name="new_field" />

                                    <field name="display_type"/>

                                    <templates>

                                        <t t-name="kanban-box">

                                            <div t-attf-class="oe_kanban_card oe_kanban_global_click {{ record.display_type.raw_value ? 'o_is_' + record.display_type.raw_value : '' }}">

                                                <t t-if="!record.display_type.raw_value">

                                                    <div class="row">

                                                        <div class="col-8">

                                                            <strong>

                                                                <span>

                                                                    <t t-esc="record.product_id.value"/>

                                                                </span>

                                                            </strong>

                                                        </div>

                                                        <div class="col-4">

                                                            <strong>

                                                                <span class="float-right text-right">

                                                                    <t t-esc="record.price_subtotal.value" groups="account.group_show_line_subtotals_tax_excluded"/>

                                                                    <t t-esc="record.price_total.value" groups="account.group_show_line_subtotals_tax_included"/>

                                                                </span>

                                                            </strong>

                                                        </div>

                                                    </div>

                                                    <div class="row">

                                                        <div class="col-12 text-muted">

                                                            <span>

                                                                Quantity:

                                                                <t t-esc="record.quantity.value"/>

                                                                <t t-esc="record.uom_id.value"/>

                                                            </span>

                                                        </div>

                                                    </div>

                                                    <div class="row">

                                                        <div class="col-12 text-muted">

                                                            <span>

                                                                Unit Price:

                                                                <t t-esc="record.price_unit.value"/>

                                                            </span>

                                                        </div>

                                                    </div>

                                                 <div class="row">

                                                        <div class="col-12 text-muted">

                                                            <span>

                                                                Descuento:

                                                                <t t-esc="record.new_field.value"/>

                                                            </span>

                                                        </div>

                                                    </div>


                                                </t>

                                                <t t-if="record.display_type.raw_value === 'line_section' || record.display_type.raw_value === 'line_note'">

                                                    <div class="row">

                                                        <div class="col-12">

                                                            <span>

                                                                <t t-esc="record.name.value"/>

                                                            </span>

                                                        </div>

                                                    </div>

                                                </t>

                                            </div>

                                        </t>

                                    </templates>


                </xpath>  

 </record>


0
Avatar
Annuleer
Avatar
Keval Mehta
Beste antwoord

If you replace the existing element then you need to start from that element in your view only. For example in your case you replace kanban tag from base then in your custom code you need to start from that tag only. So your code will be something like this : 

<xpath expr="//kanban[@class='o_kanban_mobile']" position="replace">
    <kanban class="o_kanban_mobile">
        // your code
    </kanban>

0
Avatar
Annuleer
GiancaFTx
Auteur

Hello, I made the change as indicated and it is not reflected, is there another coast that should be done ?, the model to inherit is ?: <field name = "model"> account.invoice </field>

<field name = "inherit_id" ref = "account.invoice_form" />

****************

field add: descuento_unitario

<xpath expr="//kanban[@class='o_kanban_mobile']" position="replace">

<kanban class="o_kanban_mobile">

<field name="name"/>

<field name="product_id"/>

<field name="price_subtotal" groups="account.group_show_line_subtotals_tax_excluded"/>

<field name="price_total" groups="account.group_show_line_subtotals_tax_included"/>

<field name="quantity"/>

<field name="uom_id" groups="uom.group_uom"/>

<field name="price_unit"/>

<field name="descuento_unitario" />

<field name="display_type"/>

<templates>

<t t-name="kanban-box">

<div t-attf-class="oe_kanban_card oe_kanban_global_click {{ record.display_type.raw_value ? 'o_is_' + record.display_type.raw_value : '' }}">

<t t-if="!record.display_type.raw_value">

<div class="row">

<div class="col-8">

<strong>

<span>

<t t-esc="record.product_id.value"/>

</span>

</strong>

</div>

<div class="col-4">

<strong>

<span class="float-right text-right">

<t t-esc="record.price_subtotal.value" groups="account.group_show_line_subtotals_tax_excluded"/>

<t t-esc="record.price_total.value" groups="account.group_show_line_subtotals_tax_included"/>

</span>

</strong>

</div>

</div>

<div class="row">

<div class="col-12 text-muted">

<span>

Quantity:

<t t-esc="record.quantity.value"/>

<t t-esc="record.uom_id.value"/>

</span>

</div>

</div>

<div class="row">

<div class="col-12 text-muted">

<span>

Unit Price:

<t t-esc="record.price_unit.value"/>

</span>

</div>

</div>

<div class="row">

<div class="col-12 text-muted">

<span>

Descuento:

<t t-esc="record.descuento_unitario.value"/>

</span>

</div>

</div>

</t>

<t t-if="record.display_type.raw_value === 'line_section' || record.display_type.raw_value === 'line_note'">

<div class="row">

<div class="col-12">

<span>

<t t-esc="record.name.value"/>

</span>

</div>

</div>

</t>

</div>

</t>

</templates>

</kanban>

</xpath>

Geniet je van het gesprek? Blijf niet alleen lezen, doe ook mee!

Maak vandaag nog een account aan om te profiteren van exclusieve functies en deel uit te maken van onze geweldige community!

Aanmelden
Community
  • Tutorials
  • Documentatie
  • Forum
Open Source
  • Downloaden
  • Github
  • Runbot
  • Vertalingen
Diensten
  • Odoo.sh Hosting
  • Ondersteuning
  • Upgrade
  • Gepersonaliseerde ontwikkelingen
  • Onderwijs
  • Vind een boekhouder
  • Vind een partner
  • Word een Partner
Over ons
  • Ons bedrijf
  • Merkelementen
  • Neem contact met ons op
  • Vacatures
  • Evenementen
  • Podcast
  • Blog
  • Klanten
  • Juridisch • Privacy
  • Beveiliging
الْعَرَبيّة 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 is een suite van open source zakelijke apps die aan al je bedrijfsbehoeften voldoet: CRM, E-commerce, boekhouding, inventaris, kassasysteem, projectbeheer, enz.

Odoo's unieke waardepropositie is om tegelijkertijd zeer gebruiksvriendelijk en volledig geïntegreerd te zijn.

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