I need to send a relationship status between two users (which can has values like 'friends', 'undefined', 'ignore') from a Model into a View.
Inside a template I need to create a links and labels for each case, something like:
switch ($status) {
case 'friends': 'label' = 'Unfriend', 'link' = 'user_controller/unfriend/'.$id;
case 'undefined': 'label' = 'Add to friends', 'link' = 'user_controller/addfriend/'.$id;
...
}
So where should I do this switch - inside a Model and then return array with labels and links, or just return a string and make stuff inside a View. Which way is better?