Thursday, February 16, 2012

Add a Custom Scheduler for sugarcrm


Hi  Googler ! 
I was working on sugar crm, and come to add custom scheduler.


Create a file and name it “_AddJobsHere.php” in custom/modules/Schedulers/ (you may need to create the directory). Functions need to return true.
<?php
$job_strings[] = 'your_function';
function your_function(){
  // Do stuff
  return true;
}
?>
Create a new language file
<?php
//MAKE SURE THE $mod_strings KEY IS COMBINATION OF "LBL_" & SCHEDULER JOB FUNCTION NAME, ALL CAPITALS
$mod_strings['LBL_YOUR_FUNCTION'] = 'Send Reminder';
?>
write your custom function in the file and you will able to select it when you create a new scheduler job. Your directory structure will be thus:
custom/modules/Schedulers/custom/modules/Schedulers/language
custom/modules/Schedulers/language/en_us.lang.php
custom/modules/Schedulers/_AddJobsHere.php


cheers ! 

Reactions:

1 comment:

  1. Very impressive tips!!! It is very
    knowledgeable. Thanks for sharing this wonderful content.

    Website Designing Jaipur India

    ReplyDelete

Any Questions or Suggestions ?

About

Professional & Experienced Freelance Developer From India, Technologist, Software Engineer, internet marketer and Open Sources Developer with experience in Finance, Telecoms and the Media. Contact Me for freelancing projects.

Enter your email address:

Delivered by FeedBurner

PHP Freelancer India - Google+