Merge lp:~mukunde/unifield-server/US-9724 into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 6383
Proposed branch: lp:~mukunde/unifield-server/US-9724
Merge into: lp:unifield-server
Diff against target: 96 lines (+52/-4) (has conflicts)
2 files modified
bin/addons/analytic_override/analytic_line.py (+19/-4)
bin/addons/msf_profile/i18n/fr_MF.po (+33/-0)
Text conflict in bin/addons/msf_profile/i18n/fr_MF.po
To merge this branch: bzr merge lp:~mukunde/unifield-server/US-9724
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+430438@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'bin/addons/analytic_override/analytic_line.py'
--- bin/addons/analytic_override/analytic_line.py 2022-01-05 15:03:32 +0000
+++ bin/addons/analytic_override/analytic_line.py 2022-09-26 07:25:14 +0000
@@ -170,7 +170,8 @@
170 # FIXME: refactoring of next code170 # FIXME: refactoring of next code
171 if document_date < account.date_start or (account.date != False and document_date >= account.date):171 if document_date < account.date_start or (account.date != False and document_date >= account.date):
172 if 'from' not in context or context.get('from') != 'mass_reallocation':172 if 'from' not in context or context.get('from') != 'mass_reallocation':
173 raise osv.except_osv(_('Error'), _("The analytic account selected '%s' is not active.") % (account.name or '',))173 entry_name = self.get_entry_name(cr, uid, vals, context=context)
174 raise osv.except_osv(_('Error'), _("The analytic account '%s' %s is not active.") % (account.name or '', entry_name))
174 if 'date' in vals and vals['date'] is not False:175 if 'date' in vals and vals['date'] is not False:
175 date = vals['date']176 date = vals['date']
176 dest = False177 dest = False
@@ -179,17 +180,31 @@
179 cc = account_obj.browse(cr, uid, vals['cost_center_id'], context=context)180 cc = account_obj.browse(cr, uid, vals['cost_center_id'], context=context)
180 if date < cc.date_start or (cc.date != False and date >= cc.date):181 if date < cc.date_start or (cc.date != False and date >= cc.date):
181 if 'from' not in context or context.get('from') != 'mass_reallocation':182 if 'from' not in context or context.get('from') != 'mass_reallocation':
182 raise osv.except_osv(_('Error'), _("The analytic account selected '%s' is not active.") % (cc.name or '',))183 # US-9724
184 entry_name = self.get_entry_name(cr, uid, vals, context=context)
185 raise osv.except_osv(_('Error'),_("The analytic account '%s' %s is inactive.") % (cc.name or '', entry_name))
183 if vals.get('destination_id', False):186 if vals.get('destination_id', False):
184 dest = account_obj.browse(cr, uid, vals['destination_id'], context=context)187 dest = account_obj.browse(cr, uid, vals['destination_id'], context=context)
185 if date < dest.date_start or (dest.date != False and date >= dest.date):188 if date < dest.date_start or (dest.date != False and date >= dest.date):
186 if 'from' not in context or context.get('from') != 'mass_reallocation':189 if 'from' not in context or context.get('from') != 'mass_reallocation':
187 raise osv.except_osv(_('Error'), _("The analytic account selected '%s' is not active.") % (dest.name or '',))190 entry_name = self.get_entry_name(cr, uid, vals, context=context)
191 raise osv.except_osv(_('Error'), _("The analytic account '%s' %s is not active.") % (dest.name or '', entry_name))
188 if context.get('from') != 'mass_reallocation' and dest and cc and \192 if context.get('from') != 'mass_reallocation' and dest and cc and \
189 dest_cc_link_obj.is_inactive_dcl(cr, uid, dest.id, cc.id, date, context=context):193 dest_cc_link_obj.is_inactive_dcl(cr, uid, dest.id, cc.id, date, context=context):
190 raise osv.except_osv(_('Error'), _("The combination \"%s - %s\" is not active.") % (dest.code or '', cc.code or ''))194 entry_name = self.get_entry_name(cr, uid, vals, context=context)
195 raise osv.except_osv(_('Error'), _("The combination \"%s - %s\" %s is not active.") % (dest.code or '', cc.code or '', entry_name))
191 return True196 return True
192197
198 def get_entry_name(self, cr, uid, vals, context):
199 """
200 Return the sequence entry name
201 """
202 acc_move_obj = self.pool.get('account.move.line')
203 if vals.get('move_id'):
204 name = acc_move_obj.browse(cr, uid, vals['move_id'], fields_to_fetch=['move_id'], context=context).move_id.name
205 return _(' selected in this entry %s ') % (name or '')
206 return ''
207
193 def _check_document_date(self, cr, uid, ids):208 def _check_document_date(self, cr, uid, ids):
194 """209 """
195 Check that document's date is done BEFORE posting date210 Check that document's date is done BEFORE posting date
196211
=== modified file 'bin/addons/msf_profile/i18n/fr_MF.po'
--- bin/addons/msf_profile/i18n/fr_MF.po 2022-08-23 13:15:58 +0000
+++ bin/addons/msf_profile/i18n/fr_MF.po 2022-09-26 07:25:14 +0000
@@ -114991,6 +114991,7 @@
114991#: field:sync.version.instance.monitor,platform:0114991#: field:sync.version.instance.monitor,platform:0
114992msgid "Platform"114992msgid "Platform"
114993msgstr "Plate-forme"114993msgstr "Plate-forme"
114994<<<<<<< TREE
114994114995
114995#. module: msf_doc_import114996#. module: msf_doc_import
114996#: code:addons/msf_doc_import/check_line.py:345114997#: code:addons/msf_doc_import/check_line.py:345
@@ -115817,3 +115818,35 @@
115817msgid "Force Date and time of next execution"115818msgid "Force Date and time of next execution"
115818msgstr "Date et heure forcée de la prochiane exécution plannifiée"115819msgstr "Date et heure forcée de la prochiane exécution plannifiée"
115819115820
115821=======
115822
115823#. module: analytic_override
115824#: code:addons/analytic_override/analytic_line.py:205
115825#, python-format
115826msgid " selected in this entry %s "
115827msgstr "selectionné dans cette entrée %s "
115828
115829#. module: analytic_override
115830#: code:addons/analytic_override/analytic_line.py:185
115831#, python-format
115832msgid "The analytic account '%s' %s is inactive."
115833msgstr "Le compte analytique '%s' %s n'est pas actif."
115834
115835#. module: analytic_override
115836#: code:addons/analytic_override/analytic_line.py:174
115837#: code:addons/analytic_override/analytic_line.py:191
115838#, python-format
115839msgid "The analytic account '%s' %s is not active."
115840msgstr "Le compte analytique '%s' %s n'est pas actif."
115841
115842#. module: analytic_override
115843#: code:addons/analytic_override/analytic_line.py:195
115844#, python-format
115845msgid "The combination \"%s - %s\" %s is not active."
115846msgstr "La combinaison \"%s - %s\" %s n'est pas active."
115847
115848#. module: analytic_override
115849#: model:ir.model,name:analytic_override.model_multiple_cc_selection_wizard
115850msgid "multiple.cc.selection.wizard"
115851msgstr ""
115852>>>>>>> MERGE-SOURCE

Subscribers

People subscribed via source and target branches