jiapeng 7 ans auparavant
Parent
commit
6cdf76193a
1 fichiers modifiés avec 9 ajouts et 11 suppressions
  1. 9 11
      src/main/java/com/ekexiu/portal/leavemsg/Service.java

+ 9 - 11
src/main/java/com/ekexiu/portal/leavemsg/Service.java

@ -132,17 +132,15 @@ public class Service {
132 132
			if (article == null) {
133 133
				throw new JfwBaseException(50000, "article[" + id + "] not found");
134 134
			}
135
			if (article.getArticleType().equals("1")) {
136
				if (reciver == null) {
137
					if (!uid.equals(article.getProfessorId())) {
138
						this.notifyService.notify(con, article.getProfessorId(), uid, uname, lid, article.getArticleTitle(), NotifyType.LEAVE_MSG_AT_ARTICLE,
139
								runs);
140
					}
141
				} else {
142
					if (!uid.equals(reciver)) {
143
						this.notifyService.notify(con, reciver, uid, uname, lid, article.getArticleTitle(),
144
								agree ? NotifyType.AGREE_LEAVE_MSG_AT_ARTICLE : NotifyType.REPLY_LEAVE_MSG_AT_ARTICLE, runs);
145
					}
135

136
			if (reciver == null) {
137
				if (article.getArticleType().equals("1") && (!uid.equals(article.getProfessorId()))) {
138
					this.notifyService.notify(con, article.getProfessorId(), uid, uname, lid, article.getArticleTitle(), NotifyType.LEAVE_MSG_AT_ARTICLE, runs);
139
				}
140
			} else {
141
				if (!uid.equals(reciver)) {
142
					this.notifyService.notify(con, reciver, uid, uname, lid, article.getArticleTitle(),
143
							agree ? NotifyType.AGREE_LEAVE_MSG_AT_ARTICLE : NotifyType.REPLY_LEAVE_MSG_AT_ARTICLE, runs);
146 144
				}
147 145
			}
148 146