Skip to content

Commit

Permalink
OZ-464: Add more metadata & create ERPNext mgt db script.
Browse files Browse the repository at this point in the history
  • Loading branch information
corneliouzbett committed Apr 4, 2024
1 parent 552f2aa commit 0a955ed
Show file tree
Hide file tree
Showing 5 changed files with 132 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,2 +1,23 @@
Item Group Name,Parent Item Group,Is Group,Company,Default Warehouse,Default Price List
ENT,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
General Surgery,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Histopathology,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Laboratory,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Materials,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Maxillofacial,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Obstetrics,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Ophtamology,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Orthopedics and Traumatology,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Plastic Surgery,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Procedures,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Radiology,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Urology,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Wound Dressing Without Anesthesia,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Wound Dressing With Anesthesia,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Wounds,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Others,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Exoneration,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Insurance,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Dental,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Consultation,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Drugs,All Item Groups,0,Ozone Demo,Ozone Warehouse,Standard Selling
Original file line number Diff line number Diff line change
@@ -1,5 +1,47 @@
Item Code,Price List,Rate,Currency,UOM
1019AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Standard Selling,60.0,USD,Unit
163697AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Standard Selling,5.4,USD,Unit
161451AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Standard Selling,6.3,USD,Unit
953AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Standard Selling,7.1,USD,Unit
3543c654-0834-4c90-982c-5e277005c15d,Standard Selling,0.45,USD,Tablet
0bd1bf31-b974-421f-854d-b9d463630a2b,Standard Selling,0.80,USD,Tablet
3af6ca73-f2ee-43ff-8464-fa00bf525e9b,Standard Selling,0.45,USD,Tablet
143c0048-33d5-46e6-b7b9-85b12769b629,Standard Selling,0.80,USD,Tablet
9c257346-524c-4eef-bcf3-2cf4b472b2a8,Standard Selling,0.45,USD,Tablet
fb601ad7-ffb6-4624-8f64-93522bb8d4ac,Standard Selling,0.80,USD,Tablet
a8dd3068-cd3b-4af3-a33d-616279b29db5,Standard Selling,0.66,USD,Tablet
340c9cdf-97fe-497f-9d0d-d66b8552aa25,Standard Selling,0.72,USD,Tablet
124a4a8e-f920-4898-b3d0-6d463b1c3db2,Standard Selling,0.78,USD,Tablet
eca6b8c2-5b46-4a94-a7d9-24722be131b8,Standard Selling,0.84,USD,Tablet
d8fdc1b7-e393-45e8-8a64-dc95e57f89f4,Standard Selling,0.90,USD,Tablet
c3fccbc6-565e-4c2c-b1aa-bba217fd212e,Standard Selling,0.96,USD,Tablet
6ca6fa54-5b32-4d64-a66c-542c0889f840,Standard Selling,1.02,USD,Tablet
09e58895-e7f0-4649-b7c0-e665c5c08e93,Standard Selling,1.08,USD,Tablet
38087db3-7395-431f-88d5-bb25e06e33f1,Standard Selling,1.14,USD,Tablet
8d4d2102-52a5-445d-9e0f-462d8967336a,Standard Selling,1.20,USD,Tablet
c0a931b7-c900-45fe-b672-b78a00f41ed2,Standard Selling,1.26,USD,Tablet
12da54e5-294a-4be2-834c-4ffd996a5bf6,Standard Selling,1.32,USD,Tablet
fc882328-40ef-4fa3-852f-81f69fcf954f,Standard Selling,1.38,USD,Tablet
0adc85cf-de4e-4c4b-a483-d8586f19626b,Standard Selling,1.44,USD,Tablet
d5d560bc-e481-4874-93d0-a1023d1ce766,Standard Selling,0.45,USD,Tablet
45395ed4-63b2-43d2-af2a-23f4dc8e1b9e,Standard Selling,0.80,USD,Tablet
a8e05fa5-d9be-49ae-b266-cf9a4e2f2d60,Standard Selling,0.45,USD,Tablet
d6a60960-b4df-4ab0-a231-1c3fcc8414e1,Standard Selling,0.80,USD,Tablet
af4be8ee-45b3-47e3-a32e-1c3bfb2e6f61,Standard Selling,0.45,USD,Tablet
912e4679-7758-403e-8441-5b528561f7bc,Standard Selling,0.80,USD,Tablet
2949ec94-0e60-4a99-b699-e36daa665033,Standard Selling,0.66,USD,Tube
f691c1c4-1fe3-4fd5-afbf-2167ad241164,Standard Selling,0.72,USD,Tube
4125aa3e-4b43-41c2-99a3-00bb71978084,Standard Selling,0.78,USD,Tube
5363a53f-a3c2-4a29-b7f0-a4b075052e5e,Standard Selling,0.84,USD,Tablet
5449d13a-591f-4840-9739-870966625f0f,Standard Selling,0.90,USD,Tablet
12dd160a-2ab4-4b95-900c-40ebf6ccc55f,Standard Selling,0.96,USD,Tablet
76a434fd-df90-4b19-ba47-26ddd7a00437,Standard Selling,1.02,USD,Tablet
56034516-35a4-4bca-826e-df42008ebeed,Standard Selling,1.08,USD,Tablet
396c0447-c8e2-4f2f-a9a1-b664efe352ea,Standard Selling,1.14,USD,Tablet
a8355c83-31db-4089-a962-512e35097ef0,Standard Selling,1.20,USD,Tablet
c554ffb2-5706-4623-a89a-008366cd564c,Standard Selling,1.26,USD,Tablet
8dd89c2e-b45b-4fea-98d5-f6b9f02247c1,Standard Selling,1.32,USD,Tablet
94c9f33b-ffe9-466b-8090-77cd3d5334f0,Standard Selling,1.38,USD,Tablet
4bc64ce7-18a8-460a-9314-0f89e4ca2d0b,Standard Selling,0.50,USD,Tablet
20e0d495-b906-405e-9cc7-1a18e14a5612,Standard Selling,1.25,USD,Tablet
8b8aceae-7a1e-49d1-823a-ae657ea4184f,Standard Selling,1.25,USD,Tablet
42 changes: 42 additions & 0 deletions distro/configs/erpnext/initializer_config/items/insert_item.csv
Original file line number Diff line number Diff line change
@@ -1,5 +1,47 @@
ID,Default Unit of Measure,Item Code,Item Group,Item Name
1019AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Unit,Complete blood count,Laboratory,Complete blood count
163697AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Unit,Urine microscopy panel,Laboratory,Urine microscopy panel
161451AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Unit,Stool test,Laboratory,Stool test
953AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA,Unit,Liver function tests,Laboratory,Liver function tests
3543c654-0834-4c90-982c-5e277005c15d,Tablet,Griséofulvine Co 500mg,Drugs,Griséofulvine Co 500mg
0bd1bf31-b974-421f-854d-b9d463630a2b,Tablet,Tylenol 325mg,Drugs,Tylenol 325mg
3af6ca73-f2ee-43ff-8464-fa00bf525e9b,Tablet,Advil 200mg,Drugs,Advil 200mg
143c0048-33d5-46e6-b7b9-85b12769b629,Tablet,Multi-Vitamin Adult,Drugs,Multi-Vitamin Adult
9c257346-524c-4eef-bcf3-2cf4b472b2a8,Tablet,Multi-Vitamin Children,Drugs,Multi-Vitamin Children
fb601ad7-ffb6-4624-8f64-93522bb8d4ac,Tablet,Multi-Vitamin Prenatal,Drugs,Multi-Vitamin Prenatal
a8dd3068-cd3b-4af3-a33d-616279b29db5,Tablet,Norvasc 5mg,Drugs,Norvasc 5mg
340c9cdf-97fe-497f-9d0d-d66b8552aa25,Tablet,Norvasc 10mg,Drugs,Norvasc 10mg
124a4a8e-f920-4898-b3d0-6d463b1c3db2,Tablet,Atenolol 50mg,Drugs,Atenolol 50mg
eca6b8c2-5b46-4a94-a7d9-24722be131b8,Tablet,Hctz 25mg,Drugs,Hctz 25mg
d8fdc1b7-e393-45e8-8a64-dc95e57f89f4,Tablet,Hctz 50mg,Drugs,Hctz 50mg
c3fccbc6-565e-4c2c-b1aa-bba217fd212e,Tablet,Zestril 20mg,Drugs,Zestril 20mg
6ca6fa54-5b32-4d64-a66c-542c0889f840,Tablet,Lasix 20mg,Drugs,Lasix 20mg
09e58895-e7f0-4649-b7c0-e665c5c08e93,Tablet,Aspirin 81mg,Drugs,Aspirin 81mg
38087db3-7395-431f-88d5-bb25e06e33f1,Tablet,Aspirin 325mg,Drugs,Aspirin 325mg
8d4d2102-52a5-445d-9e0f-462d8967336a,Tablet,Celebrex 200mg,Drugs,Celebrex 200mg
c0a931b7-c900-45fe-b672-b78a00f41ed2,Tablet,Neurontin 100mg,Drugs,Neurontin 100mg
12da54e5-294a-4be2-834c-4ffd996a5bf6,Tablet,Neurontin 800mg,Drugs,Neurontin 800mg
fc882328-40ef-4fa3-852f-81f69fcf954f,Tablet,Tums,Drugs,Tums
0adc85cf-de4e-4c4b-a483-d8586f19626b,Tablet,Prilosec 20mg,Drugs,Prilosec 20mg
d5d560bc-e481-4874-93d0-a1023d1ce766,Tablet,Zantac 150mg,Drugs,Zantac 150mg
45395ed4-63b2-43d2-af2a-23f4dc8e1b9e,Tablet,Protonix 20mg,Drugs,Protonix 20mg
a8e05fa5-d9be-49ae-b266-cf9a4e2f2d60,Tablet,Glucophage 500mg,Drugs,Glucophage 500mg
d6a60960-b4df-4ab0-a231-1c3fcc8414e1,Tablet,Glucotrol 5mg,Drugs,Glucotrol 5mg
af4be8ee-45b3-47e3-a32e-1c3bfb2e6f61,Tablet,Glipizide Er 3mg,Drugs,Glipizide Er 6mg
912e4679-7758-403e-8441-5b528561f7bc,Tablet,Glipizide Er 6mg,Drugs,Glipizide Er 6mg
2949ec94-0e60-4a99-b699-e36daa665033,Tube,Bacitracin,Drugs,Bacitracin
f691c1c4-1fe3-4fd5-afbf-2167ad241164,Tube,Lotrimin 1%,Drugs,Lotrimin 1%
4125aa3e-4b43-41c2-99a3-00bb71978084,Tube,Nystatin 100000U/g,Drugs,Nystatin 100000U/g
5363a53f-a3c2-4a29-b7f0-a4b075052e5e,Tablet,Levaquin 250mg,Drugs,Levaquin 250mg
5449d13a-591f-4840-9739-870966625f0f,Tablet,Valtrex 1g,Drugs,Valtrex 1g
12dd160a-2ab4-4b95-900c-40ebf6ccc55f,Tablet,Doxycycline 100mg,Drugs,Doxycycline 100mg
76a434fd-df90-4b19-ba47-26ddd7a00437,Tablet,Diflucan 200mg,Drugs,Diflucan 200mg
56034516-35a4-4bca-826e-df42008ebeed,Tablet,Albenza 400mg,Drugs,Albenza 400mg
396c0447-c8e2-4f2f-a9a1-b664efe352ea,Tablet,Lindane 1%,Drugs,Lindane 1%
a8355c83-31db-4089-a962-512e35097ef0,Tablet,Amoxicillin 500mg,Drugs,Amoxicillin 500mg
c554ffb2-5706-4623-a89a-008366cd564c,Tablet,Flagyl 250mg,Drugs,Flagyl 250mg
8dd89c2e-b45b-4fea-98d5-f6b9f02247c1,Tablet,Ceftin 250mg / 5ml,Drugs,Ceftin 250mg / 5ml
94c9f33b-ffe9-466b-8090-77cd3d5334f0,Tablet,Rocephin 1g,Drugs,Rocephin 1g
4bc64ce7-18a8-460a-9314-0f89e4ca2d0b,Tablet,Bactrim 160mg + 800mg,Drugs,Bactrim 160mg + 800mg
20e0d495-b906-405e-9cc7-1a18e14a5612,Tablet,Atenolol 100mg,Drugs,Atenolol 100mg
8b8aceae-7a1e-49d1-823a-ae657ea4184f,Tablet,Atenolol 25mg,Drugs,Atenolol 25mg
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
UOM Name,Enabled,Must be Whole Number
Tablet,1,1
Tube,1,1
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/bin/bash

set -eu

function create_user_and_database() {
mysql --password="$MYSQL_ROOT_PASSWORD" --user=root <<MYSQL_SCRIPT
CREATE DATABASE $1;
CREATE USER '$2'@'localhost' IDENTIFIED BY '$3';
CREATE USER '$2'@'%' IDENTIFIED BY '$3';
GRANT ALL PRIVILEGES ON $1.* TO '$2'@'localhost';
GRANT ALL PRIVILEGES ON $1.* TO '$2'@'%';
FLUSH PRIVILEGES;
MYSQL_SCRIPT
}

create_eip_client_user_and_database() {
local dbName="${1:-}"
local dbUser="${2:-}"
local dbUserPassword="${3:-}"
if [ "${dbName:-}" ] && [ "${dbUser:-}" ] && [ "${dbUserPassword:-}" ]; then
create_user_and_database "$dbName" "$dbUser" "$dbUserPassword";
fi
}

echo "Creating '${EIP_DB_USER_ERPNEXT}' user and '${EIP_DB_NAME_ERPNEXT}' management database..."
create_eip_client_user_and_database "${EIP_DB_NAME_ERPNEXT:-}" "${EIP_DB_USER_ERPNEXT:-}" "${EIP_DB_PASSWORD_ERPNEXT:-}";

0 comments on commit 0a955ed

Please sign in to comment.