@xuda.io/ai_module 1.1.4852 → 1.1.4854

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.mjs +7 -4
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -2798,7 +2798,7 @@ export const update_ai_agent_properties = async function (doc, app_id, uid, fiel
2798
2798
 
2799
2799
 
2800
2800
  use the field keys from the above ## fields object
2801
- and create validation for each step
2801
+ and create validations for each step
2802
2802
 
2803
2803
  result example:
2804
2804
 
@@ -2814,19 +2814,22 @@ export const update_ai_agent_properties = async function (doc, app_id, uid, fiel
2814
2814
  step: 2,
2815
2815
  title: "Rates & Terms",
2816
2816
  description: "Define the interest and duration of the loan.",
2817
- fields: ["interest_rate", "interest_type", "loan_term"]
2817
+ fields: ["interest_rate", "interest_type", "loan_term"],
2818
+ if: (obj) => obj.loan_type === 'personal' ? true : false,
2818
2819
  },
2819
2820
  {
2820
2821
  step: 3,
2821
2822
  title: "Payment Schedule",
2822
2823
  description: "How and when would you like to make payments?",
2823
- fields: ["payment_frequency", "start_date"]
2824
+ fields: ["payment_frequency", "start_date"],
2825
+ if: (obj) => obj.loan_type === 'personal' ? true : false,
2824
2826
  },
2825
2827
  {
2826
2828
  step: 4,
2827
2829
  title: "Additional Options",
2828
2830
  description: "Finalize your calculation with extra payments or schedules.",
2829
- fields: ["extra_payments", "amortization_schedule"]
2831
+ fields: ["extra_payments", "amortization_schedule"],
2832
+ if: (obj) => obj.loan_type === 'personal' ? true : false,
2830
2833
  }
2831
2834
  ]
2832
2835
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/ai_module",
3
- "version": "1.1.4852",
3
+ "version": "1.1.4854",
4
4
  "description": "Xuda AI Module",
5
5
  "main": "index.mjs",
6
6
  "type": "module",