
function scJQGeneralAdd() {
  $('input:text.sc-js-input').listen();
  $('input:password.sc-js-input').listen();
  $('textarea.sc-js-input').listen();

} // scJQGeneralAdd

function scFocusField(sField) {
  var $oField = $('#id_sc_field_' + sField);

  if (0 == $oField.length) {
    $oField = $('input[name=' + sField + ']');
  }

  if (0 == $oField.length && document.F1.elements[sField]) {
    $oField = $(document.F1.elements[sField]);
  }

  if (0 < $oField.length && 0 < $oField[0].offsetHeight && 0 < $oField[0].offsetWidth && !$oField[0].disabled) {
    $oField[0].focus();
  }
} // scFocusField

function scJQEventsAdd(iSeqRow) {
  $('#id_sc_field_case_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_case__onblur(this, iSeqRow) })
                                   .bind('change', function() { sc_billing_n3case_edit_grid_case__onchange(this, iSeqRow) })
                                   .bind('focus', function() { sc_billing_n3case_edit_grid_case__onfocus(this, iSeqRow) });
  $('#id_sc_field_suffix_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_suffix__onblur(this, iSeqRow) })
                                     .bind('change', function() { sc_billing_n3case_edit_grid_suffix__onchange(this, iSeqRow) })
                                     .bind('focus', function() { sc_billing_n3case_edit_grid_suffix__onfocus(this, iSeqRow) });
  $('#id_sc_field_type_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_type__onblur(this, iSeqRow) })
                                   .bind('change', function() { sc_billing_n3case_edit_grid_type__onchange(this, iSeqRow) })
                                   .bind('focus', function() { sc_billing_n3case_edit_grid_type__onfocus(this, iSeqRow) });
  $('#id_sc_field_status_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_status__onblur(this, iSeqRow) })
                                     .bind('change', function() { sc_billing_n3case_edit_grid_status__onchange(this, iSeqRow) })
                                     .bind('focus', function() { sc_billing_n3case_edit_grid_status__onfocus(this, iSeqRow) });
  $('#id_sc_field_pafdot_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_pafdot__onblur(this, iSeqRow) })
                                     .bind('change', function() { sc_billing_n3case_edit_grid_pafdot__onchange(this, iSeqRow) })
                                     .bind('focus', function() { sc_billing_n3case_edit_grid_pafdot__onfocus(this, iSeqRow) });
  $('#id_sc_field_dye_lot_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_dye_lot__onblur(this, iSeqRow) })
                                      .bind('change', function() { sc_billing_n3case_edit_grid_dye_lot__onchange(this, iSeqRow) })
                                      .bind('focus', function() { sc_billing_n3case_edit_grid_dye_lot__onfocus(this, iSeqRow) });
  $('#id_sc_field_pafdos_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_pafdos__onblur(this, iSeqRow) })
                                     .bind('change', function() { sc_billing_n3case_edit_grid_pafdos__onchange(this, iSeqRow) })
                                     .bind('focus', function() { sc_billing_n3case_edit_grid_pafdos__onfocus(this, iSeqRow) });
  $('#id_sc_field_p_o_number_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_p_o_number__onblur(this, iSeqRow) })
                                         .bind('change', function() { sc_billing_n3case_edit_grid_p_o_number__onchange(this, iSeqRow) })
                                         .bind('focus', function() { sc_billing_n3case_edit_grid_p_o_number__onfocus(this, iSeqRow) });
  $('#id_sc_field_grwt_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_grwt__onblur(this, iSeqRow) })
                                   .bind('change', function() { sc_billing_n3case_edit_grid_grwt__onchange(this, iSeqRow) })
                                   .bind('focus', function() { sc_billing_n3case_edit_grid_grwt__onfocus(this, iSeqRow) });
  $('#id_sc_field_trwt_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_trwt__onblur(this, iSeqRow) })
                                   .bind('change', function() { sc_billing_n3case_edit_grid_trwt__onchange(this, iSeqRow) })
                                   .bind('focus', function() { sc_billing_n3case_edit_grid_trwt__onfocus(this, iSeqRow) });
  $('#id_sc_field_ndate_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_ndate__onblur(this, iSeqRow) })
                                    .bind('change', function() { sc_billing_n3case_edit_grid_ndate__onchange(this, iSeqRow) })
                                    .bind('focus', function() { sc_billing_n3case_edit_grid_ndate__onfocus(this, iSeqRow) });
  $('#id_sc_field_bl_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_bl__onblur(this, iSeqRow) })
                                 .bind('change', function() { sc_billing_n3case_edit_grid_bl__onchange(this, iSeqRow) })
                                 .bind('focus', function() { sc_billing_n3case_edit_grid_bl__onfocus(this, iSeqRow) });
  $('#id_sc_field_style_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_style__onblur(this, iSeqRow) })
                                    .bind('change', function() { sc_billing_n3case_edit_grid_style__onchange(this, iSeqRow) })
                                    .bind('focus', function() { sc_billing_n3case_edit_grid_style__onfocus(this, iSeqRow) });
  $('#id_sc_field_color_no_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_color_no__onblur(this, iSeqRow) })
                                       .bind('change', function() { sc_billing_n3case_edit_grid_color_no__onchange(this, iSeqRow) })
                                       .bind('focus', function() { sc_billing_n3case_edit_grid_color_no__onfocus(this, iSeqRow) });
  $('#id_sc_field_shade_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_shade__onblur(this, iSeqRow) })
                                    .bind('change', function() { sc_billing_n3case_edit_grid_shade__onchange(this, iSeqRow) })
                                    .bind('focus', function() { sc_billing_n3case_edit_grid_shade__onfocus(this, iSeqRow) });
  $('#id_sc_field_color_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_color__onblur(this, iSeqRow) })
                                    .bind('change', function() { sc_billing_n3case_edit_grid_color__onchange(this, iSeqRow) })
                                    .bind('focus', function() { sc_billing_n3case_edit_grid_color__onfocus(this, iSeqRow) });
  $('#id_sc_field_width_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_width__onblur(this, iSeqRow) })
                                    .bind('change', function() { sc_billing_n3case_edit_grid_width__onchange(this, iSeqRow) })
                                    .bind('focus', function() { sc_billing_n3case_edit_grid_width__onfocus(this, iSeqRow) });
  $('#id_sc_field_grade_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_grade__onblur(this, iSeqRow) })
                                    .bind('change', function() { sc_billing_n3case_edit_grid_grade__onchange(this, iSeqRow) })
                                    .bind('focus', function() { sc_billing_n3case_edit_grid_grade__onfocus(this, iSeqRow) });
  $('#id_sc_field_pcs_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_pcs__onblur(this, iSeqRow) })
                                  .bind('change', function() { sc_billing_n3case_edit_grid_pcs__onchange(this, iSeqRow) })
                                  .bind('focus', function() { sc_billing_n3case_edit_grid_pcs__onfocus(this, iSeqRow) });
  $('#id_sc_field_lbs_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_lbs__onblur(this, iSeqRow) })
                                  .bind('change', function() { sc_billing_n3case_edit_grid_lbs__onchange(this, iSeqRow) })
                                  .bind('focus', function() { sc_billing_n3case_edit_grid_lbs__onfocus(this, iSeqRow) });
  $('#id_sc_field_yds_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_yds__onblur(this, iSeqRow) })
                                  .bind('change', function() { sc_billing_n3case_edit_grid_yds__onchange(this, iSeqRow) })
                                  .bind('focus', function() { sc_billing_n3case_edit_grid_yds__onfocus(this, iSeqRow) });
  $('#id_sc_field_sm_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_sm__onblur(this, iSeqRow) })
                                 .bind('change', function() { sc_billing_n3case_edit_grid_sm__onchange(this, iSeqRow) })
                                 .bind('focus', function() { sc_billing_n3case_edit_grid_sm__onfocus(this, iSeqRow) });
  $('#id_sc_field_invoice_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_invoice__onblur(this, iSeqRow) })
                                      .bind('change', function() { sc_billing_n3case_edit_grid_invoice__onchange(this, iSeqRow) })
                                      .bind('focus', function() { sc_billing_n3case_edit_grid_invoice__onfocus(this, iSeqRow) });
  $('#id_sc_field_it_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_it__onblur(this, iSeqRow) })
                                 .bind('change', function() { sc_billing_n3case_edit_grid_it__onchange(this, iSeqRow) })
                                 .bind('focus', function() { sc_billing_n3case_edit_grid_it__onfocus(this, iSeqRow) });
  $('#id_sc_field_smit_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_smit__onblur(this, iSeqRow) })
                                   .bind('change', function() { sc_billing_n3case_edit_grid_smit__onchange(this, iSeqRow) })
                                   .bind('focus', function() { sc_billing_n3case_edit_grid_smit__onfocus(this, iSeqRow) });
  $('#id_sc_field_loc_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_loc__onblur(this, iSeqRow) })
                                  .bind('change', function() { sc_billing_n3case_edit_grid_loc__onchange(this, iSeqRow) })
                                  .bind('focus', function() { sc_billing_n3case_edit_grid_loc__onfocus(this, iSeqRow) });
  $('#id_sc_field_bin_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_bin__onblur(this, iSeqRow) })
                                  .bind('change', function() { sc_billing_n3case_edit_grid_bin__onchange(this, iSeqRow) })
                                  .bind('focus', function() { sc_billing_n3case_edit_grid_bin__onfocus(this, iSeqRow) });
  $('#id_sc_field_id2_' + iSeqRow).bind('blur', function() { sc_billing_n3case_edit_grid_id2__onblur(this, iSeqRow) })
                                  .bind('change', function() { sc_billing_n3case_edit_grid_id2__onchange(this, iSeqRow) })
                                  .bind('focus', function() { sc_billing_n3case_edit_grid_id2__onfocus(this, iSeqRow) });
} // scJQEventsAdd

function sc_billing_n3case_edit_grid_case__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_case_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_case__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_case__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_suffix__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_suffix_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_suffix__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_suffix__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_type__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_type_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_type__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_type__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_status__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_status_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_status__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_status__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_pafdot__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_pafdot_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_pafdot__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_pafdot__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_dye_lot__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_dye_lot_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_dye_lot__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_dye_lot__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_pafdos__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_pafdos_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_pafdos__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_pafdos__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_p_o_number__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_p_o_number_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_p_o_number__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_p_o_number__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_grwt__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_grwt_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_grwt__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_grwt__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_trwt__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_trwt_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_trwt__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_trwt__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_ndate__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_ndate_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_ndate__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_ndate__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_bl__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_bl_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_bl__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_bl__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_style__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_style_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_style__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_style__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_color_no__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_color_no_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_color_no__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_color_no__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_shade__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_shade_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_shade__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_shade__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_color__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_color_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_color__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_color__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_width__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_width_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_width__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_width__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_grade__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_grade_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_grade__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_grade__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_pcs__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_pcs_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_pcs__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_pcs__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_lbs__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_lbs_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_lbs__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_lbs__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_yds__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_yds_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_yds__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_yds__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_sm__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_sm_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_sm__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_sm__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_invoice__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_invoice_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_invoice__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_invoice__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_it__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_it_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_it__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_it__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_smit__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_smit_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_smit__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_smit__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_loc__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_loc_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_loc__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_loc__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_bin__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_bin_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_bin__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_bin__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_id2__onblur(oThis, iSeqRow) {
  do_ajax_billing_n3case_edit_grid_validate_id2_(iSeqRow);
  scCssBlur(oThis, iSeqRow);
}

function sc_billing_n3case_edit_grid_id2__onchange(oThis, iSeqRow) {
  nm_check_insert(iSeqRow);
}

function sc_billing_n3case_edit_grid_id2__onfocus(oThis, iSeqRow) {
  scCssFocus(oThis, iSeqRow);
}

var sc_jq_calendar_value = {};

function scJQCalendarAdd(iSeqRow) {
  $("#id_sc_field_ndate_" + iSeqRow).datepicker({
    beforeShow: function(input, inst) {
      var $oField = $(this),
          aParts  = $oField.val().split(" "),
          sTime   = "";
      sc_jq_calendar_value["#id_sc_field_ndate_" + iSeqRow] = $oField.val();
    },
    onClose: function(dateText, inst) {
    },
    showWeek: true,
    numberOfMonths: 1,
    changeMonth: true,
    changeYear: true,
    yearRange: 'c-5:c+5',
    dayNames: ['<?php        echo html_entity_decode($this->Ini->Nm_lang['lang_days_sund']);        ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_days_mond']);        ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_days_tued']);        ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_days_wend']);        ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_days_thud']);        ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_days_frid']);        ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_days_satd']);        ?>'],
    dayNamesMin: ['<?php     echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_sund']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_mond']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_tued']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_wend']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_thud']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_frid']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_substr_days_satd']); ?>'],
    monthNamesShort: ['<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_janu']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_febr']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_marc']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_apri']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_mayy']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_june']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_july']);   ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_augu']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_sept']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_octo']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_nove']); ?>','<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_mnth_dece']); ?>'],
    weekHeader: "<?php echo html_entity_decode($this->Ini->Nm_lang['lang_shrt_days_sem']); ?>",
    firstDay: <?php echo $this->jqueryCalendarWeekInit("" . $_SESSION['scriptcase']['reg_conf']['date_week_ini'] . ""); ?>,
    dateFormat: "<?php echo $this->jqueryCalendarDtFormat("" . str_replace(array('/', 'aaaa', $_SESSION['scriptcase']['reg_conf']['date_sep']), array('', 'yyyy', ''), $this->field_config['ndate_']['date_format']) . "", "" . $_SESSION['scriptcase']['reg_conf']['date_sep'] . ""); ?>",
    showOtherMonths: true,
    showOn: "button",
    buttonImage: "<?php echo $this->jqueryIconFile('calendar'); ?>",
    buttonImageOnly: true
  });

} // scJQCalendarAdd

function scJQUploadAdd(iSeqRow) {
} // scJQUploadAdd


function scJQElementsAdd(iLine) {
  scJQEventsAdd(iLine);
  scJQCalendarAdd(iLine);
  scJQUploadAdd(iLine);
} // scJQElementsAdd

