superbar v1
@@ -16,8 +16,8 @@
|
||||
# description:
|
||||
|
||||
{
|
||||
'name': "app product browse by category navigator",
|
||||
'version': '12.0.10.29',
|
||||
'name': "App product browse by category navigator",
|
||||
'version': '11.0.10.15',
|
||||
'author': 'Sunpop.cn',
|
||||
'category': 'Base',
|
||||
'website': 'http://www.sunpop.cn',
|
||||
@@ -25,11 +25,11 @@
|
||||
'sequence': 2,
|
||||
'summary': """
|
||||
Browse Product by category tree. Use for parent children tree list kanban navigator.
|
||||
ztree widget.
|
||||
ztree widget.Hierarchy Tree.Parent Children relation tree..
|
||||
""",
|
||||
'description': """
|
||||
Superbar, zTree widget.
|
||||
Advance search with real parent children tree, ListView or KanbanView ,
|
||||
Superbar, zTree widget.
|
||||
Advance search with real parent children tree, ListView or KanbanView. parent tree, children tree,
|
||||
eg: Product category tree ,Department tree, stock location tree.
|
||||
超级方便的查询,树状视图。
|
||||
""",
|
||||
|
||||
@@ -1 +1,4 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# from . import product_category
|
||||
|
||||
|
||||
33
app_product_superbar/models/product_category.py
Normal file
@@ -0,0 +1,33 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Created on 2017-11-28
|
||||
# author: 广州尚鹏,http://www.sunpop.cn
|
||||
# email: 300883@qq.com
|
||||
# resource of Sunpop
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
# Odoo在线中文用户手册(长期更新)
|
||||
# http://www.sunpop.cn/documentation/user/10.0/zh_CN/index.html
|
||||
|
||||
# Odoo10离线中文用户手册下载
|
||||
# http://www.sunpop.cn/odoo10_user_manual_document_offline/
|
||||
# Odoo10离线开发手册下载-含python教程,jquery参考,Jinja2模板,PostgresSQL参考(odoo开发必备)
|
||||
# http://www.sunpop.cn/odoo10_developer_document_offline/
|
||||
# description:
|
||||
|
||||
from odoo import api, fields, models, exceptions, _
|
||||
|
||||
class ProductCategory(models.Model):
|
||||
_inherit = 'product.category'
|
||||
|
||||
# 更新 complete_name 算法,当有context: show_short =1 时,只显示短名
|
||||
@api.multi
|
||||
def name_get(self):
|
||||
if self._context.get('category_show_short'):
|
||||
new_res = []
|
||||
for category in self:
|
||||
name = category.name
|
||||
new_res.append((category.id, name))
|
||||
return new_res
|
||||
else:
|
||||
return super(ProductCategory, self).name_get()
|
||||
|
Before Width: | Height: | Size: 348 KiB After Width: | Height: | Size: 141 KiB |
@@ -1,12 +1,16 @@
|
||||
<section class="oe_container">
|
||||
<div class="oe_row oe_spaced" style="max-width: 95%;">
|
||||
<h2 class="oe_slogan" style="color:#875A7B;">Product Super Sidebar for Advance Search with Parent Children Tree</h2>
|
||||
<h3 class="oe_slogan">Advance Search, Advance Filter with Parent Children Tree.
|
||||
Easy to navigator and browser any data. Support list, kanban, pivot, graph view. </h3>
|
||||
<h2 class="oe_slogan" style="color:#875A7B;">ProductApp Super Sidebar for Advance Search with Parent Children Tree</h2>
|
||||
<h1>!This moduld Do Need extra paid Apps
|
||||
<a href="http://www.odoo.com/apps/modules/11.0/app_web_superbar/" target="_blank">
|
||||
<i class="fa fa-download text-warning"></i>Click to download.
|
||||
</a> </h1>
|
||||
<a href="http://www.odoo.com/apps/modules/11.0/app_web_superbar/" target="_blank">
|
||||
<i class="fa fa-download text-warning"></i>Click to download.
|
||||
</a> </h1>
|
||||
<h3 class="oe_slogan">Advance Search, Filter with Parent Children Tree.</h3>
|
||||
<h3 class="oe_slogan">Easy to navigator and browser any data. Support list, kanban, pivot, graph view. </h3>
|
||||
<h2>Online demo <i class="fa fa-user text-primary"></i> user/password: demo/demo
|
||||
<a href="http://demo.erpapp.cn/web?#view_type=list&model=sale.order&menu_id=168&action=265" target="_blank">
|
||||
<i class="fa fa-arrow-right text-warning"></i>Click to get demo.
|
||||
</a> </h2>
|
||||
</div>
|
||||
</section>
|
||||
<section class="oe_container">
|
||||
@@ -80,45 +84,12 @@
|
||||
<h1> </h1>
|
||||
<h1 class="text-danger text-center">So Easy to navigator and search any data.</h1>
|
||||
<h4 class="oe_slogan">Product by category or type in kanban view</h4>
|
||||
<div class="oe_demo oe_picture oe_screenshot">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img oe_demo oe_picture oe_screenshot src="superbar.gif"/>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="oe_container">
|
||||
<div class="oe_row oe_spaced">
|
||||
<h1> </h1>
|
||||
<h1 class="text-danger text-center">How to use! This app do need extra module. The price already included</h1>
|
||||
<h4 class="oe_slogan oe_spaced">1. Install zTree widget
|
||||
<a href="http://www.odoo.com/apps/modules/11.0/app_web_widget_ztree/" target="_blank">
|
||||
<i class="fa fa-download text-warning"></i>Click to download.
|
||||
</a>
|
||||
</h4>
|
||||
<h4 class="oe_slogan oe_spaced">2. Install app_web_superbar. <span class="text-warning">Important! Reboot odoo after installed.</span>
|
||||
</h4>
|
||||
<div class="oe_demo oe_picture oe_screenshot">
|
||||
<img src="demo2.jpg">
|
||||
</div>
|
||||
<h4 class="oe_slogan oe_spaced">3. If you want to customize, Use follow param to setup widget:</h4>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_picture oe_screenshot">
|
||||
<img src="superbar_use.gif">
|
||||
</div>
|
||||
<div class="alert alert-info" style="padding:8px;font-weight: 300; font-size: 20px;">
|
||||
<h4>In searchview xml, Write the <superbar> tag,</h4>
|
||||
<h4>position: [left, right]</h4>
|
||||
<h4>view_mode: [kanban,tree, pivot, graph view.] </h4>
|
||||
<h4>parent_key: key field name of parent child relation. leave blank would auto set.</h4>
|
||||
<h4>level: how many level to expend the tree for initialize. Default is 2</h4>
|
||||
<h4>limit: how many record to show ztree. Default is 16</h4>
|
||||
<h4>order: the field name to order by</h4>
|
||||
<h4>domain: set the domain for data, eg: [[('is_company', '=', 1)]]</h4>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="oe_container">
|
||||
<div class="oe_row oe_spaced">
|
||||
<h4 class="oe_slogan">Use in product category.</h4>
|
||||
@@ -155,6 +126,126 @@
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="oe_container">
|
||||
<div class="oe_row oe_spaced">
|
||||
<h4 class="oe_slogan">Use in contacts.</h4>
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="contacts1.jpg">
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="oe_container">
|
||||
<div class="oe_row oe_spaced">
|
||||
<h1> </h1>
|
||||
<h1 class="text-danger text-center">How to use! This app do need extra module. The price already included</h1>
|
||||
<div class="oe_span12">
|
||||
<h4 class="oe_slogan oe_spaced">1. Install zTree widget.
|
||||
<a href="http://www.odoo.com/apps/modules/11.0/app_web_widget_ztree/" target="_blank">
|
||||
<i class="fa fa-download text-warning"></i>Click to download.
|
||||
</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<h4 class="oe_slogan oe_spaced">2. Install app_web_superbar. <span class="text-warning">Important! Reboot odoo after installed.</span>
|
||||
</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<h4 class="oe_slogan oe_spaced">3. Easy use of superbar</h4>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Show superbar in list view.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use7.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Show superbar in kanban view.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use8.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Show superbar in pivot view.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use9.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Show superbar in graph view.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="usea.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Click switch to show or hide superbar.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use1.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Click checkbox to set whether to show child nodes data.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use2.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Press Ctrl(Windows) / Cmd(Mac) to Select Multi Nodes</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use3.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Set multi field to search or filter</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use4.jpg">
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12 oe_spaced">
|
||||
<h4 class="oe_slogan">Set super bar position, left or right.</h4>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="use5.jpg">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="oe_span12">
|
||||
<h4 class="oe_slogan oe_spaced">4. If you want to customize, Use follow param to setup widget:</h4>
|
||||
<div class="oe_span12">
|
||||
<div class="oe_demo oe_screenshot">
|
||||
<img src="superbar_use.png">
|
||||
</div>
|
||||
<ul class="oe_spaced" style="padding:8px;font-weight: 300; font-size: 20px;">
|
||||
<li>In search view xml, Write the <superbar> tag,</li>
|
||||
<li>position: [left, right]</li>
|
||||
<li>view_mode: [kanban,tree, pivot, graph view.]</li>
|
||||
<li>parent_key: key field name of parent child relation. leave blank would auto set.</li>
|
||||
<li>level: how many level to expend the tree for initialize. Default is 2</li>
|
||||
<li>limit: how many record to show ztree. Default is 16</li>
|
||||
<li>order: the field name to order by</li>
|
||||
<li>domain: set the domain for data, eg: [[('is_company', '=', 1)]]</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="oe_container oe_dark">
|
||||
<div class="oe_row oe_spaced text-center">
|
||||
<div class="oe_span12">
|
||||
|
||||
|
Before Width: | Height: | Size: 6.3 MiB After Width: | Height: | Size: 5.6 MiB |
BIN
app_product_superbar/static/description/superbar_use.png
Normal file
|
After Width: | Height: | Size: 54 KiB |
BIN
app_product_superbar/static/description/use1.jpg
Normal file
|
After Width: | Height: | Size: 64 KiB |
BIN
app_product_superbar/static/description/use2.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
app_product_superbar/static/description/use3.jpg
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
app_product_superbar/static/description/use4.jpg
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
app_product_superbar/static/description/use5.jpg
Normal file
|
After Width: | Height: | Size: 65 KiB |
BIN
app_product_superbar/static/description/use6.jpg
Normal file
|
After Width: | Height: | Size: 89 KiB |
BIN
app_product_superbar/static/description/use7.jpg
Normal file
|
After Width: | Height: | Size: 83 KiB |
BIN
app_product_superbar/static/description/use8.jpg
Normal file
|
After Width: | Height: | Size: 103 KiB |
BIN
app_product_superbar/static/description/use9.jpg
Normal file
|
After Width: | Height: | Size: 82 KiB |
BIN
app_product_superbar/static/description/usea.jpg
Normal file
|
After Width: | Height: | Size: 77 KiB |
@@ -9,11 +9,23 @@
|
||||
<xpath expr="//search">
|
||||
<superbar position="right" view_mode="kanban,tree">
|
||||
<field name="categ_id" domain="[]"
|
||||
parent_key="parent_id" level="2"/>
|
||||
parent_key="parent_id" level="0"/>
|
||||
<field name="type"/>
|
||||
</superbar>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!--产品list,目录显示短名,不生效停用。需要在action中传context才成-->
|
||||
<!--<record id="app_product_template_tree_view" model="ir.ui.view">-->
|
||||
<!--<field name="name">app.product.template.product.tree</field>-->
|
||||
<!--<field name="model">product.template</field>-->
|
||||
<!--<field name="inherit_id" ref="product.product_template_tree_view"/>-->
|
||||
<!--<field name="arch" type="xml">-->
|
||||
<!--<xpath expr="//field[@name='categ_id']" position="attributes">-->
|
||||
<!--<attribute name="context">{'category_show_short': True}</attribute>-->
|
||||
<!--</xpath>-->
|
||||
<!--</field>-->
|
||||
<!--</record>-->
|
||||
</data>
|
||||
</odoo>
|
||||