How to deal with tax in quotation with multi company option? - odoo

This question is about how to deal with tax in quotation with multi company option. Please take below scenario:
1) I have enabled multi companies feature and lets say I have 2 comapnies C1, C2.
2) I have two taxes T1(with company C1) and T2(with company C2).
3) I made products P1 with tax T1 and P2 with tax T2.
4) Consider I have set C1 as current company in the user settings.
5) Now, whenever I make Quotation and select both these products then, for P1 it shows tax in order line and for P2 it does not show taxes. It is so because I have set C1 as current company.
6) If i change current company in user settings from C1 to C2 then in the new quotation, now it will show tax for product P2 not for P1. It is so because I have set C2 as current company!!! i have to set the taxes manually for product P1.
How to get rid of this? I want to apply tax on the order line irrespective of the current company.

In Account Tax company field is available and required, when you create sale order line then system will set tax based on login user company.now let say if you select product P2 but if there is not any login user company tax available in product P2 then system will not set any tax in P2 product line.
You need to create two taxes for both company.
Ex : You should create tax T1/T2 for both company, so total there are four taxes in your system.two taxes per company.
In Product you can set multiple taxes.In product P1 you can set tax T1/T2 same in product P2 you can set tax T1/T2.
After that When you login with company C1 and add two products then system will set C1 company tax in both product lines. It will work for another company as well.
This may help you.

Related

Bigcommerce - Update Price of Products in Cart Based on Price List & Custom Fields

With Bigcommerce Price Lists, we obviously have the ability to give discounts based on bulk buys/qty.
We want to be able to combine the quantities of items in the cart if the products have a common custom field (or similar) and give the bulk price list discounts based on the combined qty.
For example:
Product A has a bulk purchase discount - buy 5+ and get 10% discount
Product B has a bulk purchase discount - buy 10+ and get 15% discount
Both these products would have a custom field/meta field at the variant level that = "Allow Combined Discount A"
So that means if Product A has a cart qty of 4, and product B has a cart qty of 6, the combined qty = 10
Product A should receive 10% discount (as combined qty >=5)
Product B should receive 15% discount (as combined qty >=10)
How can we achieve this? Ideally, the price updates/discounts would apply immediately when the cart quantities reach the correct levels. There could also be other products in the cart with different combining custom field/meta field values, which would need to calculate their own total - e.g. "Allow Combined Discount B"
Promotions on categories will not work as there are can be varients on products a and b where the bulk discounts do not apply, or the qty of some variants should not count towards a combined total to apply price list bulk buy discounts.

Odoo 10 how to calculate the total debt of partner

I would like to calculate the total debt of partner_id, with all his debit on every his invoice
as an example:
In Accounting\Customer Invoices I have a
when I click on bbb opens
when I click on the report, in my case Automatski racun
I want to enter in the field Vaš ukupan dug the total debt of all accounts that bbb has
And can you tell me how to iterate over all partner_id eg. in the Journal Items
Because I tried this way to get a total of bbb debt, but I did not know how to iterate
If I'm not clear enough or you need more information, please let me know
Here it is the code.
#api.onchange('partner_id')
def set_customer_credit(self):
self.custom_field = self.partner_id.credit

Perpetual Inventory Valuation- odoo 10

I created 3 chart of accounts as follow with type current asset:
23600 Stock Interim Account (Received)
14600 Stock Interim Account (Delivered)
14000 Stock Valuation Account
And assigned to product category.
Set costing method as Average and inventory valuation as Perpetual.
Created a purchase order and received products
Then system created journal entries as follow.
When i create an vendor invoice from same purchase order, in product lines it automatically choose 501100 Cost of Goods Sold in Trading instead of 23600 Stock Interim Account (Received).
Did i configure anything wrong?
How can i resolve this?

How to set a Price List if i want to put discount buy 2 get 1 free in Odoo 8?

For Example i want to put discount on different type of product(not same categories) and a specific product it's also a different type of category should be free..
other wise free product has price if customer want to bye single product at Point of sale
Example
Category A (product) Category B (Product) Category C (Product)
1(price) + 1(price) + 1 Free
Else Free product sale alone it should price

Designing a SSAS Cube with many to many reference table.

I have a table with the following schema.
Dim LocationProductsMapping Table (the key in this table is not used anywhere. It is just a primary key column. )
Key Location Products
XX A1 P1
XX A2 P2
XX A3 P3
XX A1 P2
XX A3 P2
* Dim Products (Say P1 , P2 , P3 as keys)
* Dim SellingMode (Say S1 , S2 , S3 as keys)
* Dim Shop (Shop1,Shop10,Shop100)
Fact Sales table
Product SellingMode Shop Revenue
P1 S1 Shop1 $100
P1 S2 Shop10 $400
P1 S1 Shop100 $100
P1 S3 Shop1 $100
P2 S2 Shop10 $400
P1 S1 Shop100 $100
P3 S3 Shop1 $100
Now I need to build a CUBE.
How should I create a dimension which should include My Location products mapping? (i.e, when I filter by Location, I should only get the following data of the location ).
Output
SellingMode1 $2000 Revenue 20 number of Products
SellingMode2 $3000 Revenue 25 number of products
I tried to create a hierarchy in Dimension like Location,ProductKey. But that doens't help. Values are not proper and filter condition is not applied.
I cannot change the table schema
LocationProductsMapping table is not included in the Datasource view automatically. ( I added this )
I don’t have the Dimension created for “LocationProductsMapping “, (understandable as this is the reference table)
I am not sure if you have a separate location table. If you have one, build a dimension from it, otherwise use the Location column from the LocationProductsMapping table to build the dimension.
Then create a new measure group from your LocationProductsMapping table. As Analysis Services cannot have measure groups without measures, use the count which the wizard normally suggests. Make this measure invisible, as it is not useful for users. Then on the "Dimension Usage" tab of cube designer, make sure your mapping measure group is related to the Product and Location dimensions, and set the relationship from the main measure group to location to "Many-to-many", selecting the mapping measure group.
And you are done. Analysis Services handles the rest for you.