Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
school-paper-admin-front
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
school-paper
school-paper-admin-front
Commits
fbd877c9
Commit
fbd877c9
authored
Jul 25, 2023
by
H.wb.wang.peixun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面开发
parent
81769c0d
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
47 additions
and
54 deletions
+47
-54
src/api/school-paper/questionBank.js
+11
-4
src/components/ImageUpload/index.vue
+1
-1
src/views/school-paper/banner/index.vue
+33
-47
src/views/school-paper/questionBank/index.vue
+0
-0
vue.config.js
+2
-2
No files found.
src/api/school-paper/questionBank.js
View file @
fbd877c9
...
...
@@ -8,11 +8,18 @@ export function listQuestionBank(query) {
params
:
query
})
}
// 查询题库主列表
export
function
questionType
(
query
)
{
return
request
({
url
:
'/school-paper/question-type/list'
,
method
:
'get'
,
params
:
query
})
}
// 查询题库主详细
export
function
getQuestionBank
(
id
)
{
return
request
({
url
:
'/school-paper/questionBank/'
+
id
,
url
:
'/school-paper/questionBank/
detail/
'
+
id
,
method
:
'get'
})
}
...
...
@@ -20,7 +27,7 @@ export function getQuestionBank(id) {
// 新增题库主
export
function
addQuestionBank
(
data
)
{
return
request
({
url
:
'/school-paper/questionBank'
,
url
:
'/school-paper/questionBank
/question
'
,
method
:
'post'
,
data
:
data
})
...
...
@@ -29,7 +36,7 @@ export function addQuestionBank(data) {
// 修改题库主
export
function
updateQuestionBank
(
data
)
{
return
request
({
url
:
'/school-paper/questionBank'
,
url
:
'/school-paper/questionBank
/question
'
,
method
:
'put'
,
data
:
data
})
...
...
src/components/ImageUpload/index.vue
View file @
fbd877c9
...
...
@@ -78,7 +78,7 @@ export default {
dialogVisible
:
false
,
hideUpload
:
false
,
baseUrl
:
process
.
env
.
VUE_APP_BASE_API
,
uploadImgUrl
:
process
.
env
.
VUE_APP_BASE_API
+
"/s
ystem/oss/upload
"
,
// 上传的图片服务器地址
uploadImgUrl
:
process
.
env
.
VUE_APP_BASE_API
+
"/s
chool-paper/banner/uploadFile
"
,
// 上传的图片服务器地址
headers
:
{
Authorization
:
"Bearer "
+
getToken
(),
},
...
...
src/views/school-paper/banner/index.vue
View file @
fbd877c9
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<
!--
<
el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
label=
"标题"
prop=
"bannerTitle"
>
<el-input
v-model=
"queryParams.bannerTitle"
...
...
@@ -21,20 +21,13 @@
<el-button
type=
"primary"
icon=
"el-icon-search"
size=
"mini"
@
click=
"handleQuery"
>
搜索
</el-button>
<el-button
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
</el-form>
-->
<el-row
:gutter=
"10"
class=
"mb8"
>
<el-col
:span=
"1.5"
>
<el-button
type=
"primary"
plain
icon=
"el-icon-plus"
size=
"mini"
@
click=
"handleAdd"
v-hasPermi=
"['school-paper:banner:add']"
>
新增
</el-button>
<el-button
type=
"primary"
size=
"mini"
@
click=
"handleAdd"
v-hasPermi=
"['school-paper:banner:add']"
>
新增轮播
</el-button>
</el-col>
<el-col
:span=
"1.5"
>
<
!--
<
el-col
:span=
"1.5"
>
<el-button
type=
"success"
plain
...
...
@@ -66,43 +59,39 @@
v-hasPermi=
"['school-paper:banner:export']"
>
导出
</el-button>
</el-col>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
-->
</el-row>
<el-table
v-loading=
"loading"
:data=
"bannerList"
@
selection-change=
"handleSelectionChange"
>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
label=
"主键id"
align=
"center"
prop=
"id"
v-if=
"true"
/>
<el-table-column
label=
"标题"
align=
"center"
prop=
"bannerTitle"
/>
<el-table-column
label=
"图片地址"
align=
"center"
prop=
"url"
/>
<el-table-column
label=
"备注"
align=
"center"
prop=
"remark"
/>
<el-table-column
label=
"状态:0正常,1删除"
align=
"center"
prop=
"status"
/>
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
-->
<!--
<el-table-column
label=
"主键id"
align=
"center"
prop=
"id"
v-if=
"true"
/>
-->
<el-table-column
label=
"轮播图标题"
prop=
"bannerTitle"
/>
<el-table-column
label=
"轮播图"
prop=
"url"
>
<template
slot-scope=
"scope"
>
<el-image
style=
"width: 100px; height: 100px"
:src=
"scope.url"
:preview-src-list=
"scope.url"
>
</el-image>
</
template
>
</el-table-column>
<el-table-column
label=
"是否启用"
prop=
"remark"
>
<
template
slot-scope=
"scope"
>
<el-switch
v-model=
"scope.remark"
active-color=
"#13ce66"
inactive-color=
"#ff4949"
>
</el-switch>
</
template
>
</el-table-column>
<!-- <el-table-column label="状态:0正常,1删除" align="center" prop="status" /> -->
<el-table-column
label=
"操作"
align=
"center"
class-name=
"small-padding fixed-width"
>
<
template
slot-scope=
"scope"
>
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-edit"
@
click=
"handleUpdate(scope.row)"
v-hasPermi=
"['school-paper:banner:edit']"
>
修改
</el-button>
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-delete"
@
click=
"handleDelete(scope.row)"
v-hasPermi=
"['school-paper:banner:remove']"
>
删除
</el-button>
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-edit"
@
click=
"handleUpdate(scope.row)"
v-hasPermi=
"['school-paper:banner:edit']"
>
编辑
</el-button>
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-delete"
@
click=
"handleDelete(scope.row)"
v-hasPermi=
"['school-paper:banner:remove']"
>
删除
</el-button>
</
template
>
</el-table-column>
</el-table>
<pagination
v-show=
"total>0"
:total=
"total"
:page
.
sync=
"queryParams.pageNum"
:limit
.
sync=
"queryParams.pageSize"
@
pagination=
"getList"
/>
<pagination
v-show=
"total > 0"
:total=
"total"
:page
.
sync=
"queryParams.pageNum"
:limit
.
sync=
"queryParams.pageSize"
@
pagination=
"getList"
/>
<!-- 添加或修改轮播图对话框 -->
<el-dialog
:title=
"title"
:visible
.
sync=
"open"
width=
"500px"
append-to-body
>
...
...
@@ -110,16 +99,13 @@
<el-form-item
label=
"标题"
prop=
"bannerTitle"
>
<el-input
v-model=
"form.bannerTitle"
placeholder=
"请输入标题"
/>
</el-form-item>
<el-form-item
label=
"图片地址"
prop=
"url"
>
<el-input
v-model=
"form.url"
placeholder=
"请输入图片地址"
/>
</el-form-item>
<el-form-item
label=
"备注"
prop=
"remark"
>
<el-input
v-model=
"form.remark"
placeholder=
"请输入备注"
/>
<el-form-item
label=
"上传"
prop=
"url"
>
<imageUpload
:limit=
"1"
v-model=
"form.url"
/>
</el-form-item>
</el-form>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
:loading=
"buttonLoading"
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
<div
slot=
"footer"
class=
"dialog-footer"
style=
"text-align: center;"
>
<el-button
@
click=
"cancel"
>
取 消
</el-button>
<el-button
:loading=
"buttonLoading"
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
</div>
</el-dialog>
</div>
...
...
@@ -228,7 +214,7 @@ export default {
// 多选框选中数据
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
id
)
this
.
single
=
selection
.
length
!==
1
this
.
single
=
selection
.
length
!==
1
this
.
multiple
=
!
selection
.
length
},
/** 新增按钮操作 */
...
...
src/views/school-paper/questionBank/index.vue
View file @
fbd877c9
This diff is collapsed.
Click to expand it.
vue.config.js
View file @
fbd877c9
...
...
@@ -35,8 +35,8 @@ module.exports = {
proxy
:
{
// detail: https://cli.vuejs.org/config/#devserver-proxy
[
process
.
env
.
VUE_APP_BASE_API
]:
{
target
:
`https://farming.nyinhong.com/api`
,
// target: `http://127.0.0.1:8111
`,
//
target: `https://farming.nyinhong.com/api`,
target
:
`http://192.168.0.195:8111/
`
,
changeOrigin
:
true
,
pathRewrite
:
{
[
'^'
+
process
.
env
.
VUE_APP_BASE_API
]:
''
...
...
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