tts
This commit is contained in:
parent
3481ad5392
commit
9fba22ca40
|
|
@ -58,31 +58,32 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form', 'echarts','echarts-th
|
|||
// 为表格2绑定事件
|
||||
Table.api.bindevent(table2);
|
||||
|
||||
setTimeout(function () {
|
||||
var $city = $('#select_city');
|
||||
if ($city.data('citypicker')) {
|
||||
$city.citypicker('destroy');
|
||||
}
|
||||
$city.citypicker();
|
||||
var $city = $('#select_city');
|
||||
if ($city.data('citypicker')) {
|
||||
$city.citypicker('destroy');
|
||||
}
|
||||
$city.citypicker();
|
||||
|
||||
// 延迟一点点,确保弹层生成后再调整位置
|
||||
setTimeout(function () {
|
||||
var $dropdown = $('.city-picker-dropdown');
|
||||
if ($dropdown.length) {
|
||||
var offset = $city.offset();
|
||||
$dropdown.css({
|
||||
top: offset.top + $city.outerHeight(),
|
||||
left: offset.left,
|
||||
position: 'absolute',
|
||||
position: 'absolute', // 或 'fixed' 试试
|
||||
display: 'block',
|
||||
'z-index': 9999
|
||||
});
|
||||
}
|
||||
}, 200);
|
||||
|
||||
$city.off("cp:updated").on("cp:updated", function () {
|
||||
var citypicker = $(this).data("citypicker");
|
||||
var code = citypicker.getCode("district") || citypicker.getCode("city") || citypicker.getCode("province");
|
||||
$("#select_area_id").val(code);
|
||||
});
|
||||
}, 800);
|
||||
$city.off("cp:updated").on("cp:updated", function () {
|
||||
var citypicker = $(this).data("citypicker");
|
||||
var code = citypicker.getCode("district") || citypicker.getCode("city") || citypicker.getCode("province");
|
||||
$("#select_area_id").val(code);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user