OLD | NEW |
1 /* | 1 /* |
2 This file is part of the Juju GUI, which lets users view and manage Juju | 2 This file is part of the Juju GUI, which lets users view and manage Juju |
3 environments within a graphical interface (https://launchpad.net/juju-gui). | 3 environments within a graphical interface (https://launchpad.net/juju-gui). |
4 Copyright (C) 2012-2013 Canonical Ltd. | 4 Copyright (C) 2012-2013 Canonical Ltd. |
5 | 5 |
6 This program is free software: you can redistribute it and/or modify it under | 6 This program is free software: you can redistribute it and/or modify it under |
7 the terms of the GNU Affero General Public License version 3, as published by | 7 the terms of the GNU Affero General Public License version 3, as published by |
8 the Free Software Foundation. | 8 the Free Software Foundation. |
9 | 9 |
10 This program is distributed in the hope that it will be useful, but WITHOUT | 10 This program is distributed in the hope that it will be useful, but WITHOUT |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 @param {Object} db The app.models.models.Database instance. | 144 @param {Object} db The app.models.models.Database instance. |
145 @param {String} action The operation to be performed | 145 @param {String} action The operation to be performed |
146 ("add", "change" or "remove"). | 146 ("add", "change" or "remove"). |
147 @param {Object} change The JSON entity information. | 147 @param {Object} change The JSON entity information. |
148 @param {String} kind The delta event type. | 148 @param {String} kind The delta event type. |
149 @return {undefined} Nothing. | 149 @return {undefined} Nothing. |
150 */ | 150 */ |
151 unitInfo: function(db, action, change) { | 151 unitInfo: function(db, action, change) { |
152 var unitData = { | 152 var unitData = { |
153 id: change.Name, | 153 id: change.Name, |
| 154 charm_url: change.CharmURL, |
154 service: change.Service, | 155 service: change.Service, |
155 machine: change.MachineId, | 156 machine: change.MachineId, |
156 agent_state: change.Status, | 157 agent_state: change.Status, |
157 agent_state_info: change.StatusInfo, | 158 agent_state_info: change.StatusInfo, |
158 public_address: change.PublicAddress, | 159 public_address: change.PublicAddress, |
159 private_address: change.PrivateAddress, | 160 private_address: change.PrivateAddress, |
160 open_ports: utils.convertOpenPorts(change.Ports) | 161 open_ports: utils.convertOpenPorts(change.Ports) |
161 }; | 162 }; |
162 var machineData = { | 163 var machineData = { |
163 id: change.MachineId, | 164 id: change.MachineId, |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
278 } | 279 } |
279 | 280 |
280 }; | 281 }; |
281 | 282 |
282 }, '0.1.0', { | 283 }, '0.1.0', { |
283 requires: [ | 284 requires: [ |
284 'base', | 285 'base', |
285 'array-extras' | 286 'array-extras' |
286 ] | 287 ] |
287 }); | 288 }); |
OLD | NEW |