Questions and discussion about using ProcessMaker: user interface, running cases & functionality

Moderator: amosbatto

User avatar
By kram327
#825996
I don't understand why the grid setValue doesn't work for some entries. Can somebody help me figure out why?

Loan Type = Establishment
Facility Type = Non Omnibus

grid setValue works when either one of the following values (FACILITY field) is selected:
1. DOMESTIC LETTER OF CREDIT (LC)/ TRUST RECEIPT (TR) LINE
2. IMPORT LETTER OF CREDIT (LC)/ TRUST RECEIPT (TR) LINE
3. IMPORT/ DOMESTIC LETTER OF CREDIT (LC)/ TRUST RECEIPT (TR) LINE
4. LETTER OF CREDIT (LC)/ TRUST RECEIPT (TR) LINE

grid setValue does not work when either one of the following values (FACILITY field) is selected:
1. TERM LOAN
2. SHORT TERM LOAN


Code: Select all
if (newVal == 'LOAN LINE') {
				$("#form\\[GRID_NON_FACILITY\\]\\[" + nRow + "\\]\\[NON_PN\\]").attr("disabled", false);
              	$("#form\\[GRID_NON_FACILITY\\]\\[" + nRow + "\\]\\[NON_PRINCIPAL_REPAYMENT\\]").attr("disabled", false);
              	$("#form\\[GRID_NON_FACILITY\\]\\[" + nRow + "\\]\\[NON_INTEREST\\]").attr("disabled", false);
              	$("#GRID_NON_FACILITY").setValue("Via Peso PN", nRow, 13);
              	$("#GRID_NON_FACILITY").setValue("Up to ____ days; renewable / extendible for another ____days\n\n\
(Note if with assignment, Tenor: Co-terminus with contract date)", nRow, 17);
              	$("#GRID_NON_FACILITY").setValue("Prevailing SBC lending rate; subject to _____ (monthly or periodic) setting and payment in ____(arrears or in advance)", nRow, 22);
            }

else if (newVal == 'SHORT TERM LOAN') {
              	$("#form\\[GRID_NON_FACILITY\\]\\[" + nRow + "\\]\\[NON_TERM\\]").attr("disabled", false);
              	$("#form\\[GRID_NON_FACILITY\\]\\[" + nRow + "\\]\\[NON_INTEREST\\]").attr("disabled", false);
              	$("#GRID_NON_FACILITY").setValue("For working capital requirements", nRow, 5);
              	$("#GRID_NON_FACILITY").setValue("(If tenor is 180 days or more, LAA should follow the appropriate facility wordings)", nRow, 17);
              	$("#GRID_NON_FACILITY").setValue("For working capital requirements", nRow, 22);
            }
Attachments
(13.89 KiB) Downloaded 12 times
(215.86 KiB) Downloaded 12 times
User avatar
By amosbatto
#826020
I don't see any obvious errors in your code, but it is impossible for me to debug your form when you didn't include the PM Table used in the database query.
Cannot upload CSV

Hi, I am using a multi-file upload. When I upload[…]

A Beginner's Guide for ProcessMaker

I recently completed a book on ProcessMaker - &q[…]

Hi guys. I am a newbie. I don't know how to upgrad[…]

HI Thanks so much! This is just what I need.