Sigma Php Ajax framework, Ajax Components, GUI Builder
May 23, 2012, 02:19:18 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Frozen Columns with customHead  (Read 937 times)
patilniraj82
Newbie
*
Posts: 1


View Profile
« on: March 03, 2011, 02:52:14 AM »

I am Trying to create a grid with a Image in the Header and hence i am using customHead option of the Grid.
additionally i am using frozen column for first column. below is my code derived from one of the samples with Grid Release 2.4

But when it tries to render i get a message "... please wait" and in the mozilla console i am getting null on line 580 of gt_base.js

nextElement : function(n){
580 while((n = n.nextSibling) && n.nodeType != 1){}
581 return n;

   
<code>

var grid_demo_id = "myGrid1" ;
var dsOption= {

   fields :[
      {name : 'no'  },
      {name : 'country'  },
      {name : 'customer'  },
      {name : 'employee'  },
      {name : 'bill2005' ,type: 'float' },
      {name : 'bill2006' ,type: 'float' },
      {name : 'bill2007' ,type: 'float' },
      {name : 'bill2008' ,type: 'float' },
      {name : 'orderDate' ,type:'date'  }
      
   ],

   recordType : 'array',
   data : __TEST_DATA__
}

var colsOption = [
     {id: 'no' , header: "Order No" , width :60, frozen : 'true'  },
     {id: 'employee' , header: "Employee" , width :80  },
      {id: 'country' , header: "Country" , width :70  },
      {id: 'customer' , header: "Customer" , width :80  },
      {id: 'bill2005' , header: "2005" , width :60},
      {id: 'bill2006' , header: "2006" , width :60},
      {id: 'bill2007' , header: "2007" , width :60},
      {id: 'bill2008' , header: "2008" , width :60},
      {id: 'orderDate' , header: "Delivery Date" , width :100}
       
];


var gridOption={
   id : grid_demo_id,
   width: "700",  //"100%", // 700,
   height: "350",  //"100%", // 330,
   container : 'gridbox',
   replaceContainer : true,
   customHead : 'myHead',
   dataset : dsOption ,
   columns : colsOption,
   toolbarContent : 'nav',
   toolbarPosition : null
   
};




var mygrid=new Sigma.Grid( gridOption );
Sigma.Util.onLoad( Sigma.Grid.render(mygrid) );
[/glow]

//////////////////////////////////////////////////////////






</script>
</head>
<body>
 <div id="content">
      <div id="bigbox" style="margin:15px;display:!none;">
      <div id="gridbox" style="border:0px solid #cccccc;background-color:#f3f3f3;padding:5px;height:200px;width:700px;" ></div>
  </div>
<table id="myHead" style="display:none">
<tr>
   <td columnId='no'>Order No</td>
   <td columnId='employee'>Employee</td>
   <td columnId='country'>Country</td>
   <td columnId='customer'>Customer<img src="./images/customer.gif"/></td>
   <td columnId='bill2005'>2005</td>
   <td columnId='bill2006'>2006</td>
   <td columnId='bill2007'>2007</td>
   <td columnId='bill2008'>2008</td>
   <td columnId='orderDate'>Ship Date</td>
</tr>
</table>
</code>
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.7 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!