Webylon 3.1 API Docs
  • Package
  • Class
  • Tree
  • Deprecated
  • Download
Version: current
  • 3.2
  • 3.1

Packages

  • auth
  • Booking
  • cart
    • shipping
    • steppedcheckout
  • Catalog
  • cms
    • assets
    • batchaction
    • batchactions
    • bulkloading
    • comments
    • content
    • core
    • export
    • newsletter
    • publishers
    • reports
    • security
    • tasks
  • Dashboard
  • DataObjectManager
  • event
  • faq
  • forms
    • actions
    • core
    • fields-basic
    • fields-dataless
    • fields-datetime
    • fields-files
    • fields-formatted
    • fields-formattedinput
    • fields-relational
    • fields-structural
    • transformations
    • validators
  • googlesitemaps
  • guestbook
  • installer
  • newsletter
  • None
  • photo
    • gallery
  • PHP
  • polls
  • recaptcha
  • sapphire
    • api
    • bulkloading
    • control
    • core
    • cron
    • dev
    • email
    • fields-formattedinput
    • filesystem
    • formatters
    • forms
    • i18n
    • integration
    • misc
    • model
    • parsers
    • search
    • security
    • tasks
    • testing
    • tools
    • validation
    • view
    • widgets
  • seo
    • open
      • graph
  • sfDateTimePlugin
  • spamprotection
  • stealth
    • captha
  • subsites
  • userform
    • pagetypes
  • userforms
  • webylon
  • widgets

Classes

  • BaseObjectCategory
  • BookingAdminPage
  • BookingPage
  • ErrorPage
  • ErrorPage_Controller
  • MediawebPage
  • Notifications
  • Page
  • Room
  • RoomCatalog
  • SiteConfig
  • SiteTree
  • SubsitesSelectorPage
  • SubsitesVirtualPage
  • SubsitesVirtualPage_Controller
  • VideoBankPage
  • VirtualPage
  • VirtualPage_Controller
  • VirtualProduct_Controller

Interfaces

  • HiddenClass
 1 <?php
 2 /*
 3  * Раздел "Номерной фонд". Может содержать как вложенные разделы (RoomCatalog), так и номера (Room) 
 4  * 
 5  * @author menedem
 6  */
 7 class RoomCatalog extends MediawebPage {
 8     static $allowed_children = array('Room', 'RoomCatalog', 'BookingPage'); 
 9     static $default_parent = 'RoomCatalog';
10     
11     static $has_one = array(
12         'Icon' => 'Image'
13     );
14     
15     function getCMSFields() {
16         $fields = parent::getCMSFields();
17         $fields->addFieldToTab('Root.Content.Main', new ImageField('Icon', $this->fieldLabel('Icon')), 'Content');
18         $fields->removeByName('CoverImageID');
19         return $fields;
20     }
21 
22     /**
23      * Возвращает список подрубрик
24      *
25      * @return DataObjectSet
26      */
27     public function Subcats() {
28         return DataObject::get("RoomCatalog", "ParentID = {$this->ID} AND ShowInMenus=1");
29     }
30 
31     public function Rooms() {
32         return DataObject::get("Room", "ParentID = {$this->ID}");
33     }
34 
35 }
36 
37 class RoomCatalog_Controller extends MediawebPage_Controller {
38     
39 }
40 
[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the Silverstripe Forums to ask development related questions. -
Webylon 3.1 API Docs API documentation generated by ApiGen 2.8.0