Commit f08df9ec86478015579363b5d89c587f98452e2b

Authored by wdn127929
1 parent 73df1692

图片缓存

@@ -107,6 +107,8 @@ class _BaseInfoPageState extends State<BaseInfoPage> { @@ -107,6 +107,8 @@ class _BaseInfoPageState extends State<BaseInfoPage> {
107 @override 107 @override
108 void dispose() { 108 void dispose() {
109 EventBus().emit('changeStatusColor'); 109 EventBus().emit('changeStatusColor');
  110 + _uploadImageProvider.touxiang = UploadImgModel(); //头像
  111 + _uploadImageProvider.erweima = UploadImgModel(); //二维码
110 super.dispose(); 112 super.dispose();
111 } 113 }
112 114
@@ -144,6 +144,7 @@ class _BookInfoPageState extends State<BookInfoPage> { @@ -144,6 +144,7 @@ class _BookInfoPageState extends State<BookInfoPage> {
144 @override 144 @override
145 void dispose() { 145 void dispose() {
146 _uploadImageProvider.firstImage = UploadImgModel(); 146 _uploadImageProvider.firstImage = UploadImgModel();
  147 + _uploadImageProvider.logo = UploadImgModel();
147 super.dispose(); 148 super.dispose();
148 } 149 }
149 150
@@ -71,6 +71,8 @@ class _DishShowPageState extends State<DishShowPage> { @@ -71,6 +71,8 @@ class _DishShowPageState extends State<DishShowPage> {
71 _uploadImageProvider.storeImage2 = UploadImgModel(); 71 _uploadImageProvider.storeImage2 = UploadImgModel();
72 _uploadImageProvider.storeImage3 = UploadImgModel(); 72 _uploadImageProvider.storeImage3 = UploadImgModel();
73 _uploadImageProvider.storeImage4 = UploadImgModel(); 73 _uploadImageProvider.storeImage4 = UploadImgModel();
  74 + _uploadImageProvider.storeImage5 = UploadImgModel();
  75 + _uploadImageProvider.storeImage6 = UploadImgModel();
74 super.dispose(); 76 super.dispose();
75 } 77 }
76 78
1 import 'package:cached_network_image/cached_network_image.dart'; 1 import 'package:cached_network_image/cached_network_image.dart';
2 import 'package:flutter/material.dart'; 2 import 'package:flutter/material.dart';
3 import 'package:flutter_screenutil/flutter_screenutil.dart'; 3 import 'package:flutter_screenutil/flutter_screenutil.dart';
4 -import 'package:one_key/models/seller_template_color_list_model.dart';  
5 import 'package:one_key/pages/my/marketing_center/theme_model.dart'; 4 import 'package:one_key/pages/my/marketing_center/theme_model.dart';
6 -import 'package:one_key/route/navigator_util.dart';  
7 import 'package:one_key/widgets/system_app_bar.dart'; 5 import 'package:one_key/widgets/system_app_bar.dart';
8 import 'package:one_key/widgets/v_empty_view.dart'; 6 import 'package:one_key/widgets/v_empty_view.dart';
  7 +import 'package:photo_view/photo_view_gallery.dart';
9 import 'package:provider/provider.dart'; 8 import 'package:provider/provider.dart';
10 9
11 import '../../../constant/state.dart'; 10 import '../../../constant/state.dart';
  11 +import '../../../models/seller_template_color_list_model.dart';
12 import '../../../provider/marketing_center_provider.dart'; 12 import '../../../provider/marketing_center_provider.dart';
  13 +import '../../../provider/user_model.dart';
13 import '../../../res/colors.dart'; 14 import '../../../res/colors.dart';
14 import '../../../utils/dialog_util.dart'; 15 import '../../../utils/dialog_util.dart';
15 import '../../../utils/event_bus.dart'; 16 import '../../../utils/event_bus.dart';
16 import '../../../utils/screen_util.dart'; 17 import '../../../utils/screen_util.dart';
17 import '../../../utils/utils.dart'; 18 import '../../../utils/utils.dart';
18 import '../../../widgets/MyDivider.dart'; 19 import '../../../widgets/MyDivider.dart';
  20 +import '../../../widgets/h_empty_view.dart';
19 import '../../../widgets/page_exception.dart'; 21 import '../../../widgets/page_exception.dart';
  22 +import '../../../widgets/round_button.dart';
20 import '../../online_check/photo_view_wiget.dart'; 23 import '../../online_check/photo_view_wiget.dart';
  24 +// import 'package:card_swiper/card_swiper.dart';
21 25
22 import 'dart:convert' as convert; 26 import 'dart:convert' as convert;
23 27
  28 +import 'dart:math' as math;
  29 +
  30 +import 'package:flutter_swiper/flutter_swiper.dart';
  31 +
24 /** 32 /**
25 * 33 *
26 - * 邀请函主题选择页面 34 + * 邀请函主题选择页面预览
27 */ 35 */
28 36
29 class InvitationThemeHomePage extends StatefulWidget { 37 class InvitationThemeHomePage extends StatefulWidget {
  38 + // final SellerTemplateColorListSunModel themeSunModel;
30 InvitationThemeHomePage({Key key}) : super(key: key); 39 InvitationThemeHomePage({Key key}) : super(key: key);
31 40
32 @override 41 @override
@@ -35,52 +44,60 @@ class InvitationThemeHomePage extends StatefulWidget { @@ -35,52 +44,60 @@ class InvitationThemeHomePage extends StatefulWidget {
35 } 44 }
36 45
37 class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { 46 class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
38 - ScrollController controller = ScrollController();  
39 -  
40 MarketingCenterProvider marketingCenterProvider; 47 MarketingCenterProvider marketingCenterProvider;
  48 + ScrollController controller = ScrollController();
41 49
42 //当前店铺选中的颜色和板式 50 //当前店铺选中的颜色和板式
43 51
44 - String themeColor;  
45 - String themeType = '1'; //模版类型  
46 - // int indexSelectColor = 0; //选中第几个模版 (有配色选中index)  
47 - // int indexSelectNoColor = 0; //选中第几个模版 (无配色选中index)  
48 - // List<ThemeSunModel> marketingCenterProvider.templeteDatas = []; 52 + String themeColor = '当前主题不可用';
  53 + String themeType; //模版类型
  54 + String url;
  55 + String themeTitle = '当前主题不可用'; //标题样式
  56 +
  57 + ThemeModel themeModelCurrunt; //有配色对应的当前页面模版数据
  58 +
  59 + PageController pageController;
  60 + double pageOffset = 0;
49 61
50 - // ThemeModel themeModelCurrunt; //有配色对应的当前页面模版数据 62 + SwiperController swiperController = SwiperController();
  63 +
  64 + List movies = [
  65 + 'https://q0.itc.cn/images01/20240605/50e704be01504cf2b2d8ba3999a0a681.jpeg',
  66 + 'https://img1.baidu.com/it/u=364594147,3505938130&fm=253&fmt=auto&app=138&f=JPEG?w=800&h=1200',
  67 + 'https://q0.itc.cn/images01/20240605/b94b61c5c766401698725d5b53c8f37d.jpeg',
  68 + 'https://q0.itc.cn/images01/20240605/50e704be01504cf2b2d8ba3999a0a681.jpeg',
  69 + 'https://img1.baidu.com/it/u=364594147,3505938130&fm=253&fmt=auto&app=138&f=JPEG?w=800&h=1200',
  70 + 'https://q0.itc.cn/images01/20240605/b94b61c5c766401698725d5b53c8f37d.jpeg'
  71 + ];
51 72
52 @override 73 @override
53 void initState() { 74 void initState() {
54 super.initState(); 75 super.initState();
  76 + pageController = PageController(viewportFraction: 1);
  77 + pageController.addListener(() {
  78 + setState(() => pageOffset = pageController.page);
  79 + });
55 80
56 WidgetsBinding.instance.addPostFrameCallback((_) { 81 WidgetsBinding.instance.addPostFrameCallback((_) {
57 _getThemeData(); 82 _getThemeData();
58 - bus.on("theme_color_type", (arg) {  
59 - themeColor = arg['themeColor'];  
60 - themeType = arg['themeType'];  
61 - SellerTemplateColorListSunModel themeSunModel =  
62 - marketingCenterProvider.templeteDatas[marketingCenterProvider  
63 - .templeteDatas  
64 - .indexWhere((element) => element.id == themeType)];  
65 - themeSunModel.themeColorDefault = themeColor;  
66 - bus.emit('theme_color_type_name', {  
67 - 'templateName': themeSunModel.templateName,  
68 - 'url': themeSunModel.colors.length == 0  
69 - ? themeSunModel.url  
70 - : themeSunModel  
71 - .colors[themeSunModel.colors  
72 - .indexWhere((element) => element.colorName == themeColor)]  
73 - .url  
74 - });  
75 - setState(() {});  
76 - });  
77 }); 83 });
78 - }  
79 84
80 - @override  
81 - void dispose() {  
82 - bus.off('theme_color_type');  
83 - super.dispose(); 85 + // if (themeSunModel.themeColorDefault != null) {
  86 + // themeColor = themeSunModel.themeColorDefault;
  87 + // url = themeSunModel
  88 + // .colors[themeSunModel.colors
  89 + // .indexWhere((element) => element.colorName == themeColor)]
  90 + // .url;
  91 + // } else {
  92 + // if (themeSunModel.colors.length > 0) {
  93 + // themeColor = themeSunModel.colors[0].colorName;
  94 + // url = themeSunModel.colors[0].url;
  95 + // } else {
  96 + // url = themeSunModel.url;
  97 + // }
  98 + // }
  99 +
  100 + // themeType = themeSunModel.id;
84 } 101 }
85 102
86 _getThemeData() async { 103 _getThemeData() async {
@@ -95,6 +112,7 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -95,6 +112,7 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
95 (element) => 112 (element) =>
96 element.id == marketingCenterProvider.markDataModel.type); 113 element.id == marketingCenterProvider.markDataModel.type);
97 themeType = marketingCenterProvider.templeteDatas[index].id; 114 themeType = marketingCenterProvider.templeteDatas[index].id;
  115 + swiperController.index = index;
98 116
99 List<ColorListModel> colors = 117 List<ColorListModel> colors =
100 marketingCenterProvider.templeteDatas[index].colors; 118 marketingCenterProvider.templeteDatas[index].colors;
@@ -143,8 +161,46 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -143,8 +161,46 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
143 return false; 161 return false;
144 } 162 }
145 163
  164 + // _selectTheme(String id) {
  165 + // List<ThemeSunModel> temp = [];
  166 + // temp.addAll(themeModelCurrunt.urls);
  167 + // temp.addAll(themeDatasno);
  168 + // List<String> tempUrls = temp.map((e) => e.url).toList();
  169 +
  170 + // // List<String> temp =
  171 + // // themeModel.urls.map((e) => e.url).toList();
  172 + // // print(temp);
  173 +
  174 + // // List<String> temp =
  175 + // // themeDatasno.map((e) => e.url).toList();
  176 + // print(temp);
  177 + // _showPhotoView(
  178 + // context, temp.indexWhere((element) => element.id == id), tempUrls,
  179 + // (index) {
  180 + // //选中的index
  181 + // themeType = temp[index].id; //当前选中模版的id
  182 + // setState(() {});
  183 + // });
  184 + // }
  185 +
  186 + double _scale = 1.0;
  187 + double _previousScale = 1.0;
  188 + Offset _panOffset = Offset(0, 0);
  189 + Offset _previousPanOffset = Offset(0, 0);
  190 +
  191 + void _onScaleUpdate(ScaleUpdateDetails details) {
  192 + setState(() {
  193 + _previousScale = _scale;
  194 + _scale *= details.scale;
  195 + _previousPanOffset = _panOffset;
  196 + _panOffset = _panOffset -
  197 + details.focalPoint -
  198 + _panOffset +
  199 + details.localFocalPoint;
  200 + });
  201 + }
  202 +
146 _showPhotoView(BuildContext context, int index, List<String> imgs, 203 _showPhotoView(BuildContext context, int index, List<String> imgs,
147 - CustomCallBack callback,  
148 {isShow = false, List dashName}) async { 204 {isShow = false, List dashName}) async {
149 // if (imgs.length == 1 && 205 // if (imgs.length == 1 &&
150 // imgs[0] == 206 // imgs[0] ==
@@ -173,7 +229,7 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -173,7 +229,7 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
173 needTap: false, 229 needTap: false,
174 callback: (curruntIndex) { 230 callback: (curruntIndex) {
175 //选中某个模版 231 //选中某个模版
176 - callback(curruntIndex); 232 + // callback(curruntIndex);
177 }, 233 },
178 ), 234 ),
179 // Positioned( 235 // Positioned(
@@ -205,75 +261,6 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -205,75 +261,6 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
205 Utils.setBarStatus(true, color: Colors.white); 261 Utils.setBarStatus(true, color: Colors.white);
206 } 262 }
207 263
208 - List<Widget> imagesWidgets() {  
209 - List<Widget> images = [];  
210 - for (int i = 0; i < marketingCenterProvider.templeteDatas.length; i++) {  
211 - SellerTemplateColorListSunModel themeSunModel =  
212 - marketingCenterProvider.templeteDatas[i];  
213 - images.add(InkWell(  
214 - onTap: () {  
215 - // _selectTheme(themeDatas[themeColor].urls[index].id);  
216 - //跳转到下一页  
217 - NavigatorUtil.goInvitationThemeHomePreviewPage(  
218 - context, themeSunModel);  
219 - },  
220 - child: Container(  
221 - width: (ScreenUtil().screenWidth - w(32) - w(15)) / 2,  
222 - // height: w(390),  
223 - margin: EdgeInsets.only(right: i % 2 == 0 ? w(15) : 0),  
224 - decoration: BoxDecoration(  
225 - borderRadius: BorderRadius.circular(r(10)),  
226 - border: Border.all(  
227 - color: themeType == themeSunModel.id  
228 - ? MyColours.color_005AA7  
229 - : MyColours.color_DBDBDB,  
230 - width: themeType == themeSunModel.id ? w(2) : w(1))),  
231 - child: Column(  
232 - children: [  
233 - // VEmptyView(10),  
234 - ClipRRect(  
235 - borderRadius: BorderRadius.only(  
236 - topLeft: Radius.circular(r(8)),  
237 - topRight: Radius.circular(r(8))),  
238 - child: CachedNetworkImage(  
239 - imageUrl: themeSunModel.colors == null ||  
240 - themeSunModel.colors.length == 0  
241 - ? themeSunModel.url  
242 - : themeSunModel  
243 - .colors[themeColor == null  
244 - ? 0  
245 - : themeSunModel.colors.indexWhere((element) =>  
246 - element.colorName ==  
247 - themeSunModel.themeColorDefault)]  
248 - .url,  
249 - width: (ScreenUtil().screenWidth - w(32) - w(15)) / 2,  
250 - height: w(348),  
251 - fit: BoxFit.fitWidth,  
252 - alignment: Alignment.topCenter,  
253 - ),  
254 - ),  
255 - VEmptyView(20),  
256 - Container(  
257 - padding:  
258 - EdgeInsets.symmetric(vertical: w(7), horizontal: w(3)),  
259 - width: double.infinity,  
260 - child: Text(  
261 - themeSunModel.templateName,  
262 - maxLines: 1,  
263 - overflow: TextOverflow.ellipsis,  
264 - textAlign: TextAlign.left,  
265 - style: TextStyle(  
266 - color: MyColours.color_000000, fontSize: font(14)),  
267 - ),  
268 - )  
269 - ],  
270 - ),  
271 - )));  
272 - }  
273 - marketingCenterProvider.templeteDatas.forEach((themeSunModel) {});  
274 - return images;  
275 - }  
276 -  
277 @override 264 @override
278 Widget build(BuildContext context) { 265 Widget build(BuildContext context) {
279 marketingCenterProvider = 266 marketingCenterProvider =
@@ -286,7 +273,7 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -286,7 +273,7 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
286 return ExceptionPage( 273 return ExceptionPage(
287 pageState: model.pageStateThemeHome, 274 pageState: model.pageStateThemeHome,
288 callback: () async {}, 275 callback: () async {},
289 - emptyMsg: "暂时没有预订信息展示哦", 276 + emptyMsg: "暂时没有信息展示哦",
290 emptyImg: "empty_search", 277 emptyImg: "empty_search",
291 showMsg: "加载中,请稍后...", 278 showMsg: "加载中,请稍后...",
292 ); 279 );
@@ -297,97 +284,318 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -297,97 +284,318 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
297 child: SingleChildScrollView( 284 child: SingleChildScrollView(
298 child: Column( 285 child: Column(
299 children: [ 286 children: [
300 - VEmptyView(24), 287 + InkWell(
  288 + onTap: () {
  289 + // DialogUtil.showThemeColorSelectDialogNew(
  290 + // context, themeSunModel.colors, callback: (object) {
  291 + // print(object);
  292 + // setState(() {
  293 + // themeColor = object;
  294 + // url = themeSunModel
  295 + // .colors[themeSunModel.colors.indexWhere(
  296 + // (element) => element.colorName == object)]
  297 + // .url;
  298 + // });
  299 + // });
  300 + },
  301 + child: Padding(
  302 + padding: EdgeInsets.only(
  303 + left: w(16),
  304 + top: w(12),
  305 + bottom: w(12),
  306 + right: w(12)),
  307 + child: Row(
  308 + mainAxisAlignment: MainAxisAlignment.spaceBetween,
  309 + children: [
  310 + Text(
  311 + '主题颜色选择',
  312 + style: TextStyle(
  313 + color: MyColours.color_515151,
  314 + fontSize: font(16)),
  315 + ),
  316 + Spacer(),
  317 + Text(
  318 + themeColor ?? '',
  319 + style: TextStyle(
  320 + color: themeColor == '当前主题不可用'
  321 + ? MyColours.color_BFC4D4
  322 + : MyColours.color_515151,
  323 + fontSize: font(16)),
  324 + ),
  325 + Container(
  326 + padding: EdgeInsets.symmetric(
  327 + horizontal: w(11), vertical: w(4)),
  328 + child: Image.asset(
  329 + "assets/arrow_right_new.png",
  330 + width: w(9),
  331 + height: w(16),
  332 + ),
  333 + )
  334 + // RoundButton(
  335 + // text: '预览',
  336 + // gradientStart: MyColours.color_ffffff,
  337 + // gradientEnd: MyColours.color_ffffff,
  338 + // borderColor: MyColours.color_438E93,
  339 + // textColor: MyColours.color_438E93,
  340 + // radius: ScreenUtil().setWidth(22),
  341 + // fontSize: 24,
  342 + // width: w(72),
  343 + // height: ScreenUtil().setWidth(44),
  344 + // isBold: true,
  345 + // onPressed: () {
  346 + // NavigatorUtil.goMarkingPreviewPage(context);
  347 + // },
  348 + // ),
  349 + ]))),
301 Padding( 350 Padding(
302 - padding: EdgeInsets.symmetric(horizontal: w(16)),  
303 - child: Wrap(  
304 - runSpacing: w(15),  
305 - // spacing: w(15),  
306 - children: imagesWidgets(), 351 + padding: EdgeInsets.only(left: w(16)),
  352 + child: MyDivider(double.infinity, w(0.5),
  353 + color: MyColours.color_E7E7E7)),
  354 + // VEmptyView(24),
  355 + InkWell(
  356 + onTap: () {},
  357 + child: Padding(
  358 + padding: EdgeInsets.only(
  359 + left: w(16),
  360 + top: w(12),
  361 + bottom: w(11),
  362 + right: w(12)),
  363 + child: Row(
  364 + mainAxisAlignment: MainAxisAlignment.spaceBetween,
  365 + children: [
  366 + Text(
  367 + '介绍模块标题样式',
  368 + style: TextStyle(
  369 + color: MyColours.color_515151,
  370 + fontSize: font(16)),
  371 + ),
  372 + Spacer(),
  373 + Text(
  374 + themeTitle,
  375 + style: TextStyle(
  376 + color: themeTitle == '当前主题不可用'
  377 + ? MyColours.color_BFC4D4
  378 + : MyColours.color_515151,
  379 + fontSize: font(16)),
  380 + ),
  381 + Container(
  382 + padding: EdgeInsets.symmetric(
  383 + horizontal: w(11), vertical: w(4)),
  384 + child: Image.asset(
  385 + "assets/arrow_right_new.png",
  386 + width: w(9),
  387 + height: w(16),
  388 + ),
  389 + )
  390 + // RoundButton(
  391 + // text: '预览',
  392 + // gradientStart: MyColours.color_ffffff,
  393 + // gradientEnd: MyColours.color_ffffff,
  394 + // borderColor: MyColours.color_438E93,
  395 + // textColor: MyColours.color_438E93,
  396 + // radius: ScreenUtil().setWidth(22),
  397 + // fontSize: 24,
  398 + // width: w(72),
  399 + // height: ScreenUtil().setWidth(44),
  400 + // isBold: true,
  401 + // onPressed: () {
  402 + // NavigatorUtil.goMarkingPreviewPage(context);
  403 + // },
  404 + // ),
  405 + ]))),
  406 + Padding(
  407 + padding: EdgeInsets.only(left: w(16)),
  408 + child: MyDivider(double.infinity, w(0.5),
  409 + color: MyColours.color_E7E7E7)),
  410 + Container(
  411 + width: double.infinity,
  412 + alignment: Alignment.centerLeft,
  413 + padding: EdgeInsets.only(
  414 + left: w(16), top: w(12), bottom: w(11), right: w(16)),
  415 + child: Text(
  416 + '通知主题选择(左右滑动选择要使用的主题)',
  417 + style: TextStyle(
  418 + color: MyColours.color_515151, fontSize: font(16)),
307 )), 419 )),
308 - VEmptyView(24),  
309 - // GridView.builder(  
310 - // padding: EdgeInsets.symmetric(horizontal: w(16)),  
311 - // controller: controller,  
312 - // // padding: EdgeInsets.only(top: ScreenUtil().getAdapterSize(10)),  
313 - // shrinkWrap: true,  
314 - // itemCount: marketingCenterProvider.templeteDatas.length,  
315 - // //SliverGridDelegateWithFixedCrossAxisCount 构建一个横轴固定数量Widget  
316 - // gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(  
317 - // //横轴元素个数  
318 - // crossAxisCount: 2,  
319 - // //纵轴间距  
320 - // mainAxisSpacing: w(15),  
321 - // //横轴间距  
322 - // crossAxisSpacing: w(15),  
323 - // //子组件宽高长度比例  
324 - // // childAspectRatio:  
325 - // // (ScreenUtil().screenWidth - w(62)) / 2 / 370  
326 - // ),  
327 - // itemBuilder: (BuildContext context, int index) {  
328 - // SellerTemplateColorListSunModel themeSunModel =  
329 - // marketingCenterProvider.templeteDatas[index];  
330 - // return InkWell(  
331 - // onTap: () {  
332 - // // _selectTheme(themeDatas[themeColor].urls[index].id);  
333 - // //跳转到下一页  
334 - // NavigatorUtil.goInvitationThemeHomePreviewPage(  
335 - // context, themeSunModel);  
336 - // },  
337 - // child: Container(  
338 - // height: w(385),  
339 - // decoration: BoxDecoration(  
340 - // borderRadius: BorderRadius.circular(r(10)),  
341 - // border: Border.all(  
342 - // color: themeType == themeSunModel.id  
343 - // ? MyColours.color_005AA7  
344 - // : MyColours.color_DBDBDB,  
345 - // width: themeType == themeSunModel.id  
346 - // ? w(2)  
347 - // : w(1))),  
348 - // child: Column(  
349 - // children: [  
350 - // VEmptyView(10),  
351 - // CachedNetworkImage(  
352 - // imageUrl: themeSunModel.colors == null ||  
353 - // themeSunModel.colors.length == 0  
354 - // ? themeSunModel.url  
355 - // : themeSunModel  
356 - // .colors[themeColor == null  
357 - // ? 0  
358 - // : themeSunModel.colors  
359 - // .indexWhere((element) =>  
360 - // element.colorName ==  
361 - // themeSunModel  
362 - // .themeColorDefault)]  
363 - // .url,  
364 - // width:  
365 - // (ScreenUtil().screenWidth - w(62)) / 2,  
366 - // height: w(348),  
367 - // fit: BoxFit.fitWidth,  
368 - // alignment: Alignment.topCenter,  
369 - // ),  
370 - // VEmptyView(20),  
371 - // Container(  
372 - // padding: EdgeInsets.symmetric(  
373 - // vertical: w(6), horizontal: w(2)),  
374 - // width: double.infinity,  
375 - // child: Text(  
376 - // themeSunModel.templateName,  
377 - // maxLines: 1,  
378 - // overflow: TextOverflow.ellipsis,  
379 - // textAlign: TextAlign.left,  
380 - // style: TextStyle(  
381 - // color: MyColours.color_000000,  
382 - // fontSize: font(14)),  
383 - // ),  
384 - // )  
385 - // ],  
386 - // ),  
387 - // )); 420 + Padding(
  421 + padding: EdgeInsets.only(left: w(16)),
  422 + child: MyDivider(double.infinity, w(0.5),
  423 + color: MyColours.color_E7E7E7)),
  424 + VEmptyView(60),
  425 + // Container(
  426 + // height: w(300),
  427 + // child: PhotoViewGallery.builder(
  428 + // scrollPhysics: const BouncingScrollPhysics(),
  429 + // builder: (BuildContext context, int index) {
  430 + // return PhotoViewGalleryPageOptions(
  431 + // imageProvider: NetworkImage(movies[index]),
  432 + // );
  433 + // },
  434 + // scrollDirection: Axis.horizontal,
  435 + // itemCount: movies.length,
  436 + // backgroundDecoration: BoxDecoration(color: Colors.white),
  437 + // pageController: PageController(initialPage: 0),
  438 + // onPageChanged: (index) => setState(() {
  439 + // // currentIndex = index;
  440 + // // if (widget.pageChanged != null) {
  441 + // // widget.pageChanged(index);
  442 + // // }
  443 + // }))),
  444 + Container(
  445 + height: w(359),
  446 + child: new Swiper(
  447 + controller:swiperController,
  448 + itemBuilder: (BuildContext context, int index) {
  449 + SellerTemplateColorListSunModel themeSunModel = marketingCenterProvider.templeteDatas[index];
  450 + return new ClipRRect(
  451 + borderRadius: BorderRadius.circular(r(10)),
  452 + child: CachedNetworkImage(
  453 + imageUrl: themeSunModel.colors == null ||
  454 + themeSunModel.colors.length == 0
  455 + ? themeSunModel.url
  456 + : themeSunModel
  457 + .colors[themeColor == null
  458 + ? 0
  459 + : themeSunModel.colors
  460 + .indexWhere((element) =>
  461 + element.colorName ==
  462 + themeSunModel
  463 + .themeColorDefault)]
  464 + .url,
  465 + // width:
  466 + // (ScreenUtil().screenWidth - w(62)) / 2,
  467 + // height: w(348),
  468 + fit: BoxFit.fitWidth,
  469 + alignment: Alignment.topCenter,
  470 + ));
  471 + },
  472 + // onTap: (v) {
  473 + // // print(v);
  474 + // },
  475 + onIndexChanged: (index) {
  476 + print(index);
  477 + // 当前选中的主题
  478 + },
  479 + itemCount: marketingCenterProvider.templeteDatas.length,
  480 + viewportFraction: 0.5,
  481 + scale: 0.5,
  482 + ),
  483 + ),
  484 + // Container(
  485 + // // height: w(300),
  486 + // height: w(359),
  487 + // child: PageView(
  488 + // controller: pageController,
  489 + // children: List.generate(movies.length, (index) {
  490 + // return SlidingCard(
  491 + // offset: pageOffset - index,
  492 + // movie: movies[index],
  493 + // index: index);
388 // }), 494 // }),
  495 + // ),
  496 + // )
  497 +
  498 + // Swiper(
  499 +
  500 + // itemBuilder: (BuildContext context,int index){
  501 + // return Image.network("http://nosqn.colorcun.com/app/seller-hj-empty.png",fit: BoxFit.fill,);
  502 + // },
  503 + // itemCount: 3,
  504 + // pagination: SwiperPagination(),
  505 + // control: SwiperControl(),
  506 + // ),
  507 + // GestureDetector(
  508 + // onScaleUpdate: _onScaleUpdate,
  509 + // child: Transform(
  510 + // alignment: Alignment.center,
  511 + // transform: Matrix4.identity()
  512 + // ..translate(_panOffset.dx, _panOffset.dy)
  513 + // ..scale(_scale),
  514 + // child: Image.network(
  515 + // 'http://nosqn.colorcun.com/app/seller-hj-empty.png',
  516 + // fit: BoxFit.contain,
  517 + // ),
  518 + // ),
  519 + // ),
  520 + // InkWell(
  521 + // onTap: () {
  522 + // _showPhotoView(context, 0, [url]);
  523 + // },
  524 + // child: CachedNetworkImage(
  525 + // imageUrl: url,
  526 + // width: ScreenUtil().screenWidth - w(32),
  527 + // fit: BoxFit.fitWidth,
  528 + // alignment: Alignment.topCenter,
  529 + // )),
389 ], 530 ],
390 - ))) 531 + ))),
  532 + Container(
  533 + padding:
  534 + EdgeInsets.symmetric(horizontal: w(24), vertical: w(35)),
  535 + child: Row(
  536 + children: [
  537 + RoundButton(
  538 + text: '返回',
  539 + width: w(100),
  540 + height: w(43),
  541 + radius: r(5),
  542 + fontSize: 32,
  543 + isBold: true,
  544 + gradientStart: MyColours.color_ffffff,
  545 + gradientEnd: MyColours.color_ffffff,
  546 + textColor: MyColours.color_438E93,
  547 + borderColor: MyColours.color_438E93,
  548 + onPressed: () {
  549 + Navigator.pop(context);
  550 + },
  551 + ),
  552 + HEmptyView(24),
  553 + Expanded(
  554 + child: RoundButton(
  555 + text: '保存并返回',
  556 + height: w(43),
  557 + radius: r(5),
  558 + isBold: true,
  559 + fontSize: 32,
  560 + gradientStart: MyColours.color_438E93,
  561 + gradientEnd: MyColours.color_438E93,
  562 + textColor: MyColours.color_ffffff,
  563 + borderColor: MyColours.color_438E93,
  564 + onPressed: () async {
  565 + //接口成功后刷新并返回前一页
  566 + //接口
  567 +
  568 + // Map<String, String> params = {
  569 + // 'sid': Provider.of<UserModel>(context, listen: false)
  570 + // .user
  571 + // .sellerid,
  572 + // 'type': themeType,
  573 + // 'lite_class': themeColor == null
  574 + // ? null
  575 + // : themeSunModel
  576 + // .colors[themeSunModel.colors.indexWhere(
  577 + // (element) =>
  578 + // element.colorName == themeColor)]
  579 + // .liteClass
  580 + // };
  581 +
  582 + // bool success = await marketingCenterProvider
  583 + // .setSellerTemplateConf(context, params,
  584 + // showLoading: true);
  585 + // if (success) {
  586 + // Utils.showToast('设置成功');
  587 + // //选择当前模版+主题色
  588 + // bus.emit('theme_color_type', {
  589 + // 'themeColor': themeColor,
  590 + // 'themeType': themeType,
  591 + // });
  592 + // Navigator.pop(context);
  593 + // }
  594 + },
  595 + )),
  596 + ],
  597 + ),
  598 + )
391 ], 599 ],
392 ); 600 );
393 } 601 }
@@ -395,3 +603,104 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> { @@ -395,3 +603,104 @@ class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
395 ); 603 );
396 } 604 }
397 } 605 }
  606 +
  607 +class SlidingCard extends StatelessWidget {
  608 + final double offset;
  609 + final String movie;
  610 + final int index;
  611 + const SlidingCard({this.offset, this.movie, this.index});
  612 +
  613 + @override
  614 + Widget build(BuildContext context) {
  615 + int select = 0;
  616 + double gauss = math.exp(-(math.pow((offset.abs() - 0.5), 2) / 0.08));
  617 + if (Offset(-32 * gauss * offset.sign, 0).dx == -0.0) {
  618 + //最中间的图
  619 + select = index;
  620 + }
  621 + return Transform.translate(
  622 + offset: Offset(-32 * gauss * offset.sign, 0),
  623 + child: InkWell(
  624 + onTap: () {
  625 + print(gauss);
  626 + print(Offset(-32 * gauss * offset.sign, 0));
  627 + print(index);
  628 + },
  629 + child: Card(
  630 + margin: EdgeInsets.only(left: 8, right: 8, bottom: 8),
  631 + elevation: 8,
  632 + shape: RoundedRectangleBorder(
  633 + borderRadius: BorderRadius.circular(32),
  634 + ),
  635 + child: ClipRRect(
  636 + borderRadius: BorderRadius.circular(
  637 + r(10),
  638 + ),
  639 + child: Image.network(
  640 + '${movie}',
  641 + width: select == index ? w(375) : w(179),
  642 + height: select == index ? w(359) : w(90),
  643 + // height: MediaQuery.of(context).size.height * 0.3,
  644 + alignment: Alignment(-offset.abs(), 0),
  645 + fit: BoxFit.cover,
  646 + ),
  647 + ),
  648 + // SizedBox(
  649 + // height: 8,
  650 + // ),
  651 + // Expanded(
  652 + // child: Padding(
  653 + // padding: const EdgeInsets.all(8.0),
  654 + // child: Column(
  655 + // crossAxisAlignment: CrossAxisAlignment.start,
  656 + // children: <Widget>[
  657 + // Text(
  658 + // '${movie.name}',
  659 + // style:
  660 + // TextStyle(fontSize: 20, fontWeight: FontWeight.bold),
  661 + // ),
  662 + // SizedBox(
  663 + // height: 10,
  664 + // ),
  665 + // Text(
  666 + // '上架时间: ${movie.date}',
  667 + // style: TextStyle(
  668 + // fontSize: 14, fontWeight: FontWeight.normal),
  669 + // ),
  670 + // Text(
  671 + // '${movie.intor}',
  672 + // style: TextStyle(
  673 + // fontSize: 14,
  674 + // fontWeight: FontWeight.normal,
  675 + // ),
  676 + // ),
  677 + // Spacer(),
  678 + // Row(
  679 + // children: <Widget>[
  680 + // SizedBox(width: 16,),
  681 + // Text(
  682 + // '${movie.price}',
  683 + // style: TextStyle(
  684 + // fontSize: 18, fontWeight: FontWeight.bold),
  685 + // ),
  686 + // Spacer(),
  687 + // MaterialButton(
  688 + // onPressed: () {},
  689 + // color: Colors.black,
  690 + // child: Text('购买'),
  691 + // textColor: Colors.white,
  692 + // shape: RoundedRectangleBorder(
  693 + // borderRadius: BorderRadius.circular(32),
  694 + // ),
  695 + // ),
  696 + // SizedBox(width: 16,),
  697 + // ],
  698 + // ),
  699 + // ],
  700 + // ),
  701 + // ),
  702 + // ),
  703 + )),
  704 + );
  705 + }
  706 +}
1 -// import 'package:cached_network_image/cached_network_image.dart';  
2 -// import 'package:flutter/material.dart';  
3 -// import 'package:flutter_screenutil/flutter_screenutil.dart';  
4 -// import 'package:one_key/pages/my/marketing_center/theme_model.dart';  
5 -// import 'package:one_key/widgets/system_app_bar.dart';  
6 -// import 'package:one_key/widgets/v_empty_view.dart';  
7 -// import 'package:provider/provider.dart';  
8 -  
9 -// import '../../../models/seller_template_color_list_model.dart';  
10 -// import '../../../provider/marketing_center_provider.dart';  
11 -// import '../../../provider/user_model.dart';  
12 -// import '../../../res/colors.dart';  
13 -// import '../../../utils/dialog_util.dart';  
14 -// import '../../../utils/event_bus.dart';  
15 -// import '../../../utils/screen_util.dart';  
16 -// import '../../../utils/utils.dart';  
17 -// import '../../../widgets/MyDivider.dart';  
18 -// import '../../../widgets/round_button.dart';  
19 -// import '../../online_check/photo_view_wiget.dart';  
20 -// import 'package:card_swiper/card_swiper.dart';  
21 -  
22 -// import 'dart:convert' as convert;  
23 -  
24 -// /**  
25 -// *  
26 -// * 邀请函主题选择页面预览  
27 -// */  
28 -  
29 -// class InvitationThemeHomePage extends StatefulWidget {  
30 -// // final SellerTemplateColorListSunModel themeSunModel;  
31 -// InvitationThemeHomePage({Key key}) : super(key: key);  
32 -  
33 -// @override  
34 -// _InvitationThemeHomePageState createState() =>  
35 -// _InvitationThemeHomePageState();  
36 -// }  
37 -  
38 -// class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {  
39 -// MarketingCenterProvider marketingCenterProvider;  
40 -// ScrollController controller = ScrollController();  
41 -  
42 -// //当前店铺选中的颜色和板式  
43 -  
44 -// String themeColor;  
45 -// String themeType; //模版类型  
46 -// String url;  
47 -// String themeTitle = ''; //标题样式  
48 -  
49 -// ThemeModel themeModelCurrunt; //有配色对应的当前页面模版数据  
50 -// SellerTemplateColorListSunModel themeSunModel;  
51 -  
52 -// @override  
53 -// void initState() {  
54 -// super.initState();  
55 -// // if (themeSunModel.themeColorDefault != null) {  
56 -// // themeColor = themeSunModel.themeColorDefault;  
57 -// // url = themeSunModel  
58 -// // .colors[themeSunModel.colors  
59 -// // .indexWhere((element) => element.colorName == themeColor)]  
60 -// // .url;  
61 -// // } else {  
62 -// // if (themeSunModel.colors.length > 0) {  
63 -// // themeColor = themeSunModel.colors[0].colorName;  
64 -// // url = themeSunModel.colors[0].url;  
65 -// // } else {  
66 -// // url = themeSunModel.url;  
67 -// // }  
68 -// // }  
69 -  
70 -// // themeType = themeSunModel.id;  
71 -// }  
72 -  
73 -// // _selectTheme(String id) {  
74 -// // List<ThemeSunModel> temp = [];  
75 -// // temp.addAll(themeModelCurrunt.urls);  
76 -// // temp.addAll(themeDatasno);  
77 -// // List<String> tempUrls = temp.map((e) => e.url).toList();  
78 -  
79 -// // // List<String> temp =  
80 -// // // themeModel.urls.map((e) => e.url).toList();  
81 -// // // print(temp);  
82 -  
83 -// // // List<String> temp =  
84 -// // // themeDatasno.map((e) => e.url).toList();  
85 -// // print(temp);  
86 -// // _showPhotoView(  
87 -// // context, temp.indexWhere((element) => element.id == id), tempUrls,  
88 -// // (index) {  
89 -// // //选中的index  
90 -// // themeType = temp[index].id; //当前选中模版的id  
91 -// // setState(() {});  
92 -// // });  
93 -// // }  
94 -  
95 -// double _scale = 1.0;  
96 -// double _previousScale = 1.0;  
97 -// Offset _panOffset = Offset(0, 0);  
98 -// Offset _previousPanOffset = Offset(0, 0);  
99 -  
100 -// void _onScaleUpdate(ScaleUpdateDetails details) {  
101 -// setState(() {  
102 -// _previousScale = _scale;  
103 -// _scale *= details.scale;  
104 -// _previousPanOffset = _panOffset;  
105 -// _panOffset = _panOffset -  
106 -// details.focalPoint -  
107 -// _panOffset +  
108 -// details.localFocalPoint;  
109 -// });  
110 -// }  
111 -  
112 -// _showPhotoView(BuildContext context, int index, List<String> imgs,  
113 -// {isShow = false, List dashName}) async {  
114 -// // if (imgs.length == 1 &&  
115 -// // imgs[0] ==  
116 -// // 'http://nosqn.colorcun.com/custom/lite-online/image/def-banner.png') {  
117 -// // imgs[0] = 'http://nosqn.colorcun.com/app/seller-hj-empty.png';  
118 -// // }  
119 -// Utils.setBarStatus(false, color: Colors.black);  
120 -// dynamic result = await showGeneralDialog(  
121 -// context: context,  
122 -// barrierDismissible: false,  
123 -// // barrierColor: Colors.red,  
124 -// barrierLabel:  
125 -// MaterialLocalizations.of(context).modalBarrierDismissLabel,  
126 -// transitionDuration: const Duration(milliseconds: 150),  
127 -// pageBuilder: (BuildContext context, Animation animation,  
128 -// Animation secondaryAnimation) {  
129 -// Widget child = Stack(  
130 -// alignment: Alignment.bottomCenter,  
131 -// children: <Widget>[  
132 -// PhotoPreview(  
133 -// initialIndex: index,  
134 -// photoList: imgs,  
135 -// isShow: isShow,  
136 -// dashName: dashName,  
137 -// needMask: false,  
138 -// needTap: false,  
139 -// callback: (curruntIndex) {  
140 -// //选中某个模版  
141 -// // callback(curruntIndex);  
142 -// },  
143 -// ),  
144 -// // Positioned(  
145 -// // bottom: w(20),  
146 -// // child: InkWell(  
147 -// // onTap: () {  
148 -// // callback(index);  
149 -// // },  
150 -// // child: Container(  
151 -// // padding: EdgeInsets.symmetric(  
152 -// // horizontal: w(30), vertical: w(10)),  
153 -// // decoration: BoxDecoration(  
154 -// // color: MyColours.color_ffffff,  
155 -// // borderRadius: BorderRadius.circular(r(30)),  
156 -// // ),  
157 -// // child: Text(  
158 -// // '应用',  
159 -// // style: TextStyle(  
160 -// // decoration: TextDecoration.none,  
161 -// // color: MyColours.color_515151,  
162 -// // fontSize: font(16)),  
163 -// // ),  
164 -// // ),  
165 -// // ))  
166 -// ],  
167 -// );  
168 -// return Material(child: child);  
169 -// });  
170 -// Utils.setBarStatus(true, color: Colors.white);  
171 -// }  
172 -  
173 -// @override  
174 -// Widget build(BuildContext context) {  
175 -// marketingCenterProvider =  
176 -// Provider.of<MarketingCenterProvider>(context, listen: true);  
177 -// return Scaffold(  
178 -// backgroundColor: MyColours.color_ffffff,  
179 -// appBar: SystemAppBar('客户通知设置'),  
180 -// body: Column(  
181 -// children: [  
182 -// Expanded(  
183 -// child: SingleChildScrollView(  
184 -// child: Column(  
185 -// children: [  
186 -// InkWell(  
187 -// onTap: () {  
188 -// DialogUtil.showThemeColorSelectDialogNew(  
189 -// context, themeSunModel.colors, callback: (object) {  
190 -// print(object);  
191 -// setState(() {  
192 -// themeColor = object;  
193 -// url = themeSunModel  
194 -// .colors[themeSunModel.colors.indexWhere(  
195 -// (element) => element.colorName == object)]  
196 -// .url;  
197 -// });  
198 -// });  
199 -// },  
200 -// child: Padding(  
201 -// padding: EdgeInsets.only(  
202 -// left: w(16), top: w(12), bottom: w(12), right: w(24)),  
203 -// child: Row(  
204 -// mainAxisAlignment: MainAxisAlignment.spaceBetween,  
205 -// children: [  
206 -// Text(  
207 -// '主题颜色选择',  
208 -// style: TextStyle(  
209 -// color: MyColours.color_515151,  
210 -// fontSize: font(16)),  
211 -// ),  
212 -// Spacer(),  
213 -// Text(  
214 -// themeColor??'',  
215 -// style: TextStyle(  
216 -// color: themeColor == '当前主题不可用'  
217 -// ? MyColours.color_BFC4D4  
218 -// : MyColours.color_515151,  
219 -// fontSize: font(16)),  
220 -// ),  
221 -// Container(  
222 -// padding: EdgeInsets.symmetric(  
223 -// horizontal: w(11), vertical: w(4)),  
224 -// child: Image.asset(  
225 -// "assets/arrow_right_new.png",  
226 -// width: w(9),  
227 -// height: w(16),  
228 -// ),  
229 -// )  
230 -// // RoundButton(  
231 -// // text: '预览',  
232 -// // gradientStart: MyColours.color_ffffff,  
233 -// // gradientEnd: MyColours.color_ffffff,  
234 -// // borderColor: MyColours.color_438E93,  
235 -// // textColor: MyColours.color_438E93,  
236 -// // radius: ScreenUtil().setWidth(22),  
237 -// // fontSize: 24,  
238 -// // width: w(72),  
239 -// // height: ScreenUtil().setWidth(44),  
240 -// // isBold: true,  
241 -// // onPressed: () {  
242 -// // NavigatorUtil.goMarkingPreviewPage(context);  
243 -// // },  
244 -// // ),  
245 -// ]))),  
246 -// Padding(  
247 -// padding: EdgeInsets.only(left: w(16)),  
248 -// child: MyDivider(double.infinity, w(0.5),  
249 -// color: MyColours.color_E7E7E7)),  
250 -// // VEmptyView(24),  
251 -// InkWell(  
252 -// onTap: () {},  
253 -// child: Padding(  
254 -// padding: EdgeInsets.only(  
255 -// left: w(16), top: w(12), bottom: w(12), right: w(16)),  
256 -// child: Row(  
257 -// mainAxisAlignment: MainAxisAlignment.spaceBetween,  
258 -// children: [  
259 -// Text(  
260 -// '介绍模块标题样式',  
261 -// style: TextStyle(  
262 -// color: MyColours.color_515151,  
263 -// fontSize: font(16)),  
264 -// ),  
265 -// Spacer(),  
266 -// Text(  
267 -// '当前主题不可用',  
268 -// style: TextStyle(  
269 -// color: themeTitle == '当前主题不可用'  
270 -// ? MyColours.color_BFC4D4  
271 -// : MyColours.color_515151,  
272 -// fontSize: font(16)),  
273 -// ),  
274 -// Container(  
275 -// padding: EdgeInsets.symmetric(  
276 -// horizontal: w(11), vertical: w(4)),  
277 -// child: Image.asset(  
278 -// "assets/arrow_right_new.png",  
279 -// width: w(9),  
280 -// height: w(16),  
281 -// ),  
282 -// )  
283 -// // RoundButton(  
284 -// // text: '预览',  
285 -// // gradientStart: MyColours.color_ffffff,  
286 -// // gradientEnd: MyColours.color_ffffff,  
287 -// // borderColor: MyColours.color_438E93,  
288 -// // textColor: MyColours.color_438E93,  
289 -// // radius: ScreenUtil().setWidth(22),  
290 -// // fontSize: 24,  
291 -// // width: w(72),  
292 -// // height: ScreenUtil().setWidth(44),  
293 -// // isBold: true,  
294 -// // onPressed: () {  
295 -// // NavigatorUtil.goMarkingPreviewPage(context);  
296 -// // },  
297 -// // ),  
298 -// ]))),  
299 -// Padding(  
300 -// padding: EdgeInsets.only(left: w(16)),  
301 -// child: MyDivider(double.infinity, w(0.5),  
302 -// color: MyColours.color_E7E7E7)),  
303 -// Container(  
304 -// width: double.infinity,  
305 -// alignment: Alignment.centerLeft,  
306 -// padding: EdgeInsets.only(  
307 -// left: w(16), top: w(12), bottom: w(12), right: w(16)),  
308 -// child: Text(  
309 -// '通知主题选择(左右滑动选择要使用的主题)',  
310 -// style: TextStyle(  
311 -// color: MyColours.color_515151, fontSize: font(16)),  
312 -// )),  
313 -// VEmptyView(24),  
314 -// Swiper(  
315 -  
316 -// itemBuilder: (BuildContext context,int index){  
317 -// return Image.network("http://nosqn.colorcun.com/app/seller-hj-empty.png",fit: BoxFit.fill,);  
318 -// },  
319 -// itemCount: 3,  
320 -// pagination: SwiperPagination(),  
321 -// control: SwiperControl(),  
322 -// ),  
323 -// // GestureDetector(  
324 -// // onScaleUpdate: _onScaleUpdate,  
325 -// // child: Transform(  
326 -// // alignment: Alignment.center,  
327 -// // transform: Matrix4.identity()  
328 -// // ..translate(_panOffset.dx, _panOffset.dy)  
329 -// // ..scale(_scale),  
330 -// // child: Image.network(  
331 -// // 'http://nosqn.colorcun.com/app/seller-hj-empty.png',  
332 -// // fit: BoxFit.contain,  
333 -// // ),  
334 -// // ),  
335 -// // ),  
336 -// // InkWell(  
337 -// // onTap: () {  
338 -// // _showPhotoView(context, 0, [url]);  
339 -// // },  
340 -// // child: CachedNetworkImage(  
341 -// // imageUrl: url,  
342 -// // width: ScreenUtil().screenWidth - w(32),  
343 -// // fit: BoxFit.fitWidth,  
344 -// // alignment: Alignment.topCenter,  
345 -// // )),  
346 -// ],  
347 -// ))),  
348 -// Container(  
349 -// padding: EdgeInsets.only(  
350 -// top: w(12), bottom: w(25), left: w(45), right: w(45)),  
351 -// child: RoundButton(  
352 -// onPressed: () async {  
353 -// //接口成功后刷新并返回前一页  
354 -// //接口  
355 -  
356 -// Map<String, String> params = {  
357 -// 'sid': Provider.of<UserModel>(context, listen: false)  
358 -// .user  
359 -// .sellerid,  
360 -// 'type': themeType,  
361 -// 'lite_class': themeColor == null  
362 -// ? null  
363 -// : themeSunModel  
364 -// .colors[themeSunModel.colors.indexWhere(  
365 -// (element) => element.colorName == themeColor)]  
366 -// .liteClass  
367 -// };  
368 -  
369 -// bool success = await marketingCenterProvider  
370 -// .setSellerTemplateConf(context, params,  
371 -// showLoading: true);  
372 -// if (success) {  
373 -// Utils.showToast('设置成功');  
374 -// //选择当前模版+主题色  
375 -// bus.emit('theme_color_type', {  
376 -// 'themeColor': themeColor,  
377 -// 'themeType': themeType,  
378 -// });  
379 -// Navigator.pop(context);  
380 -// }  
381 -// },  
382 -// text: '确定',  
383 -// fontSize: 32,  
384 -// isBold: true,  
385 -// textColor: MyColours.color_F8F9FD,  
386 -// height: ScreenUtil().setWidth(43 * 2),  
387 -// // width: ScreenUtil().setWidth(130 * 2),  
388 -// radius: ScreenUtil().setWidth(10),  
389 -// )),  
390 -// ],  
391 -// ),  
392 -// );  
393 -// }  
394 -// }  
  1 +// import 'package:cached_network_image/cached_network_image.dart';
  2 +// import 'package:flutter/material.dart';
  3 +// import 'package:flutter_screenutil/flutter_screenutil.dart';
  4 +// import 'package:one_key/models/seller_template_color_list_model.dart';
  5 +// import 'package:one_key/pages/my/marketing_center/theme_model.dart';
  6 +// import 'package:one_key/route/navigator_util.dart';
  7 +// import 'package:one_key/widgets/system_app_bar.dart';
  8 +// import 'package:one_key/widgets/v_empty_view.dart';
  9 +// import 'package:provider/provider.dart';
  10 +
  11 +// import '../../../constant/state.dart';
  12 +// import '../../../provider/marketing_center_provider.dart';
  13 +// import '../../../res/colors.dart';
  14 +// import '../../../utils/dialog_util.dart';
  15 +// import '../../../utils/event_bus.dart';
  16 +// import '../../../utils/screen_util.dart';
  17 +// import '../../../utils/utils.dart';
  18 +// import '../../../widgets/MyDivider.dart';
  19 +// import '../../../widgets/page_exception.dart';
  20 +// import '../../online_check/photo_view_wiget.dart';
  21 +
  22 +// import 'dart:convert' as convert;
  23 +
  24 +// /**
  25 +// *
  26 +// * 邀请函主题选择页面
  27 +// */
  28 +
  29 +// class InvitationThemeHomePage extends StatefulWidget {
  30 +// InvitationThemeHomePage({Key key}) : super(key: key);
  31 +
  32 +// @override
  33 +// _InvitationThemeHomePageState createState() =>
  34 +// _InvitationThemeHomePageState();
  35 +// }
  36 +
  37 +// class _InvitationThemeHomePageState extends State<InvitationThemeHomePage> {
  38 +// ScrollController controller = ScrollController();
  39 +
  40 +// MarketingCenterProvider marketingCenterProvider;
  41 +
  42 +// //当前店铺选中的颜色和板式
  43 +
  44 +// String themeColor;
  45 +// String themeType = '1'; //模版类型
  46 +// // int indexSelectColor = 0; //选中第几个模版 (有配色选中index)
  47 +// // int indexSelectNoColor = 0; //选中第几个模版 (无配色选中index)
  48 +// // List<ThemeSunModel> marketingCenterProvider.templeteDatas = [];
  49 +
  50 +// // ThemeModel themeModelCurrunt; //有配色对应的当前页面模版数据
  51 +
  52 +// @override
  53 +// void initState() {
  54 +// super.initState();
  55 +
  56 +// WidgetsBinding.instance.addPostFrameCallback((_) {
  57 +// _getThemeData();
  58 +// bus.on("theme_color_type", (arg) {
  59 +// themeColor = arg['themeColor'];
  60 +// themeType = arg['themeType'];
  61 +// SellerTemplateColorListSunModel themeSunModel =
  62 +// marketingCenterProvider.templeteDatas[marketingCenterProvider
  63 +// .templeteDatas
  64 +// .indexWhere((element) => element.id == themeType)];
  65 +// themeSunModel.themeColorDefault = themeColor;
  66 +// bus.emit('theme_color_type_name', {
  67 +// 'templateName': themeSunModel.templateName,
  68 +// 'url': themeSunModel.colors.length == 0
  69 +// ? themeSunModel.url
  70 +// : themeSunModel
  71 +// .colors[themeSunModel.colors
  72 +// .indexWhere((element) => element.colorName == themeColor)]
  73 +// .url
  74 +// });
  75 +// setState(() {});
  76 +// });
  77 +// });
  78 +// }
  79 +
  80 +// @override
  81 +// void dispose() {
  82 +// bus.off('theme_color_type');
  83 +// super.dispose();
  84 +// }
  85 +
  86 +// _getThemeData() async {
  87 +// Future.wait<bool>(
  88 +// [_getSellerTemplateColorList(), getSellerTemplateConf(context)])
  89 +// .then((results) async {
  90 +// print(results[0]);
  91 +// if (results[0] && results[1]) {
  92 +// //成功
  93 +// marketingCenterProvider.pageStateThemeHome = PageState.Success;
  94 +// int index = marketingCenterProvider.templeteDatas.indexWhere(
  95 +// (element) =>
  96 +// element.id == marketingCenterProvider.markDataModel.type);
  97 +// themeType = marketingCenterProvider.templeteDatas[index].id;
  98 +
  99 +// List<ColorListModel> colors =
  100 +// marketingCenterProvider.templeteDatas[index].colors;
  101 +// themeColor = colors[colors.indexWhere((element) =>
  102 +// element.liteClass ==
  103 +// marketingCenterProvider.markDataModel.liteClass)]
  104 +// .colorName;
  105 +// marketingCenterProvider.templeteDatas[index].themeColorDefault =
  106 +// themeColor;
  107 +
  108 +// setState(() {});
  109 +// } else {
  110 +// marketingCenterProvider.pageStateThemeHome =
  111 +// PageState.ConnectivityError;
  112 +// // if (!results[0]) {
  113 +// // //没有优惠券
  114 +// // } else {}
  115 +// // if (!results[1]) {
  116 +// // //没有营销中心数据
  117 +// // } else {}
  118 +// setState(() {});
  119 +// }
  120 +// }).catchError((e) {
  121 +// print(e);
  122 +// });
  123 +// }
  124 +
  125 +// Future<bool> getSellerTemplateConf(BuildContext context) async {
  126 +// bool success = await marketingCenterProvider.getSellerTemplateConf(context);
  127 +// if (success &&
  128 +// marketingCenterProvider.markDataModel != null &&
  129 +// marketingCenterProvider.markDataModel.type != '') {
  130 +// return true;
  131 +// } else {
  132 +// return false;
  133 +// }
  134 +// }
  135 +
  136 +// ///获取后台配置的模版数据
  137 +// Future<bool> _getSellerTemplateColorList() async {
  138 +// bool success =
  139 +// await marketingCenterProvider.getSellerTemplateColorList(context);
  140 +// if (success) {
  141 +// return true;
  142 +// }
  143 +// return false;
  144 +// }
  145 +
  146 +// _showPhotoView(BuildContext context, int index, List<String> imgs,
  147 +// CustomCallBack callback,
  148 +// {isShow = false, List dashName}) async {
  149 +// // if (imgs.length == 1 &&
  150 +// // imgs[0] ==
  151 +// // 'http://nosqn.colorcun.com/custom/lite-online/image/def-banner.png') {
  152 +// // imgs[0] = 'http://nosqn.colorcun.com/app/seller-hj-empty.png';
  153 +// // }
  154 +// Utils.setBarStatus(false, color: Colors.black);
  155 +// dynamic result = await showGeneralDialog(
  156 +// context: context,
  157 +// barrierDismissible: false,
  158 +// // barrierColor: Colors.red,
  159 +// barrierLabel:
  160 +// MaterialLocalizations.of(context).modalBarrierDismissLabel,
  161 +// transitionDuration: const Duration(milliseconds: 150),
  162 +// pageBuilder: (BuildContext context, Animation animation,
  163 +// Animation secondaryAnimation) {
  164 +// Widget child = Stack(
  165 +// alignment: Alignment.bottomCenter,
  166 +// children: <Widget>[
  167 +// PhotoPreview(
  168 +// initialIndex: index,
  169 +// photoList: imgs,
  170 +// isShow: isShow,
  171 +// dashName: dashName,
  172 +// needMask: false,
  173 +// needTap: false,
  174 +// callback: (curruntIndex) {
  175 +// //选中某个模版
  176 +// callback(curruntIndex);
  177 +// },
  178 +// ),
  179 +// // Positioned(
  180 +// // bottom: w(20),
  181 +// // child: InkWell(
  182 +// // onTap: () {
  183 +// // callback(index);
  184 +// // },
  185 +// // child: Container(
  186 +// // padding: EdgeInsets.symmetric(
  187 +// // horizontal: w(30), vertical: w(10)),
  188 +// // decoration: BoxDecoration(
  189 +// // color: MyColours.color_ffffff,
  190 +// // borderRadius: BorderRadius.circular(r(30)),
  191 +// // ),
  192 +// // child: Text(
  193 +// // '应用',
  194 +// // style: TextStyle(
  195 +// // decoration: TextDecoration.none,
  196 +// // color: MyColours.color_515151,
  197 +// // fontSize: font(16)),
  198 +// // ),
  199 +// // ),
  200 +// // ))
  201 +// ],
  202 +// );
  203 +// return Material(child: child);
  204 +// });
  205 +// Utils.setBarStatus(true, color: Colors.white);
  206 +// }
  207 +
  208 +// List<Widget> imagesWidgets() {
  209 +// List<Widget> images = [];
  210 +// for (int i = 0; i < marketingCenterProvider.templeteDatas.length; i++) {
  211 +// SellerTemplateColorListSunModel themeSunModel =
  212 +// marketingCenterProvider.templeteDatas[i];
  213 +// images.add(InkWell(
  214 +// onTap: () {
  215 +// // _selectTheme(themeDatas[themeColor].urls[index].id);
  216 +// //跳转到下一页
  217 +// NavigatorUtil.goInvitationThemeHomePreviewPage(
  218 +// context, themeSunModel);
  219 +// },
  220 +// child: Container(
  221 +// width: (ScreenUtil().screenWidth - w(32) - w(15)) / 2,
  222 +// // height: w(390),
  223 +// margin: EdgeInsets.only(right: i % 2 == 0 ? w(15) : 0),
  224 +// decoration: BoxDecoration(
  225 +// borderRadius: BorderRadius.circular(r(10)),
  226 +// border: Border.all(
  227 +// color: themeType == themeSunModel.id
  228 +// ? MyColours.color_005AA7
  229 +// : MyColours.color_DBDBDB,
  230 +// width: themeType == themeSunModel.id ? w(2) : w(1))),
  231 +// child: Column(
  232 +// children: [
  233 +// // VEmptyView(10),
  234 +// ClipRRect(
  235 +// borderRadius: BorderRadius.only(
  236 +// topLeft: Radius.circular(r(8)),
  237 +// topRight: Radius.circular(r(8))),
  238 +// child: CachedNetworkImage(
  239 +// imageUrl: themeSunModel.colors == null ||
  240 +// themeSunModel.colors.length == 0
  241 +// ? themeSunModel.url
  242 +// : themeSunModel
  243 +// .colors[themeColor == null
  244 +// ? 0
  245 +// : themeSunModel.colors.indexWhere((element) =>
  246 +// element.colorName ==
  247 +// themeSunModel.themeColorDefault)]
  248 +// .url,
  249 +// width: (ScreenUtil().screenWidth - w(32) - w(15)) / 2,
  250 +// height: w(348),
  251 +// fit: BoxFit.fitWidth,
  252 +// alignment: Alignment.topCenter,
  253 +// ),
  254 +// ),
  255 +// VEmptyView(20),
  256 +// Container(
  257 +// padding:
  258 +// EdgeInsets.symmetric(vertical: w(7), horizontal: w(3)),
  259 +// width: double.infinity,
  260 +// child: Text(
  261 +// themeSunModel.templateName,
  262 +// maxLines: 1,
  263 +// overflow: TextOverflow.ellipsis,
  264 +// textAlign: TextAlign.left,
  265 +// style: TextStyle(
  266 +// color: MyColours.color_000000, fontSize: font(14)),
  267 +// ),
  268 +// )
  269 +// ],
  270 +// ),
  271 +// )));
  272 +// }
  273 +// marketingCenterProvider.templeteDatas.forEach((themeSunModel) {});
  274 +// return images;
  275 +// }
  276 +
  277 +// @override
  278 +// Widget build(BuildContext context) {
  279 +// marketingCenterProvider =
  280 +// Provider.of<MarketingCenterProvider>(context, listen: true);
  281 +// return Scaffold(
  282 +// backgroundColor: MyColours.color_ffffff,
  283 +// appBar: SystemAppBar('客户通知设置'),
  284 +// body: Consumer<MarketingCenterProvider>(builder: (context1, model, _) {
  285 +// if (model.pageStateThemeHome != PageState.Success) {
  286 +// return ExceptionPage(
  287 +// pageState: model.pageStateThemeHome,
  288 +// callback: () async {},
  289 +// emptyMsg: "暂时没有预订信息展示哦",
  290 +// emptyImg: "empty_search",
  291 +// showMsg: "加载中,请稍后...",
  292 +// );
  293 +// } else {
  294 +// return Column(
  295 +// children: [
  296 +// Expanded(
  297 +// child: SingleChildScrollView(
  298 +// child: Column(
  299 +// children: [
  300 +// VEmptyView(24),
  301 +// Padding(
  302 +// padding: EdgeInsets.symmetric(horizontal: w(16)),
  303 +// child: Wrap(
  304 +// runSpacing: w(15),
  305 +// // spacing: w(15),
  306 +// children: imagesWidgets(),
  307 +// )),
  308 +// VEmptyView(24),
  309 +// // GridView.builder(
  310 +// // padding: EdgeInsets.symmetric(horizontal: w(16)),
  311 +// // controller: controller,
  312 +// // // padding: EdgeInsets.only(top: ScreenUtil().getAdapterSize(10)),
  313 +// // shrinkWrap: true,
  314 +// // itemCount: marketingCenterProvider.templeteDatas.length,
  315 +// // //SliverGridDelegateWithFixedCrossAxisCount 构建一个横轴固定数量Widget
  316 +// // gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
  317 +// // //横轴元素个数
  318 +// // crossAxisCount: 2,
  319 +// // //纵轴间距
  320 +// // mainAxisSpacing: w(15),
  321 +// // //横轴间距
  322 +// // crossAxisSpacing: w(15),
  323 +// // //子组件宽高长度比例
  324 +// // // childAspectRatio:
  325 +// // // (ScreenUtil().screenWidth - w(62)) / 2 / 370
  326 +// // ),
  327 +// // itemBuilder: (BuildContext context, int index) {
  328 +// // SellerTemplateColorListSunModel themeSunModel =
  329 +// // marketingCenterProvider.templeteDatas[index];
  330 +// // return InkWell(
  331 +// // onTap: () {
  332 +// // // _selectTheme(themeDatas[themeColor].urls[index].id);
  333 +// // //跳转到下一页
  334 +// // NavigatorUtil.goInvitationThemeHomePreviewPage(
  335 +// // context, themeSunModel);
  336 +// // },
  337 +// // child: Container(
  338 +// // height: w(385),
  339 +// // decoration: BoxDecoration(
  340 +// // borderRadius: BorderRadius.circular(r(10)),
  341 +// // border: Border.all(
  342 +// // color: themeType == themeSunModel.id
  343 +// // ? MyColours.color_005AA7
  344 +// // : MyColours.color_DBDBDB,
  345 +// // width: themeType == themeSunModel.id
  346 +// // ? w(2)
  347 +// // : w(1))),
  348 +// // child: Column(
  349 +// // children: [
  350 +// // VEmptyView(10),
  351 +// // CachedNetworkImage(
  352 +// // imageUrl: themeSunModel.colors == null ||
  353 +// // themeSunModel.colors.length == 0
  354 +// // ? themeSunModel.url
  355 +// // : themeSunModel
  356 +// // .colors[themeColor == null
  357 +// // ? 0
  358 +// // : themeSunModel.colors
  359 +// // .indexWhere((element) =>
  360 +// // element.colorName ==
  361 +// // themeSunModel
  362 +// // .themeColorDefault)]
  363 +// // .url,
  364 +// // width:
  365 +// // (ScreenUtil().screenWidth - w(62)) / 2,
  366 +// // height: w(348),
  367 +// // fit: BoxFit.fitWidth,
  368 +// // alignment: Alignment.topCenter,
  369 +// // ),
  370 +// // VEmptyView(20),
  371 +// // Container(
  372 +// // padding: EdgeInsets.symmetric(
  373 +// // vertical: w(6), horizontal: w(2)),
  374 +// // width: double.infinity,
  375 +// // child: Text(
  376 +// // themeSunModel.templateName,
  377 +// // maxLines: 1,
  378 +// // overflow: TextOverflow.ellipsis,
  379 +// // textAlign: TextAlign.left,
  380 +// // style: TextStyle(
  381 +// // color: MyColours.color_000000,
  382 +// // fontSize: font(14)),
  383 +// // ),
  384 +// // )
  385 +// // ],
  386 +// // ),
  387 +// // ));
  388 +// // }),
  389 +// ],
  390 +// )))
  391 +// ],
  392 +// );
  393 +// }
  394 +// }),
  395 +// );
  396 +// }
  397 +// }
@@ -141,6 +141,7 @@ class _StoreBaseInfoPageState extends State<StoreBaseInfoPage> { @@ -141,6 +141,7 @@ class _StoreBaseInfoPageState extends State<StoreBaseInfoPage> {
141 @override 141 @override
142 void dispose() { 142 void dispose() {
143 EventBus().emit('changeStatusColor'); 143 EventBus().emit('changeStatusColor');
  144 + _uploadImageProvider.mentou = UploadImgModel();
144 super.dispose(); 145 super.dispose();
145 } 146 }
146 147
@@ -107,6 +107,8 @@ class _BaseInfoPageSimState extends State<BaseInfoPageSim> { @@ -107,6 +107,8 @@ class _BaseInfoPageSimState extends State<BaseInfoPageSim> {
107 @override 107 @override
108 void dispose() { 108 void dispose() {
109 EventBus().emit('changeStatusColor'); 109 EventBus().emit('changeStatusColor');
  110 + _uploadImageProvider.touxiang = UploadImgModel(); //头像
  111 + _uploadImageProvider.erweima = UploadImgModel(); //二维码
110 super.dispose(); 112 super.dispose();
111 } 113 }
112 114
@@ -144,6 +144,7 @@ class _BookInfoPageSimState extends State<BookInfoPageSim> { @@ -144,6 +144,7 @@ class _BookInfoPageSimState extends State<BookInfoPageSim> {
144 @override 144 @override
145 void dispose() { 145 void dispose() {
146 _uploadImageProvider.firstImage = UploadImgModel(); 146 _uploadImageProvider.firstImage = UploadImgModel();
  147 + _uploadImageProvider.logo = UploadImgModel();
147 super.dispose(); 148 super.dispose();
148 } 149 }
149 150
@@ -141,6 +141,7 @@ class _StoreBaseInfoPageSimState extends State<StoreBaseInfoPageSim> { @@ -141,6 +141,7 @@ class _StoreBaseInfoPageSimState extends State<StoreBaseInfoPageSim> {
141 @override 141 @override
142 void dispose() { 142 void dispose() {
143 EventBus().emit('changeStatusColor'); 143 EventBus().emit('changeStatusColor');
  144 + _uploadImageProvider.mentou = UploadImgModel();
144 super.dispose(); 145 super.dispose();
145 } 146 }
146 147
@@ -61,6 +61,8 @@ class UploadImageProvider extends ChangeNotifier { @@ -61,6 +61,8 @@ class UploadImageProvider extends ChangeNotifier {
61 dish.process = 0.01; 61 dish.process = 0.01;
62 } 62 }
63 63
  64 +
  65 +
64 /// 获取七牛上传token信息 66 /// 获取七牛上传token信息
65 Future<QiniuInfoSunModel> getQiniuInfo( 67 Future<QiniuInfoSunModel> getQiniuInfo(
66 BuildContext context, Map<String, String> params, 68 BuildContext context, Map<String, String> params,
@@ -226,7 +226,8 @@ import '../pages/my/marketing_center/book_notification/store_introduce_page.dart @@ -226,7 +226,8 @@ import '../pages/my/marketing_center/book_notification/store_introduce_page.dart
226 import '../pages/my/marketing_center/comments_setting_page.dart'; 226 import '../pages/my/marketing_center/comments_setting_page.dart';
227 import '../pages/my/marketing_center/customer_notice_setting_page.dart'; 227 import '../pages/my/marketing_center/customer_notice_setting_page.dart';
228 import '../pages/my/marketing_center/invitation_theme_home_page.dart'; 228 import '../pages/my/marketing_center/invitation_theme_home_page.dart';
229 -import '../pages/my/marketing_center/invitation_theme_home_page_new.dart'; 229 +
  230 +
230 import '../pages/my/marketing_center/invitation_theme_home_preview_page.dart'; 231 import '../pages/my/marketing_center/invitation_theme_home_preview_page.dart';
231 import '../pages/my/marketing_center/marketing_center_home_page.dart'; 232 import '../pages/my/marketing_center/marketing_center_home_page.dart';
232 import '../pages/my/marketing_center/order_setting_manager_page.dart'; 233 import '../pages/my/marketing_center/order_setting_manager_page.dart';
@@ -683,6 +683,13 @@ packages: @@ -683,6 +683,13 @@ packages:
683 url: "https://pub.flutter-io.cn" 683 url: "https://pub.flutter-io.cn"
684 source: hosted 684 source: hosted
685 version: "0.0.6+1" 685 version: "0.0.6+1"
  686 + flutter_page_indicator:
  687 + dependency: transitive
  688 + description:
  689 + name: flutter_page_indicator
  690 + url: "https://pub.flutter-io.cn"
  691 + source: hosted
  692 + version: "0.0.3"
686 flutter_picker: 693 flutter_picker:
687 dependency: "direct main" 694 dependency: "direct main"
688 description: 695 description:
@@ -725,6 +732,13 @@ packages: @@ -725,6 +732,13 @@ packages:
725 url: "https://pub.flutter-io.cn" 732 url: "https://pub.flutter-io.cn"
726 source: hosted 733 source: hosted
727 version: "0.5.0" 734 version: "0.5.0"
  735 + flutter_swiper:
  736 + dependency: "direct main"
  737 + description:
  738 + name: flutter_swiper
  739 + url: "https://pub.flutter-io.cn"
  740 + source: hosted
  741 + version: "1.1.6"
728 flutter_test: 742 flutter_test:
729 dependency: "direct dev" 743 dependency: "direct dev"
730 description: flutter 744 description: flutter
@@ -1484,6 +1498,13 @@ packages: @@ -1484,6 +1498,13 @@ packages:
1484 url: "https://github.com/TencentCloud/TPNS-Flutter-Plugin.git" 1498 url: "https://github.com/TencentCloud/TPNS-Flutter-Plugin.git"
1485 source: git 1499 source: git
1486 version: "1.2.6" 1500 version: "1.2.6"
  1501 + transformer_page_view:
  1502 + dependency: transitive
  1503 + description:
  1504 + name: transformer_page_view
  1505 + url: "https://pub.flutter-io.cn"
  1506 + source: hosted
  1507 + version: "0.1.6"
1487 typed_data: 1508 typed_data:
1488 dependency: transitive 1509 dependency: transitive
1489 description: 1510 description:
@@ -144,6 +144,7 @@ dependencies: @@ -144,6 +144,7 @@ dependencies:
144 # image_picker: ^0.8.5+3 144 # image_picker: ^0.8.5+3
145 image_picker: ^0.8.6 145 image_picker: ^0.8.6
146 146
  147 +
147 #多图选择 148 #多图选择
148 # photo: ^0.4.8 149 # photo: ^0.4.8
149 # photo: 0.5.0-dev.3 150 # photo: 0.5.0-dev.3
@@ -249,6 +250,8 @@ dependencies: @@ -249,6 +250,8 @@ dependencies:
249 # workmanager: ^0.5.1 250 # workmanager: ^0.5.1
250 # flutter_wxwork: ^0.0.3 251 # flutter_wxwork: ^0.0.3
251 card_swiper: ^3.0.1 252 card_swiper: ^3.0.1
  253 + # flutter_card_swiper: ^6.1.0
  254 + flutter_swiper: ^1.1.6
252 255
253 256
254 257