mirror of https://github.com/layui/layui
修复 table complete 选项未设置时仍生效的问题 (#1423)
commit
99bc35a06c
|
@ -1035,9 +1035,7 @@ layui.define(['lay', 'laytpl', 'laypage', 'form', 'util'], function(exports){
|
||||||
dataType: options.dataType || 'json',
|
dataType: options.dataType || 'json',
|
||||||
jsonpCallback: options.jsonpCallback,
|
jsonpCallback: options.jsonpCallback,
|
||||||
headers: options.headers || {},
|
headers: options.headers || {},
|
||||||
complete: function(xhr,ts){
|
complete: typeof options.complete === 'function' ? options.complete : undefined,
|
||||||
typeof options.complete === 'function' && options.complete(xhr, ts);
|
|
||||||
},
|
|
||||||
success: function(res){
|
success: function(res){
|
||||||
// 若有数据解析的回调,则获得其返回的数据
|
// 若有数据解析的回调,则获得其返回的数据
|
||||||
if(typeof options.parseData === 'function'){
|
if(typeof options.parseData === 'function'){
|
||||||
|
|
Loading…
Reference in New Issue