Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
storebatchdocumentelementtable.php
1<?php
2namespace Bitrix\Catalog;
3
4use Bitrix\Main\Entity\FloatField;
5use Bitrix\Main\Entity\ReferenceField;
10
28{
34 public static function getTableName(): string
35 {
36 return 'b_catalog_store_batch_docs_element';
37 }
38
44 public static function getMap(): array
45 {
46 return [
47 new IntegerField(
48 'ID',
49 [
50 'primary' => true,
51 'autocomplete' => true
52 ]
53 ),
54 new IntegerField(
55 'PRODUCT_BATCH_ID',
56 [
57 'required' => true,
58 ]
59 ),
60 new ReferenceField(
61 'PRODUCT_BATCH',
62 \Bitrix\Catalog\StoreBatchTable::class,
63 ['=this.STORE_ID' => 'ref.ID'],
64 ['join_type' => 'INNER']
65 ),
66 new IntegerField('DOCUMENT_ELEMENT_ID'),
67 new ReferenceField(
68 'DOCUMENT_ELEMENT',
69 \Bitrix\Catalog\StoreDocumentElementTable::class,
70 ['=this.DOCUMENT_ELEMENT_ID' => 'ref.ID'],
71 ['join_type' => 'INNER']
72 ),
73 new \Bitrix\Main\Entity\IntegerField('SHIPMENT_ITEM_STORE_ID'),
74 new ReferenceField(
75 'SHIPMENT_ITEM_STORE',
76 ShipmentItemStoreTable::class,
77 ['=this.SHIPMENT_ITEM_STORE_ID' => 'ref.ID'],
78 ['join_type' => 'INNER']
79 ),
80 new FloatField(
81 'AMOUNT',
82 array(
83 'required' => true
84 )
85 ),
86 (new FloatField('BATCH_PRICE'))
87 ->configureDefaultValue(0.00)
88 ,
89 (new StringField('BATCH_CURRENCY'))
90 ->configureSize(3)
91 ,
92 ];
93 }
94}