Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
edx-platform-release
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hsin-Yu Chien
edx-platform-release
Commits
014185ea
Commit
014185ea
authored
8 years ago
by
wajeeha-khalid
Browse files
Options
Downloads
Plain Diff
Merge pull request #12145 from edx/jia/TNL-3818-refactor
refactored variable name
parents
00d2d6d2
e0208690
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
common/static/coffee/src/discussion/discussion.coffee
+3
-4
3 additions, 4 deletions
common/static/coffee/src/discussion/discussion.coffee
with
3 additions
and
4 deletions
common/static/coffee/src/discussion/discussion.coffee
+
3
−
4
View file @
014185ea
...
...
@@ -118,14 +118,13 @@ if Backbone?
pinnedThreadsSortComparatorWithDate
:
(
thread
,
ascending
)
->
# if threads are pinned they should be displayed on top.
# Unpinned will be sorted by their last activity date
threadCreatedTime
=
new
Date
(
thread
.
get
(
"created_at"
)).
getTime
()
threadCreatedTime
=
new
Date
(
thread
.
get
(
"last_activity_at"
)).
getTime
()
threadLastActivityAtTime
=
new
Date
(
thread
.
get
(
"last_activity_at"
)).
getTime
()
if
thread
.
get
(
'pinned'
)
#use tomorrow's date
today
=
new
Date
();
preferredDate
=
new
Date
(
today
.
getTime
()
+
(
24
*
60
*
60
*
1000
)
+
thread
Created
Time
);
preferredDate
=
new
Date
(
today
.
getTime
()
+
(
24
*
60
*
60
*
1000
)
+
thread
LastActivityAt
Time
);
else
preferredDate
=
thread
Created
Time
preferredDate
=
thread
LastActivityAt
Time
if
ascending
preferredDate
else
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment