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
1,580
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, UserError class PosCategory(models.Model): _name = "pos.category" _description = "Point of Sale Category" _order = "sequen...
43.888889
1,580
2,020
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo import models, fields, api, _ class Warehouse(models.Model): _inherit = "stock.warehouse" pos_type_id = fields.Many2one('stock.picking.type', string="Point of Sale Operation Type") def _get_sequence_values(self): sequence_values = super(Warehouse, self)._get_se...
39.607843
2,020
1,182
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (C) 2004-2008 PC Solutions (<http://pcsol.be>). All Rights Reserved from odoo import fields, models, api, _ from odoo.exceptions import ValidationError class AccountJournal(models.Model): _inherit = 'acco...
51.391304
1,182
89,740
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 odoo import api, fields, models, _, Command from odoo.exceptions import AccessError, UserError, ValidationError from odoo.tools import float_is_zer...
56.546944
89,740
41,219
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import datetime from uuid import uuid4 import pytz from odoo import api, fields, models, tools, _ from odoo.exceptions import ValidationError, UserError class PosConfig(models.Model): _name = 'pos.co...
55.105615
41,219
453
py
PYTHON
15.0
from odoo import api, fields, models, _ class Bill(models.Model): _name = "pos.bill" _order = "value" _description = "Coins/Bills" name = fields.Char("Name") value = fields.Float("Coin/Bill Value", required=True, digits=0) pos_config_ids = fields.Many2many("pos.config") @api.model de...
28.3125
453
1,076
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields, api class AccountPayment(models.Model): _inherit = 'account.payment' pos_payment_method_id = fields.Many2one('pos.payment.method', "POS Payment Method") force_outstanding_a...
44.833333
1,076
1,752
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo import api, models, fields, _ from odoo.exceptions import ValidationError class ResCompany(models.Model): _inherit = 'res.company' point_of_sale_update_stock_quantities = fields.Selection([ ('closing', 'At the session closing (recommended)'), ('real',...
47.351351
1,752
15,539
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, ValidationError from odoo.tools import float_is_zero, float_compare from itertools import groupby from collections import defaultdict class Sto...
51.624585
15,539
5,041
py
PYTHON
15.0
from odoo import api, fields, models, _ from odoo.exceptions import UserError class PosPaymentMethod(models.Model): _name = "pos.payment.method" _description = "Point of Sale Payment Methods" _order = "id asc" def _get_payment_terminal_selection(self): return [] name = fields.Char(string...
56.640449
5,041
5,079
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 itertools import groupby from operator import itemgetter from datetime import date class ProductTemplate(models.Model): _inherit = '...
43.410256
5,079
681
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class StockRule(models.Model): _inherit = 'stock.rule' def _get_stock_move_values(self, product_id, product_qty, product_uom, location_id, name, origin, company_id, values): mo...
45.4
681
1,649
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo import api, fields, models class ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' sale_tax_id = fields.Many2one('account.tax', string="Default Sale Tax", related='company_id.account_sale_tax_id', readonly=False) module_pos_mercury = fields.Bool...
71.695652
1,649
651
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields from odoo.tools.translate import _ class BarcodeRule(models.Model): _inherit = 'barcode.rule' type = fields.Selection(selection_add=[ ('weight', 'Weighted Product'), ...
28.304348
651
5,180
py
PYTHON
15.0
from odoo import api, fields, models, _ from odoo.tools import formatLang, float_is_zero from odoo.exceptions import ValidationError class PosPayment(models.Model): """ Used to register payments made in a pos.order. See `payment_ids` field of pos.order model. The main characteristics of pos.payment can b...
53.958333
5,180
2,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 class ResPartner(models.Model): _inherit = 'res.partner' pos_order_count = fields.Integer( compute='_compute_pos_order', ...
41.208955
2,761
65,808
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from datetime import timedelta from functools import partial from itertools import groupby import psycopg2 import pytz import re from odoo import api, fields, models, tools, _ from odoo.tools import float...
50.311927
65,808
903
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo import api, models class AccountChartTemplate(models.Model): _inherit = 'account.chart.template' def _load(self, sale_tax_rate, purchase_tax_rate, company): """Remove the payment methods that are created for the company before installing the chart of accounts. ...
50.166667
903
1,276
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (C) 2004-2008 PC Solutions (<http://pcsol.be>). All Rights Reserved from odoo import fields, models, api, _ from odoo.exceptions import UserError class AccountBankStatement(models.Model): _inherit = 'acc...
51.04
1,276
1,328
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 PosInvoiceReport(models.AbstractModel): _name = 'report.point_of_sale.report_invoice' _description = 'Point of Sale Invoice Report' ...
44.266667
1,328
5,348
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, tools class PosOrderReport(models.Model): _name = "report.pos.order" _description = "Point of Sale Orders Report" _auto = False _order = 'date desc' date = fie...
50.933333
5,348
4,032
py
PYTHON
15.0
# -*- coding: utf-8 -*- import json import logging from odoo import http from odoo.http import request from odoo.osv.expression import AND from odoo.tools import convert _logger = logging.getLogger(__name__) class PosController(http.Controller): @http.route(['/pos/web', '/pos/ui'], type='http', auth='user') ...
45.303371
4,032
1,779
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Blogs', 'category': 'Website/Website', 'sequence': 200, 'website': 'https://www.odoo.com/app/blog', 'summary': 'Publish blog posts, announces, news', 'version': '1.1', 'description'...
32.944444
1,779
5,178
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 users from odoo.addons.website.tools import MockRequest from odoo.addons.website_blog.tests.common import TestWebsiteBlogCommon from odoo.addons.portal....
43.881356
5,178
1,095
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import odoo.tests @odoo.tests.tagged('post_install', '-at_install') class TestUi(odoo.tests.HttpCase): def test_admin(self): # Ensure at least two blogs exist for the step asking to select a blog se...
36.5
1,095
2,466
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.website.tests.test_performance import UtilPerf import random class TestBlogPerformance(UtilPerf): def setUp(self): super().setUp() # if website_livechat is installed, disable it ...
52.468085
2,466
1,814
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tests import common class TestWebsiteBlogCommon(common.TransactionCase): def setUp(self): super(TestWebsiteBlogCommon, self).setUp() Users = self.env['res.users'] group_blog_mana...
39.434783
1,814
15,782
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import datetime import random import re from odoo import api, models, fields, _ from odoo.addons.http_routing.models.ir_http import slug, unslug from odoo.addons.website.tools import text_from_html from od...
44.207283
15,782
3,117
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 import models, fields, _ class WebsiteSnippetFilter(models.Model): _inherit = 'website.snippet.filter' def _get_hardcoded_sample(self, model): samples = super(...
54.684211
3,117
3,448
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.addons.http_routing.models.ir_http import url_for class Website(models.Model): _inherit = "website" @api.model def page_search_dependencies(self, page_id=False): ...
37.075269
3,448
16,470
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import re import werkzeug import itertools import pytz import babel.dates from collections import OrderedDict from odoo import http, fields from odoo.addons.http_routing.models.ir_http import slug, unslug from odoo.addo...
47.191977
16,470
1,161
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': "Events Booths Sales", 'category': 'Marketing/Events', 'version': '1.0', 'summary': "Manage event booths sale", 'description': """ Sell your event booths and track payments on sale orders. ...
35.181818
1,161
7,412
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import Command from odoo.addons.event_booth_sale.tests.common import TestEventBoothSaleCommon from odoo.addons.sale.tests.common import TestSaleCommon from odoo.tests.common import tagged, users from odoo.tools...
47.819355
7,412
1,101
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.event_booth.tests.common import TestEventBoothCommon from odoo.addons.event_sale.tests.common import TestEventSaleCommon class TestEventBoothSaleCommon(TestEventBoothCommon, TestEventSaleCommon): ...
34.40625
1,101
4,151
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 Command from odoo.addons.event_booth_sale.tests.common import TestEventBoothSaleCommon from odoo.fields import Datetime as FieldsDatetime from odoo.tests.common ...
44.159574
4,151
1,558
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models, fields, _ from odoo.exceptions import ValidationError class EventBoothConfigurator(models.TransientModel): _name = 'event.booth.configurator' _description = 'Event Booth Configurat...
45.823529
1,558
557
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class AccountMove(models.Model): _inherit = 'account.move' def action_invoice_paid(self): """ When an invoice linked to a sales order selling registrations is paid, upda...
34.8125
557
1,305
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 SaleOrder(models.Model): _inherit = 'sale.order' event_booth_ids = fields.One2many('event.booth', 'sale_order_id', string='Booths') event_booth_count = fields.Int...
37.285714
1,305
5,176
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 SaleOrderLine(models.Model): _inherit = 'sale.order.line' event_booth_category_id = fields.Many2one('event.booth.catego...
50.745098
5,176
4,518
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from odoo import api, fields, models _logger = logging.getLogger(__name__) class EventBoothCategory(models.Model): _inherit = 'event.booth.category' def _default_product_id(self): retu...
43.864078
4,518
242
py
PYTHON
15.0
from odoo import fields, models class SaleOrderTemplateLine(models.Model): _inherit = "sale.order.template.line" product_id = fields.Many2one(domain="[('sale_ok', '=', True), ('detailed_type', 'not in', ['event', 'event_booth'])]")
40.333333
242
923
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 ProductTemplate(models.Model): _inherit = 'product.template' detailed_type = fields.Selection(selection_add=[ ('event_booth', 'Event Booth'), ], ondelete=...
29.774194
923
606
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 EventTypeBooth(models.Model): _inherit = 'event.type.booth' product_id = fields.Many2one(related='booth_category_id.product_id') price = fields.Float(related='boo...
35.647059
606
3,759
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 EventBoothRegistration(models.Model): """event.booth.registrations are used to allow multiple partners to book the same booth. Whenever a partner has paid his regis...
48.192308
3,759
2,023
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 EventBooth(models.Model): _inherit = 'event.booth' # registrations event_booth_registration_ids = fields.One2many('event....
41.285714
2,023
246
py
PYTHON
15.0
from odoo import fields, models class SaleOrderTemplateOption(models.Model): _inherit = "sale.order.template.option" product_id = fields.Many2one(domain="[('sale_ok', '=', True), ('detailed_type', 'not in', ['event', 'event_booth'])]")
41
246
1,361
py
PYTHON
15.0
# -*- coding: utf-8 -*- { 'name': "Egyptian E-Invoice Integration", 'summary': """ Egyptian Tax Authority Invoice Integration """, 'description': """ This module integrate with the ETA Portal to automatically sign and send your invoices to the tax Authority. Special thanks ...
33.195122
1,361
41,264
py
PYTHON
15.0
import json from unittest.mock import patch from freezegun import freeze_time from odoo.tests import tagged from .common import TestEGEdiCommon ETA_TEST_RESPONSE = { 'l10n_eg_uuid': 'UUIDXIL9182712KMHJQ', 'l10n_eg_long_id': 'LIDMN12132LASKXXA', 'l10n_eg_internal_id': 'INTLA1212MMKA12', 'l10n_eg_hash...
50.625767
41,260
4,011
py
PYTHON
15.0
from datetime import datetime from pytz import timezone from odoo.fields import Command from odoo.tests import tagged from odoo.addons.account_edi.tests.common import AccountEdiTestCommon @tagged('post_install_l10n', 'post_install', '-at_install') class TestEGEdiCommon(AccountEdiTestCommon): @classmethod de...
39.673267
4,007
6,536
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging import json from odoo import api, models, fields, _ from odoo.exceptions import ValidationError, UserError from odoo.tools.sql import column_exists, create_column from datetime import datetime _logger = l...
52.709677
6,536
21,240
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import json import logging import requests from werkzeug.urls import url_quote from base64 import b64encode from urllib3.util.ssl_ import create_urllib3_context from odoo import api, models, _ from odoo.tools.float_uti...
52.186732
21,240
7,329
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import base64 import hashlib import json import pytz from asn1crypto import cms, core, x509, algos, tsp from odoo import models, fields, _ from odoo.exceptions import ValidationError class EtaThumbDrive(models.Model)...
41.88
7,329
944
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 AccountJournal(models.Model): _inherit = 'account.journal' l10n_eg_branch_id = fields.Many2one('res.partner', string='Branch', copy=False, ...
55.529412
944
2,113
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 ProductTemplate(models.Model): _inherit = "product.template" l10n_eg_eta_code = fields.Char('ETA Item code', compute='_compute_l10n_eg_eta_code', ...
44.020833
2,113
721
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 ResCompany(models.Model): _inherit = 'res.company' l10n_eg_client_identifier = fields.Char('ETA Client ID', groups="base.group_erp_manager") l10n_eg_client_secret = f...
45.0625
721
605
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 UomCode(models.Model): _name = 'l10n_eg_edi.uom.code' _description = 'ETA code for the unit of measures' name = fields.Char(required=True, translate=True) code = f...
31.842105
605
1,022
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, api, _ class ResCurrencyRate(models.Model): _inherit = 'res.currency.rate' @api.onchange('company_rate') def _onchange_rate_warning(self): # We send the ETA a rate that is...
42.583333
1,022
810
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields, api from odoo.osv import expression class EtaActivityType(models.Model): _name = 'l10n_eg_edi.activity.type' _description = 'ETA code for activity type' name = fields.Char...
35.217391
810
545
py
PYTHON
15.0
from odoo import models, fields class ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' l10n_eg_client_identifier = fields.Char(related='company_id.l10n_eg_client_identifier', readonly=False) l10n_eg_client_secret = fields.Char(related='company_id.l10n_eg_client_secret', readonly=...
60.555556
545
475
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields, api class ResPartner(models.Model): _inherit = 'res.partner' l10n_eg_building_no = fields.Char('Building No.') @api.model def _commercial_fields(self): return...
26.388889
475
468
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': "IAP / CRM", 'summary': """Bridge between IAP and CRM""", 'description': """Bridge between IAP and CRM""", 'category': 'Hidden/Tools', 'version': '1.0', 'depends': [ 'crm', ...
22.285714
468
287
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 Lead(models.Model): _inherit = 'crm.lead' reveal_id = fields.Char(string='Reveal ID', help="Technical ID of reveal request done by IAP.")
28.7
287
667
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'City Addresses', 'summary': 'Add a many2one field city on addresses', 'sequence': '19', 'category': 'Hidden/Tools', 'complexity': 'easy', 'description': """ City Management in Addresses ...
30.318182
667
1,194
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 City(models.Model): _name = 'res.city' _description = 'City' _order = 'name' name = fields.Char("Name", required=True, translate=True) zipcode = fields.Ch...
38.516129
1,194
415
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 Country(models.Model): _inherit = 'res.country' enforce_cities = fields.Boolean( string='Enforce Cities', help="Check this box to ensure every address crea...
31.923077
415
4,084
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from lxml import etree from odoo import api, models, fields from odoo.tools.translate import _ class Partner(models.Model): _inherit = 'res.partner' country_enforce_cities = fields.Boolean(related='country_id...
40.84
4,084
403
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Microsoft Users', 'category': 'Hidden/Tools', 'description': """ The module adds Microsoft user in res user. =========================================== """, 'depends': ['base_setup'], 'dat...
25.1875
403
7,388
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, _ _logger = logging.getLogger(__name__) TIMEOUT = 20 DEFAULT_MICROSOFT_AUTH_EN...
43.458824
7,388
877
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 import api, fields, models, _ class User(models.Model): _inherit = 'res.users' microsoft_calendar_rtoken = fields.Char('Microsoft Refresh Token', copy=False, groups="...
39.863636
877
1,073
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import json from odoo import http from odoo.http import request class MicrosoftAuth(http.Controller): @http.route('/microsoft_account/authentication', type='http', auth="public") def oauth2callback(self, **kw...
39.740741
1,073
1,160
py
PYTHON
15.0
# -*- coding: utf-8 -*- { 'name': 'Slovak - Accounting', 'version': '1.0', 'author': '26HOUSE', 'website': 'http://www.26house.com', 'category': 'Accounting/Localizations/Account Charts', 'description': """ Slovakia accounting chart and localization: Chart of Accounts 2020, basic VAT rates + f...
27.707317
1,136
2,413
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Employees', 'version': '1.1', 'category': 'Human Resources/Employees', 'sequence': 95, 'summary': 'Centralize employee information', 'description': "", 'website': 'https://www.odoo....
32.173333
2,413
10,242
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import OrderedDict from itertools import chain from odoo.addons.hr.tests.common import TestHrCommon from odoo.tests import new_test_user, tagged, Form from odoo.exceptions import AccessError @tagged('p...
47.198157
10,242
1,779
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.addons.hr.tests.common import TestHrCommon from odoo.addons.base.models.qweb import QWebException class TestMultiCompany(TestHrCommon): def setUp(self): super().setUp(...
44.475
1,779
949
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.hr.tests.common import TestHrCommon class TestChannel(TestHrCommon): def setUp(self): super(TestChannel, self).setUp() self.channel = self.env['mail.channel'].create({'name': 'Tes...
32.724138
949
467
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 import common class TestHrCommon(common.TransactionCase): def setUp(self): super(TestHrCommon, self).setUp() self.res_u...
35.923077
467
2,396
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.hr.tests.common import TestHrCommon class TestHrFlow(TestHrCommon): def setUp(self): super(TestHrFlow, self).setUp() self.dep_rd = self.env['hr.department'].create({ 'n...
49.916667
2,396
3,095
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.addons.hr.tests.common import TestHrCommon class TestHrEmployee(TestHrCommon): def setUp(self): super().setUp() self.user_without_image = self.env['res.users']...
43.591549
3,095
1,870
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 HrDepartureWizard(models.TransientModel): _name = 'hr.departure.wizard' _description = 'Departure Wizard' def _get_default_departure_date(self): departure_date...
49.210526
1,870
1,524
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 HrPlanWizard(models.TransientModel): _name = 'hr.plan.wizard' _description = 'Plan Wizard' plan_id = fields.Many2one('hr.plan', default=lambda self: self.env['hr.plan'...
40.105263
1,524
1,008
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 DepartureReason(models.Model): _name = "hr.departure.reason" _description = "Departure Reason" _order = "sequence" se...
37.333333
1,008
3,470
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, tools class HrEmployeePublic(models.Model): _name = "hr.employee.public" _inherit = ["hr.employee.base"] _description = 'Public Employee' _order = 'name' _auto ...
50.289855
3,470
891
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, tools, _ class BaseModel(models.AbstractModel): _inherit = 'base' def _alias_get_error_message(self, message, message_dict, alias): if alias.alias_contact == 'employees': ...
44.55
891
660
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 WorkLocation(models.Model): _name = "hr.work.location" _description = "Work Location" _order = 'name' active = fields.Boolean(default=True) name = fields.Char(...
41.25
660
697
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from random import randint from odoo import fields, models class EmployeeCategory(models.Model): _name = "hr.employee.category" _description = "Employee Category" def _get_default_color(self): re...
30.304348
697
4,642
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 Department(models.Model): _name = "hr.department" _description = "Department" _inherit = ['mail.thread'] _order ...
49.913978
4,642
250
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 ResourceResource(models.Model): _inherit = "resource.resource" user_id = fields.Many2one(copy=False)
25
250
3,906
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.addons.web_editor.controllers.main import handle_history_divergence class Job(models.Model): _name = "hr.job" _description = "Job Position" _inherit = ['ma...
50.727273
3,906
418
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, api, tools class IrUiMenu(models.Model): _inherit = 'ir.ui.menu' def _load_menus_blacklist(self): res = super()._load_menus_blacklist() if self.env.user.has_group('hr.g...
29.857143
418
2,899
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 HrPlanActivityType(models.Model): _name = 'hr.plan.activity.type' _description = 'Plan activity type' _rec_name = 'summary...
43.268657
2,899
349
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 Company(models.Model): _inherit = 'res.company' hr_presence_control_email_amount = fields.Integer(string="# emails to send") hr_presence_control_ip_list = fields.Char(...
31.727273
349
24,014
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import pytz from datetime import datetime, time from dateutil.rrule import rrule, DAILY from random import choice from string import digits from werkzeug.urls import url_encode from dateutil.relativedelta import relative...
50.769556
24,014
563
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 Alias(models.Model): _inherit = 'mail.alias' alias_contact = fields.Selection(selection_add=[ ('employees', 'Authenticated Employees'), ], ondelete={'employ...
33.117647
563
13,509
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models, fields, _, SUPERUSER_ID from odoo.exceptions import AccessError HR_READABLE_FIELDS = [ 'active', 'child_ids', 'employee_id', 'address_home_id', 'employee_ids', 'emp...
52.761719
13,507
1,958
py
PYTHON
15.0
# -*- coding: utf-8 -*- import threading from odoo import fields, models, api, _ from odoo.exceptions import ValidationError class ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' resource_calendar_id = fields.Many2one( 'resource.calendar', 'Company Working Hours', ...
61.1875
1,958
1,637
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.exceptions import AccessError class Partner(models.Model): _inherit = ['res.partner'] employee_ids = fields.One2many( 'hr.employee', 'address_home_id', stri...
39.926829
1,637
10,125
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from ast import literal_eval from odoo import api, fields, models from pytz import timezone, UTC, utc from datetime import timedelta from odoo.tools import format_time class HrEmployeeBase(models.AbstractModel): ...
52.46114
10,125
1,105
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 Channel(models.Model): _inherit = 'mail.channel' subscription_department_ids = fields.Many2many( 'hr.department', string='HR Departments', help='Automatica...
39.464286
1,105
731
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': "pos_cache", 'summary': "Enable a cache on products for a lower POS loading time.", 'description': """ This creates a product cache per POS config. It drastically lowers the time it takes to load a...
27.074074
731
3,364
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import base64 import json from ast import literal_eval from odoo import models, fields, api from odoo.tools import date_utils class pos_cache(models.Model): _name = 'pos.cache' _description = 'Point of Sale Cac...
36.967033
3,364