403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /home/bitrix/ext_www/cvetdv.ru/bitrix/modules/yandex.market/lib/catalog/run/storage/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/cvetdv.ru/bitrix/modules/yandex.market/lib/catalog/run/storage/assortment.php
<?php
namespace Yandex\Market\Catalog\Run\Storage;

use Bitrix\Main;
use Yandex\Market\Reference;

class AssortmentTable extends Reference\Storage\Table
{
	const STATUS_UNKNOWN = 'U';
	const STATUS_PLACED = 'P';
	const STATUS_MISSING = 'M';

	public static function getTableName()
	{
		return 'yamarket_catalog_run_assortment';
	}

	public static function createIndexes(Main\DB\Connection $connection)
	{
		$tableName = static::getTableName();

		$connection->createIndex($tableName, 'IX_' . $tableName . '_1', [ 'ELEMENT_ID' ]);
		$connection->createIndex($tableName, 'IX_' . $tableName . '_2', [ 'STATUS' ]);
	}

	public static function getMap()
	{
		return [
            new Main\Entity\IntegerField('CATALOG_ID', [
                'primary' => true,
            ]),
            new Main\Entity\StringField('SKU', [
                'primary' => true,
                'validation' => function() {
                    return [ new Main\Entity\Validator\Length(1, 255) ];
                },
            ]),
			new Main\Entity\IntegerField('ELEMENT_ID', [
                'nullable' => true,
            ]),
			new Main\Entity\IntegerField('CATEGORY_ID', [
                'nullable' => true,
            ]),
			new Main\Entity\EnumField('STATUS', [
				'required' => true,
				'values' => [
					static::STATUS_UNKNOWN,
					static::STATUS_PLACED,
					static::STATUS_MISSING,
				],
			]),
			new Reference\Storage\Field\CanonicalDateTime('TIMESTAMP_X', [
				'required' => true,
			]),
			new Reference\Storage\Field\CanonicalDateTime('CREATED_AT', [
				'required' => true,
			]),

            new Main\Entity\ReferenceField('OFFER', OfferTable::class, [
                '=this.CATALOG_ID' => 'ref.CATALOG_ID',
                '=this.ELEMENT_ID' => 'ref.ELEMENT_ID',
            ]),
		];
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit