Commit ead61aee authored by 前端-许佳敏's avatar 前端-许佳敏

修复注册bug,新增采购订单

parent afd9d15d
...@@ -84,6 +84,20 @@ const TranactionRoute = { ...@@ -84,6 +84,20 @@ const TranactionRoute = {
}, },
] ]
},
// 采购订单
{
path: '/memberCenter/tranactionAbility/purchaseOrder',
name: 'purchaseOrder',
key: 'purchaseOrder',
routes: [
{
path: '/memberCenter/tranactionAbility/purchaseOrder/orderList',
name: 'purchaseOrderSearch',
key: 'purchaseOrderSearch',
component: '@/pages/transaction/purchaseOrder'
},
]
} }
] ]
......
...@@ -23,7 +23,7 @@ export interface ShopInfo { ...@@ -23,7 +23,7 @@ export interface ShopInfo {
type: number; type: number;
environment: number; environment: number;
logoUrl: string; logoUrl: string;
describe: string; describe?: any;
state: number; state: number;
url: string; url: string;
} }
......
...@@ -276,3 +276,9 @@ h6 { ...@@ -276,3 +276,9 @@ h6 {
top: 36px !important; top: 36px !important;
} }
} }
// 强制块级标签居中
.global-block-center {
margin-left: auto !important;
margin-right: auto !important;
}
\ No newline at end of file
import { useState, useMemo } from 'react';
interface stringMethods {
[key: string]: (...args) => any
}
/**
* @description 传入一个值和方法map, 返回对应控制该状态的fn
* @param initialValue 初始状态
* @param methods 控制状态的方法集合对象
* @author xjm
*/
export const useMethods = <T>(initialValue: T, methods: stringMethods) => {
const [value, setValue] = useState<T>(initialValue);
const boundMethods = useMemo(
() => Object.entries(methods).reduce(
(methods, [name, fn]) => {
const method = (...args) => {
setValue(value => fn(value, ...args));
};
methods[name] = method;
return methods;
},
{}
),
[methods]
);
return [value, boundMethods];
};
\ No newline at end of file
...@@ -97,6 +97,8 @@ export default { ...@@ -97,6 +97,8 @@ export default {
'menu.tranactionAbility.enquirySubmit': '需求发布', 'menu.tranactionAbility.enquirySubmit': '需求发布',
'menu.tranactionAbility.enquirySubmit.SearchList': '待新增需求单', 'menu.tranactionAbility.enquirySubmit.SearchList': '待新增需求单',
'menu.tranactionAbility.enquirySubmit.addEnquiry': '新增需求单', 'menu.tranactionAbility.enquirySubmit.addEnquiry': '新增需求单',
'menu.tranactionAbility.purchaseOrder': '采购订单',
'menu.tranactionAbility.purchaseOrder.purchaseOrderSearch': '订单查询',
//物流能力 //物流能力
'menu.logisticsAbility': '物流', 'menu.logisticsAbility': '物流',
......
import React from 'react'
import DetailPage from '@/components/DetailPage'
import { Card } from 'antd'
import { StandardTable } from 'god'
import { PageHeaderWrapper } from '@ant-design/pro-layout'
export interface PurchaseOrderProps {}
const orderColumns = [
{
dataIndex: 'orderId',
title: '订单号'
}
]
const fetchTableData = async (params) => {
return []
}
const PurchaseOrder:React.FC<PurchaseOrderProps> = (props) => {
return <PageHeaderWrapper>
<Card>
<StandardTable
fetchTableData={params => fetchTableData(params)}
columns={orderColumns}
/>
</Card>
</PageHeaderWrapper>
}
PurchaseOrder.defaultProps = {}
export default PurchaseOrder
\ No newline at end of file
...@@ -131,13 +131,11 @@ ...@@ -131,13 +131,11 @@
margin-bottom: 0; margin-bottom: 0;
} }
} }
.registerForm { .registerForm {
max-width: 335px; max-width: 335px;
margin: 0px auto; margin: 0px auto;
padding-top: 40px; padding-top: 40px;
} }
.registerBox { .registerBox {
width: 100%; width: 100%;
min-height: 700px; min-height: 700px;
......
...@@ -175,6 +175,9 @@ const UserRegistry = () => { ...@@ -175,6 +175,9 @@ const UserRegistry = () => {
PublicApi.postMemberRegister(params).then(() => { PublicApi.postMemberRegister(params).then(() => {
actions.dispatch('onFormStepNext', {}) actions.dispatch('onFormStepNext', {})
setCurrent(current + 1) setCurrent(current + 1)
}).finally(() => {
// 调用接口后 无论成功失败需清空缓存的数据
formCache = {}
}) })
}) })
} }
...@@ -205,7 +208,7 @@ const UserRegistry = () => { ...@@ -205,7 +208,7 @@ const UserRegistry = () => {
businessTypeTitle: <span className={styles.commonPanelTitle}>请选择您要开展的业务</span>, businessTypeTitle: <span className={styles.commonPanelTitle}>请选择您要开展的业务</span>,
}} }}
/> />
<div className={styles.registerForm}> <div className={cx(styles.registerForm, 'global-block-center')}>
{ {
current === 0 && current === 0 &&
<Button type='primary' className={styles.continueButton} onClick={handleActionBtn}>同意协议并注册</Button> <Button type='primary' className={styles.continueButton} onClick={handleActionBtn}>同意协议并注册</Button>
......
...@@ -9,7 +9,7 @@ export const registerStep0Schema: ISchema = { ...@@ -9,7 +9,7 @@ export const registerStep0Schema: ISchema = {
type: 'object', type: 'object',
"x-component": 'mega-layout', "x-component": 'mega-layout',
"x-component-props": { "x-component-props": {
className: 'registerForm', className: 'registerForm global-block-center',
full: true full: true
}, },
properties: { properties: {
...@@ -106,7 +106,7 @@ export const registerStep1Schema: ISchema = { ...@@ -106,7 +106,7 @@ export const registerStep1Schema: ISchema = {
type: 'object', type: 'object',
"x-component": 'mega-layout', "x-component": 'mega-layout',
"x-component-props": { "x-component-props": {
className: 'formBoxStep2' className: 'formBoxStep2 global-block-center'
}, },
properties: { properties: {
BLOCK_LAYOUT1: { BLOCK_LAYOUT1: {
...@@ -171,7 +171,7 @@ export const forgetPwdSchema: ISchema = { ...@@ -171,7 +171,7 @@ export const forgetPwdSchema: ISchema = {
type: 'object', type: 'object',
"x-component": 'mega-layout', "x-component": 'mega-layout',
"x-component-props": { "x-component-props": {
className: 'registerForm', className: 'registerForm global-block-center',
full: true full: true
}, },
properties: { properties: {
......
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