This commit is contained in:
parent
142d413544
commit
b30bfd073c
|
@ -407,7 +407,7 @@ class ProjectsController < ApplicationController
|
||||||
@page = @page.to_i
|
@page = @page.to_i
|
||||||
# Find the page of the requested reply
|
# Find the page of the requested reply
|
||||||
@jours = @project.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
|
@jours = @project.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
|
||||||
@limit = 3
|
@limit = 10
|
||||||
|
|
||||||
offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i])
|
offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i])
|
||||||
page = 1 + offset / @limit
|
page = 1 + offset / @limit
|
||||||
|
|
|
@ -99,7 +99,7 @@ class WordsController < ApplicationController
|
||||||
@project = Project.find params[:project_id]
|
@project = Project.find params[:project_id]
|
||||||
# Find the page of the requested reply
|
# Find the page of the requested reply
|
||||||
@jours = @project.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
|
@jours = @project.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
|
||||||
@limit = 3
|
@limit = 10
|
||||||
|
|
||||||
offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i])
|
offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i])
|
||||||
page = 1 + offset / @limit
|
page = 1 + offset / @limit
|
||||||
|
|
Loading…
Reference in New Issue