5093 Posts in 1516 Topics by 1113 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 878 Views |
-
Basic CMS Customization Question

22 January 2010 at 11:05am
Hi all,
I've been trying to get this working to no avail, but basically what I'm wanting to do is this:
This is the basic data-model surrounding my question
class Ticket extends DataObject {
static $has_many = array(
'Messages' => 'Message'
);
}I'm trying to figure out how to get a custom CMS page working that allows me to see a list of Tickets, then click on a ticket, and in TicketAdmin_right.ss, show the Messages for that ticket, along with a form to add a new message.
What I have so far is TicketAdmin.php, TicketAdmin_left and _right template files, and a method for Show in my controller that allows for /admin/ticket/show/$ID (and just returns the ID).
In my TicketAdmin_right.ss template, I have the code for the list of tickets. Something like:
<% if Tickets %>
<ul>
<% control Tickets %>
<li><a href="admin/ticket/show/$ID">$Subject</a></li>
<% end_control %>
</ul>
<% end_if %>When I go that URL though, it doesn't render in my TicketAdmin_right template, it just renders on a blank page. What template do I need to create to have it show up in the nicely formatted _right.ss template? I'm trying to accomplish something similar to the attached image when I click on a particular ticket
-
Re: Basic CMS Customization Question

22 January 2010 at 7:23pm
You might able to use ModelAdmin it isn't very easy to create CMS modules from my experience
| 878 Views | ||
|
Page:
1
|
Go to Top |


