|
|
@@ -13,32 +13,17 @@ function getBodyFilters(filters) {
|
|
|
symbol: operator,
|
|
|
value: value1
|
|
|
};
|
|
|
- if(type === 'string' || type === 'index') {
|
|
|
- if(operator === 'null' || operator === 'notNull') {
|
|
|
- }else {
|
|
|
- bodyFilter['value'] = value1;
|
|
|
- }
|
|
|
- }else if(type === 'scale') {
|
|
|
- if(operator === 'null' || operator === 'notNull') {
|
|
|
- }else if(operator === 'between') {
|
|
|
- bodyFilter['value'] = value1 + ',' + value2;
|
|
|
- }else {
|
|
|
- }
|
|
|
+ if(type === 'scale' && operator === 'between') {
|
|
|
+ bodyFilter['value'] = value1 + ',' + value2;
|
|
|
}else if(type === 'time') {
|
|
|
let v1 = dateFormat(new Date(value1),'yyyy-MM-dd hh:mm:ss');
|
|
|
let v2 = dateFormat(new Date(value2),'yyyy-MM-dd hh:mm:ss');
|
|
|
|
|
|
- if(operator === 'null' || operator === 'notNull') {
|
|
|
- }else if(operator === 'between') {
|
|
|
+ if(operator === 'between') {
|
|
|
bodyFilter['value'] = v1 + ',' + v2;
|
|
|
}else {
|
|
|
bodyFilter['value'] = v1;
|
|
|
}
|
|
|
- }else if(type === 'categorical') {
|
|
|
- if(operator === 'null' || operator === 'notNull') {
|
|
|
- }else {
|
|
|
- }
|
|
|
- }else {
|
|
|
}
|
|
|
return bodyFilter;
|
|
|
});
|
|
|
@@ -195,7 +180,7 @@ export default {
|
|
|
const { baseConfig } = chartDesigner;
|
|
|
|
|
|
let body = {
|
|
|
- chartName: dataSource.name + '(未命名)',
|
|
|
+ chartName: dataSource.name + '_未命名',
|
|
|
dataId: baseConfig.dataSource,
|
|
|
groupBy: baseConfig.groupBy && baseConfig.groupBy.key ? [{
|
|
|
columnName: baseConfig.groupBy.key,
|