File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -807,7 +807,8 @@ <h4 class="modal-title text-danger">收藏语句</h4>
807
807
isdetail = true
808
808
}
809
809
var showExport = { { can_download} } === 1
810
- $ ( `#query_result${ n } ` ) . bootstrapTable ( 'destroy' ) . bootstrapTable ( {
810
+ var query_result_id = ( `query_result${ n } ` ) ;
811
+ $ ( `#${ query_result_id } ` ) . bootstrapTable ( 'destroy' ) . bootstrapTable ( {
811
812
escape : true ,
812
813
data : result [ 'rows' ] ,
813
814
columns : columns ,
@@ -870,6 +871,15 @@ <h4 class="modal-title text-danger">收藏语句</h4>
870
871
} ) ;
871
872
return html . join ( '' ) ;
872
873
} ,
874
+ onPostBody : function ( data ) {
875
+ //此处的属性及样式名称,来自于bootstrap-table.js
876
+ //有detail的表头,添加sytle
877
+ var thHasDetail = $ ( `#${ query_result_id } th.detail` ) ;
878
+ thHasDetail . css ( 'white-space' , 'nowrap' ) ;
879
+ //有详情+号的的td,添加sytle。
880
+ var tdHasDetail = $ ( `#${ query_resultId } tr[data-has-detail-view="true"] .detail-icon` ) . parent ( 'td' ) ;
881
+ tdHasDetail . css ( 'white-space' , 'nowrap' ) ;
882
+ } ,
873
883
locale : 'zh-CN' ,
874
884
onExportSaved : function ( e ) {
875
885
var tabs = $ ( "#nav-tabs li" )
You can’t perform that action at this time.
0 commit comments