This commit is contained in:
zengqiao
2020-12-19 00:40:52 +08:00
parent 49280a8617
commit 447a575f4f
83 changed files with 1578 additions and 559 deletions

View File

@@ -597,7 +597,9 @@ class Admin {
}
public getTopicsBasicInfo(clusterId: number, topicName: string) {
return getTopicsBasicInfo(clusterId, topicName).then(this.setTopicsBasicInfo);
return getTopicsBasicInfo(clusterId, topicName).then(data => {
return this.setTopicsBasicInfo(data);
});
}
public getTasksKafkaFiles(clusterId?: any) {

View File

@@ -19,6 +19,9 @@ class Order {
@observable
public loading: boolean = false;
@observable
public selectedRows: any[] = [];
@observable
public orderList: IBaseOrder[] = [];
@@ -55,6 +58,15 @@ class Order {
this.loading = value;
}
@action.bound
public setSelectedRows(rows?: any[]) {
if (rows) {
this.selectedRows = rows;
} else {
this.selectedRows = [];
}
}
@action.bound
public setOrderList(data: IBaseOrder[]) {
this.orderList = data;

View File

@@ -22,8 +22,8 @@ class RegionCenter {
@observable
public regionIdcList: IRegionIdcs[] = [
{ name: '国内', idc: 'cn' },
{ name: '美东', idc: 'us' },
{ name: '俄罗斯', idc: 'ru' },
// { name: '美东', idc: 'us' },
// { name: '俄罗斯', idc: 'ru' },
];
@action.bound

View File

@@ -35,6 +35,8 @@ export interface ITopicBaseInfo {
score: number;
topicCodeC: string;
physicalClusterId: number;
percentile: string;
regionNameList: any;
}
export interface IRealTimeTraffic {
@@ -488,9 +490,9 @@ class Topic {
return getRealTimeTraffic(clusterId, topicName).then(this.setRealTimeTraffic);
}
public getRealConsume(clusterId: number, topicName: string) {
public getRealConsume(clusterId: number, topicName: string, percentile: string) {
this.setConsumeLoading(true);
return getRealConsume(clusterId, topicName).then(this.setRealConsume);
return getRealConsume(clusterId, topicName, percentile).then(this.setRealConsume);
}
public getConnectionInfo(clusterId: number, topicName: string, appId?: string) {

View File

@@ -8,7 +8,7 @@ interface IEnum {
suffix?: string;
}
interface IUploadFileType {
fileEnum: IEnum[] ;
fileEnum: IEnum[];
storageEnum: IEnum[];
}
@@ -44,11 +44,10 @@ export class Version {
@action.bound
public setFileList(data: IUploadFile[]) {
this.fileList = (data || []).map((item, index) => {
return {
...item,
configType: this.acceptFileMap[item.fileType],
configType: this.acceptFileMap[item.fileType] || '',
key: index,
};
});

View File

@@ -24,6 +24,7 @@ class Wrapper {
});
}
@action.bound
public setXFormWrapper(xFormWrapper: IXFormWrapper) {
this.xFormWrapper = xFormWrapper;