~openerp-indonesia-team/openerp-indonesia/openerp-addons-Indonesia

« back to all changes in this revision

Viewing changes to stock_location/test/stock_location_push_flow.yml

  • Committer: Iman(ADSOFT)
  • Date: 2011-05-06 23:31:40 UTC
  • Revision ID: alle@openerp.co.id-20110506233140-egef2xos807fw784
updates

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
  Push flow specification indicates which location is chained with which location.
4
4
-
5
5
  I create product category.
6
 
 
6
-
7
7
  !record {model: product.category, id: product_category_computer0}:
8
8
    name: Computer
9
 
        
 
9
 
10
10
-
11
11
  I create Supplier.
12
 
 
12
-
13
13
  !record {model: res.partner, id: res_partner_microlinktechnologies0}:
14
14
    address:
15
15
      - street: Kailash Vaibhav, Parksite
16
16
    name: Micro Link Technologies
17
17
    property_account_payable: account_account_payable0
18
 
    property_account_receivable: account_account_receivable0   
19
 
    supplier: true        
20
 
    
 
18
    property_account_receivable: account_account_receivable0
 
19
    supplier: true
 
20
 
21
21
-
22
22
  I create Supplier address.
23
 
 
23
-
24
24
  !record {model: res.partner.address, id: res_partner_address_0}:
25
25
    country_id: base.in
26
26
    partner_id: res_partner_microlinktechnologies0
27
27
    street: Ash House, Ash Road
28
28
    title: base.res_partner_title_miss
29
 
    
 
29
 
30
30
-
31
31
  I create product and define the pushed flow .
32
32
-
33
33
  I set the chain location Supplier to stock Input
34
 
  Stock Input to Quality test and Quality test -Stock  .  
35
 
 
34
  Stock Input to Quality test and Quality test -Stock  .
 
35
-
36
36
  !record {model: product.product, id: product_product_hpcdwriters0}:
37
37
    categ_id: product_category_computer0
38
38
    cost_method: standard
62
62
    property_stock_production: stock.location_production
63
63
-
64
64
  In order to test pushed flow .I buy the product from Micro Link Technologies supplier. I create a Picking.
65
 
 
65
-
66
66
   !record {model: stock.picking , id: stock_picking_in0}:
67
67
    address_id: res_partner_address_0
68
68
    company_id: base.main_company
69
69
    invoice_state: none
70
70
    move_lines:
71
 
      - date_expected: '2010-10-08 15:36:53'
 
71
      - date_expected: !eval time.strftime('%Y-%m-%d %H:%M:%S')
72
72
        location_dest_id: stock.stock_location_stock
73
73
        location_id: stock.stock_location_suppliers
74
74
        name: 'HP CD writers'
79
79
    name: Pushed Flow Test
80
80
    type: in
81
81
-
82
 
  I confirm picking.    
 
82
  I confirm picking.
83
83
-
84
84
  !python {model: stock.picking }: |
85
85
    self.draft_force_assign(cr, uid, [ref("stock_picking_in0")], {"lang": "en_US",
91
91
  Stock/Input To Quality test and Quality test  To Stock.
92
92
-
93
93
  I check the move is in waiting state.
94
 
-  
 
94
-
95
95
  !python {model: stock.picking }: |
96
96
   from tools.translate import _
97
97
   picking_id = self.search(cr, uid, [('origin','=','Pushed Flow Test'),('type','=','out')])
117
117
          'product_id': move.product_id.id,
118
118
          'product_qty': move.product_qty,
119
119
          'product_uom': move.product_uom.id,
120
 
      } 
121
 
      self.do_partial(cr, uid, picking_id,partial_datas)  
 
120
      }
 
121
      self.do_partial(cr, uid, picking_id,partial_datas)
122
122
-
123
123
  I check the Outgoing Orders is automatically  done.
124
 
-  
 
124
-
125
125
  !python {model: stock.picking }: |
126
126
   from tools.translate import _
127
127
   picking_id = self.search(cr, uid, [('origin','=','Pushed Flow Test'),('type','=','out')])