-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathis_bon_transfert_view.xml
executable file
·146 lines (138 loc) · 7.31 KB
/
is_bon_transfert_view.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- Sequence -->
<record id="is_bon_transfert_type_seq" model="ir.sequence.type">
<field name="name">Bon de transfert</field>
<field name="code">is.bon.transfert</field>
</record>
<record id="is_bon_transfert_seq" model="ir.sequence">
<field name="name">Bon de transfert</field>
<field name="code">is.bon.transfert</field>
<field name="prefix">BT-</field>
<field name="padding">4</field>
<field name="company_id" eval="False"/>
</record>
<!-- Affecter les UCs aux lignes -->
<record id="affecter_uc_aux_lignes_bt_action_server" model="ir.actions.server">
<field name="name">Affecter les UCs aux lignes</field>
<field name="model_id" ref="model_is_bon_transfert"/>
<field name="code">action = self.affecter_uc_aux_lignes_bt_action(cr, uid, context.get('active_ids', []), context=context)</field>
</record>
<record id="affecter_uc_aux_lignes_bt_ir_value" model="ir.values">
<field eval="'client_action_multi'" name="key2"/>
<field eval="'is.bon.transfert'" name="model"/>
<field name="name">Affecter les UCs aux lignes</field>
<field eval="'ir.actions.server,%d'%affecter_uc_aux_lignes_bt_action_server" name="value"/>
</record>
<!-- Bon de transfert -->
<record id="is_bon_transfert_form_view" model="ir.ui.view">
<field name="name">is_bon_transfert_from_view</field>
<field name="model">is.bon.transfert</field>
<field name="arch" type="xml">
<form>
<header>
<button
name="desadv_action"
string="DESADV"
type="object"
confirm="Voulez-vous vraiment envoyer l'avis d'expédition par EDI ?"
attrs="{'invisible': ['|',('date_traitement_edi', '!=', False),('traitement_edi', '!=', 'DESADV')]}"
/>
</header>
<sheet class="oe_form_sheet_width_wider">
<group>
<group>
<field name="name" />
<field
name="location_id"
on_change="on_change(location_id, date_fin)"
domain="[('usage','=','internal')]" />
<field name="date_fin" on_change="on_change(location_id, date_fin)"/>
<field name="partner_id" domain="[('customer','=',True),('is_company','=',True)]" />
<field name="transporteur_id" domain="[('supplier','=',True),('is_company','=',True)]" />
</group>
<group>
<field name="date_creation" />
<field name="qt_total" />
<field name="total_uc" />
<field name="total_um" />
<field name="traitement_edi" attrs="{'invisible': [('traitement_edi', '=', False)]}"/>
<field name="date_traitement_edi" attrs="{'invisible': [('date_traitement_edi', '=', False)]}"/>
</group>
</group>
<group>
<field name="line_ids" nolabel="1" >
<tree editable="bottom">
<field name="product_id" />
<field name="mold_id" />
<field name="ref_client" />
<field name="point_dechargement" />
<field name="quantite" />
<field name="uom_id" />
<field name="uc_id" />
<field name="nb_uc" />
<field name="um_id" />
<field name="nb_um" />
</tree>
</field>
</group>
<group attrs="{'invisible': [('galia_um_ids', '=', [])]}">
<field name="galia_um_ids" nolabel="1">
<tree>
<button string="UM" name="acceder_um_action" type="object" icon="gtk-zoom-in"/>
<field name="name" string="N°étiquette UM scannée"/>
<field name="product_id"/>
<field name="qt_pieces"/>
</tree>
</field>
</group>
<group>
<field name="uc_non_affectes" attrs="{'invisible': [('uc_non_affectes', '=', 0)]}" readonly="1"/>
</group>
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
<field name="message_ids" widget="mail_thread"/>
</div>
</form>
</field>
</record>
<record model="ir.ui.view" id="is_bon_transfert_tree_view">
<field name="name">is_bon_transfert_tree_view</field>
<field name="model">is.bon.transfert</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree>
<field name="name" />
<field name="location_id" />
<field name="date_creation" />
<field name="date_fin" />
<field name="partner_id" />
<field name="qt_total" />
<field name="total_uc" />
<field name="total_um" />
<field name="commentaire" />
</tree>
</field>
</record>
<record model="ir.ui.view" id="is_bon_transfert_search_view" >
<field name="name">is_bon_transfert_search_view</field>
<field name="model">is.bon.transfert</field>
<field name="arch" type="xml">
<search>
<field name="name" />
<field name="location_id" />
<field name="partner_id" />
<field name="commentaire" />
</search>
</field>
</record>
<record id="is_bon_transfert_action" model="ir.actions.act_window">
<field name="name">Bon de transfert</field>
<field name="res_model">is.bon.transfert</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
</record>
</data>
</openerp>