Commit d9953e68 authored by 高飞's avatar 高飞
parents abbacd8b b1d888a9
......@@ -61,5 +61,8 @@
"vuex": "^3.6.2",
"webuploader": "^0.1.5",
"xlsx": "^0.17.0"
},
"volta": {
"node": "14.21.3"
}
}
......@@ -4,16 +4,16 @@ const PREFIX_RECORDS = 'api/rest/chat/chatRecords';
//分页查询群聊记录
//查询小群
export const getRecordsByPagingTeam = (chatRoomId, currPage, pageSize, startTime, endTime, fromUserId,teamId) => {
export const getRecordsByPagingTeam = (chatRoomId, currPage, pageSize, startTime, endTime, fromUserId, teamId) => {
let url = `${PREFIX_RECORDS}/chatroomTeam/page`;
url += addParam({ chatRoomId, currPage, pageSize, startTime, endTime, fromUserId,teamId });
url += addParam({ chatRoomId, currPage, pageSize, startTime, endTime, fromUserId, teamId });
return get(url);
}
//查询大群
export const getRecordsByPaging = (chatRoomId, currPage, pageSize, startTime, endTime, fromUserId,teamId) => {
export const getRecordsByPaging = (chatRoomId, currPage, pageSize, startTime, endTime, fromUserId, teamId) => {
let url = `${PREFIX_RECORDS}/chatroom/page`;
url += addParam({ chatRoomId, currPage, pageSize, startTime, endTime, fromUserId,teamId });
url += addParam({ chatRoomId, currPage, pageSize, startTime, endTime, fromUserId, teamId });
return get(url);
}
......@@ -28,3 +28,8 @@ export const getPrivateLetterByPaging = (currPage, pageSize, startTime, endTime,
export const getListUnread = (chatRoomId, userId) => {
return get(`${PREFIX_RECORDS}/listUnread?chatRoomId=${chatRoomId}&userId=${userId}`);
}
//获取图片库照片
export const getFileUrl = (bucket, name) => {
return get(`api/rest/file/viewPicture/${bucket}?objectName=${name}`);
}
\ No newline at end of file
......@@ -28,8 +28,8 @@ export const leaveChatRoom = (userId) => {
}
//查询某个用户所有聊天室(群组)
export const getChatRoomList = (userId) => {
return get(`${PREFIX_CHATROOM}/list?userId=${userId}`);
export const getChatRoomList = (data) => {
return post(`${PREFIX_CHATROOM}/list`,data);
}
//阅读(群组)信息
......
......@@ -42,7 +42,7 @@ export function queryUserPerformance(pageNum = 1, pageSize = 10, logType = LITER
* @param {*} body
* @returns
*/
export function countUserPerformance(pageNum = 1, pageSize = 10, logType = LITERATURE,body = {}) {
export function countUserPerformance(pageNum = 1, pageSize = 10, logType = LITERATURE, body = {}) {
return post(`api/rest/user/countUserPerformance?pageNum=${pageNum}&pageSize=${pageSize}&logType=${logType}`, body);
}
......@@ -67,7 +67,7 @@ export function queryNotification(pageNum, pageSize, account, text) {
* @param {*} account
* @returns
*/
export function removeNotification(ids,account) {
export function removeNotification(ids, account) {
return delete_util(`api/rest/user/removeNotification?account=${account}`, ids);
}
......@@ -82,3 +82,7 @@ export function readNotification(account, noteId) {
url += addParam({ account, noteId });
return post(url, {});
}
export function getUserList() {
return get("api/rest/system/user/queryUser")
}
\ No newline at end of file
export default{
bind(el, binding, vnode) {
const dialogHeaderEl = el.querySelector('.el-dialog__header')
const dragDom = el.querySelector('.el-dialog')
dialogHeaderEl.style.cssText += ';cursor:move;'
dragDom.style.cssText += ';top:0px;'
// 获取原有属性 ie dom元素.currentStyle 火狐谷歌 window.getComputedStyle(dom元素, null);
const getStyle = (function() {
if (window.document.currentStyle) {
return (dom, attr) => dom.currentStyle[attr]
} else {
return (dom, attr) => getComputedStyle(dom, false)[attr]
}
})()
dialogHeaderEl.onmousedown = (e) => {
// 鼠标按下,计算当前元素距离可视区的距离
const disX = e.clientX - dialogHeaderEl.offsetLeft
const disY = e.clientY - dialogHeaderEl.offsetTop
const dragDomWidth = dragDom.offsetWidth
const dragDomheight = dragDom.offsetHeight
const screenWidth = document.body.clientWidth
const screenHeight = document.body.clientHeight
const minDragDomLeft = dragDom.offsetLeft
const maxDragDomLeft = screenWidth - dragDom.offsetLeft - dragDomWidth
const minDragDomTop = dragDom.offsetTop
const maxDragDomTop = screenHeight - dragDom.offsetTop - dragDomheight
// 获取到的值带px 正则匹配替换
let styL = getStyle(dragDom, 'left')
let styT = getStyle(dragDom, 'top')
if (styL.includes('%')) {
styL = +document.body.clientWidth * (+styL.replace(/%/g, '') / 100)
styT = +document.body.clientHeight * (+styT.replace(/%/g, '') / 100)
} else {
styL = +styL.replace(/\px/g, '')
styT = +styT.replace(/\px/g, '')
}
document.onmousemove = function(e) {
// 通过事件委托,计算移动的距离
let left = e.clientX - disX
let top = e.clientY - disY
// 边界处理
if (-(left) > minDragDomLeft) {
left = -minDragDomLeft
} else if (left > maxDragDomLeft) {
left = maxDragDomLeft
}
if (-(top) > minDragDomTop) {
top = -minDragDomTop
} else if (top > maxDragDomTop) {
top = maxDragDomTop
}
// 移动当前元素
dragDom.style.cssText += `;left:${left + styL}px;top:${top + styT}px;`
// emit onDrag event
vnode.child.$emit('dragDialog')
}
document.onmouseup = function() {
document.onmousemove = null
document.onmouseup = null
}
}
}
}
\ No newline at end of file
import drag from '@/util/directive/el-dragDialog/drag'
const install = function(Vue) {
Vue.directive('el-drag-dialog', drag)
}
if (window.Vue) {
window['el-drag-dialog'] = drag
Vue.use(install);
}
drag.install = install
export default drag
......@@ -310,10 +310,12 @@ let getTime_extent = (n) => {
let pre_rq = pre_year + '-' + pre_newMonth + '-' + pre_newDate;
let pre_rq_start = pre_year + '-' + pre_newMonth + '-' + pre_newDate + ' ' + '00:00:00';
let pre_rq_end = pre_year + '-' + pre_newMonth + '-' + pre_newDate + ' ' + '23:59:59';
let currentDate = pre_year + '-' + pre_newMonth + '-' + pre_newDate + ' ' +now.toLocaleTimeString();
return {
pre_rq,
pre_rq_start,
pre_rq_end
pre_rq_end,
currentDate
}
}
......
<template>
<el-dialog title="聊天室" :visible.sync="dialogVisible" width="40%" :before-close="handleClose">
<el-dialog v-if="dialogVisible" v-el-drag-dialog title="聊天室" :visible.sync="dialogVisible" width="40%" :before-close="handleClose" :close-on-click-modal="false">
<div class="info-messageInfo">
<!-- <div class="title">
<img :src="arrow" alt="">
<span>内部通讯</span>
</div> -->
<div class="messageInfo-content">
<div class="chatPerson">
<span :style="{ backgroundColor: chatPerson.isLine ? '#30d64d' : '#686a6b' }"
v-show="chatPerson.isLine != undefined"></span>&nbsp;
<span v-text="chatPerson.name"></span>
</div>
<div id="chatContent" class="chatContent">
<div id="chatContent" class="chatContent" ref="chatContent">
<div v-for="item in chatMessageList" class="everyMessage">
<div :style="{ justifyContent: item.fromUserId == userInfo.account ? 'flex-end' : 'flex-start' }">
<template v-if="item.fromUserId != userInfo.account">
......@@ -23,7 +19,6 @@
<img :src="avatar" alt="">
</template>
</div>
</div>
</div>
<div class="chatSendMessage">
......@@ -44,6 +39,7 @@
<script>
import avatar from '../../../assets/img/ddkz/headPhoto.jpg';
import { getRecordsByPagingTeam } from '../../../api/chat/chatRecords';
import elDragDialog from "@/util/directive/el-dragDialog";
export default {
data() {
return {
......@@ -62,17 +58,23 @@ export default {
myStompClient: null
}
},
directives: {
elDragDialog
},
props: {
visible: Boolean,
analogData: Array,
stompClient: Object,
currentChatRoomInfo: Object
},
methods: {
handleClose() {
// this.dialogVisible = false;
this.$emit('handleCancel');
},
showDialog(){
this.dialogVisible = true;
},
sendMessageFn() {
if (this.sendMessage.trim().length > 0) {
this.myStompClient.send("/app/sendToChatRoomTeam/" + this.currentChatRoom.id + '/' + this.currentChatRoom.teamId, {}, JSON.stringify({
......@@ -88,8 +90,7 @@ export default {
}
},
keepBottom() {
const divscll = document.getElementById('chatContent');
divscll.scrollTop = divscll.scrollHeight;
this.$refs.chatContent.scrollTop = this.$refs.chatContent.scrollHeight;
},
listChatroom(data) {
//取消群聊的订阅
......@@ -105,18 +106,22 @@ export default {
content: JSON.parse(data.body).content,
fromUserId: data.headers.fromUserId
});
this.$nextTick(() => {
this.keepBottom();
});
}, { id: "multicast" + e.id + new Date().getTime() });
})
},
getCurrentMessageList(item) {
//查询我方聊天记录
getRecordsByPagingTeam(item.id, 1, 100, '2020-01-01 00:00:00', '2023-10-01 00:00:00', null, item.teamId).then(res1 => {
getRecordsByPagingTeam(item.id, 1, 100, '2020-01-01 00:00:00', '2024-10-01 00:00:00', null, item.teamId).then(res1 => {
this.chatMessageList = res1.records;
this.$nextTick(() => {
this.keepBottom();
});
})
}
},
computed: {
userInfo() {
......@@ -135,9 +140,6 @@ export default {
//订阅
this.listChatroom(this.analogDataList);
this.getCurrentMessageList(this.$props.currentChatRoomInfo);
setTimeout(() => {
this.keepBottom();
}, 2000);
}
}
</script>
......@@ -145,7 +147,7 @@ export default {
<style lang="scss">
.info-messageInfo {
width: 100%;
height: 70%;
height: 60%;
.title {
width: 100%;
......
<template>
<el-dialog title="人员情况" :visible.sync="dialogVisible" width="40%" :before-close="handleClose">
<el-dialog v-el-drag-dialog title="人员情况" :visible.sync="dialogVisible" width="40%"
:before-close="handleClose" @open="handleDialogOpen">
<div class="info-personInfo">
<!-- <div class="title">
<img :src="arrow" alt="">
<span>人员情况</span>
</div> -->
<div class="personInfo-content">
<div v-for="item in personList" class="everyPersonList">
<span v-text="item.userId" @click="selectPerson(item);"></span>
......@@ -16,6 +13,7 @@
<script>
import elDragDialog from "@/util/directive/el-dragDialog";
export default {
data() {
return {
......@@ -23,19 +21,30 @@ export default {
personList: []
}
},
directives: {
elDragDialog
},
props: {
visible: Boolean,
// visible: Boolean,
peopleList: Array
},
methods: {
handleClose() {
this.$emit('handleCancel');
}
this.dialogVisible = false;
// this.$emit('handleCancel');
},
mounted() {
this.dialogVisible = this.$props.visible;
showDialog() {
this.dialogVisible = true;
},
handleDialogOpen() {
// this.dialogVisible = this.$props.visible;
this.personList = this.$props.peopleList;
}
},
// mounted() {
// this.dialogVisible = this.$props.visible;
// this.personList = this.$props.peopleList;
// }
}
</script>
......@@ -44,6 +53,7 @@ export default {
.info-personInfo {
width: 100%;
height: 30%;
overflow-y: auto;
.title {
width: 100%;
......
<template>
<el-dialog title="发送公告" :visible.sync="dialogVisible" width="30%" :before-close="handleClose">
<el-dialog v-el-drag-dialog title="发送公告" :visible.sync="dialogVisible" width="30%" :before-close="handleClose">
<div class="notice">
<el-form ref="form" :model="form" label-width="80px">
<el-form-item label="标题">
......@@ -16,7 +16,7 @@
</el-upload>
</el-form-item>
<el-form-item style="text-align: center;">
<el-button type="default">取消</el-button>
<el-button type="default" @click="handleClose">取消</el-button>
<el-button type="success" @click="sendNotice">发送</el-button>
</el-form-item>
</el-form>
......@@ -28,6 +28,7 @@
<script>
import { upLoadFiles } from '../../../api/chat/chatRoom';
import { format_file } from '../../../util/http_util';
import elDragDialog from "@/util/directive/el-dragDialog";
export default {
data() {
return {
......@@ -35,7 +36,8 @@ export default {
form: {
title: '',
content: '',
attachment: ''
attachment: '',
messageForm:null
},
formatFile: format_file(),
myStompClient: null,
......@@ -43,6 +45,9 @@ export default {
analogDataList: [],
}
},
directives: {
elDragDialog
},
props: {
visible: Boolean,
stompClient: Object,
......@@ -51,13 +56,28 @@ export default {
},
methods: {
handleClose() {
this.$emit('handleCancel');
this.dialogVisible = false;
// this.$emit('handleCancel');
},
showDialog(){
this.dialogVisible = true;
},
handleChange(file, fileList) {
let fd = new FormData();
fd.append('file', file.raw);
upLoadFiles('CHAT', fd).then(res => {
this.form.attachment = res;
let type = file.name.split('.')[1];
if(type=='png'||type=='jpg'){
this.form.messageForm = 'PICTURE';
}else if(type=='mp4'){
this.form.messageForm = 'VIDEO';
}else if(type=='xlsx'||type=='xls'){
this.form.messageForm = 'EXCEL';
}else{
this.form.messageForm = 'TEXT';
}
});
},
handleRemove() { },
......
This diff is collapsed.
......@@ -9,7 +9,7 @@
</div>
<div class="button-list-right">
<div v-for="(item, index) in modules.rightModule"
:class="['module-info', isSelected-3 == index ? 'selectedModule' : '']" @click="choiceModule(index+3)"
:class="['module-info', isSelected - 3 == index ? 'selectedModule' : '']" @click="choiceModule(index + 3)"
v-text="item.name">
</div>
</div>
......@@ -340,6 +340,7 @@ export default {
background-size: 100% 105%;
background-repeat: no-repeat;
color: white;
.ant-layout-header {
background: none;
}
......@@ -354,6 +355,7 @@ export default {
font-size: 13px;
letter-spacing: 2px;
font-weight: 900;
h1 {
font-size: 34px;
letter-spacing: 7px;
......@@ -362,7 +364,8 @@ export default {
margin-bottom: 0px !important;
font-family: cursive;
text-align: center;
span{
span {
background-image: linear-gradient(to right, #498ce1, #75f8d2, #498ce1);
color: transparent;
-webkit-background-clip: text;
......@@ -848,5 +851,4 @@ export default {
transition: all 0.4s ease;
cursor: pointer;
}
}
</style>
\ No newline at end of file
}</style>
\ No newline at end of file
<template>
<div class="ddkzConfig">
<el-tabs type="border-card" @tab-click="handleTabClick" v-model="activeTabs">
<el-tab-pane>
<span slot="label"><i class="el-icon-date"></i> 新增会议</span>
<DdkzConfigAdd></DdkzConfigAdd>
</el-tab-pane>
<el-tab-pane>
<span slot="label"><i class="el-icon-date"></i> 会议列表</span>
<DdkzConfigList></DdkzConfigList>
</el-tab-pane>
</el-tabs>
</div>
</template>
<script>
import ddkzConfigAdd from '../sjgl/ddkzConfig/ddkzConfigAdd.vue';
import ddkzConfigList from '../sjgl/ddkzConfig/ddkzConfigList.vue';
export default {
data() {
return {
activeTabs: ''
}
},
components:{
DdkzConfigAdd:ddkzConfigAdd,
DdkzConfigList:ddkzConfigList
},
methods: {
handleTabClick() {
}
}
}
</script>
<style lang="scss">
.ddkzConfig {
width: 99%;
height: 98%;
padding: 30px;
box-sizing: border-box;
overflow-y: auto;
>.el-tabs--border-card {
width: calc(100% - 4px);
height: calc(100% - 4px);
border: 2px solid #125473;
border-radius: 5px;
box-sizing: border-box;
background: #ffffff00;
>.el-tabs__content {
width: 100%;
height: calc(100% - 40px);
box-sizing: border-box;
}
>.el-tabs__header {
background-color: unset;
border-bottom: 2px solid #125473;
.el-tabs__item {
color: #dedede;
}
.el-tabs__item.is-active {
color: #ffe000;
background-color: #116791;
border-right-color: #116791;
border-left-color: #116791;
}
.el-tabs__item:not(.is-disabled):hover {
color: #ffe000;
}
}
}
}
</style>
\ No newline at end of file
This diff is collapsed.
<template>
<div class="ddkzConfigList">
<div class="ddkzCondition">
<el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="dateRange" type="daterange" range-separator="至"
start-placeholder="开始时间" end-placeholder="结束时间" :default-time="['00:00:00', '23:59:59']">
</el-date-picker>
<div class="searchButton" @click="searchChatList">搜索</div>
</div>
<div class="ddkzContent">
<el-table :data="meetingList" tooltip-effect="dark" style="width: 100%;" height="calc(100% - 60px)"
@selection-change="handleSelectionChange">
<!-- <el-table-column type="selection" width="55">
</el-table-column> -->
<el-table-column prop="nickname" label="主题" align="center"></el-table-column>
<el-table-column prop="chatroomOwner" label="支持人" align="center"></el-table-column>
<el-table-column prop="createTime" label="日期" align="center"></el-table-column>
<!-- <el-table-column label="操作" align="center" width="500">
<template slot-scope="scope">
<el-button size="mini" type="danger" @click="deleteMeeting(scope.row)">删除</el-button>
</template>
</el-table-column> -->
</el-table>
</div>
</div>
</template>
<script>
import { getChatRoomList } from "@/api/chat/chatRoom";
export default {
data() {
return {
dateRange: [],
meetingList: []
}
},
methods: {
handleSelectionChange() { },
deleteMeeting(item) { },
queryChatRoomListFn(param) {
getChatRoomList(param).then(res => {
this.meetingList = res;
});
},
searchChatList(){
if(this.dateRange.length==2){
this.queryChatRoomListFn({startTime:this.dateRange[0],endTime:this.dateRange[1],userId:this.userInfo.account})
}else{
this.queryChatRoomListFn({userId:this.userInfo.account})
}
}
},
computed: {
userInfo() {
if (this.$store.getters.userInfo) {
return this.$store.getters.userInfo;
} else {
return { account: "" };
}
}
},
mounted() {
this.queryChatRoomListFn({userId:this.userInfo.account});
}
}
</script>
<style lang="scss">
.ddkzConfigList {
width: 100%;
height: 100%;
.ddkzCondition {
width: 100%;
height: 80px;
display: flex;
.el-date-editor {
background: none;
span {
color: white;
}
.el-range-input {
color: white;
background: none;
}
}
.el-input__inner {
border: 1px solid #3a5f94c9 !important;
}
.searchButton {
width: 80px;
height: 30px;
line-height: 30px;
margin-top: 4px;
margin-left: 20px;
font-size: 14px;
text-align: center;
// background-image: url(../../../assets/img/fzjc/7.png);
background-size: 100% 100%;
background-repeat: no-repeat;
border: 1px solid #3a5f94c9 !important;
border-radius: 5px;
cursor: pointer;
}
}
.ddkzContent {
width: 100%;
height: calc(100% - 50px);
overflow-y: auto;
.el-table tr {
background-color: transparent !important;
color: #ffffffc7;
}
.el-table thead tr {
height: 40px;
background: url(../../../assets/img/setting/tr1.png) no-repeat;
background-size: 100% 100%;
}
.el-table th {
background-color: transparent;
}
tbody tr {
border-bottom: 1px solid #252631;
}
.el-table td {
border-bottom: 1px solid #252631;
border-right: unset;
}
.el-table--enable-row-hover .el-table__body tr:hover>td {
background-color: #82848a78;
}
.el-table th {
border: unset;
}
.el-table--fit {
background: none !important;
border: unset;
}
.el-icon-delete-solid {
color: red;
cursor: pointer;
font-size: 18px;
}
.el-icon-edit {
color: #1172d8;
cursor: pointer;
font-size: 20px;
}
.el-icon-view {
color: #00ffff;
font-size: 20px;
cursor: pointer;
}
.el-table--group::after,
.el-table--border::after,
.el-table::before {
background-color: unset;
}
.pagination-div {
width: 100%;
height: 50px;
.el-pagination {
margin-top: 9px;
text-align: right;
.el-pagination__total {
color: white;
}
.el-pagination__jump {
color: white;
}
}
.myPagination.is-background .el-pager li:not(.disabled).active {
color: #fff;
border: 1px solid #146a80;
box-shadow: 0 0 10px #1b6097;
background-color: #1d2d46;
}
}
}
}
</style>
\ No newline at end of file
......@@ -13,6 +13,11 @@ module.exports = {
filename: '[name].[contenthash:8].js',
path: path.resolve(__dirname, './dist') // 打包后的目录
},
resolve:{
alias:{
'@':path.join(__dirname,'./src/')
}
},
plugins: [
new HtmlWebpackPlugin({
template: path.resolve(__dirname, './index.html'),
......
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