@openmrs/esm-billing-app 1.0.1-pre.98 → 1.0.2-pre.58
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.
- package/.eslintignore +0 -1
- package/.eslintrc +33 -24
- package/.husky/pre-commit +1 -1
- package/.turbo.json +1 -1
- package/.tx/config +11 -0
- package/README.md +111 -1
- package/dist/1119.js +1 -0
- package/dist/1197.js +1 -0
- package/dist/1362.js +1 -0
- package/dist/1362.js.map +1 -0
- package/dist/2146.js +1 -0
- package/dist/2690.js +1 -0
- package/dist/3029.js +2 -0
- package/dist/3029.js.LICENSE.txt +7 -0
- package/dist/3029.js.map +1 -0
- package/dist/3099.js +1 -0
- package/dist/3511.js +1 -0
- package/dist/3511.js.map +1 -0
- package/dist/3584.js +1 -0
- package/dist/4055.js +1 -0
- package/dist/4132.js +1 -0
- package/dist/4225.js +1 -0
- package/dist/4225.js.map +1 -0
- package/dist/4300.js +1 -0
- package/dist/4335.js +1 -0
- package/dist/4618.js +1 -0
- package/dist/4652.js +1 -0
- package/dist/4817.js +2 -0
- package/dist/4817.js.LICENSE.txt +77 -0
- package/dist/4817.js.map +1 -0
- package/dist/4944.js +1 -0
- package/dist/4993.js +1 -0
- package/dist/4993.js.map +1 -0
- package/dist/5173.js +1 -0
- package/dist/5241.js +1 -0
- package/dist/5442.js +1 -0
- package/dist/5661.js +1 -0
- package/dist/6022.js +1 -0
- package/dist/6468.js +1 -0
- package/dist/6540.js +2 -0
- package/dist/6540.js.map +1 -0
- package/dist/6606.js +2 -0
- package/dist/{591.js.LICENSE.txt → 6606.js.LICENSE.txt} +2 -2
- package/dist/6606.js.map +1 -0
- package/dist/6679.js +1 -0
- package/dist/6840.js +1 -0
- package/dist/6859.js +1 -0
- package/dist/6941.js +1 -0
- package/dist/6941.js.map +1 -0
- package/dist/7097.js +1 -0
- package/dist/7159.js +1 -0
- package/dist/723.js +1 -0
- package/dist/7255.js +1 -0
- package/dist/7255.js.map +1 -0
- package/dist/7617.js +1 -0
- package/dist/763.js +1 -0
- package/dist/763.js.map +1 -0
- package/dist/8163.js +1 -0
- package/dist/8349.js +1 -0
- package/dist/8618.js +1 -0
- package/dist/890.js +1 -0
- package/dist/9055.js +1 -0
- package/dist/9055.js.map +1 -0
- package/dist/9214.js +1 -0
- package/dist/9538.js +1 -0
- package/dist/{935.js → 961.js} +2 -2
- package/dist/{935.js.map → 961.js.map} +1 -1
- package/dist/986.js +1 -0
- package/dist/9879.js +1 -0
- package/dist/9895.js +1 -0
- package/dist/9900.js +1 -0
- package/dist/9913.js +1 -0
- package/dist/main.js +1 -1
- package/dist/main.js.LICENSE.txt +31 -1
- package/dist/main.js.map +1 -1
- package/dist/openmrs-esm-billing-app.js +1 -1
- package/dist/openmrs-esm-billing-app.js.buildmanifest.json +844 -165
- package/dist/openmrs-esm-billing-app.js.map +1 -1
- package/dist/routes.json +1 -1
- package/jest.config.js +4 -1
- package/package.json +19 -21
- package/src/bill-history/bill-history.component.tsx +5 -3
- package/src/bill-history/bill-history.scss +24 -9
- package/src/bill-history/bill-history.test.tsx +58 -16
- package/src/bill-item-actions/bill-item-actions.scss +26 -0
- package/src/bill-item-actions/edit-bill-item.component.tsx +221 -0
- package/src/bill-item-actions/edit-bill-item.test.tsx +137 -0
- package/src/billable-services/bill-waiver/bill-selection.component.tsx +1 -1
- package/src/billable-services/bill-waiver/bill-waiver-form.component.tsx +2 -2
- package/src/billable-services/bill-waiver/bill-waiver-form.scss +4 -4
- package/src/billable-services/bill-waiver/bill-waiver.component.tsx +4 -4
- package/src/billable-services/bill-waiver/patient-bills.component.tsx +1 -1
- package/src/billable-services/billable-service.resource.ts +19 -6
- package/src/billable-services/billable-services-home.component.tsx +19 -3
- package/src/billable-services/billable-services-menu-item/item.component.tsx +17 -0
- package/src/billable-services/billable-services-menu-item/item.scss +14 -0
- package/src/billable-services/billable-services.component.tsx +48 -9
- package/src/billable-services/billable-services.scss +10 -9
- package/src/billable-services/billable-services.test.tsx +172 -8
- package/src/billable-services/cash-point/cash-point-configuration.component.tsx +276 -0
- package/src/billable-services/cash-point/cash-point-configuration.scss +23 -0
- package/src/billable-services/create-edit/add-billable-service.component.tsx +126 -47
- package/src/billable-services/create-edit/add-billable-service.scss +14 -8
- package/src/billable-services/create-edit/add-billable-service.test.tsx +12 -10
- package/src/billable-services/dashboard/dashboard.scss +3 -3
- package/src/billable-services/payyment-modes/payment-modes-config.component.tsx +280 -0
- package/src/billable-services/payyment-modes/payment-modes-config.scss +23 -0
- package/src/billing-dashboard/billing-dashboard.component.tsx +17 -4
- package/src/billing-dashboard/billing-dashboard.scss +3 -3
- package/src/billing-form/billing-form.component.tsx +31 -25
- package/src/billing-form/billing-form.scss +9 -10
- package/src/billing-form/visit-attributes/visit-attributes-form.component.tsx +38 -14
- package/src/billing-header/billing-header.component.tsx +21 -5
- package/src/billing-header/billing-header.scss +1 -1
- package/src/billing.resource.ts +21 -4
- package/src/bills-table/bills-table.component.tsx +46 -36
- package/src/bills-table/bills-table.scss +6 -6
- package/src/bills-table/bills-table.test.tsx +108 -68
- package/src/config-schema.ts +36 -1
- package/src/constants.ts +2 -0
- package/src/dashboard.meta.ts +2 -1
- package/src/helpers/functions.ts +0 -2
- package/src/hooks/selectedDateContext.ts +10 -0
- package/src/index.ts +22 -27
- package/src/invoice/invoice-table.component.tsx +95 -56
- package/src/invoice/invoice-table.scss +7 -8
- package/src/invoice/invoice-table.test.tsx +151 -0
- package/src/invoice/invoice.component.tsx +7 -9
- package/src/invoice/invoice.scss +2 -2
- package/src/invoice/invoice.test.tsx +199 -169
- package/src/invoice/payments/payment-form/payment-form.component.tsx +84 -55
- package/src/invoice/payments/payment-form/payment-form.test.tsx +174 -0
- package/src/invoice/payments/payment-history/payment-history.component.tsx +9 -7
- package/src/invoice/payments/payment-history/payment-history.test.tsx +160 -0
- package/src/invoice/payments/payments.component.test.tsx +121 -0
- package/src/invoice/payments/payments.component.tsx +57 -48
- package/src/invoice/payments/utils.ts +17 -13
- package/src/invoice/printable-invoice/print-receipt.component.tsx +23 -8
- package/src/invoice/printable-invoice/print-receipt.test.tsx +50 -0
- package/src/metrics-cards/card.component.tsx +4 -2
- package/src/metrics-cards/metrics-cards.test.tsx +1 -1
- package/src/modal/require-payment-modal.component.tsx +2 -2
- package/src/modal/require-payment-modal.test.tsx +66 -0
- package/src/modal/require-payment.scss +2 -1
- package/src/routes.json +40 -8
- package/src/types/index.ts +15 -0
- package/{i18next-parser.config.js → tools/i18next-parser.config.js} +19 -19
- package/tools/update-openmrs-deps.mjs +42 -0
- package/translations/am.json +53 -0
- package/translations/ar.json +170 -0
- package/translations/ar_SY.json +170 -0
- package/translations/bn.json +170 -0
- package/translations/de.json +170 -0
- package/translations/en.json +53 -0
- package/translations/es.json +53 -0
- package/translations/es_MX.json +170 -0
- package/translations/fr.json +53 -0
- package/translations/he.json +53 -0
- package/translations/hi.json +170 -0
- package/translations/hi_IN.json +170 -0
- package/translations/id.json +170 -0
- package/translations/it.json +170 -0
- package/translations/km.json +53 -0
- package/translations/ku.json +170 -0
- package/translations/ky.json +170 -0
- package/translations/lg.json +170 -0
- package/translations/ne.json +170 -0
- package/translations/pl.json +170 -0
- package/translations/pt.json +170 -0
- package/translations/pt_BR.json +170 -0
- package/translations/qu.json +170 -0
- package/translations/ro_RO.json +170 -0
- package/translations/ru_RU.json +170 -0
- package/translations/si.json +170 -0
- package/translations/sw.json +170 -0
- package/translations/sw_KE.json +170 -0
- package/translations/tr.json +170 -0
- package/translations/tr_TR.json +170 -0
- package/translations/uk.json +170 -0
- package/translations/uz.json +170 -0
- package/translations/uz@Latn.json +170 -0
- package/translations/uz_UZ.json +170 -0
- package/translations/vi.json +170 -0
- package/translations/zh.json +170 -0
- package/translations/zh_CN.json +170 -0
- package/tsconfig.json +10 -8
- package/webpack.config.js +1 -1
- package/dist/146.js +0 -1
- package/dist/146.js.map +0 -1
- package/dist/294.js +0 -2
- package/dist/294.js.map +0 -1
- package/dist/319.js +0 -1
- package/dist/384.js +0 -1
- package/dist/384.js.map +0 -1
- package/dist/421.js +0 -1
- package/dist/421.js.map +0 -1
- package/dist/533.js +0 -1
- package/dist/533.js.map +0 -1
- package/dist/574.js +0 -1
- package/dist/591.js +0 -2
- package/dist/591.js.map +0 -1
- package/dist/614.js +0 -2
- package/dist/614.js.LICENSE.txt +0 -37
- package/dist/614.js.map +0 -1
- package/dist/753.js +0 -1
- package/dist/753.js.map +0 -1
- package/dist/757.js +0 -1
- package/dist/770.js +0 -1
- package/dist/770.js.map +0 -1
- package/dist/783.js +0 -1
- package/dist/783.js.map +0 -1
- package/dist/788.js +0 -1
- package/dist/800.js +0 -2
- package/dist/800.js.LICENSE.txt +0 -3
- package/dist/800.js.map +0 -1
- package/dist/807.js +0 -1
- package/dist/833.js +0 -1
- package/dist/992.js +0 -1
- package/dist/992.js.map +0 -1
- package/src/root.scss +0 -30
- /package/dist/{294.js.LICENSE.txt → 6540.js.LICENSE.txt} +0 -0
- /package/dist/{935.js.LICENSE.txt → 961.js.LICENSE.txt} +0 -0
- /package/{src → tools}/setup-tests.ts +0 -0
- /package/{test-helpers.tsx → tools/test-helpers.tsx} +0 -0
package/dist/807.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(globalThis.webpackChunk_openmrs_esm_billing_app=globalThis.webpackChunk_openmrs_esm_billing_app||[]).push([[807],{7807:e=>{e.exports=JSON.parse('{"actions":"Actions","addBill":"Add bill item(s)","addBillableServices":"Add Billable Services","addNewBillableService":"Add new billable service","addNewService":"Add new service","addPaymentOptions":"Add payment option","amount":"Amount","amountToWaiveAriaLabel":"Enter amount to waive","amountToWaiveHelper":"Specify the amount to be deducted from the bill","amountToWaiveLabel":"Amount to Waive","billableService":"Billable service","billableServices":"Billable Services","billedItems":"Billed Items","billedTo":"Billed to","billErrorService":"Bill service error","billing":"Billing","billingForm":"Billing form","billingHistory":"Billing History","billItem":"Bill item","billItems":"Bill Items","billList":"Bill list","billMetrics":"Bill metrics","billName":" {{billName}} ","billPayment":"Bill payment","billPaymentRequiredMessage":"The current patient has pending bill. Advice patient to settle bill before receiving services","billServicesManagement":"Bill services management","billsList":"Bill list","billTotal":"Bill total","billWaiver":"Bill waiver","billWaiverError":"Bill waiver failed {{error}}","billWaiverSuccess":"Bill waiver successful","cancel":"Cancel","checkFilters":"Check the filters above","clearSearchInput":"Clear search input","discard":"Discard","discount":"Discount","enterAmount":"Enter amount","enterConcept":"Associated concept","enterReferenceNumber":"Enter ref. number","errorLoadingBillServices":"Error loading bill services","errorLoadingPaymentModes":"Payment modes error","filterBy":"Filter by","filterTable":"Filter table","grandTotal":"Grand total","home":"Home","identifier":"Identifier","inlineLoading":"Loading bill items...","insuranceScheme":"Insurance scheme","invalidWaiverAmount":"Invalid waiver amount","invoice":"Invoice","invoiceError":"Invoice error","item":"Item","itemsToBeBilled":"Items to be billed","launchBillForm":"Launch bill form","lineItems":"Line items","loading":"Loading data...","loadingBillingServices":"Loading billing services...","loadingDescription":"Loading","manageBillableServices":"Manage billable services","name":"Name","nextPage":"Next page","noBilltoDisplay":"There are no bills to display for this patient","noMatchingBillsToDisplay":"No matching bills to display","noMatchingItemsToDisplay":"No matching items to display","noMatchingServicesToDisplay":"No matching services to display","noResultsFor":"No results for","noResultsFound":"No results found","noServicesToDisplay":"There are no services to display","ok":"OK","patientBillingAlert":"Patient Billing Alert","patientBills":"Patient bill","patientBillsDescription":"List of patient bills","patientCategory":"Patient category","paymentDetails":"Payment Details","paymentMethod":"Payment method","paymentMethods":"Payment methods","paymentMode":"Payment Mode","payments":"Payments","policyNumber":"Policy number","postWaiver":"Post waiver","previousPage":"Previous page","prices":"Prices","printBill":"Print bill","printReceipt":"Print receipt","processPayment":"Process Payment","quantity":"Quantity","quantityGreaterThanZero":"Quantity must be greater than zero","referenceNumber":"Reference number","save":"Save","saveAndClose":"Save and close","saving":"Saving","searchConcepts":"Search associated concept","searching":"Searching","searchItems":"Search items and services","searchThisTable":"Search this table","selectBillableService":"Select a billable service...","selectCategory":"Select category","selectPaymentMethod":"Select payment method","sellingAmount":"Enter selling price","sellingPrice":"Selling Price","service":"Service","serviceMetrics":"Service Metrics","serviceName":"Service Name","serviceShortName":"Short Name","servicesList":"Services list","serviceType":"Service Type","shortName":"Short Name","status":"Service Status","stockItem":"Stock Item","total":"Total","totalAmount":"Total Amount","totalTendered":"Total Tendered","unitPrice":"Unit price","visitTime":"Visit time","waiverForm":"Waiver form"}')}}]);
|
package/dist/833.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(globalThis.webpackChunk_openmrs_esm_billing_app=globalThis.webpackChunk_openmrs_esm_billing_app||[]).push([[833],{5833:e=>{e.exports=JSON.parse('{"actions":"Actions","addBill":"Add bill item(s)","addBillableServices":"Add Billable Services","addNewBillableService":"Add new billable service","addNewService":"Add new service","addPaymentOptions":"Add payment option","amount":"Amount","amountToWaiveAriaLabel":"Enter amount to waive","amountToWaiveHelper":"Specify the amount to be deducted from the bill","amountToWaiveLabel":"Amount to Waive","billableService":"Billable service","billableServices":"Billable Services","billedItems":"Billed Items","billedTo":"Billed to","billErrorService":"Bill service error","billing":"Billing","billingForm":"Billing form","billingHistory":"Billing History","billItem":"Bill item","billItems":"Bill Items","billList":"Bill list","billMetrics":"Bill metrics","billName":" {{billName}} ","billPayment":"Bill payment","billPaymentRequiredMessage":"The current patient has pending bill. Advice patient to settle bill before receiving services","billServicesManagement":"Bill services management","billsList":"Bill list","billTotal":"Bill total","billWaiver":"Bill waiver","billWaiverError":"Bill waiver failed {{error}}","billWaiverSuccess":"Bill waiver successful","cancel":"Cancel","checkFilters":"Check the filters above","clearSearchInput":"Clear search input","discard":"Discard","discount":"Discount","enterAmount":"Enter amount","enterConcept":"Associated concept","enterReferenceNumber":"Enter ref. number","errorLoadingBillServices":"Error loading bill services","errorLoadingPaymentModes":"Payment modes error","filterBy":"Filter by","filterTable":"Filter table","grandTotal":"Grand total","home":"Home","identifier":"Identifier","inlineLoading":"Loading bill items...","insuranceScheme":"Insurance scheme","invalidWaiverAmount":"Invalid waiver amount","invoice":"Invoice","invoiceError":"Invoice error","item":"Item","itemsToBeBilled":"Items to be billed","launchBillForm":"Launch bill form","lineItems":"Line items","loading":"Loading data...","loadingBillingServices":"Loading billing services...","loadingDescription":"Loading","manageBillableServices":"Manage billable services","name":"Name","nextPage":"Next page","noBilltoDisplay":"There are no bills to display for this patient","noMatchingBillsToDisplay":"No matching bills to display","noMatchingItemsToDisplay":"No matching items to display","noMatchingServicesToDisplay":"No matching services to display","noResultsFor":"No results for","noResultsFound":"No results found","noServicesToDisplay":"There are no services to display","ok":"OK","patientBillingAlert":"Patient Billing Alert","patientBills":"Patient bill","patientBillsDescription":"List of patient bills","patientCategory":"Patient category","paymentDetails":"Payment Details","paymentMethod":"Payment method","paymentMethods":"Payment methods","paymentMode":"Payment Mode","payments":"Payments","policyNumber":"Policy number","postWaiver":"Post waiver","previousPage":"Previous page","prices":"Prices","printBill":"Print bill","printReceipt":"Print receipt","processPayment":"Process Payment","quantity":"Quantity","quantityGreaterThanZero":"Quantity must be greater than zero","referenceNumber":"Reference number","save":"Save","saveAndClose":"Save and close","saving":"Saving","searchConcepts":"Search associated concept","searching":"Searching","searchItems":"Search items and services","searchThisTable":"Search this table","selectBillableService":"Select a billable service...","selectCategory":"Select category","selectPaymentMethod":"Select payment method","sellingAmount":"Enter selling price","sellingPrice":"Selling Price","service":"Service","serviceMetrics":"Service Metrics","serviceName":"Service Name","serviceShortName":"Short Name","servicesList":"Services list","serviceType":"Service Type","shortName":"Short Name","status":"Service Status","stockItem":"Stock Item","total":"Total","totalAmount":"Total Amount","totalTendered":"Total Tendered","unitPrice":"Unit price","visitTime":"Visit time","waiverForm":"Waiver form"}')}}]);
|
package/dist/992.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(globalThis.webpackChunk_openmrs_esm_billing_app=globalThis.webpackChunk_openmrs_esm_billing_app||[]).push([[992],{8579:(e,t,n)=>{n.d(t,{Z:()=>a});var r=n(7537),l=n.n(r),i=n(3645),o=n.n(i)()(l());o.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79}.-esm-billing__billing-form__tablet___bMbeu{padding:1.5rem 1rem;background-color:#fff}.-esm-billing__billing-form__desktop___2BPdg{padding:0rem}.-esm-billing__billing-form__button___YC37h{height:4rem;display:flex;align-content:flex-start;align-items:baseline;min-width:50%}.-esm-billing__billing-form__button___YC37h .cds--inline-loading{min-height:1rem !important}.-esm-billing__billing-form__button___YC37h .cds--inline-loading__text{font-size:unset !important}.-esm-billing__billing-form__mt2___uzoAI{margin-top:2rem}.-esm-billing__billing-form__searchContent___M86Ub{position:absolute;background-color:#fff;min-width:230px;overflow:auto;border:1px solid #ddd;z-index:1;width:92%}.-esm-billing__billing-form__searchItem___NFLjC{border-bottom:.1rem solid;border-bottom-color:silver;cursor:pointer}.-esm-billing__billing-form__invalidInput___jCUVB{border:2px solid red}.-esm-billing__billing-form__removeButton___vGWoq{color:#ee0909;right:20px;cursor:pointer}.-esm-billing__billing-form__form___hHVr1{display:flex;flex-direction:column;justify-content:space-between;height:calc(100vh - 6rem)}.omrs-breakpoint-lt-desktop .-esm-billing__billing-form__form___hHVr1{background-color:#ededed}.omrs-breakpoint-gt-tablet .-esm-billing__billing-form__form___hHVr1{background-color:#fff}.-esm-billing__billing-form__grid___angWH{margin:1rem}.-esm-billing__billing-form__row___C__4q{margin:.5rem 0rem 0rem;display:flex;flex-flow:row wrap;gap:1rem}.-esm-billing__billing-form__spacer___ypbPd{margin-top:1rem}","",{version:3,sources:["webpack://./node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/billing-form/billing-form.scss","webpack://./node_modules/@carbon/layout/scss/generated/_spacing.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CCnDF,4CACE,mBAAA,CACA,qBDLM,CCQR,6CACE,YAAA,CAGF,4CACE,WAAA,CACA,YAAA,CACA,wBAAA,CACA,oBAAA,CACA,aAAA,CAEA,iEACE,0BAAA,CAGF,uEACE,0BAAA,CAIJ,yCACE,eCWW,CDRb,mDACE,iBAAA,CACA,qBAAA,CACA,eAAA,CACA,aAAA,CACA,qBAAA,CACA,SAAA,CACA,SAAA,CAGF,gDACE,yBAAA,CACA,0BAAA,CACA,cAAA,CAGF,kDACE,oBAAA,CAGF,kDACE,aAAA,CACA,UAAA,CACA,cAAA,CAGF,0CACE,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,yBAAA,CAGF,sEACE,wBAAA,CAGF,qEACE,qBDtEM,CCyER,0CACE,WC5CW,CD+Cb,yCACE,sBAAA,CACA,YAAA,CACA,kBAAA,CACA,QCnDW,CDsDb,4CACE,eCvDW",sourceRoot:""}]),o.locals={tablet:"-esm-billing__billing-form__tablet___bMbeu",desktop:"-esm-billing__billing-form__desktop___2BPdg",button:"-esm-billing__billing-form__button___YC37h",mt2:"-esm-billing__billing-form__mt2___uzoAI",searchContent:"-esm-billing__billing-form__searchContent___M86Ub",searchItem:"-esm-billing__billing-form__searchItem___NFLjC",invalidInput:"-esm-billing__billing-form__invalidInput___jCUVB",removeButton:"-esm-billing__billing-form__removeButton___vGWoq",form:"-esm-billing__billing-form__form___hHVr1",grid:"-esm-billing__billing-form__grid___angWH",row:"-esm-billing__billing-form__row___C__4q",spacer:"-esm-billing__billing-form__spacer___ypbPd"};const a=o},2992:(e,t,n)=>{n.r(t),n.d(t,{default:()=>F});var r=n(1672),l=n.n(r),i=n(8563),o=n(7410),a=n.n(o),c=n(4766),s=n.n(c),u=n(1991),m=n.n(u),_=n(3702),A=n.n(_),d=n(2434),b=n.n(d),f=n(1422),g=n.n(f),p=n(8579),C={};C.styleTagTransform=g(),C.setAttributes=A(),C.insert=m().bind(null,"head"),C.domAPI=s(),C.insertStyleElement=b(),a()(p.Z,C);const y=p.Z&&p.Z.locals?p.Z.locals:void 0;var v=n(3397),h=n(7248),E=n(7416),S=n(5591),I=n(355),k=n(1604),w=n(1657),B=n(3261),j=n.n(B),P=n(9331);function x(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function D(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){D(e,t,n[t])}))}return e}function O(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):function(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n.push.apply(n,r)}return n}(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))})),e}function T(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,l,i=[],o=!0,a=!1;try{for(n=n.call(e);!(o=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){a=!0,l=e}finally{try{o||null==n.return||n.return()}finally{if(a)throw l}}return i}}(e,t)||q(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Q(e){return function(e){if(Array.isArray(e))return x(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||q(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function q(e,t){if(e){if("string"==typeof e)return x(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?x(e,t):void 0}}const F=function(e){var t=e.patientUuid,n=e.closeWorkspace,o=(0,v.useTranslation)().t,a=(0,h.useConfig)().defaultCurrency,c="tablet"===(0,h.useLayoutType)(),s=T((0,r.useState)(0),2),u=s[0],m=s[1],_=T((0,r.useState)([]),2),A=_[0],d=_[1],b=T((0,r.useState)([]),2),f=b[0],g=b[1],p=T((0,r.useState)(""),2),C=(p[0],p[1],T((0,r.useState)(""),2)),B=C[0],x=C[1],D=T((0,r.useState)(!1),2),q=D[0],F=D[1],G=T((0,r.useState)(!1),2),H=G[0],W=G[1],M=T((0,r.useState)([]),2),U=M[0],Y=M[1],z=T((0,r.useState)(""),2),L=z[0],V=z[1],K=(0,h.useDebounce)(L),Z=k.z.object({Qnty:k.z.number().min(1,o("quantityGreaterThanZero","Quantity must be at least one for all items."))}),R=(0,E.Lx)(K,B),J=R.data,$=R.error,X=R.isLoading,ee=(R.isValidating,(0,r.useMemo)((function(){var e;if(!K||X||$)return[];var t=J,n=new Set(f.map((function(e){return e.uuid}))),r=null==t||null===(e=t.results)||void 0===e?void 0:e.map((function(e){var t,n;return{uuid:e.uuid||"",Item:e.commonName?e.commonName:e.name,Qnty:1,Price:e.commonName?10:null===(t=e.servicePrices[0])||void 0===t?void 0:t.price,Total:e.commonName?10:null===(n=e.servicePrices[0])||void 0===n?void 0:n.price,category:e.commonName?"StockItem":"Service"}})).filter((function(e){return!n.has(e.uuid)}));return K?j().filter(K,r,{extract:function(e){return"".concat(e.Item)}}).sort((function(e,t){return e.score-t.score})).map((function(e){return e.original})):A}),[K,J,f]));return(0,r.useEffect)((function(){d(ee)}),[ee]),l().createElement(i.l09,{className:y.form},l().createElement("div",{className:y.grid},l().createElement(i.Kqy,null,l().createElement(i.SYO,{legendText:o("selectCategory","Select category"),name:"radio-button-group",defaultSelected:"radio-1",className:y.mt2,onChange:function(e){document.getElementById("searchField").disabled=!1,x("Stock Item"===e?"Stock Item":"Service")}},l().createElement(i.EUY,{labelText:o("stockItem","Stock Item"),value:"Stock Item",id:"stockItem"}),l().createElement(i.EUY,{labelText:o("service","Service"),value:"Service",id:"service"}))),l().createElement(i.Kqy,null,l().createElement(i.olm,{size:"lg",id:"searchField",disabled:!0,closeButtonLabelText:o("clearSearchInput","Clear search input"),className:y.mt2,placeholder:o("searchItems","Search items and services"),labelText:o("searchItems","Search items and services"),onKeyUp:function(e){return V(e.target.value)}})),l().createElement(i.Kqy,null,l().createElement("ul",{className:y.searchContent},(null==A?void 0:A.length)>0&&(null==A?void 0:A.map((function(e){return l().createElement("li",{key:e.uuid,className:y.searchItem},l().createElement(i.zxk,{id:e.uuid,onClick:function(t){return function(e,t,n,r,l){var i,o=f.findIndex((function(e){return e.uuid===t})),a=[];if(o>=0)a=f.map((function(e,t){if(t===o){var n=e.Qnty+1;return O(N({},e),{Qnty:n,Total:n*e.Price})}return e}));else{var c={uuid:t,Item:n,Qnty:1,Price:l,Total:l,category:r};a=Q(f).concat([c]),Y(Q(U).concat([c]))}g(a),d([]),i=a.reduce((function(e,t){return e+t.Price*t.Qnty}),0),m(i),document.getElementById("searchField").value=""}(0,e.uuid,e.Item,e.category,e.Price)},style:{background:"inherit",color:"black"}},e.Item," Qnty.",e.Qnty," Ksh.",e.Price))}))),0===(null==A?void 0:A.length)&&!X&&!!K&&l().createElement("p",null,o("noResultsFound","No results found")))),l().createElement(i.Kqy,null,l().createElement(i.iA_,{"aria-label":"sample table",className:y.mt2},l().createElement(i.ssF,null,l().createElement(i.SCH,null,l().createElement(i.xDH,null,"Item"),l().createElement(i.xDH,null,"Quantity"),l().createElement(i.xDH,null,"Price"),l().createElement(i.xDH,null,"Total"),l().createElement(i.xDH,null,"Action"))),l().createElement(i.RMI,null,f&&Array.isArray(f)?f.map((function(e){return l().createElement(i.SCH,null,l().createElement(i.pj1,null,e.Item),l().createElement(i.pj1,null,l().createElement("input",{type:"number",className:"form-control ".concat(e.Qnty<=0?y.invalidInput:""),id:e.Item,min:0,max:100,value:e.Qnty,onChange:function(t){!function(e,t){var n=parseInt(e.target.value),r=!0;try{Z.parse({Qnty:n})}catch(e){r=!1;var l=JSON.parse(e.message);(0,h.showToast)({title:o("billItems","Save Bill"),kind:"error",description:l[0].message})}var i=f.map((function(e){return e.Item.toLowerCase().includes(t.toLowerCase())?O(N({},e),{Qnty:n,Total:n>0?e.Price*n:0}):e})),a=i.some((function(e){return e.Qnty<=0}));g(i),F(!r||a);var c=i.reduce((function(e,t){return e+t.Total}),0);m(c)}(t,e.Item),e.Qnty=t.target.value}})),l().createElement(i.pj1,{id:e.Item+"Price"},e.Price),l().createElement(i.pj1,{id:e.Item+"Total",className:"totalValue"},e.Total),l().createElement(i.pj1,null,l().createElement(w.ZN,{onClick:function(){return function(e){var t=f.filter((function(t){return t.uuid!==e}));g(t),Y(U.filter((function(t){return t.uuid!==e})));var n=t.reduce((function(e,t){return e+t.Total}),0);m(n)}(e.uuid)},className:y.removeButton})))})):l().createElement("p",null,"Loading..."),l().createElement(i.SCH,null,l().createElement(i.pj1,{colSpan:3}),l().createElement(i.pj1,{style:{fontWeight:"bold"}},o("grandTotal","Grand total"),":"),l().createElement(i.pj1,{id:"GrandTotalSum"},(0,I.fK)(u,a)))))),l().createElement(i.uVA,{className:c?y.tablet:y.desktop},l().createElement(i.zxk,{className:y.button,kind:"secondary",disabled:H,onClick:n},o("discard","Discard")),l().createElement(i.zxk,{className:y.button,kind:"primary",onClick:function(){W(!0);var e={cashPoint:"54065383-b4d4-42d2-af4d-d250a1fd2590",cashier:"f9badd80-ab76-11e2-9e96-0800200c9a66",lineItems:[],payments:[],patient:t,status:"PENDING"};f.forEach((function(t){var n={quantity:parseInt(t.Qnty),price:t.Price,priceName:"Default",priceUuid:"7b9171ac-d3c1-49b4-beff-c9902aee5245",lineItemOrder:0,paymentStatus:"PENDING"};"StockItem"===t.category?n.item=t.uuid:n.billableService=t.uuid,null==e||e.lineItems.push(n)}));var r="".concat(P.r,"bill");(0,E.TQ)(e).then((function(){W(!1),n(),(0,S.JG)((function(e){return"string"==typeof e&&e.startsWith(r)}),void 0,{revalidate:!0}),(0,h.showSnackbar)({title:o("billItems","Save Bill"),subtitle:"Bill processing has been successful",kind:"success",timeoutInMs:3e3})}),(function(e){W(!1),(0,h.showSnackbar)({title:"Bill processing error",kind:"error",subtitle:null==e?void 0:e.message})}))},disabled:H&&q,type:"submit"},H?l().createElement(i.lSo,{description:o("saving","Saving")+"..."}):o("saveAndClose","Save and close")))))}}}]);
|
package/dist/992.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"992.js","mappings":"iMAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,+hDAAgiD,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,kEAAkE,iDAAiD,wEAAwE,MAAQ,GAAG,SAAW,shBAAshB,WAAa,MAEx1EH,EAAwBI,OAAS,CAChC,OAAU,6CACV,QAAW,8CACX,OAAU,6CACV,IAAO,0CACP,cAAiB,oDACjB,WAAc,iDACd,aAAgB,mDAChB,aAAgB,mDAChB,KAAQ,2CACR,KAAQ,2CACR,IAAO,0CACP,OAAU,8CAEX,S,4MCVIC,EAAU,CAAC,EAEfA,EAAQC,kBAAoB,IAC5BD,EAAQE,cAAgB,IAElBF,EAAQG,OAAS,SAAc,KAAM,QAE3CH,EAAQI,OAAS,IACjBJ,EAAQK,mBAAqB,IAEhB,IAAI,IAASL,GAKnB,QAAe,KAAW,IAAQD,OAAS,IAAQA,YAASO,E,qsECgUnE,QAxTgD,Y,IAAGC,EAAAA,EAAAA,YAAaC,EAAAA,EAAAA,eACxD,GAAQC,EAAAA,EAAAA,kBAANC,EACF,GAAsBC,EAAAA,EAAAA,aAApBC,gBACFC,EAA+B,YAApBC,EAAAA,EAAAA,iBAEmBC,EAAAA,GAAAA,EAAAA,EAAAA,UAAS,MAAtCC,EAA6BD,EAAA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AAW,CAAEuL,YAAY,KACzFC,EAAAA,EAAAA,cAAa,CACXxC,MAAO5I,EAAE,YAAa,aACtBqL,SAAU,sCACVxC,KAAM,UACNyC,YAAa,KAEjB,IACA,SAACtJ,GACCf,GAAgB,IAChBmK,EAAAA,EAAAA,cAAa,CAAExC,MAAO,wBAAyBC,KAAM,QAASwC,SAAUrJ,aAAAA,EAAAA,EAAO0G,SACjF,GAEJ,EA0GU3D,SAAU/D,GAAgBF,EAC1BkH,KAAK,UACJhH,EACC,kBAACuK,EAAAA,IAAaA,CAACzC,YAAa9I,EAAE,SAAU,UAAY,QAEpDA,EAAE,eAAgB,qBAOhC,C","sources":["webpack://@openmrs/esm-billing-app/./src/billing-form/billing-form.scss","webpack://@openmrs/esm-billing-app/./src/billing-form/billing-form.scss?036c","webpack://@openmrs/esm-billing-app/./src/billing-form/billing-form.component.tsx"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","undefined","patientUuid","closeWorkspace","useTranslation","t","useConfig","defaultCurrency","isTablet","useLayoutType","useState","grandTotal","setGrandTotal","searchOptions","setSearchOptions","billItems","setBillItems","category","setCategory","saveDisabled","setSaveDisabled","isSubmitting","setIsSubmitting","addedItems","setAddedItems","searchTerm","setSearchTerm","debouncedSearchTerm","useDebounce","billItemSchema","z","object","Qnty","number","min","useFetchSearchResults","data","error","isLoading","filterItems","isValidating","useMemo","res","existingItemUuids","Set","map","item","uuid","preprocessedData","results","Item","commonName","name","Price","servicePrices","price","Total","filter","has","fuzzy","extract","o","sort","r1","r2","score","result","original","useEffect","Form","className","styles","form","div","grid","Stack","RadioButtonGroup","legendText","defaultSelected","mt2","onChange","choiceSelected","document","getElementById","disabled","RadioButton","labelText","value","Search","size","closeButtonLabelText","placeholder","onKeyUp","e","target","ul","searchContent","length","row","li","key","searchItem","Button","onClick","event","itemid","itemname","itemcategory","itemPrice","sum","existingItemIndex","findIndex","updatedItems","index","updatedQuantity","newItem","reduce","acc","addItemToBill","style","background","color","p","Table","aria-label","TableHead","TableRow","TableHeader","TableBody","Array","isArray","TableCell","input","type","invalidInput","max","itemName","quantity","parseInt","isValid","parse","parsedErrorMessage","JSON","message","showToast","title","kind","description","toLowerCase","includes","anyInvalidQuantity","some","updatedGrandTotal","calculateTotal","TrashCan","removeItemFromBill","removeButton","colSpan","fontWeight","convertToCurrency","ButtonSet","tablet","desktop","button","bill","cashPoint","cashier","lineItems","payments","patient","status","forEach","lineItem","priceName","priceUuid","lineItemOrder","paymentStatus","billableService","url","apiBasePath","processBillItems","then","mutate","startsWith","revalidate","showSnackbar","subtitle","timeoutInMs","InlineLoading"],"sourceRoot":""}
|
package/src/root.scss
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
@use '@carbon/type';
|
|
2
|
-
@import '~@openmrs/esm-styleguide/src/vars';
|
|
3
|
-
|
|
4
|
-
.productiveHeading01 {
|
|
5
|
-
@include type.type-style('heading-compact-01');
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
.productiveHeading02 {
|
|
9
|
-
@include type.type-style('heading-compact-02');
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.bodyLong01 {
|
|
13
|
-
@include type.type-style('body-01');
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.caption01 {
|
|
17
|
-
@include type.type-style('legal-01');
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.bodyShort02 {
|
|
21
|
-
@include type.type-style('body-compact-02');
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.text02 {
|
|
25
|
-
color: $text-02;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.text01 {
|
|
29
|
-
color: $ui-05;
|
|
30
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|