1.1.2.17.2.19.2.61 (checked in on 2008/03/26 at 22:32:10 by sime)
@author Sammy Spets (thanks to Synerger Pty Ltd, Australia) @author eC Dev Team ec_recurring.module Enables recurring product support in Drupal e-Commerce.
@todo: Test that renewals in the old system are entered correctly during the upgrade @todo: Add support for GET parameters for expiry date and workflow status into ec_recurring_ui_products_active(). @todo: Add more UI code to the system. @todo: Combine the numunits and unit form elements into one element (type=time_interval). @todo: Create a hook for calculation of the start_time and improve ec_recurring_start_time() @todo: Provide some way for administrators to change the product vid of an item in the ec_transaction_product table. User's subscription page displays a list for limiting display to All, Expired, Renewed, Active. Admin user can see all that plus click an edit link. Through that interface the admin can change the vid and possibly set an expiry date.
| Name | Description |
|---|---|
| ec_recurring_adjust_cycle | Adjusts the cycles on a cycle-limited expiration entry. This function should be used rather than hard-coding in case the encoding method changes. |
| ec_recurring_block | Implementation of the hook_block(). |
| ec_recurring_build_entry | Adds both the product and reminder values that are used in the expirations table to the given node as $node->recurring['expiration_entries']. This function also sets the $node->recurring['prevpurchase'] to the schedule entry... |
| ec_recurring_cron | Implementation of hook_cron(). |
| ec_recurring_cron_settings | |
| ec_recurring_ecommerceapi | Implementation of hook_ecommerceapi. |
| ec_recurring_ec_transactionapi | Implementation of hook_ec_transactionapi() |
| ec_recurring_expirations_show | |
| ec_recurring_expiration_entry_validate | Validates the entry given to ensure all fields are supplied and non-zero (except the status field, of course). If this function finds an error exit() is called. The purpose of this function is to prevent programmatic errors. Don't use this... |
| ec_recurring_expiration_map | Executes the given function (map function) on each row of the query result of the selected query. The query to perform is identified by $mapid. This can either be one of the queries implemented in this function or one specified by the caller. In that... |
| ec_recurring_expiration_mapfn_insert_reminder | Implementation of a schedule map function |
| ec_recurring_expiration_mapfn_update_reminder | Implementation of a schedule map function |
| ec_recurring_feature_ec_checkout_validate_item | Implementation of e-Commerce hook_feature_ec_checkout_validate_item() |
| ec_recurring_feature_info | Implementation of hook_feature_info() |
| ec_recurring_feature_insert | Implementation hook_feature_insert() |
| ec_recurring_feature_load | Implementation of hook_feature_load() |
| ec_recurring_feature_update | Implementation hook_feature_update() |
| ec_recurring_mail_reset | Implementation of hook_mail_reset() from ec_mail module. |
| ec_recurring_mail_types | Implementation of hook_mail_types() from ec_mail module. |
| ec_recurring_mapfn_active_product_display | |
| ec_recurring_mapfn_product_display | |
| ec_recurring_mapfn_schedule_update_all | Updates expiry timestamp of the given product entry and all reminders associated with it have their start_time and expiry time updated. |
| ec_recurring_menu | Implementation of hook_menu(). |
| ec_recurring_nodeapi | Implementation of hook_nodeapi(). |
| ec_recurring_num_product_active | Returns the number of active product expiration entries in the system. |
| ec_recurring_on_expiry | Processes a product expiration for the product node given. This function expects the ec_recurring_expiration row to be in the expired_schedule member of the given node. |
| ec_recurring_perm | Implementation of hook_perm(). |
| ec_recurring_process_expiries | Processes expiry of entries in the ec_recurring_expiration table. |
| ec_recurring_product_allowed_in_cart | This function checks that it is the first entry of that product being added to the cart. It'll return FALSE if the product has already been added. |
| ec_recurring_product_delete | |
| ec_recurring_product_form_alter | Implementation of hook_product_form_alter(). TODO: test change to hook_product_form_alter. |
| ec_recurring_product_get_expiry | Returns the expiry date for the given product version and transaction. |
| ec_recurring_product_has_unexpired | Returns the number of unexpired products for the given node version. |
| ec_recurring_product_payment | Creates expiration entries for the product and reminders. This function must be called only when the payment status is set to paid. Usually this is called in an 'on payment completion' handler. |
| ec_recurring_product_save | Updates an association between a product version and a recurring schedule |
| ec_recurring_product_validate | Validates the node given. If errors are encountered they are flagged via form_set_error(). |
| ec_recurring_recurringapi | Implementation of hook_recurringapi(). |
| ec_recurring_reminder_delete | Deletes the reminder given by rid. Also deletes reminders already scheduled in ec_reminder_schedule including those that have expired (been sent). |
| ec_recurring_reminder_delete_form | |
| ec_recurring_reminder_delete_form_submit | |
| ec_recurring_renewals_remaining | |
| ec_recurring_renew_item | Renew the node given for the user given. |
| ec_recurring_rowfn_schedules | |
| ec_recurring_save_reminder | |
| ec_recurring_schedule_delete_form | |
| ec_recurring_schedule_delete_form_submit | |
| ec_recurring_schedule_form | Form API code for displaying the schedule add/update form. |
| ec_recurring_schedule_form_submit | Commits schedule fields supplied by the user. |
| ec_recurring_schedule_form_validate | Validates the schedule add/edit form. |
| ec_recurring_schedule_has_unexpired | Returns the number of unexpired products for the given schedule. |
| ec_recurring_set_cycle | Sets the correct value for the cycle. |
| ec_recurring_start_time | This function returns the start_time for a renewed entry. |
| ec_recurring_table | Displays a table of schedules currently stored in the system. |
| ec_recurring_token_list | |
| ec_recurring_token_values | |
| ec_recurring_ui_products | List of recurring products on the system and include links to manipulate them |
| ec_recurring_ui_products_active | |
| ec_recurring_unit_string | Returns the string representation of the given unit. The return value is localized. Providing the count is optional with the default to be one. The count is only returned in the string when $show_number is TRUE. |
| ec_recurring_user | Implementation of hook_user(). |
| ec_recurring_user_subscriptions | The correct format for renewal links is: cart/renew/nid/txnid |
| theme_recurring_date | Themes the timestamp to give a human readable date. |
| theme_recurring_schedule | Returns the HTML representation of the recurring schedule supplied. This function distinguishes between an expiry schedule and reminder schedule by the presence of the 'cycles' key. Expiry schedules have a cycles key and reminder schedules... |
| theme_recurring_status | Returns human readable text for expiration status stored in ec_recurring_expiration. |
| _ec_recurring_expirations_update_all | Updates all entries in ec_recurring_expiration with the given schedule ID. |
| _ec_recurring_expiration_update | Updates the given entry into the ec_recurring_expiration table |
| _ec_recurring_get_default_value | Returns the default value for the given field depending on the conditions given. |
| _ec_recurring_get_sid | |
| _ec_recurring_get_units | |
| _ec_recurring_int_to_hour | |
| _ec_recurring_is_schedule_selected | |
| _ec_recurring_load_schedule | Loads the given schedule from the database. This function returns reminder email schedules as well. The function returns 'expiry' timestamps for the schedule and reminder email schedules. |
| _ec_recurring_load_schedule_vid | Loads the expiry schedule attached to the product with version ID $vid. |
| _ec_recurring_schedule_delete | Delete schedule |
| _ec_recurring_schedule_save | Saves the given schedule to ec_recurring schedule table. |
| __ec_recurring_reminder_form | Its just a virtual function because D5 dont support include files. Its useless on D6. |
| __ec_recurring_reminder_form_submit | Its just a virtual function because D5 dont support include files. Its useless on D6. |
| __ec_recurring_reminder_form_validate | Its just a virtual function because D5 dont support include files. Its useless on D6. |