Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
web
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
iuav
web
Commits
b7a8bf02
提交
b7a8bf02
authored
5月 30, 2023
作者:
翁进城
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
加盟福利改为接口获取
上级
ea6070d9
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
35 行增加
和
26 行删除
+35
-26
index.ts
pages/JoinPolicy/api/index.ts
+16
-3
index.page.tsx
pages/JoinPolicy/index.page.tsx
+19
-23
没有找到文件。
pages/JoinPolicy/api/index.ts
浏览文件 @
b7a8bf02
...
@@ -6,11 +6,23 @@ export interface CooperationApplyParams {
...
@@ -6,11 +6,23 @@ export interface CooperationApplyParams {
remark
?:
string
,
remark
?:
string
,
userAccountId
:
number
,
userAccountId
:
number
,
cooperationTagId
:
number
cooperationTagId
:
number
}
}
export
interface
GetTagIdResp
{
id
:
number
,
tagName
:
string
,
tagImg
:
string
,
tagDescription
:
string
,
createTime
:
string
}
export
default
{
export
default
{
//请加盟
//
申
请加盟
cooperationApply
(
params
:
CooperationApplyParams
):
Promise
<
Response
<
string
>>
{
cooperationApply
(
params
:
CooperationApplyParams
):
Promise
<
Response
<
string
>>
{
return
request
(
'/userapp/cooperation/apply'
,
'post'
,
params
)
return
request
(
'/userapp/cooperation/apply'
,
'post'
,
params
)
},
//加盟标签相关内容
getTagById
(
params
:
{
id
:
number
}):
Promise
<
Response
<
GetTagIdResp
>>
{
return
request
(
'/userapp/cooperation/getTagById'
,
'get'
,
params
)
}
}
}
}
\ No newline at end of file
pages/JoinPolicy/index.page.tsx
浏览文件 @
b7a8bf02
import
{
Button
,
Col
,
Divider
,
Form
,
Input
,
Row
}
from
"antd"
;
import
{
Button
,
Col
,
Divider
,
Form
,
Input
,
Row
}
from
"antd"
;
import
{
useRouter
}
from
"next/router"
;
import
{
useRouter
}
from
"next/router"
;
import
{
useEffect
,
useState
}
from
"react"
;
import
LayoutView
from
"~/components/layout"
;
import
LayoutView
from
"~/components/layout"
;
import
api
from
"./api"
;
import
api
from
"./api"
;
import
styles
from
"./index.module.scss"
;
import
styles
from
"./index.module.scss"
;
export
default
function
JoinPolicy
()
{
export
default
function
JoinPolicy
()
{
const
router
=
useRouter
();
const
router
=
useRouter
();
const
[
content
,
setContent
]
=
useState
(
""
);
//福利内容
const
tagId
=
Number
(
router
.
query
.
tagId
);
useEffect
(()
=>
{
if
(
tagId
)
{
api
.
getTagById
({
id
:
tagId
,
})
.
then
((
res
)
=>
{
setContent
(
res
.
result
?.
tagDescription
.
replace
(
"
\
n"
,
"<br/>"
)
||
""
);
});
}
},
[]);
//提交
//提交
const
onFinish
=
(
values
:
any
)
=>
{
const
onFinish
=
(
values
:
any
)
=>
{
console
.
log
(
values
);
console
.
log
(
values
);
api
api
.
cooperationApply
({
.
cooperationApply
({
...
values
,
...
values
,
userAccountId
:
1
,
cooperationTagId
:
tagId
,
cooperationTagId
:
router
.
query
.
tagId
,
})
})
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
console
.
log
(
"提交结果"
,
res
);
console
.
log
(
"提交结果"
,
res
);
if
(
res
.
result
===
"已通过
"
)
{
if
(
res
.
code
===
"200
"
)
{
window
.
messageApi
.
success
(
res
.
result
);
window
.
messageApi
.
success
(
res
.
result
);
setTimeout
(()
=>
{
setTimeout
(()
=>
{
router
.
push
(
"/"
);
router
.
push
(
"/"
);
},
1500
);
},
1500
);
}
else
{
window
.
messageApi
.
error
(
res
.
message
);
}
}
});
});
};
};
...
@@ -50,24 +62,8 @@ export default function JoinPolicy() {
...
@@ -50,24 +62,8 @@ export default function JoinPolicy() {
<
div
<
div
className=
{
styles
.
font2
}
className=
{
styles
.
font2
}
style=
{
{
paddingLeft
:
50
,
paddingRight
:
50
}
}
style=
{
{
paddingLeft
:
50
,
paddingRight
:
50
}
}
>
dangerouslySetInnerHTML=
{
{
__html
:
content
}
}
1.每月自动获取一张高额度优惠券
></
div
>
<
br
/>
2.流量扶持和店铺曝光度
<
br
/>
3成为科比特指定官方生态合作伙伴
<
br
/>
4.享受不低于1亿制造采购补贴
<
br
/>
5.无人机产业链资源共享
<
br
/>
6.享受价值5亿产业链订单
<
br
/>
7.享受一对一代运营服务
<
br
/>
8.享受无人机生态圈资源
<
br
/>
9.成为科比特指定官方生态
<
br
/>
10.享受无人机生态圈资源合作伙伴
<
br
/>
11.受价值5亿产业链订单
<
br
/>
12.成为科比特指定官方生态合作伙伴
</
div
>
<
Divider
/>
<
Divider
/>
<
div
<
div
className=
{
styles
.
font1
}
className=
{
styles
.
font1
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论