diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/10.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/10.json index 46f4bf5..b94f412 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/10.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/10.json @@ -245,190 +245,7 @@ } ] }, - { - "question":"Broken Period starting from (Month)", - "question_key":"broken_period_from_month", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"Broken Period starting to (Month)", - "question_key":"broken_period_to_month", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"No of Months", - "question_key":"broken_period_no_of_months", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] - }, - { - "question":"Turnover for Broken Period in CY (Rs)", - "question_key":"broken_period_turnover_cy", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"numtoword", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] - }, - { - "question":"Turnover for Broken Period in PY (Rs)", - "question_key":"broken_period_turnover_py", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"numtoword", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] - }, - { - "question":"Increase / Decrease in Turnover for Broken Period %", - "question_key":"broken_period_turnover_percent", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"Sales / Revenue (Rs) for the broken period of the Current FY as per applicant", - "question_key":"broken_period_sales_amount", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] - }, - { - "question":"Net Profit / (Net Loss) (Rs) for the broken period of the Current FY as per applicant ", - "question_key":"broken_period_netprofit_amount", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] - }, - { - "question":"% of Net Profit / (Net Loss) over Sales for the broken period of the Current FY as per applicant ", - "question_key":"broken_period_netprofit_percent", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, + { "question":"Debtor Days as per CET", "sub_title":"In Case of credit sales, what is the average no. of days taken to receive the money?", @@ -553,110 +370,8 @@ "value":null } - ] - }, - { - "question":"Does the business have any working capital facility from any lender other than Moneywise?", - "question_key":"is_any_other_working_captial_facility", - "type":"2", - "field_width":"45", - "answers":[ - { - "answer":"Yes", - "answer_id":"Yes" - }, - { - "answer":"No", - "answer_id":"No" - } - ], - "api_properties":null, - "onchange_properties":[ - { - "purpose":"FORM_CTRL", - "form_controls":[ - { - "insert_index":"is_any_other_working_captial_facility", - "expression":"(String('is_any_other_working_captial_facility') === String('Yes'))", - "value_keys":[ - "is_any_other_working_captial_facility" - ], - "questions":[ - { - "question":"Facility details i.e. Letter of Credit/ Bank guarantee, CC limit etc.", - "question_key":"facility_details_other_lender", - "type":"3", - "field_width":"45", - "answers":[ - { - "answer":"Letter of Credit", - "answer_id":"Letter of Credit" - }, - { - "answer":"Bank guarantee", - "answer_id":"Bank guarantee" - }, - { - "answer":"CC limit", - "answer_id":"CC limit" - } - ], - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"is_any_other_working_captial_facility", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"Details of above facilities need to be entered", - "question_key":"facility_details_specify", - "type":"7", - "placeholder":"Enter the text", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"is_any_other_working_captial_facility", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - } - ] - } - ] - } - ], - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] } - ], @@ -665,13 +380,298 @@ "group_title":"Financial Information" }, { - "question":[ + "question":"Broken Period starting from (Month)", + "question_key":"broken_period_from_month", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Broken Period starting to (Month)", + "question_key":"broken_period_to_month", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"No of Months", + "question_key":"broken_period_no_of_months", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Turnover for Broken Period in CY (Rs)", + "question_key":"broken_period_turnover_cy", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"numtoword", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Turnover for Broken Period in PY (Rs)", + "question_key":"broken_period_turnover_py", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"numtoword", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Increase / Decrease in Turnover for Broken Period %", + "question_key":"broken_period_turnover_percent", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Sales / Revenue (Rs) for the broken period of the Current FY as per applicant", + "question_key":"broken_period_sales_amount", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Net Profit / (Net Loss) (Rs) for the broken period of the Current FY as per applicant ", + "question_key":"broken_period_netprofit_amount", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"% of Net Profit / (Net Loss) over Sales for the broken period of the Current FY as per applicant ", + "question_key":"broken_period_netprofit_percent", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Does the business have any working capital facility from any lender other than Moneywise?", + "question_key":"is_any_other_working_captial_facility", + "type":"2", + "field_width":"45", + "answers":[ + { + "answer":"Yes", + "answer_id":"Yes" + }, + { + "answer":"No", + "answer_id":"No" + } + ], + "api_properties":null, + "onchange_properties":[ + { + "purpose":"FORM_CTRL", + "form_controls":[ + { + "insert_index":"is_any_other_working_captial_facility", + "expression":"(String('is_any_other_working_captial_facility') === String('Yes'))", + "value_keys":[ + "is_any_other_working_captial_facility" + ], + "questions":[ + { + "question":"Facility details i.e. Letter of Credit/ Bank guarantee, CC limit etc.", + "question_key":"facility_details_other_lender", + "type":"3", + "field_width":"45", + "answers":[ + { + "answer":"Letter of Credit", + "answer_id":"Letter of Credit" + }, + { + "answer":"Bank guarantee", + "answer_id":"Bank guarantee" + }, + { + "answer":"CC limit", + "answer_id":"CC limit" + } + ], + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "is_subfield":"1", + "parent_question_key":"is_any_other_working_captial_facility", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Details of above facilities need to be entered", + "question_key":"facility_details_specify", + "type":"7", + "placeholder":"Enter the text", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "is_subfield":"1", + "parent_question_key":"is_any_other_working_captial_facility", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + } + ] + } + ] + } + ], + "is_repeatable":null, + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + + { "question":"Sales / Revenue (Rs)", + "sub_title":"Particulars of Financials for Latest Year as per person met during PD visit", "question_key":"sales_amount", "place_holder":"Enter text", "type":"1", - "field_width":"45", + "field_width":"100", "field_type":"numtoword", "api_properties":null, "answers":null, @@ -771,10 +771,6 @@ } ] } - ], - "is_repeatable":"1", - "group_title":"Particulars of Financials for Latest Year as per person met during PD visit", - "group_key":"financial_particulars" - } + ] } \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/15.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/15.json index db2dd99..fe79dac 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/15.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/15.json @@ -1,239 +1,219 @@ { - "section_id":"15", - "section_name":"Existing Loan Obligations", - "onsubmit":null, - "questions":[ + "section_id": "15", + "section_name": "Existing Loan Obligations", + "onsubmit": null, + "questions": [ { - "question":[{ - "question":"Loan type", - "question_key":"loan_type", - "type":"1", - "field_width":"100", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Loan amount", - "question_key":"loan_amount", - "type":"1", - "field_type":"num", - "field_width":"100", - "onchange_properties":null, - "api_properties":null, - "answers":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Lender name", - "question_key":"lender_name", - "type":"1", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Loan taken by", - "question_key":"loan_taken_by", - "type":"1", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Monthly Obligations", - "question_key":"monthly_obligations", - "type":"1", - "field_type":"num", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - - { - "question":"Instalment Amount", - "question_key":"instalment_amount", - "type":"1", - "field_width":"100", - "field_type":"numtoword", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Installment frequency", - "question_key":"instalment_frequency", - "type":"3", - "field_width":"100", - "api_properties":null, - "answers":[ - { - "answer_id":"Daily", - "answer":"Daily" - }, - { - "answer_id":"Every 12 days", - "answer":"Every 12 days" - }, - { - "answer_id":"Every 15 days", - "answer":"Every 15 days" - }, - { - "answer_id":"Monthly", - "answer":"Monthly" - }, - { - "answer_id":"Every 3 months", - "answer":"Every 3 months" - }, - { - "answer_id":"Every 6 months", - "answer":"Every 6 months" - }, - { - "answer_id":"Yearly", - "answer":"Yearly" - } - ], - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Original tenure in months", - "question_key":"original_tenure_months", - "type":"1", - "field_width":"100", - "field_type":"num", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Current balance tenure in months", - "question_key":"current_tenure_months", - "type":"1", - "field_type":"num", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Elapsed tenure in mths", - "question_key":"elapsed_tenure_months", - "type":"1", - "field_width":"45", - "field_type":"num", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] + "question": [ + { + "question": "Loan type", + "question_key": "loan_type", + "type": "1", + "field_width": "100", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Loan amount", + "question_key": "loan_amount", + "type": "1", + "field_type": "num", + "field_width": "100", + "onchange_properties": null, + "api_properties": null, + "answers": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Lender name", + "question_key": "lender_name", + "type": "1", + "field_width": "100", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Loan taken by", + "question_key": "loan_taken_by", + "type": "1", + "field_width": "100", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Instalment Amount", + "question_key": "instalment_amount", + "type": "1", + "field_width": "100", + "field_type": "numtoword", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Installment frequency", + "question_key": "instalment_frequency", + "type": "3", + "field_width": "100", + "api_properties": null, + "answers": [ + { + "answer_id": "Daily", + "answer": "Daily" + }, + { + "answer_id": "Every 12 days", + "answer": "Every 12 days" + }, + { + "answer_id": "Every 15 days", + "answer": "Every 15 days" + }, + { + "answer_id": "Monthly", + "answer": "Monthly" + }, + { + "answer_id": "Every 3 months", + "answer": "Every 3 months" + }, + { + "answer_id": "Every 6 months", + "answer": "Every 6 months" + }, + { + "answer_id": "Yearly", + "answer": "Yearly" + } + ], + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Original tenure in months", + "question_key": "original_tenure_months", + "type": "1", + "field_width": "100", + "field_type": "num", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Current balance tenure in months", + "question_key": "current_tenure_months", + "type": "1", + "field_type": "num", + "field_width": "100", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Elapsed tenure in mths", + "question_key": "elapsed_tenure_months", + "type": "1", + "field_width": "45", + "field_type": "num", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + } + ], + "is_repeatable": "1", + "group_title": "Existing Loan Obligations", + "group_key": "existing_loan_details" } - ], - "is_repeatable":"1", - "group_title":"Existing Loan Obligations", - "group_key":"existing_loan_details"} - ] - } - \ No newline at end of file + ] +} \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/9.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/9.json index 23dce5f..f47f4ba 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/9.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/LFMP/9.json @@ -1,176 +1,108 @@ -{ - "section_id":"9", - "section_name":"Business and Personal Banking Details", - "onsubmit":[], - "questions":[ - { - "question":[ - { - "question": "Business Account holder name", - "question_key": "applicant_name", - "type": "1", - "api_properties": { - "purpose": "answer_options_local", - "master_name": "pd_applicants", - "fields": [ - "pd_co_applicant_id", - "applicant_name" - ] - }, - "answers": null, - "onchange_properties": null, - "is_repeatable": null, - "field_type": "string", - "validations": [ - { - "name": "required", - "isactive": "1", - "validator": "Validators.required", - "message": "Required", - "value": null - } - ] - }, - { - "question":"Bank Name", - "question_key":"bank_name", - "type":"1", - "field_width":"45", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Business Account type", - "question_key":"account_type", - "type":"1", - "field_width":"45", - "api_properties":{ - "api":"getListOfMaster", - "api_method":"POST", - "params":{ - "master_name":"ACCOUNTTYPE" - }, - "fields":[ - "bt_lender_list_id", - "lender_name" - ] +{ + "section_id": "9", + "section_name": "Business and Personal Banking Details", + "onsubmit": [], + "questions": [ + { + "question": [ + { + "question": "Business Account holder name", + "question_key": "applicant_name", + "type": "1", + "api_properties": { + "purpose": "answer_options_local", + "master_name": "pd_applicants", + "fields": [ + "pd_co_applicant_id", + "applicant_name" + ] + }, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "string", + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Required", + "value": null + } + ] }, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"OD/CC Limit", - "question_key":"cc_limit", - "type":"1", - "field_width":"45", - "field_type":"num", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Is this the main business account", - "question_key":"is_main", - "type":"1", - "field_width":"45", - "api_properties":null, - "answers":[ - { - "answer":"Select", - "answer_id":"" - }, - { - "answer":"Yes", - "answer_id":"Yes" - }, - { - "answer":"No", - "answer_id":"No" - } - ], - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"No of Years", - "sub_title":"Approximate vintage of the account", - "question_key":"vintage_year", - "place_holder":"", - "field_type":"num", - "type":"1", - "field_width":"100", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "answers":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - }, - { - "question":"No of Months", - "question_key":"vintage_month", - "place_holder":"", - "field_type":"num", - "type":"1", - "field_width":"45", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "answers":null, - "validations":[ - ] - } - ], - "is_repeatable":"1", - "group_title":"Banking Details", - "group_key":"banking_details" + { + "question": "Bank Name", + "question_key": "bank_name", + "type": "1", + "field_width": "45", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Business Account type", + "question_key": "account_type", + "type": "1", + "field_width": "45", + "api_properties": { + "api": "getListOfMaster", + "api_method": "POST", + "params": { + "master_name": "ACCOUNTTYPE" + }, + "fields": [ + "bt_lender_list_id", + "lender_name" + ] + }, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "OD/CC Limit", + "question_key": "cc_limit", + "type": "1", + "field_width": "45", + "field_type": "num", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + } + ], + "is_repeatable": "1", + "group_title": "Banking Details", + "group_key": "banking_details" } - ] - } \ No newline at end of file + ] +} \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/1.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/1.json index 7ad1c84..6179faf 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/1.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/1.json @@ -49,7 +49,56 @@ "field_width":"100", "api_properties":null, "answers":null, - "onchange_properties":null, + "onchange_properties":[{ + "purpose":"FORM_CTRL", + "form_controls":[ + { + "insert_index":"relationship", + "expression":"(String('entity_type').toLowerCase() == String('individual'))", + "value_keys":[ + "entity_type" + ], + "questions":[ + { + "question":"Met / Not Met", + "question_key":"borrower_met", + "type":"2", + "field_width":"100", + "api_properties":null, + "answers":[ + { + "answer_id":"Yes", + "answer":"Yes" + }, + { + "answer_id":"No", + "answer":"No" + } + ], + "onchange_properties":null, + "is_repeatable":null, + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Field Required", + "value":null + } + ] + } + ] + } + ] + }, + { + "purpose":"question_label", + "expression":"(function () {let label= '';(String('entity_type').toLowerCase().includes('individual')) ? label= 'Number of years the borrower has been in this business.' : label = 'Number of years for which the business has been running';return label}())", + "value_keys":[ + "entity_type" + ], + "insert_control":"numbers_of_years_business_running" + }], "is_repeatable":null, "validations":[ { @@ -118,38 +167,12 @@ } ] }, - { - "question":"Met / Not Met", - "question_key":"borrower_met", - "type":"2", - "field_width":"100", - "api_properties":null, - "answers":[ - { - "answer_id":"Yes", - "answer":"Yes" - }, - { - "answer_id":"No", - "answer":"No" - } - ], - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, + { "question":"Age", "question_key":"borrower_age", "type":"1", + "field_type":"num", "field_width":"45", "api_properties":null, "answers":null, @@ -170,6 +193,7 @@ "question_key":"numbers_of_years_business_running", "type":"1", "field_width":"45", + "field_type":"num", "api_properties":null, "answers":null, "onchange_properties":null, diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/10.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/10.json index 1eb7c13..b94f412 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/10.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/10.json @@ -73,7 +73,7 @@ "onchange_properties":[ { "purpose":"answer_value", - "expression":"(Number(net_profit)/Number(sales_revenue))*100", + "expression":"((Number(net_profit)/Number(sales_revenue))*100).toFixed(2)", "value_keys":[ "sales_revenue","net_profit" ], @@ -154,6 +154,7 @@ "question":"Net Profit or (Net Loss) to Sales % ", "question_key":"net_profit_sales_percent", "type":"1", + "is_disabled":"1", "field_width":"45", "answers":null, "api_properties":null, @@ -184,6 +185,7 @@ "question":"% (↑ /↓) in Sales over PY", "question_key":"sales_py", "type":"1", + "is_disabled":"1", "field_width":"45", "answers":null, "api_properties":null, @@ -204,6 +206,7 @@ "question":"% (↑ /↓) in Net Profit over PY", "question_key":"netprofit_py", "type":"1", + "is_disabled":"1", "field_width":"45", "answers":null, "api_properties":null, @@ -225,6 +228,7 @@ "question":"% (↑ /↓) in Net Profit % over PY", "question_key":"netprofit_py_percent", "type":"1", + "is_disabled":"1", "field_width":"45", "answers":null, "api_properties":null, @@ -241,139 +245,7 @@ } ] }, - { - "question":"Broken Period starting from (Month)", - "question_key":"broken_period_from_month", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - }, - { - "name":"pattern", - "isactive":"1", - "validator":"([0-9]*)", - "message":"Numeric only", - "value":null - } - - ] - }, - { - "question":"Broken Period starting to (Month)", - "question_key":"broken_period_to_month", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - }, - { - "name":"pattern", - "isactive":"1", - "validator":"([0-9]*)", - "message":"Numeric only", - "value":null - } - - ] - }, - { - "question":"Sales / Revenue (Rs) for the broken period of the Current FY as per applicant", - "question_key":"broken_period_sales_amount", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - }, - { - "name":"pattern", - "isactive":"1", - "validator":"([0-9]*)", - "message":"Numeric only", - "value":null - } - - ] - }, - { - "question":"Net Profit / (Net Loss) (Rs) for the broken period of the Current FY as per applicant ", - "question_key":"broken_period_netprofit_amount", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - }, - { - "name":"pattern", - "isactive":"1", - "validator":"([0-9]*)", - "message":"Numeric only", - "value":null - } - - ] - }, - { - "question":"% of Net Profit / (Net Loss) over Sales for the broken period of the Current FY as per applicant ", - "question_key":"broken_period_netprofit_percent", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, + { "question":"Debtor Days as per CET", "sub_title":"In Case of credit sales, what is the average no. of days taken to receive the money?", @@ -498,116 +370,407 @@ "value":null } - ] - }, - { - "question":"Does the business have any working capital facility from any lender other than Moneywise?", - "question_key":"is_any_other_working_captial_facility", - "type":"2", - "field_width":"45", - "answers":[ - { - "answer":"Yes", - "answer_id":"Yes" - }, - { - "answer":"No", - "answer_id":"No" - } - ], - "api_properties":null, - "onchange_properties":[ - { - "purpose":"FORM_CTRL", - "form_controls":[ - { - "insert_index":"is_any_other_working_captial_facility", - "expression":"(String('is_any_other_working_captial_facility') === String('Yes'))", - "value_keys":[ - "is_any_other_working_captial_facility" - ], - "questions":[ - { - "question":"Facility details i.e. Letter of Credit/ Bank guarantee, CC limit etc.", - "question_key":"facility_details_other_lender", - "type":"3", - "field_width":"45", - "answers":[ - { - "answer":"Letter of Credit", - "answer_id":"Letter of Credit" - }, - { - "answer":"Bank guarantee", - "answer_id":"Bank guarantee" - }, - { - "answer":"CC limit", - "answer_id":"CC limit" - } - ], - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"is_any_other_working_captial_facility", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"Details of above facilities need to be entered", - "question_key":"facility_details_specify", - "type":"7", - "placeholder":"Enter the text", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"is_any_other_working_captial_facility", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - } - ] - } - ] - } - ], - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] } - ], "is_repeatable":"1", "group_key":"financial_info", "group_title":"Financial Information" - } + }, + { + "question":"Broken Period starting from (Month)", + "question_key":"broken_period_from_month", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Broken Period starting to (Month)", + "question_key":"broken_period_to_month", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"No of Months", + "question_key":"broken_period_no_of_months", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Turnover for Broken Period in CY (Rs)", + "question_key":"broken_period_turnover_cy", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"numtoword", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Turnover for Broken Period in PY (Rs)", + "question_key":"broken_period_turnover_py", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"numtoword", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Increase / Decrease in Turnover for Broken Period %", + "question_key":"broken_period_turnover_percent", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Sales / Revenue (Rs) for the broken period of the Current FY as per applicant", + "question_key":"broken_period_sales_amount", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Net Profit / (Net Loss) (Rs) for the broken period of the Current FY as per applicant ", + "question_key":"broken_period_netprofit_amount", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"% of Net Profit / (Net Loss) over Sales for the broken period of the Current FY as per applicant ", + "question_key":"broken_period_netprofit_percent", + "type":"1", + "field_width":"45", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Does the business have any working capital facility from any lender other than Moneywise?", + "question_key":"is_any_other_working_captial_facility", + "type":"2", + "field_width":"45", + "answers":[ + { + "answer":"Yes", + "answer_id":"Yes" + }, + { + "answer":"No", + "answer_id":"No" + } + ], + "api_properties":null, + "onchange_properties":[ + { + "purpose":"FORM_CTRL", + "form_controls":[ + { + "insert_index":"is_any_other_working_captial_facility", + "expression":"(String('is_any_other_working_captial_facility') === String('Yes'))", + "value_keys":[ + "is_any_other_working_captial_facility" + ], + "questions":[ + { + "question":"Facility details i.e. Letter of Credit/ Bank guarantee, CC limit etc.", + "question_key":"facility_details_other_lender", + "type":"3", + "field_width":"45", + "answers":[ + { + "answer":"Letter of Credit", + "answer_id":"Letter of Credit" + }, + { + "answer":"Bank guarantee", + "answer_id":"Bank guarantee" + }, + { + "answer":"CC limit", + "answer_id":"CC limit" + } + ], + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "is_subfield":"1", + "parent_question_key":"is_any_other_working_captial_facility", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + { + "question":"Details of above facilities need to be entered", + "question_key":"facility_details_specify", + "type":"7", + "placeholder":"Enter the text", + "answers":null, + "api_properties":null, + "onchange_properties":null, + "is_repeatable":null, + "is_subfield":"1", + "parent_question_key":"is_any_other_working_captial_facility", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + } + ] + } + ] + } + ], + "is_repeatable":null, + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + + ] + }, + + { + "question":"Sales / Revenue (Rs)", + "sub_title":"Particulars of Financials for Latest Year as per person met during PD visit", + "question_key":"sales_amount", + "place_holder":"Enter text", + "type":"1", + "field_width":"100", + "field_type":"numtoword", + "api_properties":null, + "answers":null, + "onchange_properties":[ + { + "purpose":"answer_value", + "expression":"(function (){let final_value; Number(net_profit_to_sales_percent) ? final_value = (Number(sales_amount)*Number(net_profit_to_sales_percent))/100 : '';return final_value}())", + "value_keys":[ + "sales_amount", "net_profit_to_sales_percent" + ], + "insert_control":"net_profit_rs" + }, + { + "purpose":"answer_value", + "expression":"(function (){let final_value; Number(net_profit_rs) ? final_value = (Number(net_profit_rs)/Number(sales_amount))*100 : '';return final_value}())", + "value_keys":[ + "sales_amount", "net_profit_rs" + ], + "insert_control":"net_profit_to_sales_percent" + } + ], + "is_repeatable":null, + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + }, + { + "question":"Net Profit or (Net Loss) to Sales % ", + "question_key":"net_profit_to_sales_percent", + "place_holder":"Enter number", + "type":"1", + "field_width":"45", + "api_properties":null, + "answers":null, + "onchange_properties":[ + { + "purpose":"answer_value", + "expression":"(Number(sales_amount)*Number(net_profit_to_sales_percent))/100", + "value_keys":[ + "sales_amount", "net_profit_to_sales_percent" + ], + "insert_control":"net_profit_rs" + } + ], + "is_repeatable":null, + "field_type":"num", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + }, + { + "name":"max", + "validator":"100", + "isactive":"1", + "message":"Number must be less than 100", + "value":null + } + ] + }, + { + "question":"Net Profit / (Net Loss) (Rs)", + "question_key":"net_profit_rs", + "place_holder":"Enter the text", + "type":"1", + "field_width":"45", + "api_properties":null, + "answers":null, + "is_repeatable":null, + "field_type":"numtoword", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ], + "onchange_properties":[ + { + "purpose":"answer_value", + "expression":"(Number(net_profit_rs)/Number(sales_amount))*100", + "value_keys":[ + "sales_amount", "net_profit_rs" + ], + "insert_control":"net_profit_to_sales_percent" + } + ] + } + ] } \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/11.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/11.json index 684047f..135293a 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/11.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/11.json @@ -136,13 +136,6 @@ "parent_question_key":"supplier_info_available", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } ] }, { @@ -188,13 +181,6 @@ "parent_question_key":"supplier_info_available", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - }, { "name":"pattern", "isactive":"1", @@ -217,13 +203,6 @@ "parent_question_key":"supplier_info_available", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - }, { "name":"pattern", "isactive":"1", diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/12.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/12.json index 0304763..318e9b3 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/12.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/12.json @@ -136,13 +136,6 @@ "parent_question_key":"client_info_available", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } ] }, { @@ -188,13 +181,6 @@ "parent_question_key":"client_info_available", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - }, { "name":"pattern", "isactive":"1", @@ -217,13 +203,6 @@ "parent_question_key":"client_info_available", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - }, { "name":"pattern", "isactive":"1", diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/13.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/13.json index 084fde2..61777b9 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/13.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/13.json @@ -1,181 +1,350 @@ -{ - "section_id":"13", - "section_name":"Stock details", - "onsubmit":[], - "questions":[ - { - "question":[ - { - "question":"Name of trading goods/manufacturing goods (raw material/finished goods)/ Service Provided", - "question_key":"provider_name", - "place_holder":"Enter text", - "type":"1", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"string", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ] - }, - { - "question":"Stock", - "question_key":"provider_observed", - "type":"3", - "api_properties":null, - "answers":[ - { - "answer":"Add Stock Details", - "answer_id":"yes" - }, - { - "answer":"No Stock Observed", - "answer_id":"no" - } - ], - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - ], - "onchange_properties": [ { - "purpose":"FORM_CTRL", - "form_controls":[ +{ + "section_id": "13", + "section_name": "Stock details", + "onsubmit": [], + "questions": [ + { + "question": "Is stock applicable to the business (Yes / No)", + "question_key": "stock_info_available", + "type": "2", + "field_width": "45", + "api_properties": null, + "onchange_properties": [ + { + "purpose": "FORM_CTRL", + "form_controls": [ + { + "insert_index": "stock_info_available", + "expression": "(String('stock_info_available') == String('No'))", + "value_keys": [ + "stock_info_available" + ], + "questions": [ { - "insert_index":"provider_observed", - "expression":"(String('provider_observed') === String('yes'))", - "value_keys":[ - "provider_observed" - ], - "questions":[ - { - "question":"Estimated Quantity", - "question_key":"estimated_quantity", - "type":"1", - "field_width":"100", - "field_type":"num", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"provider_observed", - "answers":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - } , - { - "question":"UOM", - "question_key":"estimated_uom", - "type":"3", - "field_width":"100", - "api_properties":{ - "api":"getListOfMaster", - "api_method":"POST", - "params":{ - "master_name":"UOM" - }, - "fields":[ - "uom_id", - "name" - ] - }, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"provider_observed", - "answers":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - } , - { - "question":"Estimated value of stock observed", - "question_key":"estimated_stock_value", - "type":"1", - "field_type":"num", - "field_width":"100", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"provider_observed", - "answers":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - } - ] } ] }] - } - ], - "is_repeatable":"1", - "group_title":"Stock details", - "group_key":"stock_details" - }, - - { - "question":"Is the stock of finished goods observed, sufficient considering the size of operations", - "question_key":"estimated_uom", - "type":"3", - "field_width":"100", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "is_subfield":"1", - "parent_question_key":"provider_observed", - "answers":[ - { - "answer":"Yes", - "answer_id":"yes" + "question": "Reason", + "question_key": "stock_not_available_reason", + "type": "7", + "field_width": "100", + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "is_subfield": "1", + "parent_question_key": "stock_info_available", + "answers": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field required", + "value": null + } + ] + } + ] + } + ] }, { - "answer":"No", - "answer_id":"no" - }, - { - "answer":"Stock not required to be maintained", - "answer_id":"not applicable" + "purpose": "FORM_CTRL", + "form_controls": [ + { + "insert_index": "stock_info_available", + "expression": "(String('stock_info_available') == String('Yes'))", + "value_keys": [ + "stock_info_available" + ], + "questions":[ + { + "question": "Is the stock of finished goods observed, sufficient considering the size of operations", + "question_key": "estimated_uom", + "type": "3", + "field_width": "100", + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "is_subfield": "1", + "parent_question_key": "stock_info_available", + "answers": [ + { + "answer": "Yes", + "answer_id": "yes" + }, + { + "answer": "No", + "answer_id": "no" + }, + { + "answer": "Stock not required to be maintained", + "answer_id": "not applicable" + } + ], + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field required", + "value": null + } + ] + } + ] + }, + { + "insert_index": "stock_info_available", + "expression": "(String('stock_info_available') == String('Yes'))", + "value_keys": [ + "stock_info_available" + ], + "questions": [ + { + "question": [ + { + "question": "Type of Stock", + "question_key": "stock_type", + "type": "3", + "field_width": "100", + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "is_subfield": "1", + "parent_question_key": "stock_info_available", + "answers": [ + { + "answer": "RM", + "answer_id": "RM" + }, + { + "answer": "FG", + "answer_id": "FG" + }, + { + "answer": "SFG", + "answer_id": "SFG" + } + ], + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field required", + "value": null + } + ] + }, + { + "question": "Name of trading goods/manufacturing goods (raw material/finished goods)/ Service Provided", + "question_key": "provider_name", + "place_holder": "Enter text", + "type": "1", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "string", + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Required", + "value": null + } + ] + }, + { + "question": "Stock", + "question_key": "provider_observed", + "type": "3", + "api_properties": null, + "answers": [ + { + "answer": "Add Stock Details", + "answer_id": "yes" + }, + { + "answer": "No Stock Observed", + "answer_id": "no" + } + ], + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Required", + "value": null + } + ], + "onchange_properties": [ + { + "purpose": "FORM_CTRL", + "form_controls": [ + { + "insert_index": "provider_observed", + "expression": "(String('provider_observed') === String('yes'))", + "value_keys": [ + "provider_observed" + ], + "questions": [ + { + "question": "Estimated Quantity", + "question_key": "estimated_quantity", + "type": "1", + "field_width": "100", + "field_type": "num", + "api_properties": null, + "onchange_properties": [ + { + "purpose": "validations", + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "", + "message": "Required", + "value": "(String('estimated_quantity') != String('')) || (String('estimated_stock_value') != String('')) ", + "validation_to": null, + "value_keys": [ + "estimated_quantity", + "estimated_stock_value" + ] + }, + { + "name": "required", + "isactive": "1", + "validator": "", + "message": "Required", + "value": "(String('estimated_quantity') != String('')) || (String('estimated_stock_value') != String('')) ", + "validation_to": "estimated_stock_value", + "value_keys": [ + "estimated_quantity", + "estimated_stock_value" + ] + } + ] + } + ], + "is_repeatable": null, + "is_subfield": "1", + "parent_question_key": "provider_observed", + "answers": null, + "validations": [] + }, + { + "question": "UOM", + "question_key": "estimated_uom", + "type": "3", + "field_width": "100", + "api_properties": { + "api": "getListOfMaster", + "api_method": "POST", + "params": { + "master_name": "UOM" + }, + "fields": [ + "uom_id", + "name" + ] + }, + "onchange_properties": null, + "is_repeatable": null, + "is_subfield": "1", + "parent_question_key": "provider_observed", + "answers": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field required", + "value": null + } + ] + }, + { + "question": "Estimated value of stock observed", + "question_key": "estimated_stock_value", + "type": "1", + "field_type": "num", + "field_width": "100", + "api_properties": null, + "onchange_properties": [ + { + "purpose": "validations", + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "", + "message": "Required", + "value": "(String('estimated_quantity') != String('')) || (String('estimated_stock_value') != String('')) ", + "validation_to": null, + "value_keys": [ + "estimated_quantity", + "estimated_stock_value" + ] + }, + { + "name": "required", + "isactive": "1", + "validator": "", + "message": "Required", + "value": "(String('estimated_quantity') != String('')) || (String('estimated_stock_value') != String('')) ", + "validation_to": "estimated_quantity", + "value_keys": [ + "estimated_quantity", + "estimated_stock_value" + ] + } + ] + } + ], + "is_repeatable": null, + "is_subfield": "1", + "parent_question_key": "provider_observed", + "answers": null, + "validations": [] + } + ] + } + ] + } + ] + } + ], + "is_repeatable": "1", + "group_title": "Stock details", + "group_key": "stock_details" + } + ] + } + ] } - ], - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - } - ] - } \ No newline at end of file + ], + "is_repeatable": null, + "answers": [ + { + "answer": "Yes", + "answer_id": "Yes" + }, + { + "answer": "No", + "answer_id": "No" + } + ], + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field required", + "value": null + } + ] + } + ] +} \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/15.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/15.json index 644a16a..fe79dac 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/15.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/15.json @@ -1,188 +1,219 @@ { - "section_id":"15", - "section_name":"Existing Loan Obligations", - "onsubmit":null, - "questions":[ + "section_id": "15", + "section_name": "Existing Loan Obligations", + "onsubmit": null, + "questions": [ { - "question":[{ - "question":"Loan type", - "question_key":"loan_type", - "type":"1", - "field_width":"100", - "answers":null, - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Loan amount", - "question_key":"loan_amount", - "type":"1", - "field_type":"num", - "field_width":"100", - "onchange_properties":null, - "api_properties":null, - "answers":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Lender name", - "question_key":"lender_name", - "type":"1", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Loan taken by", - "question_key":"loan_taken_by", - "type":"1", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Instalment Amount", - "question_key":"instalment_amount", - "type":"1", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Installment frequency", - "question_key":"instalment_frequency", - "type":"1", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Original tenure in months", - "question_key":"original_tenure_months", - "type":"1", - "field_width":"100", - "field_type":"num", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Current balance tenure in months", - "question_key":"current_tenure_months", - "type":"1", - "field_type":"num", - "field_width":"100", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Elapsed tenure in mths", - "question_key":"elapsed_tenure_months", - "type":"1", - "field_width":"45", - "field_type":"num", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] + "question": [ + { + "question": "Loan type", + "question_key": "loan_type", + "type": "1", + "field_width": "100", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Loan amount", + "question_key": "loan_amount", + "type": "1", + "field_type": "num", + "field_width": "100", + "onchange_properties": null, + "api_properties": null, + "answers": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Lender name", + "question_key": "lender_name", + "type": "1", + "field_width": "100", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Loan taken by", + "question_key": "loan_taken_by", + "type": "1", + "field_width": "100", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Instalment Amount", + "question_key": "instalment_amount", + "type": "1", + "field_width": "100", + "field_type": "numtoword", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Installment frequency", + "question_key": "instalment_frequency", + "type": "3", + "field_width": "100", + "api_properties": null, + "answers": [ + { + "answer_id": "Daily", + "answer": "Daily" + }, + { + "answer_id": "Every 12 days", + "answer": "Every 12 days" + }, + { + "answer_id": "Every 15 days", + "answer": "Every 15 days" + }, + { + "answer_id": "Monthly", + "answer": "Monthly" + }, + { + "answer_id": "Every 3 months", + "answer": "Every 3 months" + }, + { + "answer_id": "Every 6 months", + "answer": "Every 6 months" + }, + { + "answer_id": "Yearly", + "answer": "Yearly" + } + ], + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Original tenure in months", + "question_key": "original_tenure_months", + "type": "1", + "field_width": "100", + "field_type": "num", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Current balance tenure in months", + "question_key": "current_tenure_months", + "type": "1", + "field_type": "num", + "field_width": "100", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Elapsed tenure in mths", + "question_key": "elapsed_tenure_months", + "type": "1", + "field_width": "45", + "field_type": "num", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + } + ], + "is_repeatable": "1", + "group_title": "Existing Loan Obligations", + "group_key": "existing_loan_details" } - ], - "is_repeatable":"1", - "group_title":"Existing Loan Obligations", - "group_key":"existing_loan_details"} - ] - } - \ No newline at end of file + ] +} \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/16.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/16.json index 187171f..da9cc1f 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/16.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/16.json @@ -2,6 +2,22 @@ "section_id":"16", "section_name":"Family Members Involved in Business", "onsubmit":null, + "questions":[ + { + "question":"Is any other family member involved in the business", + "question_key":"is_family_details_available", + "type":"2", + "field_width":"45", + "api_properties":null, + "onchange_properties":[{ + "purpose":"FORM_CTRL", + "form_controls":[ + { + "insert_index":"is_family_details_available", + "expression":"(String('is_family_details_available') == String('Yes'))", + "value_keys":[ + "is_family_details_available" + ], "questions":[ { "question":[ @@ -14,7 +30,6 @@ "answers":null, "onchange_properties":null, "is_repeatable":null, - "field_type":"string", "validations":[ { "name":"required", @@ -36,18 +51,27 @@ "question":"Relationship", "question_key":"relationship", "place_holder":"Enter the text", - "type":"1", - "api_properties":null, + "type":"8", + "api_properties":{ + "api":"getListOfMaster", + "api_method":"POST", + "params":{ + "master_name":"RELATIONSHIPS" + }, + "fields":[ + "relationship_id", + "name" + ] + }, "answers":null, "onchange_properties":null, "is_repeatable":null, - "field_type":"string", "validations":[ { "name":"required", "isactive":"1", "validator":"Validators.required", - "message":"Share value Required", + "message":"Required", "value":null } ] @@ -56,18 +80,21 @@ "question":"Relation to Individual Stakeholders", "question_key":"stakeholder_relation", "place_holder":"Enter text", - "type":"1", - "api_properties":null, + "type":"3", + "api_properties":{ + "purpose":"answer_options_local", + "master_name":"pd_applicants", + "fields":["pd_co_applicant_id","applicant_name"] + }, "answers":null, "onchange_properties":null, "is_repeatable":null, - "field_type":"string", "validations":[ { "name":"required", "isactive":"1", "validator":"Validators.required", - "message":"Name Required", + "message":"Required", "value":null } ] @@ -76,18 +103,27 @@ "question":"Relation to Company / Firm", "question_key":"company_relation", "place_holder":"Enter text", - "type":"1", - "api_properties":null, + "type":"8", + "api_properties":{ + "api":"getListOfMaster", + "api_method":"POST", + "params":{ + "master_name":"COMPANYRELATIONSHIPS" + }, + "fields":[ + "company_relationship_id", + "name" + ] + }, "answers":null, "onchange_properties":null, "is_repeatable":null, - "field_type":"string", "validations":[ { "name":"required", "isactive":"1", "validator":"Validators.required", - "message":"Name Required", + "message":"Required", "value":null } ] @@ -96,18 +132,26 @@ "question":"Started Business (Yes / No)", "question_key":"started_biz", "place_holder":"Enter text", - "type":"1", + "type":"2", "api_properties":null, - "answers":null, + "answers":[ + { + "answer_id":"Yes", + "answer":"Yes" + }, + { + "answer_id":"No", + "answer":"No" + } + ], "onchange_properties":null, "is_repeatable":null, - "field_type":"string", "validations":[ { "name":"required", "isactive":"1", "validator":"Validators.required", - "message":"Name Required", + "message":"Required", "value":null } ] @@ -118,5 +162,27 @@ "group_title":"Family Members Involved in Business", "group_key":"family_details" } + ]}] + }], + "is_repeatable":null, + "answers":[{ + "answer":"Yes", + "answer_id":"Yes" + }, + { + "answer":"No", + "answer_id":"No" + }], + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ] + } + ] } \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/18.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/18.json index ba64c06..e09078b 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/18.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/18.json @@ -16,13 +16,6 @@ "is_repeatable":null, "field_type":"string", "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } ] }, { @@ -35,13 +28,6 @@ "onchange_properties":null, "is_repeatable":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } ] } ], diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/19.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/19.json index 592c7eb..0ede0b8 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/19.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/19.json @@ -200,13 +200,6 @@ "onchange_properties":null, "is_repeatable":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } ] } diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/2.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/2.json index 6edb1fe..4927a89 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/2.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/2.json @@ -227,18 +227,29 @@ "question_key":"uom", "type":"8", "field_width":"45", - "api_properties":{ - "api":"getListOfMaster", - "api_method":"POST", - "params":{ - "master_name":"UOM" - }, - "fields":[ - "uom_id", - "name" - ] - }, - "answers":null, + "api_properties":null, + "answers":[ + { + "answer":"Acres", + "answer_id":"Acres" + }, + { + "answer":"Hectares", + "answer_id":"Hectares" + }, + { + "answer":"Square Feet", + "answer_id":"Square Feet" + }, + { + "answer":"Square Meters", + "answer_id":"Square Meters" + }, + { + "answer":"Square Yards", + "answer_id":"Square Yards" + } + ], "onchange_properties": [{ "purpose":"FORM_CTRL", "form_controls":[ diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/5.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/5.json index 25ad0aa..2fd83bf 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/5.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/5.json @@ -168,13 +168,22 @@ ] }, { - "question":"Started Business", + "question":"Started Business (Yes / No)", "question_key":"started_biz", - "type":"1", + "type":"2", "api_properties":null, "onchange_properties":null, "is_repeatable":null, - "answers":null, + "answers":[ + { + "answer_id":"Yes", + "answer":"Yes" + }, + { + "answer_id":"No", + "answer":"No" + } + ], "validations":[ { "name":"required", diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/6.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/6.json index fd88782..634c009 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/6.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/6.json @@ -53,8 +53,8 @@ ] }, { - "question":"Business Process Brief", - "question_key":"business_process", + "question":"Remarks if any", + "question_key":"remarks", "place_holder":"Enter the text", "type":"1", "api_properties":null, @@ -62,13 +62,6 @@ "is_repeatable":null, "field_type":"string", "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } ], "onchange_properties":null } @@ -76,6 +69,26 @@ "is_repeatable":"1", "group_title":"Key Products and Business Contribution", "group_key":"key_products_contribution" - } + }, + { + "question":"Business Process Brief", + "question_key":"business_process", + "place_holder":"Enter the text", + "type":"7", + "api_properties":null, + "answers":null, + "is_repeatable":null, + "field_type":"string", + "validations":[ + { + "name":"required", + "isactive":"1", + "validator":"Validators.required", + "message":"Required", + "value":null + } + ], + "onchange_properties":null + } ] } \ No newline at end of file diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/8.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/8.json index 69aca78..f883d6c 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/8.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/8.json @@ -29,8 +29,8 @@ ], "questions":[ { - "question":"Year", - "sub_title":"How Long has business been operated from visited premises?", + "question":"No of Years", + "sub_title":"How Long has business been operated from visited premises? (Eg. If operating for 5 years and 4 months enter 5 in Years field and 4 in months field)", "question_key":"business_years", "place_holder":"", "field_type":"num", @@ -53,7 +53,7 @@ ] }, { - "question":"Month", + "question":"No of Months", "question_key":"business_months", "place_holder":"", "field_type":"num", @@ -66,13 +66,6 @@ "parent_question_key":"is_business_address", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } ] }, { @@ -88,7 +81,7 @@ "form_controls":[ { "insert_index":"business_is_pd_visited", - "expression":"(String('business_is_pd_visited') == String('Yes')) && (String('is_business_address') == String('Yes'))", + "expression":"(String('business_is_pd_visited') != String('')) && (String('is_business_address') == String('Yes'))", "value_keys":[ "business_is_pd_visited", "is_business_address" @@ -223,13 +216,6 @@ "parent_question_key":"business_ownership_type", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } ] }, { @@ -246,13 +232,6 @@ "parent_question_key":"business_ownership_type", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } ] } , @@ -508,19 +487,22 @@ "type":"1", "field_width":"45", "api_properties":null, - "onchange_properties":null, + "onchange_properties":[ + { + "purpose":"answer_value", + "expression":"(function(){let current_year = new Date().getFullYear(); return current_year-Number(business_vintage)}())", + "value_keys":[ + "business_vintage" + ], + "insert_control":"business_purchase_year" + } + ], "is_repeatable":null, "is_subfield":"1", "parent_question_key":"business_ownership_type", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } + ] }, { @@ -531,19 +513,22 @@ "type":"1", "field_width":"45", "api_properties":null, - "onchange_properties":null, + "onchange_properties":[ + { + "purpose":"answer_value", + "expression":"(function(){let current_year = new Date().getFullYear(); return current_year-Number(business_purchase_year)}())", + "value_keys":[ + "business_purchase_year" + ], + "insert_control":"business_vintage" + } + ], "is_repeatable":null, "is_subfield":"1", "parent_question_key":"business_ownership_type", "answers":null, "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } + ] } , diff --git a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/9.json b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/9.json index 776f695..f47f4ba 100644 --- a/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/9.json +++ b/ng6-seed/src/assets/data/SMC_CREDIT_TEMPLATES/WCTL/9.json @@ -1,163 +1,108 @@ -{ - "section_id":"9", - "section_name":"Business and Personal Banking Details", - "onsubmit":[], - "questions":[ - { - "question":[ - { - "question": "Business Account holder name", - "question_key": "applicant_name", - "type": "1", - "api_properties": { - "purpose": "answer_options_local", - "master_name": "pd_applicants", - "fields": [ - "pd_co_applicant_id", - "applicant_name" - ] - }, - "answers": null, - "onchange_properties": null, - "is_repeatable": null, - "field_type": "string", - "validations": [ - { - "name": "required", - "isactive": "1", - "validator": "Validators.required", - "message": "Required", - "value": null - } - ] - }, - { - "question":"Bank Name", - "question_key":"bank_name", - "type":"1", - "field_width":"45", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Business Account type", - "question_key":"account_type", - "type":"1", - "field_width":"45", - "api_properties":{ - "api":"getListOfMaster", - "api_method":"POST", - "params":{ - "master_name":"ACCOUNTTYPE" - }, - "fields":[ - "bt_lender_list_id", - "lender_name" - ] +{ + "section_id": "9", + "section_name": "Business and Personal Banking Details", + "onsubmit": [], + "questions": [ + { + "question": [ + { + "question": "Business Account holder name", + "question_key": "applicant_name", + "type": "1", + "api_properties": { + "purpose": "answer_options_local", + "master_name": "pd_applicants", + "fields": [ + "pd_co_applicant_id", + "applicant_name" + ] + }, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "string", + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Required", + "value": null + } + ] }, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Is this the main business account", - "question_key":"is_main", - "type":"1", - "field_width":"45", - "api_properties":null, - "answers":[ - { - "answer":"Select", - "answer_id":"" - }, - { - "answer":"Yes", - "answer_id":"Yes" - }, - { - "answer":"No", - "answer_id":"No" - } - ], - "onchange_properties":null, - "is_repeatable":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field Required", - "value":null - } - ] - }, - { - "question":"Year", - "sub_title":"Approximate vintage of the account", - "question_key":"vintage_year", - "place_holder":"", - "field_type":"num", - "type":"1", - "field_width":"45", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "answers":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - }, - { - "question":"Month", - "question_key":"vintage_month", - "place_holder":"", - "field_type":"num", - "type":"1", - "field_width":"45", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "answers":null, - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Field required", - "value":null - } - ] - } - ], - "is_repeatable":"1", - "group_title":"Banking Details", - "group_key":"banking_details" + { + "question": "Bank Name", + "question_key": "bank_name", + "type": "1", + "field_width": "45", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "Business Account type", + "question_key": "account_type", + "type": "1", + "field_width": "45", + "api_properties": { + "api": "getListOfMaster", + "api_method": "POST", + "params": { + "master_name": "ACCOUNTTYPE" + }, + "fields": [ + "bt_lender_list_id", + "lender_name" + ] + }, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + }, + { + "question": "OD/CC Limit", + "question_key": "cc_limit", + "type": "1", + "field_width": "45", + "field_type": "num", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + { + "name": "required", + "isactive": "1", + "validator": "Validators.required", + "message": "Field Required", + "value": null + } + ] + } + ], + "is_repeatable": "1", + "group_title": "Banking Details", + "group_key": "banking_details" } - ] - } \ No newline at end of file + ] +} \ No newline at end of file