1
0
mirror of https://github.com/newnius/YAO-portal.git synced 2025-12-13 00:56:44 +00:00

update, add virtual cluster management

This commit is contained in:
2019-07-30 15:49:09 +08:00
parent b7a13462fd
commit 3d7f919942
4 changed files with 177 additions and 6 deletions

View File

@@ -6,12 +6,14 @@ function register_events_cluster() {
$("#form-cluster-submit").click(function (e) {
var name = $('#form-cluster-name').val();
var weight = $('#form-cluster-weight').val();
var reserved = $('#form-cluster-reserved').prop("checked");
var quota_gpu = $('#form-cluster-quota-gpu-number').val();
var quota_gpu_mem = $('#form-cluster-quota-gpu-memory').val();
var quota_cpu = $('#form-cluster-quota-cpu').val();
var quota_mem = $('#form-cluster-quota-mem').val();
/* TODO validate form */
/* TODO: validate form */
$('#modal-cluster').modal('hide');
if ($('#form-cluster-submit-type').val() !== 'add')
@@ -22,6 +24,8 @@ function register_events_cluster() {
type: 'POST',
data: {
name: name,
weight: weight,
reserved: reserved,
quota_gpu: quota_gpu,
quota_gpu_mem: quota_gpu_mem,
quota_cpu: quota_cpu,