server/bo_client/app/components/bo-doc-contributors.js
author ymh <ymh.work@gmail.com>
Tue, 01 Dec 2015 13:33:08 +0100
changeset 20 a9b98b16b053
permissions -rw-r--r--
add contributor list + edition pane

import Ember from 'ember';
import _ from 'lodash/lodash';

export default Ember.Component.extend({

  actions: {
    toggleEditContributors : function() {
      console.log("EDIT CONTRIBUTORS");
      // var contributors = _.clone(this.get('document').get('contributors'));
      // console.log("EDIT CONTRIBUTPRS", contributors);
      // contributors.push({
      //   name: "Hello world",
      //   url: null,
      //   role: 'http://www.language-archives.org/OLAC/1.1/annotator'
      // });
      // this.get('document').set('contributors', contributors);
      Ember.$('#doc-contributors-table-pane').slideToggle();
      Ember.$('#doc-contributors-list-pane').slideToggle();
    }
  }
});