diff --git a/frontend/views/orders/basket-step-01.php b/frontend/views/orders/basket-step-01.php
new file mode 100644
index 0000000..bf6d4a7
--- /dev/null
+++ b/frontend/views/orders/basket-step-01.php
@@ -0,0 +1,98 @@
+title = 'Оформление заказа';
+$this->params['breadcrumbs'][] = $this->title;
+
+?>
+
+
+
Оформление заказа
+
+
+ 'basket_order_01_form'
+ ]); ?>
+
+
+
+
+
Личные данные
+
+
+ = $form->field($model, 'name',[
+ 'template' => '',
+ ])->textInput() ?>
+
+
+
+ = $form->field($model, 'email',[
+ 'template' => '',
+ ])->textInput() ?>
+
+
+
+ = $form->field($model, 'phone',[
+ 'template' => '',
+ ])->textInput() ?>
+
+
+
+
+
+
+
+
Доставка
+
+
+
+
Курьерска доставка по Киеву и области
+
+
+
+
+
В любой регион Украины
+
+
+
+
+
Самовывоз (бесплатно)
+
уточните подробности по телефону 044 ХХХ-ХХ-ХХ
+
+
+
+
+
+
+
Оплата
+
+
+
+
+
+
+
+
+
+
Согласовать с менеджером
+
+
+
+
+
+ = Html::submitButton(Yii::t('app', 'продолжить оформление'), ['class' => 'order_01_btn', 'name' => 'signup-button']) ?>
+
+
+
\ No newline at end of file
diff --git a/frontend/views/orders/basket-step-02.php b/frontend/views/orders/basket-step-02.php
new file mode 100644
index 0000000..beaf0b4
--- /dev/null
+++ b/frontend/views/orders/basket-step-02.php
@@ -0,0 +1,83 @@
+title = 'Оформление заказа';
+$this->params['breadcrumbs'][] = $this->title;
+
+?>
+
+
diff --git a/frontend/views/orders/basket-step-03.php b/frontend/views/orders/basket-step-03.php
new file mode 100644
index 0000000..0c6deaf
--- /dev/null
+++ b/frontend/views/orders/basket-step-03.php
@@ -0,0 +1,10 @@
+title = 'Оформление заказа';
+$this->params['breadcrumbs'][] = $this->title;
+
+?>
+
Спасибо за ваш заказ!
diff --git a/frontend/views/putty/basket-step-01.php b/frontend/views/putty/basket-step-01.php
deleted file mode 100644
index 2f5ea67..0000000
--- a/frontend/views/putty/basket-step-01.php
+++ /dev/null
@@ -1,93 +0,0 @@
-title = 'Оформление заказа';
-$this->params['breadcrumbs'][] = $this->title;
-
-?>
-
-
-
Оформление заказа
-
-
\ No newline at end of file
diff --git a/frontend/views/putty/basket-step-02.php b/frontend/views/putty/basket-step-02.php
deleted file mode 100644
index 5745ee6..0000000
--- a/frontend/views/putty/basket-step-02.php
+++ /dev/null
@@ -1,80 +0,0 @@
-title = 'Оформление заказа';
-$this->params['breadcrumbs'][] = $this->title;
-
-?>
-
-
Оформление заказа
-
-
-
Номер заказа 671
-
- -
-
-
-

-
-
- Штукатурка гипсовая Кнауф Ротбанд 30 кг белая
- Код: 45885-01016049
-
-
1 шт.
-
102.05 грн.
-
-
- -
-
-
-

-
-
- Штукатурка гипсовая Кнауф Ротбанд 30 кг белая
- Код: 45885-01016049
-
-
1 шт.
-
102.05 грн.
-
-
- -
-
-
-

-
-
- Штукатурка гипсовая Кнауф Ротбанд 30 кг белая
- Код: 45885-01016049
-
-
1 шт.
-
102.05 грн.
-
-
-
-
-
-
Всего товаров: 3
-
Сумма: 306.15 грн.
-
-
-
-
-
-
Детали
-
- ИмяАртем
-
-
- E-mailartem@mail.com
-
-
- Телефон050 340-34-34
-
-
Способ оплаты
-
Оплата наличными
-
Доставка
-
Курьерска доставка по Киеву и области
-
-
-
-
-
\ No newline at end of file
diff --git a/frontend/web/css/concat_all.css b/frontend/web/css/concat_all.css
index eaedebd..291bb33 100644
--- a/frontend/web/css/concat_all.css
+++ b/frontend/web/css/concat_all.css
@@ -2729,9 +2729,11 @@ span.red {
margin-right: 130px;
}
-.busket_modal_header .busket_modal_02 .order_list .busket_bottom_btn button {
+.busket_modal_header .busket_modal_02 .order_list .busket_bottom_btn .button {
display: inline-block;
padding: 10px 20px;
+ text-decoration: none;
+ margin: 0;
color: white;
background-color: #6aa034;
border: none;
@@ -2743,14 +2745,14 @@ span.red {
box-shadow: 0px 2px 0px #517a27;
}
-.busket_modal_header .busket_modal_02 .order_list .busket_bottom_btn button:active {
+.busket_modal_header .busket_modal_02 .order_list .busket_bottom_btn .button:active {
position: relative;
-webkit-box-shadow: none;
box-shadow: none;
top: 2px;
}
-.busket_modal_header .busket_modal_02 .order_list .busket_bottom_btn button:hover {
+.busket_modal_header .busket_modal_02 .order_list .busket_bottom_btn .button:hover {
background-color: #5d8d2e;
}
@@ -2768,7 +2770,174 @@ span.red {
.busket_modal_header .busket_modal_02 .order_list .delete_item_btn:hover {
color: red;
}
+/********************BASKET *************************/
+
+
+.basket_form .order_list {
+ /*width: auto;*/
+ padding: 25px 0px;
+}
+
+.basket_form .order_list ul {
+ overflow-y: overlay;
+ overflow-x: hidden;
+}
+
+.basket_form .order_list h3 {
+ text-transform: uppercase;
+ font-weight: normal;
+ font-size: 20px;
+ padding: 20px 0 15px;
+}
+
+.basket_form .order_list .order_list_li {
+ display: block;
+ max-width:440px;
+ overflow: hidden;
+}
+
+
+.basket_form .order_list li:nth-child(even){
+ background-color:#f4f4f4;
+}
+.busket_modal_01 .order_list li:nth-child(even){
+ background-color:#f4f4f4;
+}
+
+.basket_form .order_list .order_list_li .little_img {
+ /*float: none;*/
+}
+
+.basket_form .order_list .order_list_li .name_and_code {
+ text-align: left;
+ /*float: none;*/
+}
+
+.basket_form .order_list .order_list_li .name_and_code .name {
+ margin-bottom: 14px;
+}
+.basket_form .order_list .order_list_li .price {
+ padding: 0;
+}
+
+.basket_form .order_list .order_list_li .count_block_wrap {
+ display: inline-block;
+ vertical-align: top;
+ text-align: right;
+ float: left;
+}
+
+.basket_form .order_list .count_block {
+ display: block;
+ position: relative;
+ margin-bottom: 30px;
+}
+
+.basket_form .order_list .count_block .count_number {
+ display: inline-block;
+ font-size: 22px;
+ padding: 6px 13px 3px;
+ -webkit-border-radius: 3px;
+ border-radius: 3px;
+ position: relative;
+ /*top: -2px;*/
+ background-color: #fff;
+}
+
+.basket_form .order_list .count_block .count_buttons {
+ position: relative;
+ /*top: 4px;*/
+ right: 16px;
+ display: inline-block;
+ vertical-align: bottom;
+}
+
+.basket_form .order_list .count_block .count_buttons .button_plus {
+ background-color: #898b8e;
+ color: white;
+ font-weight: bold;
+ border-bottom: 1px solid #707274;
+ -webkit-border-top-right-radius: 3px;
+ border-top-right-radius: 3px;
+ font-size: 15px;
+ line-height: 15px;
+ padding: 0 7px;
+ cursor: pointer;
+}
+
+.basket_form .order_list .count_block .count_buttons .button_plus:hover {
+ background-color: #7c7e81;
+}
+
+.basket_form .order_list .count_block .count_buttons .button_minus {
+ background-color: #898b8e;
+ color: white;
+ font-weight: bold;
+ line-height: 16px;
+ text-align: center;
+ border-top: 1px solid #A2A2A2;
+ -webkit-border-bottom-right-radius: 3px;
+ border-bottom-right-radius: 3px;
+ cursor: pointer;
+}
+
+.basket_form .order_list .count_block .count_buttons .button_minus:hover {
+ background-color: #7c7e81;
+}
+
+.basket_form .order_list .busket_bottom_btn {
+ margin-top: 20px;
+ text-align: center;
+}
+
+.basket_form .order_list .busket_bottom_btn a {
+ display: inline-block;
+ font-size: 13px;
+ margin-right: 130px;
+}
+
+.basket_form .order_list .busket_bottom_btn .button {
+ display: inline-block;
+ padding: 10px 20px;
+ text-decoration: none;
+ margin: 0;
+ color: white;
+ background-color: #6aa034;
+ border: none;
+ -webkit-border-radius: 2px;
+ border-radius: 2px;
+ font-size: 13px;
+ font-weight: normal;
+ -webkit-box-shadow: 0px 2px 0px #517a27;
+ box-shadow: 0px 2px 0px #517a27;
+}
+
+.basket_form .order_list .busket_bottom_btn .button:active {
+ position: relative;
+ -webkit-box-shadow: none;
+ box-shadow: none;
+ top: 2px;
+}
+
+.basket_form .order_list .busket_bottom_btn .button:hover {
+ background-color: #5d8d2e;
+}
+
+.basket_form .order_list .delete_item_btn {
+ display: inline-block;
+ vertical-align: top;
+ margin-top: 30px;
+ padding: 0 10px 0 0;
+ cursor: pointer;
+ color: #C6C7C9;
+ font-size: 20px;
+ float: left;
+}
+
+.basket_form .order_list .delete_item_btn:hover {
+ color: red;
+}
/*=============================================== CATEGORY PAGE ================================================*/
.category_page_main_title {
diff --git a/frontend/web/css/style.css b/frontend/web/css/style.css
index 8b433fd..3da1752 100644
--- a/frontend/web/css/style.css
+++ b/frontend/web/css/style.css
@@ -866,7 +866,7 @@ padding-left:27px;
left:20px;
}
.basket_head .bh_cell.text{
- top:8px;
+ top:20px;
left:66px;
}
.basket_head .basket_head_desc{
diff --git a/frontend/web/js/basket.js b/frontend/web/js/basket.js
new file mode 100644
index 0000000..80b0271
--- /dev/null
+++ b/frontend/web/js/basket.js
@@ -0,0 +1,115 @@
+$(document).ready(function(){
+
+ var result_block = $('.basket_result');
+
+
+ function changeAjaxPrice(id, num){
+ $.post( "/orders/buy-items", {id: id, num:num}, function( data ) {
+ });
+ }
+
+ function countPrise(block){
+ var totalBlock = block.parents('.order_list');
+ var total_price = 0;
+ totalBlock.find('.price_val').each(function(){
+ total_price += +$(this).html();
+ });
+ $('.all_price_span').html(total_price);
+ }
+
+
+ $('.item').on('click', '.basket_add_but', function(e){
+ var id = $(this).data('id');
+ $.post( "/orders/buy-items", {id: id, num:1}, function( data ) {
+ $('.basket_result').each(function(){
+ $(this).html(data)
+ });
+ });
+
+ });
+
+ result_block.on('click', '.delete_item_btn', function(){
+ var block = $(this).parents('.order_list_li');
+
+
+ var id = block.data('id');
+
+ $.post( "/orders/delete", {id: id}, function( data ) {
+ });
+
+ $('.order_list_li[data-id='+id+']').each(function(){
+ var block = $(this);
+ block.remove();
+ });
+
+ countPrise(block);
+
+ });
+
+ result_block.on('click', '.button_minus', function(){
+ var block = $(this).parents('.order_list_li');
+ var price_block = block.find('.price_val');
+ var input = block.find('input');
+ var number = input.val();
+ var id = block.data('id');
+
+ if(number > 1){
+ number--;
+ input.val(number);
+ var price = price_block.data('price');
+ var new_price = number * +price;
+ price_block.html(new_price);
+ changeAjaxPrice(id, number);
+ synchronizationPriceData(id, number);
+ }
+
+ countPrise(block);
+ });
+
+
+ result_block.on('click', '.button_plus', function(){
+ var block = $(this).parents('.order_list_li');
+ var price_block = block.find('.price_val');
+ var input = block.find('input');
+ var number = input.val();
+ var id = block.data('id');
+
+ number++;
+ input.val(number);
+ var price = price_block.data('price');
+ var new_price = number * +price;
+ price_block.html(new_price);
+
+ changeAjaxPrice(id, number);
+ synchronizationPriceData(id, number);
+ countPrise(block);
+ });
+
+ result_block.on('change', '.buy_one_item', function(){
+ var block = $(this).parents('.order_list_li');
+ var num = $(this).val();
+ var price_block = block.find('.price_val');
+ var price = price_block.data('price');
+ var id = block.data('id');
+
+ var new_price = num * +price;
+ price_block.html(new_price);
+ changeAjaxPrice(id, num);
+ synchronizationPriceData(id, num);
+ countPrise(block);
+ });
+
+ function synchronizationPriceData(id, number){
+ $('.order_list_li[data-id='+id+']').each(function(){
+ var block = $(this);
+ block.find('input').val(number);
+ var price_block = block.find('.price_val');
+ var price = price_block.data('price');
+ var new_price = number * +price;
+ price_block.html(new_price);
+ });
+ }
+
+
+
+});
\ No newline at end of file
diff --git a/frontend/web/js/my_scripts.js b/frontend/web/js/my_scripts.js
index a9b4694..b498f8a 100644
--- a/frontend/web/js/my_scripts.js
+++ b/frontend/web/js/my_scripts.js
@@ -152,8 +152,8 @@ $(document).ready(function(){
modal_busket_open = $('.basket_add_but'), // открыть модалку корзины
modal_busket_header_open = $('i.head-down.bh_cell'), // открыть корзину в хедере
modal_busket_header = $('.busket_modal_header'), // модальная корзина хедер
- modal_busket_header_cont = $('.busket_modal_header .busket_bottom_btn a'),
- modal_busket_cont = $('.busket_bottom_btn a'), // ссылка модалки корзины - продолжить покупки
+ modal_busket_header_cont = $('.busket_modal_header .busket_bottom_btn .close'),
+ modal_busket_cont = $('.busket_bottom_btn .close'), // ссылка модалки корзины - продолжить покупки
forgot_pass_open_btn = $('.forgot_pass_link'), // ссылка на окно - забыли пароль
close_btn = $('.modal_close_btn'), // кнопка закрыть регистрацию
doc_h = $(document).height(),
@@ -471,77 +471,5 @@ $(document).ready(function(){
//=============================================== BUSKET MODAL WINDOW FUNCTIONS
- function all_modal_moves(){
- // BUSKET MODAL WINDOW ITEM DELETE
- var delete_item_btn = $('.delete_item_btn').click(function(){
- $(this).closest('li').remove();
- });
- }
- all_modal_moves();
-
-
- function countPrise(block){
- var total_price = 0;
- block.find('.price').each(function(){
- total_price += +$(this).html();
- });
- $('.total_price').html(total_price);
- $("input[name='OrderForm[total_price]']").val(total_price);
- }
-
-
- $('.item').on('click', '.basket_add_but', function(e){
- var id = $(this).parents('.item').data('id');
- console.log(id);
- $.post( "/orders/buy-items", {id: id}, function( data ) {
- $('.basket_result').each(function(){
- $(this).html(data)
- });
- });
-
- });
-
- $('.basket_result').on('click', '.delete_item_btn', function(){
- var id = $(this).parents('.order_list_li').data('id');
- $(this).parents('.order_list_li').remove();
- $.post( "/orders/delete", {id: id}, function( data ) {
- });
- countPrise();
- });
-
- $('.basket_result').on('click', '.button_minus', function(){
- var input = $(this).parents('.order_list_li ').find('input');
- var number = input.val();
- if(number > 1){
- number--;
- input.val(number);
- var price = $(this).parents('.goods_data').find('.item_prise_block').find('span').html();
- var new_price = number * price;
- $(this).parents('.goods_data').find('.item_prise_total_block').find('span').html(new_price);
- }
- countPrise();
- });
-
-
- $('.basket_result').on('click', '.button_plus', function(){
- var input = $(this).parents('.order_list_li ').find('input');
- var number = input.val();
- number++;
- input.val(number);
- var price = $(this).parents('.goods_data').find('.item_prise_block').find('span').html();
- var new_price = number * price;
- $(this).parents('.goods_data').find('.item_prise_total_block').find('span').html(new_price);
- countPrise();
- });
-
- $('.basket_result').on('change', '.buy_one_item', function(){
- var num = $(this).val();
- var priceBlock = $(this).parents('.order_list_li').find('.price');
- var price = priceBlock.html();
- var new_price = num * price;
- priceBlock.html(new_price);
- countPrise();
- });
-
});
\ No newline at end of file
--
libgit2 0.21.4