Skip to content

Commit 9fcbad4

Browse files
committed
[NEW] Add kanban and kanban inherit views snippets
1 parent cead677 commit 9fcbad4

File tree

2 files changed

+35
-0
lines changed

2 files changed

+35
-0
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ Below is a list of all available snippets.
7272
| `ographi` | Inherit Existing Graph View |
7373
| `opivot` | Create Pivot View |
7474
| `opivoti` | Inherit Existing Pivot View |
75+
| `okanban` | Create Kanban View |
76+
| `okanbani` | Inherit Existing Kanban View |
7577
| `oxpath` | Add the structure of xpath |
7678
| `oxpathattr` | Add the structure of xpath to attributes |
7779
| `oact` | Create new Action |

snippets/xml.json

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,39 @@
168168
],
169169
"description": "Inherit Existing Pivot View"
170170
},
171+
"odoo_kanban": {
172+
"prefix": "okanban",
173+
"body": [
174+
"<!-- ${1:model.name} kanban view -->",
175+
"<record id=\"${2:model_name}_view_kanban\" model=\"ir.ui.view\">",
176+
"\t<field name=\"name\">${1:first.name}.view.kanban</field>",
177+
"\t<field name=\"model\">${1:first.name}</field>",
178+
"\t<field name=\"arch\" type=\"xml\">",
179+
"\t\t<kanban string=\"${3:Kanban Description}\">",
180+
"\t\t\t<!-- Add your fields here -->",
181+
"\t\t\t$0",
182+
"\t\t</kanban>",
183+
"\t</field>",
184+
"</record>"
185+
],
186+
"description": "Create Kanban View"
187+
},
188+
"odoo_kanban_inherit": {
189+
"prefix": "okanbani",
190+
"body": [
191+
"<!-- ${1:model.name} inherit kanban view -->",
192+
"<record id=\"${2:view_id}\" model=\"ir.ui.view\">",
193+
"\t<field name=\"name\">${1:model.name}.inherit.view.kanban</field>",
194+
"\t<field name=\"model\">${1:model.name}</field>",
195+
"\t<field name=\"inherit_id\" ref=\"${3:base_module}.${2:view_id}\"/>",
196+
"\t<field name=\"arch\" type=\"xml\">",
197+
"\t\t<!-- Add you xpath here -->",
198+
"\t\t$0",
199+
"\t</field>",
200+
"</record>"
201+
],
202+
"description": "Inherit Existing Kanban View"
203+
},
171204
"odoo_xpath": {
172205
"prefix": "oxpath",
173206
"body": [

0 commit comments

Comments
 (0)