作者 董瑞恩
1 个管道 的构建 通过 耗费 1 秒

cost

... ... @@ -84,14 +84,20 @@
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.all.min.js"></script>
<script type="text/javascript">
function confirm() {
var serial_number = [];
var test_oil_name = [];
var selectedCategories = [];
var serial_number = $('#serial_number').val();
var mac_address = $('#mac_address').val();
var name = $('#name').val();
var hospital = $('#hospital').val();
var note = $('#note').val();
var create_time = $('#create_time').val();
return {
selectedCategories: selectedCategories,
selectedCategoriesId: selectedCategoriesId,
selectedCategoriesName: selectedCategoriesName
serial_number:serial_number,
mac_address :mac_address,
name :name,
hospital :hospital,
note :note,
create_time :create_time
};
}
</script>
... ...
... ... @@ -121,12 +121,10 @@
yes: function (index, layero) {
//do something
var iframeWin = window[layero.find('iframe')[0]['name']];
var selectedCategories = iframeWin.confirm();
if (selectedCategories.selectedCategoriesId.length == 0) {
console.log(iframeWin);
}
$('#js-categories-id-input').val(selectedCategories.selectedCategoriesId.join(','));
$('#js-categories-name-input').val(selectedCategories.selectedCategoriesName.join(' '));
//console.log(layer.getFrameIndex(index));
layer.close(index); //如果设定了yes回调,需进行手工关闭
}
... ...