Compare commits
2
Commits
39e8d5a8e1
...
2cddd87893
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2cddd87893 | ||
|
|
709a6e5ecb |
No files matched your search
@@ -1 +1 @@
|
||||
<?php get_template_part('templates/template-audience'); ?>
|
||||
<?php get_template_part('templates/template-courier'); ?>
|
||||
@@ -1 +1 @@
|
||||
<?php get_template_part('templates/template-audience'); ?>
|
||||
<?php get_template_part('templates/template-driver'); ?>
|
||||
@@ -1,16 +1,11 @@
|
||||
<?php
|
||||
if (is_singular('driver')) {
|
||||
$page_id = 76;
|
||||
} elseif (is_singular('courier')) {
|
||||
$page_id = 78;
|
||||
} else {
|
||||
$page_id = get_the_ID();
|
||||
}
|
||||
$page_id = get_queried_object_id();
|
||||
|
||||
$audience = get_field('hero_audience');
|
||||
$order_type = get_field('hero_type');
|
||||
$audience = get_field('hero_audience', $page_id);
|
||||
$order_type = get_field('hero_type', $page_id);
|
||||
$hero_title = get_field('hero_title', $page_id);
|
||||
$hero_descr = get_field('hero_descr', $page_id);
|
||||
|
||||
$hero_img = get_field('hero_img', $page_id);
|
||||
$hero_features = get_field('hero_features', 'option');
|
||||
$hero_scroller = get_field('hero_scroller', 'option');
|
||||
$hero_stores = get_field('download', 'option');
|
||||
@@ -24,12 +19,12 @@
|
||||
<h1 class="hero-title"><?php
|
||||
echo $audience
|
||||
? 'Приложение для ' . esc_html($audience)
|
||||
: wp_kses_post(get_field('hero_title'));
|
||||
: wp_kses_post($hero_title);
|
||||
?></h1>
|
||||
<div class="hero-descr"><?php
|
||||
echo $order_type
|
||||
? 'Скачай Hantico и начни получать заказы ' . esc_html($order_type) . ' уже завтра!'
|
||||
: wp_kses_post(get_field('hero_descr'));
|
||||
: wp_kses_post($hero_descr);
|
||||
?></div>
|
||||
<div class="hero-buttons">
|
||||
<a href="<?php echo get_permalink(87); ?>" class="hero-buttons__download-btn btn btn--lg btn--red">Скачать приложение</a>
|
||||
|
||||
@@ -14,6 +14,14 @@
|
||||
|
||||
$this_page_id = get_the_ID();
|
||||
|
||||
$calculator_type = get_field('calculator_type', $this_page_id);
|
||||
if (is_array($calculator_type)) {
|
||||
$calculator_type = $calculator_type['value'] ?? '';
|
||||
}
|
||||
if (!in_array($calculator_type, array('taxi', 'courier', 'cargo'), true)) {
|
||||
$calculator_type = '';
|
||||
}
|
||||
$selected_type = $calculator_type ?: ($is_courier ? 'courier' : ($is_cargo ? 'cargo' : 'taxi'));
|
||||
$calculator_title = get_field('calculator_title', $this_page_id);
|
||||
$income_title = $calculator_title
|
||||
? 'Калькулятор дохода ' . esc_html($calculator_title)
|
||||
@@ -27,20 +35,20 @@
|
||||
<?php if (!$calculator_title && $income_descr) : ?>
|
||||
<div class="income-descr section-descr"><?php echo $income_descr; ?></div>
|
||||
<?php endif; ?>
|
||||
<form class="income-calc<?php if ($is_driver || $is_courier || $is_cargo) echo ' income-calc--single'; ?>">
|
||||
<form class="income-calc<?php if ($calculator_type || $is_driver || $is_courier || $is_cargo) echo ' income-calc--single'; ?>">
|
||||
<div class="income-calc__top">
|
||||
<fieldset class="income-calc__types">
|
||||
<legend class="visually-hidden">Тип занятости</legend>
|
||||
<label class="income-calc__type income-calc__type--taxi">
|
||||
<input class="income-calc__type-input js-calc-type" type="radio" name="work_type" value="taxi"<?php if (!$is_courier && !$is_cargo) echo ' checked'; ?>>
|
||||
<input class="income-calc__type-input js-calc-type" type="radio" name="work_type" value="taxi"<?php if ($selected_type === 'taxi') echo ' checked'; ?>>
|
||||
<span class="income-calc__type-label">Такси</span>
|
||||
</label>
|
||||
<label class="income-calc__type income-calc__type--courier">
|
||||
<input class="income-calc__type-input js-calc-type" type="radio" name="work_type" value="courier"<?php if ($is_courier) echo ' checked'; ?>>
|
||||
<input class="income-calc__type-input js-calc-type" type="radio" name="work_type" value="courier"<?php if ($selected_type === 'courier') echo ' checked'; ?>>
|
||||
<span class="income-calc__type-label">Курьер</span>
|
||||
</label>
|
||||
<label class="income-calc__type income-calc__type--cargo">
|
||||
<input class="income-calc__type-input js-calc-type" type="radio" name="work_type" value="cargo"<?php if ($is_cargo) echo ' checked'; ?>>
|
||||
<input class="income-calc__type-input js-calc-type" type="radio" name="work_type" value="cargo"<?php if ($selected_type === 'cargo') echo ' checked'; ?>>
|
||||
<span class="income-calc__type-label">Грузоперевозки</span>
|
||||
</label>
|
||||
</fieldset>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/*
|
||||
Template Name: Аудитория
|
||||
Template Name: {Аудитория}
|
||||
*/
|
||||
?>
|
||||
|
||||
|
||||
@@ -9,20 +9,17 @@ Template Name: Курьерам
|
||||
|
||||
<main class="main">
|
||||
|
||||
<?php get_template_part('template-parts/audience/hero'); ?>
|
||||
<?php get_template_part('template-parts/courier-services'); ?>
|
||||
<?php get_template_part('template-parts/hero'); ?>
|
||||
<?php get_template_part('template-parts/services'); ?>
|
||||
<?php get_template_part('template-parts/income'); ?>
|
||||
<?php get_template_part('template-parts/advantages'); ?>
|
||||
<?php get_template_part('template-parts/delivery-orders'); ?>
|
||||
<?php get_template_part('template-parts/payments'); ?>
|
||||
<?php get_template_part('template-parts/scheme'); ?>
|
||||
<?php get_template_part('template-parts/payments'); ?>
|
||||
<?php get_template_part('template-parts/requirements'); ?>
|
||||
<?php get_template_part('template-parts/formats'); ?>
|
||||
<?php get_template_part('template-parts/cities'); ?>
|
||||
<?php get_template_part('template-parts/reviews'); ?>
|
||||
<?php get_template_part('template-parts/faq'); ?>
|
||||
<?php get_template_part('template-parts/jobs'); ?>
|
||||
<?php get_template_part('template-parts/getapp'); ?>
|
||||
<?php get_template_part('template-parts/related'); ?>
|
||||
<?php get_template_part('template-parts/specs'); ?>
|
||||
|
||||
</main>
|
||||
|
||||
@@ -9,7 +9,7 @@ Template Name: Аудитория
|
||||
|
||||
<main class="main">
|
||||
|
||||
<?php get_template_part('template-parts/hero'); ?>
|
||||
<?php get_template_part('template-parts/audience/hero'); ?>
|
||||
<?php get_template_part('template-parts/work'); ?>
|
||||
<?php get_template_part('template-parts/advantages'); ?>
|
||||
<?php get_template_part('template-parts/scheme'); ?>
|
||||
|
||||
Reference in new issue
Block a user