I think I have uploaded module and installed properly onto an SS3.0.3 site.
But I can use or edit my site tree under the "pages" section at all after install. I can edit the dataobject, as data objects strangely.
here is my dataobject:
<?php
class Project extends DataObjectAsPage {
static $db = array(
'Name' => 'Text',
'Description' => 'Text'
);
//The class of the page which will list this DataObject
static $listing_class = 'ProjectHolderPage';
//Class Naming (optional but reccomended)
static $plural_name = 'Projects';
static $singular_name = 'Project';
<?php
class ProjectHolderPage extends DataObjectAsPageHolder {
}
class ProjectHolderPage_Controller extends DataObjectAsPageHolder_Controller {
//This needs to know be the Class of the DataObject you want this page to list
static $item_class = 'Project';
//Set the sort for the items (defaults to Created DESC)
static $item_sort = 'Title ASC';
}
And here is my model admin:
<?php
class Project2Admin extends DataObjectAsPageAdmin {
public static $managed_models = array('Project'); // Can manage multiple models
static $url_segment = 'Projects2'; // Linked as /admin/products/
static $menu_title = 'Project Admin';
}
Any help on what Ive messed up?
Here are some of the error messages from the console:
I think I have uploaded module and installed properly onto an SS3.0.3 site.
But I can use or edit my site tree under the "pages" section at all after install. I can edit the dataobject, as data objects strangely.
here is my dataobject: <?php
class Project extends DataObjectAsPage { static $db = array( 'Name' => 'Text', 'Description' => 'Text' ); //The class of the page which will list this DataObject static $listing_class = 'ProjectHolderPage'; //Class Naming (optional but reccomended) static $plural_name = 'Projects'; static $singular_name = 'Project';
}
here is my listing page:
<?php class ProjectHolderPage extends DataObjectAsPageHolder {
} class ProjectHolderPage_Controller extends DataObjectAsPageHolder_Controller {
}
And here is my model admin:
<?php
class Project2Admin extends DataObjectAsPageAdmin { public static $managed_models = array('Project'); // Can manage multiple models static $url_segment = 'Projects2'; // Linked as /admin/products/ static $menu_title = 'Project Admin'; }
Any help on what Ive messed up?
Here are some of the error messages from the console:
GET http://www.berzerk.co.nz/admin/pages/listview 500 (Error at line 675 of /var/www/vhosts/berzerkdev.com/berzerk/framework/core/Object.php) jquery.js:8240 XHR finished loading: "http://www.berzerk.co.nz/admin/pages/listview". jquery.js:8240 GET http://www.berzerk.co.nz/admin/pages/treeview 500 (Error at line 675 of /var/www/vhosts/berzerkdev.com/berzerk/framework/core/Object.php) jquery.js:8240 XHR finished loading: "http://www.berzerk.co.nz/admin/pages/treeview". jquery.js:8240