diff --git a/static/css/styles(boris).css b/static/css/styles(boris).css index 2defdbb..3f6fb45 100644 --- a/static/css/styles(boris).css +++ b/static/css/styles(boris).css @@ -16,6 +16,9 @@ } +.orange-text{ + color: #FF613A; +} .title_page{ font-size: 44px; @@ -1325,6 +1328,11 @@ content: url(/static/img/svg/galka.svg); } +.items_subscribe.select.green:before{ + content: url(/static/img/svg/galka.svg); + filter: brightness(0) saturate(100%) invert(76%) sepia(11%) saturate(7432%) hue-rotate(88deg) brightness(94%) contrast(106%); +} + .items_subscribe:before{ color: #FF613A; display: inline-block; @@ -1332,6 +1340,168 @@ vertical-align: top; } +.subscribe_inf{ + margin-bottom: 40px; +} + +.inf_about_tarif_plan_text{ + font-size: 16px; + font-weight: 400; + color: #272424; + margin-bottom: 40px; +} + +.subscribe_inf_left_part{ + width: 54%; + background: #FFFFFF; + filter: drop-shadow(-1px 4px 10px rgba(198, 199, 203, 0.20)) drop-shadow(0px -1px 10px rgba(198, 199, 203, 0.20)); + padding: 2.373%; + float: left; + border-radius: 10px; +} + +.subscribe_inf_right_part{ + width: 33%; + background: #FFFFFF; + filter: drop-shadow(-1px 4px 10px rgba(198, 199, 203, 0.20)) drop-shadow(0px -1px 10px rgba(198, 199, 203, 0.20)); + padding: 2.373%; + float: right; + border-radius: 10px; +} + +.title_options{ + font-size: 20px; + font-weight: 500; + color: #272424; + margin-bottom: 10px; + width: 100%; + text-align: center; +} + +.title_subscribe{ + font-weight: 500; + font-size: 20px; + color: #000000; + margin-bottom: 10px; +} + +.name_subscribe{ + font-size: 44px; + font-weight: 700; + color: #000000; + margin-bottom: 20px; +} + +.extend_subscribe_btn{ + color: #FFFFFF; + font-size: 16px; + font-weight: 500; + background: #FF613A; + padding: 8px 26px; + border-radius: 10px; + margin-bottom: 10px; +} + +.another_subscribe{ + width: 98%; + padding: 24px 20px; + background: #FFFFFF; + box-shadow: -1px 4px 10px 0 rgba(198, 199, 203, 0.20), 0 -1px 10px 0 rgba(198, 199, 203, 0.20); + display: flex; + margin-bottom: 20px; + border-radius: 10px; + align-items: center; +} + +.name_subscribe_another{ + font-weight: 500; + font-size: 16px; + color: #272424; +} + +.padding-n-width-another-subscribes{ + width: 27%; + padding-right: 2%; +} + +.text_another_subscribe{ + font-size: 16px; + color: #272424; + font-weight: 400; +} + +.read_more_about_subscribe{ + color: #FFFFFF; + font-size: 16px; + font-weight: 500; + background: #FF613A; + padding: 8px 26px; + border-radius: 10px; + display: block; +} + +.subscribe_was_paid{ + color: #27242499; + font-weight: 500; + font-size: 16px; + margin-bottom: 55px; +} + +.label_toggle_switch_cont{ + color: #272424; + font-size: 14px; + width: 94%; + float: left; +} + +.toggle_switch_cont{ + position: relative; + margin-bottom: 10px; + float: right; + width: 6%; +} + +.input_toggle_switch{ + width: 28px; + height: 16px; + border-radius: 10px; + opacity: 0; + position: absolute; + z-index: 3; +} + +.input_toggle_switch_display{ + width: 28px; + height: 16px; + background: #272424; + border-radius: 10px; + transition: 200ms; +} + +.toggler_input_switch{ + position: absolute; + left: 2px; + bottom: 1px; + background: #FFFFFF; + border-radius: 100%; + display: block; + height: 14px; + width: 14px; + transition: 200ms; +} + +.input_toggle_switch:checked + .input_toggle_switch_display{ + transition: 200ms; + background: #FF613A; +} + +.input_toggle_switch:checked ~ .toggler_input_switch{ + transform: translateX(10px); + -webkit-transform: translateX(10px); + -ms-transform: translateX(10px); + transition: 200ms; +} + /*.container_subscribe.light .items_subscribe.unselected:before{*/ /* content: url(/static/img/svg/cross.svg);*/ /*}*/ @@ -1348,6 +1518,11 @@ filter: brightness(0) saturate(100%) invert(81%) sepia(1%) saturate(460%) hue-rotate(31deg) brightness(84%) contrast(81%); } +.items_subscribe.unselect.red:before{ + content: url(/static/img/svg/cross.svg); + filter: brightness(0) saturate(100%) invert(11%) sepia(92%) saturate(7217%) hue-rotate(3deg) brightness(99%) contrast(112%); +} + .items_subscribe.unselect{ /*color: #d1d1d1;*/ /*color: #626262;*/ @@ -1502,4 +1677,5 @@ border-bottom: 1px solid #919BA5; margin-top: 30px; margin-bottom: 30px; -} \ No newline at end of file +} + diff --git a/static/js/user_profile(boris).js b/static/js/user_profile(boris).js index 6c80d73..2a85de2 100644 --- a/static/js/user_profile(boris).js +++ b/static/js/user_profile(boris).js @@ -303,3 +303,30 @@ function sendMessageEnter (e,id_ticket,sender,receiver){ // } } + +function send_subscribe (id){ + let data = { + 'subscribe_id':id + } + $.ajax({ + headers: { "X-CSRFToken": $('input[name=csrfmiddlewaretoken]').val() }, + url: '/ru/subscribes/subscribe_now/', + type: "POST", + // async: true, + cache: false, + processData: false, + contentType: false, + // enctype: 'json', + data: JSON.stringify(data), + success: function(data){ + + document.querySelector(".info_profile").innerHTML = data.html; + + }, + error: function (data){ + + document.querySelector(".info_profile").innerHTML = data.responseJSON.html; + + } + }); +} \ No newline at end of file diff --git a/templates/blocks/profile/b_subscribe_current.html b/templates/blocks/profile/b_subscribe_current.html index b0797a4..a099d3b 100644 --- a/templates/blocks/profile/b_subscribe_current.html +++ b/templates/blocks/profile/b_subscribe_current.html @@ -1 +1,72 @@ -{% load static %} \ No newline at end of file +{% load static %} + +
+ Подписка +
+{% for subscribe in subscribe_for_user %} +
+
+
+
Ваш тарифный план
+
{{ subscribe.subscribe.name }}
+ + +
+
+
+
+ +
+
+ +
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+
+
Опции тарифа
+ +
+
+
+
При понижении тарифного плана оплаченный период действия текущей подписки не пересчитывается.
+
+ {% for item in subscribes %} + {% if item.id != subscribe.subscribe.id %} + +
+
{{ item.name }}
+
+ Стоимость:{{ item.price }} +
+
+ Период:{{ item.period_name }} +
+ +
+ + {% endif %} + + {% endfor %} +
+{% endfor %} \ No newline at end of file diff --git a/templates/blocks/profile/b_subscribe_variants.html b/templates/blocks/profile/b_subscribe_variants.html index 9112bbb..c14ddc4 100644 --- a/templates/blocks/profile/b_subscribe_variants.html +++ b/templates/blocks/profile/b_subscribe_variants.html @@ -51,7 +51,7 @@
- +
{% endfor %}