Skip to content

Commit

Permalink
fix: Configure service types and billables to be used in billing app
Browse files Browse the repository at this point in the history
  • Loading branch information
WodPachua committed Oct 18, 2024
1 parent 6f44b01 commit 998984a
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 0 deletions.
4 changes: 4 additions & 0 deletions distro/configuration/concepts/billingconcepts.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Uuid,Void/Retire,Same as mappings,Fully specified name:en,Fully specified name:fr,Fully specified name:es,Short name:en,Short name:fr,Short name:es,Description:en,Description:fr,Description:es,Data class,Data type,Members,_version:1,_order:500
3f6f6c92-8d5c-4a9e-bb1c-d3e00e4f8b71,,,Orthopedic Services,,,OPS,,,,,,Misc,Text,,,
550e8400-e29b-41d4-a716-446655440000,,,Nutrition Services,,,NTS,,,,,,Misc,Text,,,
0dfe7d9f-1dc9-4e68-b4cb-d19e1a006c54,,,Service Types,,,,,,,,,ConvSet,N/A,Antenatal Services;Orthopedic Services;Nutrition Services,,
16 changes: 16 additions & 0 deletions distro/configuration/liquibase/liquibase.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>

<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd
http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd">

<!-- Temporary work around to add prices via liquibase, as we wait for for the billable service edit feature -->
<changeSet id="add_item_prices" author="wodpachua">
<sql>SET foreign_key_checks = 0;</sql>
<sqlFile path="sql/item_prices.sql" relativeToChangelogFile="true" stripComments="true" />
<sql>SET foreign_key_checks = 1;</sql>
</changeSet>
</databaseChangeLog>
15 changes: 15 additions & 0 deletions distro/configuration/liquibase/sql/item_prices.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
insert into cashier_item_price (`service_id`, `price`, `payment_mode`, `name`, `creator`, `date_created`, `uuid`)
values
('1', '50.00', '1', 'Cash', '1', NOW(), uuid()),
('1', '55.00', '2', 'Bank transfer', '1', NOW(), uuid()),
('1', '55.00', '3', 'Paypal', '1', NOW(), uuid()),

('2', '80.00', '1', 'Cash', '1', NOW(), uuid()),
('2', '90.00', '2', 'Bank transfer', '1', NOW(), uuid()),
('2', '90.00', '3', 'Paypal', '1', NOW(), uuid()),

('3', '27.00', '1', 'Cash', '1', NOW(), uuid()),
('3', '32.00', '2', 'Bank transfer', '1', NOW(), uuid()),
('3', '32.00', '3', 'Paypal', '1', NOW(), uuid()),

('4', '15.00', '1', 'Cash', '1', NOW(), uuid());
6 changes: 6 additions & 0 deletions frontend/config-core_demo.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,11 @@
},
"@openmrs/esm-styleguide": {
"Brand color #1": "#005d5d"
},
"@openmrs/esm-billing-app": {
"serviceTypes": {
"billableService": "0dfe7d9f-1dc9-4e68-b4cb-d19e1a006c54"
},
"defaultCurrency": "UGX"
}
}

0 comments on commit 998984a

Please sign in to comment.