function load_QuotationfranchiseeNon(bj_tms_id){
$.ajax({
type: "POST",
dataType: "json",
async: true,
url: "/webservice/tools/systemconfig/sysCustomer.ashx?action=load_QuotationfranchiseeNon",
data: {
bj_tms_id: $('#bj_tms_id').val()
},
success: function (data, textStatus) {
$("#QuotationfranchiseeNonTable .appendTR").html('');
if (data.status == 1) {
var json = eval(data.data);
if (json.length <= 0) {
var RespHtml = "";
RespHtml += " <tbody class='appendTR'>";
RespHtml += " <tr class='trId'>";
RespHtml += " <td colspan='4' style='color:red;text-align:center'>" + "没有找到您要的相关数据! " + "</td>";
RespHtml += " </tr>";
RespHtml += "</tbody>";
$("#PushEndTable").append(RespHtml);
};
if (json.length > 0) {
var RespHtml = "";
RespHtml += " <tbody class='appendTR'>";
$.each(json, function (index, item) {
RespHtml += " <tr class='trId'>";
RespHtml += " <td>" + (index + 1) + "</td>";
RespHtml += " <td>" + item.tms_code + "</td>";
RespHtml += " <td>" + item.tms_name + "</td>";
RespHtml += " <td>" + "<a href='#' class='btn btn-outline btn-circle btn-sm blue' onclick='InsertQuotationformation(" + item.tms_id + ")'>" + "推送 " + "</a>" + "</td>";
RespHtml += " </tr>";
});
RespHtml += "</tbody>";
$("#QuotationfranchiseeNonTable").append(RespHtml);
}
}
else {
top.toastr.error(data.message);
}
},
error: function (XMLHttpRequest, textStatus, errorThrown) {
top.toastr.error(textStatus + ":" + errorThrown);
}
});
}
搜索
function txtQuotationfranchiseeNonTable() {
var str = $.trim($("#txtQuotationCINon").val()).toUpperCase();
if (IsVaild(str)) {
$("#QuotationfranchiseeNonTable tbody tr").each(function () {
var has = $(this).find("td:nth-child(2)").text().indexOf(str) >= 0 || $(this).find("td:nth-child(3)").text().indexOf(str) >= 0;
if (has) $(this).removeClass("hide");
else $(this).addClass("hide");
});
} else {
$("#QuotationfranchiseeNonTable tbody tr").each(function () {
$(this).removeClass("hide");
});
}
}
<!-- 报价加盟商公司信息 -->
<div class="modal fade" id="Quotationfranchisee" tabindex="-1" role="dialog" aria-labelledby="ChannelInformationModalLabel" aria-hidden="true">
<div class="modal-dialog modal-md">
<input type="hidden" id="bj_tms_id" />
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
×
</button>
<h4 class="modal-title" id="ChannelInformationModalLabel">渠道报价限制</h4>
</div>
<div class="modal-body">
<div class="row com-row">
<div class="col-md-6 " id="leftdiv_1">
<div class="portlet light bordered">
<div class="portlet-body">
<div class="com-title">
<span>可添加的加盟商</span>
<a style="float:right" onclick='Insertall()' href='#' class='btn btn-outline btn-circle btn-sm blue'>一键推送</a>
</div>
<div class="com-title">
<input id="txtQuotationCINon" type="text" placeholder="输入代码或名称查询..." class="form-control" onkeyup="txtQuotationfranchiseeNonTable()" />
</div>
<div class="common-table table-scrollable">
<table id="QuotationfranchiseeNonTable" class="table table-striped table-bordered table-advance table-hover">
<thead>
<tr>
<th style="width: 4%; text-align: center;">序号 </th>
<th style="text-align: center;">加盟商代码 </th>
<th style="text-align: center;">加盟商名称 </th>
<th style="width: 25%;">操作</th>
</tr>
</thead>
</table>
</div>
</div>
</div>
</div>
<div class="col-md-6" id="rightdiv_2">
<div class="portlet light bordered user-tab-list">
<div class="com-title">
<span>已添加的加盟商</span>
<a style="float:right" onclick='Deleteall()' href='#' class='btn btn-outline btn-circle btn-sm blue'>一键移除</a>
</div>
<div class="com-title">
<input id="txtQuotationCIEnd" type="text" placeholder="输入代码或名称查询..." class="form-control" onkeyup="txtQuotationfranchiseeEndTable()" />
</div>
<div class="common-table table-scrollable">
<table id="QuotationfranchiseeEndTable" class="table table-striped table-bordered table-advance table-hover">
<thead>
<tr style="text-align: center;">
<th style="width: 4%; text-align: center;">序号 </th>
<th style="text-align: center;">加盟商代码 </th>
<th style="text-align: center;">加盟商名称 </th>
<th style="width: 25%;">操作</th>
</tr>
</thead>
</table>
</div>
</div>
</div>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn" data-dismiss="modal">关 闭</button>
</div>
</div>
</div>
</div>