Go to the documentation of this file.00001 <?php
00002
00006 class Vendor_Seo extends Object_Seo
00007 {
00013 public function save()
00014 {
00015 $oVendor = oxNew( 'oxbase' );
00016 $oVendor->init( 'oxvendor' );
00017 if ( $oVendor->load( $this->getEditObjectId() ) ) {
00018 $oVendor->oxvendor__oxshowsuffix = new oxField( (int) oxConfig::getParameter( 'blShowSuffix' ) );
00019 $oVendor->save();
00020 }
00021
00022 return parent::save();
00023 }
00024
00030 protected function _getEncoder()
00031 {
00032 return oxSeoEncoderVendor::getInstance();
00033 }
00034
00040 public function isSuffixSupported()
00041 {
00042 return true;
00043 }
00044
00050 public function isEntrySuffixed()
00051 {
00052 $oVendor = oxNew( 'oxvendor' );
00053 if ( $oVendor->load( $this->getEditObjectId() ) ) {
00054 return (bool) $oVendor->oxvendor__oxshowsuffix->value;
00055 }
00056 }
00057
00063 protected function _getType()
00064 {
00065 return 'oxvendor';
00066 }
00067
00073 public function getEntryUri()
00074 {
00075 $oVendor = oxNew( 'oxvendor' );
00076 if ( $oVendor->load( $this->getEditObjectId() ) ) {
00077 return $this->_getEncoder()->getVendorUri( $oVendor, $this->getEditLang() );
00078 }
00079 }
00080 }