I explain my problem:
in one page, called ricerche.php, I define this code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="it" xmlns="http://www.w3.org/1999/xhtml" xml:lang="it">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="js/jeasy/themes/bootstrap/easyui.css">
<link rel="stylesheet" type="text/css" href="css/mainNew.css">
<!--<link rel="stylesheet" type="text/css" href="js/jeasy/prettify/prettify.css">-->
<link rel="stylesheet" type="text/css" href="js/jeasy/themes/icon.css">
<script type="text/javascript" src="js/jeasy/jquery-1.8.0.min.js"></script>
<script type="text/javascript" src="js/jeasy/jquery.easyui.min.js"></script>
<!--<script type="text/javascript" src="js/jeasy/prettify/prettify.js"></script>-->
<script type="text/javascript" src="js/jeasy/plugins/jquery.datagrid.js"></script>
<script type="text/javascript" src="js/jeasy/plugins/datagrid/datagrid-detailview.js"></script>
<script type="text/javascript">
function open1(plugin,title_tab){
if ($('#tt').tabs('exists',title_tab)){
$('#tt').tabs('select', title_tab);
} else {
$('#tt').tabs('add',{
title:title_tab,
cache:true,
href:plugin+'.php',
closable:true,
extractor:function(data){
data = $.fn.panel.defaults.extractor(data);
var tmp = $('<div></div>').html(data);
data = tmp.find('#content').html();
tmp.remove();
return data;
}
});
}
}
</script>
<title>Gestione dati genetici laboratorio FSC - Ricerche statistiche </title>
</head>
<body class="easyui-layout" style="text-align:left">
<div region="north" border="false" style="background:#486;text-align:center">
<?php include("layout/menu/top_menu.php") ?>
</div>
<div region="west" border="false" split="true" title="Attività" style="width:300px;padding:5px;"
data-options=" collapsible:true,
onCollapse:function(){
$('#dg').datagrid('resize','auto');
}
">
<ul class="easyui-tree">
<li iconCls="icon-base"><span>Ricerche</span>
<ul>
<li iconCls="icon-gears"><a href="#" onclick="open1('visualizza_polimorfismi','Polimorfismi')">Info polimorfismi</a></li>
<li iconCls="icon-gears"><a href="#" onclick="open1('visualizza_gene','gene')">Info gene</a></li>
</ul>
</li>
<li iconCls="icon-base"><span>Statistiche</span>
<ul>
<li iconCls="icon-gears"><a href="#" onclick="open1('visualizza_info_genotipi')">Dati genetici e statistiche</a></li>
</ul>
</li>
</ul>
</div>
<div region="center" border="false">
<div id="tt" class="easyui-tabs" fit="true" border="false" plain="true">
<div title="Ricerche - Help">
<div id="box">
<p>Pagina di spiegazioni per la ricerca di dati </p>
</div>
</div>
</div>
</div>
</body>
</html>
The page for 'visualizza_polimorfismi' is
<script type="text/javascript" language="javascript">
$(function(){
$('#snps').datagrid({
view: detailview,
detailFormatter:function(index,row){
return '<div style="padding:2px"><table id="ddv-' + index + '"></table></div>';
},
onExpandRow: function(index,row){
$('#ddv-'+index).datagrid({
url:'controller/subgrid_gene.php?id_RS='+row.id_RS,
fitColumns:true,
singleSelect:true,
rownumbers:true,
loadMsg:'',
height:'auto',
columns:[[
{field:'entrez_gene_id',title:'Entrez gene id',width:'100'},
{field:'official_gene_name',title:'official gene name',width:'150'},
{field:'alias',title:'alias',width:'150'},
{field:'chromosome',title:'chromosome',width:'80'},
{field:'gene_position_start',title:'gene position start',width:'150'},
{field:'gene_position_end',title:'gene position end',width:'150'},
{field:'gene_orientation',title:'gene orientation',width:'100'},
{field:'type_of_gene',title:'type of gene',width:'150'} ,
{field:'NM_transcription',title:'NM transcription',width:'100'}
]],
onResize:function(){
$('#snps').datagrid('fixDetailRowHeight',index);
},
onLoadSuccess:function(){
setTimeout(function(){
$('#snps').datagrid('fixDetailRowHeight',index);
},0);
}
});
$('#snps').datagrid('fixDetailRowHeight',index);
}
});
});
function doSearch(value,name){
$('#snps').datagrid('load',{
type_of_find:name,
type_of_value:value
});
}
</script>
<div id="content">
<div id="content-container">
<div id="box"> <!-- secondo box: per la prima tabella e sua visualizzazione-->
<h3>Elenco SNPs</h3>
<div class="inside">
<div class="table">
<table id="snps" title="Snps" class="easyui-datagrid" style="width:auto;height:auto"
url="controller/enumerate_snps.php" toolbar="#toolbar" iconCls="icon-search"
pagination="true"
singleSelect="true" >
<thead frozen="true">
<tr>
<th field="id_RS" width="auto" sortable="true" >id_RS</th>
<th field="snp_name_lab" width="auto" sortable="true" >snp name lab</th>
</thead>
<thead>
<tr>
<th field="update_date" width="auto">Update date</th>
<th field="chromosome" width="auto" sortable="true" >Chromosome</th>
<th field="chr_position" width="auto" sortable="true">chr position</th>
<th field="RefSNP_alleles" width="auto" align="center">RefSNP alleles</th>
<th field="dbsnp_build" width="auto" >dbsnp build</th>
<th field="note" width="auto" >note</th>
<th field="allele1" width="auto" align="center" >allele1</th>
<th field="allele2" width="auto" align="center">allele2</th>
<th field="Note_for_genotype_input" width="auto" >Note for genotype input</th>
<th field="Location_or_Amminoacid_change" width="auto" >Location or Amminoacid change</th>
<th field="Sequenza_context" width="auto" >Sequenza context</th>
</tr>
</thead>
</table>
<div id="toolbar">
<input class="easyui-searchbox" data-options="prompt:'Please Input Value',menu:'#search_snp',searcher:doSearch" style="width:300px;height:25px"></input>
<div id="search_snp" style="width:120px">
<div data-options="name:'id_RS_to_find',iconCls:'icon-ok'">id_RS</div>
<div data-options="name:'snp_name_lab_to_find'">Snp name lab</div>
</div>
</div>
</div>
</div>
</div>
</div><!-- /content container-->
</div> <!-- /content -->
The same are for the page 'gene'.
I attached the result:
1. the detailview not work .. Strange I defined it on ricerche.php
2. the searchbox in 'visualizza_polimorfismi' disappears during I call 'gene' page
At the moment I'm using the version 1.3.4
Where I wrong?