From dfc7a4f0842d4b5b3b4bbc7677a1e9578753bc94 Mon Sep 17 00:00:00 2001 From: saparatayev Date: Thu, 21 Oct 2021 18:17:29 +0500 Subject: [PATCH] fix: market type field output, translate & other issues --- modules/system/lang/en/validation.php | 1 + modules/system/lang/ru/validation.php | 1 + modules/system/lang/tm/validation.php | 1 + .../birzha/components/offerform/default.htm | 12 +- .../birzha/components/singleoffer/default.htm | 137 ++++++++++-------- themes/birzha/assets/css/main.css | 44 +++++- themes/birzha/config/lang.yaml | 9 ++ 7 files changed, 133 insertions(+), 72 deletions(-) diff --git a/modules/system/lang/en/validation.php b/modules/system/lang/en/validation.php index 5d417a472..a7fe94963 100644 --- a/modules/system/lang/en/validation.php +++ b/modules/system/lang/en/validation.php @@ -169,6 +169,7 @@ return [ 'description_en' => 'Description EN', 'description_tm' => 'Description TM', 'bank_file' => 'File from bank', + 'market_type' => 'Market type', ], ]; diff --git a/modules/system/lang/ru/validation.php b/modules/system/lang/ru/validation.php index ef8f4e5e3..3c2ac180e 100644 --- a/modules/system/lang/ru/validation.php +++ b/modules/system/lang/ru/validation.php @@ -169,6 +169,7 @@ return [ 'description_en' => 'Описание EN', 'description_tm' => 'Описание TM', 'bank_file' => 'Файл из банка', + 'market_type' => 'Тип рынка', ], ]; diff --git a/modules/system/lang/tm/validation.php b/modules/system/lang/tm/validation.php index 5aec36be4..c3929f965 100644 --- a/modules/system/lang/tm/validation.php +++ b/modules/system/lang/tm/validation.php @@ -171,6 +171,7 @@ return [ 'description_en' => 'Beýany EN', 'description_tm' => 'Beýany TM', 'bank_file' => 'Bankdan faýl', + 'market_type' => 'Bazaryň gornüşi', ], ]; diff --git a/plugins/tps/birzha/components/offerform/default.htm b/plugins/tps/birzha/components/offerform/default.htm index 210ceac06..9a85096a0 100644 --- a/plugins/tps/birzha/components/offerform/default.htm +++ b/plugins/tps/birzha/components/offerform/default.htm @@ -25,7 +25,7 @@
-
-
- Market type *
diff --git a/plugins/tps/birzha/components/singleoffer/default.htm b/plugins/tps/birzha/components/singleoffer/default.htm index 59d5c17bc..55a8f4c22 100644 --- a/plugins/tps/birzha/components/singleoffer/default.htm +++ b/plugins/tps/birzha/components/singleoffer/default.htm @@ -23,74 +23,89 @@
-
-
- {{offer.name}} -
-
-
- {{'page.prod_no'|_}}: -
-
- № {{offer.id}} -
-
-
-
- {{'page.prod_amount_2'|_}} : -
-
- {{offer.quantity}} {{offer.measure.code}}. -
-
-
-
- {{'page.prod_price_2'|_}}: -
-
- {{offer.price}} {{offer.currency.code}} / 1 {{offer.measure.code}}. -
-
-
-
- {{'page.prod_startdate'|_}}: -
-
- {{offer.created_at|date('d/m/Y')}} -
-
+
+ {{offer.name}}
-
-
-
- {{'page.prod_mark'|_}}: +
+
+
+
+ {{'page.prod_no'|_}}: +
+
+ № {{offer.id}} +
-
- {{offer.mark}} +
+
+ {{'page.prod_amount_2'|_}} : +
+
+ {{offer.quantity}} {{offer.measure.code}}. +
+
+
+
+ {{'page.prod_price_2'|_}}: +
+
+ {{offer.price}} {{offer.currency.code}} / 1 {{offer.measure.code}}. +
+
+
+
+ {{'page.prod_startdate'|_}}: +
+
+ {{offer.created_at|date('d/m/Y')}} +
+
+
+
+ {{'page.prod_finishdate'|_}}: +
+
+ {{offer.ends_at|date('d/m/Y')}} +
-
-
- {{'page.prod_vendor'|_}}: +
+
+
+ {{'page.prod_mark'|_}}: +
+
+ {{offer.mark}} +
-
- {{offer.manufacturer}} +
+
+ {{'page.prod_vendor'|_}}: +
+
+ {{offer.manufacturer}} +
-
-
-
- {{'page.prod_vendor_country'|_}} : +
+
+ {{'page.prod_vendor_country'|_}} : +
+
+ {{offer.country.name}} +
-
- {{offer.country.name}} -
-
-
-
- {{'page.prod_finishdate'|_}}: -
-
- {{offer.ends_at|date('d/m/Y')}} +
+
+ {{'page.market_type'|_}} +
+
+ {% if offer.market_type == 'in' %} + {{'page.market_type_option_in'|_}} + {% endif %} + {% if offer.market_type == 'out' %} + {{'page.market_type_option_out'|_}} + {% endif %} +
diff --git a/themes/birzha/assets/css/main.css b/themes/birzha/assets/css/main.css index 41e6813a7..012eeafac 100644 --- a/themes/birzha/assets/css/main.css +++ b/themes/birzha/assets/css/main.css @@ -1770,10 +1770,16 @@ li { } .detail_info { + /* display: flex; */ + /* align-items: flex-end; */ + /* justify-content: space-between; */ + width: calc(100% - 50px); + margin-left: 50px; +} + +.detail_info-inner { display: flex; - align-items: flex-end; justify-content: space-between; - width: 100%; } .detail_gallery { @@ -1821,15 +1827,16 @@ li { -o-object-fit: cover; } -.detail_about { +/* .detail_about { margin-left: 50px; -} +} */ .detail_title { font-size: var(--text-32); font-weight: 700; line-height: 1.4; margin-bottom: 30px; + width: 100%; } .detail_row { @@ -1852,7 +1859,7 @@ li { font-size: var(--text-20); font-weight: 400; line-height: 1.4; - + color: var(--blue); } .green { @@ -3605,6 +3612,18 @@ li { width: 575px; } + .detail_info { + margin-left: 0; + } + + .detail_info-inner { + justify-content: unset; + } + + .detail_other { + margin-left: 50px; + } + } @media(max-width: 1400px) { @@ -4666,6 +4685,17 @@ li { margin: 0 0 12px 10px; } + .detail_info-inner { + flex-direction: column; + -ms-flex-direction: column; + -moz-flex-direction: column; + -o-flex-direction: column; + -webkit-flex-direction: column; + } + + .detail_info { + margin-left: 0; + } } @media(max-width: 600px) { @@ -4873,6 +4903,10 @@ li { .seller_row { margin-bottom: 10px; } + + .detail_other { + margin-left: 30px; + } } @media(max-width: 500px) { diff --git a/themes/birzha/config/lang.yaml b/themes/birzha/config/lang.yaml index ce29e89f8..a7ec8fc82 100644 --- a/themes/birzha/config/lang.yaml +++ b/themes/birzha/config/lang.yaml @@ -78,6 +78,9 @@ en: page.prod_mark: Product mark page.prod_vendor: Manufacturer page.prod_vendor_country: Manufactured country + page.market_type: Market type + page.market_type_option_in: Внутренний + page.market_type_option_out: Внешний page.contact_us: Обратная связь page.your_firstname: Ваше имя page.your_lastname: Ваша фамилия @@ -196,6 +199,9 @@ ru: page.prod_mark: Марка товара page.prod_vendor: Производитель page.prod_vendor_country: Страна производителя + page.market_type: Market type + page.market_type_option_in: Внутренний + page.market_type_option_out: Внешний page.contact_us: Обратная связь page.your_firstname: Ваше имя page.your_lastname: Ваша фамилия @@ -336,6 +342,9 @@ tm: page.prod_mark: Марка товара page.prod_vendor: Производитель page.prod_vendor_country: Страна производителя + page.market_type: Market type + page.market_type_option_in: Внутренний + page.market_type_option_out: Внешний page.prod_desc: Описание page.prod_amount_2: Количество товара page.prod_price_2: Стартовая цена за единицу