By Alexandre Cayer on Friday, 23 October 2015
Posted in General Issues
Replies 8
Likes 0
Views 694
Votes 0
Hi Guys,

Could you add:

$id= isset($options[ 'id' ]) ? $options[ 'id' ] : '';
if ($id) {
$sql->where('a.id', $id);
}

to

com_easysocial/models/groupcategories.php
public function getCategories($options = array())

seems no id filter was never added... just a little copy n paste

Thanks
Hello Alexandre,

I'm sorry but we choose not to add it there because that function is to retrieve a list of group categories. If you want to load only one group category based on the given id, you can directly use this:


$category = FD::table('ClusterCategory');
$category->load($id);


Hope this helps.
·
Friday, 23 October 2015 15:23
·
0 Likes
·
0 Votes
·
0 Comments
·
Nik,

I try to change it to what you provided me and when i var_dump the value ... it gives me bool(true)... are you sure about this one

here are the two:
		$catModel = FD::model('GroupCategories');
$categories = $db1->loadObjectList();
//$catT = FD::table('ClusterCategory');

$a.='
<div class="es-create-category-select">
<div class="btn-group" data-bs-toggle="radio-buttons">';

$switch=false;
// display services items
foreach($categories as $category){
// check region
if ( strpos(".". $category->region_id ,JRequest::getVar('region')) > 0) {
$b = $catModel->getCategories(array('id' => $category->esgroup_id, 'state' => SOCIAL_STATE_PUBLISHED, 'ordering' => 'ordering'));
//$b = $catT->load($category->esgroup_id); var_dump($b);die;
·
Wednesday, 28 October 2015 12:48
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Alexandre,

You should var_dump the $catT instead. Please give it a try.


$catT->load($category->esgroup_id);
var_dump($catT);die;
·
Wednesday, 28 October 2015 13:23
·
0 Likes
·
0 Votes
·
0 Comments
·
ohhh welll... not enough beer I suppose.
While i got you, as a last question, I did try a quick template override of com_easysocial/themes/wireframe/groups/create.php in
templatess/ja_wall/html/com_easysocial/groups/create.php

without succes... might be a stupid thing again i suppose
·
Wednesday, 28 October 2015 13:44
·
0 Likes
·
0 Votes
·
0 Comments
·
thanks nik btw, dump moment sometimes...
·
Wednesday, 28 October 2015 13:45
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Alexandre,

You're welcome. For the template override, are you sure it's in the correct folder? I've tried to replicate it locally and the override is working. Perhaps, you can provide us your backend and FTP so we can have a better look on it?
·
Wednesday, 28 October 2015 13:51
·
0 Likes
·
0 Votes
·
0 Comments
·
there you go, i pasted info... at least on this one I wasn't that crazzzy i might have one idea (i change ROUTER LANGUAGE TOKEN) but i don't think it was working before...
·
Wednesday, 28 October 2015 13:54
·
0 Likes
·
0 Votes
·
0 Comments
·
Hello Alexandre,

The template override will follow the override folder in your default template which is the ja_directory. Please try add the template override in that template folder instead.
·
Wednesday, 28 October 2015 14:14
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post