Commit 69e60f0c authored by xulili's avatar xulili

我的消息

parent f309e747
...@@ -3,17 +3,17 @@ ...@@ -3,17 +3,17 @@
*/ */
import requestAPI from '@/utils/bRequest' import requestAPI from '@/utils/bRequest'
export function getMessageByClerkId(params) { export function getMessageByUserId(params) {
return requestAPI({ return requestAPI({
url: '/admin/auth/marketing/getMessageByClerkId', url: '/admin/auth/marketing/getMessageByUserId',
method: 'get', method: 'get',
params params
}) })
} }
export function getClerkInfoBySupervisorId(params) { export function getClerkInfoBySupervisorUserId(params) {
return requestAPI({ return requestAPI({
url: '/admin/auth/addressbook/clerk/getClerkInfoBySupervisorId', url: '/admin/auth/addressbook/clerk/getClerkInfoBySupervisorUserId',
method: 'get', method: 'get',
params params
}) })
......
<template> <template>
<div class="main"> <div class="main">
<div class="backgrounds"> <div class="backgrounds">
<img class="background-img" :src="cache.icon.testImg" /> <img class="background-img" :src="avatarUrl"/>
</div> </div>
<div class="infos"> <div class="infos">
<div class="info"> <div class="info">
<div class="info-logos"> <div class="info-logos">
<img class="info-logo" :src="cache.icon.testImg" /> <img class="info-logo" :src="cache.icon.testImg"/>
</div> </div>
<div class="info-msgs"> <div class="info-msgs">
<div class="msg"> <div class="msg">
...@@ -31,11 +31,11 @@ ...@@ -31,11 +31,11 @@
</div> --> </div> -->
<div class="list" @click="listTaskClick"> <div class="list" @click="listTaskClick">
<div class="list-title">任务列表</div> <div class="list-title">任务列表</div>
<img class="list-icon" :src="cache.icon.arrowRightDark" /> <img class="list-icon" :src="cache.icon.arrowRightDark"/>
</div> </div>
<div class="list list-latest"> <div class="list">
<div class="list-title">我的收益</div> <div class="list-title">我的收益</div>
<img class="list-icon" :src="cache.icon.arrowRightDark" /> <img class="list-icon" :src="cache.icon.arrowRightDark"/>
</div> </div>
<div class="list list-latest" @click="handleDetail('message')"> <div class="list list-latest" @click="handleDetail('message')">
<div class="list-title">我的消息</div> <div class="list-title">我的消息</div>
...@@ -45,23 +45,23 @@ ...@@ -45,23 +45,23 @@
<div class="main-menuBar"> <div class="main-menuBar">
<div class="menuBar-menu" @click="menuBarClick('MainSale')"> <div class="menuBar-menu" @click="menuBarClick('MainSale')">
<img class="menuBar-icon" :src="menuBarInfo.icon.now['1']" /> <img class="menuBar-icon" :src="menuBarInfo.icon.now['1']"/>
<div class="menuBar-title">活动</div> <div class="menuBar-title">活动</div>
</div> </div>
<div class="menuBar-menu" @click="menuCase()"> <div class="menuBar-menu" @click="menuCase()">
<img class="menuBar-icon" :src="menuBarInfo.icon.now['2']" /> <img class="menuBar-icon" :src="menuBarInfo.icon.now['2']"/>
<div class="menuBar-title">案例</div> <div class="menuBar-title">案例</div>
</div> </div>
<div class="menuBar-menu" @click="menuProfit()"> <div class="menuBar-menu" @click="menuProfit()">
<img class="menuBar-icon" :src="menuBarInfo.icon.now['3']" /> <img class="menuBar-icon" :src="menuBarInfo.icon.now['3']"/>
<div class="menuBar-title menuBar-title-ac">收益</div> <div class="menuBar-title menuBar-title-ac">收益</div>
</div> </div>
<div class="menuBar-menu" @click="menuTask()"> <div class="menuBar-menu" @click="menuTask()">
<img class="menuBar-icon" :src="menuBarInfo.icon.now['4']" /> <img class="menuBar-icon" :src="menuBarInfo.icon.now['4']"/>
<div class="menuBar-title">任务</div> <div class="menuBar-title">任务</div>
</div> </div>
<div class="menuBar-menu" @click="menuBarClick('Me')"> <div class="menuBar-menu" @click="menuBarClick('Me')">
<img class="menuBar-icon" :src="menuBarInfo.icon.now['5']" /> <img class="menuBar-icon" :src="menuBarInfo.icon.now['5']"/>
<div class="menuBar-title">我的</div> <div class="menuBar-title">我的</div>
</div> </div>
</div> </div>
...@@ -70,13 +70,15 @@ ...@@ -70,13 +70,15 @@
<script> <script>
import {configWx, getUserInfo} from "@/utils/aCommon" import {configWx, getUserInfo} from "@/utils/aCommon"
import { getUserInfoByUserId } from "@/api/sidebar/voucher"; import {getUserInfoByUserId} from "@/api/sidebar/voucher";
import axios from "axios" import axios from "axios"
import { editStore } from "@/api/sidebar/voucher"; import {editStore} from "@/api/sidebar/voucher";
export default { export default {
name: "me", name: "me",
data() { data() {
return { return {
avatarUrl: '',
cache: { cache: {
icon: { icon: {
testImg: "/mainSale/test-city.png", testImg: "/mainSale/test-city.png",
...@@ -130,6 +132,8 @@ ...@@ -130,6 +132,8 @@
}; };
}, },
mounted() { mounted() {
this.avatarUrl = sessionStorage.getItem("avatar")
this.checkNowMenuBar() this.checkNowMenuBar()
}, },
...@@ -146,20 +150,20 @@ ...@@ -146,20 +150,20 @@
this.$router.push("Task"); this.$router.push("Task");
}, },
menuProfit() { menuProfit() {
this.$router.push({ path: "/profitList" }); this.$router.push({path: "/profitList"});
}, },
menuTask() { menuTask() {
this.$router.push({ path: "/taskList" }); this.$router.push({path: "/taskList"});
}, },
menuCase() { menuCase() {
this.$router.push({ path: "/case" }); this.$router.push({path: "/case"});
} }
} }
}; };
</script> </script>
<style scoped> <style scoped>
.main { .main {
/*border: 1px solid red;*/ /*border: 1px solid red;*/
background-color: rgba(248, 248, 248, 1); background-color: rgba(248, 248, 248, 1);
width: 100%; width: 100%;
...@@ -172,28 +176,31 @@ ...@@ -172,28 +176,31 @@
justify-content: start; justify-content: start;
overflow: auto; overflow: auto;
} }
.backgrounds {
.backgrounds {
/*border: 1px solid dodgerblue;*/ /*border: 1px solid dodgerblue;*/
width: 100%; width: 100%;
height: 124px; height: 124px;
overflow: hidden; overflow: hidden;
background-color: rgba(10, 10, 10, 0.5); background-color: rgba(10, 10, 10, 0.5);
} }
.background-img {
.background-img {
width: 100%; width: 100%;
height: 100%; height: 100%;
object-fit: cover; object-fit: cover;
filter: blur(2px); filter: blur(2px);
} }
.infos { .infos {
/*border: 1px solid orange;*/ /*border: 1px solid orange;*/
width: 100%; width: 100%;
height: 44px; height: 44px;
margin-top: 12px; margin-top: 12px;
} }
.info {
.info {
/*border: 1px solid red;*/ /*border: 1px solid red;*/
width: 100%; width: 100%;
height: 148px; height: 148px;
...@@ -206,20 +213,23 @@ ...@@ -206,20 +213,23 @@
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
align-items: start; align-items: start;
} }
.info-logos {
.info-logos {
/*background-color: #96CEDC;*/ /*background-color: #96CEDC;*/
width: 100%; width: 100%;
height: 48px; height: 48px;
} }
.info-logo {
.info-logo {
width: 48px; width: 48px;
height: 48px; height: 48px;
border-radius: 50%; border-radius: 50%;
border: 1px solid white; border: 1px solid white;
object-fit: cover; object-fit: cover;
} }
.info-msgs {
.info-msgs {
width: 100%; width: 100%;
height: 80px; height: 80px;
margin-bottom: 12px; margin-bottom: 12px;
...@@ -232,8 +242,9 @@ ...@@ -232,8 +242,9 @@
flex-direction: row; flex-direction: row;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
} }
.msg {
.msg {
width: 50%; width: 50%;
height: 100%; height: 100%;
/*border: 1px solid red;*/ /*border: 1px solid red;*/
...@@ -243,12 +254,14 @@ ...@@ -243,12 +254,14 @@
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
align-items: flex-start; align-items: flex-start;
} }
.msg-latest {
.msg-latest {
border-right: none; border-right: none;
align-items: flex-end; align-items: flex-end;
} }
.msg-title {
.msg-title {
width: 120px; width: 120px;
height: 14px; height: 14px;
font-size: 12px; font-size: 12px;
...@@ -256,8 +269,9 @@ ...@@ -256,8 +269,9 @@
line-height: 14px; line-height: 14px;
color: rgba(45, 71, 106, 1); color: rgba(45, 71, 106, 1);
text-align: center; text-align: center;
} }
.msg-num {
.msg-num {
width: 120px; width: 120px;
height: 32px; height: 32px;
border-radius: 16px; border-radius: 16px;
...@@ -267,23 +281,25 @@ ...@@ -267,23 +281,25 @@
flex-direction: row; flex-direction: row;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
} }
.msg-num-red {
.msg-num-red {
color: rgba(208, 2, 27, 1); color: rgba(208, 2, 27, 1);
font-size: 18px; font-size: 18px;
font-weight: bold; font-weight: bold;
line-height: 20px; line-height: 20px;
text-align: center; text-align: center;
} }
.msg-num-blue {
.msg-num-blue {
color: rgba(117, 178, 253, 1); color: rgba(117, 178, 253, 1);
font-size: 18px; font-size: 18px;
font-weight: bold; font-weight: bold;
line-height: 20px; line-height: 20px;
text-align: center; text-align: center;
} }
.lists { .lists {
/*border: 1px solid red;*/ /*border: 1px solid red;*/
width: 100%; width: 100%;
height: auto; height: auto;
...@@ -291,8 +307,9 @@ ...@@ -291,8 +307,9 @@
background-color: rgba(255, 255, 255, 1); background-color: rgba(255, 255, 255, 1);
box-shadow: 0px 1px 3px 0px rgba(221, 221, 221, 1); box-shadow: 0px 1px 3px 0px rgba(221, 221, 221, 1);
} }
.list {
.list {
/*border: 1px solid dodgerblue;*/ /*border: 1px solid dodgerblue;*/
width: 100%; width: 100%;
height: 44px; height: 44px;
...@@ -303,26 +320,29 @@ ...@@ -303,26 +320,29 @@
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
} }
.list-latest {
.list-latest {
border-bottom: none; border-bottom: none;
} }
.list-title {
.list-title {
width: auto; width: auto;
height: 16px; height: 16px;
font-size: 14px; font-size: 14px;
font-weight: bold; font-weight: bold;
line-height: 16px; line-height: 16px;
color: rgba(45, 71, 106, 1); color: rgba(45, 71, 106, 1);
} }
.list-icon {
.list-icon {
margin-right: 16px; margin-right: 16px;
width: 8px; width: 8px;
height: 13px; height: 13px;
object-fit: cover; object-fit: cover;
} }
.main-menuBar { .main-menuBar {
/*border: 1px solid darkviolet;*/ /*border: 1px solid darkviolet;*/
box-shadow: inset 0px 1px 2px 0px rgba(221, 221, 221, 1); box-shadow: inset 0px 1px 2px 0px rgba(221, 221, 221, 1);
width: 100%; width: 100%;
...@@ -335,8 +355,9 @@ ...@@ -335,8 +355,9 @@
display: flex; display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
} }
.menuBar-menu {
.menuBar-menu {
/*background-color: greenyellow;*/ /*background-color: greenyellow;*/
width: 48px; width: 48px;
height: 47px; height: 47px;
...@@ -345,21 +366,24 @@ ...@@ -345,21 +366,24 @@
flex-direction: column; flex-direction: column;
justify-content: flex-end; justify-content: flex-end;
align-items: center; align-items: center;
} }
.menuBar-icon {
.menuBar-icon {
width: 24px; width: 24px;
height: 24px; height: 24px;
object-fit: cover; object-fit: cover;
} }
.menuBar-title {
.menuBar-title {
width: auto; width: auto;
height: 12px; height: 12px;
font-size: 10px; font-size: 10px;
font-weight: bold; font-weight: bold;
color: rgba(67, 119, 188, 0.4); color: rgba(67, 119, 188, 0.4);
text-align: center; text-align: center;
} }
.menuBar-title-ac {
.menuBar-title-ac {
color: rgba(67, 119, 188, 1); color: rgba(67, 119, 188, 1);
} }
</style> </style>
...@@ -20,27 +20,26 @@ ...@@ -20,27 +20,26 @@
</template> </template>
<script> <script>
import {getMessageByClerkId} from '@/utils/utils.Request.aApi' import {getMessageByUserId} from '@/utils/utils.Request.aApi'
export default { export default {
name: 'index', name: 'index',
data() { data() {
return { return {
// clerkId: '2003160512400400000', userId: '',
clerkId: '',
messageList: [] messageList: []
} }
}, },
mounted() { mounted() {
this.clerkId = sessionStorage.getItem('userId') this.userId = sessionStorage.getItem('userId')
this.handleGetMessageByClerkId() this.handleGetMessageByClerkId()
}, },
methods: { methods: {
handleGetMessageByClerkId() { handleGetMessageByClerkId() {
let _this = this let _this = this
let requestRarams = {clerkId: _this.clerkId} let requestRarams = {userId: _this.userId}
alert(JSON.stringify(requestRarams)) alert(JSON.stringify(requestRarams))
getMessageByClerkId(requestRarams) getMessageByUserId(requestRarams)
.then(res => { .then(res => {
if (res.result == 'success') { if (res.result == 'success') {
_this.messageList = res.data _this.messageList = res.data
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
</template> </template>
<script> <script>
import {getClerkInfoBySupervisorId, newTask} from '@/utils/utils.Request.aApi' import {getClerkInfoBySupervisorUserId, newTask} from '@/utils/utils.Request.aApi'
export default { export default {
name: 'releaseMessage', name: 'releaseMessage',
...@@ -29,20 +29,19 @@ ...@@ -29,20 +29,19 @@
return { return {
radio: '1', radio: '1',
checkIds: [], checkIds: [],
// supervisorId:'2003160512400400000',
supervisorId: '', supervisorId: '',
userList: [] userList: []
} }
}, },
mounted() { mounted() {
this.supervisorId = sessionStorage.getItem('userId') this.supervisorUserId = sessionStorage.getItem('userId')
this.getClerkInfoBySupervisorId() this.getClerkInfoBySupervisorId()
}, },
methods: { methods: {
// 根据主管id获取所属部门全部员工信息 // 根据主管id获取所属部门全部员工信息
getClerkInfoBySupervisorId() { getClerkInfoBySupervisorId() {
let _this = this let _this = this
getClerkInfoBySupervisorId({supervisorId: _this.supervisorId}) getClerkInfoBySupervisorUserId({supervisorUserId: _this.supervisorUserId})
.then(res => { .then(res => {
if (res.result == 'success') { if (res.result == 'success') {
_this.userList = res.data _this.userList = res.data
...@@ -65,12 +64,16 @@ ...@@ -65,12 +64,16 @@
//发布 全员发送 获取全部id 部分可见 获取check 的id //发布 全员发送 获取全部id 部分可见 获取check 的id
let title = this.$store.state.message.title let title = this.$store.state.message.title
let content = this.$store.state.message.content let content = this.$store.state.message.content
let supervisorId = this.supervisorId let supervisorUserId = this.supervisorUserId
if(this.checkIds.length==0){
_this.$toast("请选择转发人");
return false
}
let clerkIds = this.checkIds + "" let clerkIds = this.checkIds + ""
let requestParam = { let requestParam = {
title: title, title: title,
content: content, content: content,
supervisorId: supervisorId, supervisorUserId: supervisorUserId,
clerkIds: clerkIds clerkIds: clerkIds
} }
let _this = this let _this = this
......
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