Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
web
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
iuav
web
Commits
045dbce7
提交
045dbce7
authored
5月 26, 2023
作者:
余乾开
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' into feature/chuck
上级
a41f701d
47f6e2ce
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
21 个修改的文件
包含
536 行增加
和
213 行删除
+536
-213
index.tsx
api/index.tsx
+25
-0
index.module.scss
components/NavHeader/index.module.scss
+1
-5
index.tsx
components/NavHeader/index.tsx
+30
-7
index.ts
components/NavHeader/joinModal/api/index.ts
+17
-0
img.png
components/NavHeader/joinModal/assets/img.png
+0
-0
index.module.scss
components/NavHeader/joinModal/index.module.scss
+31
-0
index.tsx
components/NavHeader/joinModal/index.tsx
+52
-0
index.module.scss
components/NavHeader/publishModal/index.module.scss
+4
-2
index.tsx
components/loginModal/index.tsx
+23
-12
hooks.js
lib/hooks.js
+13
-21
_app.page.tsx
pages/_app.page.tsx
+9
-0
index.tsx
pages/flyingHandService/api/index.tsx
+24
-7
index.page.tsx
pages/flyingHandService/index.page.tsx
+97
-9
index.tsx
pages/home/waterfallFlowBody/components/map/api/index.tsx
+40
-3
img.png
pages/home/waterfallFlowBody/components/map/assets/img.png
+0
-0
index.tsx
pages/home/waterfallFlowBody/components/map/index.tsx
+132
-124
index.tsx
pages/home/waterfallFlowBody/index.tsx
+34
-23
styled.tsx
pages/home/waterfallFlowBody/styled.tsx
+1
-0
index.module.scss
pages/mall/index.module.scss
+1
-0
index.page.tsx
pages/mall/index.page.tsx
+1
-0
type.d.ts
typings/type.d.ts
+1
-0
没有找到文件。
api/index.tsx
浏览文件 @
045dbce7
...
...
@@ -8,9 +8,34 @@ export interface RegionResp {
pid
:
number
;
}
export
interface
UserInfoParams
{
userAccountId
:
number
;
}
export
interface
UserInfoResp
{
id
:
number
;
accountType
:
number
;
uid
:
string
;
phoneNum
:
string
;
userName
:
string
;
nickName
:
string
;
userImg
:
string
;
userSex
:
number
;
email
:
string
;
source
:
number
;
accountStatus
:
number
;
remark
:
string
;
portType
:
number
;
createTime
:
string
;
}
export
default
{
//获取区域数据
region
:
():
Promise
<
Response
<
Array
<
RegionResp
>>>
=>
{
return
request
(
"/pms/webDevice/getSecondDistrictInfo"
);
},
//获取用户基本信息
userInfo
:
(
params
:
UserInfoParams
):
Promise
<
Response
<
UserInfoResp
>>
=>
{
return
request
(
"/userapp/user-account/info"
,
"get"
,
params
,
{});
},
};
components/NavHeader/index.module.scss
浏览文件 @
045dbce7
...
...
@@ -78,8 +78,4 @@
background
:
none
;
}
.headImg
{
width
:
48px
;
height
:
48px
;
background
:
#ffffff
;
}
components/NavHeader/index.tsx
浏览文件 @
045dbce7
import
React
,
{
useState
}
from
"react"
;
import
React
,
{
use
Effect
,
use
State
}
from
"react"
;
import
{
Avatar
,
Button
,
Space
,
Tabs
}
from
"antd"
;
import
type
{
TabsProps
}
from
"antd"
;
import
styles
from
"./index.module.scss"
;
...
...
@@ -6,6 +6,7 @@ import { useRouter } from "next/router";
import
LoginModal
from
"~/components/loginModal"
;
import
{
useUser
}
from
"~/lib/hooks"
;
import
PublishModal
from
"./publishModal"
;
import
JoinModal
from
"./joinModal"
;
const
items
:
TabsProps
[
"items"
]
=
[
{
...
...
@@ -40,10 +41,14 @@ const items: TabsProps["items"] = [
export
default
function
NavHeader
()
{
const
router
=
useRouter
();
const
currentPath
=
router
.
asPath
;
const
[
currentPath
,
setCurrentPath
]
=
useState
(
""
)
;
const
user
=
useUser
();
console
.
log
(
"currentHash"
,
currentPath
);
useEffect
(()
=>
{
setCurrentPath
(
router
.
route
);
console
.
log
(
"currentHash"
,
currentPath
);
},
[
router
.
route
]);
const
onChange
=
(
key
:
string
)
=>
{
router
.
push
(
key
);
};
...
...
@@ -59,13 +64,15 @@ export default function NavHeader() {
setPpenLoginModal
(
false
);
};
const
[
openJoinModal
,
setOpenJoinModal
]
=
useState
(
false
);
//加盟modal
return
(
<
div
className=
{
styles
.
navHeader
}
>
<
div
className=
{
styles
.
nav
}
>
<
div
className=
{
styles
.
logo
}
></
div
>
<
Tabs
className=
{
styles
.
tabs
}
defaultA
ctiveKey=
{
currentPath
}
a
ctiveKey=
{
currentPath
}
items=
{
items
}
onChange=
{
onChange
}
/>
...
...
@@ -77,11 +84,16 @@ export default function NavHeader() {
>
+ 发布需求
</
Button
>
<
Button
className=
{
styles
.
btn2
}
>
加盟入驻
</
Button
>
<
Button
className=
{
styles
.
btn2
}
onClick=
{
()
=>
setOpenJoinModal
(
true
)
}
>
加盟入驻
</
Button
>
</
Space
>
{
user
?
(
<
div
className=
{
styles
.
haedImg
}
>
<
Avatar
size=
{
48
}
style=
{
{
background
:
"#fff
"
}
}
></
Avatar
>
<
Avatar
size=
{
36
}
style=
{
{
background
:
"#bdbdbd
"
}
}
></
Avatar
>
</
div
>
)
:
(
<
Button
...
...
@@ -94,7 +106,18 @@ export default function NavHeader() {
)
}
</
div
>
<
LoginModal
open=
{
openLoginModal
}
onCancel=
{
handleCancel
}
></
LoginModal
>
<
PublishModal
open=
{
openPublishModal
}
onCancel=
{
()
=>
{
setOpenPublishModal
(
false
)}
}
></
PublishModal
>
<
PublishModal
open=
{
openPublishModal
}
onCancel=
{
()
=>
{
setOpenPublishModal
(
false
);
}
}
></
PublishModal
>
<
JoinModal
open=
{
openJoinModal
}
onCancel=
{
()
=>
{
setOpenJoinModal
(
false
);
}
}
></
JoinModal
>
</
div
>
);
}
components/NavHeader/joinModal/api/index.ts
0 → 100644
浏览文件 @
045dbce7
import
request
,
{
Response
}
from
"~/api/request"
export
interface
ListTagResp
{
id
:
number
;
tagName
:
string
;
tagImg
?:
string
;
tagDescription
:
string
;
createTime
:
string
;
}
export
default
{
//加盟标签列表
listTag
:
():
Promise
<
Response
<
Array
<
ListTagResp
>>>
=>
{
return
request
(
'/userapp/cooperation/listTag'
)
}
}
\ No newline at end of file
components/NavHeader/joinModal/assets/img.png
0 → 100644
浏览文件 @
045dbce7
15.5 KB
components/NavHeader/joinModal/index.module.scss
0 → 100644
浏览文件 @
045dbce7
.identityBtn
{
box-sizing
:
border-box
;
padding
:
0
5px
;
position
:
absolute
;
bottom
:
0
;
left
:
50%
;
transform
:translate
(
-50
%
,
0
)
;
min-width
:
100%
;
height
:
24px
;
background
:
#e26329
;
border-radius
:
6px
;
opacity
:
0
.95
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
font-size
:
12px
;
font-family
:
PingFangSC-Medium
,
PingFang
SC
;
font-weight
:
500
;
color
:
#fff
;
white-space
:
nowrap
;
}
.modal
{
:global
.ant-modal-content
{
border-radius
:
6px
;
.ant-modal-title
{
text-align
:
center
;
}
}
}
components/NavHeader/joinModal/index.tsx
0 → 100644
浏览文件 @
045dbce7
import
{
Col
,
Modal
,
Row
}
from
"antd"
;
import
Image
from
"next/image"
;
import
styles
from
"./index.module.scss"
;
import
img
from
"./assets/img.png"
;
import
{
useEffect
,
useState
}
from
"react"
;
import
api
,
{
ListTagResp
}
from
"./api"
;
type
Props
=
{
open
?:
boolean
;
onOk
?:
()
=>
void
;
onCancel
?:
()
=>
void
;
};
export
default
function
JoinModal
(
props
:
Props
)
{
const
test
=
[
{
name
:
'飞手培训机构'
,
id
:
0
}
];
const
[
tagList
,
setTagList
]
=
useState
<
ListTagResp
[]
>
([]);
useEffect
(()
=>
{
api
.
listTag
().
then
(
res
=>
{
setTagList
(
res
.
result
||
[]);
})
},
[])
return
(
<
Modal
title=
"申请合作加盟"
open=
{
props
.
open
}
onOk=
{
props
.
onOk
}
onCancel=
{
props
.
onCancel
}
className=
{
styles
.
modal
}
width=
{
460
}
footer=
{
null
}
>
<
Row
style=
{
{
padding
:
"22px 16px 20px 16px"
,
gap
:
"16px 40px"
}
}
>
{
tagList
.
map
((
item
)
=>
{
return
(
<
Col
key=
{
item
.
id
}
style=
{
{
cursor
:
"pointer"
,
height
:
100
,
padding
:
0
}
}
>
<
Image
src=
{
img
}
width=
{
100
}
height=
{
100
}
alt=
""
></
Image
>
<
div
className=
{
styles
.
identityBtn
}
>
{
item
.
tagName
}{
">"
}
</
div
>
</
Col
>
);
})
}
</
Row
>
</
Modal
>
);
}
components/NavHeader/publishModal/index.module.scss
浏览文件 @
045dbce7
.modal
{
width
:
460px
;
:global
.ant-modal-content
{
border-radius
:
0
;
.ant-modal-title
{
text-align
:
center
;
}
}
}
components/loginModal/index.tsx
浏览文件 @
045dbce7
import
React
,
{
useState
}
from
"react"
;
import
{
Modal
}
from
"antd"
;
import
React
,
{
use
Effect
,
use
State
}
from
"react"
;
import
{
AutoComplete
,
Modal
}
from
"antd"
;
import
Image
from
"next/image"
;
type
Props
=
{
open
:
boolean
;
onCancel
:
()
=>
void
;
};
export
default
function
loginModal
(
props
:
Props
)
{
export
default
function
LoginModal
(
props
:
Props
)
{
useEffect
(()
=>
{
if
(
props
.
open
)
{
var
obj
=
new
window
.
WxLogin
({
self_redirect
:
true
,
id
:
"login_container"
,
appid
:
"wx18b7883acd204278"
,
scope
:
"snsapi_login"
,
redirect_uri
:
encodeURIComponent
(
"https://iuav.mmcuav.cn/"
),
state
:
""
,
style
:
""
,
href
:
""
,
});
}
},
[
props
.
open
]);
return
(
<>
<
Modal
...
...
@@ -30,16 +44,13 @@ export default function loginModal(props: Props) {
>
欢迎来到云享飞
</
div
>
<
Image
alt=
""
src=
""
width=
{
160
}
height=
{
160
}
style=
{
{
margin
:
"auto"
,
display
:
"block"
}
}
></
Image
>
<
div
id=
"login_container"
style=
{
{
margin
:
"auto"
,
display
:
"table"
}
}
></
div
>
<
div
style=
{
{
marginTop
:
39
,
marginTop
:
-
120
,
marginBottom
:
52
,
fontSize
:
14
,
fontFamily
:
"MicrosoftYaHei"
,
...
...
lib/hooks.js
浏览文件 @
045dbce7
/* import { useEffect } from "react";
import Router from "next/router";
import request from '~/api/request';
import useSWR, { SWRResponse } from "swr"; */
import
{
useEffect
,
useState
}
from
"react"
;
import
api
,
{
UserInfoResp
}
from
"~/api"
;
/*
const fetcher = (url) =>
fetch(url)
...
...
@@ -10,24 +8,18 @@ const fetcher = (url) =>
return { user: data?.user || null };
}); */
export
function
useUser
({
redirectTo
,
redirectIfFound
}
=
{})
{
return
{};
/* const { data, error } = useSWR("/api/user", request);
const user = data?.user;
const finished = Boolean(data);
const hasUser = Boolean(user);
export
function
useUser
()
{
const
[
user
,
setUser
]
=
useState
(
null
);
useEffect
(()
=>
{
if (!redirectTo || !finished) return;
if (
// If redirectTo is set, redirect if the user was not found.
(redirectTo && !redirectIfFound && !hasUser) ||
// If redirectIfFound is also set, redirect if the user was found
(redirectIfFound && hasUser)
) {
Router.push(redirectTo);
}
}, [redirectTo, redirectIfFound, finished, hasUser]);
api
.
userInfo
({
userAccountId
:
0
,
})
.
then
((
res
)
=>
{
setUser
(
res
.
result
);
});
},
[]);
return
error ? null : user; */
return
user
;
}
pages/_app.page.tsx
浏览文件 @
045dbce7
...
...
@@ -4,6 +4,8 @@ import type { AppProps } from 'next/app';
import
withTheme
from
'../theme'
;
import
{
message
}
from
'antd'
;
import
{
useEffect
}
from
'react'
;
import
Head
from
"next/head"
;
import
Script
from
'next/script'
;
export
default
function
App
({
Component
,
pageProps
}:
AppProps
)
{
const
[
messageApi
,
contextHolder
]
=
message
.
useMessage
();
...
...
@@ -14,6 +16,13 @@ export default function App({ Component, pageProps }: AppProps) {
return
withTheme
(
<>
<
Head
>
<
meta
name=
"viewport"
content=
"width=device-width,initial-scale=1"
></
meta
>
</
Head
>
<
Script
src=
"https://res.wx.qq.com/connect/zh_CN/htmledition/js/wxLogin.js"
></
Script
>
{
contextHolder
}
<
Component
{
...
pageProps
}
/>
</>
...
...
pages/flyingHandService/api/index.tsx
浏览文件 @
045dbce7
...
...
@@ -29,16 +29,29 @@ export interface ListPageFlyingInfoResp {
export
interface
SkillsType
{
type
:
string
;
id
:
1
,
skillsName
:
string
id
:
number
,
skillsName
:
string
,
label
:
string
|
number
,
value
:
string
|
number
}
export
interface
RegionResp
{
"childInfo"
:
RegionResp
[]
|
null
,
"id"
:
number
,
"level"
:
number
,
"name"
:
string
,
"pid"
:
number
childInfo
:
RegionResp
[]
|
null
,
id
:
number
,
level
:
number
,
name
:
string
,
pid
:
number
}
export
interface
PilotRegistrationParams
{
city
?:
number
,
drivingLicense
?:
number
,
industryAppAuth
?:
Array
<
number
>
,
province
?:
number
,
remark
?:
string
,
telephone
?:
string
,
uavLicenseLevelOne
?:
number
,
uavLicenseLevelTwo
?:
number
}
export
default
{
...
...
@@ -55,4 +68,7 @@ export default {
IndustryFlightSkills
:
():
Promise
<
Response
<
Array
<
SkillsType
>>>
=>
{
return
request
(
'/release/curriculum/getIndustryFlightSkills'
);
},
PilotRegistrations
:
(
params
:
PilotRegistrationParams
):
Promise
<
Response
<
Array
<
SkillsType
>>>
=>
{
return
request
(
'/release/curriculum/pilotRegistration'
,
"post"
,
params
);
},
}
\ No newline at end of file
pages/flyingHandService/index.page.tsx
浏览文件 @
045dbce7
import
React
,
{
useEffect
,
useState
}
from
"react"
;
import
{
Box
}
from
"./styled"
;
import
Image
from
"next/image"
;
import
{
Button
,
Select
,
Space
,
Pagination
,
Cascader
,
Modal
}
from
"antd"
;
import
{
Button
,
Select
,
Space
,
Pagination
,
Cascader
,
Modal
,
Form
,
Input
,
Checkbox
,
message
}
from
"antd"
;
import
type
{
CheckboxValueType
}
from
'antd/es/checkbox/Group'
;
import
Layout
from
"~/components/layout"
;
import
ContentBox
from
"~/components/contentBox"
;
import
api
,
{
Flying
,
SkillsType
,
RegionResp
}
from
"./api"
;
...
...
@@ -13,6 +14,7 @@ interface FilterInfoParams {
}
export
default
function
FlyingHandService
()
{
const
{
Option
}
=
Select
const
router
=
useRouter
();
const
[
list
,
setList
]
=
useState
([
"https://pad-video-x.oss-cn-shenzhen.aliyuncs.com/file/925072db-5872-44dd-8b71-e408ad3adf41.jpg"
,
...
...
@@ -163,7 +165,12 @@ export default function FlyingHandService() {
setSkills
(
res
.
result
||
[]);
});
api
.
IndustryFlightSkills
().
then
((
res
)
=>
{
setFlightSkillsList
(
res
.
result
||
[]);
const
list
=
res
.
result
?.
map
((
item
)
=>
{
item
.
label
=
item
.
skillsName
item
.
value
=
item
.
id
return
item
})
setFlightSkillsList
(
list
||
[]);
});
},
[]);
...
...
@@ -185,18 +192,29 @@ export default function FlyingHandService() {
//报名
const
[
isModalOpen
,
setIsModalOpen
]
=
useState
(
false
);
const
[
loading
,
setLoading
]
=
useState
(
false
);
const
handleOk
=
()
=>
{
const
handleOk
=
async
(
values
:
any
)
=>
{
const
value
=
form
.
getFieldsValue
()
setLoading
(
true
);
setTimeout
(()
=>
{
try
{
const
res
=
await
api
.
PilotRegistrations
(
value
)
setLoading
(
false
);
setIsModalOpen
(
false
);
},
3000
);
form
.
resetFields
()
message
.
success
(
'报名成功'
)
}
catch
(
e
:
any
){
message
.
error
(
e
.
message
)
}
};
const
handleCancel
=
()
=>
{
setIsModalOpen
(
false
);
};
const
[
form
]
=
Form
.
useForm
();
const
onChangeCheck
=
(
checkedValues
:
CheckboxValueType
[])
=>
{
console
.
log
(
'checked = '
,
checkedValues
);
};
return
(
<
Layout
>
<
Box
>
...
...
@@ -272,7 +290,7 @@ export default function FlyingHandService() {
getContainer=
{
false
}
footer=
{
[
<
Button
style=
{
{
width
:
"100%"
}
}
style=
{
{
width
:
"100%"
,
background
:
"linear-gradient(135deg, #278EFF 0%, #0052DA 100%)"
,
height
:
40
}
}
key=
"submit"
type=
"primary"
loading=
{
loading
}
...
...
@@ -282,9 +300,79 @@ export default function FlyingHandService() {
</
Button
>,
]
}
>
<
p
>
Some contents...
</
p
>
<
p
>
Some contents...
</
p
>
<
p
>
Some contents...
</
p
>
<
Form
form=
{
form
}
layout=
"vertical"
name=
"application"
initialValues=
{
{
modifier
:
'public'
}
}
>
<
div
style=
{
{
display
:
"flex"
,
justifyContent
:
"space-between"
}
}
>
<
Form
.
Item
style=
{
{
flex
:
1
,
marginRight
:
16
}
}
name=
"name"
rules=
{
[{
required
:
true
,
message
:
'Please input the title of collection!'
}]
}
>
<
Input
placeholder=
"姓名"
/>
</
Form
.
Item
>
<
Form
.
Item
style=
{
{
flex
:
1
}
}
name=
"telephone"
>
<
Input
placeholder=
"手机号"
/>
</
Form
.
Item
>
</
div
>
<
Form
.
Item
name=
"city"
rules=
{
[{
required
:
true
,
message
:
'Please select gender!'
}]
}
>
<
Cascader
allowClear
placeholder=
"地域"
className=
"selectItem"
size=
"large"
fieldNames=
{
{
label
:
"name"
,
value
:
"id"
,
children
:
"childInfo"
,
}
}
options=
{
secondDistrictInfo
}
changeOnSelect
/>
</
Form
.
Item
>
<
Form
.
Item
name=
"drivingLicense"
rules=
{
[{
required
:
true
,
message
:
'Please select gender!'
}]
}
>
<
Select
placeholder=
"是否有驾照"
>
<
Option
value=
"0"
>
是
</
Option
>
<
Option
value=
"1"
>
否
</
Option
>
</
Select
>
</
Form
.
Item
>
<
Form
.
Item
name=
"uavLicenseLevelOne"
rules=
{
[{
required
:
true
,
message
:
'Please select gender!'
}]
}
>
<
Cascader
allowClear
placeholder=
"是否有无人机执照"
className=
"selectItem"
size=
"large"
fieldNames=
{
{
label
:
"licenseType"
,
value
:
"id"
,
children
:
"childLicenses"
,
}
}
options=
{
skills
}
changeOnSelect
/>
</
Form
.
Item
>
<
Form
.
Item
name=
"industryAppAuth"
label=
"行业应用认证(多选)"
className=
"collection-create-form_last-form-item"
>
<
Checkbox
.
Group
options=
{
flightSkillsList
}
onChange=
{
onChangeCheck
}
/>
</
Form
.
Item
>
<
Form
.
Item
name=
"remark"
>
<
Input
placeholder=
"备注"
/>
</
Form
.
Item
>
</
Form
>
</
Modal
>
<
ContentBox
...
...
pages/home/waterfallFlowBody/components/map/api/index.tsx
浏览文件 @
045dbce7
import
request
,
{
Response
}
from
"~/api/request"
;
export
interface
PositioningInfoParams
{
lat
:
number
;
lon
:
number
;
lat
?:
number
;
lon
?:
number
;
pageNo
?:
number
,
pageSize
?:
number
}
export
interface
Entiy
{
...
...
@@ -19,11 +21,46 @@ export interface ListPageJobInfoResp {
locationList
:
Array
<
Entiy
>
;
}
export
interface
FlyerBitmapEntiy
{
flyerName
:
string
,
phoneNum
:
string
,
lon
:
number
,
lat
:
number
,
distance
:
number
}
export
interface
UavBitmapEntiy
{
uavName
:
string
,
online
:
number
,
lon
:
number
,
lat
:
number
,
distance
:
number
,
id
:
string
}
export
interface
BitmapInfo
<
T
>
{
pageNo
:
number
,
pageSize
:
number
,
list
:
T
[],
totalCount
:
number
,
totalPage
:
number
}
export
default
{
//web-
作业服务-分页
//web-
首页-地图-全国点位
listPositioningInfo
:
(
params
:
PositioningInfoParams
):
Promise
<
Response
<
ListPageJobInfoResp
[]
>>
=>
{
return
request
(
"/release/website/getWebsiteList"
,
"get"
,
params
);
},
//web-首页-地图-全国飞手
listFlyerBitmap
:
(
params
:
PositioningInfoParams
):
Promise
<
Response
<
BitmapInfo
<
FlyerBitmapEntiy
>>>
=>
{
return
request
(
"/release/website/flyer/bitmap"
,
"get"
,
params
);
},
//web-首页-地图-全国无人机
listUavBitmap
:
(
params
:
PositioningInfoParams
):
Promise
<
Response
<
BitmapInfo
<
UavBitmapEntiy
>>>
=>
{
return
request
(
"/release/website/uav/bitmap"
,
"get"
,
params
);
},
};
pages/home/waterfallFlowBody/components/map/assets/img.png
0 → 100644
浏览文件 @
045dbce7
10.1 KB
pages/home/waterfallFlowBody/components/map/index.tsx
浏览文件 @
045dbce7
差异被折叠。
点击展开。
pages/home/waterfallFlowBody/index.tsx
浏览文件 @
045dbce7
...
...
@@ -129,8 +129,6 @@ export default function WaterfallFlowBody() {
index
:
number
,
option
:
[]
)
=>
{
console
.
log
(
"跳转"
,
value
,
index
,
option
);
const
[
item
]
=
option
.
filter
((
item
:
any
)
=>
item
.
name
===
value
.
value
);
routerPath
(
index
,
item
);
};
...
...
@@ -153,40 +151,52 @@ export default function WaterfallFlowBody() {
let
res4
=
await
Promise
.
all
([
listAllIndustry
(),
listAllAppType
()]);
// let res4 = await Promise.all([deviceCategory(),deviceBrand(),deviceModel()])
// let res6 = await Promise.all([deviceCategory(),deviceBrand(),deviceModel()])
const
resValuelist1
=
res1
.
map
((
item
,
index
)
=>
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
eqApiTypeList
[
index
];
return
it
;
});
if
(
item
.
code
===
"200"
)
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
eqApiTypeList
[
index
];
return
it
;
});
}
return
{}
})
.
flat
();
const
resValuelist2
=
res2
.
map
((
item
,
index
)
=>
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
mallApiTypeList
[
index
];
return
it
;
});
if
(
item
.
code
===
"200"
)
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
mallApiTypeList
[
index
];
return
it
;
});
}
return
{}
})
.
flat
();
const
resValuelist3
=
res3
.
map
((
item
,
index
)
=>
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
flightApiTypeList
[
index
];
it
.
name
=
it
.
name
||
it
.
skillsName
||
it
.
licenseType
;
return
it
;
});
if
(
item
.
code
===
"200"
)
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
flightApiTypeList
[
index
];
it
.
name
=
it
.
name
||
it
.
skillsName
||
it
.
licenseType
;
return
it
;
});
}
return
{}
})
.
flat
();
const
resValuelist4
=
res4
.
map
((
item
,
index
)
=>
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
jobApiTypeList
[
index
];
console
.
log
(
it
);
it
.
name
=
it
.
name
||
it
.
appName
;
return
it
;
});
if
(
item
.
code
===
"200"
)
{
return
item
.
result
?.
map
((
it
)
=>
{
it
.
type
=
jobApiTypeList
[
index
];
it
.
name
=
it
.
name
||
it
.
appName
;
return
it
;
});
}
return
{}
})
.
flat
();
...
...
@@ -222,7 +232,6 @@ export default function WaterfallFlowBody() {
resValuelist4
,
list2Option
,
];
console
.
log
(
optionList
);
setLeftDomList
(
columns
.
map
((
item
,
index
)
=>
{
...
...
@@ -333,6 +342,7 @@ export default function WaterfallFlowBody() {
};
const
rightDom
=
(
list
:
Array
<
NewsPageType
>
)
=>
{
if
(
!
list
?.
length
)
return
;
return
(
<
div
key=
{
1009
}
className=
"right-box-item right-item"
>
<
div
className=
"title"
>
...
...
@@ -364,6 +374,7 @@ export default function WaterfallFlowBody() {
};
const
rightDom2
=
(
list
:
Array
<
NewsTenderType
>
)
=>
{
if
(
!
list
.
length
)
return
;
return
(
<
div
key=
{
1008
}
className=
"right-box-item right-item-second"
>
<
div
className=
"item-box"
>
...
...
pages/home/waterfallFlowBody/styled.tsx
浏览文件 @
045dbce7
...
...
@@ -102,6 +102,7 @@ export const Box = styled.div`
}
}
.right-item {
background-color: #fff;
border-radius: 6px;
.title {
display: flex;
...
...
pages/mall/index.module.scss
浏览文件 @
045dbce7
...
...
@@ -33,6 +33,7 @@
flex-wrap
:
wrap
;
gap
:
12px
;
height
:
565px
;
align-content
:
start
;
.item
{
cursor
:
pointer
;
...
...
pages/mall/index.page.tsx
浏览文件 @
045dbce7
...
...
@@ -133,6 +133,7 @@ export default function Mall(props: Props) {
showSizeChanger=
{
false
}
showQuickJumper
total=
{
count
}
pageSize=
{
pageParams
.
pageSize
}
onChange=
{
onPageChange
}
hideOnSinglePage=
{
true
}
style=
{
{
marginTop
:
20
}
}
...
...
typings/type.d.ts
浏览文件 @
045dbce7
...
...
@@ -3,5 +3,6 @@ import { MessageInstance } from 'antd/es/message/interface';
declare
global
{
interface
Window
{
messageApi
:
MessageInstance
;
WxLogin
:
any
;
}
}
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论