mirror of
https://github.com/clearml/clearml-web
synced 2025-05-08 22:09:54 +00:00
Added menus to pipeline cards
This commit is contained in:
parent
d9eed64770
commit
04c7a922cf
3
.gitignore
vendored
3
.gitignore
vendored
@ -48,3 +48,6 @@ gen-code
|
|||||||
# System Files
|
# System Files
|
||||||
.DS_Store
|
.DS_Store
|
||||||
Thumbs.db
|
Thumbs.db
|
||||||
|
|
||||||
|
# history
|
||||||
|
/.history
|
||||||
|
5
myreadme.md
Normal file
5
myreadme.md
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
D:\MyClearML>forclearml\Scripts\activate
|
||||||
|
python mypipeline.py
|
||||||
|
|
||||||
|
|
||||||
|
D:\MyClearML>clearml-agent daemon
|
19
package-lock.json
generated
19
package-lock.json
generated
@ -5374,6 +5374,16 @@
|
|||||||
"node": ">=14"
|
"node": ">=14"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@popperjs/core": {
|
||||||
|
"version": "2.11.8",
|
||||||
|
"resolved": "https://registry.npmjs.org/@popperjs/core/-/core-2.11.8.tgz",
|
||||||
|
"integrity": "sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==",
|
||||||
|
"peer": true,
|
||||||
|
"funding": {
|
||||||
|
"type": "opencollective",
|
||||||
|
"url": "https://opencollective.com/popperjs"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@schematics/angular": {
|
"node_modules/@schematics/angular": {
|
||||||
"version": "16.2.9",
|
"version": "16.2.9",
|
||||||
"resolved": "https://registry.npmjs.org/@schematics/angular/-/angular-16.2.9.tgz",
|
"resolved": "https://registry.npmjs.org/@schematics/angular/-/angular-16.2.9.tgz",
|
||||||
@ -10532,6 +10542,15 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/font-awesome": {
|
||||||
|
"version": "4.7.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz",
|
||||||
|
"integrity": "sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg==",
|
||||||
|
"peer": true,
|
||||||
|
"engines": {
|
||||||
|
"node": ">=0.10.3"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/for-each": {
|
"node_modules/for-each": {
|
||||||
"version": "0.3.3",
|
"version": "0.3.3",
|
||||||
"resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz",
|
"resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz",
|
||||||
|
@ -1,43 +1,41 @@
|
|||||||
const fs = require('fs');
|
const fs = require("fs");
|
||||||
|
|
||||||
const targets = [
|
const targets = ["http://localhost:8008"];
|
||||||
'https://api.trains-master.hosted.allegro.ai', // 1
|
|
||||||
];
|
|
||||||
|
|
||||||
const PROXY_CONFIG = {
|
const PROXY_CONFIG = {
|
||||||
'^/version.json$': {
|
"^/version.json$": {
|
||||||
bypass: (req, res, proxyOptions) => {
|
bypass: (req, res, proxyOptions) => {
|
||||||
let url;
|
let url;
|
||||||
if (req.url === '/version.json') {
|
if (req.url === "/version.json") {
|
||||||
url = 'src/version.json';
|
url = "src/version.json";
|
||||||
} else if (req.url === '/configuration.json') {
|
} else if (req.url === "/configuration.json") {
|
||||||
url = 'src/configuration.json';
|
url = "src/configuration.json";
|
||||||
} else if (req.url === '/onboarding.json') {
|
} else if (req.url === "/onboarding.json") {
|
||||||
url = 'src/onboarding.json';
|
url = "src/onboarding.json";
|
||||||
} else {
|
} else {
|
||||||
return req.url;
|
return req.url;
|
||||||
}
|
}
|
||||||
|
|
||||||
const ver = fs.readFileSync(url);
|
const ver = fs.readFileSync(url);
|
||||||
res.writeHead(200, {
|
res.writeHead(200, {
|
||||||
'Content-Length': ver.length,
|
"Content-Length": ver.length,
|
||||||
'Content-Type': 'application/json'
|
"Content-Type": "application/json",
|
||||||
});
|
});
|
||||||
res.end(ver);
|
res.end(ver);
|
||||||
return true;
|
return true;
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
targets.forEach((target, i) => {
|
targets.forEach((target, i) => {
|
||||||
const path = `/service/${i+1}/api`;
|
const path = `/service/${i + 1}/api`;
|
||||||
PROXY_CONFIG[path + '/*'] = {
|
PROXY_CONFIG[path + "/*"] = {
|
||||||
target: target,
|
target: target,
|
||||||
secure: false,
|
secure: false,
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
[path]: ''
|
[path]: "",
|
||||||
}
|
},
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -64,6 +64,7 @@ export const ICONS = {
|
|||||||
METRICS: 'fa-chart-area',
|
METRICS: 'fa-chart-area',
|
||||||
TOKEN: 'fa-key',
|
TOKEN: 'fa-key',
|
||||||
EDIT: 'al-ico-edit',
|
EDIT: 'al-ico-edit',
|
||||||
|
EDIT2: 'fa-pen-to-square',
|
||||||
EDITABLE: 'fa-pencil',
|
EDITABLE: 'fa-pencil',
|
||||||
RESET: 'al-ico-reset',
|
RESET: 'al-ico-reset',
|
||||||
CLONE: 'al-ico-clone',
|
CLONE: 'al-ico-clone',
|
||||||
|
@ -2,6 +2,12 @@
|
|||||||
class="p-0 cell menu-button al-icon al-color blue-300 al-ico-bars-menu"
|
class="p-0 cell menu-button al-icon al-color blue-300 al-ico-bars-menu"
|
||||||
></div>
|
></div>
|
||||||
<mat-menu #pipelinesMenu="matMenu">
|
<mat-menu #pipelinesMenu="matMenu">
|
||||||
|
<button mat-menu-item (click)="edit.emit()">
|
||||||
|
<i class="fa-solid al-icon sm-md" [class]="icons.EDIT2"></i>Edit
|
||||||
|
</button>
|
||||||
|
<button mat-menu-item (click)="runs.emit()">
|
||||||
|
<i class="al-icon sm-md" [class]="icons.RUN"></i>Runs
|
||||||
|
</button>
|
||||||
<button mat-menu-item (click)="rename.emit()">
|
<button mat-menu-item (click)="rename.emit()">
|
||||||
<i class="al-icon sm-md" [class]="icons.EDIT"></i>Rename
|
<i class="al-icon sm-md" [class]="icons.EDIT"></i>Rename
|
||||||
</button>
|
</button>
|
||||||
|
@ -13,6 +13,8 @@ export class PipelineCardMenuComponent {
|
|||||||
@Input() project: Project;
|
@Input() project: Project;
|
||||||
@Input() allTags: string[];
|
@Input() allTags: string[];
|
||||||
@Output() run = new EventEmitter();
|
@Output() run = new EventEmitter();
|
||||||
|
@Output() edit = new EventEmitter();
|
||||||
|
@Output() runs = new EventEmitter();
|
||||||
@Output() addTag = new EventEmitter<string>();
|
@Output() addTag = new EventEmitter<string>();
|
||||||
@Output() rename = new EventEmitter();
|
@Output() rename = new EventEmitter();
|
||||||
@Output() delete = new EventEmitter();
|
@Output() delete = new EventEmitter();
|
||||||
|
@ -47,6 +47,8 @@
|
|||||||
(run)="run.emit()"
|
(run)="run.emit()"
|
||||||
(rename)="editName.inlineActivated()"
|
(rename)="editName.inlineActivated()"
|
||||||
(addTag)="addTag.emit($event)"
|
(addTag)="addTag.emit($event)"
|
||||||
|
(runs)="runs.emit(project)"
|
||||||
|
(edit)="edit.emit(project)"
|
||||||
(delete)="delete.emit()"
|
(delete)="delete.emit()"
|
||||||
data-id="pipelineCardMenu"
|
data-id="pipelineCardMenu"
|
||||||
></sm-pipeline-card-menu>
|
></sm-pipeline-card-menu>
|
||||||
|
@ -44,6 +44,8 @@ import {ShowTooltipIfEllipsisDirective} from '@common/shared/ui-components/indic
|
|||||||
export class PipelineCardComponent extends ProjectCardComponent {
|
export class PipelineCardComponent extends ProjectCardComponent {
|
||||||
@Input() allTags: string[];
|
@Input() allTags: string[];
|
||||||
@Output() run = new EventEmitter();
|
@Output() run = new EventEmitter();
|
||||||
|
@Output() runs = new EventEmitter(); // view runs for pipeline
|
||||||
|
@Output() edit = new EventEmitter(); // edit pipeline
|
||||||
@Output() addTag = new EventEmitter<string>();
|
@Output() addTag = new EventEmitter<string>();
|
||||||
@Output() removeTag = new EventEmitter<string>();
|
@Output() removeTag = new EventEmitter<string>();
|
||||||
@Output() delete = new EventEmitter();
|
@Output() delete = new EventEmitter();
|
||||||
|
@ -38,6 +38,8 @@
|
|||||||
(addTag)="addTag(project, $event)"
|
(addTag)="addTag(project, $event)"
|
||||||
(removeTag)="removeTag(project, $event)"
|
(removeTag)="removeTag(project, $event)"
|
||||||
(delete)="deleteProject(project)"
|
(delete)="deleteProject(project)"
|
||||||
|
(runs)="projectCardClicked($event)"
|
||||||
|
(edit)="pipelineEditClicked($event)"
|
||||||
></sm-pipeline-card>
|
></sm-pipeline-card>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
|
||||||
|
@ -118,6 +118,11 @@ if __name__ == '__main__':
|
|||||||
this.store.dispatch(setSelectedProjectId({projectId: project.id, example: isExample(project)}));
|
this.store.dispatch(setSelectedProjectId({projectId: project.id, example: isExample(project)}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public pipelineEditClicked(pipeline: ProjectsGetAllResponseSingle) {
|
||||||
|
this.router.navigate([pipeline.id, 'edit'], {relativeTo: this.projectId ? this.route.parent.parent.parent : this.route});
|
||||||
|
this.store.dispatch(setSelectedProjectId({projectId: pipeline.id, example: isExample(pipeline)}));
|
||||||
|
}
|
||||||
|
|
||||||
protected override getName() {
|
protected override getName() {
|
||||||
return EntityTypeEnum.pipeline;
|
return EntityTypeEnum.pipeline;
|
||||||
}
|
}
|
||||||
|
@ -65,7 +65,7 @@ export const BASE_ENV = {
|
|||||||
apiBaseUrl: null,
|
apiBaseUrl: null,
|
||||||
fileBaseUrl: null,
|
fileBaseUrl: null,
|
||||||
productName: 'clearml',
|
productName: 'clearml',
|
||||||
demo: false,
|
demo: true,
|
||||||
headerPrefix: 'X-Clearml',
|
headerPrefix: 'X-Clearml',
|
||||||
version: versionConf.version,
|
version: versionConf.version,
|
||||||
userKey: 'EYVQ385RW7Y2QQUH88CZ7DWIQ1WUHP',
|
userKey: 'EYVQ385RW7Y2QQUH88CZ7DWIQ1WUHP',
|
||||||
@ -73,7 +73,7 @@ export const BASE_ENV = {
|
|||||||
companyID: 'd1bd92a3b039400cbafc60a7a5b1e52b',
|
companyID: 'd1bd92a3b039400cbafc60a7a5b1e52b',
|
||||||
loginNotice: '',
|
loginNotice: '',
|
||||||
loginBanner: '',
|
loginBanner: '',
|
||||||
autoLogin: false,
|
autoLogin: true,
|
||||||
whiteLabelLogo: null,
|
whiteLabelLogo: null,
|
||||||
whiteLabelLink: null,
|
whiteLabelLink: null,
|
||||||
whiteLabelLoginTitle: null,
|
whiteLabelLoginTitle: null,
|
||||||
|
Loading…
Reference in New Issue
Block a user