| 3468 |
eleazar |
1 |
<?php
|
| 1709 |
eleazar |
2 |
$acl = $this->viewModel()->getRoot()->getVariable('acl');
|
|
|
3 |
$currentUser = $this->currentUserHelper();
|
|
|
4 |
$roleName = $currentUser->getUserTypeId();
|
|
|
5 |
|
| 7957 |
eleazar |
6 |
$routeIndex = $this->url('recruitment-and-selection/interview/form');
|
| 7961 |
eleazar |
7 |
$routeAdd = $this->url('recruitment-and-selection/interview/form/add', ['vacancy_uuid' => 'UUID_PLACEHOLDER']);
|
| 3573 |
eleazar |
8 |
$routeVacancy = $this->url('recruitment-and-selection/interview/vacancy', ['vacancy_uuid' => 'UUID_PLACEHOLDER']);
|
| 4367 |
eleazar |
9 |
$routeType = $this->url('recruitment-and-selection/interview/type', ['candidate_uuid' => 'UUID_PLACEHOLDER']);
|
| 1877 |
eleazar |
10 |
|
| 1827 |
eleazar |
11 |
$allowAdd = $acl->isAllowed($roleName, 'recruitment-and-selection/interview/form/add') ? 1 : 0;
|
| 3533 |
eleazar |
12 |
$allowEdit = $acl->isAllowed($roleName, 'recruitment-and-selection/interview/form/edit') ? 1 : 0;
|
|
|
13 |
$allowDelete = $acl->isAllowed($roleName, 'recruitment-and-selection/interview/form/delete') ? 1 : 0;
|
| 3534 |
eleazar |
14 |
$allowReport = $acl->isAllowed($roleName, 'recruitment-and-selection/interview/report') ? 1 : 0;
|
| 8781 |
eleazar |
15 |
$allowFile = $acl->isAllowed($roleName, 'recruitment-and-selection/interview/file') ? 1 : 0;
|
| 1709 |
eleazar |
16 |
$this->headLink()->appendStylesheet($this->basePath('plugins/nprogress/nprogress.css'));
|
|
|
17 |
$this->inlineScript()->appendFile($this->basePath('plugins/nprogress/nprogress.js'));
|
|
|
18 |
|
|
|
19 |
|
|
|
20 |
$this->inlineScript()->appendFile($this->basePath('plugins/bootbox/bootbox.min.js'));
|
|
|
21 |
|
|
|
22 |
|
| 1885 |
eleazar |
23 |
$this->inlineScript()->appendFile($this->basePath('plugins/ckeditor/ckeditor.js'));
|
| 1709 |
eleazar |
24 |
$this->inlineScript()->appendFile($this->basePath('plugins/jquery-validation/jquery.validate.js'));
|
|
|
25 |
$this->inlineScript()->appendFile($this->basePath('plugins/jquery-validation/additional-methods.js'));
|
|
|
26 |
$this->inlineScript()->appendFile($this->basePath('plugins/jquery-validation/localization/messages_es.js'));
|
|
|
27 |
|
|
|
28 |
$this->headLink()->appendStylesheet($this->basePath('plugins/datatables-bs4/css/dataTables.bootstrap4.min.css'));
|
|
|
29 |
$this->headLink()->appendStylesheet($this->basePath('plugins/datatables-responsive/css/responsive.bootstrap4.min.css'));
|
|
|
30 |
|
|
|
31 |
$this->inlineScript()->appendFile($this->basePath('plugins/datatables/jquery.dataTables.min.js'));
|
|
|
32 |
$this->inlineScript()->appendFile($this->basePath('plugins/datatables-bs4/js/dataTables.bootstrap4.min.js'));
|
|
|
33 |
$this->inlineScript()->appendFile($this->basePath('plugins/datatables-responsive/js/dataTables.responsive.min.js'));
|
|
|
34 |
$this->inlineScript()->appendFile($this->basePath('plugins/datatables-responsive/js/responsive.bootstrap4.min.js'));
|
|
|
35 |
|
|
|
36 |
$this->inlineScript()->appendFile($this->basePath('plugins/jquery-validation/jquery.validate.js'));
|
|
|
37 |
$this->inlineScript()->appendFile($this->basePath('plugins/jquery-validation/additional-methods.js'));
|
|
|
38 |
$this->inlineScript()->appendFile($this->basePath('plugins/jquery-validation/localization/messages_es.js'));
|
|
|
39 |
|
|
|
40 |
$this->headLink()->appendStylesheet($this->basePath('plugins/bootstrap4-toggle/css/bootstrap4-toggle.min.css'));
|
|
|
41 |
$this->inlineScript()->appendFile($this->basePath('plugins/bootstrap4-toggle/js/bootstrap4-toggle.min.js'));
|
|
|
42 |
|
|
|
43 |
$this->inlineScript()->appendFile($this->basePath('plugins/bootstrap-confirmation/dist/bootstrap-confirmation.js'));
|
|
|
44 |
$this->headLink()->appendStylesheet($this->basePath('plugins/bootstrap-checkbox/awesome-bootstrap-checkbox.css'));
|
|
|
45 |
|
|
|
46 |
$this->inlineScript()->appendFile($this->basePath('plugins/moment/moment-with-locales.min.js'));
|
|
|
47 |
$this->headLink()->appendStylesheet($this->basePath('plugins/bootstrap-datetimepicker/css/bootstrap-datetimepicker.css'));
|
|
|
48 |
$this->inlineScript()->appendFile($this->basePath('plugins/bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js'));
|
|
|
49 |
|
| 1887 |
eleazar |
50 |
|
| 2746 |
eleazar |
51 |
$this->inlineScript()->appendFile($this->basePath('plugins/select2/js/select2.js'));
|
|
|
52 |
$this->inlineScript()->appendFile($this->basePath('plugins/select2/js/i18n/es.js'));
|
|
|
53 |
$this->headLink()->appendStylesheet($this->basePath('plugins/select2/css/select2.css'));
|
|
|
54 |
|
| 1887 |
eleazar |
55 |
$this->headLink()->appendStylesheet($this->basePath('plugins/select2-bootstrap4-theme/select2-bootstrap4.css'));
|
| 1709 |
eleazar |
56 |
|
| 2052 |
eleazar |
57 |
// JsRender //
|
|
|
58 |
$this->inlineScript()->appendFile($this->basePath('plugins/jsrender/jsrender.min.js'));
|
| 1709 |
eleazar |
59 |
|
| 4158 |
eleazar |
60 |
$status_acepted = \LeadersLinked\Model\RecruitmentSelectionInterview::STATUS_ACCEPTED;
|
| 4157 |
eleazar |
61 |
$status_rejected = \LeadersLinked\Model\RecruitmentSelectionInterview::STATUS_REJECTED;
|
| 2510 |
eleazar |
62 |
|
|
|
63 |
$points_0 = \LeadersLinked\Model\RecruitmentSelectionInterview::POINTS_0;
|
|
|
64 |
$points_1 = \LeadersLinked\Model\RecruitmentSelectionInterview::POINTS_1;
|
|
|
65 |
$points_2 = \LeadersLinked\Model\RecruitmentSelectionInterview::POINTS_2;
|
|
|
66 |
$points_3 = \LeadersLinked\Model\RecruitmentSelectionInterview::POINTS_3;
|
|
|
67 |
$points_4 = \LeadersLinked\Model\RecruitmentSelectionInterview::POINTS_4;
|
|
|
68 |
|
|
|
69 |
|
|
|
70 |
|
| 1709 |
eleazar |
71 |
$this->headStyle()->captureStart();
|
|
|
72 |
echo <<<CSS
|
|
|
73 |
|
|
|
74 |
CSS;
|
|
|
75 |
$this->headStyle()->captureEnd();
|
|
|
76 |
|
|
|
77 |
$this->inlineScript()->captureStart();
|
|
|
78 |
echo <<<JS
|
|
|
79 |
|
|
|
80 |
jQuery( document ).ready(function( $ ) {
|
| 3535 |
eleazar |
81 |
var allowDelete = $allowDelete;
|
|
|
82 |
var allowEdit = $allowEdit;
|
|
|
83 |
var allowReport = $allowReport;
|
| 8784 |
eleazar |
84 |
var allowFile = $allowFile;
|
| 1877 |
eleazar |
85 |
$.validator.setDefaults({
|
| 2015 |
eleazar |
86 |
debug: true,
|
|
|
87 |
highlight: function(element) {
|
|
|
88 |
$(element).addClass('is-invalid');
|
|
|
89 |
},
|
|
|
90 |
unhighlight: function(element) {
|
|
|
91 |
$(element).removeClass('is-invalid');
|
|
|
92 |
},
|
|
|
93 |
errorElement: 'span',
|
|
|
94 |
errorClass: 'error invalid-feedback',
|
|
|
95 |
errorPlacement: function(error, element) {
|
|
|
96 |
if(element.parent('.btn-file').length) {
|
|
|
97 |
error.insertAfter(element.parent().parent());
|
|
|
98 |
} else if(element.parent('.toggle').length) {
|
|
|
99 |
error.insertAfter(element.parent().parent());
|
|
|
100 |
} else {
|
|
|
101 |
error.insertAfter(element.parent());
|
| 1709 |
eleazar |
102 |
}
|
| 2015 |
eleazar |
103 |
}
|
|
|
104 |
});
|
| 3468 |
eleazar |
105 |
|
| 2015 |
eleazar |
106 |
$.fn.showFormErrorValidator = function(fieldname, errors) {
|
|
|
107 |
var field = $(fieldname);
|
|
|
108 |
if(field) {
|
|
|
109 |
$(field).addClass('is-invalid');
|
| 1709 |
eleazar |
110 |
|
| 2015 |
eleazar |
111 |
var error = $('<span id="' + fieldname +'-error" class="error invalid-feedback">' + errors + '</div>');
|
| 3468 |
eleazar |
112 |
|
| 2015 |
eleazar |
113 |
if(element.parent('.btn-file').length) {
|
|
|
114 |
error.insertAfter(element.parent().parent());
|
|
|
115 |
} else if(element.parent('.toggle').length) {
|
|
|
116 |
error.insertAfter(element.parent().parent());
|
|
|
117 |
} else {
|
|
|
118 |
error.insertAfter(element.parent());
|
| 1709 |
eleazar |
119 |
}
|
| 2015 |
eleazar |
120 |
}
|
|
|
121 |
};
|
| 1827 |
eleazar |
122 |
|
| 3468 |
eleazar |
123 |
var gridTable = $('#gridTable').dataTable({
|
|
|
124 |
'processing': true,
|
|
|
125 |
'serverSide': true,
|
|
|
126 |
'searching': true,
|
|
|
127 |
'order': [
|
|
|
128 |
[0, 'asc']
|
|
|
129 |
],
|
|
|
130 |
'ordering': true,
|
|
|
131 |
'ordenable': true,
|
|
|
132 |
'responsive': true,
|
|
|
133 |
'select': false,
|
|
|
134 |
'paging': true,
|
|
|
135 |
'pagingType': 'simple_numbers',
|
|
|
136 |
'ajax': {
|
|
|
137 |
'url': '$routeIndex',
|
|
|
138 |
'type': 'get',
|
|
|
139 |
'beforeSend': function(request) {
|
|
|
140 |
NProgress.start();
|
|
|
141 |
},
|
|
|
142 |
'dataFilter': function(response) {
|
|
|
143 |
var response = jQuery.parseJSON(response);
|
|
|
144 |
var json = {};
|
|
|
145 |
json.recordsTotal = 0;
|
|
|
146 |
json.recordsFiltered = 0;
|
|
|
147 |
json.data = [];
|
|
|
148 |
if (response.success) {
|
|
|
149 |
json.recordsTotal = response.data.total;
|
|
|
150 |
json.recordsFiltered = response.data.total;
|
|
|
151 |
json.data = response.data.items;
|
|
|
152 |
} else {
|
|
|
153 |
$.fn.showError(response.data)
|
|
|
154 |
}
|
|
|
155 |
return JSON.stringify(json);
|
|
|
156 |
gridTable.api().ajax.reload(null, false);
|
|
|
157 |
}
|
|
|
158 |
},
|
|
|
159 |
'language': {
|
|
|
160 |
'sProcessing': 'LABEL_DATATABLE_SPROCESSING',
|
|
|
161 |
'sLengthMenu': 'LABEL_DATATABLE_SLENGTHMENU',
|
|
|
162 |
'sZeroRecords': 'LABEL_DATATABLE_SZERORECORDS',
|
|
|
163 |
'sEmptyTable': 'LABEL_DATATABLE_SEMPTYTABLE',
|
|
|
164 |
'sInfo': 'LABEL_DATATABLE_SINFO',
|
|
|
165 |
'sInfoEmpty': 'LABEL_DATATABLE_SINFOEMPTY',
|
|
|
166 |
'sInfoFiltered': 'LABEL_DATATABLE_SINFOFILTERED',
|
|
|
167 |
'sInfoPostFix': '',
|
|
|
168 |
'sSearch': 'LABEL_DATATABLE_SSEARCH',
|
|
|
169 |
'sUrl': '',
|
|
|
170 |
'sInfoThousands': ',',
|
|
|
171 |
'sLoadingRecords': 'LABEL_DATATABLE_SLOADINGRECORDS',
|
|
|
172 |
'oPaginate': {
|
|
|
173 |
'sFirst': 'LABEL_DATATABLE_SFIRST',
|
|
|
174 |
'sLast': 'LABEL_DATATABLE_SLAST',
|
|
|
175 |
'sNext': 'LABEL_DATATABLE_SNEXT',
|
|
|
176 |
'sPrevious': 'LABEL_DATATABLE_SPREVIOUS'
|
|
|
177 |
},
|
|
|
178 |
'oAria': {
|
|
|
179 |
'sSortAscending': ': LABEL_DATATABLE_SSORTASCENDING',
|
|
|
180 |
'sSortDescending': ':LABEL_DATATABLE_SSORTDESCENDING'
|
|
|
181 |
},
|
|
|
182 |
},
|
|
|
183 |
'drawCallback': function(settings) {
|
|
|
184 |
NProgress.done();
|
|
|
185 |
$('button.btn-delete').confirmation({
|
|
|
186 |
rootSelector: 'button.btn-delete',
|
|
|
187 |
title: 'LABEL_ARE_YOU_SURE',
|
|
|
188 |
singleton: true,
|
|
|
189 |
btnOkLabel: 'LABEL_YES',
|
|
|
190 |
btnCancelLabel: 'LABEL_NO',
|
|
|
191 |
onConfirm: function(value) {
|
|
|
192 |
action = $(this).data('href');
|
|
|
193 |
NProgress.start();
|
|
|
194 |
$.ajax({
|
|
|
195 |
'dataType': 'json',
|
|
|
196 |
'accept': 'application/json',
|
|
|
197 |
'method': 'post',
|
|
|
198 |
'url': action,
|
|
|
199 |
}).done(function(response) {
|
|
|
200 |
if (response['success']) {
|
|
|
201 |
$.fn.showSuccess(response['data']);
|
|
|
202 |
gridTable.api().ajax.reload(null, false);
|
|
|
203 |
} else {
|
|
|
204 |
$.fn.showError(response['data']);
|
|
|
205 |
}
|
|
|
206 |
}).fail(function(jqXHR, textStatus, errorThrown) {
|
|
|
207 |
$.fn.showError(textStatus);
|
|
|
208 |
}).always(function() {
|
|
|
209 |
NProgress.done();
|
|
|
210 |
});
|
|
|
211 |
},
|
|
|
212 |
});
|
|
|
213 |
},
|
| 3551 |
eleazar |
214 |
'aoColumns': [
|
|
|
215 |
{
|
| 3544 |
eleazar |
216 |
'mDataProp': function(data, type, row) {
|
|
|
217 |
return data.first_name + ' ' + data.last_name
|
|
|
218 |
}
|
| 3468 |
eleazar |
219 |
},
|
| 3552 |
eleazar |
220 |
{
|
|
|
221 |
'mDataProp': 'email'
|
|
|
222 |
},
|
| 3468 |
eleazar |
223 |
{
|
| 4032 |
eleazar |
224 |
'mDataProp': function(data, type, row){
|
|
|
225 |
switch(data.type) {
|
| 4033 |
eleazar |
226 |
case 'r':
|
| 9405 |
eleazar |
227 |
return 'LABEL_HUMAN_RESOURCE'
|
| 4032 |
eleazar |
228 |
case 'b':
|
| 4034 |
eleazar |
229 |
return 'LABEL_BOSS_INTERVIEW'
|
| 4032 |
eleazar |
230 |
default:
|
|
|
231 |
return data.type
|
|
|
232 |
}
|
|
|
233 |
}
|
| 3561 |
eleazar |
234 |
},
|
|
|
235 |
{
|
| 3888 |
eleazar |
236 |
'mDataProp': 'vacancy'
|
| 3882 |
eleazar |
237 |
},
|
|
|
238 |
{
|
| 8886 |
eleazar |
239 |
'mDataProp': function(data, type, row){
|
|
|
240 |
switch(data.points) {
|
|
|
241 |
case '0':
|
| 8887 |
eleazar |
242 |
return 'LABEL_ANOTHER'
|
|
|
243 |
case '':
|
|
|
244 |
return 'LABEL_ANOTHER'
|
| 8886 |
eleazar |
245 |
case '1':
|
| 8887 |
eleazar |
246 |
return '25%'
|
| 8886 |
eleazar |
247 |
case '2':
|
| 8887 |
eleazar |
248 |
return '50%'
|
| 8886 |
eleazar |
249 |
case '3':
|
| 8887 |
eleazar |
250 |
return '75%'
|
| 8886 |
eleazar |
251 |
case '4':
|
| 8887 |
eleazar |
252 |
return '100%'
|
| 8886 |
eleazar |
253 |
default:
|
|
|
254 |
return data.points
|
|
|
255 |
}
|
| 3956 |
eleazar |
256 |
}
|
| 3953 |
eleazar |
257 |
},
|
|
|
258 |
{
|
| 3468 |
eleazar |
259 |
'mDataProp': 'actions'
|
|
|
260 |
},
|
|
|
261 |
],
|
| 3558 |
eleazar |
262 |
'columnDefs': [
|
|
|
263 |
{
|
| 3468 |
eleazar |
264 |
'targets': 0,
|
|
|
265 |
'className': 'text-vertical-middle',
|
|
|
266 |
},
|
| 3957 |
eleazar |
267 |
|
| 3468 |
eleazar |
268 |
{
|
|
|
269 |
'targets': -1,
|
|
|
270 |
'orderable': false,
|
|
|
271 |
'render': function(data, type, row) {
|
| 9413 |
eleazar |
272 |
|
| 9411 |
eleazar |
273 |
|
| 3468 |
eleazar |
274 |
s = '';
|
| 9411 |
eleazar |
275 |
|
| 3468 |
eleazar |
276 |
if (allowEdit) {
|
| 8794 |
eleazar |
277 |
s = s + '<button class="btn btn-info btn-sm btn-edit" data-href="' + data['link_edit'] + '" data-toggle="tooltip" title="LABEL_EDIT"><i class="fa fa-pencil"></i> LABEL_EDIT </button> ';
|
| 3468 |
eleazar |
278 |
}
|
| 9413 |
eleazar |
279 |
if (allowFile && data['link_file']) {
|
|
|
280 |
s = s + '<button class="btn btn-info btn-sm btn-evaluation" id="btn-file" data-href="' + data['link_file']+ '" data-toggle="tooltip" title="LABEL_EVALUATION"><i class="fa fa-external-link"></i> LABEL_EVALUATION </button> ';
|
|
|
281 |
}
|
| 3468 |
eleazar |
282 |
if (allowDelete) {
|
| 8794 |
eleazar |
283 |
s = s + '<button class="btn btn-danger btn-sm btn-delete" data-href="' + data['link_delete'] + '" data-toggle="tooltip" title="LABEL_DELETE"><i class="fa fa-trash"></i> LABEL_DELETE </button> ';
|
| 3468 |
eleazar |
284 |
}
|
|
|
285 |
if (allowReport) {
|
| 8788 |
eleazar |
286 |
s = s + '<a class="btn btn-info btn-sm btn-pdf" href="' + data['link_report'] + '" target="_blank" data-toggle="tooltip" title="LABEL_PDF"><i class="fa fa-file-o"></i> LABEL_PDF </button> ';
|
| 3468 |
eleazar |
287 |
}
|
|
|
288 |
return s;
|
|
|
289 |
}
|
|
|
290 |
}
|
|
|
291 |
],
|
|
|
292 |
});
|
| 9403 |
eleazar |
293 |
|
| 2523 |
eleazar |
294 |
function getContent() {
|
| 2897 |
eleazar |
295 |
return $('[data-competency-behavior]').map(
|
| 2523 |
eleazar |
296 |
function (idx, td) {
|
| 2895 |
eleazar |
297 |
const competencyUuid = $(td).data('competency-uuid');
|
|
|
298 |
const behaviorUuid = $(td).data('behavior-uuid');
|
| 2523 |
eleazar |
299 |
const textarea = $(td).find('textarea');
|
|
|
300 |
const select = $(td).find('select');
|
| 2521 |
eleazar |
301 |
|
| 2523 |
eleazar |
302 |
return {
|
| 2895 |
eleazar |
303 |
competencyUuid: competencyUuid,
|
| 3468 |
eleazar |
304 |
behaviorUuid : behaviorUuid,
|
| 2523 |
eleazar |
305 |
comment: textarea.val(),
|
|
|
306 |
evaluation: select.val(),
|
|
|
307 |
}
|
|
|
308 |
}
|
|
|
309 |
).get()
|
|
|
310 |
}
|
|
|
311 |
|
| 8796 |
eleazar |
312 |
|
|
|
313 |
$('body').on('click', 'button.btn-evaluation', function(e) {
|
|
|
314 |
e.preventDefault();
|
|
|
315 |
NProgress.start();
|
|
|
316 |
var action = $(this).data('href');
|
|
|
317 |
window.location.href = action;
|
|
|
318 |
});
|
|
|
319 |
|
|
|
320 |
|
| 2537 |
eleazar |
321 |
var validator = $('#form-interview').validate({
|
| 1877 |
eleazar |
322 |
debug: true,
|
|
|
323 |
onclick: false,
|
|
|
324 |
onkeyup: false,
|
|
|
325 |
ignore: [],
|
| 2534 |
eleazar |
326 |
rules: {},
|
| 1877 |
eleazar |
327 |
submitHandler: function(form) {
|
|
|
328 |
$.ajax({
|
|
|
329 |
'dataType': 'json',
|
|
|
330 |
'accept': 'application/json',
|
|
|
331 |
'method': 'post',
|
| 7962 |
eleazar |
332 |
'url': $('#form-interview').attr('action').replaceAll('UUID_PLACEHOLDER', $('#vacancy_uuid').val()),
|
| 2523 |
eleazar |
333 |
'data': {
|
| 2571 |
eleazar |
334 |
content: JSON.stringify(getContent()),
|
| 2523 |
eleazar |
335 |
candidate_uuid: $('#candidate_uuid').val(),
|
| 2686 |
eleazar |
336 |
points: $('#points').val(),
|
| 2744 |
eleazar |
337 |
comment: $('#comment').val(),
|
| 2749 |
eleazar |
338 |
status: $('#status').val(),
|
| 2523 |
eleazar |
339 |
}
|
| 1877 |
eleazar |
340 |
}).done(function(response) {
|
|
|
341 |
NProgress.start();
|
|
|
342 |
if (response['success']) {
|
|
|
343 |
$.fn.showSuccess(response['data']);
|
| 3468 |
eleazar |
344 |
$('#main').hide();
|
| 3454 |
eleazar |
345 |
$('#interview').hide();
|
| 8778 |
eleazar |
346 |
gridTable.api().ajax.reload(null, false);
|
| 1877 |
eleazar |
347 |
} else {
|
|
|
348 |
validator.resetForm();
|
|
|
349 |
if (jQuery.type(response['data']) == 'string') {
|
|
|
350 |
$.fn.showError(response['data']);
|
|
|
351 |
} else {
|
|
|
352 |
$.each(response['data'], function(fieldname, errors) {
|
| 2531 |
eleazar |
353 |
$.fn.showFormErrorValidator('#interview #' + fieldname, errors);
|
| 1877 |
eleazar |
354 |
});
|
|
|
355 |
}
|
|
|
356 |
}
|
|
|
357 |
}).fail(function(jqXHR, textStatus, errorThrown) {
|
|
|
358 |
$.fn.showError(textStatus);
|
|
|
359 |
}).always(function() {
|
|
|
360 |
NProgress.done();
|
|
|
361 |
});
|
|
|
362 |
return false;
|
|
|
363 |
},
|
|
|
364 |
invalidHandler: function(form, validator) {}
|
|
|
365 |
});
|
| 1709 |
eleazar |
366 |
|
| 2015 |
eleazar |
367 |
$('body').on('click', 'button.btn-add', function(e) {
|
| 3631 |
eleazar |
368 |
$('#form-interview').attr('action', "$routeAdd")
|
| 3644 |
eleazar |
369 |
$('#candidate_uuid').prop('disabled', false);
|
|
|
370 |
$('#vacancy_uuid').prop('disabled', false);
|
|
|
371 |
$('#vacancy_uuid').change();
|
| 8768 |
eleazar |
372 |
$('#filter_vacancy_uuid').change();
|
| 3631 |
eleazar |
373 |
|
| 2015 |
eleazar |
374 |
e.preventDefault();
|
| 3631 |
eleazar |
375 |
|
| 2015 |
eleazar |
376 |
NProgress.start();
|
|
|
377 |
$.ajax({
|
|
|
378 |
'dataType': 'json',
|
|
|
379 |
'accept': 'application/json',
|
|
|
380 |
'method': 'get',
|
| 3631 |
eleazar |
381 |
'url': $(this).data('url'),
|
| 2015 |
eleazar |
382 |
}).done(function(response) {
|
|
|
383 |
if (response['success']) {
|
| 2237 |
eleazar |
384 |
var data = response.data
|
| 4159 |
eleazar |
385 |
$("#form-interview #comment").val('');
|
|
|
386 |
$('#form-interview #status').val('$status_acepted');
|
|
|
387 |
$("#form-interview #points").val('$points_0');
|
| 3466 |
eleazar |
388 |
$("#content").hide();
|
| 8677 |
eleazar |
389 |
$("#main").show();
|
|
|
390 |
validator.resetForm();
|
| 8676 |
eleazar |
391 |
$('#custom-tabs #custom-tabs-general-tab').tab('show');
|
| 8771 |
eleazar |
392 |
$('#candidate_uuid').change();
|
| 8768 |
eleazar |
393 |
$('#interview').show();
|
| 1877 |
eleazar |
394 |
} else {
|
| 2015 |
eleazar |
395 |
$.fn.showError(response['data']);
|
| 1877 |
eleazar |
396 |
}
|
| 2015 |
eleazar |
397 |
}).fail(function(jqXHR, textStatus, errorThrown) {
|
|
|
398 |
$.fn.showError(textStatus);
|
|
|
399 |
}).always(function() {
|
|
|
400 |
NProgress.done();
|
| 1877 |
eleazar |
401 |
});
|
| 2015 |
eleazar |
402 |
});
|
| 2785 |
eleazar |
403 |
|
|
|
404 |
$('body').on('click', 'button.btn-edit', function(e) {
|
| 3604 |
eleazar |
405 |
var url = $(this).data('href');
|
| 2785 |
eleazar |
406 |
e.preventDefault();
|
|
|
407 |
NProgress.start();
|
|
|
408 |
$.ajax({
|
|
|
409 |
'dataType': 'json',
|
|
|
410 |
'accept': 'application/json',
|
|
|
411 |
'method': 'get',
|
| 2807 |
eleazar |
412 |
'url': url,
|
| 2785 |
eleazar |
413 |
}).done(function(response) {
|
|
|
414 |
if (response['success']) {
|
|
|
415 |
var data = response.data
|
| 3635 |
eleazar |
416 |
$('#vacancy_uuid').val(data['vacancy']['uuid']);
|
| 3642 |
eleazar |
417 |
$('#vacancy_uuid').prop('disabled', true);
|
| 3640 |
eleazar |
418 |
$('#candidate_uuid').html('');
|
|
|
419 |
var option = $('<option />')
|
|
|
420 |
.val(data['candidate']['uuid'])
|
|
|
421 |
.text(data['candidate']['first_name'] + ' ' + data['candidate']['last_name']);
|
|
|
422 |
$('#candidate_uuid').append(option).prop('disabled', true);
|
| 3633 |
eleazar |
423 |
$("#form-interview #comment").val(data['interview']['comment']);
|
|
|
424 |
$('#form-interview #status').val(data['interview']['status']);
|
|
|
425 |
$("#form-interview #points").val(data['interview']['points']);
|
| 2785 |
eleazar |
426 |
$("#competencies-job").html($("#competenciesTemplate").render(data))
|
| 2887 |
eleazar |
427 |
data.interview.content.forEach(obj => {
|
| 2896 |
eleazar |
428 |
$('#textarea-' + obj.competencyUuid + '-' + obj.behaviorUuid).val(obj.comment);
|
|
|
429 |
$('#select-' + obj.competencyUuid + '-' + obj.behaviorUuid).val(obj.evaluation);
|
| 2887 |
eleazar |
430 |
})
|
| 2808 |
eleazar |
431 |
$("#form-interview").attr('action', url)
|
| 3468 |
eleazar |
432 |
$("#content").hide();
|
|
|
433 |
$("#main").show()
|
| 2785 |
eleazar |
434 |
} else {
|
|
|
435 |
$.fn.showError(response['data']);
|
|
|
436 |
}
|
|
|
437 |
}).fail(function(jqXHR, textStatus, errorThrown) {
|
|
|
438 |
$.fn.showError(textStatus);
|
|
|
439 |
}).always(function() {
|
|
|
440 |
NProgress.done();
|
|
|
441 |
});
|
|
|
442 |
});
|
| 2788 |
eleazar |
443 |
|
|
|
444 |
$('button.btn-delete').confirmation({
|
| 2887 |
eleazar |
445 |
rootSelector: 'button.btn-delete',
|
|
|
446 |
title: 'LABEL_ARE_YOU_SURE',
|
|
|
447 |
singleton: true,
|
|
|
448 |
btnOkLabel: 'LABEL_YES',
|
|
|
449 |
btnCancelLabel: 'LABEL_NO',
|
|
|
450 |
onConfirm: function (value) {
|
|
|
451 |
action = $(this).data('href');
|
|
|
452 |
NProgress.start();
|
|
|
453 |
$.ajax({
|
|
|
454 |
'dataType': 'json',
|
|
|
455 |
'accept': 'application/json',
|
|
|
456 |
'method': 'post',
|
|
|
457 |
'url': $(this).data('url'),
|
|
|
458 |
}).done(function (response) {
|
|
|
459 |
if (response['success']) {
|
|
|
460 |
$.fn.showSuccess(response['data']);
|
| 3468 |
eleazar |
461 |
gridTable.api().ajax.reload(null, false);
|
| 2887 |
eleazar |
462 |
} else {
|
|
|
463 |
$.fn.showError(response['data']);
|
|
|
464 |
}
|
|
|
465 |
}).fail(function (jqXHR, textStatus, errorThrown) {
|
|
|
466 |
$.fn.showError(textStatus);
|
|
|
467 |
}).always(function () {
|
|
|
468 |
NProgress.done();
|
| 2788 |
eleazar |
469 |
});
|
| 2887 |
eleazar |
470 |
},
|
|
|
471 |
});
|
| 3468 |
eleazar |
472 |
|
| 4363 |
eleazar |
473 |
|
| 7968 |
eleazar |
474 |
$('#filter_vacancy_uuid').change(function (e) {
|
| 4363 |
eleazar |
475 |
e.preventDefault();
|
|
|
476 |
|
|
|
477 |
var uuid = e.target.value;
|
|
|
478 |
|
|
|
479 |
gridTable.api().ajax.url("$routeIndex" + "/" + uuid);
|
|
|
480 |
gridTable.api().ajax.reload(null, false);
|
|
|
481 |
})
|
|
|
482 |
|
| 2015 |
eleazar |
483 |
$('body').on('click', 'button.btn-cancel', function(e) {
|
|
|
484 |
e.preventDefault();
|
| 2521 |
eleazar |
485 |
$('#main').show();
|
| 2015 |
eleazar |
486 |
$('#row-form').hide();
|
|
|
487 |
$('#div-listing').show();
|
|
|
488 |
});
|
| 3468 |
eleazar |
489 |
|
| 7967 |
eleazar |
490 |
$('#form-filter #filter_vacancy_uuid').change(function(e) {
|
| 2015 |
eleazar |
491 |
e.preventDefault();
|
| 3468 |
eleazar |
492 |
gridTable.api().ajax.reload(null, false);
|
| 2015 |
eleazar |
493 |
})
|
| 3468 |
eleazar |
494 |
|
| 2525 |
eleazar |
495 |
/**
|
|
|
496 |
* Clicked cancel new/edit Form
|
|
|
497 |
*/
|
|
|
498 |
$('button.btn-edit-cancel').click(function(e) {
|
|
|
499 |
e.preventDefault();
|
| 3468 |
eleazar |
500 |
$("#content").show();
|
|
|
501 |
$("#main").hide();
|
| 2525 |
eleazar |
502 |
});
|
|
|
503 |
/**
|
|
|
504 |
* Clicked save and continue new Form
|
|
|
505 |
*/
|
|
|
506 |
$('button.btn-form-save-continue').click(function(e) {
|
|
|
507 |
e.preventDefault();
|
| 4162 |
eleazar |
508 |
$('#form-interview #form-continue').val('1')
|
| 2540 |
eleazar |
509 |
$('#form-interview').submit();
|
| 2525 |
eleazar |
510 |
});
|
|
|
511 |
/**
|
|
|
512 |
* Clicked save and close new/edit Form
|
|
|
513 |
*/
|
|
|
514 |
$('button.btn-form-save-close').click(function(e) {
|
|
|
515 |
e.preventDefault();
|
| 4162 |
eleazar |
516 |
$('#form-interview #form-continue').val('0')
|
| 3468 |
eleazar |
517 |
$("#content").show();
|
|
|
518 |
$("#main").hide();
|
| 2540 |
eleazar |
519 |
$('#form-interview').submit();
|
| 4157 |
eleazar |
520 |
gridTable.api().ajax.reload(null, false);
|
| 2525 |
eleazar |
521 |
});
|
| 3120 |
eleazar |
522 |
|
| 3571 |
eleazar |
523 |
$('#vacancy_uuid').on('change', function (event) {
|
| 8777 |
eleazar |
524 |
|
| 6227 |
eleazar |
525 |
$('#candidate_uuid').html('');
|
| 3571 |
eleazar |
526 |
var uuid = event.target.value;
|
| 3463 |
eleazar |
527 |
|
| 3571 |
eleazar |
528 |
$.ajax({
|
|
|
529 |
'dataType': 'json',
|
|
|
530 |
'accept': 'application/json',
|
|
|
531 |
'method': 'get',
|
|
|
532 |
'url': String('$routeVacancy').replaceAll('UUID_PLACEHOLDER', uuid),
|
|
|
533 |
}).done(function (response) {
|
|
|
534 |
var data = response.data
|
| 8777 |
eleazar |
535 |
$('#candidate_uuid').change();
|
| 3590 |
eleazar |
536 |
$('#job-description').html($('#job-description-template').render(data));
|
| 3589 |
eleazar |
537 |
$("#competencies-job").html($("#competenciesTemplate").render(data))
|
| 3571 |
eleazar |
538 |
data.candidates.forEach(function (candidate) {
|
|
|
539 |
var option = $('<option />')
|
|
|
540 |
.val(candidate.uuid)
|
|
|
541 |
.text(candidate.first_name)
|
|
|
542 |
.data('addUrl', candidate.add_url)
|
|
|
543 |
.data('editUrl', candidate.edit_url)
|
|
|
544 |
.data('deleteUrl', candidate.delete_url)
|
|
|
545 |
.data('reportUrl', candidate.report_url)
|
| 2038 |
eleazar |
546 |
|
| 3571 |
eleazar |
547 |
$('#candidate_uuid').append(option);
|
|
|
548 |
});
|
|
|
549 |
})
|
| 7954 |
eleazar |
550 |
|
| 3571 |
eleazar |
551 |
});
|
| 2052 |
eleazar |
552 |
|
| 4365 |
eleazar |
553 |
$('#candidate_uuid').on('change', function(event){
|
|
|
554 |
|
|
|
555 |
var uuid = event.target.value;
|
|
|
556 |
|
|
|
557 |
$.ajax({
|
|
|
558 |
'dataType' : 'json',
|
|
|
559 |
'accept' : 'aplication/json',
|
|
|
560 |
'method' : 'get',
|
| 4367 |
eleazar |
561 |
'url': String('$routeType').replaceAll('UUID_PLACEHOLDER', uuid),
|
| 4371 |
eleazar |
562 |
}).done(function (response) {
|
| 4369 |
eleazar |
563 |
$('#interview').html(response.data);
|
| 4365 |
eleazar |
564 |
})
|
|
|
565 |
})
|
|
|
566 |
|
| 3571 |
eleazar |
567 |
$('#vacancy_uuid').change();
|
| 7954 |
eleazar |
568 |
$('#candidate_uuid').change();
|
| 4364 |
eleazar |
569 |
$('#filter_vacancy_uuid').change();
|
| 2785 |
eleazar |
570 |
|
| 3341 |
eleazar |
571 |
});
|
| 1709 |
eleazar |
572 |
JS;
|
|
|
573 |
$this->inlineScript()->captureEnd();
|
| 10425 |
stevensc |
574 |
|
| 10428 |
stevensc |
575 |
$jsonVacancies = json_encode($vacancies);
|
|
|
576 |
|
| 10425 |
stevensc |
577 |
$js = <<<JS
|
|
|
578 |
const backendVariables= {
|
|
|
579 |
add_link: "$routeAdd",
|
|
|
580 |
vacancy_link: "$routeVacancy",
|
|
|
581 |
type_link: "$routeType",
|
|
|
582 |
table_link: "$routeIndex",
|
| 10432 |
stevensc |
583 |
vacancies: $jsonVacancies,
|
| 10425 |
stevensc |
584 |
permisions: {
|
|
|
585 |
allowAdd: $allowAdd,
|
|
|
586 |
allowEdit: $allowEdit,
|
|
|
587 |
allowDelete: $allowDelete,
|
|
|
588 |
allowReport: $allowReport,
|
|
|
589 |
allowFile: $allowFile
|
|
|
590 |
}
|
|
|
591 |
}
|
|
|
592 |
JS;
|
|
|
593 |
|
|
|
594 |
$this->inlineScript()->appendScript($js);
|
|
|
595 |
$this->inlineScript()->appendFile('/react-bundles/recruitment_and_selection/interviews/interviewsBundle.js');
|
| 1709 |
eleazar |
596 |
?>
|
|
|
597 |
|
| 3468 |
eleazar |
598 |
|
| 3460 |
eleazar |
599 |
<!-- Content Header (Page header) -->
|
| 10425 |
stevensc |
600 |
<div id="recruitment_and_selection-interview">
|
|
|
601 |
</div>
|
|
|
602 |
|
| 3460 |
eleazar |
603 |
<section class="main-header">
|
|
|
604 |
<div class="container-fluid">
|
|
|
605 |
<div class="row mb-2">
|
|
|
606 |
<div class="col-sm-12">
|
|
|
607 |
<h1>LABEL_INTERVIEW</h1>
|
|
|
608 |
</div>
|
|
|
609 |
</div>
|
|
|
610 |
</div><!-- /.container-fluid -->
|
|
|
611 |
</section>
|
| 1709 |
eleazar |
612 |
|
| 3460 |
eleazar |
613 |
<section id="content">
|
|
|
614 |
<div class="container-fluid">
|
|
|
615 |
<div class="row">
|
|
|
616 |
<div class="col-12">
|
|
|
617 |
<div class="card">
|
|
|
618 |
<div class="card-header">
|
| 4346 |
eleazar |
619 |
<div class="col-md-6 col-sm-12">
|
|
|
620 |
<div class="form-group">
|
|
|
621 |
<label for="vacancy_uuid">LABEL_VACANCIES</label>
|
| 4347 |
eleazar |
622 |
<select id="filter_vacancy_uuid" name="vacancy_uuid" class="form-control">
|
| 4346 |
eleazar |
623 |
<?php foreach($this->vacancies as $vacancy): ?>
|
|
|
624 |
<option value="<?= $vacancy->uuid ?>"><?= $vacancy->name ?></option>
|
|
|
625 |
<?php endforeach; ?>
|
|
|
626 |
</select>
|
|
|
627 |
</div>
|
|
|
628 |
</div>
|
| 3460 |
eleazar |
629 |
<?php echo $this->form()->closeTag($form); ?>
|
|
|
630 |
</div>
|
|
|
631 |
<div class="card-body">
|
|
|
632 |
<table id="gridTable" class="table table-hover">
|
|
|
633 |
<thead>
|
|
|
634 |
<tr>
|
|
|
635 |
<th>LABEL_FIRST_NAME</th>
|
|
|
636 |
<th>LABEL_EMAIL</th>
|
| 3547 |
eleazar |
637 |
<th>LABEL_TYPE_INTERVIEW</th>
|
| 3882 |
eleazar |
638 |
<th>LABEL_VACANCIES</th>
|
| 8888 |
eleazar |
639 |
<th>LABEL_EVALUATION</th>
|
| 3460 |
eleazar |
640 |
<th>LABEL_ACTIONS</th>
|
|
|
641 |
</tr>
|
|
|
642 |
</thead>
|
|
|
643 |
<tbody>
|
|
|
644 |
</tbody>
|
|
|
645 |
</table>
|
|
|
646 |
</div>
|
|
|
647 |
<div class="card-footer clearfix">
|
|
|
648 |
<div style="float:right;">
|
|
|
649 |
<button id="add-button" type="button" class="btn btn-primary btn-add"><i class="fa fa-plus"></i> LABEL_ADD </button>
|
|
|
650 |
</div>
|
|
|
651 |
</div>
|
|
|
652 |
</div>
|
|
|
653 |
</div>
|
|
|
654 |
</div>
|
|
|
655 |
</div>
|
|
|
656 |
</section>
|
|
|
657 |
|
| 3459 |
eleazar |
658 |
<section id="main" style="display: none;">
|
| 3451 |
eleazar |
659 |
<div class="container-fluid">
|
| 4165 |
eleazar |
660 |
|
| 4162 |
eleazar |
661 |
<div class="row p-2">
|
|
|
662 |
<div class="col-12">
|
|
|
663 |
<?php
|
|
|
664 |
$form->setAttributes([
|
|
|
665 |
'method' => 'post',
|
|
|
666 |
'name' => 'form-interview',
|
|
|
667 |
'id' => 'form-interview',
|
|
|
668 |
'action' => $routeAdd
|
|
|
669 |
]);
|
|
|
670 |
$form->prepare();
|
|
|
671 |
echo $this->form()->openTag($form);
|
|
|
672 |
?>
|
|
|
673 |
<div class="card">
|
|
|
674 |
<ul class="nav nav-tabs" id="custom-tabs" role="tablist">
|
|
|
675 |
<li class="nav-item" role="presentation">
|
|
|
676 |
<a class="nav-link active" id="custom-tabs-general-tab" data-toggle="tab" href="#custom-tabs-general" role="tab" aria-controls="custom-tabs-general" aria-selected="true">LABEL_GENERAL</a>
|
|
|
677 |
</li>
|
|
|
678 |
<li class="nav-item" role="presentation">
|
|
|
679 |
<a class="nav-link" id="custom-tabs-compentencies-tab" data-toggle="tab" href="#custom-tabs-compentencies" role="tab" aria-controls="custom-tabs-compentencies" aria-selected="false">LABEL_COMPETENCIES</a>
|
|
|
680 |
</li>
|
|
|
681 |
<li class="nav-item" role="presentation">
|
|
|
682 |
<a class="nav-link" id="custom-tabs-evaluation-tab" data-toggle="tab" href="#custom-tabs-evaluation" role="tab" aria-controls="custom-tabs-evaluation" aria-selected="false">LABEL_CONCLUTION</a>
|
|
|
683 |
</li>
|
|
|
684 |
</ul>
|
| 3459 |
eleazar |
685 |
|
| 4162 |
eleazar |
686 |
<div class="tab-content">
|
|
|
687 |
<div class="tab-pane fade show active" id="custom-tabs-general" role="tabpanel" aria-labelledby="custom-tabs-general-tab">
|
|
|
688 |
<div class="row">
|
|
|
689 |
<div class="col-md-6 col-sm-12">
|
|
|
690 |
<div class="form-group">
|
|
|
691 |
<label for="vacancy_uuid">LABEL_VACANCIES</label>
|
|
|
692 |
<select id="vacancy_uuid" name="vacancy_uuid" class="form-control">
|
|
|
693 |
<?php foreach($this->vacancies as $vacancy): ?>
|
|
|
694 |
<option value="<?= $vacancy->uuid ?>"><?= $vacancy->name ?></option>
|
|
|
695 |
<?php endforeach; ?>
|
|
|
696 |
</select>
|
|
|
697 |
</div>
|
| 3459 |
eleazar |
698 |
</div>
|
| 4162 |
eleazar |
699 |
<div class="col-md-6 col-sm-12">
|
|
|
700 |
<div class="form-group">
|
|
|
701 |
<label for="candidate_uuid">LABEL_CANDIDATES</label>
|
|
|
702 |
<select id="candidate_uuid" name="candidate_uuid" class="form-control">
|
|
|
703 |
</select>
|
|
|
704 |
</div>
|
| 3482 |
eleazar |
705 |
</div>
|
| 4162 |
eleazar |
706 |
|
| 3481 |
eleazar |
707 |
</div>
|
|
|
708 |
|
| 8327 |
eleazar |
709 |
<div class="p-2">
|
| 8326 |
eleazar |
710 |
<h5 id="interview"></h5>
|
|
|
711 |
<div id="job-description"></div>
|
|
|
712 |
</div>
|
| 3459 |
eleazar |
713 |
</div>
|
| 4162 |
eleazar |
714 |
<div class="tab-pane fade" id="custom-tabs-compentencies" role="tabpanel" aria-labelledby="custom-tabs-compentencies-tab">
|
|
|
715 |
<div class="row p-2">
|
|
|
716 |
<div class="col-md-12 col-sm-12 col-xs-12" id="competencies-job" style="margin-top: 1px;">
|
|
|
717 |
</div>
|
|
|
718 |
</div>
|
|
|
719 |
</div>
|
|
|
720 |
<div class="tab-pane fade" id="custom-tabs-evaluation" role="tabpanel" aria-labelledby="custom-tabs-evaluation-tab">
|
|
|
721 |
<div class="row p-2">
|
|
|
722 |
<div class="col-12">
|
|
|
723 |
<div class="form-group">
|
|
|
724 |
<?php
|
|
|
725 |
$element = $form->get('comment');
|
|
|
726 |
$element->setOptions(['label' => 'LABEL_COMMENT']);
|
|
|
727 |
$element->setAttributes(['class' => 'form-control']);
|
|
|
728 |
echo $this->formLabel($element);
|
|
|
729 |
echo $this->formText($element);
|
|
|
730 |
?>
|
|
|
731 |
</div>
|
|
|
732 |
<div class="form-group">
|
|
|
733 |
<?php
|
|
|
734 |
$element = $form->get('points');
|
|
|
735 |
$element->setAttributes(['class' => 'form-control']);
|
|
|
736 |
$element->setOptions(['label' => 'LABEL_EVALUATION']);
|
|
|
737 |
echo $this->formLabel($element);
|
|
|
738 |
echo $this->formSelect($element);
|
|
|
739 |
?>
|
|
|
740 |
</div>
|
|
|
741 |
<div class="form-group">
|
|
|
742 |
<?php
|
|
|
743 |
$element = $form->get('status');
|
|
|
744 |
$element->setAttributes(['class' => 'form-control']);
|
|
|
745 |
$element->setOptions(['label' => 'LABEL_STATUS']);
|
|
|
746 |
echo $this->formLabel($element);
|
|
|
747 |
echo $this->formSelect($element);
|
|
|
748 |
?>
|
|
|
749 |
</div>
|
| 3459 |
eleazar |
750 |
</div>
|
|
|
751 |
</div>
|
|
|
752 |
</div>
|
| 4162 |
eleazar |
753 |
<div class="card-footer clearfix">
|
| 4372 |
eleazar |
754 |
<button type="submit" style="display:none;" form="form-main" class="btn btn-info btn-form-save-continue">LABEL_SAVE & LABEL_CONTINUE</button>
|
| 4162 |
eleazar |
755 |
<button type="button" class="btn btn-primary btn-form-save-close">LABEL_SAVE & LABEL_CLOSE</button>
|
|
|
756 |
<button type="button" class="btn btn-secondary btn-edit-cancel">LABEL_CANCEL</button>
|
|
|
757 |
</div>
|
|
|
758 |
</div>
|
|
|
759 |
</div>
|
|
|
760 |
<?php echo $this->form()->closeTag($form); ?>
|
|
|
761 |
</div>
|
| 3062 |
eleazar |
762 |
</div>
|
| 4165 |
eleazar |
763 |
|
| 2015 |
eleazar |
764 |
</div>
|
|
|
765 |
</section>
|
| 2052 |
eleazar |
766 |
|
|
|
767 |
<script id="job-description-template" type="text/x-jsrender">
|
| 8326 |
eleazar |
768 |
<div class="card">
|
|
|
769 |
<div class="card-body">
|
| 2052 |
eleazar |
770 |
<h5 class="card-title">{{:job_description.name}}</h5>
|
|
|
771 |
<p class="card-text">{{:vacancy.description}}</p>
|
| 2214 |
eleazar |
772 |
<p class="card-text">{{:job_description.objectives}}</p>
|
|
|
773 |
<p class="card-text">{{:job_description.functions}}</p>
|
| 8278 |
eleazar |
774 |
</div>
|
|
|
775 |
</div>
|
| 2061 |
eleazar |
776 |
</script>
|
|
|
777 |
|
| 3459 |
eleazar |
778 |
<script id="competenciesTemplate" type="text/x-jsrender">
|
|
|
779 |
<table class="table table-bordered" id="panel-{{:slug_section}}">
|
| 3649 |
eleazar |
780 |
|
| 3459 |
eleazar |
781 |
<tbody>
|
|
|
782 |
{{for job_description.competencies}}
|
|
|
783 |
<tr>
|
| 8733 |
eleazar |
784 |
<td colspan="2" class="text-left">{{:competency_name}} - {{:competency_type_name}}</td>
|
| 3459 |
eleazar |
785 |
</tr>
|
|
|
786 |
|
|
|
787 |
{{for behaviors}}
|
|
|
788 |
<tr>
|
|
|
789 |
<td colspan="2">
|
| 3649 |
eleazar |
790 |
<table class="table table-bordered">
|
|
|
791 |
<thead>
|
| 3459 |
eleazar |
792 |
<tr>
|
| 3652 |
eleazar |
793 |
<th style="width: 20%;">LABEL_CONDUCT</th>
|
| 3649 |
eleazar |
794 |
<th style="width: 60%;">LABEL_COMMENT</th>
|
|
|
795 |
<th style="width: 20%;">LABEL_EVALUATION</th>
|
|
|
796 |
</tr>
|
|
|
797 |
</thead>
|
| 4090 |
eleazar |
798 |
<tr data-competency-behavior data-competency-uuid="{{:competency_uuid}}" data-behavior-uuid="{{:uuid}}">
|
|
|
799 |
<td class="text-left" style="width: 20%;">
|
| 3459 |
eleazar |
800 |
{{:description}}
|
|
|
801 |
</td>
|
| 4089 |
eleazar |
802 |
<td style="width: 60%;">
|
| 3459 |
eleazar |
803 |
|
|
|
804 |
<textarea
|
|
|
805 |
id="textarea-{{:competency_uuid}}-{{:uuid}}"
|
|
|
806 |
class="form-control"
|
|
|
807 |
></textarea>
|
| 3473 |
eleazar |
808 |
</td>
|
| 4090 |
eleazar |
809 |
<td style="width: 20%;">
|
|
|
810 |
|
| 4069 |
eleazar |
811 |
<select class="form-control" id="select-{{:competency_uuid}}-{{:uuid}}">
|
| 4219 |
eleazar |
812 |
<option value="<?= $points_0 ?>"><?= '0%' ?></option>
|
|
|
813 |
<option value="<?= $points_1 ?>"><?= '25%' ?></option>
|
|
|
814 |
<option value="<?= $points_2 ?>"><?= '50%' ?></option>
|
|
|
815 |
<option value="<?= $points_3 ?>"><?= '75%' ?></option>
|
|
|
816 |
<option value="<?= $points_4 ?>"><?= '100%' ?></option>
|
| 4090 |
eleazar |
817 |
</select>
|
| 3459 |
eleazar |
818 |
</td>
|
|
|
819 |
</tr>
|
|
|
820 |
</table>
|
|
|
821 |
</td>
|
|
|
822 |
</tr>
|
|
|
823 |
{{/for}}
|
|
|
824 |
{{/for}}
|
|
|
825 |
</tbody>
|
|
|
826 |
</table>
|
| 3468 |
eleazar |
827 |
</script>
|