diff --git a/fusion_accounting_followup/__manifest__.py b/fusion_accounting_followup/__manifest__.py index 7e8542f8..5429dd1b 100644 --- a/fusion_accounting_followup/__manifest__.py +++ b/fusion_accounting_followup/__manifest__.py @@ -1,6 +1,6 @@ { 'name': 'Fusion Accounting Follow-up', - 'version': '19.0.1.0.21', + 'version': '19.0.1.0.22', 'category': 'Accounting/Accounting', 'summary': 'AI-augmented customer follow-ups (dunning) for unpaid invoices.', 'description': """ @@ -44,6 +44,12 @@ menu hides; the engine + AI tools remain available for the chat. 'fusion_accounting_followup/static/src/views/followup_dashboard/followup_dashboard.js', 'fusion_accounting_followup/static/src/views/followup_dashboard/followup_dashboard.xml', 'fusion_accounting_followup/static/src/views/followup_dashboard/followup_dashboard_view.js', + 'fusion_accounting_followup/static/src/components/risk_badge/risk_badge.js', + 'fusion_accounting_followup/static/src/components/risk_badge/risk_badge.xml', + 'fusion_accounting_followup/static/src/components/partner_card/partner_card.js', + 'fusion_accounting_followup/static/src/components/partner_card/partner_card.xml', + 'fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.js', + 'fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.xml', ], }, 'installable': True, diff --git a/fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.js b/fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.js new file mode 100644 index 00000000..c511a2fe --- /dev/null +++ b/fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.js @@ -0,0 +1,15 @@ +/** @odoo-module **/ + +import { Component } from "@odoo/owl"; + +export class AgingBucketStrip extends Component { + static template = "fusion_accounting_followup.AgingBucketStrip"; + static props = { + aging: { type: Object }, + }; + + bucketWidth(bucket) { + const total = this.props.aging.total_amount || 1; + return ((bucket.amount / total) * 100).toFixed(2) + "%"; + } +} diff --git a/fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.xml b/fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.xml new file mode 100644 index 00000000..a48223c4 --- /dev/null +++ b/fusion_accounting_followup/static/src/components/aging_bucket_strip/aging_bucket_strip.xml @@ -0,0 +1,22 @@ + + + + +
+
+
+
+
+ Current + 30 + 60 + 90 + 120+ +
+
+ + + diff --git a/fusion_accounting_followup/static/src/components/partner_card/partner_card.js b/fusion_accounting_followup/static/src/components/partner_card/partner_card.js new file mode 100644 index 00000000..a8467048 --- /dev/null +++ b/fusion_accounting_followup/static/src/components/partner_card/partner_card.js @@ -0,0 +1,15 @@ +/** @odoo-module **/ + +import { Component } from "@odoo/owl"; +import { RiskBadge } from "../risk_badge/risk_badge"; + +export class PartnerCard extends Component { + static template = "fusion_accounting_followup.PartnerCard"; + static props = { + partner: { type: Object }, + selected: { type: Boolean, optional: true }, + onSelect: { type: Function }, + formatCurrency: { type: Function }, + }; + static components = { RiskBadge }; +} diff --git a/fusion_accounting_followup/static/src/components/partner_card/partner_card.xml b/fusion_accounting_followup/static/src/components/partner_card/partner_card.xml new file mode 100644 index 00000000..a83d6c1a --- /dev/null +++ b/fusion_accounting_followup/static/src/components/partner_card/partner_card.xml @@ -0,0 +1,37 @@ + + + + +
+
+
+
+ + + +
+
+
+
+ Overdue: + $ +
+
+ Lines: + +
+
+ Risk: + +
+
+ Last: + +
+
+
+
+ +
diff --git a/fusion_accounting_followup/static/src/components/risk_badge/risk_badge.js b/fusion_accounting_followup/static/src/components/risk_badge/risk_badge.js new file mode 100644 index 00000000..03260b78 --- /dev/null +++ b/fusion_accounting_followup/static/src/components/risk_badge/risk_badge.js @@ -0,0 +1,11 @@ +/** @odoo-module **/ + +import { Component } from "@odoo/owl"; + +export class RiskBadge extends Component { + static template = "fusion_accounting_followup.RiskBadge"; + static props = { + band: { type: String, optional: true }, + score: { type: Number, optional: true }, + }; +} diff --git a/fusion_accounting_followup/static/src/components/risk_badge/risk_badge.xml b/fusion_accounting_followup/static/src/components/risk_badge/risk_badge.xml new file mode 100644 index 00000000..3e6fe303 --- /dev/null +++ b/fusion_accounting_followup/static/src/components/risk_badge/risk_badge.xml @@ -0,0 +1,11 @@ + + + + + + + () + + + +