Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pisns-forum-api
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
scrmGroup
pisns-forum-api
Commits
15fb7843
Commit
15fb7843
authored
Sep 08, 2015
by
刘文胜
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
11111
parent
1e4c5a9c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
forumModerator.js
app/controllers/mobile/forumModerator.js
+4
-4
forumModerator.js
app/models/forumModerator.js
+1
-1
No files found.
app/controllers/mobile/forumModerator.js
View file @
15fb7843
...
...
@@ -30,7 +30,7 @@ function moderatorOperateLog(forumUser,thread,type){
ent_code
:
ent_code
,
info
:
thread
.
info
,
userName
:
thread
.
from
.
nickName
||
thread
.
from
.
displayName
,
content
:
thread
.
_id
,
content
:
{
id
:
thread
.
_id
,
content
:
thread
.
content
}
,
behavior
:
type
,
moderatorName
:
forumUser
.
nickName
||
forumUser
.
displayName
});
...
...
@@ -105,7 +105,7 @@ router.get('/moderators/recommend/:tid', function(req, res, next) {
q2
.
status
=
1
;
q2
.
ent_code
=
entCode
;
q2
.
forumUser
=
id
;
q2
.
infoIds
=
t
.
info
;
q2
.
infoIds
=
{
$all
:[
t
.
info
]}
;
ForumModeratorApply
.
findOne
(
q2
).
populate
(
'forumUser'
).
exec
(
function
(
err
,
result
){
if
(
err
){
return
res
.
json
(
returnCode
.
BUSY
);
...
...
@@ -151,7 +151,7 @@ router.get('/moderators/unrecommend/:tid', function(req, res, next) {
q2
.
status
=
1
;
q2
.
ent_code
=
entCode
;
q2
.
forumUser
=
id
;
q2
.
infoIds
=
t
.
info
;
q2
.
infoIds
=
{
$all
:[
t
.
info
]}
;
ForumModeratorApply
.
findOne
(
q2
).
populate
(
'forumUser'
).
exec
(
function
(
err
,
result
){
if
(
err
){
return
res
.
json
(
returnCode
.
BUSY
);
...
...
@@ -196,7 +196,7 @@ router.get('/moderators/delthread/:tid', function(req, res, next) {
q2
.
status
=
1
;
q2
.
ent_code
=
entCode
;
q2
.
forumUser
=
id
;
q2
.
infoIds
=
t
.
info
;
q2
.
infoIds
=
{
$all
:[
t
.
info
]}
;
ForumModeratorApply
.
findOne
(
q2
).
populate
(
'forumUser'
).
exec
(
function
(
err
,
result
){
if
(
err
){
return
res
.
json
(
returnCode
.
BUSY
);
...
...
app/models/forumModerator.js
View file @
15fb7843
...
...
@@ -18,7 +18,7 @@ var ForumModeratorSchema=new Schema({
require
:
false
},
content
:{
type
:
Schema
.
Types
.
ObjectId
,
type
:
Object
,
require
:
false
},
behavior
:{
//行为:1.加精 2.取消精华 3.删帖
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment