提交 f96261bf authored 作者: 龙菲's avatar 龙菲

完善角色列表

上级 ad0972e3
...@@ -42,10 +42,11 @@ export function getMenu() { ...@@ -42,10 +42,11 @@ export function getMenu() {
} }
// 获取角色列表 // 获取角色列表
export function getRoleList() { export function getRoleList(data) {
return request({ return request({
url: '/sys/roles', url: '/sys/roles',
method: 'post' method: 'post',
data
}) })
} }
......
...@@ -120,8 +120,7 @@ export const title = [{ ...@@ -120,8 +120,7 @@ export const title = [{
export const operates = { export const operates = {
operate: true, operate: true,
label: "操作", label: "操作",
width: "260px", width: "200px",
minwidth: "220px",
titleAlign: "center", titleAlign: "center",
columnAlign: "center", columnAlign: "center",
} }
......
export const title = [{ export const title = [{
prop: "name", prop: "name",
label: "名称", label: "角色名称",
columnAlign: 'center', columnAlign: 'center',
width: 200, width: 200,
showOverFlowToolTip: true showOverFlowToolTip: true
}, },
{ {
prop: "authors", prop: "createTime",
label: "作者", label: "创建时间",
columnAlign: 'center', columnAlign: 'center',
}, },
{ {
prop: "browseCount", prop: "updateTime",
label: "浏览量", label: "更新时间",
columnAlign: 'center', columnAlign: 'center',
}, },
{ {
prop: "status", prop: "status",
label: "状态", label: "状态",
columnAlign: 'center', columnAlign: 'center',
isStatus: true, isStatus: true,
width: 100 width: 100
}, },
{ {
prop: "date", prop: "remark",
label: "出版/发布日期", label: "描述",
columnAlign: 'center', columnAlign: 'center',
}, },
// {
// prop: "pdfFile",
// label: "pdf文件",
// columnAlign: 'center',
// },
{
prop: "source",
label: "文献来源",
columnAlign: 'center',
},
{
prop: "remark",
label: "备注",
columnAlign: 'center',
showOverFlowToolTip: true,
},
] ]
...@@ -56,17 +40,14 @@ export const operates = { ...@@ -56,17 +40,14 @@ export const operates = {
columnAlign: "center", columnAlign: "center",
} }
export const operations = [{ export const operations = [
type: 'view',
title: '预览'
},
{ {
type: 'download', type: 'edit',
title: '下载' title: '编辑'
}, },
{ {
type: 'edit', type: 'edit',
title: '编辑' title: '数据权限'
}, },
{ {
type: 'delete', type: 'delete',
......
...@@ -5,9 +5,9 @@ ...@@ -5,9 +5,9 @@
<el-button <el-button
type="primary" type="primary"
@click.native="handleOperation({ type: 'add' })" @click.native="handleOperation({ type: 'add' })"
icon="el-icon-s-promotion" icon="el-icon-plus"
> >
发布</el-button 新建</el-button
> >
</div> </div>
<TablePage <TablePage
...@@ -61,8 +61,7 @@ import TableOperation from "@/components/Table/TableOperation.vue"; ...@@ -61,8 +61,7 @@ import TableOperation from "@/components/Table/TableOperation.vue";
import { title, operates, operations } from "./config"; import { title, operates, operations } from "./config";
import { getRoleList } from "@/api/user"; import { getRoleList } from "@/api/user";
import InfoEditDialog from "./components/InfoEditDialog"; import InfoEditDialog from "./components/InfoEditDialog";
import SearchBar from "@/components/SearchBar"; import SearchBar from "@/components/SearchBar"
import { downloadFile, previewFile, downloadBlob } from "@/utils/file";
export default { export default {
components: { components: {
...@@ -87,12 +86,7 @@ export default { ...@@ -87,12 +86,7 @@ export default {
{ {
prop: "name", prop: "name",
type: "input", type: "input",
label: "文献名称", label: "角色名称",
},
{
prop: "authors",
type: "input",
label: "作者",
}, },
{ {
prop: "status", prop: "status",
...@@ -100,11 +94,11 @@ export default { ...@@ -100,11 +94,11 @@ export default {
label: "状态", label: "状态",
selectOptions: [ selectOptions: [
{ {
label: "已上架", label: "正常",
value: "1", value: "1",
}, },
{ {
label: "已下架", label: "弃用",
value: "0", value: "0",
}, },
], ],
...@@ -171,7 +165,7 @@ export default { ...@@ -171,7 +165,7 @@ export default {
page: this.list.current, page: this.list.current,
limit: this.list.size, limit: this.list.size,
}; };
const res = await this.getRoleList(params); const res = await getRoleList(params);
if (res.code == 0) { if (res.code == 0) {
this.list = res.data; this.list = res.data;
} }
......
...@@ -88,9 +88,9 @@ ...@@ -88,9 +88,9 @@
label: "用户名", label: "用户名",
}, },
{ {
prop: "nickName", prop: "phone",
type: "input", type: "input",
label: "昵称", label: "手机号",
}, },
], ],
currentDeptNo: null, currentDeptNo: null,
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论