LifePress
LifePress copied to clipboard
Edit Item Permalink Issue #13
The majority of this code are updates for CI 2.1 from the original LifePress code base.
The core changes that took place in this pull request is the ability to modify the slug of a posted item. This pull request does not address the following
- Changing the fav icon location for feed
- Change the permalink image for a feed
It breaks the edit/write tool for items into 2 separate views and controller functions. There is now a separate router rule servicing requests. These changes made it possible to streamline and clean up the controller level, though there is duplicate code that should be refactored at the view level.
References #13
Logan, great work. As you mentioned there is dup code in the views, what would it take to have them both running off a single view (for easy updates In the future)?
To merge the two templates into one template you'd need to pass an instance of StdClass object for the item table into the Write view. You'd also need to show/hide portions of the templates depending on the type of page you were displaying.
To me the biggest draw back would be updating Write::index() to create the item StdClass and then assigning it all of the table columns.