The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#12
|
||||
|
||||
![]()
It is Object Oriented...until you get to the Controller delegate class. And, unfortunately, that's where most of the time is spent (at least...in my case it is, since their models are thin).
I've been basing my content type off of the article content type already out there. Some of what they've done is disturbing. There's 70 lines of code in vBCms_Content_Article: ![]() With 4.1.5, they also slightly changed how preview images are done. They're now checking to see if there is a thumbnail, and if so, to use that. Which is great, until you realize that that code is sitting smack dab in the middle of vBCms_Content_Article: ![]() There's a lack of consistency among variable naming that I found...annoying. Do you use underscores between words? Or just ram them all together? Both examples are used in the codebase. I loved how, within the article content type (preview view), they assigned the reply count to the view THREE TIMES. Surely, the last two were just to make sure it understands? When you get down to the nitty-gritty, some of the comments are also atrocious. Within the same file (vBCms_Content_Article, although, I also found similar code in the section content type) you'll find this: PHP Code:
What's worse is that this function is called in places before there's a view established. Had anyone bothered to type that variable, they'd have found that bug really quick. I'm also not 100% fond of the fact the CMS fails when I have to turn off a plugin that establishes a custom content type. It seems like they could have prevented that somehow. I'm currently working on the config screen for my review content type. I'm still trying to decide if this is really worth the trouble. While the framework shows flashes of brilliance, it also shows signs of being thrown together quickly, and when they come back through and clean it all up, I'm not sure I want to rework my stuff to fit with how they've changed. Especially since I'm really not sure when any of that is going to happen. Nor am I sure I want to kill my CMS if I ever need help from customer service. Anyway, the skeleton took roughly 6-8 hours to establish and get working. Some of that time was spent researching methods/classes within the framework. I also spent some time establishing some helper methods that will likely cut down on some of the keyboard time I'd have to spend...which leaves a lot of the work I'd spend doing on a future content type rewriting the code I think should be abstracted out. So, no. It's not tough. Especially if you've worked with MVC frameworks before. If I go through the trouble of finishing, I'm refactoring to push more of the data preparation to the model. My goal is to create a fat model (with a base model that other content types can extend), and create a controller delegate class that I can basically just configure and let run. I just find it disappointing that nobody's found time in the last 18 months to make this process better. |
Благодарность от: | ||
Alfa1 |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|