mirror of
https://github.com/tencentmusic/supersonic.git
synced 2026-04-30 04:54:25 +08:00
Compare commits
2 Commits
cc2d6a21c2
...
f804371134
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f804371134 | ||
|
|
d6620e6ea7 |
@@ -1,7 +1,7 @@
|
||||
package com.tencent.supersonic.common.pojo.enums;
|
||||
|
||||
public enum AggOperatorEnum {
|
||||
ANY("ANY"),
|
||||
NONE(""),
|
||||
|
||||
MAX("MAX"),
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ public class ColumnSchema {
|
||||
|
||||
private FieldType filedType;
|
||||
|
||||
private AggOperatorEnum agg = AggOperatorEnum.ANY;
|
||||
private AggOperatorEnum agg = AggOperatorEnum.NONE;
|
||||
|
||||
private String name;
|
||||
|
||||
|
||||
@@ -110,7 +110,7 @@ public class MetricExpressionParser implements QueryParser {
|
||||
if (allMeasures.containsKey(field)) {
|
||||
Measure measure = allMeasures.get(field);
|
||||
String expr = metricExpr;
|
||||
if (Objects.nonNull(measure.getAgg())) {
|
||||
if (StringUtils.isNotBlank(measure.getAgg())) {
|
||||
expr = String.format("%s (%s)", measure.getAgg(), metricExpr);
|
||||
}
|
||||
replace.put(field, expr);
|
||||
|
||||
@@ -137,5 +137,6 @@
|
||||
"engines": {
|
||||
"node": ">=16.0.0"
|
||||
},
|
||||
"__npminstall_done": false
|
||||
"__npminstall_done": false,
|
||||
"packageManager": "pnpm@9.12.3+sha512.cce0f9de9c5a7c95bef944169cc5dfe8741abfb145078c0d508b868056848a87c81e626246cb60967cbd7fd29a6c062ef73ff840d96b3c86c40ac92cf4a813ee"
|
||||
}
|
||||
|
||||
@@ -3,7 +3,8 @@ import { Form, Input, message, Modal } from 'antd';
|
||||
import { useBoolean } from 'ahooks';
|
||||
import { changePassword } from '@/services/user';
|
||||
import { pick } from 'lodash';
|
||||
import { encryptPassword, encryptKey } from '@/utils/utils';
|
||||
import { encryptPassword } from '@/utils/utils';
|
||||
import CryptoJS from 'crypto-js';
|
||||
|
||||
export interface IRef {
|
||||
open: () => void;
|
||||
@@ -14,6 +15,7 @@ const ChangePasswordModal = forwardRef<IRef>((_, ref) => {
|
||||
const [form] = Form.useForm();
|
||||
const [open, { setTrue: openModal, setFalse: closeModal }] = useBoolean(false);
|
||||
const [confirmLoading, { set: setConfirmLoading }] = useBoolean(false);
|
||||
const encryptKey = CryptoJS.enc.Utf8.parse('supersonic@2024');
|
||||
|
||||
useImperativeHandle(ref, () => ({
|
||||
open: () => {
|
||||
|
||||
@@ -76,7 +76,7 @@ const ModelFieldForm: React.FC<Props> = ({
|
||||
|
||||
const columns = [
|
||||
{
|
||||
title: '英文名称',
|
||||
title: '字段名称',
|
||||
dataIndex: 'fieldName',
|
||||
width: 250,
|
||||
},
|
||||
@@ -204,29 +204,8 @@ const ModelFieldForm: React.FC<Props> = ({
|
||||
{
|
||||
title: '扩展配置',
|
||||
dataIndex: 'extender',
|
||||
// width: 200,
|
||||
render: (_: any, record: FieldItem) => {
|
||||
const { type } = record;
|
||||
// if (type === EnumDataSourceType.PRIMARY) {
|
||||
// return (
|
||||
// <Space>
|
||||
// <Select
|
||||
// style={{ minWidth: 150 }}
|
||||
// value={tagObjectId ? tagObjectId : undefined}
|
||||
// placeholder="请选择所属对象"
|
||||
// onChange={(value) => {
|
||||
// onTagObjectChange?.(value);
|
||||
// }}
|
||||
// options={tagObjectList.map((item: ISemantic.ITagObjectItem) => {
|
||||
// return {
|
||||
// label: item.name,
|
||||
// value: item.id,
|
||||
// };
|
||||
// })}
|
||||
// />
|
||||
// </Space>
|
||||
// );
|
||||
// }
|
||||
if (type === EnumDataSourceType.MEASURES) {
|
||||
return (
|
||||
<Select
|
||||
|
||||
@@ -110,6 +110,10 @@ export const AGG_OPTIONS = [
|
||||
label: 'count_distinct',
|
||||
value: 'count_distinct',
|
||||
},
|
||||
{
|
||||
label: 'none',
|
||||
value: '',
|
||||
},
|
||||
];
|
||||
|
||||
export const DATE_OPTIONS = ['day', 'week', 'month'];
|
||||
|
||||
@@ -156,7 +156,9 @@ export const genneratorFormItemList = (itemList: ConfigParametersItem[]) => {
|
||||
|
||||
break;
|
||||
case 'password': {
|
||||
defaultItem = <Input.Password placeholder={placeholder} />;
|
||||
defaultItem = (
|
||||
<Input.Password placeholder={placeholder} visibilityToggle={name !== 'apiKey'} />
|
||||
);
|
||||
break;
|
||||
}
|
||||
case 'longText':
|
||||
|
||||
Reference in New Issue
Block a user