Imports on CGCalendar

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
scotch33
Dev Team Member
Dev Team Member
Posts: 280
Joined: Tue Feb 14, 2006 9:56 pm

Imports on CGCalendar

Post by scotch33 »

In the latest CGCalendar my client regularly imports. The imports all come through as draft and it's a hassle for them to manually set them to published.

in the admin of the module, new events are set to come in as 'published' but this applies to manually created new events as far as I can see. I need to work out a way to set imports to come in as published. has anyone else had this particular battle?
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands
Contact:

Re: Imports on CGCalendar

Post by Rolf »

Settings page under Site Admin
Default status for new events
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
scotch33
Dev Team Member
Dev Team Member
Posts: 280
Joined: Tue Feb 14, 2006 9:56 pm

Re: Imports on CGCalendar

Post by scotch33 »

Thanks pal - in the CGCalendar settings? If so, as mentioned, already set to 'published'.
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3483
Joined: Mon Nov 28, 2011 9:29 am
Location: The Netherlands

Re: Imports on CGCalendar

Post by velden »

Quickly checked the code and - sorry to say - it seems very unlikely to me imported events are set to draft:

Code: Select all

 // now begin importing.
  $errors = array();
  $imported = 0;
  while( !feof($handle) ) {
      $event_status = 'P'; // exported events are only published events.
You might want to check the database after importing for the cgcal event table event_status column. It should read 'P' for the imported events.
Post Reply

Return to “Modules/Add-Ons”