function uc_recurring_get_fee_ops in UC Recurring Payments and Subscriptions 6.2
Same name and namespace in other branches
- 7.2 uc_recurring.module \uc_recurring_get_fee_ops()
Provide default options.
3 calls to uc_recurring_get_fee_ops()
- theme_uc_recurring_admin_table in ./
uc_recurring.module - Displays a table for users to administer their recurring fees.
- theme_uc_recurring_user_table in ./
uc_recurring.module - Displays a table for users to administer their recurring fees.
- uc_recurring_subscription_subscriber_list in modules/
uc_recurring_subscription/ uc_recurring_subscription.admin.inc
File
- ./
uc_recurring.module, line 1170 - Allows you to add a recurring fee to a product/SKU to handle subscription type services.
Code
function uc_recurring_get_fee_ops($context, $fee) {
$ops = array();
$info = uc_recurring_get_recurring_info($fee->fee_handler);
if (!empty($info['menu'])) {
foreach ($info['menu'] as $path => $menu) {
if ($menu != UC_RECURRING_MENU_DISABLED) {
if ($context == 'fee_admin') {
$full_path = 'admin/store/orders/recurring/' . $fee->rfid . '/' . $path . '/' . $info['fee handler'];
}
else {
$full_path = 'user/' . $fee->uid . '/recurring/' . $fee->rfid . '/' . $path . '/' . $info['fee handler'];
}
if (menu_valid_path(array(
'link_path' => $full_path,
))) {
$ops[$path] = l($path, $full_path, array(
'query' => drupal_get_destination(),
));
}
}
}
}
return $ops;
}