remotes/origin/1203
Назар Котюк 11 years ago
commit 7468bb6488
  1. 2
      proj/settings.py
  2. 76
      templates/client/accounts/new_profile.html
  3. 4
      templates/client/blank.html
  4. 163
      templates/client/includes/accounts/current_user.html
  5. 3
      templates/client/includes/accounts/simple_user.html
  6. 26
      templates/client/static_client/css/main.css
  7. 41
      templates/client/static_client/js/_modules/page.profile.js
  8. 1
      templates/client/static_client/js/min/_modules/block.common.min.js
  9. 1
      templates/client/static_client/js/min/_modules/block.exposition.list.min.js
  10. 1
      templates/client/static_client/js/min/_modules/block.search.min.js
  11. 1
      templates/client/static_client/js/min/_modules/page.company.min.js
  12. 1
      templates/client/static_client/js/min/_modules/page.events.feed.min.js
  13. 1
      templates/client/static_client/js/min/_modules/page.exposition.object.min.js
  14. 1
      templates/client/static_client/js/min/_modules/page.index.min.js
  15. 1
      templates/client/static_client/js/min/_modules/page.place.object.min.js
  16. 1
      templates/client/static_client/js/min/_modules/page.place.photo.min.js
  17. 1
      templates/client/static_client/js/min/_modules/page.profile.min.js
  18. 7
      templates/client/static_client/js/min/app.min.js

@ -412,4 +412,4 @@ except ImportError, e:
""" """
ADMIN_PAGINATION = 20 ADMIN_PAGINATION = 20
CLIENT_PAGINATION = 15 CLIENT_PAGINATION = 15
TEMPLATE_DEBUG = DEBUG TEMPLATE_DEBUG = DEBUG

@ -444,6 +444,44 @@
</div> </div>
</div> </div>
{% block scripts %}
<!-- mask select scripts-->
<script src="{% static 'client/js/plugins/inputmask/jquery.inputmask.js' %}"></script>
<script src="{% static 'client/js/plugins/inputmask/jquery.bind-first-0.2.3.min.js' %}"></script>
<script src="{% static 'client/js/plugins/inputmask/jquery.inputmask-multi.js' %}"></script>
<!-- page module-->
<!--<script src="{% static 'client/js' %}{% if debug %}/{% else %}_min/{% endif %}_modules/page.profile{% if debug %}{% else %}.min{% endif %}.js"></script>-->
<script src="{% static 'client/js/_modules/page.profile.js' %}"></script>
<script>
//js module initialization
EXPO.profile.init({
// class selector to identify required forms on page
updateFormClass:'update-profile-form',
// text and paths for dynamically rendered selectboxes
selectBox:[
{id:'id_country'},
{id:'id_theme',
placeHolder:'Выберите тематику компании'
},
{id:'id_city',
placeholder:'Search city',
path:'http://{{ request.get_host }}/city/get-city/'
},
{id:'id_company',
placeholder:'Search company',
path:'http://{{ request.get_host }}/company/get-company/'
}
],
// we need this id to enable mapping library
phoneBox: 'id_phone',
// some helper text in current language
lang:{
workIn:'в'// there must be 'at' in English
}
});
</script>
{% endblock %}
</div> </div>
{% endblock %} {% endblock %}
{% block popup %} {% block popup %}
@ -457,40 +495,4 @@
<script src="{% static 'client/js/plugins/select2_locale_ru.js' %}"></script> <script src="{% static 'client/js/plugins/select2_locale_ru.js' %}"></script>
{% endblock %} {% endblock %}
{% block scripts %}
<!-- mask select scripts-->
<script src="{% static 'client/js/plugins/inputmask/jquery.inputmask.js' %}"></script>
<script src="{% static 'client/js/plugins/inputmask/jquery.bind-first-0.2.3.min.js' %}"></script>
<script src="{% static 'client/js/plugins/inputmask/jquery.inputmask-multi.js' %}"></script>
<!-- page module-->
<script src="{% static 'client/js' %}{% if debug %}/{% else %}_min/{% endif %}_modules/page.profile{% if debug %}{% else %}.min{% endif %}.js"></script>
<script>
//js module initialization
EXPO.profile.init({
// class selector to identify required forms on page
updateFormClass:'update-profile-form',
// text and paths for dynamically rendered selectboxes
selectBox:[
{id:'id_country'},
{id:'id_theme',
placeHolder:'Выберите тематику компании'
},
{id:'id_city',
placeholder:'Search city',
path:'http://{{ request.get_host }}/city/get-city/'
},
{id:'id_company',
placeholder:'Search company',
path:'http://{{ request.get_host }}/company/get-company/'
}
],
// we need this id to enable mapping library
phoneBox: 'id_phone',
// some helper text in current language
lang:{
workIn:'в'// there must be 'at' in English
}
});
</script>
{% endblock %}

@ -24,7 +24,9 @@ This template include basic anf main styles and js files,
<link rel="shortcut icon" href="{% static 'client/img/favicon.ico' %}" type="image/x-icon" /> <link rel="shortcut icon" href="{% static 'client/img/favicon.ico' %}" type="image/x-icon" />
<link rel="stylesheet" href="{% static 'client/css' %}{% if debug %}/{% else %}_min/{% endif %}vendor{% if debug %}{% else %}.min{% endif %}.css"> <link rel="stylesheet" href="{% static 'client/css' %}{% if debug %}/{% else %}_min/{% endif %}vendor{% if debug %}{% else %}.min{% endif %}.css">
<link rel="stylesheet" href="{% static 'client/css' %}{% if debug %}/{% else %}_min/{% endif %}main{% if debug %}{% else %}.min{% endif %}.css"> <!--todo: вернуть минифицированную версию-->
<!--<link rel="stylesheet" href="{% static 'client/css' %}{% if debug %}/{% else %}_min/{% endif %}main{% if debug %}{% else %}.min{% endif %}.css">-->
<link rel="stylesheet" href="{% static 'client/css/main.css' %}">
<script src="{% static 'client/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js' %}"></script> <script src="{% static 'client/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js' %}"></script>
<script src="{% static 'client/js/vendor/jquery-1.10.1.min.js' %}"></script> <script src="{% static 'client/js/vendor/jquery-1.10.1.min.js' %}"></script>

@ -1,16 +1,23 @@
{% load static %} {% load static %}
{% load i18n %} {% load i18n %}
{% load template_filters %} {% load template_filters %}
{% load thumbnail %}
<div class="m-article"> <div class="m-article edit-profile">
<div class="item-wrap clearfix"> <div class="item-wrap clearfix">
{# avatar #} {# avatar #}
<aside> <aside>
<div class="i-pict p-editable"> <div class="i-pict p-editable">
{% if request.user.profile.avatar %} {% if request.user.profile.avatar %}
<img src="{{ request.user.profile.avatar.url }}" alt="" /> <div id="pick-block" class="pic_block">
{% endif %}
{% thumbnail request.user.profile.avatar "100x100" crop="center" as im %}
<img clas="user-avatar" src="{{ im.url }}" width="{{ im.width }}" height="{{ im.height }}"/>
{% endthumbnail %}
{% if request.user.profile.avatar %}
</div>
{% endif %} {% endif %}
<div class="edit-wrap"> <div class="edit-wrap">
<a class="e-btn" href="#">{% trans 'редактировать' %}</a> <a class="e-btn" href="#">{% trans 'редактировать' %}</a>
@ -51,7 +58,7 @@
{% else %} {% else %}
<span style="display:none;"> <span style="display:none;">
{% endif %} {% endif %}
<a href="#">{{ home_form.instance.country }}</a> <span id="static-home-country">{{ home_form.instance.country }}</span>
</span> </span>
{% if home_form.instance.city %} {% if home_form.instance.city %}
@ -59,7 +66,7 @@
{% else %} {% else %}
<span style="display:none;"> <span style="display:none;">
{% endif %} {% endif %}
, <a href="#">{{ home_form.instance.city }}</a> , <span id="static-home-city">{{ home_form.instance.city }}</span>
</span> </span>
<div class="edit-wrap e-left"> <div class="edit-wrap e-left">
@ -79,9 +86,7 @@
<div class="epfl"> <div class="epfl">
<label>{% trans 'Город' %}</label> <label>{% trans 'Город' %}</label>
<div class="epf-field"> <div class="epf-field">
<select name="city" style="width: 200px;"> {{ home_form.city }}
</select>
</div> </div>
</div> </div>
@ -99,7 +104,9 @@
{# name #} {# name #}
<div class="i-title p-editable"> <div class="i-title p-editable">
<span>{{ name_form.get_full_name }}</span> <span id="static-name-value">
{{ name_form.get_full_name }}
</span>
<div class="edit-wrap"> <div class="edit-wrap">
<a class="e-btn" href="#">{% trans 'редактировать' %}</a> <a class="e-btn" href="#">{% trans 'редактировать' %}</a>
<div class="e-form"> <div class="e-form">
@ -137,7 +144,7 @@
{# position #} {# position #}
<div class="i-position p-editable"> <div class="i-position p-editable">
<p> <p id="static-work-value">
{{ work_form.position.value }} {{ work_form.position.value }}
{% if work_form.work.value %} {% if work_form.work.value %}
{% trans 'в' %} {{ work_form.work.value }} {% trans 'в' %} {{ work_form.work.value }}
@ -177,62 +184,50 @@
</div> </div>
</div> </div>
{# END position #} {# END position #}
{# description #}
<div class="i-descr p-editable">
<p>{{ about_company_form.about_company.value }}</p>
<div class="edit-wrap">
<a class="e-btn" href="#">{% trans 'редактировать' %}</a>
<div class="e-form">
<form class="clearfix update-profile-form" id="about_company_form" action="/profile/update/about-company/" method="post">{% csrf_token %}
<div class="ef-body">
<div class="epfl">
<label>{{ about_company_form.about_company.label }}</label>
<div class="epf-field">
{{ about_company_form.about_company }}
</div>
</div>
</div>
<div class="ef-buttons">
<button type="submit" class="lnk icon-save">{% trans 'Сохранить' %}</button>
</div>
</form>
<a class="ef-close" href="#">{% trans 'закрыть' %}</a>
</div>
</div>
</div>
{# END description #}
<hr /> <hr />
<div class="i-contacts clearfix"> <div class="i-contacts clearfix">
<div class="ic-buttons"> <div class="ic-buttons">
<a class="button icon-edit icb-edit-profile" href="#">{% trans 'редактировать профиль' %}</a>
<a class="button orange icon-edit icb-exit-edit" href="#">{% trans 'завершить редактирование' %}</a>
<div class="p-editable"> <div class="p-editable">
<ul class="soc-media-buttons"> <ul class="soc-media-buttons soc-media-buttons1">
<li><a href="{% if social_form.facebook.value %} {{ social_form.facebook.value }} {%else %}#{% endif %}"> <li>
<img src="{% static 'client/img/soc-medias/sm-icon-fb.png' %}" title="Facebook" alt="Facebook" /> {% if social_form.facebook.value %}
<a href="{{ social_form.facebook.value }}" target="_blank">
<img id="img-facebook" src="{% static 'client/img/soc-medias/sm-icon-fb.png' %}" title="Facebook" alt="Facebook" />
</a> </a>
{% else %}
<img id="img-facebook" src="{% static 'client/img/soc-medias/sm-icon-fb_hover.png' %}" title="Facebook" alt="Facebook" />
{% endif %}
</li> </li>
<li><a href="{% if social_form.linkedin.value %} {{ social_form.linkedin.value }} {%else %}#{% endif %}"> <li>
<img src="{% static 'client/img/soc-medias/sm-icon-lin.png' %}" title="LinkedIn" alt="LinkedIn" /> {% if social_form.linkedin.value %}
<a href="{{ social_form.linkedin.value }}" target="_blank">
<img id="img-linkedin" src="{% static 'client/img/soc-medias/sm-icon-lin.png' %}" title="LinkedIn" alt="LinkedIn" />
</a> </a>
</li> {% else %}
<li><a href="{% if social_form.vk.value %} {{ social_form.vk.value }} {%else %}#{% endif %}"> <img id="img-linkedin" src="{% static 'client/img/soc-medias/sm-icon-lin_hover.png' %}" title="LinkedIn" alt="LinkedIn" />
<img src="{% static 'client/img/soc-medias/sm-icon-vk.png' %}" title="В контакте" alt="В контакте" /> {% endif %}
<li>
{% if social_form.vk.value %}
<a href="{{ social_form.vk.value }}" target="_blank">
<img id="img-vk" src="{% static 'client/img/soc-medias/sm-icon-vk.png' %}" title="В контакте" alt="В контакте" />
</a> </a>
{% else %}
<img id="img-vk" src="{% static 'client/img/soc-medias/sm-icon-vk_hover.png' %}" title="В контакте" alt="В контакте" />
{% endif %}
</li> </li>
<li><a href="{% if social_form.twitter.value %} {{ social_form.twitter.value }} {%else %}#{% endif %}">
<img src="{% static 'client/img/soc-medias/sm-icon-twit.png' %}" title="Twitter" alt="Twitter" /> <li>
{% if social_form.twitter.value %}
<a href="{{ social_form.twitter.value }}" target="_blank">
<img id="img-twitter" src="{% static 'client/img/soc-medias/sm-icon-twit.png' %}" title="Twitter" alt="Twitter" />
</a> </a>
</li> {% else %}
</ul> <img id="img-twitter" src="{% static 'client/img/soc-medias/sm-icon-twit_hover.png' %}" title="Twitter" alt="Twitter" />
{% endif %}
</li></li>
</ul>
<div class="edit-wrap"> <div class="edit-wrap">
<a class="e-btn" href="#">{% trans 'редактировать' %}</a> <a class="e-btn" href="#">{% trans 'редактировать' %}</a>
<div class="e-form"> <div class="e-form">
@ -284,7 +279,7 @@
<div class="ic-links"> <div class="ic-links">
<div class="ic-tel p-editable"> <div class="ic-tel p-editable">
{% if phone_form.phone.value %} {% if phone_form.phone.value %}
<span>{{ phone_form.phone.value|phone }}</span> <span id="static-phone-value">{{ phone_form.phone.value|phone }}</span>
{% endif %} {% endif %}
<div class="edit-wrap"> <div class="edit-wrap">
<a class="e-btn" href="#">{% trans 'редактировать' %}</a> <a class="e-btn" href="#">{% trans 'редактировать' %}</a>
@ -345,7 +340,7 @@
<div class="ic-site p-editable"> <div class="ic-site p-editable">
{% if web_page_form.web_page.value %} {% if web_page_form.web_page.value %}
<a class="icon-ext-link" href="{% if web_page_form.web_page.value %}{{ web_page_form.web_page.value }}{% else %}#{% endif %}" target="_blank"> <a class="icon-ext-link" id="static-web-page-value" href="{% if web_page_form.web_page.value %}{{ web_page_form.web_page.value }}{% else %}#{% endif %}" target="_blank">
{% if web_page_form.web_page.value %} {% if web_page_form.web_page.value %}
{{ web_page_form.web_page.value }} {{ web_page_form.web_page.value }}
{% endif %} {% endif %}
@ -388,7 +383,7 @@
<div class="ia-title">{% trans 'О себе:' %}</div> <div class="ia-title">{% trans 'О себе:' %}</div>
<div class="p-editable"> <div class="p-editable">
<p>{{ about_form.about.value }}</p> <p id="static-about-value">{{ about_form.about.value }}</p>
<div class="edit-wrap"> <div class="edit-wrap">
<a class="e-btn" href="#">{% trans 'редактировать' %}</a> <a class="e-btn" href="#">{% trans 'редактировать' %}</a>
@ -423,27 +418,41 @@
</div> </div>
{% block scripts %} {% block scripts %}
<!-- mask select scripts-->
<script src="{% static 'client/js/plugins/inputmask/jquery.inputmask.js' %}"></script>
<script src="{% static 'client/js/plugins/inputmask/jquery.bind-first-0.2.3.min.js' %}"></script>
<script src="{% static 'client/js/plugins/inputmask/jquery.inputmask-multi.js' %}"></script>
<!-- page module-->
<!--todo: вернуть минифицированную версию-->
<!--<script src="{% static 'client/js' %}{% if debug %}/{% else %}_min/{% endif %}_modules/page.profile{% if debug %}{% else %}.min{% endif %}.js"></script>-->
<script src="{% static 'client/js/_modules/page.profile.js' %}"></script> <script src="{% static 'client/js/_modules/page.profile.js' %}"></script>
<script> <script>
//js module initialization //js module initialization
EXPO.profile.init({ EXPO.profile.init({
// class seletor to identify required forms on page // class selector to identify required forms on page
updateFormClass:'update-profile-form', updateFormClass:'update-profile-form',
// text and paths for dynamically rendered selectboxes // text and paths for dynamically rendered selectboxes
selectBox:[ selectBox:[
{id:'id_country'}, {id:'id_country'},
{id:'id_theme', {id:'id_theme',
placeHolder:'Выберите тематику компании' placeHolder:'Выберите тематику компании'
}, },
{id:'id_city', {id:'id_city',
placeholder:'Search city', placeholder:'Поиск города',
path:'/city/get-city/' path:'http://{{ request.get_host }}/city/get-city/'
}, },
{id:'id_company', {id:'id_company',
placeholder:'Search company', placeholder:'Поиск компании',
path:'/company/get-company/' path:'http://{{ request.get_host }}/company/get-company/'
} }
] ],
}); // we need this id to enable mapping library
phoneBox: 'id_phone',
// some helper text in current language
lang:{
workIn:'в'// there must be 'at' in English
}
});
</script> </script>
{% endblock %} {% endblock %}

@ -8,7 +8,8 @@
<aside> <aside>
{% if member.profile.avatar %} {% if member.profile.avatar %}
<div class="i-pict"> <div class="i-pict">
<img src="{{ member.profile.avatar.url }}" alt="" /> <img clas="user-avatar" src="{{ im.url }}" width="{{ im.width }}" height="{{ im.height }}">
</div> </div>
{% endif %} {% endif %}
</aside> </aside>

@ -8045,6 +8045,7 @@ a.order-button:hover .ob-text,
margin: -1px 0 0 -6px; margin: -1px 0 0 -6px;
} }
.i-pict.p-editable .edit-wrap { .i-pict.p-editable .edit-wrap {
left: 100%; left: 100%;
top: 5px; top: 5px;
@ -8152,7 +8153,7 @@ a.order-button:hover .ob-text,
left: 28px; left: 28px;
top: 0; top: 0;
width: 600px; width: 600px;
z-index: 1000; z-index: 2;
font-family: 'dindisplay_pro', Arial, sans-serif; font-family: 'dindisplay_pro', Arial, sans-serif;
font-size: 12px; font-size: 12px;
line-height: 15px; line-height: 15px;
@ -12615,3 +12616,26 @@ hr + .rq-note {
.calenadar-body{ .calenadar-body{
overflow: hidden; overflow: hidden;
} }
/************************\
# страница редактирования профиля
\***********************/
.edit-profile .edit-wrap{
display: block;
}
.edit-profile .pe-current .e-form{
display: block;
}
.edit-profile .p-editable{
padding-left: 22px;
}
.edit-profile .p-editable.i-place{
padding-left: 36px;
}
.edit-profile .i-pict.p-editable{
padding: 0;
}
.edit-profile .i-pict.p-editable img{
z-index: 0;
}

@ -54,7 +54,8 @@ if (EXPO.profile){
if(typeof handler == 'function'){ if(typeof handler == 'function'){
// if particular data change required // if particular data change required
handler(data); this.formData = handler(data, formName);
this.getajax(data);
$('#wait-ajax').show(); $('#wait-ajax').show();
} else{ } else{
this.getajax(data); this.getajax(data);
@ -142,8 +143,7 @@ if (EXPO.profile){
var self = this; var self = this;
this.pullHandler = function (data) { this.pullHandler = function (data) {
if (data.success){ if (data.success){
var company = $('#s2id_id_company').find('.select2-chosen').text(); $('#static-work-value').text($('#id_position').val());
$('#static-work-value').html($('#id_position').val()+' '+EXPO.profile.lang.workIn+' <a href="'+data.url+'">"'+ company+'"</a>');
$('.p-editable').removeClass('pe-current'); $('.p-editable').removeClass('pe-current');
} }
@ -159,15 +159,6 @@ if (EXPO.profile){
}; };
this.ajaxPath = path; this.ajaxPath = path;
};
Forms.social_form = function (path) {
this.pullHandler = function (data) {
if (data.success){
window.location.reload();
}
};
this.ajaxPath = path;
}; };
Forms.phone_form = function (path) { Forms.phone_form = function (path) {
var self = this; var self = this;
@ -250,6 +241,15 @@ if (EXPO.profile){
} }
$('.p-editable').removeClass('pe-current'); $('.p-editable').removeClass('pe-current');
} }
};
this.pushHandler = function (data, formName){
var formData = $('#'+formName).serialize();
return JSON.parse('{"' + decodeURI(formData).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g,'":"') + '"}');
}; };
this.ajaxPath = path; this.ajaxPath = path;
@ -260,18 +260,13 @@ if (EXPO.profile){
$editPhoto = $('#pic-edit-photo'), $editPhoto = $('#pic-edit-photo'),
$pickBlock = $('#pick-block'), $pickBlock = $('#pick-block'),
$form, $form,
$avatar = $('.pic_block img'); $avatar = $('img',$pickBlock);
this.pullHandler = function (data) { this.pullHandler = function (data) {
if (data.success){ if (data.success){
if($avatar.length){ if($avatar.length){
$avatar.attr('src', data.url); $avatar.attr('src', data.url);
}else{
$pickBlock.removeClass('add_pic_block').addClass('pic_block');
$('.add-wrapper', $pickBlock).remove();
$('<img/>').attr('src', data.url).prependTo($pickBlock);
} }
// $('#static-about-value').text($('#id_about').val());
$('.p-editable').removeClass('pe-current'); $('.p-editable').removeClass('pe-current');
} }
}; };
@ -288,16 +283,10 @@ if (EXPO.profile){
$input.on('change', function () { $input.on('change', function () {
$(this).parents('form').submit(); $(this).parents('form').submit();
}); });
$editPhoto.on('click', function () {
$input.trigger('click');
});
// pick-block
this.ajaxPath = path;
}
$(function () { this.ajaxPath = path;
};
});
// methods // methods
//инициализация общих свойств //инициализация общих свойств

@ -1 +0,0 @@
var EXPO=EXPO||{};EXPO.common?console.warn("WARNING: EXPO.common is already defined!"):EXPO.common=function(){var e={},t=function(e,t){return(e.matches||e.matchesSelector||e.msMatchesSelector||e.mozMatchesSelector||e.webkitMatchesSelector||e.oMatchesSelector).call(e,t)};e.opt={};var s=function(e){this.fields=[],this.allIsClear=!1,this.ajaxUrl=e.getAttribute("action"),this.DOM=e,this._initFields(),this._eventController()};return s.prototype={_eventController:function(){var e=this;this.DOM.addEventListener?this.DOM.addEventListener("submit",function(t){return e.validate(),t.preventDefault(),!1},!1):this.DOM.attachEvent&&this.DOM.attachEvent("onsubmit",function(t){return e.validate(),t.preventDefault(),!1})},_initFields:function(){},validate:function(){var e,t=this,s=$(t.DOM).serialize(),i={},o="err-message-box",n=t.DOM.querySelector("."+o),a=n.innerHTML,r=function(s){if(e=s,t.unHighlightFields(),e.success)n&&EXPO.common.removeClass(n,"active"),window.location.reload();else{EXPO.common.removeClass(n,"active"),i={},t.fields=[];for(var o in e.errors)e.errors.hasOwnProperty(o)&&("__all__"!=o?(i={name:o,id:"id_"+o,errorText:e.errors[o]},t.fields.push(i)):n&&(EXPO.common.addClass(n,"active"),a.indexOf(e.errors[o])<0&&n.insertAdjacentHTML("beforeend",e.errors[o]+" ")));t.highliteFields()}};t.unHighlightFields(),EXPO.common.postRequest(s,t.ajaxUrl,r)},highliteFields:function(){for(var e,t,s=0;s<this.fields.length;s++)e=this.DOM.querySelector("#"+this.fields[s].id),t=e.parentNode,EXPO.common.addClass(t,"required"),EXPO.common.addClass(t,"err")},unHighlightFields:function(){for(var e,t,s=0;s<this.fields.length;s++)e=this.DOM.querySelector("#"+this.fields[s].id),t=e.parentNode,EXPO.common.removeClass(t,"required"),EXPO.common.removeClass(t,"err")},submit:function(){}},e.forms=[],$(function(){$("form.validate").each(function(){e.forms.push(new s(this))})}),$(function(){$.fn.customRadioCheck=function(){return $(this).each(function(){function e(){if("radio"==s){var e=t.attr("name"),i=$('input[type="radio"]').filter('[name="'+e+'"]');i.each(function(){var e=$(this).closest(".custom-radio");e.removeClass("checked"),$(this).is(":checked")&&e.addClass("checked")})}else t.prop("checked")?o.addClass("checked"):o.removeClass("checked");t.trigger("blur")}var t=$(this),s=t.attr("type"),i=t.closest("label"),o=t.wrap("<span class='custom-"+s+"' />").parent();i.addClass("custom-radio-check"),e(),t.on("change",e)})},$("input[type='checkbox'], input[type='radio']").customRadioCheck()}),e.init=function(e){$.extend(this.opt,e);var t=this,s=this.opt.addCalendarClass,i=this.opt.removeCalendarClass,o=this.opt.addCalendarText,n=this.opt.removeCalendarText;$(function(){$("."+s+", ."+i).on("click",function(e){o=t.opt.addCalendarText,n=t.opt.removeCalendarText,e.preventDefault();var a=$(this),r=a.attr("href");$.get(r,function(e){e.not_authorized?$.fancybox.open("#"+t.opt.loginModalId):e.success&&(e.in?a.removeClass(s).addClass(i).text(n):a.removeClass(i).addClass(s).text(o))})})})},e.hasClass=function(e,t){return e.classList?e.classList.contains(t):new RegExp("(^| )"+t+"( |$)","gi").test(el.className)},e.addClass=function(t,s){return e.hasClass(t,s)||(t.classList?t.classList.add(s):t.className+=" "+s),t},e.removeClass=function(t,s){var i=" "+t.className.replace(/[\t\r\n]/g," ")+" ";if(e.hasClass(t,s))if(t.classList)t.classList.remove(s);else{for(;i.indexOf(" "+s+" ")>=0;)i=i.replace(" "+s+" "," ");t.className=i.replace(/^\s+|\s+$/g," ")}return t},e.closest=function(t,s){for(var i=function(s){return e.hasClass(t,s)};t;){if(i(s))return t;t=t.parentNode}},e.children=function(e,s){for(var i,o=[],i=0,n=e.childNodes.length;n>i;++i)t(e.childNodes[i],s)&&o.push(e.childNodes[i]);return o},e.postRequest=function(e,t,s){e||(e=""),$.ajax({type:"POST",url:t,data:e,success:function(e){return"function"!=typeof s?e:(console.log("data recieved:"),console.log(e),console.log(JSON.stringify(e)),s(e),void 0)}})},e.getRequest=function(e,t,s){e||(e=""),$.ajax({type:"GET",url:t,data:e,success:function(e){return"function"!=typeof s?e:(console.log("data recieved:"),console.log(e),console.log(JSON.stringify(e)),s(e),void 0)}})},e.Modal=function(e){var t=this;this.id,this.opt=e,this.DOMwrap=document.getElementById(e.id),this.DOM=this.DOMwrap.querySelector("."+e.wrapClass),$(".modal-close",this.DOM).on("click",function(){t.close()}),$(".modals > *").on("click",function(e){$(e.target.parentNode).find(t.DOMwrap).length&&t.close()})},e.Modal.prototype={pullData:function(e){this.id=e.substr(1),$(e).show().siblings().hide(),this.refresh()},open:function(){$(this.DOMwrap).fadeIn(),e.addClass(document.body,"ov-hidden")},close:function(){$(this.DOMwrap).fadeOut(),e.removeClass(document.body,"ov-hidden")},refresh:function(){var e=this;e.DOM.style.width=e.opt.size[e.id].width+"px",e.DOM.style.minHeight=e.opt.size[e.id].height+"px",e.DOM.style.marginLeft=-(e.opt.size[e.id].width/2)+"px",e.DOM.style.marginTop=-(e.opt.size[e.id].height/2)+"px"}},e}();

@ -1 +0,0 @@
var EXPO=EXPO||{};EXPO.exposition=EXPO.exposition||{},EXPO.exposition.list?console.warn("WARNING: EXPO.place.object is already defined!"):EXPO.exposition.list=function(){var t=EXPO.common,n={},o=function(t,n){this.opt=n,this.DOMthis=t,this.DOMbutton=t.querySelector("."+n.buttonClass),this.DOMinput=t.querySelector("."+n.inputClass),this.inputName=this.DOMinput.getAttribute("name"),this.url=this.DOMbutton.getAttribute("href"),this._controller()};return o.prototype={_init:function(){},_controller:function(){var t=this;$(this.DOMinput).on("blur",function(){t.send()}),$(this.DOMbutton).on("click",function(){return!1})},send:function(){var n,o={},i=this,e=function(t){t.success?(console.log("ok"),$(i.DOMbutton).addClass("active")):console.log("data not send")};o[this.inputName]=this.DOMinput.value,n=t.getRequest(o,this.url,e)}},n.opt={},$(function(){}),n.init=function(n){$.extend(this.opt,n),this.notes=[];var i=this;$("."+this.opt.note.wrapClass).each(function(){var t=new o(this,i.opt.note);i.notes.push(t)}),$("."+this.opt.note.wrapDisabledClass).on("click",function(){return $.fancybox.open("#pw-login"),!1}),t.opt.addCalendarText=this.opt.addCalendarText,t.opt.removeCalendarText=this.opt.removeCalendarText},n}();

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1 +0,0 @@
var EXPO=EXPO||{};EXPO.exposition=EXPO.exposition||{},EXPO.exposition.object?console.warn("WARNING: EXPO.exposition.object is already defined!"):EXPO.exposition.object=function(){var t=EXPO.common,n={},o=function(t,n){this.opt=n,this.DOMthis=t,this.DOMbutton=t.querySelector("."+n.buttonClass),this.DOMinput=t.querySelector("."+n.inputClass),this.inputName=this.DOMinput.getAttribute("name"),this.url=this.DOMbutton.getAttribute("href"),this._controller()};return o.prototype={_init:function(){},_controller:function(){var t=this;$(this.DOMinput).on("blur",function(){t.send()}),$(this.DOMbutton).on("click",function(){return!1})},send:function(){var n,o={},e=this,i=function(t){t.success?(console.log("ok"),$(e.DOMbutton).addClass("active")):console.log("data not send")};o[this.inputName]=this.DOMinput.value,n=t.getRequest(o,this.url,i)}},n.opt={},$(function(){}),n.init=function(n){$.extend(this.opt,n);var e=this,i=$(document.getElementById(e.opt.visitButton.visitorsListId)),s=$(document.getElementById(e.opt.visitButton.wrapId));this.notes=[],i.children().length||s.show(),$("."+this.opt.note.wrapClass).each(function(){var t=new o(this,e.opt.note);e.notes.push(t)}),$("."+this.opt.note.wrapDisabledClass).on("click",function(){return $.fancybox.open("#pw-login"),!1}),t.opt.addCalendarText=this.opt.addCalendarText,t.opt.removeCalendarText=this.opt.removeCalendarText},n}();

@ -1 +0,0 @@
var EXPO=EXPO||{};EXPO.index?console.warn("WARNING: EXPO.eventsFeed is already defined!"):EXPO.index=function(){var t={};t.opt={};var n=EXPO.common,i=function(t,n){this.opt=n,this.DOMthis=t,this.DOMbutton=t.querySelector("."+n.buttonClass),this.DOMinput=t.querySelector("."+n.inputClass),this.inputName=this.DOMinput.getAttribute("name"),this.url=this.DOMbutton.getAttribute("href"),this._controller()};return i.prototype={_init:function(){},_controller:function(){var t=this;$(this.DOMinput).on("blur",function(){t.send()}),$(this.DOMbutton).on("click",function(){return!1})},send:function(){var t,i={},o=this,e=function(t){t.success?(console.log("ok"),$(o.DOMbutton).addClass("active")):console.log("data not send")};i[this.inputName]=this.DOMinput.value,t=n.getRequest(i,this.url,e)}},t.init=function(t){$.extend(this.opt,t);var n=this;this.notes=[],$("."+this.opt.note.wrapClass).each(function(){var t=new i(this,n.opt.note);n.notes.push(t)}),$("."+this.opt.note.wrapDisabledClass).on("click",function(){return $.fancybox.open("#pw-login"),!1})},t}();

@ -1 +0,0 @@
var EXPO=EXPO||{};EXPO.place=EXPO.place||{},EXPO.place.object?console.warn("WARNING: EXPO.place.object is already defined!"):EXPO.place.object=function(){var t={},i=function(t,i){this.$annotation=$("."+t.annotationClass,i),this.$fullPart=$("."+t.fullPartClass,i),this.$readMore=$("."+t.readMoreClass,i),this.cutLength=t.cutLength,this.fullText,this.init()};return i.prototype={init:function(){var t=this,i=this.$annotation.html().slice(0,t.cutLength);this.fullText=this.$annotation.html(),this.$annotation.html(i+"..."),this.$fullPart.html(this.fullText)},showMore:function(){this.$readMore.hide(),this.$annotation.hide(),this.$fullPart.removeClass("hidden")},_cutAnnotation:function(){}},t.opt={},$(function(){}),t.init=function(t){$.extend(this.opt,t);var n=this;this.articles=[],$("."+n.opt.article.class).each(function(){var t=new i(n.opt.article,this);t.$readMore.on("click",function(){t.showMore()}),n.articles.push(t)})},t}();

@ -1 +0,0 @@
var EXPO=EXPO||{};EXPO.placePhoto?console.warn("WARNING: EXPO.placePhoto is already defined!"):EXPO.placePhoto=function(){var t={};t.settings={},t.lang={};var n=function(t,n,e,i,o,r,c,a){var d=this;this.currentId=void 0,this.ajaxUrl=i,this.opt={gContainerId:n,mId:t,mTrigger:e,nBtn:o,pBtn:r,cBtn:c,mcId:a},this.$mWindow=void 0,$(function(){d.$mWindow=$("#"+d.opt.mId),d.$mtrigger=$("."+d.opt.mTrigger),d.$nBtn=$("#"+d.opt.nBtn),d.$pBtn=$("#"+d.opt.pBtn),d.$cBtn=$("#"+d.opt.cBtn),d.$mtrigger.on("click",function(){var t;try{t=$(this).children("img").data("image-id"),d.currentId=t}catch(n){console.log(n.message)}return d.show(),!1}),d.$nBtn.off("click"),d.$nBtn.on("click",function(){return d.nextSlide(),!1}),d.$pBtn.off("click"),d.$pBtn.on("click",function(){return d.prevSlide(),!1}),d.$cBtn.off("click"),d.$cBtn.on("click",function(){return d.close(),!1}),d.$mWindow.off("click"),d.$mWindow.on("click",function(t){var n=$(t.target);return n.parents().filter("#"+d.opt.mcId).length<1&&d.close(),!1})})};return n.prototype={_getAjax:function(t,n){var e=this;t||(t=""),$.ajax({type:"GET",url:e.ajaxUrl,data:t,success:function(t){"function"==typeof n?(e.rawData=t,n()):e.rawData=t}})},_renderSlide:function(t,n){var e=this;t&&(e.currentId=t),n?(dna.empty(e.opt.mcId),dna.load(e.opt.mcId,e.ajaxUrl+e.currentId,{callback:n()})):(dna.empty(e.opt.mcId),dna.load(e.opt.mcId,e.ajaxUrl+e.currentId,{empty:!0}))},_getId:function(t){var n=this,e=function(){var t=$("."+n.opt.mTrigger+' [data-image-id="'+n.currentId+'"]').parents("li").next().find("img").data("image-id");t?n.currentId=t:console.log("there is not next slides")},i=function(){var t=$("."+n.opt.mTrigger+' [data-image-id="'+n.currentId+'"]').parents("li").prev().find("img").data("image-id");t?n.currentId=t:console.log("there is not previous slides")},o=function(){console.log("_getId("+t+") RESULTS:"),console.log(n.currentId)};switch(t){case">":e();break;case"<":i();break;default:o()}},close:function(){$("body").removeClass("no-scroll"),this.$mWindow.hide()},open:function(){$("body").addClass("no-scroll"),this.$mWindow.show()},nextSlide:function(){var t=this.currentId;this._getId(">"),t!=this.currentId&&this._renderSlide()},prevSlide:function(){var t=this.currentId;this._getId("<"),t!=this.currentId&&this._renderSlide()},show:function(t){var n=this;this._renderSlide(t,function(){n.open()})}},t.init=function(t){$.extend(this.lang,t.lang),t.lang=null,$.extend(this.settings,t);var e=this;this.modal=new n(e.settings.modalId,e.settings.containerId,e.settings.modalTrigger,e.settings.ajaxUrl,e.settings.nextButtonId,e.settings.prevButtonId,e.settings.closeModalButtonId,e.settings.modalContainerId)},t}();

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save