Browse Source

我的,增加联系客服

zyh
w-R 3 years ago
parent
commit
4f48b67a8f
  1. 17
      android/app/build.gradle
  2. BIN
      assets/image/2x/icon_mine_online_service.png
  3. BIN
      assets/image/3x/icon_mine_online_service.png
  4. BIN
      assets/image/icon_mine_online_service.png
  5. 2
      lib/login/login_page.dart
  6. 2
      lib/main_page.dart
  7. 92
      lib/mine/mine_view/mine_item.dart
  8. 5
      lib/order/bargain_group_order.dart

17
android/app/build.gradle

@ -106,15 +106,10 @@ android {
defaultConfig { defaultConfig {
applicationId "com.zsw.huixiang" applicationId "com.zsw.huixiang"
minSdkVersion 21 minSdkVersion 21
targetSdkVersion 31 targetSdkVersion 30
versionCode flutterVersionCode.toInteger() versionCode flutterVersionCode.toInteger()
versionName flutterVersionName versionName flutterVersionName
ndk {
/// .so
abiFilters 'armeabi-v7a', 'arm64-v8a','x86'
}
manifestPlaceholders = mfph manifestPlaceholders = mfph
} }
@ -145,6 +140,11 @@ android {
minifyEnabled false minifyEnabled false
signingConfig signingConfigs.config signingConfig signingConfigs.config
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
ndk {
/// .so
abiFilters 'armeabi-v7a'
}
} }
debug { debug {
// debuggable true // debuggable true
@ -152,6 +152,11 @@ android {
minifyEnabled false minifyEnabled false
signingConfig signingConfigs.config signingConfig signingConfigs.config
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
ndk {
/// .so
abiFilters 'armeabi-v7a', 'arm64-v8a','x86'
}
} }
} }

BIN
assets/image/2x/icon_mine_online_service.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

BIN
assets/image/3x/icon_mine_online_service.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
assets/image/icon_mine_online_service.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 620 B

After

Width:  |  Height:  |  Size: 1.0 KiB

2
lib/login/login_page.dart

@ -342,7 +342,7 @@ class _MyLoginPageState extends State<LoginPage> with TickerProviderStateMixin {
EasyLoading.dismiss(); EasyLoading.dismiss();
} else { } else {
SmartDialog.showToast("${value?.msg ??""}", alignment: Alignment.center); // SmartDialog.showToast("${value?.msg ??""}", alignment: Alignment.center);
} }
}); });
} }

2
lib/main_page.dart

@ -306,7 +306,7 @@ class _MainPage extends State<MainPage> with WidgetsBindingObserver {
// bottomNavigationBigItem(S.of(context).pinpai, 0), // bottomNavigationBigItem(S.of(context).pinpai, 0),
bottomNavigationItem(S.of(context).main_menu1, 0), bottomNavigationItem(S.of(context).main_menu1, 0),
bottomNavigationItem(S.of(context).main_menu2, 1), bottomNavigationItem(S.of(context).main_menu2, 1),
bottomNavigationItem((Theme.of(context).platform == TargetPlatform.android) ? "订单" :S.of(context).main_menu3 , 2), bottomNavigationItem(S.of(context).main_menu3, 2),
bottomNavigationItem(S.of(context).main_menu4, 3), bottomNavigationItem(S.of(context).main_menu4, 3),
], ],
), ),

92
lib/mine/mine_view/mine_item.dart

@ -1,9 +1,11 @@
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:huixiang/generated/l10n.dart'; import 'package:huixiang/generated/l10n.dart';
import 'package:huixiang/utils/font_weight.dart'; import 'package:huixiang/utils/font_weight.dart';
import 'package:huixiang/view_widget/login_tips_dialog.dart'; import 'package:huixiang/view_widget/login_tips_dialog.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:url_launcher/url_launcher.dart';
class MineItem extends StatefulWidget { class MineItem extends StatefulWidget {
@override @override
@ -33,22 +35,6 @@ class _MineItem extends State<MineItem> {
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
// InkWell(
// onTap: () {
// SharedPreferences.getInstance().then((value) {
// if (value.getString("token") == null ||
// value.getString("token") == "") {
// LoginTipsDialog().show(context);
// return;
// }
// Navigator.of(context).pushNamed('/router/mine_wallet');
// });
// },
// child: mineItem(
// S.of(context).wodeqianbao,
// "assets/image/icon_mine_wallet.png",
// ),
// ),
Container( Container(
padding: EdgeInsets.only(left: 16,top:16,bottom:4), padding: EdgeInsets.only(left: 16,top:16,bottom:4),
child: Text( child: Text(
@ -83,6 +69,8 @@ class _MineItem extends State<MineItem> {
// ), // ),
// ), // ),
// ), // ),
///
Expanded(child: InkWell( Expanded(child: InkWell(
onTap: () { onTap: () {
SharedPreferences.getInstance().then((value) { SharedPreferences.getInstance().then((value) {
@ -100,6 +88,7 @@ class _MineItem extends State<MineItem> {
"assets/image/icon_mine_records_of_consumption.png", "assets/image/icon_mine_records_of_consumption.png",
), ),
),), ),),
///
Expanded(child: InkWell( Expanded(child: InkWell(
onTap: () { onTap: () {
SharedPreferences.getInstance().then((value) { SharedPreferences.getInstance().then((value) {
@ -116,6 +105,7 @@ class _MineItem extends State<MineItem> {
"assets/image/icon_mine_card.png", "assets/image/icon_mine_card.png",
), ),
),), ),),
///
Expanded(child: InkWell( Expanded(child: InkWell(
onTap: () { onTap: () {
SharedPreferences.getInstance().then((value) { SharedPreferences.getInstance().then((value) {
@ -132,6 +122,16 @@ class _MineItem extends State<MineItem> {
"assets/image/icon_location_address.png", "assets/image/icon_location_address.png",
), ),
),), ),),
///
Expanded(child: InkWell(
onTap: () {
showCallMobile();
},
child: mineItem(
"联系客服",
"assets/image/icon_mine_online_service.png",
),
),),
], ],
), ),
SizedBox(height: 10.h,), SizedBox(height: 10.h,),
@ -168,20 +168,6 @@ class _MineItem extends State<MineItem> {
"assets/image/pin_tuan.png", "assets/image/pin_tuan.png",
), ),
),), ),),
Expanded(child: Text("")),
],
),
Expanded(child:InkWell(
onTap: () {
Navigator.of(context).pushNamed('/router/qr_share', arguments: {});
},
child: mineItem(
S.of(context).tuiguangma,
"assets/image/icon_mine_promotion_code.png",
),
),),
Row(
children: [
Expanded(child:InkWell( Expanded(child:InkWell(
onTap: () { onTap: () {
Navigator.of(context).pushNamed('/router/invitation_record', arguments: {}); Navigator.of(context).pushNamed('/router/invitation_record', arguments: {});
@ -191,17 +177,11 @@ class _MineItem extends State<MineItem> {
"assets/image/yao_q.png", "assets/image/yao_q.png",
), ),
),), ),),
Expanded(child:Container()),
Expanded(child:Container()),
Expanded(child:Container())
], ],
), ),
SizedBox(height: 10.h,),
], ],
), ),
// mineItem(
// S.of(context).bangzhuyufankui,
// "assets/image/icon_mine_feedback.png",
// ),
); );
} }
@ -235,5 +215,41 @@ class _MineItem extends State<MineItem> {
); );
} }
showCallMobile() {
showCupertinoModalPopup(
context: context,
builder: (context) {
return CupertinoActionSheet(
title: Text(S.of(context).bodadianhua),
actions: [
CupertinoActionSheetAction(
child: Text("15392949097"),
onPressed: () {
callMobile("15392949097");
Navigator.of(context).pop();
},
isDefaultAction: true,
isDestructiveAction: false,
),
],
cancelButton: CupertinoActionSheetAction(
onPressed: () {
Navigator.of(context).pop();
},
child: Text(S.of(context).quxiao),
isDestructiveAction: true,
),
);
});
}
callMobile(mobile) async {
String url = "tel:$mobile";
if (await canLaunch(url)) {
await launch(url);
} else {
throw 'Could not launch $url';
}
}
} }

5
lib/order/bargain_group_order.dart

@ -4,14 +4,10 @@ import 'package:flutter/material.dart';
import 'package:huixiang/generated/l10n.dart'; import 'package:huixiang/generated/l10n.dart';
import 'package:huixiang/retrofit/data/activity_order_list.dart'; import 'package:huixiang/retrofit/data/activity_order_list.dart';
import 'package:huixiang/retrofit/data/base_data.dart'; import 'package:huixiang/retrofit/data/base_data.dart';
import 'package:huixiang/retrofit/data/exchange_order.dart';
import 'package:huixiang/retrofit/data/page.dart';
import 'package:huixiang/retrofit/min_api.dart'; import 'package:huixiang/retrofit/min_api.dart';
import 'package:huixiang/retrofit/retrofit_api.dart';
import 'package:huixiang/utils/font_weight.dart'; import 'package:huixiang/utils/font_weight.dart';
import 'package:huixiang/view_widget/classic_header.dart'; import 'package:huixiang/view_widget/classic_header.dart';
import 'package:huixiang/view_widget/custom_image.dart'; import 'package:huixiang/view_widget/custom_image.dart';
import 'package:huixiang/view_widget/icon_text.dart';
import 'package:huixiang/view_widget/my_appbar.dart'; import 'package:huixiang/view_widget/my_appbar.dart';
import 'package:huixiang/view_widget/my_footer.dart'; import 'package:huixiang/view_widget/my_footer.dart';
import 'package:huixiang/view_widget/my_tab.dart'; import 'package:huixiang/view_widget/my_tab.dart';
@ -20,7 +16,6 @@ import 'package:huixiang/view_widget/round_button.dart';
import 'package:pull_to_refresh/pull_to_refresh.dart'; import 'package:pull_to_refresh/pull_to_refresh.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
import 'package:shared_preferences/shared_preferences.dart';
class BargainGroupOrder extends StatefulWidget { class BargainGroupOrder extends StatefulWidget {
final Map<String, dynamic> arguments; final Map<String, dynamic> arguments;

Loading…
Cancel
Save