J1.5 talk

Developing a MVC Component/Adding Backend Actions

From Joomla! Documentation

Revision as of 06:18, 27 September 2009 by M.A.S.H (talk | contribs)
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Component tutorial - strange behaviour[edit]

Thanks for the documentation.

Was not sure where to bring up questions about if the actual component itself has an error in it or not. I have started a topic in the forum [1]

Step 6 is very difficult to follow[edit]

In the last 3 days i've gone through the tutorial from the start. I've been doing website development for a while (2 years) but am new to both Joomla and the MVC pattern. I hand coded everything into my IDE (netbeans) after reading through the article (I'd skim read through once, then go back and try and create the component) steps 1-3 are very simple and easy to follow.

So when I got stuck I went to compare my component with the zipped one supplied... uh huh... they were/are totally different?

Where did the admin 'controllers' folder come from?
Why is there only 1 controller file in the admin 'controllers' folder this seems redundant and unexplained - surely you only need a folder for controllers if multiple controllers are required? Doing this to the hello example seems to be complicating things unnessecarily.

Having re-read this step several times I don't think it's mentioned in 'Getting Down and Dirty: Doing the Real Work' you should have created the folder 'controllers' in /administrator/components/com_hello/admin (if it is it's certainly not obvious).

Step 4 begins to get complex and I think maybe where the root of my trouble with step 6 is (I think it would benefit hugely from the suggestions in: http://docs.joomla.org/Talk:Developing_a_Model-View-Controller_Component_-_Part_4_-_Creating_an_Administrator_Interface#Renaming_Part_4 ).

Step 6 doesn't give enough information about where the new admin files should be created and how they'd be named, it seems to supply source code with too little consideration to context in terms of filepaths. It would probably benefit to being broken down again into smaller parts.

I'll try and actually make recommendations about this in the next week or so (i'm at work at the moment so i'll try and do this from home).

Developing a Model-View-Controller Component - Part 4 - Creating an Administrator Interface

--M.A.S.H 11:18, 27 September 2009 (UTC)