111
This commit is contained in:
parent
190d7b4132
commit
a6f244fee0
@ -168,8 +168,8 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="padding: 15px; height: calc(100% - 17px); overflow-y:auto; ">
|
<div style="padding: 15px 0px 15px 15px; height: calc(100% - 17px); overflow-y:auto;">
|
||||||
|
|
||||||
<div class="layui-row layui-col-space15" id="model-box" style="width: 100%; height: 780px;">
|
<div class="layui-row layui-col-space15" id="model-box" style="width: 100%; height: 780px;">
|
||||||
|
|
||||||
<!-- <div class="layui-row layui-col-space15" id="model-box" style="width: 100%; height: 780px;">
|
<!-- <div class="layui-row layui-col-space15" id="model-box" style="width: 100%; height: 780px;">
|
||||||
|
@ -33,7 +33,9 @@
|
|||||||
<div id="ta-property-select-{{indexs}}" class="ta-property-select analysis-zhibiao-list-type1 analysis-background" data-index="0" data-indexs="{{indexs}}"> {{items.columnDesc}}</div>
|
<div id="ta-property-select-{{indexs}}" class="ta-property-select analysis-zhibiao-list-type1 analysis-background" data-index="0" data-indexs="{{indexs}}"> {{items.columnDesc}}</div>
|
||||||
<div class="analysis-zhibiao-list-type3 analysis-background analysis-choicetypename" data-index="0" data-indexs="{{indexs}}">{{items.comparatorName}}</div>
|
<div class="analysis-zhibiao-list-type3 analysis-background analysis-choicetypename" data-index="0" data-indexs="{{indexs}}">{{items.comparatorName}}</div>
|
||||||
{{# if(items.comparator != "is null" && items.comparator != "is not null" && items.comparator !="not null" && items.comparator != "range"){ }}
|
{{# if(items.comparator != "is null" && items.comparator != "is not null" && items.comparator !="not null" && items.comparator != "range"){ }}
|
||||||
<div class="analysis-zhibiao-list-type4" id="analysis-zhibiao-list-type4-{{indexs}}"> <input type="text" data-index="0" data-indexs="{{indexs}}" placeholder="多个条件用,隔开" value="{{items.strftv}}"> </div>
|
<div class="analysis-zhibiao-list-type4" >
|
||||||
|
<input type="text" id="analysis-zhibiao-list-type4-{{indexs}}" data-index="0" data-indexs="{{indexs}}" placeholder="多个条件用,隔开" value="{{items.strftv}}">
|
||||||
|
</div>
|
||||||
{{# } }}
|
{{# } }}
|
||||||
<div class="analysis-zhibiao-list-del analysis-zhibiao-list-del-initial-event" data-twonum="{{indexs}}"></div>
|
<div class="analysis-zhibiao-list-del analysis-zhibiao-list-del-initial-event" data-twonum="{{indexs}}"></div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -4,11 +4,13 @@
|
|||||||
<div class="analysis-overall-situation-list">
|
<div class="analysis-overall-situation-list">
|
||||||
<div class="analysis-overall-situation-attr" data-index="{{index}}">{{item.columnName}}</div>
|
<div class="analysis-overall-situation-attr" data-index="{{index}}">{{item.columnName}}</div>
|
||||||
<div class="analysis-overall-situation-fuhao" id="analysis-overall-situation-fuhao-{{index}}" data-index="{{index}}" data-type="{{item.data_type}}" >{{item.comparator_name}}</div>
|
<div class="analysis-overall-situation-fuhao" id="analysis-overall-situation-fuhao-{{index}}" data-index="{{index}}" data-type="{{item.data_type}}" >{{item.comparator_name}}</div>
|
||||||
{{# if(item.comparator_id != "is null" && item.comparator_id != "is not null" && item.comparator_id !="not null" && item.comparator_id != "range"){ }}
|
{{# if(item.comparator != "is null" && item.comparator != "is not null" && item.comparator !="not null" && item.comparator != "range"){ }}
|
||||||
<div class="analysis-overall-situation-input" > <input type="text" data-index="{{index}}" placeholder="多个用,隔开" value="{{item.strftv}}"/> </div>
|
<div class="analysis-overall-situation-input" >
|
||||||
|
<input type="text" data-index="{{index}}" placeholder="多个用,隔开" value="{{item.strftv}}"/>
|
||||||
|
</div>
|
||||||
{{# } }}
|
{{# } }}
|
||||||
|
|
||||||
{{# if(item.comparator_id === "range"){ }}
|
{{# if(item.comparator === "range"){ }}
|
||||||
<div class="analysis-overall-situation-input2" > <input data-index="{{index}}" type="text" value="{{item.section[0]}}" name="start"/> <span>与</span> <input data-index="{{index}}" name="end" type="text" value="{{item.section[1]}}"/> <span>之间</span> </div>
|
<div class="analysis-overall-situation-input2" > <input data-index="{{index}}" type="text" value="{{item.section[0]}}" name="start"/> <span>与</span> <input data-index="{{index}}" name="end" type="text" value="{{item.section[1]}}"/> <span>之间</span> </div>
|
||||||
{{# } }}
|
{{# } }}
|
||||||
<p class="analysis-overall-situation-del" data-index="{{index}}"> <img src="./static/img/cha1.png"> </p>
|
<p class="analysis-overall-situation-del" data-index="{{index}}"> <img src="./static/img/cha1.png"> </p>
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
<div class="tishi model-fuzhi" title="复制" data-id="{{d.id}}" >
|
<div class="tishi model-fuzhi" title="复制" data-id="{{d.id}}" >
|
||||||
<img src="./static/img/fuzhi2.png" />
|
<img src="./static/img/fuzhi2.png" />
|
||||||
</div>
|
</div>
|
||||||
<div class="tishi" title="更多">
|
<div class="tishi model-gengduo" title="更多">
|
||||||
<img src="./static/img/gengduo.png" />
|
<img src="./static/img/gengduo.png" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -67,7 +67,7 @@
|
|||||||
<div class="tishi model-fuzhi" title="复制" data-id="{{d.id}}">
|
<div class="tishi model-fuzhi" title="复制" data-id="{{d.id}}">
|
||||||
<img src="./static/img/fuzhi2.png" />
|
<img src="./static/img/fuzhi2.png" />
|
||||||
</div>
|
</div>
|
||||||
<div class="tishi" title="更多">
|
<div class="tishi model-gengduo" title="更多">
|
||||||
<img src="./static/img/gengduo.png" />
|
<img src="./static/img/gengduo.png" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -197,7 +197,7 @@
|
|||||||
<div class="tishi model-fuzhi" title="复制" data-id="{{d.id}}">
|
<div class="tishi model-fuzhi" title="复制" data-id="{{d.id}}">
|
||||||
<img src="./static/img/fuzhi2.png" />
|
<img src="./static/img/fuzhi2.png" />
|
||||||
</div>
|
</div>
|
||||||
<div class="tishi" title="更多">
|
<div class="tishi model-gengduo" title="更多">
|
||||||
<img src="./static/img/gengduo.png" />
|
<img src="./static/img/gengduo.png" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -28,9 +28,9 @@
|
|||||||
<div style="padding-bottom: 10px;" class="analysis-zhibiao-list2-box">
|
<div style="padding-bottom: 10px;" class="analysis-zhibiao-list2-box">
|
||||||
{{# layui.each(d.filts, function(indexs, items){ }}
|
{{# layui.each(d.filts, function(indexs, items){ }}
|
||||||
<div class="analysis-zhibiao-list analysis-zhibiao-list-mar" id="analysis-zhibiao-list-mar-{{indexs}}">
|
<div class="analysis-zhibiao-list analysis-zhibiao-list-mar" id="analysis-zhibiao-list-mar-{{indexs}}">
|
||||||
<div id="ta-property-select-{{indexs}}" class="ta-property-select analysis-zhibiao-list-type1 analysis-background" data-index="0" data-indexs="{{indexs}}"> {{items.columnDesc}}</div>
|
<div id="ta-property-select-{{indexs}}" class="ta-property-select analysis-zhibiao-list-type1 analysis-background" data-index="1" data-indexs="{{indexs}}"> {{items.columnDesc}}</div>
|
||||||
<div class="analysis-zhibiao-list-type3 analysis-background analysis-choicetypename" data-index="0" data-indexs="{{indexs}}">{{items.comparatorName}}</div>
|
<div class="analysis-zhibiao-list-type3 analysis-background analysis-choicetypename" data-index="1" data-indexs="{{indexs}}">{{items.comparatorName}}</div>
|
||||||
<div class="analysis-zhibiao-list-type4" id="analysis-zhibiao-list-type4-{{indexs}}"> <input type="text" data-index="0" data-indexs="{{indexs}}" placeholder="多个条件用,隔开" value="{{items.strftv}}"> </div>
|
<div class="analysis-zhibiao-list-type4" id="analysis-zhibiao-list-type4-{{indexs}}"> <input type="text" data-index="1" data-indexs="{{indexs}}" placeholder="多个条件用,隔开" value="{{items.strftv}}"> </div>
|
||||||
<div class="analysis-zhibiao-list-del analysis-zhibiao-list-del-return-event" data-twonum="{{indexs}}"></div>
|
<div class="analysis-zhibiao-list-del analysis-zhibiao-list-del-return-event" data-twonum="{{indexs}}"></div>
|
||||||
</div>
|
</div>
|
||||||
{{# }); }}
|
{{# }); }}
|
||||||
|
127
web/src/x.min.js
vendored
127
web/src/x.min.js
vendored
@ -25,6 +25,11 @@ var X = window.X || {
|
|||||||
{'title':'复制看板','img':'fuzhi.png','click':'copy'}
|
{'title':'复制看板','img':'fuzhi.png','click':'copy'}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
'gengduolist':[
|
||||||
|
{'title':'报表设置','id':'shezhi'},
|
||||||
|
{'title':'数据导出','id':'export'},
|
||||||
|
{'title':'报表移除','id':'del'},
|
||||||
|
],
|
||||||
//用户搜索条件
|
//用户搜索条件
|
||||||
'search':{
|
'search':{
|
||||||
category:[
|
category:[
|
||||||
@ -342,7 +347,7 @@ var X = window.X || {
|
|||||||
'今日': [moment(), moment()],
|
'今日': [moment(), moment()],
|
||||||
'昨日': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
|
'昨日': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
|
||||||
'最近7日': [moment().subtract(7, 'days'), moment().subtract(0, 'days')],
|
'最近7日': [moment().subtract(7, 'days'), moment().subtract(0, 'days')],
|
||||||
'最近30日': [moment().subtract(30, 'days'), moment().subtract(1, 'days')],
|
'最近30日': [moment().subtract(30, 'days'), moment().subtract(0, 'days')],
|
||||||
'上周': [moment().subtract(1, 'week').startOf('week')+86400000, moment().subtract(1, 'week').endOf('week')+86400000],
|
'上周': [moment().subtract(1, 'week').startOf('week')+86400000, moment().subtract(1, 'week').endOf('week')+86400000],
|
||||||
'本周': [moment().startOf('week')+86400000, moment()+86400000],
|
'本周': [moment().startOf('week')+86400000, moment()+86400000],
|
||||||
'本月': [moment().startOf('month'), moment()],
|
'本月': [moment().startOf('month'), moment()],
|
||||||
@ -4148,7 +4153,7 @@ var X = window.X || {
|
|||||||
})
|
})
|
||||||
|
|
||||||
});
|
});
|
||||||
console.log(eventdata);
|
|
||||||
// 留存分析模板特定留存流失按钮
|
// 留存分析模板特定留存流失按钮
|
||||||
var retentionlist = [
|
var retentionlist = [
|
||||||
{'title':'留存','id':0},
|
{'title':'留存','id':0},
|
||||||
@ -4169,8 +4174,40 @@ var X = window.X || {
|
|||||||
})
|
})
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
};
|
||||||
|
|
||||||
|
//更多按钮配置下拉框
|
||||||
|
X.laydropdown(".model-gengduo",X['DATA']['gengduolist'],function(d){
|
||||||
|
console.log(eventdata);
|
||||||
|
if(d.id == 'shezhi'){
|
||||||
|
var data = {
|
||||||
|
id : eventdata.id,
|
||||||
|
modelsize : eventdata.modelsize,
|
||||||
|
modeltype : eventdata.modeltype
|
||||||
|
}
|
||||||
|
X.parametersopen(data,'setupbaobiao',"auto",function(d){
|
||||||
|
|
||||||
|
})
|
||||||
|
}else if(d.id == 'export'){
|
||||||
|
layer.msg('暂未开放功能');
|
||||||
|
}else {
|
||||||
|
|
||||||
|
layer.confirm('确认移除['+ eventdata.name + ']', {
|
||||||
|
btn: ['取消','删除 '] //按钮
|
||||||
|
}, function(){
|
||||||
|
//取消
|
||||||
|
layer.close(layer.index);
|
||||||
|
}, function(){
|
||||||
|
//删除
|
||||||
|
X.api('dashboard/del_report','post',{_id:X['DATA']['dashboard_id'],report_id:eventdata.id},function(){
|
||||||
|
X.pageLogic['dashboard'].gettabledata();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
if(eventdata['modeltype'] == 'echarts' && eventdata['modelsize'] != 'small' ){
|
if(eventdata['modeltype'] == 'echarts' && eventdata['modelsize'] != 'small' ){
|
||||||
var myChart = echarts.init(document.getElementById(eventdata['id']));
|
var myChart = echarts.init(document.getElementById(eventdata['id']));
|
||||||
@ -8087,7 +8124,7 @@ var X = window.X || {
|
|||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
$(document).off('click','.analysis-zhibiao-list-type4 input').on('change','.analysis-zhibiao-list-type4 input',function(){
|
$(document).off('change','.analysis-zhibiao-list-type4 input').on('change','.analysis-zhibiao-list-type4 input',function(){
|
||||||
var index = $(this).attr('data-index');
|
var index = $(this).attr('data-index');
|
||||||
var indexs = $(this).attr('data-indexs');
|
var indexs = $(this).attr('data-indexs');
|
||||||
var txt = $(this).val();
|
var txt = $(this).val();
|
||||||
@ -8100,12 +8137,13 @@ var X = window.X || {
|
|||||||
var filtsftvdata=[];
|
var filtsftvdata=[];
|
||||||
$(document).off('click','.analysis-overall-situation-add').on('click','.analysis-overall-situation-add',function(){
|
$(document).off('click','.analysis-overall-situation-add').on('click','.analysis-overall-situation-add',function(){
|
||||||
var screentypedata = groupitemeventsdata[0];
|
var screentypedata = groupitemeventsdata[0];
|
||||||
|
console.log(screentypedata);
|
||||||
var drr={
|
var drr={
|
||||||
"columnName":screentypedata[0]['category'][0]['title'],//事件中文显示
|
"columnName":screentypedata[0]['category'][0]['title'],//事件中文显示
|
||||||
"column_id":screentypedata[0]['category'][0]['id'],//事件id
|
"column_id":screentypedata[0]['category'][0]['id'],//事件id
|
||||||
'data_type':screentypedata[0]['category'][0]['data_type'],//类型
|
'data_type':screentypedata[0]['category'][0]['data_type'],//类型
|
||||||
'comparator_name':'等于',//默认等于
|
'comparator_name':'等于',//默认等于
|
||||||
"comparator_id":'==',//符号id
|
"comparator":'==',//符号id
|
||||||
"ftv":[],//条件
|
"ftv":[],//条件
|
||||||
"strftv":'',//显示条件
|
"strftv":'',//显示条件
|
||||||
"section":[-1,1],//区间
|
"section":[-1,1],//区间
|
||||||
@ -8149,8 +8187,8 @@ var X = window.X || {
|
|||||||
data['eventView']['filts'][index]['column_id'] = val.id;
|
data['eventView']['filts'][index]['column_id'] = val.id;
|
||||||
data['eventView']['filts'][index]['data_type'] = val.type;
|
data['eventView']['filts'][index]['data_type'] = val.type;
|
||||||
data['eventView']['filts'][index]['comparator_name'] = '等于';
|
data['eventView']['filts'][index]['comparator_name'] = '等于';
|
||||||
data['eventView']['filts'][index]['comparator_id'] = '==';
|
data['eventView']['filts'][index]['comparator'] = '==';
|
||||||
data['eventView']['filts'][index]['tableType'] = val.tableType;
|
data['eventView']['filts'][index]['tableType'] = val.table_type;
|
||||||
filtsftvdata[index]=val.category;
|
filtsftvdata[index]=val.category;
|
||||||
analysisdown();//渲染下拉框
|
analysisdown();//渲染下拉框
|
||||||
})
|
})
|
||||||
@ -8162,7 +8200,7 @@ var X = window.X || {
|
|||||||
X.laydropdown("#analysis-overall-situation-fuhao-"+i,filtsftvdata[i],function(val){
|
X.laydropdown("#analysis-overall-situation-fuhao-"+i,filtsftvdata[i],function(val){
|
||||||
$(this).html(val.title);
|
$(this).html(val.title);
|
||||||
data['eventView']['filts'][i]['comparator_name'] = val.title;
|
data['eventView']['filts'][i]['comparator_name'] = val.title;
|
||||||
data['eventView']['filts'][i]['comparator_id'] = val.id;
|
data['eventView']['filts'][i]['comparator'] = val.id;
|
||||||
if(val.id == "range"){
|
if(val.id == "range"){
|
||||||
data['eventView']['filts'][i]['ftv'] = [-1,1];
|
data['eventView']['filts'][i]['ftv'] = [-1,1];
|
||||||
}
|
}
|
||||||
@ -8173,6 +8211,14 @@ var X = window.X || {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
$(document).off('click','.analysis-overall-situation-input input').on('change','.analysis-overall-situation-input input',function(){
|
||||||
|
var index = $(this).attr('data-index');
|
||||||
|
var val = $(this).val();
|
||||||
|
var valarr = val.split(",");
|
||||||
|
data['eventView']['filts'][index]['ftv']=valarr;
|
||||||
|
data['eventView']['filts'][index]['strftv']=val;
|
||||||
|
})
|
||||||
|
|
||||||
// 分组项
|
// 分组项
|
||||||
$(document).off('click','.analysis-action-right').on('click','.analysis-action-right',function() {
|
$(document).off('click','.analysis-action-right').on('click','.analysis-action-right',function() {
|
||||||
var index = $(this).attr("data-index");
|
var index = $(this).attr("data-index");
|
||||||
@ -8200,7 +8246,6 @@ var X = window.X || {
|
|||||||
var offset = obj.offset();
|
var offset = obj.offset();
|
||||||
var index = obj.attr("data-index");
|
var index = obj.attr("data-index");
|
||||||
X.querycriteriapop(groupitemeventsdata[0],'category',offset.left,offset.top+obj.height(),function(val){
|
X.querycriteriapop(groupitemeventsdata[0],'category',offset.left,offset.top+obj.height(),function(val){
|
||||||
console.log(val);
|
|
||||||
var htmlstring = val.title;
|
var htmlstring = val.title;
|
||||||
obj.html(htmlstring);
|
obj.html(htmlstring);
|
||||||
data.eventView.groupBy[index]['columnName'] = val.title;
|
data.eventView.groupBy[index]['columnName'] = val.title;
|
||||||
@ -8215,9 +8260,9 @@ var X = window.X || {
|
|||||||
var obj = $(this);
|
var obj = $(this);
|
||||||
var offset = obj.offset();
|
var offset = obj.offset();
|
||||||
// if(querydata){
|
// if(querydata){
|
||||||
X.querycriteriapop(data,'conditionquery',offset.left - 410,offset.top+obj.height(),function(){
|
X.querycriteriapop(data,'conditionquery',offset.left - 410,offset.top+obj.height(),function(){
|
||||||
|
|
||||||
})
|
})
|
||||||
// }else {
|
// }else {
|
||||||
// layer.msg('请先计算');
|
// layer.msg('请先计算');
|
||||||
// }
|
// }
|
||||||
@ -8255,6 +8300,7 @@ var X = window.X || {
|
|||||||
|
|
||||||
// 计算按钮
|
// 计算按钮
|
||||||
$(document).off('click','.analysis-calculation').on('click','.analysis-calculation',function(){
|
$(document).off('click','.analysis-calculation').on('click','.analysis-calculation',function(){
|
||||||
|
// console.log(data);
|
||||||
retaineddata()
|
retaineddata()
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -9698,6 +9744,63 @@ var X = window.X || {
|
|||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
|
// srczip/logic/setupbaobiao.js
|
||||||
|
(function(){
|
||||||
|
X.pageLogic['setupbaobiao'] = {
|
||||||
|
init : function(parms){
|
||||||
|
var me = this;
|
||||||
|
this.parms = parms;
|
||||||
|
var data = parms.extData;
|
||||||
|
var report_id = [];
|
||||||
|
console.log(data);
|
||||||
|
report_id.push(data.id);
|
||||||
|
X.api('report/read_report','post',{project_id:X.DATA.projectid,report_id:report_id},function(d){
|
||||||
|
console.log(d);
|
||||||
|
$('.setupbaobiao-title').val(d[0]['name']);
|
||||||
|
$('.setupbaobiao-textarea').html(d[0]['desc']);
|
||||||
|
// 初始化时间
|
||||||
|
var endTime = d[0]['query']['eventView']['endTime'];
|
||||||
|
var startTime = d[0]['query']['eventView']['startTime'];
|
||||||
|
$(".setupbaobiao-time").html(startTime +' - '+ endTime);
|
||||||
|
if(data.modeltype == "table"){ //初始化图表类型
|
||||||
|
$("#setupbaobiao-table").addClass("icon___XxbtJ");
|
||||||
|
}else {
|
||||||
|
$("#setupbaobiao-echarts").addClass("icon___XxbtJ");
|
||||||
|
}
|
||||||
|
//初始化窗体大小
|
||||||
|
if(data.modelsize == 'in'){ //中图
|
||||||
|
$("#setupbaobiao-in").prop("checked",true);
|
||||||
|
}else if( data.modelsize == 'small' ){//小图
|
||||||
|
$("#setupbaobiao-small").prop("checked",true);
|
||||||
|
}else{//大图
|
||||||
|
$("#setupbaobiao-large").prop("checked",true);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
X.daterender(".setupbaobiao-rli-box2",function(start, end, label){
|
||||||
|
var startTime = start.format('YYYY-MM-DD')+ " "+ "00:00:00";
|
||||||
|
var endTime = end.format('YYYY-MM-DD')+ " "+ "23:59:59";
|
||||||
|
console.log(startTime);
|
||||||
|
console.log(endTime);
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
$(document).off('click','.shape___2nUUi').on('click','.shape___2nUUi',function(){
|
||||||
|
$('.shape___2nUUi').removeClass('icon___XxbtJ');
|
||||||
|
$(this).addClass('icon___XxbtJ');
|
||||||
|
});
|
||||||
|
|
||||||
|
$(document).off('click','.setupbaobiao-xq').on('click','.setupbaobiao-xq',function(){
|
||||||
|
layer.closeAll();
|
||||||
|
});
|
||||||
|
|
||||||
|
$(document).off('click','.setupbaobiao-yy').on('click','.setupbaobiao-yy',function(){
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
})();
|
||||||
// srczip/logic/sqlquery.js
|
// srczip/logic/sqlquery.js
|
||||||
(function(){
|
(function(){
|
||||||
X.pageLogic['sqlquery'] = {
|
X.pageLogic['sqlquery'] = {
|
||||||
|
@ -24,6 +24,11 @@ var X = window.X || {
|
|||||||
{'title':'复制看板','img':'fuzhi.png','click':'copy'}
|
{'title':'复制看板','img':'fuzhi.png','click':'copy'}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
'gengduolist':[
|
||||||
|
{'title':'报表设置','id':'shezhi'},
|
||||||
|
{'title':'数据导出','id':'export'},
|
||||||
|
{'title':'报表移除','id':'del'},
|
||||||
|
],
|
||||||
//用户搜索条件
|
//用户搜索条件
|
||||||
'search':{
|
'search':{
|
||||||
category:[
|
category:[
|
||||||
@ -341,7 +346,7 @@ var X = window.X || {
|
|||||||
'今日': [moment(), moment()],
|
'今日': [moment(), moment()],
|
||||||
'昨日': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
|
'昨日': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
|
||||||
'最近7日': [moment().subtract(7, 'days'), moment().subtract(0, 'days')],
|
'最近7日': [moment().subtract(7, 'days'), moment().subtract(0, 'days')],
|
||||||
'最近30日': [moment().subtract(30, 'days'), moment().subtract(1, 'days')],
|
'最近30日': [moment().subtract(30, 'days'), moment().subtract(0, 'days')],
|
||||||
'上周': [moment().subtract(1, 'week').startOf('week')+86400000, moment().subtract(1, 'week').endOf('week')+86400000],
|
'上周': [moment().subtract(1, 'week').startOf('week')+86400000, moment().subtract(1, 'week').endOf('week')+86400000],
|
||||||
'本周': [moment().startOf('week')+86400000, moment()+86400000],
|
'本周': [moment().startOf('week')+86400000, moment()+86400000],
|
||||||
'本月': [moment().startOf('month'), moment()],
|
'本月': [moment().startOf('month'), moment()],
|
||||||
|
@ -519,7 +519,7 @@
|
|||||||
})
|
})
|
||||||
|
|
||||||
});
|
});
|
||||||
console.log(eventdata);
|
|
||||||
// 留存分析模板特定留存流失按钮
|
// 留存分析模板特定留存流失按钮
|
||||||
var retentionlist = [
|
var retentionlist = [
|
||||||
{'title':'留存','id':0},
|
{'title':'留存','id':0},
|
||||||
@ -540,8 +540,40 @@
|
|||||||
})
|
})
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
};
|
||||||
|
|
||||||
|
//更多按钮配置下拉框
|
||||||
|
X.laydropdown(".model-gengduo",X['DATA']['gengduolist'],function(d){
|
||||||
|
console.log(eventdata);
|
||||||
|
if(d.id == 'shezhi'){
|
||||||
|
var data = {
|
||||||
|
id : eventdata.id,
|
||||||
|
modelsize : eventdata.modelsize,
|
||||||
|
modeltype : eventdata.modeltype
|
||||||
|
}
|
||||||
|
X.parametersopen(data,'setupbaobiao',"auto",function(d){
|
||||||
|
|
||||||
|
})
|
||||||
|
}else if(d.id == 'export'){
|
||||||
|
layer.msg('暂未开放功能');
|
||||||
|
}else {
|
||||||
|
|
||||||
|
layer.confirm('确认移除['+ eventdata.name + ']', {
|
||||||
|
btn: ['取消','删除 '] //按钮
|
||||||
|
}, function(){
|
||||||
|
//取消
|
||||||
|
layer.close(layer.index);
|
||||||
|
}, function(){
|
||||||
|
//删除
|
||||||
|
X.api('dashboard/del_report','post',{_id:X['DATA']['dashboard_id'],report_id:eventdata.id},function(){
|
||||||
|
X.pageLogic['dashboard'].gettabledata();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
if(eventdata['modeltype'] == 'echarts' && eventdata['modelsize'] != 'small' ){
|
if(eventdata['modeltype'] == 'echarts' && eventdata['modelsize'] != 'small' ){
|
||||||
var myChart = echarts.init(document.getElementById(eventdata['id']));
|
var myChart = echarts.init(document.getElementById(eventdata['id']));
|
||||||
|
@ -329,7 +329,7 @@
|
|||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
$(document).off('click','.analysis-zhibiao-list-type4 input').on('change','.analysis-zhibiao-list-type4 input',function(){
|
$(document).off('change','.analysis-zhibiao-list-type4 input').on('change','.analysis-zhibiao-list-type4 input',function(){
|
||||||
var index = $(this).attr('data-index');
|
var index = $(this).attr('data-index');
|
||||||
var indexs = $(this).attr('data-indexs');
|
var indexs = $(this).attr('data-indexs');
|
||||||
var txt = $(this).val();
|
var txt = $(this).val();
|
||||||
@ -342,12 +342,13 @@
|
|||||||
var filtsftvdata=[];
|
var filtsftvdata=[];
|
||||||
$(document).off('click','.analysis-overall-situation-add').on('click','.analysis-overall-situation-add',function(){
|
$(document).off('click','.analysis-overall-situation-add').on('click','.analysis-overall-situation-add',function(){
|
||||||
var screentypedata = groupitemeventsdata[0];
|
var screentypedata = groupitemeventsdata[0];
|
||||||
|
console.log(screentypedata);
|
||||||
var drr={
|
var drr={
|
||||||
"columnName":screentypedata[0]['category'][0]['title'],//事件中文显示
|
"columnName":screentypedata[0]['category'][0]['title'],//事件中文显示
|
||||||
"column_id":screentypedata[0]['category'][0]['id'],//事件id
|
"column_id":screentypedata[0]['category'][0]['id'],//事件id
|
||||||
'data_type':screentypedata[0]['category'][0]['data_type'],//类型
|
'data_type':screentypedata[0]['category'][0]['data_type'],//类型
|
||||||
'comparator_name':'等于',//默认等于
|
'comparator_name':'等于',//默认等于
|
||||||
"comparator_id":'==',//符号id
|
"comparator":'==',//符号id
|
||||||
"ftv":[],//条件
|
"ftv":[],//条件
|
||||||
"strftv":'',//显示条件
|
"strftv":'',//显示条件
|
||||||
"section":[-1,1],//区间
|
"section":[-1,1],//区间
|
||||||
@ -391,8 +392,8 @@
|
|||||||
data['eventView']['filts'][index]['column_id'] = val.id;
|
data['eventView']['filts'][index]['column_id'] = val.id;
|
||||||
data['eventView']['filts'][index]['data_type'] = val.type;
|
data['eventView']['filts'][index]['data_type'] = val.type;
|
||||||
data['eventView']['filts'][index]['comparator_name'] = '等于';
|
data['eventView']['filts'][index]['comparator_name'] = '等于';
|
||||||
data['eventView']['filts'][index]['comparator_id'] = '==';
|
data['eventView']['filts'][index]['comparator'] = '==';
|
||||||
data['eventView']['filts'][index]['tableType'] = val.tableType;
|
data['eventView']['filts'][index]['tableType'] = val.table_type;
|
||||||
filtsftvdata[index]=val.category;
|
filtsftvdata[index]=val.category;
|
||||||
analysisdown();//渲染下拉框
|
analysisdown();//渲染下拉框
|
||||||
})
|
})
|
||||||
@ -404,7 +405,7 @@
|
|||||||
X.laydropdown("#analysis-overall-situation-fuhao-"+i,filtsftvdata[i],function(val){
|
X.laydropdown("#analysis-overall-situation-fuhao-"+i,filtsftvdata[i],function(val){
|
||||||
$(this).html(val.title);
|
$(this).html(val.title);
|
||||||
data['eventView']['filts'][i]['comparator_name'] = val.title;
|
data['eventView']['filts'][i]['comparator_name'] = val.title;
|
||||||
data['eventView']['filts'][i]['comparator_id'] = val.id;
|
data['eventView']['filts'][i]['comparator'] = val.id;
|
||||||
if(val.id == "range"){
|
if(val.id == "range"){
|
||||||
data['eventView']['filts'][i]['ftv'] = [-1,1];
|
data['eventView']['filts'][i]['ftv'] = [-1,1];
|
||||||
}
|
}
|
||||||
@ -415,6 +416,14 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
$(document).off('click','.analysis-overall-situation-input input').on('change','.analysis-overall-situation-input input',function(){
|
||||||
|
var index = $(this).attr('data-index');
|
||||||
|
var val = $(this).val();
|
||||||
|
var valarr = val.split(",");
|
||||||
|
data['eventView']['filts'][index]['ftv']=valarr;
|
||||||
|
data['eventView']['filts'][index]['strftv']=val;
|
||||||
|
})
|
||||||
|
|
||||||
// 分组项
|
// 分组项
|
||||||
$(document).off('click','.analysis-action-right').on('click','.analysis-action-right',function() {
|
$(document).off('click','.analysis-action-right').on('click','.analysis-action-right',function() {
|
||||||
var index = $(this).attr("data-index");
|
var index = $(this).attr("data-index");
|
||||||
@ -442,7 +451,6 @@
|
|||||||
var offset = obj.offset();
|
var offset = obj.offset();
|
||||||
var index = obj.attr("data-index");
|
var index = obj.attr("data-index");
|
||||||
X.querycriteriapop(groupitemeventsdata[0],'category',offset.left,offset.top+obj.height(),function(val){
|
X.querycriteriapop(groupitemeventsdata[0],'category',offset.left,offset.top+obj.height(),function(val){
|
||||||
console.log(val);
|
|
||||||
var htmlstring = val.title;
|
var htmlstring = val.title;
|
||||||
obj.html(htmlstring);
|
obj.html(htmlstring);
|
||||||
data.eventView.groupBy[index]['columnName'] = val.title;
|
data.eventView.groupBy[index]['columnName'] = val.title;
|
||||||
@ -497,6 +505,7 @@
|
|||||||
|
|
||||||
// 计算按钮
|
// 计算按钮
|
||||||
$(document).off('click','.analysis-calculation').on('click','.analysis-calculation',function(){
|
$(document).off('click','.analysis-calculation').on('click','.analysis-calculation',function(){
|
||||||
|
// console.log(data);
|
||||||
retaineddata()
|
retaineddata()
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
margin-top: 7px;
|
margin-top: 7px;
|
||||||
top: 100px;
|
top: 100px;
|
||||||
left: 20px;
|
left: 20px;
|
||||||
z-index: 19891015;
|
z-index: 199891015;
|
||||||
display: none;
|
display: none;
|
||||||
font-family: arial;
|
font-family: arial;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
|
@ -23,6 +23,36 @@
|
|||||||
/* .layui-nav .layui-nav-child dd.layui-this a, .layui-nav-child dd.layui-this { background-color: #f6f8fa !important; } */
|
/* .layui-nav .layui-nav-child dd.layui-this a, .layui-nav-child dd.layui-this { background-color: #f6f8fa !important; } */
|
||||||
.controlhover:hover > .control { display: block; }
|
.controlhover:hover > .control { display: block; }
|
||||||
|
|
||||||
|
::-webkit-scrollbar {
|
||||||
|
width:5px;
|
||||||
|
height:5px;
|
||||||
|
background-color:#F5F5F5;
|
||||||
|
}
|
||||||
|
/* 滚动条上的按钮 (上下箭头). */
|
||||||
|
::-webkit-scrollbar-button {
|
||||||
|
height: 0px;
|
||||||
|
width: 0px;
|
||||||
|
}
|
||||||
|
/* 滚动条上的滚动滑块. */
|
||||||
|
::-webkit-scrollbar-thumb {
|
||||||
|
background-color:#e6e6e6;
|
||||||
|
border-radius: 50px;
|
||||||
|
}
|
||||||
|
/* 滚动条轨道. */
|
||||||
|
::-webkit-scrollbar-track {
|
||||||
|
-webkit-box-shadow:inset 0 0 6px rgba(0, 142, 255, 1);
|
||||||
|
box-shadow:inset 0 0 6px rgba(0, 142, 255, 1, 1);
|
||||||
|
background-color:#F5F5F5;
|
||||||
|
}
|
||||||
|
/* 滚动条没有滑块的轨道部分 */
|
||||||
|
::-webkit-scrollbar-track-piece {
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
/* 当同时有垂直滚动条和水平滚动条时交汇的部分. */
|
||||||
|
::-webkit-scrollbar-corner {
|
||||||
|
background:transparent;
|
||||||
|
}
|
||||||
|
|
||||||
.dad-noSelect,.dad-noSelect *{
|
.dad-noSelect,.dad-noSelect *{
|
||||||
-webkit-touch-callout: none;
|
-webkit-touch-callout: none;
|
||||||
-webkit-user-select: none;
|
-webkit-user-select: none;
|
||||||
@ -533,6 +563,34 @@ label:not(.form-check-label):not(.custom-file-label) { font-weight: 400; }
|
|||||||
.fu { transform:rotate(180deg); border-bottom: 3px solid #ff5d5d; }
|
.fu { transform:rotate(180deg); border-bottom: 3px solid #ff5d5d; }
|
||||||
.funum { color: #ff5d5d !important; }
|
.funum { color: #ff5d5d !important; }
|
||||||
|
|
||||||
/* 重命名 */
|
/* 报表设置 */
|
||||||
|
.setupbaobiao-box { width: 880px; height: 460px; }
|
||||||
|
.setupbaobiao-top-box { padding: 0 20px; font-size: 14px; height: 60px; display: flex; align-items: center; justify-content: space-between; background-color: #f0f2f5; }
|
||||||
|
.setupbaobiao-but-box { display: flex; align-items: center; }
|
||||||
|
.setupbaobiao-xq{ padding-right: 20px; cursor: pointer; color: #42546d; }
|
||||||
|
.setupbaobiao-xq:hover { color: #4fa1ff; }
|
||||||
|
.setupbaobiao-yy { color: #fff; line-height: 30px; background-color: #3d90ff; height: 32px; padding: 0 16px; border-radius: 2px; cursor: pointer; }
|
||||||
|
.setupbaobiao-yy:hover { background-color: #4fa1ff; }
|
||||||
|
.setupbaobiao-top-box p { color: #42546d; }
|
||||||
|
.setupbaobiao-content-box { display: flex; }
|
||||||
|
.setupbaobiao-left-box { width: 50%; min-height: 400px; padding-bottom: 0px; border-right: 1px solid #f0f0f0; }
|
||||||
|
.setupbaobiao-right-box { width: 50%; min-height: 400px; padding-bottom: 0px; }
|
||||||
|
.setupbaobiao-con-top-box { font-size: 12px; color: #42546d; height: 60px; padding: 0 0 0 20px; line-height: 60px; border-bottom: 1px solid #f0f0f0; }
|
||||||
|
.setupbaobiao-left-from { padding-top: 16px; }
|
||||||
|
.setupbaobiao-left-from-list-box { display: flex; align-items: flex-start; width: 100%; min-height: 50px; margin-bottom: 10px; padding-left: 20px; padding-right: 10px; }
|
||||||
|
.setupbaobiao-left-from-list-title { color: #42546d; display: flex; align-items: center; width: 120px; height: 32px; font-weight: 500; font-size: 14px; line-height: 16px; }
|
||||||
|
.setupbaobiao-left-from-list-input { display: inline-block; width: 100%; line-height: 32px; }
|
||||||
|
.setupbaobiao-left-from-list-input input { width: 240px; height: 32px; padding: 0 8px; color: #42546d; font-size: 14px; line-height: 30px; border: 1px solid #f0f0f0; border-radius: 2px; }
|
||||||
|
.setupbaobiao-left-from-list-input select { appearance:none; -moz-appearance:none; -webkit-appearance:none; background: url("http://ourjs.github.io/static/2015/arrow.png") no-repeat scroll 90% center transparent; height: 32px; line-height: 30px; padding: 0 24px 0 8px; color: #42546d; font-size: 13px; border: 1px solid #f0f0f0; border-radius: 2px; }
|
||||||
|
.setupbaobiao-left-from-list-input textarea { resize: none; width: 240px; min-height: 32px; padding: 0 8px; color: #42546d; font-size: 14px; line-height: 30px; border: 1px solid #f0f0f0; border-radius: 2px; }
|
||||||
|
.setupbaobiao-right-from { padding-top: 16px; overflow: hidden; }
|
||||||
|
.setupbaobiao-rli-box { width: 100%; line-height: 32px; }
|
||||||
|
.setupbaobiao-rli-box2 { display: inline-block; min-width: 80px; height: 28px; padding: 0 8px; font-size: 13px; line-height: 26px; border: 1px solid #f0f0f0; border-radius: 2px; cursor: pointer; color: #42546d; }
|
||||||
|
.setupbaobiao-charttype { display: flex; align-items: center; }
|
||||||
|
.shape___2nUUi { width: 28px; height: 28px; color: #67729d; line-height: 28px; text-align: center; border: 1px solid #f0f0f0; cursor: pointer; }
|
||||||
|
.icon___XxbtJ { color: #fff; background: #3d90ff; }
|
||||||
|
.setupbaobiao-left-from-list-radio { display: inline-block; width: 100%; line-height: 32px; }
|
||||||
|
.setupbaobiao-left-from-list-radio-box { display: flex; color: #42546d; }
|
||||||
|
.setupbaobiao-left-from-list-radio-box input { position: relative; top: 2px; margin-right: 5px; }
|
||||||
|
.setupbaobiao-zs { color: #42546d; font-size: 12px; line-height: 20px; margin-bottom: 10px; padding: 0 10px 0 20px; }
|
||||||
|
|
||||||
|
@ -54,6 +54,12 @@
|
|||||||
<div class="content unicode" style="display: block;">
|
<div class="content unicode" style="display: block;">
|
||||||
<ul class="icon_lists dib-box">
|
<ul class="icon_lists dib-box">
|
||||||
|
|
||||||
|
<li class="dib">
|
||||||
|
<span class="icon iconfont"></span>
|
||||||
|
<div class="name">点</div>
|
||||||
|
<div class="code-name">&#xe759;</div>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li class="dib">
|
<li class="dib">
|
||||||
<span class="icon iconfont"></span>
|
<span class="icon iconfont"></span>
|
||||||
<div class="name">流失</div>
|
<div class="name">流失</div>
|
||||||
@ -120,9 +126,9 @@
|
|||||||
<pre><code class="language-css"
|
<pre><code class="language-css"
|
||||||
>@font-face {
|
>@font-face {
|
||||||
font-family: 'iconfont';
|
font-family: 'iconfont';
|
||||||
src: url('iconfont.woff2?t=1623376633178') format('woff2'),
|
src: url('iconfont.woff2?t=1629862645788') format('woff2'),
|
||||||
url('iconfont.woff?t=1623376633178') format('woff'),
|
url('iconfont.woff?t=1629862645788') format('woff'),
|
||||||
url('iconfont.ttf?t=1623376633178') format('truetype');
|
url('iconfont.ttf?t=1629862645788') format('truetype');
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
|
<h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
|
||||||
@ -148,6 +154,15 @@
|
|||||||
<div class="content font-class">
|
<div class="content font-class">
|
||||||
<ul class="icon_lists dib-box">
|
<ul class="icon_lists dib-box">
|
||||||
|
|
||||||
|
<li class="dib">
|
||||||
|
<span class="icon iconfont icon-ic_normal_dot"></span>
|
||||||
|
<div class="name">
|
||||||
|
点
|
||||||
|
</div>
|
||||||
|
<div class="code-name">.icon-ic_normal_dot
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li class="dib">
|
<li class="dib">
|
||||||
<span class="icon iconfont icon-liushi"></span>
|
<span class="icon iconfont icon-liushi"></span>
|
||||||
<div class="name">
|
<div class="name">
|
||||||
@ -247,6 +262,14 @@
|
|||||||
<div class="content symbol">
|
<div class="content symbol">
|
||||||
<ul class="icon_lists dib-box">
|
<ul class="icon_lists dib-box">
|
||||||
|
|
||||||
|
<li class="dib">
|
||||||
|
<svg class="icon svg-icon" aria-hidden="true">
|
||||||
|
<use xlink:href="#icon-ic_normal_dot"></use>
|
||||||
|
</svg>
|
||||||
|
<div class="name">点</div>
|
||||||
|
<div class="code-name">#icon-ic_normal_dot</div>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li class="dib">
|
<li class="dib">
|
||||||
<svg class="icon svg-icon" aria-hidden="true">
|
<svg class="icon svg-icon" aria-hidden="true">
|
||||||
<use xlink:href="#icon-liushi"></use>
|
<use xlink:href="#icon-liushi"></use>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
@font-face {
|
@font-face {
|
||||||
font-family: "iconfont"; /* Project id 2570810 */
|
font-family: "iconfont"; /* Project id 2570810 */
|
||||||
src: url('iconfont.woff2?t=1623376633178') format('woff2'),
|
src: url('iconfont.woff2?t=1629862645788') format('woff2'),
|
||||||
url('iconfont.woff?t=1623376633178') format('woff'),
|
url('iconfont.woff?t=1629862645788') format('woff'),
|
||||||
url('iconfont.ttf?t=1623376633178') format('truetype');
|
url('iconfont.ttf?t=1629862645788') format('truetype');
|
||||||
}
|
}
|
||||||
|
|
||||||
.iconfont {
|
.iconfont {
|
||||||
@ -13,6 +13,10 @@
|
|||||||
-moz-osx-font-smoothing: grayscale;
|
-moz-osx-font-smoothing: grayscale;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.icon-ic_normal_dot:before {
|
||||||
|
content: "\e759";
|
||||||
|
}
|
||||||
|
|
||||||
.icon-liushi:before {
|
.icon-liushi:before {
|
||||||
content: "\e601";
|
content: "\e601";
|
||||||
}
|
}
|
||||||
|
File diff suppressed because one or more lines are too long
@ -5,6 +5,13 @@
|
|||||||
"css_prefix_text": "icon-",
|
"css_prefix_text": "icon-",
|
||||||
"description": "",
|
"description": "",
|
||||||
"glyphs": [
|
"glyphs": [
|
||||||
|
{
|
||||||
|
"icon_id": "16373588",
|
||||||
|
"name": "点",
|
||||||
|
"font_class": "ic_normal_dot",
|
||||||
|
"unicode": "e759",
|
||||||
|
"unicode_decimal": 59225
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"icon_id": "2332742",
|
"icon_id": "2332742",
|
||||||
"name": "流失",
|
"name": "流失",
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 230 B |
Loading…
Reference in New Issue
Block a user