This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Should-Stop: $network | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Enterprise Business Applications | |
# Description: ODOO Business Applications | |
### END INIT INFO | |
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin | |
DAEMON=/odoo/odoo-server/odoo-bin | |
NAME=odoo-server | |
DESC=odoo-server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// like import file | |
require_once('lib/ripcord.php'); | |
// define variables to use in future | |
$url = "http://localhost:8015"; | |
$db = "o14_api"; | |
$username = "admin"; | |
$password = "admin"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
odoo.define('my.component', function (require) { | |
"use strict"; | |
const { Component, useState } = owl; | |
const { xml } = owl.tags; | |
const { patch } = require('web.utils'); | |
// import { patch } from "@web/core/utils/patch"; | |
class MyComponent extends Component { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<record id="your_model_view_form_firebits" model="ir.ui.view"> | |
<field name="name">your_model.view.form.inherit.firebits</field> | |
<field name="model">your_model</field> | |
<field name="priority" eval="25"/> | |
<field name="inherit_id" ref="your_model_view_external_id"/> | |
<field name="arch" type="xml"> | |
<xpath expr="//div[hasclass('your_class')]" position="inside"> | |
# your field | |
</xpath> | |
</field> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<section class="oe_container oe_dark"> | |
<div class="col-md-12"> | |
<h2 class="oe_slogan" style="font-size: 35px;color:#781E4F"><b>Odoo 15</b></h2> | |
</div> | |
</section> | |
<section class="oe_container"> | |
<div class="oe_row oe_spaced"> | |
<div class="oe_span12"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import json | |
import logging | |
import base64 | |
from odoo import http, tools, _ | |
from odoo.http import request | |
_logger = logging.getLogger(__name__) | |
class UtilsApi(http.Controller): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Import required modules | |
from lxml import html | |
import requests | |
import json | |
class Utils(): | |
cookies = {'session_id': ''} | |
def getUsers(self): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def create_invoice(self): | |
move_dict = { | |
'narration': "Name", | |
'ref': name, | |
'journal_id': journal_id.id, | |
'date': date, | |
} | |
line_ids = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class your_model_class_name (models.Model): | |
_name = "your_model_name" | |
@api.model | |
def create(self, vals): | |
if vals.get('seq', 'New') == 'New': | |
vals['seq'] = self.env['ir.sequence'].next_by_code('example.seq') or '/' | |
newId = super(your_model_class_name, self).create(vals) | |
return newId |