From 450e0117bfa146c35645bc232d692df2669de85b Mon Sep 17 00:00:00 2001 From: zhangmeng <494089941@qq.com> Date: Thu, 17 Mar 2022 11:02:46 +0800 Subject: [PATCH] sars -> saas --- lib/constants/market_api.dart | 2 +- lib/constants/profile_api.dart | 2 +- .../{sars_api.dart => saas_api.dart} | 2 +- .../community_introduce_page.dart | 4 +-- .../electronic_commerc_card.dart | 4 +-- .../event_activity/event_voting_page.dart | 4 +-- .../event_activity/voting_detail_page.dart | 6 ++-- .../geograhic_information.dart | 4 +-- .../geographic_information_page.dart | 4 +-- .../borrow/borrow_goods_detail_page.dart | 4 +-- .../borrow/borrow_goods_page.dart | 21 +++++++------- .../goods_manage_page/goods_manage_page.dart | 4 +-- .../retrun/return_goods_detail_page.dart | 18 +++++------- lib/pages/home/home_page.dart | 4 +-- .../house_introduce/house_introduce.dart | 13 ++++----- .../industry_committee_page.dart | 16 +++++----- .../announce/announce_view.dart | 6 ++-- .../comment_message/comment_message_page.dart | 14 ++++----- .../message_center_page.dart | 4 +-- .../message_center_page/message_func.dart | 4 +-- .../reply/replay_view.dart | 4 +-- .../thumbs_up/thumbs_up_view.dart | 4 +-- .../personal/clock_in/clock_in_page.dart | 21 ++++++-------- lib/pages/personal/personal_page.dart | 20 ++++++------- lib/pages/personal/user_func.dart | 12 ++++---- lib/pages/personal/user_profile_page.dart | 4 +-- .../share_pay_page/share_record_page.dart | 2 +- .../sign/login/select_community_page.dart | 4 +-- lib/pages/sign/sign_func.dart | 20 ++++++------- .../surrounding_enterprises_detail_page.dart | 11 +++---- .../surrounding_enterprises_page.dart | 12 ++++---- lib/pages/things_page/fixed_submit_page.dart | 15 ++++------ .../widget/add_fixed_submit_page.dart | 11 +++---- .../things_page/widget/fixed_detail_page.dart | 15 ++++------ .../visitor_access_page.dart | 19 +++++------- lib/provider/app_provider.dart | 4 +-- lib/provider/data_provider.dart | 8 ++--- lib/provider/user_provider.dart | 4 +-- .../activity/activity_detail_page.dart | 6 ++-- .../activity/activity_detail_page_old.dart | 20 ++++++------- .../activity/activity_list_page.dart | 4 +-- .../activity/activity_people_list_page.dart | 10 +++---- lib/ui/community/community_func.dart | 24 +++++++-------- .../community_views/add_new_event_page.dart | 6 ++-- .../community_views/community_page.dart | 8 ++--- .../community_views/event_detail_page.dart | 16 +++++----- .../community_views/my_community_view.dart | 6 ++-- .../community_views/new_community_view.dart | 11 +++---- .../topic/topic_community_view.dart | 4 +-- .../topic/topic_detail_page.dart | 8 ++--- .../topic/topic_search_page.dart | 17 +++++------ .../topic/topic_sliver_header.dart | 4 +-- .../community_views/widgets/chat_card.dart | 8 ++--- .../widgets/chat_card_detail.dart | 6 ++-- .../widgets/my_event_card.dart | 6 ++-- .../community_views/widgets/send_a_chat.dart | 11 +++---- .../facility/facility_appointment_card.dart | 11 +++---- .../facility/facility_appointment_view.dart | 7 ++--- .../facility/facility_type_card.dart | 11 +++---- .../facility/facility_type_detail_page.dart | 9 ++---- .../fcility_order_date_list_page.dart | 2 +- .../facility/pick_facility_page.dart | 7 ++--- .../community/notice/notice_detail_page.dart | 6 ++-- lib/ui/community/notice/notice_page.dart | 4 +-- .../task/hall/hall_view.dart | 4 +-- .../task/my_take_task/my_take_task_view.dart | 4 +-- .../task/my_task/my_task_view.dart | 4 +-- .../task/publish_task_page.dart | 6 ++-- .../function_and_service/task/task_func.dart | 16 +++++----- .../public_infomation_view.dart | 4 +-- .../advice/advice_add_comment_page.dart | 2 +- lib/ui/manager/advice/advice_detail_page.dart | 2 +- .../manager/advice/advice_evaluate_page.dart | 11 +++---- lib/ui/manager/advice/advice_page.dart | 2 +- lib/ui/manager/advice/new_advice_page.dart | 2 +- .../house_keeping/add_house_keeping_page.dart | 15 ++++------ .../house_keeping/house_keeping_card.dart | 19 +++++------- .../house_keeping_detail_page.dart | 2 +- .../house_keeping/house_keeping_func.dart | 4 +-- .../house_keeping/house_keeping_view.dart | 2 +- .../questionnaire_detail_page.dart | 15 ++++------ .../questionnaire/questionnaire_page.dart | 14 ++++----- lib/ui/manager/visitor/visitor_list_item.dart | 15 ++++------ .../manager/visitor/visitor_record_view.dart | 7 ++--- .../category/new_category_sub_card.dart | 11 +++---- lib/ui/market/collection/collection_func.dart | 7 ++--- lib/ui/market/market_page.dart | 8 ++--- lib/ui/market/order/order_card.dart | 8 ++--- lib/ui/market/order/order_detail_page.dart | 10 +++---- lib/ui/market/order/order_view.dart | 10 +++---- lib/ui/market/search/search_func.dart | 6 ++-- lib/ui/market/search/search_goods_page.dart | 2 +- lib/ui/market/search/submit_order_page.dart | 6 ++-- .../search/submit_order_page_normal.dart | 6 ++-- lib/ui/market/shop_car/shop_car_page.dart | 29 +++++++++---------- lib/ui/market/widget/market_success_page.dart | 12 ++++---- lib/ui/profile/house/add_house_page.dart | 16 +++++----- .../contract_stop/pay_surplus_rent_page.dart | 2 +- lib/ui/profile/house/house_func.dart | 2 +- .../lease_pay_query_detail_page.dart | 2 +- .../lease_pay_query/lease_pay_query_page.dart | 17 +++++------ .../lease_relevation/contract_pay_page.dart | 17 +++++------ .../contract_preview_page.dart | 21 ++++++-------- .../tenant_house_list_page.dart | 2 +- lib/ui/profile/new_house/add_house_page.dart | 23 +++++++-------- .../profile/new_house/apply_record_page.dart | 15 ++++------ .../certification/certification_page.dart | 19 +++++------- lib/ui/profile/new_house/examine_view.dart | 21 ++++++-------- lib/ui/profile/new_house/member_view.dart | 15 ++++------ lib/ui/search/bee_search.dart | 16 +++++----- lib/utils/network/net_util.dart | 10 +++---- lib/widget/beeImageNetwork.dart | 6 ++-- lib/widget/picker/bee_image_preview.dart | 4 +-- lib/widget/views/bee_download_view.dart | 7 ++--- lib/widget/views/bee_grid_image_view.dart | 4 +-- lib/widget/views/horizontal_image_view.dart | 13 ++++----- lib/widget/voice_player.dart | 4 +-- 117 files changed, 468 insertions(+), 595 deletions(-) rename lib/constants/{sars_api.dart => saas_api.dart} (99%) diff --git a/lib/constants/market_api.dart b/lib/constants/market_api.dart index a479c038..561f7c8e 100644 --- a/lib/constants/market_api.dart +++ b/lib/constants/market_api.dart @@ -1,4 +1,4 @@ -part of 'sars_api.dart'; +part of 'saas_api.dart'; class _MarketApi { _Collection collection = _Collection(); diff --git a/lib/constants/profile_api.dart b/lib/constants/profile_api.dart index 4ba963ad..40057b68 100644 --- a/lib/constants/profile_api.dart +++ b/lib/constants/profile_api.dart @@ -1,4 +1,4 @@ -part of 'sars_api.dart'; +part of 'saas_api.dart'; class _ProfileApi { _MyHouse house = _MyHouse(); diff --git a/lib/constants/sars_api.dart b/lib/constants/saas_api.dart similarity index 99% rename from lib/constants/sars_api.dart rename to lib/constants/saas_api.dart index ed7aeb55..7cac0182 100644 --- a/lib/constants/sars_api.dart +++ b/lib/constants/saas_api.dart @@ -3,7 +3,7 @@ import 'package:aku_new_community/widget/others/user_tool.dart'; part 'market_api.dart'; part 'profile_api.dart'; -class SARSAPI { +class SAASAPI { ///HOST static const String host = 'http://121.41.26.225:8006'; diff --git a/lib/pages/community_introduce/community_introduce_page.dart b/lib/pages/community_introduce/community_introduce_page.dart index b18cb927..05e95dbf 100644 --- a/lib/pages/community_introduce/community_introduce_page.dart +++ b/lib/pages/community_introduce/community_introduce_page.dart @@ -1,7 +1,7 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/community_introduce/community_introduce_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; @@ -48,7 +48,7 @@ class _CommunityIntroducePageState extends State { child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, fit: BoxFit.cover, - image: SARSAPI.image(ImgModel.first(_model.imgList))), + image: SAASAPI.image(ImgModel.first(_model.imgList))), width: double.infinity, height: 424.w, ), diff --git a/lib/pages/electronic_commerc/electronic_commerc_card.dart b/lib/pages/electronic_commerc/electronic_commerc_card.dart index 3aa3987a..08c2faa9 100644 --- a/lib/pages/electronic_commerc/electronic_commerc_card.dart +++ b/lib/pages/electronic_commerc/electronic_commerc_card.dart @@ -1,6 +1,6 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/electronic_commerc/electronic_commerc_list_model.dart'; import 'package:aku_new_community/pages/electronic_commerc/electronic_commerc_detail_page.dart'; @@ -70,7 +70,7 @@ class _ElectronicCommercCardState extends State { width: 240.w, height: 200.w, fit: BoxFit.cover, - image: SARSAPI.image(ImgModel.first(model.imgList)), + image: SAASAPI.image(ImgModel.first(model.imgList)), ), ], ), diff --git a/lib/pages/event_activity/event_voting_page.dart b/lib/pages/event_activity/event_voting_page.dart index e4b80837..6927c303 100644 --- a/lib/pages/event_activity/event_voting_page.dart +++ b/lib/pages/event_activity/event_voting_page.dart @@ -1,6 +1,6 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/event_voting_model.dart'; import 'package:aku_new_community/pages/event_activity/voting_detail_page.dart'; @@ -61,7 +61,7 @@ class _EventVotingPageState extends State { child: ClipRect( child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), fit: BoxFit.cover, ), ), diff --git a/lib/pages/event_activity/voting_detail_page.dart b/lib/pages/event_activity/voting_detail_page.dart index 7adf227f..861dea77 100644 --- a/lib/pages/event_activity/voting_detail_page.dart +++ b/lib/pages/event_activity/voting_detail_page.dart @@ -1,6 +1,6 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/voting_detail_model.dart'; import 'package:aku_new_community/pages/manager_func.dart'; @@ -133,7 +133,7 @@ class _VotingDetailPageState extends State { borderRadius: BorderRadius.circular(4.w), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image( + image: SAASAPI.image( ImgModel.first(model.imgUrls), ), fit: BoxFit.cover, @@ -232,7 +232,7 @@ class _VotingDetailPageState extends State { borderRadius: BorderRadius.circular(8.w), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(_model.imgUrls)), + image: SAASAPI.image(ImgModel.first(_model.imgUrls)), ), ), 44.w.heightBox, diff --git a/lib/pages/geographic_information/geograhic_information.dart b/lib/pages/geographic_information/geograhic_information.dart index 14920f81..6707b934 100644 --- a/lib/pages/geographic_information/geograhic_information.dart +++ b/lib/pages/geographic_information/geograhic_information.dart @@ -1,7 +1,7 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/geographic_information/geographic_information_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; @@ -51,7 +51,7 @@ class _GeographicInformationPageState extends State { child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, fit: BoxFit.cover, - image: SARSAPI.image(ImgModel.first(_model.imgUrls))), + image: SAASAPI.image(ImgModel.first(_model.imgUrls))), width: double.infinity, height: 424.w, ), diff --git a/lib/pages/geographic_information/geographic_information_page.dart b/lib/pages/geographic_information/geographic_information_page.dart index 7f13d0f7..63196d11 100644 --- a/lib/pages/geographic_information/geographic_information_page.dart +++ b/lib/pages/geographic_information/geographic_information_page.dart @@ -1,7 +1,7 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/geographic_information/geographic_information_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; @@ -51,7 +51,7 @@ class _GeographicInformationPageState extends State { child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, fit: BoxFit.cover, - image: SARSAPI.image(ImgModel.first(_model.imgUrls))), + image: SAASAPI.image(ImgModel.first(_model.imgUrls))), width: double.infinity, height: 424.w, ), diff --git a/lib/pages/goods_manage_page/borrow/borrow_goods_detail_page.dart b/lib/pages/goods_manage_page/borrow/borrow_goods_detail_page.dart index 91e3efe1..013e404c 100644 --- a/lib/pages/goods_manage_page/borrow/borrow_goods_detail_page.dart +++ b/lib/pages/goods_manage_page/borrow/borrow_goods_detail_page.dart @@ -1,7 +1,7 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/article_borrow_detail_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; @@ -197,7 +197,7 @@ class _BorrowGoodsDetailPageState extends State { child: ClipRRect( child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgList)), + image: SAASAPI.image(ImgModel.first(model.imgList)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, diff --git a/lib/pages/goods_manage_page/borrow/borrow_goods_page.dart b/lib/pages/goods_manage_page/borrow/borrow_goods_page.dart index 91ed8116..430f9c1a 100644 --- a/lib/pages/goods_manage_page/borrow/borrow_goods_page.dart +++ b/lib/pages/goods_manage_page/borrow/borrow_goods_page.dart @@ -1,16 +1,7 @@ -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:power_logger/power_logger.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/article_borrow_model.dart'; import 'package:aku_new_community/pages/goods_manage_page/borrow/borrow_goods_detail_page.dart'; @@ -18,6 +9,14 @@ import 'package:aku_new_community/utils/network/base_list_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:power_logger/power_logger.dart'; +import 'package:velocity_x/velocity_x.dart'; + import 'borrow_examine_page.dart'; class BorrowGoodsSubmitModel { @@ -172,7 +171,7 @@ class _BorrowGoodsPageState extends State { child: ClipRRect( child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, diff --git a/lib/pages/goods_manage_page/goods_manage_page.dart b/lib/pages/goods_manage_page/goods_manage_page.dart index 0b1c63b7..30d0aee5 100644 --- a/lib/pages/goods_manage_page/goods_manage_page.dart +++ b/lib/pages/goods_manage_page/goods_manage_page.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/article_borrow_model.dart'; import 'package:aku_new_community/pages/goods_manage_page/borrow/borrow_goods_page.dart'; @@ -53,7 +53,7 @@ class _GoodsManagePageState extends State { child: ClipRRect( child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, diff --git a/lib/pages/goods_manage_page/retrun/return_goods_detail_page.dart b/lib/pages/goods_manage_page/retrun/return_goods_detail_page.dart index 21b4c2e6..b513d976 100644 --- a/lib/pages/goods_manage_page/retrun/return_goods_detail_page.dart +++ b/lib/pages/goods_manage_page/retrun/return_goods_detail_page.dart @@ -1,15 +1,7 @@ -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/article_return_list_model.dart'; import 'package:aku_new_community/pages/goods_manage_page/borrow/borrow_examine_page.dart'; @@ -17,6 +9,12 @@ import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/radio_button.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class ReturnGoodsDetailPage extends StatefulWidget { ReturnGoodsDetailPage({Key? key}) : super(key: key); @@ -205,7 +203,7 @@ class _ReturnGoodsDetailPageState extends State { child: ClipRRect( child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgList)), + image: SAASAPI.image(ImgModel.first(model.imgList)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, diff --git a/lib/pages/home/home_page.dart b/lib/pages/home/home_page.dart index 365072d7..2c9a4181 100644 --- a/lib/pages/home/home_page.dart +++ b/lib/pages/home/home_page.dart @@ -1,7 +1,7 @@ // Dart imports: import 'package:aku_new_community/constants/application_objects.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/color_ext.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/home/home_activity_model.dart'; @@ -549,7 +549,7 @@ class _HomePageState extends State if (_swiperModels.isNotEmpty) { var color = await PaletteGenerator.fromImageProvider(CachedNetworkImageProvider( - SARSAPI.image(ImgModel.first(_swiperModels[index].imgList)), + SAASAPI.image(ImgModel.first(_swiperModels[index].imgList)), )); _barColor.value = color.dominantColor?.color ?? Colors.transparent; } else { diff --git a/lib/pages/house_introduce/house_introduce.dart b/lib/pages/house_introduce/house_introduce.dart index a9abc6a3..ab64bb68 100644 --- a/lib/pages/house_introduce/house_introduce.dart +++ b/lib/pages/house_introduce/house_introduce.dart @@ -1,17 +1,16 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/house_introduce/house_introduce_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; + import 'house_detail_page.dart'; class HouseIntroducePage extends StatefulWidget { @@ -56,7 +55,7 @@ class _HouseIntroducePageState extends State { borderRadius: BorderRadius.circular(4.w), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), height: 200.w, width: 240.w, fit: BoxFit.fill, diff --git a/lib/pages/industry_committee/industry_committee_page.dart b/lib/pages/industry_committee/industry_committee_page.dart index 97027d8f..63724928 100644 --- a/lib/pages/industry_committee/industry_committee_page.dart +++ b/lib/pages/industry_committee/industry_committee_page.dart @@ -1,14 +1,7 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; -import 'package:url_launcher/url_launcher.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/user/committee_item_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; @@ -16,6 +9,11 @@ import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/hive_store.dart'; import 'package:aku_new_community/utils/websocket/tips_dialog.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; +import 'package:url_launcher/url_launcher.dart'; class IndustryCommitteePage extends StatefulWidget { IndustryCommitteePage({Key? key}) : super(key: key); @@ -97,7 +95,7 @@ class _IndustryCommitteePageState extends State { borderRadius: BorderRadius.circular(4.w), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), height: 150.w, width: 150.w, fit: BoxFit.cover, diff --git a/lib/pages/message_center_page/announce/announce_view.dart b/lib/pages/message_center_page/announce/announce_view.dart index efb774c9..418209c3 100644 --- a/lib/pages/message_center_page/announce/announce_view.dart +++ b/lib/pages/message_center_page/announce/announce_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/home/home_announce_model.dart'; import 'package:aku_new_community/pages/message_center_page/announce/announce_card.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; @@ -112,7 +112,7 @@ class _AnnounceViewState extends State { _modelLists.clear(); _innerModelList.clear(); var base = - await NetUtil().getList(SARSAPI.announce.list, params: { + await NetUtil().getList(SAASAPI.announce.list, params: { 'page': _page, 'size': _size, }); @@ -128,7 +128,7 @@ class _AnnounceViewState extends State { onLoad: () async { _page++; var base = - await NetUtil().getList(SARSAPI.announce.list, params: { + await NetUtil().getList(SAASAPI.announce.list, params: { 'page': _page, 'size': _size, }); diff --git a/lib/pages/message_center_page/comment_message/comment_message_page.dart b/lib/pages/message_center_page/comment_message/comment_message_page.dart index 1d5a6fa2..6c097446 100644 --- a/lib/pages/message_center_page/comment_message/comment_message_page.dart +++ b/lib/pages/message_center_page/comment_message/comment_message_page.dart @@ -1,10 +1,5 @@ -import 'package:flutter/cupertino.dart'; - -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/message/comment_message_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; @@ -12,6 +7,9 @@ import 'package:aku_new_community/utils/bee_date_util.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; class CommentMessagePage extends StatefulWidget { CommentMessagePage({Key? key}) : super(key: key); @@ -75,7 +73,7 @@ class _CommentMessagePageState extends State { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.headSculpture)), + image: SAASAPI.image(ImgModel.first(model.headSculpture)), fit: BoxFit.cover, ), ), @@ -99,7 +97,7 @@ class _CommentMessagePageState extends State { height: 160.w, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), fit: BoxFit.cover, ), ), diff --git a/lib/pages/message_center_page/message_center_page.dart b/lib/pages/message_center_page/message_center_page.dart index d8881514..0eea6cd6 100644 --- a/lib/pages/message_center_page/message_center_page.dart +++ b/lib/pages/message_center_page/message_center_page.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/pages/message_center_page/announce/announce_view.dart'; import 'package:aku_new_community/pages/message_center_page/reply/replay_view.dart'; import 'package:aku_new_community/pages/message_center_page/thumbs_up/thumbs_up_view.dart'; @@ -51,7 +51,7 @@ class _MessageCenterPageState extends State actions: [ MaterialButton( onPressed: () async { - var res = await NetUtil().get(SARSAPI.message.allRead, params: { + var res = await NetUtil().get(SAASAPI.message.allRead, params: { 'type': _tabController.index + 1, }); if (res.success) { diff --git a/lib/pages/message_center_page/message_func.dart b/lib/pages/message_center_page/message_func.dart index cd973897..2dea3078 100644 --- a/lib/pages/message_center_page/message_func.dart +++ b/lib/pages/message_center_page/message_func.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/message/system_message_detail_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; @@ -16,7 +16,7 @@ class MessageFunc { } static Future readMessage(int? id) async { - BaseModel baseModel = await NetUtil().get(SARSAPI.message.read, params: { + BaseModel baseModel = await NetUtil().get(SAASAPI.message.read, params: { 'messageId': id, }); if (baseModel.success) { diff --git a/lib/pages/message_center_page/reply/replay_view.dart b/lib/pages/message_center_page/reply/replay_view.dart index 216b451a..03fde28e 100644 --- a/lib/pages/message_center_page/reply/replay_view.dart +++ b/lib/pages/message_center_page/reply/replay_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/message/reply_list_model.dart'; import 'package:aku_new_community/pages/message_center_page/reply/reply_card.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; @@ -29,7 +29,7 @@ class _ReplayViewState extends State { @override Widget build(BuildContext context) { return BeeListView( - path: SARSAPI.message.allComment, + path: SAASAPI.message.allComment, controller: widget.controller, convert: (models) => models.rows.map((e) => ReplyListModel.fromJson(e)).toList(), diff --git a/lib/pages/message_center_page/thumbs_up/thumbs_up_view.dart b/lib/pages/message_center_page/thumbs_up/thumbs_up_view.dart index f0ee82f4..94ee48e5 100644 --- a/lib/pages/message_center_page/thumbs_up/thumbs_up_view.dart +++ b/lib/pages/message_center_page/thumbs_up/thumbs_up_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/message/reply_list_model.dart'; import 'package:aku_new_community/pages/message_center_page/thumbs_up/thumbs_up_card.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; @@ -24,7 +24,7 @@ class _ThumbsUpViewState extends State { @override Widget build(BuildContext context) { return BeeListView( - path: SARSAPI.message.allLikes, + path: SAASAPI.message.allLikes, controller: widget.controller, convert: (models) => models.rows.map((e) => ReplyListModel.fromJson(e)).toList(), diff --git a/lib/pages/personal/clock_in/clock_in_page.dart b/lib/pages/personal/clock_in/clock_in_page.dart index e79e76e0..9eb034ea 100644 --- a/lib/pages/personal/clock_in/clock_in_page.dart +++ b/lib/pages/personal/clock_in/clock_in_page.dart @@ -1,14 +1,5 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/num_ext.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; @@ -19,6 +10,12 @@ import 'package:aku_new_community/pages/personal/clock_in/clock_success_dialog.d import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_back_button.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class ClockInPage extends StatefulWidget { const ClockInPage({Key? key}) : super(key: key); @@ -37,7 +34,7 @@ class _ClockInPageState extends State { bool get hasClocked => _integralModel?.isSign ?? false; Future getData() async { - var base = await NetUtil().get(SARSAPI.profile.integral.info); + var base = await NetUtil().get(SAASAPI.profile.integral.info); if (base.success) { _integralModel = IntegralInfoModel.fromJson(base.data); if (_integralModel != null) { @@ -225,7 +222,7 @@ class _ClockInPageState extends State { ? null : () async { var base = - await NetUtil().get(SARSAPI.profile.integral.sign); + await NetUtil().get(SAASAPI.profile.integral.sign); if (base.success) { await Get.dialog(ClockSuccessDialog( todayIntegral: 1, tomorrowIntegral: 2)); diff --git a/lib/pages/personal/personal_page.dart b/lib/pages/personal/personal_page.dart index cd8611b6..5f493fe2 100644 --- a/lib/pages/personal/personal_page.dart +++ b/lib/pages/personal/personal_page.dart @@ -1,13 +1,4 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; -import 'package:provider/provider.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/pages/personal/clock_in/clock_in_page.dart'; import 'package:aku_new_community/pages/personal/user_profile_page.dart'; @@ -23,6 +14,13 @@ import 'package:aku_new_community/ui/profile/new_house/my_house_page.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; +import 'package:provider/provider.dart'; + import 'address/address_list_page.dart'; import 'clock_in/clock_success_dialog.dart'; import 'intergral/integral_center_page.dart'; @@ -341,7 +339,7 @@ class _PersonalIndexState extends State MaterialButton( onPressed: () async { var base = await NetUtil() - .get(SARSAPI.profile.integral.sign); + .get(SAASAPI.profile.integral.sign); if (base.success) { await Get.dialog(ClockSuccessDialog( todayIntegral: 1, tomorrowIntegral: 2)); diff --git a/lib/pages/personal/user_func.dart b/lib/pages/personal/user_func.dart index 2db03836..449d6a01 100644 --- a/lib/pages/personal/user_func.dart +++ b/lib/pages/personal/user_func.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/community/board_model.dart'; import 'package:aku_new_community/model/community/swiper_model.dart'; import 'package:aku_new_community/model/user/adress_model.dart'; @@ -12,7 +12,7 @@ class Userfunc { ///查询我的收货地址列表 static Future> getMyAddress() async { BaseModel model = await NetUtil().get( - SARSAPI.market.address.myAddress, + SAASAPI.market.address.myAddress, ); if (model.data!.length == 0) return []; return (model.data as List).map((e) => AddressModel.fromJson(e)).toList(); @@ -21,7 +21,7 @@ class Userfunc { ///添加收货地址 static Future insertAddress(String name, String tel, int? location, String addressDetail, int? isDefault) async { - BaseModel model = await NetUtil().post(SARSAPI.market.address.insert, + BaseModel model = await NetUtil().post(SAASAPI.market.address.insert, params: { 'name': name, 'tel': tel, @@ -42,7 +42,7 @@ class Userfunc { ///修改收货地址 static Future updateAddress(int id, String name, String tel, int? location, String addressDetail, int? isDefault) async { - BaseModel model = await NetUtil().post(SARSAPI.market.address.update, + BaseModel model = await NetUtil().post(SAASAPI.market.address.update, params: { 'id': id, 'name': name, @@ -63,7 +63,7 @@ class Userfunc { ///删除收货地址 static Future deleteAddress(int addressId) async { - BaseModel model = await NetUtil().post(SARSAPI.market.address.delete, + BaseModel model = await NetUtil().post(SAASAPI.market.address.delete, params: {'id': addressId}, showMessage: false); if (model.success) { BotToast.showText(text: '删除成功'); @@ -76,7 +76,7 @@ class Userfunc { ///设置默认收货地址 static Future setIsDefaultAddress(int addressId) async { - BaseModel model = await NetUtil().post(SARSAPI.market.address.setDefault, + BaseModel model = await NetUtil().post(SAASAPI.market.address.setDefault, params: {'id': addressId}, showMessage: false); if (model.success) { BotToast.showText(text: '设置成功'); diff --git a/lib/pages/personal/user_profile_page.dart b/lib/pages/personal/user_profile_page.dart index 51eaf351..8f276af0 100644 --- a/lib/pages/personal/user_profile_page.dart +++ b/lib/pages/personal/user_profile_page.dart @@ -1,7 +1,7 @@ import 'dart:io'; import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/pages/personal/change_nick_name_page.dart'; import 'package:aku_new_community/pages/personal/update_tel_page.dart'; import 'package:aku_new_community/provider/user_provider.dart'; @@ -69,7 +69,7 @@ class _UserProfilePageState extends State { //Upload Avatar Function cancel = BotToast.showLoading(); BaseModel model = - await NetUtil().upload(SARSAPI.uploadFile.uploadImg, file); + await NetUtil().upload(SAASAPI.uploadFile.uploadImg, file); if (model.success) userProvider.updateAvatar(model.data as String); else diff --git a/lib/pages/share_pay_page/share_record_page.dart b/lib/pages/share_pay_page/share_record_page.dart index b6fe37d4..a8a04930 100644 --- a/lib/pages/share_pay_page/share_record_page.dart +++ b/lib/pages/share_pay_page/share_record_page.dart @@ -5,7 +5,7 @@ import 'package:flutter_easyrefresh/easy_refresh.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/life_pay/share_pay_record_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/utils/headers.dart'; diff --git a/lib/pages/sign/login/select_community_page.dart b/lib/pages/sign/login/select_community_page.dart index 988281ed..501b4771 100644 --- a/lib/pages/sign/login/select_community_page.dart +++ b/lib/pages/sign/login/select_community_page.dart @@ -6,7 +6,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/login/community_model.dart'; import 'package:aku_new_community/models/login/history_login_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; @@ -96,7 +96,7 @@ class _SelectCommunityState extends State { onTap: () async { var cancel = BotToast.showLoading(); List _communities = []; - var base = await NetUtil().get(SARSAPI.login.allCommunity, params: { + var base = await NetUtil().get(SAASAPI.login.allCommunity, params: { 'cityId': UserTool .appProveider.pickedCityAndCommunity!.cityModel.district.id, }); diff --git a/lib/pages/sign/sign_func.dart b/lib/pages/sign/sign_func.dart index d80fb0b9..b0e46cca 100644 --- a/lib/pages/sign/sign_func.dart +++ b/lib/pages/sign/sign_func.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/user/pick_building_model.dart'; import 'package:aku_new_community/models/user/my_house_model.dart'; import 'package:aku_new_community/models/user/user_info_model.dart'; @@ -21,7 +21,7 @@ class SignFunc { static Future sendMessageCode( String phone, int communityId) async { BaseModel baseModel = await NetUtil().post( - SARSAPI.login.sendSMSCode, + SAASAPI.login.sendSMSCode, params: {'tel': phone, 'communityId': communityId}, showMessage: true, ); @@ -31,7 +31,7 @@ class SignFunc { static Future sendForgotMessageCode( String phone, int communityId) async { BaseModel baseModel = await NetUtil().post( - SARSAPI.user.sendForgotTelCode, + SAASAPI.user.sendForgotTelCode, params: {'tel': phone, 'communityId': communityId}, showMessage: true, ); @@ -65,7 +65,7 @@ class SignFunc { static Future loginBySms( String phone, String code, int communityId) async { Response response = await NetUtil().dio!.post( - SARSAPI.login.loginTelCode, + SAASAPI.login.loginTelCode, data: { 'tel': phone, 'code': code, @@ -124,14 +124,14 @@ class SignFunc { ///更新用户信息 static Future getUserInfo() async { - BaseModel baseModel = await NetUtil().get(SARSAPI.user.userProfile); + BaseModel baseModel = await NetUtil().get(SAASAPI.user.userProfile); if (baseModel.data == null || !baseModel.success) return null; return UserInfoModel.fromJson(baseModel.data); } ///设置密码(密码不存在时调用 static Future settingPsd(String psd) async { - BaseModel baseModel = await NetUtil().get(SARSAPI.user.settingPsd, + BaseModel baseModel = await NetUtil().get(SAASAPI.user.settingPsd, params: {'password': psd}, showMessage: true); if (baseModel.data == null || !baseModel.success) return false; return true; @@ -140,7 +140,7 @@ class SignFunc { ///提交修改的新密码(忘记密码) static Future settingForgotPsd( String psd, String tel, String telcode) async { - BaseModel baseModel = await NetUtil().get(SARSAPI.user.settingForgotPsd, + BaseModel baseModel = await NetUtil().get(SAASAPI.user.settingForgotPsd, params: { 'newPassword': psd, 'tel': tel, @@ -155,7 +155,7 @@ class SignFunc { static Future> getMyHouseInfo() async { BaseModel baseModel = await NetUtil().get( - SARSAPI.profile.house.userHouse, + SAASAPI.profile.house.userHouse, ); if ((baseModel.data as List).isEmpty) return []; return (baseModel.data as List) @@ -175,7 +175,7 @@ class SignFunc { ///检测昵称是否重复 static Future checkNickRepeat(String nick) async { - BaseModel baseModel = await NetUtil().get(SARSAPI.user.checkNickRepeat, + BaseModel baseModel = await NetUtil().get(SAASAPI.user.checkNickRepeat, params: { 'nickName': nick, }, @@ -185,7 +185,7 @@ class SignFunc { ///设置昵称 static Future setNickName(String nick) async { - BaseModel baseModel = await NetUtil().get(SARSAPI.user.setNickName, + BaseModel baseModel = await NetUtil().get(SAASAPI.user.setNickName, params: { 'nickName': nick, }, diff --git a/lib/pages/surrounding_enterprises/surrounding_enterprises_detail_page.dart b/lib/pages/surrounding_enterprises/surrounding_enterprises_detail_page.dart index e193382a..d9eded83 100644 --- a/lib/pages/surrounding_enterprises/surrounding_enterprises_detail_page.dart +++ b/lib/pages/surrounding_enterprises/surrounding_enterprises_detail_page.dart @@ -1,14 +1,11 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_screenutil/flutter_screenutil.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/surrounding_enterprises/surrounding_enterprises_model.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; class SurroundingEnterprisesDetailPage extends StatefulWidget { final SurroundingEnterprisesModel surroundingEnterprisesModel; @@ -35,7 +32,7 @@ class _SurroundingEnterprisesDetailPageState child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, fit: BoxFit.cover, - image: SARSAPI.image(ImgModel.first( + image: SAASAPI.image(ImgModel.first( widget.surroundingEnterprisesModel.imgList))), width: double.infinity, height: 424.w, diff --git a/lib/pages/surrounding_enterprises/surrounding_enterprises_page.dart b/lib/pages/surrounding_enterprises/surrounding_enterprises_page.dart index d9f30a6b..2cca7951 100644 --- a/lib/pages/surrounding_enterprises/surrounding_enterprises_page.dart +++ b/lib/pages/surrounding_enterprises/surrounding_enterprises_page.dart @@ -1,18 +1,16 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/surrounding_enterprises/surrounding_enterprises_model.dart'; import 'package:aku_new_community/pages/surrounding_enterprises/surrounding_enterprises_detail_page.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; class SurroundingEnterprisesPage extends StatefulWidget { SurroundingEnterprisesPage({Key? key}) : super(key: key); @@ -59,7 +57,7 @@ class _SurroundingEnterprisesPageState borderRadius: BorderRadius.circular(4.w), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgList)), + image: SAASAPI.image(ImgModel.first(model.imgList)), height: 200.w, width: 240.w, fit: BoxFit.fill, diff --git a/lib/pages/things_page/fixed_submit_page.dart b/lib/pages/things_page/fixed_submit_page.dart index 931b0817..b301a4b4 100644 --- a/lib/pages/things_page/fixed_submit_page.dart +++ b/lib/pages/things_page/fixed_submit_page.dart @@ -1,15 +1,6 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/extensions/num_ext.dart'; import 'package:aku_new_community/model/user/fixed_submit_model.dart'; import 'package:aku_new_community/pages/manager_func.dart'; @@ -21,6 +12,12 @@ import 'package:aku_new_community/utils/bee_map.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/bottom_button.dart'; import 'package:aku_new_community/widget/views/horizontal_image_view.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class FixedSubmitPage extends StatefulWidget { FixedSubmitPage({Key? key}) : super(key: key); diff --git a/lib/pages/things_page/widget/add_fixed_submit_page.dart b/lib/pages/things_page/widget/add_fixed_submit_page.dart index 717bfa62..39acd874 100644 --- a/lib/pages/things_page/widget/add_fixed_submit_page.dart +++ b/lib/pages/things_page/widget/add_fixed_submit_page.dart @@ -1,15 +1,8 @@ import 'dart:io'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:get/get.dart'; -import 'package:provider/provider.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/pages/manager_func.dart'; import 'package:aku_new_community/pages/things_page/widget/finish_fixed_submit_page.dart'; import 'package:aku_new_community/provider/app_provider.dart'; @@ -21,6 +14,10 @@ import 'package:aku_new_community/widget/buttons/bee_check_button.dart'; import 'package:aku_new_community/widget/buttons/bottom_button.dart'; import 'package:aku_new_community/widget/others/house_head_card.dart'; import 'package:aku_new_community/widget/picker/grid_image_picker.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; +import 'package:provider/provider.dart'; class AddFixedSubmitPage extends StatefulWidget { AddFixedSubmitPage({Key? key}) : super(key: key); diff --git a/lib/pages/things_page/widget/fixed_detail_page.dart b/lib/pages/things_page/widget/fixed_detail_page.dart index a6db41cd..7c24b4b4 100644 --- a/lib/pages/things_page/widget/fixed_detail_page.dart +++ b/lib/pages/things_page/widget/fixed_detail_page.dart @@ -1,14 +1,5 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; -import 'package:url_launcher/url_launcher.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/manage/fix_report/fix_detail_model.dart'; import 'package:aku_new_community/pages/life_pay/pay_finish_page.dart'; import 'package:aku_new_community/pages/life_pay/pay_util.dart'; @@ -20,6 +11,12 @@ import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/views/horizontal_image_view.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; +import 'package:url_launcher/url_launcher.dart'; class FixedDetailPage extends StatefulWidget { final int id; diff --git a/lib/pages/visitor_access_page/visitor_access_page.dart b/lib/pages/visitor_access_page/visitor_access_page.dart index 28a17eda..6f796b50 100644 --- a/lib/pages/visitor_access_page/visitor_access_page.dart +++ b/lib/pages/visitor_access_page/visitor_access_page.dart @@ -1,15 +1,4 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_icons/flutter_icons.dart'; -import 'package:get/get.dart'; -import 'package:provider/provider.dart'; -import 'package:share/share.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/pages/manager_func.dart'; import 'package:aku_new_community/provider/app_provider.dart'; import 'package:aku_new_community/provider/user_provider.dart'; @@ -20,6 +9,14 @@ import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/common_input.dart'; import 'package:aku_new_community/widget/picker/bee_date_picker.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_icons/flutter_icons.dart'; +import 'package:get/get.dart'; +import 'package:provider/provider.dart'; +import 'package:share/share.dart'; +import 'package:velocity_x/velocity_x.dart'; class VisitorAccessPage extends StatefulWidget { VisitorAccessPage({Key? key}) : super(key: key); diff --git a/lib/provider/app_provider.dart b/lib/provider/app_provider.dart index 5eafad28..b454104a 100644 --- a/lib/provider/app_provider.dart +++ b/lib/provider/app_provider.dart @@ -4,7 +4,7 @@ import 'dart:io'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/application_objects.dart'; import 'package:aku_new_community/constants/config.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/real_time_weather_model.dart'; import 'package:aku_new_community/model/message/message_center_model.dart'; import 'package:aku_new_community/model/user/adress_model.dart'; @@ -310,7 +310,7 @@ class AppProvider extends ChangeNotifier { ///保存默认收货地址 Future getMyAddress() async { - BaseModel model = await NetUtil().get(SARSAPI.market.address.myAddress); + BaseModel model = await NetUtil().get(SAASAPI.market.address.myAddress); if (model.data?.length == 0) return []; else { diff --git a/lib/provider/data_provider.dart b/lib/provider/data_provider.dart index aa97ca98..7a973901 100644 --- a/lib/provider/data_provider.dart +++ b/lib/provider/data_provider.dart @@ -1,12 +1,10 @@ -import 'package:flutter/material.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/login/china_region_model.dart'; import 'package:aku_new_community/models/login/history_login_model.dart'; import 'package:aku_new_community/utils/hive_store.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; +import 'package:flutter/material.dart'; class DataProvider extends ChangeNotifier { Future init() async { @@ -28,7 +26,7 @@ class DataProvider extends ChangeNotifier { List get cityModel => _cityModel; Future updateCityList() async { - var model = await NetUtil().get(SARSAPI.city.allCity); + var model = await NetUtil().get(SAASAPI.city.allCity); if (model.success) { _cityModel = (model.data as List) .map((e) => ChinaRegionModel.fromJson(e)) diff --git a/lib/provider/user_provider.dart b/lib/provider/user_provider.dart index 9d5e5efc..944514d2 100644 --- a/lib/provider/user_provider.dart +++ b/lib/provider/user_provider.dart @@ -1,7 +1,7 @@ import 'dart:io'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/user/my_house_model.dart'; import 'package:aku_new_community/models/user/user_config_model.dart'; import 'package:aku_new_community/models/user/user_info_model.dart'; @@ -161,7 +161,7 @@ class UserProvider extends ChangeNotifier { ///修改头像 Future updateAvatar(String? path) async { BaseModel model = await NetUtil().post( - SARSAPI.user.updateAvatar, + SAASAPI.user.updateAvatar, params: { 'fileUrls': [path] }, diff --git a/lib/ui/community/activity/activity_detail_page.dart b/lib/ui/community/activity/activity_detail_page.dart index 0146d1d5..b4649f83 100644 --- a/lib/ui/community/activity/activity_detail_page.dart +++ b/lib/ui/community/activity/activity_detail_page.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/home/activity_detail_model.dart'; import 'package:aku_new_community/utils/headers.dart'; @@ -77,7 +77,7 @@ class _ActivityDetailPageState extends State { firstRefresh: true, onRefresh: () async { BaseModel baseModel = await NetUtil().get( - SARSAPI.activity.detail, + SAASAPI.activity.detail, params: {'activityId': widget.id}, ); _model = ActivityDetailModel.fromJson(baseModel.data); @@ -151,7 +151,7 @@ class _ActivityDetailPageState extends State { bottomNavi: BottomButton( child: '立即报名'.text.size(32.sp).color(Colors.black).bold.make(), onPressed: () async { - await NetUtil().post(SARSAPI.activity.registration, + await NetUtil().post(SAASAPI.activity.registration, params: {'activityId': _model!.id}, showMessage: true); }, ), diff --git a/lib/ui/community/activity/activity_detail_page_old.dart b/lib/ui/community/activity/activity_detail_page_old.dart index a58db53d..3081d65e 100644 --- a/lib/ui/community/activity/activity_detail_page_old.dart +++ b/lib/ui/community/activity/activity_detail_page_old.dart @@ -1,16 +1,7 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; -import 'package:shimmer/shimmer.dart'; - import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/community/activity_detail_model.dart'; import 'package:aku_new_community/ui/community/activity/activity_people_list_page.dart'; @@ -20,6 +11,13 @@ import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/bottom_button.dart'; import 'package:aku_new_community/widget/others/stack_avatar.dart'; import 'package:aku_new_community/widget/picker/bee_image_preview.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; +import 'package:shimmer/shimmer.dart'; @Deprecated('旧页面 酌情删除') class ActivityDetailPage extends StatefulWidget { @@ -135,7 +133,7 @@ class _ActivityDetailPageState extends State { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(e.url), + image: SAASAPI.image(e.url), fit: BoxFit.cover, ), ), diff --git a/lib/ui/community/activity/activity_list_page.dart b/lib/ui/community/activity/activity_list_page.dart index ea2da37b..715230d3 100644 --- a/lib/ui/community/activity/activity_list_page.dart +++ b/lib/ui/community/activity/activity_list_page.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/home/home_activity_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/community/activity/activity_card.dart'; @@ -36,7 +36,7 @@ class _ActivityListPageState extends State { ], body: BeeListView( controller: _refreshController, - path: SARSAPI.activity.list, + path: SAASAPI.activity.list, convert: (model) => model.rows.map((e) => HomeActivityModel.fromJson(e)).toList(), builder: (items) { diff --git a/lib/ui/community/activity/activity_people_list_page.dart b/lib/ui/community/activity/activity_people_list_page.dart index 0588dce6..572f974b 100644 --- a/lib/ui/community/activity/activity_people_list_page.dart +++ b/lib/ui/community/activity/activity_people_list_page.dart @@ -1,15 +1,13 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; - import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/community/activity_people_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; class ActivityPeopleListPage extends StatefulWidget { final int? id; @@ -50,7 +48,7 @@ class _ActivityPeopleListPageState extends State { 20.wb, FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrl)), + image: SAASAPI.image(ImgModel.first(model.imgUrl)), height: 60.w, width: 60.w, ), diff --git a/lib/ui/community/community_func.dart b/lib/ui/community/community_func.dart index 2424d34c..f92aa653 100644 --- a/lib/ui/community/community_func.dart +++ b/lib/ui/community/community_func.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/good/market_swiper_model.dart'; import 'package:aku_new_community/models/community/dynamic_my_list_body.dart'; import 'package:aku_new_community/models/community/information_list_model.dart'; @@ -20,7 +20,7 @@ class CommunityFunc { ///查询热门话题 static Future> getListGambit() async { var model = await NetUtil().get( - SARSAPI.community.topNewList, + SAASAPI.community.topNewList, params: {'hotShowNum': 3, 'showNum': 3}, ); if ((model.data as List).length == 0) return []; @@ -30,7 +30,7 @@ class CommunityFunc { ///我的动态 static Future> getMyEventItem() async { BaseListModel model = await NetUtil().getList( - SARSAPI.community.dynamicMyListL, + SAASAPI.community.dynamicMyListL, params: {'pageNum': 1, 'size': 8}, ); if (model.rows.length == 0) return []; @@ -40,7 +40,7 @@ class CommunityFunc { ///查询热门资讯 static Future> getHotNews() async { BaseListModel model = await NetUtil().getList( - SARSAPI.information.list, + SAASAPI.information.list, params: {'pageNum': 1, 'size': 4}, ); if (model.rows.length == 0) return []; @@ -62,7 +62,7 @@ class CommunityFunc { ///查询顶部统计信息 static Future getMarketStatistics() async { BaseModel model = await NetUtil().get( - SARSAPI.market.home.topInfo, + SAASAPI.market.home.topInfo, ); if (model.success) { return MarketStatisticsModel.fromJson(model.data); @@ -76,7 +76,7 @@ class CommunityFunc { static Future> getGoodsClassificationList( int parentId) async { BaseListModel model = await NetUtil().getList( - SARSAPI.market.category.category, + SAASAPI.market.category.category, params: {'pageNum': 1, 'size': 9, 'parentId': parentId}, ); if (model.rows.length == 0) return []; @@ -86,7 +86,7 @@ class CommunityFunc { ///查询爆款推荐 static Future> getGoodsPopularModel(int num) async { BaseModel model = await NetUtil().get( - SARSAPI.market.good.popular, + SAASAPI.market.good.popular, params: {'num': num}, ); if (model.data!.length == 0) return []; @@ -98,7 +98,7 @@ class CommunityFunc { ///获取所有商品的分类 static Future> getCategory() async { BaseModel model = await NetUtil().get( - SARSAPI.market.category.categoryInfo, + SAASAPI.market.category.categoryInfo, ); if (model.data!.length == 0) return []; @@ -112,7 +112,7 @@ class CommunityFunc { ///获取商城的轮播图 static Future> marketSwiper() async { BaseModel model = await NetUtil().get( - SARSAPI.market.rotation.rotation, + SAASAPI.market.rotation.rotation, ); if (model.data!.length == 0) return []; return (model.data as List) @@ -122,7 +122,7 @@ class CommunityFunc { static Future> activityList() async { BaseListModel model = await NetUtil().getList( - SARSAPI.activity.list, + SAASAPI.activity.list, params: {'pageNum': 1, 'size': 5}, ); if (model.rows.length == 0) return []; @@ -131,7 +131,7 @@ class CommunityFunc { static Future> board() async { BaseListModel model = await NetUtil().getList( - SARSAPI.announce.list, + SAASAPI.announce.list, params: {'pageNum': 1, 'size': 5}, ); if (model.rows.length == 0) return []; @@ -140,7 +140,7 @@ class CommunityFunc { static Future> swiper() async { BaseModel model = await NetUtil().get( - SARSAPI.homeCarouse.list, + SAASAPI.homeCarouse.list, ); if (model.data!.length == 0) return []; return (model.data as List) diff --git a/lib/ui/community/community_views/add_new_event_page.dart b/lib/ui/community/community_views/add_new_event_page.dart index 7d3cd2ab..1cf61347 100644 --- a/lib/ui/community/community_views/add_new_event_page.dart +++ b/lib/ui/community/community_views/add_new_event_page.dart @@ -1,7 +1,7 @@ import 'dart:io'; import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/community/all_dynamic_list_model.dart'; import 'package:aku_new_community/models/community/topic_list_model.dart'; import 'package:aku_new_community/ui/community/community_views/topic/topic_search_page.dart'; @@ -53,7 +53,7 @@ class _AddNewEventPageState extends State { List? imgs; print(_files.length); if (_files.isNotEmpty) { - imgs = await NetUtil().uploadFiles(_files, SARSAPI.uploadFile.uploadImg); + imgs = await NetUtil().uploadFiles(_files, SAASAPI.uploadFile.uploadImg); } Map params = { @@ -70,7 +70,7 @@ class _AddNewEventPageState extends State { } BaseModel baseModel = await NetUtil().post( - SARSAPI.community.dynamicInsert, + SAASAPI.community.dynamicInsert, params: params, showMessage: true, ); diff --git a/lib/ui/community/community_views/community_page.dart b/lib/ui/community/community_views/community_page.dart index e24b9824..d31946c9 100644 --- a/lib/ui/community/community_views/community_page.dart +++ b/lib/ui/community/community_views/community_page.dart @@ -2,7 +2,7 @@ import 'dart:math'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/community/all_dynamic_list_model.dart'; import 'package:aku_new_community/models/community/information_category_list_model.dart'; @@ -177,7 +177,7 @@ class _CommunityPageState extends State Future getNewInfo() async { BaseListModel baseListModel = await NetUtil().getList( - SARSAPI.community.dynamicList, + SAASAPI.community.dynamicList, params: {"pageNum": _pageNum, "size": _size, 'type': 1}); if (baseListModel.rows.isNotEmpty) { _newItems = (baseListModel.rows) @@ -210,7 +210,7 @@ class _CommunityPageState extends State _homeTitle('热门资讯', () async { final cancel = BotToast.showLoading(); BaseModel model = - await NetUtil().get(SARSAPI.information.categoryList); + await NetUtil().get(SAASAPI.information.categoryList); var category = []; if (model.success == true && model.data != null) { category = (model.data as List) @@ -306,7 +306,7 @@ class _CommunityPageState extends State ), image: DecorationImage( image: NetworkImage( - SARSAPI.image(ImgModel.first(item.imgList)), + SAASAPI.image(ImgModel.first(item.imgList)), ), fit: BoxFit.cover, ), diff --git a/lib/ui/community/community_views/event_detail_page.dart b/lib/ui/community/community_views/event_detail_page.dart index 7f61146f..632e6d4c 100644 --- a/lib/ui/community/community_views/event_detail_page.dart +++ b/lib/ui/community/community_views/event_detail_page.dart @@ -1,7 +1,7 @@ import 'dart:math'; import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/community/comment_list_model.dart'; import 'package:aku_new_community/models/community/dynamic_detail_model.dart'; @@ -73,7 +73,7 @@ class _EventDetailPageState extends State { }; Future updateComments() async { - var base = await NetUtil().get(SARSAPI.community.singleComment, params: { + var base = await NetUtil().get(SAASAPI.community.singleComment, params: { 'commentId': _comments[_currentCommentIndex].id, }); if (base.success) { @@ -144,13 +144,13 @@ class _EventDetailPageState extends State { firstRefresh: true, onRefresh: () async { BaseModel model = await NetUtil().get( - SARSAPI.community.dynamicDetail, + SAASAPI.community.dynamicDetail, params: {'dynamicId': widget.dynamicId}, ); _model = DynamicDetailModel.fromJson(model.data); _page = 1; var base = - await NetUtil().getList(SARSAPI.community.commentList, params: { + await NetUtil().getList(SAASAPI.community.commentList, params: { 'pageNum': _page, 'size': _size, 'dynamicId': widget.dynamicId, @@ -171,7 +171,7 @@ class _EventDetailPageState extends State { onLoad: () async { _page++; var base = - await NetUtil().getList(SARSAPI.community.commentList, params: { + await NetUtil().getList(SAASAPI.community.commentList, params: { 'pageNum': _page, 'size': _size, 'dynamicId': widget.dynamicId, @@ -305,7 +305,7 @@ class _EventDetailPageState extends State { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.avatarImgList)), + image: SAASAPI.image(ImgModel.first(model.avatarImgList)), height: 96.w, width: 96.w, fit: BoxFit.cover, @@ -349,7 +349,7 @@ class _EventDetailPageState extends State { GestureDetector( onTap: () async { var res = - await NetUtil().get(SARSAPI.community.commentLike, params: { + await NetUtil().get(SAASAPI.community.commentLike, params: { 'commentId': model.id, }); if (res.success) { @@ -569,7 +569,7 @@ class _EventDetailPageState extends State { height: 55.w, onPressed: () async { var res = await NetUtil() - .post(SARSAPI.community.commentInsert, params: params); + .post(SAASAPI.community.commentInsert, params: params); if (res.success) { _textEditingController.clear(); if (_rootId == 0) { diff --git a/lib/ui/community/community_views/my_community_view.dart b/lib/ui/community/community_views/my_community_view.dart index f547ad4c..fc85cc52 100644 --- a/lib/ui/community/community_views/my_community_view.dart +++ b/lib/ui/community/community_views/my_community_view.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/community/my_event_item_model.dart'; import 'package:aku_new_community/models/community/dynamic_my_list_body.dart'; @@ -133,7 +133,7 @@ class MyCommunityViewState extends State controller: _refreshController, onRefresh: () async { _myEventItems = await CommunityFunc.getMyEventItem(); - var base = await NetUtil().get(SARSAPI.community.dynamicMyListH); + var base = await NetUtil().get(SAASAPI.community.dynamicMyListH); if (base.success) { _head = DynamicMyListHead.fromJson(base.data); } @@ -336,7 +336,7 @@ class MyCommunityViewState extends State tag: ImgModel.first(item.dynamicImgList), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(item.dynamicImgList)), + image: SAASAPI.image(ImgModel.first(item.dynamicImgList)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, diff --git a/lib/ui/community/community_views/new_community_view.dart b/lib/ui/community/community_views/new_community_view.dart index f542c5f7..6a7dbf08 100644 --- a/lib/ui/community/community_views/new_community_view.dart +++ b/lib/ui/community/community_views/new_community_view.dart @@ -1,12 +1,9 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/community/all_dynamic_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/community/community_views/widgets/chat_card.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; class NewCommunityView extends StatefulWidget { NewCommunityView({Key? key}) : super(key: key); @@ -33,7 +30,7 @@ class NewCommunityViewState extends State Widget build(BuildContext context) { super.build(context); return BeeListView( - path: SARSAPI.community.dynamicList, + path: SAASAPI.community.dynamicList, controller: _refreshController, convert: (model) { return model.rows.map((e) => AllDynamicListModel.fromJson(e)).toList(); diff --git a/lib/ui/community/community_views/topic/topic_community_view.dart b/lib/ui/community/community_views/topic/topic_community_view.dart index 236b3123..317695bf 100644 --- a/lib/ui/community/community_views/topic/topic_community_view.dart +++ b/lib/ui/community/community_views/topic/topic_community_view.dart @@ -1,7 +1,7 @@ import 'dart:ui'; import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/community/topic_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/community/community_views/topic/topic_detail_page.dart'; @@ -147,7 +147,7 @@ class TopicCommunityViewState extends State { return BeeScaffold( title: '所有话题'.text.color(ktextPrimary).size(32.sp).normal.make(), body: BeeListView( - path: SARSAPI.community.topicList, + path: SAASAPI.community.topicList, controller: _refreshController, convert: (model) { return model.rows.map((e) => TopicListModel.fromJson(e)).toList(); diff --git a/lib/ui/community/community_views/topic/topic_detail_page.dart b/lib/ui/community/community_views/topic/topic_detail_page.dart index c1017e05..7e1f8e07 100644 --- a/lib/ui/community/community_views/topic/topic_detail_page.dart +++ b/lib/ui/community/community_views/topic/topic_detail_page.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/community/all_dynamic_list_model.dart'; @@ -65,13 +65,13 @@ class _TopicDetailPageState extends State { footer: MaterialFooter(), onRefresh: () async { _page = 1; - var res = await NetUtil().get(SARSAPI.community.topicDetail, + var res = await NetUtil().get(SAASAPI.community.topicDetail, params: {'topicId': widget.topicId}); if (res.success) { _detailModel = TopDetailModel.fromJson(res.data); } var baseList = await NetUtil() - .getList(SARSAPI.community.dynamicList, params: { + .getList(SAASAPI.community.dynamicList, params: { 'pageNum': _page, 'size': 4, 'topicId': widget.topicId, @@ -86,7 +86,7 @@ class _TopicDetailPageState extends State { onLoad: () async { _page++; BaseListModel baseList = await NetUtil() - .getList(SARSAPI.community.dynamicList, params: { + .getList(SAASAPI.community.dynamicList, params: { 'pageNum': _page, 'size': 4, 'topicId': widget.topicId, diff --git a/lib/ui/community/community_views/topic/topic_search_page.dart b/lib/ui/community/community_views/topic/topic_search_page.dart index 87f48366..80625109 100644 --- a/lib/ui/community/community_views/topic/topic_search_page.dart +++ b/lib/ui/community/community_views/topic/topic_search_page.dart @@ -1,18 +1,15 @@ +import 'package:aku_new_community/constants/saas_api.dart'; +import 'package:aku_new_community/extensions/widget_list_ext.dart'; +import 'package:aku_new_community/models/community/topic_list_model.dart'; +import 'package:aku_new_community/utils/network/net_util.dart'; +import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; - import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:get/get.dart'; import 'package:velocity_x/src/extensions/num_ext.dart'; import 'package:velocity_x/src/extensions/string_ext.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; -import 'package:aku_new_community/extensions/widget_list_ext.dart'; -import 'package:aku_new_community/models/community/topic_list_model.dart'; -import 'package:aku_new_community/utils/network/net_util.dart'; -import 'package:aku_new_community/widget/bee_divider.dart'; - class TopicSearchPage extends StatefulWidget { const TopicSearchPage({ Key? key, @@ -27,7 +24,7 @@ class _TopicSearchPageState extends State { bool isHot = true; Future _getModels() async { - var re = await NetUtil().get(SARSAPI.community.topicList, params: { + var re = await NetUtil().get(SAASAPI.community.topicList, params: { 'pageNum': 1, 'size': 10, }); @@ -80,7 +77,7 @@ class _TopicSearchPageState extends State { return; } var re = await NetUtil() - .get(SARSAPI.community.topicList, params: { + .get(SAASAPI.community.topicList, params: { 'pageNum': 1, 'size': 20, }); diff --git a/lib/ui/community/community_views/topic/topic_sliver_header.dart b/lib/ui/community/community_views/topic/topic_sliver_header.dart index c4fbd397..479881d6 100644 --- a/lib/ui/community/community_views/topic/topic_sliver_header.dart +++ b/lib/ui/community/community_views/topic/topic_sliver_header.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/bee_back_button.dart'; import 'package:flutter/material.dart'; @@ -95,7 +95,7 @@ class TopicSliverHeader extends SliverPersistentHeaderDelegate { tag: "$imgPath\_$id", child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(imgPath), + image: SAASAPI.image(imgPath), fit: BoxFit.cover, ), ), diff --git a/lib/ui/community/community_views/widgets/chat_card.dart b/lib/ui/community/community_views/widgets/chat_card.dart index 216327f8..a98f368b 100644 --- a/lib/ui/community/community_views/widgets/chat_card.dart +++ b/lib/ui/community/community_views/widgets/chat_card.dart @@ -2,7 +2,7 @@ import 'dart:math'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/community/all_dynamic_list_model.dart'; import 'package:aku_new_community/provider/user_provider.dart'; @@ -73,7 +73,7 @@ class _ChatCardState extends State { ), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(widget.model.dynamicList)), + image: SAASAPI.image(ImgModel.first(widget.model.dynamicList)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, @@ -102,7 +102,7 @@ class _ChatCardState extends State { Spacer(), GestureDetector( onTap: () async { - var res = await NetUtil().get(SARSAPI.community.dynamicLike, + var res = await NetUtil().get(SAASAPI.community.dynamicLike, params: {'dynamicId': widget.model.id}); if (res.success) { _isLiked = !_isLiked; @@ -192,7 +192,7 @@ class _ChatCardState extends State { child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, image: - SARSAPI.image(ImgModel.first(widget.model.avatarImgList)), + SAASAPI.image(ImgModel.first(widget.model.avatarImgList)), height: 96.w, width: 96.w, fit: BoxFit.cover, diff --git a/lib/ui/community/community_views/widgets/chat_card_detail.dart b/lib/ui/community/community_views/widgets/chat_card_detail.dart index 83190e1d..7d5244a2 100644 --- a/lib/ui/community/community_views/widgets/chat_card_detail.dart +++ b/lib/ui/community/community_views/widgets/chat_card_detail.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/community/dynamic_detail_model.dart'; import 'package:aku_new_community/provider/user_provider.dart'; @@ -67,7 +67,7 @@ class _ChatCardDetailState extends State { tag: ImgModel.first(widget.model.dynamicImgList), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(widget.model.dynamicImgList)), + image: SAASAPI.image(ImgModel.first(widget.model.dynamicImgList)), imageErrorBuilder: (context, error, stackTrace) { return Image.asset( R.ASSETS_IMAGES_PLACEHOLDER_WEBP, @@ -100,7 +100,7 @@ class _ChatCardDetailState extends State { child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, image: - SARSAPI.image(ImgModel.first(widget.model.avatarImgList)), + SAASAPI.image(ImgModel.first(widget.model.avatarImgList)), height: 96.w, width: 96.w, fit: BoxFit.cover, diff --git a/lib/ui/community/community_views/widgets/my_event_card.dart b/lib/ui/community/community_views/widgets/my_event_card.dart index 47d23f6c..2b272ba9 100644 --- a/lib/ui/community/community_views/widgets/my_event_card.dart +++ b/lib/ui/community/community_views/widgets/my_event_card.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/community/my_event_item_model.dart'; import 'package:aku_new_community/models/community/dynamic_detail_model.dart'; @@ -67,7 +67,7 @@ class MyEventCard extends StatelessWidget { MaterialButton( onPressed: () async { BaseModel models = await NetUtil().get( - SARSAPI.community.dynamicDetail, + SAASAPI.community.dynamicDetail, params: {'dynamicId': model.id}, ); DynamicDetailModel eventItemModel = @@ -102,7 +102,7 @@ class MyEventCard extends StatelessWidget { ), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrl)), + image: SAASAPI.image(ImgModel.first(model.imgUrl)), width: 152.w, height: 152.w, fit: BoxFit.cover, diff --git a/lib/ui/community/community_views/widgets/send_a_chat.dart b/lib/ui/community/community_views/widgets/send_a_chat.dart index 439eda00..546b2220 100644 --- a/lib/ui/community/community_views/widgets/send_a_chat.dart +++ b/lib/ui/community/community_views/widgets/send_a_chat.dart @@ -1,13 +1,10 @@ +import 'package:aku_new_community/constants/saas_api.dart'; +import 'package:aku_new_community/utils/headers.dart'; +import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:flutter/material.dart'; - import 'package:get/get.dart'; import 'package:velocity_x/velocity_x.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; -import 'package:aku_new_community/utils/headers.dart'; -import 'package:aku_new_community/utils/network/net_util.dart'; - class SendAChat extends StatefulWidget { final FocusNode? node; @@ -26,7 +23,7 @@ class SendAChat extends StatefulWidget { ); if (result != null) { await NetUtil().post( - SARSAPI.community.commentInsert, + SAASAPI.community.commentInsert, params: { 'rootId': rootId, 'parentId': parentId, diff --git a/lib/ui/community/facility/facility_appointment_card.dart b/lib/ui/community/facility/facility_appointment_card.dart index d083b811..174a2f26 100644 --- a/lib/ui/community/facility/facility_appointment_card.dart +++ b/lib/ui/community/facility/facility_appointment_card.dart @@ -1,17 +1,14 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/facility/facility_appointment_model.dart'; import 'package:aku_new_community/ui/common/qr_scan.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; class FacilityAppointmentCard extends StatelessWidget { final FacilityAppointmentModel model; diff --git a/lib/ui/community/facility/facility_appointment_view.dart b/lib/ui/community/facility/facility_appointment_view.dart index 54e30135..ad45786f 100644 --- a/lib/ui/community/facility/facility_appointment_view.dart +++ b/lib/ui/community/facility/facility_appointment_view.dart @@ -1,13 +1,10 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/facility/facility_appointment_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/community/facility/facility_appointment_card.dart'; import 'package:aku_new_community/utils/headers.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; enum FacilityAppointmentType { MY, diff --git a/lib/ui/community/facility/facility_type_card.dart b/lib/ui/community/facility/facility_type_card.dart index 991e7490..16f78476 100644 --- a/lib/ui/community/facility/facility_type_card.dart +++ b/lib/ui/community/facility/facility_type_card.dart @@ -1,14 +1,11 @@ -import 'package:flutter/material.dart'; - -import 'package:get/get.dart'; - import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/models/facility/facility_type_model.dart'; import 'package:aku_new_community/ui/community/facility/facility_preorder_page.dart'; import 'package:aku_new_community/utils/headers.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; class FacilityTypeCard extends StatelessWidget { final FacilityTypeModel model; @@ -29,7 +26,7 @@ class FacilityTypeCard extends StatelessWidget { children: [ FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), height: 320.w, width: double.infinity, fit: BoxFit.cover, diff --git a/lib/ui/community/facility/facility_type_detail_page.dart b/lib/ui/community/facility/facility_type_detail_page.dart index 5398f209..647fb5df 100644 --- a/lib/ui/community/facility/facility_type_detail_page.dart +++ b/lib/ui/community/facility/facility_type_detail_page.dart @@ -1,15 +1,12 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/facility/facility_type_detail_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; class FacilityTypeDetailPage extends StatefulWidget { final int id; diff --git a/lib/ui/community/facility/fcility_order_date_list_page.dart b/lib/ui/community/facility/fcility_order_date_list_page.dart index 88bd3f1c..926acabe 100644 --- a/lib/ui/community/facility/fcility_order_date_list_page.dart +++ b/lib/ui/community/facility/fcility_order_date_list_page.dart @@ -6,7 +6,7 @@ import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/facility/facility_order_date_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; diff --git a/lib/ui/community/facility/pick_facility_page.dart b/lib/ui/community/facility/pick_facility_page.dart index c3779ae3..f4c69dd7 100644 --- a/lib/ui/community/facility/pick_facility_page.dart +++ b/lib/ui/community/facility/pick_facility_page.dart @@ -1,14 +1,11 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/facility/facility_type_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/community/facility/facility_type_card.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; class PickFacilityPage extends StatefulWidget { PickFacilityPage({Key? key}) : super(key: key); diff --git a/lib/ui/community/notice/notice_detail_page.dart b/lib/ui/community/notice/notice_detail_page.dart index 04335ce8..a9f73558 100644 --- a/lib/ui/community/notice/notice_detail_page.dart +++ b/lib/ui/community/notice/notice_detail_page.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/home/announce_detail_model.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; @@ -39,7 +39,7 @@ class _NoticeDetailPageState extends State { header: MaterialHeader(), onRefresh: () async { BaseModel baseModel = await NetUtil().get( - SARSAPI.announce.detail, + SAASAPI.announce.detail, params: {'announcementId': widget.id}, ); if (baseModel.data != null) { @@ -90,7 +90,7 @@ class _NoticeDetailPageState extends State { title: e.url ?? '', onPressed: () async { String? result = await Get.dialog(BeeDownloadView( - file: SARSAPI.image(e.url), + file: SAASAPI.image(e.url), )); if (result != null) OpenFile.open(result); }, diff --git a/lib/ui/community/notice/notice_page.dart b/lib/ui/community/notice/notice_page.dart index 0f0377bc..74017991 100644 --- a/lib/ui/community/notice/notice_page.dart +++ b/lib/ui/community/notice/notice_page.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/home/home_announce_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/community/notice/notice_card.dart'; @@ -24,7 +24,7 @@ class _NoticePageState extends State { title: '社区公告', body: BeeListView( controller: _refreshController, - path: SARSAPI.announce.list, + path: SAASAPI.announce.list, convert: (model) => model.rows.map((e) => HomeAnnounceModel.fromJson(e)).toList(), builder: (items) { diff --git a/lib/ui/function_and_service/task/hall/hall_view.dart b/lib/ui/function_and_service/task/hall/hall_view.dart index 1934be13..ac70d562 100644 --- a/lib/ui/function_and_service/task/hall/hall_view.dart +++ b/lib/ui/function_and_service/task/hall/hall_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/task/hall_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:flutter/material.dart'; @@ -28,7 +28,7 @@ class _HallViewState extends State { @override Widget build(BuildContext context) { return BeeListView( - path: SARSAPI.task.list, + path: SAASAPI.task.list, controller: widget.refreshController, extraParams: { 'taskModel': 1, diff --git a/lib/ui/function_and_service/task/my_take_task/my_take_task_view.dart b/lib/ui/function_and_service/task/my_take_task/my_take_task_view.dart index cdef149a..669c374c 100644 --- a/lib/ui/function_and_service/task/my_take_task/my_take_task_view.dart +++ b/lib/ui/function_and_service/task/my_take_task/my_take_task_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/task/my_take_task_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:flutter/material.dart'; @@ -28,7 +28,7 @@ class _MyTakeTaskViewState extends State { @override Widget build(BuildContext context) { return BeeListView( - path: SARSAPI.task.list, + path: SAASAPI.task.list, controller: widget.refreshController, extraParams: { 'taskModel': 2, diff --git a/lib/ui/function_and_service/task/my_task/my_task_view.dart b/lib/ui/function_and_service/task/my_task/my_task_view.dart index c244b57d..f15108cc 100644 --- a/lib/ui/function_and_service/task/my_task/my_task_view.dart +++ b/lib/ui/function_and_service/task/my_task/my_task_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/task/my_task_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:flutter/material.dart'; @@ -28,7 +28,7 @@ class _MyTaskViewState extends State { @override Widget build(BuildContext context) { return BeeListView( - path: SARSAPI.task.list, + path: SAASAPI.task.list, controller: widget.refreshController, extraParams: { 'taskModel': 2, diff --git a/lib/ui/function_and_service/task/publish_task_page.dart b/lib/ui/function_and_service/task/publish_task_page.dart index de7099ee..939bd5c5 100644 --- a/lib/ui/function_and_service/task/publish_task_page.dart +++ b/lib/ui/function_and_service/task/publish_task_page.dart @@ -1,7 +1,7 @@ import 'dart:io'; import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/ui/function_and_service/task/task_func.dart'; import 'package:aku_new_community/ui/function_and_service/task/task_map.dart'; @@ -118,7 +118,7 @@ class _PublishTaskPageState extends State { if (_voiceUri != null) { try { var base = await NetUtil().upload( - SARSAPI.uploadFile.uploadImg, + SAASAPI.uploadFile.uploadImg, File.fromUri(Uri(path: _voiceUri))); if (base.success) { _voiceUrl = base.data; @@ -133,7 +133,7 @@ class _PublishTaskPageState extends State { if (_photos.isNotEmpty) { try { imgs = await NetUtil() - .uploadFiles(_photos, SARSAPI.uploadFile.uploadImg); + .uploadFiles(_photos, SAASAPI.uploadFile.uploadImg); } catch (e) { print(e.toString()); } diff --git a/lib/ui/function_and_service/task/task_func.dart b/lib/ui/function_and_service/task/task_func.dart index 6fbb2d9f..f9b90038 100644 --- a/lib/ui/function_and_service/task/task_func.dart +++ b/lib/ui/function_and_service/task/task_func.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; class TaskFunc { @@ -21,7 +21,7 @@ class TaskFunc { required int rewardType, required String reward, }) async { - var base = await NetUtil().post(SARSAPI.task.insert, + var base = await NetUtil().post(SAASAPI.task.insert, params: { 'type': type, 'sex': sex, @@ -48,7 +48,7 @@ class TaskFunc { static Future cancel({ required int taskId, }) async { - var base = await NetUtil().get(SARSAPI.task.cancel, params: { + var base = await NetUtil().get(SAASAPI.task.cancel, params: { 'taskId': taskId, }); return base.success; @@ -59,7 +59,7 @@ class TaskFunc { static Future take({ required int taskId, }) async { - var base = await NetUtil().get(SARSAPI.task.receive, + var base = await NetUtil().get(SAASAPI.task.receive, params: { 'taskId': taskId, }, @@ -72,7 +72,7 @@ class TaskFunc { static Future finish({ required int taskId, }) async { - var base = await NetUtil().get(SARSAPI.task.finish, params: { + var base = await NetUtil().get(SAASAPI.task.finish, params: { 'taskId': taskId, }); return base.success; @@ -82,7 +82,7 @@ class TaskFunc { static Future confirm({ required int taskId, }) async { - var base = await NetUtil().get(SARSAPI.task.confirm, params: { + var base = await NetUtil().get(SAASAPI.task.confirm, params: { 'taskId': taskId, }); return base.success; @@ -92,7 +92,7 @@ class TaskFunc { static Future start({ required int taskId, }) async { - var base = await NetUtil().get(SARSAPI.task.startService, params: { + var base = await NetUtil().get(SAASAPI.task.startService, params: { 'taskId': taskId, }); return base.success; @@ -104,7 +104,7 @@ class TaskFunc { required int star, required String evaluation, }) async { - var base = await NetUtil().get(SARSAPI.task.evaluation, + var base = await NetUtil().get(SAASAPI.task.evaluation, params: {'taskId': taskId, 'star': star, 'evaluation': evaluation}); return base.success; } diff --git a/lib/ui/home/public_infomation/public_infomation_view.dart b/lib/ui/home/public_infomation/public_infomation_view.dart index 162a1e4a..a2d21e46 100644 --- a/lib/ui/home/public_infomation/public_infomation_view.dart +++ b/lib/ui/home/public_infomation/public_infomation_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/community/information_category_list_model.dart'; import 'package:aku_new_community/models/community/information_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; @@ -24,7 +24,7 @@ class _PublicInfomationViewState extends State Widget build(BuildContext context) { super.build(context); return BeeListView( - path: SARSAPI.information.list, + path: SAASAPI.information.list, controller: _refreshController, extraParams: {'categoryId': widget.model.id}, convert: (model) => diff --git a/lib/ui/manager/advice/advice_add_comment_page.dart b/lib/ui/manager/advice/advice_add_comment_page.dart index a92dceb2..032fe304 100644 --- a/lib/ui/manager/advice/advice_add_comment_page.dart +++ b/lib/ui/manager/advice/advice_add_comment_page.dart @@ -5,7 +5,7 @@ import 'package:get/get.dart'; import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; diff --git a/lib/ui/manager/advice/advice_detail_page.dart b/lib/ui/manager/advice/advice_detail_page.dart index 5d946d09..8634d63f 100644 --- a/lib/ui/manager/advice/advice_detail_page.dart +++ b/lib/ui/manager/advice/advice_detail_page.dart @@ -11,7 +11,7 @@ import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/manager/advice_detail_model.dart'; import 'package:aku_new_community/model/manager/suggestion_or_complain_model.dart'; import 'package:aku_new_community/ui/manager/advice/advice_add_comment_page.dart'; diff --git a/lib/ui/manager/advice/advice_evaluate_page.dart b/lib/ui/manager/advice/advice_evaluate_page.dart index 350b9d1b..955ba12d 100644 --- a/lib/ui/manager/advice/advice_evaluate_page.dart +++ b/lib/ui/manager/advice/advice_evaluate_page.dart @@ -1,16 +1,13 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_rating_bar/flutter_rating_bar.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_rating_bar/flutter_rating_bar.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class AdviceEvaluatePage extends StatefulWidget { final int? id; diff --git a/lib/ui/manager/advice/advice_page.dart b/lib/ui/manager/advice/advice_page.dart index 69616f68..bdd5d8e6 100644 --- a/lib/ui/manager/advice/advice_page.dart +++ b/lib/ui/manager/advice/advice_page.dart @@ -7,7 +7,7 @@ import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/manager/suggestion_or_complain_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/manager/advice/advice_card.dart'; diff --git a/lib/ui/manager/advice/new_advice_page.dart b/lib/ui/manager/advice/new_advice_page.dart index ab45d3b1..40552b8c 100644 --- a/lib/ui/manager/advice/new_advice_page.dart +++ b/lib/ui/manager/advice/new_advice_page.dart @@ -13,7 +13,7 @@ import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/provider/app_provider.dart'; import 'package:aku_new_community/ui/manager/advice/advice_page.dart'; import 'package:aku_new_community/utils/headers.dart'; diff --git a/lib/ui/manager/house_keeping/add_house_keeping_page.dart b/lib/ui/manager/house_keeping/add_house_keeping_page.dart index 3d3a4472..9b89461d 100644 --- a/lib/ui/manager/house_keeping/add_house_keeping_page.dart +++ b/lib/ui/manager/house_keeping/add_house_keeping_page.dart @@ -1,16 +1,7 @@ import 'dart:io'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:power_logger/power_logger.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/ui/manager/house_keeping/house_keeping_func.dart'; import 'package:aku_new_community/ui/manager/house_keeping/house_keeping_submit_page.dart'; @@ -21,6 +12,12 @@ import 'package:aku_new_community/widget/buttons/bottom_button.dart'; import 'package:aku_new_community/widget/others/house_head_card.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; import 'package:aku_new_community/widget/picker/grid_image_picker.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:power_logger/power_logger.dart'; +import 'package:velocity_x/velocity_x.dart'; class AddHouseKeepingPage extends StatefulWidget { AddHouseKeepingPage({Key? key}) : super(key: key); diff --git a/lib/ui/manager/house_keeping/house_keeping_card.dart b/lib/ui/manager/house_keeping/house_keeping_card.dart index 1fb35436..a30d53fa 100644 --- a/lib/ui/manager/house_keeping/house_keeping_card.dart +++ b/lib/ui/manager/house_keeping/house_keeping_card.dart @@ -1,15 +1,6 @@ -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/house_keeping/house_keeping_list_model.dart'; import 'package:aku_new_community/models/house_keeping/house_keeping_process_model.dart'; import 'package:aku_new_community/ui/manager/house_keeping/house_keeping_detail_page.dart'; @@ -17,6 +8,12 @@ import 'package:aku_new_community/ui/manager/house_keeping/house_keeping_func.da import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/buttons/card_bottom_button.dart'; import 'package:aku_new_community/widget/others/aku_chip_box.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class HouseKeepingCard extends StatelessWidget { final HouseKeepingListModel model; @@ -124,7 +121,7 @@ class HouseKeepingCard extends StatelessWidget { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(imgObj ?? '')), + image: SAASAPI.image(imgObj ?? '')), ); }, itemCount: model.submitImgList.length, diff --git a/lib/ui/manager/house_keeping/house_keeping_detail_page.dart b/lib/ui/manager/house_keeping/house_keeping_detail_page.dart index c6619943..cd179d76 100644 --- a/lib/ui/manager/house_keeping/house_keeping_detail_page.dart +++ b/lib/ui/manager/house_keeping/house_keeping_detail_page.dart @@ -12,7 +12,7 @@ import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/house_keeping/house_keeping_list_model.dart'; import 'package:aku_new_community/models/house_keeping/house_keeping_process_model.dart'; import 'package:aku_new_community/pages/life_pay/pay_finish_page.dart'; diff --git a/lib/ui/manager/house_keeping/house_keeping_func.dart b/lib/ui/manager/house_keeping/house_keeping_func.dart index f19cca8c..6c51f8a5 100644 --- a/lib/ui/manager/house_keeping/house_keeping_func.dart +++ b/lib/ui/manager/house_keeping/house_keeping_func.dart @@ -1,12 +1,10 @@ import 'dart:io'; -import 'package:bot_toast/bot_toast.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/house_keeping/house_keeping_process_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; +import 'package:bot_toast/bot_toast.dart'; class HouseKeepingFunc { ///提交新增家政服务 diff --git a/lib/ui/manager/house_keeping/house_keeping_view.dart b/lib/ui/manager/house_keeping/house_keeping_view.dart index bd58a1fc..8546d898 100644 --- a/lib/ui/manager/house_keeping/house_keeping_view.dart +++ b/lib/ui/manager/house_keeping/house_keeping_view.dart @@ -5,7 +5,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/house_keeping/house_keeping_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/manager/house_keeping/house_keeping_card.dart'; diff --git a/lib/ui/manager/questionnaire/questionnaire_detail_page.dart b/lib/ui/manager/questionnaire/questionnaire_detail_page.dart index 43c74238..5411d410 100644 --- a/lib/ui/manager/questionnaire/questionnaire_detail_page.dart +++ b/lib/ui/manager/questionnaire/questionnaire_detail_page.dart @@ -1,13 +1,6 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/app_theme.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/questionnaire_detail_model.dart'; import 'package:aku_new_community/model/manager/quetionnaire_submit_model.dart'; @@ -21,6 +14,10 @@ import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/bottom_button.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; class QuestionnaireDetailPage extends StatefulWidget { final int? id; @@ -229,7 +226,7 @@ class _QuestionnaireDetailPageState extends State { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image( + image: SAASAPI.image( ImgModel.first(_model.voResourcesImgList), ), ), diff --git a/lib/ui/manager/questionnaire/questionnaire_page.dart b/lib/ui/manager/questionnaire/questionnaire_page.dart index fee99729..29d6e5e5 100644 --- a/lib/ui/manager/questionnaire/questionnaire_page.dart +++ b/lib/ui/manager/questionnaire/questionnaire_page.dart @@ -1,12 +1,6 @@ -import 'package:flutter/material.dart'; - -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/manager/questinnaire_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; @@ -16,6 +10,10 @@ import 'package:aku_new_community/utils/hive_store.dart'; import 'package:aku_new_community/utils/websocket/tips_dialog.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/others/stack_avatar.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; class QuestionnairePage extends StatefulWidget { QuestionnairePage({Key? key}) : super(key: key); @@ -82,7 +80,7 @@ class _QuestionnairePageState extends State { child: ClipRRect( child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), ), ), ), diff --git a/lib/ui/manager/visitor/visitor_list_item.dart b/lib/ui/manager/visitor/visitor_list_item.dart index b809eb4f..b4d3cd97 100644 --- a/lib/ui/manager/visitor/visitor_list_item.dart +++ b/lib/ui/manager/visitor/visitor_list_item.dart @@ -1,18 +1,15 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:common_utils/common_utils.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/model/manager/visitor_list_item_model.dart'; import 'package:aku_new_community/ui/manager/visitor/visitor_passport_page.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class VisitorListItem extends StatefulWidget { final VisitorListItemModel model; diff --git a/lib/ui/manager/visitor/visitor_record_view.dart b/lib/ui/manager/visitor/visitor_record_view.dart index 0867fa06..4421d1cf 100644 --- a/lib/ui/manager/visitor/visitor_record_view.dart +++ b/lib/ui/manager/visitor/visitor_record_view.dart @@ -1,13 +1,10 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/model/manager/visitor_list_item_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/manager/visitor/visitor_list_item.dart'; import 'package:aku_new_community/utils/headers.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; class VisitorRecordView extends StatefulWidget { ///访客状态(1.已分享,2.已提交,3.已到期) diff --git a/lib/ui/market/category/new_category_sub_card.dart b/lib/ui/market/category/new_category_sub_card.dart index 1c614d55..fb6ec60a 100644 --- a/lib/ui/market/category/new_category_sub_card.dart +++ b/lib/ui/market/category/new_category_sub_card.dart @@ -1,12 +1,9 @@ -import 'package:flutter/material.dart'; - -import 'package:get/get.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/market/market_all_category_model.dart'; import 'package:aku_new_community/ui/market/search/search_goods_page.dart'; import 'package:aku_new_community/utils/headers.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; class NewCategorySubCard extends StatelessWidget { final MarketAllCategoryModel subModels; @@ -23,7 +20,7 @@ class NewCategorySubCard extends StatelessWidget { children: [ Spacer(), FadeInImage.assetNetwork( - image: SARSAPI.image( + image: SAASAPI.image( subModels.imgUrls.isNotEmpty ? subModels.imgUrls.first : ''), //subModels.imgUrls!.isNotEmpty? subModels.imgUrls!.first :'', placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, diff --git a/lib/ui/market/collection/collection_func.dart b/lib/ui/market/collection/collection_func.dart index fd2cff89..911b87b1 100644 --- a/lib/ui/market/collection/collection_func.dart +++ b/lib/ui/market/collection/collection_func.dart @@ -1,5 +1,4 @@ -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/collection/collection_goods_model.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; @@ -7,14 +6,14 @@ import 'package:aku_new_community/utils/network/net_util.dart'; class CollectionFunc { ///加入和取消收藏 static Future collection(int jcookGoodsId) async { - await NetUtil().get(SARSAPI.market.collection.changeCollection, + await NetUtil().get(SAASAPI.market.collection.changeCollection, params: {"appGoodsPushId": jcookGoodsId}, showMessage: true); } /// 获取此供应商热度最高的商品 static Future> getCollectionList() async { BaseModel baseModel = - await NetUtil().get(SARSAPI.market.collection.myCollection); + await NetUtil().get(SAASAPI.market.collection.myCollection); if (baseModel.success == true && baseModel.data != null) { return (baseModel.data as List) .map((e) => CollectionGoodsModel.fromJson(e)) diff --git a/lib/ui/market/market_page.dart b/lib/ui/market/market_page.dart index 213cf8b7..2baeffff 100644 --- a/lib/ui/market/market_page.dart +++ b/lib/ui/market/market_page.dart @@ -3,7 +3,7 @@ import 'dart:ui' as ui; import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/model/good/market_swiper_model.dart'; import 'package:aku_new_community/models/market/goods_popular_model.dart'; @@ -81,7 +81,7 @@ class _MarketPageState extends State Future updateMarketInfo() async { _pageNum = 1; BaseListModel baseListModel = await NetUtil().getList( - SARSAPI.market.good.recommend, + SAASAPI.market.good.recommend, params: { 'pageNum': _pageNum, 'size': _size, @@ -98,7 +98,7 @@ class _MarketPageState extends State Future loadMarketInfo() async { BaseListModel baseListModel = await NetUtil().getList( - SARSAPI.market.good.recommend, + SAASAPI.market.good.recommend, params: { 'pageNum': _pageNum, 'size': _size, @@ -757,7 +757,7 @@ class _MarketPageState extends State ), child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(swiperModel.imgList!.isNotEmpty + image: SAASAPI.image(swiperModel.imgList!.isNotEmpty ? swiperModel.imgList!.first.url : ''), fit: BoxFit.fill, diff --git a/lib/ui/market/order/order_card.dart b/lib/ui/market/order/order_card.dart index aaff17c0..e7d6aec1 100644 --- a/lib/ui/market/order/order_card.dart +++ b/lib/ui/market/order/order_card.dart @@ -1,6 +1,6 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/order/order_list_model.dart'; import 'package:aku_new_community/pages/life_pay/pay_finish_page.dart'; import 'package:aku_new_community/pages/life_pay/pay_util.dart'; @@ -106,7 +106,7 @@ class _OrderCardState extends State { if (result == true) { Function cancel = BotToast.showLoading(); BaseModel baseModel = - await NetUtil().get(SARSAPI.market.order.delete, params: { + await NetUtil().get(SAASAPI.market.order.delete, params: { "orderId": widget.model.id, }); if (baseModel.success) { @@ -136,7 +136,7 @@ class _OrderCardState extends State { ); if (result == true) { Function cancel = BotToast.showLoading(); - BaseModel baseModel = await NetUtil().get(SARSAPI.market.order.cancel, + BaseModel baseModel = await NetUtil().get(SAASAPI.market.order.cancel, params: {"orderId": widget.model.id, 'cancelReasonCode': 4}); if (baseModel.success) { BotToast.showText(text: '取消成功'); @@ -166,7 +166,7 @@ class _OrderCardState extends State { if (result == true) { Function cancel = BotToast.showLoading(); BaseModel baseModel = - await NetUtil().get(SARSAPI.market.order.confirm, params: { + await NetUtil().get(SAASAPI.market.order.confirm, params: { "orderId": widget.model.id, }); if (baseModel.success) { diff --git a/lib/ui/market/order/order_detail_page.dart b/lib/ui/market/order/order_detail_page.dart index 986d82d9..da97fc18 100644 --- a/lib/ui/market/order/order_detail_page.dart +++ b/lib/ui/market/order/order_detail_page.dart @@ -3,7 +3,7 @@ import 'dart:async'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/order/logistics_model.dart'; import 'package:aku_new_community/model/order/order_list_model.dart'; import 'package:aku_new_community/pages/life_pay/pay_util.dart'; @@ -94,7 +94,7 @@ class _OrderDetailPageState extends State { if (result == true) { Function cancel = BotToast.showLoading(); BaseModel baseModel = - await NetUtil().get(SARSAPI.market.order.delete, params: { + await NetUtil().get(SAASAPI.market.order.delete, params: { "orderId": widget.orderModel.id, }); if (baseModel.success) { @@ -125,7 +125,7 @@ class _OrderDetailPageState extends State { ); if (result == true) { Function cancel = BotToast.showLoading(); - BaseModel baseModel = await NetUtil().get(SARSAPI.market.order.cancel, + BaseModel baseModel = await NetUtil().get(SAASAPI.market.order.cancel, params: {"orderId": widget.orderModel.id, 'cancelReasonCode': 4}); if (baseModel.success) { BotToast.showText(text: '取消成功'); @@ -156,7 +156,7 @@ class _OrderDetailPageState extends State { if (result == true) { Function cancel = BotToast.showLoading(); BaseModel baseModel = - await NetUtil().get(SARSAPI.market.order.confirm, params: { + await NetUtil().get(SAASAPI.market.order.confirm, params: { "orderId": widget.orderModel.id, }); if (baseModel.success) { @@ -546,7 +546,7 @@ class _OrderDetailPageState extends State { LineButton( onPressed: () async { BaseModel baseModel = await NetUtil() - .get(SARSAPI.market.order.findLogistics, params: { + .get(SAASAPI.market.order.findLogistics, params: { "orderId": widget.orderModel.id, }); if (baseModel.success == true && baseModel.data != null) { diff --git a/lib/ui/market/order/order_view.dart b/lib/ui/market/order/order_view.dart index 7d172a6c..01eaa82f 100644 --- a/lib/ui/market/order/order_view.dart +++ b/lib/ui/market/order/order_view.dart @@ -1,12 +1,10 @@ +import 'package:aku_new_community/constants/saas_api.dart'; +import 'package:aku_new_community/model/order/order_list_model.dart'; +import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:flutter/material.dart'; - import 'package:flutter_easyrefresh/easy_refresh.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; -import 'package:aku_new_community/model/order/order_list_model.dart'; -import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'order_card.dart'; class OrderView extends StatefulWidget { @@ -36,7 +34,7 @@ class _OrderViewState extends State { @override Widget build(BuildContext context) { return BeeListView( - path: SARSAPI.market.order.myOrder, + path: SAASAPI.market.order.myOrder, controller: _refreshController, extraParams: {"tradeStatus": widget.index, 'orderCode': null}, convert: (models) { diff --git a/lib/ui/market/search/search_func.dart b/lib/ui/market/search/search_func.dart index b8843212..e7c1be88 100644 --- a/lib/ui/market/search/search_func.dart +++ b/lib/ui/market/search/search_func.dart @@ -1,5 +1,5 @@ import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/market/good_detail_model.dart'; import 'package:aku_new_community/models/market/order/order_detail_model.dart'; import 'package:aku_new_community/models/search/search_goods_model.dart'; @@ -54,7 +54,7 @@ class SearchFunc { ///查询商品详情 static Future getGoodDetail(int shopId) async { BaseModel model = await NetUtil().get( - SARSAPI.market.good.goodDetail, + SAASAPI.market.good.goodDetail, params: {'appGoodsPushId': shopId}, ); if (model.data == null) return GoodDetailModel.fail(); @@ -73,7 +73,7 @@ class SearchFunc { ///加入购物车 static Future addGoodsCar(int jcookGoodsId) async { - BaseModel model = await NetUtil().post(SARSAPI.market.shopCart.insert, + BaseModel model = await NetUtil().post(SAASAPI.market.shopCart.insert, params: {'appGoodsPushId': jcookGoodsId}, showMessage: true); if (model.msg == null) return ''; return model.msg as String; diff --git a/lib/ui/market/search/search_goods_page.dart b/lib/ui/market/search/search_goods_page.dart index eee2a1af..4980e3e8 100644 --- a/lib/ui/market/search/search_goods_page.dart +++ b/lib/ui/market/search/search_goods_page.dart @@ -8,7 +8,7 @@ import 'package:waterfall_flow/waterfall_flow.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/market/goods_popular_model.dart'; import 'package:aku_new_community/models/search/search_goods_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; diff --git a/lib/ui/market/search/submit_order_page.dart b/lib/ui/market/search/submit_order_page.dart index a2d2dbac..e49c2afa 100644 --- a/lib/ui/market/search/submit_order_page.dart +++ b/lib/ui/market/search/submit_order_page.dart @@ -1,7 +1,7 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/order/create_order_model.dart'; import 'package:aku_new_community/model/user/adress_model.dart'; import 'package:aku_new_community/models/market/shop_car/shop_car_list_model.dart'; @@ -73,7 +73,7 @@ class _SubmitOrderPageState extends State { Future createOrder( int addressId, List goodsList) async { BaseModel model = await NetUtil().post( - SARSAPI.market.shopCart.settlement, + SAASAPI.market.shopCart.settlement, params: { 'addressId': addressId, 'settlementGoodsDTOList': goodsList.map((v) => v.toJson()).toList() @@ -727,7 +727,7 @@ class _SubmitOrderPageState extends State { Future changeNum(int jcookGoodsId, int num) async { var cancel = BotToast.showLoading(); - var base = await NetUtil().post(SARSAPI.market.shopCart.updateNum, + var base = await NetUtil().post(SAASAPI.market.shopCart.updateNum, params: {'appGoodsPushId': jcookGoodsId, 'num': num}); if (!(base.success)) { BotToast.showText(text: base.msg); diff --git a/lib/ui/market/search/submit_order_page_normal.dart b/lib/ui/market/search/submit_order_page_normal.dart index 864389f8..77b3611d 100644 --- a/lib/ui/market/search/submit_order_page_normal.dart +++ b/lib/ui/market/search/submit_order_page_normal.dart @@ -1,6 +1,6 @@ import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/model/order/create_order_model.dart'; import 'package:aku_new_community/model/user/adress_model.dart'; @@ -73,7 +73,7 @@ class _SubmitOrderNormalPageState extends State { Future createOrder( int addressId, List goodsList) async { BaseModel model = await NetUtil().post( - SARSAPI.market.shopCart.settlement, + SAASAPI.market.shopCart.settlement, params: { 'addressId': addressId, 'settlementGoodsDTOList': goodsList.map((v) => v.toJson()).toList() @@ -759,7 +759,7 @@ class _SubmitOrderNormalPageState extends State { Future changeNum(int jcookGoodsId, int num) async { var cancel = BotToast.showLoading(); - var base = await NetUtil().post(SARSAPI.market.shopCart.updateNum, + var base = await NetUtil().post(SAASAPI.market.shopCart.updateNum, params: {'appGoodsPushId': jcookGoodsId, 'num': num}); if (!(base.success)) { BotToast.showText(text: base.msg); diff --git a/lib/ui/market/shop_car/shop_car_page.dart b/lib/ui/market/shop_car/shop_car_page.dart index a3b77aec..65390060 100644 --- a/lib/ui/market/shop_car/shop_car_page.dart +++ b/lib/ui/market/shop_car/shop_car_page.dart @@ -1,17 +1,6 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; -import 'package:flutter/services.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/const/resource.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/market/shop_car/shop_car_list_model.dart'; import 'package:aku_new_community/ui/market/search/submit_order_page.dart'; import 'package:aku_new_community/ui/market/shop_car/shop_car_func.dart'; @@ -21,6 +10,14 @@ import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/bee_check_radio.dart'; import 'package:aku_new_community/widget/buttons/end_button.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/services.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class ShopCarPage extends StatefulWidget { const ShopCarPage({Key? key}) : super(key: key); @@ -96,7 +93,7 @@ class _ShopCarPageState extends State { header: MaterialHeader(), onRefresh: () async { var base = - await NetUtil().get(SARSAPI.market.shopCart.myCart); + await NetUtil().get(SAASAPI.market.shopCart.myCart); if (base.success) { _models = (base.data as List) .map((e) => ShopCarListModel.fromJson(e)) @@ -248,7 +245,7 @@ class _ShopCarPageState extends State { if (result == true) { BaseModel model = await NetUtil().post( - SARSAPI.market.shopCart.delete, + SAASAPI.market.shopCart.delete, params: { 'appGoodsPushIds': _selectIndex.map((e) => _models[e].id).toList() }, @@ -607,7 +604,7 @@ class _ShopCarPageState extends State { Future changeNum(int jcookGoodsId, int num) async { var cancel = BotToast.showLoading(); - var base = await NetUtil().post(SARSAPI.market.shopCart.updateNum, + var base = await NetUtil().post(SAASAPI.market.shopCart.updateNum, params: {'appGoodsPushId': jcookGoodsId, 'num': num}); if (!(base.success)) { BotToast.showText(text: base.msg); @@ -634,7 +631,7 @@ class _ShopCarPageState extends State { if (result == true) { BaseModel model = await NetUtil().post( - SARSAPI.market.shopCart.delete, + SAASAPI.market.shopCart.delete, params: { 'appGoodsPushIds': _selectIndex.map((e) => _models[e].id).toList() }, diff --git a/lib/ui/market/widget/market_success_page.dart b/lib/ui/market/widget/market_success_page.dart index 16bab18a..1bc10fff 100644 --- a/lib/ui/market/widget/market_success_page.dart +++ b/lib/ui/market/widget/market_success_page.dart @@ -1,14 +1,7 @@ import 'dart:ui'; -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:waterfall_flow/waterfall_flow.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/market/order/goods_home_model.dart'; import 'package:aku_new_community/pages/tab_navigator.dart'; import 'package:aku_new_community/utils/headers.dart'; @@ -17,6 +10,11 @@ import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/end_button.dart'; import 'package:aku_new_community/widget/buttons/line_button.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:waterfall_flow/waterfall_flow.dart'; + import '../market_home_goods_card.dart'; class MarketSuccessPage extends StatefulWidget { diff --git a/lib/ui/profile/house/add_house_page.dart b/lib/ui/profile/house/add_house_page.dart index bbb04833..3c98c9db 100644 --- a/lib/ui/profile/house/add_house_page.dart +++ b/lib/ui/profile/house/add_house_page.dart @@ -1,13 +1,5 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; - import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/ui/profile/house/house_item.dart'; import 'package:aku_new_community/ui/profile/house/pick_building_page.dart'; import 'package:aku_new_community/ui/profile/house/pick_role_page.dart'; @@ -15,6 +7,12 @@ import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; class AddHousePage extends StatefulWidget { AddHousePage({Key? key}) : super(key: key); diff --git a/lib/ui/profile/house/contract_stop/pay_surplus_rent_page.dart b/lib/ui/profile/house/contract_stop/pay_surplus_rent_page.dart index 56d94220..5d0af137 100644 --- a/lib/ui/profile/house/contract_stop/pay_surplus_rent_page.dart +++ b/lib/ui/profile/house/contract_stop/pay_surplus_rent_page.dart @@ -9,7 +9,7 @@ import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/pages/life_pay/pay_finish_page.dart'; import 'package:aku_new_community/pages/life_pay/pay_util.dart'; diff --git a/lib/ui/profile/house/house_func.dart b/lib/ui/profile/house/house_func.dart index 1d5c04f1..fc3aeeeb 100644 --- a/lib/ui/profile/house/house_func.dart +++ b/lib/ui/profile/house/house_func.dart @@ -4,7 +4,7 @@ import 'dart:typed_data'; import 'package:bot_toast/bot_toast.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/house/lease_detail_model.dart'; import 'package:aku_new_community/models/house/lease_echo_model.dart'; import 'package:aku_new_community/models/house/submit_model.dart'; diff --git a/lib/ui/profile/house/lease_pay_query/lease_pay_query_detail_page.dart b/lib/ui/profile/house/lease_pay_query/lease_pay_query_detail_page.dart index f5c4ad93..9a9796ed 100644 --- a/lib/ui/profile/house/lease_pay_query/lease_pay_query_detail_page.dart +++ b/lib/ui/profile/house/lease_pay_query/lease_pay_query_detail_page.dart @@ -7,7 +7,7 @@ import 'package:power_logger/power_logger.dart'; import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/house/lease_fee_list_model.dart'; import 'package:aku_new_community/pages/life_pay/pay_finish_page.dart'; import 'package:aku_new_community/pages/life_pay/pay_util.dart'; diff --git a/lib/ui/profile/house/lease_pay_query/lease_pay_query_page.dart b/lib/ui/profile/house/lease_pay_query/lease_pay_query_page.dart index 3cf12163..7ad707ef 100644 --- a/lib/ui/profile/house/lease_pay_query/lease_pay_query_page.dart +++ b/lib/ui/profile/house/lease_pay_query/lease_pay_query_page.dart @@ -1,15 +1,5 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/models/house/lease_fee_list_model.dart'; import 'package:aku_new_community/ui/profile/house/lease_pay_query/lease_pay_query_detail_page.dart'; import 'package:aku_new_community/utils/headers.dart'; @@ -18,6 +8,13 @@ import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class LeasePayQueryPage extends StatefulWidget { final int id; diff --git a/lib/ui/profile/house/lease_relevation/contract_pay_page.dart b/lib/ui/profile/house/lease_relevation/contract_pay_page.dart index 310f81b4..086ab1c7 100644 --- a/lib/ui/profile/house/lease_relevation/contract_pay_page.dart +++ b/lib/ui/profile/house/lease_relevation/contract_pay_page.dart @@ -1,15 +1,5 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:power_logger/power_logger.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/models/house/lease_detail_model.dart'; import 'package:aku_new_community/pages/life_pay/pay_finish_page.dart'; @@ -19,6 +9,13 @@ import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/bottom_sheets/pay_mothod_bottom_sheet.dart'; import 'package:aku_new_community/widget/buttons/bottom_button.dart'; import 'package:aku_new_community/widget/others/bee_input_row.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:power_logger/power_logger.dart'; +import 'package:velocity_x/velocity_x.dart'; class ContractPayPage extends StatefulWidget { final int id; diff --git a/lib/ui/profile/house/lease_relevation/contract_preview_page.dart b/lib/ui/profile/house/lease_relevation/contract_preview_page.dart index 350378fe..f07953af 100644 --- a/lib/ui/profile/house/lease_relevation/contract_preview_page.dart +++ b/lib/ui/profile/house/lease_relevation/contract_preview_page.dart @@ -1,23 +1,20 @@ import 'dart:typed_data'; -import 'package:flutter/material.dart'; - import 'package:advance_pdf_viewer/advance_pdf_viewer.dart'; -import 'package:bot_toast/bot_toast.dart'; -import 'package:dotted_border/dotted_border.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:power_logger/power_logger.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/ui/profile/house/house_func.dart'; import 'package:aku_new_community/ui/profile/house/lease_relevation/download_contract_page.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/buttons/bottom_button.dart'; import 'package:aku_new_community/widget/others/sign_name_board.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:dotted_border/dotted_border.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:power_logger/power_logger.dart'; +import 'package:velocity_x/velocity_x.dart'; class ContractPreviewPage extends StatefulWidget { final String url; @@ -39,7 +36,7 @@ class _ContractPreviewPageState extends State { void initState() { Future.delayed(Duration(milliseconds: 300), () async { Function cancel = BotToast.showLoading(); - doc = await PDFDocument.fromURL(SARSAPI.image(widget.url)); + doc = await PDFDocument.fromURL(SAASAPI.image(widget.url)); cancel(); _currentPage = 0; setState(() {}); diff --git a/lib/ui/profile/house/lease_relevation/tenant_house_list_page.dart b/lib/ui/profile/house/lease_relevation/tenant_house_list_page.dart index 83e4a995..afe25b90 100644 --- a/lib/ui/profile/house/lease_relevation/tenant_house_list_page.dart +++ b/lib/ui/profile/house/lease_relevation/tenant_house_list_page.dart @@ -5,7 +5,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:velocity_x/velocity_x.dart'; import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/models/house/lease_list_model.dart'; import 'package:aku_new_community/pages/things_page/widget/bee_list_view.dart'; import 'package:aku_new_community/ui/profile/house/lease_relevation/lease_house_card.dart'; diff --git a/lib/ui/profile/new_house/add_house_page.dart b/lib/ui/profile/new_house/add_house_page.dart index 05e3b84e..86c32f3a 100644 --- a/lib/ui/profile/new_house/add_house_page.dart +++ b/lib/ui/profile/new_house/add_house_page.dart @@ -1,13 +1,4 @@ -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/int_ext.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/models/sars_model/my_house/estate_cascade_model.dart'; @@ -21,6 +12,12 @@ import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; import 'package:aku_new_community/widget/picker/bee_house_cascade_picker.dart'; import 'package:aku_new_community/widget/picker/bee_identify_picker.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class AddHousePage extends StatefulWidget { const AddHousePage({Key? key}) : super(key: key); @@ -228,7 +225,7 @@ class _AddHousePageState extends State { return; } var cancel = BotToast.showLoading(); - var base = await NetUtil().post(SARSAPI.profile.house.addHouse, + var base = await NetUtil().post(SAASAPI.profile.house.addHouse, params: { 'identity': _identify.index + 1, 'manageEstateIds': manageEstateIds, @@ -313,7 +310,7 @@ class _AddHousePageState extends State { var house = GestureDetector( onTap: () async { var cancel = BotToast.showLoading(); - var base = await NetUtil().get(SARSAPI.house.allHouses, params: { + var base = await NetUtil().get(SAASAPI.house.allHouses, params: { 'communityId': UserTool.userProvider.userInfoModel!.communityId }); cancel(); @@ -480,7 +477,7 @@ class _AddHousePageState extends State { GestureDetector( onTap: () async { var cancel = BotToast.showLoading(); - var base = await NetUtil().get(SARSAPI.house.allHouses, params: { + var base = await NetUtil().get(SAASAPI.house.allHouses, params: { 'communityId': UserTool.userProvider.userInfoModel!.communityId }); cancel(); diff --git a/lib/ui/profile/new_house/apply_record_page.dart b/lib/ui/profile/new_house/apply_record_page.dart index f66d6b16..67124c4b 100644 --- a/lib/ui/profile/new_house/apply_record_page.dart +++ b/lib/ui/profile/new_house/apply_record_page.dart @@ -1,11 +1,4 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:velocity_x/velocity_x.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/models/sars_model/my_house/my_house_apply_record_list_model.dart'; @@ -13,6 +6,10 @@ import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/tag/bee_tag.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:velocity_x/velocity_x.dart'; class ApplyRecordPage extends StatefulWidget { const ApplyRecordPage({Key? key}) : super(key: key); @@ -34,7 +31,7 @@ class _ApplyRecordPageState extends State { header: MaterialHeader(), footer: MaterialFooter(), onRefresh: () async { - var base = await NetUtil().get(SARSAPI.profile.house.applyRecord); + var base = await NetUtil().get(SAASAPI.profile.house.applyRecord); if (base.success) { _models = (base.data as List) .map((e) => MyHouseApplyRecordListModel.fromJson(e)) diff --git a/lib/ui/profile/new_house/certification/certification_page.dart b/lib/ui/profile/new_house/certification/certification_page.dart index 9c759e22..941865f7 100644 --- a/lib/ui/profile/new_house/certification/certification_page.dart +++ b/lib/ui/profile/new_house/certification/certification_page.dart @@ -1,13 +1,4 @@ -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:common_utils/common_utils.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/ui/profile/new_house/certification/certification_success_page.dart'; import 'package:aku_new_community/ui/profile/new_house/widgets/add_house_button.dart'; @@ -15,6 +6,12 @@ import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; import 'package:aku_new_community/widget/bee_scaffold.dart'; import 'package:aku_new_community/widget/others/user_tool.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:common_utils/common_utils.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class CertificationPage extends StatefulWidget { const CertificationPage({Key? key}) : super(key: key); @@ -138,7 +135,7 @@ class _CertificationPageState extends State { onTap: () async { var cancel = BotToast.showLoading(); var base = - await NetUtil().post(SARSAPI.user.certification, params: { + await NetUtil().post(SAASAPI.user.certification, params: { 'name': _nameController.text, 'idCard': _codeController.text, }); diff --git a/lib/ui/profile/new_house/examine_view.dart b/lib/ui/profile/new_house/examine_view.dart index 7bc3d85f..c97af2b9 100644 --- a/lib/ui/profile/new_house/examine_view.dart +++ b/lib/ui/profile/new_house/examine_view.dart @@ -1,12 +1,4 @@ -import 'package:flutter/material.dart'; - -import 'package:bot_toast/bot_toast.dart'; -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:velocity_x/velocity_x.dart'; - -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/widget_list_ext.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/models/sars_model/my_house/my_family_examine_list_model.dart'; @@ -14,6 +6,11 @@ import 'package:aku_new_community/utils/bee_map.dart'; import 'package:aku_new_community/utils/enum/identify.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; +import 'package:bot_toast/bot_toast.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:velocity_x/velocity_x.dart'; class ExamineView extends StatefulWidget { const ExamineView({Key? key}) : super(key: key); @@ -58,7 +55,7 @@ class _ExamineViewState extends State { footer: MaterialFooter(), onRefresh: () async { var base = await NetUtil() - .get(SARSAPI.profile.family.myFamilyMember, params: { + .get(SAASAPI.profile.family.myFamilyMember, params: { 'status': _currentIndex, }); if (base.success) { @@ -219,7 +216,7 @@ class _ExamineViewState extends State { color: Color(0xFFFAC058), onPressed: () async { var base = await NetUtil().post( - SARSAPI.profile.family.myFamilyReview, + SAASAPI.profile.family.myFamilyReview, params: { 'operate': 1, 'estateReviewId': model.estateId, @@ -244,7 +241,7 @@ class _ExamineViewState extends State { color: Colors.white, onPressed: () async { var base = await NetUtil().post( - SARSAPI.profile.family.myFamilyReview, + SAASAPI.profile.family.myFamilyReview, params: { 'operate': 2, 'estateReviewId': model.estateId, diff --git a/lib/ui/profile/new_house/member_view.dart b/lib/ui/profile/new_house/member_view.dart index 1bbc27a3..935b19c0 100644 --- a/lib/ui/profile/new_house/member_view.dart +++ b/lib/ui/profile/new_house/member_view.dart @@ -1,12 +1,5 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/models/sars_model/my_house/my_family_member_list_model.dart'; import 'package:aku_new_community/ui/profile/new_house/my_house_page.dart'; @@ -14,6 +7,10 @@ import 'package:aku_new_community/utils/bee_map.dart'; import 'package:aku_new_community/utils/enum/identify.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_divider.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:velocity_x/velocity_x.dart'; class MemberView extends StatefulWidget { const MemberView({Key? key}) : super(key: key); @@ -32,7 +29,7 @@ class _MemberViewState extends State { header: MaterialHeader(), footer: MaterialFooter(), onRefresh: () async { - var base = await NetUtil().get(SARSAPI.profile.family.myFamilyMember); + var base = await NetUtil().get(SAASAPI.profile.family.myFamilyMember); if (base.success) { _memberModels = (base.data as List) .map((e) => MyFamilyMemberListModel.fromJson(e)) diff --git a/lib/ui/search/bee_search.dart b/lib/ui/search/bee_search.dart index 28efdcc5..860673e9 100644 --- a/lib/ui/search/bee_search.dart +++ b/lib/ui/search/bee_search.dart @@ -1,13 +1,7 @@ -import 'package:flutter/material.dart'; - -import 'package:flutter_easyrefresh/easy_refresh.dart'; -import 'package:get/get.dart'; -import 'package:velocity_x/velocity_x.dart'; - import 'package:aku_new_community/base/base_style.dart'; import 'package:aku_new_community/constants/api.dart'; import 'package:aku_new_community/constants/application_objects.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:aku_new_community/model/community/activity_item_model.dart'; import 'package:aku_new_community/model/community/community_topic_model.dart'; @@ -19,6 +13,10 @@ import 'package:aku_new_community/utils/login_util.dart'; import 'package:aku_new_community/utils/network/base_model.dart'; import 'package:aku_new_community/utils/network/net_util.dart'; import 'package:aku_new_community/widget/bee_back_button.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_easyrefresh/easy_refresh.dart'; +import 'package:get/get.dart'; +import 'package:velocity_x/velocity_x.dart'; class BeeSearch extends StatefulWidget { BeeSearch({Key? key}) : super(key: key); @@ -114,7 +112,7 @@ class _BeeSearchState extends State { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrls)), + image: SAASAPI.image(ImgModel.first(model.imgUrls)), fit: BoxFit.cover, )), ), @@ -165,7 +163,7 @@ class _BeeSearchState extends State { clipBehavior: Clip.antiAlias, child: FadeInImage.assetNetwork( placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(ImgModel.first(model.imgUrl)), + image: SAASAPI.image(ImgModel.first(model.imgUrl)), fit: BoxFit.cover, )), ), diff --git a/lib/utils/network/net_util.dart b/lib/utils/network/net_util.dart index 66b99766..dcfb7959 100644 --- a/lib/utils/network/net_util.dart +++ b/lib/utils/network/net_util.dart @@ -1,7 +1,7 @@ import 'dart:io'; import 'dart:typed_data'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/pages/sign/login/login_page.dart'; import 'package:aku_new_community/provider/user_provider.dart'; import 'package:aku_new_community/utils/developer_util.dart'; @@ -24,10 +24,10 @@ class NetUtil { NetUtil._internal() { BaseOptions options = BaseOptions( - baseUrl: SARSAPI.baseURL, - connectTimeout: SARSAPI.networkTimeOut, - receiveTimeout: SARSAPI.networkTimeOut, - sendTimeout: SARSAPI.networkTimeOut, + baseUrl: SAASAPI.baseURL, + connectTimeout: SAASAPI.networkTimeOut, + receiveTimeout: SAASAPI.networkTimeOut, + sendTimeout: SAASAPI.networkTimeOut, headers: {}, ); if (_dio == null) _dio = Dio(options); diff --git a/lib/widget/beeImageNetwork.dart b/lib/widget/beeImageNetwork.dart index 82c1157a..019b0bd3 100644 --- a/lib/widget/beeImageNetwork.dart +++ b/lib/widget/beeImageNetwork.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:aku_new_community/model/common/img_model.dart'; import 'package:flutter/material.dart'; @@ -26,8 +26,8 @@ class BeeImageNetwork extends StatelessWidget { return FadeInImage.assetNetwork( placeholder: Assets.images.placeholder.path, image: imgs == null - ? SARSAPI.image(urls!.isEmpty ? '' : urls!.first) - : SARSAPI.image(ImgModel.first(imgs)), + ? SAASAPI.image(urls!.isEmpty ? '' : urls!.first) + : SAASAPI.image(ImgModel.first(imgs)), imageErrorBuilder: (context, obj, stackTrace) { return Image.asset( Assets.images.placeholder.path, diff --git a/lib/widget/picker/bee_image_preview.dart b/lib/widget/picker/bee_image_preview.dart index b4294b3d..700932c7 100644 --- a/lib/widget/picker/bee_image_preview.dart +++ b/lib/widget/picker/bee_image_preview.dart @@ -1,6 +1,6 @@ import 'dart:io'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/gen/assets.gen.dart'; import 'package:flutter/material.dart'; import 'package:get/get.dart'; @@ -66,7 +66,7 @@ class _BeeImagePreviewState extends State { tag: widget.tag ?? widget.path!, child: FadeInImage.assetNetwork( placeholder: Assets.images.placeholder.path, - image: SARSAPI.image(widget.path), + image: SAASAPI.image(widget.path), imageErrorBuilder: (context, obj, stackTrace) { return Image.asset( Assets.images.placeholder.path, diff --git a/lib/widget/views/bee_download_view.dart b/lib/widget/views/bee_download_view.dart index 635f17bb..3aaa4750 100644 --- a/lib/widget/views/bee_download_view.dart +++ b/lib/widget/views/bee_download_view.dart @@ -1,14 +1,11 @@ import 'dart:io'; -import 'package:flutter/material.dart'; - +import 'package:aku_new_community/constants/api.dart'; import 'package:dio/dio.dart'; +import 'package:flutter/material.dart'; import 'package:get/get.dart'; import 'package:path_provider/path_provider.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; - class BeeDownloadView extends StatefulWidget { final String? file; diff --git a/lib/widget/views/bee_grid_image_view.dart b/lib/widget/views/bee_grid_image_view.dart index b97f298f..a3fb8a77 100644 --- a/lib/widget/views/bee_grid_image_view.dart +++ b/lib/widget/views/bee_grid_image_view.dart @@ -1,4 +1,4 @@ -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/picker/bee_image_preview.dart'; import 'package:flutter/material.dart'; @@ -36,7 +36,7 @@ class BeeGridImageView extends StatelessWidget { height: 184.w, width: 184.w, placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(urls[index]), + image: SAASAPI.image(urls[index]), fit: BoxFit.cover, ), ), diff --git a/lib/widget/views/horizontal_image_view.dart b/lib/widget/views/horizontal_image_view.dart index b2ce7c77..44d72a30 100644 --- a/lib/widget/views/horizontal_image_view.dart +++ b/lib/widget/views/horizontal_image_view.dart @@ -1,13 +1,10 @@ -import 'package:flutter/material.dart'; -import 'package:flutter/rendering.dart'; - -import 'package:flutter_screenutil/flutter_screenutil.dart'; - import 'package:aku_new_community/const/resource.dart'; -import 'package:aku_new_community/constants/api.dart'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/utils/headers.dart'; import 'package:aku_new_community/widget/picker/bee_image_preview.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/rendering.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; class HorizontalImageView extends StatelessWidget { final List urls; @@ -39,7 +36,7 @@ class HorizontalImageView extends StatelessWidget { height: 184.w, width: 184.w, placeholder: R.ASSETS_IMAGES_PLACEHOLDER_WEBP, - image: SARSAPI.image(urls[index]), + image: SAASAPI.image(urls[index]), fit: BoxFit.cover, ), ), diff --git a/lib/widget/voice_player.dart b/lib/widget/voice_player.dart index 715a3756..db8bbad7 100644 --- a/lib/widget/voice_player.dart +++ b/lib/widget/voice_player.dart @@ -1,7 +1,7 @@ import 'dart:async'; import 'dart:math'; -import 'package:aku_new_community/constants/sars_api.dart'; +import 'package:aku_new_community/constants/saas_api.dart'; import 'package:aku_new_community/extensions/num_ext.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; @@ -68,7 +68,7 @@ class _VoicePlayerState extends State return; } if (widget.url != null) { - await player.setUrl(SARSAPI.image(widget.url)); + await player.setUrl(SAASAPI.image(widget.url)); } else { await player.setFilePath(widget.path!); }