content: import React from 'react';
  import { browserHistory } from 'react-router';
  import Loading from '/imports/ui/loading';
  
  
  class _Component extends React.Component {
    handelDelete(id) {
      if (window.confirm('确认删除？')) {
        Meteor.call('bookNew.delete', id);
      }
    }
    render() {
      const data = this.props.data;
      return (
        <div>
          <h1>出版申请</h1>
          {this.props.ready ?
              <table className="ui celled striped table">
                <thead>
                  <tr>
                    <th>作品名称</th>
                    <th>版面数字</th>
                    <th>开本</th>
                    <th>印数</th>
                    <th>装帧</th>
                    <th>姓名</th>
                    <th>单位</th>
                    <th>手机号</th>
                    <th>邮箱</th>
                    <th></th>
                  </tr>
                </thead>
                <tbody>
                  {data.map( (data, idx) =>
                    <tr key={idx}>
                      <td>{data.bookname}</td>
                      <td>{data.layout}</td>
                      <td>{data.size}</td>
                      <td>{data.pages}</td>
                      <td>{data.binding}</td>
                      <td>{data.truename}</td>
                      <td>{data.unit}</td>
                      <td>{data.mobile}</td>
                      <td>{data.email}</td>
                      <td className="control">
                        <i className="blue remove icon pointer" onClick={()=> this.handelDelete(data._id)} />
                      </td>
                    </tr>
                  )}
                </tbody>
              </table>
              :
              <Loading/>
          }
        </div>
      );
    }
  }
  
  export default _Component;
  