Compare commits
51 Commits
b7b23d636d
...
20c4782abe
| Author | SHA1 | Date |
|---|---|---|
|
|
20c4782abe | |
|
|
2a80971d7b | |
|
|
114c84a552 | |
|
|
33f9c4285e | |
|
|
9c84671527 | |
|
|
b9ff29e627 | |
|
|
e1d712226c | |
|
|
a4df233358 | |
|
|
4bf91af230 | |
|
|
f18af2dc00 | |
|
|
fc25478f83 | |
|
|
550026b7ce | |
|
|
cc6be3ddb1 | |
|
|
eb082fffdc | |
|
|
fa76843f3b | |
|
|
e8accc8a9e | |
|
|
aa7fab6b2a | |
|
|
2bb3be3619 | |
|
|
1e0d6b4e4f | |
|
|
7c0f2e99b4 | |
|
|
3454bd97cc | |
|
|
a790e43234 | |
|
|
f557f7eb6b | |
|
|
fe3bee0ed7 | |
|
|
a122669284 | |
|
|
91c3a6b9d6 | |
|
|
0356a370ad | |
|
|
203687b3cf | |
|
|
4243858519 | |
|
|
84c6194789 | |
|
|
cbfca65f8d | |
|
|
e323fdaca2 | |
|
|
f8ed7696bb | |
|
|
928be6b42f | |
|
|
de516a2f97 | |
|
|
159a22f9c7 | |
|
|
aefeac6120 | |
|
|
b1477681d1 | |
|
|
992759ba21 | |
|
|
b09c94c09d | |
|
|
d883935cb2 | |
|
|
376db29e4c | |
|
|
484e1ae32b | |
|
|
6bc48f018e | |
|
|
7777741428 | |
|
|
7733b6b0d1 | |
|
|
65dce43690 | |
|
|
f4e5b35713 | |
|
|
3c4548156f | |
|
|
70eb7fb338 | |
|
|
a8b3102f3c |
|
|
@ -45,7 +45,7 @@ class HrPayslipRun(models.Model):
|
|||
'attendance_days': attendance_days,
|
||||
'leave_days': leave_days,
|
||||
'lop_days': lop_days,
|
||||
'doj':employee.doj,
|
||||
'doj':contract.date_start,
|
||||
'birthday':employee.birthday,
|
||||
'bank': employee.bank_account_id.display_name if employee.bank_account_id else '-',
|
||||
'sick_leave_balance': leave_balances.get('LEAVE110', 0),
|
||||
|
|
|
|||
|
|
@ -18,8 +18,12 @@
|
|||
'version': '0.1',
|
||||
|
||||
# any module necessary for this one to work correctly
|
||||
|
||||
'depends': ['base','hr','account','mail','hr_skills', 'hr_contract'],
|
||||
|
||||
|
||||
|
||||
|
||||
# always loaded
|
||||
'data': [
|
||||
'security/security.xml',
|
||||
|
|
|
|||
|
|
@ -0,0 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import models
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
{
|
||||
'name': 'Human Resources',
|
||||
'version': '1.0',
|
||||
'summary': 'Human Resources all',
|
||||
'description': '''
|
||||
Human Resources of the module
|
||||
''',
|
||||
'category': 'Human Resources',
|
||||
'author': 'Raman Marikanti',
|
||||
'depends': ['base', 'mail',
|
||||
'hr_employee_extended','hr_contract','hr_payroll',
|
||||
'hr_attendance_extended','hr_payroll_holidays',
|
||||
'hr_recruitment_extended'],
|
||||
'data': [
|
||||
'security/ir.model.access.csv',
|
||||
'views/hr_views.xml',
|
||||
],
|
||||
'license': 'LGPL-3',
|
||||
'installable': True,
|
||||
'application': False,
|
||||
'auto_install': False,
|
||||
}
|
||||
|
|
@ -0,0 +1 @@
|
|||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||
|
|
|
@ -0,0 +1,97 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<menuitem name="Human Resources"
|
||||
id="hr_menu_root"/>
|
||||
<menuitem
|
||||
id="menu_hr_main"
|
||||
name="Employees"
|
||||
parent="hr_menu_root"
|
||||
sequence="0"/>
|
||||
<menuitem
|
||||
id="menu_hr_employee_user_hr"
|
||||
name="Employees"
|
||||
action="hr.open_view_employee_list_my"
|
||||
parent="menu_hr_main"
|
||||
sequence="1"/>
|
||||
|
||||
<menuitem
|
||||
id="hr_menu_all_contracts_hr"
|
||||
name="Contracts"
|
||||
action="hr_contract.action_hr_contract"
|
||||
parent="menu_hr_main"
|
||||
sequence="30"/>
|
||||
<menuitem
|
||||
id="hr_menu_salary_attachments_hr"
|
||||
name="Salary Attachments"
|
||||
action="hr_payroll.hr_salary_attachment_action"
|
||||
parent="menu_hr_main"
|
||||
sequence="35"/>
|
||||
|
||||
|
||||
<!-- ////////////////////////////////////////////////////////////////////////////// -->
|
||||
<menuitem
|
||||
id="menu_hr_pay"
|
||||
name="Payslips"
|
||||
parent="hr_menu_root"
|
||||
sequence="1"
|
||||
groups="hr_payroll.group_hr_payroll_user"/>
|
||||
|
||||
<menuitem
|
||||
id="menu_hr_payslip_run_hr"
|
||||
action="hr_payroll.action_hr_payslip_run_tree"
|
||||
name="Batches"
|
||||
sequence="2"
|
||||
parent="menu_hr_pay"/>
|
||||
|
||||
|
||||
<menuitem
|
||||
id="menu_hr_payroll_employee_payslips_hr"
|
||||
name="All Payslips"
|
||||
parent="menu_hr_pay"
|
||||
sequence="1"
|
||||
action="hr_payroll.action_view_hr_payslip_month_form"
|
||||
groups="hr_payroll.group_hr_payroll_user"/>
|
||||
<!-- ////////////////////////////////////////////////////////////////////////////// -->
|
||||
<menuitem
|
||||
id="menu_hr_attendance_hr"
|
||||
name="Work Management"
|
||||
parent="hr_menu_root"
|
||||
sequence="1"
|
||||
groups="hr_payroll.group_hr_payroll_user"/>
|
||||
|
||||
<menuitem
|
||||
id="menu_hr_attendance_view_attendances_hr"
|
||||
name="Attendance" parent="menu_hr_attendance_hr"
|
||||
sequence="5"
|
||||
groups="hr_attendance.group_hr_attendance_officer"
|
||||
action="hr_attendance.hr_attendance_action"/>
|
||||
|
||||
<menuitem
|
||||
id="menu_open_department_leave_approve_hr"
|
||||
name="Time Off"
|
||||
parent="menu_hr_attendance_hr"
|
||||
action="hr_holidays.hr_leave_action_action_approve_department"
|
||||
sequence="55"/>
|
||||
|
||||
<!-- ////////////////////////////////////////////////////////////////////////////// -->
|
||||
<menuitem
|
||||
name="Recruitment"
|
||||
id="menu_hr_recruitment_hr"
|
||||
parent="hr_menu_root"
|
||||
sequence="-1"/>
|
||||
|
||||
<menuitem
|
||||
name="Applications"
|
||||
parent="menu_hr_recruitment_hr"
|
||||
id="menu_hr_recruitment_applications_hr"
|
||||
action="hr_recruitment.crm_case_categ0_act_job"
|
||||
sequence="3"/>
|
||||
|
||||
<menuitem
|
||||
name="Candidates"
|
||||
parent="menu_hr_recruitment_hr"
|
||||
id="menu_hr_candidate_hr"
|
||||
action="hr_recruitment.action_hr_candidate"
|
||||
sequence="2"/>
|
||||
</odoo>
|
||||
|
|
@ -1381,7 +1381,10 @@ class HrPayslip(models.Model):
|
|||
|
||||
|
||||
def days_count(self):
|
||||
days = self.worked_days_line_ids.filtered(lambda x:x.work_entry_type_id.code == 'OUT').number_of_days
|
||||
joining_date = self.contract_id.date_start
|
||||
if not joining_date or joining_date == self.date_from:
|
||||
return 0
|
||||
date_from = min(joining_date, self.date_from)
|
||||
if joining_date > date_from:
|
||||
|
||||
|
|
@ -1400,7 +1403,7 @@ class HrPayslip(models.Model):
|
|||
weekend_days_count = weekend_count
|
||||
else:
|
||||
weekend_days_count = 0
|
||||
return weekend_days_count
|
||||
return weekend_days_count + days
|
||||
|
||||
def action_edit_payslip_lines(self):
|
||||
self.ensure_one()
|
||||
|
|
@ -1849,3 +1852,40 @@ class HrPayslip(models.Model):
|
|||
if 'stats' in sections:
|
||||
result['stats'] = self._get_dashboard_stats()
|
||||
return result
|
||||
|
||||
def get_leave_balance(self):
|
||||
employee = self.employee_id
|
||||
if not employee:
|
||||
return {'error': 'No employee linked to this user'}
|
||||
|
||||
leave_data = {}
|
||||
leave_types = self.env['hr.leave.type'].search([
|
||||
])
|
||||
if not leave_types:
|
||||
return []
|
||||
|
||||
for leave_type in leave_types:
|
||||
allocations = self.env['hr.leave.allocation'].search([
|
||||
('employee_id', '=', employee.id),
|
||||
('holiday_status_id', '=', leave_type.id),
|
||||
('state', '=', 'validate'),
|
||||
])
|
||||
taken_leaves = self.env['hr.leave'].search([
|
||||
('employee_id', '=', employee.id),
|
||||
('holiday_status_id', '=', leave_type.id),
|
||||
('state', 'in', ['validate','validate1','confirm']),
|
||||
])
|
||||
|
||||
total_allocated = sum(a.number_of_days for a in allocations)
|
||||
total_taken = sum(l.number_of_days for l in taken_leaves)
|
||||
remaining = total_allocated - total_taken
|
||||
if remaining <= 0:
|
||||
continue
|
||||
leave_data[leave_type.name] = {
|
||||
'name':leave_type.name,
|
||||
'allocated': total_allocated,
|
||||
'taken': total_taken,
|
||||
'remaining': remaining,
|
||||
}
|
||||
|
||||
return leave_data
|
||||
|
|
|
|||
|
|
@ -44,20 +44,21 @@
|
|||
<table style="width: 100%; border-collapse: collapse; font-size: 12px; margin-bottom: 10px;">
|
||||
<tr>
|
||||
<td style="border: 1px solid #ccc; padding: 6px;">
|
||||
<u><b>Pay Summary</b></u><br/><br/>
|
||||
<strong>Pay Period:</strong> <t style="padding: 6px;" t-esc="o.date_from"/> - <t t-esc="o.date_to"/><br/>
|
||||
<t t-set="days" t-value="(o.date_to - o.date_from).days + 1"/>
|
||||
<strong>Number of Days:</strong> <t style="padding: 6px;" t-esc="days"/> Days<br/>
|
||||
<strong>Worked Days:</strong> <t style="padding: 6px;" t-esc="days"/> Days
|
||||
</td>
|
||||
<t t-set="timeoff_data_table" t-value="o._get_employee_timeoff_data()"/>
|
||||
<td t-if="timeoff_data_table" style="border: 1px solid #ccc; padding: 6px;">
|
||||
<div t-foreach="timeoff_data_table" t-as="timeoff_data">
|
||||
<strong t-out="timeoff_data[0] + ':'"/>
|
||||
<t t-out="timeoff_data[1].get('remaining_leaves')"/> /
|
||||
<t t-out="timeoff_data[1].get('max_leaves')"/>
|
||||
<t t-if="timeoff_data[1].get('request_unit') == 'hour'">Hours</t>
|
||||
<t t-else="">Days</t>
|
||||
<t t-set="leave_data" t-value="o.get_leave_balance()"/>
|
||||
<td t-if="leave_data" style="border: 1px solid #ccc; padding: 6px;">
|
||||
<p><u><b>Leave Balance</b></u>
|
||||
<div t-foreach="leave_data.values()" t-as="data">
|
||||
<strong t-out="data['name'] + ':'"/>
|
||||
<t t-out="data['remaining']"/>
|
||||
Days
|
||||
</div>
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
|
@ -76,12 +77,16 @@
|
|||
<div t-foreach="o.line_ids.filtered(lambda l: l.appears_on_payslip and l.category_id.code in ['BASIC','SPA','ALW']and l.amount > 0)" t-as="l">
|
||||
<t t-esc="l.name"/><br/>
|
||||
</div>
|
||||
<br/>
|
||||
<strong>Total Income</strong>
|
||||
</td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;">
|
||||
<div t-foreach="o.line_ids.filtered(lambda l: l.appears_on_payslip and l.category_id.code in ['BASIC','SPA','ALW'] and l.amount > 0)" t-as="l">
|
||||
<t t-esc="l.amount"/><br/>
|
||||
<t t-esc="'%.2f' % l.amount"/><br/>
|
||||
<t t-set="income" t-value="income + l.amount"/>
|
||||
</div>
|
||||
<br/>
|
||||
<strong><t t-esc="'%.2f' % income"/></strong>
|
||||
</td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px;">
|
||||
<t t-set="contribution" t-value="0"/>
|
||||
|
|
@ -91,7 +96,7 @@
|
|||
</td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;">
|
||||
<div t-foreach="o.line_ids.filtered(lambda l: l.appears_on_payslip and l.category_id.code in ['COMP','MA'] and l.amount > 0)" t-as="l">
|
||||
<t t-esc="l.amount"/><br/>
|
||||
<t t-esc="'%.2f' % l.amount"/><br/>
|
||||
<t t-set="contribution" t-value="contribution + l.amount"/>
|
||||
</div>
|
||||
</td>
|
||||
|
|
@ -107,30 +112,33 @@
|
|||
</div>
|
||||
</td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;">
|
||||
<strong><t t-esc="contribution + income"/></strong><br/><br/><br/>
|
||||
<strong><t t-esc="'%.2f' % (contribution + income)"/></strong><br/><br/><br/>
|
||||
<div t-foreach="o.line_ids.filtered(lambda l: l.appears_on_payslip and l.category_id.code == 'DED')" t-as="l">
|
||||
<t t-esc="l.amount"/><br/>
|
||||
<t t-esc="'%.2f' % l.amount"/><br/>
|
||||
<t t-set="ded" t-value="ded + l.amount"/>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="border: 1px solid #ccc; padding: 6px;"><strong>Gross Salary</strong></td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;"><strong><t t-esc="income"/></strong></td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px;"><strong>Total Deduction</strong></td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;"><strong><t t-esc="ded"/></strong></td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px;" colspan="3"><strong>Gross Salary</strong></td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;" colspan="1"><strong><t t-esc="'%.2f' % income"/></strong></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="net-salary" colspan="3" style="border: 1px solid #ccc; padding: 6px;"><strong>Net Salary:</strong></td>
|
||||
<td class="net-salary" colspan="1" style="border: 1px solid #ccc; padding: 6px; text-align: right;">
|
||||
<t t-esc="(contribution + income) + ded"/>
|
||||
<td style="border: 1px solid #ccc; padding: 6px;" colspan="3"><strong>Total Deduction</strong></td>
|
||||
<td style="border: 1px solid #ccc; padding: 6px; text-align: right;" colspan="1"><strong><t t-esc="'%.2f' % ded"/></strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="net-salary" colspan="3" style="border: 1px solid #ccc; padding: 6px;font-size: 14px;"><strong>Net Salary:</strong></td>
|
||||
<td class="net-salary" colspan="1" style="border: 1px solid #ccc; padding: 6px; text-align: right;font-size: 14px;">
|
||||
<strong><t t-esc="'%.2f' % (income + ded)"/></strong>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<div class="to-pay" style="margin-top: 20px;">
|
||||
<p t-if="o.net_wage >= 0">
|
||||
To pay <strong><span t-esc="(contribution + income) + ded"/></strong> (<span style="padding-right: 5px;" t-esc="o.env.company.currency_id.amount_to_text((contribution + income) + ded) "/> only) to <i><span t-field="o.employee_id.legal_name"/></i> - <b><span t-field="o.employee_id.bank_account_id.bank_id.name"/> Account : <span t-field="o.employee_id.bank_account_id.acc_number">XXXXXXXXXXXX</span></b>
|
||||
To pay <strong><span t-esc="'%.2f' % (income + ded)"/></strong> (<span style="padding-right: 5px;" t-esc="o.env.company.currency_id.amount_to_text(income + ded)"/> only) to <i><span t-field="o.employee_id.legal_name"/></i> - <b><span t-field="o.employee_id.bank_account_id.bank_id.name"/> Account : <span t-field="o.employee_id.bank_account_id.acc_number">XXXXXXXXXXXX</span></b>
|
||||
|
||||
|
||||
</p>
|
||||
|
|
|
|||
|
|
@ -256,6 +256,8 @@ class HRJobRecruitment(models.Model):
|
|||
rec.submission_status = 'zero'
|
||||
|
||||
|
||||
experience = fields.Many2one('candidate.experience', string="Experience")
|
||||
|
||||
@api.depends('application_ids.submitted_to_client')
|
||||
def _compute_no_of_submissions(self):
|
||||
counts = dict(self.env['hr.applicant']._read_group(
|
||||
|
|
|
|||
|
|
@ -0,0 +1 @@
|
|||
from . import models
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
{
|
||||
'name': 'Offer Letters',
|
||||
'version': '1.0.0',
|
||||
'summary': 'Generate and manage employee offer letters',
|
||||
'description': """
|
||||
This module allows HR to create, manage and send offer letters to candidates
|
||||
with a modern React.js interface for enhanced user experience.
|
||||
""",
|
||||
'author': 'Raman Marikanti',
|
||||
'category': 'Human Resources',
|
||||
'depends': ['base', 'hr_recruitment','hr_payroll','hr_ftp'],
|
||||
'data': [
|
||||
'security/ir.model.access.csv',
|
||||
'views/offer_letter_views.xml',
|
||||
# 'views/templates.xml',
|
||||
'views/menu_views.xml',
|
||||
'report/offer_letter_report.xml',
|
||||
'report/offer_letter_template.xml',
|
||||
],
|
||||
'assets': {
|
||||
'web.assets_backend': [
|
||||
'offer_letters/static/src/js/pay_details_widget.js',
|
||||
],
|
||||
},
|
||||
|
||||
'demo': [],
|
||||
'installable': True,
|
||||
'application': True,
|
||||
'license': 'LGPL-3',
|
||||
}
|
||||
|
|
@ -0,0 +1 @@
|
|||
from . import offer_letter
|
||||
|
|
@ -0,0 +1,225 @@
|
|||
from odoo import models, fields, api, _
|
||||
from odoo.exceptions import UserError
|
||||
from collections import defaultdict
|
||||
from datetime import timedelta, datetime
|
||||
|
||||
from odoo.tools.safe_eval import safe_eval
|
||||
import json
|
||||
import calendar
|
||||
|
||||
class DefaultDictroll(defaultdict):
|
||||
def get(self, key, default=None):
|
||||
if key not in self and default is not None:
|
||||
self[key] = default
|
||||
return self[key]
|
||||
|
||||
class OfferLetter(models.Model):
|
||||
_name = 'offer.letter'
|
||||
_description = 'Employee Offer Letter'
|
||||
_inherit = ['mail.thread', 'mail.activity.mixin']
|
||||
_order = 'create_date desc'
|
||||
|
||||
name = fields.Char(
|
||||
string='Reference',
|
||||
required=True,
|
||||
default=lambda self: _('New'),
|
||||
copy=False
|
||||
)
|
||||
candidate_id = fields.Many2one( 'hr.applicant', string='Candidate', required=True,
|
||||
)
|
||||
|
||||
employee_id = fields.Char(
|
||||
string='Employee ID',
|
||||
readonly=True
|
||||
)
|
||||
position = fields.Char(
|
||||
string='Position',
|
||||
required=True
|
||||
)
|
||||
|
||||
salary = fields.Float(
|
||||
string='Salary',
|
||||
required=True
|
||||
)
|
||||
mi = fields.Float(
|
||||
string='Medical Insurance',
|
||||
)
|
||||
currency_id = fields.Many2one(
|
||||
'res.currency',
|
||||
string='Currency',
|
||||
default=lambda self: self.env.company.currency_id
|
||||
)
|
||||
joining_date = fields.Date(
|
||||
string='Joining Date',
|
||||
default=lambda self: (datetime.now() + timedelta(days=14)).strftime('%Y-%m-%d'))
|
||||
contract_type = fields.Selection([
|
||||
('permanent', 'Permanent'),
|
||||
('contract', 'Fixed Term Contract'),
|
||||
('intern', 'Internship')],
|
||||
string='Contract Type',
|
||||
default='permanent'
|
||||
)
|
||||
probation_period = fields.Integer(
|
||||
string='Probation Period (months)',
|
||||
default=3
|
||||
)
|
||||
terms_conditions = fields.Text(
|
||||
string='Terms and Conditions',
|
||||
default=lambda self: self._default_terms()
|
||||
)
|
||||
state = fields.Selection([
|
||||
('draft', 'Draft'),
|
||||
('sent', 'Sent'),
|
||||
('accepted', 'Accepted'),
|
||||
('rejected', 'Rejected'),
|
||||
('expired', 'Expired')],
|
||||
string='Status',
|
||||
default='draft',
|
||||
tracking=True
|
||||
)
|
||||
sent_date = fields.Datetime(string='Sent Date')
|
||||
response_date = fields.Datetime(string='Response Date')
|
||||
pay_struct_id = fields.Many2one('hr.payroll.structure', string="Salary Structure", required=True)
|
||||
manager_id = fields.Many2one('hr.employee', string='Manager')
|
||||
|
||||
|
||||
@api.model
|
||||
def _default_terms(self):
|
||||
return """
|
||||
<p>1. This offer is contingent upon satisfactory reference checks.</p>
|
||||
<p>2. You will be required to sign a confidentiality agreement.</p>
|
||||
<p>3. The company reserves the right to modify job responsibilities.</p>
|
||||
"""
|
||||
|
||||
@api.model
|
||||
def create(self, vals):
|
||||
if vals.get('name', _('New')) == _('New'):
|
||||
vals['name'] = self.env['ir.sequence'].next_by_code('offer.letter') or _('New')
|
||||
return super(OfferLetter, self).create(vals)
|
||||
|
||||
def action_send_offer(self):
|
||||
self.ensure_one()
|
||||
# template = self.env.ref('offer_letters.email_template_offer_letter')
|
||||
self.write({'state': 'sent', 'sent_date': fields.Datetime.now()})
|
||||
# template.send_mail(self.id, force_send=True)
|
||||
return True
|
||||
|
||||
def action_accept_offer(self):
|
||||
self.ensure_one()
|
||||
# employee = self.env['hr.employee'].create({
|
||||
# 'name': self.candidate_id.partner_name,
|
||||
# 'job_title': self.position,
|
||||
# 'department_id': self.department_id.id,
|
||||
# 'currency_id': self.currency_id.id,
|
||||
# })
|
||||
self.write({
|
||||
'state': 'accepted',
|
||||
# 'employee_id': employee,
|
||||
'response_date': fields.Datetime.now()
|
||||
})
|
||||
return True
|
||||
|
||||
def action_reject_offer(self):
|
||||
self.ensure_one()
|
||||
self.write({
|
||||
'state': 'rejected',
|
||||
'response_date': fields.Datetime.now()
|
||||
})
|
||||
return True
|
||||
|
||||
@api.onchange('candidate_id')
|
||||
def _onchange_candidate_id(self):
|
||||
self.position = self.candidate_id.job_id.name
|
||||
|
||||
def get_paydetailed_lines(self):
|
||||
today = fields.Date.today()
|
||||
first_day = today.replace(day=1)
|
||||
last_day = today.replace(day=calendar.monthrange(today.year, today.month)[1])
|
||||
|
||||
payslip = self.env['hr.payslip'].new({
|
||||
'date_from': first_day,
|
||||
'date_to': last_day,
|
||||
})
|
||||
|
||||
contract = self.env['hr.contract'].new({
|
||||
'date_start': first_day,
|
||||
'date_end': last_day,
|
||||
'l10n_in_medical_insurance':self.mi,
|
||||
'l10n_in_provident_fund': True,
|
||||
'name': 'test',
|
||||
'wage': self.salary / 12,
|
||||
})
|
||||
|
||||
categories_dict = {}
|
||||
rules_dict = {}
|
||||
result = {}
|
||||
|
||||
localdict = {
|
||||
'payslip': payslip,
|
||||
'contract': contract,
|
||||
'worked_days': {},
|
||||
'categories': defaultdict(lambda: 0), # Fixed: Changed DefaultDictroll to defaultdict
|
||||
'rules': defaultdict(lambda: dict(total=0, amount=0, quantity=0)),
|
||||
'result': None,
|
||||
'result_qty': 1.0,
|
||||
'result_rate': 100,
|
||||
'result_name': False,
|
||||
'inputs': {},
|
||||
}
|
||||
blacklisted_ids = set(self.env.context.get('prevent_payslip_computation_line_ids', []))
|
||||
for rule in sorted(self.pay_struct_id.rule_ids, key=lambda r: r.sequence):
|
||||
if rule.id in blacklisted_ids or not rule._satisfy_condition(localdict):
|
||||
continue
|
||||
qty = 1.0
|
||||
rate = 100.0
|
||||
amount = 0.0
|
||||
try:
|
||||
if rule.amount_select == 'fix':
|
||||
amount = rule.amount_fix
|
||||
elif rule.amount_select == 'percentage':
|
||||
base = float(safe_eval(rule.amount_percentage_base or '0.0', localdict, mode='exec', nocopy=True))
|
||||
amount = base * rule.amount_percentage / 100
|
||||
elif rule.amount_select == 'code':
|
||||
safe_eval(rule.amount_python_compute or '0.0', localdict, mode='exec', nocopy=True)
|
||||
amount = float(localdict.get('result', 0.0))
|
||||
except Exception as e:
|
||||
raise UserError(_("Error in rule %s: %s") % (rule.name, str(e)))
|
||||
|
||||
total = payslip._get_payslip_line_total(amount, qty, rate, rule)
|
||||
rule_code = rule.code
|
||||
previous_amount = localdict.get(rule.code, 0.0)
|
||||
category_code = rule.category_id.code
|
||||
tot_rule = payslip._get_payslip_line_total(amount, qty, rate, rule)
|
||||
|
||||
# Make sure _sum_salary_rule_category method exists
|
||||
if hasattr(rule.category_id, '_sum_salary_rule_category'):
|
||||
localdict = rule.category_id._sum_salary_rule_category(localdict, tot_rule - previous_amount)
|
||||
|
||||
localdict[rule_code] = total
|
||||
rules_dict[rule_code] = rule
|
||||
categories_dict[category_code] = categories_dict.get(category_code, 0.0) + amount
|
||||
|
||||
result[rule_code] = {
|
||||
'sequence': rule.sequence,
|
||||
'code': rule_code,
|
||||
'name': rule.name, # Simplified name retrieval
|
||||
'salary_rule_id': rule.id,
|
||||
'amount': round(amount,2),
|
||||
'y_amount': round((amount * 12),2),
|
||||
'quantity': qty,
|
||||
'rate': rate,
|
||||
'total': round(total,2),
|
||||
}
|
||||
|
||||
self.terms_conditions = json.dumps(list(result.values()))
|
||||
return {
|
||||
'type': 'ir.actions.act_window',
|
||||
'res_model': self._name,
|
||||
'res_id': self.id,
|
||||
'view_mode': 'form',
|
||||
'view_type': 'form',
|
||||
'target': 'current',
|
||||
}
|
||||
|
||||
def generate_pdf_report(self):
|
||||
return self.env.ref('offer_letters.hr_offer_letters_employee_print').report_action(self)
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<record id="hr_offer_letters_employee_print" model="ir.actions.report">
|
||||
<field name="name">Offer Letter</field>
|
||||
<field name="model">offer.letter</field>
|
||||
<field name="report_type">qweb-pdf</field>
|
||||
<field name="report_name">offer_letters.report_offer_letter</field>
|
||||
<field name="report_file">offer_letters.report_offer_letter</field>
|
||||
<field name="print_report_name">'Offer Letter - %s' % (object.name).replace('/', '')</field>
|
||||
<field name="binding_model_id" ref="model_offer_letter"/>
|
||||
<field name="binding_type">report</field>
|
||||
</record>
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,396 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<template id="external_layout_offer_letter">
|
||||
<!-- support for custom header -->
|
||||
<t t-set="company" t-value="env.company"/>
|
||||
<div t-attf-class="header pt-5">
|
||||
<span class="row">
|
||||
<img class="col-2" t-att-src="'/logo.png?company=%s' % company.id"
|
||||
style="padding: 0px; margin:0px; height: 100px; width: 100px;vertical-align: top"
|
||||
t-att-alt="'%s' % company.name"/>
|
||||
<h3 class="col-10"
|
||||
style="font-weight: bold;vertical-align: bottom;padding-top: 15px;font-family: 'Times New Roman', Times, serif; text-align:center">
|
||||
FAST TRACK PROJECTS PVT LTD.
|
||||
</h3>
|
||||
|
||||
</span>
|
||||
|
||||
</div>
|
||||
<main>
|
||||
<t t-out="0"/>
|
||||
</main>
|
||||
|
||||
<div t-attf-class="footer" style="padding-top:20px;font-size:14px">
|
||||
<p style="text-align:center">
|
||||
<strong>
|
||||
<span style="font-weight: bold" t-esc="env.company.name"/> - Unit of FAST TRACK PROJECTS PVT LTD.,
|
||||
<br/>
|
||||
Unit 302, Surya Arcade, Cyber Hills, Gachibowli, Hyderabad, 500032 Telangana INDIA
|
||||
<br/>
|
||||
Phone: +91 40 42601144 www.ftprotech.com | CIN: U45201TG2000PTC035652
|
||||
</strong>
|
||||
</p>
|
||||
</div>
|
||||
</template>
|
||||
<template id="report_offer_letter">
|
||||
<t t-foreach="docs" t-as="o">
|
||||
<t t-call="offer_letters.external_layout_offer_letter">
|
||||
<div class="page p-10" width="100%" height="100%">
|
||||
<table class="table" style="line-height:20px; font-size:14px;" width="100%">
|
||||
<tr width="100%">
|
||||
<td style="text-decoration: underline;padding-left:10px;color:blue;padding-top:15px">PRIVATE & CONFIDENTIAL</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-weight: bold"><t t-esc="o.name"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-weight: bold">To,</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><span style="font-weight: bold" t-esc="o.candidate_id.partner_name"/><br/>
|
||||
<div id="employee_private_address" t-if="o.candidate_id.private_street and o.candidate_id.private_city">
|
||||
<span t-field="o.candidate_id.private_street"/>,<br/>
|
||||
<span t-field="o.candidate_id.private_street2" t-if="o.candidate_id.private_street2" class="ms-2"/><span t-if="o.candidate_id.private_street2">,</span>
|
||||
<br/> <span t-field="o.candidate_id.private_city" class="ms-2"/>
|
||||
<span t-field="o.candidate_id.private_zip"/>
|
||||
<span t-field="o.candidate_id.private_country_id"/>
|
||||
</div>
|
||||
<br/><br/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-weight: bold;">Dear <span t-esc="o.candidate_id.partner_name"></span>,</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>We are pleased to extend you an offer to join <span style="font-weight: bold" t-esc="env.company.name"/> as a <span style="font-weight: bold" t-esc="o.position"/><br/>
|
||||
This letter will memorialize the terms of your employment by <span style="font-weight: bold" t-esc="env.company.name"/> Your employment is contingent on your ability to obtain employment eligibility documentation as required by law. However, if considered expedient and necessary, we may conduct background checks on you on our own or through a third party. You hereby consent to any such background checks and undertake to co-operate if so requested by us.
|
||||
We are excited and looking forward to your joining.<br/>The terms of your employment are as follows:<br/><br/>Start Date: You will have to report on or before <span style="font-weight: bold" t-esc="o.joining_date"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">1. Place Of Work: </span>Your assigned work location is Hyderabad. The Company may, after giving you reasonable notice, transfer or assign your services to any place of business of the Company that may presently be operating, or which may subsequently be acquired or established, in any part of India or abroad.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">2. Leave and Working Hours: </span>You will be entitled to leave as per company policy and will observe the working hours as may be applicable to your category of employees and location of posting.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
|
||||
<span style="font-weight: bold">3. Fulfillment Obligation: </span>Any cash bonuses or other expenses paid prior to normal salary periods are recoverable by the Company for the first 90 days of employment should you terminate your employment without cause.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
|
||||
<span style="font-weight: bold">4. Confidentiality and Invention Assignment: </span>Your employment is conditioned upon your execution of Confidentiality and Invention Assignment Agreements and agreement to abide by the terms and conditions of those Agreements. Failure to abide by the terms of the Agreements may result in your dismissal, and you are subject to their terms even after the termination of your employment.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">5. Transfer & Relocation: </span>You will be liable to transfer in such capacity as the company may from time to time determine to any other location, department, establishment, factory or branch of the company or its affiliate, associate or subsidiary companies. In such case, you will be governed by the terms and conditions of service applicable to the new assignment.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">6. Non-Compete: </span>You agree that during the term of your employment and for further period of 6 calendar months after separation from the Company, for whatever reasons, you shall not carry on or engage in directly or indirectly in any business which competes directly or indirectly with any or all the business pursued by the Company in any territory, whether in India or overseas, at the relevant point of time or proposed to be pursued by the Company in the immediate future, in respect of which proposal you were aware of or likely to be aware of considering the nature of your duties , other than through the Company.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">7. Non-Solicitation and Non Hire of Company Employees: </span>You agree that during the term of your employment and a further period of 24 (twenty four) calendar months after separation from the Company, for whatever reasons, you shall not either directly or indirectly solicit or entice away or endeavor to solicit or to entice away or assist any other Person to solicit or hire or entice away from the Company, any Company employee.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold;">8. Probation, Confirmation & Termination: </span>
|
||||
<br/> <span style="font-weight: bold;"> a) </span>You will be on probation for a period of180 Days from the date of your appointment, where after, post completion of 180 Days your service with the organization stands confirmed unless otherwise notified in writing through the HR team. The Company reserves the right to reduce or extend your probation period at its absolute discretion.
|
||||
<br/> <span style="font-weight: bold;"> b) </span>During the probation period/ extended period of probation or, <span style="font-weight: bold">company</span> shall be entitled to terminate your employment without cause at any time by giving <span style="font-weight: bold">you 30 calendar days' notice or salary in lieu thereof</span>. However, in case of cause, the Company can terminate your employment immediately. If you wish to terminate your employment with the Company during the probation period/ extended period of probation then you shall be required to serve 90 calendar days' notice period from the day next to resignation or salary in lieu thereof. During the notice period you shall not be entitled to any paid or unpaid leave and the notice period cannot be adjusted by any accrued leave. The decision to waive the notice period lies at the sole discretion of the Company.
|
||||
<br/> <span style="font-weight: bold;"> c) </span>No Leaves can be availed during your probation period expect for sick leave maximum of one per month.
|
||||
<br/> <span style="font-weight: bold;"> d) </span>Absence for a continuous period of six working days without prior approval of your superior, can lead to your services being terminated without notice or explanation.
|
||||
<br/> <span style="font-weight: bold;"> e) </span>No leave can be available during the notice period. Failure to complete the notice period will be considered equivalent to two times the shortfall in pay and the same will be adjusted as part of the full and final settlement.
|
||||
<br/> <span style="font-weight: bold;"> f) </span>Post probation confirmation, the <span style="font-weight: bold">company</span> shall be entitled to <span style="font-weight: bold">terminate your employment</span>, without cause, at any time by giving out <span style="font-weight: bold">30 days' notice </span> or salary in lieu thereof. You are also bound to provide the company with <span style="font-weight: bold">90 days' notice period </span> from the day next to resignation or salary in lieu thereof. During the notice period you shall not be entitled to any paid or unpaid leave and the notice period cannot be adjusted by any accrued leave. The decision to waive the notice period lies at the sole discretion of the Company.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">9. Confidentiality & Non-Complete and Non-Solicitation: </span>You certify not to share your salary or any company details along with not joining any competitor as an employee or contractor or solicit any employee from the company to join a company.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">10. Term: </span>The Company may terminate your employment for cause with immediate effect at any time. No salary or allowances will be paid for any period if you are terminated for cause.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">11. Salary: </span>Compensation of INR <span style="font-weight: bold"> <t t-esc="o.salary"/>/- p.a. only ( <t t-esc="env.company.currency_id.amount_to_text(o.salary)"/>). </span>.Refer to Annexure B
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">12. "Employee Agreement": </span>To protect the interests of the Company, you will need to sign the Company's standard Terms & Conditions of Employment (attached as annexure A), invention assignment agreement, <span style="font-weight: bold" t-esc="env.company.name"/>, Confidentiality Agreement and conflict of interest agreement (collectively, the "Employee Agreements") as a condition of your employment. You represent that your signing of this offer letter, and the Employee Agreements and your commencement of employment with the Company will not breach any agreement currently in place between yourself and current or past employers.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="100%">
|
||||
Please confirm that this letter sets forth the terms of your employment with the Company by countersigning a copy of this letter below. Your signature below indicates that you fully understand the terms of your employment with the Company and that you enter this Agreement knowingly and of your own accord.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<br/>
|
||||
<span style="font-weight: bold">Sincerely</span>
|
||||
<br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:100%">
|
||||
For<br/>
|
||||
Authorized Signatory
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold" t-esc="env.company.name"/>
|
||||
<span style="white-space: nowrap;float: right;" >Accepted and Agreed
|
||||
<br/><br/><br/><br/>
|
||||
</span>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold"><t t-esc="o.manager_id.name"/></span><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.candidate_id.partner_name"></span><br/>
|
||||
<span style="font-weight: bold"><t t-esc="o.manager_id.job_id.name"/></span><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.position"></span><br/>
|
||||
<span style="font-weight: bold" t-esc="o.joining_date"/><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.joining_date"/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table class="table" style="line-height:20px; font-size:14px;page-break-before: always !important;" width="100%">
|
||||
<tr>
|
||||
<td style="text-align:center;"> <span style="font-weight: bold;">Annexure - A</span><br/><br/><span style="font-weight: bold;">Terms & Conditions of Employment</span> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<br/>
|
||||
<span style="font-weight: bold">1. </span>During the term of your employment with <span style="font-weight: bold" t-esc="env.company.name"/> , you may not engage in any employment or act in any way, which either conflicts with your duties and obligations to <span style="font-weight: bold" t-esc="env.company.name"/>, or is contrary to the policies or the interests of <span style="font-weight: bold" t-esc="env.company.name"/>.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">2. </span>During the term of your employment with <span style="font-weight: bold" t-esc="env.company.name"/> you are required to disclose all material and relevant information, which may either affect your employment with <span style="font-weight: bold" t-esc="env.company.name"/> currently or in the future or may conflict with the terms of your employment with <span style="font-weight: bold" t-esc="env.company.name"/> either directly or indirectly. If at any time during your employment, if <span style="font-weight: bold" t-esc="env.company.name"/>. becomes aware that you have suppressed any material or relevant information required to be disclosed by you, <span style="font-weight: bold" t-esc="env.company.name"/> reserves the right to forthwith terminate your employment without any notice and without any obligation or liability to pay any remuneration or other dues to you irrespective of the period that you may have been employed by <span style="font-weight: bold" t-esc="env.company.name"/>.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">3. </span>You agree to conform to and comply with <span style="font-weight: bold" t-esc="env.company.name"/>s Policy and such other directions and guidelines which <span style="font-weight: bold" t-esc="env.company.name"/> may from time to time give as per its own discretion.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">4. </span>Notwithstanding anything mentioned in this Agreement, <span style="font-weight: bold" t-esc="env.company.name"/> may terminate your employment, with immediate effect by a notice in writing (without salary in lieu of notice), in the event of your misconduct, including but not limited to, fraudulent, dishonest or undisciplined conduct of, or breach of integrity, or embezzlement, or misappropriation or misuse by you of <span style="font-weight: bold" t-esc="env.company.name"/> ’s property, or insubordination or failure to comply with the directions given to you by persons so authorized, or your insolvency or conviction for any offence involving moral turpitude, or breach by you of any terms of this Agreement or <span style="font-weight: bold" t-esc="env.company.name"/> Policy or other documents or directions of <span style="font-weight: bold" t-esc="env.company.name"/> , or irregularity in attendance, or your unauthorized absence of from the place of work for more than Three (3) working days, or closure of the business of <span style="font-weight: bold" t-esc="env.company.name"/> , or redundancy of your post in <span style="font-weight: bold" t-esc="env.company.name"/>, or upon you conducting yourself in a manner which is regarded by <span style="font-weight: bold" t-esc="env.company.name"/> as prejudicial to its own interests or to the interests of its clients.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">5. </span>Notwithstanding anything aforesaid, termination by you shall be subject to the satisfactory completion of all your existing duties, obligations and projects.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">6. </span>At the time of termination of your employment, if there are any dues from you, the same may be adjusted against any money due to you from <span style="font-weight: bold" t-esc="env.company.name"/> on account of salary, bonus or any other such payments.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">7. </span>You agree that the laws of India shall govern the interpretation and enforcement of this Agreement and the provisions of the Indian Arbitration and Conciliation Act, 1996, shall govern all disputes under this Agreement. The venue for arbitration will be Hyderabad.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
This is to certify that I have read this Agreement and understood all the terms and conditions mentioned therein and I hereby accept and agree to abide by them.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold">Employee Name : <t t-esc="o.candidate_id.partner_name"/><br/><br/><br/><br/><br/>Signature: <br/>Date of Joining: <t t-esc="o.joining_date"/></span>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table class="table" style="line-height:20px; font-size:14px;page-break-before: always !important;" width="100%">
|
||||
<tr>
|
||||
<td style="text-align:center;" > <span style="font-weight: bold;">Annexure - B</span>
|
||||
<br/><br/><span style="font-weight: bold;">Salary Break Up</span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td > <br/>
|
||||
<t t-if="o.terms_conditions">
|
||||
<style>
|
||||
.custom-table-container {
|
||||
width: 700px;
|
||||
margin: 0 auto;
|
||||
border-collapse: collapse;
|
||||
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
|
||||
font-size: 14px;
|
||||
background-color: #fff;
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
|
||||
border-radius: 8px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.custom-table-container th,
|
||||
.custom-table-container td {
|
||||
padding: 12px 15px;
|
||||
border-bottom: 1px solid #e0e0e0;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.custom-table-container thead {
|
||||
background-color: #f5f5f5;
|
||||
font-weight: bold;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.custom-table-container th.text-end,
|
||||
.custom-table-container td.text-end {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.custom-table-container tr.text-danger {
|
||||
color: #d9534f;
|
||||
background-color: #fff5f5;
|
||||
}
|
||||
|
||||
.custom-table-container tbody tr:hover {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
</style>
|
||||
|
||||
<table class="custom-table-container">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Sequence</th>
|
||||
<!-- <th width="25%">Code</th>-->
|
||||
<th width="50%">Name</th>
|
||||
<th class="text-end" width="25%">Amount(M)</th>
|
||||
<th class="text-end" width="25%">Amount(Y)</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<t t-set="pay_details_lines" t-value="json.loads(o.terms_conditions)"/>
|
||||
<t t-set="n" t-value="0"/>
|
||||
<t t-foreach="pay_details_lines" t-as="line">
|
||||
<t t-set="n" t-value="n+1"/>
|
||||
<tr t-att-class="'text-danger' if line.get('amount', 0) < 0 else ''">
|
||||
<td><t t-esc="n"/></td>
|
||||
<!-- <td><t t-esc="line.get('code', '')"/></td>-->
|
||||
<td><t t-esc="line.get('name', '')"/></td>
|
||||
<td class="text-end"><t t-esc="'%.2f' % line.get('amount', 0)"/></td>
|
||||
<td class="text-end"><t t-esc="'%.2f' % line.get('y_amount', 0)"/></td>
|
||||
</tr>
|
||||
</t>
|
||||
</tbody>
|
||||
</table>
|
||||
</t>
|
||||
</td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<br/>
|
||||
<span style="font-weight: bold">1. ##VPP as per Policy.<br/>2. *Subject to Monthly Attendance and Subject to Income Tax Deductions<br/>3. **As per Statutory Norms<br/>4. Medical Insurance is for SELF only for coverage INR of 500000</span><br/><br/><br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<br/>
|
||||
<span style="font-weight: bold">Sincerely</span>
|
||||
<br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:100%">
|
||||
For<br/>
|
||||
Authorized Signatory
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold" t-esc="env.company.name"/>
|
||||
<span style="white-space: nowrap;float: right;" >Accepted and Agreed
|
||||
<br/><br/><br/><br/>
|
||||
</span>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span style="font-weight: bold"><t t-esc="o.manager_id.name"/></span><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.candidate_id.partner_name"></span><br/>
|
||||
<span style="font-weight: bold"><t t-esc="o.manager_id.job_id.name"/></span><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.position"></span><br/>
|
||||
<span style="font-weight: bold" t-esc="o.joining_date"/><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.joining_date"/>
|
||||
<br/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table class="table" style="line-height:20px; font-size:14px;page-break-before: always !important;" width="100%">
|
||||
<tr>
|
||||
<td style="text-align:center;" > <span style="font-weight: bold;">Annexure - C</span><br/><br/><span style="font-weight: bold;">NONDISCLOSURE AGREEMENT</span> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span>THIS NONDISCLOSURE AGREEMENT (this "Agreement") is entered into and effective as of the date specified on the signature page below between <span t-esc="env.company.name"/> a Company incorporated under Indian Companies Act 1956, having registered office in Hyderabad, India ("Company") Ashwath Sreeram(Recipient)</span><br/>
|
||||
<span>Whereas "Company" wishes to explore the possibility of entering into an employment agreement with Recipient which requires "Company" to disclose to Recipient certain Confidential Information as defined below.</span>
|
||||
<span>Now therefore, in consideration of the rights and obligations contained herein, the parties agree as follows:</span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span>1. <span style="text-decoration: underline;padding-left:10px;">Confidential Information.</span> "Confidential Information" as used in this Agreement shall mean information in any form, disclosed by Company, which relates to its business. Confidential Information includes, but is not limited to, patents, employees and related information, trade secrets, research and development plans, current and future products, product pricing, customers lists, markets, business plans, financial data, contractual terms, documentation, records, studies, reports, know-how, test results, software, software source or object code, and any other information which reasonably ought to be considered to be Confidential Information.</span><br/>
|
||||
<span>2. <span style="text-decoration: underline;padding-left:10px;">Exclusions.</span> Confidential Information does not include any information which (a) at the time of disclosure, is available to the general public; (b) at a later date, becomes available to the general public through no fault of Recipient, and then only after such later date; (c) Recipient can demonstrate was in its possession prior to receipt without an obligation of confidence; (d) is disclosed to Recipient without restriction on disclosure by a third party who had the lawful right to disclose such information; or (e) Recipient can demonstrate was independently developed by Recipient without use of any Confidential Information.</span><br/>
|
||||
<span>3. <span style="text-decoration: underline;padding-left:10px;">Protection of Confidential Information.</span> Recipient agrees that it shall treat Confidential Information with the same degree of care as it accords to its own Confidential Information of like kind, but in no event less than a reasonable degree of care. Recipient agrees that it will not make use of, disseminate, or in any way disclose any Confidential Information to any person, firm or business, except to the extent necessary for negotiations, discussions, and consultations with personnel or authorized representatives of Company., and any other purpose which Company may hereafter authorize in writing. Recipient may disclose the Confidential Information pursuant to a valid court order provided that Company is given prompt notice of any such order and an opportunity to contest the order. Recipient agrees that it shall disclose Confidential Information only to those of its employees or consultants who have a legitimate business need to know such information and who have previously agreed, either as a condition of employment or to obtain the Confidential Information, to be bound by terms and conditions substantially similar to those in this Agreement.</span><br/>
|
||||
<span>4. <span style="text-decoration: underline;padding-left:10px;">Return of Confidential Information.</span> All information furnished under this Agreement shall remain the property of the Company and shall be returned to it or destroyed or purged promptly at its request. All documents, memoranda, notes and other tangible embodiments whatsoever prepared by Recipient based on or which includes Confidential Information shall be destroyed to the extent necessary to remove all such Confidential Information upon the disclosing party's request. All destruction under this Paragraph 4 shall be certified in writing to the disclosing party by an authorized officer of Recipient.</span><br/>
|
||||
<span>5. <span style="text-decoration: underline;padding-left:10px;">Export Regulations.</span> Recipient agrees that it shall not export the Confidential Information to any country to which export is restricted by the company.</span><br/>
|
||||
<span>6. <span style="text-decoration: underline;padding-left:10px;">No License or Warranty.</span> Except as expressly set forth in this Agreement, no license under any patents, copyrights, mask rights or other proprietary rights is granted or conveyed by the Company's transmittal of Confidential Information or other information to Recipient under this Agreement. THE INFORMATION IS PROVIDED "AS IS" AND THERE IS NO REPRESENTATIONS OR
|
||||
|
||||
WARRANTIES, EXPRESS OR IMPLIED, WITH RESPECT TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO A WARRANTY AGAINST INFRINGEMENT, ACCURACY OR
|
||||
COMPLETENESS. Recipient will use all information received in a safe and prudent manner and is responsible for all risk or loss arising out of its use of such information. The recipient agrees that Company shall have no </span><br/>
|
||||
<span>7. <span style="text-decoration: underline;padding-left:10px;">No Inducement or Commitment.</span> Confidential Information provided to Recipient does not and is not intended to represent an inducement by Company or a commitment by Company to enter into any business relationship with Recipient or with any other entity. If the parties desire to pursue business opportunities, the parties will execute a separate written agreement to govern such business relationship.</span><br/>
|
||||
<span>8. <span style="text-decoration: underline;padding-left:10px;">Effective Date and Term.</span> This Agreement shall be effective from the Effective Date specified below and shall continue for three (3) years following the return of all Confidential Information in accordance with Paragraph 4 above when accompanied by a written notice of termination.</span><br/>
|
||||
<span>9. <span style="text-decoration: underline;padding-left:10px;">Remedies.</span> It is understood and agreed that money damages would not be a sufficient remedy for any breach of this Agreement and that Company shall be entitled to seek injunctive relief as a remedy for any such breach. Such remedy shall not be deemed to be exclusive but shall be in addition to all other remedies available at law or equity.</span><br/>
|
||||
<span>10. <span style="text-decoration: underline;padding-left:10px;">Non-assignment.</span> This Agreement may not be assigned, or otherwise transferred without the prior written consent of Company.</span><br/>
|
||||
<span>11. <span style="text-decoration: underline;padding-left:10px;">Miscellaneous.</span> This Agreement embodies the entire understanding between the parties respecting the subject matter of this Agreement and supersedes any and all prior negotiations, correspondence, understandings and agreements between the parties respecting the use and disclosure of Confidential Information. This Agreement shall not be modified except by a writing duly executed on behalf of the party against whom such modification is sought to be enforced. The failure of any party to require performance by another party of any provision of this Agreement shall in no way affect the full right to require such performance at any time thereafter. Should any provisions of this Agreement be found unenforceable, the remainder shall still be in effect. This Agreement has been negotiated by the parties and their respective attorneys, and the language of this Agreement shall not be construed for or against either party. The headings are not part of this Agreement. Either the original or copies, including facsimile transmissions, of this Agreement, may be executed in counterparts, each of which shall be an original as against any party whose signature appears on such counterpart and all of which together shall constitute one and the same instrument.</span><br/>
|
||||
<span>12. <span style="text-decoration: underline;padding-left:10px;">Notices.</span> All notices under this Agreement shall be deemed to have been duly given upon the mailing of the notice, post-paid, to the party entitled to such notice at the address set forth below.</span><br/>
|
||||
<span>13. <span style="text-decoration: underline;padding-left:10px;">Governing Law.</span> This Agreement shall be interpreted under the laws of the State of Telangana, India</span><br/>
|
||||
<span>14. All clauses mentioned in this NDA is applicable including our group Companies. Any misuse of data, information or any confidential information including our group companies will be prosecuted within Hyderabad Jurisdiction.</span><br/>
|
||||
<span>IN WITNESS WHEREOF each of the parties has caused the Agreement to be executed by its duly authorized representative.</span><br/><br/>
|
||||
<span>Effective Date:</span><br/><br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<span>Fast Track Projects Pvt. Ltd <br/> By:</span>
|
||||
<span style="float: right;">Employee / Consultant/Recipient <br/> By:</span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<br/><br/>
|
||||
<span style="font-weight: bold"><t t-esc="o.manager_id.name"/></span><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.candidate_id.partner_name"></span><br/>
|
||||
<span style="font-weight: bold"><t t-esc="o.manager_id.job_id.name"/></span><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.position"></span><br/>
|
||||
<span style="font-weight: bold" t-esc="o.joining_date"/><span style="font-weight: bold;white-space: nowrap;float: right;" t-esc="o.joining_date"/>
|
||||
<br/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
</odoo>
|
||||
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||
access_offer_letter_user,offer.letter.user,model_offer_letter,base.group_user,1,1,1,0
|
||||
access_offer_letter_manager,offer.letter.manager,model_offer_letter,hr.group_hr_manager,1,1,1,1
|
||||
|
|
|
@ -0,0 +1,70 @@
|
|||
/** @odoo-module **/
|
||||
|
||||
import { Component, useState, xml } from "@odoo/owl";
|
||||
import { registry } from "@web/core/registry";
|
||||
import { CharField, charField } from "@web/views/fields/char/char_field";
|
||||
|
||||
// Local utility function to parse the field value
|
||||
function parseData(value) {
|
||||
try {
|
||||
return JSON.parse(value);
|
||||
} catch (e) {
|
||||
console.warn("Failed to parse value in PayDetailsWidget:", value);
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
export class PayDetailsWidget extends CharField {
|
||||
static props = {
|
||||
...CharField.props,
|
||||
resModel: { type: String, optional: true },
|
||||
onlySearchable: { type: Boolean, optional: true },
|
||||
followRelations: { type: Boolean, optional: true },
|
||||
};
|
||||
|
||||
setup() {
|
||||
this.state = useState({
|
||||
lines: parseData(this.props.record.data.terms_conditions) || []
|
||||
});
|
||||
}
|
||||
|
||||
formatAmount(amount) {
|
||||
return parseFloat(amount).toFixed(2);
|
||||
}
|
||||
}
|
||||
|
||||
PayDetailsWidget.template = xml`
|
||||
<div class="o_pay_details_widget" align="center">
|
||||
<table class="table table-sm table-striped table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Sequence</th>
|
||||
<th>Code</th>
|
||||
<th>Name</th>
|
||||
<th class="text-end">Amount</th>
|
||||
<th class="text-end">Year Total</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<t t-set="n" t-value="0"/>
|
||||
<t t-foreach="state.lines" t-as="line" t-key="line['code']">
|
||||
<t t-set="n" t-value="n+1"/>
|
||||
<tr t-att-class="{'text-danger': line['amount'] < 0}">
|
||||
<td><t t-esc="n"/></td>
|
||||
<td><t t-esc="line['code']"/></td>
|
||||
<td><t t-esc="line['name']"/></td>
|
||||
<td class="text-end"><t t-esc="formatAmount(line['amount'])"/></td>
|
||||
<td class="text-end"><t t-esc="formatAmount(line['y_amount'])"/></td>
|
||||
</tr>
|
||||
</t>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
`;
|
||||
|
||||
export const PayDetailsWidgets = {
|
||||
...charField,
|
||||
component: PayDetailsWidget,
|
||||
};
|
||||
|
||||
registry.category("fields").add("pay_details_widget", PayDetailsWidgets);
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<odoo>
|
||||
<menuitem id="menu_offer_letters_list" name="Offer Letters" parent="hr_ftp.menu_hr_recruitment_hr" action="action_offer_letters"/>
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,64 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<odoo>
|
||||
<record id="view_offer_letter_list" model="ir.ui.view">
|
||||
<field name="name">offer.letter.list</field>
|
||||
<field name="model">offer.letter</field>
|
||||
<field name="arch" type="xml">
|
||||
<list>
|
||||
<field name="name"/>
|
||||
<field name="candidate_id"/>
|
||||
<field name="position"/>
|
||||
<field name="state"/>
|
||||
<field name="sent_date"/>
|
||||
</list>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_offer_letter_form" model="ir.ui.view">
|
||||
<field name="name">offer.letter.form</field>
|
||||
<field name="model">offer.letter</field>
|
||||
<field name="arch" type="xml">
|
||||
<form>
|
||||
<header>
|
||||
<button name="action_send_offer" type="object" string="Send Offer" class="oe_highlight" invisble="state != 'draft'"/>
|
||||
<button name="action_accept_offer" type="object" string="Accept Offer" invisble="state != 'sent'" class="oe_highlight"/>
|
||||
<button name="action_reject_offer" type="object" string="Reject Offer" invisble="state != 'sent'" class="oe_danger"/>
|
||||
<button name="get_paydetailed_lines" type="object" string="Get Data" invisble="state != 'sent'" class="oe_danger"/>
|
||||
<button name="generate_pdf_report" type="object" string="Generate PDF" class="oe_highlight"/>
|
||||
<field name="state" widget="statusbar" statusbar_visible="draft,sent,accepted,rejected,expired"/>
|
||||
</header>
|
||||
<sheet>
|
||||
<group>
|
||||
<group>
|
||||
<field name="name" readonly="state != 'draft'"/>
|
||||
<field name="candidate_id"/>
|
||||
<field name="manager_id"/>
|
||||
<field name="position"/>
|
||||
<field name="salary"/>
|
||||
<field name="mi"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="currency_id"/>
|
||||
<field name="joining_date"/>
|
||||
<field name="contract_type"/>
|
||||
<field name="probation_period"/>
|
||||
<field name="pay_struct_id"/>
|
||||
</group>
|
||||
</group>
|
||||
<notebook>
|
||||
<page string="Terms Conditions">
|
||||
<field name="terms_conditions" widget="pay_details_widget"/>
|
||||
</page>
|
||||
</notebook>
|
||||
</sheet>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_offer_letters" model="ir.actions.act_window">
|
||||
<field name="name">Offer Letters</field>
|
||||
<field name="res_model">offer.letter</field>
|
||||
<field name="view_mode">list,form</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
Loading…
Reference in New Issue