Add the ERPNext settings UI, History and detail controls, and voiced.invoice.v1 export (Phase F3)
- Settings gets an Integrations tab: connection fields with a write-only API secret, a CA PEM option, Test connection with versions and warnings, live mapping lists loaded after a test, naming mode, toggles and its own Save. - Pushing for a GST-registered vendor is refused until a connection test result is stored. The UI shows the reason and disables Send. - History shows an ERPNext status column from one bulk call, a row Send and Open in ERPNext, and a bulk Send selected with a draft-or-submit confirm step and per-row results that never abort the batch. The detail view gets an ERPNext panel and per-payment send. All of it is hidden or disabled when the integration is not configured. - Optional auto-push after issue runs in the background and never blocks or fails the issue. - Generic export: a deterministic voiced.invoice.v1 JSON (and CSV line items) for selected invoices, documented in docs/voiced-invoice-v1.md with a golden test. Money is integer paise plus a decimal string. The new screens have not been run in a webview yet. The ERPNext Payment Entry deduction fields still need a live check.
This commit is contained in:
@@ -698,3 +698,76 @@ body {
|
||||
.voiced-detail__unarchived p {
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
/* Settings, Integrations, ERPNext */
|
||||
.voiced-erp__section > h3 {
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
.voiced-erp__fields {
|
||||
display: grid;
|
||||
gap: 1rem;
|
||||
max-width: 40rem;
|
||||
margin-top: 1rem;
|
||||
}
|
||||
|
||||
.voiced-erp__label {
|
||||
font-size: 0.75rem;
|
||||
color: var(--cds-text-secondary);
|
||||
margin-bottom: 0.25rem;
|
||||
}
|
||||
|
||||
.voiced-erp__secret > * + * {
|
||||
margin-top: 0.5rem;
|
||||
}
|
||||
|
||||
.voiced-erp__result > * + * {
|
||||
margin-top: 0.75rem;
|
||||
}
|
||||
|
||||
.voiced-erp__uoms {
|
||||
border: 0;
|
||||
padding: 0;
|
||||
display: grid;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.voiced-erp__uoms legend {
|
||||
font-size: 0.75rem;
|
||||
color: var(--cds-text-secondary);
|
||||
}
|
||||
|
||||
.voiced-erp__error {
|
||||
color: var(--cds-text-error);
|
||||
font-size: 0.75rem;
|
||||
}
|
||||
|
||||
/* ERPNext column and bulk-send bar on the invoices list */
|
||||
.voiced-history__bulk {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
.voiced-erp__results {
|
||||
list-style: none;
|
||||
margin-top: 1rem;
|
||||
max-height: 16rem;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.voiced-erp__results li {
|
||||
padding: 0.25rem 0;
|
||||
border-bottom: 1px solid var(--cds-border-subtle);
|
||||
}
|
||||
|
||||
.voiced-erp__panel {
|
||||
border: 1px solid var(--cds-border-subtle);
|
||||
padding: 1rem;
|
||||
}
|
||||
|
||||
.voiced-erp__panel > * + * {
|
||||
margin-top: 0.75rem;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user