Android 为什么';这架战机的尸体上没有任何东西吗?

Android 为什么';这架战机的尸体上没有任何东西吗?,android,flutter,dart,Android,Flutter,Dart,正在讨论的类是从另一个页面调用的 onPressed: () { Navigator.push(context, MaterialPageRoute( builder: (context) => ProPage(iD: bestRatedPros[index]["ID"]))

正在讨论的类是从另一个页面调用的

 onPressed: () {
                                Navigator.push(context, MaterialPageRoute(
                                    builder: (context) =>
                                        ProPage(iD: bestRatedPros[index]["ID"])));
                              },
其中,bestRatedPros是具有以下类的变量iD的映射列表-

    import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';

class ProPage extends StatefulWidget {
  ProPage({Key key, this.iD}) : super(key: key);
  final iD;
  @override
  _ProPageState createState() => _ProPageState(iD);
}

class _ProPageState extends State<ProPage> {
  int iD;
  _ProPageState(this.iD);


  @override
  void initState() {
    super.initState();
  }

  Widget build(BuildContext context) {
    return Scaffold(
        backgroundColor: Colors.amber,
        extendBodyBehindAppBar: true,
        appBar: AppBar(
          iconTheme: IconThemeData(
            color: Colors.white, //change your color here
          ),
          elevation: 0,
          backgroundColor: Colors.amber
        ),
        body: 
           Text("EWFWEFEWEWFWEF",style: TextStyle(color: Colors.black))


    );
  }
}
import'包装:flift/cupertino.dart';
进口“包装:颤振/材料.省道”;
类传播扩展了StatefulWidget{
ProPage({Key-Key,this.iD}):super(Key:Key);
最终iD;
@凌驾
_孕母细胞createState()=>\u孕母细胞(iD);
}
类_-孕前体扩展状态{
int-iD;
_丙孕酯(this.iD);
@凌驾
void initState(){
super.initState();
}
小部件构建(构建上下文){
返回脚手架(
背景颜色:Colors.amber,
extendedBodyBehindAppBar:true,
appBar:appBar(
iconTheme:IconThemeData(
颜色:Colors.white,//在此处更改颜色
),
海拔:0,
背景颜色:Colors.amber
),
正文:
文本(“EWFWEF”,样式:TextStyle(颜色:Colors.black))
);
}
}
getDataFromBackend函数和 所有与之相关的变量都应该在体内。但不管是什么,身体里都没有任何东西。即使是一个简单的文本小部件也不能。我只是尝试将变量iD从一个页面传递到另一个页面,而不会使事情复杂化。运行日志没有显示任何错误或警告。

Arun

请参见下面的文本位置:

原因是您指定了:

extendedbodybehindappbar:true,
在您的脚手架上,因此主体被展开,其顶部隐藏在AppBar