/**
 * @Date:   2019-05-20T16:45:00+08:00
 * @Last modified time: 2019-06-26T18:40:44+08:00
 */

import { connect } from 'umi';
import CommonListEdit from '../../components/Common/CommonListEdit';

function commonListEdit({
  dispatch, app, content,
}) {
  const commonListEitProps = {
    app,
    content,
    dispatch,
    onAddPane: getAddPane, /* 增加标签 */
  };
  function getAddPane(pane) {
    /* 增加标签 */
    dispatch({ type: 'app/addPane', payload: { pane } });
  }
  return (
    <CommonListEdit {...commonListEitProps} style={{ height: '100%' }} />
  );
}

export default connect(({ app, content }) =>
  ({ app, content }))(commonListEdit);
