23 lines
1.0 KiB
JavaScript
23 lines
1.0 KiB
JavaScript
import React from 'react';
|
|
import { Form, Button, Space } from 'antd';
|
|
import OnUser from '../onUser/index';
|
|
export default function Render(props) {
|
|
const { relations, entity, entityId, oakId, oakDirty, oakFullpath, } = props.data;
|
|
const { onConfirm, onReset, t } = props.methods;
|
|
return (<>
|
|
<OnUser oakAutoUnmount={true} oakPath={oakFullpath} entity={entity} entityId={entityId} relations={relations} oakId={oakId}/>
|
|
<Form colon labelCol={{ span: 4 }} wrapperCol={{ span: 8 }}>
|
|
<Form.Item wrapperCol={{ offset: 4 }}>
|
|
<Space>
|
|
<Button disabled={!oakDirty} type="primary" onClick={() => onConfirm()}>
|
|
{t('common::action.confirm')}
|
|
</Button>
|
|
<Button htmlType="reset" onClick={() => onReset()}>
|
|
{t('common::reset')}
|
|
</Button>
|
|
</Space>
|
|
</Form.Item>
|
|
</Form>
|
|
</>);
|
|
}
|