lib/carte/client/views/content.cjsx in carte-server-0.0.25 vs lib/carte/client/views/content.cjsx in carte-server-0.0.26

- old
+ new

@@ -9,23 +9,21 @@ module.exports = React.createClass displayName: 'Content' componentWillMount: -> - console.log 'componentWillMount' + console.log '[views/content] component will mount' @callback = ()=> @forceUpdate() @props.router.on "route", @callback componentWillUnmount: -> - console.log 'componentWillMount un' + console.log '[views/content] component will unmount' @props.router.off "route", @callback render: -> - console.log 'render component' switch @props.router.current when "list" - console.log 'list', @props.router.query cards = new CardCollection() cards.query = $.extend {}, config.default_query, @props.router.query cards.fetching = true cards.fetch success: ()-> cards.fetching = false #title = [] @@ -35,33 +33,27 @@ #title = config.title + ' (' + title + ')' #document.title = title document.title = config.title <List key='list' router={@props.router} cards={cards} /> when "show" - console.log 'show' cards = new CardCollection() cards.fetching = true card = new CardModel(title: @props.router.title) card.fetch success: (card)-> - console.log card for left in card.get("lefts") cardModel = new CardModel(left) cardModel.set 'focused', false - console.log 'adding left', cardModel cards.add cardModel card.set 'focused', true cards.add card for right in card.get("rights") cardModel = new CardModel(right) cardModel.set 'focused', false - console.log 'adding right', cardModel cards.add cardModel cards.fetching = false error: (card, response)=> - console.log 'error!!!!!!!!!!!!!!!!!!!!!!!!', response cards.fetching = false document.title = config.title + '、' + card.get('title') <List key='show' cards={cards} card={card} /> else - console.log 'else' <div>Loading ...</div>