ajustes ip para api
This commit is contained in:
@@ -5,6 +5,7 @@ import 'package:educa_controle_acesso/widgets/text_custom.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import '../controllers/main_controllers.dart';
|
||||
import '../utils/colors.dart';
|
||||
import '../utils/fixos.dart';
|
||||
import '../widgets/buttom_custom.dart';
|
||||
import '../widgets/snackBars.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
@@ -67,7 +68,7 @@ class _LoginScreenState extends State<LoginScreen> {
|
||||
cidade = Cidades().listCidades[i].cidadeQuery.toUpperCase();
|
||||
}
|
||||
}
|
||||
final url = 'http://192.168.18.2:8000/acesso_maria?LOGIN=${inputLogin.text.toUpperCase()}&CIDADE=$cidade';
|
||||
final url = 'http://${Fixos.IP_API_PORTA}/acesso_maria?LOGIN=${inputLogin.text.toUpperCase()}&CIDADE=$cidade';
|
||||
print(url);
|
||||
final response = await http.get(Uri.parse(url));
|
||||
var map = json.decode(response.body);
|
||||
@@ -101,7 +102,7 @@ class _LoginScreenState extends State<LoginScreen> {
|
||||
}
|
||||
}
|
||||
|
||||
final url = 'http://192.168.18.2:8000/logincontrole?NO_USERNAME=${inputLogin.text.toUpperCase()}&CIDADE=$cidade';
|
||||
final url = 'http://${Fixos.IP_API_PORTA}/logincontrole?NO_USERNAME=${inputLogin.text.toUpperCase()}&CIDADE=$cidade';
|
||||
print(url);
|
||||
final response = await http.get(Uri.parse(url));
|
||||
var map = json.decode(response.body);
|
||||
@@ -149,6 +150,7 @@ class _LoginScreenState extends State<LoginScreen> {
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Spacer(),
|
||||
Container(
|
||||
child: Image.asset("assets/images/logoEduca.png",width:width * 0.15,height: height * 0.12)
|
||||
),
|
||||
@@ -170,7 +172,7 @@ class _LoginScreenState extends State<LoginScreen> {
|
||||
controller: inputSenha,
|
||||
title: 'SENHA',
|
||||
obscure: true,
|
||||
width: width * 0.18,
|
||||
width: width>900? width * 0.18:width*0.5,
|
||||
colorBorder: PaletteColors.white,
|
||||
),
|
||||
),
|
||||
@@ -181,7 +183,7 @@ class _LoginScreenState extends State<LoginScreen> {
|
||||
inputFormatters: [],
|
||||
controller: inputCodigo,
|
||||
title: 'CÓDIGO',
|
||||
width: width * 0.18,
|
||||
width: width>900? width * 0.18:width*0.5,
|
||||
colorBorder: PaletteColors.white,
|
||||
),
|
||||
),
|
||||
@@ -203,6 +205,13 @@ class _LoginScreenState extends State<LoginScreen> {
|
||||
colorBorder: PaletteColors.primaryColor,
|
||||
onPressed: ()=>verificacao(),
|
||||
),
|
||||
Spacer(),
|
||||
Row(
|
||||
children: [
|
||||
Spacer(),
|
||||
TextCustom(text: 'versão 1.0'),
|
||||
],
|
||||
)
|
||||
],
|
||||
),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user