工作总结 2018-4-13 bootstrapTable 属性 queryParams: queryParams,//参数 get 中 %5B%5D 数组的意思
<table id="dataTable" data-toggle="table" data-show-columns="true" data-mobile-responsive="true"></table>
function getTab() {
$('#dataTable').bootstrapTable({
method: 'get', //这里要设置为get,不知道为什么 设置post获取不了
url: '/AtmAtm/GetCodeList',
cache: false,
striped: true,
pagination: true,
pageList: [10, 30, 50, 100],
pageSize: 10,
pageNumber: 1,
search: true,
sidePagination: 'server',//设置为服务器端分页
queryParams: queryParams,//参数
showColumns: true,
showRefresh: true,
minimumCountColumns: 2,
clickToSelect: true,
smartDisplay: true,
columns: [{
checkbox: 'true',
title: '@LangResources.Resource.Info_SelectList'
},
{
field: 'AtmCode',
title: '@LangResources.Resource.BarCode',
align: 'center',
width: '120',
valign: 'center',
sortable: true
}, {
field: 'AtmNo',
title: '@LangResources.Resource.AtmNo',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
//formatter: operateFormatter
}
, {
field: 'TerminalNum',
title: '@LangResources.Resource.TerminalNum',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
//formatter: operateFormatter
}
, {
field: 'ManufacturerObj',
title: '@LangResources.Resource.ProducerName',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
//formatter: operateFormatter
}
, {
field: 'atmname',
title: '@LangResources.Resource.Info_JiJuMingCheng',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
},
{
field: 'AtmTypeName',
title: '@LangResources.Resource.AtmTypeName',
align: 'center',
width: '150',
valign: 'center',
sortable: true,
//formatter: operateFormatter
},
{
field: 'CustomerName',
title: '@LangResources.Resource.CustomerName',
align: 'center',
width: '40',
valign: 'center',
sortable: true,
//formatter: operateFormatter
}, {
field: 'Menu_CityRegion',
title: '@LangResources.Resource.Menu_CityRegion',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
//formatter: operateFormatter
}, {
field: 'BlockName',
title: '@LangResources.Resource.BlockName',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
//formatter: operateFormatter
}, {
field: 'StreetName',
title: '@LangResources.Resource.StreetName',
align: 'center',
width: '40',
valign: 'center',
sortable: true,
//formatter: operateFormatter
},
@*{
field: 'AtmStatus',
title: '@LangResources.Resource.AtmStatus',
align: 'center',
width: '40',
valign: 'center',
sortable: true,
//formatter: operateFormatter
},*@
{
field: 'JobType',
title: '@LangResources.Resource.JobType',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
formatter: CodeFormatter
},
{
field: 'RevertPosition',
title: '@LangResources.Resource.RevertPosition',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
},
{
field: 'BillAddress',
title: '@LangResources.Resource.BillAddress',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
},
{
field: 'provinceobj',
title: '@LangResources.Resource.province',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
},
{
field: 'Districtobj',
title: '@LangResources.Resource.District',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
},
{
field: 'DPSBinobj',
title: '@LangResources.Resource.dpsbin',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
},
{
field: 'PasswordLimit',
title: '@LangResources.Resource.PasswordLimit',
align: 'center',
width: '60',
valign: 'center',
sortable: true,
},
{
field: 'Address',
title: '@LangResources.Resource.Address',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
},
{
field: 'IsAt',
title: '@LangResources.Resource.IsAt',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
},
{
field: 'EndMDate',
title: '@LangResources.Resource.EndMDate',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
},
{
field: 'AtmSetupType',
title: '@LangResources.Resource.AtmSetupType',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
}, {
field: 'IsNon',
title: 'nodv',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
},
{
field: 'Remark',
title: '@LangResources.Resource.Remark',
align: 'center',
width: '100',
valign: 'center',
sortable: true,
}, {
field: 'StartMDates',
title: '@LangResources.Resource.StartMDates',
align: 'center',
width: '80',
valign: 'center',
sortable: true,
formatter: dateFormatter
},
{
field: 'Id',
title: '@LangResources.Resource.Operation',
align: 'center',
width: '250',
valign: 'top',
sortable: true,
formatter: EditeOpt
}
], onLoadSuccess: function () {
},
onLoadError: function () {
//mif.showErrorMessageBox("数据加载失败!");
}
});
$('#dataTable').bootstrapTable('hideColumn', 'Address');
}
//设置传入参数
function queryParams(params) {
debugger
console.info(params);
var CustomerType = $("#CustomerType").val();
var ATMModelType = $("#ATMModelType").val();
var mxdrq = $("#mxdrq").val();
var startdate = $("#startdate").val();
var enddate = $("#enddate").val();
return {
"offset": params.offset,
"limit": params.limit,
"CustomerType": CustomerType,
"ATMModelType": ATMModelType,
"mxdrq": mxdrq,
"startdate": startdate,
"enddate": enddate,
"sort": params.sort,
"search": params.search,
"order": params.order
}
return params;
}
get请求 的参数 全部 保存在
queryParams: queryParams,//参数 里面(bootstrap 封装好的)


http://localhost:8003/AtmAtm/GetCodeList?offset=0&limit=10&CustomerType%5B%5D=9e6f6cff-6e64-41f1-a7be-c07335764423&CustomerType%5B%5D=58194020-9eaf-4a6c-a5cc-b8fa6f628ba9&CustomerType%5B%5D=045426c5-9fd9-4c26-b4f0-dc0015ee96b8&CustomerType%5B%5D=ea0087c9-4172-4c03-92c5-4cc0cd9ac62d&CustomerType%5B%5D=40bde8fc-8a97-45e7-9907-524167975791&ATMModelType%5B%5D=a73a5fb1-bd7f-4088-9a33-3cb539e02f89&ATMModelType%5B%5D=b6cc57f2-d067-462c-9cc7-4f892932d0d5&ATMModelType%5B%5D=82e91205-1a16-11e7-b428-00163e003600&ATMModelType%5B%5D=83d5a7cc-4955-445a-b4b6-c881c4dcfcec&ATMModelType%5B%5D=1b673892-b161-4968-9066-3c3ca72bac37&ATMModelType%5B%5D=82e91099-1a16-11e7-b428-00163e003600&mxdrq=2&startdate=2014-06-29&enddate=2018-04-13&search=&order=asc&_=1523614816387
%5B%5D 数组 的 意思
在后台
//查询
//string[] CustomerType = (Request["CustomerType[]"] + "").Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
//string[] ATMModelType = (Request["ATMModelType[]"] + "").Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
string CustomerType = (Request["CustomerType[]"] + "");
string ATMModelType = (Request["ATMModelType[]"] + "");
get请求 Request 的话 这样
Request["CustomerType[]"]
获取 数组
post请求 的话 这样
public string GetCodeList(List<string> arr) 或者 对象中某属性
获取 数组
工作总结 2018-4-13 bootstrapTable 属性 queryParams: queryParams,//参数 get 中 %5B%5D 数组的意思的更多相关文章
- 工作总结 2018 - 4 - 13 select标签 multiple 属性 同时选择多个选项
<div class="col-xs-4"> @Html.DropDownList("CustomerType", (MultiSelectList ...
- (转)新手C#SQL语句的学习2018.08.13
1.创建数据库(create) CREATE DATABASE database-name 2.删除数据库(drop) drop database dbname 3.备份数据库 --- 创建 备份数据 ...
- java基础64 JavaScript中的Arrays数组对象和prototype原型属性(网页知识)
1.Arrays数组对象的创建方式 方式一: var 变量名=new Array(); //创建一个长度为0的数组. 方式二: var 变量名=new Array(长度); //创建一个指定长度的数组 ...
- bootstrap-table的一些配置参数例子
$('#reportTable').bootstrapTable({ method: 'post', url: '/qStock/AjaxPage', dataType: "json&quo ...
- [转贴]JavaScript中Array(数组)的属性和方法
数组有四种定义的方式 使用构造函数:var a = new Array();var b = new Array(8); var c = new Array("first", &qu ...
- javabean 参数收集 设置属性 设置不同级别的域对象的属性 默认存储在pagecontext中
javabean 参数收集 设置属性 设置不同级别的域对象的属性 默认存储在pagecontext中
- JavaScript中Array(数组)的属性和方法(转)
数组有四种定义的方式 使用构造函数:var a = new Array();var b = new Array(8);var c = new Array("first", &quo ...
- Servlet中的属性(attribute)和参数(parameter)的区别
1.引子 初学者对属性(attribute)和参数(parameter)容易搞混.没搞清他们的区别,项目中就可能出现一此莫名其妙的问题. 2.两者的区别 1) 属性(attribute) 属性是在后台 ...
- 【学习笔记】六:面向对象的程序设计——理解JS中的对象属性、创建对象、JS中的继承
ES中没有类的概念,这也使其对象和其他语言中的对象有所不同,ES中定义对象为:“无序属性的集合,其属性包含基本值.对象或者函数”.现在常用的创建单个对象的方法为对象字面量形式.在常见多个对象时,使用工 ...
随机推荐
- vue-cli 中使用less
(1)安装Less模块: npm install less (2)安装less和less-loader,命令如下 npm install less less-loader --sava-dev (3) ...
- (独孤九剑)--PHP简介与现况
(1)为什么学习PHP? 1.好就业: 2.入门简单,学习周期短,两个月即可: 3.学习编程思路,使编程习惯更加规范: 4.大公司直招: 5.处理大并发数据: 6.开源,所以更加安全 (2)PHP是什 ...
- vue 自定义指令使用
<template> <div> <!-- 让input元素在打开页面的时候就获得焦点 --> <input type="text" v- ...
- c#数据库连接学习
/*通过C#winform程序访问数据库数据 用到的命名空间和变量类型: using System.Data.SqlClient; SqlConnection:数据库连接类 SqlCommand:数据 ...
- (九)python3 列表生成式
列表生成式即 List Comprehensions,是 Python 内置的非常简单却强大的可以用来创建 list 的生成式. 要生成 list [1, 2, 3, 4, 5, 6, 7, 8, 9 ...
- Spring Quartz 和 Spring Task使用比较
Quartz 和 Spring Task执行时间对比: 1. Quartz同步模式:一个任务的两次执行的时间间隔是:“执行时间”和“trigger的设定间隔”的最大值 2. Task默认同步模式:一个 ...
- MyBatis 返回Map<String,Object>类型
<!-- 导出所有数据 --> <select id="exportAll" resultMap="map"> SELECT t1.ME ...
- 洛谷 1850 NOIP2016提高组 换教室
[题解] 先用floyed处理出两点间的最短路. 设f[i][j][k]表示走到第i个教室,总共换了j次,当前换或者不换,期望的最小移动距离. 分情况讨论来转移即可. #include<cstd ...
- 圆角计算 Shader
圆角的计算 在Shader中,我们使用UV坐标来计算需要显示的部分和不需要显示的部分,使用透明来处理显示与不显示.UV坐标如下图1,我们将坐标平移到图2位置,面片的UV坐标原点在面片中心,UV坐标范围 ...
- xtu summer individual-4 A - Beautiful IP Addresses
Beautiful IP Addresses Time Limit: 2000ms Memory Limit: 262144KB This problem will be judged on Code ...