How can I make a ResourceController ignore the show method? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: How can I make a ResourceController ignore the show method? (/showthread.php?tid=77525) |
How can I make a ResourceController ignore the show method? - blaasvaer - 09-11-2020 Hi, I don't like the 'show' method of the ResourceController – it seems redundant. I'd rather have my index show all or one based on whether a parameter is passed in or not. That's maybe just me. But how can I make this possible without getting into a HUGE fight with 'the way' CI 4 have chosen to handle this? I'd basically like to avoid this: Code: error "\"show\" action not implemented." Is this possible or should I go back to just using a 'normal' controller and write it all myself, instead of ending up 'fighting' the framework? I guess 'a lot' of decisions have been made in designing the resourcecontroller ... but if 'overriding' was part of it I don't know. Any ideas? RE: How can I make a ResourceController ignore the show method? - tgix - 09-12-2020 https://codeigniter4.github.io/userguide/incoming/restful.html#limit-the-routes-made ? |