Skip to content

Commit

Permalink
feat: add navigator to selling screen
Browse files Browse the repository at this point in the history
  • Loading branch information
boroboro01 committed Oct 16, 2024
1 parent 01a4cad commit 3210d1b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/screens/selling/end_selling_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class _EndSellingScreenState extends State<EndSellingScreen> {
textAlign: TextAlign.center,
),
const Text(
'기기 수거를 위한 절차를 확인해볼까요?',
'기기 접수가 완료되면 알려드릴게요!',
style: TextStyle(
fontFamily: 'Pretendard',
fontSize: 20.0,
Expand Down
8 changes: 7 additions & 1 deletion lib/screens/selling/flaw_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import 'package:font_awesome_flutter/font_awesome_flutter.dart';
import 'package:logger/logger.dart';
import 'package:provider/provider.dart';
import 'package:saphy/provider/image_provider.dart';
import 'package:saphy/screens/selling/end_selling_screen.dart';
import 'package:saphy/service/selling_service.dart';
import 'package:saphy/utils/colors.dart';
import 'package:saphy/widgets/normal_button.dart';
Expand Down Expand Up @@ -172,7 +173,12 @@ class _FlawScreenState extends State<FlawScreen> {
"isRepaired": controllers[5].text, // 수리 여부
}
};
createSellingItem(imageFiles, requestObject);
final statecode = createSellingItem(imageFiles, requestObject);
if (statecode == 200) {
Navigator.of(context).pushReplacement(MaterialPageRoute(
builder: (context) => const EndSellingScreen(),
));
}
},
flag: true,
),
Expand Down

0 comments on commit 3210d1b

Please sign in to comment.