slider_view.xml 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <openerp>
  3. <data>
  4. <menuitem id="menu_slider_config" name="Slider Configuration" parent="base.menu_base_partner" sequence="40"/>
  5. <!-- Product Category Slider -->
  6. <!-- Product Category Slider Form View-->
  7. <record id="prod_cat_slider_form_view" model="ir.ui.view">
  8. <field name="name">product.category.slider.form.view</field>
  9. <field name="model">product.category.slider.config</field>
  10. <field name="arch" type="xml">
  11. <form string="Product/Category Slider">
  12. <sheet>
  13. <group>
  14. <field name="name"/>
  15. <field name="active"/>
  16. <field name="no_of_counts"/>
  17. <field name="prod_cat_type"/>
  18. <field name="auto_rotate"/>
  19. <field attrs="{'invisible': [('auto_rotate', '=', False)]}" name="sliding_speed"/>
  20. <field attrs="{'invisible': [('prod_cat_type', '=', 'category')], 'required': [('prod_cat_type', '=', 'product')]}" name="collections_product" widget="many2many_tags"/>
  21. <field attrs="{'invisible': [('prod_cat_type', '=', 'product')], 'required': [('prod_cat_type', '=', 'category')]}" name="collections_category" widget="many2many_tags"/>
  22. </group>
  23. </sheet>
  24. </form>
  25. </field>
  26. </record>
  27. <!-- Product Category Slider List View-->
  28. <record id="prod_cat_slider_list_view" model="ir.ui.view">
  29. <field name="name">product.category.slider.list.view</field>
  30. <field name="model">product.category.slider.config</field>
  31. <field name="arch" type="xml">
  32. <tree string="Product/Category Slider">
  33. <field name="name"/>
  34. <field name="no_of_counts"/>
  35. <field name="prod_cat_type"/>
  36. <!-- <field name="auto_rotate"/><field name="sliding_speed"/><field name="collections"/>-->
  37. </tree>
  38. </field>
  39. </record>
  40. <!-- Product Category Slider Action -->
  41. <record id="prod_cat_slider_action" model="ir.actions.act_window">
  42. <field name="name">Slider de Productos por Categoria</field>
  43. <field name="type">ir.actions.act_window</field>
  44. <field name="res_model">product.category.slider.config</field>
  45. <field name="view_type">form</field>
  46. <field name="view_mode">tree,form</field>
  47. <field eval="False" name="view_id"/>
  48. <field name="help" type="html">
  49. <p class="oe_view_nocontent_create">Click para crear un nuevo Slider.
  50. </p>
  51. </field>
  52. </record>
  53. <!-- Product Category menu in slider config -->
  54. <menuitem action="prod_cat_slider_action" id="prod_cat_slider_menu" name="Product/Category Slider Configuraton" parent="kingfisher_pro.menu_slider_config" sequence="60"/>
  55. <!-- Brands slider -->
  56. <record id="product_brandz_search_view" model="ir.ui.view">
  57. <field name="name">product.brands.search.form</field>
  58. <field name="model">product.brands</field>
  59. <field name="arch" type="xml">
  60. <search string="Product Brands">
  61. <field name="name"/>
  62. </search>
  63. </field>
  64. </record>
  65. <!-- Brand Products -->
  66. <act_window domain="[('product_brand_id', '=', active_id)]" id="action_open_brand_products" name="Brand Products" res_model="product.template" view_mode="kanban,form,tree" view_type="form"/>
  67. <!-- Product Brand -->
  68. <act_window domain="[('product_ids', 'in', active_id)]" id="action_open_single_product_brand" name="Product Brand" res_model="product.brands" target="current" view_mode="kanban,form,tree" view_type="form"/>
  69. <!-- Product brand form view -->
  70. <record id="view_product_brands_form_view" model="ir.ui.view">
  71. <field name="name">product.brands.form</field>
  72. <field name="model">product.brands</field>
  73. <field name="arch" type="xml">
  74. <form string="Marca de Producto">
  75. <sheet>
  76. <field class="oe_avatar oe_left" name="brand_logo" widget="image"/>
  77. <div class="oe_title">
  78. <div class="oe_edit_only">
  79. <label for="name" string="Nombre de Marca"/>
  80. </div>
  81. <h1>
  82. <field name="name"/>
  83. </h1>
  84. </div>
  85. <div class="oe_right oe_button_box">
  86. <button class="oe_inline oe_stat_button" icon="fa-cubes" name="%(action_open_brand_products)d" type="action">
  87. <field name="products_count" string="Products" widget="statinfo"/>
  88. </button>
  89. </div>
  90. <group string="Tapa de Marca">
  91. <field height="74px" name="brand_cover" nolabel="1" widget="image"/>
  92. </group>
  93. <group string="Descripción">
  94. <field name="brand_description" nolabel="1"/>
  95. </group>
  96. </sheet>
  97. </form>
  98. </field>
  99. </record>
  100. <!-- Product brand tree view -->
  101. <record id="view_product_brands_tree_view" model="ir.ui.view">
  102. <field name="name">product.brands.tree</field>
  103. <field name="model">product.brands</field>
  104. <field name="arch" type="xml">
  105. <tree string="product.brands">
  106. <field name="name"/>
  107. <field name="brand_description"/>
  108. </tree>
  109. </field>
  110. </record>
  111. <!-- Product brand kanban view -->
  112. <record id="view_product_brands_kanban_view" model="ir.ui.view">
  113. <field name="name">product.brands.kanban</field>
  114. <field name="model">product.brands</field>
  115. <field name="arch" type="xml">
  116. <kanban>
  117. <field name="brand_logo"/>
  118. <field name="products_count"/>
  119. <field name="brand_description"/>
  120. <templates>
  121. <t t-name="kanban-box">
  122. <div class="oe_kanban_vignette oe_semantic_html_override">
  123. <a type="open">
  124. <img class="o_kanban_image" height="74" t-att-src="kanban_image('product.product', 'brand_logo', record.id.value)" width="74"/>
  125. </a>
  126. <div class="oe_kanban_details">
  127. <h4>
  128. <a type="open">
  129. <field name="name"/>
  130. </a>
  131. </h4>
  132. <div>
  133. <a name="%(kingfisher_pro.action_open_brand_products)d" type="action">
  134. <t t-esc="record.products_count.value"/>Productos</a>
  135. </div>
  136. <span>
  137. <t t-raw="record.brand_description.value.substr(0,200)"/>
  138. <t t-if="record.brand_description.value.length &gt;200">
  139. <a type="open">
  140. <b>...</b>
  141. </a>
  142. </t>
  143. </span>
  144. </div>
  145. </div>
  146. </t>
  147. </templates>
  148. </kanban>
  149. </field>
  150. </record>
  151. <!-- Product brand search view -->
  152. <record id="inherit_product_search_view" model="ir.ui.view">
  153. <field name="name">inherited.product.search.form</field>
  154. <field name="model">product.product</field>
  155. <field name="inherit_id" ref="product.product_search_form_view"/>
  156. <field name="arch" type="xml">
  157. <field name="name" position="after">
  158. <field name="product_brand_id"/>
  159. </field>
  160. <field name="categ_id" position="before">
  161. <filter context="{'group_by' : 'product_brand_id'}" domain="[]" name="groupby_brand" string="Brands"/>
  162. </field>
  163. </field>
  164. </record>
  165. <!-- Product template inherited search view -->
  166. <record id="inherited_view_product_template_search_brand" model="ir.ui.view">
  167. <field name="name">product.template.search.brand</field>
  168. <field name="model">product.template</field>
  169. <field name="inherit_id" ref="product.product_template_search_view"/>
  170. <field name="arch" type="xml">
  171. <field name="name" position="after">
  172. <field name="product_brand_id"/>
  173. </field>
  174. <field name="categ_id" position="before">
  175. <filter context="{'group_by' : 'product_brand_id'}" domain="[]" name="groupby_brand" string="Brand"/>
  176. </field>
  177. </field>
  178. </record>
  179. <!-- Product product inherited search view -->
  180. <record id="inherited_product_template_form_brand_add" model="ir.ui.view">
  181. <field name="name">product.template.product.form</field>
  182. <field name="model">product.template</field>
  183. <field name="inherit_id" ref="product.product_template_form_view"/>
  184. <field name="arch" type="xml">
  185. <field name="name" position="after">
  186. <field name="product_brand_id" placeholder="Brand"/>
  187. </field>
  188. </field>
  189. </record>
  190. <!-- Product template inherited kanban view -->
  191. <record id="inherited_view_product_template_kanban_brand" model="ir.ui.view">
  192. <field name="name">product kanban view: add brand</field>
  193. <field name="model">product.template</field>
  194. <field name="inherit_id" ref="product.product_template_kanban_view"/>
  195. <field name="arch" type="xml">
  196. <xpath expr="//h4" position="after">
  197. <div>
  198. <a name="%(action_open_single_product_brand)d" t-if="record.product_brand_id" type="action">
  199. <field name="product_brand_id"/>
  200. </a>
  201. </div>
  202. </xpath>
  203. </field>
  204. </record>
  205. <!-- Product product inherited kanban view -->
  206. <record id="inherited_view_product_variant_kanban_brand" model="ir.ui.view">
  207. <field name="name">product variant kanban view: add brand</field>
  208. <field name="model">product.product</field>
  209. <field name="inherit_id" ref="product.product_kanban_view"/>
  210. <field name="arch" type="xml">
  211. <xpath expr="//h4" position="after">
  212. <div>
  213. <a t-if="record.product_brand_id" type="open">
  214. <field name="product_brand_id"/>
  215. </a>
  216. </div>
  217. </xpath>
  218. </field>
  219. </record>
  220. <!-- Product template inherited tree view -->
  221. <record id="inherited_view_product_template_tree_brand" model="ir.ui.view">
  222. <field name="name">product tree view: add brand</field>
  223. <field name="model">product.template</field>
  224. <field name="inherit_id" ref="product.product_template_tree_view"/>
  225. <field name="arch" type="xml">
  226. <field name="name" position="after">
  227. <field name="product_brand_id"/>
  228. </field>
  229. </field>
  230. </record>
  231. <!-- Product product inherited tree view -->
  232. <record id="inherited_view_product_variant_tree_brand" model="ir.ui.view">
  233. <field name="name">product variant tree view: add brand</field>
  234. <field name="model">product.product</field>
  235. <field name="inherit_id" ref="product.product_product_tree_view"/>
  236. <field name="arch" type="xml">
  237. <field name="name" position="after">
  238. <field name="product_brand_id"/>
  239. </field>
  240. </field>
  241. </record>
  242. <!-- Product brand action -->
  243. <record id="action_product_brand" model="ir.actions.act_window">
  244. <field name="name">Marcas</field>
  245. <field name="res_model">product.brands</field>
  246. <field name="view_type">form</field>
  247. <field name="view_mode">kanban,form,tree</field>
  248. </record>
  249. <!-- Brand Menu -->
  250. <menuitem action="action_product_brand" id="menu_product_brand" name="Product Brands" parent="kingfisher_pro.menu_slider_config"/>
  251. <!-- Blog Slider -->
  252. <!-- Blog Slider Form View-->
  253. <record id="dynamic_blog_slider_form_view" model="ir.ui.view">
  254. <field name="name">dynamic.blog.slider.form.view</field>
  255. <field name="model">blog.slider.config</field>
  256. <field name="arch" type="xml">
  257. <form string="Slider del Blog">
  258. <sheet>
  259. <group>
  260. <field name="name"/>
  261. <field name="active"/>
  262. <field name="no_of_counts"/>
  263. <field name="auto_rotate"/>
  264. <field attrs="{'invisible': [('auto_rotate', '=', False)]}" name="sliding_speed"/>
  265. <field name="collections_blog_post" widget="many2many_tags"/>
  266. </group>
  267. </sheet>
  268. </form>
  269. </field>
  270. </record>
  271. <!-- Blog Slider List View-->
  272. <record id="dynamic_blog_slider_list_view" model="ir.ui.view">
  273. <field name="name">dynamic.blog.slider.list.view</field>
  274. <field name="model">blog.slider.config</field>
  275. <field name="arch" type="xml">
  276. <tree string="Blog Post Slider">
  277. <field name="name"/>
  278. <field name="no_of_counts"/>
  279. </tree>
  280. </field>
  281. </record>
  282. <!-- Blog Slider Action -->
  283. <record id="dynamic_blog_slider_action" model="ir.actions.act_window">
  284. <field name="name">Blog-Slider de Publicaciones</field>
  285. <field name="type">ir.actions.act_window</field>
  286. <field name="res_model">blog.slider.config</field>
  287. <field name="view_type">form</field>
  288. <field name="view_mode">tree,form</field>
  289. <field eval="False" name="view_id"/>
  290. <field name="help" type="html">
  291. <p class="oe_view_nocontent_create">Click para Crear un Nuevo Slider.
  292. </p>
  293. </field>
  294. </record>
  295. <!-- Blog slider main menu in config -->
  296. <menuitem id="blog_post_slider_configuration" name="Slider Configuración" parent="knowledge.menu_document" sequence="20"/>
  297. <menuitem action="dynamic_blog_slider_action" id="dynamic_blog_slider_menu" name="Configuración Slider Blog" parent="kingfisher_pro.blog_post_slider_configuration" sequence="60"/>
  298. <!-- Multi Product Slider Form View-->
  299. <record id="multi_slider_form_view" model="ir.ui.view">
  300. <field name="name">multi.slider.form.view</field>
  301. <field name="model">multi.slider.config</field>
  302. <field name="arch" type="xml">
  303. <form string="Multi Slider">
  304. <sheet>
  305. <group>
  306. <field name="name"/>
  307. <field name="active"/>
  308. </group>
  309. <group string="Configuración del Slide">
  310. <field name="auto_rotate"/>
  311. <field attrs="{'invisible': [('auto_rotate', '=', False)]}" name="sliding_speed"/>
  312. </group>
  313. <group string="Configuración de Colecciones">
  314. <field name="no_of_collection"/>
  315. <field attrs="{'invisible': [('no_of_collection', '=', False)]}" name="label_collection_1"/>
  316. <field attrs="{'invisible': [('no_of_collection', '=', False)]}" name="collection_1_ids" widget="many2many_tags"/>
  317. <field attrs="{'invisible': [('no_of_collection', '=', False)]}" name="label_collection_2"/>
  318. <field attrs="{'invisible': [('no_of_collection', '=', False)]}" name="collection_2_ids" widget="many2many_tags"/>
  319. <field attrs="{'invisible': ['|', ('no_of_collection', '=', False), ('no_of_collection', 'not in', ('3', '4', '5'))], 'required': [('no_of_collection', 'in', ('3', '4', '5'))]}" name="label_collection_3"/>
  320. <field attrs="{'invisible': ['|', ('no_of_collection', '=', False), ('no_of_collection', 'not in', ('3', '4', '5'))], 'required': ['|', ('no_of_collection', 'in', ('3', '4', '5'))]}" name="collection_3_ids" widget="many2many_tags"/>
  321. <field attrs="{'invisible': ['|', ('no_of_collection', '=', False), ('no_of_collection', 'not in', ('4', '5'))], 'required': [('no_of_collection', 'in', ('4', '5'))]}" name="label_collection_4"/>
  322. <field attrs="{'invisible': ['|', ('no_of_collection', '=', False), ('no_of_collection', 'not in', ('4', '5'))], 'required': [('no_of_collection', 'in', ('4', '5'))]}" name="collection_4_ids" widget="many2many_tags"/>
  323. <field attrs="{'invisible': ['|', ('no_of_collection', '=', False), ('no_of_collection', '!=', '5')], 'required': [('no_of_collection', '=', '5')]}" name="label_collection_5"/>
  324. <field attrs="{'invisible': ['|', ('no_of_collection', '=', False), ('no_of_collection', '!=', '5')], 'required': [('no_of_collection', '=', '5')]}" name="collection_5_ids" widget="many2many_tags"/>
  325. </group>
  326. </sheet>
  327. </form>
  328. </field>
  329. </record>
  330. <!-- Multi Product Slider List View-->
  331. <record id="multi_slider_list_view" model="ir.ui.view">
  332. <field name="name">multi.slider.list.view</field>
  333. <field name="model">multi.slider.config</field>
  334. <field name="arch" type="xml">
  335. <tree string="Slider Dinamico">
  336. <field name="name"/>
  337. <field name="active"/>
  338. <field name="no_of_collection"/>
  339. </tree>
  340. </field>
  341. </record>
  342. <!-- Multi Product Slider Action -->
  343. <record id="multi_slider_action" model="ir.actions.act_window">
  344. <field name="name">Multi Slider</field>
  345. <field name="type">ir.actions.act_window</field>
  346. <field name="res_model">multi.slider.config</field>
  347. <field name="view_type">form</field>
  348. <field name="view_mode">tree,form</field>
  349. <field eval="False" name="view_id"/>
  350. <field name="help" type="html">
  351. <p class="oe_view_nocontent_create">Click para crear un Nuevo Slider.
  352. </p>
  353. </field>
  354. </record>
  355. <!-- Main menu in config -->
  356. <menuitem action="multi_slider_action" id="multi_slider_menu" name="Slider Multi-Producto" parent="kingfisher_pro.menu_slider_config" sequence="70"/>
  357. <!-- Virta a Estirar -->
  358. <record id="color_sitioweb_action" model="ir.actions.act_window">
  359. <field name="name">Color - SitioWeb</field>
  360. <field name="type">ir.actions.act_window</field>
  361. <field name="res_model">ir.ui.view</field>
  362. <field name="">ir.ui.view</field>
  363. <field name="view_type">form</field>
  364. <field name="view_mode">tree,form</field>
  365. <field name="target">inlineview</field>
  366. <field eval="False" name="view_id"/>
  367. <field name="domain">['|', '|', ['name', 'ilike', 'Color_Sitio_Web'], ['model', 'ilike', 'Color_Sitio_Web'], ['model_data_id', 'ilike', 'Color_Sitio_Web']]</field>
  368. <field name="help" type="html">
  369. <p class="oe_view_nocontent_create">Aqui va el ayuda.
  370. </p>
  371. </field>
  372. </record>
  373. <menuitem action="" id="color_base_menu" name="Color Sitio-WEb" parent="base.marketing_menu" sequence="100"/>
  374. <menuitem action="color_sitioweb_action" id="color_menu_web" name="Sitio-WEb" parent="color_base_menu" sequence="100"/>
  375. </data>
  376. </openerp>