├── .DS_Store
├── .gitignore
├── .idea
├── GHShopCart_flutter.iml
├── encodings.xml
├── libraries
│ ├── Dart_Packages.xml
│ ├── Dart_SDK.xml
│ └── Flutter_Plugins.xml
├── misc.xml
├── modules.xml
├── vcs.xml
└── workspace.xml
├── LICENSE
├── README.md
├── android
├── .gitignore
├── app
│ ├── build.gradle
│ └── src
│ │ ├── debug
│ │ └── AndroidManifest.xml
│ │ ├── main
│ │ ├── AndroidManifest.xml
│ │ ├── kotlin
│ │ │ └── com
│ │ │ │ └── example
│ │ │ │ └── ghshopcart_flutter
│ │ │ │ └── MainActivity.kt
│ │ └── res
│ │ │ ├── drawable
│ │ │ └── launch_background.xml
│ │ │ ├── mipmap-hdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-mdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxxhdpi
│ │ │ └── ic_launcher.png
│ │ │ └── values
│ │ │ └── styles.xml
│ │ └── profile
│ │ └── AndroidManifest.xml
├── build.gradle
├── ghshopcart_flutter_android.iml
├── gradle.properties
├── gradle
│ └── wrapper
│ │ └── gradle-wrapper.properties
└── settings.gradle
├── ghshopcart_flutter.iml
├── images
├── .DS_Store
├── 2.0x
│ ├── bg.png
│ ├── logo.png
│ ├── user.png
│ └── user_bg.jpg
├── 3.0x
│ ├── bg.png
│ ├── logo.png
│ ├── user.png
│ └── user_bg.jpg
├── bg.jpg
├── checkNormal.png
├── checkSelected.png
├── collect.png
├── customerService.png
├── down.png
├── downSeletecd.png
├── filter.png
├── filterSeletecd.png
├── goPublic.png
├── logo.png
├── price.png
├── screen.png
├── serviceIcon.png
├── shop.png
├── shoppingCart.png
├── thickness.png
├── up.png
├── upSeletecd.png
├── user.png
└── user_bg.jpg
├── ios
├── .DS_Store
├── .gitignore
├── Flutter
│ ├── AppFrameworkInfo.plist
│ ├── Debug.xcconfig
│ └── Release.xcconfig
├── Podfile
├── Podfile.lock
├── Runner.xcodeproj
│ ├── project.pbxproj
│ ├── project.xcworkspace
│ │ └── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── xcschemes
│ │ └── Runner.xcscheme
├── Runner.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
└── Runner
│ ├── AppDelegate.swift
│ ├── Assets.xcassets
│ ├── AppIcon.appiconset
│ │ ├── Contents.json
│ │ ├── Icon-App-1024x1024@1x.png
│ │ ├── Icon-App-20x20@1x.png
│ │ ├── Icon-App-20x20@2x.png
│ │ ├── Icon-App-20x20@3x.png
│ │ ├── Icon-App-29x29@1x.png
│ │ ├── Icon-App-29x29@2x.png
│ │ ├── Icon-App-29x29@3x.png
│ │ ├── Icon-App-40x40@1x.png
│ │ ├── Icon-App-40x40@2x.png
│ │ ├── Icon-App-40x40@3x.png
│ │ ├── Icon-App-60x60@2x.png
│ │ ├── Icon-App-60x60@3x.png
│ │ ├── Icon-App-76x76@1x.png
│ │ ├── Icon-App-76x76@2x.png
│ │ └── Icon-App-83.5x83.5@2x.png
│ └── LaunchImage.imageset
│ │ ├── Contents.json
│ │ ├── LaunchImage.png
│ │ ├── LaunchImage@2x.png
│ │ ├── LaunchImage@3x.png
│ │ └── README.md
│ ├── Base.lproj
│ ├── LaunchScreen.storyboard
│ └── Main.storyboard
│ ├── Info.plist
│ └── Runner-Bridging-Header.h
├── lib
├── .DS_Store
├── main.dart
├── model
│ ├── .DS_Store
│ ├── GHGoodDetailsModel.dart
│ └── GHHotGoodsModel.dart
├── pages
│ ├── .DS_Store
│ └── tabs
│ │ └── GHShopCart.dart
├── services
│ ├── ScreenAdaper.dart
│ └── httptool.dart
└── widget
│ ├── GHCountItemWidget.dart
│ └── LoadingWidget.dart
├── pubspec.yaml
└── test
└── widget_test.dart
/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/.DS_Store
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://www.dartlang.org/guides/libraries/private-files
2 |
3 | # Files and directories created by pub
4 | .dart_tool/
5 | .packages
6 | build/
7 | # If you're building an application, you may want to check-in your pubspec.lock
8 | pubspec.lock
9 | 购物车.psd
10 | # Directory created by dartdoc
11 | # If you don't generate documentation locally you can remove this line.
12 | doc/api/
13 |
14 | # Avoid committing generated Javascript files:
15 | *.dart.js
16 | *.info.json # Produced by the --dump-info flag.
17 | *.js # When generated by dart2js. Don't specify *.js if your
18 | # project includes source files written in JavaScript.
19 | *.js_
20 | *.js.deps
21 | *.js.map
22 |
23 | .flutter-plugins
24 | .flutter-plugins-dependencies
--------------------------------------------------------------------------------
/.idea/GHShopCart_flutter.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/.idea/encodings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/.idea/libraries/Dart_Packages.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
356 |
357 |
358 |
359 |
360 |
361 |
362 |
363 |
364 |
365 |
366 |
367 |
368 |
369 |
370 |
371 |
372 |
373 |
374 |
375 |
376 |
377 |
378 |
379 |
380 |
381 |
382 |
383 |
384 |
385 |
386 |
387 |
388 |
389 |
390 |
391 |
392 |
393 |
394 |
395 |
396 |
397 |
398 |
399 |
400 |
401 |
402 |
403 |
404 |
405 |
406 |
407 |
408 |
409 |
410 |
411 |
412 |
--------------------------------------------------------------------------------
/.idea/libraries/Dart_SDK.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/.idea/libraries/Flutter_Plugins.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.idea/workspace.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
187 |
188 |
189 |
190 |
191 |
192 |
193 |
194 |
195 |
196 |
197 |
198 |
199 |
200 |
201 | 1593271480254
202 |
203 |
204 | 1593271480254
205 |
206 |
207 |
208 |
209 |
210 |
211 |
212 |
213 |
214 |
215 |
216 |
217 |
218 |
219 |
220 |
221 |
222 |
223 |
224 |
225 |
226 |
227 |
228 |
229 |
230 |
231 |
232 |
233 |
234 |
235 |
236 |
237 |
238 |
239 |
240 |
241 |
242 |
243 |
244 |
245 |
246 |
247 |
248 |
249 |
250 |
251 |
252 |
253 |
254 |
255 |
256 |
257 |
258 |
259 |
260 |
261 |
262 |
263 |
264 |
265 |
266 |
267 |
268 |
269 |
270 |
271 |
272 |
273 |
274 |
275 |
276 |
277 |
278 |
279 |
280 |
281 |
282 |
283 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2020 GHome
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # GHShopCart
2 |
3 | **Flutter版:sunny::sunny: 购物车**
4 |
5 |
6 | **一个仿京东的购物车,Dart语言编写**
7 |
8 | ### 环境
9 |
10 | ```
11 | Flutter 1.12.13+hotfix.9 • channel stable •
12 |
13 | Dart 2.7.2
14 |
15 | Xcode 11.5
16 |
17 | Android Studio 3.4.1
18 | ```
19 |
20 | 
21 |
22 |
23 | ### 安装方法
24 |
25 | ```
26 | cd ~想要存储的文件路径
27 | git clone https://github.com/shabake/GHShopCart_flutter.git
28 | ```
29 | 克隆好项目后运行项目,运行`flutter run`会自动下载依赖包
30 |
31 | ```
32 | cd 项目路径
33 | flutter run
34 | ```
35 |
36 | ### 本demo仅做学习交流,不可作为商业用途,最后demo如果对你有帮助,帮忙点一个Star。如有任何问题,欢迎打扰45329453@qq.com
37 | ---
38 |
--------------------------------------------------------------------------------
/android/.gitignore:
--------------------------------------------------------------------------------
1 | gradle-wrapper.jar
2 | /.gradle
3 | /captures/
4 | /gradlew
5 | /gradlew.bat
6 | /local.properties
7 | GeneratedPluginRegistrant.java
8 |
--------------------------------------------------------------------------------
/android/app/build.gradle:
--------------------------------------------------------------------------------
1 | def localProperties = new Properties()
2 | def localPropertiesFile = rootProject.file('local.properties')
3 | if (localPropertiesFile.exists()) {
4 | localPropertiesFile.withReader('UTF-8') { reader ->
5 | localProperties.load(reader)
6 | }
7 | }
8 |
9 | def flutterRoot = localProperties.getProperty('flutter.sdk')
10 | if (flutterRoot == null) {
11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
12 | }
13 |
14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
15 | if (flutterVersionCode == null) {
16 | flutterVersionCode = '1'
17 | }
18 |
19 | def flutterVersionName = localProperties.getProperty('flutter.versionName')
20 | if (flutterVersionName == null) {
21 | flutterVersionName = '1.0'
22 | }
23 |
24 | apply plugin: 'com.android.application'
25 | apply plugin: 'kotlin-android'
26 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
27 |
28 | android {
29 | compileSdkVersion 28
30 |
31 | sourceSets {
32 | main.java.srcDirs += 'src/main/kotlin'
33 | }
34 |
35 | lintOptions {
36 | disable 'InvalidPackage'
37 | }
38 |
39 | defaultConfig {
40 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
41 | applicationId "com.example.ghshopcart_flutter"
42 | minSdkVersion 16
43 | targetSdkVersion 28
44 | versionCode flutterVersionCode.toInteger()
45 | versionName flutterVersionName
46 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
47 | }
48 |
49 | buildTypes {
50 | release {
51 | // TODO: Add your own signing config for the release build.
52 | // Signing with the debug keys for now, so `flutter run --release` works.
53 | signingConfig signingConfigs.debug
54 | }
55 | }
56 | }
57 |
58 | flutter {
59 | source '../..'
60 | }
61 |
62 | dependencies {
63 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
64 | testImplementation 'junit:junit:4.12'
65 | androidTestImplementation 'androidx.test:runner:1.1.1'
66 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
67 | }
68 |
--------------------------------------------------------------------------------
/android/app/src/debug/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
8 |
12 |
19 |
20 |
21 |
22 |
23 |
24 |
26 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/android/app/src/main/kotlin/com/example/ghshopcart_flutter/MainActivity.kt:
--------------------------------------------------------------------------------
1 | package com.example.ghshopcart_flutter
2 |
3 | import androidx.annotation.NonNull;
4 | import io.flutter.embedding.android.FlutterActivity
5 | import io.flutter.embedding.engine.FlutterEngine
6 | import io.flutter.plugins.GeneratedPluginRegistrant
7 |
8 | class MainActivity: FlutterActivity() {
9 | override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) {
10 | GeneratedPluginRegistrant.registerWith(flutterEngine);
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
12 |
13 |
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
8 |
9 |
--------------------------------------------------------------------------------
/android/app/src/profile/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | buildscript {
2 | ext.kotlin_version = '1.3.50'
3 | repositories {
4 | google()
5 | jcenter()
6 | }
7 |
8 | dependencies {
9 | classpath 'com.android.tools.build:gradle:3.5.0'
10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
11 | }
12 | }
13 |
14 | allprojects {
15 | repositories {
16 | google()
17 | jcenter()
18 | }
19 | }
20 |
21 | rootProject.buildDir = '../build'
22 | subprojects {
23 | project.buildDir = "${rootProject.buildDir}/${project.name}"
24 | }
25 | subprojects {
26 | project.evaluationDependsOn(':app')
27 | }
28 |
29 | task clean(type: Delete) {
30 | delete rootProject.buildDir
31 | }
32 |
--------------------------------------------------------------------------------
/android/ghshopcart_flutter_android.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/android/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx1536M
2 | android.enableR8=true
3 | android.useAndroidX=true
4 | android.enableJetifier=true
5 |
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Fri Jun 23 08:50:38 CEST 2017
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip
7 |
--------------------------------------------------------------------------------
/android/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 |
3 | def flutterProjectRoot = rootProject.projectDir.parentFile.toPath()
4 |
5 | def plugins = new Properties()
6 | def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins')
7 | if (pluginsFile.exists()) {
8 | pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) }
9 | }
10 |
11 | plugins.each { name, path ->
12 | def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile()
13 | include ":$name"
14 | project(":$name").projectDir = pluginDirectory
15 | }
16 |
--------------------------------------------------------------------------------
/ghshopcart_flutter.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/images/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/.DS_Store
--------------------------------------------------------------------------------
/images/2.0x/bg.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/2.0x/bg.png
--------------------------------------------------------------------------------
/images/2.0x/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/2.0x/logo.png
--------------------------------------------------------------------------------
/images/2.0x/user.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/2.0x/user.png
--------------------------------------------------------------------------------
/images/2.0x/user_bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/2.0x/user_bg.jpg
--------------------------------------------------------------------------------
/images/3.0x/bg.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/3.0x/bg.png
--------------------------------------------------------------------------------
/images/3.0x/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/3.0x/logo.png
--------------------------------------------------------------------------------
/images/3.0x/user.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/3.0x/user.png
--------------------------------------------------------------------------------
/images/3.0x/user_bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/3.0x/user_bg.jpg
--------------------------------------------------------------------------------
/images/bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/bg.jpg
--------------------------------------------------------------------------------
/images/checkNormal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/checkNormal.png
--------------------------------------------------------------------------------
/images/checkSelected.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/checkSelected.png
--------------------------------------------------------------------------------
/images/collect.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/collect.png
--------------------------------------------------------------------------------
/images/customerService.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/customerService.png
--------------------------------------------------------------------------------
/images/down.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/down.png
--------------------------------------------------------------------------------
/images/downSeletecd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/downSeletecd.png
--------------------------------------------------------------------------------
/images/filter.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/filter.png
--------------------------------------------------------------------------------
/images/filterSeletecd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/filterSeletecd.png
--------------------------------------------------------------------------------
/images/goPublic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/goPublic.png
--------------------------------------------------------------------------------
/images/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/logo.png
--------------------------------------------------------------------------------
/images/price.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/price.png
--------------------------------------------------------------------------------
/images/screen.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/screen.png
--------------------------------------------------------------------------------
/images/serviceIcon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/serviceIcon.png
--------------------------------------------------------------------------------
/images/shop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/shop.png
--------------------------------------------------------------------------------
/images/shoppingCart.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/shoppingCart.png
--------------------------------------------------------------------------------
/images/thickness.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/thickness.png
--------------------------------------------------------------------------------
/images/up.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/up.png
--------------------------------------------------------------------------------
/images/upSeletecd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/upSeletecd.png
--------------------------------------------------------------------------------
/images/user.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/user.png
--------------------------------------------------------------------------------
/images/user_bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/images/user_bg.jpg
--------------------------------------------------------------------------------
/ios/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/.DS_Store
--------------------------------------------------------------------------------
/ios/.gitignore:
--------------------------------------------------------------------------------
1 | *.mode1v3
2 | *.mode2v3
3 | *.moved-aside
4 | *.pbxuser
5 | *.perspectivev3
6 | **/*sync/
7 | .sconsign.dblite
8 | .tags*
9 | **/.vagrant/
10 | **/DerivedData/
11 | Icon?
12 | **/Pods/
13 | **/.symlinks/
14 | profile
15 | xcuserdata
16 | **/.generated/
17 | Flutter/App.framework
18 | Flutter/Flutter.framework
19 | Flutter/Flutter.podspec
20 | Flutter/Generated.xcconfig
21 | Flutter/app.flx
22 | Flutter/app.zip
23 | Flutter/flutter_assets/
24 | Flutter/flutter_export_environment.sh
25 | ServiceDefinitions.json
26 | Runner/GeneratedPluginRegistrant.*
27 |
28 | # Exceptions to above rules.
29 | !default.mode1v3
30 | !default.mode2v3
31 | !default.pbxuser
32 | !default.perspectivev3
33 |
--------------------------------------------------------------------------------
/ios/Flutter/AppFrameworkInfo.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | App
9 | CFBundleIdentifier
10 | io.flutter.flutter.app
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | App
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1.0
23 | MinimumOSVersion
24 | 8.0
25 |
26 |
27 |
--------------------------------------------------------------------------------
/ios/Flutter/Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/ios/Flutter/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/ios/Podfile:
--------------------------------------------------------------------------------
1 | # Uncomment this line to define a global platform for your project
2 | # platform :ios, '9.0'
3 |
4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency.
5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true'
6 |
7 | project 'Runner', {
8 | 'Debug' => :debug,
9 | 'Profile' => :release,
10 | 'Release' => :release,
11 | }
12 |
13 | def parse_KV_file(file, separator='=')
14 | file_abs_path = File.expand_path(file)
15 | if !File.exists? file_abs_path
16 | return [];
17 | end
18 | generated_key_values = {}
19 | skip_line_start_symbols = ["#", "/"]
20 | File.foreach(file_abs_path) do |line|
21 | next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ }
22 | plugin = line.split(pattern=separator)
23 | if plugin.length == 2
24 | podname = plugin[0].strip()
25 | path = plugin[1].strip()
26 | podpath = File.expand_path("#{path}", file_abs_path)
27 | generated_key_values[podname] = podpath
28 | else
29 | puts "Invalid plugin specification: #{line}"
30 | end
31 | end
32 | generated_key_values
33 | end
34 |
35 | target 'Runner' do
36 | use_frameworks!
37 | use_modular_headers!
38 |
39 | # Flutter Pod
40 |
41 | copied_flutter_dir = File.join(__dir__, 'Flutter')
42 | copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework')
43 | copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec')
44 | unless File.exist?(copied_framework_path) && File.exist?(copied_podspec_path)
45 | # Copy Flutter.framework and Flutter.podspec to Flutter/ to have something to link against if the xcode backend script has not run yet.
46 | # That script will copy the correct debug/profile/release version of the framework based on the currently selected Xcode configuration.
47 | # CocoaPods will not embed the framework on pod install (before any build phases can generate) if the dylib does not exist.
48 |
49 | generated_xcode_build_settings_path = File.join(copied_flutter_dir, 'Generated.xcconfig')
50 | unless File.exist?(generated_xcode_build_settings_path)
51 | raise "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first"
52 | end
53 | generated_xcode_build_settings = parse_KV_file(generated_xcode_build_settings_path)
54 | cached_framework_dir = generated_xcode_build_settings['FLUTTER_FRAMEWORK_DIR'];
55 |
56 | unless File.exist?(copied_framework_path)
57 | FileUtils.cp_r(File.join(cached_framework_dir, 'Flutter.framework'), copied_flutter_dir)
58 | end
59 | unless File.exist?(copied_podspec_path)
60 | FileUtils.cp(File.join(cached_framework_dir, 'Flutter.podspec'), copied_flutter_dir)
61 | end
62 | end
63 |
64 | # Keep pod path relative so it can be checked into Podfile.lock.
65 | pod 'Flutter', :path => 'Flutter'
66 |
67 | # Plugin Pods
68 |
69 | # Prepare symlinks folder. We use symlinks to avoid having Podfile.lock
70 | # referring to absolute paths on developers' machines.
71 | system('rm -rf .symlinks')
72 | system('mkdir -p .symlinks/plugins')
73 | plugin_pods = parse_KV_file('../.flutter-plugins')
74 | plugin_pods.each do |name, path|
75 | symlink = File.join('.symlinks', 'plugins', name)
76 | File.symlink(path, symlink)
77 | pod name, :path => File.join(symlink, 'ios')
78 | end
79 | end
80 |
81 | # Prevent Cocoapods from embedding a second Flutter framework and causing an error with the new Xcode build system.
82 | install! 'cocoapods', :disable_input_output_paths => true
83 |
84 | post_install do |installer|
85 | installer.pods_project.targets.each do |target|
86 | target.build_configurations.each do |config|
87 | config.build_settings['ENABLE_BITCODE'] = 'NO'
88 | end
89 | end
90 | end
91 |
--------------------------------------------------------------------------------
/ios/Podfile.lock:
--------------------------------------------------------------------------------
1 | PODS:
2 | - city_pickers (0.0.1):
3 | - Flutter
4 | - Flutter (1.0.0)
5 | - flutter_webview_plugin (0.0.1):
6 | - Flutter
7 | - fluttertoast (0.0.2):
8 | - Flutter
9 | - FMDB (2.7.5):
10 | - FMDB/standard (= 2.7.5)
11 | - FMDB/standard (2.7.5)
12 | - shared_preferences (0.0.1):
13 | - Flutter
14 | - shared_preferences_macos (0.0.1):
15 | - Flutter
16 | - shared_preferences_web (0.0.1):
17 | - Flutter
18 | - sqflite (0.0.1):
19 | - Flutter
20 | - FMDB (~> 2.7.2)
21 |
22 | DEPENDENCIES:
23 | - city_pickers (from `.symlinks/plugins/city_pickers/ios`)
24 | - Flutter (from `Flutter`)
25 | - flutter_webview_plugin (from `.symlinks/plugins/flutter_webview_plugin/ios`)
26 | - fluttertoast (from `.symlinks/plugins/fluttertoast/ios`)
27 | - shared_preferences (from `.symlinks/plugins/shared_preferences/ios`)
28 | - shared_preferences_macos (from `.symlinks/plugins/shared_preferences_macos/ios`)
29 | - shared_preferences_web (from `.symlinks/plugins/shared_preferences_web/ios`)
30 | - sqflite (from `.symlinks/plugins/sqflite/ios`)
31 |
32 | SPEC REPOS:
33 | trunk:
34 | - FMDB
35 |
36 | EXTERNAL SOURCES:
37 | city_pickers:
38 | :path: ".symlinks/plugins/city_pickers/ios"
39 | Flutter:
40 | :path: Flutter
41 | flutter_webview_plugin:
42 | :path: ".symlinks/plugins/flutter_webview_plugin/ios"
43 | fluttertoast:
44 | :path: ".symlinks/plugins/fluttertoast/ios"
45 | shared_preferences:
46 | :path: ".symlinks/plugins/shared_preferences/ios"
47 | shared_preferences_macos:
48 | :path: ".symlinks/plugins/shared_preferences_macos/ios"
49 | shared_preferences_web:
50 | :path: ".symlinks/plugins/shared_preferences_web/ios"
51 | sqflite:
52 | :path: ".symlinks/plugins/sqflite/ios"
53 |
54 | SPEC CHECKSUMS:
55 | city_pickers: b0370f4c35c201723b5b7fcce10ec29b59d5bc35
56 | Flutter: 0e3d915762c693b495b44d77113d4970485de6ec
57 | flutter_webview_plugin: ed9e8a6a96baf0c867e90e1bce2673913eeac694
58 | fluttertoast: b644586ef3b16f67fae9a1f8754cef6b2d6b634b
59 | FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
60 | shared_preferences: af6bfa751691cdc24be3045c43ec037377ada40d
61 | shared_preferences_macos: f3f29b71ccbb56bf40c9dd6396c9acf15e214087
62 | shared_preferences_web: 141cce0c3ed1a1c5bf2a0e44f52d31eeb66e5ea9
63 | sqflite: 4001a31ff81d210346b500c55b17f4d6c7589dd0
64 |
65 | PODFILE CHECKSUM: 1b66dae606f75376c5f2135a8290850eeb09ae83
66 |
67 | COCOAPODS: 1.9.1
68 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
11 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
12 | 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; };
13 | 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
14 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
15 | 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; };
16 | 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
17 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
18 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
19 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
20 | F66070E84A4098C5BC7BE790 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 05F6E2770FB3408B0D5D25D5 /* Pods_Runner.framework */; };
21 | /* End PBXBuildFile section */
22 |
23 | /* Begin PBXCopyFilesBuildPhase section */
24 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = {
25 | isa = PBXCopyFilesBuildPhase;
26 | buildActionMask = 2147483647;
27 | dstPath = "";
28 | dstSubfolderSpec = 10;
29 | files = (
30 | 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */,
31 | 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */,
32 | );
33 | name = "Embed Frameworks";
34 | runOnlyForDeploymentPostprocessing = 0;
35 | };
36 | /* End PBXCopyFilesBuildPhase section */
37 |
38 | /* Begin PBXFileReference section */
39 | 05F6E2770FB3408B0D5D25D5 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
40 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; };
41 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; };
42 | 3585BE6017E0D216308E01D7 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; };
43 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; };
44 | 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = ""; };
45 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; };
46 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
47 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; };
48 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; };
49 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; };
50 | 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = ""; };
51 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
52 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
53 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
54 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
55 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
56 | C42C0C9C4D0B432E58AA1FC6 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; };
57 | F2CB862E846399A19D786FC2 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; };
58 | /* End PBXFileReference section */
59 |
60 | /* Begin PBXFrameworksBuildPhase section */
61 | 97C146EB1CF9000F007C117D /* Frameworks */ = {
62 | isa = PBXFrameworksBuildPhase;
63 | buildActionMask = 2147483647;
64 | files = (
65 | 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */,
66 | 3B80C3941E831B6300D905FE /* App.framework in Frameworks */,
67 | F66070E84A4098C5BC7BE790 /* Pods_Runner.framework in Frameworks */,
68 | );
69 | runOnlyForDeploymentPostprocessing = 0;
70 | };
71 | /* End PBXFrameworksBuildPhase section */
72 |
73 | /* Begin PBXGroup section */
74 | 38A096C2D308F07BF2EE247B /* Pods */ = {
75 | isa = PBXGroup;
76 | children = (
77 | F2CB862E846399A19D786FC2 /* Pods-Runner.debug.xcconfig */,
78 | C42C0C9C4D0B432E58AA1FC6 /* Pods-Runner.release.xcconfig */,
79 | 3585BE6017E0D216308E01D7 /* Pods-Runner.profile.xcconfig */,
80 | );
81 | name = Pods;
82 | path = Pods;
83 | sourceTree = "";
84 | };
85 | 4ED5B34AB31656B5DF203217 /* Frameworks */ = {
86 | isa = PBXGroup;
87 | children = (
88 | 05F6E2770FB3408B0D5D25D5 /* Pods_Runner.framework */,
89 | );
90 | name = Frameworks;
91 | sourceTree = "";
92 | };
93 | 9740EEB11CF90186004384FC /* Flutter */ = {
94 | isa = PBXGroup;
95 | children = (
96 | 3B80C3931E831B6300D905FE /* App.framework */,
97 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
98 | 9740EEBA1CF902C7004384FC /* Flutter.framework */,
99 | 9740EEB21CF90195004384FC /* Debug.xcconfig */,
100 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
101 | 9740EEB31CF90195004384FC /* Generated.xcconfig */,
102 | );
103 | name = Flutter;
104 | sourceTree = "";
105 | };
106 | 97C146E51CF9000F007C117D = {
107 | isa = PBXGroup;
108 | children = (
109 | 9740EEB11CF90186004384FC /* Flutter */,
110 | 97C146F01CF9000F007C117D /* Runner */,
111 | 97C146EF1CF9000F007C117D /* Products */,
112 | 38A096C2D308F07BF2EE247B /* Pods */,
113 | 4ED5B34AB31656B5DF203217 /* Frameworks */,
114 | );
115 | sourceTree = "";
116 | };
117 | 97C146EF1CF9000F007C117D /* Products */ = {
118 | isa = PBXGroup;
119 | children = (
120 | 97C146EE1CF9000F007C117D /* Runner.app */,
121 | );
122 | name = Products;
123 | sourceTree = "";
124 | };
125 | 97C146F01CF9000F007C117D /* Runner */ = {
126 | isa = PBXGroup;
127 | children = (
128 | 97C146FA1CF9000F007C117D /* Main.storyboard */,
129 | 97C146FD1CF9000F007C117D /* Assets.xcassets */,
130 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
131 | 97C147021CF9000F007C117D /* Info.plist */,
132 | 97C146F11CF9000F007C117D /* Supporting Files */,
133 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
134 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
135 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */,
136 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */,
137 | );
138 | path = Runner;
139 | sourceTree = "";
140 | };
141 | 97C146F11CF9000F007C117D /* Supporting Files */ = {
142 | isa = PBXGroup;
143 | children = (
144 | );
145 | name = "Supporting Files";
146 | sourceTree = "";
147 | };
148 | /* End PBXGroup section */
149 |
150 | /* Begin PBXNativeTarget section */
151 | 97C146ED1CF9000F007C117D /* Runner */ = {
152 | isa = PBXNativeTarget;
153 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
154 | buildPhases = (
155 | 40DCEB87593FA17D184A4E7B /* [CP] Check Pods Manifest.lock */,
156 | 9740EEB61CF901F6004384FC /* Run Script */,
157 | 97C146EA1CF9000F007C117D /* Sources */,
158 | 97C146EB1CF9000F007C117D /* Frameworks */,
159 | 97C146EC1CF9000F007C117D /* Resources */,
160 | 9705A1C41CF9048500538489 /* Embed Frameworks */,
161 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
162 | 5515D8A96A262B55EB36A051 /* [CP] Embed Pods Frameworks */,
163 | );
164 | buildRules = (
165 | );
166 | dependencies = (
167 | );
168 | name = Runner;
169 | productName = Runner;
170 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
171 | productType = "com.apple.product-type.application";
172 | };
173 | /* End PBXNativeTarget section */
174 |
175 | /* Begin PBXProject section */
176 | 97C146E61CF9000F007C117D /* Project object */ = {
177 | isa = PBXProject;
178 | attributes = {
179 | LastUpgradeCheck = 1020;
180 | ORGANIZATIONNAME = "The Chromium Authors";
181 | TargetAttributes = {
182 | 97C146ED1CF9000F007C117D = {
183 | CreatedOnToolsVersion = 7.3.1;
184 | LastSwiftMigration = 1100;
185 | };
186 | };
187 | };
188 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
189 | compatibilityVersion = "Xcode 3.2";
190 | developmentRegion = en;
191 | hasScannedForEncodings = 0;
192 | knownRegions = (
193 | en,
194 | Base,
195 | );
196 | mainGroup = 97C146E51CF9000F007C117D;
197 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
198 | projectDirPath = "";
199 | projectRoot = "";
200 | targets = (
201 | 97C146ED1CF9000F007C117D /* Runner */,
202 | );
203 | };
204 | /* End PBXProject section */
205 |
206 | /* Begin PBXResourcesBuildPhase section */
207 | 97C146EC1CF9000F007C117D /* Resources */ = {
208 | isa = PBXResourcesBuildPhase;
209 | buildActionMask = 2147483647;
210 | files = (
211 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
212 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
213 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
214 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
215 | );
216 | runOnlyForDeploymentPostprocessing = 0;
217 | };
218 | /* End PBXResourcesBuildPhase section */
219 |
220 | /* Begin PBXShellScriptBuildPhase section */
221 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
222 | isa = PBXShellScriptBuildPhase;
223 | buildActionMask = 2147483647;
224 | files = (
225 | );
226 | inputPaths = (
227 | );
228 | name = "Thin Binary";
229 | outputPaths = (
230 | );
231 | runOnlyForDeploymentPostprocessing = 0;
232 | shellPath = /bin/sh;
233 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin";
234 | };
235 | 40DCEB87593FA17D184A4E7B /* [CP] Check Pods Manifest.lock */ = {
236 | isa = PBXShellScriptBuildPhase;
237 | buildActionMask = 2147483647;
238 | files = (
239 | );
240 | inputFileListPaths = (
241 | );
242 | inputPaths = (
243 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
244 | "${PODS_ROOT}/Manifest.lock",
245 | );
246 | name = "[CP] Check Pods Manifest.lock";
247 | outputFileListPaths = (
248 | );
249 | outputPaths = (
250 | "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt",
251 | );
252 | runOnlyForDeploymentPostprocessing = 0;
253 | shellPath = /bin/sh;
254 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
255 | showEnvVarsInLog = 0;
256 | };
257 | 5515D8A96A262B55EB36A051 /* [CP] Embed Pods Frameworks */ = {
258 | isa = PBXShellScriptBuildPhase;
259 | buildActionMask = 2147483647;
260 | files = (
261 | );
262 | inputPaths = (
263 | );
264 | name = "[CP] Embed Pods Frameworks";
265 | outputPaths = (
266 | );
267 | runOnlyForDeploymentPostprocessing = 0;
268 | shellPath = /bin/sh;
269 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
270 | showEnvVarsInLog = 0;
271 | };
272 | 9740EEB61CF901F6004384FC /* Run Script */ = {
273 | isa = PBXShellScriptBuildPhase;
274 | buildActionMask = 2147483647;
275 | files = (
276 | );
277 | inputPaths = (
278 | );
279 | name = "Run Script";
280 | outputPaths = (
281 | );
282 | runOnlyForDeploymentPostprocessing = 0;
283 | shellPath = /bin/sh;
284 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
285 | };
286 | /* End PBXShellScriptBuildPhase section */
287 |
288 | /* Begin PBXSourcesBuildPhase section */
289 | 97C146EA1CF9000F007C117D /* Sources */ = {
290 | isa = PBXSourcesBuildPhase;
291 | buildActionMask = 2147483647;
292 | files = (
293 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */,
294 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
295 | );
296 | runOnlyForDeploymentPostprocessing = 0;
297 | };
298 | /* End PBXSourcesBuildPhase section */
299 |
300 | /* Begin PBXVariantGroup section */
301 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = {
302 | isa = PBXVariantGroup;
303 | children = (
304 | 97C146FB1CF9000F007C117D /* Base */,
305 | );
306 | name = Main.storyboard;
307 | sourceTree = "";
308 | };
309 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = {
310 | isa = PBXVariantGroup;
311 | children = (
312 | 97C147001CF9000F007C117D /* Base */,
313 | );
314 | name = LaunchScreen.storyboard;
315 | sourceTree = "";
316 | };
317 | /* End PBXVariantGroup section */
318 |
319 | /* Begin XCBuildConfiguration section */
320 | 249021D3217E4FDB00AE95B9 /* Profile */ = {
321 | isa = XCBuildConfiguration;
322 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
323 | buildSettings = {
324 | ALWAYS_SEARCH_USER_PATHS = NO;
325 | CLANG_ANALYZER_NONNULL = YES;
326 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
327 | CLANG_CXX_LIBRARY = "libc++";
328 | CLANG_ENABLE_MODULES = YES;
329 | CLANG_ENABLE_OBJC_ARC = YES;
330 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
331 | CLANG_WARN_BOOL_CONVERSION = YES;
332 | CLANG_WARN_COMMA = YES;
333 | CLANG_WARN_CONSTANT_CONVERSION = YES;
334 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
335 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
336 | CLANG_WARN_EMPTY_BODY = YES;
337 | CLANG_WARN_ENUM_CONVERSION = YES;
338 | CLANG_WARN_INFINITE_RECURSION = YES;
339 | CLANG_WARN_INT_CONVERSION = YES;
340 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
341 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
342 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
343 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
344 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
345 | CLANG_WARN_STRICT_PROTOTYPES = YES;
346 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
347 | CLANG_WARN_UNREACHABLE_CODE = YES;
348 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
349 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
350 | COPY_PHASE_STRIP = NO;
351 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
352 | ENABLE_NS_ASSERTIONS = NO;
353 | ENABLE_STRICT_OBJC_MSGSEND = YES;
354 | GCC_C_LANGUAGE_STANDARD = gnu99;
355 | GCC_NO_COMMON_BLOCKS = YES;
356 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
357 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
358 | GCC_WARN_UNDECLARED_SELECTOR = YES;
359 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
360 | GCC_WARN_UNUSED_FUNCTION = YES;
361 | GCC_WARN_UNUSED_VARIABLE = YES;
362 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
363 | MTL_ENABLE_DEBUG_INFO = NO;
364 | SDKROOT = iphoneos;
365 | SUPPORTED_PLATFORMS = iphoneos;
366 | TARGETED_DEVICE_FAMILY = "1,2";
367 | VALIDATE_PRODUCT = YES;
368 | };
369 | name = Profile;
370 | };
371 | 249021D4217E4FDB00AE95B9 /* Profile */ = {
372 | isa = XCBuildConfiguration;
373 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
374 | buildSettings = {
375 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
376 | CLANG_ENABLE_MODULES = YES;
377 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
378 | ENABLE_BITCODE = NO;
379 | FRAMEWORK_SEARCH_PATHS = (
380 | "$(inherited)",
381 | "$(PROJECT_DIR)/Flutter",
382 | );
383 | INFOPLIST_FILE = Runner/Info.plist;
384 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
385 | LIBRARY_SEARCH_PATHS = (
386 | "$(inherited)",
387 | "$(PROJECT_DIR)/Flutter",
388 | );
389 | PRODUCT_BUNDLE_IDENTIFIER = com.example.ghshopcartFlutter;
390 | PRODUCT_NAME = "$(TARGET_NAME)";
391 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
392 | SWIFT_VERSION = 5.0;
393 | VERSIONING_SYSTEM = "apple-generic";
394 | };
395 | name = Profile;
396 | };
397 | 97C147031CF9000F007C117D /* Debug */ = {
398 | isa = XCBuildConfiguration;
399 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
400 | buildSettings = {
401 | ALWAYS_SEARCH_USER_PATHS = NO;
402 | CLANG_ANALYZER_NONNULL = YES;
403 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
404 | CLANG_CXX_LIBRARY = "libc++";
405 | CLANG_ENABLE_MODULES = YES;
406 | CLANG_ENABLE_OBJC_ARC = YES;
407 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
408 | CLANG_WARN_BOOL_CONVERSION = YES;
409 | CLANG_WARN_COMMA = YES;
410 | CLANG_WARN_CONSTANT_CONVERSION = YES;
411 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
412 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
413 | CLANG_WARN_EMPTY_BODY = YES;
414 | CLANG_WARN_ENUM_CONVERSION = YES;
415 | CLANG_WARN_INFINITE_RECURSION = YES;
416 | CLANG_WARN_INT_CONVERSION = YES;
417 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
418 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
419 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
420 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
421 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
422 | CLANG_WARN_STRICT_PROTOTYPES = YES;
423 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
424 | CLANG_WARN_UNREACHABLE_CODE = YES;
425 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
426 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
427 | COPY_PHASE_STRIP = NO;
428 | DEBUG_INFORMATION_FORMAT = dwarf;
429 | ENABLE_STRICT_OBJC_MSGSEND = YES;
430 | ENABLE_TESTABILITY = YES;
431 | GCC_C_LANGUAGE_STANDARD = gnu99;
432 | GCC_DYNAMIC_NO_PIC = NO;
433 | GCC_NO_COMMON_BLOCKS = YES;
434 | GCC_OPTIMIZATION_LEVEL = 0;
435 | GCC_PREPROCESSOR_DEFINITIONS = (
436 | "DEBUG=1",
437 | "$(inherited)",
438 | );
439 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
440 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
441 | GCC_WARN_UNDECLARED_SELECTOR = YES;
442 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
443 | GCC_WARN_UNUSED_FUNCTION = YES;
444 | GCC_WARN_UNUSED_VARIABLE = YES;
445 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
446 | MTL_ENABLE_DEBUG_INFO = YES;
447 | ONLY_ACTIVE_ARCH = YES;
448 | SDKROOT = iphoneos;
449 | TARGETED_DEVICE_FAMILY = "1,2";
450 | };
451 | name = Debug;
452 | };
453 | 97C147041CF9000F007C117D /* Release */ = {
454 | isa = XCBuildConfiguration;
455 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
456 | buildSettings = {
457 | ALWAYS_SEARCH_USER_PATHS = NO;
458 | CLANG_ANALYZER_NONNULL = YES;
459 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
460 | CLANG_CXX_LIBRARY = "libc++";
461 | CLANG_ENABLE_MODULES = YES;
462 | CLANG_ENABLE_OBJC_ARC = YES;
463 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
464 | CLANG_WARN_BOOL_CONVERSION = YES;
465 | CLANG_WARN_COMMA = YES;
466 | CLANG_WARN_CONSTANT_CONVERSION = YES;
467 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
468 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
469 | CLANG_WARN_EMPTY_BODY = YES;
470 | CLANG_WARN_ENUM_CONVERSION = YES;
471 | CLANG_WARN_INFINITE_RECURSION = YES;
472 | CLANG_WARN_INT_CONVERSION = YES;
473 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
474 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
475 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
476 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
477 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
478 | CLANG_WARN_STRICT_PROTOTYPES = YES;
479 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
480 | CLANG_WARN_UNREACHABLE_CODE = YES;
481 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
482 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
483 | COPY_PHASE_STRIP = NO;
484 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
485 | ENABLE_NS_ASSERTIONS = NO;
486 | ENABLE_STRICT_OBJC_MSGSEND = YES;
487 | GCC_C_LANGUAGE_STANDARD = gnu99;
488 | GCC_NO_COMMON_BLOCKS = YES;
489 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
490 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
491 | GCC_WARN_UNDECLARED_SELECTOR = YES;
492 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
493 | GCC_WARN_UNUSED_FUNCTION = YES;
494 | GCC_WARN_UNUSED_VARIABLE = YES;
495 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
496 | MTL_ENABLE_DEBUG_INFO = NO;
497 | SDKROOT = iphoneos;
498 | SUPPORTED_PLATFORMS = iphoneos;
499 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
500 | TARGETED_DEVICE_FAMILY = "1,2";
501 | VALIDATE_PRODUCT = YES;
502 | };
503 | name = Release;
504 | };
505 | 97C147061CF9000F007C117D /* Debug */ = {
506 | isa = XCBuildConfiguration;
507 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
508 | buildSettings = {
509 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
510 | CLANG_ENABLE_MODULES = YES;
511 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
512 | ENABLE_BITCODE = NO;
513 | FRAMEWORK_SEARCH_PATHS = (
514 | "$(inherited)",
515 | "$(PROJECT_DIR)/Flutter",
516 | );
517 | INFOPLIST_FILE = Runner/Info.plist;
518 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
519 | LIBRARY_SEARCH_PATHS = (
520 | "$(inherited)",
521 | "$(PROJECT_DIR)/Flutter",
522 | );
523 | PRODUCT_BUNDLE_IDENTIFIER = com.example.ghshopcartFlutter;
524 | PRODUCT_NAME = "$(TARGET_NAME)";
525 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
526 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
527 | SWIFT_VERSION = 5.0;
528 | VERSIONING_SYSTEM = "apple-generic";
529 | };
530 | name = Debug;
531 | };
532 | 97C147071CF9000F007C117D /* Release */ = {
533 | isa = XCBuildConfiguration;
534 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
535 | buildSettings = {
536 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
537 | CLANG_ENABLE_MODULES = YES;
538 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
539 | ENABLE_BITCODE = NO;
540 | FRAMEWORK_SEARCH_PATHS = (
541 | "$(inherited)",
542 | "$(PROJECT_DIR)/Flutter",
543 | );
544 | INFOPLIST_FILE = Runner/Info.plist;
545 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
546 | LIBRARY_SEARCH_PATHS = (
547 | "$(inherited)",
548 | "$(PROJECT_DIR)/Flutter",
549 | );
550 | PRODUCT_BUNDLE_IDENTIFIER = com.example.ghshopcartFlutter;
551 | PRODUCT_NAME = "$(TARGET_NAME)";
552 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
553 | SWIFT_VERSION = 5.0;
554 | VERSIONING_SYSTEM = "apple-generic";
555 | };
556 | name = Release;
557 | };
558 | /* End XCBuildConfiguration section */
559 |
560 | /* Begin XCConfigurationList section */
561 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = {
562 | isa = XCConfigurationList;
563 | buildConfigurations = (
564 | 97C147031CF9000F007C117D /* Debug */,
565 | 97C147041CF9000F007C117D /* Release */,
566 | 249021D3217E4FDB00AE95B9 /* Profile */,
567 | );
568 | defaultConfigurationIsVisible = 0;
569 | defaultConfigurationName = Release;
570 | };
571 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = {
572 | isa = XCConfigurationList;
573 | buildConfigurations = (
574 | 97C147061CF9000F007C117D /* Debug */,
575 | 97C147071CF9000F007C117D /* Release */,
576 | 249021D4217E4FDB00AE95B9 /* Profile */,
577 | );
578 | defaultConfigurationIsVisible = 0;
579 | defaultConfigurationName = Release;
580 | };
581 | /* End XCConfigurationList section */
582 | };
583 | rootObject = 97C146E61CF9000F007C117D /* Project object */;
584 | }
585 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
32 |
33 |
39 |
40 |
41 |
42 |
43 |
44 |
54 |
56 |
62 |
63 |
64 |
65 |
66 |
67 |
73 |
75 |
81 |
82 |
83 |
84 |
86 |
87 |
90 |
91 |
92 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | import UIKit
2 | import Flutter
3 |
4 | @UIApplicationMain
5 | @objc class AppDelegate: FlutterAppDelegate {
6 | override func application(
7 | _ application: UIApplication,
8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
9 | ) -> Bool {
10 | GeneratedPluginRegistrant.register(with: self)
11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions)
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "size" : "20x20",
5 | "idiom" : "iphone",
6 | "filename" : "Icon-App-20x20@2x.png",
7 | "scale" : "2x"
8 | },
9 | {
10 | "size" : "20x20",
11 | "idiom" : "iphone",
12 | "filename" : "Icon-App-20x20@3x.png",
13 | "scale" : "3x"
14 | },
15 | {
16 | "size" : "29x29",
17 | "idiom" : "iphone",
18 | "filename" : "Icon-App-29x29@1x.png",
19 | "scale" : "1x"
20 | },
21 | {
22 | "size" : "29x29",
23 | "idiom" : "iphone",
24 | "filename" : "Icon-App-29x29@2x.png",
25 | "scale" : "2x"
26 | },
27 | {
28 | "size" : "29x29",
29 | "idiom" : "iphone",
30 | "filename" : "Icon-App-29x29@3x.png",
31 | "scale" : "3x"
32 | },
33 | {
34 | "size" : "40x40",
35 | "idiom" : "iphone",
36 | "filename" : "Icon-App-40x40@2x.png",
37 | "scale" : "2x"
38 | },
39 | {
40 | "size" : "40x40",
41 | "idiom" : "iphone",
42 | "filename" : "Icon-App-40x40@3x.png",
43 | "scale" : "3x"
44 | },
45 | {
46 | "size" : "60x60",
47 | "idiom" : "iphone",
48 | "filename" : "Icon-App-60x60@2x.png",
49 | "scale" : "2x"
50 | },
51 | {
52 | "size" : "60x60",
53 | "idiom" : "iphone",
54 | "filename" : "Icon-App-60x60@3x.png",
55 | "scale" : "3x"
56 | },
57 | {
58 | "size" : "20x20",
59 | "idiom" : "ipad",
60 | "filename" : "Icon-App-20x20@1x.png",
61 | "scale" : "1x"
62 | },
63 | {
64 | "size" : "20x20",
65 | "idiom" : "ipad",
66 | "filename" : "Icon-App-20x20@2x.png",
67 | "scale" : "2x"
68 | },
69 | {
70 | "size" : "29x29",
71 | "idiom" : "ipad",
72 | "filename" : "Icon-App-29x29@1x.png",
73 | "scale" : "1x"
74 | },
75 | {
76 | "size" : "29x29",
77 | "idiom" : "ipad",
78 | "filename" : "Icon-App-29x29@2x.png",
79 | "scale" : "2x"
80 | },
81 | {
82 | "size" : "40x40",
83 | "idiom" : "ipad",
84 | "filename" : "Icon-App-40x40@1x.png",
85 | "scale" : "1x"
86 | },
87 | {
88 | "size" : "40x40",
89 | "idiom" : "ipad",
90 | "filename" : "Icon-App-40x40@2x.png",
91 | "scale" : "2x"
92 | },
93 | {
94 | "size" : "76x76",
95 | "idiom" : "ipad",
96 | "filename" : "Icon-App-76x76@1x.png",
97 | "scale" : "1x"
98 | },
99 | {
100 | "size" : "76x76",
101 | "idiom" : "ipad",
102 | "filename" : "Icon-App-76x76@2x.png",
103 | "scale" : "2x"
104 | },
105 | {
106 | "size" : "83.5x83.5",
107 | "idiom" : "ipad",
108 | "filename" : "Icon-App-83.5x83.5@2x.png",
109 | "scale" : "2x"
110 | },
111 | {
112 | "size" : "1024x1024",
113 | "idiom" : "ios-marketing",
114 | "filename" : "Icon-App-1024x1024@1x.png",
115 | "scale" : "1x"
116 | }
117 | ],
118 | "info" : {
119 | "version" : 1,
120 | "author" : "xcode"
121 | }
122 | }
123 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "universal",
5 | "filename" : "LaunchImage.png",
6 | "scale" : "1x"
7 | },
8 | {
9 | "idiom" : "universal",
10 | "filename" : "LaunchImage@2x.png",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "universal",
15 | "filename" : "LaunchImage@3x.png",
16 | "scale" : "3x"
17 | }
18 | ],
19 | "info" : {
20 | "version" : 1,
21 | "author" : "xcode"
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md:
--------------------------------------------------------------------------------
1 | # Launch Screen Assets
2 |
3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory.
4 |
5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images.
--------------------------------------------------------------------------------
/ios/Runner/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
--------------------------------------------------------------------------------
/ios/Runner/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/ios/Runner/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | NSAppTransportSecurity
6 |
7 | NSAllowsArbitraryLoads
8 |
9 |
10 | CFBundleDevelopmentRegion
11 | $(DEVELOPMENT_LANGUAGE)
12 | CFBundleExecutable
13 | $(EXECUTABLE_NAME)
14 | CFBundleIdentifier
15 | $(PRODUCT_BUNDLE_IDENTIFIER)
16 | CFBundleInfoDictionaryVersion
17 | 6.0
18 | CFBundleName
19 | ghshopcart_flutter
20 | CFBundlePackageType
21 | APPL
22 | CFBundleShortVersionString
23 | $(FLUTTER_BUILD_NAME)
24 | CFBundleSignature
25 | ????
26 | CFBundleVersion
27 | $(FLUTTER_BUILD_NUMBER)
28 | LSRequiresIPhoneOS
29 |
30 | UILaunchStoryboardName
31 | LaunchScreen
32 | UIMainStoryboardFile
33 | Main
34 | UISupportedInterfaceOrientations
35 |
36 | UIInterfaceOrientationPortrait
37 | UIInterfaceOrientationLandscapeLeft
38 | UIInterfaceOrientationLandscapeRight
39 |
40 | UISupportedInterfaceOrientations~ipad
41 |
42 | UIInterfaceOrientationPortrait
43 | UIInterfaceOrientationPortraitUpsideDown
44 | UIInterfaceOrientationLandscapeLeft
45 | UIInterfaceOrientationLandscapeRight
46 |
47 | UIViewControllerBasedStatusBarAppearance
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/ios/Runner/Runner-Bridging-Header.h:
--------------------------------------------------------------------------------
1 | #import "GeneratedPluginRegistrant.h"
--------------------------------------------------------------------------------
/lib/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/lib/.DS_Store
--------------------------------------------------------------------------------
/lib/main.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'pages/tabs/GHShopCart.dart';
3 |
4 |
5 | void main() {
6 |
7 | runApp(MyApp());
8 | }
9 |
10 | class MyApp extends StatefulWidget {
11 | MyApp({Key key}) : super(key: key);
12 |
13 | _MyAppState createState() => _MyAppState();
14 | }
15 |
16 |
17 | class _MyAppState extends State {
18 | @override
19 | Widget build(BuildContext context) {
20 | return MaterialApp(
21 | /// 隐藏debug
22 | debugShowCheckedModeBanner: false,
23 |
24 | /// 设置主题
25 | theme: ThemeData(
26 | primaryColor: Colors.white,
27 | ),
28 | title: "GHShopCart_flutter",
29 | home: GHShopCart(),
30 | );
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/lib/model/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/lib/model/.DS_Store
--------------------------------------------------------------------------------
/lib/model/GHGoodDetailsModel.dart:
--------------------------------------------------------------------------------
1 | class GHGoodDetailsModel {
2 | String isSelf;
3 | String description;
4 | List coupons;
5 | List service;
6 | int sales;
7 | List urls;
8 | String receiptTip;
9 | String updatedAt;
10 | String evaluate;
11 | String objectId;
12 | List storeAdvantages;
13 | String createdAt;
14 | String title;
15 | String goodId;
16 | Operators operators;
17 | String url;
18 | Object price;
19 | int count;
20 | String seletecdStrings;
21 | bool check;
22 |
23 | GHGoodDetailsModel(
24 | {this.isSelf,
25 | this.description,
26 | this.coupons,
27 | this.service,
28 | this.sales,
29 | this.urls,
30 | this.receiptTip,
31 | this.updatedAt,
32 | this.evaluate,
33 | this.objectId,
34 | this.goodId,
35 | this.storeAdvantages,
36 | this.createdAt,
37 | this.title,
38 | this.operators,
39 | this.url,
40 | this.count,
41 | this.seletecdStrings,
42 | this.check,
43 | this.price});
44 |
45 | GHGoodDetailsModel.fromJson(Map json) {
46 | isSelf = json['isSelf'];
47 | description = json['description'];
48 | Object tempCoupons = json['coupons'];
49 | if (tempCoupons is List) {
50 | coupons = tempCoupons.cast();
51 | } else {
52 | coupons = [];
53 | }
54 |
55 | Object tempservice = json['service'];
56 | if (tempservice is List) {
57 | service = tempservice.cast();
58 | } else {
59 | service = [];
60 | }
61 |
62 | sales = json['sales'];
63 |
64 | Object tempurls = json['urls'];
65 | if (tempurls is List) {
66 | urls = tempurls.cast();
67 | } else {
68 | urls = [];
69 | }
70 | count = json['count'];
71 | check = json['check'];
72 | goodId = json['goodId'];
73 | receiptTip = json['receiptTip'];
74 | updatedAt = json['updatedAt'];
75 | evaluate = json['evaluate'];
76 | objectId = json['objectId'];
77 | Object tempstoreAdvantages = json['storeAdvantages'];
78 | if (tempstoreAdvantages is List) {
79 | storeAdvantages = tempstoreAdvantages.cast();
80 | } else {
81 | storeAdvantages = [];
82 | }
83 |
84 | createdAt = json['createdAt'];
85 | title = json['title'];
86 | operators = json['operators'] != null
87 | ? new Operators.fromJson(json['operators'])
88 | : null;
89 | url = json['url'];
90 | price = json['price'];
91 | seletecdStrings = json['seletecdStrings'];
92 | }
93 |
94 | Map toJson() {
95 | final Map data = new Map();
96 | data['isSelf'] = this.isSelf;
97 | data['description'] = this.description;
98 | data['coupons'] = this.coupons;
99 | data['service'] = this.service;
100 | data['sales'] = this.sales;
101 | data['urls'] = this.urls;
102 | data['receiptTip'] = this.receiptTip;
103 | data['updatedAt'] = this.updatedAt;
104 | data['evaluate'] = this.evaluate;
105 | data['objectId'] = this.objectId;
106 | data['count'] = this.count;
107 | data['check'] = this.check;
108 | data['storeAdvantages'] = this.storeAdvantages;
109 | data['createdAt'] = this.createdAt;
110 | data['title'] = this.title;
111 | data['goodId'] = this.goodId;
112 |
113 | data['seletecdStrings'] = this.seletecdStrings;
114 | if (this.operators != null) {
115 | data['operators'] = this.operators.toJson();
116 | }
117 | data['url'] = this.url;
118 | data['price'] = this.price;
119 | return data;
120 | }
121 | }
122 |
123 | class Operators {
124 | List operator;
125 |
126 | Operators({this.operator});
127 |
128 | Operators.fromJson(Map json) {
129 | if (json['operator'] != null) {
130 | operator = new List();
131 | json['operator'].forEach((v) {
132 | operator.add(new Operator.fromJson(v));
133 | });
134 | }
135 | }
136 |
137 | Map toJson() {
138 | final Map data = new Map();
139 | if (this.operator != null) {
140 | data['operator'] = this.operator.map((v) => v.toJson()).toList();
141 | }
142 | return data;
143 | }
144 | }
145 |
146 | class Operator {
147 | String title;
148 |
149 | Operator({this.title});
150 | Operator.fromJson(Map json) {
151 | title = json['title'];
152 | }
153 |
154 | Map toJson() {
155 | final Map data = new Map();
156 | data['title'] = this.title;
157 | return data;
158 | }
159 | }
160 |
--------------------------------------------------------------------------------
/lib/model/GHHotGoodsModel.dart:
--------------------------------------------------------------------------------
1 | class GHHotGoodsModel {
2 | List results;
3 |
4 | GHHotGoodsModel({this.results});
5 |
6 | GHHotGoodsModel.fromJson(Map json) {
7 | if (json['results'] != null) {
8 | results = new List();
9 | json['results'].forEach((v) {
10 | results.add(new GHHotGoodsItemModel.fromJson(v));
11 | });
12 | }
13 | }
14 |
15 | Map toJson() {
16 | final Map data = new Map();
17 | if (this.results != null) {
18 | data['result'] = this.results.map((v) => v.toJson()).toList();
19 | }
20 | return data;
21 | }
22 | }
23 |
24 | class GHHotGoodsItemModel {
25 |
26 | String price; //所有的类型都继承 Object
27 | String url;
28 | String oldPrice;
29 | String title;
30 |
31 | GHHotGoodsItemModel(
32 | {
33 | this.price,
34 | this.oldPrice,
35 | this.title,
36 | this.url,
37 | });
38 |
39 | GHHotGoodsItemModel.fromJson(Map json) {
40 | url = json['url'];
41 | oldPrice = json['oldPrice'];
42 | title = json['title'];
43 | price = json['price'];
44 | }
45 |
46 | Map toJson() {
47 | final Map data = new Map();
48 |
49 | data['price'] = this.price;
50 | data['title'] = this.title;
51 | data['oldPrice'] = this.oldPrice;
52 | data['url'] = this.url;
53 | return data;
54 | }
55 | }
--------------------------------------------------------------------------------
/lib/pages/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shabake/GHShopCart_flutter/497f19a882c898a0f1630a40740d8bde23b3c35a/lib/pages/.DS_Store
--------------------------------------------------------------------------------
/lib/pages/tabs/GHShopCart.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import '../../services/httptool.dart';
3 | import 'package:transparent_image/transparent_image.dart';
4 | import '../../services/ScreenAdaper.dart';
5 | import "../../model/GHGoodDetailsModel.dart";
6 | import '../../widget/GHCountItemWidget.dart';
7 | import '../../widget/LoadingWidget.dart';
8 | import '../../model/GHHotGoodsModel.dart';
9 | import 'package:flutter_screenutil/flutter_screenutil.dart';
10 |
11 |
12 | /// 购物车
13 | class GHShopCart extends StatefulWidget {
14 | @override
15 | _GHShopCartState createState() => _GHShopCartState();
16 | }
17 |
18 | class _GHShopCartState extends State {
19 | /// 热卖商品
20 | List _hotGoodsList = [];
21 |
22 | /// 购物车列表
23 | List _shopCartList = [];
24 |
25 | /// 记录是否已经全选
26 | bool _isAllCheck = false;
27 |
28 | /// 编辑/完成
29 | bool _isEdit = false;
30 |
31 | /// 共计
32 | double _total = 0;
33 |
34 | @override
35 | void initState() {
36 | super.initState();
37 | this._getShopCartList();
38 | }
39 |
40 | /// 获取购物车列表
41 | void _getShopCartList() async {
42 | var url = "https://a4cj1hm5.api.lncld.net/1.1/classes/shopCartList";
43 | var c = Uri.encodeComponent('-createdAt');
44 | url = url + '?' + "order=" + c;
45 | HttpRequest.request(url, method: 'GET').then((res) {
46 | List _tempList = [];
47 | List _results = res["results"];
48 | _results.forEach((item) {
49 | GHGoodDetailsModel goodDetailsModel =
50 | new GHGoodDetailsModel.fromJson(item);
51 | _tempList.add(goodDetailsModel);
52 | });
53 |
54 | double _tempTotal = 0;
55 | bool _tempIsAllCheck = true;
56 | for (var i = 0; i < _tempList.length; i++) {
57 | GHGoodDetailsModel goodDetailsModel = _tempList[i];
58 | if (goodDetailsModel.check == true) {
59 | _tempTotal += goodDetailsModel.count * goodDetailsModel.price;
60 | } else {
61 | _tempIsAllCheck = false;
62 | }
63 | }
64 |
65 | setState(() {
66 | this._shopCartList = _tempList;
67 | this._total = _tempTotal;
68 | this._isAllCheck = _tempIsAllCheck;
69 | });
70 | });
71 | }
72 |
73 | /// 获取热门商品的数据
74 | void _getHotGoodsData() async {
75 | var url = "https://a4cj1hm5.api.lncld.net/1.1/classes/shopHotGoods";
76 | await HttpRequest.request(url).then((value) {
77 | var list = new GHHotGoodsModel.fromJson(value).results;
78 | setState(() {
79 | this._hotGoodsList = list;
80 | });
81 | });
82 | }
83 |
84 | /// 修改购物车中的商品
85 | void _updateShopCartList(
86 | GHGoodDetailsModel goodDetailsModel, String goodId) async {
87 | var url =
88 | "https://a4cj1hm5.api.lncld.net/1.1/classes/shopCartList/${goodId}";
89 | Map params = {
90 | "count": goodDetailsModel.count,
91 | "check": goodDetailsModel.check,
92 | };
93 | HttpRequest.request(url, method: 'PUT', params: params).then((value) {
94 | var objectId = value["objectId"];
95 | if (objectId != null) {
96 | print("更新成功");
97 | this._getShopCartList();
98 | } else {
99 | print("更新失败");
100 | }
101 | });
102 | }
103 |
104 | /// 热销商品widget
105 | Widget _hotGoodstWidget() {
106 | if (this._hotGoodsList.length == 0) {
107 | return Text("");
108 | }
109 | return Container(
110 | color: Color.fromRGBO(245, 245, 245, 1),
111 | padding: EdgeInsets.only(left: 10, top: 10, bottom: 10),
112 | child: Wrap(
113 | spacing: 10,
114 | runSpacing: 10,
115 | children: this._hotGoodsList.map((value) {
116 | return Container(
117 | decoration: BoxDecoration(
118 | color: Colors.white,
119 | border: Border.all(
120 | color: Color.fromRGBO(233, 233, 233, 0.9), width: 1)),
121 | padding:
122 | EdgeInsets.only(top: 20, left: 20, right: 20, bottom: 10),
123 | width: (ScreenAdaper.getScreenWidth() - 30) / 2,
124 | child: Column(
125 | mainAxisAlignment: MainAxisAlignment.start,
126 | children: [
127 | Container(
128 | width: 80,
129 | height: 100,
130 | child: new FadeInImage.memoryNetwork(
131 | placeholder: kTransparentImage,
132 | image: "${value.url}",
133 | ),
134 | ),
135 | SizedBox(
136 | height: 3,
137 | ),
138 | Container(
139 | child: Text(
140 | "${value.title}",
141 | maxLines: 2,
142 | overflow: TextOverflow.ellipsis,
143 | ),
144 | ),
145 | SizedBox(
146 | height: 10,
147 | ),
148 | Container(
149 | child: Row(
150 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
151 | children: [
152 | Container(
153 | child: Row(
154 | children: [
155 | Container(
156 | child: Text(
157 | "¥",
158 | style:
159 | TextStyle(fontSize: 10, color: Colors.red),
160 | ),
161 | ),
162 | Container(
163 | child: Text(
164 | "${value.price}",
165 | style: TextStyle(
166 | color: Colors.red,
167 | fontWeight: FontWeight.bold),
168 | ),
169 | )
170 | ],
171 | )),
172 | Container(
173 | height: 21,
174 | width: 40,
175 | alignment: Alignment.center,
176 | decoration: BoxDecoration(
177 | border: Border.all(
178 | color: Color.fromRGBO(233, 233, 233, 0.9),
179 | width: 1,
180 | ),
181 | borderRadius: BorderRadius.circular(10),
182 | ),
183 | child: Text(
184 | "看详情",
185 | style:
186 | TextStyle(color: Colors.black54, fontSize: 10),
187 | ),
188 | )
189 | ],
190 | ),
191 | )
192 | ],
193 | ));
194 | }).toList(),
195 | ),
196 | );
197 | }
198 |
199 | /// 没有登录的登录
200 | Widget _notLoginLetLoginWidget() {
201 | return Container(
202 | padding: EdgeInsets.all(10),
203 | child: Row(
204 | mainAxisAlignment: MainAxisAlignment.center,
205 | children: [
206 | Container(
207 | alignment: Alignment.center,
208 | height: 30,
209 | width: 80,
210 | decoration: BoxDecoration(
211 | borderRadius: BorderRadius.circular(20),
212 | border: Border.all(
213 | color: Color.fromRGBO(200, 200, 200, 1), width: 1)),
214 | child: GestureDetector(
215 | behavior: HitTestBehavior.opaque,
216 | onTap: () {
217 | print("点击登录");
218 | },
219 | child: Text(
220 | "登录",
221 | style: TextStyle(fontSize: 12, color: Colors.black87),
222 | ),
223 | )),
224 | SizedBox(
225 | width: 10,
226 | ),
227 | Container(
228 | child: Text(
229 | "登录后同步电脑与手机购物车中的商品",
230 | style: TextStyle(fontSize: 12, color: Colors.black87),
231 | ),
232 | ),
233 | ],
234 | ),
235 | );
236 | }
237 |
238 | /// 空的购物车
239 | Widget _emptyShopCartWidget() {
240 | return Container(
241 | alignment: Alignment.center,
242 | child: Text(
243 | "购物车是空",
244 | style: TextStyle(fontSize: 16, color: Colors.black87),
245 | ),
246 | );
247 | }
248 |
249 | /// 未登录导航
250 | Widget _notLoginNavigationWidget() {
251 | return Container(
252 | child: Row(
253 | mainAxisAlignment: MainAxisAlignment.center,
254 | children: [
255 | Container(
256 | alignment: Alignment.center,
257 | height: 40,
258 | width: 120,
259 | decoration: BoxDecoration(
260 | borderRadius: BorderRadius.circular(20),
261 | border: Border.all(
262 | color: Color.fromRGBO(200, 200, 200, 1), width: 1)),
263 | child: GestureDetector(
264 | behavior: HitTestBehavior.opaque,
265 | child: Text("随便看看",
266 | style: TextStyle(fontWeight: FontWeight.bold, fontSize: 16)),
267 | ),
268 | ),
269 | SizedBox(
270 | width: 30,
271 | ),
272 | Container(
273 | padding: EdgeInsets.all(10),
274 | alignment: Alignment.center,
275 | height: 40,
276 | width: 120,
277 | decoration: BoxDecoration(
278 | borderRadius: BorderRadius.circular(20),
279 | border: Border.all(
280 | color: Color.fromRGBO(200, 200, 200, 1), width: 1)),
281 | child: GestureDetector(
282 | behavior: HitTestBehavior.opaque,
283 | child: Text(
284 | "收藏商品",
285 | style: TextStyle(fontWeight: FontWeight.bold, fontSize: 16),
286 | ),
287 | )),
288 | ],
289 | ),
290 | );
291 | }
292 |
293 | Widget _recommendWidget() {
294 | return Container(
295 | height: 50,
296 | color: Color.fromRGBO(245, 245, 245, 1),
297 | child: Row(
298 | mainAxisAlignment: MainAxisAlignment.center,
299 | children: [
300 | Container(
301 | child: Icon(
302 | Icons.hearing,
303 | color: Colors.red,
304 | ),
305 | ),
306 | SizedBox(
307 | width: 10,
308 | ),
309 | Container(
310 | child: Text(
311 | "为你推荐",
312 | style: TextStyle(fontWeight: FontWeight.bold, fontSize: 16),
313 | ),
314 | )
315 | ],
316 | ),
317 | );
318 | }
319 |
320 | /// 没有登录
321 | Widget _notLoginWidgte() {
322 | return Container(
323 | child: ListView(
324 | children: [
325 | this._notLoginLetLoginWidget(),
326 | Divider(),
327 | this._emptyShopCartWidget(),
328 | SizedBox(
329 | height: 10,
330 | ),
331 | this._notLoginNavigationWidget(),
332 | SizedBox(
333 | height: 10,
334 | ),
335 | this._recommendWidget(),
336 |
337 | /// 热门推荐
338 | this._hotGoodstWidget(),
339 | ],
340 | ),
341 | );
342 | }
343 |
344 | /// 自定义appBar
345 | Widget _appBar() {
346 | return AppBar(
347 | title: Container(
348 | child: Row(
349 | mainAxisAlignment: MainAxisAlignment.center,
350 | crossAxisAlignment: CrossAxisAlignment.center,
351 | children: [
352 | Container(
353 | child: Text("购物车"),
354 | ),
355 | InkWell(
356 | onTap: () {},
357 | child: Row(
358 | crossAxisAlignment: CrossAxisAlignment.end,
359 | children: [
360 | Container(
361 | child: Icon(
362 | Icons.location_on,
363 | size: 18,
364 | color: Colors.red,
365 | ),
366 | ),
367 | Container(
368 | child: Text(
369 | "北京",
370 | style: TextStyle(fontSize: 12, color: Colors.black38),
371 | ),
372 | ),
373 | ],
374 | ))
375 | ],
376 | ),
377 | ),
378 | actions: [
379 | Container(
380 | margin: EdgeInsets.only(right: 20),
381 | alignment: Alignment.center,
382 | child: GestureDetector(
383 | behavior: HitTestBehavior.opaque,
384 | onTap: () {
385 | setState(() {
386 | this._isEdit = !this._isEdit;
387 | });
388 | },
389 | child: Text(
390 | this._isEdit == false ? "编辑" : "完成",
391 | style: TextStyle(fontSize: 14, color: Colors.black38),
392 | )))
393 | ],
394 | );
395 | }
396 |
397 | /// 批量处理全选
398 | void _actionAllCheck(bool isAllCheck) {
399 | List maps = [];
400 | for (var i = 0; i < this._shopCartList.length; i++) {
401 | GHGoodDetailsModel goodDetailsModel = _shopCartList[i];
402 | Map map = {
403 | "method": "PUT",
404 | "path": "/1.1/classes/shopCartList/${goodDetailsModel.objectId}",
405 | "body": {"check": isAllCheck}
406 | };
407 | maps.add(map);
408 | }
409 | var url = "https://a4cj1hm5.api.lncld.net/1.1/batch";
410 |
411 | Map params = {"requests": maps};
412 |
413 | HttpRequest.request(url, method: 'POST', params: params).then((value) {
414 | if (value != null) {
415 | this._getShopCartList();
416 | } else {
417 | print("更新失败");
418 | }
419 | });
420 | }
421 |
422 | /// 底部工具条
423 | Widget _bottomToolBar() {
424 | return Container(
425 | color: Colors.white,
426 | child: Container(
427 | decoration: BoxDecoration(
428 | border: Border(
429 | top: BorderSide(
430 | width: 1,
431 | color: Colors.black12,
432 | ))),
433 | child: Row(
434 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
435 | children: [
436 | Container(
437 | padding: EdgeInsets.only(left: 10),
438 | width: 100,
439 | child: Row(
440 | mainAxisAlignment: MainAxisAlignment.start,
441 | children: [
442 | Container(
443 | width: 20,
444 | height: 20,
445 | child: GestureDetector(
446 | onTap: () {
447 | setState(() {
448 | this._isAllCheck = !this._isAllCheck;
449 | });
450 | this._actionAllCheck(this._isAllCheck);
451 | },
452 | child: this._isAllCheck == true
453 | ? Image.asset('images/checkSelected.png')
454 | : Image.asset('images/checkNormal.png'))),
455 | Container(
456 | padding: EdgeInsets.only(left: 10),
457 | child: Text(
458 | "全选",
459 | style: TextStyle(fontSize: 14, color: Colors.black54),
460 | ),
461 | ),
462 | ],
463 | ),
464 | ),
465 | this._isEdit == false
466 | ? Container(
467 | child: Row(
468 | children: [
469 | Container(
470 | child: RichText(
471 | text: TextSpan(
472 | text: "¥",
473 | style: TextStyle(
474 | color: Colors.red, fontSize: 10),
475 | children: [
476 | TextSpan(
477 | text: "${this._total}",
478 | style: TextStyle(
479 | color: Colors.red,
480 | fontSize: 20,
481 | fontWeight: FontWeight.bold)),
482 | TextSpan(
483 | text: ".00",
484 | style: TextStyle(
485 | color: Colors.red,
486 | fontSize: 10,
487 | fontWeight: FontWeight.bold)),
488 | ])),
489 | ),
490 | SizedBox(
491 | width: 10,
492 | ),
493 | Container(
494 | color: Colors.red,
495 | width: 120,
496 | height: 60,
497 | child: GestureDetector(
498 | behavior: HitTestBehavior.opaque,
499 | onTap: () {
500 | // if (this.list.length == 0) {
501 | // Navigator.pushNamed(context, '/login');
502 | // } else {
503 | // Navigator.pushNamed(context, '/CheckOut');
504 | // }
505 | },
506 | child: Center(
507 | child: Text(
508 | "结算",
509 | style: TextStyle(
510 | color: Colors.white, fontSize: 20),
511 | ),
512 | ),
513 | ))
514 | ],
515 | ),
516 | )
517 | : Container(
518 | alignment: Alignment.center,
519 | height: 30,
520 | width: 80,
521 | decoration: BoxDecoration(
522 | borderRadius: BorderRadius.circular(20),
523 | border: Border.all(
524 | color: Color.fromRGBO(200, 200, 200, 1), width: 1)),
525 | child: GestureDetector(
526 | behavior: HitTestBehavior.opaque,
527 | onTap: () {
528 | print("点击删除");
529 | },
530 | child: Text(
531 | "删除",
532 | style: TextStyle(fontSize: 12, color: Colors.black87),
533 | ),
534 | )),
535 | ],
536 | ),
537 | ),
538 | );
539 | }
540 |
541 | /// 购物车子项
542 | Widget _shopCartItem(GHGoodDetailsModel goodDetailsModel) {
543 | return Container(
544 | padding: EdgeInsets.all(10),
545 | height: 130,
546 | child: Row(
547 | crossAxisAlignment: CrossAxisAlignment.center,
548 | children: [
549 | Container(
550 | width: 20,
551 | height: 20,
552 | child: GestureDetector(
553 | onTap: () {
554 | setState(() {
555 | goodDetailsModel.check = !goodDetailsModel.check;
556 | });
557 | this._updateShopCartList(
558 | goodDetailsModel, goodDetailsModel.objectId);
559 | },
560 | child: goodDetailsModel.check == true
561 | ? Image.asset('images/checkSelected.png')
562 | : Image.asset('images/checkNormal.png'))),
563 | Expanded(
564 | flex: 1,
565 | child: GestureDetector(
566 | onTap: () {
567 |
568 | },
569 | child: Column(
570 | mainAxisAlignment: MainAxisAlignment.start,
571 | children: [
572 | Container(
573 | padding: EdgeInsets.only(left: 10),
574 | width: double.infinity,
575 | child: Row(
576 | crossAxisAlignment: CrossAxisAlignment.start,
577 | children: [
578 | Container(
579 | padding: EdgeInsets.only(right: 10),
580 | height: 100,
581 | width: 100,
582 | child: new FadeInImage.memoryNetwork(
583 | placeholder: kTransparentImage,
584 | image: goodDetailsModel.url,
585 | ),
586 | ),
587 | Expanded(
588 | flex: 1,
589 | child: Container(
590 | height: 110,
591 | child: Column(
592 | crossAxisAlignment:
593 | CrossAxisAlignment.start,
594 | mainAxisAlignment:
595 | MainAxisAlignment.spaceBetween,
596 | children: [
597 | Container(
598 | child: Column(
599 | crossAxisAlignment:
600 | CrossAxisAlignment.start,
601 | children: [
602 | Container(
603 | padding:
604 | EdgeInsets.only(bottom: 10),
605 | child: Text(
606 | goodDetailsModel.title,
607 | style: TextStyle(
608 | fontSize: 14,
609 | fontWeight:
610 | FontWeight.bold),
611 | ),
612 | ),
613 | Container(
614 | color: Colors.black12,
615 | child: Text(
616 | goodDetailsModel
617 | .seletecdStrings,
618 | style: TextStyle(
619 | fontSize: 12,
620 | ),
621 | ),
622 | )
623 | ],
624 | )),
625 | Container(
626 | child: Row(
627 | mainAxisAlignment:
628 | MainAxisAlignment.spaceBetween,
629 | children: [
630 | Container(
631 | child: RichText(
632 | text: TextSpan(
633 | text: "¥",
634 | style: TextStyle(
635 | color: Colors.red,
636 | fontSize: 10),
637 | children: [
638 | TextSpan(
639 | text:
640 | "${goodDetailsModel?.price}",
641 | style: TextStyle(
642 | color: Colors.red,
643 | fontSize: 20,
644 | fontWeight:
645 | FontWeight
646 | .bold)),
647 | TextSpan(
648 | text: ".00",
649 | style: TextStyle(
650 | color: Colors.red,
651 | fontSize: 10,
652 | fontWeight:
653 | FontWeight
654 | .bold)),
655 | ])),
656 | ),
657 | Container(
658 | child: GHCountItemWidger(
659 | count: goodDetailsModel.count,
660 | addClick: (value) {
661 | setState(() {
662 | goodDetailsModel.count =
663 | value;
664 | });
665 | this._updateShopCartList(
666 | goodDetailsModel,
667 | goodDetailsModel
668 | .objectId);
669 | },
670 | subClick: (value) {
671 | setState(() {
672 | goodDetailsModel.count =
673 | value;
674 | });
675 | this._updateShopCartList(
676 | goodDetailsModel,
677 | goodDetailsModel
678 | .objectId);
679 | },
680 | ),
681 | )
682 | ],
683 | ))
684 | ],
685 | ),
686 | ))
687 | ],
688 | ),
689 | ),
690 | ],
691 | )))
692 | ],
693 | ));
694 | }
695 |
696 | /// 购物车列表
697 | Widget _shopCartWidget() {
698 | return Stack(
699 | children: [
700 | Container(
701 | color: Colors.white,
702 | height: ScreenAdaper.getScreenHeight() - 60 - ScreenUtil.bottomBarHeight,
703 | child: ListView.builder(
704 | itemCount: this._shopCartList.length,
705 | itemBuilder: (BuildContext context, index) {
706 | return this._shopCartItem(this._shopCartList[index]);
707 | })),
708 | Positioned(
709 | width: ScreenAdaper.getScreenWidth(),
710 | height: 60,
711 | bottom: 0,
712 | child: this._bottomToolBar(),
713 | ),
714 | ],
715 | );
716 | }
717 |
718 | /// 判断bodywidget
719 | Widget _bodyWidgt() {
720 | if (this._shopCartList.length == 0) {
721 | return LoadingWidget();
722 | }
723 | return this._shopCartWidget();
724 | }
725 |
726 | Widget build(BuildContext context) {
727 | ScreenAdaper.init(context);
728 | return Scaffold(
729 | appBar: this._appBar(),
730 | body: this. _bodyWidgt(),
731 | );
732 | }
733 | }
734 |
--------------------------------------------------------------------------------
/lib/services/ScreenAdaper.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter_screenutil/flutter_screenutil.dart';
2 |
3 | class ScreenAdaper {
4 | static init(context) {
5 | ScreenUtil.init(width: 750, height: 1334);
6 | }
7 |
8 | static height(double value) {
9 | return ScreenUtil().setHeight(value);
10 | }
11 |
12 | static width(double value) {
13 | return ScreenUtil().setWidth(value);
14 | }
15 |
16 | static getScreenHeight() {
17 | return ScreenUtil.screenHeight;
18 | }
19 |
20 | static getScreenWidth() {
21 | return ScreenUtil.screenWidth;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/lib/services/httptool.dart:
--------------------------------------------------------------------------------
1 | import 'package:dio/dio.dart';
2 |
3 | class HttpRequest {
4 | static final BaseOptions options = BaseOptions(baseUrl: "");
5 |
6 | static final Dio dio = Dio(options);
7 |
8 | static Future request(String url,
9 | {String method, Map params, Interceptor inter}) async {
10 | // 1.请求的单独配置
11 | Options options = Options(method: method);
12 | options.headers = httpHeaders;
13 | // // 2.添加第一个拦截器
14 | // Interceptor dInter =
15 | // InterceptorsWrapper(onRequest: (RequestOptions options) {
16 | // // 1.在进行任何网络请求的时候, 可以添加一个loading显示
17 | //
18 | // // 2.很多页面的访问必须要求携带Token,那么就可以在这里判断是有Token
19 | //
20 | // // 3.对参数进行一些处理,比如序列化处理等
21 | // print("拦截了请求");
22 | // return options;
23 | // }, onResponse: (Response response) {
24 | // print("拦截了响应");
25 | // return response;
26 | // }, onError: (DioError error) {
27 | // print("拦截了错误");
28 | // return error;
29 | // });
30 | //
31 | // List inters = [dInter];
32 | // if (inter != null) {
33 | // inters.add(inter);
34 | // }
35 | //
36 | // dio.interceptors.addAll(inters);
37 | // 3.发送网络请求
38 | try {
39 | Response response =
40 | await dio.request(url, data: params, options: options);
41 | print(response.data);
42 |
43 | return response.data;
44 | } on DioError catch (e) {
45 | print(e);
46 | return Future.error(e);
47 | }
48 | }
49 | }
50 |
51 | const httpHeaders = {
52 | 'Content-Type': 'application/json',
53 | 'X-LC-Id': 'a4Cj1Hm5aMrdhob6xGw71B5A-gzGzoHsz',
54 | 'X-LC-Key': 'XQaL1tUQC0DCQxBA9fpoR21C',
55 | };
56 |
--------------------------------------------------------------------------------
/lib/widget/GHCountItemWidget.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 | typedef clickCallback = void Function(int value);
4 |
5 | /// 显示数量子控件
6 | class GHCountItemWidger extends StatefulWidget {
7 | /// 数量
8 | int count;
9 |
10 | /// 是否可以点击
11 | bool isEnable;
12 |
13 | final clickCallback addClick;
14 | final clickCallback subClick;
15 |
16 | GHCountItemWidger({
17 | Key key,
18 | this.isEnable = true,
19 | this.count,
20 | this.addClick,
21 | this.subClick,
22 | }) : super(key: key);
23 |
24 | _GHCountItemWidgerState createState() => _GHCountItemWidgerState();
25 | }
26 |
27 | class _GHCountItemWidgerState extends State {
28 | @override
29 |
30 | /// 数量
31 | int _count;
32 |
33 | void initState() {
34 | super.initState();
35 | this._count = widget.count;
36 | }
37 |
38 | Widget _centerNumber() {
39 | return Container(
40 | decoration: BoxDecoration(
41 | border: Border.all(
42 | width: 1,
43 | color: Colors.black12,
44 | )),
45 | child: Row(
46 | children: [
47 | Container(
48 | alignment: Alignment.center,
49 | width: 40,
50 | height: 20,
51 | child: Text("${this._count}"),
52 | decoration: BoxDecoration(
53 | border: Border(
54 | left: BorderSide(
55 | width: 0.5,
56 | color: Colors.black12,
57 | ),
58 | right: BorderSide(
59 | width: 1,
60 | color: Colors.black12,
61 | )),
62 | ),
63 | ),
64 | ],
65 | ),
66 | );
67 | }
68 |
69 | Widget _rightNumber() {
70 | return GestureDetector(
71 | behavior: HitTestBehavior.opaque,
72 | onTap: () {
73 | if (!widget.isEnable) {
74 | print("禁止响应");
75 | return;
76 | }
77 | setState(() {
78 | this._count++;
79 | });
80 | widget.addClick(this._count);
81 | },
82 | child: Container(
83 | decoration: BoxDecoration(
84 | border: Border.all(
85 | width: 1,
86 | color: Colors.black12,
87 | )),
88 | child: Row(
89 | children: [
90 | Container(
91 | alignment: Alignment.center,
92 | width: 20,
93 | height: 20,
94 | child: Text("+"),
95 | ),
96 | ],
97 | ),
98 | ),
99 | );
100 | }
101 |
102 | Widget _leftNumber() {
103 | return GestureDetector(
104 | onTap: () {
105 | if (!widget.isEnable) {
106 | print("禁止响应");
107 | return;
108 | }
109 |
110 | if (this._count > 1) {
111 | setState(() {
112 | this._count--;
113 | });
114 | }
115 | widget.subClick(this._count);
116 | },
117 | behavior: HitTestBehavior.opaque,
118 | child: Container(
119 | decoration: BoxDecoration(
120 | border: Border.all(
121 | width: 1,
122 | color: Colors.black12,
123 | )),
124 | child: Row(
125 | children: [
126 | Container(
127 | alignment: Alignment.center,
128 | width: 20,
129 | height: 20,
130 | child: Text("-"),
131 | ),
132 | ],
133 | ),
134 | ),
135 | );
136 | }
137 |
138 | Widget build(BuildContext context) {
139 | return Container(
140 | padding: EdgeInsets.all(10),
141 | child: Row(
142 | mainAxisAlignment: MainAxisAlignment.end,
143 | children: [
144 | this._leftNumber(),
145 | this._centerNumber(),
146 | this._rightNumber(),
147 | ],
148 | ),
149 | );
150 | }
151 | }
152 |
--------------------------------------------------------------------------------
/lib/widget/LoadingWidget.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 | class LoadingWidget extends StatelessWidget {
4 | const LoadingWidget({Key key}) : super(key: key);
5 |
6 | @override
7 | Widget build(BuildContext context) {
8 | return Center(
9 | child: Padding(
10 | padding: EdgeInsets.all(10.0),
11 | child: Row(
12 | mainAxisAlignment: MainAxisAlignment.center,
13 | crossAxisAlignment: CrossAxisAlignment.center,
14 | children: [
15 | CircularProgressIndicator(
16 | strokeWidth: 1.0,
17 | ),
18 | SizedBox(width: 10),
19 | Text(
20 | '正在加载',
21 | style: TextStyle(fontSize: 14.0),
22 | )
23 | ],
24 | ),
25 | ),
26 | );
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/pubspec.yaml:
--------------------------------------------------------------------------------
1 | name: ghshopcart_flutter
2 | description: A new Flutter project.
3 |
4 | # The following defines the version and build number for your application.
5 | # A version number is three numbers separated by dots, like 1.2.43
6 | # followed by an optional build number separated by a +.
7 | # Both the version and the builder number may be overridden in flutter
8 | # build by specifying --build-name and --build-number, respectively.
9 | # In Android, build-name is used as versionName while build-number used as versionCode.
10 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning
11 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
12 | # Read more about iOS versioning at
13 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
14 | version: 1.0.0+1
15 |
16 | environment:
17 | sdk: ">=2.1.0 <3.0.0"
18 |
19 | dependencies:
20 | flutter:
21 | sdk: flutter
22 |
23 | # The following adds the Cupertino Icons font to your application.
24 | # Use with the CupertinoIcons class for iOS style icons.
25 | cupertino_icons: ^0.1.2
26 | flutter_screenutil: ^2.1.0
27 | dio: ^2.1.7
28 | shared_preferences: ^0.5.3+1
29 | flutter_webview_plugin: ^0.3.0
30 | event_bus: ^1.1.0
31 | provider: ^3.0.0+1
32 | fluttertoast: ^3.1.0
33 | sqflite: ^1.1.5
34 | city_pickers: ^0.1.30
35 | common_utils: ^1.2.1
36 | flutter_easyrefresh: ^2.1.1
37 | transparent_image: ^1.0.0
38 |
39 | dev_dependencies:
40 | flutter_test:
41 | sdk: flutter
42 |
43 |
44 | # For information on the generic Dart part of this file, see the
45 | # following page: https://dart.dev/tools/pub/pubspec
46 |
47 | # The following section is specific to Flutter.
48 | flutter:
49 |
50 | # The following line ensures that the Material Icons font is
51 | # included with your application, so that you can use the icons in
52 | # the material Icons class.
53 | uses-material-design: true
54 |
55 | # To add assets to your application, add an assets section, like this:
56 | assets:
57 | - images/checkNormal.png
58 | - images/checkSelected.png
59 | # An image asset can refer to one or more resolution-specific "variants", see
60 | # https://flutter.dev/assets-and-images/#resolution-aware.
61 |
62 | # For details regarding adding assets from package dependencies, see
63 | # https://flutter.dev/assets-and-images/#from-packages
64 |
65 | # To add custom fonts to your application, add a fonts section here,
66 | # in this "flutter" section. Each entry in this list should have a
67 | # "family" key with the font family name, and a "fonts" key with a
68 | # list giving the asset and other descriptors for the font. For
69 | # example:
70 | # fonts:
71 | # - family: Schyler
72 | # fonts:
73 | # - asset: fonts/Schyler-Regular.ttf
74 | # - asset: fonts/Schyler-Italic.ttf
75 | # style: italic
76 | # - family: Trajan Pro
77 | # fonts:
78 | # - asset: fonts/TrajanPro.ttf
79 | # - asset: fonts/TrajanPro_Bold.ttf
80 | # weight: 700
81 | #
82 | # For details regarding fonts from package dependencies,
83 | # see https://flutter.dev/custom-fonts/#from-packages
84 |
--------------------------------------------------------------------------------
/test/widget_test.dart:
--------------------------------------------------------------------------------
1 | // This is a basic Flutter widget test.
2 | //
3 | // To perform an interaction with a widget in your test, use the WidgetTester
4 | // utility that Flutter provides. For example, you can send tap and scroll
5 | // gestures. You can also use WidgetTester to find child widgets in the widget
6 | // tree, read text, and verify that the values of widget properties are correct.
7 |
8 | import 'package:flutter/material.dart';
9 | import 'package:flutter_test/flutter_test.dart';
10 |
11 | import 'package:ghshopcart_flutter/main.dart';
12 |
13 | void main() {
14 | testWidgets('Counter increments smoke test', (WidgetTester tester) async {
15 | // Build our app and trigger a frame.
16 | await tester.pumpWidget(MyApp());
17 |
18 | // Verify that our counter starts at 0.
19 | expect(find.text('0'), findsOneWidget);
20 | expect(find.text('1'), findsNothing);
21 |
22 | // Tap the '+' icon and trigger a frame.
23 | await tester.tap(find.byIcon(Icons.add));
24 | await tester.pump();
25 |
26 | // Verify that our counter has incremented.
27 | expect(find.text('0'), findsNothing);
28 | expect(find.text('1'), findsOneWidget);
29 | });
30 | }
31 |
--------------------------------------------------------------------------------