update
This commit is contained in:
parent
ecccd4a9bf
commit
2d3f5bd96e
11 changed files with 184 additions and 143 deletions
|
|
@ -45,6 +45,15 @@ class RefMedicines {
|
|||
}
|
||||
}
|
||||
|
||||
Future<String> getNameUsingBarcode(String barcode) async {
|
||||
try {
|
||||
final data = await _supabase.from('ref_medicines').select('medicine_name').eq('barcode', barcode);
|
||||
return data.first['medicine_name'];
|
||||
} catch (e) {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
||||
Future<bool> postMedicine(String uuid, String name, String muuid, String guuid, String tuuid, String barcode) async {
|
||||
final medicine = {
|
||||
'ref_medicines_uuid': uuid,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue