AnsweredAssumed Answered

How do you change the number of columns on the homepage in CE?

Question asked by Arvo Bowen on Jul 1, 2014
Latest reply on Jul 4, 2014 by deasy deasy
I just deployed a new copy of Sugar because of a script that has hosed my install.  Now I'm trying to recreate all the little changes I made to Sugar for the 2 months I had it running.  On my initial install I had managed to change the number of columns on the homepage from 2 (two) to 1 (one).  I can't remember exactly what file I edited before but I could tell you if I edited a certain file (if I was asked) because I have a backup of the old install.

Currently the only thing I can do is the following, though I do NOT consider this a fix!  It also leaves a huge gap on the right side and ends up wasting a ton of real estate!  So I'm looking for another way...  Or a patch to make this way actually work as expected (full width used, not 85%).
Anyway here is what I currently do...
- Edit "/modules/Home/index.php" : Change the % (width) of the columns 0 and 1 in the array.

Before:
      }     }
     $count = 0;
     $columns = array();
     $columns[0] = array();
     $columns[0]['width'] = '60%';
     $columns[0]['dashlets'] = array();
     $columns[1] = array();
     $columns[1]['width'] = '40%';
     $columns[1]['dashlets'] = array();
     foreach($dashlets as $guid=>$dashlet) {
         if( $dashlet['forceColumn'] == 0 ) array_push($columns[0]['dashlets'], $guid);
         else array_push($columns[1]['dashlets'], $guid);
         $count++;
     }
}



After:
    }     }
   $count = 0;
   $columns = array();
   $columns[0] = array();
   $columns[0]['width'] = '100%';
   $columns[0]['dashlets'] = array();
   $columns[1] = array();
   $columns[1]['width'] = '0%';
   $columns[1]['dashlets'] = array();
   foreach($dashlets as $guid=>$dashlet) {
       if( $dashlet['forceColumn'] == 0 ) array_push($columns[0]['dashlets'], $guid);
       else array_push($columns[1]['dashlets'], $guid);
       $count++;
   }
}
             


Outcomes