NexusVswitch UI development modified enable disable actions and details tab
Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/b04ba4f8 Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/b04ba4f8 Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/b04ba4f8 Branch: refs/heads/3.0.x Commit: b04ba4f8e01d69c99e8c0052016268ef55cd3995 Parents: 060090f Author: Sanjay Tripathi <[email protected]> Authored: Thu May 24 15:25:15 2012 +0530 Committer: Sanjay Tripathi <[email protected]> Committed: Thu May 24 15:25:15 2012 +0530 ---------------------------------------------------------------------- ui/scripts/system.js | 36 ++++++++++++++++++++++++------------ 1 files changed, 24 insertions(+), 12 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/b04ba4f8/ui/scripts/system.js ---------------------------------------------------------------------- diff --git a/ui/scripts/system.js b/ui/scripts/system.js index a1a1009..3541a31 100644 --- a/ui/scripts/system.js +++ b/ui/scripts/system.js @@ -6496,7 +6496,7 @@ vsmdeviceid: { label: 'label.name' }, type: { label: 'label.type' }, zonename: { label: 'label.zone' }, - state: { label: 'label.status' } + vsmdevicestate: { label: 'label.status' } }, detailView: { actions: { @@ -6516,9 +6516,14 @@ dataType: "json", async: true, success: function(json) { - var item = json.getciscovsmbyclusteridcmdresponse.cisconexusvsm; - args.context.clusters[0].state = item.allocationstate; - addExtraPropertiesToClusterObject(item); + var jid = json.enablecisconexusvsmresponse.jobid; + args.response.success( + {_custom: + {jobId: jid} + } + ); + //args.context.vSwitches[0].vsmdevicestate = item.allocationstate; + //addExtraPropertiesToClusterObject(item); args.response.success({ actionFilter: nexusActionfilter, data:item @@ -6549,9 +6554,14 @@ dataType: "json", async: true, success: function(json) { - var item = json.getciscovsmbyclusteridcmdresponse.cisconexusvsm; - args.context.clusters[0].state = item.allocationstate; - addExtraPropertiesToClusterObject(item); + var jid = json.disablecisconexusvsmresponse.jobid; + args.response.success( + {_custom: + {jobId: jid} + } + ); + //args.context.vSwitches[0].vsmdevicestate = item.allocationstate; + //addExtraPropertiesToClusterObject(item); args.response.success({ actionFilter: nexusActionfilter, data:item @@ -6596,10 +6606,12 @@ details: { title: 'label.details', fields: { - name: { label: 'label.name' }, - type: { label: 'label.type' }, - zonename: { label: 'label.zone' }, - state: { label: 'label.status' } + vsmdeviceid: { label: 'label.name' }, + ipaddress: { label: 'label.ipaddress' }, + vsmctrlvlanid: { label: 'label.vsmctrlvlanid' }, + vsmpktvlanid: { label: 'label.vsmpktvlanid' }, + vsmstoragevlanid: { label: 'label.vsmstoragevlanid' }, + vsmdevicestate: { label: 'label.state' } }, dataProvider: function(args) { @@ -6607,7 +6619,7 @@ url: createURL("listCiscoNexusVSMs&clusterid=" + args.context.clusters[0].id), dataType: "json", success: function(json) { - var item = json.listcisconexusvsmscmdresponse.cisconexusvsm; + var item = json.listcisconexusvsmscmdresponse.cisconexusvsm[0]; addExtraPropertiesToClusterObject(item); args.response.success({ actionFilter: nexusActionfilter,
