
import { Button, Popconfirm } from 'antd'
import FormPage from '../../components/FormPage'
import {extendRule, initFilter} from "../../utils/common";

//用户组列表页
export default {
  btnEdit:({record,close,loadData,login,dispatch})=> {
    const closeF=()=>{
      close();
      loadData();
    };
    const regClick= async function() {
      await dispatch({
        type: 'custom/save',
        payload: {
          ['userGroupEditClick'+(record? record.ID:'')]:true
        },
      });
    };
    const data={
      id:(record? record.ID:''),
      close:closeF,
      userGroupEditClick:login.userGroupEditClick
    };
    return {
      content: <FormPage formCode={'FM011'} data={data}/>,
      click: regClick
    }
  }

}
