bitrix-expert / tools
Helpers for developers on Bitrix
Installs: 20 289
Dependents: 1
Suggesters: 0
Security: 0
Stars: 36
Watchers: 13
Forks: 14
Open Issues: 2
Requires
- php: >=5.4.0
README
Tools for developers on Bitrix CMS:
- IblockTools: finder info blocks and properties by IDs or symbol codes.
<?php use Bex\Tools\Iblock\IblockTools; $iblockFinder = IblockTools::find('iblock_type', 'iblock_code'); $iblockId = $iblockFinder->id(); $propEnumId = $iblockFinder->propEnumId('PROP_CODE', 'VALUE_XML_ID'); // And much moreā¦
- GroupTools: finder users groups by IDs or symbol codes.
<?php use Bex\Tools\Group\GroupTools; $groupFinder = GroupTools::find('group_code'); $groupId = $groupFinder->id(); $groupCode = GroupTools::findById(3)->code(); // And that's not all ;-)
- HlBlockTools: finder for highloadblock IDs by it's names.
<?php use Bex\Tools\HlBlock\HlBlockTools; $hlBlockFinder = HlBlockTools::find('ReferenceName'); $hlBlockId = $hlBlockFinder->id(); $hlBlockName = HlBlockTools::findById(2)->name();
- Catalog\GroupTools: finder for catalog groups (price types) by it's names? id's or "BASE" flag.
<?php use Bex\Tools\Catalog\GroupTools; $catalogGroupFinder = GroupTools::find('RETAIL'); $priceTypeId = $catalogGroupFinder->id(); $priceTypeName = GroupTools::findBase()->name();
- Prevents the creation of infoblocks with the same codes.
- Prevents the creation of user groups with the same string id.
Installation
Add library on your Composer:
composer require bitrix-expert/tools
Documentation
See wiki and php docs in the classes of library.