On the quotation, it shows {“TVA 20% - GC”: 20.0} in items table. I want to display only TAX DESCRIPTION.
Where you want to display this field, as this field is used for internal purpose to apply auto tax on item.
Thanks
On QUOTATION ITEM (item table on quotation) I want to display TAX ITEM DESCRIPTION (TVA 20%) or only ITEM TAX RATE (20.0)…
… and not {“TVA 20% - GC”: 20.0}
You can not make changes in the existing field, this will break the system. Create new custom field like “Tax Description” and write script to copy the data from item tax rate field to tax description field.
Thanks, Rohit
Tell me :
For you, Is it logical to display { "TVA 20% - GC»: 20,0} and not only the rate on a sales order document ? No ?
This field is used in calculation of taxes
We can not display it as (TVA 20%) or (20.0), because user can add more than one tax on item master.
But you can add custom script like
frappe.ui.form.on('Quotation', 'before_save', function(frm){
$.each(frm.doc.items, function(i, data){
if(data.item_tax_rate){
tax = JSON.parse(data.item_tax_rate)
for(key in tax){
frappe.model.set_value(data.doctype, data.name, "tax_description", key)
}
}
})
})
OUTPUT: -
Above code is for your reference, I hope you understand it
Thanks, Rohit
Thank You very much for your answer.
It work very fine :)))))
For more complexity ,
To greater complexity,
I have 4 companies that share the same products:
CG
C78
C91
C94
I created 4 taxes (10%) for each company:
TVA 10% - CG
TVA 10% - C78
TVA 10% - C91
TVA 10% - C94
For an article, I have selected the four taxes:
TVA 10% - CG
TVA 10% - C78
TVA 10% - C91
TVA 10% - C94
How to make the field “Tax Description” selects the tax for the concerned company ?
For transactions, it’s always the value entered in the Tax Description field only. Please setup your Sales/Purchase Taxes and other Charges and enter Tax Description based on value expected in the Print Format.