Shop_Payment_System_Handler
in package
Online shop.
Tags
Table of Contents
Properties
- $_aDiscountPrices : array<string|int, mixed>
- $_adminMailContentType : mixed
- Content-type письма администратору о заказе
- $_adminMailSubject : mixed
- Тема письма администратору о заказе
- $_allowOrderPropertyFiles : bool
- Allow upload files for order's property
- $_amount : array<string|int, mixed>
- $_amountPurchaseDiscount : array<string|int, mixed>
- $_applyDiscountCards : bool
- Apply Discount Cards
- $_applyDiscounts : bool
- Round prices
- $_aProperties : array<string|int, mixed>
- List of properties
- $_aProperty_Dirs : array<string|int, mixed>
- Property directories
- $_bonusMultiplier : int
- DEPRECATED as of HostCMS 6.9.2
- $_from : mixed
- Адреса отправителя
- $_notificationModes : mixed
- Массив с режимами, при использовании которых должно происходить уведомление о покупке - apply - применение изменений заказа из списка заказа, включая изменение статуса - edit - редактирование заказа - changeStatusPaid - изменение статуса оплаты из списка заказов - cancelPaid - отмена заказа
- $_orderParams : array<string|int, mixed>
- Params of the order
- $_quantity : array<string|int, mixed>
- $_quantityPurchaseDiscount : array<string|int, mixed>
- $_round : bool
- Round prices
- $_senderName : mixed
- Имя отправителя
- $_Shop_Payment_System_Model : Shop_Payment_System_Model
- Payment system
- $_shopOrder : mixed
- Объект заказа
- $_shopOrderBeforeAction : mixed
- Объект заказа до изменения.
- $_siteuserMailContentType : mixed
- Content-type письма пользователю о заказе
- $_siteuserMailSubject : mixed
- Тема письма пользователю о заказе
- $_weight : array<string|int, mixed>
- $_xsl : mixed
- XSL данных о заказе
- $_xslAdminMail : mixed
- XSL письма администратору о заказе
- $_xslSiteuserMail : mixed
- XSL письма пользователю о заказе
Methods
- __construct() : mixed
- Constructor.
- adminMailContentType() : self
- Set Content-type of admin's e-mail
- adminMailSubject() : self
- Set subject to shop's administrator e-mail
- allowOrderPropertyFiles() : self
- Allow upload files for order's property
- applyBonuses() : self
- Apply Bonuses
- applyDiscountCards() : self
- Apply Discount Cards
- applyDiscounts() : self
- Apply Discounts
- applyPartialPayment() : self
- Apply Partial Payment by Siteuser's account
- changedOrder() : mixed
- Уведомление об операциях с заказом
- checkAfterContent() : mixed
- Call ->checkPaymentAfterContent() on each shop's Shop_Payment_System_Handlers
- checkBeforeContent() : mixed
- Call ->checkPaymentBeforeContent() on each shop's Shop_Payment_System_Handlers
- createNotification() : self
- Create Notifications
- createOrder() : mixed
- Create a new order by $this->_orderParams
- execute() : mixed
- Executes the business logic.
- factory() : mixed
- Create instance of payment system
- from() : self
- Set FROM
- getAdminEmail() : Core_Mail
- Get admin e-mail
- getAdminEmails() : array<string|int, mixed>
- Get array of admin emails
- getInvoice() : mixed
- Get invoice form
- getNotification() : mixed
- Get notification form
- getShopOrder() : Shop_Order_Model
- Get Shop_Order Model
- getShopOrderBeforeAction() : Shop_Order_Model
- Get order before change
- getSiteuserEmail() : Core_Mail
- Get user mail
- orderParams() : self
- Set order params
- printInvoice() : self
- Shows invoice
- printNotification() : self
- Shows notification
- round() : self
- Round prices
- send() : mixed
- Send emails about order
- sendAdminEmail() : self
- Send e-mail to shop's administrator
- senderName() : self
- Set subject to user e-mail
- sendSiteuserEmail() : self
- Send e-mail to user
- setMailSubjects() : self
- Set Mail Subjects
- setNotificationModes() : self
- Set $this->_notificationModes
- setXSLs() : self
- Set XSLs to e-mail
- shopOrder() : self
- Set order
- shopOrderBeforeAction() : self
- Set order before change
- siteuserMailContentType() : self
- Set Content-type of user's e-mail
- siteuserMailSubject() : self
- Set subject to user e-mail
- userExecute() : self
- Клиентская логика обработки платежа
- xsl() : self
- Set XSL for order data
- xslAdminMail() : self
- Set XSL for admin's e-mail
- xslSiteuserMail() : self
- Set XSL for user's e-mail
- _addDelivery() : self
- Add a delivery into the order
- _addPropertiesList() : self
- Add list of user's properties to XML
- _addPurchaseDiscount() : self
- Add a discount to the purchase
- _addShopDiscountcardBonusTransaction() : self
- Добавление транзакции со списанием бонусов, используется для возврата бонусов при отмене оплаты заказа
- _applyBonuses() : self
- Backward compatibility, see applyBonuses()
- _attachDigitalItems() : self
- Attach digital items to mail
- _check() : mixed
- Protected method to call $methodName on each shop's Shop_Payment_System_Handlers
- _createNotification() : self
- Backward compatibility, see createNotifications()
- _getDeliveryName() : string
- Get delivery name
- _getEmailFrom() : string
- Get sender email
- _prepareXml() : Shop_Model
- Prepare XML
- _processOrder() : mixed
- Создание нового заказа на основе данных, указанных в orderParams
- _processXml() : mixed
- Process XML
Properties
$_aDiscountPrices
protected
array<string|int, mixed>
$_aDiscountPrices
= array()
$_adminMailContentType
Content-type письма администратору о заказе
protected
mixed
$_adminMailContentType
= 'text/html'
$_adminMailSubject
Тема письма администратору о заказе
protected
mixed
$_adminMailSubject
= \NULL
$_allowOrderPropertyFiles
Allow upload files for order's property
protected
bool
$_allowOrderPropertyFiles
= \FALSE
$_amount
protected
array<string|int, mixed>
$_amount
= \NULL
$_amountPurchaseDiscount
protected
array<string|int, mixed>
$_amountPurchaseDiscount
= \NULL
$_applyDiscountCards
Apply Discount Cards
protected
bool
$_applyDiscountCards
= \TRUE
$_applyDiscounts
Round prices
protected
bool
$_applyDiscounts
= \TRUE
$_aProperties
List of properties
protected
array<string|int, mixed>
$_aProperties
= array()
$_aProperty_Dirs
Property directories
protected
array<string|int, mixed>
$_aProperty_Dirs
= array()
$_bonusMultiplier
DEPRECATED as of HostCMS 6.9.2
protected
int
$_bonusMultiplier
= 1
$_from
Адреса отправителя
protected
mixed
$_from
= \NULL
$_notificationModes
Массив с режимами, при использовании которых должно происходить уведомление о покупке - apply - применение изменений заказа из списка заказа, включая изменение статуса - edit - редактирование заказа - changeStatusPaid - изменение статуса оплаты из списка заказов - cancelPaid - отмена заказа
protected
mixed
$_notificationModes
= array('changeStatusPaid', 'edit')
$_orderParams
Params of the order
protected
array<string|int, mixed>
$_orderParams
= \NULL
$_quantity
protected
array<string|int, mixed>
$_quantity
= \NULL
$_quantityPurchaseDiscount
protected
array<string|int, mixed>
$_quantityPurchaseDiscount
= \NULL
$_round
Round prices
protected
bool
$_round
= \TRUE
$_senderName
Имя отправителя
protected
mixed
$_senderName
= \NULL
$_Shop_Payment_System_Model
Payment system
protected
Shop_Payment_System_Model
$_Shop_Payment_System_Model
= \NULL
$_shopOrder
Объект заказа
protected
mixed
$_shopOrder
= \NULL
$_shopOrderBeforeAction
Объект заказа до изменения.
protected
mixed
$_shopOrderBeforeAction
= \NULL
$_siteuserMailContentType
Content-type письма пользователю о заказе
protected
mixed
$_siteuserMailContentType
= 'text/html'
$_siteuserMailSubject
Тема письма пользователю о заказе
protected
mixed
$_siteuserMailSubject
= \NULL
$_weight
protected
array<string|int, mixed>
$_weight
= \NULL
$_xsl
XSL данных о заказе
protected
mixed
$_xsl
= \NULL
$_xslAdminMail
XSL письма администратору о заказе
protected
mixed
$_xslAdminMail
= \NULL
$_xslSiteuserMail
XSL письма пользователю о заказе
protected
mixed
$_xslSiteuserMail
= \NULL
Methods
__construct()
Constructor.
public
__construct(Shop_Payment_System_Model $oShop_Payment_System_Model) : mixed
Parameters
- $oShop_Payment_System_Model : Shop_Payment_System_Model
-
payment system
adminMailContentType()
Set Content-type of admin's e-mail
public
adminMailContentType(string $contentType) : self
Parameters
- $contentType : string
-
Content-type
Return values
selfadminMailSubject()
Set subject to shop's administrator e-mail
public
adminMailSubject(string $subject) : self
Parameters
- $subject : string
-
subject
Return values
selfallowOrderPropertyFiles()
Allow upload files for order's property
public
allowOrderPropertyFiles(bool $allowOrderPropertyFiles) : self
Parameters
- $allowOrderPropertyFiles : bool
Return values
selfapplyBonuses()
Apply Bonuses
public
applyBonuses() : self
Return values
selfapplyDiscountCards()
Apply Discount Cards
public
applyDiscountCards(bool $applyDiscountCards) : self
Parameters
- $applyDiscountCards : bool
Return values
selfapplyDiscounts()
Apply Discounts
public
applyDiscounts(bool $applyDiscounts) : self
Parameters
- $applyDiscounts : bool
Return values
selfapplyPartialPayment()
Apply Partial Payment by Siteuser's account
public
applyPartialPayment() : self
Return values
selfchangedOrder()
Уведомление об операциях с заказом
public
changedOrder(string $mode) : mixed
Parameters
- $mode : string
-
режим изменения:
- apply - применение изменений заказа из списка заказа, включая изменение статуса
- edit - редактирование заказа
- changeStatusPaid - изменение статуса оплаты из списка заказов
- cancelPaid - отмена заказа
Tags
checkAfterContent()
Call ->checkPaymentAfterContent() on each shop's Shop_Payment_System_Handlers
public
static checkAfterContent(Shop_Model $oShop) : mixed
Parameters
- $oShop : Shop_Model
checkBeforeContent()
Call ->checkPaymentBeforeContent() on each shop's Shop_Payment_System_Handlers
public
static checkBeforeContent(Shop_Model $oShop) : mixed
Parameters
- $oShop : Shop_Model
createNotification()
Create Notifications
public
createNotification() : self
Return values
selfcreateOrder()
Create a new order by $this->_orderParams
public
createOrder() : mixed
execute()
Executes the business logic.
public
execute() : mixed
Tags
factory()
Create instance of payment system
public
static factory(Shop_Payment_System_Model $oShop_Payment_System_Model) : mixed
Parameters
- $oShop_Payment_System_Model : Shop_Payment_System_Model
-
payment system
from()
Set FROM
public
from(string $from) : self
Parameters
- $from : string
Return values
selfgetAdminEmail()
Get admin e-mail
public
getAdminEmail() : Core_Mail
Return values
Core_MailgetAdminEmails()
Get array of admin emails
public
getAdminEmails() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>getInvoice()
Get invoice form
public
getInvoice() : mixed
getNotification()
Get notification form
public
getNotification() : mixed
getShopOrder()
Get Shop_Order Model
public
getShopOrder() : Shop_Order_Model
Return values
Shop_Order_ModelgetShopOrderBeforeAction()
Get order before change
public
getShopOrderBeforeAction() : Shop_Order_Model
Return values
Shop_Order_ModelgetSiteuserEmail()
Get user mail
public
getSiteuserEmail() : Core_Mail
Return values
Core_MailorderParams()
Set order params
public
orderParams(array<string|int, mixed> $orderParams) : self
Parameters
- $orderParams : array<string|int, mixed>
Tags
Return values
selfprintInvoice()
Shows invoice
public
printInvoice() : self
Return values
selfprintNotification()
Shows notification
public
printNotification() : self
Return values
selfround()
Round prices
public
round(bool $round) : self
Parameters
- $round : bool
Return values
selfsend()
Send emails about order
public
send() : mixed
Tags
sendAdminEmail()
Send e-mail to shop's administrator
public
sendAdminEmail(Core_Mail $oCore_Mail) : self
Parameters
- $oCore_Mail : Core_Mail
-
mail
Tags
Return values
selfsenderName()
Set subject to user e-mail
public
senderName(mixed $senderName) : self
Parameters
- $senderName : mixed
Return values
selfsendSiteuserEmail()
Send e-mail to user
public
sendSiteuserEmail(Core_Mail $oCore_Mail) : self
Parameters
- $oCore_Mail : Core_Mail
-
mail
Tags
Return values
selfsetMailSubjects()
Set Mail Subjects
public
setMailSubjects() : self
Return values
selfsetNotificationModes()
Set $this->_notificationModes
public
setNotificationModes(array<string|int, mixed> $notificationModes) : self
Parameters
- $notificationModes : array<string|int, mixed>
Return values
selfsetXSLs()
Set XSLs to e-mail
public
setXSLs() : self
Tags
Return values
selfshopOrder()
Set order
public
shopOrder(Shop_Order_Model $oShop_Order) : self
Parameters
- $oShop_Order : Shop_Order_Model
Return values
selfshopOrderBeforeAction()
Set order before change
public
shopOrderBeforeAction(Shop_Order_Model $oShopOrderBeforeAction) : self
Parameters
- $oShopOrderBeforeAction : Shop_Order_Model
Return values
selfsiteuserMailContentType()
Set Content-type of user's e-mail
public
siteuserMailContentType(string $contentType) : self
Parameters
- $contentType : string
-
Content-type
Return values
selfsiteuserMailSubject()
Set subject to user e-mail
public
siteuserMailSubject(string $subject) : self
Parameters
- $subject : string
-
subject
Return values
selfuserExecute()
Клиентская логика обработки платежа
public
userExecute() : self
Return values
selfxsl()
Set XSL for order data
public
xsl(Xsl_Model $oXsl) : self
Parameters
- $oXsl : Xsl_Model
Return values
selfxslAdminMail()
Set XSL for admin's e-mail
public
xslAdminMail(Xsl_Model $oXsl) : self
Parameters
- $oXsl : Xsl_Model
Return values
selfxslSiteuserMail()
Set XSL for user's e-mail
public
xslSiteuserMail(Xsl_Model $oXsl) : self
Parameters
- $oXsl : Xsl_Model
Return values
self_addDelivery()
Add a delivery into the order
protected
_addDelivery() : self
Tags
Return values
self_addPropertiesList()
Add list of user's properties to XML
protected
_addPropertiesList(int $parent_id, object $parentObject) : self
Parameters
- $parent_id : int
-
parent directory
- $parentObject : object
Return values
self_addPurchaseDiscount()
Add a discount to the purchase
protected
_addPurchaseDiscount() : self
Return values
self_addShopDiscountcardBonusTransaction()
Добавление транзакции со списанием бонусов, используется для возврата бонусов при отмене оплаты заказа
protected
_addShopDiscountcardBonusTransaction(int $shop_discountcard_bonus_id, float $amount) : self
Parameters
- $shop_discountcard_bonus_id : int
- $amount : float
Return values
self_applyBonuses()
Backward compatibility, see applyBonuses()
protected
_applyBonuses() : self
Return values
self_attachDigitalItems()
Attach digital items to mail
protected
_attachDigitalItems(Core_Mail $oCore_Mail) : self
Parameters
- $oCore_Mail : Core_Mail
-
mail
Tags
Return values
self_check()
Protected method to call $methodName on each shop's Shop_Payment_System_Handlers
protected
static _check(Shop_Model $oShop, mixed $methodName) : mixed
Parameters
- $oShop : Shop_Model
- $methodName : mixed
_createNotification()
Backward compatibility, see createNotifications()
protected
_createNotification() : self
Return values
self_getDeliveryName()
Get delivery name
protected
_getDeliveryName(Shop_Delivery_Model $oShop_Delivery[, mixed $shop_delivery_condition_name = NULL ]) : string
Parameters
- $oShop_Delivery : Shop_Delivery_Model
- $shop_delivery_condition_name : mixed = NULL
Return values
string_getEmailFrom()
Get sender email
protected
_getEmailFrom() : string
Return values
string_prepareXml()
Prepare XML
protected
_prepareXml() : Shop_Model
Tags
Return values
Shop_Model_processOrder()
Создание нового заказа на основе данных, указанных в orderParams
protected
_processOrder() : mixed
Tags
_processXml()
Process XML
protected
_processXml() : mixed