Mayur Maheshwari(OpenERP) has proposed merging 
lp:~openerp-dev/openobject-addons/trunk-first_10_clicks-purchase-mma into 
lp:openobject-addons.

Requested reviews:
  OpenERP Core Team (openerp)

For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-first_10_clicks-purchase-mma/+merge/106570

Hello Sir,

I have improved the following things:

1] Added status bar and action buttons on the top bar above the form and 
the history and comments on the bottom bar below the form.

2] Improved the menu-tips & menu String.

3] Restricted some fields to appropriate groups.


Thanks.
mma


-- 
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-first_10_clicks-purchase-mma/+merge/106570
Your team OpenERP R&D Team is subscribed to branch 
lp:~openerp-dev/openobject-addons/trunk-first_10_clicks-purchase-mma.
=== modified file 'purchase/purchase_view.xml'
--- purchase/purchase_view.xml	2012-05-16 16:01:15 +0000
+++ purchase/purchase_view.xml	2012-05-21 06:23:24 +0000
@@ -130,11 +130,26 @@
             <field name="model">purchase.order</field>
             <field name="type">form</field>
             <field name="arch" type="xml">
-                <form string="Purchase Order">
+                <form layout="manual">
+                <div class="oe_form_topbar">
+                    <button name="action_cancel_draft" states="cancel" string="Set to Draft" type="object" icon="gtk-convert"/>
+                    <button name="picking_ok" states="except_picking" string="Manually Corrected" icon="gtk-convert"/>
+                    <button name="invoice_ok" states="except_invoice" string="Manually Corrected" icon="gtk-convert"/>
+                    <button name="purchase_confirm" states="draft" string="Convert to Purchase Order" icon="gtk-go-forward" class="oe_form_button_hi"/>
+                    <button name="purchase_appbuyer" states="wait_auth" string="Approve Purchase" icon="gtk-ok"/>
+                    <button name="purchase_approve" states="confirmed" string="Approved" icon="gtk-go-forward" class="oe_form_button_hi"/>
+                    <button name="%(report_purchase_order)d" string="Print" states="approved" type="action" icon="gtk-print"/>
+                    <button name="action_cancel" states="approved,except_picking,except_invoice,wait" string="Cancel Purchase Order" type="object" icon="gtk-cancel"/>
+                    <button name="purchase_cancel" states="draft,confirmed,wait_auth" string="Cancel" icon="gtk-cancel"/>
+                <div class="oe_right">
+                    <field name="state" nolabel="1" widget="statusbar" statusbar_visible="draft,approved,done" statusbar_colors='{"except_picking":"red","except_invoice":"red","confirmed":"blue","wait":"blue"}'/>
+                </div>
+                </div>
+                <sheet string="Purchase Order" layout="auto">
                     <group col="6" colspan="4">
                         <field name="name"/>
                         <field name="date_order"/>
-                        <field name="invoiced"/>
+                        <field name="invoiced" groups="base.group_no_one"/>
                         <newline/>
                         <field name="warehouse_id" on_change="onchange_warehouse_id(warehouse_id)" widget="selection" groups="stock.group_locations"/>
                         <field name="partner_ref"/>
@@ -164,23 +179,11 @@
                                 <field name="amount_total" sum="Total amount"/>
                                 <button name="button_dummy" states="draft" string="Compute" type="object" icon="gtk-execute"/>
                             </group>
-                            <group col="11" colspan="4">
-                                <field name="state" widget="statusbar" statusbar_visible="draft,approved,done" statusbar_colors='{"except_picking":"red","except_invoice":"red","confirmed":"blue","wait":"blue"}' readonly="1"/>
-                                <button name="purchase_cancel" states="draft,confirmed,wait_auth" string="Cancel" icon="gtk-cancel"/>
-                                <button name="action_cancel_draft" states="cancel" string="Set to Draft" type="object" icon="gtk-convert"/>
-                                <button name="action_cancel" states="approved,except_picking,except_invoice,wait" string="Cancel Purchase Order" type="object" icon="gtk-cancel"/>
-                                <button name="picking_ok" states="except_picking" string="Manually Corrected" icon="gtk-convert"/>
-                                <button name="invoice_ok" states="except_invoice" string="Manually Corrected" icon="gtk-convert"/>
-                                <button name="purchase_confirm" states="draft" string="Convert to Purchase Order" icon="gtk-go-forward"/>
-                                <button name="purchase_appbuyer" states="wait_auth" string="Approve Purchase" icon="gtk-ok"/>
-                                <button name="purchase_approve" states="confirmed" string="Approved" icon="gtk-go-forward"/>
-                                <button name="%(report_purchase_order)d" string="Print" states="approved" type="action" icon="gtk-print"/>
-                            </group>
                         </page>
                         <page string="Delivery &amp; Invoicing">
                             <group colspan="2" col="2">
                                 <separator string="Delivery" colspan="2"/>
-                                <field name="dest_address_id" on_change="onchange_dest_address_id(dest_address_id)"/>
+                                <field name="dest_address_id" on_change="onchange_dest_address_id(dest_address_id)" gropus="purchase.group_delivery_invoice_address"/>
                                 <field name="minimum_planned_date"/>
                                 <field name="location_id" groups="stock.group_locations"/>
                             </group>
@@ -203,7 +206,10 @@
                             <field colspan="4" name="notes" nolabel="1"/>
                         </page>
                     </notebook>
-                   <field name="message_ids_social" colspan="4" widget="ThreadView" nolabel="1"/>
+                    </sheet>
+                    <div class="oe_form_sheet_width">
+                        <field name="message_ids_social" colspan="4" widget="ThreadView" nolabel="1"/>
+                    </div>
                 </form>
             </field>
         </record>
@@ -301,13 +307,13 @@
         </record>
 
         <record id="purchase_rfq" model="ir.actions.act_window">
-            <field name="name">Requests for Quotation</field>
+            <field name="name">Quotations</field>
             <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="view_mode">tree,form,graph,calendar</field>
             <field name="search_view_id" ref="view_request_for_quotation_filter"/>
-            <field name="help">You can create a request for quotation when you want to buy products to a supplier but the purchase is not confirmed yet. Use also this menu to review requests for quotation created automatically based on your logistic rules (minimum stock, MTO, etc). You can convert the request for quotation into a purchase order once the order is confirmed. If you use the extended interface (from user's preferences), you can select the way to control your supplier invoices: based on the order, based on the receptions or manual encoding.</field>
+            <field name="help">Here you can create purchase orders. They allow you to manage receptions, and control your supplier invoices.</field>
         </record>
         <menuitem action="purchase_rfq" id="menu_purchase_rfq"
             parent="menu_procurement_management"

=== modified file 'purchase/security/purchase_security.xml'
--- purchase/security/purchase_security.xml	2012-04-04 09:08:30 +0000
+++ purchase/security/purchase_security.xml	2012-05-21 06:23:24 +0000
@@ -14,6 +14,11 @@
         <field name="users" eval="[(4, ref('base.user_root'))]"/>
     </record>
 
+    <record id="group_delivery_invoice_address" model="res.groups">
+        <field name="name">Addresses in Purchase Orders</field>
+        <field name="category_id" ref="base.module_category_hidden"/>
+    </record>
+
     <record id="group_analytic_accounting" model="res.groups">
         <field name="name">Analytic Accounting for Purchases</field>
         <field name="category_id" ref="base.module_category_hidden"/>

=== modified file 'stock/stock_view.xml'
--- stock/stock_view.xml	2012-05-16 16:01:15 +0000
+++ stock/stock_view.xml	2012-05-21 06:23:24 +0000
@@ -723,13 +723,13 @@
                             <field name="name" readonly="1"/>
                             <field name="origin"/>
                             <field name="partner_id" on_change="onchange_partner_in(partner_id)" colspan="4"/>
-                            <field name="invoice_state" string="Invoice Control"/>
+                            <field name="invoice_state" string="Invoice Control" groups="account.group_account_invoice"/>
                             <field name="backorder_id" readonly="1"/>
                         </group>
                         <group colspan="2" col="2">
                             <field name="date"/>
                             <field name="min_date" readonly="1"/>
-                            <field name="stock_journal_id" widget="selection"/>
+                            <field name="stock_journal_id" widget="selection" groups="account.group_account_user"/>
                         </group>
                     </group>
                     <notebook colspan="4">
@@ -762,7 +762,7 @@
                                         groups="product.group_stock_packaging"
                                         icon="terp-stock_effects-object-colorize"
                                         states="draft,assigned,confirmed"/>
-                                    <field name="location_dest_id"/>
+                                    <field name="location_dest_id" groups="stock.group_locations"/>
                                     <field name="date_expected" string="Date Expected"/>
                                     <field name="state"/>
                                 </tree>
@@ -785,7 +785,7 @@
                                     <group colspan="2" col="2">
                                         <separator string="Locations" colspan="2" />
                                         <field name="location_id" domain="[('usage','&lt;&gt;','view')]"/>
-                                        <field name="location_dest_id" domain="[('usage','=','internal')]"/>
+                                        <field name="location_dest_id" domain="[('usage','=','internal')]" groups="stock.group_locations"/>
                                     </group>
 
                                     <group colspan="2" col="2">
@@ -1030,8 +1030,8 @@
                     <field name="origin"/>
                     <field name="date"/>
                     <field name="min_date"/>
-                    <field name="invoice_state"/>
-                    <field name="stock_journal_id" widget="selection"/>
+                    <field name="invoice_state" groups="account.group_account_user"/>
+                    <field name="stock_journal_id" widget="selection" groups="account.group_account_invoice"/>
                     <field name="state"/>
                     <button name="action_process" states="assigned" string="Process" type="object" icon="gtk-go-forward"/>
                     <button name="button_cancel" states="assigned,confirmed,draft" string="Cancel" icon="gtk-cancel" confirm="This operation will cancel the shipment. Do you want to continue?" />
@@ -1388,9 +1388,9 @@
                                 icon="gtk-convert" context="{'scrap': True}"
                                 states="draft,waiting,confirmed,assigned" colspan="1"/>
                         <newline/>
-                        <field name="location_id" groups="stock.group_locations"/>
+                        <field name="location_id" groups="stock.group_locations" />
                         <field name="location_dest_id" groups="stock.group_locations"/>
-                        <field name="partner_id"/>
+                        <field name="partner_id" groups="stock.group_locations"/>
 
                     </group>
                     <group colspan="2" col="2">

=== modified file 'stock/wizard/stock_partial_picking_view.xml'
--- stock/wizard/stock_partial_picking_view.xml	2012-05-16 16:01:15 +0000
+++ stock/wizard/stock_partial_picking_view.xml	2012-05-21 06:23:24 +0000
@@ -22,9 +22,9 @@
                         <tree editable="bottom" string="Product Moves">
                             <field name="product_id" />
                             <field name="quantity" />
-                            <field name="product_uom" />
+                            <field name="product_uom" groups="product.group_uom"/>
                             <field name="tracking" invisible="1"/>
-                            <field name="prodlot_id" domain="[('product_id', '=', product_id)]" invisible="context.get('hide_tracking',False)" attrs="{'required':[('tracking','=',True)]}"/>
+                            <field name="prodlot_id" domain="[('product_id', '=', product_id)]" invisible="context.get('hide_tracking',False)" attrs="{'required':[('tracking','=',True)]}" groups="stock.group_production_lot"/>
                             <!-- Removed as this feature is not logic: price must be updated upon reception of invoice -->
                             <field name="update_cost" invisible="1"/>
                             <field name="cost"  invisible="1"/>

_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help   : https://help.launchpad.net/ListHelp

Reply via email to