Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

JoomlaTune Support Forum    JComments component    Bug-reports    Topic: Error on import - no negative rating
Pages: [1]   Go Down
  Print  
Author Topic: Error on import - no negative rating  (Read 2106 times)
0 Members and 1 Guest are viewing this topic.
clone
Newbie
*

Karma: 0
Offline Offline

Posts: 6


« on: November 18, 2009, 05:49:57 »

Hi,

I made some changes to admin.jcomments.migration.php file, since the imported chrono comments didn't have negative rating.
Don't know about the other systems, but ChronoComments uses only one field to store comment rating, so it can be positive or negative. As JComments uses separate unsigned fields, the direct transfer didn't work, so the thing I changed in order to get everything to import is :

from : $comment->ispoor   = $row->rating < 0 ? $row->rating : 0;

to     : $comment->ispoor   = $row->rating < 0 ? abs($row->rating) : 0;

Cheers

Clone
Logged
smart
Administrator
Hero Member
*****

Karma: 160
Offline Offline

Gender: Male
Posts: 2559



WWW
« Reply #1 on: November 18, 2009, 14:14:46 »

Ok, thanks! I've already applied this fix to new version...
Logged

If you use JComments, please post a rating and a review at the Joomla! Extensions Directory
Pages: [1]   Go Up
  Print  
JoomlaTune Support Forum    JComments component    Bug-reports    Topic: Error on import - no negative rating
 
Jump to: