Merge branch '0.3.9'
Conflicts: intaro.intarocrm/export/export_setup.php intaro.intarocrm/install/version.php
This commit is contained in:
commit
0e4988e415
2
intaro.intarocrm/description.ru
Normal file
2
intaro.intarocrm/description.ru
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
* При настройке выгрузки каталога сделано необязательным указание артикула товара
|
||||||
|
* Доработан скрипт генерации ICML-файла в части работы со спецсимволами
|
@ -1,4 +1,4 @@
|
|||||||
<?
|
<?
|
||||||
|
|
||||||
|
|
||||||
if(!check_bitrix_sessid()) return;
|
if(!check_bitrix_sessid()) return;
|
||||||
@ -20,9 +20,9 @@ if (($ACTION == 'EXPORT_EDIT' || $ACTION == 'EXPORT_COPY') && $STEP == 1)
|
|||||||
|
|
||||||
if ($STEP>1)
|
if ($STEP>1)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
if (count($IBLOCK_EXPORT) < count($IBLOCK_PROPERTY_ARTICLE))
|
if (count($IBLOCK_EXPORT) < count($IBLOCK_PROPERTY_ARTICLE))
|
||||||
$arSetupErrors[] = GetMessage("ERROR_ARTICLE_NOT_SET");
|
$arSetupErrors[] = GetMessage("ERROR_ARTICLE_NOT_SET");
|
||||||
|
|
||||||
if (strlen($SETUP_FILE_NAME)<=0)
|
if (strlen($SETUP_FILE_NAME)<=0)
|
||||||
@ -51,7 +51,7 @@ if (!empty($arSetupErrors))
|
|||||||
|
|
||||||
if ($STEP==1)
|
if ($STEP==1)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<form method="post" action="<?php echo $APPLICATION->GetCurPage(); ?>" >
|
<form method="post" action="<?php echo $APPLICATION->GetCurPage(); ?>" >
|
||||||
@ -66,8 +66,8 @@ if ($STEP==1)
|
|||||||
{
|
{
|
||||||
$IBLOCK_EXPORT = array();
|
$IBLOCK_EXPORT = array();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$boolAll = false;
|
$boolAll = false;
|
||||||
$intCountChecked = 0;
|
$intCountChecked = 0;
|
||||||
$intCountAvailIBlock = 0;
|
$intCountAvailIBlock = 0;
|
||||||
@ -88,14 +88,14 @@ if ($STEP==1)
|
|||||||
$db_properties = CIBlock::GetProperties($res['ID'], Array());
|
$db_properties = CIBlock::GetProperties($res['ID'], Array());
|
||||||
|
|
||||||
$properties = Array();
|
$properties = Array();
|
||||||
while($prop = $db_properties->Fetch())
|
while($prop = $db_properties->Fetch())
|
||||||
$properties[] = $prop;
|
$properties[] = $prop;
|
||||||
|
|
||||||
if (count($IBLOCK_EXPORT) != 0)
|
if (count($IBLOCK_EXPORT) != 0)
|
||||||
$boolExport = (in_array($res['ID'], $IBLOCK_EXPORT));
|
$boolExport = (in_array($res['ID'], $IBLOCK_EXPORT));
|
||||||
else
|
else
|
||||||
$boolExport = true;
|
$boolExport = true;
|
||||||
|
|
||||||
$arIBlockList[] = array(
|
$arIBlockList[] = array(
|
||||||
'ID' => $res['ID'],
|
'ID' => $res['ID'],
|
||||||
'NAME' => $res['NAME'],
|
'NAME' => $res['NAME'],
|
||||||
@ -105,7 +105,7 @@ if ($STEP==1)
|
|||||||
'OLD_PROPERTY_SELECT' => $IBLOCK_PROPERTY_ARTICLE[$res['ID']] != "" ? $IBLOCK_PROPERTY_ARTICLE[$res['ID']] : null,
|
'OLD_PROPERTY_SELECT' => $IBLOCK_PROPERTY_ARTICLE[$res['ID']] != "" ? $IBLOCK_PROPERTY_ARTICLE[$res['ID']] : null,
|
||||||
'SITE_LIST' => '('.implode(' ',$arSiteList).')',
|
'SITE_LIST' => '('.implode(' ',$arSiteList).')',
|
||||||
);
|
);
|
||||||
|
|
||||||
if ($boolExport)
|
if ($boolExport)
|
||||||
$intCountChecked++;
|
$intCountChecked++;
|
||||||
$intCountAvailIBlock++;
|
$intCountAvailIBlock++;
|
||||||
@ -119,11 +119,12 @@ if ($STEP==1)
|
|||||||
$intCountChecked = $intCountAvailIBlock;
|
$intCountChecked = $intCountAvailIBlock;
|
||||||
$boolAll = true;
|
$boolAll = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<table class="adm-list-table" id="export_setup">
|
<table class="adm-list-table" id="export_setup">
|
||||||
<thead>
|
<thead>
|
||||||
<tr class="adm-list-table-header">
|
<tr class="adm-list-table-header">
|
||||||
@ -174,10 +175,10 @@ if ($STEP==1)
|
|||||||
</font>
|
</font>
|
||||||
</td>
|
</td>
|
||||||
<td class="adm-list-table-cell">
|
<td class="adm-list-table-cell">
|
||||||
<select
|
<select
|
||||||
style="width: 200px;"
|
style="width: 200px;"
|
||||||
id="IBLOCK_PROPERTY_ARTICLE<?=$arIBlock["ID"]?>"
|
id="IBLOCK_PROPERTY_ARTICLE<?=$arIBlock["ID"]?>"
|
||||||
name="IBLOCK_PROPERTY_ARTICLE[<?=$arIBlock["ID"]?>]"
|
name="IBLOCK_PROPERTY_ARTICLE[<?=$arIBlock["ID"]?>]"
|
||||||
class="property-export">
|
class="property-export">
|
||||||
<option value=""></option>
|
<option value=""></option>
|
||||||
<?
|
<?
|
||||||
@ -189,13 +190,15 @@ if ($STEP==1)
|
|||||||
if ($arIBlock['OLD_PROPERTY_SELECT'] == $prop["CODE"]){
|
if ($arIBlock['OLD_PROPERTY_SELECT'] == $prop["CODE"]){
|
||||||
echo " selected";
|
echo " selected";
|
||||||
} else {
|
} else {
|
||||||
if ($prop["CODE"] == "ARTICLE" ||
|
if ($arIBlock['OLD_PROPERTY_SELECT'] != "") {
|
||||||
$prop["CODE"] == "ART" ||
|
if ($prop["CODE"] == "ARTICLE" ||
|
||||||
$prop["CODE"] == "ARTNUMBER" )
|
$prop["CODE"] == "ART" ||
|
||||||
echo " selected";
|
$prop["CODE"] == "ARTNUMBER" )
|
||||||
|
echo " selected";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
>
|
>
|
||||||
<?=$prop["NAME"];?>
|
<?=$prop["NAME"];?>
|
||||||
@ -226,25 +229,25 @@ if ($STEP==1)
|
|||||||
'/bitrix/catalog_export/'))
|
'/bitrix/catalog_export/'))
|
||||||
.'intarocrm'/* .mt_rand(0, 999999) */.'.xml'
|
.'intarocrm'/* .mt_rand(0, 999999) */.'.xml'
|
||||||
); ?>" size="50">
|
); ?>" size="50">
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
|
|
||||||
<?if ($ACTION=="EXPORT_SETUP" || $ACTION == 'EXPORT_EDIT' || $ACTION == 'EXPORT_COPY'):?>
|
<?if ($ACTION=="EXPORT_SETUP" || $ACTION == 'EXPORT_EDIT' || $ACTION == 'EXPORT_COPY'):?>
|
||||||
<font class="text"><?=GetMessage("PROFILE_NAME");?><br><br></font>
|
<font class="text"><?=GetMessage("PROFILE_NAME");?><br><br></font>
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
name="SETUP_PROFILE_NAME"
|
name="SETUP_PROFILE_NAME"
|
||||||
value="<?echo htmlspecialchars($SETUP_PROFILE_NAME)?>"
|
value="<?echo htmlspecialchars($SETUP_PROFILE_NAME)?>"
|
||||||
size="50">
|
size="50">
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<?endif;?>
|
<?endif;?>
|
||||||
|
|
||||||
|
|
||||||
<script type="text/javascript" src="/bitrix/js/main/jquery/jquery-1.7.min.js"></script>
|
<script type="text/javascript" src="/bitrix/js/main/jquery/jquery-1.7.min.js"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function checkAll(obj,cnt)
|
function checkAll(obj,cnt)
|
||||||
@ -267,11 +270,11 @@ if ($STEP==1)
|
|||||||
BX(obj.id.replace('IBLOCK_EXPORT','IBLOCK_PROPERTY_ARTICLE')).value = 'none';
|
BX(obj.id.replace('IBLOCK_EXPORT','IBLOCK_PROPERTY_ARTICLE')).value = 'none';
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
<?//Следующие переменные должны быть обязательно установлены?>
|
<?//Следующие переменные должны быть обязательно установлены?>
|
||||||
<?=bitrix_sessid_post();?>
|
<?=bitrix_sessid_post();?>
|
||||||
|
|
||||||
<input type="hidden" name="lang" value="<?echo LANGUAGE_ID ?>">
|
<input type="hidden" name="lang" value="<?echo LANGUAGE_ID ?>">
|
||||||
<input type="hidden" name="ACT_FILE" value="<?echo htmlspecialcharsbx($_REQUEST["ACT_FILE"]) ?>">
|
<input type="hidden" name="ACT_FILE" value="<?echo htmlspecialcharsbx($_REQUEST["ACT_FILE"]) ?>">
|
||||||
<input type="hidden" name="ACTION" value="<?echo htmlspecialcharsbx($ACTION) ?>">
|
<input type="hidden" name="ACTION" value="<?echo htmlspecialcharsbx($ACTION) ?>">
|
||||||
@ -279,7 +282,7 @@ if ($STEP==1)
|
|||||||
<input type="hidden" name="SETUP_FIELDS_LIST" value="SETUP_FILE_NAME,IBLOCK_EXPORT,IBLOCK_PROPERTY_ARTICLE">
|
<input type="hidden" name="SETUP_FIELDS_LIST" value="SETUP_FILE_NAME,IBLOCK_EXPORT,IBLOCK_PROPERTY_ARTICLE">
|
||||||
<input type="submit" value="<?echo ($ACTION=="EXPORT")?GetMessage("CET_EXPORT"):GetMessage("CET_SAVE")?>">
|
<input type="submit" value="<?echo ($ACTION=="EXPORT")?GetMessage("CET_EXPORT"):GetMessage("CET_SAVE")?>">
|
||||||
|
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<?
|
<?
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<?
|
<?
|
||||||
$arModuleVersion = array(
|
$arModuleVersion = array(
|
||||||
'VERSION' => '0.3.8',
|
"VERSION" => "0.3.9",
|
||||||
'VERSION_DATE' => '2013-08-14 19:32:00',
|
"VERSION_DATE" => "2013-08-21 18:32:00",
|
||||||
);
|
);
|
10
intaro.intarocrm/updater.php
Normal file
10
intaro.intarocrm/updater.php
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
<?
|
||||||
|
if (file_exists($_SERVER['DOCUMENT_ROOT'] . '/bitrix/php_interface/include/catalog_export/intarocrm_run.php')) {
|
||||||
|
unlink($_SERVER['DOCUMENT_ROOT'] . '/bitrix/php_interface/include/catalog_export/intarocrm_run.php');
|
||||||
|
}
|
||||||
|
$updater->CopyFiles("install/export/intarocrm_run.php", "php_interface/include/catalog_export/intarocrm_run.php");
|
||||||
|
|
||||||
|
if (file_exists($_SERVER['DOCUMENT_ROOT'] . '/bitrix/php_interface/include/catalog_export/intarocrm_setup.php')) {
|
||||||
|
unlink($_SERVER['DOCUMENT_ROOT'] . '/bitrix/php_interface/include/catalog_export/intarocrm_setup.php');
|
||||||
|
}
|
||||||
|
$updater->CopyFiles("install/export/intarocrm_setup.php", "php_interface/include/catalog_export/intarocrm_setup.php");
|
Loading…
Reference in New Issue
Block a user