diff --git a/lib/const/api.dart b/lib/const/api.dart index 44eb252..213cf1c 100644 --- a/lib/const/api.dart +++ b/lib/const/api.dart @@ -64,6 +64,34 @@ class _Manage { ///报事报修:查询所有的报事报修信息(包含条件搜索) String get repairList => '/user/repair/list'; + ///报事报修:根据报事报修id查询报修详情 + String get repairDetail => '/user/repair/findById'; + + ///报事报修:查询派工单详情表-派工类型 + String get dispatchListDetailType => + '/manage/dataDictionary/findSysDispatchListDetailType'; + + ///报事报修:查询所有的工单时限信息(id and name) + String get workOrderTimeLimit => '/user/repair/findWorkOrderTimeLimit'; + + ///报事报修:查询所有的工单类型明细信息(工单子类信息) + String get workOrderTypeDetail => '/user/repair/findWorkOrderTypeDetail'; + + ///报事报修:报事报修:派单 + String get repairDispatch => '/user/repair/dispatch'; + + ///报事报修:改派 + String get repairReassignment => '/user/repair/reassignment'; + + ///报事报修:报事报修:接单 + String get recevingOrders => '/user/repair/receivingOrders'; + + ///报事报修:申请延时 + String get applyDelayed => '/user/repair/applyDelayed'; + + ///报事报修:处理完成 + String get handleResult => '/user/repair/handleResult'; + ///借还管理:查询全部物品 String get borrowList => '/user/borrow/articleList'; @@ -104,11 +132,13 @@ class _Manage { class _Upload { ///上传个人资料头像照片 String get avatar => '/user/upload/butlerAppHeadSculpture'; + ///报事报修:根据报事报修id查询报修详情 String get repairDetail => '/user/repair/findById'; ///报事报修:查询派工单详情表-派工类型 - String get dispatchListDetailType => '/manage/dataDictionary/findSysDispatchListDetailType'; + String get dispatchListDetailType => + '/manage/dataDictionary/findSysDispatchListDetailType'; ///报事报修:查询所有的工单时限信息(id and name) String get workOrderTimeLimit => '/user/repair/findWorkOrderTimeLimit'; @@ -116,18 +146,12 @@ class _Upload { ///报事报修:查询所有的工单类型明细信息(工单子类信息) String get workOrderTypeDetail => '/user/repair/findWorkOrderTypeDetail'; - ///报事报修:报事报修:派单 - String get repairDispatch => '/user/repair/dispatch'; + ///上传物品信息详情照片 + String get uploadArticleDetail => '/user/upload/uploadArticleDetail'; - ///报事报修:改派 - String get repairReassignment => '/user/repair/reassignment'; - - ///报事报修:报事报修:接单 - String get recevingOrders => '/user/repair/receivingOrders'; - - ///报事报修:申请延时 - String get applyDelayed => '/user/repair/applyDelayed'; + ///报事报修:处理完成 + String get handleResult => '/user/repair/handleResult'; -///报事报修:处理完成 -String get handleResult => '/user/repair/handleResult'; + ///上传物品信息照片 + String get uploadArtical => '/user/upload/uploadArticle'; } diff --git a/lib/ui/sub_pages/business_and_fix/fix_work_finish_page.dart b/lib/ui/sub_pages/business_and_fix/fix_work_finish_page.dart index 218b13d..c2440b6 100644 --- a/lib/ui/sub_pages/business_and_fix/fix_work_finish_page.dart +++ b/lib/ui/sub_pages/business_and_fix/fix_work_finish_page.dart @@ -2,11 +2,13 @@ import 'dart:io'; // Flutter imports: +import 'package:aku_community_manager/const/api.dart'; import 'package:aku_community_manager/models/manager/bussiness_and_fix/bussiness_and_fix_model.dart'; import 'package:aku_community_manager/models/manager/bussiness_and_fix/fixed_detail_model.dart'; import 'package:aku_community_manager/ui/sub_pages/business_and_fix/fix_submit_finish_page.dart'; import 'package:aku_community_manager/utils/network/base_model.dart'; import 'package:aku_community_manager/utils/network/manage_func.dart'; +import 'package:aku_community_manager/utils/network/net_util.dart'; import 'package:bot_toast/bot_toast.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; @@ -387,7 +389,8 @@ class _FixWorkFinishPageState extends State { // materialPrice: double.parse(_materialController.text), // ); // Get.back(); - + List urls = await NetUtil() + .uploadFiles(_imgs, API.upload.uploadArtical); BaseModel baseModel = await ManageFunc.handleResult( widget.model.repairDetail.dispatchId, _descriptionController.text, @@ -395,10 +398,11 @@ class _FixWorkFinishPageState extends State { humanPrice, materialPrice, humanPrice + materialPrice, - 1, []); + 1, + urls); if (baseModel.status) { FixSubmitFinishPage( - model:widget.fixModel, + model: widget.fixModel, ).to(); } else { BotToast.showText(text: baseModel.message);