Source of file AnyPriceProductPage_ProductVariation.php
Size: 1,274 Bytes - Last Modified: 2021-12-23T10:40:30+00:00
/var/www/docs.ssmods.com/process/src/src/Model/AnyPriceProductPage_ProductVariation.php
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 | <?php namespace Sunnysideup\EcommerceAnyPriceProduct\Model; use Sunnysideup\EcommerceAnyPriceProduct\Model\AnyPriceProductPage_ProductVariationOrderItem; use SilverStripe\Security\Member; use Sunnysideup\EcommerceProductVariation\Model\Buyables\ProductVariation; class AnyPriceProductPage_ProductVariation extends ProductVariation { /** * ### @@@@ START REPLACEMENT @@@@ ### * OLD: private static $db (case sensitive) * NEW: private static $table_name = '[SEARCH_REPLACE_CLASS_NAME_GOES_HERE]'; private static $db (COMPLEX) * EXP: Check that is class indeed extends DataObject and that it is not a data-extension! * ### @@@@ STOP REPLACEMENT @@@@ ### */ private static $table_name = 'AnyPriceProductPage_ProductVariation'; private static $db =array( "Description" => "Varchar(200)" ); /** * * @var String */ protected $defaultClassNameForOrderItem = AnyPriceProductPage_ProductVariationOrderItem::class; public function canPurchase(Member $member = null, $checkPrice = true) { return true; } public function TableSubTitle() { return $this->getTableSubTitle(); } public function getTableSubTitle() { return $this->Description; } } |