Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
national_museum_vod
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
qzhxx
national_museum_vod
Commits
9634ca70
Commit
9634ca70
authored
Jun 04, 2021
by
Your Name
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
展板分类删除提示
parent
7b19e994
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
343 additions
and
336 deletions
+343
-336
index.vue
src/page/content/display/classify/index.vue
+343
-336
No files found.
src/page/content/display/classify/index.vue
View file @
9634ca70
<
template
>
<
template
>
<div
class=
"listPage H100"
>
<div
class=
"listPage H100"
>
<div
class=
"search-container"
>
<div
class=
"search-container"
>
<el-form
<el-form
:inline=
"true"
:inline=
"true"
:model=
"form"
:model=
"form"
ref=
"form"
ref=
"form"
onsubmit=
"return false;"
onsubmit=
"return false;"
>
>
<el-form-item
>
<el-form-item
>
<el-input
<el-input
placeholder=
"请输入分类名称"
placeholder=
"请输入分类名称"
v-model=
"form.nameOrCode"
v-model=
"form.nameOrCode"
@
keyup
.
enter
.
native=
"onSearch"
@
keyup
.
enter
.
native=
"onSearch"
clearable
clearable
></el-input>
></el-input>
</el-form-item>
</el-form-item>
<el-form-item>
<el-form-item>
<el-date-picker
<el-date-picker
value-format=
"yyyy-MM-dd"
value-format=
"yyyy-MM-dd"
v-model=
"form.dateRange"
v-model=
"form.dateRange"
type=
"daterange"
type=
"daterange"
range-separator=
"至"
range-separator=
"至"
start-placeholder=
"开始日期"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
end-placeholder=
"结束日期"
></el-date-picker>
></el-date-picker>
</el-form-item>
</el-form-item>
<el-form-item>
<el-form-item>
<div
class=
"btn-group"
>
<div
class=
"btn-group"
>
<el-button
<el-button
type=
"primary"
type=
"primary"
@
click=
"onSearch"
@
click=
"onSearch"
>
查询
</el-button
>
查询
</el-button
>
>
<el-button
@
click=
"Reset"
>
重置
</el-button
<el-button
@
click=
"Reset"
>
重置
</el-button
>
>
</div>
</div>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
<div
class=
"page-tip"
>
<div
class=
"page-tip"
>
<span
class=
"page-tip-title"
>
页面说明:
</span>
<span
class=
"page-tip-title"
>
页面说明:
</span>
<span
class=
"page-tips"
<span
class=
"page-tips"
>
可通过创建时间、展板分类名称模糊搜索快速筛选展板分类信息,可对展板分类信息进行修改、删除。可新增视频分类。
</span
>
可通过创建时间、展板分类名称模糊搜索快速筛选展板分类信息,可对展板分类信息进行修改、删除。可新增视频分类。
</span
>
>
</div>
</div>
</div>
</div>
<div
class=
"table-content"
>
<div
class=
"table-content"
>
<div
class=
"btn-group"
>
<div
class=
"btn-group"
>
<el-button
type=
"primary"
@
click=
"addPermis()"
>
新建展板分类
</el-button>
<el-button
type=
"primary"
@
click=
"addPermis()"
>
新建展板分类
</el-button>
</div>
</div>
<div
class=
"party-table"
>
<div
class=
"party-table"
>
<el-table
<el-table
border
border
style=
"width: 100%; height: 100%"
style=
"width: 100%; height: 100%"
height=
"100%"
height=
"100%"
ref=
"multipleTable"
ref=
"multipleTable"
:data=
"tableData"
:data=
"tableData"
>
>
<el-table-column
<el-table-column
type=
"index"
type=
"index"
width=
"120"
width=
"120"
label=
"序号"
label=
"序号"
><template
slot-scope=
"scope"
>
><template
slot-scope=
"scope"
>
<span>
{{
(
page
.
_index
-
1
)
*
10
+
scope
.
$index
+
1
}}
</span>
<span>
{{
(
page
.
_index
-
1
)
*
10
+
scope
.
$index
+
1
}}
</span>
</
template
></el-table-column>
</
template
></el-table-column>
<el-table-column
label=
"展板分类名称"
prop=
"name"
></el-table-column>
<el-table-column
label=
"展板分类名称"
prop=
"name"
></el-table-column>
<el-table-column
<el-table-column
label=
"版权方"
label=
"版权方"
prop=
"copyrightOwnerNames"
prop=
"copyrightOwnerNames"
></el-table-column>
></el-table-column>
<el-table-column
label=
"创建时间"
prop=
"createTime"
></el-table-column>
<el-table-column
label=
"创建时间"
prop=
"createTime"
></el-table-column>
<el-table-column
label=
"备注"
prop=
"remarks"
></el-table-column>
<el-table-column
label=
"备注"
prop=
"remarks"
></el-table-column>
<el-table-column
label=
"操作"
header-align=
"center"
align=
"center"
>
<el-table-column
label=
"操作"
header-align=
"center"
align=
"center"
>
<
template
slot-scope=
"scope"
width=
"220"
>
<
template
slot-scope=
"scope"
width=
"220"
>
<div
class=
"table-btn-group"
>
<div
class=
"table-btn-group"
>
<el-tooltip
content=
"修改"
placement=
"top"
>
<el-tooltip
content=
"修改"
placement=
"top"
>
<el-button
circle
@
click=
"openEdit(scope.row)"
>
<el-button
circle
@
click=
"openEdit(scope.row)"
>
<i
class=
"icon-table icon-edit"
></i>
<i
class=
"icon-table icon-edit"
></i>
</el-button>
</el-button>
</el-tooltip>
</el-tooltip>
<el-tooltip
content=
"删除"
placement=
"top"
>
<el-tooltip
content=
"删除"
placement=
"top"
>
<el-button
circle
@
click=
"handleDelete(scope.row)"
>
<el-button
circle
@
click=
"handleDelete(scope.row)"
>
<i
class=
"icon-table icon-del"
></i>
<i
class=
"icon-table icon-del"
></i>
</el-button>
</el-button>
</el-tooltip>
</el-tooltip>
</div>
</div>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
</el-table>
</el-table>
</div>
</div>
<party-pagination
:page=
"page"
@
changePage=
"handleCurrentChange"
/>
<party-pagination
:page=
"page"
@
changePage=
"handleCurrentChange"
/>
</div>
</div>
<!--新增弹框-->
<!--新增弹框-->
<el-dialog
<el-dialog
:title=
"type?'新建展板分类':'编辑展板分类'"
:title=
"type?'新建展板分类':'编辑展板分类'"
custom-class=
"party-dialog"
custom-class=
"party-dialog"
width=
"468px"
width=
"468px"
:visible
.
sync=
"FormVisible"
:visible
.
sync=
"FormVisible"
:before-close=
"close"
:before-close=
"close"
>
>
<div
class=
"dialog-content"
>
<div
class=
"dialog-content"
>
<el-form
<el-form
:model=
"classForm"
:model=
"classForm"
ref=
"classForm"
ref=
"classForm"
label-width=
"80px"
label-width=
"80px"
label-position=
"top"
label-position=
"top"
:rules=
"rule"
:rules=
"rule"
id=
"ruleo"
id=
"ruleo"
class=
"party-form"
class=
"party-form"
>
>
<el-form-item
label=
"展板分类名称"
prop=
"name"
>
<el-form-item
label=
"展板分类名称"
prop=
"name"
>
<el-input
oninput=
"value = value.trim()"
v-model=
"classForm.name"
></el-input>
<el-input
oninput=
"value = value.trim()"
v-model=
"classForm.name"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"备注"
prop=
"remarks"
>
<el-form-item
label=
"备注"
prop=
"remarks"
>
<el-input
type=
"textarea"
v-model=
"classForm.remarks"
></el-input>
<el-input
type=
"textarea"
v-model=
"classForm.remarks"
></el-input>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
</div>
</div>
<div
slot=
"footer"
class=
"dialog-footer btn-group"
>
<div
slot=
"footer"
class=
"dialog-footer btn-group"
>
<el-button
size=
"mini"
v-show=
"type"
type=
"primary"
@
click=
"permisSave"
<el-button
size=
"mini"
v-show=
"type"
type=
"primary"
@
click=
"permisSave"
>
确定
</el-button
>
确定
</el-button
>
>
<el-button
size=
"mini"
v-show=
"!type"
type=
"primary"
@
click=
"permisEdit"
<el-button
size=
"mini"
v-show=
"!type"
type=
"primary"
@
click=
"permisEdit"
>
确定
</el-button
>
确定
</el-button
>
>
<el-button
size=
"mini"
@
click=
"close"
>
取 消
</el-button>
<el-button
size=
"mini"
@
click=
"close"
>
取 消
</el-button>
</div>
</div>
</el-dialog>
</el-dialog>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
{
partyPagination
}
from
"@/components/index"
;
import
{
partyPagination
}
from
"@/components/index"
;
export
default
{
export
default
{
components
:
{
partyPagination
},
components
:
{
partyPagination
},
data
()
{
data
()
{
return
{
return
{
type
:
true
,
type
:
true
,
page
:
{
_index
:
1
,
_size
:
10
,
total
:
0
},
page
:
{
_index
:
1
,
_size
:
10
,
total
:
0
},
tableData
:
[],
tableData
:
[],
FormVisible
:
false
,
FormVisible
:
false
,
formLabelWidth
:
"100px"
,
formLabelWidth
:
"100px"
,
form
:
{
form
:
{
dateRange
:[]
dateRange
:[]
},
},
classForm
:
{},
classForm
:
{},
rule
:
{
rule
:
{
name
:
[
name
:
[
{
required
:
true
,
message
:
"请输入展板分类名称"
,
trigger
:
"blur"
},
{
required
:
true
,
message
:
"请输入展板分类名称"
,
trigger
:
"blur"
},
{
min
:
1
,
max
:
20
,
message
:
"请输入1到20个字"
},
{
min
:
1
,
max
:
20
,
message
:
"请输入1到20个字"
},
],
],
remarks
:
[
remarks
:
[
{
min
:
1
,
max
:
100
,
message
:
"请输入1到100个字"
},
{
min
:
1
,
max
:
100
,
message
:
"请输入1到100个字"
},
],
],
},
},
value
:
""
,
value
:
""
,
name
:
""
,
name
:
""
,
};
};
},
},
computed
:
{},
computed
:
{},
mounted
()
{
mounted
()
{
this
.
onSearch
();
this
.
onSearch
();
},
},
methods
:
{
methods
:
{
onSearch
()
{
onSearch
()
{
this
.
page
.
_index
=
1
;
this
.
page
.
_index
=
1
;
this
.
getTableData
();
this
.
getTableData
();
},
},
// 获得数据接口
// 获得数据接口
getTableData
()
{
getTableData
()
{
let
vm
=
this
;
let
vm
=
this
;
let
param
=
{
let
param
=
{
_index
:
this
.
page
.
_index
,
_index
:
this
.
page
.
_index
,
_size
:
this
.
page
.
_size
,
_size
:
this
.
page
.
_size
,
nameOrCode
:
this
.
form
.
nameOrCode
,
nameOrCode
:
this
.
form
.
nameOrCode
,
startDate
:
this
.
form
.
dateRange
.
length
?
this
.
form
.
dateRange
[
0
]
:
""
,
startDate
:
this
.
form
.
dateRange
.
length
?
this
.
form
.
dateRange
[
0
]
:
""
,
endDate
:
this
.
form
.
dateRange
.
length
?
this
.
form
.
dateRange
[
1
]
:
""
,
endDate
:
this
.
form
.
dateRange
.
length
?
this
.
form
.
dateRange
[
1
]
:
""
,
};
};
vm
.
$https
(
vm
.
$https
(
{
{
url
:
"exhibitionBoardCat/getPageList"
,
url
:
"exhibitionBoardCat/getPageList"
,
method
:
"post"
,
method
:
"post"
,
authType
:
this
.
backToken
,
authType
:
this
.
backToken
,
},
},
vm
.
$qs
.
stringify
(
param
)
vm
.
$qs
.
stringify
(
param
)
)
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
let
data
=
res
.
data
.
data
;
let
data
=
res
.
data
.
data
;
vm
.
page
.
total
=
data
.
total
;
vm
.
page
.
total
=
data
.
total
;
vm
.
tableData
=
data
.
records
;
vm
.
tableData
=
data
.
records
;
})
})
.
catch
(
function
(
err
)
{
.
catch
(
function
(
err
)
{
console
.
log
(
err
);
console
.
log
(
err
);
});
});
},
},
// 分页
// 分页
handleCurrentChange
(
val
)
{
handleCurrentChange
(
val
)
{
this
.
page
.
_index
=
val
;
this
.
page
.
_index
=
val
;
this
.
getTableData
();
this
.
getTableData
();
},
},
// 重置
// 重置
Reset
()
{
Reset
()
{
this
.
form
=
{
dateRange
:[]};
this
.
form
=
{
dateRange
:[]};
this
.
onSearch
();
this
.
onSearch
();
},
},
// 添加
// 添加
addPermis
()
{
addPermis
()
{
this
.
FormVisible
=
true
;
this
.
FormVisible
=
true
;
this
.
type
=
true
;
this
.
type
=
true
;
this
.
classForm
=
{}
this
.
classForm
=
{}
},
},
// 新建展板分类确认保存
// 新建展板分类确认保存
permisSave
()
{
permisSave
()
{
let
_this
=
this
;
let
_this
=
this
;
_this
.
$refs
.
classForm
.
validate
((
valid
)
=>
{
_this
.
$refs
.
classForm
.
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
valid
)
{
const
params
=
{
const
params
=
{
name
:
this
.
classForm
.
name
,
name
:
this
.
classForm
.
name
,
remarks
:
this
.
classForm
.
remarks
,
remarks
:
this
.
classForm
.
remarks
,
}
}
_this
_this
.
$https
(
.
$https
(
{
{
url
:
"exhibitionBoardCat/save"
,
url
:
"exhibitionBoardCat/save"
,
method
:
"post"
,
method
:
"post"
,
authType
:
this
.
backToken
,
authType
:
this
.
backToken
,
},
},
_this
.
$qs
.
stringify
(
params
)
_this
.
$qs
.
stringify
(
params
)
)
)
.
then
(
.
then
(
(
res
)
=>
{
(
res
)
=>
{
if
(
res
.
data
.
resultCode
===
'200'
)
{
if
(
res
.
data
.
resultCode
===
'200'
)
{
_this
.
$message
.
success
(
"新建成功!"
);
_this
.
$message
.
success
(
"新建成功!"
);
//跳回用户列表
//跳回用户列表
_this
.
onSearch
();
_this
.
onSearch
();
_this
.
close
()
_this
.
close
()
}
else
{
}
else
{
_this
.
$message
.
error
(
res
.
data
.
message
);
_this
.
$message
.
error
(
res
.
data
.
message
);
}
}
},
},
(
error
)
=>
{
(
error
)
=>
{
_this
.
$message
({
_this
.
$message
({
type
:
"error"
,
type
:
"error"
,
message
:
error
,
message
:
error
,
});
});
}
}
);
);
}
}
});
});
},
},
// 编辑展板分类确认保存
// 编辑展板分类确认保存
permisEdit
()
{
permisEdit
()
{
let
_this
=
this
;
let
_this
=
this
;
_this
.
$refs
.
classForm
.
validate
((
valid
)
=>
{
_this
.
$refs
.
classForm
.
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
valid
)
{
_this
_this
.
$https
(
.
$https
(
{
{
url
:
"exhibitionBoardCat/update"
,
url
:
"exhibitionBoardCat/update"
,
method
:
"put"
,
method
:
"put"
,
authType
:
this
.
backToken
,
authType
:
this
.
backToken
,
},
},
_this
.
$qs
.
stringify
(
_this
.
classForm
)
_this
.
$qs
.
stringify
(
_this
.
classForm
)
)
)
.
then
(
.
then
(
(
res
)
=>
{
(
res
)
=>
{
if
(
res
.
data
.
resultCode
===
'200'
)
{
if
(
res
.
data
.
resultCode
===
'200'
)
{
_this
.
$message
.
success
(
"修改成功!"
);
_this
.
$message
.
success
(
"修改成功!"
);
//跳回用户列表
//跳回用户列表
_this
.
onSearch
();
_this
.
onSearch
();
_this
.
close
()
_this
.
close
()
}
else
{
}
else
{
_this
.
$message
.
error
(
res
.
data
.
message
);
_this
.
$message
.
error
(
res
.
data
.
message
);
}
}
},
},
(
error
)
=>
{
(
error
)
=>
{
_this
.
$message
({
_this
.
$message
({
type
:
"error"
,
type
:
"error"
,
message
:
error
,
message
:
error
,
});
});
}
}
);
);
}
}
});
});
},
},
// 关闭
// 关闭
close
()
{
close
()
{
this
.
FormVisible
=
false
;
this
.
FormVisible
=
false
;
this
.
classForm
=
{}
this
.
classForm
=
{}
this
.
$refs
[
"classForm"
].
clearValidate
();
this
.
$refs
[
"classForm"
].
clearValidate
();
this
.
$refs
[
"classForm"
].
resetFields
();
this
.
$refs
[
"classForm"
].
resetFields
();
},
},
// 编辑弹框
// 编辑弹框
openEdit
(
row
)
{
openEdit
(
row
)
{
this
.
type
=
false
;
this
.
type
=
false
;
this
.
FormVisible
=
true
;
this
.
FormVisible
=
true
;
this
.
classForm
=
JSON
.
parse
(
JSON
.
stringify
(
row
));
this
.
classForm
=
JSON
.
parse
(
JSON
.
stringify
(
row
));
},
},
// 删除
// 删除
handleDelete
(
row
)
{
handleDelete
(
row
)
{
let
_this
=
this
;
let
_this
=
this
;
this
.
$confirm
(
"此操作将永久删除, 是否继续?"
,
"提示"
,
{
this
.
$confirm
(
"此操作将永久删除, 是否继续?"
,
"提示"
,
{
confirmButtonText
:
"确定"
,
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
,
type
:
"warning"
,
})
})
.
then
(()
=>
{
.
then
(()
=>
{
_this
_this
.
$https
({
.
$https
({
method
:
"delete"
,
method
:
"delete"
,
url
:
"exhibitionBoardCat/delete/"
+
row
.
id
,
url
:
"exhibitionBoardCat/delete/"
+
row
.
id
,
authType
:
this
.
backToken
,
authType
:
this
.
backToken
,
})
})
.
then
(
.
then
(
(
res
)
=>
{
(
res
)
=>
{
this
.
$message
({
type
:
"success"
,
message
:
"删除成功!"
});
if
(
res
.
data
.
resultCode
===
"500"
){
_this
.
onSearch
();
this
.
$message
({
},
type
:
"error"
,
(
error
)
=>
{
message
:
res
.
data
.
message
,
this
.
$message
({
});
type
:
"error"
,
}
else
{
message
:
"删除失败!"
+
error
.
response
.
data
,
this
.
$message
({
type
:
"success"
,
message
:
"删除成功!"
});
});
_this
.
onSearch
();
}
}
);
},
})
(
error
)
=>
{
.
catch
(()
=>
{});
this
.
$message
({
},
type
:
"error"
,
},
message
:
"删除失败!"
+
error
.
response
.
data
,
};
});
</
script
>
}
);
<
style
lang=
"less"
>
})
@import "../../../../style/table.less";
.
catch
(()
=>
{});
</
style
>
},
},
};
</
script
>
<
style
lang=
"less"
>
@import "../../../../style/table.less";
</
style
>
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