|
|
@ -3,9 +3,9 @@ |
|
|
|
<div class="header"> |
|
|
|
<p class="title"><img src="../../assets/loginImg/logo.png"/>安瑞集团信息化平台</p> |
|
|
|
<div class="head_info"> |
|
|
|
<!-- <p>{{Orgname}},</p>--> |
|
|
|
<!-- <p>{{Orgname}},</p>--> |
|
|
|
<!--<p>{{$store.getters.userInfo.Orgname}}</p>--> |
|
|
|
<p>欢迎您,{{pNameAndDepartmentNameAndPostName}} {{ roleName }} {{name}}</p> |
|
|
|
<p>欢迎您,{{ pNameAndDepartmentNameAndPostName }} {{ roleName }} {{ name }}</p> |
|
|
|
<!--<img src="@/assets/images/info.png" />--> |
|
|
|
<p @click="logout()" class="dy"><img src="@/assets/images/dy.png"/></p> |
|
|
|
</div> |
|
|
@ -16,7 +16,7 @@ |
|
|
|
<ul class="grid-content bg-ltop"> |
|
|
|
<li @click="todowork"> |
|
|
|
<div style="position: relative"> |
|
|
|
<el-badge v-if="shuliang.workCount !== 0" :value="shuliang.workCount" size="mini" class="mark" /> |
|
|
|
<el-badge v-if="shuliang.workCount !== 0" :value="shuliang.workCount" size="mini" class="mark"/> |
|
|
|
<img src="@/assets/home/ltIcon1.png"> |
|
|
|
</div> |
|
|
|
<p>待办工作</p> |
|
|
@ -72,7 +72,7 @@ |
|
|
|
<ul class="bg-bottom"> |
|
|
|
<li @click="toNav(index)" v-for="(item,index) in menus" :key='index'> |
|
|
|
<img :src="item.imgUrl"> |
|
|
|
<p>{{item.title}}</p> |
|
|
|
<p>{{ item.title }}</p> |
|
|
|
</li> |
|
|
|
</ul> |
|
|
|
<p class="copy">Copyright © {{ year }} 安瑞集团 All Rights Reserved</p> |
|
|
@ -162,16 +162,48 @@ |
|
|
|
<p>系统管理</p> |
|
|
|
</li> --> |
|
|
|
<!--</ul>--> |
|
|
|
<el-dialog center :visible.sync="dialogVisible" width="40%" :show-close="false" :close-on-click-modal="false"> |
|
|
|
<el-form :model="form" class="formadd"> |
|
|
|
<el-row style="border-top: 1px solid #e0e3eb"> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>原密码</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="20"> |
|
|
|
<el-form-item><el-input v-model="form.original" type="password" show-password/></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>新密码</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="20"> |
|
|
|
<el-form-item><el-input v-model="form.password" type="password" show-password/></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>确认密码</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="20"> |
|
|
|
<el-form-item><el-input v-model="form.confirmPassword" type="password" show-password/></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
</el-form> |
|
|
|
<div slot="footer" class="dialog-footer"> |
|
|
|
<el-button type="primary" size="small" @click="handleConirm">确 定</el-button> |
|
|
|
<el-button size="small" @click="handleQuXiao">取 消</el-button> |
|
|
|
</div> |
|
|
|
</el-dialog> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import {getToken, removeToken, getStorage, removeStorage} from '@/utils/auth' |
|
|
|
import {sourcesofrole} from '@/api/system/Role/role.js' |
|
|
|
import User from '@/api/User/login.js' |
|
|
|
import { getTodoNum } from '@/api/system/home/home' |
|
|
|
import { getToken, removeToken, getStorage, removeStorage } from '@/utils/auth' |
|
|
|
import {sourcesofrole} from '@/api/system/Role/role.js' |
|
|
|
import User from '@/api/User/login.js' |
|
|
|
import { getTodoNum } from '@/api/system/home/home' |
|
|
|
|
|
|
|
export default { |
|
|
|
export default { |
|
|
|
data() { |
|
|
|
return { |
|
|
|
menus: [{ |
|
|
@ -209,6 +241,13 @@ |
|
|
|
shuliang: { |
|
|
|
workCount: '' |
|
|
|
}, |
|
|
|
dialogVisible: false, |
|
|
|
form: { |
|
|
|
original: '', |
|
|
|
password: '', |
|
|
|
confirmPassword: '', |
|
|
|
userSid: '' |
|
|
|
}, |
|
|
|
timer: '', |
|
|
|
Orgname: '', |
|
|
|
departmentName: '', |
|
|
@ -222,8 +261,7 @@ |
|
|
|
|
|
|
|
}, |
|
|
|
created() { |
|
|
|
this.getNum() |
|
|
|
this.timer = setInterval(this.getNum, 20000) |
|
|
|
this.getsPasswordByUserSid() |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
this.Orgname = window.sessionStorage.getItem('Orgname') |
|
|
@ -238,6 +276,16 @@ |
|
|
|
// }) |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
getsPasswordByUserSid() { |
|
|
|
User.selectPasswordByUserSid(window.sessionStorage.getItem('userSid')).then((resp) => { |
|
|
|
if (resp.success && resp.data) { |
|
|
|
this.dialogVisible = true |
|
|
|
} else { |
|
|
|
this.getNum() |
|
|
|
this.timer = setInterval(this.getNum, 20000) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
getNum() { |
|
|
|
getTodoNum(window.sessionStorage.getItem('userSid')).then((resp) => { |
|
|
|
if (resp.success) { |
|
|
@ -245,6 +293,42 @@ |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
handleConirm() { |
|
|
|
if (this.form.original === '') { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '原密码不能为空' }) |
|
|
|
return |
|
|
|
} |
|
|
|
if (this.form.password !== this.form.confirmPassword) { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '两次输入密码不一致' }) |
|
|
|
return |
|
|
|
} |
|
|
|
this.form.userSid = window.sessionStorage.getItem('userSid') |
|
|
|
User.updatePassword(this.form).then((resp) => { |
|
|
|
if (resp.success) { |
|
|
|
this.$alert('密码修改成功!请重新登录点击确定后退出。', '修改成功', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
callback: action => { |
|
|
|
this.handleQuXiao() |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
handleQuXiao() { |
|
|
|
this.dialogVisible = false |
|
|
|
this.form = { |
|
|
|
original: '', |
|
|
|
password: '', |
|
|
|
confirmPassword: '' |
|
|
|
} |
|
|
|
User.logout({ token: getStorage() }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
removeStorage() |
|
|
|
this.$store.commit('user/SET_UESRINFO', '') |
|
|
|
this.$router.push({ path: '/login' }) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
todowork() { |
|
|
|
window.open('/#/todo' + '?token=' + getStorage(), '_blank') |
|
|
|
// this.$router.push({ path: '/todo' + '?token=' + getStorage() }) |
|
|
@ -261,7 +345,7 @@ |
|
|
|
cancelButtonText: '取消', |
|
|
|
type: 'warning' |
|
|
|
}).then(() => { |
|
|
|
User.logout({ token: getStorage() }).then(res => { |
|
|
|
User.logout({token: getStorage()}).then(res => { |
|
|
|
removeStorage() |
|
|
|
this.$store.commit('user/SET_UESRINFO', '') |
|
|
|
this.$router.push({ path: '/login' }) |
|
|
@ -285,7 +369,7 @@ |
|
|
|
} else if (index == '8') { |
|
|
|
let myPopup = window.open('http://120.46.172.184/message/#/' + '?token=' + getStorage(), '_blank') |
|
|
|
} else if (index == '1') { |
|
|
|
let myPopup = window.open('http://120.46.172.184/scm/#/' + '?token=' + getStorage(), '_blank') |
|
|
|
let myPopup = window.open('http://anrui.yyundong.com/scm/#/' + '?token=' + getStorage(), '_blank') |
|
|
|
} else if (index == '4') { |
|
|
|
let myPopup = window.open('http://120.46.172.184/fin/#/' + '?token=' + getStorage(), '_blank') |
|
|
|
} else if (index == '5') { |
|
|
@ -300,21 +384,21 @@ |
|
|
|
beforeDestroy() { |
|
|
|
clearInterval(this.timer) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
</script> |
|
|
|
<style scoped="scoped"> |
|
|
|
li:hover, |
|
|
|
p:hover { |
|
|
|
li:hover, |
|
|
|
p:hover { |
|
|
|
cursor: pointer |
|
|
|
} |
|
|
|
} |
|
|
|
</style> |
|
|
|
<style lang="scss" scoped> |
|
|
|
p { |
|
|
|
p { |
|
|
|
margin: 0; |
|
|
|
padding: 0; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.header { |
|
|
|
.header { |
|
|
|
background-color: #0294d7; |
|
|
|
color: #fff; |
|
|
|
overflow: hidden; |
|
|
@ -344,22 +428,22 @@ |
|
|
|
p { |
|
|
|
float: left; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.head_info img { |
|
|
|
.head_info img { |
|
|
|
width: 25px; |
|
|
|
margin-top: 20px; |
|
|
|
margin-left: 30px; |
|
|
|
margin-right: 10px; |
|
|
|
float: left; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.head_info .dy { |
|
|
|
.head_info .dy { |
|
|
|
margin-left: 10px; |
|
|
|
margin-right: 20px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.container1 { |
|
|
|
.container1 { |
|
|
|
background: #E9F1F7; |
|
|
|
padding: 20px; |
|
|
|
width: 100%; |
|
|
@ -476,9 +560,9 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.copy { |
|
|
|
.copy { |
|
|
|
position: fixed; |
|
|
|
bottom: 0; |
|
|
|
width: calc(100% - 40px); |
|
|
@ -489,15 +573,17 @@ |
|
|
|
background: #E9F1F7; |
|
|
|
font-size: 14px; |
|
|
|
color: #666; |
|
|
|
} |
|
|
|
.mark { |
|
|
|
} |
|
|
|
|
|
|
|
.mark { |
|
|
|
position: absolute; |
|
|
|
top: 38%; |
|
|
|
margin-left: 58px; |
|
|
|
} |
|
|
|
.mark { |
|
|
|
} |
|
|
|
|
|
|
|
.mark { |
|
|
|
::v-deep .el-badge__content { |
|
|
|
font-size: 14px !important; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
</style> |
|
|
|