Uploaded image for project: 'CiviHR'
  1. CiviHR
  2. HR-200

Notification for "Is Visa Required"

    Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Won't Do
    • Affects Version/s: HR-1.1
    • Fix Version/s: HR-1.1
    • Component/s: None
    • Labels:
      None

      Description

      == Original Description ==
      If the "Is Visa Required" field is checked and no record is entered, then it should a notification whenever the contact page has been visited. Need to add an Activity Notification to the Dashboard, and to periodically email a reminder.

      == Updated Description ==

      • Create activity types, "Visa Expiration"
      • Implement a helper function, CRM_HRVisa_Activity::sync($contactID) to:
      • Determine if "Is Visa Required" is true or false
      • Find the latest visa
      • Find/update or create an activity of type "Visa Expiration" (given the $contactID). There should be 0-1 records. If multiple exist, take the last (chronologically) and log an error.
      • Set the activity_date_time to the expiration date of the latest visa
      • Set status to "Cancelled" if an activity is found but not required
      • Set status to "Scheduled" otherwise
      • Add hook_civicrm_custom to call CRM_HRVisa_Activity::sync($contactID)
      • During hook_install/enable/disable/uninstall, setup a weekly scheduled reminder for activities of type "Visa Expiration"
      • Upgrade: Find all contacts who require visas and run CRM_HRVisa_Activity::sync($contactID)
      • Add unit-test

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                dakshayani.chinchwadkar Dakshayani
                Reporter:
                yashodha Yashodha Chaku
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 2 days
                  2d