How to send mail automatically while creating new vendor bill or customer invoice in odoo - odoo

Hello everyone I have a custom accounting module inherits from odoo accounting module. I have created a budget and a budget has someone responsible for, and an analytic account related to this budget. I want to create vendor bills and customer invoices based on an analytic account related to the specific budget and I want to send an email notification message to the person responsible for the budget in his email when I create a new bill or invoice to notify him that with a message ( new bill has been created you need to validate it).

You can use automated actions:
Configure the outgoing email server.
Set the email of the related partner to the user who creates the invoice and the same for the responsible.
Install the base_automation module.
Create an automated action which will trigger the invoice creation:
Go to Technical / Automation / Automated Actions and create new action.
For example:
name: Email responsible
Model: Invoice
Action To Do: Send email
Email Template: Invoicing: Invoice email
Trigger Condition: On Creation
You may duplicate the Invoice email template and change the To (Partners) to the responsible.

Related

Please define account for the produce: "Product name" (id:4)

I installed Odoo Community v15.0-20211005 recently and while learning it ,I keep on coming across this error
Please define account for the produce: "Product name" (id:4)
whenever I try to close a session after a sale.
Each product in Odoo linked to Product Category and you need to specify the Income/Expense accounts either in Product category or Product itself.
Go to the Inventory app -> Configuration then product categories and you have to open each category and make sure the Income/Expense accounts is set.
Income Account: This account to be used to validate the invoices of the customer.
Expense Account: This account to be to used when the vendor bill is prepared.
If you want to set Income/Expense accounts for a product to be different from his product category accounts, Open the product and in Accounting tab you can set Income/Expense accounts for the product and these accounts will override the category accounts when sell/purchase this prduct.

Giving Employee usergroup access to custom module - Odoo

I have created a module named Purchases containing menu item: Purchasesand views: Received purchases, Pending purchases and want to give access to this module to only the Employees\Employee.
I have created a new user with email emp1#gmail.com from the Settings and added it to user group Employees\Employee. I have given the Employees\Employee group access rights to the Purchases, Received purchases and Pending purchases views.
When I log in as the employee emp1#gmail.com I still do not get the Menu Item Purchases. I only get the Settings and Discuss menu items.
I got it wrong. It seems that I should have added that model to the access rights first and give permission to view,read,write,delete. Thanks.

Retrieval of all the invoices of particular contact id in xero

In xero, if we create a contact. Using that contact we perform couple of sales invoice and purchase bills and few of them get paid. Now I want to obtain the list of the invoices groupedBy ContactID in php
Xero have recently released functionality that allows this in an easy way.
You can use the ContactIDs query parameter on the invoices endpoint like the following:
GET ../Invoices?ContactIDs=623e392d-7402-40e4-a54c-fdf29783e9a4
You can also do this for more than one ContactID by supplying a comma separated list of ContactIDs.
You can find more information about this in this handy blog post

Dropship in Odoo

How to configure Dropship in Odoo. I just downloaded the module from the Sales DropShip. But I don`t know how to configure that module. Is there any method for dropshipping. Any help would be appreciated.
Drop-shipping means while delivering the goods, you don't deliver it from the stock, but instead you place an order to supplier (purchase order) and ask them to directly delivery those goods to the customer. So goods doesn't physically comes to your warehouse/company and directly gets delivered to customer from supplier. When the purchase order (which will automatically gets created from the sales order) gets received the sales order automatically gets into the "Done" state.
For configuring it in Odoo, following are the steps:
Install Drop Shipping Module.
On installation it will create a new picking names "Dropship" where you will find the default source location as "Supplier" and default destination location as "Customer"
Also, it will create route which will have a pull rule from Supplier -> Customer
Under the Settings -> Configuration -> Sales -> Sales Features - Select the option "Choose MTO, drop shipping,... on sales order lines", which will allow to select the route on the sale order lines while creating the sales order.
Now, for testing create a product and do the following configuration
Under the route select "Make to order"
Define the supplier for the product
Create the sales order and while entering the sale order lines select the route as "Dropshipping" and confirm it, which will generate the purchase order based on the route, for the supplier defined in the product's supplier info. When you will receive goods in the purchase order, it will take the sales order into the done state. Now you will able to see a button labeled "View Delivery Order" which will take you to delivery order with name prefix as "DS..."
In the purchase order generated, check under the "Deliveries and Invoices" tab, you will find the destination location as "Customer" location.
Note:-
Also, under the Purhcase configuration from setting, if you check the option "Routes - Manage Dropshipping", it will install the dropshipping module.
Hope this helps!!.
It is very simple for the configuration.
Steps are here:
Install Drop Shipping Module.
create a new picking names "Dropship" where you will find the default source location as "Supplier" and default destination location as "Customer"
Under the Settings -> Configuration -> Sales -> Sales Features - Select the option "Choose MTO, drop shipping,... on sales order lines",
Now, for testing create a product and do the following configuration
Still getting issue than, Here I am sharing few post those will help you step by step:
Dropship in Odoo
DropShipping

how create a rule for user can only see their own customers in openerp

I need to create a rule to a user can only see their own customers (SALES / CUSTOMERS in OpenERP menu), similar at rules "personal phone calls" or "personal initiative" in the "Sales / User: Own Leads Only".
I have resolved (partially) the problem with a duplicated group from SALES / USER: OWN LEADS ONLY group, and I have added a new rule based on "res_partner: access (read) on my partner" with the same DOMAIN and I have modified this rule to grant access to read, write, create and delete and now a user only can see his partners but now, when I try create a new partner, like a contact or company, I cant, because the system tell me access denied (document type: partner and action create). I dont know why can't create a new partner.
My version OpenERP is 7.0
Can anyone help me?
Thanks!
Mc
You need to use this domain in your new record rule:
['|',('user_id','=',False),('user_id','=',user.id)]
After setting this domain in your record rule, save it and again check your scenario.
By applying this domain, You will see your own customers as well as the customers, in which, there is no Salesperson defined. If possible, define salesperson for every customer so it will give you the exact result that you want.