Commit 8323908b by 张超军

Merge branch 'dev_zwpt' of http://47.92.108.28/changchao/founder_vue into dev_zwpt

parents d7c370e4 32ab5bab
...@@ -99,12 +99,12 @@ Plugin.install = function (Vue) { ...@@ -99,12 +99,12 @@ Plugin.install = function (Vue) {
window.axios = _axios; window.axios = _axios;
Object.defineProperties(Vue.prototype, { Object.defineProperties(Vue.prototype, {
axios: { axios: {
get() { get () {
return _axios; return _axios;
} }
}, },
$axios: { $axios: {
get() { get () {
return _axios; return _axios;
} }
} }
......
...@@ -92,28 +92,27 @@ ...@@ -92,28 +92,27 @@
</div> </div>
</div> </div>
<!--四 --> <!--四 -->
<div class="tag"> <el-tag
<el-tag style="width: 100%; color: #666666;margin-bottom:1rem "
style="width: 100%; color: #666666; " v-show="isShowTip"
v-show="isShowTip" >
> <span v-html="'&nbsp;&nbsp;'"></span>
<span v-html="'&nbsp;&nbsp;'"></span> <i
<i class="el-icon-info"
class="el-icon-info" style="color: #055fe7; font-size: 15px"
style="color: #055fe7; font-size: 15px" ></i>
></i> 已选择
已选择 <span style="color: #055fe7">{{ multipleSelection.length }}</span> 项​
<span style="color: #055fe7">{{ multipleSelection.length }}</span> 项​ <!-- <span v-html="'&nbsp;&nbsp;'"></span> -->
<!-- <span v-html="'&nbsp;&nbsp;'"></span> --> <!-- ​服务调用总计:<span v-html="'&nbsp;&nbsp;'"></span>36.4万 -->
<!-- ​服务调用总计:<span v-html="'&nbsp;&nbsp;'"></span>36.4万 --> <el-link
<el-link type="primary"
type="primary" :underline="false"
:underline="false" style="margin-left: 1.25rem"
style="margin-left: 1.25rem" @click="toggleSelection()"
@click="toggleSelection()" >清除</el-link>
>清除</el-link> </el-tag>
</el-tag>
</div>
<!-- 五 --> <!-- 五 -->
<el-table <el-table
:max-height="height" :max-height="height"
...@@ -855,6 +854,7 @@ export default { ...@@ -855,6 +854,7 @@ export default {
batch () { batch () {
this.disabled = !this.disabled; this.disabled = !this.disabled;
this.selectBoo = !this.selectBoo; this.selectBoo = !this.selectBoo;
this.isShowTip = !this.isShowTip;
this.toggleSelection(); this.toggleSelection();
// this.$set(this.multipleSelection, []) // this.$set(this.multipleSelection, [])
}, },
...@@ -879,11 +879,11 @@ export default { ...@@ -879,11 +879,11 @@ export default {
handleSelectionChange (val) { handleSelectionChange (val) {
this.multipleSelection = val; this.multipleSelection = val;
console.log(this.multipleSelection); console.log(this.multipleSelection);
if (this.multipleSelection.length) { // if (this.multipleSelection.length) {
this.isShowTip = true; // this.isShowTip = true;
} else { // } else {
this.isShowTip = false; // this.isShowTip = false;
} // }
}, },
/** /**
* @description: pageSize 改变时会触发 * @description: pageSize 改变时会触发
...@@ -1020,9 +1020,6 @@ export default { ...@@ -1020,9 +1020,6 @@ export default {
.delSelection /deep/ .el-table-column--selection .cell { .delSelection /deep/ .el-table-column--selection .cell {
display: none; display: none;
} }
.tag {
height: 40px;
}
// 滚动条的宽度 // 滚动条的宽度
/deep/ .el-table__body-wrapper::-webkit-scrollbar { /deep/ .el-table__body-wrapper::-webkit-scrollbar {
width: 6px; // 横向滚动条 width: 6px; // 横向滚动条
......
...@@ -160,6 +160,39 @@ ...@@ -160,6 +160,39 @@
label="任务号" label="任务号"
width="220" width="220"
> >
<template slot-scope="scope">
<svg-icon
style="
width: 0.875rem;
height: 0.6875rem;
margin-bottom: 0.125rem;
margin-left: 0.3125rem;
"
v-if="scope.row.personExportRecordGrandchildren || scope.row.personExportRecordGrandchildren === null"
icon-class="tree_f"
>
</svg-icon>
<svg-icon
style="
width: 0.8125rem;
height: 0.375rem;
margin: 0 0 0.1875rem 0;
"
v-else-if="!scope.row.personExportRecordGrandchildren || scope.row.personExportRecordGrandchildren !== null"
icon-class="tree_c"
></svg-icon>
{{
scope.row.personExportRecordGrandchildren || scope.row.personExportRecordGrandchildren === null
? scope.row.taskNumber
: scope.row.taskNumber
}}
<div
v-show="scope.row.personExportRecordGrandchildren && scope.row.personExportRecordGrandchildren !== null"
class="children-count"
>
{{ scope.row.personExportRecordGrandchildren ? scope.row.personExportRecordGrandchildren.length : 0 }}
</div>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="barcode" prop="barcode"
...@@ -192,7 +225,7 @@ ...@@ -192,7 +225,7 @@
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="collectIdcard" prop="collectIdName"
label="采集二代证" label="采集二代证"
width="200" width="200"
> >
...@@ -204,7 +237,7 @@ ...@@ -204,7 +237,7 @@
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="exportType" prop="exportName"
label="导出模式" label="导出模式"
width="auto" width="auto"
> >
...@@ -237,6 +270,39 @@ ...@@ -237,6 +270,39 @@
label="任务号" label="任务号"
width="220" width="220"
> >
<template slot-scope="scope">
<svg-icon
style="
width: 0.875rem;
height: 0.6875rem;
margin-bottom: 0.125rem;
margin-left: 0.3125rem;
"
v-if="scope.row.caseExportRecordGrandchildren || scope.row.caseExportRecordGrandchildren === null"
icon-class="tree_f"
>
</svg-icon>
<svg-icon
style="
width: 0.8125rem;
height: 0.375rem;
margin: 0 0 0.1875rem 0;
"
v-else-if="!scope.row.caseExportRecordGrandchildren || scope.row.caseExportRecordGrandchildren !== null"
icon-class="tree_c"
></svg-icon>
{{
scope.row.caseExportRecordGrandchildren || scope.row.caseExportRecordGrandchildren === null
? scope.row.taskNumber
: scope.row.taskNumber
}}
<div
v-show="scope.row.caseExportRecordGrandchildren && scope.row.caseExportRecordGrandchildren !== null"
class="children-count"
>
{{ scope.row.caseExportRecordGrandchildren ? scope.row.caseExportRecordGrandchildren.length : 0 }}
</div>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="barcode" prop="barcode"
...@@ -251,7 +317,7 @@ ...@@ -251,7 +317,7 @@
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="exportType" prop="exportName"
label="导出模式" label="导出模式"
width="200" width="200"
> >
...@@ -297,7 +363,8 @@ ...@@ -297,7 +363,8 @@
</div> </div>
</template> </template>
<script> <script>
import "@/icons/tree_f.svg";
import "@/icons/tree_c.svg";
export default { export default {
name: "gzlb", name: "gzlb",
data () { data () {
...@@ -799,3 +866,86 @@ export default { ...@@ -799,3 +866,86 @@ export default {
color: #333333; color: #333333;
} }
</style> </style>
<!--table树-->
<style scoped lang="scss">
.children-count {
width: 34px;
font-size: 12px;
text-align: center;
background: #f6f8fa;
border-radius: 11px;
position: absolute;
right: 10px;
top: 25%;
}
.el-tree /deep/ .el-tree-node__expand-icon.expanded {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
/*有子节点 且未展开*/
.el-table /deep/ .el-icon-arrow-right:before {
// background: url("../../icons/tree_f.svg") no-repeat 0 3px;
content: "";
display: block;
width: 16px;
height: 16px;
font-size: 16px;
background-size: 16px;
}
/*有子节点 且已展开*/
.el-table /deep/ .el-table__expand-icon--expanded {
.el-icon-arrow-right:before {
// background: url("../../icons/tree_c.svg") no-repeat 0 3px;
content: "";
display: block;
width: 15px;
height: 20px;
font-size: 18px;
background-size: 21px;
}
}
/*没有子节点*/
.el-tree
/deep/
.el-tree-node__expand-icon.is-leaf::before
.el-table
/deep/
.el-table__placeholder::before {
// background: url("../../icons/tree_f.svg") no-repeat 0 3px;
content: "";
display: block;
width: 16px;
height: 18px;
font-size: 16px;
background-size: 16px;
}
/deep/.el-table--enable-row-hover .el-table__body tr:hover {
cursor: pointer;
}
</style>
<style lang="scss" >
.el-table__expand-icon {
position: absolute;
right: 45px;
cursor: pointer;
color: #b51f1f;
transition: transform 0.2s ease-in-out;
width: 11px;
height: 11px;
/* border: black 1px solid; */
margin: 0;
background-image: url("../../assets/img/confirm/expend.png");
background-position: center;
background-size: 11px;
background-repeat: no-repeat;
}
.el-table__expand-icon.el-table__expand-icon--expanded {
width: 11px;
height: 11px;
background-image: url("../../assets/img/confirm/shrink.png");
background-position: center;
background-size: 11px;
background-repeat: no-repeat;
transform: rotate(180deg) !important;
}
</style>
...@@ -162,20 +162,51 @@ export default { ...@@ -162,20 +162,51 @@ export default {
}, },
methods: { methods: {
focus () { focus () {
// 创建隐藏的可下载链接
let eleLink = document.createElement('a') this.$axios
// let url = 'http://192.168.128.107:8099/api/export/person/' + this.rowData[0].barcode .post("/api/export/case/" + this.rowData[0].ysxtAsjbh)
// let url = 'http://www.meetfood.cn:2390/api/export/case/' + this.rowData[0].ysxtAsjbh .then((response) => {
let url = 'http://192.168.128.110:8099/api/export/case/' + this.rowData[0].ysxtAsjbh console.log(response)
eleLink.download = this.filenameexport if (response.status === 200) {
eleLink.style.display = 'none' if (response.data.code) {
eleLink.href = url this.$message.error(response.data.message);
// 触发点击 } else {
document.body.appendChild(eleLink) // 创建隐藏的可下载链接
eleLink.click() let eleLink = document.createElement('a')
// 然后移除 // let url = 'http://192.168.128.107:8099/api/export/person/' + this.rowData[0].barcode
document.body.removeChild(eleLink) let url = 'http://www.meetfood.cn:2390/api/export/case/' + this.rowData[0].ysxtAsjbh
this.dialogVisible = false; // let url = 'http://192.168.128.110:8099/api/export/case/' + this.rowData[0].ysxtAsjbh
eleLink.download = this.filenameexport
eleLink.style.display = 'none'
eleLink.href = url
// 触发点击
document.body.appendChild(eleLink)
eleLink.click()
// 然后移除
document.body.removeChild(eleLink)
this.dialogVisible = false;
this.$router.push('/dclb')
}
} else {
this.$message.error(response.data.message);
}
});
// // 创建隐藏的可下载链接
// let eleLink = document.createElement('a')
// // let url = 'http://192.168.128.107:8099/api/export/person/' + this.rowData[0].barcode
// // let url = 'http://www.meetfood.cn:2390/api/export/case/' + this.rowData[0].ysxtAsjbh
// let url = 'http://192.168.128.110:8099/api/export/case/' + this.rowData[0].ysxtAsjbh
// eleLink.download = this.filenameexport
// eleLink.style.display = 'none'
// eleLink.href = url
// // 触发点击
// document.body.appendChild(eleLink)
// eleLink.click()
// // 然后移除
// document.body.removeChild(eleLink)
// this.dialogVisible = false;
}, },
// 发查询指位信息 // 发查询指位信息
getHpseqno () { getHpseqno () {
......
...@@ -548,21 +548,48 @@ export default { ...@@ -548,21 +548,48 @@ export default {
}, },
methods: { methods: {
focus () { focus () {
// 创建隐藏的可下载链接
let eleLink = document.createElement('a')
// let url = 'http://192.168.128.107:8099/api/export/person/' + this.rowData[0].barcode
// let url = 'http://www.meetfood.cn:2390/api/export/person/' + this.rowData[0].ysxtAsjxgrybh
let url = 'http://192.168.128.110:8099/api/export/person/' + this.rowData[0].ysxtAsjxgrybh
eleLink.download = this.filenameexport this.$axios
eleLink.style.display = 'none' .post("/api/export/person/" + this.rowData[0].ysxtAsjxgrybh)
eleLink.href = url .then((response) => {
// 触发点击 if (response.status === 200) {
document.body.appendChild(eleLink) if (response.data.code) {
eleLink.click() this.$message.error(response.data.message);
// 然后移除 } else {
document.body.removeChild(eleLink) // 创建隐藏的可下载链接
this.dialogVisible = false; let eleLink = document.createElement('a')
let url = 'http://www.meetfood.cn:2390/api/export/person/' + this.rowData[0].ysxtAsjxgrybh
eleLink.download = this.filenameexport
eleLink.style.display = 'none'
eleLink.href = url
// 触发点击
document.body.appendChild(eleLink)
eleLink.click()
// 然后移除
document.body.removeChild(eleLink)
this.dialogVisible = false;
this.$router.push('/dclb')
}
} else {
this.$message.error(response.data.message);
}
});
// // 创建隐藏的可下载链接
// let eleLink = document.createElement('a')
// // let url = 'http://192.168.128.107:8099/api/export/person/' + this.rowData[0].barcode
// // let url = 'http://www.meetfood.cn:2390/api/export/person/' + this.rowData[0].ysxtAsjxgrybh
// let url = 'http://192.168.128.110:8099/api/export/person/' + this.rowData[0].ysxtAsjxgrybh
// eleLink.download = this.filenameexport
// eleLink.style.display = 'none'
// eleLink.href = url
// // 触发点击
// document.body.appendChild(eleLink)
// eleLink.click()
// // 然后移除
// document.body.removeChild(eleLink)
// this.dialogVisible = false;
}, },
handleClose (done) { handleClose (done) {
this.dialogVisible = false; this.dialogVisible = false;
......
...@@ -751,6 +751,7 @@ export default { ...@@ -751,6 +751,7 @@ export default {
batch () { batch () {
this.disabled = !this.disabled this.disabled = !this.disabled
this.selectBoo = !this.selectBoo; this.selectBoo = !this.selectBoo;
this.isShowTip = !this.isShowTip;
this.toggleSelection() this.toggleSelection()
}, },
/** /**
...@@ -770,11 +771,11 @@ export default { ...@@ -770,11 +771,11 @@ export default {
handleSelectionChange (val) { handleSelectionChange (val) {
this.multipleSelection = val; this.multipleSelection = val;
console.log(this.multipleSelection); console.log(this.multipleSelection);
if (this.multipleSelection.length) { // if (this.multipleSelection.length) {
this.isShowTip = true; // this.isShowTip = true;
} else { // } else {
this.isShowTip = false; // this.isShowTip = false;
} // }
}, },
/** /**
* @description: pageSize 改变时会触发 * @description: pageSize 改变时会触发
......
...@@ -92,7 +92,12 @@ ...@@ -92,7 +92,12 @@
> >
<el-table-column type="selection" height width="auto"> <el-table-column type="selection" height width="auto">
</el-table-column> </el-table-column>
<el-table-column prop="name" label="用户组" :width="width1"> <el-table-column
prop="name"
label="用户组"
:width="width1"
show-overflow-tooltip
>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="roleNames" prop="roleNames"
...@@ -166,7 +171,7 @@ ...@@ -166,7 +171,7 @@
cursor: pointer; cursor: pointer;
" "
src="../../assets/img/qbryk/bj.png" src="../../assets/img/qbryk/bj.png"
@click="openedit(scope.row.id)" @click="openedit(scope.row)"
/> />
</Confirmation> </Confirmation>
<Confirmation <Confirmation
...@@ -281,7 +286,7 @@ ...@@ -281,7 +286,7 @@
v-show="isShowEditGroupDialogBg" v-show="isShowEditGroupDialogBg"
@click="canceledit" @click="canceledit"
></div> ></div>
<div class="addUserDialog" v-show="isShowEditGroupDialog"> <div class="addUserDialog dialog" v-show="isShowEditGroupDialog">
<div class="head-title"> <div class="head-title">
<div class="left">编辑用户组</div> <div class="left">编辑用户组</div>
<div class="close" @click="canceledit"> <div class="close" @click="canceledit">
...@@ -327,8 +332,8 @@ ...@@ -327,8 +332,8 @@
</el-form-item> </el-form-item>
<el-form-item class="info-item" label="启用状态:" prop="status"> <el-form-item class="info-item" label="启用状态:" prop="status">
<el-radio-group class="radio-info" v-model="editFormParams.status"> <el-radio-group class="radio-info" v-model="editFormParams.status">
<el-radio :label="1">启用</el-radio> <el-radio :label="1" class="qiyong">启用</el-radio>
<el-radio :label="0">停用</el-radio> <el-radio :label="0" class="tingyong">停用</el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item class="addbtns"> <el-form-item class="addbtns">
...@@ -353,7 +358,7 @@ ...@@ -353,7 +358,7 @@
<div class="head-title"> <div class="head-title">
<div class="left"> <div class="left">
<img class="title-img" :src="src" alt="" /> <img class="title-img" :src="src" alt="" />
{{ title.unitname }} {{ checkItem.name }}
</div> </div>
<div class="close" @click="cancelrole"> <div class="close" @click="cancelrole">
<img src="@/assets/img/manage/close.png" alt="" /> <img src="@/assets/img/manage/close.png" alt="" />
...@@ -368,20 +373,13 @@ ...@@ -368,20 +373,13 @@
</div> </div>
</div> </div>
<div class="default-role-group"> <div class="default-role-group">
<div class="default-btn"> <div
<span>指纹入库员</span> class="default-btn"
<div class="triangle"> v-for="item in checkItem.roleNames &&
<i class="el-icon-close"></i> checkItem.roleNames.split(',')"
</div> :key="item"
</div> >
<div class="default-btn"> <span>{{ item }}</span>
<span>综合认定员</span>
<div class="triangle">
<i class="el-icon-close"></i>
</div>
</div>
<div class="default-btn">
<span>高级认定员</span>
<div class="triangle"> <div class="triangle">
<i class="el-icon-close"></i> <i class="el-icon-close"></i>
</div> </div>
...@@ -392,24 +390,8 @@ ...@@ -392,24 +390,8 @@
添加完成 添加完成
</div> </div>
<div class="add-role-group"> <div class="add-role-group">
<div class="default-btn"> <div class="default-btn" v-for="item in userArr" :key="item.id">
<span>指纹入库员</span> <span>{{ item.name }}</span>
<img src="@/assets/img/jiahao.png" alt="" />
</div>
<div class="default-btn">
<span>综合认定员</span>
<img src="@/assets/img/jiahao.png" alt="" />
</div>
<div class="default-btn">
<span>高级认定员</span>
<img src="@/assets/img/jiahao.png" alt="" />
</div>
<div class="default-btn">
<span>指纹入库员</span>
<img src="@/assets/img/jiahao.png" alt="" />
</div>
<div class="default-btn custom">
<span>综合认定员</span>
<img src="@/assets/img/jiahao.png" alt="" /> <img src="@/assets/img/jiahao.png" alt="" />
</div> </div>
<div class="default-btn custom"> <div class="default-btn custom">
...@@ -651,6 +633,8 @@ export default { ...@@ -651,6 +633,8 @@ export default {
isShowUserDialog: false, // 用户设置 弹窗 isShowUserDialog: false, // 用户设置 弹窗
isShowRoleDialogBg: false, // 角色设置 背景 isShowRoleDialogBg: false, // 角色设置 背景
isShowRoleDialog: false, // 角色设置 弹窗 isShowRoleDialog: false, // 角色设置 弹窗
checkItem: {}, //选中后的信息
userArr: [], //用户集合
}; };
}, },
computed: { computed: {
...@@ -668,6 +652,19 @@ export default { ...@@ -668,6 +652,19 @@ export default {
this.selectBoo = false; this.selectBoo = false;
this.$refs.multipleTable.clearSelection(); this.$refs.multipleTable.clearSelection();
}, },
searchUser() {
let self = this;
this.$axios
.get("/system/roles")
.then((res) => {
if (res.data !== null) {
self.userArr = res.data;
} else {
this.$message.error("获取角色信息失败!");
}
})
.catch(() => {});
},
clear() { clear() {
this.searchParams.page.page = 1; //必填 this.searchParams.page.page = 1; //必填
this.searchParams.page.total = 20; //必填 this.searchParams.page.total = 20; //必填
...@@ -763,7 +760,9 @@ export default { ...@@ -763,7 +760,9 @@ export default {
this.isShowAddUserDialogBg = false; this.isShowAddUserDialogBg = false;
}, },
// 打开编辑弹窗 // 打开编辑弹窗
openedit(id) { openedit(row) {
this.checkItem = row;
let id = row.id;
var usergroup = new URLSearchParams(); var usergroup = new URLSearchParams();
usergroup.append("Id", id); usergroup.append("Id", id);
this.$axios this.$axios
...@@ -800,6 +799,7 @@ export default { ...@@ -800,6 +799,7 @@ export default {
}, },
// 打开用户设置弹窗 // 打开用户设置弹窗
setUser(row) { setUser(row) {
this.checkItem = row;
// this.visible.setUserVisible = true; // this.visible.setUserVisible = true;
this.isShowUserDialog = true; this.isShowUserDialog = true;
this.isShowUserDialogBg = true; this.isShowUserDialogBg = true;
...@@ -807,6 +807,7 @@ export default { ...@@ -807,6 +807,7 @@ export default {
}, },
// 打开角色弹窗 // 打开角色弹窗
setRole(row) { setRole(row) {
this.checkItem = row;
// this.visible.setRoleVisible = true; // this.visible.setRoleVisible = true;
this.isShowRoleDialog = true; this.isShowRoleDialog = true;
this.isShowRoleDialogBg = true; this.isShowRoleDialogBg = true;
...@@ -906,6 +907,7 @@ export default { ...@@ -906,6 +907,7 @@ export default {
}, },
mounted() { mounted() {
this.search(); this.search();
this.searchUser();
}, },
watch: { watch: {
selectBoo: { selectBoo: {
......
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
<div class="table"> <div class="table">
<el-table <el-table
:height="userWidths.height" :height="userWidths.height"
style="width: 100%;" style="width: 100%"
highlight-current-row highlight-current-row
ref="multipleTable" ref="multipleTable"
:key="key1" :key="key1"
...@@ -114,7 +114,7 @@ ...@@ -114,7 +114,7 @@
<div <div
class="tags" class="tags"
v-for="item in scope.row.roleNames && v-for="item in scope.row.roleNames &&
scope.row.roleNames.split(',')" scope.row.roleNames.split(',')"
> >
{{ item }} {{ item }}
</div> </div>
...@@ -129,18 +129,14 @@ ...@@ -129,18 +129,14 @@
<template slot-scope="scope"> <template slot-scope="scope">
<div <div
v-for="(item, index) in scope.row.permissionNames && v-for="(item, index) in scope.row.permissionNames &&
scope.row.permissionNames.split(',')" scope.row.permissionNames.split(',')"
> >
{{ index > 0 ? "/" : "" }} {{ index > 0 ? "/" : "" }}
{{ item }} {{ item }}
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column prop="status" label="启用状态" width="110">
prop="status"
label="启用状态"
:width="userWidths.width1"
>
<template slot-scope="scope"> <template slot-scope="scope">
<div v-if="scope.row.status === 0" class="circle-red"></div> <div v-if="scope.row.status === 0" class="circle-red"></div>
<div v-if="scope.row.status === 1" class="circle-blue"></div> <div v-if="scope.row.status === 1" class="circle-blue"></div>
...@@ -156,7 +152,12 @@ ...@@ -156,7 +152,12 @@
<el-table-column prop="active" label="操作"> <el-table-column prop="active" label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<img <img
style="width: 1.125rem;height: 1.125rem;margin-right: 1.125rem;cursor: pointer" style="
width: 1.125rem;
height: 1.125rem;
margin-right: 1.125rem;
cursor: pointer;
"
src="../../assets/img/qbryk/bj.png" src="../../assets/img/qbryk/bj.png"
@click="userEdit(scope.row.userId, scope.row.roleName)" @click="userEdit(scope.row.userId, scope.row.roleName)"
/> />
...@@ -264,7 +265,7 @@ ...@@ -264,7 +265,7 @@
<div <div
class="tags" class="tags"
v-for="item in scope.row.roleNames && v-for="item in scope.row.roleNames &&
scope.row.roleNames.split(',')" scope.row.roleNames.split(',')"
> >
{{ item }} {{ item }}
</div> </div>
...@@ -278,7 +279,11 @@ ...@@ -278,7 +279,11 @@
<template slot-scope="scope"> <template slot-scope="scope">
<div class="group-item"> <div class="group-item">
<svg-icon <svg-icon
style="width: 1rem;height: .8125rem;margin-bottom: -0.0625rem;" style="
width: 1rem;
height: 0.8125rem;
margin-bottom: -0.0625rem;
"
icon-class="group-item" icon-class="group-item"
/> />
{{ scope.row.userCount }} {{ scope.row.userCount }}
...@@ -290,9 +295,7 @@ ...@@ -290,9 +295,7 @@
</el-table-column> </el-table-column>
<el-table-column> <el-table-column>
<template slot-scope="scope"> <template slot-scope="scope">
<div class="set-btn" :width="groupWidths.btnwidth"> <div class="set-btn" :width="groupWidths.btnwidth">用户设置</div>
用户设置
</div>
</template> </template>
</el-table-column> </el-table-column>
...@@ -305,7 +308,7 @@ ...@@ -305,7 +308,7 @@
<template slot-scope="scope"> <template slot-scope="scope">
<div <div
v-for="(item, index) in scope.row.permissionNames && v-for="(item, index) in scope.row.permissionNames &&
scope.row.permissionNames.split(',')" scope.row.permissionNames.split(',')"
> >
{{ index > 0 ? "/" : "" }} {{ index > 0 ? "/" : "" }}
{{ item }} {{ item }}
...@@ -333,7 +336,12 @@ ...@@ -333,7 +336,12 @@
<el-table-column prop="active" label="操作"> <el-table-column prop="active" label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<img <img
style="width: 1.125rem;height: 1.125rem;margin-right: 1.125rem;cursor: pointer" style="
width: 1.125rem;
height: 1.125rem;
margin-right: 1.125rem;
cursor: pointer;
"
src="../../assets/img/qbryk/bj.png" src="../../assets/img/qbryk/bj.png"
@click="groupEdit(scope.row.id)" @click="groupEdit(scope.row.id)"
/> />
...@@ -407,7 +415,7 @@ export default { ...@@ -407,7 +415,7 @@ export default {
width2: 100, width2: 100,
width5: 220, width5: 220,
width1: 100, width1: 100,
height: 480 height: 480,
}, },
// 搜索用户 // 搜索用户
userSearchParams: { userSearchParams: {
...@@ -420,18 +428,18 @@ export default { ...@@ -420,18 +428,18 @@ export default {
page: { page: {
total: 20, total: 20,
count: 0, count: 0,
page: 1 page: 1,
} },
}, },
src: require("@/assets/img/police-badge.png"), src: require("@/assets/img/police-badge.png"),
groupTableData: [], groupTableData: [],
// 用户组列表的表格宽度 // 用户组列表的表格宽度
groupWidths: { groupWidths: {
width3: 110, width3: 220,
width2: 400, width2: 400,
width1: 200, width1: 200,
height: 480, height: 480,
btnwidth: 200 btnwidth: 200,
}, },
// 搜索用户组 // 搜索用户组
groupSearchParams: { groupSearchParams: {
...@@ -445,9 +453,9 @@ export default { ...@@ -445,9 +453,9 @@ export default {
page: { page: {
total: 20, total: 20,
count: 0, count: 0,
page: 1 page: 1,
} },
} },
}; };
}, },
computed: { computed: {
...@@ -466,7 +474,7 @@ export default { ...@@ -466,7 +474,7 @@ export default {
this.groupSearchParams.page.count / this.groupSearchParams.page.total this.groupSearchParams.page.count / this.groupSearchParams.page.total
) + 1 ) + 1
); );
} },
}, },
methods: { methods: {
getUser() { getUser() {
...@@ -508,19 +516,19 @@ export default { ...@@ -508,19 +516,19 @@ export default {
this.searchGroup(); this.searchGroup();
}, },
// 用户当期页发生变化 // 用户当期页发生变化
userHandleCurrPageChange: function(val) { userHandleCurrPageChange: function (val) {
this.userSearchParams.page.page = val; this.userSearchParams.page.page = val;
this.searchUser(); this.searchUser();
}, },
// 用户每页展示数量发生变化 // 用户每页展示数量发生变化
userHandleSizeChange: function(val) { userHandleSizeChange: function (val) {
this.userSearchParams.page.total = val; this.userSearchParams.page.total = val;
this.searchUser(); this.searchUser();
}, },
// 获取用户信息 // 获取用户信息
searchUser() { searchUser() {
console.info("搜索用户列表"); console.info("搜索用户列表");
this.$axios.get("/system/users").then(res => { this.$axios.get("/system/users").then((res) => {
console.info(res); console.info(res);
this.userTableData = res.data; this.userTableData = res.data;
}); });
...@@ -543,24 +551,24 @@ export default { ...@@ -543,24 +551,24 @@ export default {
name: "UserPermission", name: "UserPermission",
params: { params: {
id: id, id: id,
rolename: rolename rolename: rolename,
} },
}); });
}, },
// 用户组当前页发生变化 // 用户组当前页发生变化
groupHandleCurrPageChange: function(val) { groupHandleCurrPageChange: function (val) {
this.groupSearchParams.page.page = val; this.groupSearchParams.page.page = val;
this.searchGroup(); this.searchGroup();
}, },
// 用户组每页展示数量发生变化 // 用户组每页展示数量发生变化
groupHandleSizeChange: function(val) { groupHandleSizeChange: function (val) {
this.groupSearchParams.page.total = val; this.groupSearchParams.page.total = val;
this.searchGroup(); this.searchGroup();
}, },
// 获取用户组信息 // 获取用户组信息
searchGroup() { searchGroup() {
this.$axios.get("/system/user-groups").then(res => { this.$axios.get("/system/user-groups").then((res) => {
console.info(res); console.info(res);
this.groupTableData = res.data; this.groupTableData = res.data;
}); });
...@@ -582,8 +590,8 @@ export default { ...@@ -582,8 +590,8 @@ export default {
this.$router.push({ this.$router.push({
name: "GroupPermission", name: "GroupPermission",
params: { params: {
id: id id: id,
} },
}); });
}, },
...@@ -606,11 +614,11 @@ export default { ...@@ -606,11 +614,11 @@ export default {
// roleId;/必填 // roleId;/必填
this.$axios this.$axios
.post("/login/permission/add", permission) .post("/login/permission/add", permission)
.then(res => { .then((res) => {
console.log(res); console.log(res);
this.$message.success(res.message); this.$message.success(res.message);
}) })
.catch(failResponse => {}); .catch((failResponse) => {});
}, },
// 删除权限 // 删除权限
del() { del() {
...@@ -618,11 +626,11 @@ export default { ...@@ -618,11 +626,11 @@ export default {
permission.append("menuId", "888"); permission.append("menuId", "888");
this.$axios this.$axios
.post("/login/permission/deletePermissionById", permission) .post("/login/permission/deletePermissionById", permission)
.then(res => { .then((res) => {
console.log(res); console.log(res);
this.$message.success(res.message); this.$message.success(res.message);
}) })
.catch(failResponse => {}); .catch((failResponse) => {});
}, },
// 编辑权限 // 编辑权限
edit() { edit() {
...@@ -630,10 +638,10 @@ export default { ...@@ -630,10 +638,10 @@ export default {
permission.append("menuId", "777"); permission.append("menuId", "777");
this.$axios this.$axios
.post("/login/permission/querypermissionInfo", permission) .post("/login/permission/querypermissionInfo", permission)
.then(res => { .then((res) => {
console.log(res); console.log(res);
}) })
.catch(failResponse => {}); .catch((failResponse) => {});
// menuId;//权限id // menuId;//权限id
// menuname;//菜单名称 // menuname;//菜单名称
// pid;//父级权限id // pid;//父级权限id
...@@ -649,10 +657,10 @@ export default { ...@@ -649,10 +657,10 @@ export default {
permission1.append("menuname", "修改菜单名字"); permission1.append("menuname", "修改菜单名字");
this.$axios this.$axios
.post("/login/permission/update", permission1) .post("/login/permission/update", permission1)
.then(res => { .then((res) => {
console.log(res); console.log(res);
}) })
.catch(failResponse => {}); .catch((failResponse) => {});
}, },
// 刷新 // 刷新
search() { search() {
...@@ -664,22 +672,27 @@ export default { ...@@ -664,22 +672,27 @@ export default {
permission.append("total", "20"); //必填 permission.append("total", "20"); //必填
this.$axios this.$axios
.post("/login/permission/querypermissionAll", permission) .post("/login/permission/querypermissionAll", permission)
.then(res => { .then((res) => {
console.log(res); console.log(res);
this.$message.success(res.message); this.$message.success(res.message);
}) })
.catch(failResponse => {}); .catch((failResponse) => {});
} },
}, },
mounted() { mounted() {
this.isUser = true; this.isUser = true;
if (this.isUser) { if (this.isUser) {
this.searchUser(); this.searchUser();
} }
} },
}; };
</script> </script>
<style lang="css">
.el-tooltip__popper {
font-size: 14px;
max-width: 50%;
}
</style>
<style scoped lang="scss"> <style scoped lang="scss">
@import "scss/permission"; @import "scss/permission";
</style> </style>
<template> <template>
<el-container class="manage-page" direction="vertical"> <el-container class="manage-page" direction="vertical">
<div class="sider"> <div class="sider" @click="resetEdit('screen')">
<div class="btns"> <div class="btns">
<div class="add" @click="add"> <div class="add" @click.stop="add">
<svg-icon <svg-icon
style=" style="
width: 0.8125rem; width: 0.8125rem;
...@@ -73,6 +73,7 @@ ...@@ -73,6 +73,7 @@
>1</el-checkbox >1</el-checkbox
> >
<div <div
@click.stop="() => {}"
:class="{ :class="{
'diy-role-item': true, 'diy-role-item': true,
active: item.id === diyRoleItemIndex, active: item.id === diyRoleItemIndex,
...@@ -96,8 +97,15 @@ ...@@ -96,8 +97,15 @@
<img <img
class="img" class="img"
:src="editurl" :src="editurl"
v-if="!item.edit"
@click.stop="editDiyRoleItem(item)" @click.stop="editDiyRoleItem(item)"
/> />
<img
class="img"
v-else
src="~@/assets/img/duigou.png"
@click.stop="editName(item)"
/>
</div> </div>
</div> </div>
</div> </div>
...@@ -105,7 +113,7 @@ ...@@ -105,7 +113,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="main"> <div class="main" @click="resetEdit('screen')">
<div class="header"> <div class="header">
<div class="btns"> <div class="btns">
<div class="btn" :class="{ active: funFlag }" @click="funAuth"> <div class="btn" :class="{ active: funFlag }" @click="funAuth">
...@@ -300,9 +308,20 @@ export default { ...@@ -300,9 +308,20 @@ export default {
roleMenusSelection: function (val) { roleMenusSelection: function (val) {
console.info(val); console.info(val);
}, },
diyRoleItemIndex: {
handler(val, oldval) {
this.oldCurrtId = oldval;
let arr = [...this.diyRoleList, ...this.defaultRoleBtns];
let obj = arr.find((i) => i.id == val);
this.checkItem = JSON.parse(JSON.stringify(obj));
console.log(this.checkItem);
},
},
// checkItem: null
btnType: { btnType: {
immediate: true, immediate: true,
handler(val) { handler(val, oldval) {
this.oldBtnType = oldval;
if (val == "default") { if (val == "default") {
this.disabled = true; this.disabled = true;
} else { } else {
...@@ -341,6 +360,12 @@ export default { ...@@ -341,6 +360,12 @@ export default {
btnCheckList: [], btnCheckList: [],
//手动新添加的用户集合 //手动新添加的用户集合
customAddUser: [], customAddUser: [],
//点击后的对象信息
checkItem: null,
//上一次选中的对象id
oldCurrtId: null,
//上一次选中的对象类型
oldBtnType: null,
}; };
}, },
methods: { methods: {
...@@ -490,9 +515,12 @@ export default { ...@@ -490,9 +515,12 @@ export default {
this.checkList = []; this.checkList = [];
} }
}); });
let arr = [...this.diyRoleList, ...this.defaultRoleBtns];
let obj = arr.find((i) => i.id == this.diyRoleItemIndex);
this.checkItem = JSON.parse(JSON.stringify(obj));
console.info("角色权限===》", this.defaultRoleBtns); console.info("角色权限===》", this.defaultRoleBtns);
console.info("角色权限===》", this.diyRoleList); console.info("角色权限===》", this.diyRoleList);
console.info("选中的角色信息", this.checkItem);
} else { } else {
this.$message.error("获取角色信息失败!"); this.$message.error("获取角色信息失败!");
} }
...@@ -529,6 +557,20 @@ export default { ...@@ -529,6 +557,20 @@ export default {
this.$refs.diyRoles.scrollTop = this.$refs.diyRoles.scrollHeight; this.$refs.diyRoles.scrollTop = this.$refs.diyRoles.scrollHeight;
}, 20); }, 20);
}, },
//查看用户组的信息
viewGroupItem(id) {
let arr = [...this.diyRoleList, ...this.defaultRoleBtns];
let obj = arr.find((i) => i.id == id);
return JSON.parse(JSON.stringify(obj));
},
//修改名
editName(item) {
let edit;
let index = this.diyRoleList.findIndex((i) => i.id == item.id);
if (!item.edit && typeof item.edit != Boolean) edit = false;
edit = !item.edit;
this.$set(this.diyRoleList[index], "edit", edit);
},
// 编辑 // 编辑
edit() { edit() {
console.info("编辑数据"); console.info("编辑数据");
...@@ -567,7 +609,10 @@ export default { ...@@ -567,7 +609,10 @@ export default {
this.viewSelect(item); this.viewSelect(item);
}, },
//重置编辑状态 //重置编辑状态
resetEdit() { resetEdit(type) {
if (type == "screen") {
}
let newArr = this.diyRoleList.map((i) => { let newArr = this.diyRoleList.map((i) => {
i.edit = false; i.edit = false;
return i; return i;
......
...@@ -106,7 +106,12 @@ ...@@ -106,7 +106,12 @@
</el-table-column> </el-table-column>
<el-table-column prop="policeNumber" label="警号" :width="width2"> <el-table-column prop="policeNumber" label="警号" :width="width2">
</el-table-column> </el-table-column>
<el-table-column prop="userGroupNames" label="用户组" :width="width3"> <el-table-column
prop="userGroupNames"
label="用户组"
show-overflow-tooltip
:width="width3"
>
</el-table-column> </el-table-column>
<el-table-column prop="unitName" label="所属单位" :width="width5"> <el-table-column prop="unitName" label="所属单位" :width="width5">
</el-table-column> </el-table-column>
...@@ -121,6 +126,7 @@ ...@@ -121,6 +126,7 @@
class="tags" class="tags"
v-for="item in scope.row.roleNames && v-for="item in scope.row.roleNames &&
scope.row.roleNames.split(',')" scope.row.roleNames.split(',')"
:key="item"
> >
{{ item }} {{ item }}
</div> </div>
...@@ -136,6 +142,7 @@ ...@@ -136,6 +142,7 @@
<div <div
v-for="(item, index) in scope.row.permissionNames && v-for="(item, index) in scope.row.permissionNames &&
scope.row.permissionNames.split(',')" scope.row.permissionNames.split(',')"
:key="index"
> >
{{ index > 0 ? "/" : "" }} {{ index > 0 ? "/" : "" }}
{{ item }} {{ item }}
...@@ -430,7 +437,7 @@ export default { ...@@ -430,7 +437,7 @@ export default {
if (value === "") { if (value === "") {
callback(new Error("请输入用户名!")); callback(new Error("请输入用户名!"));
} else { } else {
if (/[\u4e00-\u9fa5]+/g.test(value) || value.length >= 8) { if (/[\u4e00-\u9fa5]+/g.test(value) || value.length > 8) {
callback(new Error("用户名不可为汉字字符,最长8位!")); callback(new Error("用户名不可为汉字字符,最长8位!"));
} else { } else {
callback(); callback();
...@@ -490,7 +497,7 @@ export default { ...@@ -490,7 +497,7 @@ export default {
if (value === "") { if (value === "") {
callback(new Error("请输入密码!")); callback(new Error("请输入密码!"));
} else { } else {
if (value.length >= 8) { if (value.length > 8) {
callback(new Error("密码长度需在8位数以内!")); callback(new Error("密码长度需在8位数以内!"));
} else { } else {
callback(); callback();
...@@ -574,7 +581,7 @@ export default { ...@@ -574,7 +581,7 @@ export default {
{ validator: validateTruename, trigger: "blur", required: true }, { validator: validateTruename, trigger: "blur", required: true },
], //用户真实姓名 ], //用户真实姓名
policeNumber: [ policeNumber: [
{ validator: validatePolicemanid, trigger: "blur", required: true }, { validator: validatePolicemanid, trigger: "blur", required: false },
], //警号 ], //警号
phoneNumber: [ phoneNumber: [
{ validator: validateTelphone, trigger: "blur", required: true }, { validator: validateTelphone, trigger: "blur", required: true },
...@@ -967,6 +974,12 @@ const data1 = [ ...@@ -967,6 +974,12 @@ const data1 = [
}, },
]; ];
</script> </script>
<style lang="css">
.el-tooltip__popper {
font-size: 14px;
max-width: 50%;
}
</style>
<style scoped lang="scss"> <style scoped lang="scss">
.delSelection /deep/ .el-table-column--selection .cell { .delSelection /deep/ .el-table-column--selection .cell {
display: none; display: none;
...@@ -981,6 +994,7 @@ const data1 = [ ...@@ -981,6 +994,7 @@ const data1 = [
.info { .info {
margin-top: 0px !important; margin-top: 0px !important;
} }
@import "scss/user"; @import "scss/user";
@import "./scss/dialog_table"; @import "./scss/dialog_table";
</style> </style>
...@@ -567,7 +567,7 @@ ...@@ -567,7 +567,7 @@
left: calc(50% - 471.5px); left: calc(50% - 471.5px);
z-index: 1000; z-index: 1000;
width: 626px; width: 626px;
height: 440px; padding-bottom: 20px;
background: #ffffff; background: #ffffff;
box-shadow: 0px 14px 30px 0px rgba(0, 21, 51, 0.25); box-shadow: 0px 14px 30px 0px rgba(0, 21, 51, 0.25);
border-radius: 6px; border-radius: 6px;
...@@ -609,7 +609,8 @@ ...@@ -609,7 +609,8 @@
//border: saddlebrown 1px solid; //border: saddlebrown 1px solid;
.default-role-group { .default-role-group {
width: 578px; width: 578px;
height: auto; max-height: 125px;
overflow: auto;
background: #fdfeff; background: #fdfeff;
box-shadow: 1px 0px 3px 0px rgba(5, 95, 231, 0.3), -1px 1px 3px 0px rgba(5, 95, 231, 0.24); box-shadow: 1px 0px 3px 0px rgba(5, 95, 231, 0.3), -1px 1px 3px 0px rgba(5, 95, 231, 0.24);
border-radius: 4px; border-radius: 4px;
...@@ -620,6 +621,7 @@ ...@@ -620,6 +621,7 @@
flex-wrap: wrap; flex-wrap: wrap;
.default-btn { .default-btn {
position: relative; position: relative;
margin: 5px 0;
width: 160px; width: 160px;
height: 32px; height: 32px;
background: #f6f8fa; background: #f6f8fa;
...@@ -660,8 +662,9 @@ ...@@ -660,8 +662,9 @@
margin: 16px 0 16px 0; margin: 16px 0 16px 0;
} }
.add-role-group { .add-role-group {
overflow: auto;
width: 578px; width: 578px;
height: 111px; height: 150px;
background: #f6f8fa; background: #f6f8fa;
box-shadow: 1px 0px 3px 0px rgba(5, 95, 231, 0.3), -1px 1px 3px 0px rgba(5, 95, 231, 0.24); box-shadow: 1px 0px 3px 0px rgba(5, 95, 231, 0.3), -1px 1px 3px 0px rgba(5, 95, 231, 0.24);
border-radius: 4px; border-radius: 4px;
......
...@@ -177,17 +177,17 @@ $phone: var(--phone, #606266); //#ff4242; ...@@ -177,17 +177,17 @@ $phone: var(--phone, #606266); //#ff4242;
} }
} }
.bz-src-item{ .bz-src-item {
width: 333px; width: 333px;
height: 150px; height: 150px;
.img{ .img {
border: 1px #CCCCCC solid; border: 1px #cccccc solid;
width: 105px; width: 105px;
height: 150px; height: 150px;
position: relative; position: relative;
top: -105px; top: -105px;
margin-right: 5px; margin-right: 5px;
.title{ .title {
text-align: center; text-align: center;
position: relative; position: relative;
bottom: -100px; bottom: -100px;
...@@ -195,24 +195,25 @@ $phone: var(--phone, #606266); //#ff4242; ...@@ -195,24 +195,25 @@ $phone: var(--phone, #606266); //#ff4242;
width: 104px; width: 104px;
height: 20px; height: 20px;
background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #000000 100%); background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #000000 100%);
color: #FFFFFF; color: #ffffff;
font-size: 12px; font-size: 12px;
line-height: 20px; line-height: 20px;
z-index: 100; z-index: 100;
} }
} }
.item{ .item {
height: 150px; height: 150px;
width: 220px; width: 220px;
font-size: 14px; font-size: 14px;
.title{ .title {
color: #999999; color: #999999;
height:22px ; height: 22px;
width: 180px; width: 180px;
height: 22px; height: 22px;
} }
.value{ .value {
color: #333333; height:22px ; color: #333333;
height: 22px;
width: 180px; width: 180px;
height: 22px; height: 22px;
} }
...@@ -347,21 +348,29 @@ $phone: var(--phone, #606266); //#ff4242; ...@@ -347,21 +348,29 @@ $phone: var(--phone, #606266); //#ff4242;
} }
.finger { .finger {
box-sizing: border-box; box-sizing: border-box;
border: #001e33 1px solid; border-radius: 8px;
border: 1px solid #cccccc;
background: #ffffff;
box-shadow: 0px 14px 30px 2px rgba(0, 21, 51, 0.16);
width: calc(50vh - 35px); width: calc(50vh - 35px);
height: calc(50vh - 35px);; height: calc(50vh - 35px);
margin-bottom: 20px; margin-bottom: 20px;
// .wtx { position: relative;
// position: absolute; .wtx {
// width: 75%; position: absolute;
// left: 50%; width: 100%;
// top: 45%; top: 50%;
// transform: translate(-50%, -50%); left: 50%;
// > span { transform: translateY(-50%) translateX(-50%);
// display: inline-block; }
// margin-top: 20px; img {
// font-size: 14px; width: 100% !important;
// color: #cccccc; }
// } span {
//} font-size: 17px;
}} }
}
}
.bzActive {
filter: blur(2px);
}
...@@ -393,10 +393,10 @@ ...@@ -393,10 +393,10 @@
:modal-append-to-body="false" :modal-append-to-body="false"
> >
<div v-if="showProgress"> <div v-if="showProgress">
<!-- <el-progress <el-progress
type="circle" type="circle"
:percentage="UploadPercent" :percentage="UploadPercent"
></el-progress> --> ></el-progress>
<div style="margin-top:.9375rem; margin-bottom:.9375rem;font-size: .875rem;font-family: MicrosoftYaHei;color: #909090;">正在解析指纹文件,点击“取消”可终止处理</div> <div style="margin-top:.9375rem; margin-bottom:.9375rem;font-size: .875rem;font-family: MicrosoftYaHei;color: #909090;">正在解析指纹文件,点击“取消”可终止处理</div>
<el-button @click="abort">取 消</el-button> <el-button @click="abort">取 消</el-button>
</div> </div>
...@@ -440,8 +440,8 @@ export default { ...@@ -440,8 +440,8 @@ export default {
fptxWidth3: 100, fptxWidth3: 100,
action: '', action: '',
fileList: [], fileList: [],
UploadPercent: null, UploadPercent: 0,
percentage: null, percentage: 0,
dialogVisible: false, // 进度条弹窗 dialogVisible: false, // 进度条弹窗
showProgress: true, // 进度条(正在导入) showProgress: true, // 进度条(正在导入)
drlx: 3, // 导入类型 drlx: 3, // 导入类型
...@@ -562,7 +562,7 @@ export default { ...@@ -562,7 +562,7 @@ export default {
// console.log(event) // console.log(event)
this.dialogVisible = true; this.dialogVisible = true;
// this.UploadPercent = Number(file.percentage.toFixed(0)); // this.UploadPercent = Number(file.percentage.toFixed(0));
this.UploadPercent = Number(event.percent.toFixed()) // this.UploadPercent = Number(event.percent.toFixed())
// if (this.UploadPercent == 99) { // if (this.UploadPercent == 99) {
// // this.dialogVisible = false; // // this.dialogVisible = false;
// // this.$refs.upload.clearFiles() // // this.$refs.upload.clearFiles()
...@@ -678,6 +678,7 @@ export default { ...@@ -678,6 +678,7 @@ export default {
}, },
// 上传 // 上传
submitUpload () { submitUpload () {
let that = this
if (this.nowSelectRightData.length == 0) { if (this.nowSelectRightData.length == 0) {
this.$message.error('请选择要上传的文件') this.$message.error('请选择要上传的文件')
} else { } else {
...@@ -701,7 +702,15 @@ export default { ...@@ -701,7 +702,15 @@ export default {
method: 'post', method: 'post',
url: this.action, url: this.action,
data: formData, data: formData,
loading: false loading: false,
onUploadProgress: function (progressEvent) {
// this.dialogVisible = true;
console.log(progressEvent, 1);
that.UploadPercent = ((progressEvent.loaded / 10 * 9.9) / progressEvent.total).toFixed(2) * 100
console.log(that.UploadPercent, 123)
// Number(event.percent.toFixed())
},
}).then(res => { }).then(res => {
if (res.data.code === 0) { if (res.data.code === 0) {
// this.tableDate = response.data.ret.list; // this.tableDate = response.data.ret.list;
......
...@@ -258,13 +258,46 @@ ...@@ -258,13 +258,46 @@
<el-table-column <el-table-column
prop="taskNumber" prop="taskNumber"
label="任务号" label="任务号"
width="220" width="300"
> >
<template slot-scope="scope">
<svg-icon
style="
width: 0.875rem;
height: 0.6875rem;
margin-bottom: 0.125rem;
margin-left: 0.3125rem;
"
v-if="scope.row.pcImportRecordGrandchildren || scope.row.pcImportRecordGrandchildren === null"
icon-class="tree_f"
>
</svg-icon>
<svg-icon
style="
width: 0.8125rem;
height: 0.375rem;
margin: 0 0 0.1875rem 0;
"
v-else-if="!scope.row.pcImportRecordGrandchildren || scope.row.pcImportRecordGrandchildren !== null"
icon-class="tree_c"
></svg-icon>
{{
scope.row.pcImportRecordGrandchildren || scope.row.pcImportRecordGrandchildren === null
? scope.row.taskNumber
: scope.row.taskNumber
}}
<div
v-show="scope.row.pcImportRecordGrandchildren && scope.row.pcImportRecordGrandchildren !== null"
class="children-count"
>
{{ scope.row.pcImportRecordGrandchildren ? scope.row.pcImportRecordGrandchildren.length : 0 }}
</div>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="fileName" prop="fileName"
label="文件名" label="文件名"
width="300" width="320"
show-overflow-tooltip show-overflow-tooltip
> >
</el-table-column> </el-table-column>
...@@ -275,19 +308,19 @@ ...@@ -275,19 +308,19 @@
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="dataType" prop="dataTypeName"
label="类型" label="类型"
width="200" width="100"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="logicDatabase" prop="logicDatabase"
label="逻辑分库" label="逻辑分库"
width="200" width="100"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="status" prop="statusName"
label="状态" label="状态"
width="auto" width="auto"
> >
...@@ -295,7 +328,7 @@ ...@@ -295,7 +328,7 @@
<el-table-column <el-table-column
fixed="right" fixed="right"
label="操作" label="操作"
width="200" width="auto"
> >
<template slot-scope="scope"> <template slot-scope="scope">
<div class="ops"> <div class="ops">
...@@ -380,8 +413,41 @@ ...@@ -380,8 +413,41 @@
<el-table-column <el-table-column
prop="taskNumber" prop="taskNumber"
label="任务号" label="任务号"
width="220" width="300"
> >
<template slot-scope="scope">
<svg-icon
style="
width: 0.875rem;
height: 0.6875rem;
margin-bottom: 0.125rem;
margin-left: 0.3125rem;
"
v-if="scope.row.affirmImportRecordGrandchildren || scope.row.affirmImportRecordGrandchildren === null"
icon-class="tree_f"
>
</svg-icon>
<svg-icon
style="
width: 0.8125rem;
height: 0.375rem;
margin: 0 0 0.1875rem 0;
"
v-else-if="!scope.row.affirmImportRecordGrandchildren || scope.row.affirmImportRecordGrandchildren !== null"
icon-class="tree_c"
></svg-icon>
{{
scope.row.affirmImportRecordGrandchildren || scope.row.affirmImportRecordGrandchildren === null
? scope.row.taskNumber
: scope.row.taskNumber
}}
<div
v-show="scope.row.affirmImportRecordGrandchildren && scope.row.affirmImportRecordGrandchildren !== null"
class="children-count"
>
{{ scope.row.affirmImportRecordGrandchildren ? scope.row.affirmImportRecordGrandchildren.length : 0 }}
</div>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="fileName" prop="fileName"
...@@ -391,7 +457,7 @@ ...@@ -391,7 +457,7 @@
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="queryType" prop="dataTypeName"
label="查询类型" label="查询类型"
width="200" width="200"
> >
...@@ -409,11 +475,11 @@ ...@@ -409,11 +475,11 @@
<el-table-column <el-table-column
prop="logicDatabase" prop="logicDatabase"
label="逻辑分库" label="逻辑分库"
width="200" width="100"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="status" prop="statusName"
label="状态" label="状态"
width="auto" width="auto"
> >
...@@ -421,7 +487,7 @@ ...@@ -421,7 +487,7 @@
<el-table-column <el-table-column
fixed="right" fixed="right"
label="操作" label="操作"
width="200" width="auto"
> >
<template slot-scope="scope"> <template slot-scope="scope">
<div class="ops"> <div class="ops">
...@@ -542,6 +608,8 @@ ...@@ -542,6 +608,8 @@
</div> </div>
</template> </template>
<script> <script>
import "@/icons/tree_f.svg";
import "@/icons/tree_c.svg";
import tjddl from "../AllPersonnelBase/modules/tjddl.vue"; // 添加到队列弹窗 import tjddl from "../AllPersonnelBase/modules/tjddl.vue"; // 添加到队列弹窗
import fztm from "../AllPersonnelBase/modules/fztm.vue"; // 复制数据弹窗 import fztm from "../AllPersonnelBase/modules/fztm.vue"; // 复制数据弹窗
import fcx from "../AllPersonnelBase/modules/fcx.vue"; // 发查询弹窗 import fcx from "../AllPersonnelBase/modules/fcx.vue"; // 发查询弹窗
...@@ -1237,3 +1305,87 @@ export default { ...@@ -1237,3 +1305,87 @@ export default {
color: #333333; color: #333333;
} }
</style> </style>
<!--table树-->
<style scoped lang="scss">
.children-count {
width: 34px;
font-size: 12px;
text-align: center;
background: #f6f8fa;
border-radius: 11px;
position: absolute;
right: 10px;
top: 25%;
}
.el-tree /deep/ .el-tree-node__expand-icon.expanded {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
/*有子节点 且未展开*/
.el-table /deep/ .el-icon-arrow-right:before {
// background: url("../../icons/tree_f.svg") no-repeat 0 3px;
content: "";
display: block;
width: 16px;
height: 16px;
font-size: 16px;
background-size: 16px;
}
/*有子节点 且已展开*/
.el-table /deep/ .el-table__expand-icon--expanded {
.el-icon-arrow-right:before {
// background: url("../../icons/tree_c.svg") no-repeat 0 3px;
content: "";
display: block;
width: 15px;
height: 20px;
font-size: 18px;
background-size: 21px;
}
}
/*没有子节点*/
.el-tree
/deep/
.el-tree-node__expand-icon.is-leaf::before
.el-table
/deep/
.el-table__placeholder::before {
// background: url("../../icons/tree_f.svg") no-repeat 0 3px;
content: "";
display: block;
width: 16px;
height: 18px;
font-size: 16px;
background-size: 16px;
}
/deep/.el-table--enable-row-hover .el-table__body tr:hover {
cursor: pointer;
}
</style>
<style lang="scss" >
.el-table__expand-icon {
position: absolute;
right: 45px;
cursor: pointer;
color: #b51f1f;
transition: transform 0.2s ease-in-out;
width: 11px;
height: 11px;
/* border: black 1px solid; */
margin: 0;
background-image: url("../../assets/img/confirm/expend.png");
background-position: center;
background-size: 11px;
background-repeat: no-repeat;
}
.el-table__expand-icon.el-table__expand-icon--expanded {
width: 11px;
height: 11px;
background-image: url("../../assets/img/confirm/shrink.png");
background-position: center;
background-size: 11px;
background-repeat: no-repeat;
transform: rotate(180deg) !important;
}
</style>
/* /*
* @Author: your name * @Author: your name
* @Date: 2021-09-07 09:57:48 * @Date: 2021-09-07 09:57:48
* @LastEditTime: 2021-11-15 21:11:13 * @LastEditTime: 2021-11-17 14:02:53
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: \指纹系统\founder_vue\vue.config.js * @FilePath: \指纹系统\founder_vue\vue.config.js
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment