Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
project-online
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
project-online
Commits
b3300459
提交
b3300459
authored
5月 11, 2022
作者:
matian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
bug fixes
上级
9abe451f
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
48 行增加
和
137 行删除
+48
-137
Header.vue
src/components/layout/Header.vue
+7
-114
Index.vue
src/components/layout/Index.vue
+2
-5
Main.vue
src/components/layout/Main.vue
+1
-1
main.ts
src/main.ts
+3
-3
CardQuery.vue
src/modules/internet/components/CardQuery.vue
+3
-4
ManagerLogin.vue
src/modules/internet/components/ManagerLogin.vue
+2
-4
Index.vue
src/modules/internet/views/Index.vue
+3
-3
QueryDetail.vue
src/modules/internet/views/QueryDetail.vue
+27
-3
没有找到文件。
src/components/layout/Header.vue
浏览文件 @
b3300459
...
...
@@ -2,140 +2,33 @@
export
default
{
name
:
'AppHeader'
}
</
script
>
<
script
setup
lang=
"ts"
>
import
{
useUserStore
}
from
'@/stores/user'
withDefaults
(
defineProps
<
{
hasTitle
?:
boolean
}
>
(),
{
hasTitle
:
true
})
const
userStore
=
useUserStore
()
const
userInfo
=
userStore
.
user
const
logout
=
()
=>
{
userStore
.
logout
()
}
</
script
>
<
script
setup
lang=
"ts"
></
script
>
<
template
>
<header
class=
"app-header"
>
<div
class=
"app-header-left"
>
<div
class=
"logo"
>
<router-link
to=
"/"
><img
src=
"https://webapp-pub.ezijing.com/project_online/fdc/fdc_header_logo.png"
/></router-link>
</div>
</div>
<div
class=
"app-header-right"
>
<el-dropdown
v-if=
"userInfo"
>
<div
class=
"avatar"
>
<img
:src=
"userInfo.avatar || 'https://webapp-pub.ezijing.com/website/base/images/avatar.svg'"
/>
</div>
<template
#
dropdown
>
<el-dropdown-menu>
<div
class=
"app-header-user"
>
<div
class=
"app-header-user-avatar"
>
<img
:src=
"userInfo.avatar || 'https://webapp-pub.ezijing.com/website/base/images/avatar.svg'"
/>
</div>
<div
class=
"app-header-user-main"
>
<h3>
{{
userStore
.
userName
}}
</h3>
<p>
{{
userInfo
.
email
||
userInfo
.
mobile
}}
</p>
</div>
<div
class=
"app-header-user-buttons"
>
<el-button
round
@
click=
"logout"
>
退出登录
</el-button>
</div>
</div>
</el-dropdown-menu>
</
template
>
</el-dropdown>
<div
class=
"logo"
>
<router-link
to=
"/"
><img
src=
"https://webapp-pub.ezijing.com/project_online/fdc/fdc_header_logo.png"
/></router-link>
</div>
</header>
</
template
>
<
style
lang=
"scss"
>
.app-header
{
height
:
64px
;
position
:
absolute
;
top
:
44
px
;
top
:
23
px
;
left
:
72px
;
z-index
:
1000
;
padding
:
0
20px
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
height
:
64px
;
background-color
:
#fff
;
color
:
#fff
;
.logo
{
width
:
120px
;
}
}
.app-header-left
{
display
:
flex
;
align-items
:
center
;
.app-name
{
margin-left
:
20px
;
padding
:
0
15px
;
line-height
:
1
;
border-left
:
2px
solid
#fff
;
}
}
.app-header-right
{
display
:
flex
;
.avatar
{
width
:
40px
;
height
:
40px
;
border-radius
:
50%
;
overflow
:
hidden
;
img
{
width
:
100%
;
height
:
100%
;
object-fit
:
cover
;
border-radius
:
50%
;
overflow
:
hidden
;
}
&
:hover
{
background-color
:
rgba
(
60
,
64
,
67
,
0
.08
);
}
}
}
.app-header-user
{
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
text-align
:
center
;
padding
:
16px
;
}
.app-header-user-avatar
{
margin-bottom
:
6px
;
width
:
80px
;
height
:
80px
;
border-radius
:
50%
;
overflow
:
hidden
;
img
{
width
:
100%
;
height
:
100%
;
object-fit
:
cover
;
}
}
.app-header-user-main
{
h3
{
color
:
#202124
;
font
:
500
16px
/
22px
Helvetica
,
Arial
,
sans-serif
;
letter-spacing
:
0
.29px
;
margin
:
0
;
text-align
:
center
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
}
p
{
color
:
#5f6368
;
font
:
400
14px
/
19px
Helvetica
,
Arial
,
sans-serif
;
letter-spacing
:
normal
;
text-align
:
center
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
}
}
.app-header-user-buttons
{
padding-top
:
16px
;
}
</
style
>
src/components/layout/Index.vue
浏览文件 @
b3300459
...
...
@@ -15,10 +15,7 @@ withDefaults(defineProps<{ sidebar?: boolean; hasTitle?: boolean }>(), {
<
template
>
<div
class=
"app-layout"
>
<app-header
:hasTitle=
"hasTitle"
></app-header>
<div
class=
"app-layout-container"
>
<!--
<app-aside
v-if=
"sidebar"
></app-aside>
-->
<app-main></app-main>
</div>
<app-main></app-main>
</div>
</
template
>
...
...
@@ -27,11 +24,11 @@ withDefaults(defineProps<{ sidebar?: boolean; hasTitle?: boolean }>(), {
width
:
100%
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
space-between
;
background
:
#fff
;
}
.app-layout-container
{
flex
:
1
;
display
:
flex
;
height
:
calc
(
100vh
-
166px
);
}
</
style
>
src/components/layout/Main.vue
浏览文件 @
b3300459
...
...
@@ -12,7 +12,7 @@
.app-main
{
position
:
relative
;
flex
:
1
;
top
:
1
66
px
;
top
:
1
10
px
;
}
.app-main-inner
{
margin
:
0
auto
;
...
...
src/main.ts
浏览文件 @
b3300459
...
...
@@ -11,14 +11,14 @@ import zhCn from 'element-plus/es/locale/lang/zh-cn'
// 公共css
import
'./assets/css/base.css'
// 公共组件
import
AppCard
from
'@/components/base/AppCard.vue'
import
AppContainer
from
'@/components/base/AppContainer.vue'
//
import AppCard from '@/components/base/AppCard.vue'
//
import AppContainer from '@/components/base/AppContainer.vue'
import
modules
from
'./modules'
const
app
=
createApp
(
App
)
// 注册公共组件
app
.
component
(
'AppCard'
,
AppCard
).
component
(
'AppContainer'
,
AppContainer
)
//
app.component('AppCard', AppCard).component('AppContainer', AppContainer)
// 注册模块
modules
({
router
})
...
...
src/modules/internet/components/CardQuery.vue
浏览文件 @
b3300459
...
...
@@ -10,7 +10,6 @@ const form = reactive({
idNumber
:
''
,
// 身份证号
cardNumber
:
''
// 证书编号
})
const
queryResultList
=
reactive
({
list
:
[]
as
any
[]
})
const
handleSubmit
=
()
=>
{
...
...
@@ -23,7 +22,8 @@ const handleSubmit = () => {
if
(
res
.
code
===
0
)
{
queryResultList
.
list
=
res
.
data
window
.
localStorage
.
setItem
(
'list'
,
JSON
.
stringify
(
queryResultList
.
list
))
console
.
log
(
res
,
'pppp'
)
// const localTime = new Date().getTime()
// window.localStorage.setItem('localTime', JSON.stringify(localTime))
$router
.
push
({
path
:
'detail'
,
query
:
{
...
...
@@ -35,8 +35,7 @@ const handleSubmit = () => {
$router
.
push
({
path
:
'detail'
,
query
:
{
code
:
res
.
code
,
code
:
res
.
code
}
})
}
...
...
src/modules/internet/components/ManagerLogin.vue
浏览文件 @
b3300459
...
...
@@ -10,11 +10,10 @@ const isShowGetCode = ref(false)
const
isDisposed
=
ref
(
false
)
const
time
=
ref
(
60
)
const
loginType
=
ref
(
''
)
const
isCode
=
ref
(
false
)
// 登录
const
handleLogin
=
()
=>
{
if
(
isCode
.
value
===
true
)
{
if
(
is
ShowGet
Code
.
value
===
true
)
{
loginType
.
value
=
'2'
}
else
{
loginType
.
value
=
'1'
...
...
@@ -29,7 +28,7 @@ const handleLogin = () => {
api
.
login
(
params
).
then
((
res
:
any
)
=>
{
console
.
log
(
res
,
'0000'
)
if
(
res
.
code
===
0
)
{
window
.
location
.
href
=
'https://fdc-admin.ezijing.com
/bfi/cert
'
window
.
location
.
href
=
'https://fdc-admin.ezijing.com'
}
else
{
ElMessage
.
warning
(
res
.
msg
)
}
...
...
@@ -52,7 +51,6 @@ function getCode() {
api
.
sendCode
(
params
).
then
(
res
=>
{
console
.
log
(
'获取验证码结果'
,
res
)
isDisposed
.
value
=
true
isCode
.
value
=
true
handleTimeChange
()
})
}
...
...
src/modules/internet/views/Index.vue
浏览文件 @
b3300459
...
...
@@ -9,7 +9,7 @@ const tabList: Array<{ tabName: string }> = [
tabName
:
'证书查询'
},
{
tabName
:
'学
习
登录'
tabName
:
'学
员
登录'
},
{
tabName
:
'管理员登录'
...
...
@@ -44,7 +44,7 @@ function handleTabChange(index: number) {
<
style
lang=
"scss"
>
.home
{
height
:
calc
(
100vh
-
1
66
px
);
height
:
calc
(
100vh
-
1
10
px
);
width
:
100%
;
background
:
url(https://webapp-pub.oss-cn-beijing.aliyuncs.com/project_online/fdc/%20fdc_bg.png)
no-repeat
;
background-size
:
100%
100%
;
...
...
@@ -58,7 +58,7 @@ function handleTabChange(index: number) {
align-items
:
center
;
flex-direction
:
column
;
width
:
472px
;
// min-
height: 496px;
height
:
496px
;
background
:
#ffffff
;
opacity
:
1
;
border-radius
:
20px
;
...
...
src/modules/internet/views/QueryDetail.vue
浏览文件 @
b3300459
/* eslint-disable no-constant-condition */
<
script
setup
lang=
"ts"
>
import
{
reactive
,
onMounted
}
from
'vue'
import
{
useRoute
}
from
'vue-router'
import
{
reactive
,
ref
,
onMounted
}
from
'vue'
import
{
useRoute
,
useRouter
}
from
'vue-router'
const
queryResultList
=
reactive
({
list
:
[]
as
any
[]
})
const
route
=
useRoute
()
const
$router
=
useRouter
()
const
time
=
ref
(
1800
)
let
timer
:
any
=
null
const
getTime
=
()
=>
{
// 避免重复执行 setTimeout
timer
&&
clearTimeout
(
timer
)
timer
=
setTimeout
(()
=>
{
if
(
time
.
value
>
0
)
{
time
.
value
--
getTime
()
// 递归调用
}
else
{
$router
.
push
(
'/home/index'
)
}
},
1000
)
}
onMounted
(()
=>
{
// const new_date = new Date().getTime() //新建一个日期对象,默认现在的时间
// const old_date = window.localStorage.getItem('localTime') //设置过去的一个时间点,"yyyy-MM-dd HH:mm:ss"格式化日期
// console.log((Number(new_date) - Number(old_date)) / 86400 / 3600 / 60, '000000000')
// if ((Number(new_date) - Number(old_date)) / 86400 / 3600 / 60 >= 30) {
// $router.push('/home/index')
// }
console
.
log
(
time
.
value
)
if
(
route
.
query
.
code
===
'1'
)
{
queryResultList
.
list
=
[]
getTime
()
}
else
{
queryResultList
.
list
=
JSON
.
parse
(
window
.
localStorage
.
getItem
(
'list'
)
||
'0'
)
getTime
()
}
})
</
script
>
<
template
>
<div
class=
"main_content"
>
{{
time
}}
<div
class=
"home-box"
v-if=
"queryResultList.list.length > 0"
>
<div
v-for=
"(item, index) in queryResultList.list"
:key=
"index"
class=
"home-box-content"
>
<div
class=
"home-box-content-btn"
>
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论