Commit 6c478b5f authored by XieZhiXiong's avatar XieZhiXiong

fixbug

parent bcea6348
......@@ -16,6 +16,7 @@ import {
DownOutlined,
} from '@ant-design/icons';
import { StandardTable } from 'god';
import moment from 'moment';
import { ColumnType } from 'antd/lib/table/interface';
import { createFormActions } from '@formily/antd';
import EyePreview from '@/components/EyePreview';
......@@ -41,8 +42,21 @@ import { MEMBER_OUTER_STATUS_TYPE, MEMBER_STATUS_TAG_MAP } from '../constant';
const formActions = createFormActions();
const fetchListData = async (params: any) => {
let res = await PublicApi.getMemberAbilitySubPage(params);
return res.data;
const { startDate = null, endDate = null } = params;
const payload = { ...params };
if (startDate) {
payload.startDate = moment(+startDate).format('YYYY-MM-DD');
}
if (endDate) {
payload.endDate = moment(+endDate).format('YYYY-MM-DD');
}
const res = await PublicApi.getMemberAbilitySubPage(payload);
if (res.code === 1000) {
return res.data;
}
return [];
};
const MemberMaintain: React.FC<[]> = () => {
......
......@@ -12,6 +12,7 @@ import {
DownOutlined,
} from '@ant-design/icons';
import { StandardTable } from 'god';
import moment from 'moment';
import { ColumnType } from 'antd/lib/table/interface';
import { createFormActions, FormEffectHooks } from '@formily/antd';
import { useStateFilterSearchLinkageEffect } from '@/formSchema/effects/useFilterSearch';
......@@ -38,8 +39,21 @@ import { coverColFiltersItem } from '../utils';
const formActions = createFormActions();
const fetchData = async (params: any) => {
let res = await PublicApi.getMemberAbilityMaintenancePage(params);
return res.data;
const { startDate = null, endDate = null } = params;
const payload = { ...params };
if (startDate) {
payload.startDate = moment(+startDate).format('YYYY-MM-DD');
}
if (endDate) {
payload.endDate = moment(+endDate).format('YYYY-MM-DD');
}
const res = await PublicApi.getMemberAbilityMaintenancePage(payload);
if (res.code === 1000) {
return res.data;
}
return [];
};
const MemberMaintain: React.FC<[]> = () => {
......
......@@ -3,6 +3,7 @@ import { history } from 'umi';
import { Card, Space, Button, Badge, Modal, message } from 'antd';
import { ClockCircleOutlined, QuestionCircleOutlined } from '@ant-design/icons';
import { StandardTable } from 'god';
import moment from 'moment';
import { ColumnType } from 'antd/lib/table/interface';
import { createFormActions } from '@formily/antd';
import EyePreview from '@/components/EyePreview';
......@@ -126,8 +127,22 @@ const MemberPr1: React.FC<{}> = props => {
};
const fetchListData = async (params: any) => {
let res = await PublicApi.getMemberAbilityValidateStep1Page(params);
return res.data;
const { startDate = null, endDate = null } = params;
const payload = { ...params };
if (startDate) {
payload.startDate = moment(+startDate).format('YYYY-MM-DD');
}
if (endDate) {
payload.endDate = moment(+endDate).format('YYYY-MM-DD');
}
const res = await PublicApi.getMemberAbilityValidateStep1Page(payload);
if (res.code === 1000) {
return res.data;
}
return [];
};
const handleBatch = () => {
......
......@@ -3,6 +3,7 @@ import { history } from 'umi';
import { Card, Space, Button, Badge, Modal, message } from 'antd';
import { ClockCircleOutlined, QuestionCircleOutlined } from '@ant-design/icons';
import { StandardTable } from 'god';
import moment from 'moment';
import { ColumnType } from 'antd/lib/table/interface';
import { createFormActions } from '@formily/antd';
import EyePreview from '@/components/EyePreview';
......@@ -126,8 +127,22 @@ const MemberPr2: React.FC<{}> = props => {
};
const fetchListData = async (params: any) => {
let res = await PublicApi.getMemberAbilityValidateStep2Page(params);
return res.data;
const { startDate = null, endDate = null } = params;
const payload = { ...params };
if (startDate) {
payload.startDate = moment(+startDate).format('YYYY-MM-DD');
}
if (endDate) {
payload.endDate = moment(+endDate).format('YYYY-MM-DD');
}
const res = await PublicApi.getMemberAbilityValidateStep2Page(payload);
if (res.code === 1000) {
return res.data;
}
return [];
};
const handleBatch = () => {
......
......@@ -3,6 +3,7 @@ import { history } from 'umi';
import { Card, Space, Button, Badge, Modal, message } from 'antd';
import { ClockCircleOutlined, QuestionCircleOutlined } from '@ant-design/icons';
import { StandardTable } from 'god';
import moment from 'moment';
import { ColumnType } from 'antd/lib/table/interface';
import { createFormActions } from '@formily/antd';
import EyePreview from '@/components/EyePreview';
......@@ -129,8 +130,22 @@ const MemberPrConfirm: React.FC<{}> = props => {
};
const fetchListData = async (params: any) => {
let res = await PublicApi.getMemberAbilityValidateConfirmPage(params);
return res.data;
const { startDate = null, endDate = null } = params;
const payload = { ...params };
if (startDate) {
payload.startDate = moment(+startDate).format('YYYY-MM-DD');
}
if (endDate) {
payload.endDate = moment(+endDate).format('YYYY-MM-DD');
}
const res = await PublicApi.getMemberAbilityValidateConfirmPage(payload);
if (res.code === 1000) {
return res.data;
}
return [];
};
const handleBatch = () => {
......
......@@ -3,6 +3,7 @@ import { history } from 'umi';
import { Card, Space, Button, Badge, Modal, message } from 'antd';
import { ClockCircleOutlined, QuestionCircleOutlined } from '@ant-design/icons';
import { StandardTable } from 'god';
import moment from 'moment';
import { ColumnType } from 'antd/lib/table/interface';
import { createFormActions } from '@formily/antd';
import EyePreview from '@/components/EyePreview';
......@@ -126,8 +127,22 @@ const MemberPrSubmit: React.FC<{}> = props => {
};
const fetchListData = async (params: any) => {
let res = await PublicApi.getMemberAbilityValidateCommitPage(params);
return res.data;
const { startDate = null, endDate = null } = params;
const payload = { ...params };
if (startDate) {
payload.startDate = moment(+startDate).format('YYYY-MM-DD');
}
if (endDate) {
payload.endDate = moment(+endDate).format('YYYY-MM-DD');
}
const res = await PublicApi.getMemberAbilityValidateCommitPage(payload);
if (res.code === 1000) {
return res.data;
}
return [];
};
const handleBatch = () => {
......
......@@ -24,9 +24,20 @@ export const billsTypeDetailSchema: ISchema = {
title: '单据类型编号',
'x-component-props': {
placeholder: '最长10个字符',
maxLength: 5,
maxLength: 10,
},
required: true,
'x-rules': [
{
required: true,
message: '请输入单据类型编号',
},
{
validator: value => {
const CNReg = /[\u4E00-\u9FA5]/g;
return CNReg.test(value) ? '请输入非中文字符,可以是字母 + 数字 + 字符的组合' : '';
},
},
],
},
name: {
type: 'string',
......
......@@ -110,7 +110,16 @@ export const warehouseDetailSchema: ISchema = {
'x-component-props': {
label: '仓库名称',
wrapperCol: 24,
required: true,
'x-rules': [
{
required: true,
message: '请输入仓库名称',
},
{
limitByte: true, // 自定义校验规则
maxByte: 20,
}
],
},
properties: {
MEGA_LAYOUT1_1: {
......@@ -185,7 +194,13 @@ export const warehouseDetailSchema: ISchema = {
principal: {
type: 'string',
title: '仓库负责人',
'x-component-props': {},
'x-component-props': {},
'x-rules': [
{
limitByte: true, // 自定义校验规则
maxByte: 16,
}
],
},
MEGA_LAYOUT2: {
type: 'object',
......@@ -221,10 +236,6 @@ export const warehouseDetailSchema: ISchema = {
},
'x-rules': [
{
required: true,
message: '请输入你的手机号码',
},
{
pattern: PATTERN_MAPS.phone,
message: '请输入正确格式的手机号',
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment