You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

195 lines
6.7 KiB
Plaintext

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>搜索的多选</title>
<link href="../../../Scripts/easyUI145/themes/default/easyui.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../../../Scripts/bootstrap/js/jquery.min.js"></script>
<script src="../../../Scripts/QueryString.js" type="text/javascript"></script>
<script src="../../../Scripts/config.js" type="text/javascript"></script>
<script src="../../../Comm/Gener.js" type="text/javascript"></script>
<link href="../../../../DataUser/Style/ccbpm.css" rel="stylesheet" type="text/css" />
<base target="_self" />
<script type="text/javascript">
//页面启动函数.
$(function () {
//组织主键.
var mypk = "MultipleInputSearch_" + GetQueryString("FK_MapData") + "_" + GetQueryString("KeyOfEn");
var en = new Entity("BP.Sys.MapExt");
en.MyPK = mypk;
var i = en.RetrieveFromDBSources();
GenerFullAllCtrlsVal(en);
if (i == 0)
$("#Btn_Delete").attr("disabled", true);
else
$("#Btn_Delete").removeAttr("disabled");
//去掉 ' 号。
var tag = en.Doc;
while (tag.indexOf('~') > 1) {
tag = tag.replace("~", "'");
}
//按照文本计算.
$("#TB_Doc").val(tag);
});
//执行保存
function Save() {
//组织主键.
var mypk = "MultipleInputSearch_" + GetQueryString("FK_MapData") + "_" + GetQueryString("KeyOfEn");
var en = new Entity("BP.Sys.MapExt");
en.MyPK = mypk;
en.RetrieveFromDBSources();
en.CopyForm(); //复制表单数据.
en.FK_MapData = GetQueryString("FK_MapData");
en.AttrOfOper = GetQueryString("KeyOfEn");
en.ExtType = "MultipleInputSearch";
en.MyPK = mypk;
if (en.Update() == 0)
en.Insert();
SetHref( "MultipleInputSearch.htm?FK_MapData=" + GetQueryString("FK_MapData") + "&KeyOfEn=" + GetQueryString("KeyOfEn") + "&M=" + Math.random());
return;
}
//删除.
function Delete() {
if (window.confirm('您确定要删除吗?') == false)
return;
var mypk = "MultipleInputSearch_" + GetQueryString("FK_MapData") + "_" + GetQueryString("KeyOfEn");
var en = new Entity("BP.Sys.MapExt");
en.MyPK = mypk;
en.RetrieveFromDBSources();
var i = en.Delete();
var url = "MultipleInputSearch.htm?FK_MapData=" + GetQueryString("FK_MapData") + "&KeyOfEn=" + GetQueryString("KeyOfEn") + "&M=" + Math.random();
SetHref(url);
}
</script>
<style>
.table a {
color: #1c60be
}
.table ul {
padding: 10px 0px;
}
.table li {
list-style-type: none;
line-height: 26px;
}
</style>
</head>
<body>
<div class="container-full">
<div class="attrnode-bar-header">
<span class="pull-right">
<input type="button" value="保存" id="Btn_Save" class="cc-btn-tab" onclick="Save()" />
<input type="button" value="删除" id="Btn_Delete" class="cc-btn-tab" onclick="Delete()" />
<input type="button" value="帮助" id="Btn_Help" class="cc-btn-tab" onclick="ShowHidden('help')" />
</span>
<strong> 文本框搜索输入多选</strong>
</div>
<form id="cc">
<table class="table">
<tr>
<td>数据源类型 </td>
<td>
<select id="DDL_DBType" name="DDL_DBType">
<option value="0">执行SQL</option>
<option value="1">执行url返回JSON</option>
<option value="2">执行CCFromRef.js返回JSON</option>
</select>
</td>
</tr>
<tr>
<td>
<a href="javascript:ShowHidden('SearchTip')">搜索提示</a>
<div id="SearchTip" style="color:Gray; display:none">
<ul>
<li>显示在搜索文本框的背景文字.</li>
<li>输入城市名称,比如:beijing,bj,进行搜索.</li>
<li>人员的编号,名称,拼音,进行模糊搜索.</li>
</ul>
</div>
</td>
<td><input type="text" id="TBPara_SearchTip" name="TBPara_SearchTip" style="width:90%;" /> </td>
</tr>
<tr>
<td>
是否显示签名
</td>
<td> <label> <input type="checkbox" id="CB_Tag" name="CB_Tag" />是否显示签名</label></td>
</tr>
<tr>
<td colspan="2">搜索数据源</td>
</tr>
<tr>
<td colspan=2>
<textarea rows="3" id="TB_Doc" name="TB_Doc" style="width:90%;" ></textarea>
</td>
</tr>
<tr>
<td colspan="2">列表数据源</td>
</tr>
<tr>
<td colspan=2>
<textarea rows="3" id="TB_Tag1" name="TB_Tag1" style="width:90%;" ></textarea>
</td>
</tr>
</table>
<div id="help" style="color:Gray; display:none">
<ul>
<li>SQL格式为:</li>
<li>SELECT No,Name FROM Port_Emp WHERE PinYin LIKE '@Key%' OR No LIKE '%@Key%' OR Name LIKE '%@Key%' </li>
<li>SELECT No,Name FROM CN_City WHERE PinYin LIKE '%@Key%' OR Name LIKE '%@Key%'</li>
<li>URL格式为:</li>
<li>/DataUser/Handler.ashx?xxx=sss </li>
<li>方法的格式为:</li>
<li>MyFunName</li>
</ul>
</div>
<div class="cs-content-box">
<fieldset>
<legend>运行效果</legend>
<a href="javascript:WinOpen('MultipleInputSearch.png');"> <img src="MultipleInputSearch.png" /> </a>
</fieldset>
</div>
</form>
</div>
</body>
</html>