queryDataList static method

Future<List<ScanModel>?> queryDataList(
  1. String taskId,
  2. String actualOrder
)

Implementation

static Future<List<ScanModel>?> queryDataList(
  String taskId,
  String actualOrder,
) async {
  List<Map<String, Object?>> list = await database!.rawQuery(
      'SELECT * FROM lesntec_scans WHERE taskId = ? AND actualOrder = ?',
      [taskId, actualOrder]);
  List<ScanModel> listTemp = [];
  for (var element in list) {
    ScanModel model = ScanModel.fromJson(element);
    listTemp.add(model);
  }
  return listTemp;
}