Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
safe-campus-bbs
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
万成波
safe-campus-bbs
Commits
2a38011e
Commit
2a38011e
authored
Sep 29, 2025
by
yuwenwen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改BUG,修改打包配置
parent
f153f60a
Changes
22
Show whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
127 additions
and
159 deletions
+127
-159
safe-campus-bbs-ui/.env.production
safe-campus-bbs-ui/.env.production
+1
-1
safe-campus-bbs-ui/src/assets/images/index-img.png
safe-campus-bbs-ui/src/assets/images/index-img.png
+0
-0
safe-campus-bbs-ui/src/router/index.js
safe-campus-bbs-ui/src/router/index.js
+1
-0
safe-campus-bbs-ui/src/views/index.vue
safe-campus-bbs-ui/src/views/index.vue
+13
-58
safe-campus-bbs-ui/src/views/login.vue
safe-campus-bbs-ui/src/views/login.vue
+3
-3
safe-campus-bbs-ui/src/views/moments/index.vue
safe-campus-bbs-ui/src/views/moments/index.vue
+3
-0
safe-campus-bbs-ui/src/views/pointsManage/index.vue
safe-campus-bbs-ui/src/views/pointsManage/index.vue
+1
-1
safe-campus-bbs-ui/src/views/register.vue
safe-campus-bbs-ui/src/views/register.vue
+1
-1
safe-campus-bbs-ui/src/views/sensitives/index.vue
safe-campus-bbs-ui/src/views/sensitives/index.vue
+3
-6
safe-campus-bbs-ui/src/views/userLevel/FormDialog.vue
safe-campus-bbs-ui/src/views/userLevel/FormDialog.vue
+1
-1
safe-campus-bbs-ui/vue.config.js
safe-campus-bbs-ui/vue.config.js
+1
-1
safe-campus-bbs-uniapp/components/ImageUpload.vue
safe-campus-bbs-uniapp/components/ImageUpload.vue
+1
-0
safe-campus-bbs-uniapp/config/index.config.js
safe-campus-bbs-uniapp/config/index.config.js
+1
-1
safe-campus-bbs-uniapp/manifest.json
safe-campus-bbs-uniapp/manifest.json
+1
-1
safe-campus-bbs-uniapp/pages.json
safe-campus-bbs-uniapp/pages.json
+4
-2
safe-campus-bbs-uniapp/pages/index/index.vue
safe-campus-bbs-uniapp/pages/index/index.vue
+4
-7
safe-campus-bbs-uniapp/pages/login/login.vue
safe-campus-bbs-uniapp/pages/login/login.vue
+47
-55
safe-campus-bbs-uniapp/pages/publish/publish.vue
safe-campus-bbs-uniapp/pages/publish/publish.vue
+3
-3
safe-campus-bbs-uniapp/pages/topic-detail/topic-detail.vue
safe-campus-bbs-uniapp/pages/topic-detail/topic-detail.vue
+23
-5
safe-campus-bbs-uniapp/pages/topics/topics.vue
safe-campus-bbs-uniapp/pages/topics/topics.vue
+11
-0
safe-campus-bbs-uniapp/static/styles/index.scss
safe-campus-bbs-uniapp/static/styles/index.scss
+1
-1
safe-campus-bbs-uniapp/utils/request.js
safe-campus-bbs-uniapp/utils/request.js
+3
-12
No files found.
safe-campus-bbs-ui/.env.production
View file @
2a38011e
...
@@ -5,4 +5,4 @@ VUE_APP_TITLE = 一站式高校轻享平台
...
@@ -5,4 +5,4 @@ VUE_APP_TITLE = 一站式高校轻享平台
ENV = 'production'
ENV = 'production'
# 若依管理系统/生产环境
# 若依管理系统/生产环境
VUE_APP_BASE_API = '/prod-api'
VUE_APP_BASE_API = '/
bbs/
prod-api'
safe-campus-bbs-ui/src/assets/images/index-img.png
0 → 100644
View file @
2a38011e
4.71 KB
safe-campus-bbs-ui/src/router/index.js
View file @
2a38011e
...
@@ -177,6 +177,7 @@ Router.prototype.replace = function push(location) {
...
@@ -177,6 +177,7 @@ Router.prototype.replace = function push(location) {
}
}
export
default
new
Router
({
export
default
new
Router
({
base
:
'
/bbs/pc
'
,
mode
:
'
history
'
,
// 去掉url中的#
mode
:
'
history
'
,
// 去掉url中的#
scrollBehavior
:
()
=>
({
y
:
0
}),
scrollBehavior
:
()
=>
({
y
:
0
}),
routes
:
constantRoutes
routes
:
constantRoutes
...
...
safe-campus-bbs-ui/src/views/index.vue
View file @
2a38011e
<
template
>
<
template
>
<div
class=
"app-container home"
>
<div
class=
"app-container home"
>
<div
class=
"app-home"
>
<p>
欢迎使用一站式高校轻享平台
</p>
<img
src=
"@/assets/images/index-img.png"
/>
</div>
</div>
</div>
</
template
>
</
template
>
...
@@ -23,64 +27,15 @@ export default {
...
@@ -23,64 +27,15 @@ export default {
<
style
scoped
lang=
"scss"
>
<
style
scoped
lang=
"scss"
>
.home
{
.home
{
blockquote
{
transform
:
translateY
(
25%
);
padding
:
10px
20px
;
}
margin
:
0
0
20px
;
.app-home
{
font-size
:
17
.5px
;
margin
:
auto
;
border-left
:
5px
solid
#eee
;
text-align
:
center
;
}
hr
{
margin-top
:
20px
;
margin-bottom
:
20px
;
border
:
0
;
border-top
:
1px
solid
#eee
;
}
.col-item
{
margin-bottom
:
20px
;
}
ul
{
padding
:
0
;
margin
:
0
;
}
font-family
:
"open sans"
,
"Helvetica Neue"
,
Helvetica
,
Arial
,
sans-serif
;
font-size
:
13px
;
color
:
#676a6c
;
overflow-x
:
hidden
;
ul
{
list-style-type
:
none
;
}
h4
{
margin-top
:
0px
;
}
h2
{
margin-top
:
10px
;
font-size
:
26px
;
font-weight
:
100
;
}
p
{
p
{
margin-top
:
10px
;
margin-bottom
:
0px
;
font-size
:
46px
;
b
{
color
:
#eeeeee
;
font-weight
:
700
;
}
}
.update-log
{
ol
{
display
:
block
;
list-style-type
:
decimal
;
margin-block-start
:
1em
;
margin-block-end
:
1em
;
margin-inline-start
:
0
;
margin-inline-end
:
0
;
padding-inline-start
:
40px
;
}
}
}
}
}
</
style
>
</
style
>
...
...
safe-campus-bbs-ui/src/views/login.vue
View file @
2a38011e
...
@@ -56,7 +56,7 @@
...
@@ -56,7 +56,7 @@
</el-form>
</el-form>
<!-- 底部 -->
<!-- 底部 -->
<div
class=
"el-login-footer"
>
<div
class=
"el-login-footer"
>
<span>
Copyright © 201
8-2023 ruoyi.vip
All Rights Reserved.
</span>
<span>
Copyright © 201
9-2025 江西唐果科技有限公司
All Rights Reserved.
</span>
</div>
</div>
</div>
</div>
</
template
>
</
template
>
...
@@ -72,8 +72,8 @@ export default {
...
@@ -72,8 +72,8 @@ export default {
return
{
return
{
codeUrl
:
""
,
codeUrl
:
""
,
loginForm
:
{
loginForm
:
{
username
:
"
admin
"
,
username
:
""
,
password
:
"
admin123
"
,
password
:
""
,
rememberMe
:
false
,
rememberMe
:
false
,
code
:
""
,
code
:
""
,
uuid
:
""
uuid
:
""
...
...
safe-campus-bbs-ui/src/views/moments/index.vue
View file @
2a38011e
...
@@ -24,6 +24,9 @@
...
@@ -24,6 +24,9 @@
<el-table-column
label=
"动态内容"
prop=
"content"
align=
"center"
>
<el-table-column
label=
"动态内容"
prop=
"content"
align=
"center"
>
<template
#default
="
{ row }">
<template
#default
="
{ row }">
<div
v-html=
"formatContent(row.content)"
class=
"content-container"
></div>
<div
v-html=
"formatContent(row.content)"
class=
"content-container"
></div>
<div
v-if=
"row.type == 'IMAGE' && row.attachments && row.attachments.length > 0"
>
<el-image
v-for=
"(img,idx) in row.attachments"
:key=
"idx"
:src=
"img.url"
></el-image>
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"话题"
align=
"center"
prop=
"topicNames"
width=
"240"
></el-table-column>
<el-table-column
label=
"话题"
align=
"center"
prop=
"topicNames"
width=
"240"
></el-table-column>
...
...
safe-campus-bbs-ui/src/views/pointsManage/index.vue
View file @
2a38011e
...
@@ -23,7 +23,7 @@
...
@@ -23,7 +23,7 @@
<el-table-column
label=
"会员等级"
prop=
"gradeName"
align=
"center"
></el-table-column>
<el-table-column
label=
"会员等级"
prop=
"gradeName"
align=
"center"
></el-table-column>
<el-table-column
label=
"累计积分"
prop=
"accumulatedPoints"
align=
"center"
></el-table-column>
<el-table-column
label=
"累计积分"
prop=
"accumulatedPoints"
align=
"center"
></el-table-column>
<el-table-column
label=
"可用积分"
prop=
"currentPoints"
align=
"center"
></el-table-column>
<el-table-column
label=
"可用积分"
prop=
"currentPoints"
align=
"center"
></el-table-column>
<el-table-column
label=
"操作"
align=
"center"
>
<el-table-column
label=
"操作"
align=
"center"
width=
"200"
>
<template
#default
="
{ row }">
<template
#default
="
{ row }">
<el-button
type=
"text"
@
click=
"handleAddPoints(row)"
>
增加
</el-button>
<el-button
type=
"text"
@
click=
"handleAddPoints(row)"
>
增加
</el-button>
<el-button
type=
"text"
@
click=
"handleDecreasePoints(row)"
>
扣减
</el-button>
<el-button
type=
"text"
@
click=
"handleDecreasePoints(row)"
>
扣减
</el-button>
...
...
safe-campus-bbs-ui/src/views/register.vue
View file @
2a38011e
...
@@ -61,7 +61,7 @@
...
@@ -61,7 +61,7 @@
</el-form>
</el-form>
<!-- 底部 -->
<!-- 底部 -->
<div
class=
"el-register-footer"
>
<div
class=
"el-register-footer"
>
<span>
Copyright © 201
8-2023 ruoyi.vip
All Rights Reserved.
</span>
<span>
Copyright © 201
9-2025 江西唐果科技有限公司
All Rights Reserved.
</span>
</div>
</div>
</div>
</div>
</
template
>
</
template
>
...
...
safe-campus-bbs-ui/src/views/sensitives/index.vue
View file @
2a38011e
...
@@ -11,12 +11,9 @@
...
@@ -11,12 +11,9 @@
</el-form-item>
</el-form-item>
</el-form>
</el-form>
<el-row
class=
"mb10"
>
<el-row
class=
"mb10"
>
<el-col
:span=
"2"
>
<el-button
type=
"primary"
@
click=
"handleAdd"
>
新增敏感词
</el-button>
<el-button
type=
"primary"
@
click=
"handleAdd"
>
新增敏感词
</el-button>
</el-col>
<el-col
:span=
"2"
>
<el-button
type=
"primary"
plain
@
click=
"handleImport"
>
批量导入敏感词
</el-button>
<el-button
type=
"primary"
plain
@
click=
"handleImport"
>
批量导入敏感词
</el-button>
</el-col>
</el-row>
</el-row>
<el-table
:data=
"tableList"
>
<el-table
:data=
"tableList"
>
<el-table-column
label=
"序号"
width=
"55"
type=
"index"
align=
"center"
></el-table-column>
<el-table-column
label=
"序号"
width=
"55"
type=
"index"
align=
"center"
></el-table-column>
...
...
safe-campus-bbs-ui/src/views/userLevel/FormDialog.vue
View file @
2a38011e
<
template
>
<
template
>
<el-dialog
:visible.sync=
"visible"
v-if=
"visible"
:title=
"dialogTitle"
width=
"28%"
class=
"dialog"
<el-dialog
:visible.sync=
"visible"
v-if=
"visible"
:title=
"dialogTitle"
width=
"28%"
class=
"dialog"
@
close=
"handleClose"
>
@
close=
"handleClose"
:close-on-click-modal=
"false"
>
<el-form
:model=
"form"
ref=
"formRef"
:rules=
"rules"
label-position=
"top"
>
<el-form
:model=
"form"
ref=
"formRef"
:rules=
"rules"
label-position=
"top"
>
<el-form-item
label=
"等级名称"
prop=
"name"
>
<el-form-item
label=
"等级名称"
prop=
"name"
>
<el-input
placeholder=
"请输入"
v-model=
"form.name"
></el-input>
<el-input
placeholder=
"请输入"
v-model=
"form.name"
></el-input>
...
...
safe-campus-bbs-ui/vue.config.js
View file @
2a38011e
...
@@ -18,7 +18,7 @@ module.exports = {
...
@@ -18,7 +18,7 @@ module.exports = {
// 部署生产环境和开发环境下的URL。
// 部署生产环境和开发环境下的URL。
// 默认情况下,Vue CLI 会假设你的应用是被部署在一个域名的根路径上
// 默认情况下,Vue CLI 会假设你的应用是被部署在一个域名的根路径上
// 例如 https://www.ruoyi.vip/。如果应用被部署在一个子路径上,你就需要用这个选项指定这个子路径。例如,如果你的应用被部署在 https://www.ruoyi.vip/admin/,则设置 baseUrl 为 /admin/。
// 例如 https://www.ruoyi.vip/。如果应用被部署在一个子路径上,你就需要用这个选项指定这个子路径。例如,如果你的应用被部署在 https://www.ruoyi.vip/admin/,则设置 baseUrl 为 /admin/。
publicPath
:
process
.
env
.
NODE_ENV
===
"
production
"
?
"
/
"
:
"
/
"
,
publicPath
:
process
.
env
.
NODE_ENV
===
"
production
"
?
"
/
bbs/pc
"
:
"
/
"
,
// 在npm run build 或 yarn build 时 ,生成文件的目录名称(要和baseUrl的生产环境路径一致)(默认dist)
// 在npm run build 或 yarn build 时 ,生成文件的目录名称(要和baseUrl的生产环境路径一致)(默认dist)
outputDir
:
'
dist
'
,
outputDir
:
'
dist
'
,
// 用于放置生成的静态资源 (js、css、img、fonts) 的;(项目打包之后,静态资源会放在这个文件夹下)
// 用于放置生成的静态资源 (js、css、img、fonts) 的;(项目打包之后,静态资源会放在这个文件夹下)
...
...
safe-campus-bbs-uniapp/components/ImageUpload.vue
View file @
2a38011e
...
@@ -203,6 +203,7 @@
...
@@ -203,6 +203,7 @@
// 从本地相册选择图片或使用相机拍照
// 从本地相册选择图片或使用相机拍照
uni
.
chooseImage
({
uni
.
chooseImage
({
count
:
_this
.
limiData
,
count
:
_this
.
limiData
,
sourceType
:
[
'
album
'
],
success
(
res
)
{
success
(
res
)
{
const
tempFilePaths
=
JSON
.
parse
(
JSON
.
stringify
(
res
.
tempFilePaths
));
const
tempFilePaths
=
JSON
.
parse
(
JSON
.
stringify
(
res
.
tempFilePaths
));
if
(
tempFilePaths
.
length
<=
_this
.
limiData
)
{
if
(
tempFilePaths
.
length
<=
_this
.
limiData
)
{
...
...
safe-campus-bbs-uniapp/config/index.config.js
View file @
2a38011e
...
@@ -9,7 +9,7 @@ const CONFIG = {
...
@@ -9,7 +9,7 @@ const CONFIG = {
production
:
{
production
:
{
debug
:
false
,
debug
:
false
,
platformName
:
'
一站式轻享
'
,
platformName
:
'
一站式轻享
'
,
requestUrl
:
'
/prod-api
'
,
requestUrl
:
'
/
bbs/
prod-api
'
,
}
}
}
}
...
...
safe-campus-bbs-uniapp/manifest.json
View file @
2a38011e
...
@@ -72,7 +72,7 @@
...
@@ -72,7 +72,7 @@
"h5"
:
{
"h5"
:
{
"router"
:
{
"router"
:
{
"mode"
:
"history"
,
"mode"
:
"history"
,
"base"
:
"/h5/"
"base"
:
"/
bbs/
h5/"
}
}
}
}
}
}
safe-campus-bbs-uniapp/pages.json
View file @
2a38011e
...
@@ -18,7 +18,8 @@
...
@@ -18,7 +18,8 @@
"path"
:
"pages/topics/topics"
,
"path"
:
"pages/topics/topics"
,
"style"
:
"style"
:
{
{
"navigationBarTitleText"
:
"话题"
"navigationBarTitleText"
:
"话题"
,
"enablePullDownRefresh"
:
true
}
}
},
},
{
{
...
@@ -46,7 +47,8 @@
...
@@ -46,7 +47,8 @@
"path"
:
"pages/topic-detail/topic-detail"
,
"path"
:
"pages/topic-detail/topic-detail"
,
"style"
:
"style"
:
{
{
"navigationBarTitleText"
:
"话题详情"
"navigationBarTitleText"
:
"话题详情"
,
"enablePullDownRefresh"
:
true
}
}
},
},
{
{
...
...
safe-campus-bbs-uniapp/pages/index/index.vue
View file @
2a38011e
...
@@ -16,7 +16,7 @@
...
@@ -16,7 +16,7 @@
</scroll-view>
</scroll-view>
<!-- 发布按钮 -->
<!-- 发布按钮 -->
<movable-area
class=
"movable-area"
>
<movable-area
class=
"movable-area"
>
<movable-view
class=
"add-dynamic-box move-button"
:x=
"area.x
"
:y=
"area.y
"
direction=
"all"
@
change=
"onChange"
<movable-view
class=
"add-dynamic-box move-button"
:x=
"area.x
+'rpx'"
:y=
"area.y + 'rpx'
"
direction=
"all"
@
change=
"onChange"
damping=
"30"
@
click=
"toPublishPage"
>
damping=
"30"
@
click=
"toPublishPage"
>
<image
class=
"icon"
src=
"/static/images/publish-icon.png"
></image>
<image
class=
"icon"
src=
"/static/images/publish-icon.png"
></image>
</movable-view>
</movable-view>
...
@@ -41,8 +41,8 @@
...
@@ -41,8 +41,8 @@
},
},
total
:
0
,
total
:
0
,
area
:
{
area
:
{
x
:
33
0
,
x
:
62
0
,
y
:
60
0
y
:
106
0
},
},
emotions
emotions
}
}
...
@@ -128,11 +128,8 @@
...
@@ -128,11 +128,8 @@
.move-button
{
.move-button
{
pointer-events
:
auto
;
pointer-events
:
auto
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
pointer-events
:
auto
;
pointer-events
:
auto
;
border-radius
:
50%
;
}
}
}
}
...
...
safe-campus-bbs-uniapp/pages/login/login.vue
View file @
2a38011e
...
@@ -11,7 +11,8 @@
...
@@ -11,7 +11,8 @@
import
{
import
{
setToken
,
setToken
,
getRedirectPath
,
getRedirectPath
,
setRedirectPath
setRedirectPath
,
removeToken
}
from
'
@/utils/auth
'
;
}
from
'
@/utils/auth
'
;
import
{
import
{
getParams
getParams
...
@@ -26,27 +27,9 @@
...
@@ -26,27 +27,9 @@
}
}
},
},
onLoad
(
options
)
{
onLoad
(
options
)
{
let
{
code
,
targetPath
,
token
}
=
options
;
let
{
code
}
=
options
;
const
params
=
new
URLSearchParams
(
window
.
location
.
search
);
setRedirectPath
(
window
.
location
.
href
)
if
(
targetPath
&&
targetPath
!=
'
undefined
'
)
{
this
.
stateParams
=
params
.
get
(
'
targetPath
'
)
this
.
queryParams
=
params
}
else
{
this
.
stateParams
=
''
}
if
(
token
&&
token
!=
'
undefined
'
)
{
setToken
(
token
)
this
.
$store
.
dispatch
(
'
GetInfo
'
)
this
.
pageRedirect
()
}
else
{
this
.
code
=
code
;
this
.
code
=
code
;
if
(
code
)
{
this
.
loginIn
();
this
.
loginIn
();
}
else
{
this
.
getRedirectUrl
()
}
}
},
},
methods
:
{
methods
:
{
...
@@ -56,46 +39,55 @@
...
@@ -56,46 +39,55 @@
}
}
login
(
params
).
then
(
res
=>
{
login
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
200
&&
res
.
data
)
{
if
(
res
.
code
==
200
&&
res
.
data
)
{
setToken
(
res
.
data
.
token
)
setToken
(
res
.
data
)
this
.
$store
.
dispatch
(
'
GetInfo
'
)
this
.
$store
.
dispatch
(
'
GetInfo
'
)
this
.
pageRedirect
()
uni
.
switchTab
({
}
else
{
url
:
'
/pages/index/index
'
this
.
errInfo
=
res
.
msg
}
})
})
},
// 获取回调地址
getRedirectUrl
()
{
// let params = {
// path: getRedirectPath() || ''
// }
// getUrl(params).then(res => {
// console.log(res)
// if (res.code == 200 && res.data) {
// window.location = res.data
// }
// })
window
.
location
=
'
https://open.weixin.qq.com/connect/oauth2/authorize?appid=ww63ca87d5f8647514&redirect_uri=https%3A%2F%2Ftest.tangguo.ren/h5/pages/login/login/&response_type=code&scope=snsapi_base#wechat_redirect
'
},
// 页面跳转
pageRedirect
(){
if
(
this
.
stateParams
)
{
const
businessParams
=
new
URLSearchParams
();
this
.
queryParams
.
forEach
((
value
,
key
)
=>
{
if
(
key
!==
'
code
'
&&
key
!==
'
targetPath
'
)
{
businessParams
.
append
(
key
,
value
);
}
}
});
if
(
res
.
code
==
200
&&
!
res
.
data
){
uni
.
redirectTo
({
url
:
`
${
this
.
stateParams
}
?
${
businessParams
.
toString
()}
`
})
}
else
{
uni
.
switchTab
({
uni
.
switchTab
({
url
:
'
/pages/index/index
'
url
:
'
/pages/index/index
'
})
})
}
}
if
(
res
.
code
==
401
){
// removeToken()
window
.
location
=
res
.
data
}
}
})
},
// 获取回调地址
// getRedirectUrl() {
// // let params = {
// // path: getRedirectPath() || ''
// // }
// // getUrl(params).then(res => {
// // console.log(res)
// // if (res.code == 200 && res.data) {
// // window.location = res.data
// // }
// // })
// window.location = 'https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxd2a84aa7529d3801&redirect_uri=https%3A%2F%2Fwecom.jift.edu.cn%2Fbbs%2Fh5%2Fpages%2Flogin%2Flogin%2F&response_type=code&scope=snsapi_base&state=#wechat_redirect'
// },
// 页面跳转
// pageRedirect(){
// if (this.stateParams) {
// const businessParams = new URLSearchParams();
// this.queryParams.forEach((value, key) => {
// if (key !== 'code' && key !== 'targetPath') {
// businessParams.append(key, value);
// }
// });
// uni.redirectTo({
// url: `${this.stateParams}?${businessParams.toString()}`
// })
// } else {
// uni.switchTab({
// url: '/pages/index/index'
// })
// }
// }
}
}
}
}
</
script
>
</
script
>
...
...
safe-campus-bbs-uniapp/pages/publish/publish.vue
View file @
2a38011e
...
@@ -39,11 +39,11 @@
...
@@ -39,11 +39,11 @@
<view
class=
"pk-type-box"
>
<view
class=
"pk-type-box"
>
<radio-group
v-model=
"form.voteOptionType"
@
change=
"radioChange"
>
<radio-group
v-model=
"form.voteOptionType"
@
change=
"radioChange"
>
<label
class=
"radio"
style=
"margin-right: 40rpx;"
>
<label
class=
"radio"
style=
"margin-right: 40rpx;"
>
<radio
value=
"IMAGE"
:checked=
"form.voteOptionType=='IMAGE'"
/>
图片PK
</label>
<label
class=
"radio"
>
<radio
value=
"TEXT"
:checked=
"form.voteOptionType=='TEXT'"
/>
文字PK
<radio
value=
"TEXT"
:checked=
"form.voteOptionType=='TEXT'"
/>
文字PK
</label>
</label>
<label
class=
"radio"
>
<radio
value=
"IMAGE"
:checked=
"form.voteOptionType=='IMAGE'"
/>
图片PK
</label>
</radio-group>
</radio-group>
<view
class=
"choice-box"
v-if=
"form.voteOptionType=='IMAGE'"
>
<view
class=
"choice-box"
v-if=
"form.voteOptionType=='IMAGE'"
>
...
...
safe-campus-bbs-uniapp/pages/topic-detail/topic-detail.vue
View file @
2a38011e
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
<scroll-view
class=
"scroll-view-topic"
scroll-y
:show-scrollbar=
"false"
v-if=
"list.length>0"
<scroll-view
class=
"scroll-view-topic"
scroll-y
:show-scrollbar=
"false"
v-if=
"list.length>0"
@
scrolltolower=
"loadMore"
>
@
scrolltolower=
"loadMore"
>
<template
v-for=
"(item,index) in list"
>
<template
v-for=
"(item,index) in list"
>
<dynamic-item
:form=
"item"
></dynamic-item>
<dynamic-item
:form=
"item"
@
refresh=
"handleRefresh"
></dynamic-item>
</
template
>
</
template
>
</scroll-view>
</scroll-view>
<scroll-view
class=
"scroll-view-topic"
scroll-y
:show-scrollbar=
"false"
v-else
>
<scroll-view
class=
"scroll-view-topic"
scroll-y
:show-scrollbar=
"false"
v-else
>
...
@@ -61,6 +61,12 @@
...
@@ -61,6 +61,12 @@
this
.
getDetail
()
this
.
getDetail
()
}
}
},
},
onPullDownRefresh
()
{
this
.
refreshContentList
()
setTimeout
(()
=>
{
uni
.
stopPullDownRefresh
();
},
1000
)
},
methods
:
{
methods
:
{
getDetail
()
{
getDetail
()
{
uni
.
showLoading
({
uni
.
showLoading
({
...
@@ -78,10 +84,21 @@
...
@@ -78,10 +84,21 @@
url
:
`/pages/publish/publish?topicId=
${
this
.
queryParams
.
topicId
}
&topicName=
${
this
.
topicName
}
`
url
:
`/pages/publish/publish?topicId=
${
this
.
queryParams
.
topicId
}
&topicName=
${
this
.
topicName
}
`
})
})
},
},
handleRefresh
(){
this
.
list
=
[];
this
.
queryParams
.
pageNum
=
1
;
this
.
getDetail
();
},
// 下拉刷新
refreshContentList
()
{
this
.
list
=
[];
this
.
queryParams
.
pageNum
=
1
;
this
.
getDetail
();
},
loadMore
()
{
loadMore
()
{
if
(
this
.
list
.
length
<
this
.
total
)
{
if
(
this
.
list
.
length
<
this
.
total
)
{
this
.
queryParams
.
pageNum
+=
1
;
this
.
queryParams
.
pageNum
+=
1
;
this
.
get
List
()
this
.
get
Detail
()
}
}
},
},
}
}
...
@@ -93,7 +110,8 @@
...
@@ -93,7 +110,8 @@
.topic-detail-page
{
.topic-detail-page
{
background-color
:
white
;
background-color
:
white
;
overflow
:
hidden
;
overflow
:
hidden
;
.topic-box
{
.topic-box
{
padding
:
32rpx
34rpx
2rpx
32rpx
;
padding
:
32rpx
34rpx
2rpx
32rpx
;
...
...
safe-campus-bbs-uniapp/pages/topics/topics.vue
View file @
2a38011e
...
@@ -45,6 +45,12 @@
...
@@ -45,6 +45,12 @@
onShow
()
{
onShow
()
{
this
.
getList
()
this
.
getList
()
},
},
onPullDownRefresh
()
{
this
.
refreshContentList
()
setTimeout
(()
=>
{
uni
.
stopPullDownRefresh
();
},
1000
)
},
methods
:
{
methods
:
{
// 话题热搜榜
// 话题热搜榜
getList
()
{
getList
()
{
...
@@ -56,6 +62,11 @@
...
@@ -56,6 +62,11 @@
this
.
hotList
=
res
.
data
this
.
hotList
=
res
.
data
})
})
},
},
// 下拉刷新
refreshContentList
()
{
this
.
hotList
=
[];
this
.
getList
();
},
topTopicDetailPage
(
item
)
{
topTopicDetailPage
(
item
)
{
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
'
/pages/topic-detail/topic-detail?topicId=
'
+
item
.
id
+
'
&topicName=
'
+
item
.
name
url
:
'
/pages/topic-detail/topic-detail?topicId=
'
+
item
.
id
+
'
&topicName=
'
+
item
.
name
...
...
safe-campus-bbs-uniapp/static/styles/index.scss
View file @
2a38011e
...
@@ -302,7 +302,7 @@
...
@@ -302,7 +302,7 @@
width
:
100vw
;
width
:
100vw
;
height
:
100vh
;
height
:
100vh
;
background-color
:
rgba
(
0
,
0
,
0
,
0
.3
);
background-color
:
rgba
(
0
,
0
,
0
,
0
.3
);
z-index
:
99
0
;
z-index
:
99
9
;
position
:fixed
;
position
:fixed
;
top
:
0
;
top
:
0
;
left
:
0
;
left
:
0
;
...
...
safe-campus-bbs-uniapp/utils/request.js
View file @
2a38011e
import
config
from
'
@/config/index.config.js
'
;
import
config
from
'
@/config/index.config.js
'
;
import
{
getToken
,
setRedirectPath
}
from
'
@/utils/auth
'
;
import
{
getToken
,
removeToken
,
setRedirectPath
}
from
'
@/utils/auth
'
;
import
errorCode
from
'
@/utils/errorCode
'
;
import
errorCode
from
'
@/utils/errorCode
'
;
import
{
toast
,
showConfirm
,
tansParams
}
from
'
@/utils/common
'
import
{
toast
,
showConfirm
,
tansParams
}
from
'
@/utils/common
'
import
store
from
'
@/store
'
;
import
store
from
'
@/store
'
;
...
@@ -43,17 +43,8 @@ const request = config => {
...
@@ -43,17 +43,8 @@ const request = config => {
const
code
=
data
.
code
||
200
const
code
=
data
.
code
||
200
const
msg
=
errorCode
[
code
]
||
data
.
msg
||
errorCode
[
'
default
'
]
const
msg
=
errorCode
[
code
]
||
data
.
msg
||
errorCode
[
'
default
'
]
if
(
code
===
401
)
{
if
(
code
===
401
)
{
removeToken
()
showConfirm
(
'
登录状态已过期,您可以继续留在该页面,或者重新登录?
'
).
then
(
res
=>
{
resolve
(
data
)
if
(
res
.
confirm
)
{
store
.
dispatch
(
'
LogOut
'
).
then
(
res
=>
{
uni
.
reLaunch
({
url
:
'
/pages/login/login
'
})
})
}
})
reject
(
'
无效的会话,或者会话已过期,请重新登录。
'
)
}
else
if
(
code
===
500
)
{
}
else
if
(
code
===
500
)
{
toast
(
msg
)
toast
(
msg
)
reject
(
'
500
'
)
reject
(
'
500
'
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment