|
|
@ -9,7 +9,7 @@ import {
|
|
|
|
} from '@ant-design/pro-components';
|
|
|
|
} from '@ant-design/pro-components';
|
|
|
|
import { FormattedMessage, useIntl } from '@umijs/max';
|
|
|
|
import { FormattedMessage, useIntl } from '@umijs/max';
|
|
|
|
import { Form, message } from 'antd';
|
|
|
|
import { Form, message } from 'antd';
|
|
|
|
import { proFormItemStyleProps, proFormModelWidth } from '../../../../../config/defaultForm';
|
|
|
|
import { proFormSmallItemStyleProps, proFormSmallModelWidth } from '../../../../../config/defaultForm';
|
|
|
|
import React from 'react';
|
|
|
|
import React from 'react';
|
|
|
|
export type FormValueType = {
|
|
|
|
export type FormValueType = {
|
|
|
|
target?: string;
|
|
|
|
target?: string;
|
|
|
@ -34,9 +34,9 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<ModalForm<API.Project>
|
|
|
|
<ModalForm<API.Project>
|
|
|
|
width={proFormModelWidth}
|
|
|
|
width={proFormSmallModelWidth}
|
|
|
|
title={intl.formatMessage({
|
|
|
|
title={intl.formatMessage({
|
|
|
|
id: 'project.project.table.list.update',
|
|
|
|
id: 'contact.contact.table.list.update',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}
|
|
|
|
})}
|
|
|
|
open={props.updateModalOpen}
|
|
|
|
open={props.updateModalOpen}
|
|
|
@ -62,22 +62,22 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
}}
|
|
|
|
}}
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<ProForm.Group>
|
|
|
|
<ProForm.Group>
|
|
|
|
<ProFormText
|
|
|
|
{/* <ProFormText
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="id"
|
|
|
|
name="id"
|
|
|
|
label="id"
|
|
|
|
label="id"
|
|
|
|
disabled={true}
|
|
|
|
disabled={true}
|
|
|
|
initialValue={props.values.id}
|
|
|
|
initialValue={props.values.id}
|
|
|
|
/>
|
|
|
|
/> */}
|
|
|
|
<ProFormText
|
|
|
|
<ProFormText
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="name"
|
|
|
|
name="name"
|
|
|
|
label={<FormattedMessage id="project.project.table.list.name" defaultMessage="$$$" />}
|
|
|
|
label={<FormattedMessage id="contact.contact.table.list.name" defaultMessage="$$$" />}
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
id: 'common.please_input',
|
|
|
|
id: 'common.please_input',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
id: 'project.project.table.list.name',
|
|
|
|
id: 'contact.contact.table.list.name',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}`}
|
|
|
|
})}`}
|
|
|
|
required={true}
|
|
|
|
required={true}
|
|
|
@ -88,7 +88,7 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
required: true,
|
|
|
|
required: true,
|
|
|
|
message: (
|
|
|
|
message: (
|
|
|
|
<FormattedMessage
|
|
|
|
<FormattedMessage
|
|
|
|
id="project.project.table.rule.required.name"
|
|
|
|
id="contact.contact.table.rule.required.name"
|
|
|
|
defaultMessage="name is required"
|
|
|
|
defaultMessage="name is required"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
),
|
|
|
|
),
|
|
|
@ -96,14 +96,14 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
]}
|
|
|
|
]}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
<ProFormText
|
|
|
|
<ProFormText
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="code"
|
|
|
|
name="code"
|
|
|
|
label={<FormattedMessage id="project.project.table.list.code" defaultMessage="$$$" />}
|
|
|
|
label={<FormattedMessage id="contact.contact.table.list.phone" defaultMessage="$$$" />}
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
id: 'common.please_input',
|
|
|
|
id: 'common.please_input',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
id: 'project.project.table.list.code',
|
|
|
|
id: 'contact.contact.table.list.phone',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}`}
|
|
|
|
})}`}
|
|
|
|
required={true}
|
|
|
|
required={true}
|
|
|
@ -122,14 +122,14 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
]}
|
|
|
|
]}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
<ProFormText
|
|
|
|
<ProFormText
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="info"
|
|
|
|
name="info"
|
|
|
|
label={<FormattedMessage id="project.project.table.list.info" defaultMessage="$$$" />}
|
|
|
|
label={<FormattedMessage id="contact.contact.table.list.mail" defaultMessage="$$$" />}
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
id: 'common.please_input',
|
|
|
|
id: 'common.please_input',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
id: 'project.project.table.list.info',
|
|
|
|
id: 'contact.contact.table.list.mail',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
})}`}
|
|
|
|
})}`}
|
|
|
|
required={true}
|
|
|
|
required={true}
|
|
|
@ -149,7 +149,7 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
|
|
|
|
|
|
|
|
{/* <ProFormCheckbox.Group
|
|
|
|
{/* <ProFormCheckbox.Group
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="isEnable"
|
|
|
|
name="isEnable"
|
|
|
|
layout="vertical"
|
|
|
|
layout="vertical"
|
|
|
|
label={<FormattedMessage id="project.project.table.list.isEnable" defaultMessage="$$$" />}
|
|
|
|
label={<FormattedMessage id="project.project.table.list.isEnable" defaultMessage="$$$" />}
|
|
|
@ -163,7 +163,22 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
启用此项目
|
|
|
|
启用此项目
|
|
|
|
</div> */}
|
|
|
|
</div> */}
|
|
|
|
<ProFormText
|
|
|
|
<ProFormText
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
|
|
|
|
name="remark"
|
|
|
|
|
|
|
|
label={<FormattedMessage id="contact.contact.table.list.WeChatID" defaultMessage="$$$" />}
|
|
|
|
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
|
|
|
|
id: 'common.please_input',
|
|
|
|
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
|
|
|
|
})}${intl.formatMessage({
|
|
|
|
|
|
|
|
id: 'contact.contact.table.list.WeChatID',
|
|
|
|
|
|
|
|
defaultMessage: '$$$',
|
|
|
|
|
|
|
|
})}`}
|
|
|
|
|
|
|
|
required={false}
|
|
|
|
|
|
|
|
initialValue={props.values.remark}
|
|
|
|
|
|
|
|
disabled={false}
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
<ProFormText
|
|
|
|
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="remark"
|
|
|
|
name="remark"
|
|
|
|
label={<FormattedMessage id="project.project.table.list.remark" defaultMessage="$$$" />}
|
|
|
|
label={<FormattedMessage id="project.project.table.list.remark" defaultMessage="$$$" />}
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
|
placeholder={`${intl.formatMessage({
|
|
|
@ -177,15 +192,15 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
initialValue={props.values.remark}
|
|
|
|
initialValue={props.values.remark}
|
|
|
|
disabled={false}
|
|
|
|
disabled={false}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
<ProFormSwitch
|
|
|
|
{/* <ProFormSwitch
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="isEnable"
|
|
|
|
name="isEnable"
|
|
|
|
label={<FormattedMessage id="project.project.table.list.isEnable" defaultMessage="$$$" />}
|
|
|
|
label={<FormattedMessage id="project.project.table.list.isEnable" defaultMessage="$$$" />}
|
|
|
|
initialValue={props.values.isEnable}
|
|
|
|
initialValue={props.values.isEnable}
|
|
|
|
disabled={false}
|
|
|
|
disabled={false}
|
|
|
|
/>
|
|
|
|
/> */}
|
|
|
|
<ProFormDateTimePicker
|
|
|
|
{/* <ProFormDateTimePicker
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="createTime"
|
|
|
|
name="createTime"
|
|
|
|
label={
|
|
|
|
label={
|
|
|
|
<FormattedMessage id="project.project.table.list.createTime" defaultMessage="$$$" />
|
|
|
|
<FormattedMessage id="project.project.table.list.createTime" defaultMessage="$$$" />
|
|
|
@ -202,7 +217,7 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
disabled={true}
|
|
|
|
disabled={true}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
<ProFormDateTimePicker
|
|
|
|
<ProFormDateTimePicker
|
|
|
|
width={proFormItemStyleProps.column2Width}
|
|
|
|
width={proFormSmallItemStyleProps.width}
|
|
|
|
name="updateTime"
|
|
|
|
name="updateTime"
|
|
|
|
label={
|
|
|
|
label={
|
|
|
|
<FormattedMessage id="project.project.table.list.updateTime" defaultMessage="$$$" />
|
|
|
|
<FormattedMessage id="project.project.table.list.updateTime" defaultMessage="$$$" />
|
|
|
@ -217,7 +232,7 @@ const UpdateForm: React.FC<UpdateFormProps> = (props) => {
|
|
|
|
required={false}
|
|
|
|
required={false}
|
|
|
|
initialValue={props.values.updateTime}
|
|
|
|
initialValue={props.values.updateTime}
|
|
|
|
disabled={true}
|
|
|
|
disabled={true}
|
|
|
|
/>
|
|
|
|
/> */}
|
|
|
|
</ProForm.Group>
|
|
|
|
</ProForm.Group>
|
|
|
|
</ModalForm>
|
|
|
|
</ModalForm>
|
|
|
|
);
|
|
|
|
);
|
|
|
|