2 In order to test hr_recruitment module for OpenERP, I will create applicants form, Manages job positions and the recruitment process.
7 !record {model: hr.department, id: hr_department_rd0}:
8 manager_id: base.user_root
12 I create new Job Position.
14 !record {model: hr.job, id: hr_job_jea0}:
15 department_id: 'hr_department_rd0'
16 description: 'Position of Jr. Application Engineer'
20 I create a recruitment stage "Initial Jobs Demand".
22 !record {model: hr.recruitment.stage, id: hr_recrutiment_stage_first0}:
23 name: 'Initial Jobs Demand'
26 I create an applicant.
28 !record {model: hr.applicant, id: hr_applicant_fresher0}:
30 department_id: hr.dep_it
32 partner_address_id: base.res_partner_address_tang
33 partner_id: base.res_partner_asus
34 partner_name: Marion Jones
35 partner_phone: '1111112223'
39 stage_id: hr_recrutiment_stage_first0
40 type_id: hr_recruitment.degree_licenced
43 I check that applicant is on "draft" state.
45 !assert {model: hr.applicant, id: hr_applicant_fresher0}:
49 I change the state by click on "In Progress" button.
51 !python {model: hr.applicant}: |
52 self.case_open(cr, uid, [ref("hr_applicant_fresher0")], {"active_ids": [ref("hr_recruitment.menu_crm_case_categ0_act_job")],
56 I create a new case category.
58 !record {model: crm.case.categ, id: crm_case_categ_employee0}:
62 I schedule a phonecall for this applicant by click on "Schedule a Phone Call" button.
64 !record {model: hr.recruitment.job2phonecall, id: hr_recruitment_forinterview0}:
65 user_id: base.user_root
66 deadline: !eval time.strftime('%Y-%m-%d 11:51:00')
67 note: 'For interview.'
68 category_id: 'crm_case_categ_employee0'
71 I click on "Schedule phonecall" button of this wizard.
73 !python {model: hr.recruitment.job2phonecall}: |
74 self.make_phonecall(cr, uid, [ref('hr_recruitment_forinterview0')], {'active_ids': [ref('hr_applicant_fresher0')]})
77 I schedule meeting for interview of this applicant by click on "Schedule Meeting" button.
79 !python {model: hr.applicant}: |
80 self.action_makeMeeting(cr, uid, [ref('hr_recruitment_forinterview0')])
82 I create an entry for the meeting with the applicant.
84 !record {model: crm.meeting, id: crm_meeting_fresher0}:
85 alarm_id: base_calendar.alarm1
87 date: !eval "(datetime.now()+timedelta(1)).strftime('%Y-%m-%d 00:00:00')"
88 date_deadline: !eval "(datetime.now()+timedelta(1)).strftime('%Y-%m-%d 08:00:00')"
92 opportunity_id: crm.crm_case_construstazunits0
93 partner_address_id: base.res_partner_address_tang
94 partner_id: base.res_partner_asus
98 user_id: base.user_root
101 On a successful meeting with the applicant, I hired employee by click on "Hired" button.
103 !python {model: hr.applicant}: |
104 self.case_close(cr, uid, [ref('hr_applicant_fresher0')])
106 I check that applicant state is "Hired".
108 !assert {model: hr.applicant, id: hr_applicant_fresher0}: