对接:我的房屋:修改选中的房产审核id

问卷调查/活动投票 未在进行中状态不可提交
hmxc
张萌 4 years ago
parent d9de27a01f
commit 389527ea47

@ -77,6 +77,9 @@ class _User {
/// ///
String get deleteHouse => '/user/myHouse/falseDelete'; String get deleteHouse => '/user/myHouse/falseDelete';
///id
String get changeSelectExanmineId => '/user/myHouse/changeSelectExamineId';
/// ///
String get carParkingList => '/user/myParkingSpace/list'; String get carParkingList => '/user/myParkingSpace/list';

@ -264,7 +264,9 @@ class _VotingDetailPageState extends State<VotingDetailPage> {
), ),
), ),
bottomNavi: BottomButton( bottomNavi: BottomButton(
onPressed: () async { onPressed: _model.status != 2
? () {}
: () async {
if (_selectId == null) { if (_selectId == null) {
BotToast.showText(text: '请先选择候选人!'); BotToast.showText(text: '请先选择候选人!');
} else { } else {
@ -279,7 +281,12 @@ class _VotingDetailPageState extends State<VotingDetailPage> {
} }
} }
}, },
child: '投票'.text.black.size(28.sp).bold.make()), child: '投票'
.text
.color(_model.status != 2 ? ktextSubColor : ktextPrimary)
.size(28.sp)
.bold
.make()),
); );
} }
} }

@ -1,5 +1,6 @@
import 'package:akuCommunity/base/base_style.dart'; import 'package:akuCommunity/base/base_style.dart';
import 'package:akuCommunity/pages/home/home_page.dart'; import 'package:akuCommunity/pages/home/home_page.dart';
import 'package:akuCommunity/pages/tab_navigator.dart';
import 'package:akuCommunity/widget/bee_scaffold.dart'; import 'package:akuCommunity/widget/bee_scaffold.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
@ -59,7 +60,7 @@ class _BorrowFinshPageState extends State<BorrowFinshPage> {
minWidth: double.infinity, minWidth: double.infinity,
onPressed: widget.isSuccess onPressed: widget.isSuccess
? () { ? () {
Get.offAll(HomePage()); Get.offAll(TabNavigator());
} }
: () { : () {
Get.back(); Get.back();

@ -22,7 +22,8 @@ import 'package:akuCommunity/widget/buttons/bottom_button.dart';
class QuestionnaireDetailPage extends StatefulWidget { class QuestionnaireDetailPage extends StatefulWidget {
final int id; final int id;
QuestionnaireDetailPage({Key key, this.id}) : super(key: key); final int status;
QuestionnaireDetailPage({Key key, this.id, this.status}) : super(key: key);
@override @override
_QuestionnaireDetailPageState createState() => _QuestionnaireDetailPageState createState() =>
@ -253,10 +254,17 @@ class _QuestionnaireDetailPageState extends State<QuestionnaireDetailPage> {
), ),
), ),
bottomNavi: BottomButton( bottomNavi: BottomButton(
child: '确认提交'.text.black.size(32.sp).bold.make(), child: '确认提交'
onPressed: () async { .text
BaseModel baseModel = .color(widget.status != 2 ? ktextSubColor : ktextPrimary)
await ManagerFunc.questionnaireSubmit(widget.id, _submitModels); .size(32.sp)
.bold
.make(),
onPressed: widget.status != 2
? () {}
: () async {
BaseModel baseModel = await ManagerFunc.questionnaireSubmit(
widget.id, _submitModels);
Get.to(() => SubmitComplishPage( Get.to(() => SubmitComplishPage(
status: baseModel.status, status: baseModel.status,
message: baseModel.message, message: baseModel.message,

@ -47,6 +47,7 @@ class _QuestionnairePageState extends State<QuestionnairePage> {
onTap: () { onTap: () {
Get.to(() => QuestionnaireDetailPage( Get.to(() => QuestionnaireDetailPage(
id: model.id, id: model.id,
status: model.status,
)); ));
}, },
child: Container( child: Container(

@ -227,9 +227,11 @@ class _HouseCard extends StatelessWidget {
), ),
], ],
), ),
onPressed: () { onPressed: () async {
final appProvider = Provider.of<AppProvider>(context, listen: false); final appProvider = Provider.of<AppProvider>(context, listen: false);
appProvider.setCurrentHouse(model); appProvider.setCurrentHouse(model);
//id
await NetUtil().get(API.user.changeSelectExanmineId,params: {"examineId":model.estateId});
Get.back(); Get.back();
}, },
), ),

Loading…
Cancel
Save