fixes for the comments of the PR#404

revert-70aa11f8
sameera910409 8 years ago
parent fef7c07cb2
commit 204a0ed943

@ -130,7 +130,7 @@ public interface DeviceManagementService {
String status,
@ApiParam(
name = "groupId",
value = "The group name of the device included",
value = "Id of the group which device belongs",
required = false)
@QueryParam("groupId")
int groupId,

@ -53,7 +53,7 @@ var groupModule = {};
);
};
groupModule.getGroupDeviceCount = function (groupId, owner) {
groupModule.getGroupDeviceCount = function (groupId) {
endPoint = deviceServiceEndpoint + "/groups/id/" + groupId + "/devices/count";
return serviceInvokers.XMLHttp.get(
endPoint, function (responsePayload) {

@ -22,7 +22,6 @@ function onRequest(context) {
var deviceModule = require("/app/modules/business-controllers/device.js")["deviceModule"];
var groupName = request.getParameter("groupName");
var groupOwner = request.getParameter("groupOwner");
var groupId = request.getParameter("groupId");
var viewModel = {};
@ -42,9 +41,9 @@ function onRequest(context) {
}
viewModel.currentUser = currentUser;
var deviceCount = 0;
if (groupId && groupOwner) {
if (groupId) {
var groupModule = require("/app/modules/business-controllers/group.js")["groupModule"];
deviceCount = groupModule.getGroupDeviceCount(groupId, groupOwner);
deviceCount = groupModule.getGroupDeviceCount(groupId);
} else {
deviceCount = deviceModule.getDevicesCount();
}

@ -352,7 +352,6 @@ function attachEvents() {
*/
$("a.remove-group-link").click(function () {
var groupId = $(this).data("group-id");
var groupOwner = $(this).data("group-owner");
$(modalPopupContent).html($('#remove-group-modal-content').html());
showPopup();

Loading…
Cancel
Save