mirror of
				https://github.com/inventree/inventree-app.git
				synced 2025-10-31 05:15:42 +00:00 
			
		
		
		
	Improve server status message
This commit is contained in:
		| @@ -146,6 +146,9 @@ class _MyHomePageState extends State<MyHomePage> { | ||||
|  | ||||
|     }).catchError((e) { | ||||
|       _serverConnection = false; | ||||
|       _serverStatusColor = Color.fromARGB(255, 250, 50, 50); | ||||
|  | ||||
|       _serverStatus = "Error connecting to $_serverAddress"; | ||||
|  | ||||
|       if (e is TimeoutException) { | ||||
|         _serverMessage = "No response from server"; | ||||
| @@ -282,10 +285,13 @@ class _MyHomePageState extends State<MyHomePage> { | ||||
|                     children: <Widget>[ | ||||
|                       Text('$_serverStatus', | ||||
|                         style: TextStyle( | ||||
|                         color: _serverStatusColor, | ||||
|                           color: _serverStatusColor, | ||||
|                           ), | ||||
|                         ), | ||||
|                       Text('$_serverMessage', | ||||
|                         style: TextStyle( | ||||
|                           color: _serverStatusColor, | ||||
|                         ), | ||||
|                       ), | ||||
|                       Text('$_serverMessage' | ||||
|                       ), | ||||
|                     ], | ||||
|                     ), | ||||
|   | ||||
		Reference in New Issue
	
	Block a user