[MIG] purchase_collective: Migration to 16.0

This commit is contained in:
Luis 2024-01-11 10:42:00 +01:00
parent 27386c71cc
commit 9434c90457
9 changed files with 7 additions and 16 deletions

View file

@ -19,7 +19,7 @@ El Usuario que crea la orden es el encargado de distribuir los productos al rest
'author': "Criptomart",
'website': "https://criptomart.net",
'category': 'Purchase Management',
'version': '0.12.0.1.0',
'version': "16.0.1.0.0",
'depends': ["purchase","sale","product","network_partner"],
'data': [
'security/purchase_collective_security.xml',

View file

@ -7,7 +7,6 @@ from operator import attrgetter
from odoo import models, fields, api, osv, _
from odoo.exceptions import Warning
from odoo.tools.safe_eval import safe_eval as eval
import odoo.addons.decimal_precision as dp
_logger = logging.getLogger(__name__)
@ -59,12 +58,10 @@ class PurchaseCollectiveOrder(models.Model):
return res
@api.multi
def subscribe(self, partner):
self.message_subscribe(partner_ids=[(partner.id)])
self.message_post(body=("Order line created by %s" %(partner.name)))
@api.multi
def button_details(self):
context = self.env.context.copy()
view_id = self.env.ref(

View file

@ -15,7 +15,6 @@ class SaleOrder(models.Model):
)
is_cp = fields.Boolean(string="Is part of a Collective Purchase")
@api.multi
def action_confirm(self):
for order in self:
order.warehouse_id = order.partner_id.node_id.wh_id

View file

@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<odoo>
<record model="ir.module.category" id="module_category_purchase_collective_management">
<field name="name">Collective Purchase</field>
@ -44,5 +43,4 @@
<field name="perm_unlink" eval="False"/>
<field name="perm_create" eval="True"/>
</record>
</data>
</openerp>
</odoo>

View file

@ -5,7 +5,6 @@
<field name="name">Open</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase_collective.order</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="context">{
'search_default_my_sale_orders_filter': 1
@ -22,7 +21,6 @@
<field name="name">Closed</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase_collective.order</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="context">{
'search_default_my_sale_orders_filter': 1
@ -39,7 +37,6 @@
<field name="name">Cancelled</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase_collective.order</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="context">{
'search_default_my_sale_orders_filter': 1

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="0">
<data>
<record id="view_partner_network_net_inherit_pc_form" model="ir.ui.view">
<field name="name">partner.net.form.wh.view</field>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="0">
<data>
<record id="view_partner_network_node_inherit_pc_form" model="ir.ui.view">
<field name="name">partner.node.form.wh.view</field>

View file

@ -1,5 +1,5 @@
<odoo>
<data noupdate="0">
<data>
<record id="purchase_collective_order_form_view" model="ir.ui.view">
<field name="name">purchase.collective.order.form.view</field>

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="0">
<data>
<record id="view_form_sale_order_cp" model="ir.ui.view">
<field name="name">sale order collective purchase extension</field>
<field name="model">sale.order</field>