aboutsummaryrefslogtreecommitdiff
path: root/engine/js/classes
diff options
context:
space:
mode:
Diffstat (limited to 'engine/js/classes')
-rw-r--r--engine/js/classes/ElggEntity.js20
-rw-r--r--engine/js/classes/ElggUser.js12
2 files changed, 22 insertions, 10 deletions
diff --git a/engine/js/classes/ElggEntity.js b/engine/js/classes/ElggEntity.js
new file mode 100644
index 000000000..9461a463f
--- /dev/null
+++ b/engine/js/classes/ElggEntity.js
@@ -0,0 +1,20 @@
+/**
+ * Create a new ElggEntity
+ *
+ * @class Represents an ElggEntity
+ * @property {number} guid
+ * @property {string} type
+ * @property {string} subtype
+ * @property {number} owner_guid
+ * @property {number} site_guid
+ * @property {number} container_guid
+ * @property {number} access_id
+ * @property {number} time_created
+ * @property {number} time_updated
+ * @property {number} last_action
+ * @property {string} enabled
+ *
+ */
+elgg.ElggEntity = function(o) {
+ $.extend(this, o);
+}; \ No newline at end of file
diff --git a/engine/js/classes/ElggUser.js b/engine/js/classes/ElggUser.js
index dec7431de..8a7a8b7eb 100644
--- a/engine/js/classes/ElggUser.js
+++ b/engine/js/classes/ElggUser.js
@@ -8,15 +8,7 @@
* @property {string} username
*/
elgg.ElggUser = function(o) {
- //elgg.ElggEntity.call(this, o);
- this = o;
+ elgg.ElggEntity.call(this, o);
};
-//elgg.inherit(elgg.ElggUser, elgg.ElggEntity);
-
-/**
- * @return {boolean} Whether the user is an admin
- */
-elgg.ElggUser.prototype.isAdmin = function() {
- return this.admin === 'yes';
-}; \ No newline at end of file
+elgg.inherit(elgg.ElggUser, elgg.ElggEntity); \ No newline at end of file