refactor : apply some analyze
This commit is contained in:
@@ -161,15 +161,14 @@ class InspectionPoultryScienceLogic extends GetxController {
|
||||
Future<void> submitInspectionReport({required int id}) async {
|
||||
isOnUpload.value = true;
|
||||
|
||||
DioFormData formData = DioFormData();
|
||||
var ls = [];
|
||||
var tmpFiles = [];
|
||||
|
||||
for (var element in pickedImages) {
|
||||
ls.add(await MultipartFile.fromFile(element.path, filename: element.name));
|
||||
tmpFiles.add(await MultipartFile.fromFile(element.path, filename: element.name));
|
||||
}
|
||||
|
||||
var data = FormData.fromMap({
|
||||
'file': ls,
|
||||
'file': tmpFiles,
|
||||
'hatching_id': id.toString(),
|
||||
'lat': currentLocation.value.latitude.toString(),
|
||||
'log': currentLocation.value.longitude.toString(),
|
||||
|
||||
@@ -132,11 +132,11 @@ class InspectionPoultrySciencePage extends GetView<InspectionPoultryScienceLogic
|
||||
buildRow(title: 'شماره مجوز جوجه ریزی', value: item.licenceNumber ?? 'N/A'),
|
||||
buildRow(
|
||||
title: 'حجم جوجه ریزی',
|
||||
value: item.quantity.separatedByComma ?? 'N/A',
|
||||
value: item.quantity.separatedByComma,
|
||||
valueStyle: AppFonts.yekan14.copyWith(color: AppColor.blueNormal),
|
||||
),
|
||||
buildRow(title: 'مانده در سالن', value: item.leftOver.separatedByComma ?? 'N/A'),
|
||||
buildRow(title: 'تلفات', value: item.losses.separatedByComma ?? 'N/A'),
|
||||
buildRow(title: 'مانده در سالن', value: item.leftOver.separatedByComma ),
|
||||
buildRow(title: 'تلفات', value: item.losses.separatedByComma ),
|
||||
buildRow(
|
||||
title: 'دامپزشک فارم',
|
||||
value: '${item.vetFarm?.vetFarmFullName}(${item.vetFarm?.vetFarmMobile})',
|
||||
@@ -152,7 +152,7 @@ class InspectionPoultrySciencePage extends GetView<InspectionPoultryScienceLogic
|
||||
),
|
||||
),
|
||||
Visibility(
|
||||
visible: (item.reportInfo?.image == false ?? false),
|
||||
visible: (item.reportInfo?.image == false),
|
||||
child: RElevated(
|
||||
text: 'ثبت بازرسی',
|
||||
isFullWidth: true,
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:rasadyar_chicken/presentation/pages/role/view.dart';
|
||||
import 'package:rasadyar_chicken/presentation/widget/app_bar.dart';
|
||||
import 'package:rasadyar_core/core.dart';
|
||||
|
||||
import '../../../widget/app_bar.dart';
|
||||
import 'logic.dart';
|
||||
|
||||
class PoultryActionPage extends GetView<PoultryActionLogic> {
|
||||
|
||||
Reference in New Issue
Block a user