[IMP] Some changes in hr recruitment
- Remove page of 'Communication and History', - Remove group of 'Dates' from notebook page, - Moved button of 'Send new email' on top of right side on main page, - Improved messages and notification. bzr revid: jra@tinyerp.com-20120228133516-iw1zjxhb1xjdzgaf
This commit is contained in:
@@ -392,6 +392,7 @@ class hr_applicant(crm.crm_case, osv.osv):
|
||||
return res
|
||||
|
||||
def _case_open_notification(self, case, context=None):
|
||||
case.message_mark_done(context)
|
||||
message = _("Changed Status to <b>In Progress<b>.")
|
||||
case.message_append_note('' ,message, type='notification', need_action_user_id=case.user_id.id)
|
||||
return True
|
||||
@@ -399,22 +400,22 @@ class hr_applicant(crm.crm_case, osv.osv):
|
||||
def _case_close_notification(self, case, context=None):
|
||||
case[0].message_mark_done(context)
|
||||
if case[0].emp_id:
|
||||
message = _("Applicant is being <b>Hired</b> as an employee.")
|
||||
message = _("Applicant is <b>Hired</b> and employee created.")
|
||||
case[0].message_append_note('' ,message, type='notification')
|
||||
else:
|
||||
message = _("Applicant is being <b>Hired</b>.")
|
||||
message = _("Applicant is <b>Hired</b>.")
|
||||
case[0].message_append_note('' ,message, type='notification')
|
||||
return True
|
||||
|
||||
def _case_cancel_notification(self, case, context=None):
|
||||
case[0].message_mark_done(context=context)
|
||||
message = _("Applicant Subject <em>'%s'</em> has been <b>Cancelled<b>.") % (case[0].name)
|
||||
message = _("Applicant is <b>Cancelled<b>.")
|
||||
case[0].message_append_note('' ,message, type="notification")
|
||||
return True
|
||||
|
||||
def _case_pending_notification(self, case, context=None):
|
||||
message = _("Changed Status to <b>Pending<b>.")
|
||||
case[0].message_append_note('' ,message, type='notification', need_action_user_id=case[0].user_id.id)
|
||||
case[0].message_append_note('' ,message, type='notification')
|
||||
return True
|
||||
|
||||
def _case_reset_notification(self, cr, uid, ids, context=None):
|
||||
@@ -427,7 +428,7 @@ class hr_applicant(crm.crm_case, osv.osv):
|
||||
for obj in self.browse(cr, uid, ids, context=context):
|
||||
self.message_subscribe(cr, uid, ids, [obj.user_id.id], context=context)
|
||||
self.message_append_note(cr, uid, ids, _('System notification'),
|
||||
_("Applicant <b>Created</b>."), type='notification', need_action_user_id=obj.user_id.id, context=context)
|
||||
_("Applicant is <b>Created</b>."), type='notification', need_action_user_id=obj.user_id.id, context=context)
|
||||
return True
|
||||
|
||||
|
||||
@@ -517,7 +518,7 @@ class hr_applicant(crm.crm_case, osv.osv):
|
||||
def write(self, cr, uid, ids, vals, context=None):
|
||||
if 'stage_id' in vals and vals['stage_id']:
|
||||
stage = self.pool.get('hr.recruitment.stage').browse(cr, uid, vals['stage_id'], context=context)
|
||||
text = _("Changed Stage to <b>%s</b>") % stage.name
|
||||
text = _("Changed Stage to <b>%s</b>.") % stage.name
|
||||
self.message_append(cr, uid, ids, text, body_text=text, context=context)
|
||||
return super(hr_applicant,self).write(cr, uid, ids, vals, context=context)
|
||||
|
||||
|
||||
@@ -79,6 +79,9 @@
|
||||
<field name="partner_name"/>
|
||||
<field name="job_id" on_change="onchange_job(job_id)"/>
|
||||
<button name="action_makeMeeting" type="object" string="Meeting" icon="gtk-index"/>
|
||||
<button string="Send New Email"
|
||||
name="%(mail.action_email_compose_message_wizard)d"
|
||||
icon="terp-mail-message-new" type="action"/>
|
||||
<newline/>
|
||||
<field name="department_id" widget="selection" on_change="onchange_department_id(department_id)"/>
|
||||
<group colspan="2" col="4">
|
||||
@@ -124,13 +127,6 @@
|
||||
<field name="source_id"/>
|
||||
<field name="reference"/>
|
||||
</group>
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Dates"/>
|
||||
<field name="create_date"/>
|
||||
<field name="write_date"/>
|
||||
<field name="date_closed"/>
|
||||
<field name="date_open"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Status"/>
|
||||
<group col="8" colspan="4">
|
||||
<field name="state" widget="statusbar" statusbar_visible="draft,open,done" statusbar_colors='{"pending":"blue"}'/>
|
||||
@@ -141,29 +137,6 @@
|
||||
<button name="case_reset" string="Reset to New" states="done,cancel" type="object" icon="gtk-convert"/>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Communication & History" groups="base.group_extended">
|
||||
<group colspan="4">
|
||||
<field colspan="4" name="email_cc" string="Global CC" widget="char"/>
|
||||
</group>
|
||||
<field name="message_ids" colspan="4" nolabel="1" mode="tree" readonly="1">
|
||||
<tree string="History">
|
||||
<field name="display_text" string="History Information"/>
|
||||
<field name="email_from" invisible="1"/>
|
||||
<button
|
||||
string="Reply" attrs="{'invisible': [('email_from', '=', False)]}"
|
||||
name="%(mail.action_email_compose_message_wizard)d"
|
||||
context="{'mail.compose.message.mode':'reply', 'message_id':active_id}"
|
||||
icon="terp-mail-replied" type="action" />
|
||||
</tree>
|
||||
</field>
|
||||
<button string="Add Internal Note"
|
||||
name="%(crm.action_crm_add_note)d"
|
||||
context="{'model': 'crm.lead' }"
|
||||
icon="terp-document-new" type="action" />
|
||||
<button string="Send New Email"
|
||||
name="%(mail.action_email_compose_message_wizard)d"
|
||||
icon="terp-mail-message-new" type="action"/>
|
||||
</page>
|
||||
<page string="Notes">
|
||||
<field name="description" nolabel="1" colspan="4"/>
|
||||
</page>
|
||||
|
||||
Reference in New Issue
Block a user