mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
16 lines
488 B
Python
16 lines
488 B
Python
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
|
# Copyright 2017 Serpent Consulting Services Pvt. Ltd.
|
|
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
|
|
|
|
from odoo import SUPERUSER_ID
|
|
from odoo.api import Environment
|
|
|
|
|
|
def post_init_hook(cr, pool):
|
|
"""
|
|
Fetches all the sale order and resets the sequence of the order lines
|
|
"""
|
|
env = Environment(cr, SUPERUSER_ID, {})
|
|
sale = env['sale.order'].search([])
|
|
sale._reset_sequence()
|