Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

ACAD-866 Adding in unique idenfitiers for wigets that can be multiply…

…-instantiated in the user's homepage
  • Loading branch information...
commit 204b97e06ac1d922ce349e6524274c75d3d577bf 1 parent 797d833
@croby croby authored
View
2  devwidgets/displayprofilesection/javascript/displayprofilesection.js
@@ -316,6 +316,8 @@ require(["jquery", "sakai/sakai.api.core"], function($, sakai) {
userid = sakai_global.profile.main.data.userid;
editing = userid && userid === sakai.data.me.user.userid;
getData( renderSection );
+ // add a class to the container to uniquely identify this widget
+ $rootel.find('#displayprofilesection_container').addClass(widgetData.sectionid);
};
init();
View
3  devwidgets/inbox/javascript/inbox.js
@@ -502,6 +502,9 @@ require(["jquery", "sakai/sakai.api.core"], function($, sakai) {
handleHashChange(null, {}, {}, all, {}, true);
$(window).bind("hashchanged.inbox.sakai", handleHashChange);
$(window).bind(tuid + ".shown.sakai", handleShown);
+ // Add the title key as class to the #inbox_widget div to uniquely
+ // identify this instance of the widget
+ $rootel.find('#inbox_widget').addClass(sakai.api.i18n.General.process(widgetData.title, "noop").toLowerCase());
};
init();
Please sign in to comment.
Something went wrong with that request. Please try again.