diff --git a/src/api/system/message.js b/src/api/system/message.js
index 9ab42695..85d2ecc4 100644
--- a/src/api/system/message.js
+++ b/src/api/system/message.js
@@ -42,11 +42,24 @@ const isRead=function(){
const updateIsRead=function(ids){
return ajax.postJson('/xboe/sys/message/updateIsRead',ids)
}
+
+/**把当前人所有未读消息设置为已读*/
+const readAll=function(){
+ return ajax.postJson('/xboe/sys/message/readall')
+}
+
+/**清空当前人的接收到的所有的消息*/
+const cleanAll=function(){
+ return ajax.postJson('/xboe/sys/message/clearall')
+}
+
export default{
list,
del,
detail,
save,
isRead,
- updateIsRead
+ updateIsRead,
+ readAll,
+ cleanAll
}
diff --git a/src/assets/styles/portal-index.scss b/src/assets/styles/portal-index.scss
index d094e37d..8393bb6b 100644
--- a/src/assets/styles/portal-index.scss
+++ b/src/assets/styles/portal-index.scss
@@ -244,7 +244,7 @@
font-size: 24px;
font-family: JCHEadA;
color: #D9D9D9;
-
+
margin-right: 10px;
img{
vertical-align: top;
@@ -272,12 +272,12 @@
color: #333333;
line-height: 22px;
}
-.portal-index-title{
- font-size: 16px;
- font-weight: 500;
- color: #00253E;
- line-height: 22px;
-}
+// .portal-index-title{
+// font-size: 16px;
+// font-weight: 500;
+// color: #00253E;
+// line-height: 22px;
+// }
.portal-index-summary{
font-size: 14px;
font-weight: 400;
@@ -359,21 +359,9 @@
// padding: 2px 12px;
line-height: 24px;
}
- /**滚动条的宽度*/
-::-webkit-scrollbar {
- width: 5px;
- height: 5px;
-}
-/*滚动条的滑块*/
-::-webkit-scrollbar-thumb {
- background-color: #D8D8D8;
- border-radius: 5px;
-}
-::-webkit-scrollbar-thumb:hover {
- background: #D8D8D8;
-}
+
@keyframes ubAddBlock {
// from {
// bottom: 0;
@@ -449,6 +437,13 @@
}
// boe-index
@media screen and (max-width: 1366px){
+ .portal-index-title{
+ font-size: 14px;
+ font-weight: 500;
+ color: #00253E;
+ margin-bottom: 4px;
+ // line-height: 22px;
+}
.portal-input{
width: 260px;
}
@@ -592,6 +587,7 @@
line-height: 14px;
}
.qa-views{
+ font-size: 12px !important;
left: 10px;
bottom: 6px;
}
@@ -717,7 +713,12 @@
.case-inter-orgin{
width: 47%;
}
-
+ .portal-index-title{
+ font-size: 16px;
+ font-weight: 500;
+ color: #00253E;
+ line-height: 22px;
+}
.portal-input{
width: 280px;
}
@@ -856,6 +857,7 @@
.qa-views{
left: 18px;
bottom: 18px;
+ font-size: 14px;
}
}
.qa-char{
@@ -986,7 +988,12 @@
}
@media screen and (max-width: 1920px) and (min-width: 1681px){
-
+ .portal-index-title{
+ font-size: 16px;
+ font-weight: 500;
+ color: #00253E;
+ line-height: 22px;
+}
.case-inter-orgin{
width: 60%;
}
@@ -1138,6 +1145,7 @@
.qa-views{
left: 20px;
bottom: 20px;
+ font-size: 14px;
}
}
.qa-char{
@@ -1246,6 +1254,12 @@
}
@media screen and (min-width: 1921px){
+ .portal-index-title{
+ font-size: 16px;
+ font-weight: 500;
+ color: #00253E;
+ line-height: 22px;
+}
.case-inter-orgin{
width: 60%;
}
@@ -1393,6 +1407,7 @@
.qa-views{
left: 20px;
bottom: 20px;
+ font-size: 14px;
}
}
.qa-char{
diff --git a/src/assets/styles/portal.scss b/src/assets/styles/portal.scss
index 336afc6d..73501e1f 100644
--- a/src/assets/styles/portal.scss
+++ b/src/assets/styles/portal.scss
@@ -2,6 +2,29 @@
* 门户页面的一些通用样式定义在这里面
*/
body {margin: 0px;padding: 0px;}
+
+/**滚动条的宽度*/
+::-webkit-scrollbar {
+ width: 8px;
+ height: 10px;
+ scrollbar-color: #009cea #f7f7f9; /* 滑块颜色 滚动条背景颜色 */
+ scrollbar-width: thin; /* 滚动条宽度有三种:thin、auto、none */
+}
+
+/*滚动条的滑块*/
+::-webkit-scrollbar-thumb {
+ //background-color: #D8D8D8;
+ border-radius: 3px;
+ background-color: rgb(103, 197, 255);
+}
+
+::-webkit-scrollbar-thumb:hover {
+ background: #D8D8D8;
+ height: 12px;
+ width: 12px;
+}
+
+
//定义全局的核心区域宽度
.xcontent{
min-width: 1100px;
diff --git a/src/components/Course/weikeContent.vue b/src/components/Course/weikeContent.vue
index dc0ccf43..b406eb8a 100644
--- a/src/components/Course/weikeContent.vue
+++ b/src/components/Course/weikeContent.vue
@@ -737,7 +737,6 @@
this.homework.info.id='';
this.exam.content={id:'',contentType:61,sortIndex:3};
this.exam.show=1;
- this.exam.content='';
this.exam.paperJson={items:[]};
this.exam.info.id='';
this.exam.info.paperContent='';
diff --git a/src/components/HomePage/answerList.vue b/src/components/HomePage/answerList.vue
index 227b5e7f..0dee5e93 100644
--- a/src/components/HomePage/answerList.vue
+++ b/src/components/HomePage/answerList.vue
@@ -11,10 +11,10 @@
{{item.contentInfo}}
-
+
{{displayAll(item)}}
diff --git a/src/components/HomePage/articleList.vue b/src/components/HomePage/articleList.vue
index 355ece57..e6623838 100644
--- a/src/components/HomePage/articleList.vue
+++ b/src/components/HomePage/articleList.vue
@@ -11,10 +11,10 @@
{{item.info.title || item.contentInfo}}
-
+
diff --git a/src/components/HomePage/caseList.vue b/src/components/HomePage/caseList.vue
index 6179217c..b3f40ec6 100644
--- a/src/components/HomePage/caseList.vue
+++ b/src/components/HomePage/caseList.vue
@@ -17,10 +17,10 @@
-
+
diff --git a/src/components/HomePage/courseList.vue b/src/components/HomePage/courseList.vue
index ade382a9..ed94fba3 100644
--- a/src/components/HomePage/courseList.vue
+++ b/src/components/HomePage/courseList.vue
@@ -26,10 +26,10 @@
最新一次学习时间:{{item.eventTime}}
-
+
{{personal? '继续学习' : '我也去学'}}
diff --git a/src/components/HomePage/homePage.vue b/src/components/HomePage/homePage.vue
index 485b3780..af3a6305 100644
--- a/src/components/HomePage/homePage.vue
+++ b/src/components/HomePage/homePage.vue
@@ -14,7 +14,7 @@
-
{{userData.name}}{{orgInfo}}
+ {{userData.name}}{{userData.orgInfo}}
{{statData.level}}
@@ -26,7 +26,7 @@
已关注
{{pageId == userInfo.aid ? '留言板':'去留言'}}
-
+
@@ -35,11 +35,11 @@
{{userData.sign}}
暂无签名
-
+
-
-
+
+
@@ -147,6 +147,7 @@
apiUser.getByIds([this.pageId]).then(res => {
if (res.status == 200) {
this.userData = res.result[0];
+ this.userData.orgInfo=cutFullName(this.userData.orgInfo);
} else {
this.$message.error(res.message);
}
@@ -359,7 +360,7 @@
border: 1px solid #619DFF;
font-size: 14px;
color: #387DF7;
-
+
}
.Followed{
width: 80px;
@@ -468,7 +469,7 @@
}
}
.content-bottom{
-
+
.medalbutt{
margin-right: 20px;
}
diff --git a/src/components/HomePage/noteList.vue b/src/components/HomePage/noteList.vue
index b94124f8..92f1543b 100644
--- a/src/components/HomePage/noteList.vue
+++ b/src/components/HomePage/noteList.vue
@@ -11,10 +11,10 @@
{{item.contentInfo}}
-
+
{{item.info.content}}
diff --git a/src/components/HomePage/putTo.vue b/src/components/HomePage/putTo.vue
index 7332aecf..f9c634bd 100644
--- a/src/components/HomePage/putTo.vue
+++ b/src/components/HomePage/putTo.vue
@@ -12,10 +12,10 @@
{{item.info.title || item.contentInfo}}
-
+
-
+
{{ formatNum(data.views)}}
@@ -235,7 +235,6 @@ export default {
// if(type=='praise'){
// typeText='点赞了我的'
// }
-
let content;
let conType;
if(this.type==1){
@@ -283,6 +282,9 @@ export default {
content,
refId,
refType:this.type,
+ source:1,
+ pageUrl:location.href,
+ sendAid:this.userInfo.aid,
sendName,
acceptName,
acceptId,
@@ -291,9 +293,7 @@ export default {
conType,
}
apiMessage.save(message).then(res=>{
- if(res.status==200){
-
- }
+ if(res.status!=200){ console.log('发送消息失败') }
})
},
checkHas(){
diff --git a/src/components/System/chooseOrg.vue b/src/components/System/chooseOrg.vue
index ccf3220d..b4b722e9 100644
--- a/src/components/System/chooseOrg.vue
+++ b/src/components/System/chooseOrg.vue
@@ -1,7 +1,7 @@
-
+
-
+
动态
@@ -20,6 +20,18 @@
还没有动态
+
课程
@@ -28,6 +40,18 @@
还没有课程
+
案例
@@ -36,6 +60,18 @@
还没有案例
+
笔记
@@ -44,6 +80,18 @@
还没有笔记
+
提问
@@ -52,6 +100,18 @@
还没有提问
+
回答
@@ -60,6 +120,18 @@
还没有回答
+
文章
@@ -68,6 +140,18 @@
还没有文章
+
关注
@@ -78,18 +162,6 @@
-->
-
-
-
-
@@ -125,6 +197,7 @@
},
data(){
return{
+ pageId:'',
loading:false,
loading1:false,
loading2:false,
@@ -133,22 +206,30 @@
loading5:false,
loading6:false,
intTabIndex:-1,//初始化显示哪个tab,71我关注的人,72关注我的人
- page:{
- pageIndex:1,
- pageSize:10,
- count:0
- },
input:'',
- activeName:'',
- pageId:'',
+ activeName:'0',
// pageList:[],
casePageList:[],
+ casePage:{count:0,pageSize:10, pageIndex:1},
+
notePageList:[],
+ notePage:{count:0,pageSize:10,pageIndex:1},
+
articlePageList:[],
+ articlePage:{count:0,pageSize:10,pageIndex:1},
+
qaPageList:[],
+ qaPage:{count:0,pageSize:10,pageIndex:1},
+
answerPageList:[],
+ answerPage:{count:0,pageSize:10,pageIndex:1},
+
cousrePageList:[],
+ cousrePage:{count:0,pageSize:10,pageIndex:1},
+
allPageList:[],
+ allPage:{count:0,pageSize:10,pageIndex:1},
+
personal:false,
orgData:[],
Profess:[]
@@ -211,19 +292,40 @@
loadMajorType:'majorType/loadMajorTypes',
loadOrgDomain:'orgDomain/loadOrgDomains'
}),
+ getPagerData(){
+ if(this.activeName == '0') {
+ return this.allPage;
+ } else if(this.activeName == '1') {
+ return this.cousrePage;
+ } else if(this.activeName == '2') {
+ return this.articlePage;
+ } else if(this.activeName == '3') {
+ return this.casePage;
+ } else if(this.activeName == '4') {
+ return this.qaPage;
+ } else if(this.activeName == '5') {
+ return this.answerPage;
+ } else if(this.activeName == '6') {
+ return this.notePage;
+ }
+ return null;
+ },
handleSizeChange(val) {
- this.page.pageSize = val;
- this.page.pageIndex = 1;
+ let curPageData=this.getPagerData();
+ curPageData.pageIndex=1;
+ curPageData.pageSize=val;
this.getList();
},
handleCurrentChange(val) {
- this.page.pageIndex = val;
+ let curPageData=this.getPagerData();
+ curPageData.pageIndex=val;
this.getList();
},
getList() {
+ let curPageData=this.getPagerData();
let data = {
- pageIndex:this.page.pageIndex,
- pageSize:this.page.pageSize,
+ pageIndex:curPageData.pageIndex,
+ pageSize:curPageData.pageSize,
contentType:this.activeName == 0? '':this.activeName,//内容类型
aid:this.pageId, //指定用户的动态,
hidden:this.pageId == this.userInfo.aid?'':false,//是否隐藏,不指定,查询全部
@@ -253,7 +355,7 @@
this.loading5 = false;
this.loading6 = false;
if(res.status == 200) {
- this.page.count = res.result.count;
+ curPageData.count = res.result.count;
let ids = res.result.list.map(item=>item.contentId);
const noReapetIds = [...new Set(ids)];
res.result.list.forEach(item=>{
@@ -542,17 +644,43 @@
})
},
handleClick() {
- if(this.activeName == '7') {
- //单独的分页,所以这里不与当前页面的分页共用
- this.$refs.followList.resetActive();
- this.$refs.followList.getPage();
- return
+
+ if(this.activeName == '0') {
+ if(this.allPageList.length>0){
+ return;
}
- this.page.count = 0
+ } else if(this.activeName == '1') {
+ if(this.cousrePageList.length>0){
+ return;
+ }
+ } else if(this.activeName == '2') {
+ if(this.articlePageList.length>0){
+ return;
+ }
+ } else if(this.activeName == '3') {
+ if(this.casePageList.length>0){
+ return;
+ }
+ } else if(this.activeName == '4') {
+ if(this.qaPageList.length>0){
+ return;
+ }
+ } else if(this.activeName == '5') {
+ if(this.answerPageList.length>0){
+ return;
+ }
+ } else if(this.activeName == '6') {
+ if(this.notePageList.length>0){
+ return;
+ }
+ }else if(this.activeName == '7'){
+ //单独的分页,所以这里不与当前页面的分页共用
+ this.$refs.followList.resetActive();
+ this.$refs.followList.getPage();
+ return
+ }
if(this.activeName == '8') {
- this.page.count = 0;
- // console.log(this.$refs.followList,'this.$refs.followList');
- // this.$refs.followList.getPage();
+ // 书箱没有了
return
}
this.getList();
@@ -562,6 +690,10 @@
diff --git a/src/views/user/Noteedit.vue b/src/views/user/Noteedit.vue
index 6d7817fb..b90aea6b 100644
--- a/src/views/user/Noteedit.vue
+++ b/src/views/user/Noteedit.vue
@@ -72,7 +72,7 @@ export default {
imgContent:[],
fileBaseUrl: process.env.VUE_APP_FILE_BASE_URL,
isShowList:false,
- isShowTip:'',
+ isShowTip:'',
radio: '1',
editdata:{
content:'',
@@ -84,24 +84,44 @@ export default {
histdata:[],
id:'',
timer:null,
+ localStorageKey:'note-local-key',
+ localStorageJson:'',
rowNum:16
};
},
mounted(){
this.id = this.$route.query.id;
this.notedetail();
- this.timer = setInterval(()=>{
- this.savedata(1);
- },30000);
let screenWidth = window.screen.availWidth;
if (screenWidth <= 1440) {
this.editContent = 'edit-content-low';
this.rowNum = 11;
}
+ //检查是事本地存在
+ this.localStorageJson= localStorage.getItem(this.localStorageKey);
+ if(this.localStorageJson){ //存在本地数据
+ this.loadLocalJson();
+ }
+ this.timer = setInterval(()=>{this.savedata(1);},30000);
},
methods:{
+ loadLocalJson(){ //加载本地的数据
+ let $this=this;
+ this.$confirm('您有未保存的笔记,是否加载?', '提示', {
+ confirmButtonText: '确定',
+ cancelButtonText: '取消',
+ type: 'warning'
+ }).then(() => {
+ let entity=JSON.parse($this.localStorageJson);
+ $this.editdata = entity;
+ $this.editdata.openTypeBackups = entity.openType;
+ $this.histId = entity.id;
+ }).catch(() => {
+ localStorage.removeItem(this.localStorageKey);
+ });
+ },
toCoursePage(){
if(this.editdata.type==1){
this.$router.push('/course/detail?id='+this.editdata.courseId);
@@ -110,9 +130,9 @@ export default {
imgDel(index) {
this.imgContent.splice(index,1);
},
- timeDel() {
- this.editdata.playTime = '';
- },
+ timeDel() {
+ this.editdata.playTime = '';
+ },
comeback(){
clearInterval(this.timer);
this.timer = null;
@@ -126,7 +146,6 @@ export default {
this.editdata = res.result;
this.editdata.openTypeBackups = res.result.openType;
this.histId = res.result.id;
-
this.hist();
})
},
@@ -170,41 +189,45 @@ export default {
},
savedata(num){
if(this.editdata.openTypeBackups == 1 && this.editdata.openType == 9) {
- this.$message({
- message: '仅支持公开笔记转私密笔记!',
- type: 'warning'
- });
+ this.$message({ message: '仅支持公开笔记转私密笔记!', type: 'warning' });
this.editdata.openType == 1;
}
if(num == 1) {
this.editdata.isAuto = true;
-
}
if(this.imgContent.length > 0) {
this.editdata.content = this.imgContent.join();
}
apiNote.update(this.editdata).then(res=>{
if(res.status == 200) {
- sessionStorage.setItem('isShowTip','');
+ localStorage.removeItem(this.localStorageKey); //清空本地缓存
if(num ==1) {//自动保存
this.editdata.sysVersion += 1;
this.isShowTip = '笔记自动保存成功';
- setTimeout(()=>{
- this.isShowTip = '';
- },10000*2)
+ setTimeout(()=>{ this.isShowTip = ''; },10000*2)
} else {
this.notedetail()
this.$message({message: '笔记保存成功',type: 'success',center: true});
- // 跳转到笔记列表
+ //跳转到笔记列表
clearInterval(this.timer);
this.timer = null;
this.$router.go(-1);
}
+ }else{
+ if(num ==1){
+ console.log('笔记保存失败:'+res.message);
+ }else{
+ this.$message({message: '笔记保存失败:'+res.message,type: 'error',center: true});
+ }
}
}).catch(()=>{
+ let saveJsonStr = JSON.stringify(this.editdata);
+ //本地保存
+ localStorage.setItem(this.localStorageKey,saveJsonStr);
this.isShowTip = '当前网络异常,内容已离线保存,请尝试连接网络后重新保存!';
- setTimeout(()=>{ this.isShowTip = ''; },10000 * 2)
- sessionStorage.setItem('isShowTip',this.editdata.content);
+ //this.$message({message: '当前网络异常,内容已离线保存,请尝试连接网络后重新保存!',type: 'warning',center: true});
+ setTimeout(()=>{ this.isShowTip = ''; },10000 * 2);
+
})
}
},
@@ -215,8 +238,11 @@ export default {
this.timer = null
},
destroyed(){
- clearInterval(this.timer)
- this.timer = null
+ if(this.timer!=null){
+ clearInterval(this.timer)
+ this.timer = null
+ }
+
}
}