My Subscriptions

No active or expired subscriptions. View Available Subscriptions

Advanced Search

Home arrow Forum arrow JCal Client 1.6.xarrow 1.6.x General Discussionarrow Admin repeat method bug on edit
Pages: [1]
Print
Author Topic: Admin repeat method bug on edit  (Read 307 times)
idealists
Newbie
*
Posts: 8


View Profile
« on: April 17, 2008, 01:45:02 AM »

When I come in to edit an event which has a "Repeat method set", eg "Repeat every FIRST Sunday" the wrong radio button is selected.
The "Don't repeat this event" option is selected.

Is there a known fix for this?

Thanks much.
Logged
idealists
Newbie
*
Posts: 8


View Profile
« Reply #1 on: April 24, 2008, 05:00:28 AM »

VMan? Anyone?
Logged
PattiH
Newbie
*
Posts: 2


View Profile
« Reply #2 on: April 27, 2008, 08:59:48 AM »

I think this is a known bug (see that locked thread above).  However, one problem I'm also having is that repeating events are not "sticking". Maybe that goes along with the radio button not showing that it was a repeating event. When I look at the calendar making sure that repeating events that I have added are there, they are at first, but then when I come back later (on the front end), they have disappeared.
Logged
idealists
Newbie
*
Posts: 8


View Profile
« Reply #3 on: April 29, 2008, 03:26:54 AM »

Ok, I think I fixed it.

admin...->components->com_jcalpro->includes->events.php
around line: 129 within function editEvent ( $id, $option, $section )

 switch ( $row->recur_type )
        {
            case 'day':
            case 'week':
            case 'month':
            case 'year':
                $row->recur_type_select = '1';
            break;         
            case '':
            default:
                $row->recur_type_select = '0';
            break;
        }

change to:
 switch ( $row->recur_type )
        {
            case 'day':
            case 'week':
            case 'month':
            case 'year':
                $row->recur_type_select = '1';
            break;
         
   case 0:
   case 1:
   case 2:
   case 3:
   case 4:
   case 5:
   case 6:
      $row->recur_type_select = '2';
   break;
         
            case '':
            default:
                $row->recur_type_select = '0';
            break;
        }

and then a few lines below after the line:
$checked['recurEvery'] = ( ( int ) $row->recur_type_select == 1 ) ? 'checked' : '';
add the line below:
$checked['recurOrdinal'] = ( ( int ) $row->recur_type_select == 2 ) ? 'checked' : '';



Logged
idealists
Newbie
*
Posts: 8


View Profile
« Reply #4 on: April 29, 2008, 10:13:08 AM »

Correction to the first part of my fix.
Use this:
 switch ( $row->recur_type )
        {
            case 'day':
            case 'week':
            case 'month':
            case 'year':
                $row->recur_type_select = '1';
            break;
         
         
         case 0:
            if ($row->recur_ord < 1) {
               $row->recur_type_select = '0';
               break;
            }
         case 1:
         case 2:
         case 3:
         case 4:
         case 5:
         case 6:
            $row->recur_type_select = '2';
         break;
         
         
            case '':
            default:
                $row->recur_type_select = '0';
            break;
        }

Also if you use Mambo you will have to change the Mambo section of the editEvent (I think the code fix will be the same).

Hope that helps someone..also if you spot a bug in th fix..please post it here for the benefit of all.

Thx
Logged
Pages: [1]
Print
Jump to:  

Powered by SMF 1.1.3 | SMF © 2006-2007, Simple Machines LLC
Joomla Bridge by JoomlaHacks.com

Original Joomla Template design by RocketTheme ( Conversion by Bloc)