Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
A
admin-ci-test
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
test-ci
admin-ci-test
Commits
657c23a4
提交
657c23a4
authored
7月 19, 2023
作者:
龚洪江
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'develop'
上级
d83d5086
08a1cd0f
隐藏空白字符变更
内嵌
并排
正在显示
13 个修改的文件
包含
219 行增加
和
116 行删除
+219
-116
kustomization.yaml
kustomization/overlays/dev/kustomization.yaml
+1
-1
index.tsx
src/components/EditableCell/index.tsx
+3
-23
index.tsx
...ponents/goods/commonAddOrEdit/addOrEditSkuModal/index.tsx
+3
-0
index.tsx
src/components/richText/index.tsx
+1
-1
index.tsx
...nation/addOrEditInstitution/components/baseInfo/index.tsx
+3
-7
index.scss
.../addOrEditInstitution/components/introduceInfo/index.scss
+4
-0
index.scss
...nation/addOrEditInstitution/components/skuInfo/index.scss
+4
-0
index.tsx
...ination/addOrEditInstitution/components/skuInfo/index.tsx
+22
-1
index.tsx
...ning/ licensureExamination/addOrEditInstitution/index.tsx
+18
-11
index.tsx
...Training/ licensureExamination/institutionsList/index.tsx
+105
-18
index.ts
src/router/index.ts
+1
-1
router.tsx
src/router/router.tsx
+53
-52
validateUtils.ts
src/utils/validateUtils.ts
+1
-1
没有找到文件。
kustomization/overlays/dev/kustomization.yaml
浏览文件 @
657c23a4
...
...
@@ -14,4 +14,4 @@ patches:
images
:
-
name
:
REGISTRY/NAMESPACE/IMAGE:TAG
newName
:
mmc-registry.cn-shenzhen.cr.aliyuncs.com/sharefly-dev/admin
newTag
:
2bc3f5681467023eaf7d732d8bffde2e434fe72a
newTag
:
843987a0ad1fd382895fe3cccbd37490f1b36f28
src/components/EditableCell/index.tsx
浏览文件 @
657c23a4
...
...
@@ -17,6 +17,7 @@ const EditableCell: React.FC<
EditableCellProps
&
{
selectOption
?:
{
name
:
string
;
id
:
number
}[];
uploadSuccess
?:
(
record
:
any
,
result
:
any
)
=>
void
;
rules
?:
any
;
}
>
=
({
editing
,
...
...
@@ -28,6 +29,7 @@ const EditableCell: React.FC<
selectOption
,
uploadSuccess
,
children
,
rules
,
...
restProps
})
=>
{
const
inputNode
=
()
=>
{
...
...
@@ -60,32 +62,10 @@ const EditableCell: React.FC<
return
<
Input
placeholder=
{
`请输入${title}`
}
/>;
}
};
const
getMessage
=
()
=>
{
switch
(
inputType
)
{
case
'number'
:
case
'text'
:
return
`请输入
${
title
}
`
;
case
'select'
:
return
`请选择
${
title
}
`
;
case
'uploader'
:
return
`请上传
${
title
}
`
;
default
:
return
`请输入
${
title
}
`
;
}
};
return
(
<
td
{
...
restProps
}
>
{
editing
?
(
<
Form
.
Item
name=
{
dataIndex
+
record
.
id
}
style=
{
{
margin
:
0
}
}
rules=
{
[
{
required
:
true
,
message
:
getMessage
(),
},
]
}
>
<
Form
.
Item
name=
{
dataIndex
+
record
.
id
}
style=
{
{
margin
:
0
}
}
rules=
{
rules
}
>
{
inputNode
()
}
</
Form
.
Item
>
)
:
(
...
...
src/components/goods/commonAddOrEdit/addOrEditSkuModal/index.tsx
浏览文件 @
657c23a4
...
...
@@ -88,12 +88,14 @@ const AddOrEditSkuModal: React.FC<ModalProps & selfProps> = ({
align
:
'center'
,
dataIndex
:
'specName'
,
editable
:
true
,
rules
:
[{
required
:
true
,
message
:
'请输入选项名称'
}],
},
{
title
:
'料号'
,
align
:
'center'
,
dataIndex
:
'partNo'
,
editable
:
true
,
rules
:
[{
required
:
true
,
message
:
'请输入料号'
}],
},
{
title
:
'操作'
,
...
...
@@ -143,6 +145,7 @@ const AddOrEditSkuModal: React.FC<ModalProps & selfProps> = ({
dataIndex
:
col
.
dataIndex
,
title
:
col
.
title
,
editing
:
true
,
rules
:
col
.
rules
,
}),
};
});
...
...
src/components/richText/index.tsx
浏览文件 @
657c23a4
...
...
@@ -70,7 +70,7 @@ const RichText: React.FC<PropsType> = ({
//富文本修改
const
richTextChange
=
(
editor
:
IDomEditor
)
=>
{
if
(
onChange
)
{
onChange
(
editor
.
getHtml
()
||
''
);
onChange
(
editor
.
isEmpty
()
?
''
:
editor
.
getHtml
()
);
}
};
useEffect
(()
=>
{
...
...
src/pages/pilotTraining/ licensureExamination/addOrEditInstitution/components/baseInfo/index.tsx
浏览文件 @
657c23a4
...
...
@@ -17,7 +17,7 @@ interface selfProps {
//上传机构请求类型
type
insertOrgParametersType
=
Omit
<
InterReqType
<
insertOrgType
>
,
'trainingProgramsVOS'
>
;
const
BaseInfo
:
FC
<
selfProps
>
=
forwardRef
((
props
,
ref
)
=>
{
const
BaseInfo
:
FC
<
selfProps
>
=
forwardRef
((
_
props
,
ref
)
=>
{
const
[
baseInfoForm
]
=
Form
.
useForm
<
insertOrgParametersType
>
();
//地图地点选择
const
[
selectMapShow
,
setSelectMapShow
]
=
useState
<
boolean
>
(
false
);
...
...
@@ -157,11 +157,7 @@ const BaseInfo: FC<selfProps> = forwardRef((props, ref) => {
<
UploadOutlined
/>
</
Uploader
>
</
Form
.
Item
>
<
Form
.
Item
label=
'机构副图'
name=
'auxiliaryPicture'
rules=
{
[{
required
:
true
,
message
:
'请上传机构副图'
}]
}
>
<
Form
.
Item
label=
'机构副图'
name=
'auxiliaryPicture'
>
<
Uploader
fileUpload
listType=
'picture-card'
...
...
@@ -206,7 +202,7 @@ const BaseInfo: FC<selfProps> = forwardRef((props, ref) => {
name=
'name'
rules=
{
[{
required
:
true
,
message
:
'请输入机构名称'
}]
}
>
<
Input
placeholder=
'请输入机构名称'
maxLength=
{
30
}
/>
<
Input
placeholder=
'请输入机构名称'
maxLength=
{
25
}
/>
</
Form
.
Item
>
<
Form
.
Item
label=
'机构地区'
...
...
src/pages/pilotTraining/ licensureExamination/addOrEditInstitution/components/introduceInfo/index.scss
浏览文件 @
657c23a4
...
...
@@ -4,6 +4,10 @@
font-weight
:
bold
;
margin-bottom
:
10px
;
line-height
:
20px
;
&
:before
{
content
:
'*'
;
color
:
red
;
}
}
&
-rich
{
...
...
src/pages/pilotTraining/ licensureExamination/addOrEditInstitution/components/skuInfo/index.scss
浏览文件 @
657c23a4
...
...
@@ -4,6 +4,10 @@
font-weight
:
bold
;
margin-bottom
:
10px
;
line-height
:
20px
;
&
:before
{
content
:
'*'
;
color
:
red
;
}
}
&
-table
{
...
...
src/pages/pilotTraining/ licensureExamination/addOrEditInstitution/components/skuInfo/index.tsx
浏览文件 @
657c23a4
...
...
@@ -32,7 +32,7 @@ interface selfProps {
ref
:
any
;
}
const
SkuInfo
:
FC
<
selfProps
>
=
forwardRef
((
props
,
ref
)
=>
{
const
SkuInfo
:
FC
<
selfProps
>
=
forwardRef
((
_
props
,
ref
)
=>
{
const
[
skuForm
]
=
Form
.
useForm
<
any
>
();
//机型下拉列表
const
[
modelsList
,
setModelsList
]
=
useState
<
modelsListType
>
([]);
...
...
@@ -41,11 +41,25 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
//执照类型列表
const
[
typeList
,
setTypeList
]
=
useState
<
typeListType
>
([]);
//价格正则
const
priceValidator
=
(
_rule
:
any
,
value
:
any
)
=>
{
const
reg
=
/^
\d
+
(\.\d{1,2})?
$/
;
if
(
reg
.
test
(
value
))
{
if
(
value
<
0
||
value
>
100000
)
{
return
Promise
.
reject
(
new
Error
(
'价格大于0且小于10万'
));
}
}
else
{
return
Promise
.
reject
(
new
Error
(
'价格为数字且保留小数点后两位'
));
}
return
Promise
.
resolve
();
};
const
defaultColumns
:
(
ColumnTypes
[
number
]
&
{
editable
?:
boolean
;
dataIndex
?:
string
;
selectOption
?:
{
name
:
string
;
id
:
number
}[];
inputType
?:
string
;
rules
?:
any
;
})[]
=
[
{
title
:
'序号'
,
...
...
@@ -60,6 +74,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
width
:
'10%'
,
inputType
:
'uploader'
,
editable
:
true
,
rules
:
[{
required
:
true
,
message
:
'请上传培训主图'
}],
},
{
title
:
'培训机型'
,
...
...
@@ -69,6 +84,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
inputType
:
'select'
,
width
:
'15%'
,
selectOption
:
modelsList
,
rules
:
[{
required
:
true
,
message
:
'请选择培训机型'
}],
},
{
title
:
'培训等级'
,
...
...
@@ -78,6 +94,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
inputType
:
'select'
,
width
:
'15%'
,
selectOption
:
gradeList
,
rules
:
[{
required
:
true
,
message
:
'请选择培训等级'
}],
},
{
title
:
'培训类型'
,
...
...
@@ -87,6 +104,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
inputType
:
'select'
,
width
:
'15%'
,
selectOption
:
typeList
,
rules
:
[{
required
:
true
,
message
:
'请选择培训类型'
}],
},
{
title
:
'培训价格'
,
...
...
@@ -94,6 +112,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
editable
:
true
,
dataIndex
:
'price'
,
width
:
'12%'
,
rules
:
[{
required
:
true
,
validator
:
priceValidator
}],
},
{
title
:
'操作'
,
...
...
@@ -142,6 +161,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
selectOption
:
col
.
selectOption
,
inputType
:
col
.
inputType
,
uploadSuccess
:
col
.
inputType
===
'uploader'
?
uploadSuccess
:
undefined
,
rules
:
col
.
rules
,
}),
};
});
...
...
@@ -211,6 +231,7 @@ const SkuInfo: FC<selfProps> = forwardRef((props, ref) => {
setTypeList
(
result
||
[]);
});
};
useEffect
(()
=>
{
getLicenceModelsList
();
getLicenceGradeList
();
...
...
src/pages/pilotTraining/ licensureExamination/addOrEditInstitution/index.tsx
浏览文件 @
657c23a4
...
...
@@ -43,6 +43,9 @@ const AddOrEditInstitution = () => {
skuRef
.
current
.
getForm
().
validateFields
(),
])
.
then
((
value
)
=>
{
if
(
!
introduceInfo
)
{
return
message
.
warning
(
'机构介绍不能为空'
);
}
const
skuReqData
=
skuRef
.
current
.
getTableData
().
map
((
v
:
tableDataType
)
=>
{
return
Object
.
getOwnPropertyNames
(
v
).
reduce
((
pre
:
any
,
cur
:
string
)
=>
{
if
(
Object
.
getOwnPropertyNames
(
value
[
1
]).
includes
(
cur
+
v
.
id
))
{
...
...
@@ -94,7 +97,7 @@ const AddOrEditInstitution = () => {
if
(
institutionDetail
)
{
baseRef
.
current
.
getForm
().
setFieldsValue
({
mainImage
:
institutionDetail
.
mainImage
,
auxiliaryPicture
:
institutionDetail
.
auxiliaryPicture
,
auxiliaryPicture
:
institutionDetail
.
auxiliaryPicture
||
undefined
,
video
:
institutionDetail
.
video
,
name
:
institutionDetail
.
name
,
region
:
institutionDetail
.
region
,
...
...
@@ -117,21 +120,25 @@ const AddOrEditInstitution = () => {
},
]);
baseRef
.
current
.
getDefaultDataEvent
().
setSubImgList
(
institutionDetail
.
auxiliaryPicture
.
split
(
','
).
map
((
v
:
string
)
=>
({
institutionDetail
.
auxiliaryPicture
?
.
split
(
','
).
map
((
v
:
string
)
=>
({
id
:
Math
.
random
(),
uid
:
Math
.
random
(),
url
:
v
,
name
:
'auxiliaryPicture'
,
})),
}))
||
[],
);
baseRef
.
current
.
getDefaultDataEvent
().
setVideoList
(
institutionDetail
.
video
?
[
{
id
:
Math
.
random
(),
uid
:
Math
.
random
(),
url
:
institutionDetail
.
video
,
name
:
'video'
,
},
]
:
[],
);
baseRef
.
current
.
getDefaultDataEvent
().
setVideoList
([
{
id
:
Math
.
random
(),
uid
:
Math
.
random
(),
url
:
institutionDetail
.
video
,
name
:
'video'
,
},
]);
const
programsList
=
institutionDetail
.
programsDOList
.
map
((
v
)
=>
({
...
v
,
fileList
:
[
...
...
src/pages/pilotTraining/ licensureExamination/institutionsList/index.tsx
浏览文件 @
657c23a4
import
SearchBox
,
{
searchColumns
}
from
'~/components/search-box'
;
import
{
Button
,
message
,
Modal
,
Table
,
Tag
}
from
'antd'
;
import
{
Button
,
message
,
Modal
,
Table
}
from
'antd'
;
import
{
ColumnsType
}
from
'antd/es/table'
;
import
{
PlusOutlined
}
from
'@ant-design/icons'
;
import
{
useNavigate
}
from
'react-router-dom'
;
import
{
PilotTrainAPI
}
from
'~/api'
;
import
{
useEffect
,
useState
}
from
'react'
;
import
{
InterDataType
,
PaginationProps
}
from
'~/api/interface'
;
import
{
listOrgPageType
}
from
'~/api/interface/pilotTrainType'
;
import
{
InterDataType
,
InterReqType
,
PaginationProps
}
from
'~/api/interface'
;
import
{
licenceGradeListType
,
licenceModelsListType
,
licenceTypeListType
,
listOrgPageType
,
}
from
'~/api/interface/pilotTrainType'
;
import
{
filterObjAttr
}
from
'~/utils'
;
//机构列表返回类型
type
institutionListType
=
InterDataType
<
listOrgPageType
>
[
'list'
];
//机型下拉返回类型
type
modelsListType
=
InterDataType
<
licenceModelsListType
>
;
//等级下拉返回类型
type
gradeListType
=
InterDataType
<
licenceGradeListType
>
;
//执照类型返回类型
type
typeListType
=
InterDataType
<
licenceTypeListType
>
;
//机构列表请求参数类型
type
listOrgPageParametersType
=
InterReqType
<
listOrgPageType
>
;
const
InstitutionsList
=
()
=>
{
const
navigate
=
useNavigate
();
//培训类型下拉
//机型下拉列表
const
[
modelsList
,
setModelsList
]
=
useState
<
modelsListType
>
([]);
//等级下拉列表
const
[
gradeList
,
setGradeList
]
=
useState
<
gradeListType
>
([]);
//执照类型列表
const
[
typeList
,
setTypeList
]
=
useState
<
typeListType
>
([]);
const
search
:
searchColumns
[]
=
[
{
label
:
'机构名称'
,
name
:
''
,
placeholder
:
'请输入机构名称'
,
type
:
'input'
},
{
label
:
'培训类型'
,
name
:
''
,
placeholder
:
'请选择培训类型'
,
type
:
'select'
,
options
:
[]
},
{
label
:
'选择日期'
,
name
:
''
,
placeholder
:
'请选择日期'
,
type
:
'rangePicker'
,
options
:
[]
},
{
label
:
'机构名称'
,
name
:
'name'
,
placeholder
:
'请输入机构名称'
,
type
:
'input'
},
{
label
:
'培训等级'
,
name
:
'gradeId'
,
placeholder
:
'请选择培训等级'
,
type
:
'select'
,
options
:
gradeList
,
},
{
label
:
'培训机型'
,
name
:
'modelsId'
,
placeholder
:
'请选择培训机型'
,
type
:
'select'
,
options
:
modelsList
,
},
{
label
:
'培训类型'
,
name
:
'typeId'
,
placeholder
:
'请选择培训类型'
,
type
:
'select'
,
options
:
typeList
,
},
{
label
:
'选择日期'
,
name
:
'time'
,
placeholder
:
'请选择日期'
,
type
:
'rangePicker'
,
options
:
[],
},
];
const
tableColumns
:
ColumnsType
<
institutionListType
[
0
]
>
=
[
{
...
...
@@ -36,7 +80,11 @@ const InstitutionsList = () => {
title
:
'培训类型'
,
align
:
'center'
,
render
:
(
_text
:
string
,
record
)
=>
record
.
programsDOList
.
map
((
v
)
=>
<
Tag
key=
{
v
.
id
}
>
{
v
.
typeName
}
</
Tag
>),
record
.
programsDOList
[
0
].
gradeName
+
'/'
+
record
.
programsDOList
[
0
].
modelsName
+
'/'
+
record
.
programsDOList
[
0
].
typeName
,
width
:
'20%'
,
},
{
...
...
@@ -65,25 +113,28 @@ const InstitutionsList = () => {
pageSize
:
10
,
totalCount
:
0
,
});
const
[
query
,
setQuery
]
=
useState
<
listOrgPageParametersType
>
();
const
toAddInstitutions
=
()
=>
{
navigate
(
'/pilotTraining/institutionsList/add'
);
};
//机构列表
const
getListOrgPage
=
()
=>
{
PilotTrainAPI
.
getListOrgPage
({
pageNo
:
pagination
.
pageNo
,
pageSize
:
pagination
.
pageSize
}).
then
(
({
result
})
=>
{
setTableData
(
result
.
list
||
[]);
pagination
.
totalCount
=
result
.
totalCount
;
setPagination
(
pagination
);
},
);
const
getListOrgPage
=
(
query
?:
listOrgPageParametersType
)
=>
{
PilotTrainAPI
.
getListOrgPage
({
pageNo
:
pagination
.
pageNo
,
pageSize
:
pagination
.
pageSize
,
...
query
,
}).
then
(({
result
})
=>
{
setTableData
(
result
.
list
||
[]);
pagination
.
totalCount
=
result
.
totalCount
;
setPagination
(
pagination
);
});
};
//分页-监听
const
paginationChange
=
(
pageNo
:
number
,
pageSize
:
number
)
=>
{
pagination
.
pageNo
=
pageNo
;
pagination
.
pageSize
=
pageSize
;
getListOrgPage
();
getListOrgPage
(
query
);
};
//机构删除
const
deleteInstitutionsClick
=
(
record
:
institutionListType
[
0
])
=>
{
...
...
@@ -107,8 +158,42 @@ const InstitutionsList = () => {
const
editInstitutionsClick
=
(
record
:
institutionListType
[
0
])
=>
{
navigate
({
pathname
:
'/pilotTraining/institutionsList/edit'
,
search
:
`id=
${
record
.
id
}
`
});
};
//培训机型下拉
const
getLicenceModelsList
=
()
=>
{
PilotTrainAPI
.
getLicenceModelsList
().
then
(({
result
})
=>
{
setModelsList
(
result
||
[]);
});
};
//培训等级下拉
const
getLicenceGradeList
=
()
=>
{
PilotTrainAPI
.
getLicenceGradeList
().
then
(({
result
})
=>
{
setGradeList
(
result
||
[]);
});
};
//培训类型下拉
const
getLicenceTypeList
=
()
=>
{
PilotTrainAPI
.
getLicenceTypeList
().
then
(({
result
})
=>
{
setTypeList
(
result
||
[]);
});
};
//筛选
const
searchSuccess
=
(
value
:
any
)
=>
{
const
req
=
{
...
filterObjAttr
(
value
,
[
'time'
]),
startTime
:
value
.
startTime
?
value
.
startTime
.
split
(
' '
)[
0
]
:
undefined
,
endTime
:
value
.
endTime
?
value
.
endTime
.
split
(
' '
)[
0
]
:
undefined
,
};
setQuery
(
req
);
pagination
.
pageNo
=
1
;
pagination
.
pageSize
=
10
;
getListOrgPage
(
req
);
};
useEffect
(()
=>
{
getListOrgPage
();
getLicenceModelsList
();
getLicenceGradeList
();
getLicenceTypeList
();
},
[]);
return
(
<
div
className=
'institutions-list'
>
...
...
@@ -119,11 +204,13 @@ const InstitutionsList = () => {
新增
</
Button
>
}
searchData=
{
searchSuccess
}
/>
<
Table
bordered
columns=
{
tableColumns
}
dataSource=
{
tableData
}
rowKey=
'id'
pagination=
{
{
total
:
pagination
.
totalCount
,
pageSize
:
pagination
.
pageSize
,
...
...
src/router/index.ts
浏览文件 @
657c23a4
...
...
@@ -22,7 +22,7 @@ export const authRouterList = async () => {
const
getRouteList
=
(
data
:
RouteObjectType
[])
=>
{
return
data
.
reduce
((
pre
:
RouteObjectType
[],
cur
)
=>
{
const
Obj
:
RouteObjectType
=
{
...
cur
};
if
(
ids
.
includes
(
Obj
.
meta
.
id
)
||
Obj
.
meta
.
hidden
||
Obj
.
path
?.
includes
(
'pilotTraining'
)
)
{
if
(
ids
.
includes
(
Obj
.
meta
.
id
)
||
Obj
.
meta
.
hidden
)
{
if
(
Obj
.
children
)
{
Obj
.
children
=
[...
getRouteList
(
Obj
.
children
)];
}
...
...
src/router/router.tsx
浏览文件 @
657c23a4
...
...
@@ -33,6 +33,7 @@ import {
ReadOutlined
,
ThunderboltOutlined
,
BankOutlined
,
VerifiedOutlined
,
}
from
'@ant-design/icons'
;
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore
...
...
@@ -102,14 +103,14 @@ const CategoryDetail = React.lazy(() => import('~/pages/categoryManage/category/
// 目录管理
const
DirectoryManage
=
React
.
lazy
(()
=>
import
(
'~/pages/categoryManage/directoryManage'
));
//
//
飞手培训
//
const InstitutionsListView = React.lazy(
//
() => import('~/pages/pilotTraining/ licensureExamination/institutionsList'),
//
);
//
//
机构上传
//
const AddInstitutionsView = React.lazy(
//
() => import('~/pages/pilotTraining/ licensureExamination/addOrEditInstitution'),
//
);
//飞手培训
const
InstitutionsListView
=
React
.
lazy
(
()
=>
import
(
'~/pages/pilotTraining/ licensureExamination/institutionsList'
),
);
//机构上传
const
AddInstitutionsView
=
React
.
lazy
(
()
=>
import
(
'~/pages/pilotTraining/ licensureExamination/addOrEditInstitution'
),
);
// 系统管理
import
AccountManageView
from
'~/pages/systemManage/accountManage'
;
...
...
@@ -895,50 +896,50 @@ export const routerList: Array<RouteObjectType> = [
// },
// ],
// },
//
{
//
path: '/pilotTraining',
//
element: <LayoutView />,
//
errorElement: <ErrorPage />,
//
meta: {
// id: 15
00,
//
icon: <BankOutlined />,
//
title: '飞手培训',
//
},
//
children: [
//
{
//
path: '/pilotTraining/institutionsList',
//
element: withLoadingComponent(<InstitutionsListView />),
//
errorElement: <ErrorPage />,
//
meta: {
// id: 15
10,
//
title: '执照考试',
//
icon: <VerifiedOutlined />,
//
},
//
},
//
{
//
path: '/pilotTraining/institutionsList/add',
//
element: withLoadingComponent(<AddInstitutionsView />),
//
errorElement: <ErrorPage />,
//
meta: {
//
id: 1520,
//
title: '机构上传',
//
icon: <UserOutlined />,
//
hidden: true,
//
},
//
},
//
{
//
path: '/pilotTraining/institutionsList/edit',
//
element: withLoadingComponent(<AddInstitutionsView />),
//
errorElement: <ErrorPage />,
//
meta: {
//
id: 1530,
//
title: '机构编辑',
//
icon: <UserOutlined />,
//
hidden: true,
//
},
//
},
//
],
//
},
{
path
:
'/pilotTraining'
,
element
:
<
LayoutView
/>,
errorElement
:
<
ErrorPage
/>,
meta
:
{
id
:
16
00
,
icon
:
<
BankOutlined
/>,
title
:
'飞手培训'
,
},
children
:
[
{
path
:
'/pilotTraining/institutionsList'
,
element
:
withLoadingComponent
(<
InstitutionsListView
/>),
errorElement
:
<
ErrorPage
/>,
meta
:
{
id
:
16
10
,
title
:
'执照考试'
,
icon
:
<
VerifiedOutlined
/>,
},
},
{
path
:
'/pilotTraining/institutionsList/add'
,
element
:
withLoadingComponent
(<
AddInstitutionsView
/>),
errorElement
:
<
ErrorPage
/>,
meta
:
{
id
:
1520
,
title
:
'机构上传'
,
icon
:
<
UserOutlined
/>,
hidden
:
true
,
},
},
{
path
:
'/pilotTraining/institutionsList/edit'
,
element
:
withLoadingComponent
(<
AddInstitutionsView
/>),
errorElement
:
<
ErrorPage
/>,
meta
:
{
id
:
1530
,
title
:
'机构编辑'
,
icon
:
<
UserOutlined
/>,
hidden
:
true
,
},
},
],
},
{
path
:
'/systemManage'
,
element
:
<
LayoutView
/>,
...
...
src/utils/validateUtils.ts
浏览文件 @
657c23a4
// 不能输入数字,其他可
惜
输入
// 不能输入数字,其他可
以
输入
export
const
exceptNumber
=
(
val
:
any
)
=>
{
val
.
target
.
value
=
val
.
target
.
value
.
replace
(
/1
?(\d
|
([
1-9
]\d
+
))(
.
\d
+
)?
$/g
,
''
).
replace
(
/
\s
/g
,
''
);
};
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论