SubscribeTable
SubscribeTable class for handling table with subscriptions to unavailable products.
Class methods
Method | Description | Available from version |
---|---|---|
checkPermissionSubscribe | Checks permission for subscription to product. | |
getContactTypes | Returns all available user contacts types used for subscription. | |
getMap | Returns list of fields for table with subscriptions to unavailable products. | |
getTableName | Returns name for table with subscriptions to unavailable products. | |
onAddContactType | Handler to the event onAddContactType . Adds new user contact type. |
|
onIblockElementDelete | Handler to the event onIblockElementDelete . Deletes subscription data when deleting a product. |
|
onProductSetAvailableUpdate | Handler to the event onProductSetAvailableUpdate . Sends notification about product availability (event for bundles). |
|
onProductUpdate | Handler for the event onProductUpdate . Sends notification to subscribers about product availability (event for standard products). |
|
onSaleOrderSaved | Handler for the event OnSaleOrderSaved . Deletes user's product subscription when placing an order. |
|
onUserDelete | Handler for the event onUserDelete . Updates subscription data when deleting a user. |
|
runAgentToSendNotice | Launches agent for subscriber notifications delivery. | |
runAgentToSendRepeatedNotice | Launches agent for recurring subscriber notifications. | |
sendNotice | Agent. Receives necessary data and sends notifications to users. | |
sendRepeatedNotice | Agent. Receives necessary data and sends recurring user notifications. | |
setOldProductAvailable | Saves old product availability value into a static variable for later check, how this availability was updated. | |
validateNeedSending | Returns validator for the field NEED_SENDING . |
|
validateSiteId | Returns validator for the field SITE_ID . |
Fields of subscriptions to unavailable products
Field | Description | Type | Required |
---|---|---|---|
ID | Subscription ID. | Int | Yes |
DATE_FROM | Product subscription start date. | Datetime | Yes |
DATE_TO | Product subscription end date. | Datetime | No |
USER_CONTACT | User contact. | Varchar(255) | Yes |
CONTACT_TYPE | Contact type. | Smallint | Yes |
USER_ID | user ID. | Int | No |
ITEM_ID | Product ID. | Int | Yes |
NEED_SENDING | Subscription activity. | Char(1) | Yes |
SITE_ID | Site ID. | Char(2) | Yes |
© «Bitrix24», 2001-2024