first commit

This commit is contained in:
2024-11-11 15:28:20 +01:00
commit 3f5649dbc7
6231 changed files with 999089 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
<? global $lang;?>
<div class="mini-buttons" id="buttons">
<a href="/panel-pracodawcy/profil" class="btn <?= $this -> active == 'moj-profil' ? 'active' : '';?>">
<?= $lang['moj-profil'];?>
</a>
<a href="/panel-pracodawcy/ogloszenia" class="btn <?= $this -> active == 'ogloszenia' ? 'active' : '';?>">
<?= $lang['ogloszenia'];?>
</a>
<a href="/panel-pracodawcy/odpowiedzi-na-ogloszenia" class="btn <?= $this -> active == 'cv' ? 'active' : '';?>">
CV
</a>
<a href="/panel-pracodawcy/proponowani-kandydaci" class="btn btn-red <?= $this -> active == 'proponowani-kandydaci' ? 'active' : '';?>">
proponowani kandydaci
</a>
<a href="/panel-pracodawcy/obserwowani-kandydaci" class="btn <?= $this -> active == 'obserwowani-kandydaci' ? 'active' : '';?>" style="display:none;">
<?= $lang['obserwowani-kandydaci'];?>
</a>
<a href="/panel-pracodawcy/ustawienia-konta" class="btn <?= $this -> active == 'ustawienia-konta' ? 'active' : '';?>">
<?= $lang['ustawienia-konta'];?>
</a>
<a href="/panel-pracodawcy/zakup-punktow" class="btn <?= $this -> active == 'zakup-punktow' ? 'active' : '';?>">
zakup punktów
</a>
</div>

View File

@@ -0,0 +1,609 @@
<? global $lang, $globelus_settings; ?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'ogloszenia'
] );?>
</div>
<div class="mini-box fluid">
<div class="title">
<?= ucfirst($lang['dodaj-ogloszenie']); ?>
<span class="pull-right text-danger small">
Posiadasz <?= (int)$this->user_points; ?> pkt. <a href="/panel-pracodawcy/zakup-punktow">Doładuj konto.</a>
</span>
</div>
<div class="container-fluid">
<div class="row">
<div class="col-12">
<div class="content profil">
<form id="advert-add" method="POST" action="/globelusFirms/advert_save/" enctype="multipart/form-data">
<input type="hidden" name="id" value="<?= $this->advert['id']; ?>">
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="title" class="col-12 col-sm-4"><?= ucfirst($lang['tytul-ogloszenia']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" required id="title" name="title" class="form-control" value="<?= htmlspecialchars($this->advert['title']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="category" class="col-12 col-sm-4"><?= ucfirst($lang['branza']); ?>:</label>
<div class="col-12 col-sm-8">
<select name="category" id="category" required class="form-control">
<option value="">--- <?= $lang['wybierz']; ?> ---</option>
<?
$categories = \front\factory\GlobelusAdverts::categories();
if (is_array($categories)) : foreach ($categories as $category) : ?>
<option value="<?= $category['id']; ?>" <? if ($category['id'] == $this->advert['category_id']) : ?>selected="selected" <? endif; ?>><?= $category['name']; ?></option>
<? endforeach;
endif;
?>
</select>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="position" class="col-12 col-sm-4">Stanowisko:</label>
<div class="col-12 col-sm-8">
<select name="position" id="position" required class="form-control">
<option value="">--- <?= $lang['wybierz']; ?> ---</option>
<? if ( is_array( $this -> positions ) ): foreach ( $this -> positions as $position ):?>
<option value="<?= $position['id']; ?>" <? if ( $position['id'] == $this -> advert['id_position'] ):?>selected="selected" <? endif; ?>><?= htmlspecialchars( $position['name'] );?></option>
<? endforeach; endif;?>
</select>
</div>
</div>
</div>
</div>
<hr />
<div class="step-title"><?= ucfirst($lang['miejsce-zatrudnienia']); ?></div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="country" class="col-12 col-sm-4"><?= ucfirst($lang['kraj']); ?>:</label>
<div class="col-12 col-sm-8">
<select name="country" id="country" required class="form-control">
<option value="">--- <?= $lang['wybierz']; ?> ---</option>
<?
$countries = \front\factory\Globelus::countries();
if (is_array($countries)) : foreach ($countries as $country) :
if ($country['name'] != '- dowolny -') : ?>
<option value="<?= $country['id']; ?>" <? if ($country['id'] == $this->advert['country_id']) : ?>selected="selected" <? endif; ?>><?= $country['name']; ?></option>
<? endif;
endforeach;
endif;
?>
</select>
</div>
</div>
</div>
</div>
<div class="row voivodeship">
<div class="col-12">
<div class="form-group row">
<label form="region" class="col-12 col-sm-4"><?= ucfirst($lang['region']); ?>/<?= ucfirst($lang['wojewodztwo']); ?>:</label>
<div class="col-12 col-sm-8">
<select name="id_voivodeship" id="id_voivodeship" class="form-control">
<option value="">--- wybierz województwo ---</option>
<? foreach ($this->voivodeships as $voivodeship) : ?>
<option value="<?= $voivodeship['id']; ?>" <? if ($voivodeship['id'] == $this->advert['id_voivodeship']) : ?>selected="selected" <? endif; ?>><?= $voivodeship['name']; ?></option>
<? endforeach; ?>
</select>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="city" class="col-12 col-sm-4"><?= ucfirst($lang['miasto']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" required name="city" value="<?= htmlspecialchars($this->advert['city']); ?>">
</div>
</div>
</div>
</div>
<hr />
<div class="step-title"><?= ucfirst(\S::lang('dodatkowe-informacje')); ?></div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="region" class="col-12 col-sm-4"><?= ucfirst(\S::lang('proponowane-wynagrodzenie')); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control number" name="salary" value="<?= htmlspecialchars($this->advert['salary']); ?>" required="required">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="work_type" class="col-12 col-sm-4"><?= ucfirst(\S::lang('rodzaj-pracy')); ?>:</label>
<div class="col-12 col-sm-8">
<select name="work_type" class="form-control" required="required">
<option value="0">--- <?= $lang['wybierz']; ?> ---</option>
<?
$types = \front\factory\Globelus::work_types();
if (is_array($types)) : foreach ($types as $key => $val) : ?>
<option value="<?= $key; ?>" <? if ($key == $this->advert['work_type']) : ?>selected="selected" <? endif; ?>><?= $val; ?></option>
<? endforeach;
endif;
?>
</select>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="without_language" class="col-12 col-sm-4"><?= ucfirst(\S::lang('oferta-dla-osob-bez-znajomosc-jezyka')); ?>:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="without_language" value="0" class="checkbox" <? if (!$this->advert['without_language']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="without_language" value="1" class="checkbox" <? if ($this->advert['without_language']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="without_experience" class="col-12 col-sm-4"><?= ucfirst(\S::lang('oferta-dla-osob-bez-doswiadczenia')); ?>:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="without_experience" value="0" class="checkbox" <? if (!$this->advert['without_experience']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="without_experience" value="1" class="checkbox" <? if ($this->advert['without_experience']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="for_couples" class="col-12 col-sm-4"><?= ucfirst(\S::lang('oferta-dla-par')); ?>:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="for_couples" value="0" class="checkbox" <? if (!$this->advert['for_couples']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="for_couples" value="1" class="checkbox" <? if ($this->advert['for_couples']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="from_now" class="col-12 col-sm-4">Pomoc z zakwaterowaniem?:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="accommodation" value="0" class="checkbox accommodation" <? if (!$this->advert['accommodation']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="accommodation" value="1" class="checkbox accommodation" <? if ($this->advert['accommodation']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="accommodation_cost" class="col-12 col-sm-4">Jaki koszt dla pracownika?:</label>
<div class="col-12 col-sm-8 pt7">
<input type="text" class="form-control" name="accommodation_cost" id="accommodation_cost" value="<?= htmlspecialchars($this->advert['accommodation_cost']); ?>" <? if ($this->advert['travel_refund']) : ?>required="required" <? endif; ?>>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="overtime" class="col-12 col-sm-4">Gwarancja godzin:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="overtime" value="0" class="checkbox overtime" <? if (!$this->advert['overtime']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="overtime" value="1" class="checkbox overtime" <? if ($this->advert['overtime']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="overtime_quantity" class="col-12 col-sm-4">Ile godzin gwarantuje pracodawca?:</label>
<div class="col-12 col-sm-8 pt7">
<input type="text" class="form-control" id="overtime_quantity" name="overtime_quantity" value="<?= htmlspecialchars($this->advert['overtime_quantity']); ?>" <? if ($this->advert['overtime']) : ?>required="required" <? endif; ?>>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="travel_refund" class="col-12 col-sm-4">Pracodawca refunduje przejazd/przelot:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="travel_refund" value="0" class="checkbox" <? if (!$this->advert['travel_refund']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="travel_refund" value="1" class="checkbox" <? if ($this->advert['travel_refund']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="outside_ue" class="col-12 col-sm-4">Praca dla obywateli spoza UE:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="outside_ue" value="0" class="checkbox" <? if (!$this->advert['outside_ue']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="outside_ue" value="1" class="checkbox" <? if ($this->advert['outside_ue']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="without_driving_license" class="col-12 col-sm-4">Oferta bez prawa jazdy:</label>
<div class="col-12 col-sm-8 pt7">
<input type="radio" name="without_driving_license" value="0" class="checkbox" <? if (!$this->advert['without_driving_license']) : ?>checked="checked" <? endif; ?> />nie
<input type="radio" name="without_driving_license" value="1" class="checkbox" <? if ($this->advert['without_driving_license']) : ?>checked="checked" <? endif; ?> />tak
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
Zdjęcie nad ogłoszeniem
<br>
<span>
<small>Ważna informacja: jeśli chcesz, aby ta grafika była widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu dodaj ją w Profilu Pracodawcy.</small>
</span>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="advert-img-top" class="col-12 col-sm-4">Zdjęcie (max. 1mb):</label>
<div class="col-12 col-sm-8 pt10">
<input type="file" id="advert-img-top" name="advert-img-top">
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="advert-img-top">
<? if (file_exists(\front\factory\GlobelusFirms::advert_add_img_top_url($this->advert['id']))) :?>
<img src="/advert_add_img_top/<?= $this->advert['id']; ?>/<?= \S::get_token(); ?>" style="max-width: 200px;">
<a class="btn btn-danger advert-img-top_delete" href="#">Usuń zdjęcie</a>
<? endif; ?>
</div>
</div>
</div>
</hr>
<hr>
<div class="step-title">
Zdjęcie pod ogłoszeniem
<br>
<span>
<small>Ważna informacja: jeśli chcesz, aby ta grafika była widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu dodaj ją w Profilu Pracodawcy.</small>
</span>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="advert-img-bottom" class="col-12 col-sm-4">Zdjęcie (max. 1mb):</label>
<div class="col-12 col-sm-8 pt10">
<input type="file" id="advert-img-bottom" name="advert-img-bottom">
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="advert-img-bottom">
<? if (file_exists(\front\factory\GlobelusFirms::advert_add_img_bottom_url($this->advert['id']))) :?>
<img src="/advert_add_img_bottom/<?= $this->advert['id']; ?>/<?= \S::get_token(); ?>" style="max-width: 200px;">
<a class="btn btn-danger advert-img-bottom_delete" href="#">Usuń zdjęcie</a>
<? endif; ?>
</div>
</div>
</div>
</hr>
<hr>
<div class="step-title"><?= ucfirst($lang['tresc-ogloszenia-opis-wymagania']); ?></div>
<div class="subtitle warrning"><?= ucfirst($lang['tresc-ogloszenia-ostrzezenie']); ?></div>
<div class="row">
<div class="col-12">
<textarea name="text" id="text"><?= $this->advert['text']; ?></textarea>
<p class="hidden editor-error">Proszę uzupełnić treść ogłoszenia.</p>
</div>
</div>
<div class="row mt-3">
<div class="col-12">
<div class="form-group row">
<label form="application_link" class="col-12 col-sm-4">Link do własnego formularza aplikacji:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="aplication_link" value="<?= htmlspecialchars($this->advert['aplication_link']);?>">
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">Osoba rekrutująca na stanowisko</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="contact_person" class="col-12 col-sm-4"><?= ucfirst($lang['osoba-do-kontaktu']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="contact_person" value="<?= $this->advert['id'] ? htmlspecialchars($this->advert['contact_person']) : htmlspecialchars($this->user['contact_person_1']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="email" class="col-12 col-sm-4"><?= ucfirst($lang['email']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="email" value="<?= $this->advert['id'] ? htmlspecialchars($this->advert['email']) : htmlspecialchars($this->user['email_1']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="phone" class="col-12 col-sm-4"><?= ucfirst($lang['telefon']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="phone" value="<?= $this->advert['id'] ? htmlspecialchars($this->advert['phone']) : htmlspecialchars($this->user['phone_1']); ?>">
</div>
</div>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="contact_person2" class="col-12 col-sm-4"><?= ucfirst($lang['osoba-do-kontaktu']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="contact_person2" value="<?= $this->advert['id'] ? htmlspecialchars($this->advert['contact_person2']) : htmlspecialchars($this->user['contact_person_2']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="email2" class="col-12 col-sm-4"><?= ucfirst($lang['email']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="email2" value="<?= $this->advert['id'] ? htmlspecialchars($this->advert['email2']) : htmlspecialchars($this->user['email_2']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="phone2" class="col-12 col-sm-4"><?= ucfirst($lang['telefon']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="phone2" value="<?= $this->advert['id'] ? htmlspecialchars($this->advert['phone2']) : htmlspecialchars($this->user['phone_2']); ?>">
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<div class="col-12 mt20">
<a href="/panel-pracodawcy/ogloszenia" class="btn btn-danger mr15"><?= ucfirst($lang['anuluj']); ?></a>
<input type="submit" value="<?= ucfirst($lang['zapisz']); ?>" class="btn btn-success">
</div>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
<link class="footer" rel="stylesheet" type="text/css" href="/plugins/summernote/summernote-lite.css">
<link class="footer" rel="stylesheet" type="text/css" href="/plugins/selectize/css/selectize.bootstrap3.css">
<script class="footer" type="text/javascript" src="/plugins/popper.js"></script>
<script class="footer" type="text/javascript" src="/plugins/summernote/summernote-lite.js"></script>
<script class="footer" type="text/javascript" src="/plugins/summernote/lang/summernote-pl-PL.js"></script>
<script class="footer" type="text/javascript" src="/plugins/selectize/js/selectize.js"></script>
<script class="footer" type="text/javascript">
$(function() {
$( '#category' ).selectize({
maxItems: 1
});
$( '#country' ).selectize({
maxItems: 1
});
$( '#position' ).selectize({
maxItems: 1
});
$('body').on('change', '#country', function() {
if ($(this).val() == '1')
$('.row.voivodeship').show();
else
$('.row.voivodeship').hide();
});
$('#country').trigger("change");
$('.accommodation').on('ifChecked', function(event) {
if ($(this).attr("value") == "0")
$("#accommodation_cost").removeAttr('required');
if ($(this).attr("value") == "1")
$("#accommodation_cost").attr('required', 'required');
});
$('.overtime').on('ifChecked', function(event) {
if ($(this).attr("value") == "0")
$("#overtime_quantity").removeAttr('required');
if ($(this).attr("value") == "1")
$("#overtime_quantity").attr('required', 'required');
});
$('body').on('submit', '#advert-add', function(e) {
var text = $("#text").summernote('code');
text = text.replace(/(<([^>]+)>)/ig, '');
text = text.replace(/&nbsp;/g, '');
if ($.trim(text) === '') {
$('#text').parent('.col-12').children('.note-editor').addClass('error');
$('#text').parent('.col-12').children('.editor-error').removeClass('hidden');
$('html, body').animate({
scrollTop: $('#text').parent('.col-12').children('.note-editor').offset().top
}, 100);
e.preventDefault();
} else {
$('#text').parent('.col-12').children('.note-editor').removeClass('error');
$('#text').parent('.col-12').children('.editor-error').addClass('hidden');
}
var work_type = $( 'select[name="work_type"]' ).val();
if ( work_type == 0 )
{
$( 'select[name="work_type"]' ).addClass( 'error' );
$( 'select[name="work_type"]' ).focus();
e.preventDefault();
}
else
{
$( 'select[name="work_type"]' ).removeClass( 'error' );
}
});
$('#text').summernote({
height: 200,
lang: 'pl-PL',
toolbar: [
['style', ['bold', 'italic', 'underline', 'clear']],
['font', ['strikethrough', 'superscript', 'subscript']],
['fontsize', ['fontsize']],
['height', ['height']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['table', ['table']]
]
});
});
/*usuwanie zdjecia top */
$( function()
{
$( 'body' ).on( click_event, '.advert-img-top_delete', function()
{
$.alert(
{
title: '<?= ucfirst( $lang['potwierdz'] );?>',
icon: 'fa fa-exclamation',
content: 'Czy napewno chcesz usunąć zdjęcie górne?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
$.ajax(
{
type: 'POST',
url: '/globelusFirms/delete_advert_img_top/',
data:
{
id: <?= (int)$this -> advert['id'];?>
},
beforeSend: function() {},
success: function( response )
{
var data = jQuery.parseJSON( response );
if ( data.result == 'ok' ) {
const img_header = document.querySelector(".advert-img-top");
img_header.classList.add("img-hide");
}
}
});
}
}
}
});
});
});
/*usuwanie zdjecia bottom */
$( function()
{
$( 'body' ).on( click_event, '.advert-img-bottom_delete', function()
{
$.alert(
{
title: '<?= ucfirst( $lang['potwierdz'] );?>',
icon: 'fa fa-exclamation',
content: 'Czy napewno chcesz usunąć zdjęcie dolne?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
$.ajax(
{
type: 'POST',
url: '/globelusFirms/delete_advert_img_bottom/',
data:
{
id: <?= (int)$this -> advert['id'];?>
},
beforeSend: function() {},
success: function( response )
{
var data = jQuery.parseJSON( response );
if ( data.result == 'ok' ) {
const img_header = document.querySelector(".advert-img-bottom");
img_header.classList.add("img-hide");
}
}
});
}
}
}
});
});
});
</script>

View File

@@ -0,0 +1,181 @@
<? global $lang;?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'ogloszenia'
] );?>
<div class="mini-box fluid">
<div class="title">
<?= ucfirst( $lang['lista-odpowiedzi'] );?>
</div>
<div class="subtitle mb0">
<?= ucfirst( $lang['lista-odpowiedzi-do-ogloszenia'] );?>: <strong><?= $this -> advert['title'];?></strong>
</div>
</div>
<? if ( is_array( $this -> answers ) and count( $this -> answers ) ):?>
<? foreach ( $this -> answers as $answer ):?>
<div class="answer <? if ( !$answer['displayed'] ):?>nondisplayed<? else:?>displayed<? endif?>">
<div class="row">
<div class="col-12">
<div class="img">
<? if ( $answer['user_id'] and file_exists( \front\factory\GlobelusCandidates::avatar_url( $answer['user_id'] ) ) ):?>
<img src="/avatar/<?= $answer['user_id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-avatar.png">
<? endif;?>
</div>
<div class="content">
<div class="title">
<span class="name"><?= $answer['surname'] . ' ' . $answer['name'];?></span>
<a href="#" class="delete text-danger" answer-id="<?= $answer['id'];?>"><?= \S::lang( 'usun' );?></a>
<span class="date-add"><?= date( 'Y-m-d H:i', strtotime( $answer['date_add'] ) );?></span>
</div>
<div class="info">
<?= $lang['tel.'];?> <?= $answer['phone'];?> |
<?= $lang['email'];?> <a href="mailto:<?= $answer['email'];?>"><?= $answer['email'];?></a> |
<? if ( ( $answer['cv'] and file_exists( $answer['cv'] ) ) || ( !$answer['cv'] and $answer['user_id'] and file_exists( \front\factory\GlobelusCandidates::cv_url( $answer['user_id'] ) ) ) ):?>
<?
if ( !$answer['cv'] and $answer['user_id'] and file_exists( \front\factory\GlobelusCandidates::cv_url( $answer['user_id'] ) ) )
$cv_url = '/cv/' . $answer['user_id'] . '/' . \S::get_token() . '/';
else if ( $answer['cv'] and file_exists( $answer['cv'] ) )
$cv_url = '/cv-tmp/' . $answer['id'] . '/' . \S::get_token() . '/';
?>
<a href="<?= $cv_url;?>" class="cv" answer-id="<?= $answer['id'];?>">
<i class="fa fa-file-text"></i> <?= $lang['pobierz-cv'];?>
</a>
<? endif;?>
<? if ( $answer['user_id'] ):?>
| <a href="/kandydat/<?= $answer['user_id'];?>/<?= ( !$answer['surname'] and !$answer['name'] ) ? 'u' : \S::seo( $answer['surname'] . ' ' . $answer['name'] );?>/" target="_blank" answer-id="<?= $answer['id'];?>" class="visit-user"><?= $lang['zobacz-profil-kandydata-w-bazie-kandydatow'];?></a>
<? endif;?>
</div>
<div class="text">
<?= nl2br( $answer['text'] );?>
</div>
</div>
</div>
</div>
</div>
<? endforeach;?>
<? else:?>
<div class="alert alert-danger mt20"><?= $lang['panel-pracodawcy-brak-odpowiedzi'];?></div>
<? endif;?>
<div class="row">
<div class="col-12 mt20">
<a href="/panel-pracodawcy/ogloszenia" class="btn btn-danger mr15"><?= ucfirst( $lang['wstecz'] );?></a>
</div>
</div>
</div>
<script class="footer" type="text/javascript">
$( function() {
$( 'body' ).on( 'click', '.cv', function(e) {
e.preventDefault();
var answer = $( this ).parents( '.answer' );
var href = $( this ).attr( 'href' );
var answer_id = $( this ).attr( 'answer-id' );
$.ajax(
{
type: 'POST',
cache: false,
url: '/GlobelusFirms/set_answer_as_displayed/',
data:
{
answer_id: answer_id
},
beforeSend: function() {},
success: function( data )
{
var win = window.open( href, '_blank' );
win.focus();
answer.removeClass( 'nondisplayed' ).addClass( 'displayed' );
}
});
});
$( 'body' ).on( 'click', '.visit-user', function(e) {
e.preventDefault();
<? if ( !is_array( $this -> g_user['categories'] ) or !count( $this -> g_user['categories'] ) ):?>
$.alert({
title: 'Oferty pracy',
icon: 'fa fa-exclamation',
content: '<?= \S::lang( 'baza-cv-komunikat' );?>',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
confirm:
{
text: '<?= \S::lang( 'zamknij' );?>',
btnClass: 'btn',
keys: ['enter'],
action: function() {
}
}
}
});
<? else:?>
var answer = $( this ).parents( '.answer' );
var href = $( this ).attr( 'href' );
var answer_id = $( this ).attr( 'answer-id' );
$.ajax(
{
type: 'POST',
cache: false,
url: '/GlobelusFirms/set_answer_as_displayed/',
data:
{
answer_id: answer_id
},
beforeSend: function() {},
success: function( data )
{
var win = window.open( href, '_blank' );
win.focus();
answer.removeClass( 'nondisplayed' ).addClass( 'displayed' );
}
});
<? endif;?>
});
$( 'body' ).on( 'click', '#user-panel .answer .delete', function()
{
var answer_id = $( this ).attr( 'answer-id' );
$.alert(
{
title: '<?= ucfirst( \S::lang( 'potwierdz' ) );?>',
icon: 'fa fa-exclamation',
content: '<?= \S::lang( 'potwierdz-usuniecie-odpowiedzi' );?>',
type: 'orange',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
confirm:
{
text: '<?= \S::lang( 'zatwierdz' );?>',
btnClass: 'btn-danger',
keys: ['enter'],
action: function()
{
document.location.href="/GlobelusFirms/answer_delete/advert_id=<?= $this -> advert['id'];?>&answer_id=" + answer_id;
}
},
cancel:
{
text: '<?= \S::lang( 'anuluj' );?>',
action: function() {}
}
}
});
return false;
});
});
</script>

View File

@@ -0,0 +1,736 @@
<? global $lang, $globelus_settings;?>
<link class="footer" rel="stylesheet" type="text/css" href="/libraries/framework/vendor/plugins/datatables/media/css/dataTables.plugins.css">
<link class="footer" rel="stylesheet" type="text/css" href="/libraries/framework/vendor/plugins/datatables/media/css/dataTables.bootstrap.css">
<script class="footer" type="text/javascript">
var dir = '/plugins/grid';
</script>
<script class="footer" src="/libraries/framework/vendor/jquery/jquery_ui/jquery-ui.min.js"></script>
<script class="footer" src="/libraries/framework/vendor/plugins/moment/moment.js"></script>
<script class="footer" src="/libraries/framework/vendor/plugins/moment/pl.js"></script>
<script class="footer" src="/libraries/framework/vendor/plugins/datepicker/js/bootstrap-datetimepicker.js"></script>
<script class="footer" src="/libraries/framework/vendor/plugins/daterange/daterangepicker.js"></script>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'ogloszenia'
] );?>
<div class="mini-box fluid">
<div class="title">
<?= ucfirst( $lang['moje-ogloszenia'] );?>
<span class="pull-right text-danger small">
Posiadasz <?= (int)$this -> firm_points;?> pkt. <a href="/panel-pracodawcy/zakup-punktow">Doładuj konto.</a>
</span>
</div>
<div class="subtitle">
<?= $lang['moje-ogloszenia-podtytul'];?>
<? if ( $this -> user['profile_completed'] ):?>
<a href="/panel-pracodawcy/dodaj-ogloszenie" class="btn btn-success btn-add-advert"><?= $lang['dodaj-ogloszenie'];?></a>
<? endif;?>
</div>
<? if ( !$this -> user['profile_completed'] ):?>
<div class="alert alert-danger">Aby móc dodawać ogłoszenia uzupełnij podstawowe dane o firmie.</div>
<? endif;?>
<p class="legend hidden">
<span style="color: #2cbd2b;">Na zielono oznaczono ogłoszenia wyróżnione na górze listy ogłoszeń. Koszt wyróżnienia ogłoszenia: <strong><?= $globelus_settings['pkt-polecanie-ogloszenia'];?> pkt.</strong></span><br />
<span style="color: #f70;">Na pomarańczowo oznaczono ogłoszenia polecane na stronie głównej. Koszt polecenia ogłoszenia: <strong><?= $globelus_settings['pkt-polecanie-ogloszenia'];?> pkt.</strong></span><br />
<span>Koszt odświeżenia ogłoszenia: <strong><?= $globelus_settings['pkt-odswiezenie-ogloszenia'];?> pkt.</strong></span>
</p>
<div class="row">
<div class="col-12">
<div class="content profil">
<div class="row">
<?
if ( $this -> user['profile_completed'] ):
global $database;
$gdb = [
'database_type' => 'mysql',
'database_name' => $database['name'],
'server' => $database['host'],
'username' => $database['user'],
'password' => $database['password'],
'charset' => 'utf8'
];
include 'plugins/grid/gdb.min.php';
include 'plugins/grid/grid.php';
include 'plugins/grid/grid-view.php';
$grid = new \grid( 'ogloszenia-' . $this -> user['id'] );
$grid -> gdb_opt = $gdb;
$grid -> lp = true;
$grid -> sql = 'SELECT '
. 'ga.id, title, ga.visible, date_add, ga.visits, ga.active_to, ga.highlight, ga.highlight_to, ga.main_page_to, ga.old, main_page, ga.last_refresh, refresh_count, highlight_left, main_page_left, '
. 'disabled_by_admin, additional_promotion, '
. '( SELECT COUNT(0) FROM globelus_adverts_answers WHERE advert_id = ga.id AND deleted = 0 ) AS answers, '
. '( SELECT COUNT(0) FROM globelus_adverts_answers WHERE advert_id = ga.id AND displayed = 0 AND deleted = 0 ) AS answers_nondisplayed, '
. 'IF ( ga.last_refresh IS NOT NULL, ga.last_refresh, ga.date_add ) AS date_refresh '
. 'FROM '
. 'globelus_adverts AS ga '
. 'LEFT JOIN globelus_adverts_categories AS gac ON gac.id = category_id '
. 'INNER JOIN globelus_users AS gu ON ga.user_id = gu.id '
. 'WHERE '
. 'user_id = ' . (int)$this -> user['id'] . ' '
. '[where] '
. 'ORDER BY '
. '[order_p1] [order_p2]';
$grid -> sql_count = 'SELECT '
. 'COUNT(0) '
. 'FROM '
. 'globelus_adverts AS ga '
. 'LEFT JOIN globelus_adverts_categories AS gac ON gac.id = category_id '
. 'INNER JOIN globelus_users AS gu ON ga.user_id = gu.id '
. 'WHERE '
. 'user_id = ' . (int)$this -> user['id'] . ' '
. '[where] ';
$grid -> debug = false;
$grid -> context_menu = false;
$grid -> condensed = true;
$grid -> multiselect = true;
$grid -> hide_columns = false;
$grid -> order = [ 'column' => 'date_refresh', 'type' => 'DESC' ];
$grid -> search = [
[ 'name' => 'Tytuł', 'db' => 'title', 'type' => 'text' ],
[ 'name' => 'Widoczne', 'db' => 'ga.visible', 'column' => 'visible', 'type' => 'select', 'replace' => [ 'array' => [ 0 => 'nie', 1 => 'tak' ] ] ],
[ 'name' => 'Wyróżnione', 'db' => 'ga.highlight', 'column' => 'highlight', 'type' => 'select', 'replace' => [ 'array' => [ 0 => 'nie', 1 => 'tak' ] ] ],
[ 'name' => 'Polecone', 'db' => 'ga.main_page', 'column' => 'main_page', 'type' => 'select', 'replace' => [ 'array' => [ 0 => 'nie', 1 => 'tak' ] ] ]
];
$grid -> columns_view = [
[
'name' => 'Lp.',
'th' => [ 'class' => 'g-lp' ],
'td' => [ 'class' => 'g-center' ],
'autoincrement' => true
], [
'name' => 'Tytuł',
'db' => 'title',
'sort' => true,
'th' => [ 'style' => 'min-width: 400px;' ],
'php' =>
'if ( [additional_promotion] ) { '
. 'echo "<i class=\'fa fa-star text-blue\'></i> "; '
. '} '
. 'echo "<a href=\'/oferta/[id]/" . \\S::seo( \'[title]\', true ) . "\' target=\'blank\'>" '
. ' . addslashes( mb_substr( \'[title]\', 0, 60, \'UTF-8\' ) ); '
. 'if ( strlen( \'[title]\' ) > 60 ) echo "..."; echo "</a>"; '
. 'if ( "[highlight]" )'
. ' echo "<p class=\'small\'>Ogłoszenie wyróżnione do <b>[highlight_to]</b></p>";'
. 'if ( "[main_page]" )'
. ' echo "<p class=\'small\'>Ogłoszenie polecone na stronie głównej do <b>[main_page_to]</b></p>";'
. 'if ( [disabled_by_admin] ) '
. 'echo "<p class=\'info text-danger text-italic\' style=\'font-size: 12px;\'>Ogłoszenie wyłączone przez administratora.</p>";'
], [
'name' => 'Ważność',
'db' => 'active_to',
'sort' => true,
'th' => [ 'style' => 'min-width: 100px;' ],
'php' => 'if ( [old] ) { '
. 'echo "ogłoszenie wygasłe"; '
. '} else { '
. 'if ( "[active_to]" != null ) { '
. 'echo date( "Y-m-d", strtotime( "[active_to]" ) ); '
. '} else { '
. 'echo "bezterminowo"; '
. '} '
. '}'
], [
'name' => 'Wyś.',
'td' => [ 'class' => 'g-center' ],
'db' => 'visits',
'sort' => true
], [
'name' => 'CV',
'td' => [ 'class' => 'g-center' ],
'db' => 'answers',
'sort' => true,
'php' => 'echo "<a href=\'/panel-pracodawcy/odpowiedzi/[id]\' class=\'btn"; if ( [answers_nondisplayed] ) echo " btn-danger "; else echo " btn-gray "; echo "pull-right\'>[answers]</a>"; '
], [
'name' => 'Widoczne',
'db' => 'visible',
'replace' => [ 'array' => [ 0 => '<span style="color: #FF0000;">nie</span>', 1 => 'tak' ] ],
'td' => [ 'class' => 'g-center' ],
'th' => [ 'class' => 'g-center', 'style' => 'width: 100px;' ],
'sort' => true
], [
'name' => 'Wyróźnione',
'db' => 'highlight',
'replace' => [ 'array' => [ 0 => '<span style="color: #FF0000;">nie</span>', 1 => 'tak' ] ],
'td' => [ 'class' => 'g-center' ],
'th' => [ 'class' => 'g-center', 'style' => 'width: 100px;' ],
'sort' => true
], [
'name' => 'Polecone',
'db' => 'main_page',
'replace' => [ 'array' => [ 0 => '<span style="color: #FF0000;">nie</span>', 1 => 'tak' ] ],
'td' => [ 'class' => 'g-center' ],
'th' => [ 'class' => 'g-center', 'style' => 'width: 100px;' ],
'sort' => true
], [
'name' => 'Opcje',
'th' => [ 'style' => 'width: 150px;' ],
'tr_second' => true,
'php' =>
// 'if ( "[last_refresh]" == null or \front\factory\GlobelusFirms::get_firm_points( ' . $this -> user['id'] . ' ) < ' . $globelus_settings['pkt-odswiezenie-ogloszenia'] . ' ) '
// . ' $refresh_diff = \S::date_diff( date( \'Y-m-d H:i:s\', strtotime( "[date_add]" ) ), date( \'Y-m-d H:i:s\' ), 60 * 60 * 24 ); '
// . 'else '
// . '$refresh_diff = \S::date_diff( date( \'Y-m-d H:i:s\', strtotime( "[last_refresh]" ) ), date( \'Y-m-d H:i:s\' ), 60 * 60 * 24 ); '
// . 'if ( [refresh_count] < 10 and \'[active_to]\' > date( \'Y-m-d\' ) and \front\factory\GlobelusFirms::get_firm_points( ' . $this -> user['id'] . ' ) >= ' . $globelus_settings['pkt-odswiezenie-ogloszenia'] . ' ) { '
// . 'if ( $refresh_diff >= 5 ) { '
// . 'echo "<p><a href=\'/panel-pracodawcy/odswiez-ogloszenie/[id]/\' style=\'color: #000;\'>odśwież (" . ( 10 - [refresh_count] ) . ")</a></p>"; '
// . '} '
// . '}'
//sprawdzanie czy ogłoszenie nie jest wygasłe
'if ( [old] ) {'
. 'echo "<a href=\'#\' class=\'btn btn-sm btn-dark btn-disabled\'>ogłoszenie wygasłe</a>";'
. '}'
//sprawdzanie ilości punktów
. 'if ( [disabled_by_admin] ) { '
. '$class = \'btn-disabled\'; $title = \'Ogłoszenie zostało wyłączone przez administratora.\'; '
. '} else { '
. 'if ( ![visible] ) { '
. '$class = \'btn-disabled\'; $title = \'Nie można odświeżyć ogłoszenia, które nie jest opublikowane.\';'
. '} else { '
. 'if ( ' . $this -> firm_points . ' < ' . $globelus_settings['pkt-odswiezenie-ogloszenia'] . ' ) { '
. '$class = \'btn-disabled\'; $title = \'Nie posiadasz wystarczającej liczby punktów, aby odświeżyć ogłoszenie.\';'
. '} else {'
//sprawdzanie czy ogłoszenie nie jest wygasłe
. 'if ( \'[active_to]\' < date( \'Y-m-d\' ) or [old] ) { '
. '$class = \'btn-disabled\'; $title = \'Ogłoszenia wygasłego nie można odświeżyć.\';'
. '} else { '
//sprawdzanie kiedy ogłoszenie było ostatnio odświeżone
. 'if ( "[last_refresh]" == null ) '
. '$refresh_diff = \S::date_diff( date( \'Y-m-d H:i:s\', strtotime( "[date_add]" ) ), date( \'Y-m-d H:i:s\' ), 60 * 60 * 24 ); '
. 'else '
. '$refresh_diff = \S::date_diff( date( \'Y-m-d H:i:s\', strtotime( "[last_refresh]" ) ), date( \'Y-m-d H:i:s\' ), 60 * 60 * 24 ); '
. 'if ( $refresh_diff < 1 ) { '
. '$class = \'btn-disabled\'; $title = \'Ogłoszenie można odświeżać nie częściej niż co 24 godziny.\';'
. '} else {'
. '$class = \'\'; $title = \'\'; '
. '} '
. '} '
. '} '
. '} '
. '} '
. 'if ( $title ) '
. 'echo "<span class=\'container-tooltip\' data-tippy-content=\'" . $title . "\'><a href=\'#\' class=\'advert-refresh btn btn-primary btn-sm " . $class . "\' advert-id=\'[id]\'>odśwież</a></span>"; '
. 'else '
. 'echo "<a href=\'#\' class=\'advert-refresh btn btn-primary btn-sm " . $class . "\' advert-id=\'[id]\'>odśwież</a>"; '
. 'if ( "[last_refresh]" )'
. '$add_diff = \S::date_diff( date( "Y-m-d H:i:s", strtotime( "[last_refresh]" ) ), date( "Y-m-d H:i:s" ), 60 * 60 * 24 ); '
. 'else '
. '$add_diff = \S::date_diff( date( "Y-m-d H:i:s", strtotime( "[date_add]" ) ), date( "Y-m-d H:i:s" ), 60 * 60 * 24 ); '
//dodatkowa promocja - sprawdzenie czy ogłoszenie jest opublikowane
. 'if ( [disabled_by_admin] ) { '
. '$class4 = \'btn-disabled\'; $title4 = \'Ogłoszenie zostało wyłączone przez administratora.\'; '
. '} else { '
. 'if ( ![visible] ) { '
. '$class4 = \'btn-disabled\'; $title4 = \'Nie można włączyć dodatkowej promocji ogłoszenia, które nie jest opublikowane.\'; '
. '} else {'
//dodatkowa promocja - sprawdzenie czy ogłoszenie nie ma już włączonęj dodatkowej promocji
. 'if ( [additional_promotion] ) { '
. '$class4 = \'btn-disabled\'; $title4 = \'Ogłoszenie ma już włączoną dodatkową promocję.\'; '
. '} else {'
//dodatkowa promocja - sprawdzenie ilości dostępnych punktów
. 'if ( ' . $this -> firm_points . ' < ' . $globelus_settings['pkt-dodatkowa-promocja-ogloszenia'] . ' ) { '
. '$class4 = \'btn-disabled\'; $title4 = \'Nie posiadasz wystarczającej ilości punktów, aby włączyć dodatkową promocję ogłoszenia.\'; '
. '} '
. 'else {'
. '$class4 = \'\'; $title4 = \'\'; '
. '} '
. '} '
. '} '
. '} '
//przycisk dodatkowej promocji
. 'if ( $title4 ) '
. 'echo "<span class=\'container-tooltip\' data-tippy-content=\'" . $title4 . "\'>" '
. '. "<a href=\'#\' class=\'advert_highlight btn btn-primary btn-sm " . $class4 . "\' advert-id=\'[id]\'>dodatkowa promocja</a>" '
. '. "</span>"; '
. 'else '
. 'echo "<a href=\'#\' class=\'advert-additional-promotion btn btn-primary btn-sm\' advert-id=\'[id]\'>dodatkowa promocja</a>"; '
//wyróżnienie - sprawdzanie czy ogłoszenie jest opublikowane
. 'if ( [disabled_by_admin] ) { '
. '$class2 = \'btn-disabled\'; $title2 = \'Ogłoszenie zostało wyłączone przez administratora.\'; '
. '} else { '
. 'if ( ![visible] ) { '
. '$class2 = \'btn-disabled\'; $title2 = \'Nie można włączyć wyróżnienia ogłoszenia, które nie jest opublikowane.\'; '
. '} '
. 'else {'
//wyróznienie - sprawdzenie czy ogłoszenie nie jest już wyróżnione
. 'if ( [highlight] ) { '
. '$class2 = \'btn-disabled\'; $title2 = \'Ogłoszenie jest już wyróżnione.\'; '
. '} '
. 'else {'
//wyróżnienie - sprawdzenie ilości dostępnych punktów
. 'if ( ' . $this -> firm_points . ' < ' . $globelus_settings['pkt-wyroznienie-ogloszenia'] . ' ) { '
. '$class2 = \'btn-disabled\'; $title2 = \'Nie posiadasz wystarczającej ilości punktów, aby włączyć wyróżnienie ogłoszenie.\'; '
. '} '
. 'else {'
. '$class2 = \'\'; $title2 = \'\'; '
. '} '
. '} '
. '} '
. '} '
//przycisk wyróżnienie
. 'if ( $title2 ) '
. 'echo "<span class=\'container-tooltip\' data-tippy-content=\'" . $title2 . "\'>" '
. '. "<a href=\'#\' class=\'advert_highlight btn btn-primary btn-sm " . $class2 . "\' advert-id=\'[id]\'>włącz wyróżnienie</a>" '
. '. "</span>"; '
. 'else '
. 'echo "<a href=\'#\' class=\'advert_highlight btn btn-primary btn-sm\' advert-id=\'[id]\'>włącz wyróżnienie</a>"; '
//polecenie - sprawdzenie czy ogłoszenie jest opulikowane
. 'if ( [disabled_by_admin] ) { '
. '$class3 = \'btn-disabled\'; $title3 = \'Ogłoszenie zostało wyłączone przez administratora.\'; '
. '} else { '
. 'if ( ![visible] ) { '
. '$class3 = \'btn-disabled\'; $title3 = \'Nie można włączyć polecenia ogłoszenia, które nie jest opublikowane.\'; '
. '} '
. 'else {'
//polecenie - sprawdzenie czy ogłoszenie nie jest już polecane
. 'if ( [main_page] ) { '
. '$class3 = \'btn-disabled\'; $title3 = \'Ogłoszenie jest już polecane na stronie głónej.\'; '
. '} '
. 'else {'
//wyróżnienie - sprawdzenie ilości dostępnych punktów
. 'if ( ' . $this -> firm_points . ' < ' . $globelus_settings['pkt-wyroznienie-ogloszenia'] . ' ) { '
. '$class3 = \'btn-disabled\'; $title3 = \'Nie posiadasz wystarczającej ilości punktów, aby wyróżnić ogłoszenie.\'; '
. '} '
. 'else {'
. '$class3 = \'\'; $title3 = \'\'; '
. '} '
. '} '
. '} '
. '} '
//przycisk polecenie
. 'if ( $title3 ) '
. 'echo "<span class=\'container-tooltip\' data-tippy-content=\'" . $title3 . "\'>" '
. '. "<a href=\'#\' class=\'advert_main_page btn btn-primary btn-sm " . $class3 . "\' advert-id=\'[id]\'>włącz polecenie</a>" '
. '. "</span>"; '
. 'else '
. 'echo "<a href=\'#\' class=\'advert_main_page btn btn-primary btn-sm\' advert-id=\'[id]\'>włącz polecenie</a>"; '
. 'if ( ![disabled_by_admin] ) { '
. 'if ( \'[active_to]\' >= date( \'Y-m-d\' ) ) { '
. 'if ( [visible] ) '
. 'echo "<a href=\'#\' class=\'btn btn-sm btn-primary advert-disable\' advert-id=\'[id]\'>wyłącz ogłoszenie</a>"; '
. 'else { '
//sprawdzenie ile ktoś ma ogłoszeń
. 'if ( ' . $this -> adverts_count . ' >= ' . $globelus_settings['limit-ogloszen'] . ' ) { '
. 'if ( ' . $this -> firm_points . ' < ' . $globelus_settings['pkt-dodanie-ogloszenia-powyzej-limitu'] . ' ) { '
. 'echo "<span class=\'container-tooltip\' data-tippy-content=\'Niestety posiadasz zbyt mało punktów aby opublikować nowe ogłoszenie.\'>" '
. '. "<a href=\'#\' class=\'advert-public btn btn-primary btn-sm btn-disabled\' advert-id=\'[id]\'>publikuj</a>" '
. '. "</span>"; '
. '} else { '
. 'echo "<a href=\'#\' class=\'btn btn-sm btn-primary advert-public\' advert-id=\'[id]\'>publikuj</a>"; '
. '} '
. '} '
. 'else {'
. 'echo "<a href=\'#\' class=\'btn btn-sm btn-primary advert-public\' advert-id=\'[id]\'>publikuj</a>"; '
. '} '
. '} '
. '} '
. 'echo \'<a href="/panel-pracodawcy/edytuj-ogloszenie/[id]" class="btn btn-sm btn-primary advert-edit" title="edytuj" style="font-size: 12px;">edytuj</a>\';'
. '} '
. 'echo \'<a href="#" class="btn btn-primary advert-delete" advert-id="[id]" title="usuń">usuń</a>\'; '
]
];
$grid -> buttons = [
[
'class' => 'btn-danger multi-disable',
'label' => 'Wyłącz',
'url' => '/globelusFirms/multi_disable/'
], [
'class' => 'btn-danger multi-delete',
'label' => 'Usuń',
'url' => '/globelusFirms/multi_delete/'
]
];
echo $grid -> draw();
endif;
?>
</div>
</div>
</div>
</div>
</div>
</div>
<script class="footer" src="/libraries/framework/vendor/plugins/datatables/media/js/jquery.dataTables.js"></script>
<script class="footer" src="/libraries/framework/vendor/plugins/datatables/media/js/dataTables.bootstrap.js"></script>
<script class="footer" type="text/javascript">
$( function()
{
tippy('[data-tippy-content]', {
theme: 'material'
});
$( 'body' ).on( click_event, '.advert-additional-promotion', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
$.alert(
{
title: 'Dodatkowa promocja ogłoszenia',
icon: 'fa fa-exclamation',
content: 'Dodatkowa promocja ogłoszenia kosztuje <b><?= $globelus_settings['pkt-dodatkowa-promocja-ogloszenia'];?> punktów<\/b>, zostaną one pobrane z Twojego konta.',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
document.location.href='/globelusFirms/advert_additional_promotion/advert-id=' + advert_id;
}
}
}
});
});
$( 'body' ).on( click_event, '.advert_highlight', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
$.alert(
{
title: 'Wyróżnienie ogłoszenia',
icon: 'fa fa-exclamation',
content: 'Wyróżnienie ogłoszenia kosztuje <b><?= $globelus_settings['pkt-wyroznienie-ogloszenia'];?> punktów<\/b>, zostaną one pobrane z Twojego konta.',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
document.location.href='/globelusFirms/advert_highlight_enable/advert-id=' + advert_id;
}
}
}
});
});
$( 'body' ).on( click_event, '.advert-refresh', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
$.alert(
{
title: 'Odświeżenie ogłoszenia',
icon: 'fa fa-exclamation',
content: 'Odświeżenie ogłoszenia kosztuje <b><?= $globelus_settings['pkt-odswiezenie-ogloszenia'];?> punkt<\/b>, zostanie on pobrany z Twojego konta.',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
document.location.href = '/panel-pracodawcy/odswiez-ogloszenie/' + advert_id + '/';
}
}
}
});
});
$( 'body' ).on( click_event, '.multi-delete', function(e)
{
var ids = getCheckedIds( 'ogloszenia-<?= $this -> user['id'];?>' );
var href = $( this ).attr( 'href' );
$.alert(
{
title: 'Usunięcie ogłoszeń',
icon: 'fa fa-exclamation',
content: 'Na pewno chcesz usunąć wybrane ogłoszenia?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-red',
keys: ['enter'],
action: function()
{
$.ajax({
type: 'POST',
cache: false,
url: href,
data: {
ids: ids
},
beforeSend: function() {},
success: function( data ) {
document.location.reload();
}
});
}
}
}
});
return false;
});
$( 'body' ).on( click_event, '.multi-disable', function(e)
{
var ids = getCheckedIds( 'ogloszenia-<?= $this -> user['id'];?>' );
var href = $( this ).attr( 'href' );
$.alert(
{
title: 'Wyłączenie ogłoszeń',
icon: 'fa fa-exclamation',
content: 'Na pewno chcesz wyłączyć wybrane ogłoszenia?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-red',
keys: ['enter'],
action: function()
{
$.ajax({
type: 'POST',
cache: false,
url: href,
data: {
ids: ids
},
beforeSend: function() {},
success: function( data ) {
document.location.reload();
}
});
}
}
}
});
return false;
});
$( 'body' ).on( click_event, '.advert-disable', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
$.alert(
{
title: 'Wyłączenie ogłoszenia',
icon: 'fa fa-exclamation',
content: '<?= $lang['potwierdz-wylaczenie-ogloszenia'];?>',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-red',
keys: ['enter'],
action: function()
{
document.location.href='/globelusFirms/advert_disable/advert-id=' + advert_id;
}
}
}
});
});
$( 'body' ).on( click_event, '.advert-public', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
<? if ( $this -> adverts_count >= $globelus_settings['limit-ogloszen'] and $this -> firm_points >= $globelus_settings['pkt-dodanie-ogloszenia-powyzej-limitu'] ):?>
$.alert(
{
title: 'Publikowanie ogłoszenia',
icon: 'fa fa-exclamation',
content: 'Posiadasz już opulikowanych <b><?= $this -> adverts_count;?> ogłoszeń<\/b>.<br>Każde nowe opublikowane ogłoszenie to koszt <b><?= $globelus_settings['pkt-dodanie-ogloszenia-powyzej-limitu'];?> punktów.<\/b>',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
document.location.href='/globelusFirms/advert_enable/advert-id=' + advert_id;
}
}
}
});
<? endif;?>
<? if ( $this -> adverts_count < $globelus_settings['limit-ogloszen'] ):?>
document.location.href='/globelusFirms/advert_enable/advert-id=' + advert_id;
<? endif;?>
});
$( 'body' ).on( click_event, '.advert_main_page', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
$.alert(
{
title: 'Polecenie ogłoszenia',
icon: 'fa fa-exclamation',
content: 'Włączenie polecenia ogłoszenia kosztuje <b><?= $globelus_settings['pkt-polecanie-ogloszenia'];?> punktów<\/b>, zostaną one pobrane z Twojego konta.',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
document.location.href='/globelusFirms/advert_main_page_enable/advert-id=' + advert_id;
}
}
}
});
});
$( 'body' ).on( click_event, '.advert-delete', function(e)
{
e.preventDefault();
var advert_id = $( this ).attr( 'advert-id' );
$.alert(
{
title: 'Usunięcie ogłoszenia',
icon: 'fa fa-exclamation',
content: 'Na pewno chcesz usunąć wybrane ogłoszenie?<br/><strong>Tej operacji nie można cofnąć.</strong>',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-danger',
keys: ['enter'],
action: function()
{
document.location.href='/globelusFirms/advert_delete/advert-id=' + advert_id;
}
}
}
});
});
});
</script>

View File

@@ -0,0 +1,61 @@
<script type="text/javascript" class="footer">
$.alert(
{
title: 'Oferty pracy',
icon: 'fa fa-exclamation',
content: 'Dodawanie ogłoszeń dostępne jest tylko dla zalogowanych pracodawców.',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
confirm:
{
text: '<?= \S::lang( 'zamknij' );?>',
btnClass: 'btn',
keys: ['enter'],
action: function() {
document.location.href = '<?= $_SERVER['HTTP_REFERER'];?>';
}
},
cancel:
{
text: 'Zaloguj się',
btnClass: 'btn-blue',
keys: ['enter'],
action: function() {
document.location.href = '/logowanie';
}
}
}
});
</script>
<div class="box" id="new-offers">
<div class="container">
<div class="title">
[PHP]echo \S::lang( 'polecane-oferty-pracy' );[/PHP]
</div>
<div class="row">
<div class="col-12 col-md-6">
[PHP]echo \front\controls\GlobelusAdverts::main_page_adverts(4);[/PHP]
</div>
<div class="col-12 col-md-6">
[PHP]include 'templates_user/globelus/main-adverts.php';[/PHP]
</div>
</div>
</div>
</div>
<div class="box" id="jakiej-pracy-szukasz">
<div class="container">
<div class="row">
<div class="col-12">
<a href="/jakiej-pracy-szukasz">
<img src="/layout/images/jakiej-pracy-szukasz.jpg" alt="" style="width: 100%;">
</a>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,61 @@
<script type="text/javascript" class="footer">
$.alert(
{
title: 'Oferty pracy',
icon: 'fa fa-exclamation',
content: 'Oferty pracy mogą dodawać wyłącznie zarejestrowani i zalogowani pracodawcy.',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
confirm:
{
text: '<?= \S::lang( 'zamknij' );?>',
btnClass: 'btn',
keys: ['enter'],
action: function() {
document.location.href = '<?= $_SERVER['HTTP_REFERER'];?>';
}
},
cancel:
{
text: 'Zaloguj się',
btnClass: 'btn-blue',
keys: ['enter'],
action: function() {
document.location.href = '/logowanie';
}
}
}
});
</script>
<div class="box" id="new-offers">
<div class="container">
<div class="title">
[PHP]echo \S::lang( 'polecane-oferty-pracy' );[/PHP]
</div>
<div class="row">
<div class="col-12 col-md-6">
[PHP]echo \front\controls\GlobelusAdverts::main_page_adverts(4);[/PHP]
</div>
<div class="col-12 col-md-6">
[PHP]include 'templates_user/globelus/main-adverts.php';[/PHP]
</div>
</div>
</div>
</div>
<div class="box" id="jakiej-pracy-szukasz">
<div class="container">
<div class="row">
<div class="col-12">
<a href="/jakiej-pracy-szukasz">
<img src="/layout/images/jakiej-pracy-szukasz.jpg" alt="" style="width: 100%;">
</a>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,182 @@
<? global $lang;?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'cv'
] );?>
<div class="mini-box fluid">
<div class="title">
Lista CV
</div>
</div>
<? if ( is_array( $this -> answers ) and count( $this -> answers ) ):?>
<? foreach ( $this -> answers as $answer ):?>
<div class="answer <? if ( !$answer['displayed'] ):?>nondisplayed<? else:?>displayed<? endif?>">
<div class="row">
<div class="col-12">
<div class="img">
<? if ( $answer['user_id'] and file_exists( \front\factory\GlobelusCandidates::avatar_url( $answer['user_id'] ) ) ):?>
<img src="/avatar/<?= $answer['user_id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-avatar.png">
<? endif;?>
</div>
<div class="content">
<div class="title">
<p>Ogłoszenie: <b><?= $answer['title'];?></b></p>
<span class="name"><?= $answer['surname'] . ' ' . $answer['name'];?></span>
<a href="#" class="delete text-danger" answer-id="<?= $answer['id'];?>"><?= \S::lang( 'usun' );?></a>
<span class="date-add"><?= date( 'Y-m-d H:i', strtotime( $answer['date_add'] ) );?></span>
</div>
<div class="info">
<?= $lang['tel.'];?> <?= $answer['phone'];?> |
<?= $lang['email'];?> <a href="mailto:<?= $answer['email'];?>"><?= $answer['email'];?></a> |
<? if ( ( $answer['cv'] and file_exists( $answer['cv'] ) ) || ( !$answer['cv'] and $answer['user_id'] and file_exists( \front\factory\GlobelusCandidates::cv_url( $answer['user_id'] ) ) ) ):?>
<?
if ( !$answer['cv'] and $answer['user_id'] and file_exists( \front\factory\GlobelusCandidates::cv_url( $answer['user_id'] ) ) )
$cv_url = '/cv/' . $answer['user_id'] . '/' . \S::get_token() . '/';
else if ( $answer['cv'] and file_exists( $answer['cv'] ) )
$cv_url = '/cv-tmp/' . $answer['id'] . '/' . \S::get_token() . '/';
?>
<a href="<?= $cv_url;?>" class="cv" answer-id="<?= $answer['id'];?>">
<i class="fa fa-file-text"></i> <?= $lang['pobierz-cv'];?>
</a>
<? endif;?>
<? if ( $answer['user_id'] ):?>
| <a href="/kandydat/<?= $answer['user_id'];?>/<?= ( !$answer['surname'] and !$answer['name'] ) ? 'u' : \S::seo( $answer['surname'] . ' ' . $answer['name'] );?>/" target="_blank" answer-id="<?= $answer['id'];?>" class="visit-user"><?= $lang['zobacz-profil-kandydata-w-bazie-kandydatow'];?></a>
<? endif;?>
</div>
<div class="text">
<?= nl2br( $answer['text'] );?>
</div>
</div>
</div>
</div>
</div>
<? endforeach;?>
<? else:?>
<div class="alert alert-danger mt20"><?= $lang['panel-pracodawcy-brak-odpowiedzi'];?></div>
<? endif;?>
<div class="row">
<div class="col-12 mt20">
<a href="/panel-pracodawcy/ogloszenia" class="btn btn-danger mr15"><?= ucfirst( $lang['wstecz'] );?></a>
</div>
</div>
</div>
<script class="footer" type="text/javascript">
$( function()
{
$( 'body' ).on( 'click', '.cv', function(e)
{
e.preventDefault();
var answer = $( this ).parents( '.answer' );
var href = $( this ).attr( 'href' );
var answer_id = $( this ).attr( 'answer-id' );
$.ajax(
{
type: 'POST',
cache: false,
url: '/GlobelusFirms/set_answer_as_displayed/',
data:
{
answer_id: answer_id
},
beforeSend: function() {},
success: function( data )
{
var win = window.open( href, '_blank' );
win.focus();
answer.removeClass( 'nondisplayed' ).addClass( 'displayed' );
}
});
});
$( 'body' ).on( 'click', '.visit-user', function(e)
{
e.preventDefault();
<? if ( !is_array( $this -> g_user['categories'] ) or !count( $this -> g_user['categories'] ) ):?>
$.alert({
title: 'Oferty pracy',
icon: 'fa fa-exclamation',
content: '<?= \S::lang( 'baza-cv-komunikat' );?>',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
confirm:
{
text: '<?= \S::lang( 'zamknij' );?>',
btnClass: 'btn',
keys: ['enter'],
action: function() {
}
}
}
});
<? else:?>
var answer = $( this ).parents( '.answer' );
var href = $( this ).attr( 'href' );
var answer_id = $( this ).attr( 'answer-id' );
$.ajax(
{
type: 'POST',
cache: false,
url: '/GlobelusFirms/set_answer_as_displayed/',
data:
{
answer_id: answer_id
},
beforeSend: function() {},
success: function( data )
{
var win = window.open( href, '_blank' );
win.focus();
answer.removeClass( 'nondisplayed' ).addClass( 'displayed' );
}
});
<? endif;?>
});
$( 'body' ).on( 'click', '#user-panel .answer .delete', function()
{
var answer_id = $( this ).attr( 'answer-id' );
$.alert(
{
title: '<?= ucfirst( \S::lang( 'potwierdz' ) );?>',
icon: 'fa fa-exclamation',
content: '<?= \S::lang( 'potwierdz-usuniecie-odpowiedzi' );?>',
type: 'orange',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= \S::lang( 'anuluj' );?>',
action: function() {}
},
confirm:
{
text: '<?= \S::lang( 'zatwierdz' );?>',
btnClass: 'btn-danger',
keys: ['enter'],
action: function()
{
document.location.href="/GlobelusFirms/answer_delete/answer_id=" + answer_id;
}
}
}
});
return false;
});
});
</script>

View File

@@ -0,0 +1,98 @@
<? global $lang;?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'zakup-punktow'
] );?>
<div class="mini-box fluid">
<div class="title">
Zakup punktów
<span class="pull-right text-danger small">
Posiadasz <?= (int)\front\factory\GlobelusFirms::get_firm_points( $this -> user['id'] );?> pkt. <a href="/panel-pracodawcy/zakup-punktow">Doładuj konto.</a>
</span>
</div>
<? if ( !$this -> user['profile_completed'] ):?>
<div class="alert alert-danger">Aby doładować konto musisz uzupełnić Swój profil. <a href="/panel-pracodawcy/profil">Przejdź do profilu</a>.</div>
<? else:?>
<div class="subtitle">
Wybierz jeden z dostępnych pakietów i zwiększ ilość posiadanych punktów.
</div>
<div class="row">
<div class="col-lg-5">
<div class="row">
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=2"><strong><?= $this -> gsettings['pkt-pakiet-2-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-2-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=3"><strong><?= $this -> gsettings['pkt-pakiet-3-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-3-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=4"><strong><?= $this -> gsettings['pkt-pakiet-4-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-4-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=5"><strong><?= $this -> gsettings['pkt-pakiet-5-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-5-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=6"><strong><?= $this -> gsettings['pkt-pakiet-6-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-6-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=7"><strong><?= $this -> gsettings['pkt-pakiet-7-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-7-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
<div class="col-12 points-prices">
<div class="content">
<div class="row">
<div class="col-12">
<a href="/panel-pracodawcy/zakup-punktow/pakiet=8"><strong><?= $this -> gsettings['pkt-pakiet-8-ilosc'];?></strong> punktów za <strong><?= number_format( $this -> gsettings['pkt-pakiet-8-cena'], 2, ',', ' ' );?></strong> zł</a>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="col-lg-7 lg-hm">
<?=\front\view\Scontainers::scontainer( 6 );?>
</div>
</div>
<? endif;?>
<div class="row">
<div class="col-12">
<?=\front\view\Scontainers::scontainer( 5 );?>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,50 @@
<div class="new-order">
<div class="title">
Płatność za zamówienie
</div>
<div class="text">
Wybrałeś pakiet <b><?= $this -> gsettings['pkt-pakiet-' . $this -> package . '-ilosc'];?> punktów</b>.<br/>
Za chwilę zostaniesz przekierowany do strony <b>Tpay.com</b> gdzie będziesz mógł dokonać płatności.
</div>
</div>
<?
$url = 'https://secure.tpay.com';
if ( $_SERVER['SERVER_NAME'] == 'www.globelus.pro24.com.pl' )
$id = '1010';
else
$id = '50184';
if ( $_SERVER['SERVER_NAME'] == 'www.globelus.pro24.com.pl' )
$code = 'demo';
else
$code = '42mYboa8982hg6W9';
$url .= '?id=' . $id;
$url .= '&kwota=' . str_replace( ',', '.', $this -> gsettings['pkt-pakiet-' . $this -> package . '-cena'] );
$url .= '&opis=' . urlencode( 'Zakup pakietu ' . $this -> gsettings['pkt-pakiet-' . $this -> package . '-ilosc'] . ' punktów.' );
if ( $_SERVER['SERVER_NAME'] == 'www.globelus.pro24.com.pl' )
$url .= '&wyn_email=' . urlencode( 'biuro@project-pro.pl' );
else
$url .= '&wyn_email=' . urlencode( 'kontakt@globelus.pl' );
if ( $_SERVER['SERVER_NAME'] == 'www.globelus.pro24.com.pl' )
$url .= '&email=' . urlencode( 'pyziak84@gmail.com' );
else
$url .= '&email=' . urlencode( $this -> user['email'] );
$url .= '&nazwisko=' . urlencode( $this -> user['firm_name'] );
$url .= '&crc=' . $this -> hash;
$url .= '&result_url=' . urlencode( 'https://' . $_SERVER['SERVER_NAME'] . '/panel-pracodawcy/zakup-punktow/status' );
$url .= '&return_url=' . urlencode( 'https://' . $_SERVER['SERVER_NAME'] . '/panel-pracodawcy/zakup-punktow/platnosc-prawidlowa' );
$url .= '&return_error_url=' . urlencode( 'https://' . $_SERVER['SERVER_NAME'] . '/panel-pracodawcy/zakup-punktow/platnosc-nieprawidlowa' );
$url .= '&md5sum=' . md5( $id . '&' . str_replace( ',', '.', $this -> gsettings['pkt-pakiet-' . $this -> package . '-cena'] ) . '&' . $this -> hash . '&' . $code );
?>
<script class="footer" type="text/javascript">
$( function() {
console.log( '<?= $url;?>' );
setTimeout( function(){
document.location.href = '<?= $url;?>';
}, 1000 );
});
</script>

View File

@@ -0,0 +1,194 @@
<? global $lang, $g_user;?>
<div class="firm-details">
<div class="top">
<div class="row">
<div class="col-12">
<div class="logo-container">
<div class="name"><?= htmlspecialchars( $this -> firm['firm_name_profile'] );?></div>
<div class="logo">
<? if ( file_exists( \front\factory\GlobelusFirms::logo_url( $this -> firm['id'] ) ) ):?>
<img src="/logo/<?= $this -> firm['id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-logo.jpg">
<? endif;?>
</div>
</div>
</div>
</div>
</div>
<div class="content">
<div class="row">
<div class="col-12">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['firma'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['firm_name_profile'] );?>
</div>
</div>
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['numer-identyfikacji-podatkowej'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['nip_vat'] );?>
</div>
</div>
</div>
</div>
<hr/>
<div class="step-title">
<?= $lang['pracodawca-profil-krok-2-opis'];?>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['telefon'] );?>:</label>
<div class="col-12 col-sm-8">
<? if ( !$this -> g_user ):?>
<a href="/logowanie">Zaloguj się aby zobaczyć numer telefonu</a>
<? else:?>
<?= htmlspecialchars( $this -> firm['phone'] );?>
<? endif;?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['adres-email'] );?>:</label>
<div class="col-12 col-sm-8">
<? if ( !$this -> g_user ):?>
<a href="/logowanie">Zaloguj się aby zobaczyć adres email</a>
<? else:?>
<?= htmlspecialchars( $this -> firm['email'] );?>
<? endif;?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['strona-www'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['www'] );?>
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= $lang['pracodawca-profil-krok-3-opis'];?>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['kraj'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['country'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['region'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['region'] );?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['miasto'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['city'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['kod-pocztowy'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['postal_code'] );?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['ulica'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['street'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['nr-budynku-lokalu'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> firm['apartment_number'] );?>
</div>
</div>
</div>
</div>
</div>
<div class="content">
<div class="row">
<div class="col-12">
<div class="step-title">
<?= ucfirst( $lang['krotki-opis-firmy'] );?>
</div>
<?
$text = $this -> firm['other_information'];
$text = preg_replace('/[a-z0-9_\-\+\.]+@[a-z0-9\-]+\.([a-z]{2,4})(?:\.[a-z]{2})?/i', ' <a href="/logowanie">Zaloguj się aby zobaczyć adres email</a> ', $text );
$text = preg_replace('/(\+[0-9]{11}|\+[0-9]{2} [0-9]{9}|\+[0-9]{2} [0-9]{3} [0-9]{3} [0-9]{3}|\+[0-9]{2} [0-9]{3}-[0-9]{3}-[0-9]{3})/i', ' <a href="/logowanie">Zaloguj się aby zobaczyć numer telefonu</a> ', $text );
echo $text;
?>
</div>
</div>
</div>
<div class="adverts-title">Wszystkie oferty tego pracodawcy</div>
<? if ( is_array( $this -> adverts ) and count( $this -> adverts ) ):?>
<? foreach ( $this -> adverts as $advert ):?>
<div class="advert-entry <? if ( $advert['highlight'] ):?>highlight<? endif;?>">
<? if ( $advert['highlight'] ):?><div id="highlight-text">Oferta wyróżniona</div><? endif;?>
<div class="row">
<div class="col-12 col-sm-3 col-md-2">
<div class="logo">
<? if ( file_exists( \front\factory\GlobelusFirms::logo_url( $advert['user_id'] ) ) ):?>
<img src="/logo/<?= $advert['user_id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-logo.jpg">
<? endif;?>
</div>
</div>
<div class="col-12 col-sm-9 col-md-10">
<div class="row">
<div class="col-12 col-md-9">
<h2>
<a href="/oferta/<?= $advert['id'];?>/<?= \S::seo( $advert['title'], true );?>" title="Ogłoszenie: <?= addslashes( $advert['title'] );?>"><?= $advert['title'];?></a>
</h2>
</div>
<div class="col-12 col-md-3 date-add">
<?= date( 'Y-m-d', strtotime( $advert['date_add'] ) );?>
<div class="flag">
<? if ( file_exists( 'upload/filemanager/flags/' . \S::seo( $advert['country'] ) . '.jpg' ) ):?>
<img src="/upload/filemanager/flags/<?= \S::seo( $advert['country'] );?>.jpg">
<? endif;?>
</div>
</div>
</div>
<div class="info">
<a href="/oferty-pracy/<?= \S::seo( $advert['country'], true );?>" class="place" title="praca <?= $adver['country'];?>"><?= $advert['country'];?></a> - <?= $advert['city'];?></span> | <a href="/pracodawca/<?= $advert['user_id'];?>/<?= \S::seo( $advert['firm_name_profile'] );?>" class="firm"><?= $advert['firm_name_profile'];?></a> | <a href="/oferty-pracy/<?= \S::seo( $advert['category'], true );?>" class="category" title="praca <?= $advert['category'];?>"><?= $advert['category'];?></a>
</div>
<div class="short-text">
<?= mb_substr( strip_tags( $advert['text'] ), 0, 150, 'UTF-8' );?>...
</div>
<a href="/oferta/<?= $advert['id'];?>/<?= \S::seo( $advert['title'], true );?>" class="btn btn-success"><?= $lang['szczegoly-oferty'];?></a>
</div>
</div>
</div>
<? endforeach;?>
<? endif;?>
<a href="javascript:history.back()" class="btn btn-dark btn-back"><?= $lang['wstecz'];?></a>
</div>

View File

@@ -0,0 +1,36 @@
<div class="firms-alphabet-filtr">
<?
echo "<a href='/pracodawcy' id='all'>wszystkie</a>";
foreach ( range('a', 'z' ) as $i ):
echo "<a href='/pracodawcy/$i'"; if ( $i == $this -> letter ) echo "class='active'"; echo ">$i</a>";
endforeach;
?>
</div>
<div class="firms-list">
<div class="row">
<? if ( is_array( $this -> firms_list ) and count( $this -> firms_list ) ): foreach ( $this -> firms_list as $firm ):?>
<div class="col-12 col-sm-4">
<a class="firm-entry" href="/pracodawca/<?= $firm['id'];?>/<?= \S::seo( $firm['firm_name_profile'], true );?>">
<h2><?= $firm['firm_name'];?></h2>
<div class="logo">
<? if ( file_exists( \front\factory\GlobelusFirms::logo_url( $firm['id'] ) ) ):?>
<img src="/logo/<?= $firm['id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-logo.jpg">
<? endif;?>
</div>
</a>
</div>
<? endforeach; endif;?>
</div>
</div>
<?
$this -> letter ? $link = 'pracodawcy/' . $this -> letter : $link = 'pracodawcy';
if ( ( $this -> firms_count / \front\factory\GlobelusFirms::firm_list_limit ) > 1 ):
echo \front\view\Globelus::pager(
$link,
ceil( $this -> firms_count / \front\factory\GlobelusFirms::firm_list_limit ),
$this -> current_page
);
endif;
?>

View File

@@ -0,0 +1,56 @@
<? global $lang;?>
<div>
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'obserwowani-kandydaci'
] );?>
<div class="mini-box fluid mb15">
<div class="title">
<?= ucfirst( $lang['obserwowani-kandydaci'] );?>
<span class="pull-right text-danger small">
Posiadasz <?= (int)\front\factory\GlobelusFirms::get_firm_points( $this -> user['id'] );?> pkt. <a href="/panel-pracodawcy/zakup-punktow">Doładuj konto.</a>
</span>
</div>
<div class="subtitle mb0">
<?= ucfirst( $lang['obserwowani-kandydaci-podtytul'] );?>
</div>
</div>
<? if ( is_array( $this -> candidates ) and count( $this -> candidates ) ):?>
<? foreach ( $this -> candidates as $candidate ):?>
<div class="cv-entry">
<div class="row">
<div class="col-12 col-sm-2">
<div class="img">
<? if ( file_exists( \front\factory\GlobelusCandidates::avatar_url( $candidate['id'] ) ) ):?>
<img src="/avatar/<?= $candidate['id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-avatar.png">
<? endif;?>
</div>
</div>
<div class="col-12 col-sm-10">
<div class="row">
<div class="col-12 col-sm-9">
<h2>
<a href="/kandydat/<?= $candidate['id'];?>/<?= \S::seo( $candidate['surname'] . ' ' . $candidate['name'], true );?>/" target="_blank" title="Kandydat: <?= addslashes( $candidate['surname'] . ' ' . $candidate['name'] );?>"><?= $candidate['surname'] . ' ' . $candidate['name'];?></a>
</h2>
</div>
<div class="col-12 col-sm-3 sex-and-birth">
<?= $lang['plec'];?>: <?= !$candidate['sex'] ? $lang['kobieta'] : $lang['mezczyzna'];?><br />
<?= $lang['wiek'];?>: <?= $age = \S::date_diff( $candidate['date_of_birth'], date( 'Y-m-d H:i:s' ), 60 * 60 * 24 * 365.25 );?> <?= \front\factory\Globelus::age_word_translations( $age );?>
</div>
</div>
<div class="info">
<?= $lang['tel.'];?> <?= $candidate['phone'];?> | <?= $lang['email'];?>: <a href="mailto:<?= $candidate['email'];?>"><?= $candidate['email'];?></a>
</div>
<div class="short-text">
<?= $advert['short_text'];?>
</div>
<a href="/kandydat/<?= $candidate['id'];?>/<?= \S::seo( $candidate['surname'] . ' ' . $candidate['name'], true );?>/" target="_blank" class="btn btn-success"><?= $lang['profil-kandydata'];?></a>
</div>
</div>
</div>
<? endforeach;?>
<? else:?>
<div class="alert alert-danger mt20"><?= $lang['panel-pracodawcy-brak-obserwowanych-kandydatow'];?></div>
<? endif;?>
</div>

View File

@@ -0,0 +1,9 @@
<div class="new-order">
<div class="title red">
Zamówienie nieopłacone
</div>
<div class="text">
<p>Twoje zamówienie niestety nie zostało opłacone. Spróbuj ponownie lub skontaktuj się z nami.</p>
<a href="/panel-pracodawcy/profil" class="btn btn-primary">Wróć do panelu pracodawcy</a>
</div>
</div>

View File

@@ -0,0 +1,9 @@
<div class="new-order">
<div class="title">
Zamówienie zostało opłacone
</div>
<div class="text">
<p>Twoje zamówienie zostało opłacone. Punkty niedługo pojawią się na Twoim koncie.</p>
<a href="/panel-pracodawcy/profil" class="btn btn-primary">Wróć do panelu pracodawcy</a>
</div>
</div>

View File

@@ -0,0 +1,573 @@
<? global $lang; ?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'moj-profil'
] );?>
</div>
<div class="mini-box fluid">
<div class="title">
<?= ucfirst($lang['edycja-profilu']); ?>
</div>
<div class="row">
<div class="col-12">
<div class="content profil">
<form method="POST" action="/globelusFirms/data_save/" enctype="multipart/form-data">
<div class="step-title">
<?= $lang['pracodawca-profil-krok-1-opis']; ?>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="firm_name" class="col-12 col-sm-4"><?= ucfirst($lang['nazwa-firmy']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" id="firm_name" name="firm_name" required class="form-control" value="<?= htmlspecialchars($this->g_user['firm_name']); ?>">
</div>
</div>
</div>
<div class="col-12">
<div class="form-group row">
<label form="firm_name_profile" class="col-12 col-sm-4"><?= ucfirst($lang['nazwa-firmy-publikowana-na-portalu']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" id="firm_name_profile" name="firm_name_profile" required class="form-control" value="<?= htmlspecialchars($this->g_user['firm_name_profile']); ?>">
</div>
</div>
</div>
<div class="col-12">
<div class="form-group row">
<label form="nip" class="col-12 col-sm-4"><?= ucfirst($lang['numer-identyfikacji-podatkowej']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" id="nip_vat" name="nip_vat" class="form-control" required value="<?= htmlspecialchars($this->g_user['nip_vat']); ?>">
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= $lang['pracodawca-profil-krok-2-opis']; ?>
</div>
<div class="row">
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="phone" class="col-12 col-sm-4"><?= ucfirst($lang['telefon']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="phone" class="form-control" required value="<?= htmlspecialchars($this->g_user['phone']); ?>">
</div>
</div>
</div>
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="email" class="col-12 col-sm-4"><?= ucfirst($lang['adres-email']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="email" class="form-control" readonly="readonly" value="<?= htmlspecialchars($this->g_user['email']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="www" class="col-12 col-sm-4"><?= ucfirst($lang['strona-www']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="www" class="form-control" value="<?= htmlspecialchars($this->g_user['www']); ?>">
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= $lang['pracodawca-profil-krok-3-opis']; ?>
</div>
<div class="row">
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="country_id" class="col-12 col-sm-4"><?= ucfirst($lang['kraj']); ?></label>
<div class="col-12 col-sm-8">
<select name="country_id" class="form-control" required placeholder="<?= $lang['kraj']; ?>">
<option value="">--- <?= $lang['wybierz']; ?> ---</option>
<?
$countries = \front\factory\Globelus::countries();
if (is_array($countries)) : foreach ($countries as $country) : ?>
<option value="<?= $country['id']; ?>" <? if ($this->g_user['country_id'] == $country['id']) : ?>selected="selected" <? endif; ?>><?= $country['name']; ?></option>
<? endforeach;
endif;
?>
</select>
</div>
</div>
</div>
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="region" class="col-12 col-sm-4"><?= ucfirst($lang['region']); ?>/<?= ucfirst($lang['wojewodztwo']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="region" required class="form-control" value="<?= htmlspecialchars($this->g_user['region']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="city" class="col-12 col-sm-4"><?= ucfirst($lang['miasto']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="city" required class="form-control" value="<?= htmlspecialchars($this->g_user['city']); ?>">
</div>
</div>
</div>
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="postal_code" class="col-12 col-sm-4"><?= ucfirst($lang['kod-pocztowy']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="postal_code" required class="form-control" value="<?= htmlspecialchars($this->g_user['postal_code']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="street" class="col-12 col-sm-4"><?= ucfirst($lang['ulica']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="street" required class="form-control" value="<?= htmlspecialchars($this->g_user['street']); ?>">
</div>
</div>
</div>
<div class="col-12 col-sm-6">
<div class="form-group row">
<label form="apartment_number" required class="col-12 col-sm-4"><?= ucfirst($lang['nr-budynku-lokalu']); ?></label>
<div class="col-12 col-sm-8">
<input type="text" name="apartment_number" class="form-control" value="<?= htmlspecialchars($this->g_user['apartment_number']); ?>">
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= $lang['pracodawca-profil-krok-4-opis']; ?>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="logo" class="col-12 col-sm-4"><?= ucfirst($lang['logo']); ?> (max. 1mb):</label>
<div class="col-12 col-sm-8 pt10">
<input type="file" id="logo" name="logo">
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="img_logo">
<? if (file_exists(\front\factory\GlobelusFirms::logo_url($this->g_user['id']))) :?>
<img src="/logo/<?= $this->g_user['id']; ?>/<?= \S::get_token(); ?>" style="max-width: 200px;">
<a class="btn btn-danger img_logo_delete" href="#">Usuń zdjęcie</a>
<? endif; ?>
</div>
</div>
</div>
<hr />
<div class="step-title">
Zdjęcie nad ogłoszeniem<br>
<p><span><small>Ważna informacja: ta grafika będzie widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu i zmienić ją będzie można tylko w Profilu Pracodawcy.</small></span></p>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="img-header" class="col-12 col-sm-4">Zdjęcie (max. 1mb):</label>
<div class="col-12 col-sm-8 pt10">
<input type="file" id="img-header" name="img-header">
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="img_header">
<? if (file_exists(\front\factory\GlobelusFirms::img_header_url($this->g_user['id']))) :?>
<img src="/img_header/<?= $this->g_user['id']; ?>/<?= \S::get_token(); ?>" style="max-width: 200px;">
<a class="btn btn-danger img_header_delete" href="#">Usuń zdjęcie</a>
<? endif; ?>
</div>
</div>
</div>
<hr />
<hr />
<div class="step-title">
Zdjęcie pod ogłoszeniem
<p><span><small>Ważna informacja: ta grafika będzie widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu i zmienić ją będzie można tylko w Profilu Pracodawcy.</small></span></p>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="img-bottom" class="col-12 col-sm-4">Zdjęcie (max. 1mb):</label>
<div class="col-12 col-sm-8 pt10">
<input type="file" id="img-bottom" name="img-bottom">
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="img_bottom">
<? if (file_exists(\front\factory\GlobelusFirms::img_bottom_url($this->g_user['id']))) :?>
<img src="/img_bottom/<?= $this->g_user['id']; ?>/<?= \S::get_token(); ?>" style="max-width: 200px;">
<a class="btn btn-danger img_bottom_delete" href="#">Usuń zdjęcie</a>
<? endif; ?>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= ucfirst($lang['krotki-opis-firmy']); ?>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<div class="col-12">
<textarea name="other_information" id="other_information"><?= $this->g_user['other_information']; ?></textarea>
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= ucfirst(\S::lang('osoby-do-kontaktu')); ?>
<p><span><small>Ważna informacja: dane osób rekrutujących będą widoczne jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu, ale w momencie dodawania ogłoszenia będzie można je zedytować.</small></span></p>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="contact_person_1" class="col-12 col-sm-4"><?= ucfirst($lang['osoba-do-kontaktu']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="contact_person_1" value="<?= htmlspecialchars($this->g_user['contact_person_1']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="email_1" class="col-12 col-sm-4"><?= ucfirst($lang['email']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="email_1" value="<?= htmlspecialchars($this->g_user['email_1']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="phone_1" class="col-12 col-sm-4"><?= ucfirst($lang['telefon']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="phone_1" value="<?= htmlspecialchars($this->g_user['phone_1']); ?>">
</div>
</div>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="contact_person_2" class="col-12 col-sm-4"><?= ucfirst($lang['osoba-do-kontaktu']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="contact_person_2" value="<?= htmlspecialchars($this->g_user['contact_person_2']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="email_2" class="col-12 col-sm-4"><?= ucfirst($lang['email']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="email_2" value="<?= htmlspecialchars($this->g_user['email_2']); ?>">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label form="phone_2" class="col-12 col-sm-4"><?= ucfirst($lang['telefon']); ?>:</label>
<div class="col-12 col-sm-8">
<input type="text" class="form-control" name="phone_2" value="<?= htmlspecialchars($this->g_user['phone_2']); ?>">
</div>
</div>
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= \S::lang('klauzula'); ?>
<p><span><small>Ważna informacja: klauzula będzie widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu i zmienić ją będzie można tylko w Profilu Pracodawcy.</small></span></p>
</div>
<div class="subtitle warrning"></div>
<div class="row">
<div class="col-12">
<textarea name="clauses" id="clauses"><?= $this->g_user['clauses']; ?></textarea>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<div class="col-12 mt20">
<a href="/panel-pracodawcy/profil" class="btn btn-danger mr15"><?= ucfirst($lang['anuluj']); ?></a>
<input type="submit" value="<?= ucfirst($lang['zatwierdz-zmiany']); ?>" class="btn btn-success">
</div>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<link class="footer" rel="stylesheet" type="text/css" href="/libraries/framework/vendor/plugins/datepicker/css/bootstrap-datetimepicker.css">
<link class="footer" rel="stylesheet" type="text/css" href="/plugins/selectize/css/selectize.bootstrap3.css">
<link class="footer" rel="stylesheet" type="text/css" href="/plugins/summernote/summernote-lite.css">
<script class="footer" type="text/javascript" src="/plugins/summernote/summernote-lite.js"></script>
<script class="footer" type="text/javascript" src="/plugins/summernote/lang/summernote-pl-PL.js"></script>
<script class="footer" type="text/javascript" src="/libraries/framework/vendor/plugins/moment/moment.js"></script>
<script class="footer" type="text/javascript" src="/libraries/framework/vendor/plugins/moment/pl.js"></script>
<script class="footer" type="text/javascript" src="/libraries/framework/vendor/plugins/datepicker/js/bootstrap-datetimepicker.js"></script>
<script class="footer" type="text/javascript" src="/plugins/selectize/js/selectize.js"></script>
<script class="footer" type="text/javascript">
$(function() {
$('#other_information').summernote({
height: 200,
lang: 'pl-PL',
toolbar: [
['font', ['bold', 'underline', 'clear']],
['para', ['ul', 'ol', 'paragraph']],
['table', ['table']]
]
});
$('#text, #clauses').summernote({
height: 200,
lang: 'pl-PL',
toolbar: [
['style', ['bold', 'italic', 'underline', 'clear']],
['font', ['strikethrough', 'superscript', 'subscript']],
['fontsize', ['fontsize']],
['height', ['height']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['table', ['table']]
]
});
$('body').on('submit', '#user-panel form', function(e) {
if ($("#user-panel form #logo")[0].files.length && !($('#user-panel form #logo')[0].files[0].size < 125000)) {
e.preventDefault();
$.alert({
title: '<?= ucfirst($lang['blad']); ?>',
icon: 'fa fa-exclamation',
content: '<?= $lang['plik-logo-jest-zbyt-duzy']; ?>',
type: 'blue',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
autoClose: 'confirm|10000',
columnClass: 'large',
theme: 'modern',
buttons: {
confirm: {
text: '<?= $lang['zamknij']; ?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function() {}
}
}
});
}
});
$('body').on(click_event, '.input-icon .fa', function() {
$(this).parent().children('input').focus();
});
$('body').on(click_event, '#inexperience', function() {
if ($(this).is(':checked'))
$('.positions_0 input, .positions_0 select').removeAttr('required').attr('readonly', 'readonly');
else
$('.positions_0 input, .positions_0 select').attr('required', 'required').removeAttr('readonly');
});
$('input[type="text"].date').datetimepicker({
format: "YYYY-MM-DD",
pickTime: false
});
$('.countries').selectize({
maxItems: 6
});
});
/*usuwanie loga */
$( function()
{
$( 'body' ).on( click_event, '.img_logo_delete', function()
{
$.alert(
{
title: '<?= ucfirst( $lang['potwierdz'] );?>',
icon: 'fa fa-exclamation',
content: 'Czy napewno chcesz usunąć logo?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
$.ajax(
{
type: 'POST',
url: '/globelusFirms/delete_logo/',
data:
{
user_id: <?= $this -> g_user['id'];?>
},
beforeSend: function() {},
success: function( response )
{
var data = jQuery.parseJSON( response );
if ( data.result == 'ok' ) {
const img_logo = document.querySelector(".img_logo");
img_logo.classList.add("img-hide");
}
}
});
}
}
}
});
});
});
/*usuwanie zdjecia header */
$( function()
{
$( 'body' ).on( click_event, '.img_header_delete', function()
{
$.alert(
{
title: '<?= ucfirst( $lang['potwierdz'] );?>',
icon: 'fa fa-exclamation',
content: 'Czy napewno chcesz usunąć zdjęcie górne?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
$.ajax(
{
type: 'POST',
url: '/globelusFirms/delete_img_header/',
data:
{
user_id: <?= $this -> g_user['id'];?>
},
beforeSend: function() {},
success: function( response )
{
var data = jQuery.parseJSON( response );
if ( data.result == 'ok' ) {
const img_header = document.querySelector(".img_header");
img_header.classList.add("img-hide");
}
}
});
}
}
}
});
});
});
/*usuwanie zdjecia bottom */
$( function()
{
$( 'body' ).on( click_event, '.img_bottom_delete', function()
{
$.alert(
{
title: '<?= ucfirst( $lang['potwierdz'] );?>',
icon: 'fa fa-exclamation',
content: 'Czy napewno chcesz usunąć zdjęcie dolne?',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
$.ajax(
{
type: 'POST',
url: '/globelusFirms/delete_img_bottom/',
data:
{
user_id: <?= $this -> g_user['id'];?>
},
beforeSend: function() {},
success: function( response )
{
var data = jQuery.parseJSON( response );
if ( data.result == 'ok' ) {
const img_bottom = document.querySelector(".img_bottom");
img_bottom.classList.add("img-hide");
}
}
});
}
}
}
});
});
});
</script>

View File

@@ -0,0 +1,218 @@
<? global $lang;?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'moj-profil'
] );?>
<div class="mini-box fluid">
<div class="title">
<?= $this -> g_user['firm_name_profile'] != '' ? htmlspecialchars( $this -> g_user['firm_name_profile'] ) : 'Twój profil'?>
<span class="pull-right text-danger small">
Posiadasz <?= \front\factory\GlobelusFirms::get_firm_points( $this -> g_user['id'] );?> pkt. <a href="/panel-pracodawcy/zakup-punktow">Dokup więcej.</a>
</span>
</div>
<div class="subtitle">
<?= $lang['moj-profil-podtytul-pracodawca'];?>
<a href="/panel-pracodawcy/edycja-profilu" class="btn btn-success"><?= $lang['edytuj-profil'];?></a>
</div>
<div class="row">
<div class="col-12">
<div class="content profil">
<div class="row">
<div class="col-12">
<div class="logo-container">
<div class="name"><?= htmlspecialchars( $this -> g_user['firm_name'] );?></div>
<div class="logo">
<? if ( file_exists( \front\factory\GlobelusFirms::logo_url( $this -> g_user['id'] ) ) ):?>
<img src="/logo/<?= $this -> g_user['id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-logo.jpg">
<? endif;?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['nazwa-firmy'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['firm_name'] );?>
</div>
</div>
</div>
<div class="col-12">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['nazwa-firmy-publikowana-na-portalu'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['firm_name_profile'] );?>
</div>
</div>
</div>
<div class="col-12">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['numer-identyfikacji-podatkowej'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['nip_vat'] );?>
</div>
</div>
</div>
</div>
<hr/>
<div class="step-title">
<?= $lang['pracodawca-profil-krok-2-opis'];?>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['telefon'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['phone'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['adres-email'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['email'] );?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['strona-www'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['www'] );?>
</div>
</div>
</div>
</div>
<hr />
<div class="step-title">
<?= $lang['pracodawca-profil-krok-3-opis'];?>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['kraj'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['country'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['region'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['region'] );?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['miasto'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['city'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['kod-pocztowy'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['postal_code'] );?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['ulica'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['street'] );?>
</div>
</div>
</div>
<div class="col-12 col-md-6">
<div class="form-group row">
<label class="col-12 col-sm-4"><?= ucfirst( $lang['nr-budynku-lokalu'] );?>:</label>
<div class="col-12 col-sm-8">
<?= htmlspecialchars( $this -> g_user['apartment_number'] );?>
</div>
</div>
</div>
</div>
<hr/>
<div class="row">
<div class="col-12">
<div class="step-title">
<?= ucfirst( \S::lang( 'osoby-do-kontaktu' ) );?>
<p><span><small>Ważna informacja: dane osób rekrutujących będą widoczne jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu, ale w momencie dodawania ogłoszenia będzie można je zedytować.</small></span></p>
</div>
<div class="form-group row">
<div class="col-md-6">
<?= $this -> g_user['contact_person_1'];?><br />
<?= $this -> g_user['email_1'];?><br />
<?= $this -> g_user['phone_1'];?>
</div>
<div class="col-md-6">
<?= $this -> g_user['contact_person_2'];?><br />
<?= $this -> g_user['email_2'];?><br />
<?= $this -> g_user['phone_2'];?>
</div>
</div>
</div>
</div>
<hr/>
<div class="step-title">
<?= ucfirst( $lang['krotki-opis-firmy'] );?>
</div>
<div class="row">
<div class="col-12">
<?= $this -> g_user['other_information'];?>
</div>
</div>
<hr/>
<div class="step-title">
<?= ucfirst( \S::lang( 'klauzula' ) );?>
<p><span><small>Ważna informacja: klauzula będzie widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu i zmienić ją będzie można tylko w Profilu Pracodawcy.</small></span></p>
</div>
<div class="row">
<div class="col-12">
<?= $this -> g_user['clauses'];?>
</div>
</div>
<?
$img_header_url = \front\factory\GlobelusFirms::img_header_url( $this -> g_user['id'] );
if ( file_exists( $img_header_url ) ):?>
<hr/>
<div class="step-title">
Zdjęcie nad ogłoszeniem
<p><span><small>Ważna informacja: klauzula będzie widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu i zmienić ją będzie można tylko w Profilu Pracodawcy.</small></span></p>
</div>
<div class="image_header"><img src="/img_header/<?= $this->g_user['id'];?>/<?= \S::get_token();?>"></div>
<?
endif;
?>
<?
$img_bottom_url = \front\factory\GlobelusFirms::img_bottom_url( $this -> g_user['id'] );
if ( file_exists( $img_bottom_url ) ):?>
<hr/>
<div class="step-title">
Zdjęcie pod ogłoszeniem
<p><span><small>Ważna informacja: klauzula będzie widoczna jednocześnie we wszystkich ogłoszeniach publikowanych z tego profilu i zmienić ją będzie można tylko w Profilu Pracodawcy.</small></span></p>
</div>
<div class="image_bottom"><img src="/img_bottom/<?= $this->g_user['id'];?>/<?= \S::get_token();?>"></div>
<?
endif;
?>
</div>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,118 @@
<? global $lang;?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'ustawienia-konta'
] );?>
<div class="mini-box fluid">
<div class="title">
<?= ucfirst( $lang['ustawienia-konta'] );?>
</div>
<div class="subtitle">
<?= $lang['ustawienia-konta-podtytul'];?>
</div>
<div class="container-fluid">
<div class="row">
<div class="col-12">
<div class="content profil">
<form method="POST" action="/globelusFirms/change_password/">
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="current_password" class="col-12 col-sm-4"><?= ucfirst( $lang['obecne-haslo'] );?>:</label>
<div class="col-12 col-sm-8">
<input type="password" required id="current_password" name="current_password" class="form-control">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="new_password" class="col-12 col-sm-4"><?= ucfirst( $lang['nowe-haslo'] );?>:</label>
<div class="col-12 col-sm-8">
<input type="password" required id="new_password" name="new_password" pattern="^\S{6,}$" class="form-control">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<label form="repeat_new_password" class="col-12 col-sm-4"><?= ucfirst( $lang['powtorz-nowe-haslo'] );?>:</label>
<div class="col-12 col-sm-8">
<input type="password" required id="repeat_new_password" name="repeat_new_password" pattern="^\S{6,}$" class="form-control" oninput="check_match(this)">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-12 col-md-6">
<div class="form-group row">
<div class="col-12 col-sm-8 offset-sm-4 mt20">
<input type="submit" value="<?= ucfirst( $lang['zmien-haslo'] );?>" class="btn btn-success">
</div>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
<hr/>
<div class="subtitle">
<?= $lang['usuwanie-konta-podtytul'];?>
</div>
<div class="row">
<div class="col-12 col-md-6">
<a href="#" class="btn btn-danger account-delete"><?= ucfirst( $lang['usun-konto'] );?></a>
</div>
</div>
</div>
</div>
<script class="footer" type="text/javascript">
$( function()
{
$( 'body' ).on( click_event, '.account-delete', function()
{
$.alert(
{
title: '<?= ucfirst( $lang['potwierdz'] );?>',
icon: 'fa fa-exclamation',
content: '<?= $lang['potwierdz-usuniecie-konta'];?>',
closeIcon: true,
closeIconClass: 'fa fa-close',
typeAnimated: true,
animation: 'opacity',
columnClass: 'large',
theme: 'modern',
buttons:
{
cancel:
{
text: '<?= $lang['anuluj'];?>',
action: function() {}
},
confirm:
{
text: '<?= $lang['zatwierdz'];?>',
btnClass: 'btn-blue',
keys: ['enter'],
action: function()
{
document.location.href="/globelusUser/delete_account/";
}
}
}
});
});
});
function check_match(input)
{
if ( input.value !== document.getElementById( 'new_password' ).value )
input.setCustomValidity( '<?= $lang['podane-hasla-sa-rozne' ];?>');
else
input.setCustomValidity('');
}
</script>

View File

@@ -0,0 +1,93 @@
<? global $lang;?>
<div id="user-panel">
<?= \Tpl::view( 'globelus/firms/_partials/menu', [
'active' => 'proponowani-kandydaci'
] );?>
<!--<div class="form-group row">
<label form="sex" class="col-12" style="text-align: left;">Wybierz ogłoszenie:</label>
<div class="col-12">
<select class="form-control" onchange="document.location.href='/panel-pracodawcy/proponowani-kandydaci?aid=' + $( this ).val();">
<option value="0">--- wszystkie ogłoszenia ---</option>
<? foreach ( $this -> adverts as $advert ):?>
<option value="<?= $advert['id'];?>" <? if ( $this -> current_advert == $advert['id'] ):?>selected="selected"<? endif;?>><?= $advert['title'];?></option>
<? endforeach;?>
</select>
</div>
</div>-->
<div class="mini-box fluid">
<?
if ( is_array( $this -> candidates ) and count( $this -> candidates ) ):
foreach ( $this -> candidates as $candidate_id ):
$candidate = \front\factory\GlobelusUser::user_details( $candidate_id );
?>
<div class="cv-entry <? if ( $candidate['highlight'] ):?>highlight<? endif;?>">
<? if ( $candidate['highlight'] ):?><div id="highlight-text">Kandydat wyróżniony</div><? endif;?>
<div class="row">
<div class="col-12 col-sm-2">
<div class="img">
<? if ( file_exists( \front\factory\GlobelusCandidates::avatar_url( $candidate['id'] ) ) ):?>
<img src="/avatar/<?= $candidate['id'];?>/<?= \S::get_token();?>">
<? else:?>
<img src="/images/no-avatar.png">
<? endif;?>
</div>
</div>
<div class="col-12 col-sm-10">
<div class="row">
<div class="col-12 col-sm-8">
<h2>
<a href="/proponowany-kandydat/<?= $candidate['id'];?>/<?= \S::seo( $candidate['surname'] . ' ' . $candidate['name'], true );?>/" title="Kandydat: <?= addslashes( $candidate['surname'] . ' ' . $candidate['name'] );?>"><?= $candidate['surname'] . ' ' . $candidate['name'];?></a>
</h2>
</div>
<div class="col-12 col-sm-4 sex-and-birth">
<?= $lang['plec'];?>:
<?
if ( $candidate['sex'] == '1' )
echo $lang['mezczyzna'];
else if ( $candidate['sex'] == '0' )
echo $lang['kobieta'];
else
echo '-';
?>
<? if ( $candidate['date_of_birth'] and $candidate['date_of_birth'] != '1970-01-01' ):?>
, <?= $lang['wiek'];?>: <?= $age = \S::date_diff( $candidate['date_of_birth'], date( 'Y-m-d H:i:s' ), 60 * 60 * 24 * 365.25 );?> <?= \front\factory\Globelus::age_word_translations( $age );?>
<? endif;?>
</div>
</div>
<div class="info">
<?= $lang['tel.'];?> <?= $candidate['phone'];?>, <?= $lang['email'];?>: <a href="mailto:<?= $candidate['email'];?>"><?= $candidate['email'];?></a>
</div>
<div class="info-2">
<?
if ( is_array( $candidate['positions'] ) and count( $candidate['positions'] ) ):
echo '<p class="mb0">Chętnie podejmę pracę na stanowisku:<br />';
foreach ( $candidate['positions'] as $position ):
if ( !$position['id_position'] )
continue;
echo ' ● <strong>' . \front\factory\Globelus::position_name( $position['id_position'] ) . '</strong>'; if ( $position['experience'] ) echo ' - ' . $lang['moj-staz-na-tym-stanowisku'] . ' ' . $this -> positions_experience[ $position['experience'] ];
if ( $position != end( $candidate['positions'] ) )
echo '<br />';
endforeach;
echo '</p>';
endif;
?>
</div>
<div class="info-2">
<?= $candidate['sex'] ? $lang['ostatnio-szukal-pracy'] : $lang['ostatnio-szukala-pracy'];?>: <strong><?= $candidate['last_refresh'] ? date( 'Y-m-d', strtotime( $candidate['last_refresh'] ) ) : date( 'Y-m-d', strtotime( $candidate['register_date'] ) );?></strong>
</div>
<div class="short-text">
<?= $advert['short_text'];?>
</div>
<a href="/proponowany-kandydat/<?= $candidate['id'];?>/<?= \S::seo( $candidate['surname'] . ' ' . $candidate['name'], true );?>/" class="btn btn-success" target="_blank"><?= $lang['profil-kandydata'];?></a>
</div>
</div>
</div>
<? endforeach;
else:
?>
<div class="alert alert-danger">Brak proponowanych kandydatów</div>
<?
endif;?>
</div>
</div>