产品使用及交流论坛

注册

 

QQ登录

只需一步,快速开始

发新话题 回复该主题

请问xiyou老大:搜索模型问题 [复制链接]

1#
调用文件内容:
<script type='text/javascript' src='/e/js/calendar.js'></script>
<form action="/e/search/" method="get" target="zdy_search" name="S_gzrzdj">
    分类:<select id="sortid" name="sortid">
    <option value="0">所有类别</option>
    <option value="643" selected="selected">|-工作日志登记</option>
    </select><br />
    发布日期:<input id="thedate_min" maxlength="10" name="thedate_min" type="text" /><a href="javascriptpen_calendar('thedate_min')"><img height="20" alt="" hspace="2" align="absBottom" border="0" src="/e/images/public/date.gif" /></a> 至 <input id="thedate_max" maxlength="10" name="thedate_max" type="text" /><a href="javascriptpen_calendar('thedate_max')"><img height="20" alt="" hspace="2" align="absBottom" border="0" src="/e/images/public/date.gif" /></a><br />
    排序:<select id="order" name="order">
    <option value="pa_gzlx2 desc" selected="selected">按系统类别&uarr;</option>
    <option value="pa_gzlx2">按系统类别&darr;</option>
    </select> <br />
    每页显示数:<input maxlength="9" size="5" name="pagesize" value="20" type="text" /><br />
    <!--以上html代码可根据需要删除和修改--><input type="hidden" name="modelid" value="215" /><input type="hidden" name="siteid" value="1" /><input class="bt" type="submit" value=" 生成 " />
</form>


被调用文件内容:
<%
Sql_Condition=Sql_condition+"and pa_gzlx='运行维护工作' and pa_gzlx1='故障处理方面'";


DataTable dt=Get_Data();
DataRow dr;
for(int i=0;i<dt.Rows.Count;i++)
{
  dr=dt.Rows[i]; //说明:给dr赋值

%>

<%=i+1%>、<%=dr["pa_gzlx2"].ToString()%><%=((DateTime)dr["thedate"]).ToString("yyyy-MM-dd")%>:
<%=Server.HtmlEncode(dr["pa_gzrz"].ToString())%>。
<%=Server.HtmlEncode(dr["pa_clnr"].ToString())%><br>


<%
}
%>
[b]问题:查询结果未按日期截取数据。[/b]
分享 转发
TOP
发新话题 回复该主题