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 8eba7e4..0c4d37c 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 @@ -1,808 +1,654 @@ -{ - "section_id":"10", - "section_name":"Financial Information", - "onsubmit":[ - { - "expression":"(function (){let sum_val=null;let ques_key=[];control.forEach(ques_obj=>{ques_key.push(ques_obj[submitProperty.key_name])});console.log('none',ques_key);return new Set(ques_key).size === ques_key.length}())", - "group_key":"financial_info", - "key_name":"fy", - "msg":"Financial Year already entered earlier" +{ + "section_id": "10", + "section_name": "Financial Information", + "onsubmit": [ + { + "expression": "(function (){let sum_val=null;let ques_key=[];control.forEach(ques_obj=>{ques_key.push(ques_obj[submitProperty.key_name])});console.log('none',ques_key);return new Set(ques_key).size === ques_key.length}())", + "group_key": "financial_info", + "key_name": "fy", + "msg": "Financial Year already entered earlier" } ], - "questions":[ - { - "question":"Number of financial years for which we have financials", - "question_key":"no_of_financial_years", - "place_holder":"Enter the number", - "type":"1", - "field_width":"45", - "api_properties":null, - "answers":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":"alphabets only ", - "value":null - } - ] - }, - { - "question":[ - { - "question":"Enter FY", - "question_key":"fy", - "type":"3", - "field_width":"45", - "answers":[ - - ], - "answer_value":"GET_FY_YEARS", - "api_properties":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Fin Yr Required", - "value":null - } - ] - }, - { - "question":"Sales / Revenue (Rs)", - "question_key":"sales_revenue", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":[ - { - "purpose":"answer_value", - "expression":"((Number(net_profit)/Number(sales_revenue))*100).toFixed(2)", - "value_keys":[ - "sales_revenue","net_profit" - ], - "insert_control":"net_profit_sales_percent" - }, - { - "purpose":"answer_value_arr", - "arr_include":["py","now"], - "expression":"((Number(sales_revenue[now])-Number(sales_revenue[py]))/Number(sales_revenue[py]))*100", - "value_keys":[ - "sales_revenue" - ], - "insert_control":"sales_py" - }, - { - "purpose":"answer_value_arr", - "arr_include":["py","now"], - "expression":"(((Number(net_profit_sales_percent[now])-Number(net_profit_sales_percent[py]))/Number(net_profit_sales_percent[py]))*100).toFixed(2)", - "value_keys":[ - "net_profit_sales_percent" - ], - "insert_control":"netprofit_py_percent" - } - ], - "is_repeatable":null, - "field_type":"numtoword", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"Net Profit / (Net Loss) (Rs) ", - "question_key":"net_profit", - "type":"1", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":[ - { - "purpose":"answer_value", - "expression":"((Number(net_profit)/Number(sales_revenue))*100).toFixed(2)", - "value_keys":[ - "sales_revenue","net_profit" - ], - "insert_control":"net_profit_sales_percent" - }, - { - "purpose":"answer_value_arr", - "arr_include":["py","now"], - "expression":"((Number(net_profit[now])-Number(net_profit[py]))/Number(net_profit[py]))*100", - "value_keys":[ - "net_profit" - ], - "insert_control":"netprofit_py" - }, - { - "purpose":"answer_value_arr", - "arr_include":["py","now"], - "expression":"(((Number(net_profit_sales_percent[now])-Number(net_profit_sales_percent[py]))/Number(net_profit_sales_percent[py]))*100).toFixed(2)", - "value_keys":[ - "net_profit_sales_percent" - ], - "insert_control":"netprofit_py_percent" - } - ], - "is_repeatable":null, - "field_type":"numtoword", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "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, - "onchange_properties":[ - { - "purpose":"answer_value_arr", - "arr_include":["py","now"], - "expression":"(((Number(net_profit_sales_percent[now])-Number(net_profit_sales_percent[py]))/Number(net_profit_sales_percent[py]))*100).toFixed(2)", - "value_keys":[ - "net_profit_sales_percent" - ], - "insert_control":"netprofit_py_percent" - } - ], - "is_repeatable":null, - "field_type":"num", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } + "questions": [ + { + "question": "Number of financial years for which we have financials", + "question_key": "no_of_financial_years", + "place_holder": "Enter the number", + "type": "1", + "field_width": "45", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + { + "name": "pattern", + "isactive": "1", + "validator": "[0-9]*", + "message": "Numeric only ", + "value": null + } + ] + }, + { + "question": [ + { + "question": "Enter FY", + "question_key": "fy", + "type": "3", + "field_width": "45", + "answers": [], + "answer_value": "GET_FY_YEARS", + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ ] }, - { - "question":"% (↑ /↓) in Sales over PY", - "question_key":"sales_py", - "type":"1", - "is_disabled":"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":"% (↑ /↓) in Net Profit over PY", - "question_key":"netprofit_py", - "type":"1", - "is_disabled":"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":"% (↑ /↓) in Net Profit % over PY", - "question_key":"netprofit_py_percent", - "type":"1", - "is_disabled":"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)", + "question_key": "sales_revenue", + "type": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": [ + { + "purpose": "answer_value", + "expression": "((Number(net_profit)/Number(sales_revenue))*100).toFixed(2)", + "value_keys": [ + "sales_revenue", + "net_profit" + ], + "insert_control": "net_profit_sales_percent" + }, + { + "purpose": "answer_value_arr", + "arr_include": [ + "py", + "now" + ], + "expression": "((Number(sales_revenue[now])-Number(sales_revenue[py]))/Number(sales_revenue[py]))*100", + "value_keys": [ + "sales_revenue" + ], + "insert_control": "sales_py" + }, + { + "purpose": "answer_value_arr", + "arr_include": [ + "py", + "now" + ], + "expression": "(((Number(net_profit_sales_percent[now])-Number(net_profit_sales_percent[py]))/Number(net_profit_sales_percent[py]))*100).toFixed(2)", + "value_keys": [ + "net_profit_sales_percent" + ], + "insert_control": "netprofit_py_percent" + } + ], + "is_repeatable": null, + "field_type": "numtoword", + "validations": [ + + ] + }, + { + "question": "Net Profit / (Net Loss) (Rs) ", + "question_key": "net_profit", + "type": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": [ + { + "purpose": "answer_value", + "expression": "((Number(net_profit)/Number(sales_revenue))*100).toFixed(2)", + "value_keys": [ + "sales_revenue", + "net_profit" + ], + "insert_control": "net_profit_sales_percent" + }, + { + "purpose": "answer_value_arr", + "arr_include": [ + "py", + "now" + ], + "expression": "((Number(net_profit[now])-Number(net_profit[py]))/Number(net_profit[py]))*100", + "value_keys": [ + "net_profit" + ], + "insert_control": "netprofit_py" + }, + { + "purpose": "answer_value_arr", + "arr_include": [ + "py", + "now" + ], + "expression": "(((Number(net_profit_sales_percent[now])-Number(net_profit_sales_percent[py]))/Number(net_profit_sales_percent[py]))*100).toFixed(2)", + "value_keys": [ + "net_profit_sales_percent" + ], + "insert_control": "netprofit_py_percent" + } + ], + "is_repeatable": null, + "field_type": "numtoword", + "validations": [ + + ] + }, + { + "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, + "onchange_properties": [ + { + "purpose": "answer_value_arr", + "arr_include": [ + "py", + "now" + ], + "expression": "(((Number(net_profit_sales_percent[now])-Number(net_profit_sales_percent[py]))/Number(net_profit_sales_percent[py]))*100).toFixed(2)", + "value_keys": [ + "net_profit_sales_percent" + ], + "insert_control": "netprofit_py_percent" + } + ], + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "% (? /?) in Sales over PY", + "question_key": "sales_py", + "type": "1", + "is_disabled": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "% (? /?) in Net Profit over PY", + "question_key": "netprofit_py", + "type": "1", + "is_disabled": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "% (? /?) in Net Profit % over PY", + "question_key": "netprofit_py_percent", + "type": "1", + "is_disabled": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "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?", + "question_key": "debtor_days_cet", + "type": "1", + "field_width": "100", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "Creditor Days as per CET", + "sub_title": "In Case of credit purchases, what is the average no. of days taken to pay the money?", + "question_key": "creditor_days_cet", + "type": "1", + "field_width": "100", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "Inventory Days as per CET", + "sub_title": "What is the average no. of days for which stock lies unsold during the year?", + "question_key": "inventory_days_cet", + "type": "1", + "field_width": "100", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + } + ], + "is_repeatable": "1", + "group_key": "financial_info", + "group_title": "Financial Information" + }, + { + "question": "Debtor Days as per CM Discussion", + "question_key": "debtor_days_cm", + "type": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ - { - "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?", - "question_key":"debtor_days_cet", - "type":"1", - "field_width":"100", - "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":"Creditor Days as per CET", - "sub_title":"In Case of credit purchases, what is the average no. of days taken to pay the money?", - "question_key":"creditor_days_cet", - "type":"1", - "field_width":"100", - "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":"Inventory Days as per CET", - "sub_title":"What is the average no. of days for which stock lies unsold during the year?", - "question_key":"inventory_days_cet", - "type":"1", - "field_width":"100", - "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 - } - - ] - } - - - - ], - "is_repeatable":"1", - "group_key":"financial_info", - "group_title":"Financial Information" + ] + }, + { + "question": "Creditor Days as per CM Discussion", + "question_key": "creditor_days_cm", + "type": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "Inventory Days as per CM Discussion", + "question_key": "inventory_days_cm", + "type": "1", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "num", + "validations": [ + + ] + }, + { + "question": "Broken Period starting from (Date)", + "question_key": "broken_period_from_month", + "type": "1", + "field_width": "45", + "place_holder": "DD-MM-YYYY (Eg 05-02-2020)", + "answers": null, + "api_properties": null, + "onchange_properties": [ + { + "purpose": "answer_value", + "expression": "(function (){let final_value = ''; if(String('broken_period_to_month') && String('broken_period_from_month')) {let from_date = new Date((String('broken_period_from_month')).split('-').reverse().join('-'));let to_date = new Date((String('broken_period_to_month')).split('-').reverse().join('-'));console.log(to_date);if(!from_date || !to_date || !from_date instanceof Date || !to_date instanceof Date || isNaN(from_date) || isNaN(to_date)) {final_value = '';return;}final_value = to_date.getMonth() - from_date.getMonth() + (12 * (to_date.getFullYear() - from_date.getFullYear()))};return final_value}())", + "value_keys": [ + "broken_period_to_month", + "broken_period_from_month" + ], + "insert_control": "broken_period_no_of_months" + } + ], + "is_repeatable": null, + "field_type": "string", + "validations": [ + + ] + }, + { + "question": "Broken Period starting to (Date)", + "question_key": "broken_period_to_month", + "type": "1", + "place_holder": "DD-MM-YYYY (Eg 03-12-2020)", + "field_width": "45", + "answers": null, + "api_properties": null, + "onchange_properties": [ + { + "purpose": "answer_value", + "expression": "(function (){let final_value = ''; if(String('broken_period_to_month') && String('broken_period_from_month')) {let from_date = new Date((String('broken_period_from_month')).split('-').reverse().join('-'));let to_date = new Date((String('broken_period_to_month')).split('-').reverse().join('-'));console.log(to_date);if(!from_date || !to_date || !from_date instanceof Date || !to_date instanceof Date || isNaN(from_date) || isNaN(to_date)) {final_value = '';return;}final_value = to_date.getMonth() - from_date.getMonth() + (12 * (to_date.getFullYear() - from_date.getFullYear()))};return final_value}())", + "value_keys": [ + "broken_period_to_month", + "broken_period_from_month" + ], + "insert_control": "broken_period_no_of_months" + } + ], + "is_repeatable": null, + "field_type": "string", + "validations": [ + + ] + }, + { + "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": [ + + ] + }, + { + "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": [ + { + "purpose": "answer_value", + "expression": "(((Number(broken_period_turnover_cy)-Number(broken_period_turnover_py))/Number(broken_period_turnover_cy))*100).toFixed(2)", + "value_keys": [ + "broken_period_turnover_py", + "broken_period_turnover_cy" + ], + "insert_control": "broken_period_turnover_percent" + } + ], + "is_repeatable": null, + "field_type": "numtoword", + "validations": [ + + ] + }, + { + "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": [ + { + "purpose": "answer_value", + "expression": "(((Number(broken_period_turnover_cy)-Number(broken_period_turnover_py))/Number(broken_period_turnover_cy))*100).toFixed(2)", + "value_keys": [ + "broken_period_turnover_py", + "broken_period_turnover_cy" + ], + "insert_control": "broken_period_turnover_percent" + } + ], + "is_repeatable": null, + "field_type": "numtoword", + "validations": [ + + ] + }, + { + "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": [ + + ] + }, + { + "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" }, - { - "question":"Debtor Days as per CM Discussion", - "question_key":"debtor_days_cm", - "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":"Creditor Days as per CM Discussion", - "question_key":"creditor_days_cm", - "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":"Inventory Days as per CM Discussion", - "question_key":"inventory_days_cm", - "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 from (Date)", - "question_key":"broken_period_from_month", - "type":"1", - "field_width":"45", - "place_holder":"DD-MM-YYYY (Eg 05-02-2020)", - "answers":null, - "api_properties":null, - "onchange_properties":[ + { + "answer": "No", + "answer_id": "No" + } + ], + "api_properties": null, + "onchange_properties": [ + { + "purpose": "FORM_CTRL", + "form_controls": [ { - "purpose":"answer_value", - "expression":"(function (){let final_value = ''; if(String('broken_period_to_month') && String('broken_period_from_month')) {let from_date = new Date((String('broken_period_from_month')).split('-').reverse().join('-'));let to_date = new Date((String('broken_period_to_month')).split('-').reverse().join('-'));console.log(to_date);if(!from_date || !to_date || !from_date instanceof Date || !to_date instanceof Date || isNaN(from_date) || isNaN(to_date)) {final_value = '';return;}final_value = to_date.getMonth() - from_date.getMonth() + (12 * (to_date.getFullYear() - from_date.getFullYear()))};return final_value}())", - "value_keys":[ - "broken_period_to_month", "broken_period_from_month" + "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" ], - "insert_control":"broken_period_no_of_months" - } - ], - "is_repeatable":null, - "field_type":"string", - "validations":[ - { - "name":"required", - "isactive":"1", - "validator":"Validators.required", - "message":"Required", - "value":null - } - - ] - }, - { - "question":"Broken Period starting to (Date)", - "question_key":"broken_period_to_month", - "type":"1", - "place_holder":"DD-MM-YYYY (Eg 03-12-2020)", - "field_width":"45", - "answers":null, - "api_properties":null, - "onchange_properties":[ - { - "purpose":"answer_value", - "expression":"(function (){let final_value = ''; if(String('broken_period_to_month') && String('broken_period_from_month')) {let from_date = new Date((String('broken_period_from_month')).split('-').reverse().join('-'));let to_date = new Date((String('broken_period_to_month')).split('-').reverse().join('-'));console.log(to_date);if(!from_date || !to_date || !from_date instanceof Date || !to_date instanceof Date || isNaN(from_date) || isNaN(to_date)) {final_value = '';return;}final_value = to_date.getMonth() - from_date.getMonth() + (12 * (to_date.getFullYear() - from_date.getFullYear()))};return final_value}())", - "value_keys":[ - "broken_period_to_month", "broken_period_from_month" - ], - "insert_control":"broken_period_no_of_months" - } - ], - "is_repeatable":null, - "field_type":"string", - "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":[ - { - "purpose":"answer_value", - "expression":"(((Number(broken_period_turnover_cy)-Number(broken_period_turnover_py))/Number(broken_period_turnover_cy))*100).toFixed(2)", - "value_keys":[ - "broken_period_turnover_py","broken_period_turnover_cy" - ], - "insert_control":"broken_period_turnover_percent" - } - ], - "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":[ - { - "purpose":"answer_value", - "expression":"(((Number(broken_period_turnover_cy)-Number(broken_period_turnover_py))/Number(broken_period_turnover_cy))*100).toFixed(2)", - "value_keys":[ - "broken_period_turnover_py","broken_period_turnover_cy" - ], - "insert_control":"broken_period_turnover_percent" - } - ], - "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":"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":"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 - } - - ] - }, - { - "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" - }, - { - "answer":"Others", - "answer_id":"Others" - } + "questions": [ + { + "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": [ + + ] + }, + { + "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" + }, + { + "answer": "Others", + "answer_id": "Others" + } + ], + "api_properties": null, + "onchange_properties": [ + { + "purpose": "FORM_CTRL", + "form_controls": [ + { + "insert_index": "facility_details_other_lender", + "expression": "(String('facility_details_other_lender').toLowerCase() == String('others'))", + "value_keys": [ + "facility_details_other_lender" ], - "api_properties":null, - "onchange_properties": [ + "questions": [ { - "purpose":"FORM_CTRL", - "form_controls":[{ - "insert_index":"facility_details_other_lender", - "expression":"(String('facility_details_other_lender').toLowerCase() == String('others'))", - "value_keys":[ - "facility_details_other_lender" - ], - "questions":[ - { - "question": "Specify Facility details", - "question_key": "facility_details_other", - "type": "1", - "field_width": "45", - "field_type": "string", - "api_properties": null, - "answers": null, - "onchange_properties": null, - "is_repeatable": null, - "validations": [ - ] - } - ] - }] + "question": "Specify Facility details", + "question_key": "facility_details_other", + "type": "1", + "field_width": "45", + "field_type": "string", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [] } - ], - "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": null, + "is_subfield": "1", + "parent_question_key": "is_any_other_working_captial_facility", + "validations": [ + + ] + } + ] } - ] - }, + } + ], + "is_repeatable": null, + "validations": [ - { - "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.toFixed(2)}())", - "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).toFixed(2)", - "value_keys":[ - "sales_amount", "net_profit_rs" - ], - "insert_control":"net_profit_to_sales_percent" - } - ] - }, - { - "question_key":"common_remarks", - "question":"Remarks", - "place_holder":"Enter the text", - "type":"7", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"string", - "field_width":"45", - "validations":[ - ] - } - - ] - } \ No newline at end of file + ] + }, + { + "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.toFixed(2)}())", + "value_keys": [ + "sales_amount", + "net_profit_rs" + ], + "insert_control": "net_profit_to_sales_percent" + } + ], + "is_repeatable": null, + "validations": [ + + ] + }, + { + "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": "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": [ + + ], + "onchange_properties": [ + { + "purpose": "answer_value", + "expression": "((Number(net_profit_rs)/Number(sales_amount))*100).toFixed(2)", + "value_keys": [ + "sales_amount", + "net_profit_rs" + ], + "insert_control": "net_profit_to_sales_percent" + } + ] + }, + { + "question_key": "common_remarks", + "question": "Remarks", + "place_holder": "Enter the text", + "type": "7", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "string", + "field_width": "45", + "validations": [] + } + ] +} \ 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 2bc77da..95c2d22 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,143 +1,117 @@ { - "section_id": "9", - "section_name": "Business and Personal Banking Details", - "onsubmit": [], - "questions": [ - { - "question": [ - { - "question": "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": "Account type", - "question_key": "account_type", - "type": "3", - "field_width": "45", - "api_properties":null, - "answers": [ - { - "answer":"Savings", - "answer_id":"Savings" - }, - { - "answer":"OD", - "answer_id":"OD" + "section_id": "9", + "section_name": "Business and Personal Banking Details", + "onsubmit": [], + "questions": [ + { + "question": [ + { + "question": "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" + ] }, - { - "answer":"Current", - "answer_id":"Current" - }, - { - "answer":"CC", - "answer_id":"CC" - } - ], - "onchange_properties": [ - { - "purpose":"FORM_CTRL", - "form_controls":[{ - "insert_index":"account_type", - "expression":"(String('account_type').toLowerCase() != String('savings') && String('account_type').toLowerCase() != String('current'))", - "value_keys":[ - "account_type" - ], - "questions":[ + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "string", + "validations": [ + ] + }, + { + "question": "Bank Name", + "question_key": "bank_name", + "type": "1", + "field_width": "45", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "validations": [ + ] + }, + { + "question": "Account type", + "question_key": "account_type", + "type": "3", + "field_width": "45", + "api_properties": null, + "answers": [ + { + "answer": "Savings", + "answer_id": "Savings" + }, + { + "answer": "OD", + "answer_id": "OD" + }, + { + "answer": "Current", + "answer_id": "Current" + }, + { + "answer": "CC", + "answer_id": "CC" + } + ], + "onchange_properties": [ + { + "purpose": "FORM_CTRL", + "form_controls": [ { - "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": [ + "insert_index": "account_type", + "expression": "(String('account_type').toLowerCase() != String('savings') && String('account_type').toLowerCase() != String('current'))", + "value_keys": [ + "account_type" + ], + "questions": [ { - "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": [ + + ] } ] } - ] - }] - } - ], - "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" - }, - { - "question_key":"common_remarks", - "question":"Remarks", - "place_holder":"Enter the text", - "type":"7", - "api_properties":null, - "answers":null, - "onchange_properties":null, - "is_repeatable":null, - "field_type":"string", - "field_width":"45", - "validations":[ - ] - } - ] + ] + } + ], + "is_repeatable": null, + "validations": [ + + ] + } + ], + "is_repeatable": "1", + "group_title": "Banking Details", + "group_key": "banking_details" + }, + { + "question_key": "common_remarks", + "question": "Remarks", + "place_holder": "Enter the text", + "type": "7", + "api_properties": null, + "answers": null, + "onchange_properties": null, + "is_repeatable": null, + "field_type": "string", + "field_width": "45", + "validations": [] + } + ] } \ No newline at end of file