Sha256: 47c7e1741feecceaf3382af45cecabcbac5b37d54e369ea71e7416b346cd774f

Contents?: true

Size: 1.48 KB

Versions: 36

Compression:

Stored size: 1.48 KB

Contents

I"ß(function() {
  var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
    hasProp = {}.hasOwnProperty;

  App.Views.Admin.Users.List = (function(superClass) {
    extend(List, superClass);

    function List(opts) {
      if (opts == null) {
        opts = {};
      }
      List.__super__.constructor.call(this, opts);
      this.users = opts.users;
    }

    List.prototype.render = function() {
      return $("table tbody").empty();
    };

    List.prototype.renderUsers = function(users, order) {
      var i, len, user;
      if (order == null) {
        order = 'append';
      }
      for (i = 0, len = users.length; i < len; i++) {
        user = users[i];
        if (order === 'append') {
          $("table").append(JST["templates/admin/users/user"]({
            user: user
          }));
        } else {
          $("table").prepend(JST["templates/admin/users/user"]({
            user: user
          }));
        }
      }
      return $('table a.ping').click(function(e) {
        var userId;
        e.preventDefault();
        userId = $(e.target).parents('tr').data('id');
        return App.Env.loco.emit({
          signal: 'ping',
          user_id: userId
        });
      });
    };

    return List;

  })(App.Views.Base);

}).call(this);
:ET

Version data entries

36 entries across 23 versions & 1 rubygems

Version Path
loco-rails-3.0.3 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.5.3 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.5.2 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-3.0.2 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-3.0.1 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.5.1 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.5.0 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.4.0 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.4.0 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache
loco-rails-2.3.0 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache
loco-rails-2.3.0 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-3.0.0 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-3.0.0 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache
loco-rails-2.2.2 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache
loco-rails-2.2.2 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.2.1 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.2.1 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache
loco-rails-2.2.0 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache
loco-rails-2.2.0 test/dummy/tmp/cache/assets/sprockets/v3.0/A4/a4UnfDue5FpEVBWdAEM6JAfiuRqZ6quJKmNAIJxoEi4.cache
loco-rails-2.1.0 test/dummy/tmp/cache/assets/sprockets/v3.0/pO/pOBFQ6wlWQUxqBPvQ1BskY3oTCt_VmP1vitrgC0Bk_I.cache