Very small modifs
bzr revid: pinky-a2e0149df70552387ac1c43a09fb54c9e21bc10d
This commit is contained in:
parent
1c778b26a6
commit
3c1f189772
|
@ -146,5 +146,3 @@ class make_invoice_onshipping(wizard.interface):
|
|||
}
|
||||
make_invoice_onshipping("delivery.invoice_onshipping")
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -42,6 +42,7 @@ class mrp_procurement(osv.osv):
|
|||
'state': 'open',
|
||||
'planned_hours': procurement.product_qty,
|
||||
'user_id': procurement.product_id.product_manager.id,
|
||||
'notes': procurement.origin,
|
||||
'procurement_id': procurement.id
|
||||
})
|
||||
return task_id
|
||||
|
|
|
@ -338,7 +338,7 @@ class sale_order(osv.osv):
|
|||
write_cancel_ids = []
|
||||
for order in self.browse(cr, uid, ids, context={}):
|
||||
for line in order.order_line:
|
||||
if line.procurement_id and line.procurement_id.state != 'done':
|
||||
if line.procurement_id and (line.procurement_id.state != 'done') and (line.state!='done'):
|
||||
finished = False
|
||||
if line.procurement_id and line.procurement_id.state == 'cancel':
|
||||
canceled = True
|
||||
|
@ -602,7 +602,12 @@ class sale_order_line(osv.osv):
|
|||
return self.write(cr, uid, ids, {'state':'confirmed'})
|
||||
|
||||
def button_done(self, cr, uid, ids, context={}):
|
||||
return self.write(cr, uid, ids, {'state':'done'})
|
||||
wf_service = netsvc.LocalService("workflow")
|
||||
res = self.write(cr, uid, ids, {'state':'done'})
|
||||
for line in self.browse(cr,uid,ids,context):
|
||||
wf_service.trg_write(uid, 'sale.order', line.order_id.id, cr)
|
||||
|
||||
return res
|
||||
|
||||
def uos_change(self, cr, uid, ids, product_uos, product_uos_qty=0, product_id=None):
|
||||
if not product_id:
|
||||
|
|
|
@ -109,6 +109,16 @@
|
|||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
<tree string="Sales Order Lines">
|
||||
<field name="name" colspan="3"/>
|
||||
<field name="product_id"/>
|
||||
<field name="product_uom_qty" string="Qty"/>
|
||||
<field name="product_uom" string="UoM"/>
|
||||
<field name="discount"/>
|
||||
<field name="price_unit"/>
|
||||
<field name="price_net"/>
|
||||
<field name="price_subtotal"/>
|
||||
</tree>
|
||||
</field>
|
||||
<newline/>
|
||||
<group colspan="4" col="7">
|
||||
|
@ -345,13 +355,13 @@
|
|||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Sales Order Lines">
|
||||
<field name="order_id"/>
|
||||
<field name="name" colspan="3"/>
|
||||
<field name="product_id"/>
|
||||
<field name="product_uom_qty" string="Qty"/>
|
||||
<field name="product_uom" string="UoM"/>
|
||||
<field name="discount"/>
|
||||
<field name="price_unit"/>
|
||||
<field name="delay"/>
|
||||
<field name="price_net"/>
|
||||
<field name="price_subtotal"/>
|
||||
</tree>
|
||||
|
@ -384,7 +394,7 @@
|
|||
<separator string="States" colspan="4"/>
|
||||
<field name="state" select="1"/>
|
||||
<group colspan="2" col="2">
|
||||
<button string="Done" name="button_done" states="confirmed"/>
|
||||
<button string="Done" name="button_done" type="object" states="confirmed"/>
|
||||
|
||||
</group>
|
||||
</page><page string="Properties">
|
||||
|
|
Loading…
Reference in New Issue