Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
A
admin-ci-test
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
test-ci
admin-ci-test
Commits
166357db
提交
166357db
authored
7月 28, 2022
作者:
ZhangLingKun
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
测试
上级
97225fb3
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
25 行增加
和
34 行删除
+25
-34
.gitignore
.gitignore
+2
-0
workspace.xml
.idea/workspace.xml
+8
-16
api.ts
src/api/modules/common/api.ts
+1
-1
index.tsx
src/pages/testPage/index.tsx
+9
-12
index.ts
src/router/index.ts
+5
-5
没有找到文件。
.gitignore
浏览文件 @
166357db
...
...
@@ -4,6 +4,7 @@
/node_modules
/.pnp
.pnp.js
/.idea
# testing
/coverage
...
...
@@ -18,6 +19,7 @@
.env.test.local
.env.production.local
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.idea/workspace.xml
浏览文件 @
166357db
...
...
@@ -2,21 +2,11 @@
<project
version=
"4"
>
<component
name=
"ChangeListManager"
>
<list
default=
"true"
id=
"449bb119-753b-455c-bc48-817b4f4462f0"
name=
"默认变更列表"
comment=
""
>
<change
afterPath=
"$PROJECT_DIR$/.eslintrc"
afterDir=
"false"
/>
<change
afterPath=
"$PROJECT_DIR$/src/api/index.ts"
afterDir=
"false"
/>
<change
afterPath=
"$PROJECT_DIR$/src/api/modules/common/api.ts"
afterDir=
"false"
/>
<change
afterPath=
"$PROJECT_DIR$/src/api/modules/common/interface.ts"
afterDir=
"false"
/>
<change
afterPath=
"$PROJECT_DIR$/src/api/request.ts"
afterDir=
"false"
/>
<change
afterPath=
"$PROJECT_DIR$/src/pages/testPage/index.tsx"
afterDir=
"false"
/>
<change
afterPath=
"$PROJECT_DIR$/src/router/index.ts"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/package-lock.json"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/package-lock.json"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/package.json"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/package.json"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/App.css"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/assets/css/App.css"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/App.test.tsx"
beforeDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/App.tsx"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/App.tsx"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/index.css"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/assets/css/index.css"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/index.tsx"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/index.tsx"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/logo.svg"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/assets/image/logo.svg"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/.gitignore"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/.gitignore"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/.idea/workspace.xml"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/.idea/workspace.xml"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/api/modules/common/api.ts"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/api/modules/common/api.ts"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/pages/testPage/index.tsx"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/pages/testPage/index.tsx"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/router/index.ts"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/router/index.ts"
afterDir=
"false"
/>
</list>
<option
name=
"SHOW_DIALOG"
value=
"false"
/>
<option
name=
"HIGHLIGHT_CONFLICTS"
value=
"true"
/>
...
...
@@ -36,7 +26,7 @@
<property
name=
"RunOnceActivity.OpenProjectViewOnStart"
value=
"true"
/>
<property
name=
"RunOnceActivity.ShowReadmeOnStart"
value=
"true"
/>
<property
name=
"WebServerToolWindowFactoryState"
value=
"false"
/>
<property
name=
"last_opened_file_path"
value=
"$PROJECT_DIR$/
src/router
"
/>
<property
name=
"last_opened_file_path"
value=
"$PROJECT_DIR$/
../../rn/react-native-ts
"
/>
<property
name=
"node.js.detected.package.eslint"
value=
"true"
/>
<property
name=
"node.js.detected.package.standard"
value=
"true"
/>
<property
name=
"node.js.detected.package.tslint"
value=
"true"
/>
...
...
@@ -102,6 +92,8 @@
<workItem
from=
"1658916775971"
duration=
"1437000"
/>
<workItem
from=
"1658918510762"
duration=
"708000"
/>
<workItem
from=
"1658993729518"
duration=
"3844000"
/>
<workItem
from=
"1658997888565"
duration=
"35000"
/>
<workItem
from=
"1658997931871"
duration=
"3323000"
/>
</task>
<servers
/>
</component>
...
...
src/api/modules/common/api.ts
浏览文件 @
166357db
...
...
@@ -4,6 +4,6 @@ import {PlatformLogin} from './interface';
export
class
commonAPI
{
//登录接口
static
platformLogin
(
data
:
PlatformLogin
)
{
return
Axios
.
post
(
'/userservlet/auth/platformLogin
1
'
,
data
);
return
Axios
.
post
(
'/userservlet/auth/platformLogin'
,
data
);
}
}
src/pages/testPage/index.tsx
浏览文件 @
166357db
import
React
from
"react"
;
import
{
commonAPI
}
from
'../../api'
const
Home
=
()
=>
{
export
const
Home
=
()
=>
{
const
[
token
,
setToken
]
=
React
.
useState
(
''
);
const
GetLogin
=
async
()
=>
{
const
res
:
any
=
await
commonAPI
.
platformLogin
({
...
...
@@ -15,21 +15,18 @@ const Home = () => {
React
.
useEffect
(()
=>
{
console
.
log
(
'首页 !!!'
);
GetLogin
();
})
}
,[]
)
//
const list = [1,2,3,4,5]
const
list
=
[
1
,
2
,
3
,
4
,
5
]
return
(
<
div
>
<
div
style=
{
{
padding
:
"1rem 0"
}
}
>
<
div
>
home !
</
div
>
<
div
>
{
token
}
</
div
>
{
list
.
map
((
i
,
j
)
=>
{
return
(
<
h2
key=
{
j
}
>
{
j
}
Home
{
i
}
</
h2
>
)
})
}
</
div
>
// <div style={{ padding: "1rem 0" }}>
// {list.map((i,j)=>{
// return(
// <h2 key={j}>{j} Home {i}</h2>
// )
// })}
// </div>
);
}
export
default
Home
src/router/index.ts
浏览文件 @
166357db
import
Home
from
"../pages/testPage"
;
import
{
Home
}
from
"../pages/testPage"
;
// import About from "../pages/test/About";
...
...
@@ -7,8 +7,8 @@ export const router = [
path
:
'home'
,
element
:
Home
,
},
{
path
:
'about'
,
element
:
Home
,
}
//
{
//
path: 'about',
//
element: Home,
//
}
];
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论