Línea 246... |
Línea 246... |
246 |
$('#form-main #job_description_id').val(response['data']['job_description_id']).trigger('change');
|
246 |
$('#form-main #job_description_id').val(response['data']['job_description_id']).trigger('change');
|
247 |
$('#form-main #location_search').val(response['data']['location_search']);
|
247 |
$('#form-main #location_search').val(response['data']['location_search']);
|
248 |
$('#form-main #job_category_id').val(response['data']['job_category_id']).trigger('change');
|
248 |
$('#form-main #job_category_id').val(response['data']['job_category_id']).trigger('change');
|
249 |
$('#form-main #industry_id').val(response['data']['industry_id']).trigger('change');
|
249 |
$('#form-main #industry_id').val(response['data']['industry_id']).trigger('change');
|
250 |
$('#form-main #form-status').val(response['data']['status']);
|
250 |
$('#form-main #form-status').val(response['data']['status']);
|
251 |
CKEDITOR.instances['form-description'].setData(response['data']['description']);
|
251 |
CKEDITOR.instances['description'].setData(response['data']['description']);
|
Línea 252... |
Línea 252... |
252 |
|
252 |
|
253 |
|
253 |
|
254 |
} else {
|
254 |
} else {
|
Línea 270... |
Línea 270... |
270 |
$('#form-main #form-name').val('');
|
270 |
$('#form-main #form-name').val('');
|
271 |
$('#form-main #job_description_id').val('').trigger('change');
|
271 |
$('#form-main #job_description_id').val('').trigger('change');
|
272 |
$('#form-main #location_search').val('');
|
272 |
$('#form-main #location_search').val('');
|
273 |
$('#form-main #job_category_id').val('').trigger('change');
|
273 |
$('#form-main #job_category_id').val('').trigger('change');
|
274 |
$('#form-main #industry_id').val('').trigger('change');
|
274 |
$('#form-main #industry_id').val('').trigger('change');
|
275 |
$('#form-main #description').val('');
|
- |
|
276 |
$('#form-main #form-date').val('');
|
275 |
$('#form-main #form-date').val('');
|
277 |
$('#form-main #form-status').val('$status_active');
|
276 |
$('#form-main #form-status').val('$status_active');
|
278 |
CKEDITOR.instances['form-description'].setData('');
|
277 |
CKEDITOR.instances['description'].setData('');
|
279 |
$('#row-lists').hide();
|
278 |
$('#row-lists').hide();
|
280 |
$('#row-form').show();
|
279 |
$('#row-form').show();
|
281 |
$('#form-main #form-name').focus();
|
280 |
$('#form-main #form-name').focus();
|
282 |
return;
|
281 |
return;
|
283 |
});
|
282 |
});
|
Línea 380... |
Línea 379... |
380 |
* Save Form Data
|
379 |
* Save Form Data
|
381 |
*/
|
380 |
*/
|
382 |
const saveData = (action) => {
|
381 |
const saveData = (action) => {
|
383 |
if ($('#form-name').val() == '') {
|
382 |
if ($('#form-name').val() == '') {
|
384 |
$.fn.showError('ERROR_ENTER_NAME');
|
383 |
$.fn.showError('ERROR_ENTER_NAME');
|
385 |
} else if ($('#form-description').val() == '') {
|
384 |
} else if ($('#description').val() == '') {
|
386 |
$.fn.showError('ERROR_ENTER_DESCRIPTION');
|
385 |
$.fn.showError('ERROR_ENTER_DESCRIPTION');
|
387 |
} else if ($('#form-category').val() == '') {
|
386 |
} else if ($('#form-category').val() == '') {
|
388 |
$.fn.showError('ERROR_ENTER_CATEGORY');
|
387 |
$.fn.showError('ERROR_ENTER_CATEGORY');
|
389 |
} else if ($('#form-industry').val() == '') {
|
388 |
} else if ($('#form-industry').val() == '') {
|
390 |
$.fn.showError('ERROR_ENTER_INDUSTRY');
|
389 |
$.fn.showError('ERROR_ENTER_INDUSTRY');
|