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
3,054
py
PYTHON
15.0
from odoo import fields, models, api, _ from odoo.exceptions import UserError EXEMPTION_REASON_CODES = [ ('VATEX-SA-29', 'VATEX-SA-29 Financial services mentioned in Article 29 of the VAT Regulations.'), ('VATEX-SA-29-7', 'VATEX-SA-29-7 Life insurance services mentioned in Article 29 of the VAT.'), ('VATE...
52.655172
3,054
10,347
py
PYTHON
15.0
import uuid import json from markupsafe import Markup from odoo import _, fields, models, api from odoo.tools import float_repr from datetime import datetime from base64 import b64decode, b64encode from lxml import etree from cryptography.hazmat.primitives.serialization import Encoding, PublicFormat from cryptography.h...
53.890625
10,347
23,534
py
PYTHON
15.0
import json from hashlib import sha256 from base64 import b64decode, b64encode from lxml import etree from datetime import date, datetime from odoo import models, fields, _, api from odoo.exceptions import UserError from cryptography.hazmat.primitives.serialization import load_pem_private_key from cryptography.hazmat.p...
52.414254
23,534
36,898
py
PYTHON
15.0
import json import requests from markupsafe import Markup from lxml import etree from datetime import datetime from base64 import b64encode, b64decode from odoo import models, fields, service, _, api from odoo.exceptions import UserError from odoo.modules.module import get_module_resource from requests.exceptions impor...
59.13141
36,898
4,744
py
PYTHON
15.0
import re from odoo import models, fields from odoo.exceptions import UserError from cryptography.hazmat.backends import default_backend from cryptography.hazmat.primitives import serialization from cryptography.hazmat.primitives.asymmetric import ec class ResCompany(models.Model): _inherit = "res.company" d...
50.967742
4,740
978
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class AccountEdiDocument(models.Model): _inherit = 'account.edi.document' def _prepare_jobs(self): """ Override to achieve the following: If there is a job to ...
34.928571
978
669
py
PYTHON
15.0
from odoo import models, fields, api, _ class ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' l10n_sa_api_mode = fields.Selection(related='company_id.l10n_sa_api_mode', readonly=False) @api.depends('company_id') def _compute_company_informations(self): super()._com...
47.785714
669
21,829
py
PYTHON
15.0
# -*- coding: utf-8 -*- from hashlib import sha256 from base64 import b64encode from lxml import etree from odoo import models, fields from odoo.modules.module import get_module_resource import re TAX_EXEMPTION_CODES = ['VATEX-SA-29', 'VATEX-SA-29-7', 'VATEX-SA-30'] TAX_ZERO_RATE_CODES = ['VATEX-SA-32', 'VATEX-SA-33',...
53.898765
21,829
1,584
py
PYTHON
15.0
from odoo import fields, models, api class ResPartner(models.Model): _inherit = 'res.partner' l10n_sa_edi_building_number = fields.Char("Building Number") l10n_sa_edi_plot_identification = fields.Char("Plot Identification") l10n_sa_additional_identification_scheme = fields.Selection([ ('TIN'...
44
1,584
1,643
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (c) 2015 WT-IO-IT GmbH (https://www.wt-io-it.at) # Mag. Wolfgang Taferner <wolfgang.taferner@wt-io-it.at> # List of contributors: # Mag. Wolfgang Taferner <wolfgang.taferner@wt-io-it.at> #...
32.215686
1,643
1,114
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Notes', 'version': '1.0', 'category': 'Productivity/Notes', 'description': "", 'website': 'https://www.odoo.com/app/notes', 'summary': 'Organize your work with memos', 'sequence': 2...
25.318182
1,114
626
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.base.tests.common import TransactionCaseWithUserDemo class TestNote(TransactionCaseWithUserDemo): def test_bug_lp_1156215(self): """ ensure any users can create new users """ demo_...
28.454545
626
437
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 MailActivityType(models.Model): _inherit = "mail.activity.type" category = fields.Selection(selection_add=[('reminder', 'Reminder')]) class MailActivity(models.Model): ...
27.3125
437
2,824
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, models, modules, _ _logger = logging.getLogger(__name__) class Users(models.Model): _name = 'res.users' _inherit = ['res.users'] @api.model_create_multi def creat...
38.684932
2,824
6,455
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 import html2plaintext from odoo.addons.web_editor.controllers.main import handle_history_divergence class Stage(models.Model): _name = "note.stage" _descr...
44.826389
6,455
802
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import http from odoo.http import request class NoteController(http.Controller): @http.route('/note/new', type='json', auth='user') def note_new_from_systray(self, note, activity_type_id=None, date_d...
40.1
802
999
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Online Event Booths', 'category': 'Marketing/Events', 'version': '1.0', 'summary': 'Events, display your booths on your website', 'description': """ Display your booths on your website for ...
31.21875
999
496
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 EventType(models.Model): _inherit = 'event.type' booth_menu = fields.Boolean( string='Booths on Website', compute='_compute_booth_menu', readonly=Fals...
29.176471
496
2,310
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.http_routing.models.ir_http import slug class Event(models.Model): _inherit = 'event.event' exhibition_map = fields.Image(string='Exhibition Map', max_w...
42
2,310
323
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 EventMenu(models.Model): _inherit = "website.event.menu" menu_type = fields.Selection( selection_add=[('booth', 'Event Booth Menus')], ondelete={'booth': 'cascade'...
29.363636
323
7,626
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import json import werkzeug from werkzeug.exceptions import Forbidden, NotFound from odoo import exceptions, http, _ from odoo.http import request from odoo.addons.website_event.controllers.main import WebsiteEventContr...
45.664671
7,626
974
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'HR Org Chart', 'category': 'Hidden', 'version': '1.0', 'description': """ Org Chart Widget for HR ======================= This module extend the employee form with a organizational cha...
26.324324
974
1,277
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tests import Form, tagged, TransactionCase from odoo.exceptions import MissingError @tagged('post_install', '-at_install') class TestEmployeeDeletion(TransactionCase): def test_employee_deletion(self): ...
32.74359
1,277
696
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 Employee(models.Model): _inherit = ["hr.employee"] subordinate_ids = fields.One2many('hr.employee', string='Subordinates', compute='_compute_subordinates', help="Direct an...
38.666667
696
1,584
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 HrEmployeeBase(models.AbstractModel): _inherit = "hr.employee.base" child_all_count = fields.Integer( 'Indirect Subordinates Count', compute='_compute...
40.615385
1,584
3,651
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import http from odoo.exceptions import AccessError from odoo.http import request class HrOrgChartController(http.Controller): _managers_level = 5 # FP request def _check_employee(self, employee_id,...
36.51
3,651
657
py
PYTHON
15.0
#-*- coding:utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (C) 2013-2015 Akretion (http://www.akretion.com) { 'name': 'France - FEC Export', 'icon': '/l10n_fr/static/description/icon.png', 'category': 'Accounting/Localizations/Reporting', 'summary': "F...
32.75
655
3,862
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import base64 from datetime import timedelta from freezegun import freeze_time from odoo.addons.account.tests.common import AccountTestInvoicingCommon from odoo.tests import tagged from odoo import fields, Command @ta...
48.2625
3,861
19,320
py
PYTHON
15.0
#-*- coding:utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (C) 2013-2015 Akretion (http://www.akretion.com) import base64 import io from odoo import api, fields, models, _ from odoo.exceptions import UserError, AccessDenied from odoo.tools import float_is_zero, pycom...
44.825986
19,320
2,258
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (C) 2009 Renato Lima - Akretion { 'name': 'Brazilian - Accounting', 'category': 'Accounting/Localizations/Account Charts', 'description': """ Base module for the Brazilian localization =========...
37.016393
2,258
1,360
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 AccountTaxTemplate(models.Model): """ Add fields used to define some brazilian taxes """ _inherit = 'account.tax.template' tax_discount = fields.Boolean(string='Discou...
48.571429
1,360
2,456
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Denmark - Accounting', 'version': '1.0', 'author': 'Odoo House ApS, VK DATA ApS', 'website': 'http://odoodanmark.dk', 'category': 'Accounting/Localizations/Account Charts', 'description...
22.394495
2,441
769
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models class AccountJournal(models.Model): _inherit = 'account.journal' @api.model def _prepare_liquidity_account_vals(self, company, code, vals): # OVERRIDE account_v...
36.619048
769
683
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models class AccountChartTemplate(models.Model): _inherit = 'account.chart.template' @api.model def _prepare_transfer_account_for_direct_creation(self, name, company): res = s...
40.176471
683
1,705
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Thanks to AEOdoo and the Spanish community # Specially among others Ignacio Ibeas, Pedro Baeza and Landoo { 'name': "Spain - SII EDI Suministro de Libros", 'version': '1.0', 'category': 'Accounting/Localiz...
36.234043
1,703
3,277
py
PYTHON
15.0
# -*- coding: utf-8 -*- from datetime import datetime from odoo.tests import tagged from odoo import fields from .common import TestEsEdiCommon @tagged('external_l10n', 'post_install', '-at_install', '-standard', 'external') class TestEdiWebServices(TestEsEdiCommon): @classmethod def setUpClass(cls, chart_t...
42.012821
3,277
49,679
py
PYTHON
15.0
# coding: utf-8 from .common import TestEsEdiCommon import json from freezegun import freeze_time from unittest.mock import patch from odoo.tests import tagged def mocked_l10n_es_edi_call_web_service_sign(edi_format, invoices, info_list): return {inv: {'success': True} for inv in invoices} @tagged('post_inst...
46.955577
49,679
2,764
py
PYTHON
15.0
# coding: utf-8 import base64 from pytz import timezone from datetime import datetime from odoo.tests import tagged from odoo.tools import misc, float_compare from odoo.addons.account_edi.tests.common import AccountEdiTestCommon @tagged('post_install_l10n', 'post_install', '-at_install') class TestEsEdiCommon(Accoun...
35.896104
2,764
1,975
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 SIIAccountTaxMixin(models.AbstractModel): _name = 'l10n_es.sii.account.tax.mixin' _description = 'SII Fields' l10n_es_exempt_reason = fields.Selection( selectio...
35.909091
1,975
1,456
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 AccountMove(models.Model): _inherit = 'account.move' l10n_es_edi_is_required = fields.Boolean( string="Is the Spanish EDI needed", compute='_compute_l...
40.444444
1,456
33,473
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from collections import defaultdict from urllib3.util.ssl_ import create_urllib3_context, DEFAULT_CIPHERS from urllib3.contrib.pyopenssl import inject_into_urllib3 from OpenSSL.crypto import load_certificate, load_private...
48.231988
33,473
3,675
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from base64 import b64decode from pytz import timezone from datetime import datetime from cryptography.hazmat.backends import default_backend from cryptography.hazmat.primitives.serialization import Encoding, NoEncryptio...
42.241379
3,675
1,527
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' l10n_es_edi_certificate_id = fields.Many2one( string="Certificate (ES)", store=True, readonl...
33.911111
1,526
469
py
PYTHON
15.0
# -*- coding: utf-8 -*- from odoo import fields, models class ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' l10n_es_edi_certificate_ids = fields.One2many(related='company_id.l10n_es_edi_certificate_ids', readonly=False) l10n_es_edi_tax_agency = fields.Selection(related='comp...
42.636364
469
715
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Skills Certification', 'category': 'Hidden', 'version': '1.0', 'summary': 'Add certification to resumé of your employees', 'description': """ Certification and Skills for HR =======...
25.464286
713
1,838
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.tools import html2plaintext class SurveyUserInput(models.Model): _inherit = 'survey.user_input' def _mark_done(self): """ Will add certification to employee's ...
44.804878
1,837
903
py
PYTHON
15.0
# -*- coding: utf-8 -*- { 'name': "delivery_mondialrelay", 'summary': """ Let's choose a Point Relais® as shipping address """, 'description': """ This module allow your customer to choose a Point Relais® and use it as shipping address. This module doesn't implement the WebService. It is on...
33.37037
901
2,746
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models, api, _ from odoo.tools.json import scriptsafe as json_safe from odoo.exceptions import ValidationError class ChooseDeliveryCarrier(models.TransientModel): _inherit = 'choose.deliver...
45.016393
2,746
675
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.exceptions import UserError class SaleOrderMondialRelay(models.Model): _inherit = 'sale.order' def action_confirm(self): unmatch = self.filtered(lambda so: so.carri...
37.5
675
1,244
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models, api class DeliveryCarrierMondialRelay(models.Model): _inherit = 'delivery.carrier' is_mondialrelay = fields.Boolean(compute='_compute_is_mondialrelay') mondialrelay_brand =...
42.896552
1,244
1,501
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models, api class ResPartnerMondialRelay(models.Model): _inherit = 'res.partner' is_mondialrelay = fields.Boolean(compute='_compute_is_mondialrelay') @api.depends('ref') def _...
34.113636
1,501
584
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Indian - UPI', 'version': '1.0', 'description': """ Invoice with UPI QR code ========================= This module adds QR code in invoice report for UPI payment allowing to make payment via any UPI...
32.444444
584
925
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import base64 from odoo import models from odoo.tools.image import image_data_uri class AccountMove(models.Model): _inherit = "account.move" def generate_qr_code(self): self.ensure_one() if sel...
40.217391
925
243
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' l10n_in_upi_id = fields.Char(string="UPI Id")
24.3
243
1,013
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Sales Expense', 'version': '1.0', 'category': 'Sales/Sales', 'summary': 'Quotation, Sales Orders, Delivery & Invoicing Control', 'description': """ Reinvoice Employee Expense ==============...
28.942857
1,013
5,103
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.hr_expense.tests.common import TestExpenseCommon from odoo.addons.sale.tests.common import TestSaleCommon from odoo.tests import tagged @tagged('post_install', '-at_install') class TestSaleExpense(Test...
50.029412
5,103
5,057
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.hr_expense.tests.common import TestExpenseCommon from odoo.addons.sale.tests.common import TestSaleCommon from odoo.tests import tagged @tagged('-at_install', 'post_install') class TestReInvoice(TestEx...
43.222222
5,057
1,875
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models class AccountMoveLine(models.Model): _inherit = 'account.move.line' def _sale_can_be_reinvoice(self): """ determine if the generated analytic line should be reinvoiced or n...
48.076923
1,875
2,503
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 Expense(models.Model): _inherit = "hr.expense" sale_order_id = fields.Many2one('sale.order', compute='_compute_sale_order_id', store=True, string='Customer to Reinvoi...
54.413043
2,503
1,771
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 import SUPERUSER_ID from odoo.osv import expression class SaleOrder(models.Model): _inherit = 'sale.order' expense_ids = fields.One2many('hr.expense', 'sale_order...
63.25
1,771
814
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models class ProductTemplate(models.Model): _inherit = 'product.template' @api.depends('can_be_expensed') def _compute_visible_expense_policy(self): expense_products = self.fi...
40.7
814
720
py
PYTHON
15.0
#-*- coding:utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Work Entries', 'category': 'Human Resources/Employees', 'sequence': 39, 'summary': 'Manage work entries', 'description': "", 'installable': True, 'depends': [ 'hr', ], ...
25.714286
720
1,069
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 ResourceCalendarAttendance(models.Model): _inherit = 'resource.calendar.attendance' def _default_work_entry_type_id(self): return self.env.ref('hr_work_entry.work_e...
32.393939
1,069
590
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, _ class HrEmployee(models.Model): _inherit = 'hr.employee' def action_open_work_entries(self): self.ensure_one() return { 'type': 'ir.actions.act_window', ...
32.777778
590
11,095
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from contextlib import contextmanager from dateutil.relativedelta import relativedelta import itertools from psycopg2 import OperationalError from odoo import api, fields, models, tools, _ class HrWorkEntry(models.Mod...
45.847107
11,095
548
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Mass mailing on track speakers', 'category': 'Hidden', 'version': '1.0', 'description': """ Mass mail event track speakers ============================== Bridge module adding UX requir...
26.095238
548
750
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class Event(models.Model): _inherit = "event.event" def action_mass_mailing_track_speakers(self): mass_mailing_action = dict( name='Mass Mail Attendees', ...
34.090909
750
320
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class EventTrack(models.Model): _inherit = 'event.track' _mailing_enabled = True def _mailing_get_default_domain(self, mailing): return [('stage_id.is_cancel', '=', False)]
26.666667
320
534
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': "Calendar - SMS", 'version': "1.1", 'summary': 'Send text messages as event reminders', 'description': "Send text messages as event reminders", 'category': 'Hidden', 'depends': ['calenda...
28.105263
534
1,246
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import datetime from odoo.tests.common import SingleTransactionCase class TestCalendarSms(SingleTransactionCase): @classmethod def setUpClass(cls): super(TestCalendarSms, cls).setUpClass...
37.757576
1,246
896
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models class AlarmManager(models.AbstractModel): _inherit = 'calendar.alarm_manager' @api.model def _send_reminder(self): """ Cron method, overridden here to send SMS reminder...
37.333333
896
1,791
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.exceptions import UserError class CalendarEvent(models.Model): _inherit = 'calendar.event' def _sms_get_default_partners(self): """ Method overridden from mail.threa...
40.704545
1,791
1,052
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 CalendarAlarm(models.Model): _inherit = 'calendar.alarm' alarm_type = fields.Selection(selection_add=[ ('sms', 'SMS Text Message') ], ondelete={'sms': 'se...
42.08
1,052
1,196
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'Google Calendar', 'version': '1.0', 'category': 'Productivity', 'description': "", 'depends': ['google_account', 'calendar'], 'data': [ 'data/google_calendar_data.xml', ...
31.473684
1,196
3,203
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from unittest.mock import MagicMock, patch from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService from odoo.addons.google_account.models.google_service import GoogleService from odoo.addons....
42.144737
3,203
71,245
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, date from dateutil.relativedelta import relativedelta from odoo.tests.common import new_test_user from odoo.addons.google_calendar.tests.test_sync_common import TestSyncGoogle,...
46.113269
71,245
26,237
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from datetime import datetime from dateutil.relativedelta import relativedelta from unittest.mock import patch from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService from odoo.addons.google_...
42.046474
26,237
2,091
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.google_calendar.models.google_sync import google_calendar_token from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService class ResetGoogleAcc...
40.211538
2,091
9,717
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.tools import email_normalize import logging from typing import Iterator, Mapping from collections import abc import re _logger = logging.getLogger(__name__) class GoogleEvent(abc.Set): """This helper cla...
41.883621
9,717
5,099
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from uuid import uuid4 import requests import json import logging from odoo import fields from odoo.tools import exception_to_unicode from odoo.addons.google_calendar.utils.google_event import GoogleEvent from odoo.addo...
44.72807
5,099
15,960
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging from contextlib import contextmanager from functools import wraps from requests import HTTPError import pytz from dateutil.parser import parse from odoo import api, fields, models, registry, _ from odoo.t...
46.395349
15,960
4,045
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import logging import requests from datetime import timedelta from odoo import fields, models, _ from odoo.exceptions import UserError from odoo.addons.google_account.models.google_service import GOOGLE_TOKEN_ENDPOINT f...
50.5625
4,045
2,177
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.addons.google_calendar.models.google_sync import google_calendar_token from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService class Attendee(models.Model):...
42.686275
2,177
14,204
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import pytz from dateutil.parser import parse from dateutil.relativedelta import relativedelta from odoo import api, fields, models, tools, _ class Meeting(models.Model): _name = 'calendar.event' _inherit = ['...
49.838596
14,204
5,463
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, Command from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService, InvalidSyncToken from odoo.addons.google_calendar.models.google_sync imp...
51.056075
5,463
440
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 ResConfigSettings(models.TransientModel): _inherit = 'res.config.settings' cal_client_id = fields.Char("Client_id", config_parameter='google_calendar_client_id', defa...
40
440
11,388
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import re from odoo import api, models, Command from odoo.tools import email_normalize from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService class RecurrenceRule(models.Model): _name ...
50.167401
11,388
2,631
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import http from odoo.http import request from odoo.addons.google_calendar.utils.google_calendar import GoogleCalendarService class GoogleCalendarController(http.Controller): @http.route('/google_calenda...
45.362069
2,631
1,038
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': 'OdooBot', 'version': '1.2', 'category': 'Productivity/Discuss', 'summary': 'Add OdooBot in discussions', 'description': "", 'website': 'https://www.odoo.com/app/discuss', 'depends':...
27.315789
1,038
438
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class Http(models.AbstractModel): _inherit = 'ir.http' def session_info(self): res = super(Http, self).session_info() if self.env.user.has_group('base.group_user'): ...
31.285714
438
396
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models class MailThread(models.AbstractModel): _inherit = 'mail.thread' def _message_post_after_hook(self, message, msg_vals): self.env['mail.bot']._apply_logic(self, msg_vals) ...
33
396
895
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 Users(models.Model): _inherit = 'res.users' odoobot_state = fields.Selection( [ ('not_initialized', 'Not initialized'), ('onboarding_emoji',...
38.913043
895
12,500
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import itertools import random from odoo import models, _ class MailBot(models.AbstractModel): _name = 'mail.bot' _description = 'Mail Bot' def _apply_logic(self, record, values, command=None): ""...
52.42437
12,477
1,142
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, models, _ class Channel(models.Model): _inherit = 'mail.channel' def execute_command_help(self, **kwargs): super().execute_command_help(**kwargs) self.env['mail.bot']._app...
49.652174
1,142
902
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # Copyright (c) 2011 Cubic ERP - Teradata SAC. (https://cubicerp.com). { "name": "Bolivia - Accounting", "version": "2.0", "description": """ Bolivian accounting chart and tax localization. Plan contable bo...
29.096774
902
858
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. { 'name': "Events Booths", 'category': 'Marketing/Events', 'version': '1.0', 'summary': "Manage event booths", 'description': """ Create booths for your favorite event. """, 'depends': ['event...
28.6
858
997
py
PYTHON
15.0
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo.addons.event.tests.common import TestEventCommon class TestEventBoothCommon(TestEventCommon): @classmethod def setUpClass(cls): super(TestEventBoothCommon, cls).setUpClass() cls.even...
33.233333
997
4,180
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.tests.common import TestEventBoothCommon from odoo.fields import Datetime as FieldsDatetime from odoo.tests.common import us...
44.946237
4,180
2,505
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.addons.event_booth.tests.common import TestEventBoothCommon from odoo.fields import Datetime as FieldsDatetime from odoo.tests.common import users, tagged @tagged('po...
43.947368
2,505
336
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 EventType(models.Model): _inherit = 'event.type' event_type_booth_ids = fields.One2many( 'event.type.booth', 'event_type_id', string='Booths', readonly=Fal...
28
336