|
@@ -154,9 +154,10 @@ function getCategoryHtml() {
|
|
|
html.push('<div class="form-group" cate-id="' + cate.id + '">');
|
|
|
html.push('<lable>', cate.name, '</lable>');
|
|
|
html.push('<div>');
|
|
|
- for (const v of cate.value) {
|
|
|
+ for (const iV in cate.value) {
|
|
|
+ const v = cate.value[iV];
|
|
|
html.push('<div class="form-check-inline">');
|
|
|
- html.push('<input class="form-check-input" type="radio"', 'value="' , v.id, '">');
|
|
|
+ html.push('<input class="form-check-input" type="radio"', 'name="' + cate.name + '" ', 'value="' , v.id, (iV == 0 ? '" checked="' : ''), '">');
|
|
|
html.push('<label class="form-check-label">', v.value, '</label>');
|
|
|
html.push('</div>');
|
|
|
}
|
|
@@ -303,7 +304,6 @@ $(document).ready(() => {
|
|
|
$('.modal-body', '#add-bd').append(getCategoryHtml());
|
|
|
// 初始化标段树结构
|
|
|
initTenderTree();
|
|
|
- console.log(tenderTree);
|
|
|
$('.c-body').html(getTenderTreeHtml());
|
|
|
bindTenderUrl();
|
|
|
// 分类
|
|
@@ -358,6 +358,8 @@ $(document).ready(() => {
|
|
|
initTenderTree();
|
|
|
$('.c-body').html(getTenderTreeHtml());
|
|
|
bindTenderUrl();
|
|
|
+ $('#add-bd').modal('hide');
|
|
|
+ $('[name=name]', '#add-bd').val('');
|
|
|
});
|
|
|
});
|
|
|
});
|