|
@@ -131,7 +131,7 @@
|
|
|
<div style="width:100%;float: left;">
|
|
|
<div class="c1 label"> 粒度:</div>
|
|
|
<div class="timeTypeDiv c1" style="width: 10%;">
|
|
|
- <select name="timeType" id="timeType" onchange="handleChange(this)">
|
|
|
+ <select name="timeType" id="timeType" onChange="handleChange(this.options[this.selectedIndex].value)">
|
|
|
<option value="QUATER">15分钟</option>
|
|
|
<option value="HOUR">小时</option>
|
|
|
<option value="DAY">天</option>
|
|
@@ -255,7 +255,8 @@
|
|
|
// console.log(window.sessionStorage.getItem('userName'))
|
|
|
$("#userName").text(window.sessionStorage.getItem('userName'))
|
|
|
})
|
|
|
- function handleChange(){
|
|
|
+ function handleChange(val){
|
|
|
+ console.log('val: ', val);
|
|
|
console.log('5555')
|
|
|
console.log($('#timeType').val())
|
|
|
let timeType = $('#timeType').val()
|
|
@@ -599,7 +600,27 @@
|
|
|
btn: ['确定'],
|
|
|
shadeClose: true,
|
|
|
success: function(layero, index){
|
|
|
- console.log(layero, index);
|
|
|
+ let data = checkedData[0].id;
|
|
|
+ $.ajax({
|
|
|
+ type: "POST",
|
|
|
+ contentType: "application/json;charset=UTF-8",
|
|
|
+ url: '/api/getTemplateDetail',
|
|
|
+ data: data,
|
|
|
+ success: function (r) {
|
|
|
+ if (r?.success) {
|
|
|
+ templateId = r.data.id;
|
|
|
+ $('#templateName').val(r.data.templateName);
|
|
|
+ let arr = [];
|
|
|
+ r.data.list.map(item=>{
|
|
|
+ arr.push(item.id)
|
|
|
+ })
|
|
|
+ console.log('arr: ', arr);
|
|
|
+ tree.setChecked('Id2', arr)
|
|
|
+ return
|
|
|
+ }
|
|
|
+ alert(r?.message ?? '发生错误了');
|
|
|
+ }
|
|
|
+ });
|
|
|
},
|
|
|
yes: function(index, layero){
|
|
|
const templateName = $('#templateName').val()
|