Merge lp:~andres-calle/openerp-ecuador/6.0 into lp:openerp-ecuador/6.0
- 6.0
- Merge into ecua_contabilidad60
Proposed by
Christopher Ormaza - (Ecuadorenlinea.net)
Status: | Needs review |
---|---|
Proposed branch: | lp:~andres-calle/openerp-ecuador/6.0 |
Merge into: | lp:openerp-ecuador/6.0 |
Diff against target: |
4198 lines (+3292/-47) 63 files modified
README.md (+9/-0) account_fiscal_position_country/AUTHORS.txt (+1/-0) account_fiscal_position_country/__init__.py (+27/-0) account_fiscal_position_country/__openerp__.py (+50/-0) account_fiscal_position_country/account.py (+30/-0) account_fiscal_position_country/account_invoice_view.xml (+28/-0) account_fiscal_position_country/account_view.xml (+18/-0) account_fiscal_position_country/country.py (+39/-0) account_fiscal_position_country/country_view.xml (+17/-0) account_fiscal_position_country/invoice.py (+43/-0) account_fiscal_position_country_sale/AUTHORS.txt (+1/-0) account_fiscal_position_country_sale/__init__.py (+25/-0) account_fiscal_position_country_sale/__openerp__.py (+46/-0) account_fiscal_position_country_sale/sale.py (+40/-0) account_fiscal_position_country_sale/sale_view.xml (+19/-0) ecua_cash_register_report/__init__.py (+23/-0) ecua_cash_register_report/__openerp__.py (+51/-0) ecua_cash_register_report/object/__init__.py (+23/-0) ecua_cash_register_report/object/caja_reporte.py (+526/-0) ecua_cash_register_report/report/report_data.xml (+21/-0) ecua_cash_register_report/view/ecua_cash_register_report_view.xml (+154/-0) ecua_facturas_ice_manual/objects/invoice.py (+3/-3) ecua_facturas_ice_manual/report/factura_ice_report.xml (+2/-1) ecua_facturas_manual/__openerp__.py (+2/-0) ecua_facturas_manual/objects/invoice.py (+0/-1) ecua_facturas_manual/objects/invoice_line.py (+2/-0) ecua_facturas_manual/objects/purchase_order.py (+1/-1) ecua_facturas_manual/objects/sale_order.py (+9/-1) ecua_facturas_manual/report/factura_report.xml (+2/-1) ecua_facturas_manual/views/account_invoice_view.xml (+46/-8) ecua_facturas_manual/views/account_voucher.xml (+47/-0) ecua_liquidacion_compras/data/data.xml (+1/-0) ecua_liquidacion_compras/report/liquidacion_reporte.xml (+2/-1) ecua_partner/__init__.py (+25/-0) ecua_partner/__openerp__.py (+45/-0) ecua_partner/ecua_partner.py (+39/-0) ecua_retenciones_manual/data/data.xml (+2/-0) ecua_retenciones_manual/report/retention_report.xml (+2/-1) ecua_seguro_social/data/company_configuration.xml (+1/-0) ecua_seguro_social/objects/payroll.py (+4/-1) ecua_seguro_social/objects/vacation.py (+1/-1) ecua_states/objects/states.py (+20/-22) ecua_verifica_ruc_cedula/partner.py (+20/-2) ecua_verifica_ruc_cedula/views/verificar_ruc_cedula_view.xml (+2/-2) l10n_ec_niif_minimal/objects/account_invoice_tax.py (+1/-1) trescloud_cheques/__init__.py (+29/-0) trescloud_cheques/__openerp__.py (+52/-0) trescloud_cheques/account.py (+105/-0) trescloud_cheques/account_view.xml (+27/-0) trescloud_cheques/account_voucher.py (+122/-0) trescloud_cheques/account_voucher_view.xml (+68/-0) trescloud_cheques/amount_to_words.py (+96/-0) trescloud_cheques/i18n/es.po (+308/-0) trescloud_cheques/i18n/trescloud_cheques.pot (+307/-0) trescloud_cheques/report/report_data.xml (+47/-0) trescloud_cheques/security/ir.model.access.csv (+2/-0) trescloud_cheques/trescloud_cheques.py (+299/-0) trescloud_cheques/trescloud_cheques_view.xml (+94/-0) trescloud_cheques/workflow/check_wkf.xml (+105/-0) trescloud_voucher_lote/__init__.py (+26/-0) trescloud_voucher_lote/__openerp__.py (+42/-0) trescloud_voucher_lote/trescloud_voucher_lote.py (+63/-0) trescloud_voucher_lote/views/trescloud_voucher_lote_view.xml (+30/-0) |
To merge this branch: | bzr merge lp:~andres-calle/openerp-ecuador/6.0 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Christopher Ormaza - (Ecuadorenlinea.net) | Needs Fixing | ||
Review via email: mp+162357@code.launchpad.net |
Commit message
Description of the change
Cambios propuestos por TRESCLOUD
To post a comment you must log in.
Revision history for this message
Christopher Ormaza - (Ecuadorenlinea.net) (chris-ormaza) wrote : | # |
review:
Needs Fixing
Unmerged revisions
- 4. By Andres Calle (TRESCLOUD)
-
Mejoras varias realizadas por TRESCLOUD, y agregado cheques, automatizacion de posiciones fiscales para clientes/
proveedores ecuatorianos, cierre de caja, otros
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === added file 'README.md' |
2 | --- README.md 1970-01-01 00:00:00 +0000 |
3 | +++ README.md 2013-05-03 13:54:27 +0000 |
4 | @@ -0,0 +1,9 @@ |
5 | +OpenERP-EC-NIIF-PYMES 6.0 |
6 | +========================= |
7 | +Branch 6.0 - Contabilidad y RRHH Niif Pymes para OpenERP 6.0 |
8 | + |
9 | +Incluye para la versión 6.0: |
10 | + |
11 | +- Modulos contables |
12 | +- Modulos de recursos humanos |
13 | +- Otros modulos relacionados a PYMES |
14 | \ No newline at end of file |
15 | |
16 | === added directory 'account_fiscal_position_country' |
17 | === added file 'account_fiscal_position_country/AUTHORS.txt' |
18 | --- account_fiscal_position_country/AUTHORS.txt 1970-01-01 00:00:00 +0000 |
19 | +++ account_fiscal_position_country/AUTHORS.txt 2013-05-03 13:54:27 +0000 |
20 | @@ -0,0 +1,1 @@ |
21 | +Leonardo Pistone <leonardo.pistone@agilebg.com> |
22 | |
23 | === added file 'account_fiscal_position_country/__init__.py' |
24 | --- account_fiscal_position_country/__init__.py 1970-01-01 00:00:00 +0000 |
25 | +++ account_fiscal_position_country/__init__.py 2013-05-03 13:54:27 +0000 |
26 | @@ -0,0 +1,27 @@ |
27 | +# -*- coding: utf-8 -*- |
28 | +############################################################################## |
29 | +# |
30 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
31 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
32 | +# All Rights Reserved |
33 | +# |
34 | +# This program is free software: you can redistribute it and/or modify |
35 | +# it under the terms of the GNU Affero General Public License as published |
36 | +# by the Free Software Foundation, either version 3 of the License, or |
37 | +# (at your option) any later version. |
38 | +# |
39 | +# This program is distributed in the hope that it will be useful, |
40 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
41 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
42 | +# GNU General Public License for more details. |
43 | +# |
44 | +# You should have received a copy of the GNU Affero General Public License |
45 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
46 | +# |
47 | +############################################################################## |
48 | + |
49 | +import country |
50 | +import account |
51 | +import invoice |
52 | + |
53 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
54 | |
55 | === added file 'account_fiscal_position_country/__openerp__.py' |
56 | --- account_fiscal_position_country/__openerp__.py 1970-01-01 00:00:00 +0000 |
57 | +++ account_fiscal_position_country/__openerp__.py 2013-05-03 13:54:27 +0000 |
58 | @@ -0,0 +1,50 @@ |
59 | +# -*- coding: utf-8 -*- |
60 | +############################################################################## |
61 | +# |
62 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
63 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
64 | +# All Rights Reserved |
65 | +# |
66 | +# This program is free software: you can redistribute it and/or modify |
67 | +# it under the terms of the GNU Affero General Public License as published |
68 | +# by the Free Software Foundation, either version 3 of the License, or |
69 | +# (at your option) any later version. |
70 | +# |
71 | +# This program is distributed in the hope that it will be useful, |
72 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
73 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
74 | +# GNU General Public License for more details. |
75 | +# |
76 | +# You should have received a copy of the GNU Affero General Public License |
77 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
78 | +# |
79 | +############################################################################## |
80 | + |
81 | +{ |
82 | + 'name': 'Fiscal Position by country', |
83 | + 'version': '0.2', |
84 | + 'category': 'Generic Modules/Accounting', |
85 | + 'description': """A rule to select automatically the fiscal position based on the country |
86 | + In the configuration of the country, choose a default fiscal position for it. |
87 | + When selecting a partner in an invoice, if the fiscal position for the partner is not set, the one |
88 | + from the country will be used. |
89 | + |
90 | + For more info: http://planet.domsense.com/en/2011/12/account_fiscal_position_country/""", |
91 | + 'author': 'Agile Business Group & Domsense', |
92 | + 'website': 'http://www.agilebg.com', |
93 | + 'license': 'AGPL-3', |
94 | + |
95 | + 'depends': ['base','account'], |
96 | + 'init_xml': [], |
97 | + 'update_xml': |
98 | + [ |
99 | + 'account_view.xml', |
100 | + 'account_invoice_view.xml', |
101 | + 'country_view.xml', |
102 | + ], |
103 | + 'demo_xml': [], |
104 | + "active": False, |
105 | + |
106 | + 'installable': True, |
107 | +} |
108 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
109 | |
110 | === added file 'account_fiscal_position_country/account.py' |
111 | --- account_fiscal_position_country/account.py 1970-01-01 00:00:00 +0000 |
112 | +++ account_fiscal_position_country/account.py 2013-05-03 13:54:27 +0000 |
113 | @@ -0,0 +1,30 @@ |
114 | +# -*- coding: utf-8 -*- |
115 | +############################################################################## |
116 | +# |
117 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
118 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
119 | +# All Rights Reserved |
120 | +# |
121 | +# This program is free software: you can redistribute it and/or modify |
122 | +# it under the terms of the GNU Affero General Public License as published |
123 | +# by the Free Software Foundation, either version 3 of the License, or |
124 | +# (at your option) any later version. |
125 | +# |
126 | +# This program is distributed in the hope that it will be useful, |
127 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
128 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
129 | +# GNU General Public License for more details. |
130 | +# |
131 | +# You should have received a copy of the GNU Affero General Public License |
132 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
133 | +# |
134 | +############################################################################## |
135 | + |
136 | +from osv import fields, osv |
137 | + |
138 | +class account_fiscal_position(osv.osv): |
139 | + _inherit = "account.fiscal.position" |
140 | + _columns = { |
141 | + 'country_ids': fields.one2many('res.country', 'property_account_position', 'Countries', readonly=True), |
142 | + } |
143 | +account_fiscal_position() |
144 | |
145 | === added file 'account_fiscal_position_country/account_invoice_view.xml' |
146 | --- account_fiscal_position_country/account_invoice_view.xml 1970-01-01 00:00:00 +0000 |
147 | +++ account_fiscal_position_country/account_invoice_view.xml 2013-05-03 13:54:27 +0000 |
148 | @@ -0,0 +1,28 @@ |
149 | +<?xml version="1.0" encoding="UTF-8"?> |
150 | +<openerp> |
151 | + <data> |
152 | + |
153 | + <record id="invoice_form_position_country" model="ir.ui.view"> |
154 | + <field name="name">account.invoice.form.position.country</field> |
155 | + <field name="model">account.invoice</field> |
156 | + <field name="inherit_id" ref="account.invoice_form"/> |
157 | + <field name="arch" type="xml"> |
158 | + <field name="partner_id" position="replace"> |
159 | + <field string="Customer" name="partner_id" on_change="onchange_partner_id_fiscal_position(type,partner_id,date_invoice,payment_term, partner_bank_id,company_id)" groups="base.group_user" context="{'search_default_customer': 1}"/> |
160 | + </field> |
161 | + </field> |
162 | + </record> |
163 | + |
164 | + <record id="invoice_supplier_form_position_country" model="ir.ui.view"> |
165 | + <field name="name">account.invoice.supplier.form.position.country</field> |
166 | + <field name="model">account.invoice</field> |
167 | + <field name="inherit_id" ref="account.invoice_supplier_form"/> |
168 | + <field name="arch" type="xml"> |
169 | + <field name="partner_id" position="replace"> |
170 | + <field string="Supplier" name="partner_id" on_change="onchange_partner_id_fiscal_position(type,partner_id,date_invoice,payment_term, partner_bank_id,company_id)" context="{'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}"/> |
171 | + </field> |
172 | + </field> |
173 | + </record> |
174 | + |
175 | + </data> |
176 | +</openerp> |
177 | |
178 | === added file 'account_fiscal_position_country/account_view.xml' |
179 | --- account_fiscal_position_country/account_view.xml 1970-01-01 00:00:00 +0000 |
180 | +++ account_fiscal_position_country/account_view.xml 2013-05-03 13:54:27 +0000 |
181 | @@ -0,0 +1,18 @@ |
182 | +<?xml version="1.0" encoding="UTF-8"?> |
183 | +<openerp> |
184 | + <data> |
185 | + |
186 | + <record id="view_account_position_form_country" model="ir.ui.view"> |
187 | + <field name="name">account.fiscal.position.form.country</field> |
188 | + <field name="model">account.fiscal.position</field> |
189 | + <field name="inherit_id" ref="account.view_account_position_form"/> |
190 | + <field name="type">form</field> |
191 | + <field name="arch" type="xml"> |
192 | + <field name="note" position="after"> |
193 | + <field name="country_ids" colspan="4" nolabel="1"/> |
194 | + </field> |
195 | + </field> |
196 | + </record> |
197 | + |
198 | + </data> |
199 | +</openerp> |
200 | |
201 | === added file 'account_fiscal_position_country/country.py' |
202 | --- account_fiscal_position_country/country.py 1970-01-01 00:00:00 +0000 |
203 | +++ account_fiscal_position_country/country.py 2013-05-03 13:54:27 +0000 |
204 | @@ -0,0 +1,39 @@ |
205 | +# -*- coding: utf-8 -*- |
206 | +############################################################################## |
207 | +# |
208 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
209 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
210 | +# All Rights Reserved |
211 | +# |
212 | +# This program is free software: you can redistribute it and/or modify |
213 | +# it under the terms of the GNU Affero General Public License as published |
214 | +# by the Free Software Foundation, either version 3 of the License, or |
215 | +# (at your option) any later version. |
216 | +# |
217 | +# This program is distributed in the hope that it will be useful, |
218 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
219 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
220 | +# GNU General Public License for more details. |
221 | +# |
222 | +# You should have received a copy of the GNU Affero General Public License |
223 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
224 | +# |
225 | +############################################################################## |
226 | + |
227 | +from osv import fields, osv |
228 | + |
229 | +class Country(osv.osv): |
230 | + _inherit = 'res.country' |
231 | + _columns = { |
232 | + # 'fiscal_position_id': fields.many2one('account.fiscal.position','Default fiscal position'), |
233 | + 'property_account_position': fields.property( |
234 | + 'account.fiscal.position', |
235 | + type='many2one', |
236 | + relation='account.fiscal.position', |
237 | + string="Default Fiscal Position", |
238 | + method=True, |
239 | + view_load=True, |
240 | + help="The fiscal position will determine taxes and the accounts used for the country, if not set specifically elsewere.", |
241 | + ), |
242 | + } |
243 | +Country() |
244 | |
245 | === added file 'account_fiscal_position_country/country_view.xml' |
246 | --- account_fiscal_position_country/country_view.xml 1970-01-01 00:00:00 +0000 |
247 | +++ account_fiscal_position_country/country_view.xml 2013-05-03 13:54:27 +0000 |
248 | @@ -0,0 +1,17 @@ |
249 | +<?xml version="1.0" encoding="UTF-8"?> |
250 | +<openerp> |
251 | + <data> |
252 | + |
253 | + <record model="ir.ui.view" id="view_country_fiscal_position_form"> |
254 | + <field name="name">country.fiscal.position.form</field> |
255 | + <field name="model">res.country</field> |
256 | + <field name="inherit_id" ref="base.view_country_form"/> |
257 | + <field name="arch" type="xml"> |
258 | + <field name="code" position="after"> |
259 | + <field name="property_account_position" widget="selection"/> |
260 | + </field> |
261 | + </field> |
262 | + </record> |
263 | + |
264 | + </data> |
265 | +</openerp> |
266 | |
267 | === added file 'account_fiscal_position_country/invoice.py' |
268 | --- account_fiscal_position_country/invoice.py 1970-01-01 00:00:00 +0000 |
269 | +++ account_fiscal_position_country/invoice.py 2013-05-03 13:54:27 +0000 |
270 | @@ -0,0 +1,43 @@ |
271 | +# -*- coding: utf-8 -*- |
272 | +############################################################################## |
273 | +# |
274 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
275 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
276 | +# All Rights Reserved |
277 | +# |
278 | +# This program is free software: you can redistribute it and/or modify |
279 | +# it under the terms of the GNU Affero General Public License as published |
280 | +# by the Free Software Foundation, either version 3 of the License, or |
281 | +# (at your option) any later version. |
282 | +# |
283 | +# This program is distributed in the hope that it will be useful, |
284 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
285 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
286 | +# GNU General Public License for more details. |
287 | +# |
288 | +# You should have received a copy of the GNU Affero General Public License |
289 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
290 | +# |
291 | +############################################################################## |
292 | + |
293 | +from osv import fields, osv |
294 | + |
295 | +class account_invoice(osv.osv): |
296 | + _inherit = "account.invoice" |
297 | + |
298 | + def onchange_partner_id_fiscal_position(self, cr, uid, ids, type, partner_id,\ |
299 | + date_invoice=False, payment_term=False, partner_bank_id=False, company_id=False): |
300 | + |
301 | + result = super(account_invoice, self).onchange_partner_id(cr, uid, ids, type, partner_id,\ |
302 | + date_invoice, payment_term, partner_bank_id, company_id) |
303 | + |
304 | + if not result['value']['fiscal_position']: |
305 | + if partner_id: |
306 | + partner = self.pool.get('res.partner').browse(cr, uid, partner_id) |
307 | + addr = self.pool.get('res.partner').address_get(cr, uid, [partner_id]) |
308 | + address = self.pool.get('res.partner.address').browse(cr, uid, addr['default']) |
309 | + result['value']['fiscal_position'] = address.country_id and address.country_id.property_account_position and address.country_id.property_account_position.id or False |
310 | + |
311 | + return result |
312 | + |
313 | +account_invoice() |
314 | |
315 | === added directory 'account_fiscal_position_country_sale' |
316 | === added file 'account_fiscal_position_country_sale/AUTHORS.txt' |
317 | --- account_fiscal_position_country_sale/AUTHORS.txt 1970-01-01 00:00:00 +0000 |
318 | +++ account_fiscal_position_country_sale/AUTHORS.txt 2013-05-03 13:54:27 +0000 |
319 | @@ -0,0 +1,1 @@ |
320 | +Leonardo Pistone <leonardo.pistone@agilebg.com> |
321 | |
322 | === added file 'account_fiscal_position_country_sale/__init__.py' |
323 | --- account_fiscal_position_country_sale/__init__.py 1970-01-01 00:00:00 +0000 |
324 | +++ account_fiscal_position_country_sale/__init__.py 2013-05-03 13:54:27 +0000 |
325 | @@ -0,0 +1,25 @@ |
326 | +# -*- coding: utf-8 -*- |
327 | +############################################################################## |
328 | +# |
329 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
330 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
331 | +# All Rights Reserved |
332 | +# |
333 | +# This program is free software: you can redistribute it and/or modify |
334 | +# it under the terms of the GNU Affero General Public License as published |
335 | +# by the Free Software Foundation, either version 3 of the License, or |
336 | +# (at your option) any later version. |
337 | +# |
338 | +# This program is distributed in the hope that it will be useful, |
339 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
340 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
341 | +# GNU General Public License for more details. |
342 | +# |
343 | +# You should have received a copy of the GNU Affero General Public License |
344 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
345 | +# |
346 | +############################################################################## |
347 | + |
348 | +import sale |
349 | + |
350 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
351 | |
352 | === added file 'account_fiscal_position_country_sale/__openerp__.py' |
353 | --- account_fiscal_position_country_sale/__openerp__.py 1970-01-01 00:00:00 +0000 |
354 | +++ account_fiscal_position_country_sale/__openerp__.py 2013-05-03 13:54:27 +0000 |
355 | @@ -0,0 +1,46 @@ |
356 | +# -*- coding: utf-8 -*- |
357 | +############################################################################## |
358 | +# |
359 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
360 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
361 | +# All Rights Reserved |
362 | +# |
363 | +# This program is free software: you can redistribute it and/or modify |
364 | +# it under the terms of the GNU Affero General Public License as published |
365 | +# by the Free Software Foundation, either version 3 of the License, or |
366 | +# (at your option) any later version. |
367 | +# |
368 | +# This program is distributed in the hope that it will be useful, |
369 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
370 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
371 | +# GNU General Public License for more details. |
372 | +# |
373 | +# You should have received a copy of the GNU Affero General Public License |
374 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
375 | +# |
376 | +############################################################################## |
377 | + |
378 | +{ |
379 | + 'name': 'Fiscal Position by country, sales', |
380 | + 'version': '0.2', |
381 | + 'category': 'Generic Modules/Accounting', |
382 | + 'description': """A rule to select automatically the fiscal position in a sale order |
383 | + This module extends the account_fiscal_position_country_sale to sale orders. The modules are |
384 | + kept separate to reduce dependencies |
385 | + """, |
386 | + 'author': 'Agile Business Group & Domsense', |
387 | + 'website': 'http://www.agilebg.com', |
388 | + 'license': 'AGPL-3', |
389 | + |
390 | + 'depends': ['account_fiscal_position_country','sale'], |
391 | + 'init_xml': [], |
392 | + 'update_xml': |
393 | + [ |
394 | + 'sale_view.xml', |
395 | + ], |
396 | + 'demo_xml': [], |
397 | + 'active': False, |
398 | + |
399 | + 'installable': True, |
400 | +} |
401 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
402 | |
403 | === added file 'account_fiscal_position_country_sale/sale.py' |
404 | --- account_fiscal_position_country_sale/sale.py 1970-01-01 00:00:00 +0000 |
405 | +++ account_fiscal_position_country_sale/sale.py 2013-05-03 13:54:27 +0000 |
406 | @@ -0,0 +1,40 @@ |
407 | +# -*- coding: utf-8 -*- |
408 | +############################################################################## |
409 | +# |
410 | +# Copyright (C) 2011 Agile Business Group sagl (<http://www.agilebg.com>) |
411 | +# Copyright (C) 2011 Domsense srl (<http://www.domsense.com>) |
412 | +# All Rights Reserved |
413 | +# |
414 | +# This program is free software: you can redistribute it and/or modify |
415 | +# it under the terms of the GNU Affero General Public License as published |
416 | +# by the Free Software Foundation, either version 3 of the License, or |
417 | +# (at your option) any later version. |
418 | +# |
419 | +# This program is distributed in the hope that it will be useful, |
420 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
421 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
422 | +# GNU General Public License for more details. |
423 | +# |
424 | +# You should have received a copy of the GNU Affero General Public License |
425 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
426 | +# |
427 | +############################################################################## |
428 | + |
429 | +from osv import fields, osv |
430 | + |
431 | +class sale_order(osv.osv): |
432 | + _inherit = "sale.order" |
433 | + |
434 | + def onchange_partner_id_fiscal_position(self, cr, uid, ids, partner_id): |
435 | + result = super(sale_order, self).onchange_partner_id(cr, uid, ids, partner_id) |
436 | + |
437 | + if not result['value']['fiscal_position']: |
438 | + if partner_id: |
439 | + partner = self.pool.get('res.partner').browse(cr, uid, partner_id) |
440 | + addr = self.pool.get('res.partner').address_get(cr, uid, [partner_id]) |
441 | + address = self.pool.get('res.partner.address').browse(cr, uid, addr['default']) |
442 | + result['value']['fiscal_position'] = address.country_id and address.country_id.property_account_position and address.country_id.property_account_position.id or False |
443 | + |
444 | + return result |
445 | + |
446 | +sale_order() |
447 | |
448 | === added file 'account_fiscal_position_country_sale/sale_view.xml' |
449 | --- account_fiscal_position_country_sale/sale_view.xml 1970-01-01 00:00:00 +0000 |
450 | +++ account_fiscal_position_country_sale/sale_view.xml 2013-05-03 13:54:27 +0000 |
451 | @@ -0,0 +1,19 @@ |
452 | +<?xml version="1.0" encoding="utf-8"?> |
453 | +<openerp> |
454 | + |
455 | + <data> |
456 | + |
457 | + <record id="view_order_form_position_country" model="ir.ui.view"> |
458 | + <field name="name">view.order.form.position.country</field> |
459 | + <field name="model">sale.order</field> |
460 | + <field name="inherit_id" ref="sale.view_order_form"/> |
461 | + <field name="arch" type="xml"> |
462 | + <field name="partner_id" position="replace"> |
463 | + <field name="partner_id" on_change="onchange_partner_id_fiscal_position(partner_id)" domain="[('customer','=',True)]" context="{'search_default_customer':1}" required="1"/> |
464 | + </field> |
465 | + </field> |
466 | + </record> |
467 | + |
468 | + </data> |
469 | + |
470 | +</openerp> |
471 | |
472 | === added directory 'ecua_cash_register_report' |
473 | === added file 'ecua_cash_register_report/__init__.py' |
474 | --- ecua_cash_register_report/__init__.py 1970-01-01 00:00:00 +0000 |
475 | +++ ecua_cash_register_report/__init__.py 2013-05-03 13:54:27 +0000 |
476 | @@ -0,0 +1,23 @@ |
477 | +# -*- encoding: utf-8 -*- |
478 | +######################################################################## |
479 | +# |
480 | +# @authors: Patricio Rangles |
481 | +# Copyright (C) 2012 TRESCLOUD CIA. LTDA. |
482 | +# |
483 | +#This program is free software: you can redistribute it and/or modify |
484 | +#it under the terms of the GNU General Public License as published by |
485 | +#the Free Software Foundation, either version 3 of the License, or |
486 | +#(at your option) any later version. |
487 | +# |
488 | +# This module is GPLv3 or newer and incompatible |
489 | +# with OpenERP SA "AGPL + Private Use License"! |
490 | +# |
491 | +#This program is distributed in the hope that it will be useful, |
492 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
493 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
494 | +#GNU General Public License for more details. |
495 | +# |
496 | +#You should have received a copy of the GNU General Public License |
497 | +#along with this program. If not, see http://www.gnu.org/licenses. |
498 | +######################################################################## |
499 | +import object |
500 | \ No newline at end of file |
501 | |
502 | === added file 'ecua_cash_register_report/__openerp__.py' |
503 | --- ecua_cash_register_report/__openerp__.py 1970-01-01 00:00:00 +0000 |
504 | +++ ecua_cash_register_report/__openerp__.py 2013-05-03 13:54:27 +0000 |
505 | @@ -0,0 +1,51 @@ |
506 | + |
507 | +# -*- encoding: utf-8 -*- |
508 | +######################################################################## |
509 | +# |
510 | +# @authors: Patricio Rangles |
511 | +# Copyright (C) 2012 TRESCloud Cia. Ltda. |
512 | +# |
513 | +#This program is free software: you can redistribute it and/or modify |
514 | +#it under the terms of the GNU General Public License as published by |
515 | +#the Free Software Foundation, either version 3 of the License, or |
516 | +#(at your option) any later version. |
517 | +# |
518 | +# This module is GPLv3 or newer and incompatible |
519 | +# with OpenERP SA "AGPL + Private Use License"! |
520 | +# |
521 | +#This program is distributed in the hope that it will be useful, |
522 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
523 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
524 | +#GNU General Public License for more details. |
525 | +# |
526 | +#You should have received a copy of the GNU General Public License |
527 | +#along with this program. If not, see http://www.gnu.org/licenses. |
528 | +######################################################################## |
529 | +{ |
530 | + "name" : "Reporte para Control de Registro de Caja", |
531 | + "version" : "1.0", |
532 | + "author" : "TRESCloud Cia. Ltda.", |
533 | + "website": "http://www.trescloud.com", |
534 | + "category" : "Reportes", |
535 | + "description": """Reporte para Control de Registro de Caja |
536 | + Permite generar un reporte imprimible de los movimientos realizados por cada usuario |
537 | + en la fecha indicada. Este reporte es unico por que captura el estado actual de las |
538 | + facturas, ordenes de venta movimiento de diarios entre otros. |
539 | + |
540 | + Autor: |
541 | + Patricio Rangles |
542 | + """, |
543 | + "depends": ['base', |
544 | + 'ecua_autorizaciones_sri', |
545 | + ], |
546 | + "init_xml": [], |
547 | + "update_xml": [ |
548 | + 'report/report_data.xml', |
549 | + 'view/ecua_cash_register_report_view.xml', |
550 | + ], |
551 | + "installable": True, |
552 | + "active": False, |
553 | +} |
554 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
555 | + |
556 | + |
557 | |
558 | === added directory 'ecua_cash_register_report/object' |
559 | === added file 'ecua_cash_register_report/object/__init__.py' |
560 | --- ecua_cash_register_report/object/__init__.py 1970-01-01 00:00:00 +0000 |
561 | +++ ecua_cash_register_report/object/__init__.py 2013-05-03 13:54:27 +0000 |
562 | @@ -0,0 +1,23 @@ |
563 | +# -*- encoding: utf-8 -*- |
564 | +######################################################################## |
565 | +# |
566 | +# @authors: Patricio Rangles |
567 | +# Copyright (C) 2012 TRESCLOUD CIA. LTDA. |
568 | +# |
569 | +#This program is free software: you can redistribute it and/or modify |
570 | +#it under the terms of the GNU General Public License as published by |
571 | +#the Free Software Foundation, either version 3 of the License, or |
572 | +#(at your option) any later version. |
573 | +# |
574 | +# This module is GPLv3 or newer and incompatible |
575 | +# with OpenERP SA "AGPL + Private Use License"! |
576 | +# |
577 | +#This program is distributed in the hope that it will be useful, |
578 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
579 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
580 | +#GNU General Public License for more details. |
581 | +# |
582 | +#You should have received a copy of the GNU General Public License |
583 | +#along with this program. If not, see http://www.gnu.org/licenses. |
584 | +######################################################################## |
585 | +import caja_reporte |
586 | \ No newline at end of file |
587 | |
588 | === added file 'ecua_cash_register_report/object/caja_reporte.py' |
589 | --- ecua_cash_register_report/object/caja_reporte.py 1970-01-01 00:00:00 +0000 |
590 | +++ ecua_cash_register_report/object/caja_reporte.py 2013-05-03 13:54:27 +0000 |
591 | @@ -0,0 +1,526 @@ |
592 | +############################################################################## |
593 | +# |
594 | +# OpenERP, Open Source Management Solution |
595 | +# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). |
596 | +# |
597 | +# This program is free software: you can redistribute it and/or modify |
598 | +# it under the terms of the GNU Affero General Public License as |
599 | +# published by the Free Software Foundation, either version 3 of the |
600 | +# License, or (at your option) any later version. |
601 | +# |
602 | +# This program is distributed in the hope that it will be useful, |
603 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
604 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
605 | +# GNU Affero General Public License for more details. |
606 | +# |
607 | +# You should have received a copy of the GNU Affero General Public License |
608 | +# along with this program. If not, see <http://www.gnu.org/licenses/>. |
609 | +# |
610 | +############################################################################## |
611 | + |
612 | +import time |
613 | +from datetime import date |
614 | +#from datetime import datetime |
615 | +#from dateutil.relativedelta import relativedelta |
616 | + |
617 | +#import pooler |
618 | +#import tools |
619 | +from osv import fields,osv |
620 | + |
621 | +class caja_reporte(osv.osv_memory): |
622 | + |
623 | + _name = 'caja.reporte' |
624 | + |
625 | + def is_today(self, date_compare, reference): |
626 | + """ |
627 | + This function checks if a giving date falls in the actual date (now) |
628 | + """ |
629 | + |
630 | + if not date_compare: |
631 | + return False |
632 | + |
633 | + return date_compare == reference[0:10] |
634 | + |
635 | + def onchange_date_user_id(self, cr, uid, ids, date, user_id, context=None): |
636 | + #this function make the calculate of every field needed |
637 | + # and return the changes to the view |
638 | + |
639 | + if not context: |
640 | + context={} |
641 | + |
642 | + #asign the value into variable |
643 | + context['date_new'] = date |
644 | + context['user_id_new'] = user_id |
645 | + |
646 | + value = {} |
647 | + |
648 | + value['ovsf_ids'] = self._Ordenes_venta_sin_facturar(cr, uid, context = context) |
649 | + value['fsc_ids'] = self._facturas_sin_cancelar(cr, uid, context = context) |
650 | + value['cobros_efectivo_cheque'] = self._cobros_efectivo_cheque(cr, uid, context = context) |
651 | + value['facturas_emitidas'] = self._facturas_emitidas(cr, uid, context = context) |
652 | + value['ordenes_venta_emitidas'] = self._ordenes_venta_emitidas(cr, uid, context = context) |
653 | + value['cobros_efec_cheq_consolidado'] = self._cobros_efectivo_cheque_consolidado(cr, uid, context = context) |
654 | + |
655 | + return {'value': value} |
656 | + |
657 | + def _Ordenes_venta_sin_facturar(self, cr, uid, context = None): |
658 | + # the Idea is search in sale.order all rows from this user (id) and |
659 | + # load the field. |
660 | + |
661 | + user_id_to_use = uid |
662 | + referencia = time.strftime('%Y-%m-%d %H:%M:%S') |
663 | + |
664 | + if 'user_id_new' in context: |
665 | + user_id_to_use = context['user_id_new'] |
666 | + |
667 | + if 'date_new' in context: |
668 | + referencia = context['date_new'] |
669 | + |
670 | + #resource to return |
671 | + res = [] |
672 | + |
673 | + #This dict is for easy work whit repeats names |
674 | + res_dic = {} |
675 | + |
676 | + sale_orden_obj = self.pool.get('sale.order') |
677 | + |
678 | + #order by name (represent the number of order of sale) |
679 | + list_ids = sale_orden_obj.search(cr, uid, [('state','!=','progress'), |
680 | + '&',('state','!=','cancel'), |
681 | + ('user_id','=',user_id_to_use),], |
682 | + order='name') |
683 | + |
684 | + for orden_sin_factura in sale_orden_obj.browse(cr, uid, list_ids): |
685 | + |
686 | + #Verify the date |
687 | + if self.is_today(orden_sin_factura.date_order, referencia): |
688 | + |
689 | + temp = { |
690 | + 'name': orden_sin_factura.partner_id.name, |
691 | + 'sale_number': orden_sin_factura.name, |
692 | + 'reference': orden_sin_factura.client_order_ref, |
693 | + 'total': orden_sin_factura.amount_total, |
694 | + } |
695 | + |
696 | + res.append(temp) |
697 | + |
698 | + return res |
699 | + |
700 | + def _facturas_sin_cancelar(self, cr, uid, context = None): |
701 | + # the Idea is search in account.invoice all rows from this user (id) and |
702 | + # load the field. |
703 | + |
704 | + user_id_to_use = uid |
705 | + referencia = time.strftime('%Y-%m-%d %H:%M:%S') |
706 | + |
707 | + if 'user_id_new' in context: |
708 | + user_id_to_use = context['user_id_new'] |
709 | + |
710 | + if 'date_new' in context: |
711 | + referencia = context['date_new'] |
712 | + |
713 | + #resource to return |
714 | + res = [] |
715 | + |
716 | + #This dict is for easy work whit repeats names |
717 | + res_dic = {} |
718 | + |
719 | + account_invoice_obj = self.pool.get('account.invoice') |
720 | + |
721 | + # order by invoice_number |
722 | + list_ids = account_invoice_obj.search(cr, uid, [('reconciled','=',False), |
723 | + ('state','!=','cancel'), |
724 | + ('type','=','out_invoice'), |
725 | + ('user_id','=',user_id_to_use),], |
726 | + order='invoice_number') |
727 | + |
728 | + for factura_sin_cancelar in account_invoice_obj.browse(cr, uid, list_ids): |
729 | + |
730 | + #Verify the date |
731 | + if self.is_today(factura_sin_cancelar.date_invoice, referencia): |
732 | + |
733 | + temp = { |
734 | + 'name': factura_sin_cancelar.partner_id.name, |
735 | + 'invoice_number': factura_sin_cancelar.invoice_number, |
736 | + 'reference': factura_sin_cancelar.name, |
737 | + 'total': factura_sin_cancelar.amount_total, |
738 | + } |
739 | + |
740 | + res.append(temp) |
741 | + |
742 | + return res |
743 | + |
744 | + |
745 | + def _cobros_efectivo_cheque(self, cr, uid, context = None): |
746 | + # the Idea is search in account.vouchert all rows from this user (id) and |
747 | + # load the fields grouping by journal and "Efectivo" and/or "Cheques". |
748 | + |
749 | + user_id_to_use = uid |
750 | + referencia = time.strftime('%Y-%m-%d %H:%M:%S') |
751 | + |
752 | + if 'user_id_new' in context: |
753 | + user_id_to_use = context['user_id_new'] |
754 | + |
755 | + if 'date_new' in context: |
756 | + referencia = context['date_new'] |
757 | + |
758 | + #resource to return |
759 | + res = [] |
760 | + |
761 | + voucher_obj = self.pool.get('account.voucher') |
762 | + voucher_line_obj = self.pool.get('account.voucher.line') |
763 | + |
764 | + # first search the account_voucher in state posted, type receip and created by user_id |
765 | + voucher_list = voucher_obj.search(cr, uid, [('state','=','posted'), |
766 | + ('type','=','receipt'), |
767 | + ('create_uid','=',user_id_to_use),],) |
768 | + #order='journal_id') |
769 | + |
770 | + voucher_list = tuple(voucher_list) |
771 | + |
772 | + # each one contain voucher_lines, search the lines (Could filter using cr or dr type) |
773 | + voucher_line_list = voucher_line_obj.search(cr, uid, [('voucher_id','in',voucher_list),], |
774 | + order='name') |
775 | + |
776 | + for lineas in voucher_line_obj.browse(cr, uid, voucher_line_list): |
777 | + |
778 | + #Verify the date |
779 | + if self.is_today(lineas.voucher_id.date, referencia): |
780 | + |
781 | + temp = { |
782 | + 'partner': lineas.partner_id.name, |
783 | + 'name': lineas.voucher_id.journal_id.name, |
784 | + 'factura': lineas.name, |
785 | + 'importe': lineas.amount, |
786 | + 'saldo': lineas.amount_original - lineas.amount, |
787 | + } |
788 | + |
789 | + res.append(temp) |
790 | + |
791 | + #Order by journal_id |
792 | + def __cmpTexto(x, y): |
793 | + if x['name'] < y['name']: |
794 | + return -1 |
795 | + elif x['name'] == y['name']: |
796 | + return 0 |
797 | + else: |
798 | + return 1 |
799 | + |
800 | + cmp = lambda x,y: __cmpTexto(x, y) |
801 | + |
802 | + res.sort(cmp) |
803 | + |
804 | + return res |
805 | + |
806 | + |
807 | + def _facturas_emitidas(self, cr, uid, context = None): |
808 | + # the Idea is search in account.invoice all rows from this user (id) and |
809 | + # load the field, in this case present a list of emiting invoice showing |
810 | + # the actual state |
811 | + |
812 | + user_id_to_use = uid |
813 | + referencia = time.strftime('%Y-%m-%d %H:%M:%S') |
814 | + |
815 | + if 'user_id_new' in context: |
816 | + user_id_to_use = context['user_id_new'] |
817 | + |
818 | + if 'date_new' in context: |
819 | + referencia = context['date_new'] |
820 | + |
821 | + #resource to return |
822 | + res = [] |
823 | + |
824 | + #This dict is for easy work whit repeats names |
825 | + res_dic = {} |
826 | + |
827 | + object_obj = self.pool.get('account.invoice') |
828 | + |
829 | + list_ids = object_obj.search(cr, uid, [('state','!=','draft'), |
830 | + ('type','=','out_invoice'), |
831 | + ('user_id','=',user_id_to_use),], |
832 | + order='invoice_number,name,state') |
833 | + |
834 | + #Need a internal id for every client id (name can be the same twice) |
835 | + i = 0 |
836 | + |
837 | + for element in object_obj.browse(cr, uid, list_ids): |
838 | + |
839 | + #Verify the date |
840 | + if self.is_today(element.date_invoice, referencia): |
841 | + |
842 | + res_dic[i] = { |
843 | + 'name': element.partner_id.name, |
844 | + 'number': element.invoice_number, |
845 | + 'reference': element.name, |
846 | + 'total': element.amount_total, |
847 | + 'estado': element.state, |
848 | + } |
849 | + |
850 | + i = i + 1 |
851 | + |
852 | + for elem in res_dic: |
853 | + res.append(res_dic[elem]) |
854 | + |
855 | + return res |
856 | + |
857 | + |
858 | + |
859 | + def _ordenes_venta_emitidas(self, cr, uid, context = None): |
860 | + # the Idea is search in sale.order all rows from this user (id) and |
861 | + # load the field, in this case present a list of emiting sale oreder showing |
862 | + # the actual state |
863 | + |
864 | + user_id_to_use = uid |
865 | + referencia = time.strftime('%Y-%m-%d %H:%M:%S') |
866 | + |
867 | + if 'user_id_new' in context: |
868 | + user_id_to_use = context['user_id_new'] |
869 | + |
870 | + if 'date_new' in context: |
871 | + referencia = context['date_new'] |
872 | + |
873 | + #resource to return |
874 | + res = [] |
875 | + |
876 | + #This dict is for easy work whit repeats names |
877 | + res_dic = {} |
878 | + |
879 | + object_obj = self.pool.get('sale.order') |
880 | + |
881 | + list_ids = object_obj.search(cr, uid, [('state','!=','draft'), |
882 | + ('user_id','=',user_id_to_use),], |
883 | + order='name,state') |
884 | + |
885 | + #Need a internal id for every client id (name can be the same twice) |
886 | + i = 0 |
887 | + |
888 | + for element in object_obj.browse(cr, uid, list_ids): |
889 | + |
890 | + #Verify the date |
891 | + if self.is_today(element.date_order, referencia): |
892 | + |
893 | + res_dic[i] = { |
894 | + 'name': element.partner_id.name, |
895 | + 'reference': element.client_order_ref, |
896 | + 'number': element.name, |
897 | + 'total': element.amount_total, |
898 | + 'tarifa': element.pricelist_id.name, |
899 | + 'estado': element.state, |
900 | + } |
901 | + |
902 | + i = i + 1 |
903 | + |
904 | + for elem in res_dic: |
905 | + res.append(res_dic[elem]) |
906 | + |
907 | + return res |
908 | + |
909 | + |
910 | + def _cobros_efectivo_cheque_consolidado(self, cr, uid, context = None): |
911 | + # the Idea is search in account.vouchert all rows from this user (id) and |
912 | + # load the fields grouping by journal and "Efectivo" and/or "Cheques". |
913 | + |
914 | + user_id_to_use = uid |
915 | + referencia = time.strftime('%Y-%m-%d %H:%M:%S') |
916 | + |
917 | + if 'user_id_new' in context: |
918 | + user_id_to_use = context['user_id_new'] |
919 | + |
920 | + if 'date_new' in context: |
921 | + referencia = context['date_new'] |
922 | + |
923 | + #resource to return |
924 | + res = [] |
925 | + |
926 | + #This dict is for easy work whit repeats names |
927 | + res_dic = {} |
928 | + |
929 | + object_obj = self.pool.get('account.voucher') |
930 | + |
931 | + list_ids = object_obj.search(cr, uid, [('state','=','posted'), |
932 | + ('create_uid','=',user_id_to_use),], |
933 | + order='create_uid') |
934 | + |
935 | + for lineas in object_obj.browse(cr, uid, list_ids): |
936 | + |
937 | + #Verify the date |
938 | + if self.is_today(lineas.date, referencia): |
939 | + |
940 | + #Group by consumer and sum |
941 | + if lineas.journal_id.name in res_dic: |
942 | + |
943 | + temp = res_dic[lineas.journal_id.name] |
944 | + |
945 | + res_dic[lineas.journal_id.name] = { |
946 | + 'name': lineas.journal_id.name, |
947 | + 'number': temp['number'] + 1, |
948 | + 'total': temp['total'] + lineas.amount, |
949 | + } |
950 | + |
951 | + #first element |
952 | + else: |
953 | + res_dic[lineas.journal_id.name] = { |
954 | + 'name': lineas.journal_id.name, |
955 | + 'number': 1, |
956 | + 'total': lineas.amount, |
957 | + #'tipo': 'cec', |
958 | + } |
959 | + |
960 | + for elem in res_dic: |
961 | + res.append(res_dic[elem]) |
962 | + |
963 | + return res |
964 | + |
965 | + |
966 | + _columns = { |
967 | + 'date': fields.datetime('fecha', required=True), |
968 | + 'user_id': fields.many2one('res.users', 'Usuario', required=True), |
969 | + 'shop_id': fields.many2one('sale.shop', 'Tienda', required=True), |
970 | + 'ovsf_ids': fields.one2many('caja.ordenes.sin.factura', 'caja_id', 'Ordenes de Venta sin facturar', readonly=True),# required=False, domain=[('tipo','=','ov')]), |
971 | + 'fsc_ids': fields.one2many('caja.factura.sin.pago', 'caja_id', 'Facturas sin cobrar', readonly=True),# required=False, domain=[('tipo','=','fc')]), |
972 | + 'cobros_efectivo_cheque': fields.one2many('caja.diarios.pagos', 'caja_id', 'Cobros en Efectivo y Cheque', readonly=True),# required=False, domain=[('tipo','=','cec')]), |
973 | + # |
974 | + 'facturas_emitidas': fields.one2many('caja.facturas.emitidas', 'caja_id', 'Facturas Emitidas', readonly=True),# required=False, domain=[('tipo','=','cec')]), |
975 | + 'ordenes_venta_emitidas': fields.one2many('caja.ordenes.venta.emitidas', 'caja_id', 'Notas de Venta Emitidas', readonly=True),# required=False, domain=[('tipo','=','cec')]), |
976 | + 'cobros_efec_cheq_consolidado': fields.one2many('caja.diarios.pagos.consolidado', 'caja_id', 'Cobros en Efectivo y Cheque Consolidado', readonly=True),# required=False, domain=[('tipo','=','cec')]), |
977 | + |
978 | +# 'tarjetas_ids': fields.one2many('caja.ordenes.facturas', 'caja_id', 'Cobros Tarjetas', required=False, domain=[('tipo','=','ct')]), |
979 | +# 'bancos_ids': fields.one2many('caja.ordenes.facturas', 'caja_id', 'Cobros Bancos', required=False, domain=[('tipo','=','cb')]), |
980 | +# 'retenciones_ids': fields.one2many('caja.ordenes.facturas', 'caja_id', 'Cobros Retenciones', required=False, domain=[('tipo','=','cr')]), |
981 | + } |
982 | + |
983 | + _defaults = { |
984 | + 'date': lambda *a: time.strftime('%Y-%m-%d %H:%M:%S'), |
985 | + 'user_id': lambda s, cr, uid, c: uid, |
986 | + 'ovsf_ids': _Ordenes_venta_sin_facturar, |
987 | + 'fsc_ids': _facturas_sin_cancelar, |
988 | + 'cobros_efectivo_cheque': _cobros_efectivo_cheque, |
989 | + 'facturas_emitidas': _facturas_emitidas, |
990 | + 'ordenes_venta_emitidas': _ordenes_venta_emitidas, |
991 | + 'cobros_efec_cheq_consolidado': _cobros_efectivo_cheque_consolidado, |
992 | +# 'tarjetas_ids': _tarjetas_ids, |
993 | +# 'bancos_ids': _bancos_ids, |
994 | +# 'retenciones_ids': _retenciones_ids, |
995 | + } |
996 | + |
997 | +# def imprimir(self, cr, uid, ids, context=None): |
998 | +# |
999 | +# if context is None: |
1000 | +# context = {} |
1001 | +# |
1002 | +# data = {} |
1003 | +# data['model'] = 'account.invoice' |
1004 | +# data['ids'] = context.get('active_ids', False) |
1005 | +# |
1006 | +# return { |
1007 | +# 'type': 'ir.actions.report.xml', |
1008 | +# 'report_name': 'caja_reporte', # the 'Service Name' from the report |
1009 | +# 'datas' : data, |
1010 | +# 'context': context, |
1011 | +# } |
1012 | + |
1013 | + def imprimir(self, cr, uid, ids, context=None): |
1014 | + |
1015 | + # create the data for the report, only when the system print the report |
1016 | + # use the ids to instance this object and complete the info for the search |
1017 | + |
1018 | + |
1019 | + return { |
1020 | + 'type': 'ir.actions.report.xml', |
1021 | + 'report_name': 'caja_reporte', # the 'Service Name' from the report |
1022 | + 'datas' : { |
1023 | + 'model' : 'caja.reporte', # Report Model |
1024 | + 'res_ids' : ids |
1025 | + } |
1026 | + } |
1027 | + |
1028 | +caja_reporte() |
1029 | + |
1030 | +class caja_ordenes_sin_factura(osv.osv_memory): |
1031 | + |
1032 | + _name = 'caja.ordenes.sin.factura' |
1033 | + |
1034 | + _columns = { |
1035 | + 'name': fields.char('Cliente', size=256, required=False, readonly=False), |
1036 | + 'sale_number': fields.char('Orden de Venta', size=256, required=False, readonly=False), |
1037 | + 'reference': fields.char('Referencia', size=256, required=False, readonly=False), |
1038 | + 'total': fields.float('Total', digits=(2,5)), |
1039 | + 'caja_id':fields.many2one('caja.reporte', 'Reporte Caja', required=False), |
1040 | + |
1041 | + } |
1042 | + |
1043 | +caja_ordenes_sin_factura() |
1044 | + |
1045 | +class caja_facturas_sin_pago(osv.osv_memory): |
1046 | + |
1047 | + _name = 'caja.factura.sin.pago' |
1048 | + |
1049 | + _columns = { |
1050 | + 'name': fields.char('Cliente', size=256, required=False, readonly=False), |
1051 | + 'invoice_number': fields.char('Facturas', size=256, required=False, readonly=False), |
1052 | + 'reference': fields.char('Descripcion', size=256, required=False, readonly=False), |
1053 | + 'total': fields.float('Total', digits=(2,5)), |
1054 | + 'caja_id':fields.many2one('caja.reporte', 'Reporte Caja', required=False), |
1055 | + } |
1056 | + |
1057 | +caja_facturas_sin_pago() |
1058 | + |
1059 | +class caja_diarios_pagos(osv.osv_memory): |
1060 | + |
1061 | + _name = 'caja.diarios.pagos' |
1062 | + |
1063 | + _columns = { |
1064 | + 'partner': fields.char('Cliente', size=256, required=False, readonly=False), |
1065 | + 'name': fields.char('Diario', size=256, required=False, readonly=False), |
1066 | + 'factura': fields.char('Numero de Factura', size=256, required=False, readonly=False), |
1067 | + 'importe': fields.float('Importe', digits=(2,5)), |
1068 | + 'saldo': fields.float('Saldo', digits=(2,5)), |
1069 | + 'caja_id':fields.many2one('caja.reporte', 'Reporte Caja', required=False), |
1070 | + } |
1071 | + |
1072 | +caja_diarios_pagos() |
1073 | + |
1074 | +class caja_facturas_emitidas(osv.osv_memory): |
1075 | + |
1076 | + _name = 'caja.facturas.emitidas' |
1077 | + |
1078 | + _columns = { |
1079 | + 'name': fields.char('Cliente', size=256, required=False, readonly=False), |
1080 | + 'number': fields.char('Numero de Factura', size=32, required=False, readonly=False), |
1081 | + 'reference': fields.char('Descripcion', size=256, required=False, readonly=False), |
1082 | + 'total': fields.float('Total', digits=(2,5)), |
1083 | + 'estado': fields.char('Estado', size=32, required=False, readonly=False), |
1084 | + 'caja_id':fields.many2one('caja.reporte', 'Reporte Caja', required=False), |
1085 | + } |
1086 | + |
1087 | +caja_facturas_emitidas() |
1088 | + |
1089 | +class caja_ordenes_venta_emitidas(osv.osv_memory): |
1090 | + |
1091 | + _name = 'caja.ordenes.venta.emitidas' |
1092 | + |
1093 | + _columns = { |
1094 | + 'name': fields.char('Cliente', size=256, required=False, readonly=False), |
1095 | + 'number': fields.char('Numero de Orden de Venta', size=32, required=False, readonly=False), |
1096 | + 'reference': fields.char('Referencia', size=256, required=False, readonly=False), |
1097 | + 'total': fields.float('Total', digits=(2,5)), |
1098 | + 'estado': fields.char('Estado', size=32, required=False, readonly=False), |
1099 | + 'tarifa': fields.char('Tarifa', size=256, required=False, readonly=False), |
1100 | + 'caja_id':fields.many2one('caja.reporte', 'Reporte Caja', required=False), |
1101 | + } |
1102 | + |
1103 | +caja_ordenes_venta_emitidas() |
1104 | + |
1105 | +class caja_diarios_pagos_consolidado(osv.osv_memory): |
1106 | + |
1107 | + _name = 'caja.diarios.pagos.consolidado' |
1108 | + |
1109 | + _columns = { |
1110 | + 'name': fields.char('Cliente', size=256, required=False, readonly=False), |
1111 | + 'number': fields.integer('Numero'), |
1112 | + 'total': fields.float('Total', digits=(2,5)), |
1113 | + 'caja_id':fields.many2one('caja.reporte', 'Reporte Caja', required=False), |
1114 | + } |
1115 | + |
1116 | +caja_diarios_pagos_consolidado() |
1117 | + |
1118 | |
1119 | === added directory 'ecua_cash_register_report/report' |
1120 | === added file 'ecua_cash_register_report/report/caja_report.odt' |
1121 | Binary files ecua_cash_register_report/report/caja_report.odt 1970-01-01 00:00:00 +0000 and ecua_cash_register_report/report/caja_report.odt 2013-05-03 13:54:27 +0000 differ |
1122 | === added file 'ecua_cash_register_report/report/report_data.xml' |
1123 | --- ecua_cash_register_report/report/report_data.xml 1970-01-01 00:00:00 +0000 |
1124 | +++ ecua_cash_register_report/report/report_data.xml 2013-05-03 13:54:27 +0000 |
1125 | @@ -0,0 +1,21 @@ |
1126 | +<?xml version="1.0" encoding="UTF-8"?> |
1127 | +<openerp> |
1128 | + <data> |
1129 | + |
1130 | +<!-- !!!!!!!!!!!!!!!!!!!!!!!!! REPORTE - CAJA !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> |
1131 | + |
1132 | + <record id="caja_report" model="ir.actions.report.xml"> |
1133 | + <field name="name">Reporte de Caja</field> |
1134 | + <field name="type">ir.actions.report.xml</field> |
1135 | + <field name="model">caja.reporte</field> |
1136 | + <field name="report_name">caja_reporte</field> |
1137 | + <field name="report_type">aeroo</field> |
1138 | + <field name="in_format">oo-odt</field> |
1139 | + <field name='out_format' eval="ref('report_aeroo_ooo.report_mimetypes_pdf_odt')" /> |
1140 | + <field name="report_rml">ecua_cash_register_report/report/caja_report.odt</field> |
1141 | + <field name="parser_state">default</field> |
1142 | + <field name="tml_source">file</field> |
1143 | + </record> |
1144 | + |
1145 | + </data> |
1146 | +</openerp> |
1147 | \ No newline at end of file |
1148 | |
1149 | === added directory 'ecua_cash_register_report/view' |
1150 | === added file 'ecua_cash_register_report/view/ecua_cash_register_report_view.xml' |
1151 | --- ecua_cash_register_report/view/ecua_cash_register_report_view.xml 1970-01-01 00:00:00 +0000 |
1152 | +++ ecua_cash_register_report/view/ecua_cash_register_report_view.xml 2013-05-03 13:54:27 +0000 |
1153 | @@ -0,0 +1,154 @@ |
1154 | +<?xml version="1.0" encoding="UTF-8"?> |
1155 | +<openerp> |
1156 | + <data> |
1157 | + |
1158 | + <record model="ir.ui.view" id="caja_reporte_form_view"> |
1159 | + <field name="name">caja.reporte.form</field> |
1160 | + <field name="model">caja.reporte</field> |
1161 | + <field name="type">form</field> |
1162 | + <field name="arch" type="xml"> |
1163 | + <form string="Reporte de Caja"> |
1164 | + <group col="6" colspan="4"> |
1165 | + <field name="date" readonly="0" |
1166 | + on_change="onchange_date_user_id(date, user_id)" |
1167 | + groups="account.group_account_user"/> |
1168 | + <field name="user_id" readonly="0" |
1169 | + on_change="onchange_date_user_id(date, user_id)" |
1170 | + groups="account.group_account_user"/> |
1171 | + </group> |
1172 | + <newline/> |
1173 | + <group col="6" colspan="4"> |
1174 | + <button name="imprimir" string="Imprimir Reporte de Caja" type="object"/> |
1175 | + </group> |
1176 | + <newline/> |
1177 | + <notebook colspan="4"> |
1178 | + <page string="Ordenes de Venta sin factura"> |
1179 | + <field name="ovsf_ids" nolabel="1"/> |
1180 | + </page> |
1181 | + <page string="Facturas sin Cancelar"> |
1182 | + <field name="fsc_ids" nolabel="1"/> |
1183 | + </page> |
1184 | + <page string="Cobros Efectuados"> |
1185 | + <field name="cobros_efectivo_cheque" nolabel="1"/> |
1186 | + </page> |
1187 | + <page string="Resumen Cobros Efectuados"> |
1188 | + <field name="cobros_efec_cheq_consolidado" nolabel="1"/> |
1189 | + </page> |
1190 | + <page string="Facturas Emitidas"> |
1191 | + <field name="facturas_emitidas" nolabel="1"/> |
1192 | + </page> |
1193 | + <page string="Ordenes de Venta Emitidas"> |
1194 | + <field name="ordenes_venta_emitidas" nolabel="1"/> |
1195 | + </page> |
1196 | + </notebook> |
1197 | + </form> |
1198 | + </field> |
1199 | + </record> |
1200 | + |
1201 | + <record model="ir.ui.view" id="caja_ordenes_sin_factura_tree_view"> |
1202 | + <field name="name">caja.ordenes.sin.factura.tree</field> |
1203 | + <field name="model">caja.ordenes.sin.factura</field> |
1204 | + <field name="type">tree</field> |
1205 | + <field name="arch" type="xml"> |
1206 | + <tree string="Detalle"> |
1207 | + <field name="name" select="1"/> |
1208 | + <field name="sale_number" select="1"/> |
1209 | + <field name="reference" select="1"/> |
1210 | + <field name="total" select="1"/> |
1211 | + </tree> |
1212 | + </field> |
1213 | + </record> |
1214 | + |
1215 | + <record model="ir.ui.view" id="caja_factura_sin_pago_tree_view"> |
1216 | + <field name="name">caja.factura.sin.pago.tree</field> |
1217 | + <field name="model">caja.factura.sin.pago</field> |
1218 | + <field name="type">tree</field> |
1219 | + <field name="arch" type="xml"> |
1220 | + <tree string="Detalle"> |
1221 | + <field name="name" select="1"/> |
1222 | + <field name="invoice_number" select="1"/> |
1223 | + <field name="reference" select="1"/> |
1224 | + <field name="total" select="1"/> |
1225 | + </tree> |
1226 | + </field> |
1227 | + </record> |
1228 | + |
1229 | + <record model="ir.ui.view" id="caja_diarios_pagos_tree_view"> |
1230 | + <field name="name">caja.diarios.pagos.tree</field> |
1231 | + <field name="model">caja.diarios.pagos</field> |
1232 | + <field name="type">tree</field> |
1233 | + <field name="arch" type="xml"> |
1234 | + <tree string="Detalle"> |
1235 | + <field name="partner" select="1"/> |
1236 | + <field name="name" select="1"/> |
1237 | + <field name="factura" select="1"/> |
1238 | + <field name="importe" select="1"/> |
1239 | + <field name="saldo" select="1"/> |
1240 | + </tree> |
1241 | + </field> |
1242 | + </record> |
1243 | + |
1244 | + <record model="ir.ui.view" id="caja_diarios_pagos_consolidado_tree_view"> |
1245 | + <field name="name">caja.diarios.pagos.consolidado.tree</field> |
1246 | + <field name="model">caja.diarios.pagos.consolidado</field> |
1247 | + <field name="type">tree</field> |
1248 | + <field name="arch" type="xml"> |
1249 | + <tree string="Detalle"> |
1250 | + <field name="name" select="1"/> |
1251 | + <field name="number" select="1"/> |
1252 | + <field name="total" select="1"/> |
1253 | + </tree> |
1254 | + </field> |
1255 | + </record> |
1256 | + |
1257 | + |
1258 | + |
1259 | + <record model="ir.ui.view" id="caja_facturas_emitidas_view"> |
1260 | + <field name="name">caja.facturas.emitidas.tree</field> |
1261 | + <field name="model">caja.facturas.emitidas</field> |
1262 | + <field name="type">tree</field> |
1263 | + <field name="arch" type="xml"> |
1264 | + <tree string="Detalle"> |
1265 | + <field name="name" select="1"/> |
1266 | + <field name="number" select="1"/> |
1267 | + <field name="reference" select="1"/> |
1268 | + <field name="total" select="1"/> |
1269 | + <field name="estado" select="1"/> |
1270 | + </tree> |
1271 | + </field> |
1272 | + </record> |
1273 | + |
1274 | + <record model="ir.ui.view" id="caja_ordenes_venta_emitidas_view"> |
1275 | + <field name="name">caja.ordenes.venta.emitidas.tree</field> |
1276 | + <field name="model">caja.ordenes.venta.emitidas</field> |
1277 | + <field name="type">tree</field> |
1278 | + <field name="arch" type="xml"> |
1279 | + <tree string="Detalle"> |
1280 | + <field name="name" select="1"/> |
1281 | + <field name="number" select="1"/> |
1282 | + <field name="reference" select="1"/> |
1283 | + <field name="total" select="1"/> |
1284 | + <field name="estado" select="1"/> |
1285 | + <field name="tarifa" select="1"/> |
1286 | + </tree> |
1287 | + </field> |
1288 | + </record> |
1289 | + |
1290 | + <record model="ir.actions.act_window" id="action_caja_reporte_tree_view"> |
1291 | + <field name="name">caja.reporte</field> |
1292 | + <field name="type">ir.actions.act_window</field> |
1293 | + <field name="res_model">caja.reporte</field> |
1294 | + <!-- <field name="domain">[('field_name','condition',criteria)]</field>--> |
1295 | + <field name="view_type">form</field> |
1296 | + <field name="view_mode">tree,form</field> |
1297 | + <field name="view_id" ref="caja_reporte_form_view"/> |
1298 | + <field name="target">new</field> |
1299 | + </record> |
1300 | + |
1301 | + |
1302 | +<!-- MENU --> |
1303 | + |
1304 | + <menuitem id="caja_reporte" name="Reporte de Caja" action="action_caja_reporte_tree_view" parent="base.next_id_64"/> |
1305 | + |
1306 | + </data> |
1307 | +</openerp> |
1308 | |
1309 | === modified file 'ecua_facturas_ice_manual/__init__.py' (properties changed: -x to +x) |
1310 | === modified file 'ecua_facturas_ice_manual/__openerp__.py' (properties changed: -x to +x) |
1311 | === modified file 'ecua_facturas_ice_manual/data/ice_codes.xml' (properties changed: -x to +x) |
1312 | === modified file 'ecua_facturas_ice_manual/data/ice_tax.xml' (properties changed: -x to +x) |
1313 | === modified file 'ecua_facturas_ice_manual/docs/formulario 105.xls' (properties changed: -x to +x) |
1314 | === modified file 'ecua_facturas_ice_manual/docs/instruc 105.doc' (properties changed: -x to +x) |
1315 | === modified file 'ecua_facturas_ice_manual/i18n/es.po' (properties changed: -x to +x) |
1316 | === modified file 'ecua_facturas_ice_manual/objects/__init__.py' (properties changed: -x to +x) |
1317 | === modified file 'ecua_facturas_ice_manual/objects/invoice.py' (properties changed: -x to +x) |
1318 | --- ecua_facturas_ice_manual/objects/invoice.py 2013-04-21 14:26:15 +0000 |
1319 | +++ ecua_facturas_ice_manual/objects/invoice.py 2013-05-03 13:54:27 +0000 |
1320 | @@ -217,7 +217,7 @@ |
1321 | taxes.append(tax) |
1322 | #computo de ice |
1323 | if ice: |
1324 | - for tax in tax_obj.compute_all(cr, uid, taxes, (line.price_unit* (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id, {'skip_round':True})['taxes']: |
1325 | + for tax in tax_obj.compute_all(cr, uid, taxes, (line.price_unit* (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id)['taxes']:#, {'skip_round':True})['taxes']: |
1326 | tax_browse = tax_obj.browse(cr, uid, tax['id'], context) |
1327 | val={} |
1328 | val['invoice_id'] = inv.id |
1329 | @@ -261,7 +261,7 @@ |
1330 | ice_value = 1 |
1331 | if line.product_id.ice_type_id: |
1332 | ice_value = 1+line.product_id.ice_type_id.rate |
1333 | - for tax in tax_obj.compute_all(cr, uid, tax_iva, (line.price_unit * (ice_value) * (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id,{'skip_round':True})['taxes']: |
1334 | + for tax in tax_obj.compute_all(cr, uid, tax_iva, (line.price_unit * (ice_value) * (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id)['taxes']:#,{'skip_round':True})['taxes']: |
1335 | tax_browse = tax_obj.browse(cr, uid, tax['id'], context) |
1336 | val={} |
1337 | val['invoice_id'] = inv.id |
1338 | @@ -302,7 +302,7 @@ |
1339 | tax_grouped[key]['tax_amount'] += val['tax_amount'] |
1340 | |
1341 | else: |
1342 | - for tax in tax_obj.compute_all(cr, uid, line.invoice_line_tax_id, (line.price_unit* (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id,{'skip_round':True})['taxes']: |
1343 | + for tax in tax_obj.compute_all(cr, uid, line.invoice_line_tax_id, (line.price_unit* (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id,)['taxes']:#context={'skip_round':True})['taxes']: |
1344 | tax_browse = tax_obj.browse(cr, uid, tax['id'], context) |
1345 | val={} |
1346 | val['invoice_id'] = inv.id |
1347 | |
1348 | === modified file 'ecua_facturas_ice_manual/objects/product.py' (properties changed: -x to +x) |
1349 | === modified file 'ecua_facturas_ice_manual/objects/purchase_order.py' (properties changed: -x to +x) |
1350 | === modified file 'ecua_facturas_ice_manual/objects/sale_order.py' (properties changed: -x to +x) |
1351 | === modified file 'ecua_facturas_ice_manual/report/factura_ice_report.odt' (properties changed: -x to +x) |
1352 | === modified file 'ecua_facturas_ice_manual/report/factura_ice_report.xml' (properties changed: -x to +x) |
1353 | --- ecua_facturas_ice_manual/report/factura_ice_report.xml 2013-02-16 14:02:25 +0000 |
1354 | +++ ecua_facturas_ice_manual/report/factura_ice_report.xml 2013-05-03 13:54:27 +0000 |
1355 | @@ -1,6 +1,7 @@ |
1356 | <?xml version="1.0" encoding="UTF-8"?> |
1357 | <openerp> |
1358 | - <data> |
1359 | + <!-- no actualizar ya que en multicompania o multidb debe poder personalizarse --> |
1360 | + <data noupdate="1"> |
1361 | <record id="invoice_ice_report" model="ir.actions.report.xml"> |
1362 | <field name="name">Facturas ICE</field> |
1363 | <field name="type">ir.actions.report.xml</field> |
1364 | |
1365 | === modified file 'ecua_facturas_ice_manual/security/ir.model.access.csv' (properties changed: -x to +x) |
1366 | === modified file 'ecua_facturas_ice_manual/views/account_invoice_view.xml' (properties changed: -x to +x) |
1367 | === modified file 'ecua_facturas_ice_manual/views/product_view.xml' (properties changed: -x to +x) |
1368 | === modified file 'ecua_facturas_ice_manual/views/purchase_order_view.xml' (properties changed: -x to +x) |
1369 | === modified file 'ecua_facturas_ice_manual/views/sale_order_view.xml' (properties changed: -x to +x) |
1370 | === modified file 'ecua_facturas_ice_manual/wizard/__init__.py' (properties changed: -x to +x) |
1371 | === modified file 'ecua_facturas_ice_manual/wizard/invoice_print_wizard.py' (properties changed: -x to +x) |
1372 | === modified file 'ecua_facturas_ice_manual/wizard/wizard_invoice_ice.py' (properties changed: -x to +x) |
1373 | === modified file 'ecua_facturas_ice_manual/wizard/wizard_invoice_ice.xml' (properties changed: -x to +x) |
1374 | === modified file 'ecua_facturas_ice_manual/wizard/wizard_sale_order_ice.py' (properties changed: -x to +x) |
1375 | === modified file 'ecua_facturas_ice_manual/wizard/wizard_sale_order_ice.xml' (properties changed: -x to +x) |
1376 | === modified file 'ecua_facturas_manual/Revision' (properties changed: -x to +x) |
1377 | === modified file 'ecua_facturas_manual/__init__.py' (properties changed: -x to +x) |
1378 | === modified file 'ecua_facturas_manual/__openerp__.py' (properties changed: -x to +x) |
1379 | --- ecua_facturas_manual/__openerp__.py 2013-02-16 14:02:25 +0000 |
1380 | +++ ecua_facturas_manual/__openerp__.py 2013-05-03 13:54:27 +0000 |
1381 | @@ -24,6 +24,7 @@ |
1382 | "depends" : [ |
1383 | 'base', |
1384 | 'account', |
1385 | + 'account_voucher', |
1386 | 'sale', |
1387 | 'stock', |
1388 | 'purchase', |
1389 | @@ -52,6 +53,7 @@ |
1390 | 'views/purchase_order_view.xml', |
1391 | 'views/sale_order_view.xml', |
1392 | 'views/account_invoice_line_view.xml', |
1393 | + 'views/account_voucher.xml' |
1394 | ], |
1395 | "installable": True, |
1396 | "active": False, |
1397 | |
1398 | === modified file 'ecua_facturas_manual/i18n/es.po' (properties changed: -x to +x) |
1399 | === modified file 'ecua_facturas_manual/objects/__init__.py' (properties changed: -x to +x) |
1400 | === modified file 'ecua_facturas_manual/objects/company.py' (properties changed: -x to +x) |
1401 | === modified file 'ecua_facturas_manual/objects/invoice.py' (properties changed: -x to +x) |
1402 | --- ecua_facturas_manual/objects/invoice.py 2013-04-21 14:05:46 +0000 |
1403 | +++ ecua_facturas_manual/objects/invoice.py 2013-05-03 13:54:27 +0000 |
1404 | @@ -376,7 +376,6 @@ |
1405 | for node in nodes: |
1406 | node.set('invisible', "0") |
1407 | res['arch'] = etree.tostring(doc) |
1408 | - res['arch'] |
1409 | return res |
1410 | |
1411 | def _get_automatic(self, cr, uid, context=None): |
1412 | |
1413 | === modified file 'ecua_facturas_manual/objects/invoice_line.py' (properties changed: -x to +x) |
1414 | --- ecua_facturas_manual/objects/invoice_line.py 2013-04-21 14:26:15 +0000 |
1415 | +++ ecua_facturas_manual/objects/invoice_line.py 2013-05-03 13:54:27 +0000 |
1416 | @@ -45,6 +45,8 @@ |
1417 | _columns = { |
1418 | 'price_unit_final': fields.function(_price_unit_final, method=True, type='float', digits_compute= dp.get_precision('Invoice Line Price'), string='Price Unit Final', store=True), |
1419 | } |
1420 | + |
1421 | def onchange_account_id(self, cr, uid, ids, fposition_id, account_id): |
1422 | return {} |
1423 | + |
1424 | account_invoice_line() |
1425 | \ No newline at end of file |
1426 | |
1427 | === modified file 'ecua_facturas_manual/objects/picking.py' (properties changed: -x to +x) |
1428 | === modified file 'ecua_facturas_manual/objects/purchase_order.py' (properties changed: -x to +x) |
1429 | --- ecua_facturas_manual/objects/purchase_order.py 2013-04-21 14:26:15 +0000 |
1430 | +++ ecua_facturas_manual/objects/purchase_order.py 2013-05-03 13:54:27 +0000 |
1431 | @@ -49,7 +49,7 @@ |
1432 | cur = order.pricelist_id.currency_id |
1433 | for line in order.order_line: |
1434 | val1 += line.price_subtotal |
1435 | - for c in self.pool.get('account.tax').compute_all(cr, uid, line.taxes_id, line.price_unit, line.product_qty, order.partner_address_id.id, line.product_id.id, order.partner_id, context={'skip_round':True})['taxes']: |
1436 | + for c in self.pool.get('account.tax').compute_all(cr, uid, line.taxes_id, line.price_unit, line.product_qty, order.partner_address_id.id, line.product_id.id, order.partner_id)['taxes']:#, context={'skip_round':True})['taxes']: |
1437 | tax = c.get('amount', 0.0) |
1438 | val += c.get('amount', 0.0) |
1439 | if tax == 0.0 and c.get('type_ec', False) == 'iva': |
1440 | |
1441 | === modified file 'ecua_facturas_manual/objects/sale_order.py' (properties changed: -x to +x) |
1442 | --- ecua_facturas_manual/objects/sale_order.py 2013-04-21 14:26:15 +0000 |
1443 | +++ ecua_facturas_manual/objects/sale_order.py 2013-05-03 13:54:27 +0000 |
1444 | @@ -36,7 +36,7 @@ |
1445 | |
1446 | def _amount_line_tax(self, cr, uid, line, context=None): |
1447 | val = 0.0 |
1448 | - for c in self.pool.get('account.tax').compute_all(cr, uid, line.tax_id, line.price_unit * (1-(line.discount or 0.0)/100.0), line.product_uom_qty, line.order_id.partner_invoice_id.id, line.product_id, line.order_id.partner_id,{'skip_round':True})['taxes']: |
1449 | + for c in self.pool.get('account.tax').compute_all(cr, uid, line.tax_id, line.price_unit * (1-(line.discount or 0.0)/100.0), line.product_uom_qty, line.order_id.partner_invoice_id.id, line.product_id, line.order_id.partner_id)['taxes']:#,{'skip_round':True})['taxes']: |
1450 | val += c.get('amount', 0.0) |
1451 | return val |
1452 | |
1453 | @@ -185,7 +185,15 @@ |
1454 | if automatic: |
1455 | automatic_number = doc_obj.get_next_value_secuence(cr, uid, 'invoice', False, order.company_id.id, order.shop_id.id, order.printer_id.id, 'account.invoice', 'invoice_number_out', context) |
1456 | invoice_number_out = automatic_number |
1457 | + date_invoice = time.strftime('%Y-%m-%d') |
1458 | + else: |
1459 | + #Is useful in the case of there are not automatic, that happens when you choice generate_automatic |
1460 | + curr_shop = self.pool.get('sale.shop').browse(cr, uid, [order.shop_id.id], context)[0] |
1461 | + printer_obj = self.pool.get('sri.printer.point') |
1462 | + automatic_number =curr_shop.number + "-" + printer_obj.browse(cr, uid,order.printer_id.id, context).number + "-000000000" |
1463 | + invoice_number_out = automatic_number |
1464 | date_invoice = time.strftime('%Y-%m-%d') |
1465 | + |
1466 | inv = { |
1467 | 'name': order.client_order_ref or '', |
1468 | 'origin': order.name, |
1469 | |
1470 | === modified file 'ecua_facturas_manual/report/factura.jrxml' (properties changed: -x to +x) |
1471 | === modified file 'ecua_facturas_manual/report/factura_report.odt' (properties changed: -x to +x) |
1472 | === modified file 'ecua_facturas_manual/report/factura_report.xml' (properties changed: -x to +x) |
1473 | --- ecua_facturas_manual/report/factura_report.xml 2013-02-16 14:02:25 +0000 |
1474 | +++ ecua_facturas_manual/report/factura_report.xml 2013-05-03 13:54:27 +0000 |
1475 | @@ -1,6 +1,7 @@ |
1476 | <?xml version="1.0" encoding="UTF-8"?> |
1477 | <openerp> |
1478 | - <data> |
1479 | + <!-- no actualizar ya que en multicompania o multidb debe poder personalizarse --> |
1480 | + <data noupdate="1"> |
1481 | <record id="invoice_report" model="ir.actions.report.xml"> |
1482 | <field name="name">Facturas</field> |
1483 | <field name="type">ir.actions.report.xml</field> |
1484 | |
1485 | === modified file 'ecua_facturas_manual/security/ir.model.access.csv' (properties changed: -x to +x) |
1486 | === modified file 'ecua_facturas_manual/views/account_invoice_line_view.xml' (properties changed: -x to +x) |
1487 | === modified file 'ecua_facturas_manual/views/account_invoice_view.xml' (properties changed: -x to +x) |
1488 | --- ecua_facturas_manual/views/account_invoice_view.xml 2013-04-21 14:05:46 +0000 |
1489 | +++ ecua_facturas_manual/views/account_invoice_view.xml 2013-05-03 13:54:27 +0000 |
1490 | @@ -22,7 +22,7 @@ |
1491 | context="{'search_default_customer': 1}" /> |
1492 | <field domain="[('partner_id','=',partner_id)]" name="address_invoice_id" /> |
1493 | <field name="fiscal_position" groups="base.group_extended" |
1494 | - widget="selection" /> |
1495 | + widget="selection" required="1"/> |
1496 | <newline /> |
1497 | <field name="date_invoice" /> |
1498 | <field name="period_id" domain="[('state', '=', 'draft')]" |
1499 | @@ -133,6 +133,7 @@ |
1500 | widget="selection" /> |
1501 | <field name="number" readonly="1" /> |
1502 | <field name="type" invisible="1" /> |
1503 | + <newline /> |
1504 | <field name="currency_id" width="50" /> |
1505 | <button name="%(account.action_account_change_currency)d" |
1506 | type="action" icon="terp-stock_effects-object-colorize" string="Change" |
1507 | @@ -143,7 +144,7 @@ |
1508 | context="{'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" /> |
1509 | <field domain="[('partner_id','=',partner_id)]" name="address_invoice_id" /> |
1510 | <field name="fiscal_position" groups="base.group_extended" |
1511 | - widget="selection" /> |
1512 | + widget="selection" required="1"/> |
1513 | <newline /> |
1514 | <field name="date_invoice" /> |
1515 | <field name="period_id" domain="[('state', '=', 'draft')]" |
1516 | @@ -262,6 +263,12 @@ |
1517 | </record> |
1518 | |
1519 | |
1520 | +<!-- P.R Modificado Herencia: |
1521 | +El modulo account_cancel hereda primero el boton invoice_cancel y el sistema hace caso omiso |
1522 | +a la modificacion hecha por esta herencia en el boton cancelar (invoice_form_cancel_inherit). |
1523 | +Se crea una vista que herede de account_cancel para los 2 botones existentes alli. Tambien se |
1524 | +comenta los botones para modificarlos en la nueva vista --> |
1525 | + |
1526 | <record model="ir.ui.view" id="account_invoice_sales_form_view"> |
1527 | <field name="name">account.invoice.form</field> |
1528 | <field name="model">account.invoice</field> |
1529 | @@ -293,25 +300,25 @@ |
1530 | <field name="invoice_number_out" required="1" |
1531 | on_change="onchange_number(invoice_number_out, automatic, company_id, shop_id, printer_id)"></field> |
1532 | </xpath> |
1533 | - <xpath |
1534 | +<!-- <xpath |
1535 | expr="/form/notebook/page/group/group//button[@name='invoice_cancel']" |
1536 | position="replace"> |
1537 | <button name="invoice_cancel" states="proforma2,sale,open" |
1538 | string="Cancel" icon="gtk-cancel" groups="account.group_account_manager" /> |
1539 | - </xpath> |
1540 | + </xpath> --> |
1541 | |
1542 | <xpath |
1543 | expr="/form/group//button[@name='%(account.action_account_change_currency)d']" |
1544 | position="replace" /> |
1545 | |
1546 | - <xpath |
1547 | +<!-- <xpath |
1548 | expr="/form/notebook/page/group/group//button[@name='%(account.action_account_state_open)d']" |
1549 | position="replace"> |
1550 | <button name="%(account.action_account_state_open)d" type='action' |
1551 | string='Re-Open' states='paid' icon="gtk-convert" |
1552 | groups="account.group_account_manager" /> |
1553 | - </xpath> |
1554 | - |
1555 | + </xpath> --> |
1556 | + |
1557 | <xpath expr="/form/group//field[@name='journal_id']" position="replace"> |
1558 | <field name="journal_id" groups="base.group_user" invisible="1" |
1559 | on_change="onchange_journal_id(journal_id)" widget="selection" /> |
1560 | @@ -345,6 +352,38 @@ |
1561 | </field> |
1562 | </record> |
1563 | |
1564 | +<!-- P.R Creado Herencia: |
1565 | +El modulo account_cancel hereda primero el boton invoice_cancel, por eso se construye una vista que |
1566 | +herede y modifique esta herencia en el boton cancelar (invoice_form_cancel_inherit). |
1567 | +--> |
1568 | + <record model="ir.ui.view" id="invoice_form_cancel_groups_inherit"> |
1569 | + <field name="name">invoice.form.cancel.groups.inherit</field> |
1570 | + <field name="model">account.invoice</field> |
1571 | + <field name="type">form</field> |
1572 | + <field name="inherit_id" ref="account_cancel.invoice_form_cancel_inherit" /> |
1573 | + <field name="arch" type="xml"> |
1574 | + <xpath |
1575 | + expr="//button[@name='invoice_cancel']" |
1576 | + position="replace"> |
1577 | + <button name="invoice_cancel" states="proforma2,sale,open" |
1578 | + string="Cancel" icon="gtk-cancel" groups="account.group_account_manager" /> |
1579 | + </xpath> |
1580 | + <xpath |
1581 | + expr="//button[@name='%(account.action_account_state_open)d']" |
1582 | + position="replace"> |
1583 | + <button name="%(account.action_account_state_open)d" type='action' |
1584 | + string='Re-Open' states='paid' icon="gtk-convert" |
1585 | + groups="account.group_account_manager" /> |
1586 | + </xpath> |
1587 | + </field> |
1588 | + </record> |
1589 | + |
1590 | + |
1591 | +<!-- P.R. Domain que no permite seleccionar todos los proveedores, eliminado |
1592 | + on_change="onchange_partner_id(type,partner_id,date_invoice,payment_term, partner_bank_id,company_id)" |
1593 | + domain="['|',('type_ref','=','ruc'),('foreing','=',True)]" |
1594 | + context="{'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" /> |
1595 | +--> |
1596 | <record model="ir.ui.view" id="account_invoice_purchase_form_view"> |
1597 | <field name="name">account.invoice.form</field> |
1598 | <field name="model">account.invoice</field> |
1599 | @@ -364,7 +403,6 @@ |
1600 | <xpath expr="/form/group//field[@name='partner_id']" position="replace"> |
1601 | <field string="Supplier" name="partner_id" |
1602 | on_change="onchange_partner_id(type,partner_id,date_invoice,payment_term, partner_bank_id,company_id)" |
1603 | - domain="['|',('type_ref','=','ruc'),('foreing','=',True)]" |
1604 | context="{'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" /> |
1605 | </xpath> |
1606 | <xpath expr="/form/group/field[@name='number']" position="replace"> |
1607 | |
1608 | === added file 'ecua_facturas_manual/views/account_voucher.xml' |
1609 | --- ecua_facturas_manual/views/account_voucher.xml 1970-01-01 00:00:00 +0000 |
1610 | +++ ecua_facturas_manual/views/account_voucher.xml 2013-05-03 13:54:27 +0000 |
1611 | @@ -0,0 +1,47 @@ |
1612 | +<?xml version="1.0" encoding="UTF-8"?> |
1613 | +<openerp> |
1614 | + <data> |
1615 | + |
1616 | + <record model="ir.ui.view" id="view_vendor_receipt_form_groups_inherit"> |
1617 | + <field name="name">view.vendor.receipt.form.groups.inherit</field> |
1618 | + <field name="model">account.voucher</field> |
1619 | + <field name="type">form</field> |
1620 | + <field name="inherit_id" ref="account_voucher.view_vendor_receipt_form" /> |
1621 | + <field name="arch" type="xml"> |
1622 | + <xpath expr="//button[@string='Unreconcile']" position="replace"> |
1623 | + <button name="cancel_voucher" string="Unreconcile" type="object" |
1624 | + states="posted" icon="terp-stock_effects-object-colorize" |
1625 | + confirm="Are you sure to unreconcile this record ?" |
1626 | + groups="account.group_account_manager" /> |
1627 | + </xpath> |
1628 | + <xpath expr="//button[@string='Cancel']" position="replace"> |
1629 | + <button name="cancel_voucher" string="Cancel" states="draft,proforma" |
1630 | + icon="gtk-cancel" groups="account.group_account_manager" /> |
1631 | + </xpath> |
1632 | + </field> |
1633 | + </record> |
1634 | + |
1635 | + |
1636 | + <record model="ir.ui.view" id="view_vendor_payment_form_groups_inherit"> |
1637 | + <field name="name">view.vendor.payment.form.groups.inherit</field> |
1638 | + <field name="model">account.voucher</field> |
1639 | + <field name="type">form</field> |
1640 | + <field name="inherit_id" ref="account_voucher.view_vendor_payment_form" /> |
1641 | + <field name="arch" type="xml"> |
1642 | + <xpath expr="//button[@string='Unreconcile']" position="replace"> |
1643 | + <button name="cancel_voucher" string="Unreconcile" type="object" |
1644 | + states="posted" icon="terp-stock_effects-object-colorize" |
1645 | + confirm="Are you sure to unreconcile this record ?" |
1646 | + groups="account.group_account_manager" /> |
1647 | + </xpath> |
1648 | + <xpath expr="//button[@string='Cancel']" position="replace"> |
1649 | + <button name="cancel_voucher" string="Cancel" states="draft,proforma" |
1650 | + icon="gtk-cancel" groups="account.group_account_manager" /> |
1651 | + </xpath> |
1652 | + </field> |
1653 | + </record> |
1654 | + |
1655 | + |
1656 | + </data> |
1657 | +</openerp> |
1658 | + |
1659 | \ No newline at end of file |
1660 | |
1661 | === modified file 'ecua_facturas_manual/views/authorization_supplier_view.xml' (properties changed: -x to +x) |
1662 | === modified file 'ecua_facturas_manual/views/purchase_order_view.xml' (properties changed: -x to +x) |
1663 | === modified file 'ecua_facturas_manual/views/sale_order_view.xml' (properties changed: -x to +x) |
1664 | === modified file 'ecua_facturas_manual/wizard/__init__.py' (properties changed: -x to +x) |
1665 | === modified file 'ecua_facturas_manual/wizard/invoice_print_wizard.py' (properties changed: -x to +x) |
1666 | === modified file 'ecua_facturas_manual/wizard/invoice_print_wizard.xml' (properties changed: -x to +x) |
1667 | === modified file 'ecua_inventarios/__init__.py' (properties changed: -x to +x) |
1668 | === modified file 'ecua_inventarios/__openerp__.py' (properties changed: -x to +x) |
1669 | === modified file 'ecua_inventarios/data/location_data.xml' (properties changed: -x to +x) |
1670 | === modified file 'ecua_inventarios/i18n/es.po' (properties changed: -x to +x) |
1671 | === modified file 'ecua_inventarios/object/__init__.py' (properties changed: -x to +x) |
1672 | === modified file 'ecua_inventarios/object/invoice.py' (properties changed: -x to +x) |
1673 | === modified file 'ecua_inventarios/object/location.py' (properties changed: -x to +x) |
1674 | === modified file 'ecua_inventarios/object/product.py' (properties changed: -x to +x) |
1675 | === modified file 'ecua_inventarios/object/sale.py' (properties changed: -x to +x) |
1676 | === modified file 'ecua_inventarios/object/stock.py' (properties changed: -x to +x) |
1677 | === modified file 'ecua_inventarios/report/__init__.py' (properties changed: -x to +x) |
1678 | === modified file 'ecua_inventarios/secutiry/ir.model.access.csv' (properties changed: -x to +x) |
1679 | === modified file 'ecua_inventarios/views/invoice_view.xml' (properties changed: -x to +x) |
1680 | === modified file 'ecua_inventarios/views/location_view.xml' (properties changed: -x to +x) |
1681 | === modified file 'ecua_inventarios/wizard/__init__.py' (properties changed: -x to +x) |
1682 | === modified file 'ecua_inventarios/wizard/delivery_note_wizard.py' (properties changed: -x to +x) |
1683 | === modified file 'ecua_inventarios/wizard/delivery_note_wizard.xml' (properties changed: -x to +x) |
1684 | === modified file 'ecua_inventarios/workflow/invoice_workflow.xml' (properties changed: -x to +x) |
1685 | === modified file 'ecua_liquidacion_compras/Revision' (properties changed: -x to +x) |
1686 | === modified file 'ecua_liquidacion_compras/__init__.py' (properties changed: -x to +x) |
1687 | === modified file 'ecua_liquidacion_compras/__openerp__.py' (properties changed: -x to +x) |
1688 | === modified file 'ecua_liquidacion_compras/data/data.xml' (properties changed: -x to +x) |
1689 | --- ecua_liquidacion_compras/data/data.xml 2013-02-16 14:02:25 +0000 |
1690 | +++ ecua_liquidacion_compras/data/data.xml 2013-05-03 13:54:27 +0000 |
1691 | @@ -18,6 +18,7 @@ |
1692 | <field name="code">DLIQ</field> |
1693 | <field name="type">purchase</field> |
1694 | <field name="liquidation">True</field> |
1695 | + <field name="update_posted">True</field> |
1696 | <field name="view_id" ref="account.account_journal_view"/> |
1697 | <field name="sequence_id" ref="liquidacion_sequence"/> |
1698 | <field name="user_id" ref="base.user_root"/> |
1699 | |
1700 | === modified file 'ecua_liquidacion_compras/i18n/es.mo' (properties changed: -x to +x) |
1701 | === modified file 'ecua_liquidacion_compras/i18n/es.po' (properties changed: -x to +x) |
1702 | === modified file 'ecua_liquidacion_compras/objects/__init__.py' (properties changed: -x to +x) |
1703 | === modified file 'ecua_liquidacion_compras/objects/account_journal.py' (properties changed: -x to +x) |
1704 | === modified file 'ecua_liquidacion_compras/objects/liquidacion_compra.py' (properties changed: -x to +x) |
1705 | === modified file 'ecua_liquidacion_compras/objects/shop.py' (properties changed: -x to +x) |
1706 | === modified file 'ecua_liquidacion_compras/report/liquidacion_reporte.odt' (properties changed: -x to +x) |
1707 | === modified file 'ecua_liquidacion_compras/report/liquidacion_reporte.xml' (properties changed: -x to +x) |
1708 | --- ecua_liquidacion_compras/report/liquidacion_reporte.xml 2013-02-16 14:02:25 +0000 |
1709 | +++ ecua_liquidacion_compras/report/liquidacion_reporte.xml 2013-05-03 13:54:27 +0000 |
1710 | @@ -1,6 +1,7 @@ |
1711 | <?xml version="1.0" encoding="UTF-8"?> |
1712 | <openerp> |
1713 | - <data> |
1714 | + <!-- no actualizar ya que en multicompania o multidb debe poder personalizarse --> |
1715 | + <data noupdate="1"> |
1716 | <record id="liquidacion_report" model="ir.actions.report.xml"> |
1717 | <field name="name">Liquidación de Compras</field> |
1718 | <field name="type">ir.actions.report.xml</field> |
1719 | |
1720 | === modified file 'ecua_liquidacion_compras/security/ir.model.access.csv' (properties changed: -x to +x) |
1721 | === modified file 'ecua_liquidacion_compras/views/account_journal_view.xml' (properties changed: -x to +x) |
1722 | === modified file 'ecua_liquidacion_compras/views/liquidacion_compra.xml' (properties changed: -x to +x) |
1723 | === modified file 'ecua_liquidacion_compras/views/shop_view.xml' (properties changed: -x to +x) |
1724 | === modified file 'ecua_notas_credito_manual/Analisis Notas de Facturas Rectificativas OERP.odt' (properties changed: -x to +x) |
1725 | === modified file 'ecua_notas_credito_manual/Requisitos' (properties changed: -x to +x) |
1726 | === modified file 'ecua_notas_credito_manual/Revision' (properties changed: -x to +x) |
1727 | === modified file 'ecua_notas_credito_manual/__init__.py' (properties changed: -x to +x) |
1728 | === modified file 'ecua_notas_credito_manual/__openerp__.py' (properties changed: -x to +x) |
1729 | === modified file 'ecua_notas_credito_manual/data/data.xml' (properties changed: -x to +x) |
1730 | === modified file 'ecua_notas_credito_manual/data/data_init.xml' (properties changed: -x to +x) |
1731 | === modified file 'ecua_notas_credito_manual/data/formato nota de credito.pdf' (properties changed: -x to +x) |
1732 | === modified file 'ecua_notas_credito_manual/i18n/es.po' (properties changed: -x to +x) |
1733 | === modified file 'ecua_notas_credito_manual/objects/__init__.py' (properties changed: -x to +x) |
1734 | === modified file 'ecua_notas_credito_manual/objects/invoice.py' (properties changed: -x to +x) |
1735 | === modified file 'ecua_notas_credito_manual/objects/shop.py' (properties changed: -x to +x) |
1736 | === modified file 'ecua_notas_credito_manual/report/credit_note_report.odt' (properties changed: -x to +x) |
1737 | === modified file 'ecua_notas_credito_manual/report/credit_note_report.xml' (properties changed: -x to +x) |
1738 | === modified file 'ecua_notas_credito_manual/security/ir.model.access.csv' (properties changed: -x to +x) |
1739 | === modified file 'ecua_notas_credito_manual/views/invoice_refund_view.xml' (properties changed: -x to +x) |
1740 | === modified file 'ecua_notas_credito_manual/views/invoice_view.xml' (properties changed: -x to +x) |
1741 | === modified file 'ecua_notas_credito_manual/views/shop_view.xml' (properties changed: -x to +x) |
1742 | === modified file 'ecua_notas_credito_manual/wizard/__init__.py' (properties changed: -x to +x) |
1743 | === modified file 'ecua_notas_credito_manual/wizard/wizard_credit_note.py' (properties changed: -x to +x) |
1744 | === modified file 'ecua_notas_credito_manual/wizard/wizard_credit_note_view.xml' (properties changed: -x to +x) |
1745 | === modified file 'ecua_notas_credito_manual/workflow/invoice_workflow.xml' (properties changed: -x to +x) |
1746 | === modified file 'ecua_pagos/__init__.py' (properties changed: -x to +x) |
1747 | === modified file 'ecua_pagos/__openerp__.py' (properties changed: -x to +x) |
1748 | === modified file 'ecua_pagos/data/init.xml' (properties changed: -x to +x) |
1749 | === modified file 'ecua_pagos/data/journal_data.xml' (properties changed: -x to +x) |
1750 | === modified file 'ecua_pagos/objects/__init__.py' (properties changed: -x to +x) |
1751 | === modified file 'ecua_pagos/objects/deposit_slip.py' (properties changed: -x to +x) |
1752 | === modified file 'ecua_pagos/objects/invoice.py' (properties changed: -x to +x) |
1753 | === modified file 'ecua_pagos/objects/journal.py' (properties changed: -x to +x) |
1754 | === modified file 'ecua_pagos/objects/move_line.py' (properties changed: -x to +x) |
1755 | === modified file 'ecua_pagos/objects/partner.py' (properties changed: -x to +x) |
1756 | === modified file 'ecua_pagos/objects/payment_line.py' (properties changed: -x to +x) |
1757 | === modified file 'ecua_pagos/objects/voucher.py' (properties changed: -x to +x) |
1758 | === modified file 'ecua_pagos/report/voucher_report.odt' (properties changed: -x to +x) |
1759 | === modified file 'ecua_pagos/report/voucher_report.xml' (properties changed: -x to +x) |
1760 | === modified file 'ecua_pagos/security/ir.model.access.csv' (properties changed: -x to +x) |
1761 | === modified file 'ecua_pagos/views/journal_view.xml' (properties changed: -x to +x) |
1762 | === modified file 'ecua_pagos/views/payment_line_view.xml' (properties changed: -x to +x) |
1763 | === modified file 'ecua_pagos/views/payment_mode_view.xml' (properties changed: -x to +x) |
1764 | === modified file 'ecua_pagos/views/voucher_view.xml' (properties changed: -x to +x) |
1765 | === added directory 'ecua_partner' |
1766 | === added file 'ecua_partner/__init__.py' |
1767 | --- ecua_partner/__init__.py 1970-01-01 00:00:00 +0000 |
1768 | +++ ecua_partner/__init__.py 2013-05-03 13:54:27 +0000 |
1769 | @@ -0,0 +1,25 @@ |
1770 | +# -*- coding: utf-8 -*- |
1771 | +######################################################################## |
1772 | +# |
1773 | +#@authors:TRESCLOUD Cia.Ltda |
1774 | +# Copyright (C) 2013 |
1775 | +# |
1776 | +#This program is free software: you can redistribute it and/or modify |
1777 | +#it under the terms of the GNU General Public License as published by |
1778 | +#the Free Software Foundation, either version 3 of the License, or |
1779 | +#(at your option) any later version. |
1780 | +# |
1781 | +# This module is GPLv3 or newer and incompatible |
1782 | +# with OpenERP SA "AGPL + Private Use License"! |
1783 | +# |
1784 | +#This program is distributed in the hope that it will be useful, |
1785 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
1786 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
1787 | +#GNU General Public License for more details. |
1788 | +# |
1789 | +#You should have received a copy of the GNU General Public License |
1790 | +#along with this program. If not, see http://www.gnu.org/licenses. |
1791 | +#ice |
1792 | +######################################################################## |
1793 | + |
1794 | +import ecua_partner |
1795 | \ No newline at end of file |
1796 | |
1797 | === added file 'ecua_partner/__openerp__.py' |
1798 | --- ecua_partner/__openerp__.py 1970-01-01 00:00:00 +0000 |
1799 | +++ ecua_partner/__openerp__.py 2013-05-03 13:54:27 +0000 |
1800 | @@ -0,0 +1,45 @@ |
1801 | +# -*- coding: utf-8 -*- |
1802 | +######################################################################## |
1803 | +# |
1804 | +# @authors:TRESCLOUD Cia.Ltda |
1805 | +# Copyright (C) 2013 |
1806 | +# |
1807 | +#This program is free software: you can redistribute it and/or modify |
1808 | +#it under the terms of the GNU General Public License as published by |
1809 | +#the Free Software Foundation, either version 3 of the License, or |
1810 | +#(at your option) any later version. |
1811 | +# |
1812 | +# This module is GPLv3 or newer and incompatible |
1813 | +# with OpenERP SA "AGPL + Private Use License"! |
1814 | +# |
1815 | +#This program is distributed in the hope that it will be useful, |
1816 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
1817 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
1818 | +#GNU General Public License for more details. |
1819 | +# |
1820 | +#You should have received a copy of the GNU General Public License |
1821 | +#along with this program. If not, see http://www.gnu.org/licenses. |
1822 | +#ice |
1823 | +######################################################################## |
1824 | +{ |
1825 | + "name" : "Módulo de mejoras a partners para Ecuador", |
1826 | + "author" : "TRESCloud Cia. Ltda.", |
1827 | + "maintainer": 'TRESCloud Cia. Ltda.', |
1828 | + "website": 'http://www.trescloud.com', |
1829 | + 'complexity': "easy", |
1830 | + "description": """Sistema de mejoras a la vista de creación de PARTNERS |
1831 | + |
1832 | + Este sistema permite agregar mejoras a la vista de creación de partners, poniendo por defecto valores de Ecuador en el campo de localización, el nombre del vendedor y la fecha de creación. |
1833 | + |
1834 | + Desarrollador: |
1835 | + |
1836 | + Carlos Yumbillo |
1837 | + |
1838 | + """, |
1839 | + "category": "Partners", |
1840 | + "version" : "1.0", |
1841 | + 'depends': ['base','account'], |
1842 | + 'init_xml': [], |
1843 | + 'update_xml': [], |
1844 | + 'installable': True, |
1845 | +} |
1846 | \ No newline at end of file |
1847 | |
1848 | === added file 'ecua_partner/ecua_partner.py' |
1849 | --- ecua_partner/ecua_partner.py 1970-01-01 00:00:00 +0000 |
1850 | +++ ecua_partner/ecua_partner.py 2013-05-03 13:54:27 +0000 |
1851 | @@ -0,0 +1,39 @@ |
1852 | +# -*- coding: utf-8 -*- |
1853 | +from osv import osv, fields |
1854 | +from datetime import datetime |
1855 | + |
1856 | +class partner(osv.osv): |
1857 | + _inherit='res.partner' |
1858 | + _name = 'res.partner' |
1859 | + |
1860 | + def _get_user_id(self, cr, uid, ids, context={}): |
1861 | + user_obj = self.pool.get('res.users') |
1862 | + user = user_obj.browse(cr,uid,uid) |
1863 | + return user.id |
1864 | + |
1865 | + _defaults = { |
1866 | + 'user_id': _get_user_id, |
1867 | + 'date': datetime.now() |
1868 | + } |
1869 | + |
1870 | +partner() |
1871 | + |
1872 | +class partner_address(osv.osv): |
1873 | + _inherit='res.partner.address' |
1874 | + _name = 'res.partner.address' |
1875 | + |
1876 | + def _get_user_location_id(self, cr, uid, ids, context={}): |
1877 | + user_obj = self.pool.get('res.users') |
1878 | + user = user_obj.browse(cr,uid,uid) |
1879 | + partner_address = user.company_id.partner_id.address |
1880 | + |
1881 | + for loc in partner_address: |
1882 | + loc.location.id |
1883 | + |
1884 | + return loc.location.id |
1885 | + |
1886 | + _defaults = { |
1887 | + 'location': _get_user_location_id, |
1888 | + } |
1889 | + |
1890 | +partner_address() |
1891 | \ No newline at end of file |
1892 | |
1893 | === modified file 'ecua_posicion_fiscal/__init__.py' (properties changed: -x to +x) |
1894 | === modified file 'ecua_posicion_fiscal/__openerp__.py' (properties changed: -x to +x) |
1895 | === modified file 'ecua_posicion_fiscal/documentation/PORCENTAJE DE RETENCIÓN DE IMPUESTO A LA RENTA 2011.xls' (properties changed: -x to +x) |
1896 | === modified file 'ecua_posicion_fiscal/documentation/Retenciones_IVA.ods' (properties changed: -x to +x) |
1897 | === modified file 'ecua_posicion_fiscal/object/__init__.py' (properties changed: -x to +x) |
1898 | === modified file 'ecua_posicion_fiscal/object/fiscal_position.py' (properties changed: -x to +x) |
1899 | === modified file 'ecua_posicion_fiscal/object/invoice.py' (properties changed: -x to +x) |
1900 | === modified file 'ecua_posicion_fiscal/object/purchase.py' (properties changed: -x to +x) |
1901 | === modified file 'ecua_posicion_fiscal/object/sale.py' (properties changed: -x to +x) |
1902 | === modified file 'ecua_posicion_fiscal/security/ir.model.access.csv' (properties changed: -x to +x) |
1903 | === modified file 'ecua_posicion_fiscal/view/fiscal_position_view.xml' (properties changed: -x to +x) |
1904 | === modified file 'ecua_posicion_fiscal/view/invoice_view.xml' (properties changed: -x to +x) |
1905 | === modified file 'ecua_posicion_fiscal/view/purchase_view.xml' (properties changed: -x to +x) |
1906 | === modified file 'ecua_posicion_fiscal/view/sale_order_view.xml' (properties changed: -x to +x) |
1907 | === modified file 'ecua_posicion_fiscal/wizard/__init__.py' (properties changed: -x to +x) |
1908 | === modified file 'ecua_remision/__init__.py' (properties changed: -x to +x) |
1909 | === modified file 'ecua_remision/__openerp__.py' (properties changed: -x to +x) |
1910 | === modified file 'ecua_remision/data/data.xml' (properties changed: -x to +x) |
1911 | === modified file 'ecua_remision/i18n/es.po' (properties changed: -x to +x) |
1912 | === modified file 'ecua_remision/objects/__init__.py' (properties changed: -x to +x) |
1913 | === modified file 'ecua_remision/objects/carrier.py' (properties changed: -x to +x) |
1914 | === modified file 'ecua_remision/objects/company.py' (properties changed: -x to +x) |
1915 | === modified file 'ecua_remision/objects/delivery_note.py' (properties changed: -x to +x) |
1916 | === modified file 'ecua_remision/objects/partner.py' (properties changed: -x to +x) |
1917 | === modified file 'ecua_remision/objects/sale_order.py' (properties changed: -x to +x) |
1918 | === modified file 'ecua_remision/objects/stock_move.py' (properties changed: -x to +x) |
1919 | === modified file 'ecua_remision/objects/stock_picking.py' (properties changed: -x to +x) |
1920 | === modified file 'ecua_remision/report/delivery_note_report.xml' (properties changed: -x to +x) |
1921 | === modified file 'ecua_remision/security/ir.model.access.csv' (properties changed: -x to +x) |
1922 | === modified file 'ecua_remision/views/carrier_view.xml' (properties changed: -x to +x) |
1923 | === modified file 'ecua_remision/views/company_view.xml' (properties changed: -x to +x) |
1924 | === modified file 'ecua_remision/views/delivery_note_view.xml' (properties changed: -x to +x) |
1925 | === modified file 'ecua_remision/views/partner_view.xml' (properties changed: -x to +x) |
1926 | === modified file 'ecua_remision/views/picking_view.xml' (properties changed: -x to +x) |
1927 | === modified file 'ecua_remision/views/sale_order_view.xml' (properties changed: -x to +x) |
1928 | === modified file 'ecua_remision/wizard/__init__.py' (properties changed: -x to +x) |
1929 | === modified file 'ecua_remision/wizard/cancel_delivery_notes_wizard.py' (properties changed: -x to +x) |
1930 | === modified file 'ecua_remision/wizard/cancel_delivery_notes_wizard.xml' (properties changed: -x to +x) |
1931 | === modified file 'ecua_remision/wizard/create_invoice_remision.py' (properties changed: -x to +x) |
1932 | === modified file 'ecua_remision/wizard/create_invoice_remision_wizard.xml' (properties changed: -x to +x) |
1933 | === modified file 'ecua_remision/wizard/stock_partial_picking.py' (properties changed: -x to +x) |
1934 | === modified file 'ecua_remision/wizard/stock_partial_picking_wizard.xml' (properties changed: -x to +x) |
1935 | === modified file 'ecua_remision/workflow/delivery_note_workflow.xml' (properties changed: -x to +x) |
1936 | === modified file 'ecua_retenciones_manual/Revision' (properties changed: -x to +x) |
1937 | === modified file 'ecua_retenciones_manual/__init__.py' (properties changed: -x to +x) |
1938 | === modified file 'ecua_retenciones_manual/__openerp__.py' (properties changed: -x to +x) |
1939 | === modified file 'ecua_retenciones_manual/data/data.xml' (properties changed: -x to +x) |
1940 | --- ecua_retenciones_manual/data/data.xml 2013-02-16 14:02:25 +0000 |
1941 | +++ ecua_retenciones_manual/data/data.xml 2013-05-03 13:54:27 +0000 |
1942 | @@ -29,6 +29,7 @@ |
1943 | <!-- field model="account.account" name="default_credit_account_id" ref="l10n_ec_niif_minimal.101050101"/> |
1944 | <field model="account.account" name="default_debit_account_id" ref="l10n_ec_niif_minimal.101050101"/--> |
1945 | <field name="user_id" ref="base.user_root"/> |
1946 | + <field name="update_posted">True</field> |
1947 | </record> |
1948 | |
1949 | <record id="ir_retention_journal" model="account.journal"> |
1950 | @@ -40,6 +41,7 @@ |
1951 | <!--field model="account.account" name="default_credit_account_id" ref="l10n_ec_niif_minimal.1010502"/> |
1952 | <field model="account.account" name="default_debit_account_id" ref="l10n_ec_niif_minimal.1010502"/--> |
1953 | <field name="user_id" ref="base.user_root"/> |
1954 | + <field name="update_posted">True</field> |
1955 | </record> |
1956 | |
1957 | <record id="base.main_company" model="res.company"> |
1958 | |
1959 | === modified file 'ecua_retenciones_manual/i18n/es.po' (properties changed: -x to +x) |
1960 | === modified file 'ecua_retenciones_manual/objects/__init__.py' (properties changed: -x to +x) |
1961 | === modified file 'ecua_retenciones_manual/objects/company.py' (properties changed: -x to +x) |
1962 | === modified file 'ecua_retenciones_manual/objects/invoice.py' (properties changed: -x to +x) |
1963 | === modified file 'ecua_retenciones_manual/objects/retencion_line.py' (properties changed: -x to +x) |
1964 | === modified file 'ecua_retenciones_manual/objects/retenciones.py' (properties changed: -x to +x) |
1965 | === modified file 'ecua_retenciones_manual/objects/voucher.py' (properties changed: -x to +x) |
1966 | === modified file 'ecua_retenciones_manual/report/retention_report.odt' (properties changed: -x to +x) |
1967 | === modified file 'ecua_retenciones_manual/report/retention_report.xml' (properties changed: -x to +x) |
1968 | --- ecua_retenciones_manual/report/retention_report.xml 2013-02-16 14:02:25 +0000 |
1969 | +++ ecua_retenciones_manual/report/retention_report.xml 2013-05-03 13:54:27 +0000 |
1970 | @@ -1,6 +1,7 @@ |
1971 | <?xml version="1.0" encoding="UTF-8"?> |
1972 | <openerp> |
1973 | - <data> |
1974 | + <!-- no actualizar ya que en multicompania o multidb debe poder personalizarse --> |
1975 | + <data noupdate="1"> |
1976 | <record id="retention_report" model="ir.actions.report.xml"> |
1977 | <field name="name">Retenciones</field> |
1978 | <field name="type">ir.actions.report.xml</field> |
1979 | |
1980 | === modified file 'ecua_retenciones_manual/security/ir.model.access.csv' (properties changed: -x to +x) |
1981 | === modified file 'ecua_retenciones_manual/views/company_view.xml' (properties changed: -x to +x) |
1982 | === modified file 'ecua_retenciones_manual/views/invoice_view.xml' (properties changed: -x to +x) |
1983 | === modified file 'ecua_retenciones_manual/views/retenciones_view.xml' (properties changed: -x to +x) |
1984 | === modified file 'ecua_retenciones_manual/views/shop.xml' (properties changed: -x to +x) |
1985 | === modified file 'ecua_retenciones_manual/views/type_document.xml' (properties changed: -x to +x) |
1986 | === modified file 'ecua_retenciones_manual/wizard/__init__.py' (properties changed: -x to +x) |
1987 | === modified file 'ecua_retenciones_manual/wizard/cancel_retentions_wizard.py' (properties changed: -x to +x) |
1988 | === modified file 'ecua_retenciones_manual/wizard/cancel_retentions_wizard.xml' (properties changed: -x to +x) |
1989 | === modified file 'ecua_retenciones_manual/wizard/retention_wizard.py' (properties changed: -x to +x) |
1990 | === modified file 'ecua_retenciones_manual/wizard/retention_wizard_view.xml' (properties changed: -x to +x) |
1991 | === modified file 'ecua_retenciones_manual/workflow/retention_workflow.xml' (properties changed: -x to +x) |
1992 | === modified file 'ecua_seguro_social/__init__.py' (properties changed: +x to -x) |
1993 | === modified file 'ecua_seguro_social/__openerp__.py' (properties changed: +x to -x) |
1994 | === modified file 'ecua_seguro_social/data/calendar.xml' (properties changed: +x to -x) |
1995 | === modified file 'ecua_seguro_social/data/company_configuration.xml' (properties changed: +x to -x) |
1996 | --- ecua_seguro_social/data/company_configuration.xml 2013-02-16 14:02:25 +0000 |
1997 | +++ ecua_seguro_social/data/company_configuration.xml 2013-05-03 13:54:27 +0000 |
1998 | @@ -21,6 +21,7 @@ |
1999 | <field name="view_id" ref="account.account_journal_view"/> |
2000 | <field name="sequence_id" ref="sueldos_sequence"/> |
2001 | <field name="user_id" ref="base.user_root"/> |
2002 | + <field name="update_posted">True</field> |
2003 | </record> |
2004 | |
2005 | </data> |
2006 | |
2007 | === modified file 'ecua_seguro_social/data/data_init.xml' (properties changed: +x to -x) |
2008 | === modified file 'ecua_seguro_social/data/education_area.xml' (properties changed: +x to -x) |
2009 | === modified file 'ecua_seguro_social/data/salary_estructure.xml' (properties changed: +x to -x) |
2010 | === modified file 'ecua_seguro_social/i18n/es.po' (properties changed: +x to -x) |
2011 | === modified file 'ecua_seguro_social/objects/__init__.py' (properties changed: +x to -x) |
2012 | === modified file 'ecua_seguro_social/objects/account.py' (properties changed: +x to -x) |
2013 | === modified file 'ecua_seguro_social/objects/account_move.py' (properties changed: -x to +x) |
2014 | === modified file 'ecua_seguro_social/objects/advances.py' (properties changed: +x to -x) |
2015 | === modified file 'ecua_seguro_social/objects/calendar.py' (properties changed: +x to -x) |
2016 | === modified file 'ecua_seguro_social/objects/company.py' (properties changed: +x to -x) |
2017 | === modified file 'ecua_seguro_social/objects/contract.py' (properties changed: +x to -x) |
2018 | === modified file 'ecua_seguro_social/objects/education_level.py' (properties changed: +x to -x) |
2019 | === modified file 'ecua_seguro_social/objects/employee.py' (properties changed: +x to -x) |
2020 | === modified file 'ecua_seguro_social/objects/family_burden.py' (properties changed: +x to -x) |
2021 | === modified file 'ecua_seguro_social/objects/holidays.py' (properties changed: -x to +x) |
2022 | === modified file 'ecua_seguro_social/objects/move_line.py' (properties changed: +x to -x) |
2023 | === modified file 'ecua_seguro_social/objects/newholidays.py' (properties changed: -x to +x) |
2024 | === modified file 'ecua_seguro_social/objects/partner.py' (properties changed: +x to -x) |
2025 | === modified file 'ecua_seguro_social/objects/payroll.py' (properties changed: +x to -x) |
2026 | --- ecua_seguro_social/objects/payroll.py 2013-03-21 21:19:42 +0000 |
2027 | +++ ecua_seguro_social/objects/payroll.py 2013-05-03 13:54:27 +0000 |
2028 | @@ -1532,7 +1532,10 @@ |
2029 | 'quantity': fields.float('Quantity', digits_compute=dp.get_precision('Payroll')), |
2030 | 'total': fields.function(_calculate_total, method=True, type='float', string='Total', digits_compute=dp.get_precision('Payroll'),store=True ), |
2031 | } |
2032 | - |
2033 | + _sql_constraints = [ |
2034 | + ('code_unique_salary_rule', '1=1', _('Code can duplicate')), |
2035 | + ] |
2036 | + |
2037 | hr_payslip_line() |
2038 | |
2039 | class hr_allounce_deduction_categoty(osv.osv): |
2040 | |
2041 | === modified file 'ecua_seguro_social/objects/provision.py' (properties changed: -x to +x) |
2042 | === modified file 'ecua_seguro_social/objects/vacation.py' (properties changed: -x to +x) |
2043 | --- ecua_seguro_social/objects/vacation.py 2013-03-21 21:19:42 +0000 |
2044 | +++ ecua_seguro_social/objects/vacation.py 2013-05-03 13:54:27 +0000 |
2045 | @@ -50,7 +50,7 @@ |
2046 | |
2047 | def get_year_start_end(self, cr, uid, last_vacation_id, employee_id, year_vacation, date_start_vacation, date_end_vacation, context=None): |
2048 | """ |
2049 | - Calcula y devuelve desde que ano hasta que ano se va a tomar vacaciones |
2050 | + Calcula y devuelve desde que año hasta que ano se va a tomar vacaciones |
2051 | Ejm. del 2 al 4 ano se va a tomar vacaciones |
2052 | """ |
2053 | # el algoritmo es: |
2054 | |
2055 | === modified file 'ecua_seguro_social/objects/voucher.py' (properties changed: +x to -x) |
2056 | === modified file 'ecua_seguro_social/report/__init__.py' (properties changed: +x to -x) |
2057 | === modified file 'ecua_seguro_social/report/ecua_seguro_social_reports.xml' (properties changed: +x to -x) |
2058 | === modified file 'ecua_seguro_social/report/nomina_general.ods' (properties changed: +x to -x) |
2059 | === modified file 'ecua_seguro_social/report/nomina_general_parser.py' (properties changed: +x to -x) |
2060 | === modified file 'ecua_seguro_social/report/nomina_general_report.xml' (properties changed: +x to -x) |
2061 | === modified file 'ecua_seguro_social/report/report_hr_advances.odt' (properties changed: +x to -x) |
2062 | === modified file 'ecua_seguro_social/report/report_hr_advances.xml' (properties changed: +x to -x) |
2063 | === modified file 'ecua_seguro_social/report/report_hr_employee_need_vacation.odt' (properties changed: -x to +x) |
2064 | === modified file 'ecua_seguro_social/report/report_hr_employee_need_vacation.xml' (properties changed: -x to +x) |
2065 | === modified file 'ecua_seguro_social/report/report_hr_provision.odt' (properties changed: -x to +x) |
2066 | === modified file 'ecua_seguro_social/report/report_hr_vacation.odt' (properties changed: -x to +x) |
2067 | === modified file 'ecua_seguro_social/report/report_hr_vacation.xml' (properties changed: -x to +x) |
2068 | === modified file 'ecua_seguro_social/report/report_payslip.py' (properties changed: +x to -x) |
2069 | === modified file 'ecua_seguro_social/report/report_payslip.rml' (properties changed: +x to -x) |
2070 | === modified file 'ecua_seguro_social/report/report_payslip.sxw' (properties changed: +x to -x) |
2071 | === modified file 'ecua_seguro_social/report/report_payslip_details.odt' (properties changed: +x to -x) |
2072 | === modified file 'ecua_seguro_social/report/report_payslip_details.py' (properties changed: +x to -x) |
2073 | === modified file 'ecua_seguro_social/report/report_payslip_details.xml' (properties changed: +x to -x) |
2074 | === modified file 'ecua_seguro_social/report/report_payslip_details_group.odt' (properties changed: +x to -x) |
2075 | === modified file 'ecua_seguro_social/report/report_payslip_details_group.xml' (properties changed: +x to -x) |
2076 | === modified file 'ecua_seguro_social/security/hr_security.xml' (properties changed: +x to -x) |
2077 | === modified file 'ecua_seguro_social/security/ir.model.access.csv' (properties changed: +x to -x) |
2078 | === modified file 'ecua_seguro_social/views/advances_view.xml' (properties changed: +x to -x) |
2079 | === modified file 'ecua_seguro_social/views/calendar_view.xml' (properties changed: +x to -x) |
2080 | === modified file 'ecua_seguro_social/views/company_view.xml' (properties changed: +x to -x) |
2081 | === modified file 'ecua_seguro_social/views/contract_view.xml' (properties changed: +x to -x) |
2082 | === modified file 'ecua_seguro_social/views/education_level_view.xml' (properties changed: +x to -x) |
2083 | === modified file 'ecua_seguro_social/views/employee_view.xml' (properties changed: +x to -x) |
2084 | === modified file 'ecua_seguro_social/views/extra_input_output_view.xml' (properties changed: +x to -x) |
2085 | === modified file 'ecua_seguro_social/views/family_burden_view.xml' (properties changed: +x to -x) |
2086 | === modified file 'ecua_seguro_social/views/holiday_view.xml' (properties changed: +x to -x) |
2087 | === modified file 'ecua_seguro_social/views/newholidays_view.xml' (properties changed: -x to +x) |
2088 | === modified file 'ecua_seguro_social/views/payroll_view.xml' (properties changed: +x to -x) |
2089 | === modified file 'ecua_seguro_social/views/payslip_line_view.xml' (properties changed: +x to -x) |
2090 | === modified file 'ecua_seguro_social/views/provision_view.xml' (properties changed: -x to +x) |
2091 | === modified file 'ecua_seguro_social/views/vacation_view.xml' (properties changed: -x to +x) |
2092 | === modified file 'ecua_seguro_social/views/voucher_view.xml' (properties changed: +x to -x) |
2093 | === modified file 'ecua_seguro_social/wizards/__init__.py' (properties changed: +x to -x) |
2094 | === modified file 'ecua_seguro_social/wizards/hr_payroll_contribution_register_report.py' (properties changed: +x to -x) |
2095 | === modified file 'ecua_seguro_social/wizards/hr_payroll_contribution_register_report.xml' (properties changed: +x to -x) |
2096 | === modified file 'ecua_seguro_social/wizards/hr_payroll_payslips_by_employees.py' (properties changed: +x to -x) |
2097 | === modified file 'ecua_seguro_social/wizards/hr_payroll_payslips_by_employees.xml' (properties changed: +x to -x) |
2098 | === modified file 'ecua_seguro_social/wizards/multi_advances_wizard.py' (properties changed: +x to -x) |
2099 | === modified file 'ecua_seguro_social/wizards/multi_advances_wizard_view.xml' (properties changed: +x to -x) |
2100 | === modified file 'ecua_seguro_social/wizards/payment_wizard.xml' (properties changed: +x to -x) |
2101 | === modified file 'ecua_seguro_social/wizards/payroll_statement.py' (properties changed: +x to -x) |
2102 | === modified file 'ecua_seguro_social/wizards/payroll_statement_view.xml' (properties changed: +x to -x) |
2103 | === modified file 'ecua_seguro_social/wizards/wizard_payslip.py' (properties changed: +x to -x) |
2104 | === modified file 'ecua_seguro_social/workflows/advances_workflow.xml' (properties changed: +x to -x) |
2105 | === modified file 'ecua_seguro_social/workflows/payroll_workflow.xml' (properties changed: +x to -x) |
2106 | === modified file 'ecua_sequence/__init__.py' (properties changed: -x to +x) |
2107 | === modified file 'ecua_sequence/__openerp__.py' (properties changed: -x to +x) |
2108 | === modified file 'ecua_sequence/object/__init__.py' (properties changed: -x to +x) |
2109 | === modified file 'ecua_sequence/object/ir_sequence.py' (properties changed: -x to +x) |
2110 | === modified file 'ecua_sequence/security/ir.model.access.csv' (properties changed: -x to +x) |
2111 | === modified file 'ecua_states/i18n/es_EC.po' (properties changed: -x to +x) |
2112 | === modified file 'ecua_states/objects/states.py' |
2113 | --- ecua_states/objects/states.py 2013-02-16 14:02:25 +0000 |
2114 | +++ ecua_states/objects/states.py 2013-05-03 13:54:27 +0000 |
2115 | @@ -23,6 +23,26 @@ |
2116 | |
2117 | from osv import osv, fields |
2118 | |
2119 | +class res_parroquia(osv.osv): |
2120 | + ''' |
2121 | + Open ERP Model |
2122 | + ''' |
2123 | + _name = 'res.parroquia' |
2124 | + _description = 'Parroquias' |
2125 | + |
2126 | + _columns = { |
2127 | + 'name':fields.char('Nombre', size=255, required=True, readonly=False), |
2128 | + 'city_id':fields.many2one('city.city', 'Ciudad', required=True), |
2129 | + 'type':fields.selection([ |
2130 | + ('urbana','Urbana'), |
2131 | + ('rural','Rural'), |
2132 | + ], 'Tipo', select=True, readonly=False,required=True), |
2133 | + |
2134 | + } |
2135 | + _defaults = { |
2136 | + 'type': 'urbana', |
2137 | + } |
2138 | +res_parroquia() |
2139 | |
2140 | class region(osv.osv): |
2141 | _name = 'res.region' |
2142 | @@ -156,28 +176,6 @@ |
2143 | } |
2144 | city() |
2145 | |
2146 | - |
2147 | -class res_parroquia(osv.osv): |
2148 | - ''' |
2149 | - Open ERP Model |
2150 | - ''' |
2151 | - _name = 'res.parroquia' |
2152 | - _description = 'Parroquias' |
2153 | - |
2154 | - _columns = { |
2155 | - 'name':fields.char('Nombre', size=255, required=True, readonly=False), |
2156 | - 'city_id':fields.many2one('city.city', 'Ciudad', required=True), |
2157 | - 'type':fields.selection([ |
2158 | - ('urbana','Urbana'), |
2159 | - ('rural','Rural'), |
2160 | - ], 'Tipo', select=True, readonly=False,required=True), |
2161 | - |
2162 | - } |
2163 | - _defaults = { |
2164 | - 'type': 'urbana', |
2165 | - } |
2166 | -res_parroquia() |
2167 | - |
2168 | class res_partner_sector(osv.osv): |
2169 | _name = 'res.partner.sector' |
2170 | _description = 'Parish and Sectors' |
2171 | |
2172 | === modified file 'ecua_states/views/menu.xml' (properties changed: -x to +x) |
2173 | === modified file 'ecua_states/views/partner_view.xml' (properties changed: -x to +x) |
2174 | === modified file 'ecua_verifica_ruc_cedula/__init__.py' (properties changed: -x to +x) |
2175 | === modified file 'ecua_verifica_ruc_cedula/__openerp__.py' (properties changed: -x to +x) |
2176 | === modified file 'ecua_verifica_ruc_cedula/i18n/en_US.po' (properties changed: -x to +x) |
2177 | === modified file 'ecua_verifica_ruc_cedula/i18n/es.po' (properties changed: -x to +x) |
2178 | === modified file 'ecua_verifica_ruc_cedula/i18n/es_EC.po' (properties changed: -x to +x) |
2179 | === modified file 'ecua_verifica_ruc_cedula/installer.py' (properties changed: -x to +x) |
2180 | === modified file 'ecua_verifica_ruc_cedula/installer.xml' (properties changed: -x to +x) |
2181 | === modified file 'ecua_verifica_ruc_cedula/partner.py' (properties changed: -x to +x) |
2182 | --- ecua_verifica_ruc_cedula/partner.py 2013-02-16 14:02:25 +0000 |
2183 | +++ ecua_verifica_ruc_cedula/partner.py 2013-05-03 13:54:27 +0000 |
2184 | @@ -200,9 +200,17 @@ |
2185 | def create(self, cr, uid, values, context=None): |
2186 | if not context: |
2187 | context = {} |
2188 | - if context.get('skip_ruc_validation'): |
2189 | + |
2190 | + # If foreing is True don't have to verify the CI/RUC |
2191 | + foreing = False |
2192 | + |
2193 | + if 'foreing' in values: |
2194 | + foreing = values['foreing'] |
2195 | + |
2196 | + if context.get('skip_ruc_validation') or foreing: |
2197 | return super(res_partner, self).create(cr, uid, values, context) |
2198 | ref = None |
2199 | + |
2200 | try: |
2201 | ref = values['ref'] |
2202 | if not ref: |
2203 | @@ -258,7 +266,17 @@ |
2204 | def write(self, cr, uid, ids, values,context=None): |
2205 | if not context: |
2206 | context = {} |
2207 | - if context.get('skip_ruc_validation'): |
2208 | + |
2209 | + # If foreing is True don't have to verify the CI/RUC |
2210 | + # First, check if change the value of foreing, else use the stored value |
2211 | + foreing = False |
2212 | + |
2213 | + if 'foreing' in values: |
2214 | + foreing = values['foreing'] |
2215 | + else: |
2216 | + foreing = self.pool.get('res.partner').browse(cr, uid, ids[0]).foreing |
2217 | + |
2218 | + if context.get('skip_ruc_validation') or foreing: |
2219 | return super(res_partner, self).write(cr, uid, ids, values, context) |
2220 | ref = None |
2221 | try: |
2222 | |
2223 | === modified file 'ecua_verifica_ruc_cedula/views/verificar_ruc_cedula_view.xml' (properties changed: -x to +x) |
2224 | --- ecua_verifica_ruc_cedula/views/verificar_ruc_cedula_view.xml 2013-02-16 14:02:25 +0000 |
2225 | +++ ecua_verifica_ruc_cedula/views/verificar_ruc_cedula_view.xml 2013-05-03 13:54:27 +0000 |
2226 | @@ -97,8 +97,8 @@ |
2227 | <field name="type">form</field> |
2228 | <field name="arch" type="xml"> |
2229 | <xpath expr="/form/group//field[@name='ref']" position="replace"> |
2230 | - <field string="CEDULA/RUC" name="ref" |
2231 | - attrs="{'readonly':[('foreing','=',True)]}" select="1"> |
2232 | + <field string="CEDULA/RUC" name="ref" select="1"> |
2233 | +<!-- attrs="{'readonly':[('foreing','=',True)]}" --> |
2234 | </field> |
2235 | <field string="type" name="type_ref" invisible="1"> |
2236 | </field> |
2237 | |
2238 | === modified file 'ecua_verifica_ruc_cedula_importacion/__init__.py' (properties changed: -x to +x) |
2239 | === modified file 'ecua_verifica_ruc_cedula_importacion/__openerp__.py' (properties changed: -x to +x) |
2240 | === modified file 'ecua_verifica_ruc_cedula_importacion/partner.py' (properties changed: -x to +x) |
2241 | === modified file 'ecua_verifica_ruc_cedula_importacion/partner_view.xml' (properties changed: -x to +x) |
2242 | === modified file 'l10n_ec_niif_minimal/__init__.py' (properties changed: -x to +x) |
2243 | === modified file 'l10n_ec_niif_minimal/__openerp__.py' (properties changed: -x to +x) |
2244 | === modified file 'l10n_ec_niif_minimal/data/account_chart.xml' (properties changed: -x to +x) |
2245 | === modified file 'l10n_ec_niif_minimal/data/account_tax_103.xml' (properties changed: -x to +x) |
2246 | === modified file 'l10n_ec_niif_minimal/data/account_tax_104.xml' (properties changed: -x to +x) |
2247 | === modified file 'l10n_ec_niif_minimal/data/account_tax_code.xml' (properties changed: -x to +x) |
2248 | === modified file 'l10n_ec_niif_minimal/i18n/l10n_ec_niif_minimal.pot' (properties changed: -x to +x) |
2249 | === modified file 'l10n_ec_niif_minimal/objects/__init__.py' (properties changed: -x to +x) |
2250 | === modified file 'l10n_ec_niif_minimal/objects/account_installer.py' (properties changed: -x to +x) |
2251 | === modified file 'l10n_ec_niif_minimal/objects/account_invoice_tax.py' (properties changed: -x to +x) |
2252 | --- l10n_ec_niif_minimal/objects/account_invoice_tax.py 2013-04-21 14:26:15 +0000 |
2253 | +++ l10n_ec_niif_minimal/objects/account_invoice_tax.py 2013-05-03 13:54:27 +0000 |
2254 | @@ -53,7 +53,7 @@ |
2255 | company_currency = inv.company_id.currency_id.id |
2256 | |
2257 | for line in inv.invoice_line: |
2258 | - for tax in tax_obj.compute_all(cr, uid, line.invoice_line_tax_id, (line.price_unit* (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id, {'skip_round':True})['taxes']: |
2259 | + for tax in tax_obj.compute_all(cr, uid, line.invoice_line_tax_id, (line.price_unit* (1-(line.discount or 0.0)/100.0)), line.quantity, inv.address_invoice_id.id, line.product_id, inv.partner_id)['taxes']:#, {'skip_round':True})['taxes']: |
2260 | tax_browse = tax_obj.browse(cr, uid, tax['id'], context) |
2261 | val={} |
2262 | val['invoice_id'] = inv.id |
2263 | |
2264 | === modified file 'l10n_ec_niif_minimal/objects/account_tax.py' (properties changed: -x to +x) |
2265 | === modified file 'l10n_ec_niif_minimal/views/account_tax_view.xml' (properties changed: -x to +x) |
2266 | === modified file 'l10n_ec_niif_minimal/views/l10n_chart_ec_niif_minimal_wizard.xml' (properties changed: -x to +x) |
2267 | === added directory 'trescloud_cheques' |
2268 | === added file 'trescloud_cheques/__init__.py' |
2269 | --- trescloud_cheques/__init__.py 1970-01-01 00:00:00 +0000 |
2270 | +++ trescloud_cheques/__init__.py 2013-05-03 13:54:27 +0000 |
2271 | @@ -0,0 +1,29 @@ |
2272 | +# -*- coding: utf-8 -*- |
2273 | +######################################################################## |
2274 | +# |
2275 | +#@authors:TRESCLOUD Cia.Ltda |
2276 | +# Copyright (C) 2012 |
2277 | +# |
2278 | +#This program is free software: you can redistribute it and/or modify |
2279 | +#it under the terms of the GNU General Public License as published by |
2280 | +#the Free Software Foundation, either version 3 of the License, or |
2281 | +#(at your option) any later version. |
2282 | +# |
2283 | +# This module is GPLv3 or newer and incompatible |
2284 | +# with OpenERP SA "AGPL + Private Use License"! |
2285 | +# |
2286 | +#This program is distributed in the hope that it will be useful, |
2287 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
2288 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
2289 | +#GNU General Public License for more details. |
2290 | +# |
2291 | +#You should have received a copy of the GNU General Public License |
2292 | +#along with this program. If not, see http://www.gnu.org/licenses. |
2293 | +#ice |
2294 | +######################################################################## |
2295 | + |
2296 | +import account_voucher |
2297 | +import trescloud_cheques |
2298 | +import account |
2299 | +import amount_to_words |
2300 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
2301 | \ No newline at end of file |
2302 | |
2303 | === added file 'trescloud_cheques/__openerp__.py' |
2304 | --- trescloud_cheques/__openerp__.py 1970-01-01 00:00:00 +0000 |
2305 | +++ trescloud_cheques/__openerp__.py 2013-05-03 13:54:27 +0000 |
2306 | @@ -0,0 +1,52 @@ |
2307 | +# -*- coding: utf-8 -*- |
2308 | +######################################################################## |
2309 | +# |
2310 | +# @authors:TRESCLOUD Cia.Ltda |
2311 | +# Copyright (C) 2012 |
2312 | +# |
2313 | +#This program is free software: you can redistribute it and/or modify |
2314 | +#it under the terms of the GNU General Public License as published by |
2315 | +#the Free Software Foundation, either version 3 of the License, or |
2316 | +#(at your option) any later version. |
2317 | +# |
2318 | +# This module is GPLv3 or newer and incompatible |
2319 | +# with OpenERP SA "AGPL + Private Use License"! |
2320 | +# |
2321 | +#This program is distributed in the hope that it will be useful, |
2322 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
2323 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
2324 | +#GNU General Public License for more details. |
2325 | +# |
2326 | +#You should have received a copy of the GNU General Public License |
2327 | +#along with this program. If not, see http://www.gnu.org/licenses. |
2328 | +#ice |
2329 | +######################################################################## |
2330 | +{ |
2331 | + "name" : "Módulo de cheques para Ecuador", |
2332 | + "author" : "TRESCloud Cia. Ltda.", |
2333 | + "maintainer": 'TRESCloud Cia. Ltda.', |
2334 | + "website": 'http://www.trescloud.com', |
2335 | + 'complexity': "easy", |
2336 | + "description": """Sistema gestión y control de CHEQUES |
2337 | + |
2338 | + Este sistema permite la impresión de los cheques y conocer el estado de los mismos. |
2339 | + |
2340 | + Desarrollador: |
2341 | + |
2342 | + Carlos Yumbillo |
2343 | + |
2344 | + """, |
2345 | + "category": "Tesoreria", |
2346 | + "version" : "1.0", |
2347 | + 'depends': ['base','account','account_payment'], |
2348 | + 'init_xml': [], |
2349 | + 'update_xml': [ |
2350 | + 'security/ir.model.access.csv', |
2351 | + 'trescloud_cheques_view.xml', |
2352 | + 'workflow/check_wkf.xml', |
2353 | + 'account_voucher_view.xml', |
2354 | + 'account_view.xml', |
2355 | + 'report/report_data.xml', |
2356 | + ], |
2357 | + 'installable': True, |
2358 | +} |
2359 | \ No newline at end of file |
2360 | |
2361 | === added file 'trescloud_cheques/account.py' |
2362 | --- trescloud_cheques/account.py 1970-01-01 00:00:00 +0000 |
2363 | +++ trescloud_cheques/account.py 2013-05-03 13:54:27 +0000 |
2364 | @@ -0,0 +1,105 @@ |
2365 | +from osv import osv, fields |
2366 | + |
2367 | +class account_journal(osv.osv): |
2368 | + """ |
2369 | + Add fields Allow Check writing, Use Preprinted Check and Check Sequence on journal |
2370 | + """ |
2371 | + _inherit = "account.journal" |
2372 | + _columns = { |
2373 | + 'allow_check_writing': fields.boolean('Allow Check writing', help='Fill this if the journal is to be used for writing checks.'), |
2374 | + 'use_preprint_check': fields.boolean('Use Preprinted Check'), |
2375 | + 'check_sequence': fields.many2one('ir.sequence', 'Check Sequence', |
2376 | + help="This field contains the information related to the numbering of the check number."), |
2377 | + } |
2378 | + |
2379 | +account_journal() |
2380 | + |
2381 | +#class check_log(osv.osv): |
2382 | +# """ |
2383 | +# Check Log model |
2384 | +# """ |
2385 | +# _name = 'check.log' |
2386 | +# _description = 'Check Log' |
2387 | +# _columns = { |
2388 | +# 'name': fields.many2one('account.voucher', 'Reference payment'), |
2389 | +# 'status': fields.selection([('active', 'Active'), ('voided', 'Voided'), ('stop_pay', 'Stop Pay Placed'), ('lost', 'Lost'), ('unk', 'Unknown')], |
2390 | +# "Check Status"), |
2391 | +# 'check_no': fields.char('Check Number', size=64), |
2392 | +# 'cleared': fields.boolean('Cleared', help="Check this if the check is cleared (aka Paid) by the Bank") |
2393 | +# } |
2394 | +# |
2395 | +# _defaults = { |
2396 | +# 'status': 'blank', |
2397 | +# } |
2398 | +#check_log() |
2399 | +# |
2400 | +# |
2401 | +#class account_invoice(osv.osv): |
2402 | +# """Update inv_reference field. |
2403 | +# This field will update only if the stock_assigned_picker module is installed.""" |
2404 | +# _inherit = "account.invoice" |
2405 | +# |
2406 | +# def _calc_inv_ref(self, cr, uid, ids, name, args, context=None): |
2407 | +# """ |
2408 | +# @param cr: current row of the database |
2409 | +# @param uid: id of user currently logged |
2410 | +# @param ids: ids of selected records |
2411 | +# @param name: |
2412 | +# @param args: |
2413 | +# @param context: context |
2414 | +# @return: |
2415 | +# """ |
2416 | +# res = {} |
2417 | +# picking_obj = self.pool.get('stock.picking') |
2418 | +# for inv in self.browse(cr, uid, ids, context=context): |
2419 | +# cr.execute("SELECT purchase_id FROM purchase_invoice_rel WHERE invoice_id = %s", (inv.id,)) |
2420 | +# pur_ids = cr.fetchall() or None |
2421 | +# if pur_ids and pur_ids[0]: |
2422 | +# pick_ids = picking_obj.search(cr, uid, [('purchase_id', '=', pur_ids[0][0])], context=context) |
2423 | +# if pick_ids: |
2424 | +# pici_id = picking_obj.browse(cr, uid, pick_ids[0], context=context) |
2425 | +# if hasattr(pici_id, 'ref_inv_no'): |
2426 | +# res[inv.id] = pici_id.ref_inv_no |
2427 | +# return res |
2428 | +# |
2429 | +# def _get_invoice_pur(self, cr, uid, ids, context=None): |
2430 | +# """ |
2431 | +# @param cr: current row of database |
2432 | +# @param uid: id of user currently logged in |
2433 | +# @param ids: ids of selected records |
2434 | +# @param context: context |
2435 | +# @return: list of ids |
2436 | +# """ |
2437 | +# result = {} |
2438 | +# for purchase_id in self.pool.get('purchase.order').browse(cr, uid, ids, context=context): |
2439 | +# for invoice_id in purchase_id.invoice_ids: |
2440 | +# result[invoice_id.id] = True |
2441 | +# return result.keys() |
2442 | +# |
2443 | +# def _get_invoice_pick(self, cr, uid, ids, context=None): |
2444 | +# """ |
2445 | +# @param cr: current row of database |
2446 | +# @param uid: id of user currently logged in |
2447 | +# @param ids: ids of selected records |
2448 | +# @param context: context |
2449 | +# @return: list of ids |
2450 | +# """ |
2451 | +# result = {} |
2452 | +# for pick in self.pool.get('stock.picking').browse(cr, uid, ids, context=context): |
2453 | +# if pick.purchase_id: |
2454 | +# for invoice_id in pick.purchase_id.invoice_ids: |
2455 | +# result[invoice_id.id] = True |
2456 | +# return result.keys() |
2457 | +# |
2458 | +# _columns = { |
2459 | +# 'inv_ref': fields.function(_calc_inv_ref, method=True, string='Reference Invoice', type='char', size=32, |
2460 | +# store = { |
2461 | +# 'account.invoice': (lambda self, cr, uid, ids, c={}: ids, ['state'], 10), |
2462 | +# 'purchase.order': (_get_invoice_pur, ['order_line'], 10), |
2463 | +# 'stock.picking': (_get_invoice_pick, ['ref_inv_no', 'purchase_id'], 10), |
2464 | +# }, multi=False), |
2465 | +# } |
2466 | +# |
2467 | +#account_invoice() |
2468 | +# |
2469 | +## vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
2470 | |
2471 | === added file 'trescloud_cheques/account_view.xml' |
2472 | --- trescloud_cheques/account_view.xml 1970-01-01 00:00:00 +0000 |
2473 | +++ trescloud_cheques/account_view.xml 2013-05-03 13:54:27 +0000 |
2474 | @@ -0,0 +1,27 @@ |
2475 | +<?xml version="1.0" encoding="utf-8"?> |
2476 | +<openerp> |
2477 | + <data> |
2478 | + |
2479 | + <!-- check option in journal --> |
2480 | + |
2481 | + <record id="view_account_journal_form" model="ir.ui.view"> |
2482 | + <field name="name">account.journal.form</field> |
2483 | + <field name="model">account.journal</field> |
2484 | + <field name="type">form</field> |
2485 | + <field name="inherit_id" ref="account.view_account_journal_form" /> |
2486 | + <field name="arch" type="xml"> |
2487 | + <!-- <field name="type" on_change="onchange_type(type, currency)" />--> |
2488 | + <field name="entry_posted" position="after"> |
2489 | + <field name="allow_check_writing" attrs="{'readonly':[('type','!=','bank')]}" /> |
2490 | + <!-- <field name="use_preprint_check" attrs="{'readonly':[('type','!=','bank')]}" />--> |
2491 | + </field> |
2492 | + <field name="sequence_id" required="0" position="after"> |
2493 | + <field name="check_sequence" |
2494 | + attrs= |
2495 | + "{'invisible':[('allow_check_writing','=',False)]}" /> |
2496 | + </field> |
2497 | + </field> |
2498 | + </record> |
2499 | + |
2500 | + </data> |
2501 | +</openerp> |
2502 | |
2503 | === added file 'trescloud_cheques/account_voucher.py' |
2504 | --- trescloud_cheques/account_voucher.py 1970-01-01 00:00:00 +0000 |
2505 | +++ trescloud_cheques/account_voucher.py 2013-05-03 13:54:27 +0000 |
2506 | @@ -0,0 +1,122 @@ |
2507 | +# -*- coding: utf-8 -*- |
2508 | +from osv import osv, fields |
2509 | +from tools.amount_to_text_en import amount_to_text |
2510 | +from tools.translate import _ |
2511 | + |
2512 | +class account_voucher(osv.osv): |
2513 | + _inherit = 'account.voucher' |
2514 | + |
2515 | + def _get_journal(self, cr, uid, context=None): |
2516 | + """ |
2517 | + Function to initialise the variable journal_id |
2518 | + """ |
2519 | + if context is None: |
2520 | + context = {} |
2521 | + journal_obj = self.pool.get('account.journal') |
2522 | + if 'invoice_id' in context: |
2523 | + currency_id = self.pool.get('account.invoice').browse(cr, uid, context['invoice_id'], context=context).currency_id.id |
2524 | + journal_id = journal_obj.search(cr, uid, [('currency', '=', currency_id)], limit=1, context=context) |
2525 | + return journal_id and journal_id[0] or False |
2526 | + if 'journal_id' in context: |
2527 | + return context['journal_id'] |
2528 | + if not 'journal_id' in context and 'search_default_journal_id' in context: |
2529 | + return context.get('search_default_journal_id') |
2530 | + ttype = context.get('type', 'bank') |
2531 | + if ttype in ('payment', 'receipt'): |
2532 | + ttype = 'bank' |
2533 | + if 'write_check' in context: |
2534 | + res = journal_obj.search(cr, uid, [('allow_check_writing', '=', True)], limit=1, context=context) |
2535 | + else: |
2536 | + res = journal_obj.search(cr, uid, [('type', '=', ttype)], limit=1, context=context) |
2537 | + return res and res[0] or False |
2538 | + |
2539 | + def _check_get(self, cr, uid, context=None): |
2540 | + rs={} |
2541 | + lista_check=[] |
2542 | + if context: |
2543 | + rs = { |
2544 | + 'mount':context['price'], |
2545 | + 'payee_name':context['partner_id'], |
2546 | + 'daily':"", |
2547 | + 'check_number':2, |
2548 | + 'current_date':context['current_date'], |
2549 | + } |
2550 | + lista_check.append(rs) |
2551 | + return lista_check |
2552 | + |
2553 | + |
2554 | + def onchange_partner_id(self, cr, uid, ids, partner_id, journal_id, price, currency_id, ttype, date, context=None): |
2555 | + """ Inherited - add amount_in_word in return value dictionary |
2556 | + cr: cursor |
2557 | + uid: user id |
2558 | + ids: ids of account voucher |
2559 | + partner_id: partner's id |
2560 | + journal_id: journal's id |
2561 | + price: price |
2562 | + currency_id: id of currency using |
2563 | + date: date |
2564 | + context: context |
2565 | + """ |
2566 | + rs={} |
2567 | + lines={} |
2568 | + lista_check=[] |
2569 | + tres_check_obj=self.pool.get('check.check') |
2570 | + |
2571 | + default = super(account_voucher, self).onchange_partner_id(cr, uid, ids, partner_id, journal_id, price, |
2572 | + currency_id, ttype, date, context=context) |
2573 | + if 'value' in default: |
2574 | + if journal_id: |
2575 | + allow_check_writing = self.pool.get('account.journal').browse(cr, uid, journal_id, context=context).allow_check_writing |
2576 | + default['value'].update({'allow_check': allow_check_writing}) |
2577 | + journal_obj = self.pool.get('account.journal') |
2578 | + journal = journal_obj.browse(cr, uid, journal_id).type |
2579 | + if journal == 'bank' : |
2580 | + default['value'].update({'reference': "Cheque"}) |
2581 | + else: |
2582 | + default['value'].update({'reference': "Efectivo"}) |
2583 | + |
2584 | + return default |
2585 | + |
2586 | + _columns = { |
2587 | + 'amount_in_word': fields.char("Amount in word", size=128, readonly=True, states={'draft': [('readonly', False)]}), |
2588 | + 'allow_check': fields.boolean('Allow Check Writing'), # attrs does not support '.' format and fields.relates get the value when v save the record |
2589 | + 'chk_seq': fields.char("Check Number", size=64, readonly=True), |
2590 | + 'chk_status': fields.boolean("Check Status"), |
2591 | + 'check_ids': fields.one2many('check.check','check_id','Check lines',readonly=True, states={'draft':[('readonly',False)]}) |
2592 | + } |
2593 | + |
2594 | + _defaults = { |
2595 | + 'journal_id': _get_journal, |
2596 | + 'chk_status': False, |
2597 | + # 'check_ids':_check_get, |
2598 | + } |
2599 | + |
2600 | + def unlink(self, cr, uid, ids, context=None): |
2601 | + """ |
2602 | + Función que impide la eliminación de vouchers que tengan cheques asociados. |
2603 | + """ |
2604 | + |
2605 | + check_obj = self.pool.get('check.check') |
2606 | + id_check = check_obj.search(cr,uid,[('check_id','=',ids[0])]) |
2607 | + if id_check: |
2608 | + check = check_obj.browse(cr,uid,id_check[0]) |
2609 | + if check.check_id: |
2610 | + raise osv.except_osv(_('Invalid action !'), _('Cannot delete Voucher(s) because there is a associated check. !')) |
2611 | + return super(account_voucher, self).unlink(cr, uid, ids, context=context) |
2612 | + |
2613 | + def action_move_line_create(self, cr, uid, ids, context=None): |
2614 | + res=super(account_voucher, self).action_move_line_create( cr, uid, ids, context=context) |
2615 | + i=0 |
2616 | + |
2617 | + for obj_voucher in self.browse(cr, uid, ids, context=context): |
2618 | + if len(obj_voucher.check_ids)>1: |
2619 | + raise osv.except_osv(_('Warning'), |
2620 | + _("Error while processing 'account.voucher' you can have only one check!")) |
2621 | + if obj_voucher.check_ids: |
2622 | + if obj_voucher.check_ids[0].state!='printed': |
2623 | + raise osv.except_osv(_('Warning'), |
2624 | + _("Error while processing 'account.voucher' you can only validate check in state printed!")) |
2625 | + |
2626 | + return True |
2627 | + |
2628 | +account_voucher() |
2629 | \ No newline at end of file |
2630 | |
2631 | === added file 'trescloud_cheques/account_voucher_view.xml' |
2632 | --- trescloud_cheques/account_voucher_view.xml 1970-01-01 00:00:00 +0000 |
2633 | +++ trescloud_cheques/account_voucher_view.xml 2013-05-03 13:54:27 +0000 |
2634 | @@ -0,0 +1,68 @@ |
2635 | +<?xml version="1.0" encoding="UTF-8"?> |
2636 | +<openerp> |
2637 | + <data> |
2638 | + |
2639 | + <!-- Account Voucher --> |
2640 | + |
2641 | + <record model="ir.ui.view" id="view_vendor_payment_check_form"> |
2642 | + <field name="name">account.voucher.payment.check.form</field> |
2643 | + <field name="model">account.voucher</field> |
2644 | + <field name="type">form</field> |
2645 | + <field name="inherit_id" ref="account_voucher.view_vendor_payment_form" /> |
2646 | + <field name="arch" type="xml"> |
2647 | + <field name="partner_id" domain="[('supplier','=',True)]" required="1" |
2648 | + on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date)" |
2649 | + context="{'invoice_currency':currency_id}" string="Supplier"/> |
2650 | + <field name="amount" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date)"/> |
2651 | + <field name="amount" position="after"> |
2652 | + <field name="allow_check" invisible="1"/> |
2653 | + <!-- <field name="amount_in_word" attrs="{'invisible':[('allow_check','!=',1)]}" nolabel="1" colspan="2"/>--> |
2654 | + <!--<field name="chk_seq" attrs="{'invisible':[('allow_check','!=',1)]}" colspan="1"/>--> |
2655 | + <!--<field name="chk_status" invisible="1" />--> |
2656 | + </field> |
2657 | + <field name="journal_id" |
2658 | + domain="[('type','in',['bank', 'cash'])]" |
2659 | + widget="selection" select="1" |
2660 | + on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date)" |
2661 | + string="Payment Method"/> |
2662 | + <field name="date" select="1" on_change="onchange_date(partner_id, journal_id, amount, currency_id, type, date)"/> |
2663 | + <field name="name" colspan="4"/> |
2664 | + <field name="type" invisible="True"/> |
2665 | + <field name="currency_id" invisible="True"/> |
2666 | + <field name="state"/> |
2667 | + <separator string="Other Information" colspan="2" position="replace"/> |
2668 | + <field name="line_dr_ids" position="before"> |
2669 | + <field name="check_ids" attrs="{'invisible':[('allow_check','!=',1)]}" default_get="{'journal_id':journal_id,'amount':amount, 'partner_id':partner_id,'date':date}" colspan="4" nolabel="1" height="140"> |
2670 | + <tree string="Checks Lines"> |
2671 | + <field name="check_number"/> |
2672 | + <field name="payee_name"/> |
2673 | + <field name="amount"/> |
2674 | + <field name="journal_id"/> |
2675 | + <field name="current_date"/> |
2676 | + <field name="state"/> |
2677 | + <button name="imprimir" string="Print" states="draft" type="object" icon="gtk-print"/> |
2678 | + </tree> |
2679 | + <form string="Manage checks"> |
2680 | + <group col="2" colspan="2"> |
2681 | + <separator colspan="2"></separator> |
2682 | + <field name="supplier" on_change="onchange_partner(supplier)" attrs="{'readonly':[('state','!=','draft')]}" readonly="1"/> |
2683 | + <field name="check_number" attrs="{'readonly':[('state','!=','draft')]}"/> |
2684 | + <field name="amount" on_change="onchange_amount(amount)" attrs="{'readonly':[('state','!=','draft')]}" /> |
2685 | + <field name="payee_name" attrs="{'readonly':[('state','!=','draft')]}" /> |
2686 | + <field name="ver_p" invisible="1"/> |
2687 | + </group> |
2688 | + <group col="2" colspan="2"> |
2689 | + <separator colspan="2"></separator> |
2690 | + <field name="journal_id" on_change="onchange_check_number(journal_id)" attrs="{'readonly':[('state','!=','draft')]}" readonly="1"/> |
2691 | + <field name="current_date" attrs="{'readonly':[('state','!=','draft')]}"/> |
2692 | + <newline/> |
2693 | + <field name="amount_in_words" nolabel="1" colspan="2"/> |
2694 | + </group> |
2695 | + </form> |
2696 | + </field> |
2697 | + </field> |
2698 | + </field> |
2699 | + </record> |
2700 | + |
2701 | + </data> |
2702 | +</openerp> |
2703 | |
2704 | === added file 'trescloud_cheques/amount_to_words.py' |
2705 | --- trescloud_cheques/amount_to_words.py 1970-01-01 00:00:00 +0000 |
2706 | +++ trescloud_cheques/amount_to_words.py 2013-05-03 13:54:27 +0000 |
2707 | @@ -0,0 +1,96 @@ |
2708 | +# -*- coding: utf-8 -*- |
2709 | +############################################################################## |
2710 | +# |
2711 | +# OpenERP, Open Source Management Solution |
2712 | +# Copyright (C) 2011 NovaPoint Group LLC (<http://www.novapointgroup.com>) |
2713 | +# Copyright (C) 2004-2010 OpenERP SA (<http://www.openerp.com>) |
2714 | +# |
2715 | +# This program is free software: you can redistribute it and/or modify |
2716 | +# it under the terms of the GNU General Public License as published by |
2717 | +# the Free Software Foundation, either version 3 of the License, or |
2718 | +# (at your option) any later version. |
2719 | +# |
2720 | +# This program is distributed in the hope that it will be useful, |
2721 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
2722 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
2723 | +# GNU General Public License for more details. |
2724 | +# |
2725 | +# You should have received a copy of the GNU General Public License |
2726 | +# along with this program. If not, see <http://www.gnu.org/licenses/> |
2727 | +# |
2728 | +############################################################################## |
2729 | + |
2730 | +# can be used for numbers as large as 999 vigintillion |
2731 | +# (vigintillion --> 10 to the power 60) |
2732 | +# tested with Python24 vegaseat 07dec2006 |
2733 | + |
2734 | +# Modificado por Andres Calle - TRESCLOUD Cía Ltda andres.calle@trescloud.com |
2735 | +# Basado en el trabajo realizado por Gabriel Umaña gabriumaa@gmail.com |
2736 | + |
2737 | +""" |
2738 | +Este archivo fue realizado por Gabriel Umana gabriumaa@gmail.com |
2739 | +Es para poner los valores de los cheques en castellano |
2740 | +""" |
2741 | +import math |
2742 | + |
2743 | +UNIDADES = ( '', 'Un ', 'Dos ', 'Tres ', 'Cuatro ', 'Cinco ', 'Seis ', 'Siete ', 'Ocho ', 'Nueve ', 'Diez ', 'Once ', 'Doce ', 'Trece ', 'Catorce ', 'Quince ', 'Dieciseis ', 'Diecisiete ', 'Dieciocho ', 'Diecinueve ', 'Veinte ') |
2744 | +DECENAS = ('Venti', 'Treinta ', 'Cuarenta ', 'Cincuenta ', 'Sesenta ', 'Setenta ', 'Ochenta ', 'Noventa ', 'Cien ') |
2745 | +CENTENAS = ('Ciento ', 'Doscientos ', 'Trecientos ', 'Cuatrocientos ', 'Quinientos ', 'Seiscientos ', 'Setecientos ', 'ochocientos ', 'novecientos ' ) |
2746 | + |
2747 | +def Numero_a_Texto(number_in): |
2748 | + convertido = '' |
2749 | + number_str = str(number_in) if (type(number_in) != 'str') else number_in |
2750 | + number_str = number_str.zfill(9) |
2751 | + millones, miles, cientos = number_str[:3], number_str[3:6], number_str[6:] |
2752 | + if(millones): |
2753 | + if(millones == '001'): |
2754 | + convertido += 'Un Millon ' |
2755 | + elif(int(millones) > 0): |
2756 | + convertido += '%sMillones ' % __convertNumber(millones) |
2757 | + if(miles): |
2758 | + if(miles == '001'): |
2759 | + convertido += 'Mil ' |
2760 | + elif(int(miles) > 0): |
2761 | + convertido += '%sMil ' % __convertNumber(miles) |
2762 | + if(cientos): |
2763 | + if(cientos == '001'): |
2764 | + convertido += 'Un ' |
2765 | + elif(int(cientos) > 0): |
2766 | + convertido += '%s ' % __convertNumber(cientos) |
2767 | + return convertido |
2768 | + |
2769 | +def __convertNumber(n): |
2770 | + output = '' |
2771 | + if(n == '100'): |
2772 | + output = "Cien " |
2773 | + elif(n[0] != '0'): |
2774 | + output = CENTENAS[int(n[0])-1] |
2775 | + k = int(n[1:]) |
2776 | + if(k <= 20): |
2777 | + output += UNIDADES[k] |
2778 | + else: |
2779 | + if((k > 30) & (n[2] != '0')): |
2780 | + output += '%sy %s' % (DECENAS[int(n[1])-2], UNIDADES[int(n[2])]) |
2781 | + else: |
2782 | + output += '%s%s' % (DECENAS[int(n[1])-2], UNIDADES[int(n[2])]) |
2783 | + return output |
2784 | + |
2785 | + |
2786 | +def amount_to_words_es(j): |
2787 | + try: |
2788 | + Arreglo1 = str(j).split(',') |
2789 | + Arreglo2 = str(j).split('.') |
2790 | + if (len(Arreglo1) > len(Arreglo2) or len(Arreglo1) == len(Arreglo2)): |
2791 | + Arreglo = Arreglo1 |
2792 | + else: |
2793 | + Arreglo = Arreglo2 |
2794 | + |
2795 | + if (len(Arreglo) == 2): |
2796 | + whole = math.floor(j) |
2797 | + frac = j - whole |
2798 | + num = str("{0:.2f}".format(frac))[2:] |
2799 | + return Numero_a_Texto(Arreglo[0]) + 'con ' + num + "/100" |
2800 | + elif (len(Arreglo) == 1): |
2801 | + return Numero_a_Texto(Arreglo[0]) + 'con ' + '00/100' |
2802 | + except ValueError: |
2803 | + return "Cero" |
2804 | \ No newline at end of file |
2805 | |
2806 | === added directory 'trescloud_cheques/i18n' |
2807 | === added file 'trescloud_cheques/i18n/es.po' |
2808 | --- trescloud_cheques/i18n/es.po 1970-01-01 00:00:00 +0000 |
2809 | +++ trescloud_cheques/i18n/es.po 2013-05-03 13:54:27 +0000 |
2810 | @@ -0,0 +1,308 @@ |
2811 | +# Translation of OpenERP Server. |
2812 | +# This file contains the translation of the following modules: |
2813 | +# * trescloud_cheques |
2814 | +# |
2815 | +msgid "" |
2816 | +msgstr "" |
2817 | +"Project-Id-Version: OpenERP Server 6.0.4\n" |
2818 | +"Report-Msgid-Bugs-To: support@openerp.com\n" |
2819 | +"POT-Creation-Date: 2013-04-25 20:27+0000\n" |
2820 | +"PO-Revision-Date: 2013-04-25 20:27+0000\n" |
2821 | +"Last-Translator: <>\n" |
2822 | +"Language-Team: \n" |
2823 | +"MIME-Version: 1.0\n" |
2824 | +"Content-Type: text/plain; charset=UTF-8\n" |
2825 | +"Content-Transfer-Encoding: \n" |
2826 | +"Plural-Forms: \n" |
2827 | + |
2828 | +#. module: trescloud_cheques |
2829 | +#: code:addons/trescloud_cheques/account_voucher.py:114 |
2830 | +#, python-format |
2831 | +msgid "Error while processing 'account.voucher' you can have only one check!" |
2832 | +msgstr "Error mientras procesa 'account.voucher', puede tener solo un cheque! " |
2833 | + |
2834 | +#. module: trescloud_cheques |
2835 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:158 |
2836 | +#, python-format |
2837 | +msgid "Cannot delete check(s) that are already printed!" |
2838 | +msgstr "No se pueden eliminar cheques que ya están impresos!" |
2839 | + |
2840 | +#. module: trescloud_cheques |
2841 | +#: help:check.check,check_number:0 |
2842 | +msgid "check number" |
2843 | +msgstr "Número de cheque" |
2844 | + |
2845 | +#. module: trescloud_cheques |
2846 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:77 |
2847 | +#, python-format |
2848 | +msgid "Please add \"Check Sequence\" for journal %s.'%str(journal_id.name))\n" |
2849 | +" }\n" |
2850 | +" return {'warning':warning}\n" |
2851 | +" result=self.get_id(cr, uid, journal_id.check_sequence.id , test='id', context=context)\n" |
2852 | +" res['check_number']=result[0]\n" |
2853 | +" res['new_no']=result[0]\n" |
2854 | +" journal_id = self.pool.get('account.journal" |
2855 | +msgstr "" |
2856 | + |
2857 | +#. module: trescloud_cheques |
2858 | +#: view:account.voucher:0 |
2859 | +#: view:check.check:0 |
2860 | +msgid "Print" |
2861 | +msgstr "Imprimir" |
2862 | + |
2863 | +#. module: trescloud_cheques |
2864 | +#: field:check.check,state:0 |
2865 | +msgid "State" |
2866 | +msgstr "Estado" |
2867 | + |
2868 | +#. module: trescloud_cheques |
2869 | +#: view:check.check:0 |
2870 | +#: selection:check.check,state:0 |
2871 | +msgid "Draft" |
2872 | +msgstr "Borrador" |
2873 | + |
2874 | +#. module: trescloud_cheques |
2875 | +#: field:check.check,new_no:0 |
2876 | +msgid "Update Check Number" |
2877 | +msgstr "Actualizar número de cheque" |
2878 | + |
2879 | +#. module: trescloud_cheques |
2880 | +#: field:check.check,check_id:0 |
2881 | +msgid "Check Reference" |
2882 | +msgstr "Referencia del cheque" |
2883 | + |
2884 | +#. module: trescloud_cheques |
2885 | +#: view:account.voucher:0 |
2886 | +msgid "Supplier" |
2887 | +msgstr "Proveedor" |
2888 | + |
2889 | +#. module: trescloud_cheques |
2890 | +#: field:account.voucher,check_ids:0 |
2891 | +msgid "Check lines" |
2892 | +msgstr "Detalle de cheques" |
2893 | + |
2894 | +#. module: trescloud_cheques |
2895 | +#: model:ir.actions.report.xml,name:trescloud_cheques.voucher_report |
2896 | +msgid "Comprobante Ingreso-Egreso" |
2897 | +msgstr "" |
2898 | + |
2899 | +#. module: trescloud_cheques |
2900 | +#: field:check.check,check_number:0 |
2901 | +msgid "Check Number" |
2902 | +msgstr "Número de cheque" |
2903 | + |
2904 | +#. module: trescloud_cheques |
2905 | +#: field:check.check,amount_in_words:0 |
2906 | +msgid " " |
2907 | +msgstr "" |
2908 | + |
2909 | +#. module: trescloud_cheques |
2910 | +#: view:account.voucher:0 |
2911 | +msgid "Payment Method" |
2912 | +msgstr "Método de pago" |
2913 | + |
2914 | +#. module: trescloud_cheques |
2915 | +#: model:ir.actions.act_window,name:trescloud_cheques.action_view_check |
2916 | +#: model:ir.ui.menu,name:trescloud_cheques.submenu_check |
2917 | +msgid "Cheques" |
2918 | +msgstr "Cheques" |
2919 | + |
2920 | +#. module: trescloud_cheques |
2921 | +#: help:check.check,payee_name:0 |
2922 | +msgid "Used to indicate the payee name of check." |
2923 | +msgstr "Usado para indicar el nombre del beneficario del cheque" |
2924 | + |
2925 | +#. module: trescloud_cheques |
2926 | +#: field:check.check,journal_id:0 |
2927 | +#: model:ir.model,name:trescloud_cheques.model_account_journal |
2928 | +msgid "Journal" |
2929 | +msgstr "Diario" |
2930 | + |
2931 | +#. module: trescloud_cheques |
2932 | +#: view:check.check:0 |
2933 | +msgid "Vouchers" |
2934 | +msgstr "Comprobantes" |
2935 | + |
2936 | +#. module: trescloud_cheques |
2937 | +#: view:check.check:0 |
2938 | +#: selection:check.check,state:0 |
2939 | +msgid "Rejected" |
2940 | +msgstr "Rechazado" |
2941 | + |
2942 | +#. module: trescloud_cheques |
2943 | +#: model:ir.model,name:trescloud_cheques.model_check_check |
2944 | +msgid "check.check" |
2945 | +msgstr "" |
2946 | + |
2947 | +#. module: trescloud_cheques |
2948 | +#: code:addons/trescloud_cheques/account_voucher.py:118 |
2949 | +#, python-format |
2950 | +msgid "Error while processing 'account.voucher' you can only validate check in state printed!" |
2951 | +msgstr "Error mientras procesa 'account.voucher', solo puedes validarla con un cheque en estado impreso! " |
2952 | + |
2953 | +#. module: trescloud_cheques |
2954 | +#: code:addons/trescloud_cheques/account_voucher.py:113 |
2955 | +#: code:addons/trescloud_cheques/account_voucher.py:117 |
2956 | +#, python-format |
2957 | +msgid "Warning" |
2958 | +msgstr "Advertencia" |
2959 | + |
2960 | +#. module: trescloud_cheques |
2961 | +#: view:check.check:0 |
2962 | +#: selection:check.check,state:0 |
2963 | +msgid "Printed" |
2964 | +msgstr "Impreso" |
2965 | + |
2966 | +#. module: trescloud_cheques |
2967 | +#: model:ir.actions.report.xml,name:trescloud_cheques.report_check |
2968 | +msgid "Impresion de cheque" |
2969 | +msgstr "Impresión del cheque" |
2970 | + |
2971 | +#. module: trescloud_cheques |
2972 | +#: code:addons/trescloud_cheques/account_voucher.py:104 |
2973 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:158 |
2974 | +#, python-format |
2975 | +msgid "Invalid action !" |
2976 | +msgstr "Acción invalida !" |
2977 | + |
2978 | +#. module: trescloud_cheques |
2979 | +#: help:check.check,new_no:0 |
2980 | +msgid "Enter new check number here if you wish to update" |
2981 | +msgstr "Introduzca el nuevo número de cheque aquí si desea actualizar" |
2982 | + |
2983 | +#. module: trescloud_cheques |
2984 | +#: view:check.check:0 |
2985 | +msgid "Reprint" |
2986 | +msgstr "Reimprimir" |
2987 | + |
2988 | +#. module: trescloud_cheques |
2989 | +#: code:addons/trescloud_cheques/account_voucher.py:104 |
2990 | +#, python-format |
2991 | +msgid "Cannot delete Voucher(s) because there is a associated check. !" |
2992 | +msgstr "No puede eliminar comprobante(s) porque hay un cheque asociado. !" |
2993 | + |
2994 | +#. module: trescloud_cheques |
2995 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:49 |
2996 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:76 |
2997 | +#, python-format |
2998 | +msgid "Warning!" |
2999 | +msgstr "Advertencia!" |
3000 | + |
3001 | +#. module: trescloud_cheques |
3002 | +#: view:check.check:0 |
3003 | +#: selection:check.check,state:0 |
3004 | +msgid "Lost" |
3005 | +msgstr "Perdido" |
3006 | + |
3007 | +#. module: trescloud_cheques |
3008 | +#: sql_constraint:check.check:0 |
3009 | +msgid "The check number must be unique !" |
3010 | +msgstr "El número de cheque debe ser único !" |
3011 | + |
3012 | +#. module: trescloud_cheques |
3013 | +#: view:account.voucher:0 |
3014 | +#: view:check.check:0 |
3015 | +msgid "Manage checks" |
3016 | +msgstr "Gestionar cheques" |
3017 | + |
3018 | +#. module: trescloud_cheques |
3019 | +#: field:check.check,amount:0 |
3020 | +msgid "Amount" |
3021 | +msgstr "Total" |
3022 | + |
3023 | +#. module: trescloud_cheques |
3024 | +#: field:check.check,ver_p:0 |
3025 | +msgid "Verificacion" |
3026 | +msgstr "Verificación" |
3027 | + |
3028 | +#. module: trescloud_cheques |
3029 | +#: view:account.voucher:0 |
3030 | +msgid "Other Information" |
3031 | +msgstr "Otra información" |
3032 | + |
3033 | +#. module: trescloud_cheques |
3034 | +#: view:check.check:0 |
3035 | +msgid "Search Check" |
3036 | +msgstr "Buscar cheque" |
3037 | + |
3038 | +#. module: trescloud_cheques |
3039 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:205 |
3040 | +#: constraint:check.check:0 |
3041 | +#, python-format |
3042 | +msgid "The number of check is incorrect, it must be of six digits XXXXXX, X is a number." |
3043 | +msgstr "El número de cheque es incorrecto, debe tener 6 digitos XXXXXX, X es un número." |
3044 | + |
3045 | +#. module: trescloud_cheques |
3046 | +#: view:check.check:0 |
3047 | +#: selection:check.check,state:0 |
3048 | +msgid "Charged" |
3049 | +msgstr "Cobrado" |
3050 | + |
3051 | +#. module: trescloud_cheques |
3052 | +#: view:account.voucher:0 |
3053 | +msgid "Checks Lines" |
3054 | +msgstr "Detalle de cheques" |
3055 | + |
3056 | +#. module: trescloud_cheques |
3057 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:49 |
3058 | +#, python-format |
3059 | +msgid "Please add \"Check Sequence\" for journal %s.'%str(voucher_id.journal_id.name)))\n" |
3060 | +" res = self.get_id(cr, uid, voucher_id.journal_id.check_sequence.id, test='id', context=context)\n" |
3061 | +" return res and res[0]\n" |
3062 | +" else:\n" |
3063 | +" return False\n" |
3064 | +" \n" |
3065 | +" def _get_new_no(self, cr, uid, context=None):\n" |
3066 | +" \"\"\"\n" |
3067 | +" Function to get the next number used to generate sequence\n" |
3068 | +" \"\"\"\n" |
3069 | +" if context is None:\n" |
3070 | +" context = {}\n" |
3071 | +" res = []\n" |
3072 | +" if 'active_id' in context:\n" |
3073 | +" voucher_id = self.pool.get('account.voucher" |
3074 | +msgstr "" |
3075 | + |
3076 | +#. module: trescloud_cheques |
3077 | +#: model:ir.model,name:trescloud_cheques.model_account_voucher |
3078 | +msgid "Accounting Voucher" |
3079 | +msgstr "Comprobante contable" |
3080 | + |
3081 | +#. module: trescloud_cheques |
3082 | +#: sql_constraint:account.journal:0 |
3083 | +msgid "The name of the journal must be unique per company !" |
3084 | +msgstr "El nombre del diario debe ser único por companía !" |
3085 | + |
3086 | +#. module: trescloud_cheques |
3087 | +#: field:check.check,payee_name:0 |
3088 | +msgid "Payee name" |
3089 | +msgstr "Beneficario" |
3090 | + |
3091 | +#. module: trescloud_cheques |
3092 | +#: view:check.check:0 |
3093 | +#: selection:check.check,state:0 |
3094 | +msgid "Canceled" |
3095 | +msgstr "Anulado" |
3096 | + |
3097 | +#. module: trescloud_cheques |
3098 | +#: sql_constraint:account.journal:0 |
3099 | +msgid "The code of the journal must be unique per company !" |
3100 | +msgstr "El código del diario debe ser único por compañía !" |
3101 | + |
3102 | +#. module: trescloud_cheques |
3103 | +#: field:check.check,current_date:0 |
3104 | +msgid "Current date" |
3105 | +msgstr "Fecha" |
3106 | + |
3107 | +#. module: trescloud_cheques |
3108 | +#: field:check.check,supplier:0 |
3109 | +msgid "Partner" |
3110 | +msgstr "Cliente" |
3111 | + |
3112 | +#. module: trescloud_cheques |
3113 | +#: model:ir.actions.act_window,help:trescloud_cheques.action_view_check |
3114 | +msgid "With this module you can create and print new checks. You can also track the status of the check (like cancelled, charged, lost or rejected).\n" |
3115 | +"It is related to vendor payments module and must have a journal configured as a check journal." |
3116 | +msgstr "Con este módulo se puede crear e imprimir nuevos cheques. También puede realizar el seguimiento del estado de los cheques (como anulado, cobrado, perdido o rechazado).\n" |
3117 | +"Está relacionado con el módulo de pagos a proveedores y debe tener un diario configurado como un diario cheques. " |
3118 | + |
3119 | |
3120 | === added file 'trescloud_cheques/i18n/trescloud_cheques.pot' |
3121 | --- trescloud_cheques/i18n/trescloud_cheques.pot 1970-01-01 00:00:00 +0000 |
3122 | +++ trescloud_cheques/i18n/trescloud_cheques.pot 2013-05-03 13:54:27 +0000 |
3123 | @@ -0,0 +1,307 @@ |
3124 | +# Translation of OpenERP Server. |
3125 | +# This file contains the translation of the following modules: |
3126 | +# * trescloud_cheques |
3127 | +# |
3128 | +msgid "" |
3129 | +msgstr "" |
3130 | +"Project-Id-Version: OpenERP Server 6.0.4\n" |
3131 | +"Report-Msgid-Bugs-To: support@openerp.com\n" |
3132 | +"POT-Creation-Date: 2013-04-25 20:27+0000\n" |
3133 | +"PO-Revision-Date: 2013-04-25 20:27+0000\n" |
3134 | +"Last-Translator: <>\n" |
3135 | +"Language-Team: \n" |
3136 | +"MIME-Version: 1.0\n" |
3137 | +"Content-Type: text/plain; charset=UTF-8\n" |
3138 | +"Content-Transfer-Encoding: \n" |
3139 | +"Plural-Forms: \n" |
3140 | + |
3141 | +#. module: trescloud_cheques |
3142 | +#: code:addons/trescloud_cheques/account_voucher.py:114 |
3143 | +#, python-format |
3144 | +msgid "Error while processing 'account.voucher' you can have only one check!" |
3145 | +msgstr "" |
3146 | + |
3147 | +#. module: trescloud_cheques |
3148 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:158 |
3149 | +#, python-format |
3150 | +msgid "Cannot delete check(s) that are already printed!" |
3151 | +msgstr "" |
3152 | + |
3153 | +#. module: trescloud_cheques |
3154 | +#: help:check.check,check_number:0 |
3155 | +msgid "check number" |
3156 | +msgstr "" |
3157 | + |
3158 | +#. module: trescloud_cheques |
3159 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:77 |
3160 | +#, python-format |
3161 | +msgid "Please add \"Check Sequence\" for journal %s.'%str(journal_id.name))\n" |
3162 | +" }\n" |
3163 | +" return {'warning':warning}\n" |
3164 | +" result=self.get_id(cr, uid, journal_id.check_sequence.id , test='id', context=context)\n" |
3165 | +" res['check_number']=result[0]\n" |
3166 | +" res['new_no']=result[0]\n" |
3167 | +" journal_id = self.pool.get('account.journal" |
3168 | +msgstr "" |
3169 | + |
3170 | +#. module: trescloud_cheques |
3171 | +#: view:account.voucher:0 |
3172 | +#: view:check.check:0 |
3173 | +msgid "Print" |
3174 | +msgstr "" |
3175 | + |
3176 | +#. module: trescloud_cheques |
3177 | +#: field:check.check,state:0 |
3178 | +msgid "State" |
3179 | +msgstr "" |
3180 | + |
3181 | +#. module: trescloud_cheques |
3182 | +#: view:check.check:0 |
3183 | +#: selection:check.check,state:0 |
3184 | +msgid "Draft" |
3185 | +msgstr "" |
3186 | + |
3187 | +#. module: trescloud_cheques |
3188 | +#: field:check.check,new_no:0 |
3189 | +msgid "Update Check Number" |
3190 | +msgstr "" |
3191 | + |
3192 | +#. module: trescloud_cheques |
3193 | +#: field:check.check,check_id:0 |
3194 | +msgid "Check Reference" |
3195 | +msgstr "" |
3196 | + |
3197 | +#. module: trescloud_cheques |
3198 | +#: view:account.voucher:0 |
3199 | +msgid "Supplier" |
3200 | +msgstr "" |
3201 | + |
3202 | +#. module: trescloud_cheques |
3203 | +#: field:account.voucher,check_ids:0 |
3204 | +msgid "Check lines" |
3205 | +msgstr "" |
3206 | + |
3207 | +#. module: trescloud_cheques |
3208 | +#: model:ir.actions.report.xml,name:trescloud_cheques.voucher_report |
3209 | +msgid "Comprobante Ingreso-Egreso" |
3210 | +msgstr "" |
3211 | + |
3212 | +#. module: trescloud_cheques |
3213 | +#: field:check.check,check_number:0 |
3214 | +msgid "Check Number" |
3215 | +msgstr "" |
3216 | + |
3217 | +#. module: trescloud_cheques |
3218 | +#: field:check.check,amount_in_words:0 |
3219 | +msgid " " |
3220 | +msgstr "" |
3221 | + |
3222 | +#. module: trescloud_cheques |
3223 | +#: view:account.voucher:0 |
3224 | +msgid "Payment Method" |
3225 | +msgstr "" |
3226 | + |
3227 | +#. module: trescloud_cheques |
3228 | +#: model:ir.actions.act_window,name:trescloud_cheques.action_view_check |
3229 | +#: model:ir.ui.menu,name:trescloud_cheques.submenu_check |
3230 | +msgid "Cheques" |
3231 | +msgstr "" |
3232 | + |
3233 | +#. module: trescloud_cheques |
3234 | +#: help:check.check,payee_name:0 |
3235 | +msgid "Used to indicate the payee name of check." |
3236 | +msgstr "" |
3237 | + |
3238 | +#. module: trescloud_cheques |
3239 | +#: field:check.check,journal_id:0 |
3240 | +#: model:ir.model,name:trescloud_cheques.model_account_journal |
3241 | +msgid "Journal" |
3242 | +msgstr "" |
3243 | + |
3244 | +#. module: trescloud_cheques |
3245 | +#: view:check.check:0 |
3246 | +msgid "Vouchers" |
3247 | +msgstr "" |
3248 | + |
3249 | +#. module: trescloud_cheques |
3250 | +#: view:check.check:0 |
3251 | +#: selection:check.check,state:0 |
3252 | +msgid "Rejected" |
3253 | +msgstr "" |
3254 | + |
3255 | +#. module: trescloud_cheques |
3256 | +#: model:ir.model,name:trescloud_cheques.model_check_check |
3257 | +msgid "check.check" |
3258 | +msgstr "" |
3259 | + |
3260 | +#. module: trescloud_cheques |
3261 | +#: code:addons/trescloud_cheques/account_voucher.py:118 |
3262 | +#, python-format |
3263 | +msgid "Error while processing 'account.voucher' you can only validate check in state printed!" |
3264 | +msgstr "" |
3265 | + |
3266 | +#. module: trescloud_cheques |
3267 | +#: code:addons/trescloud_cheques/account_voucher.py:113 |
3268 | +#: code:addons/trescloud_cheques/account_voucher.py:117 |
3269 | +#, python-format |
3270 | +msgid "Warning" |
3271 | +msgstr "" |
3272 | + |
3273 | +#. module: trescloud_cheques |
3274 | +#: view:check.check:0 |
3275 | +#: selection:check.check,state:0 |
3276 | +msgid "Printed" |
3277 | +msgstr "" |
3278 | + |
3279 | +#. module: trescloud_cheques |
3280 | +#: model:ir.actions.report.xml,name:trescloud_cheques.report_check |
3281 | +msgid "Impresion de cheque" |
3282 | +msgstr "" |
3283 | + |
3284 | +#. module: trescloud_cheques |
3285 | +#: code:addons/trescloud_cheques/account_voucher.py:104 |
3286 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:158 |
3287 | +#, python-format |
3288 | +msgid "Invalid action !" |
3289 | +msgstr "" |
3290 | + |
3291 | +#. module: trescloud_cheques |
3292 | +#: help:check.check,new_no:0 |
3293 | +msgid "Enter new check number here if you wish to update" |
3294 | +msgstr "" |
3295 | + |
3296 | +#. module: trescloud_cheques |
3297 | +#: view:check.check:0 |
3298 | +msgid "Reprint" |
3299 | +msgstr "" |
3300 | + |
3301 | +#. module: trescloud_cheques |
3302 | +#: code:addons/trescloud_cheques/account_voucher.py:104 |
3303 | +#, python-format |
3304 | +msgid "Cannot delete Voucher(s) because there is a associated check. !" |
3305 | +msgstr "" |
3306 | + |
3307 | +#. module: trescloud_cheques |
3308 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:49 |
3309 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:76 |
3310 | +#, python-format |
3311 | +msgid "Warning!" |
3312 | +msgstr "" |
3313 | + |
3314 | +#. module: trescloud_cheques |
3315 | +#: view:check.check:0 |
3316 | +#: selection:check.check,state:0 |
3317 | +msgid "Lost" |
3318 | +msgstr "" |
3319 | + |
3320 | +#. module: trescloud_cheques |
3321 | +#: sql_constraint:check.check:0 |
3322 | +msgid "The check number must be unique !" |
3323 | +msgstr "" |
3324 | + |
3325 | +#. module: trescloud_cheques |
3326 | +#: view:account.voucher:0 |
3327 | +#: view:check.check:0 |
3328 | +msgid "Manage checks" |
3329 | +msgstr "" |
3330 | + |
3331 | +#. module: trescloud_cheques |
3332 | +#: field:check.check,amount:0 |
3333 | +msgid "Amount" |
3334 | +msgstr "" |
3335 | + |
3336 | +#. module: trescloud_cheques |
3337 | +#: field:check.check,ver_p:0 |
3338 | +msgid "Verificacion" |
3339 | +msgstr "" |
3340 | + |
3341 | +#. module: trescloud_cheques |
3342 | +#: view:account.voucher:0 |
3343 | +msgid "Other Information" |
3344 | +msgstr "" |
3345 | + |
3346 | +#. module: trescloud_cheques |
3347 | +#: view:check.check:0 |
3348 | +msgid "Search Check" |
3349 | +msgstr "" |
3350 | + |
3351 | +#. module: trescloud_cheques |
3352 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:205 |
3353 | +#: constraint:check.check:0 |
3354 | +#, python-format |
3355 | +msgid "The number of check is incorrect, it must be of six digits XXXXXX, X is a number." |
3356 | +msgstr "" |
3357 | + |
3358 | +#. module: trescloud_cheques |
3359 | +#: view:check.check:0 |
3360 | +#: selection:check.check,state:0 |
3361 | +msgid "Charged" |
3362 | +msgstr "" |
3363 | + |
3364 | +#. module: trescloud_cheques |
3365 | +#: view:account.voucher:0 |
3366 | +msgid "Checks Lines" |
3367 | +msgstr "" |
3368 | + |
3369 | +#. module: trescloud_cheques |
3370 | +#: code:addons/trescloud_cheques/trescloud_cheques.py:49 |
3371 | +#, python-format |
3372 | +msgid "Please add \"Check Sequence\" for journal %s.'%str(voucher_id.journal_id.name)))\n" |
3373 | +" res = self.get_id(cr, uid, voucher_id.journal_id.check_sequence.id, test='id', context=context)\n" |
3374 | +" return res and res[0]\n" |
3375 | +" else:\n" |
3376 | +" return False\n" |
3377 | +" \n" |
3378 | +" def _get_new_no(self, cr, uid, context=None):\n" |
3379 | +" \"\"\"\n" |
3380 | +" Function to get the next number used to generate sequence\n" |
3381 | +" \"\"\"\n" |
3382 | +" if context is None:\n" |
3383 | +" context = {}\n" |
3384 | +" res = []\n" |
3385 | +" if 'active_id' in context:\n" |
3386 | +" voucher_id = self.pool.get('account.voucher" |
3387 | +msgstr "" |
3388 | + |
3389 | +#. module: trescloud_cheques |
3390 | +#: model:ir.model,name:trescloud_cheques.model_account_voucher |
3391 | +msgid "Accounting Voucher" |
3392 | +msgstr "" |
3393 | + |
3394 | +#. module: trescloud_cheques |
3395 | +#: sql_constraint:account.journal:0 |
3396 | +msgid "The name of the journal must be unique per company !" |
3397 | +msgstr "" |
3398 | + |
3399 | +#. module: trescloud_cheques |
3400 | +#: field:check.check,payee_name:0 |
3401 | +msgid "Payee name" |
3402 | +msgstr "" |
3403 | + |
3404 | +#. module: trescloud_cheques |
3405 | +#: view:check.check:0 |
3406 | +#: selection:check.check,state:0 |
3407 | +msgid "Canceled" |
3408 | +msgstr "" |
3409 | + |
3410 | +#. module: trescloud_cheques |
3411 | +#: sql_constraint:account.journal:0 |
3412 | +msgid "The code of the journal must be unique per company !" |
3413 | +msgstr "" |
3414 | + |
3415 | +#. module: trescloud_cheques |
3416 | +#: field:check.check,current_date:0 |
3417 | +msgid "Current date" |
3418 | +msgstr "" |
3419 | + |
3420 | +#. module: trescloud_cheques |
3421 | +#: field:check.check,supplier:0 |
3422 | +msgid "Partner" |
3423 | +msgstr "" |
3424 | + |
3425 | +#. module: trescloud_cheques |
3426 | +#: model:ir.actions.act_window,help:trescloud_cheques.action_view_check |
3427 | +msgid "With this module you can create and print new checks. You can also track the status of the check (like cancelled, charged, lost or rejected).\n" |
3428 | +"It is related to vendor payments module and must have a journal configured as a check journal." |
3429 | +msgstr "" |
3430 | + |
3431 | |
3432 | === added directory 'trescloud_cheques/report' |
3433 | === added file 'trescloud_cheques/report/cheque_report.odt' |
3434 | Binary files trescloud_cheques/report/cheque_report.odt 1970-01-01 00:00:00 +0000 and trescloud_cheques/report/cheque_report.odt 2013-05-03 13:54:27 +0000 differ |
3435 | === added file 'trescloud_cheques/report/ingreso_egreso_report.odt' |
3436 | Binary files trescloud_cheques/report/ingreso_egreso_report.odt 1970-01-01 00:00:00 +0000 and trescloud_cheques/report/ingreso_egreso_report.odt 2013-05-03 13:54:27 +0000 differ |
3437 | === added file 'trescloud_cheques/report/report_data.xml' |
3438 | --- trescloud_cheques/report/report_data.xml 1970-01-01 00:00:00 +0000 |
3439 | +++ trescloud_cheques/report/report_data.xml 2013-05-03 13:54:27 +0000 |
3440 | @@ -0,0 +1,47 @@ |
3441 | +<?xml version="1.0" encoding="UTF-8"?> |
3442 | +<openerp> |
3443 | + <!-- no actualizar ya que en multicompania o multidb debe poder personalizarse --> |
3444 | + <data noupdate="1"> |
3445 | + |
3446 | + <!-- !!!!!!!!!!!!!!!!!!!!!!!!! REPORTE - CHEQUE !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> |
3447 | + |
3448 | + <record id="report_check" model="ir.actions.report.xml"> |
3449 | + <field name="name">Impresion de cheque</field> |
3450 | + <field name="type">ir.actions.report.xml</field> |
3451 | + <field name="model">check.check</field> |
3452 | + <field name="report_name">check_report</field> |
3453 | + <field name="report_type">aeroo</field> |
3454 | + <field name="in_format">oo-odt</field> |
3455 | + <field name='out_format' eval="ref('report_aeroo_ooo.report_mimetypes_pdf_odt')" /> |
3456 | + <field name="report_rml">trescloud_cheques/report/cheque_report.odt</field> |
3457 | + <field name="parser_state">default</field> |
3458 | + <field name="tml_source">file</field> |
3459 | + </record> |
3460 | + |
3461 | +<!-- !!!!!!!!!!!!!!!!!!!!!!!!! REPORTE - COMPROBANTE DE INGRESO Y EGRESO !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> |
3462 | + |
3463 | + <record id="voucher_report" model="ir.actions.report.xml"> |
3464 | + <field name="name">Comprobante Ingreso-Egreso</field> |
3465 | + <field name="type">ir.actions.report.xml</field> |
3466 | + <field name="model">account.voucher</field> |
3467 | + <field name="report_name">Comprobante Ingreso-Egreso</field> |
3468 | + <field name="report_type">aeroo</field> |
3469 | + <field name="in_format">oo-odt</field> |
3470 | + <field name='out_format' eval="ref('report_aeroo_ooo.report_mimetypes_pdf_odt')" /> |
3471 | + <field name="report_rml">trescloud_cheques/report/ingreso_egreso_report.odt</field> |
3472 | + <field name="parser_state">default</field> |
3473 | + <field name="tml_source">file</field> |
3474 | + </record> |
3475 | + |
3476 | + <ir_set> |
3477 | + <field eval="'action'" name="key" /> |
3478 | + <field eval="'client_print_multi'" name="key2" /> |
3479 | + <field eval="['account.voucher']" name="models" /> |
3480 | + <field name="name">voucher</field> |
3481 | + <field eval="'ir.actions.report.xml,'+str(voucher_report)" name="value" /> |
3482 | + <field eval="True" name="isobject" /> |
3483 | + <field eval="True" name="replace" /> |
3484 | + </ir_set> |
3485 | + |
3486 | + </data> |
3487 | +</openerp> |
3488 | \ No newline at end of file |
3489 | |
3490 | === added directory 'trescloud_cheques/security' |
3491 | === added file 'trescloud_cheques/security/ir.model.access.csv' |
3492 | --- trescloud_cheques/security/ir.model.access.csv 1970-01-01 00:00:00 +0000 |
3493 | +++ trescloud_cheques/security/ir.model.access.csv 2013-05-03 13:54:27 +0000 |
3494 | @@ -0,0 +1,2 @@ |
3495 | +"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink" |
3496 | +"access_check_check","check.check","model_check_check","account_payment.group_account_payment",1,1,1,0 |
3497 | \ No newline at end of file |
3498 | |
3499 | === added file 'trescloud_cheques/trescloud_cheques.py' |
3500 | --- trescloud_cheques/trescloud_cheques.py 1970-01-01 00:00:00 +0000 |
3501 | +++ trescloud_cheques/trescloud_cheques.py 2013-05-03 13:54:27 +0000 |
3502 | @@ -0,0 +1,299 @@ |
3503 | +# -*- coding: utf-8 -*- |
3504 | +from osv import osv, fields |
3505 | +from datetime import datetime |
3506 | +from amount_to_words import amount_to_words_es |
3507 | +from tools.translate import _ |
3508 | +import netsvc |
3509 | +import pooler |
3510 | +import time |
3511 | +import re |
3512 | + |
3513 | +class check(osv.osv): |
3514 | + |
3515 | + """ Cheque """ |
3516 | + _name = 'check.check' |
3517 | + |
3518 | + def get_id(self, cr, uid, sequence_id, test='id', context=None): |
3519 | + """ |
3520 | + Function to find next sequence number |
3521 | + """ |
3522 | + seq_pool = self.pool.get('ir.sequence') |
3523 | + assert test in ('code', 'id') |
3524 | + company_id = self.pool.get('res.users').read(cr, uid, uid, ['company_id'], context=context)['company_id'][0] or None |
3525 | + cr.execute('''SELECT id, number_next, prefix, suffix, padding |
3526 | + FROM ir_sequence |
3527 | + WHERE %s=%%s |
3528 | + AND active=true |
3529 | + AND (company_id = %%s or company_id is NULL) |
3530 | + ORDER BY company_id, id |
3531 | + FOR UPDATE NOWAIT''' % test, |
3532 | + (sequence_id, company_id)) |
3533 | + res = cr.dictfetchone() |
3534 | + if res: |
3535 | + if res['number_next']: |
3536 | + return (seq_pool._process(res['prefix']) + '%%0%sd' % res['padding'] % res['number_next'] + seq_pool._process(res['suffix']), |
3537 | + res['number_next']) |
3538 | + else: |
3539 | + return (seq_pool._process(res['prefix']) + seq_pool._process(res['suffix']), 0) |
3540 | + return False |
3541 | + |
3542 | + def _get_nxt_no(self, cr, uid, context=None): |
3543 | + """ |
3544 | + Function to find next sequence number and update sequence |
3545 | + """ |
3546 | + if context is None: |
3547 | + context = {} |
3548 | + if 'active_id' in context: |
3549 | + voucher_id = self.pool.get('account.voucher').browse(cr, uid, context['active_id'], context=context) |
3550 | + if not voucher_id.journal_id.check_sequence: |
3551 | + raise osv.except_osv(_('Warning!'), _('Please add "Check Sequence" for journal %s.'%str(voucher_id.journal_id.name))) |
3552 | + res = self.get_id(cr, uid, voucher_id.journal_id.check_sequence.id, test='id', context=context) |
3553 | + return res and res[0] |
3554 | + else: |
3555 | + return False |
3556 | + |
3557 | + def _get_new_no(self, cr, uid, context=None): |
3558 | + """ |
3559 | + Function to get the next number used to generate sequence |
3560 | + """ |
3561 | + if context is None: |
3562 | + context = {} |
3563 | + res = [] |
3564 | + if 'active_id' in context: |
3565 | + voucher_id = self.pool.get('account.voucher').browse(cr, uid, context['active_id'], context=context) |
3566 | + res = self.get_id(cr, uid, voucher_id.journal_id.check_sequence.id , test='id', context=context) |
3567 | + #print res |
3568 | + return res and res[1] |
3569 | + |
3570 | + def onchange_check_number(self, cr, uid, ids, journal, context=None): |
3571 | + journal_id = self.pool.get('account.journal').browse(cr, uid, journal, context=context) |
3572 | + result={} |
3573 | + res={} |
3574 | + context={} |
3575 | + warning = {} |
3576 | + if not journal_id.check_sequence: |
3577 | + warning = { |
3578 | + 'title': _('Warning!'), |
3579 | + 'message': _('Please add "Check Sequence" for journal %s.'%str(journal_id.name)) |
3580 | + } |
3581 | + return {'warning':warning} |
3582 | + result=self.get_id(cr, uid, journal_id.check_sequence.id , test='id', context=context) |
3583 | + res['check_number']=result[0] |
3584 | + res['new_no']=result[0] |
3585 | + journal_id = self.pool.get('account.journal').browse(cr, uid, journal, context=context) |
3586 | + context.update({'journal_id':journal}) |
3587 | + return {'value': res} |
3588 | + |
3589 | + def default_get(self, cr, uid, fields_list, context=None): |
3590 | + """ |
3591 | + Returns default values for fields |
3592 | + @param fields_list: list of fields, for which default values are required to be read |
3593 | + @param context: context arguments, like lang, time zone |
3594 | + |
3595 | + @return: Returns a dict that contains default values for fields |
3596 | + """ |
3597 | + if context is None: |
3598 | + context = {} |
3599 | + journal_id=context.get('journal_id', False) |
3600 | + values={} |
3601 | + if journal_id: |
3602 | + partner_obj = self.pool.get('res.partner') |
3603 | + partner = partner_obj.browse(cr, uid, context['partner_id']) |
3604 | + values = super(check, self).default_get(cr, uid, fields_list, context=context) |
3605 | + values.update({ |
3606 | + 'amount':context['amount'], |
3607 | + 'journal_id':context['journal_id'], |
3608 | + 'supplier':context['partner_id'], |
3609 | + 'payee_name':partner.name, |
3610 | + 'amount_in_words':amount_to_words_es(context['amount']), |
3611 | + 'check_number':self._get_nxt_no(cr, uid, context), |
3612 | + 'new_no': self._get_new_no(cr, uid, context), |
3613 | + 'state':'draft', |
3614 | + 'ver_p':True, |
3615 | + |
3616 | + }) |
3617 | + else: |
3618 | + #journalo_id = self.pool.get('account.journal').browse(cr, uid, journal_id, context=context) |
3619 | + #nxt_no = self.pool.get('ir.sequence').read(cr, uid, journalo_id.check_sequence.id, ['number_next'], context=context)['number_next'] |
3620 | + #new_no=nxt_no+1 |
3621 | + #self.pool.get('ir.sequence').write(cr, uid, [journalo_id.check_sequence.id], {'number_next': new_no}, context=context) |
3622 | + values.update({ |
3623 | + 'amount_in_words': 'Cero con 00/100', |
3624 | + 'current_date': datetime.now(), |
3625 | + 'state': 'draft', |
3626 | + 'ver_p':False, |
3627 | + # 'new_no':nxt_no, |
3628 | + |
3629 | + }) |
3630 | + return values |
3631 | + |
3632 | + def onchange_partner(self,cr,uid,ids,partner_id,context=None): |
3633 | + result={} |
3634 | + partner_obj = self.pool.get('res.partner') |
3635 | + partner = partner_obj.browse(cr, uid, partner_id) |
3636 | + result['payee_name'] = partner.name |
3637 | + return {'value': result} |
3638 | + |
3639 | + def onchange_amount(self, cr, uid, ids, amount, context=None): |
3640 | + """ |
3641 | + Function to convert amount to words |
3642 | + """ |
3643 | + result = {} |
3644 | + |
3645 | + amount_in_words = amount_to_words_es(amount) |
3646 | + |
3647 | + result['amount_in_words'] = amount_in_words |
3648 | + |
3649 | + return {'value': result} |
3650 | + |
3651 | + def unlink(self, cr, uid, ids, context=None): |
3652 | + if context is None: |
3653 | + context = {} |
3654 | + checks = self.read(cr, uid, ids, ['state'], context=context) |
3655 | + unlink_ids = [] |
3656 | + for t in checks: |
3657 | + if t['state'] in ('draft'): |
3658 | + unlink_ids.append(t['id']) |
3659 | + else: |
3660 | + raise osv.except_osv(_('Invalid action !'), _('Cannot delete check(s) that are already printed!')) |
3661 | + osv.osv.unlink(self, cr, uid, unlink_ids, context=context) |
3662 | + return True |
3663 | + |
3664 | + _columns = { |
3665 | + 'supplier':fields.many2one('res.partner', 'Partner', change_default=1, required=True ), |
3666 | + 'journal_id': fields.many2one('account.journal', 'Journal',required=True), |
3667 | + 'check_number': fields.char('Check Number', size=32, help='check number',required=True), |
3668 | + 'payee_name': fields.char('Payee name', size=45, help='Used to indicate the payee name of check.', required=True), |
3669 | + 'current_date': fields.date('Current date', required=True), |
3670 | + 'amount': fields.float('Amount', digits=(2,2), required=True), |
3671 | + 'amount_in_words': fields.char(' ', size=70), |
3672 | + 'check_id': fields.many2one('account.voucher', 'Check Reference'), |
3673 | + 'state': fields.selection([ |
3674 | + ('draft', 'Draft'), |
3675 | + ('printed', 'Printed'), |
3676 | + ('canceled', 'Canceled'), |
3677 | + ('charged', 'Charged'), |
3678 | + ('lost', 'Lost'), |
3679 | + ('rejected', 'Rejected'), |
3680 | + ],"State", readonly=True,), |
3681 | + 'new_no': fields.integer('Update Check Number', help= 'Enter new check number here if you wish to update'), |
3682 | + 'ver_p':fields.boolean('Verificacion'), |
3683 | + } |
3684 | + _sql_constraints = [ |
3685 | + ('check_number_uniq', 'unique (check_number)','The check number must be unique !'), |
3686 | + ] |
3687 | + _defaults = { |
3688 | + 'amount_in_words': 'Cero con 00/100', |
3689 | + 'current_date': datetime.now(), |
3690 | + 'state': 'draft', |
3691 | + 'check_number':_get_nxt_no, |
3692 | + 'new_no': _get_new_no, |
3693 | + } |
3694 | + |
3695 | + def _check_number_check(self,cr,uid,ids): |
3696 | + res = True |
3697 | + for check in self.browse(cr, uid, ids): |
3698 | + cadena='(\d{6})' |
3699 | + ref = check.check_number |
3700 | + if check.check_number: |
3701 | + if re.match(cadena,ref): |
3702 | + res = True |
3703 | + else: |
3704 | + res = False |
3705 | + return res |
3706 | + |
3707 | + _constraints = [(_check_number_check,_('The number of check is incorrect, it must be of six digits XXXXXX, X is a number.'),['check_number',])] |
3708 | + |
3709 | + def action_canceled(self, cr, uid, ids, context=None): |
3710 | + if context is None: |
3711 | + context = {} |
3712 | + if not len(ids): |
3713 | + return False |
3714 | + self.write(cr, uid, ids, {'state': 'canceled'}) |
3715 | + wf_service = netsvc.LocalService("workflow") |
3716 | + for i in ids: |
3717 | + wf_service.trg_write(uid,'check.check', i, cr) |
3718 | + return True |
3719 | + |
3720 | + def action_charged(self, cr, uid, ids, context=None): |
3721 | + if context is None: |
3722 | + context = {} |
3723 | + if not len(ids): |
3724 | + return False |
3725 | + self.write(cr, uid, ids, {'state': 'charged'}) |
3726 | + wf_service = netsvc.LocalService("workflow") |
3727 | + for i in ids: |
3728 | + wf_service.trg_write(uid,'check.check', i, cr) |
3729 | + return True |
3730 | + |
3731 | + def action_lost(self, cr, uid, ids, context=None): |
3732 | + if context is None: |
3733 | + context = {} |
3734 | + if not len(ids): |
3735 | + return False |
3736 | + self.write(cr, uid, ids, {'state': 'lost'}) |
3737 | + wf_service = netsvc.LocalService("workflow") |
3738 | + for i in ids: |
3739 | + wf_service.trg_write(uid,'check.check', i, cr) |
3740 | + return True |
3741 | + |
3742 | + def action_rejected(self, cr, uid, ids, context=None): |
3743 | + if context is None: |
3744 | + context = {} |
3745 | + if not len(ids): |
3746 | + return False |
3747 | + self.write(cr, uid, ids, {'state': 'rejected'}) |
3748 | + wf_service = netsvc.LocalService("workflow") |
3749 | + for i in ids: |
3750 | + wf_service.trg_write(uid,'check.check', i, cr) |
3751 | + return True |
3752 | + |
3753 | + def action_printed(self, cr, uid, ids, context=None): |
3754 | + if context is None: |
3755 | + context = {} |
3756 | + self.write(cr, uid, ids, {'state': 'printed', 'date': time.strftime('%Y-%m-%d %H:%M:%S')}, context=context) |
3757 | +# self.write(cr, uid, ids, {}) |
3758 | +# self.write(cr, uid, ids, { 'state' : 'printed' }) |
3759 | +####################################################################################################### |
3760 | + #funciona cuando es sobre modulos base. |
3761 | +####################################################################################################### |
3762 | + |
3763 | +# for obj_inv in self.browse(cr, uid, ids, context=context): |
3764 | +# if obj_inv.ver_p == False: |
3765 | +# nxt_no = self.pool.get('ir.sequence').read(cr, uid, obj_inv.journal_id.check_sequence.id, ['number_next'], context=context)['number_next'] |
3766 | +# new_no=nxt_no+1 |
3767 | +# self.pool.get('ir.sequence').write(cr, uid, [ obj_inv.journal_id.check_sequence.id], {'number_next': new_no}, context=context) |
3768 | + |
3769 | +######################################################################################################## |
3770 | + ## funcion especifica para ecua_account |
3771 | +######################################################################################################## |
3772 | + for obj_inv in self.browse(cr, uid, ids, context=context): |
3773 | + nxt_no = self.pool.get('ir.sequence').read(cr, uid, obj_inv.journal_id.check_sequence.id, ['number_next'], context=context)['number_next'] |
3774 | + new_no=nxt_no+1 |
3775 | + self.pool.get('ir.sequence').write(cr, uid, [ obj_inv.journal_id.check_sequence.id], {'number_next': new_no}, context=context) |
3776 | + |
3777 | + return True |
3778 | + |
3779 | + def imprimir(self, cr, uid, ids, context=None): |
3780 | + self.action_printed(cr, uid, ids, context=context) |
3781 | + return { |
3782 | + 'type': 'ir.actions.report.xml', |
3783 | + 'report_name': 'check_report', # the 'Service Name' from the report |
3784 | + 'datas' : { |
3785 | + 'model' : 'check.check', # Report Model |
3786 | + 'res_ids' : ids |
3787 | + } |
3788 | + } |
3789 | + |
3790 | + def reprint(self, cr, uid, ids, context=None): |
3791 | + |
3792 | + return { |
3793 | + 'type': 'ir.actions.report.xml', |
3794 | + 'report_name': 'check_report', # the 'Service Name' from the report |
3795 | + 'datas' : { |
3796 | + 'model' : 'check.check', # Report Model |
3797 | + 'res_ids' : ids |
3798 | + } |
3799 | + } |
3800 | + |
3801 | +check() |
3802 | |
3803 | === added file 'trescloud_cheques/trescloud_cheques_view.xml' |
3804 | --- trescloud_cheques/trescloud_cheques_view.xml 1970-01-01 00:00:00 +0000 |
3805 | +++ trescloud_cheques/trescloud_cheques_view.xml 2013-05-03 13:54:27 +0000 |
3806 | @@ -0,0 +1,94 @@ |
3807 | +<?xml version="1.0" encoding="utf-8"?> |
3808 | +<openerp> |
3809 | + <data> |
3810 | + |
3811 | + <!-- VISTA --> |
3812 | + <record model="ir.ui.view" id="view_ckeck_form"> |
3813 | + <field name="name">view.check.form</field> |
3814 | + <field name="model">check.check</field> |
3815 | + <field name="type">form</field> |
3816 | + <field name="arch" type="xml"> |
3817 | + <form string="Manage checks"> |
3818 | + <group col="2" colspan="2"> |
3819 | + <separator colspan="2"></separator> |
3820 | + <field name="supplier" on_change="onchange_partner(supplier)" attrs="{'readonly':[('state','!=','draft')]}"/> |
3821 | + <field name="check_number" attrs="{'readonly':[('state','!=','draft')]}"/> |
3822 | + <field name="amount" on_change="onchange_amount(amount)" attrs="{'readonly':[('state','!=','draft')]}"/> |
3823 | + <field name="payee_name" attrs="{'readonly':[('state','!=','draft')]}"/> |
3824 | + </group> |
3825 | + <group col="2" colspan="2"> |
3826 | + <separator colspan="2"></separator> |
3827 | + <field name="journal_id" on_change="onchange_check_number(journal_id)" attrs="{'readonly':[('state','!=','draft')]}"/> |
3828 | + <field name="current_date" attrs="{'readonly':[('state','!=','draft')]}"/> |
3829 | + <newline/> |
3830 | + <field name="amount_in_words" nolabel="1" colspan="2"/> |
3831 | + </group> |
3832 | + <group col="8" colspan="8"> |
3833 | + <separator colspan="7"></separator> |
3834 | + <field name="state"/> |
3835 | + <button name="check_draft_to_printed" string="Print" type="workflow" states="draft" icon="gtk-print"/> |
3836 | + <button name="reprint" string="Reprint" type="object" states="printed" icon="gtk-print"/> |
3837 | + <button name="action_charged" string="Charged" type="object" states="printed" icon="terp-dolar"/> |
3838 | + <button name="action_rejected" string="Rejected" type="object" states="printed" icon="terp-dolar_ok!"/> |
3839 | + <button name="action_canceled" string="Canceled" states="printed" icon="gtk-cancel" type="object"/> |
3840 | + <button name="action_lost" string="Lost" type="object" states="printed" icon="terp-gtk-media-pause"/> |
3841 | + </group> |
3842 | + </form> |
3843 | + </field> |
3844 | + </record> |
3845 | + |
3846 | + <record id="check_check_view_filter" model="ir.ui.view"> |
3847 | + <field name="name">check.check.select</field> |
3848 | + <field name="model">check.check</field> |
3849 | + <field name="type">search</field> |
3850 | + <field name="arch" type="xml"> |
3851 | + <search string="Search Check"> |
3852 | + <group col="10" colspan="4"> |
3853 | + <filter name="draft" icon="terp-document-new" string="Draft" domain="[('state','=','draft')]" help="Draft Checks"/> |
3854 | + <filter name="printed" icon="gtk-print" string="Printed" domain="[('state','=','printed')]" help="Printed Checks"/> |
3855 | + <filter name="charged" icon="terp-dolar" string="Charged" domain="[('state','=','charged')]" help="Charged Checks"/> |
3856 | + <filter name="rejected" icon="terp-dolar_ok!" string="Rejected" domain="[('state','=','rejected')]" help="Reject Checks"/> |
3857 | + <filter name="canceled" icon="gtk-cancel" string="Canceled" domain="[('state','=','canceled')]" help="Canceled Checks"/> |
3858 | + <filter name="lost" icon="terp-gtk-media-pause" string="Lost" domain="[('state','=','lost')]" help="Lost Checks"/> |
3859 | + <separator orientation="vertical"/> |
3860 | + <field name="supplier"/> |
3861 | + <field name="check_number"/> |
3862 | + </group> |
3863 | + </search> |
3864 | + </field> |
3865 | + </record> |
3866 | + |
3867 | + <record model="ir.ui.view" id="view_check_tree"> |
3868 | + <field name="name">view.check.tree</field> |
3869 | + <field name="model">check.check</field> |
3870 | + <field name="type">tree</field> |
3871 | + <field name="arch" type="xml"> |
3872 | + <tree string="Vouchers"> |
3873 | + <field name="current_date"/> |
3874 | + <field name="supplier"/> |
3875 | + <field name="journal_id"/> |
3876 | + <field name="check_number"/> |
3877 | + <field name="amount"/> |
3878 | + <field name="state"/> |
3879 | + </tree> |
3880 | + </field> |
3881 | + </record> |
3882 | + |
3883 | + <!-- ACCION --> |
3884 | + <record model="ir.actions.act_window" id="action_view_check"> |
3885 | + <field name="name">Cheques</field> |
3886 | + <field name="type">ir.actions.act_window</field> |
3887 | + <field name="res_model">check.check</field> |
3888 | + <field name="view_type">form</field> |
3889 | + <field name="view_mode">tree,form</field> |
3890 | + <field name="view_id" ref="view_check_tree"/> |
3891 | + <field name="search_view_id" ref="check_check_view_filter"/> |
3892 | + <field name="help">With this module you can create and print new checks. You can also track the status of the check (like cancelled, charged, lost or rejected). |
3893 | +It is related to vendor payments module and must have a journal configured as a check journal.</field> |
3894 | + </record> |
3895 | + |
3896 | + <!-- MENU --> |
3897 | + <menuitem id="submenu_check" name="Cheques" action="action_view_check" parent="account.menu_finance_payables"/> |
3898 | + |
3899 | + </data> |
3900 | +</openerp> |
3901 | \ No newline at end of file |
3902 | |
3903 | === added directory 'trescloud_cheques/workflow' |
3904 | === added file 'trescloud_cheques/workflow/check_wkf.xml' |
3905 | --- trescloud_cheques/workflow/check_wkf.xml 1970-01-01 00:00:00 +0000 |
3906 | +++ trescloud_cheques/workflow/check_wkf.xml 2013-05-03 13:54:27 +0000 |
3907 | @@ -0,0 +1,105 @@ |
3908 | +<?xml version="1.0" ?> |
3909 | +<openerp> |
3910 | + <data> |
3911 | + <record id="workflow_workflowchecks0" model="workflow"> |
3912 | + <field eval="1" name="on_create"/> |
3913 | + <field name="name">workflow_checks</field> |
3914 | + <field name="osv">check.check</field> |
3915 | + </record> |
3916 | + |
3917 | + <record id="workflow_activity_draft0" model="workflow.activity"> |
3918 | + <field name="kind">function</field> |
3919 | + <field name="name">Draft</field> |
3920 | + <field name="join_mode">XOR</field> |
3921 | + <field model="workflow" name="wkf_id" search="[('name', '=', u'workflow_checks')]"/> |
3922 | + <field eval="0" name="flow_stop"/> |
3923 | + <field name="split_mode">XOR</field> |
3924 | + <field name="action">write({'state':'draft'})</field> |
3925 | + <field eval="1" name="flow_start"/> |
3926 | + </record> |
3927 | + <record id="workflow_activity_printed0" model="workflow.activity"> |
3928 | + <field name="kind">function</field> |
3929 | + <field name="name">Printed</field> |
3930 | + <field name="join_mode">XOR</field> |
3931 | + <field model="workflow" name="wkf_id" search="[('name', '=', u'workflow_checks')]"/> |
3932 | + <field eval="0" name="flow_stop"/> |
3933 | + <field name="split_mode">XOR</field> |
3934 | + <!-- <field name="action">write({'state':'printed'})</field>--> |
3935 | + <field name="action">action_printed()</field> |
3936 | + <field eval="0" name="flow_start"/> |
3937 | + </record> |
3938 | + <record id="workflow_activity_canceled0" model="workflow.activity"> |
3939 | + <field name="kind">function</field> |
3940 | + <field name="name">Canceled</field> |
3941 | + <field name="join_mode">XOR</field> |
3942 | + <field model="workflow" name="wkf_id" search="[('name', '=', u'workflow_checks')]"/> |
3943 | + <field eval="1" name="flow_stop"/> |
3944 | + <field name="split_mode">XOR</field> |
3945 | + <field name="action">action_canceled()</field> |
3946 | + <field eval="0" name="flow_start"/> |
3947 | + </record> |
3948 | + <record id="workflow_activity_charged0" model="workflow.activity"> |
3949 | + <field name="kind">function</field> |
3950 | + <field name="name">Charged</field> |
3951 | + <field name="join_mode">XOR</field> |
3952 | + <field model="workflow" name="wkf_id" search="[('name', '=', u'workflow_checks')]"/> |
3953 | + <field eval="1" name="flow_stop"/> |
3954 | + <field name="split_mode">XOR</field> |
3955 | + <field name="action">write({'state':'charged'})</field> |
3956 | + <field eval="0" name="flow_start"/> |
3957 | + </record> |
3958 | + <record id="workflow_activity_lost0" model="workflow.activity"> |
3959 | + <field name="kind">function</field> |
3960 | + <field name="name">Lost</field> |
3961 | + <field name="join_mode">XOR</field> |
3962 | + <field model="workflow" name="wkf_id" search="[('name', '=', u'workflow_checks')]"/> |
3963 | + <field eval="1" name="flow_stop"/> |
3964 | + <field name="split_mode">XOR</field> |
3965 | + <field name="action">write({'state':'lost'})</field> |
3966 | + <field eval="0" name="flow_start"/> |
3967 | + </record> |
3968 | + <record id="workflow_activity_rejected0" model="workflow.activity"> |
3969 | + <field name="kind">function</field> |
3970 | + <field name="name">Rejected</field> |
3971 | + <field name="join_mode">XOR</field> |
3972 | + <field model="workflow" name="wkf_id" search="[('name', '=', u'workflow_checks')]"/> |
3973 | + <field eval="1" name="flow_stop"/> |
3974 | + <field name="split_mode">XOR</field> |
3975 | + <field name="action">write({'state':'rejected'})</field> |
3976 | + <field eval="0" name="flow_start"/> |
3977 | + </record> |
3978 | + </data> |
3979 | + |
3980 | + <data> |
3981 | + <record id="workflow_transition_2" model="workflow.transition"> |
3982 | + <field name="signal">check_draft_to_printed</field> |
3983 | + <field model="workflow.activity" name="act_from" search="[('name', '=', u'Draft')]"/> |
3984 | + <field model="workflow.activity" name="act_to" search="[('name', '=', u'Printed')]"/> |
3985 | + <field name="condition">True</field> |
3986 | + </record> |
3987 | + <record id="workflow_transition_0" model="workflow.transition"> |
3988 | + <field name="signal">check_printed_to_canceled</field> |
3989 | + <field model="workflow.activity" name="act_from" search="[('name', '=', u'Printed')]"/> |
3990 | + <field model="workflow.activity" name="act_to" search="[('name', '=', u'Canceled')]"/> |
3991 | + <field name="condition">True</field> |
3992 | + </record> |
3993 | + <record id="workflow_transition_1" model="workflow.transition"> |
3994 | + <field name="signal">check_printed_to_charged</field> |
3995 | + <field model="workflow.activity" name="act_from" search="[('name', '=', u'Printed')]"/> |
3996 | + <field model="workflow.activity" name="act_to" search="[('name', '=', u'Charged')]"/> |
3997 | + <field name="condition">True</field> |
3998 | + </record> |
3999 | + <record id="workflow_transition_3" model="workflow.transition"> |
4000 | + <field name="signal">check_printed_to_lost</field> |
4001 | + <field model="workflow.activity" name="act_from" search="[('name', '=', u'Printed')]"/> |
4002 | + <field model="workflow.activity" name="act_to" search="[('name', '=', u'Lost')]"/> |
4003 | + <field name="condition">True</field> |
4004 | + </record> |
4005 | + <record id="workflow_transition_6" model="workflow.transition"> |
4006 | + <field name="signal">check_printed_to_rejected</field> |
4007 | + <field model="workflow.activity" name="act_from" search="[('name', '=', u'Printed')]"/> |
4008 | + <field model="workflow.activity" name="act_to" search="[('name', '=', u'Rejected')]"/> |
4009 | + <field name="condition">True</field> |
4010 | + </record> |
4011 | + </data> |
4012 | +</openerp> |
4013 | \ No newline at end of file |
4014 | |
4015 | === added directory 'trescloud_voucher_lote' |
4016 | === added file 'trescloud_voucher_lote/__init__.py' |
4017 | --- trescloud_voucher_lote/__init__.py 1970-01-01 00:00:00 +0000 |
4018 | +++ trescloud_voucher_lote/__init__.py 2013-05-03 13:54:27 +0000 |
4019 | @@ -0,0 +1,26 @@ |
4020 | + |
4021 | +# -*- encoding: utf-8 -*- |
4022 | +######################################################################## |
4023 | +# |
4024 | +# @authors: Patricio Rangles |
4025 | +# Copyright (C) 2012 TRESCLOUD CIA. LTDA. |
4026 | +# |
4027 | +#This program is free software: you can redistribute it and/or modify |
4028 | +#it under the terms of the GNU General Public License as published by |
4029 | +#the Free Software Foundation, either version 3 of the License, or |
4030 | +#(at your option) any later version. |
4031 | +# |
4032 | +# This module is GPLv3 or newer and incompatible |
4033 | +# with OpenERP SA "AGPL + Private Use License"! |
4034 | +# |
4035 | +#This program is distributed in the hope that it will be useful, |
4036 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
4037 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
4038 | +#GNU General Public License for more details. |
4039 | +# |
4040 | +#You should have received a copy of the GNU General Public License |
4041 | +#along with this program. If not, see http://www.gnu.org/licenses. |
4042 | +######################################################################## |
4043 | +import trescloud_voucher_lote |
4044 | + |
4045 | + |
4046 | |
4047 | === added file 'trescloud_voucher_lote/__openerp__.py' |
4048 | --- trescloud_voucher_lote/__openerp__.py 1970-01-01 00:00:00 +0000 |
4049 | +++ trescloud_voucher_lote/__openerp__.py 2013-05-03 13:54:27 +0000 |
4050 | @@ -0,0 +1,42 @@ |
4051 | +# -*- encoding: utf-8 -*- |
4052 | +######################################################################## |
4053 | +# |
4054 | +# @authors: Patricio Rangles |
4055 | +# Copyright (C) 2012 TRESCloud Cia. Ltda. |
4056 | +# |
4057 | +#This program is free software: you can redistribute it and/or modify |
4058 | +#it under the terms of the GNU General Public License as published by |
4059 | +#the Free Software Foundation, either version 3 of the License, or |
4060 | +#(at your option) any later version. |
4061 | +# |
4062 | +# This module is GPLv3 or newer and incompatible |
4063 | +# with OpenERP SA "AGPL + Private Use License"! |
4064 | +# |
4065 | +#This program is distributed in the hope that it will be useful, |
4066 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
4067 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
4068 | +#GNU General Public License for more details. |
4069 | +# |
4070 | +#You should have received a copy of the GNU General Public License |
4071 | +#along with this program. If not, see http://www.gnu.org/licenses. |
4072 | +######################################################################## |
4073 | +{ |
4074 | + "name" : "Registro del Numero de Lote de Vouchers", |
4075 | + "version" : "1.0", |
4076 | + "author" : "Patricio Rangles", |
4077 | + "website": "http://www.trescloud.com", |
4078 | + "category" : "Lote de Vouchers", |
4079 | + "description": """Ingreso del numero de lote para los vouchers que son cobrados a los clientes |
4080 | + Debe configurarse un diario (Journal) para cada institucion que emite la tarjeta con la cual se |
4081 | + efectua el pago""", |
4082 | + "depends": ['base','account_voucher'], |
4083 | + "init_xml": [], |
4084 | + "update_xml": [ |
4085 | + 'views/trescloud_voucher_lote_view.xml', |
4086 | + ], |
4087 | + "installable": True, |
4088 | + "active": False, |
4089 | +} |
4090 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
4091 | + |
4092 | + |
4093 | |
4094 | === added file 'trescloud_voucher_lote/trescloud_voucher_lote.py' |
4095 | --- trescloud_voucher_lote/trescloud_voucher_lote.py 1970-01-01 00:00:00 +0000 |
4096 | +++ trescloud_voucher_lote/trescloud_voucher_lote.py 2013-05-03 13:54:27 +0000 |
4097 | @@ -0,0 +1,63 @@ |
4098 | + |
4099 | +# -*- encoding: utf-8 -*- |
4100 | +######################################################################## |
4101 | +# |
4102 | +# @authors: Patricio Rangles |
4103 | +# Copyright (C) 2012 TRESCLOUD Cia Ltda. |
4104 | +# |
4105 | +#This program is free software: you can redistribute it and/or modify |
4106 | +#it under the terms of the GNU General Public License as published by |
4107 | +#the Free Software Foundation, either version 3 of the License, or |
4108 | +#(at your option) any later version. |
4109 | +# |
4110 | +# This module is GPLv3 or newer and incompatible |
4111 | +# with OpenERP SA "AGPL + Private Use License"! |
4112 | +# |
4113 | +#This program is distributed in the hope that it will be useful, |
4114 | +#but WITHOUT ANY WARRANTY; without even the implied warranty of |
4115 | +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
4116 | +#GNU General Public License for more details. |
4117 | +# |
4118 | +#You should have received a copy of the GNU General Public License |
4119 | +#along with this program. If not, see http://www.gnu.org/licenses. |
4120 | +######################################################################## |
4121 | + |
4122 | +from osv import osv |
4123 | +from osv import fields |
4124 | +#from tools.translate import _ |
4125 | + |
4126 | +class account_voucher(osv.osv): |
4127 | + |
4128 | + _inherit = 'account.voucher' |
4129 | + _name = 'account.voucher' |
4130 | + |
4131 | + _columns = { |
4132 | + 'reference': fields.char('No. Referencia', size=64, required=True, readonly=True, states={'draft':[('readonly',False)]}, help="Puede anotarse la siguiente informacion: No. de Deposito, No. de Voucher, otras referencias"), |
4133 | + } |
4134 | + |
4135 | + _defaults = { |
4136 | + 'reference': 'Efectivo', |
4137 | + } |
4138 | + |
4139 | +account_voucher() |
4140 | + |
4141 | + |
4142 | +#class account_journal(osv.osv): |
4143 | +# |
4144 | +# _inherit = 'account.journal' |
4145 | +# _name = 'account.journal' |
4146 | +# |
4147 | +# _columns = { |
4148 | +# 'imprimir_cheque': fields.boolean('Habilitar para generar la impresion de cheques desde egresos (Pagos)'), |
4149 | +# 'ingresar_voucher': fields.boolean('Habilitar para ingresar la informacion de vouchers desde ingresos (Cobros)'), |
4150 | +# } |
4151 | +# |
4152 | +# _defaults = { |
4153 | +# 'imprimir_cheque': False, |
4154 | +# 'ingresar_voucher': False, |
4155 | +# } |
4156 | +# |
4157 | +#account_journal() |
4158 | + |
4159 | + |
4160 | +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: |
4161 | \ No newline at end of file |
4162 | |
4163 | === added directory 'trescloud_voucher_lote/views' |
4164 | === added file 'trescloud_voucher_lote/views/trescloud_voucher_lote_view.xml' |
4165 | --- trescloud_voucher_lote/views/trescloud_voucher_lote_view.xml 1970-01-01 00:00:00 +0000 |
4166 | +++ trescloud_voucher_lote/views/trescloud_voucher_lote_view.xml 2013-05-03 13:54:27 +0000 |
4167 | @@ -0,0 +1,30 @@ |
4168 | +<?xml version="1.0" encoding="UTF-8"?> |
4169 | +<openerp> |
4170 | + <data> |
4171 | + |
4172 | + <record model="ir.ui.view" id="account_voucher_receipt_form_view"> |
4173 | + <field name="name">account.voucher.form</field> |
4174 | + <field name="model">account.voucher</field> |
4175 | + <field name="type">form</field> |
4176 | + <field name="inherit_id" ref="account_voucher.view_vendor_receipt_form"/> |
4177 | + <field name="arch" type="xml"> |
4178 | + <field name="reference" position="replace"> |
4179 | + <field name="reference" string="No. Referencia"/> |
4180 | + </field> |
4181 | + </field> |
4182 | + </record> |
4183 | + |
4184 | + <record id="account_voucher_receipt_search_view" model="ir.ui.view"> |
4185 | + <field name="name">account.voucher.customer_pay.search</field> |
4186 | + <field name="model">account.voucher</field> |
4187 | + <field name="type">search</field> |
4188 | + <field name="inherit_id" ref="account_voucher.view_voucher_filter_customer_pay"/> |
4189 | + <field name="arch" type="xml"> |
4190 | + <field name="reference" position="replace"> |
4191 | + <field name="reference" string="No. Referencia" /> |
4192 | + </field> |
4193 | + </field> |
4194 | + </record> |
4195 | + |
4196 | + </data> |
4197 | +</openerp> |
4198 | \ No newline at end of file |
Estimado Andres
Te recomendaria que si estas usando modulos de otros desarrollos, solo agregues la dependencia, ya que nuestra rama es de localización, a menos que esos modulos de Domsense sean personalizados para nuestra legislación, deberias agregar tambien tu participación en la modificación y mantenerlos de manera indenpendiente
Con respecto al contexto en las funciones de redondeo, nosotros la usamos con nuestra rama del openerp en la versión 6, para evitar problemas con los cálculos de decimales, te pido revises el repositorio en https:/ /bitbucket. org/cormaza/ openerp_ base, por favor has los cambios para que estas funciones de calculo sean usadas con este contexto