Skip to content

Commit caff69c

Browse files
committed
Merge branch 'CMS-530' into 'master'
Добавил приоритет для кастомных полей чекаута Closes CMS-530 See merge request ecommerce_modules/wordpress/wordpress_cdek_delivery!48
2 parents 22647fb + a78a87f commit caff69c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/Helpers/CheckoutHelper.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ public static function restoreCheckoutFields(array $fields): array
8383
'required' => true,
8484
'class' => ['form-row-wide'],
8585
'clear' => true,
86+
'priority' => 120,
8687
'custom_attributes' => [
8788
'maxlength' => 4,
8889
],
@@ -92,6 +93,7 @@ public static function restoreCheckoutFields(array $fields): array
9293
'required' => true,
9394
'class' => ['form-row-wide'],
9495
'clear' => true,
96+
'priority' => 120,
9597
'custom_attributes' => [
9698
'maxlength' => 6,
9799
],
@@ -100,18 +102,21 @@ public static function restoreCheckoutFields(array $fields): array
100102
'type' => 'date',
101103
'label' => __('Дата выдачи паспорта', 'woocommerce'),
102104
'required' => true,
105+
'priority' => 120,
103106
'class' => ['form-row-wide'],
104107
'clear' => true,
105108
];
106109
$fields['billing']['passport_organization'] = [
107110
'label' => __('Орган выдачи паспорта', 'woocommerce'),
108111
'required' => true,
112+
'priority' => 120,
109113
'class' => ['form-row-wide'],
110114
'clear' => true,
111115
];
112116
$fields['billing']['tin'] = [
113117
'label' => __('ИНН', 'woocommerce'),
114118
'required' => true,
119+
'priority' => 120,
115120
'class' => ['form-row-wide'],
116121
'clear' => true,
117122
'custom_attributes' => [
@@ -120,6 +125,7 @@ public static function restoreCheckoutFields(array $fields): array
120125
];
121126
$fields['billing']['passport_date_of_birth'] = [
122127
'type' => 'date',
128+
'priority' => 120,
123129
'label' => __('Дата рождения', 'woocommerce'),
124130
'required' => true,
125131
'class' => ['form-row-wide'],

0 commit comments

Comments
 (0)