mirror of https://github.com/OCA/web.git
commit
8d18bad799
|
@ -220,6 +220,7 @@ Contributors
|
|||
- Adrià Gil Sorribes <adria.gil@forgeflow.com>
|
||||
- Christopher Ormaza <chris.ormaza@forgeflow.com>
|
||||
- SodexisTeam <dev@sodexis.com>
|
||||
- Jasmin Solanki <jasmin.solanki@forgeflow.com>
|
||||
|
||||
Maintainers
|
||||
-----------
|
||||
|
@ -234,13 +235,13 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
|
|||
mission is to support the collaborative development of Odoo features and
|
||||
promote its widespread use.
|
||||
|
||||
.. |maintainer-ChrisOForgeFlow| image:: https://github.com/ChrisOForgeFlow.png?size=40px
|
||||
:target: https://github.com/ChrisOForgeFlow
|
||||
:alt: ChrisOForgeFlow
|
||||
.. |maintainer-JasminSForgeFlow| image:: https://github.com/JasminSForgeFlow.png?size=40px
|
||||
:target: https://github.com/JasminSForgeFlow
|
||||
:alt: JasminSForgeFlow
|
||||
|
||||
Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:
|
||||
|
||||
|maintainer-ChrisOForgeFlow|
|
||||
|maintainer-JasminSForgeFlow|
|
||||
|
||||
This module is part of the `OCA/web <https://github.com/OCA/web/tree/17.0/web_widget_x2many_2d_matrix>`_ project on GitHub.
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
{
|
||||
"name": "2D matrix for x2many fields",
|
||||
"version": "17.0.1.0.0",
|
||||
"maintainers": ["ChrisOForgeFlow"],
|
||||
"maintainers": ["JasminSForgeFlow"],
|
||||
"development_status": "Production/Stable",
|
||||
"author": (
|
||||
"Therp BV, "
|
||||
|
|
|
@ -10,3 +10,4 @@
|
|||
- Adrià Gil Sorribes \<<adria.gil@forgeflow.com>\>
|
||||
- Christopher Ormaza \<<chris.ormaza@forgeflow.com>\>
|
||||
- SodexisTeam \<<dev@sodexis.com>\>
|
||||
- Jasmin Solanki \<<jasmin.solanki@forgeflow.com>\>
|
|
@ -8,10 +8,11 @@
|
|||
|
||||
/*
|
||||
:Author: David Goodger (goodger@python.org)
|
||||
:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $
|
||||
:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $
|
||||
:Copyright: This stylesheet has been placed in the public domain.
|
||||
|
||||
Default cascading style sheet for the HTML output of Docutils.
|
||||
Despite the name, some widely supported CSS2 features are used.
|
||||
|
||||
See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to
|
||||
customize this style sheet.
|
||||
|
@ -274,7 +275,7 @@ pre.literal-block, pre.doctest-block, pre.math, pre.code {
|
|||
margin-left: 2em ;
|
||||
margin-right: 2em }
|
||||
|
||||
pre.code .ln { color: grey; } /* line numbers */
|
||||
pre.code .ln { color: gray; } /* line numbers */
|
||||
pre.code, code { background-color: #eeeeee }
|
||||
pre.code .comment, code .comment { color: #5C6576 }
|
||||
pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold }
|
||||
|
@ -300,7 +301,7 @@ span.option {
|
|||
span.pre {
|
||||
white-space: pre }
|
||||
|
||||
span.problematic {
|
||||
span.problematic, pre.problematic {
|
||||
color: red }
|
||||
|
||||
span.section-subtitle {
|
||||
|
@ -574,17 +575,20 @@ If you spotted it first, help us to smash it by providing a detailed and welcome
|
|||
<li>Adrià Gil Sorribes <<a class="reference external" href="mailto:adria.gil@forgeflow.com">adria.gil@forgeflow.com</a>></li>
|
||||
<li>Christopher Ormaza <<a class="reference external" href="mailto:chris.ormaza@forgeflow.com">chris.ormaza@forgeflow.com</a>></li>
|
||||
<li>SodexisTeam <<a class="reference external" href="mailto:dev@sodexis.com">dev@sodexis.com</a>></li>
|
||||
<li>Jasmin Solanki <<a class="reference external" href="mailto:jasmin.solanki@forgeflow.com">jasmin.solanki@forgeflow.com</a>></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="maintainers">
|
||||
<h2><a class="toc-backref" href="#toc-entry-11">Maintainers</a></h2>
|
||||
<p>This module is maintained by the OCA.</p>
|
||||
<a class="reference external image-reference" href="https://odoo-community.org"><img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" /></a>
|
||||
<a class="reference external image-reference" href="https://odoo-community.org">
|
||||
<img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" />
|
||||
</a>
|
||||
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
|
||||
mission is to support the collaborative development of Odoo features and
|
||||
promote its widespread use.</p>
|
||||
<p>Current <a class="reference external" href="https://odoo-community.org/page/maintainer-role">maintainer</a>:</p>
|
||||
<p><a class="reference external image-reference" href="https://github.com/ChrisOForgeFlow"><img alt="ChrisOForgeFlow" src="https://github.com/ChrisOForgeFlow.png?size=40px" /></a></p>
|
||||
<p><a class="reference external image-reference" href="https://github.com/JasminSForgeFlow"><img alt="JasminSForgeFlow" src="https://github.com/JasminSForgeFlow.png?size=40px" /></a></p>
|
||||
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/web/tree/17.0/web_widget_x2many_2d_matrix">OCA/web</a> project on GitHub.</p>
|
||||
<p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>
|
||||
</div>
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
showRowTotals="props.showRowTotals"
|
||||
showColumnTotals="props.showColumnTotals"
|
||||
readonly="props.readonly"
|
||||
domain="props.domain"
|
||||
/>
|
||||
</div>
|
||||
</t>
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
|
||||
import {Component, onWillUpdateProps} from "@odoo/owl";
|
||||
import {registry} from "@web/core/registry";
|
||||
import {Domain} from "@web/core/domain";
|
||||
import {evaluateExpr} from "@web/core/py_js/py";
|
||||
const fieldRegistry = registry.category("fields");
|
||||
|
||||
export class X2Many2DMatrixRenderer extends Component {
|
||||
|
@ -162,6 +164,12 @@ export class X2Many2DMatrixRenderer extends Component {
|
|||
record: record,
|
||||
name: this.matrixFields.value,
|
||||
};
|
||||
const domain = record.fields[this.matrixFields.value].domain;
|
||||
if (domain) {
|
||||
result.domain = new Domain(
|
||||
evaluateExpr(domain, record.evalContext)
|
||||
).toList();
|
||||
}
|
||||
if (value === null) {
|
||||
result.readonly = true;
|
||||
}
|
||||
|
@ -174,6 +182,7 @@ X2Many2DMatrixRenderer.props = {
|
|||
list: {type: Object, optional: true},
|
||||
matrixFields: {type: Object, optional: true},
|
||||
readonly: {type: Boolean, optional: true},
|
||||
domain: {type: [Array, Function], optional: true},
|
||||
showRowTotals: {type: Boolean, optional: true},
|
||||
showColumnTotals: {type: Boolean, optional: true},
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue