[IMP] improve the purchase view

bzr revid: rma@tinyerp.com-20120917100152-miaqma5m5tw6n8bl
This commit is contained in:
Randhir Mayatra (OpenERP) 2012-09-17 15:31:52 +05:30
parent 5168930d36
commit c353c80621
3 changed files with 17 additions and 12 deletions

View File

@ -14,7 +14,9 @@
<menuitem id="menu_purchase_config_purchase" name="Configuration"
groups="group_purchase_manager"
parent="base.menu_purchase_root" sequence="100"/>
<menuitem
action="product.product_pricelist_action_for_purchase" id="menu_product_pricelist_action2_purchase"
parent="menu_purchase_config_purchase" sequence="10" groups="product.group_purchase_pricelist" />
<menuitem
id="menu_purchase_config_pricelist" name="Pricelists"
parent="menu_purchase_config_purchase" sequence="50" groups="product.group_purchase_pricelist"/>
@ -22,10 +24,6 @@
<menuitem
action="product.product_pricelist_action" id="menu_product_pricelist_action_purhase"
parent="menu_purchase_config_pricelist" sequence="20" groups="base.group_no_one"/>
<menuitem
action="product.product_pricelist_action_for_purchase" id="menu_product_pricelist_action2_purchase"
parent="menu_purchase_config_pricelist" sequence="10" />
<menuitem
action="product.product_price_type_action" id="menu_product_pricelist_action2_purchase_type"
parent="menu_purchase_config_pricelist" sequence="60" />
@ -349,7 +347,7 @@
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase.order</field>
<field name="context">{'search_default_draft': 1}</field>
<field name="domain">[('state','in',('draft','sent','confirmed'))]</field>
<field name="domain">[('state','in',('draft','sent'))]</field>
<field name="view_mode">tree,form,graph,calendar</field>
<field name="search_view_id" ref="view_purchase_order_filter"/>
<field name="help" type="html">
@ -375,7 +373,7 @@
<field name="res_model">purchase.order</field>
<field name="view_mode">tree,form,graph,calendar</field>
<field name="context">{}</field>
<field name="domain">[('state','not in',('draft','sent','confirmed'))]</field>
<field name="domain">[('state','not in',('draft','sent'))]</field>
<field name="search_view_id" ref="view_purchase_order_filter"/>
<field name="help" type="html">
<p class="oe_view_nocontent_create">

View File

@ -46,10 +46,6 @@ class purchase_config_settings(osv.osv_memory):
'group_purchase_delivery_address': fields.boolean("Allow a different address for incoming products and invoicings",
implied_group='purchase.group_delivery_invoice_address',
help="Allows you to specify different delivery and invoice addresses on a purchase order."),
'module_purchase_analytic_plans': fields.boolean('Allow using multiple analytic accounts on the same order',
help ="""Allows the user to maintain several analysis plans. These let you split
lines on a purchase order between several accounts and analytic plans.
This installs the module purchase_analytic_plans."""),
'module_warning': fields.boolean("Alerts by products or supplier",
help="""Allow to configure warnings on products and trigger them when a user wants to purchase a given product or a given supplier.
Example: Product: this product is deprecated, do not purchase more than 5.
@ -62,6 +58,12 @@ class purchase_config_settings(osv.osv_memory):
help="""Purchase Requisitions are used when you want to request quotations from several suppliers for a given set of products.
You can configure per product if you directly do a Request for Quotation
to one supplier or if you want a purchase requisition to negotiate with several suppliers."""),
'module_purchase_analytic_plans': fields.boolean('Use multiple analytic accounts on purchase orders',
help ="""Allows the user to maintain several analysis plans. These let you split lines on a purchase order between several accounts and analytic plans.
This installs the module purchase_analytic_plans."""),
'group_analytic_account_for_purchases': fields.boolean('Analytic accounting for purchases',
implied_group='purchase.group_analytic_accounting',
help="Allows you to specify an analytic account on purchase orders."),
}
_defaults = {
@ -75,7 +77,8 @@ class account_config_settings(osv.osv_memory):
_inherit = 'account.config.settings'
_columns = {
'module_purchase_analytic_plans': fields.boolean('Use multiple analytic accounts on orders',
help="""This allows install module purchase_analytic_plans."""),
help ="""Allows the user to maintain several analysis plans. These let you split lines on a purchase order between several accounts and analytic plans.
This installs the module purchase_analytic_plans."""),
'group_analytic_account_for_purchases': fields.boolean('Analytic accounting for purchases',
implied_group='purchase.group_analytic_accounting',
help="Allows you to specify an analytic account on purchase orders."),

View File

@ -74,6 +74,10 @@
<field name="module_purchase_analytic_plans" class="oe_inline"/>
<label for="module_purchase_analytic_plans"/>
</div>
<div>
<field name="group_analytic_account_for_purchases" class="oe_inline"/>
<label for="group_analytic_account_for_purchases"/>
</div>
</div>
</group>
</form>