<?php
namespace Entity; class Validator_BspImportedRefund extends \App\Entity\Utils\Extension_ValidateDefaultAbstract { protected function isAccessible_insert() { if (!\App\UserAccess\CurrentUserAccessFast::getInstance()->hasAccessToOption('Modules/Bsp/Listing-insert')) { $this->entity->getMessages()->addWarningCode('noAccessToOption'); } } protected function check_insert() { } protected function isAccessible_update() { if (!\App\UserAccess\CurrentUserAccessFast::getInstance()->hasAccessToOption('Modules/Bsp/Listing-update')) { $this->entity->getMessages()->addWarningCode('noAccessToOption'); } } protected function isAvailable_update() { if (!\Entity\BspImportedRefund::select($this->entity->getId())->recordExists()) { $this->entity->getMessages()->addErrorCode('update_invalidId'); } } protected function check_update() { } protected function isAccessible_delete() { if (!\App\UserAccess\CurrentUserAccessFast::getInstance()->hasAccessToOption('Modules/Bsp/Listing-delete')) { $this->entity->getMessages()->addWarningCode('noAccessToOption'); } } protected function isAvailable_delete() { } }