diff --git a/hr_recruitment_validations/__init__.py b/hr_recruitment_validations/__init__.py new file mode 100644 index 000000000..427d284cf --- /dev/null +++ b/hr_recruitment_validations/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2016-TODAY Cybrosys Technologies(). +# Author: Cybrosys Technologies() +# you can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL v3), Version 3. +# +# It is forbidden to publish, distribute, sublicense, or sell copies +# of the Software or modified copies of the Software. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +import models diff --git a/hr_recruitment_validations/__manifest__.py b/hr_recruitment_validations/__manifest__.py new file mode 100644 index 000000000..2662fb981 --- /dev/null +++ b/hr_recruitment_validations/__manifest__.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2016-TODAY Cybrosys Technologies(). +# Author: Cybrosys Technologies() +# you can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL v3), Version 3. +# +# It is forbidden to publish, distribute, sublicense, or sell copies +# of the Software or modified copies of the Software. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +{ + 'name': 'Advanced HR Recruitment', + 'version': '10.0.1.0.0', + 'summary': 'Creates validations In HR Recruitment Workflow' + '(Eg: An application stage cannot be moved to its previous one)', + 'description': """ Once Application stage is set as Contract signed then Users cannot change its value + """, + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'category': 'Human Resources', + 'website': 'https://www.cybrosys.com', + 'depends': [ + 'base', + 'hr_recruitment' + ], + 'data': ['views/hr_form_extend.xml'], + 'images': ['static/description/banner.jpg'], + 'installable': True, + 'license': 'LGPL-3', + 'installable': True, + 'auto_install': False, +} diff --git a/hr_recruitment_validations/models/__init__.py b/hr_recruitment_validations/models/__init__.py new file mode 100644 index 000000000..811755b32 --- /dev/null +++ b/hr_recruitment_validations/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2016-TODAY Cybrosys Technologies(). +# Author: Cybrosys Technologies() +# you can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL v3), Version 3. +# +# It is forbidden to publish, distribute, sublicense, or sell copies +# of the Software or modified copies of the Software. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +import hr_form_validations diff --git a/hr_recruitment_validations/models/hr_form_validations.py b/hr_recruitment_validations/models/hr_form_validations.py new file mode 100644 index 000000000..426dd10e3 --- /dev/null +++ b/hr_recruitment_validations/models/hr_form_validations.py @@ -0,0 +1,38 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2016-TODAY Cybrosys Technologies(). +# Author: Cybrosys Technologies() +# you can modify it under the terms of the GNU LESSER +# GENERAL PUBLIC LICENSE (LGPL v3), Version 3. +# +# It is forbidden to publish, distribute, sublicense, or sell copies +# of the Software or modified copies of the Software. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details. +# +# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from odoo import models, fields, api, _ +from odoo.exceptions import UserError + + +class AddValidationHr(models.Model): + _inherit = 'hr.applicant' + + stage_check = fields.Char(related='stage_id.name') + + @api.multi + def write(self, data): + res = super(AddValidationHr, self).write(data) + if data['stage_id'] and data['last_stage_id']: + if data['last_stage_id'] > data['stage_id']: + raise UserError(_("Invalid movement!!!")) + return res diff --git a/hr_recruitment_validations/static/description/banner.jpg b/hr_recruitment_validations/static/description/banner.jpg new file mode 100644 index 000000000..c9c925532 Binary files /dev/null and b/hr_recruitment_validations/static/description/banner.jpg differ diff --git a/hr_recruitment_validations/static/description/cybro_logo.png b/hr_recruitment_validations/static/description/cybro_logo.png new file mode 100644 index 000000000..bb309114c Binary files /dev/null and b/hr_recruitment_validations/static/description/cybro_logo.png differ diff --git a/hr_recruitment_validations/static/description/hr_recruitment.png b/hr_recruitment_validations/static/description/hr_recruitment.png new file mode 100644 index 000000000..57d51a3e7 Binary files /dev/null and b/hr_recruitment_validations/static/description/hr_recruitment.png differ diff --git a/hr_recruitment_validations/static/description/hr_recruitment_2.png b/hr_recruitment_validations/static/description/hr_recruitment_2.png new file mode 100644 index 000000000..d4bfa7708 Binary files /dev/null and b/hr_recruitment_validations/static/description/hr_recruitment_2.png differ diff --git a/hr_recruitment_validations/static/description/icon.png b/hr_recruitment_validations/static/description/icon.png new file mode 100644 index 000000000..b342dc883 Binary files /dev/null and b/hr_recruitment_validations/static/description/icon.png differ diff --git a/hr_recruitment_validations/static/description/index.html b/hr_recruitment_validations/static/description/index.html new file mode 100644 index 000000000..975684808 --- /dev/null +++ b/hr_recruitment_validations/static/description/index.html @@ -0,0 +1,78 @@ +
+
+

Advanced HR Recruitment

+

Creates validations In HR Recruitment Workflow

+

Author : Cybrosys Techno Solutions , www.cybrosys.com

+
+

Features:

+
    +
  •    Once application stage is set to contract signed, then changing the stage option is disabled.
  • +
  •    An applicant cannot be refused after contract is signed.
  • +
  •    An applicant cannot be moved to a previous stage.
  • +
+
+
+
+ +
+
+

Application Form

+
+
+
+ +
+
+
+

+ An application stage cannot be moved to its previous one +

+
+ +
+
+
+ +
+
+

Contract Signed Stage

+
+
+
+ +
+
+
+

+ Refuse Button and stage changing options are disabled +

+
+
+
+
+ +
+

Need Any Help?

+ +
diff --git a/hr_recruitment_validations/views/hr_form_extend.xml b/hr_recruitment_validations/views/hr_form_extend.xml new file mode 100644 index 000000000..b5afddeb7 --- /dev/null +++ b/hr_recruitment_validations/views/hr_form_extend.xml @@ -0,0 +1,24 @@ + + + + + Jobs - Recruitment Form + hr.applicant + + + + + + +