Add creatable attribute on tree and form views
issue10929 review370201002
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
* Add creatable attribute on tree and form views
|
||||
* Fill local cache of Function field instances with values
|
||||
* Cache Function field getter without context in readonly transactions
|
||||
* Use expire delay instead of UTC datetime in reset password email
|
||||
|
||||
@@ -204,6 +204,9 @@ Each form view must start with this tag.
|
||||
The method must be registered in :attr:`trytond.model.Model.__rpc__`.
|
||||
..
|
||||
|
||||
* ``creatable``: A boolean to specify if the form can be used to create new
|
||||
record. The default value is ``true``.
|
||||
|
||||
* ``col``: see in common-attributes-col_.
|
||||
|
||||
* ``cursor``: The name of the field that must have the cursor by default.
|
||||
@@ -586,6 +589,9 @@ Each tree view must start with this tag.
|
||||
|
||||
* ``editable``: A boolean to specify if the list is editable.
|
||||
|
||||
* ``creatable``: A boolean to specify if the editable list can be used to
|
||||
create new record. The default value is ``true``.
|
||||
|
||||
* ``sequence``: The name of the field that is used for sorting. This field
|
||||
must be an integer and it will be updated to match the new sort order
|
||||
when the user uses ``Drag and Drop`` on list rows.
|
||||
|
||||
@@ -16,6 +16,8 @@ form =
|
||||
| vpaned)*
|
||||
}
|
||||
attlist.form &= attribute on_write { text }?
|
||||
attlist.form &=
|
||||
[ a:defaultValue = "1" ] attribute creatable { "0" | "1" }?
|
||||
attlist.form &= [ a:defaultValue = "4" ] attribute col { text }?
|
||||
attlist.form &= attribute cursor { text }?
|
||||
|
||||
|
||||
@@ -30,6 +30,17 @@
|
||||
</attribute>
|
||||
</optional>
|
||||
</define>
|
||||
<define name="attlist.form" combine="interleave">
|
||||
<optional>
|
||||
<attribute a:defaultValue="1">
|
||||
<name ns="">creatable</name>
|
||||
<choice>
|
||||
<value>0</value>
|
||||
<value>1</value>
|
||||
</choice>
|
||||
</attribute>
|
||||
</optional>
|
||||
</define>
|
||||
<define name="attlist.form" combine="interleave">
|
||||
<optional>
|
||||
<attribute a:defaultValue="4">
|
||||
|
||||
@@ -6,6 +6,8 @@ tree = element tree { attlist.tree,
|
||||
}
|
||||
attlist.tree &= attribute on_write { text }?
|
||||
attlist.tree &= attribute editable { "0" | "1" }?
|
||||
attlist.tree &=
|
||||
[ a:defaultValue = "1" ] attribute creatable { "0" | "1" }?
|
||||
attlist.tree &= attribute sequence { text }?
|
||||
attlist.tree &=
|
||||
[ a:defaultValue = "0" ] attribute keyword_open { "0" | "1" }?
|
||||
|
||||
@@ -33,6 +33,17 @@
|
||||
</attribute>
|
||||
</optional>
|
||||
</define>
|
||||
<define name="attlist.tree" combine="interleave">
|
||||
<optional>
|
||||
<attribute a:defaultValue="1">
|
||||
<name ns="">creatable</name>
|
||||
<choice>
|
||||
<value>0</value>
|
||||
<value>1</value>
|
||||
</choice>
|
||||
</attribute>
|
||||
</optional>
|
||||
</define>
|
||||
<define name="attlist.tree" combine="interleave">
|
||||
<optional>
|
||||
<attribute>
|
||||
|
||||
Reference in New Issue
Block a user