Skip to content

Commit

Permalink
Merge pull request #99 from dimipay/release/1.0.5+14
Browse files Browse the repository at this point in the history
v1.0.5 프로덕션 버전 릴리즈
  • Loading branch information
doch2 authored Mar 17, 2023
2 parents 2a0e2ad + 3ab471e commit 4928d23
Show file tree
Hide file tree
Showing 13 changed files with 53 additions and 35 deletions.
12 changes: 12 additions & 0 deletions appcast.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<channel>
<title>디미페이</title>
<!-- Android -->
<item>
<title>v1.0.5</title>
<description>법인카드가 등록 가능해졌으며 UX 개선 등이 이루어졌습니다.</description>
<pubDate>Fri, 17 Mar 2023 12:00:00 +0000</pubDate>
<enclosure url="https://play.google.com/store/apps/details?id=com.develop.dimipay" sparkle:version="1.0.5" sparkle:os="android" />
</item>
<item>
<title>v1.0.4</title>
<description>마이너한 버그 수정과 UX 개선 등이 이루어졌습니다.</description>
Expand All @@ -16,6 +22,12 @@
<enclosure url="https://play.google.com/store/apps/details?id=com.develop.dimipay" sparkle:version="1.0.3" sparkle:os="android" />
</item>
<!-- IOS -->
<item>
<title>v1.0.5</title>
<description>법인카드가 등록 가능해졌으며 UX 개선 등이 이루어졌습니다.</description>
<pubDate>Fri, 17 Mar 2023 12:00:00 +0000</pubDate>
<enclosure url="https://apps.apple.com/app/id1642292289" sparkle:version="1.0.4" sparkle:os="ios" />
</item>
<item>
<title>v1.0.4</title>
<description>마이너한 버그 수정과 UX 개선 등이 이루어졌습니다.</description>
Expand Down
12 changes: 6 additions & 6 deletions ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -379,15 +379,15 @@
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 13;
CURRENT_PROJECT_VERSION = 14;
DEVELOPMENT_TEAM = X2TSPBJQ6J;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.4;
MARKETING_VERSION = 1.0.5;
PRODUCT_BUNDLE_IDENTIFIER = com.dimigo.dimipay;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down Expand Up @@ -515,15 +515,15 @@
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 13;
CURRENT_PROJECT_VERSION = 14;
DEVELOPMENT_TEAM = X2TSPBJQ6J;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.4;
MARKETING_VERSION = 1.0.5;
PRODUCT_BUNDLE_IDENTIFIER = com.dimigo.dimipay;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand All @@ -543,15 +543,15 @@
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 13;
CURRENT_PROJECT_VERSION = 14;
DEVELOPMENT_TEAM = X2TSPBJQ6J;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.4;
MARKETING_VERSION = 1.0.5;
PRODUCT_BUNDLE_IDENTIFIER = com.dimigo.dimipay;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down
2 changes: 2 additions & 0 deletions lib/app/core/utils/loader.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import 'package:firebase_core/firebase_core.dart';
import 'package:dimipay/app/data/services/upgrader/service.dart';
import 'package:get/get.dart';
import 'package:kakao_flutter_sdk/kakao_flutter_sdk.dart';
import 'package:screen_brightness/screen_brightness.dart';
import 'package:url_strategy/url_strategy.dart';
import 'package:flutter/foundation.dart';

Expand All @@ -17,6 +18,7 @@ class AppLoader {
KakaoSdk.init(nativeAppKey: TokenReference.KAKAO_NATIVE_KEY);

await Future.wait([
ScreenBrightness().setAutoReset(false),
Firebase.initializeApp(options: kIsWeb ? TokenReference.FIREBASEOPTION : null),
Get.putAsync<UpgraderService>(() => UpgraderService().init()),
Get.putAsync<AuthService>(() => AuthService(AuthRepository(ApiProvider())).init()),
Expand Down
4 changes: 2 additions & 2 deletions lib/app/data/modules/payment_method/controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ class PaymentMethodController extends GetxController with StateMixin<List<Paymen
Future<PaymentMethod> createPaymentMethod({
required String cardNumber,
required String password,
required DateTime ownerBirthday,
required String ownerPersonalNum,
required DateTime expireAt,
}) async {
PaymentMethod paymentMethod = await repository.createPaymentMethod(cardNumber: cardNumber, password: password, ownerBirthday: ownerBirthday, expireAt: expireAt);
PaymentMethod paymentMethod = await repository.createPaymentMethod(cardNumber: cardNumber, password: password, ownerPersonalNum: ownerPersonalNum, expireAt: expireAt);
_paymentMethods.value?.add(paymentMethod);
_paymentMethods.refresh();
return paymentMethod;
Expand Down
2 changes: 1 addition & 1 deletion lib/app/data/modules/payment_method/repository.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class PaymentMethodRepository {
PaymentMethodRepository(this.api);

Future<List<PaymentMethod>> getPaymentMethods() => api.getPaymentMethods();
Future<PaymentMethod> createPaymentMethod({required String cardNumber, required String password, required DateTime ownerBirthday, required DateTime expireAt}) => api.createPaymentMethod(cardNumber: cardNumber, password: password, expireAt: expireAt, ownerBirthday: ownerBirthday);
Future<PaymentMethod> createPaymentMethod({required String cardNumber, required String password, required String ownerPersonalNum, required DateTime expireAt}) => api.createPaymentMethod(cardNumber: cardNumber, password: password, expireAt: expireAt, ownerPersonalNum: ownerPersonalNum);
Future<void> patchPaymentMethod({required PaymentMethod paymentMethod}) => api.patchPaymentMethod(paymentMethod: paymentMethod);
Future<void> deletePaymentMethod({required PaymentMethod paymentMethod}) => api.deletePaymentMethod(paymentMethod: paymentMethod);
}
5 changes: 3 additions & 2 deletions lib/app/data/provider/api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ class LogInterceptor extends Interceptor {

class ApiProvider implements ApiInterface {
final Dio dio = Dio();
// final baseUrl = kReleaseMode ? 'https://api.dimipay.io' : 'https://dev.api.dimipay.io';
final baseUrl = 'https://api.dimipay.io';

ApiProvider() {
Expand Down Expand Up @@ -217,15 +218,15 @@ class ApiProvider implements ApiInterface {
Future<PaymentMethod> createPaymentMethod({
required String cardNumber,
required String password,
required DateTime ownerBirthday,
required String ownerPersonalNum,
required DateTime expireAt,
}) async {
String url = "/payment/method";
Map<String, String> body = {
"number": cardNumber,
"year": DateFormat('yyyy').format(expireAt).substring(2),
"month": DateFormat('MM').format(expireAt),
"idNo": DateFormat('yyyyMMdd').format(ownerBirthday).substring(2),
"idNo": ownerPersonalNum,
"pw": password,
};
Response response = await dio.post(url, data: body);
Expand Down
2 changes: 1 addition & 1 deletion lib/app/data/provider/api_interface.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ abstract class ApiInterface {
Future<PaymentMethod> createPaymentMethod({
required String cardNumber,
required String password,
required DateTime ownerBirthday,
required String ownerPersonalNum,
required DateTime expireAt,
});

Expand Down
6 changes: 1 addition & 5 deletions lib/app/pages/history/page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class HistoryPage extends GetView<HistoryPageController> {
for (var dailyTransaction in dailyTransactions.entries) {
children.add(TransactionGroup(date: dailyTransaction.key, transactions: dailyTransaction.value));
}
children.sort((a, b) => a.date.compareTo(b.date));
children.sort((a, b) => b.date.compareTo(a.date));
return Column(children: children);
}

Expand Down Expand Up @@ -99,10 +99,6 @@ class TransactionGroup extends StatelessWidget {
'${date.month}월 ${date.day}일',
style: DPTextTheme.REGULAR,
),
Text(
'$sum원',
style: DPTextTheme.REGULAR_IMPORTANT,
),
],
),
const SizedBox(height: 24),
Expand Down
12 changes: 8 additions & 4 deletions lib/app/pages/pay/controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ class PayPageController extends GetxController with StateMixin<String> {
Rx<String?> paymentToken = Rx(null);
PayResultSSEController payStream = Get.find<PayResultSSEController>();
int get currentIndex => paymentMethodController.paymentMethods!.indexOf(currentPaymentMethod!);
double? _screenBrightness;

@override
void onInit() async {
Expand Down Expand Up @@ -76,17 +77,20 @@ class PayPageController extends GetxController with StateMixin<String> {

Future<void> setBrightness(double brightness) async {
try {
_screenBrightness = await ScreenBrightness().system;
await ScreenBrightness().setScreenBrightness(brightness);
} catch (e) {
log(e.toString());
}
}

Future<void> resetBrightness() async {
try {
await ScreenBrightness().resetScreenBrightness();
} catch (e) {
log(e.toString());
if (_screenBrightness != null) {
try {
await ScreenBrightness().setScreenBrightness(_screenBrightness!);
} catch (e) {
log(e.toString());
}
}
}

Expand Down
2 changes: 1 addition & 1 deletion lib/app/pages/pin/page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ class PinPage extends GetView<PinPageController> {
Obx(() {
if (controller.isPinLocked.value) {
return GestureDetector(
onTap: () => launchUrl(Uri.parse('http://pf.kakao.com/_Rxanxlxj/chat')),
onTap: () => launchUrl(Uri.parse('http://pf.kakao.com/_gHxlCxj/chat')),
child: const Text(
'핀 복구하기',
style: TextStyle(fontFamily: 'Pretendard', fontWeight: FontWeight.w600, fontSize: 16, height: 1.2, color: DPColors.MAIN_THEME, decoration: TextDecoration.underline),
Expand Down
19 changes: 11 additions & 8 deletions lib/app/pages/register_card/controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -6,30 +6,31 @@ import 'package:dimipay/app/widgets/snackbar.dart';
import 'package:dio/dio.dart';
import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:intl/intl.dart';

class RegisterCardPageController extends GetxController with StateMixin {
final String? redirect = Get.arguments?['redirect'];
final PaymentMethodController paymentMethodController = Get.find<PaymentMethodController>();

final TextEditingController cardNumberFieldController = TextEditingController();
final TextEditingController expiredDateFieldController = TextEditingController();
final TextEditingController birthdayFieldController = TextEditingController();
final TextEditingController ownerPersonalNumFieldController = TextEditingController();
final TextEditingController passwordFieldController = TextEditingController();

final formKey = GlobalKey<FormState>();
final FocusScopeNode formFocusScopeNode = FocusScopeNode();

final Rx<String?> cardNumber = Rx(null);
final Rx<DateTime?> expiredAt = Rx(null);
final Rx<DateTime?> birthday = Rx(null);
final Rx<String?> ownerPersonalNum = Rx(null);
final Rx<String?> password = Rx(null);

@override
void onInit() {
change(null, status: RxStatus.success());
cardNumberFieldController.addListener(onCardNumberChange);
expiredDateFieldController.addListener(onExpireDateChange);
birthdayFieldController.addListener(onBirthdayChange);
ownerPersonalNumFieldController.addListener(onBirthdayChange);
passwordFieldController.addListener(onPasswordChange);

super.onInit();
Expand Down Expand Up @@ -92,12 +93,14 @@ class RegisterCardPageController extends GetxController with StateMixin {
}

void onBirthdayChange() {
String data = birthdayFieldController.text;
String data = ownerPersonalNumFieldController.text;
if (data.length == 6) {
birthday.value = DateTime.parse("00$data");
ownerPersonalNum.value = DateFormat('yyyyMMdd').format(DateTime.parse("00$data")).substring(2);
formFocusScopeNode.nextFocus();
} else if (data.length == 10) {
ownerPersonalNum.value = data;
} else {
birthday.value = null;
ownerPersonalNum.value = null;
}
}

Expand All @@ -112,7 +115,7 @@ class RegisterCardPageController extends GetxController with StateMixin {
}

bool get inputValidity {
return cardNumber.value != null && expiredAt.value != null && birthday.value != null && password.value != null;
return cardNumber.value != null && expiredAt.value != null && ownerPersonalNum.value != null && password.value != null;
}

Future<void> scanCreditCard() async {
Expand All @@ -135,7 +138,7 @@ class RegisterCardPageController extends GetxController with StateMixin {
PaymentMethod paymentMethod = await paymentMethodController.createPaymentMethod(
cardNumber: cardNumber.value!,
password: password.value!,
ownerBirthday: birthday.value!,
ownerPersonalNum: ownerPersonalNum.value!,
expireAt: expiredAt.value!,
);

Expand Down
8 changes: 4 additions & 4 deletions lib/app/pages/register_card/page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@ class RegisterCardPage extends GetView<RegisterCardPageController> {
Flexible(
child: DPTextFormField(
enableInteractiveSelection: false,
controller: controller.birthdayFieldController,
controller: controller.ownerPersonalNumFieldController,
textInputType: TextInputType.number,
label: '생년 월일',
hintText: '6자리',
maxLength: 6,
label: '생년월일 / 사업자번호',
hintText: '6 / 10자리',
maxLength: 10,
),
),
],
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ publish_to: "none" # Remove this line if you wish to publish to pub.dev
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version: 1.0.4+13
version: 1.0.5+14

environment:
sdk: ">=2.17.0 <3.0.0"
Expand Down

0 comments on commit 4928d23

Please sign in to comment.