Date Time format in Flutter dd/MM/YYYY hh:mm

前端 未结 6 1068
耶瑟儿~
耶瑟儿~ 2020-12-28 14:10

By using this :

Text(new DateTime.fromMillisecondsSinceEpoch(values[index][\"start_time\"]*1000).toString(), 

I am getting the ty

6条回答
  •  时光说笑
    2020-12-28 14:47

    var dateInFormatText = widget.snapshot["date"].toString().split("/");
    
    DateTime dateResult = new DateTime.utc(
    int.parse(dateInFormatText[2]),     
    int.parse(dateInFormatText[1]), 
    int.parse(dateInFormatText[0]));
    
    

提交回复
热议问题