[IMP] improved code to add subtype of stage change of applicant on job
bzr revid: tpa@tinyerp.com-20130624090410-af4jc4myy88huyol
This commit is contained in:
parent
4a972b4089
commit
e8ae12827e
|
@ -156,7 +156,7 @@ class hr_job(osv.osv):
|
||||||
|
|
||||||
def write(self, cr, uid, ids, vals, context=None):
|
def write(self, cr, uid, ids, vals, context=None):
|
||||||
if vals.get('state') == 'recruit':
|
if vals.get('state') == 'recruit':
|
||||||
self.message_post(cr, uid, ids, body=_('job in <b>Recruitment</b> Stage'), subtype="hr.mt_job_recruit", context=context)
|
self.message_post(cr, uid, ids, body=_('job in <b>Recruitment</b> Stage'), context=context)
|
||||||
return super(hr_job, self).write(cr, uid, ids, vals, context=context)
|
return super(hr_job, self).write(cr, uid, ids, vals, context=context)
|
||||||
|
|
||||||
class hr_employee(osv.osv):
|
class hr_employee(osv.osv):
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -485,6 +485,12 @@
|
||||||
<field name="default" eval="False"/>
|
<field name="default" eval="False"/>
|
||||||
<field name="description">Applicant refused</field>
|
<field name="description">Applicant refused</field>
|
||||||
</record>
|
</record>
|
||||||
|
<record id="mt_job_applicant_stage" model="mail.message.subtype">
|
||||||
|
<field name="name">Application Stage Changed</field>
|
||||||
|
<field name="res_model">hr.job</field>
|
||||||
|
<field name="parent_id" eval="ref('mt_stage_changed')"/>
|
||||||
|
<field name="relation_field">job_id</field>
|
||||||
|
</record>
|
||||||
<!-- Applicant Categories(Tag) -->
|
<!-- Applicant Categories(Tag) -->
|
||||||
<record id="tag_applicant_reserve" model="hr.applicant_category">
|
<record id="tag_applicant_reserve" model="hr.applicant_category">
|
||||||
<field name="name">Reserve</field>
|
<field name="name">Reserve</field>
|
||||||
|
|
|
@ -40,7 +40,7 @@ openerp.hr_recruitment = function (openerp) {
|
||||||
if (!self.$el.find(".oe_justgage_edit").size()) {
|
if (!self.$el.find(".oe_justgage_edit").size()) {
|
||||||
var $svg = self.$el.find('svg');
|
var $svg = self.$el.find('svg');
|
||||||
$div = $('<div class="oe_justgage_edit" style="text-align: center; z-index: 1; position: absolute; width: ' + $svg.outerWidth() + 'px; top: ' + ($svg.outerHeight()/2+20) + 'px;"/>');
|
$div = $('<div class="oe_justgage_edit" style="text-align: center; z-index: 1; position: absolute; width: ' + $svg.outerWidth() + 'px; top: ' + ($svg.outerHeight()/2+20) + 'px;"/>');
|
||||||
$input = $('<input style="text-align: center; width: ' + ($svg.outerWidth()/2) + 'px; margin: auto;"/>').val(value);
|
$input = $('<input style="text-align: center; width: ' + ($svg.outerWidth()/2) + 'px; margin: auto;"/>').val(parent.values.no_of_recruitment.value);
|
||||||
$div.append($input);
|
$div.append($input);
|
||||||
self.$el.prepend($div)
|
self.$el.prepend($div)
|
||||||
$input.focus()
|
$input.focus()
|
||||||
|
|
Loading…
Reference in New Issue