size
int64
0
304k
ext
stringclasses
1 value
lang
stringclasses
1 value
branch
stringclasses
1 value
content
stringlengths
0
304k
avg_line_length
float64
0
238
max_line_length
int64
0
304k
584
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class FleetVehicleAssignationLog(models.Model): _name = "fleet.vehicle.assignation.log" _description = "Drivers history on a vehicle" _order = "create_date desc, date_start d...
38.933333
584
20,940
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from dateutil.relativedelta import relativedelta from odoo import api, fields, models, _ from odoo.osv import expression from odoo.addons.fleet.models.fleet_vehicle_model import FUEL_TYPES #Some fields don't have the ...
55.543767
20,940
431
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class FleetVehicleTag(models.Model): _name = 'fleet.vehicle.tag' _description = 'Vehicle Tag' name = fields.Char('Tag Name', required=True, translate=True) color = field...
30.785714
431
366
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class ResConfigSettings(models.TransientModel): _inherit = ['res.config.settings'] delay_alert_contract = fields.Integer(string='Delay alert contract outdated', default=30, conf...
36.6
366
352
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class ResPartner(models.Model): _inherit = 'res.partner' plan_to_change_car = fields.Boolean('Plan To Change Car', default=False) plan_to_change_bike = fields.Boolean('Plan ...
32
352
7,365
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from dateutil.relativedelta import relativedelta from odoo import api, fields, models class FleetVehicleLogContract(models.Model): _inherit = ['mail.thread', 'mail.activity.mixin'] _name = 'fleet.vehicle.log.c...
49.763514
7,365
1,228
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models class FleetVehicleOdometer(models.Model): _name = 'fleet.vehicle.odometer' _description = 'Odometer log for a vehicle' _order = 'date desc' name = fields.Char(compu...
38.375
1,228
477
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class FleetVehicleModelCategory(models.Model): _name = 'fleet.vehicle.model.category' _description = 'Category of the model' _order = 'sequence asc, id asc' _sql_constra...
28.058824
477
5,199
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from psycopg2 import sql from odoo import tools from odoo import api, fields, models class FleetReport(models.Model): _name = "fleet.vehicle.cost.report" _description = "Fleet Analysis Report" _auto = False...
33.11465
5,199
557
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Mass mailing on lead / opportunities', 'category': 'Hidden', 'version': '1.0', 'summary': 'Add lead / opportunities UTM info on mass mailing', 'description': """UTM and mass mailing on lead...
29.315789
557
294
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class UtmCampaign(models.Model): _inherit = 'utm.campaign' ab_testing_winner_selection = fields.Selection(selection_add=[('crm_lead_count', 'Leads')])
29.4
294
209
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class CrmLead(models.Model): _inherit = 'crm.lead' _mailing_enabled = True
23.222222
209
2,019
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models, _, tools class MassMailing(models.Model): _name = 'mailing.mailing' _inherit = 'mailing.mailing' use_leads = fields.Boolean('Use Leads', compute='_compute_use_leads') c...
43.891304
2,019
695
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Colombian - Point of Sale', 'icon': '/l10n_co/static/description/icon.png', 'version': '1.0', 'description': """Colombian - Point of Sale""", 'category': 'Accounting/Localizations/Point of ...
25.740741
695
391
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Google Users', 'category': 'Hidden/Tools', 'description': """ The module adds google user in res user. ======================================== """, 'depends': ['base_setup'], 'data': [ ...
24.4375
391
8,704
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import datetime import json import logging import requests from werkzeug import urls from odoo import api, fields, models, _ from odoo.exceptions import UserError _logger = logging.getLogger(__name__) T...
43.089109
8,704
1,376
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import json from werkzeug.exceptions import BadRequest from odoo import http from odoo.http import request class GoogleAuth(http.Controller): @http.route('/google_account/authentication', type='http', auth="publi...
43
1,376
6,485
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Inventory', 'version': '1.1', 'summary': 'Manage your stock and logistics activities', 'description': "", 'website': 'https://www.odoo.com/app/inventory', 'depends': ['product', 'barcod...
43.233333
6,485
30,335
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging import math from datetime import datetime, timedelta from itertools import product as cartesian_product from collections import defaultdict from odoo import models, api from odoo.tools import populate, gr...
49.325203
30,335
772
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models from odoo.tools import populate class ProductProduct(models.Model): _inherit = 'product.product' def _populate_get_types(self): types, types_distribution = super()._populate_get...
30.88
772
12,151
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.mail.tests.common import mail_new_test_user from odoo.tests.common import Form, TransactionCase from odoo.exceptions import AccessError, UserError class TestEditableQuant(TransactionCase): @classme...
41.050676
12,151
8,700
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tests.common import TransactionCase class TestWiseOperator(TransactionCase): def test_wise_operator(self): # Create a new storable product product_wise = self.env['product.product'].crea...
45.789474
8,700
604
py
PYTHON
15.0
# Part of Odoo. See LICENSE file for full copyright and licensing details. import odoo from odoo.tests import Form, HttpCase, tagged @tagged('-at_install', 'post_install') class TestStockReportTour(HttpCase): def setUp(self): super().setUp() def _get_report_url(self): return '/web#&model=prod...
31.789474
604
9,728
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.exceptions import UserError, ValidationError from odoo.tests.common import TransactionCase class TestRobustness(TransactionCase): @classmethod def setUpClass(cls): super(TestRobustness, cls).s...
37.272031
9,728
24,607
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import date, datetime, timedelta from dateutil.relativedelta import relativedelta from odoo.exceptions import ValidationError from odoo.tests.common import Form, TransactionCase class TestInventory(Transa...
47.230326
24,607
41,457
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from contextlib import closing from datetime import datetime, timedelta from unittest.mock import patch from odoo import fields from odoo.addons.mail.tests.common import mail_new_test_user from odoo.exceptions import Va...
50.068841
41,457
10,603
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import datetime, timedelta from odoo import fields, tests from odoo.tests.common import Form class TestReportStockQuantity(tests.TransactionCase): def setUp(self): super().setUp() sel...
43.633745
10,603
86,515
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import date, datetime, timedelta from odoo.tests.common import Form, TransactionCase class TestReportsCommon(TransactionCase): @classmethod def setUpClass(cls): super().setUpClass() ...
52.688794
86,515
280,852
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.exceptions import UserError from odoo.tests import Form from odoo.tests.common import TransactionCase class StockMove(TransactionCase): @classmethod def setUpClass(cls): super(StockMove, cls)....
46.878985
280,852
127,356
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo.addons.stock.tests.common import TestStockCommon from odoo.exceptions import ValidationError from odoo.tests import Form from odoo.tools import mute_logger, float_round from odoo import fields class TestStockFlow(TestStockCommon): def setUp(cls): super(TestStockFlow, cls...
55.882405
127,356
12,461
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Author: Leonardo Pistone # Copyright 2015 Camptocamp SA from odoo.addons.stock.tests.common2 import TestStockCommon from odoo.exceptions import UserError from odoo.tests.common import Form class TestVirtualAvailable...
44.663082
12,461
4,841
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo.tests import common class TestStockCommon(common.TransactionCase): @classmethod def setUpClass(cls): super(TestStockCommon, cls).setUpClass() cls.ProductObj = cls.env['product.product'] cls.UomObj = cls.env['uom.uom'] cls.PartnerObj = cls.env...
49.907216
4,841
29,354
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo.addons.stock.tests.common2 import TestStockCommon from odoo.tests import Form from odoo.exceptions import UserError from odoo.tools import mute_logger class TestWarehouse(TestStockCommon): def setUp(self): super(TestWarehouse, self).setUp() self.partner = self.e...
46.742038
29,354
2,515
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo.addons.stock.tests.common import TestStockCommon class TestReturnPicking(TestStockCommon): def test_stock_return_picking_line_creation(self): StockReturnObj = self.env['stock.return.picking'] picking_out = self.PickingObj.create({ 'picking_type_id': ...
50.3
2,515
71,868
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tests import Form from odoo.tests.common import TransactionCase from odoo.tools import float_round from odoo.exceptions import UserError class TestPackingCommon(TransactionCase): @classmethod def setU...
49.427785
71,868
1,508
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo.tests import common class TestStockLocationSearch(common.TransactionCase): def setUp(self): super(TestStockLocationSearch, self).setUp() self.location = self.env['stock.location'] self.stock_location = self.env.ref('stock.stock_location_stock') se...
41.888889
1,508
167,429
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import timedelta from odoo.addons.stock.tests.common import TestStockCommon from odoo.exceptions import UserError from odoo.tests import Form from odoo.tools import float_is_zero, float_compare from date...
46.897199
167,423
2,023
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo.addons.mail.tests.common import mail_new_test_user from odoo.addons.product.tests import common class TestStockCommon(common.TestProductCommon): def _create_move(self, product, src_location, dst_location, **values): # TDE FIXME: user as parameter Move = self.env...
35.491228
2,023
19,037
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.exceptions import UserError, ValidationError from odoo.tests.common import Form, TransactionCase class StockGenerate(TransactionCase): @classmethod def setUpClass(cls): super(StockGenerate, cl...
42.024283
19,037
21,730
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import date, datetime, timedelta from odoo.tests.common import Form, TransactionCase from odoo.tools import mute_logger from odoo.exceptions import UserError class TestProcRule(TransactionCase): def...
43.373253
21,730
8,710
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tests.common import TransactionCase class TestPackingNeg(TransactionCase): def test_packing_neg(self): res_partner_2 = self.env['res.partner'].create({ 'name': 'Deco Addict', ...
47.595628
8,710
27,253
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.exceptions import UserError from odoo.tests.common import TransactionCase, Form class TestMultiCompany(TransactionCase): @classmethod def setUpClass(cls): super(TestMultiCompany, cls).setUpCla...
46.746141
27,253
896
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class StockInventoryConflict(models.TransientModel): _name = 'stock.inventory.conflict' _description = 'Conflict in Inventory' quant_ids = fields.Many2many( 'stock.q...
37.333333
896
4,243
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import datetime from odoo import _, api, fields, models from odoo.exceptions import UserError from odoo.tools.misc import clean_context class ProductReplenish(models.TransientModel): _name = 'product.replenish' ...
48.770115
4,243
1,163
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models from odoo.tools.date_utils import add class StockOrderpointSnooze(models.TransientModel): _name = 'stock.orderpoint.snooze' _description = 'Snooze Orderpoint' orderpoin...
34.205882
1,163
1,684
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, fields, models from odoo.osv import expression from odoo.tools.misc import format_datetime class StockQuantityHistory(models.TransientModel): _name = 'stock.quantity.history' _description = ...
43.179487
1,684
3,493
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models from odoo.tools.float_utils import float_compare class StockBackorderConfirmationLine(models.TransientModel): _name = 'stock.backorder.confirmation.line' _description = 'Bac...
44.782051
3,493
1,900
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models class StockWarnInsufficientQty(models.AbstractModel): _name = 'stock.warn.insufficient.qty' _description = 'Warn Insufficient Quantity' product_id = fields.Many2one('pr...
37.254902
1,900
1,335
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models class ChooseDestinationLocation(models.TransientModel): _name = 'stock.package.destination' _description = 'Stock Package Destination' picking_id = fields.Many2one('sto...
46.034483
1,335
604
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class StockInventoryWarning(models.TransientModel): _name = 'stock.inventory.warning' _description = 'Inventory Adjustment Warning' quant_ids = fields.Many2many('stock.quant...
33.555556
604
1,861
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # # Order Point Method: # - Order if the virtual stock of today is below the min of the defined order point # from odoo import models, tools import logging import threading _logger = logging.getLogger(__name__) c...
40.456522
1,861
1,441
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models class StockTrackConfirmation(models.TransientModel): _name = 'stock.track.confirmation' _description = 'Stock Track Confirmation' tracking_line_ids = fields.One2many('s...
40.027778
1,441
1,764
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict from odoo import fields, models class ProductLabelLayout(models.TransientModel): _inherit = 'product.label.layout' move_line_ids = fields.Many2many('stock.move.line') pi...
45.230769
1,764
10,902
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models from odoo.exceptions import UserError from odoo.tools.float_utils import float_round class ReturnPickingLine(models.TransientModel): _name = "stock.return.picking.line" _...
54.753769
10,896
1,445
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models from odoo.exceptions import ValidationError class StockAssignSerialNumbers(models.TransientModel): _name = 'stock.assign.serial' _description = 'Stock Assign Serial Numbe...
42.5
1,445
1,263
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class StockRequestCount(models.TransientModel): _name = 'stock.request.count' _description = 'Stock Request an Inventory Count' inventory_date = fields.Date( 'Invent...
39.46875
1,263
2,757
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models from odoo.exceptions import UserError class StockImmediateTransferLine(models.TransientModel): _name = 'stock.immediate.transfer.line' _description = 'Immediate Transfer ...
43.078125
2,757
4,484
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from json import dumps from datetime import datetime, time from odoo import api, fields, models, SUPERUSER_ID from odoo.osv.expression import AND from odoo.tools import get_month, subtract, format_date class StockRepl...
56.05
4,484
2,347
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models class StockRulesReport(models.TransientModel): _name = 'stock.rules.report' _description = 'Stock Rules report' product_id = fields.Many2one('product.product', string='...
46.94
2,347
1,900
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models from odoo.exceptions import UserError class ProductChangeQuantity(models.TransientModel): _name = "stock.change.product.qty" _description = "Change Product Quantity" ...
44.186047
1,900
1,176
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models, _ class StockInventoryAdjustmentName(models.TransientModel): _name = 'stock.inventory.adjustment.name' _description = 'Inventory Adjustment Reference / Reason' def default_...
43.555556
1,176
27,511
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import calendar from collections import defaultdict, OrderedDict from datetime import timedelta from odoo import _, api, fields, models from odoo.exceptions import UserError from odoo.tools.misc import groupby from odo...
62.10158
27,511
56,738
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from collections import namedtuple from odoo import _, _lt, api, fields, models from odoo.exceptions import UserError _logger = logging.getLogger(__name__) ROUTE_NAMES = { 'one_step': _lt('Receive ...
53.073901
56,736
4,043
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models class StorageCategory(models.Model): _name = 'stock.storage.category' _description = "Storage Category" _order = "name" name = fields.Char('Storage Category', re...
53.197368
4,043
10,473
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models from odoo.exceptions import UserError from odoo.tools import float_compare class StockScrap(models.Model): _name = 'stock.scrap' _inherit = ['mail.thread'] _order = '...
53.984536
10,473
52,515
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import Counter, defaultdict from odoo import _, api, fields, tools, models from odoo.exceptions import UserError, ValidationError from odoo.tools import OrderedSet, groupby from odoo.tools.float_utils i...
61.928066
52,515
55,111
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from psycopg2 import Error, OperationalError from odoo import _, api, fields, models from odoo.exceptions import UserError, ValidationError from odoo.osv import expression from odoo.tools.float_utils imp...
51.648547
55,109
11,453
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from itertools import groupby from operator import itemgetter from collections import defaultdict from odoo import _, api, fields, models from odoo.tools.float_utils import float_is_zero class StockPackageLevel(models...
51.823529
11,453
123,122
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict from datetime import timedelta from itertools import groupby from odoo.tools import groupby as groupbyelem from operator import itemgetter from odoo import _, api, Command, fields, m...
56.920481
123,119
9,211
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models class Company(models.Model): _inherit = "res.company" _check_company_auto = True def _default_confirmation_mail_template(self): try: return self....
44.497585
9,211
30,378
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from collections import defaultdict from datetime import datetime, time from dateutil import relativedelta from itertools import groupby from psycopg2 import OperationalError from odoo import SUPERUSER_ID...
52.106346
30,378
11,465
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from re import findall as regex_findall from re import split as regex_split from odoo.tools.misc import attrgetter from odoo import _, api, fields, models from odoo.exceptions import UserError, ValidationError class P...
48.995726
11,465
82,967
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import json import time from ast import literal_eval from datetime import date, timedelta from itertools import groupby from operator import attrgetter, itemgetter from collections import defaultdict from odoo import SU...
54.014974
82,967
7,761
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import _, api, fields, models from odoo.exceptions import UserError from odoo.tools.float_utils import float_compare class RemovalStrategy(models.Model): _name = 'product.removal' _description = 'Remo...
49.433121
7,761
528
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class BarcodeRule(models.Model): _inherit = 'barcode.rule' type = fields.Selection(selection_add=[ ('weight', 'Weighted Product'), ('location', 'Location'), ...
26.4
528
59,412
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import operator as py_operator from ast import literal_eval from collections import defaultdict from dateutil.relativedelta import relativedelta from odoo import _, api, fields, models from odoo.exceptions import UserEr...
54.356816
59,412
31,328
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from collections import defaultdict, namedtuple from dateutil.relativedelta import relativedelta from odoo import SUPERUSER_ID, _, api, fields, models, registry from odoo.exceptions import UserError from...
53.098305
31,328
7,568
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models, SUPERUSER_ID, _ from odoo.exceptions import UserError class ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' module_product_expiry = fields.Boole...
65.808696
7,568
3,220
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields, _ class PackageType(models.Model): _name = 'stock.package.type' _description = "Stock package type" def _get_default_length_uom(self): return self.env['product.temp...
58.545455
3,220
1,140
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models from odoo.addons.base.models.res_partner import WARNING_HELP, WARNING_MESSAGE class Partner(models.Model): _inherit = 'res.partner' _check_company_auto = True property_stock...
54.285714
1,140
7,792
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models, _ from odoo.exceptions import UserError class ReportStockRule(models.AbstractModel): _name = 'report.stock.report_stock_rule' _description = 'Stock rule report' @api.model ...
56.057554
7,792
10,710
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models, _ from odoo.tools import config from odoo.tools import format_datetime from markupsafe import Markup rec = 0 def autoIncrement(): global rec pStart = 1 pInterval = 1 if rec...
43.360324
10,710
7,019
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models, tools class ReportStockQuantity(models.Model): _name = 'report.stock.quantity' _auto = False _description = 'Stock Quantity Report' date = fields.Date(string='Date', re...
44.144654
7,019
17,394
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict, OrderedDict from odoo import _, api, models from odoo.tools import float_compare, float_is_zero, format_date class ReceptionReport(models.AbstractModel): _name = 'report.stock....
57.596026
17,394
13,866
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict from odoo import api, models from odoo.tools import float_compare, float_is_zero, format_date, float_round class ReplenishmentReport(models.AbstractModel): _name = 'report.stock...
51.546468
13,866
1,310
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict from odoo import _, models from odoo.exceptions import UserError class ReportProductLabel(models.AbstractModel): _name = 'report.stock.label_product_product_view' _descripti...
40.9375
1,310
1,547
py
PYTHON
15.0
# -*- coding: utf-8 -*- import werkzeug from werkzeug.exceptions import InternalServerError from odoo import http from odoo.http import request from odoo.addons.web.controllers.main import _serialize_exception from odoo.tools.misc import html_escape import json class StockReportController(http.Controller): @ht...
39.666667
1,547
865
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Resource', 'version': '1.1', 'category': 'Hidden', 'description': """ Module for resource management. =============================== A resource represent something that can be scheduled (a de...
27.903226
865
55,091
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import date, datetime from freezegun import freeze_time from pytz import timezone, utc from odoo import fields from odoo.exceptions import ValidationError from odoo.addons.resource.models.resource import I...
43.550198
55,091
3,323
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tests.common import TransactionCase class TestResourceCommon(TransactionCase): def _define_calendar(self, name, attendances, tz): return self.env['resource.calendar'].create({ 'name':...
41.5375
3,323
297
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class ResourceTest(models.Model): _description = 'Test Resource Model' _name = 'resource.test' _inherit = ['resource.mixin'] name = fields.Char()
24.75
297
49,201
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict import math from datetime import datetime, time, timedelta from dateutil.relativedelta import relativedelta from dateutil.rrule import rrule, DAILY, WEEKLY from functools import partia...
46.459868
49,201
1,286
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models, _ class ResCompany(models.Model): _inherit = 'res.company' resource_calendar_ids = fields.One2many( 'resource.calendar', 'company_id', 'Working Hours') resourc...
37.823529
1,286
890
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class ResUsers(models.Model): _inherit = 'res.users' resource_ids = fields.One2many( 'resource.resource', 'user_id', 'Resources') resource_calendar_id = fields.Many2...
37.083333
890
8,729
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict from dateutil.relativedelta import relativedelta from pytz import utc from odoo import api, fields, models def timezone_datetime(time): if not time.tzinfo: time = time.r...
44.085859
8,729
791
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Sale Purchase', 'summary': 'Sale based on service outsourcing.', 'description': """ Allows the outsourcing of services. This module allows one to sell services provided by external providers and wi...
28.25
791
2,997
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.exceptions import AccessError from odoo.addons.sale_purchase.tests.common import TestCommonSalePurchaseNoChart from odoo.tests import tagged @tagged('-at_install', 'post_install') class TestAccessRights(TestC...
42.814286
2,997
2,605
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.sale.tests.common import TestSaleCommon class TestCommonSalePurchaseNoChart(TestSaleCommon): @classmethod def setUpClass(cls, chart_template_ref=None): super().setUpClass(chart_templat...
37.753623
2,605
17,751
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.exceptions import UserError, AccessError from odoo.tests import tagged from odoo.addons.sale_purchase.tests.common import TestCommonSalePurchaseNoChart @tagged('-at_install', 'post_install') class TestSalePur...
63.852518
17,751
17,054
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from dateutil.relativedelta import relativedelta from odoo import api, fields, models, _ from odoo.exceptions import UserError from odoo.tools import float_compare from odoo.tools.misc import get_lang class SaleOrder(...
51.993902
17,054