Merge lp:~julie-w/unifield-server/US-5902 into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 5454
Proposed branch: lp:~julie-w/unifield-server/US-5902
Merge into: lp:unifield-server
Diff against target: 194 lines (+113/-1)
7 files modified
bin/addons/msf_homere_interface/__openerp__.py (+1/-0)
bin/addons/msf_homere_interface/hr.py (+2/-0)
bin/addons/msf_homere_interface/hr_employee_activation_wizard.xml (+41/-0)
bin/addons/msf_homere_interface/wizard/__init__.py (+1/-0)
bin/addons/msf_homere_interface/wizard/hr_employee_activation.py (+52/-0)
bin/addons/msf_profile/i18n/fr_MF.po (+14/-1)
bin/addons/register_accounting/account.py (+2/-0)
To merge this branch: bzr merge lp:~julie-w/unifield-server/US-5902
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+370913@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/msf_homere_interface/__openerp__.py'
--- bin/addons/msf_homere_interface/__openerp__.py 2018-10-31 15:29:09 +0000
+++ bin/addons/msf_homere_interface/__openerp__.py 2019-08-02 15:10:27 +0000
@@ -34,6 +34,7 @@
34 'hr_view.xml',34 'hr_view.xml',
35 'hr_payroll_view.xml',35 'hr_payroll_view.xml',
36 'hr_payroll_wizard.xml',36 'hr_payroll_wizard.xml',
37 'hr_employee_activation_wizard.xml',
37 ],38 ],
38 "demo_xml" : [],39 "demo_xml" : [],
39 "test": [],40 "test": [],
4041
=== modified file 'bin/addons/msf_homere_interface/hr.py'
--- bin/addons/msf_homere_interface/hr.py 2019-04-08 14:33:50 +0000
+++ bin/addons/msf_homere_interface/hr.py 2019-08-02 15:10:27 +0000
@@ -256,6 +256,8 @@
256 """256 """
257 if not ids:257 if not ids:
258 return True258 return True
259 elif isinstance(ids, (int, long)):
260 ids = [ids]
259 # Some verifications261 # Some verifications
260 if not context:262 if not context:
261 context = {}263 context = {}
262264
=== added file 'bin/addons/msf_homere_interface/hr_employee_activation_wizard.xml'
--- bin/addons/msf_homere_interface/hr_employee_activation_wizard.xml 1970-01-01 00:00:00 +0000
+++ bin/addons/msf_homere_interface/hr_employee_activation_wizard.xml 2019-08-02 15:10:27 +0000
@@ -0,0 +1,41 @@
1<?xml version="1.0" encoding="UTF-8"?>
2<openerp>
3 <data>
4
5 <!-- Wizard -->
6 <record id="employee_activation_view" model="ir.ui.view">
7 <field name="name">Activate/Deactivate Employees</field>
8 <field name="model">hr.employee.activation</field>
9 <field name="type">form</field>
10 <field name="arch" type="xml">
11 <form string="Activate/Deactivate Employees">
12 <field name="active_status"/>
13 <button icon="gtk-cancel" string="Cancel" special="cancel"/>
14 <button icon="terp-camera_test" string="Approve" name="change_employee_status" type="object" default_focus="1"/>
15 </form>
16 </field>
17 </record>
18
19 <!-- Action in Menu -->
20 <record id="employee_activation_action" model="ir.actions.act_window">
21 <field name="name">Activate/Deactivate Employees</field>
22 <field name="type">ir.actions.act_window</field>
23 <field name="res_model">hr.employee.activation</field>
24 <field name="view_type">form</field>
25 <field name="view_mode">form</field>
26 <field name="view_id" ref="employee_activation_view"/>
27 <field name="target">new</field>
28 </record>
29 <record model="ir.values" id="employee_activation_values">
30 <field name="model_id" ref="model_hr_employee" />
31 <field name="object" eval="1" />
32 <field name="name">Activate/Deactivate Employees</field>
33 <field name="key2">client_action_multi</field>
34 <field name="value" eval="'ir.actions.act_window,' + str(ref('employee_activation_action'))" />
35 <field name="key">action</field>
36 <field name="model">hr.employee</field>
37 <field name="sequence" eval="105"/>
38 </record>
39
40 </data>
41</openerp>
042
=== modified file 'bin/addons/msf_homere_interface/wizard/__init__.py'
--- bin/addons/msf_homere_interface/wizard/__init__.py 2018-04-19 11:49:43 +0000
+++ bin/addons/msf_homere_interface/wizard/__init__.py 2019-08-02 15:10:27 +0000
@@ -29,5 +29,6 @@
29import hr_expat_import29import hr_expat_import
30import hr_nat_staff_import30import hr_nat_staff_import
31import hr_payment_order31import hr_payment_order
32import hr_employee_activation
3233
33# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:34# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
3435
=== added file 'bin/addons/msf_homere_interface/wizard/hr_employee_activation.py'
--- bin/addons/msf_homere_interface/wizard/hr_employee_activation.py 1970-01-01 00:00:00 +0000
+++ bin/addons/msf_homere_interface/wizard/hr_employee_activation.py 2019-08-02 15:10:27 +0000
@@ -0,0 +1,52 @@
1# -*- coding: utf-8 -*-
2##############################################################################
3#
4# OpenERP, Open Source Management Solution
5# Copyright (C) 2019 MSF, TeMPO Consulting
6#
7# This program is free software: you can redistribute it and/or modify
8# it under the terms of the GNU Affero General Public License as
9# published by the Free Software Foundation, either version 3 of the
10# License, or (at your option) any later version.
11#
12# This program is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15# GNU Affero General Public License for more details.
16#
17# You should have received a copy of the GNU Affero General Public License
18# along with this program. If not, see <http://www.gnu.org/licenses/>.
19#
20##############################################################################
21
22from osv import fields, osv
23
24
25class hr_employee_activation(osv.osv_memory):
26 _name = 'hr.employee.activation'
27
28 _columns = {
29 'active_status': fields.boolean('Set selected employees as active'),
30 }
31
32 _defaults = {
33 'active_status': True,
34 }
35
36 def change_employee_status(self, cr, uid, ids, context=None):
37 """
38 Sets the selected employees to active or inactive
39 """
40 if context is None:
41 context = {}
42 if isinstance(ids, (int, long)):
43 ids = [ids]
44 employee_obj = self.pool.get('hr.employee')
45 data = self.read(cr, uid, ids, ['active_status'], context=context)[0]
46 for employee_id in context.get('active_ids', []):
47 employee_obj.write(cr, uid, employee_id, {'active': data['active_status']}, context=context)
48 return {'type': 'ir.actions.act_window_close'}
49
50
51hr_employee_activation()
52# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
053
=== modified file 'bin/addons/msf_profile/i18n/fr_MF.po'
--- bin/addons/msf_profile/i18n/fr_MF.po 2019-07-31 14:57:17 +0000
+++ bin/addons/msf_profile/i18n/fr_MF.po 2019-08-02 15:10:27 +0000
@@ -40334,7 +40334,7 @@
40334msgid "Document date"40334msgid "Document date"
40335msgstr "Date du document"40335msgstr "Date du document"
4033640336
40337#. modules: msf_budget, res_currency_functional, account, register_accounting, finance40337#. modules: msf_budget, res_currency_functional, account, register_accounting, finance, msf_homere_interface
40338#: view:account.invoice:040338#: view:account.invoice:0
40339#: view:account.move:040339#: view:account.move:0
40340#: view:validate.account.move:040340#: view:validate.account.move:0
@@ -40343,6 +40343,7 @@
40343#: view:msf.budget:040343#: view:msf.budget:0
40344#: view:account.invoice:040344#: view:account.invoice:0
40345#: view:activate.currencies:040345#: view:activate.currencies:0
40346#: view:hr.employee.activation:0
40346msgid "Approve"40347msgid "Approve"
40347msgstr "Approuver"40348msgstr "Approuver"
4034840349
@@ -98178,6 +98179,7 @@
98178#: view:wizard.pick.import:098179#: view:wizard.pick.import:0
98179#: code:addons/msf_doc_import/purchase_order.py:6098180#: code:addons/msf_doc_import/purchase_order.py:60
98180#: view:wizard.import.product.line:098181#: view:wizard.import.product.line:0
98182#: view:hr.employee.activation:0
98181#: selection:export.report.stock.move,state:098183#: selection:export.report.stock.move,state:0
98182#, python-format98184#, python-format
98183msgid "Cancel"98185msgid "Cancel"
@@ -107760,3 +107762,14 @@
107760#: view:account.invoice:0107762#: view:account.invoice:0
107761msgid "This invoice will sync to its counterpart instance."107763msgid "This invoice will sync to its counterpart instance."
107762msgstr "Cette facture sera synchronisée à l'instance de Contrepartie."107764msgstr "Cette facture sera synchronisée à l'instance de Contrepartie."
107765
107766#. module: msf_homere_interface
107767#: view:hr.employee.activation:0
107768#: model:ir.actions.act_window,name:msf_homere_interface.employee_activation_action
107769msgid "Activate/Deactivate Employees"
107770msgstr "Activer / Désactiver les Employés"
107771
107772#. module: msf_homere_interface
107773#: field:hr.employee.activation,active_status:0
107774msgid "Set selected employees as active"
107775msgstr "Marquer les employés sélectionnés comme actifs"
107763107776
=== modified file 'bin/addons/register_accounting/account.py'
--- bin/addons/register_accounting/account.py 2016-08-18 08:32:03 +0000
+++ bin/addons/register_accounting/account.py 2019-08-02 15:10:27 +0000
@@ -67,6 +67,8 @@
67 def write(self, cr, uid, ids, vals, context=None):67 def write(self, cr, uid, ids, vals, context=None):
68 if not ids:68 if not ids:
69 return True69 return True
70 elif isinstance(ids, (int, long)):
71 ids = [ids]
70 if context is None:72 if context is None:
71 context = {}73 context = {}
7274

Subscribers

People subscribed via source and target branches