You are here

function _uc_file_download_table_behavior in Ubercart 6.2

Same name and namespace in other branches
  1. 7.3 uc_file/uc_file.module \_uc_file_download_table_behavior()

Attaches jQuery behaviors for each of the rows on the file download modification table.

1 call to _uc_file_download_table_behavior()
uc_file_user_form in uc_file/uc_file.module
Form builder for per-user file download administration.

File

uc_file/uc_file.module, line 415

Code

function _uc_file_download_table_behavior($id, $fid) {
  drupal_add_js("\nDrupal.behaviors.ucUserAccountFileDownload" . $id . " = function(context) {\n  \$('#edit-file-download-" . $fid . "-time-granularity:not(.ucUserAccountFileDownload-processed)', context).addClass('ucUserAccountFileDownload-processed').change(\n    function() {\n      _uc_file_expiration_disable_check('#edit-file-download-" . $fid . "-time-granularity', '#edit-file-download-" . $fid . "-time-quantity');\n      _uc_file_expiration_disable_check('#edit-file-download-" . $fid . "-time-granularity', '#edit-file-download-" . $fid . "-time-polarity');\n    }\n  );\n}", 'inline');
}