提交
This commit is contained in:
parent
ad569eb8d4
commit
638cd6d840
@ -66,7 +66,8 @@
|
|||||||
<div class="kanbanadmin-list-box">
|
<div class="kanbanadmin-list-box">
|
||||||
<span class="kanbanadmin-list-tit">{{item.name}}</span>
|
<span class="kanbanadmin-list-tit">{{item.name}}</span>
|
||||||
<span class="kanbanadmin-list-add-box">
|
<span class="kanbanadmin-list-add-box">
|
||||||
<span class="kanbanadmin-list-add to-added-more{{index - 1}}"><i class="layui-icon"></i></span>
|
<span class="kanbanadmin-list-add to-added-table" data-id="{{item._id}}"><i class="layui-icon"></i></span>
|
||||||
|
<span class="kanbanadmin-list-add to-added-chart" data-id="{{item._id}}"><i class="layui-icon"></i></span>
|
||||||
<span class="kanbanadmin-list-add to-added-del" data-id="{{item._id}}"> <i class="layui-icon">ဆ</i> </span>
|
<span class="kanbanadmin-list-add to-added-del" data-id="{{item._id}}"> <i class="layui-icon">ဆ</i> </span>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
75
web/src/x.min.js
vendored
75
web/src/x.min.js
vendored
@ -3079,7 +3079,7 @@ var X = window.X || {
|
|||||||
});
|
});
|
||||||
|
|
||||||
//筛选
|
//筛选
|
||||||
$(".tab-right-box .tjsx").click(function(){
|
$(document).off('click','.tab-right-box .tjsx').on("click",".tab-right-box .tjsx",function(){
|
||||||
X.open({
|
X.open({
|
||||||
type: 1,
|
type: 1,
|
||||||
title: false,
|
title: false,
|
||||||
@ -3090,7 +3090,7 @@ var X = window.X || {
|
|||||||
url: "screen",
|
url: "screen",
|
||||||
extData : {}
|
extData : {}
|
||||||
})
|
})
|
||||||
});
|
})
|
||||||
|
|
||||||
// 侧边栏搜索
|
// 侧边栏搜索
|
||||||
$('.sousuo-txt').bind('input propertychange', function() {
|
$('.sousuo-txt').bind('input propertychange', function() {
|
||||||
@ -3244,7 +3244,6 @@ var X = window.X || {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
index --;
|
index --;
|
||||||
console.log(eventdata);
|
|
||||||
if(index <= 0){
|
if(index <= 0){
|
||||||
X.template("modeltable","chart-box",eventdata,function(){
|
X.template("modeltable","chart-box",eventdata,function(){
|
||||||
for(let i in eventdata){
|
for(let i in eventdata){
|
||||||
@ -4039,6 +4038,29 @@ var X = window.X || {
|
|||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
|
// srczip/logic/dropdownlist2.js
|
||||||
|
(function(){
|
||||||
|
X.pageLogic['dropdownlist2'] = {
|
||||||
|
init : function(parms){
|
||||||
|
var me = this;
|
||||||
|
this.parms = parms;
|
||||||
|
this.callback = parms.callback;
|
||||||
|
var listdata = parms.extData;
|
||||||
|
// console.log('aaa',listdata);
|
||||||
|
|
||||||
|
X.laytpldata("#dropdownlist-con-box-dot",listdata,".dropdownlist-con-box");
|
||||||
|
|
||||||
|
$(document).off('click','.dropdownlist-list').on('click','.dropdownlist-list',function(){
|
||||||
|
var index = $(this).attr("data-index");
|
||||||
|
var dataArr = listdata[index];
|
||||||
|
me.callback && me.callback(dataArr);
|
||||||
|
layer.closeAll(0);
|
||||||
|
})
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
})();
|
||||||
|
|
||||||
// srczip/logic/event.js
|
// srczip/logic/event.js
|
||||||
(function(){
|
(function(){
|
||||||
X.pageLogic['event'] = {
|
X.pageLogic['event'] = {
|
||||||
@ -5259,6 +5281,32 @@ var X = window.X || {
|
|||||||
toadddataprocessing();
|
toadddataprocessing();
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 修改报表类型
|
||||||
|
$(document).off('click','.to-added-table').on('click','.to-added-table',function(){
|
||||||
|
var obj = $(this);
|
||||||
|
var id = obj.attr("data-id");
|
||||||
|
for(let i in submitdata){
|
||||||
|
if(submitdata[i]['report_id'] == id){
|
||||||
|
submitdata[i]['graph_type'] = 'table';
|
||||||
|
layer.msg('修改为表格展示',{time: 1000});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
$(document).off('click','.to-added-chart').on('click','.to-added-chart',function(){
|
||||||
|
var obj = $(this);
|
||||||
|
var id = obj.attr("data-id");
|
||||||
|
console.log(id);
|
||||||
|
for(let i in submitdata){
|
||||||
|
if(submitdata[i]['report_id'] == id){
|
||||||
|
submitdata[i]['graph_type'] = 'echarts';
|
||||||
|
layer.msg('修改为图表展示',{time: 1000});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//渲染已添加报表下拉框
|
//渲染已添加报表下拉框
|
||||||
function toadddataprocessing(){
|
function toadddataprocessing(){
|
||||||
@ -5267,11 +5315,7 @@ var X = window.X || {
|
|||||||
if(reportlistdata[i]['added'] == true){
|
if(reportlistdata[i]['added'] == true){
|
||||||
toadddata.push(reportlistdata[i]);
|
toadddata.push(reportlistdata[i]);
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
var downmenu = [
|
|
||||||
{title:'表格',id:'table'},
|
|
||||||
{title:'图形',id:'echarts'}
|
|
||||||
]
|
|
||||||
submitdata = [];
|
submitdata = [];
|
||||||
for(let i in toadddata){
|
for(let i in toadddata){
|
||||||
var arr = {
|
var arr = {
|
||||||
@ -5279,13 +5323,8 @@ var X = window.X || {
|
|||||||
graph_type:'table',
|
graph_type:'table',
|
||||||
model:toadddata[i]['cat'],
|
model:toadddata[i]['cat'],
|
||||||
name:toadddata[i]['name'],
|
name:toadddata[i]['name'],
|
||||||
}
|
};
|
||||||
submitdata.push(arr);
|
submitdata.push(arr);
|
||||||
X.laydropdown('.to-added-more'+i,downmenu,function(d){
|
|
||||||
|
|
||||||
submitdata[i]['graph_type'] = d.id;
|
|
||||||
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -5293,8 +5332,8 @@ var X = window.X || {
|
|||||||
var id = $(this).attr('data-id');
|
var id = $(this).attr('data-id');
|
||||||
X.api('dashboard/del_report','post',{_id:X['DATA']['dashboard_id'],report_id:id},function(){
|
X.api('dashboard/del_report','post',{_id:X['DATA']['dashboard_id'],report_id:id},function(){
|
||||||
kanbanupdata();
|
kanbanupdata();
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
$(document).off('click','.kanbanadmin-but-yy').on('click','.kanbanadmin-but-yy',function(){
|
$(document).off('click','.kanbanadmin-but-yy').on('click','.kanbanadmin-but-yy',function(){
|
||||||
X.api('dashboard/add_report','post',{_id:X['DATA']['dashboard_id'],report_ids:submitdata},function(d){
|
X.api('dashboard/add_report','post',{_id:X['DATA']['dashboard_id'],report_ids:submitdata},function(d){
|
||||||
@ -5303,8 +5342,8 @@ var X = window.X || {
|
|||||||
layer.closeAll();
|
layer.closeAll();
|
||||||
layer.msg('应用成功');
|
layer.msg('应用成功');
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -101,7 +101,7 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
//筛选
|
//筛选
|
||||||
$(".tab-right-box .tjsx").click(function(){
|
$(document).off('click','.tab-right-box .tjsx').on("click",".tab-right-box .tjsx",function(){
|
||||||
X.open({
|
X.open({
|
||||||
type: 1,
|
type: 1,
|
||||||
title: false,
|
title: false,
|
||||||
@ -112,7 +112,7 @@
|
|||||||
url: "screen",
|
url: "screen",
|
||||||
extData : {}
|
extData : {}
|
||||||
})
|
})
|
||||||
});
|
})
|
||||||
|
|
||||||
// 侧边栏搜索
|
// 侧边栏搜索
|
||||||
$('.sousuo-txt').bind('input propertychange', function() {
|
$('.sousuo-txt').bind('input propertychange', function() {
|
||||||
@ -266,7 +266,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
index --;
|
index --;
|
||||||
console.log(eventdata);
|
|
||||||
if(index <= 0){
|
if(index <= 0){
|
||||||
X.template("modeltable","chart-box",eventdata,function(){
|
X.template("modeltable","chart-box",eventdata,function(){
|
||||||
for(let i in eventdata){
|
for(let i in eventdata){
|
||||||
|
@ -78,6 +78,32 @@
|
|||||||
toadddataprocessing();
|
toadddataprocessing();
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 修改报表类型
|
||||||
|
$(document).off('click','.to-added-table').on('click','.to-added-table',function(){
|
||||||
|
var obj = $(this);
|
||||||
|
var id = obj.attr("data-id");
|
||||||
|
for(let i in submitdata){
|
||||||
|
if(submitdata[i]['report_id'] == id){
|
||||||
|
submitdata[i]['graph_type'] = 'table';
|
||||||
|
layer.msg('修改为表格展示',{time: 1000});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
$(document).off('click','.to-added-chart').on('click','.to-added-chart',function(){
|
||||||
|
var obj = $(this);
|
||||||
|
var id = obj.attr("data-id");
|
||||||
|
console.log(id);
|
||||||
|
for(let i in submitdata){
|
||||||
|
if(submitdata[i]['report_id'] == id){
|
||||||
|
submitdata[i]['graph_type'] = 'echarts';
|
||||||
|
layer.msg('修改为图表展示',{time: 1000});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//渲染已添加报表下拉框
|
//渲染已添加报表下拉框
|
||||||
function toadddataprocessing(){
|
function toadddataprocessing(){
|
||||||
@ -86,11 +112,7 @@
|
|||||||
if(reportlistdata[i]['added'] == true){
|
if(reportlistdata[i]['added'] == true){
|
||||||
toadddata.push(reportlistdata[i]);
|
toadddata.push(reportlistdata[i]);
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
var downmenu = [
|
|
||||||
{title:'表格',id:'table'},
|
|
||||||
{title:'图形',id:'echarts'}
|
|
||||||
]
|
|
||||||
submitdata = [];
|
submitdata = [];
|
||||||
for(let i in toadddata){
|
for(let i in toadddata){
|
||||||
var arr = {
|
var arr = {
|
||||||
@ -98,13 +120,8 @@
|
|||||||
graph_type:'table',
|
graph_type:'table',
|
||||||
model:toadddata[i]['cat'],
|
model:toadddata[i]['cat'],
|
||||||
name:toadddata[i]['name'],
|
name:toadddata[i]['name'],
|
||||||
}
|
};
|
||||||
submitdata.push(arr);
|
submitdata.push(arr);
|
||||||
X.laydropdown('.to-added-more'+i,downmenu,function(d){
|
|
||||||
|
|
||||||
submitdata[i]['graph_type'] = d.id;
|
|
||||||
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -112,8 +129,8 @@
|
|||||||
var id = $(this).attr('data-id');
|
var id = $(this).attr('data-id');
|
||||||
X.api('dashboard/del_report','post',{_id:X['DATA']['dashboard_id'],report_id:id},function(){
|
X.api('dashboard/del_report','post',{_id:X['DATA']['dashboard_id'],report_id:id},function(){
|
||||||
kanbanupdata();
|
kanbanupdata();
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
$(document).off('click','.kanbanadmin-but-yy').on('click','.kanbanadmin-but-yy',function(){
|
$(document).off('click','.kanbanadmin-but-yy').on('click','.kanbanadmin-but-yy',function(){
|
||||||
X.api('dashboard/add_report','post',{_id:X['DATA']['dashboard_id'],report_ids:submitdata},function(d){
|
X.api('dashboard/add_report','post',{_id:X['DATA']['dashboard_id'],report_ids:submitdata},function(d){
|
||||||
@ -122,8 +139,8 @@
|
|||||||
layer.closeAll();
|
layer.closeAll();
|
||||||
layer.msg('应用成功');
|
layer.msg('应用成功');
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user