* Автоматическое соотношение контрагентов по умолчанию, фильтр активности значений * Добавлен фильтр активных складов и типов цен
This commit is contained in:
parent
c7aad78e5f
commit
b4f4aaa023
@ -1,3 +1,7 @@
|
||||
## 2023-03-27 v.6.2.2
|
||||
- Добавление значения по умолчанию у элемента выбора контрагента
|
||||
- Добавлена фильтрация полей по активности
|
||||
|
||||
## 2023-03-17 v.6.2.1
|
||||
- Добавлена передача менеджера при изменении заказа по истории
|
||||
|
||||
|
@ -1 +1,2 @@
|
||||
- Добавлена передача менеджера при изменении заказа по истории
|
||||
- Добавление значения по умолчанию у элемента выбора контрагента
|
||||
- Добавлена фильтрация полей по активности
|
||||
|
@ -222,10 +222,12 @@ if (isset($arResult['PAYMENT'])) {
|
||||
<select name="delivery-type-<?php echo $bitrixDeliveryType['ID']; ?>" class="typeselect">
|
||||
<option value=""></option>
|
||||
<?php foreach($arResult['deliveryTypesList'] as $deliveryType): ?>
|
||||
<?php if ($deliveryType['active'] === true): ?>
|
||||
<option value="<?php echo $deliveryType['code']; ?>"
|
||||
<?php if($defaultDelivTypes[$bitrixDeliveryType['ID']] == $deliveryType['code']) echo 'selected'; ?>>
|
||||
<?php echo $APPLICATION->ConvertCharset($deliveryType['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
</option>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</td>
|
||||
@ -244,7 +246,7 @@ if (isset($arResult['PAYMENT'])) {
|
||||
<select name="payment-type-<?php echo $bitrixPaymentType['ID']; ?>" class="typeselect">
|
||||
<option value=""></option>
|
||||
<?php foreach($arResult['paymentTypesList'] as $paymentType): ?>
|
||||
<?php if($paymentType['active'] == 1): ?>
|
||||
<?php if($paymentType['active'] === true): ?>
|
||||
<option value="<?php echo $paymentType['code']; ?>"
|
||||
<?php if($defaultPayTypes[$bitrixPaymentType['ID']] == $paymentType['code']) echo 'selected'; ?>>
|
||||
<?php
|
||||
@ -293,11 +295,11 @@ if (isset($arResult['PAYMENT'])) {
|
||||
<select name="payment-status-<?php echo $bitrixStatus['ID']; ?>" class="typeselect">
|
||||
<option value="" selected=""></option>
|
||||
<?php foreach($arResult['paymentGroupList'] as $orderStatusGroup): if(!empty($orderStatusGroup['statuses'])) : ?>
|
||||
<?php if($orderStatusGroup['active'] == 1) : ?>
|
||||
<?php if($orderStatusGroup['active'] === true) : ?>
|
||||
<optgroup label="<?php echo $APPLICATION->ConvertCharset($orderStatusGroup['name'], 'utf-8', SITE_CHARSET); ?>">
|
||||
<?php foreach($orderStatusGroup['statuses'] as $payment): ?>
|
||||
<?php if(isset($arResult['paymentList'][$payment])): ?>
|
||||
<?php if($arResult['paymentList'][$payment]['active'] == 1): ?>
|
||||
<?php if($arResult['paymentList'][$payment]['active'] === true): ?>
|
||||
<option value="<?php echo $arResult['paymentList'][$payment]['code']; ?>"
|
||||
<?php if ($defaultPayStatuses[$bitrixStatus['ID']] == $arResult['paymentList'][$payment]['code']) echo 'selected'; ?>>
|
||||
<?php echo $APPLICATION->ConvertCharset($arResult['paymentList'][$payment]['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
@ -330,7 +332,7 @@ if (isset($arResult['PAYMENT'])) {
|
||||
<select name="payment-<?php echo $bitrixPayment['ID']; ?>" class="typeselect">
|
||||
<option value=""></option>
|
||||
<?php foreach($arResult['paymentStatusesList'] as $paymentStatus): ?>
|
||||
<?php if($paymentStatus['active'] == 1): ?>
|
||||
<?php if($paymentStatus['active'] === true): ?>
|
||||
<option value="<?php echo $paymentStatus['code']; ?>"
|
||||
<?php if($defaultPayment[$bitrixPayment['ID']] == $paymentStatus['code']) echo 'selected'; ?>>
|
||||
<?php echo $APPLICATION->ConvertCharset($paymentStatus['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
@ -353,7 +355,7 @@ if (isset($arResult['PAYMENT'])) {
|
||||
<select name="order-type-<?php echo $bitrixOrderType['ID']; ?>" class="typeselect">
|
||||
<option value=""></option>
|
||||
<?php foreach($arResult['orderTypesList'] as $orderType): ?>
|
||||
<?php if($orderType['active'] == 1): ?>
|
||||
<?php if($orderType['active'] === true): ?>
|
||||
<option value="<?php echo $orderType['code']; ?>"
|
||||
<?php if($defaultOrderTypes[$bitrixOrderType['ID']] == $orderType['code']) echo 'selected'; ?>>
|
||||
<?php echo $APPLICATION->ConvertCharset($orderType['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
|
@ -38,6 +38,18 @@ if (!isset($arResult['LEGAL_DETAILS'])) {
|
||||
|
||||
if (!isset($arResult['CONTRAGENT_TYPES'])) {
|
||||
$arResult['CONTRAGENT_TYPES'] = unserialize(COption::GetOptionString($MODULE_ID, $CRM_CONTRAGENT_TYPE, 0));
|
||||
|
||||
if ($arResult['CONTRAGENT_TYPES'] === false) {
|
||||
foreach ($arResult['contragentType'] as $crmContrAgentType) {
|
||||
if ($crmContrAgentType['ID'] === 'individual') {
|
||||
$arResult['CONTRAGENT_TYPES']['1'] = 'individual';
|
||||
}
|
||||
|
||||
if ($crmContrAgentType['ID'] === 'legal-entity') {
|
||||
$arResult['CONTRAGENT_TYPES']['2'] = 'legal-entity';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($arResult['ORDER_PROPS'])) {
|
||||
@ -167,13 +179,12 @@ if (isset($arResult['ORDER_PROPS'])) {
|
||||
<b>
|
||||
<label>
|
||||
<input class="addr" type="radio" name="address-detail-<?= $bitrixOrderType['ID']?>" value="0"
|
||||
<?= (count($defaultOrderProps[$bitrixOrderType['ID']]) < 6) ? 'checked' : '' ?>>
|
||||
<?= (is_array($defaultOrderProps[$bitrixOrderType['ID']]) && count($defaultOrderProps[$bitrixOrderType['ID']]) < 6) ? 'checked' : '' ?>>
|
||||
<?= GetMessage('ADDRESS_SHORT')?>
|
||||
</label>
|
||||
<label>
|
||||
<input class="addr" type="radio" name="address-detail-<?= $bitrixOrderType['ID']?>" value="1"
|
||||
<?= (count($defaultOrderProps[$bitrixOrderType['ID']]) > 5) ? 'checked' : '' ?>
|
||||
>
|
||||
<?= (is_array($defaultOrderProps[$bitrixOrderType['ID']]) && count($defaultOrderProps[$bitrixOrderType['ID']]) > 5) ? 'checked' : '' ?>>
|
||||
<?= GetMessage('ADDRESS_FULL')?>
|
||||
</label>
|
||||
</b>
|
||||
@ -182,7 +193,7 @@ if (isset($arResult['ORDER_PROPS'])) {
|
||||
<?php endif; ?>
|
||||
|
||||
<tr <?= ($countProps > 3) ? 'class="address-detail-' . $bitrixOrderType['ID'] . '"' : ''?>
|
||||
<?= (($countProps > 3) && (count($defaultOrderProps[$bitrixOrderType['ID']]) < 6))
|
||||
<?= (is_array($defaultOrderProps[$bitrixOrderType['ID']] && ($countProps > 3) && (count($defaultOrderProps[$bitrixOrderType['ID']]) < 6)))
|
||||
? 'style="display:none;"'
|
||||
: ''
|
||||
?>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
$arModuleVersion = [
|
||||
'VERSION' => '6.2.1',
|
||||
'VERSION_DATE' => '2023-03-17 18:00:00'
|
||||
'VERSION' => '6.2.2',
|
||||
'VERSION_DATE' => '2023-03-27 14:00:00'
|
||||
];
|
||||
|
@ -1373,11 +1373,13 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<select name="payment-type-<?php echo $bitrixPaymentType['ID']; ?>" class="typeselect">
|
||||
<option value="" selected=""></option>
|
||||
<?php foreach ($arResult['paymentTypesList'] as $paymentType): ?>
|
||||
<?php if($paymentType['active'] === true): ?>
|
||||
<option value="<?php echo $paymentType['code']; ?>" <?php if ($optionsPayTypes[$bitrixPaymentType['ID']] === $paymentType['code']) {
|
||||
echo 'selected';
|
||||
} ?>>
|
||||
<?php echo $APPLICATION->ConvertCharset($paymentType['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
</option>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</label>
|
||||
@ -1422,6 +1424,7 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<optgroup label="<?php echo $APPLICATION->ConvertCharset($orderStatusGroup['name'], 'utf-8', SITE_CHARSET); ?>">
|
||||
<?php foreach ($orderStatusGroup['statuses'] as $payment): ?>
|
||||
<?php if (isset($arResult['paymentList'][$payment])): ?>
|
||||
<?php if($arResult['paymentList'][$payment]['active'] === true): ?>
|
||||
<option value="<?php echo $arResult['paymentList'][$payment]['code']; ?>" <?php if ($optionsPayStatuses[$bitrixPaymentStatus['ID']]
|
||||
=== $arResult['paymentList'][$payment]['code']) {
|
||||
echo 'selected';
|
||||
@ -1429,6 +1432,7 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<?php echo $APPLICATION->ConvertCharset($arResult['paymentList'][$payment]['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
</option>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</optgroup>
|
||||
<?php endif; endforeach; ?>
|
||||
@ -1458,11 +1462,13 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<select name="payment-<?php echo $bitrixPayment['ID']; ?>" class="typeselect">
|
||||
<option value=""></option>
|
||||
<?php foreach ($arResult['paymentStatusesList'] as $paymentStatus): ?>
|
||||
<?php if($paymentStatus['active'] === true): ?>
|
||||
<option value="<?php echo $paymentStatus['code']; ?>" <?php if ($optionsPayment[$bitrixPayment['ID']] === $paymentStatus['code']) {
|
||||
echo 'selected';
|
||||
} ?>>
|
||||
<?php echo $APPLICATION->ConvertCharset($paymentStatus['name'], 'utf-8', SITE_CHARSET); ?>
|
||||
</option>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</td>
|
||||
@ -1485,6 +1491,7 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<select name="order-type-<?php echo $bitrixOrderType['ID']; ?>" class="typeselect">
|
||||
<option value=""></option>
|
||||
<?php foreach ($arResult['orderTypesList'] as $orderType): ?>
|
||||
<?php if($orderType['active'] === true): ?>
|
||||
<option value="<?php echo $orderType['code']; ?>"
|
||||
<?php if ($optionsOrderTypes[$bitrixOrderType['ID']] === $orderType['code']) {
|
||||
echo 'selected';
|
||||
@ -1493,6 +1500,7 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
->ConvertCharset($orderType['name'], 'utf-8', SITE_CHARSET)
|
||||
?>
|
||||
</option>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</td>
|
||||
@ -2093,9 +2101,11 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<select class="typeselect" name="stores-export-<?php echo $catalogExportStore['ID'] ?>">
|
||||
<option value=""></option>
|
||||
<?php foreach ($arResult['inventoriesList'] as $inventoriesList): ?>
|
||||
<?php if ($inventoriesList['active'] === true): ?>
|
||||
<option value="<?php echo $inventoriesList['code'] ?>" <?php if ($optionStores[$catalogExportStore['ID']] === $inventoriesList['code']) {
|
||||
echo 'selected="selected"';
|
||||
} ?>><?php echo $inventoriesList['name'] ?></option>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</td>
|
||||
@ -2171,9 +2181,11 @@ if (isset($_POST['Update']) && ($_POST['Update'] === 'Y')) {
|
||||
<select class="typeselect" name="price-type-export-<?php echo $catalogExportPrice['ID']; ?>">
|
||||
<option value=""></option>
|
||||
<?php foreach ($arResult['priceTypeList'] as $priceTypeList): ?>
|
||||
<?php if ($priceTypeList['active'] === true): ?>
|
||||
<option value="<?php echo $priceTypeList['code'] ?>" <?php if ($optionPrices[$catalogExportPrice['ID']] === $priceTypeList['code']) {
|
||||
echo 'selected="selected"';
|
||||
} ?>><?php echo $priceTypeList['name'] ?></option>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</td>
|
||||
|
Loading…
Reference in New Issue
Block a user