Skip to content

Commit

Permalink
[ADD] Addon: sale_partial_lock
Browse files Browse the repository at this point in the history
  • Loading branch information
Tiago Amaral committed Sep 17, 2024
1 parent 577cc99 commit 1ef6dea
Show file tree
Hide file tree
Showing 7 changed files with 83 additions and 0 deletions.
7 changes: 7 additions & 0 deletions l10n_br_di/static/description/index.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="Docutils: https://docutils.sourceforge.io/" />
<title>Declaração de Importação</title>
<style type="text/css">

/*
:Author: David Goodger ([email protected])
Expand Down
23 changes: 23 additions & 0 deletions sale_partial_lock/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
=================
Sale Partial Lock
=================

KMEE

Configuration
=============

To configure this module, you need to:

#. Go to ...

Usage
=====

To use this module, you need to:

#. Go to ...


Changelog
=========
Empty file added sale_partial_lock/__init__.py
Empty file.
17 changes: 17 additions & 0 deletions sale_partial_lock/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Copyright 2024 KMEE
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

{
"name": "Sale Partial Lock",
"version": "14.0.1.0.0",
"license": "AGPL-3",
"author": "KMEE",
"website": "https://github.com/KMEE/kmee-odoo-addons",
"depends": [
"sale",
],
"data": [
"views/sale_order.xml",
],
"demo": [],
}
29 changes: 29 additions & 0 deletions sale_partial_lock/views/sale_order.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="utf-8" ?>
<!-- Copyright 2024 KMEE
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
<odoo>

<record model="ir.ui.view" id="sale_order_line_form_view">
<field name="name">sale.order.form (in sale_partial_lock)</field>
<field name="model">sale.order</field>
<field name="inherit_id" ref="sale.view_order_form" />
<field name="arch" type="xml">
<xpath expr="//form//header//button[@name='action_draft']" position="after">
<button
name="action_cancel"
type="object"
string="Cancel"
states="done"
/>
</xpath>
<xpath
expr='//button[@name="%(sale.action_view_sale_advance_payment_inv)d"][2]'
position="attributes"
>
<attribute
name="attrs"
>{'invisible': ['|',('invoice_status', '!=', 'no'), ('state', 'not in', ('sale', 'done'))]}</attribute>
</xpath>
</field>
</record>
</odoo>
1 change: 1 addition & 0 deletions setup/sale_partial_lock/odoo/addons/sale_partial_lock
6 changes: 6 additions & 0 deletions setup/sale_partial_lock/setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import setuptools

setuptools.setup(
setup_requires=['setuptools-odoo'],
odoo_addon=True,
)

0 comments on commit 1ef6dea

Please sign in to comment.