version23.8Beta accede a warehouse
This commit is contained in:
parent
b28c3b2c84
commit
c2f4239ff0
|
@ -40,7 +40,15 @@
|
|||
</configurations>
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="3b8bed57-fcd9-4c4b-a644-0b0381aae011" name="Default" comment="Versión 23.4Beta en Sfusion">
|
||||
<list default="true" id="3b8bed57-fcd9-4c4b-a644-0b0381aae011" name="Default" comment="">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/build.gradle" beforeDir="false" afterPath="$PROJECT_DIR$/app/build.gradle" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/ExpeditionSummaryActivity.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/ExpeditionSummaryActivity.kt" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/MODELS/Ruta.java" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/MODELS/Ruta.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/MainActivity.java" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/MainActivity.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/UTILS/Utils.java" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/UTILS/Utils.java" afterDir="false" />
|
||||
</list>
|
||||
<list id="bb82280e-2612-45ba-bd45-0d90b078e5b6" name="ignore" comment="ignore">
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/5.4.1/executionHistory/executionHistory.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/5.4.1/executionHistory/executionHistory.bin" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/5.4.1/executionHistory/executionHistory.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/5.4.1/executionHistory/executionHistory.lock" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/5.4.1/fileHashes/fileHashes.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/5.4.1/fileHashes/fileHashes.bin" afterDir="false" />
|
||||
|
@ -51,34 +59,17 @@
|
|||
<change beforePath="$PROJECT_DIR$/.gradle/5.4.1/javaCompile/javaCompile.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/5.4.1/javaCompile/javaCompile.lock" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/5.4.1/javaCompile/taskHistory.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/5.4.1/javaCompile/taskHistory.bin" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/buildOutputCleanup/buildOutputCleanup.lock" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/buildOutputCleanup/buildOutputCleanup.lock" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/buildOutputCleanup/cache.properties" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/buildOutputCleanup/cache.properties" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.gradle/buildOutputCleanup/outputFiles.bin" beforeDir="false" afterPath="$PROJECT_DIR$/.gradle/buildOutputCleanup/outputFiles.bin" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.hgignore" beforeDir="false" afterPath="$PROJECT_DIR$/.hgignore" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/compiler.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/compiler.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/deploymentTargetDropDown.xml" beforeDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/misc.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/misc.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/modules/app/vn-delivery.app.iml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/modules/app/vn-delivery.app.iml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/modules/app/vn-delivery.app.main.iml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/modules/app/vn-delivery.app.main.iml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/modules/app/vn-delivery.app.unitTest.iml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/modules/app/vn-delivery.app.unitTest.iml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/apk/release/output.json" beforeDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/build.gradle" beforeDir="false" afterPath="$PROJECT_DIR$/app/build.gradle" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/google-services.json" beforeDir="false" afterPath="$PROJECT_DIR$/app/google-services.json" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/release/app-release.apk" beforeDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/release/output.json" beforeDir="false" afterPath="$PROJECT_DIR$/app/release/output.json" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/ExpeditionSummaryActivity.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/ExpeditionSummaryActivity.kt" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/Tickets.java" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/Tickets.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/UTILS/ApiUtils.java" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/UTILS/ApiUtils.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/UTILS/ApiUtilsSalix.java" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/UTILS/ApiUtilsSalix.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/build/intermediates/lint-cache/maven.google/com/google/firebase/group-index.xml" beforeDir="false" afterPath="$PROJECT_DIR$/build/intermediates/lint-cache/maven.google/com/google/firebase/group-index.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/build/intermediates/lint-cache/maven.google/master-index.xml" beforeDir="false" afterPath="$PROJECT_DIR$/build/intermediates/lint-cache/maven.google/master-index.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/vn-delivery.iml" beforeDir="false" afterPath="$PROJECT_DIR$/vn-delivery.iml" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="ExecutionTargetManager" SELECTED_TARGET="device_and_snapshot_combo_box_target[C:\Users\sergiodt\.android\avd\Pixel_2_API_24.avd]" />
|
||||
<component name="ExecutionTargetManager" SELECTED_TARGET="device_and_snapshot_combo_box_target[21114523025303]" />
|
||||
<component name="ExternalProjectsData">
|
||||
<projectState path="$PROJECT_DIR$">
|
||||
<ProjectState />
|
||||
|
@ -369,7 +360,7 @@
|
|||
<breakpoints>
|
||||
<line-breakpoint enabled="true" type="kotlin-line">
|
||||
<url>file://$PROJECT_DIR$/app/src/main/java/verdnatura/es/repartoverdnatura/ExpeditionSummaryActivity.kt</url>
|
||||
<line>319</line>
|
||||
<line>317</line>
|
||||
<option name="timeStamp" value="5" />
|
||||
</line-breakpoint>
|
||||
</breakpoints>
|
||||
|
|
|
@ -23,10 +23,10 @@ android {
|
|||
getByName("release") {
|
||||
applicationIdSuffix = ".sfusion"
|
||||
}
|
||||
/*
|
||||
|
||||
getByName("debug") {
|
||||
applicationIdSuffix = ".sfusion"
|
||||
}*/
|
||||
}
|
||||
/* getByName("release") {
|
||||
applicationIdSuffix = ".sfusion"
|
||||
}
|
||||
|
|
|
@ -6,6 +6,7 @@ import android.content.Intent
|
|||
import android.media.MediaPlayer
|
||||
import android.os.Bundle
|
||||
import android.support.v7.app.AppCompatActivity
|
||||
import android.util.Log
|
||||
import android.view.View
|
||||
import android.view.inputmethod.InputMethodManager
|
||||
import android.widget.*
|
||||
|
@ -57,7 +58,7 @@ class ExpeditionSummaryActivity : AppCompatActivity() {
|
|||
super.onCreate(savedInstanceState)
|
||||
|
||||
setContentView(R.layout.activity_expedition_summary)
|
||||
|
||||
Log.d("VERDNATURA::",""+ localClassName)
|
||||
mpError = MediaPlayer.create((this), R.raw.error)
|
||||
mpOk = MediaPlayer.create((this), R.raw.ok)
|
||||
mpErrorRepeat = MediaPlayer.create((this), R.raw.errorrepeat)
|
||||
|
@ -76,11 +77,8 @@ class ExpeditionSummaryActivity : AppCompatActivity() {
|
|||
if (bundle != null) {
|
||||
|
||||
if (bundle.get("app") == "picking") {
|
||||
/* Utils.saveTokenUser(this,bundle.get("token").toString())
|
||||
Utils.saveUserPass(this,bundle.get("user").toString(),bundle.get("password").toString())
|
||||
Utils.saveIdUser(this,bundle.get("userId").toString())*/
|
||||
|
||||
routeOfLoad = bundle.get("routeId").toString()
|
||||
route = Ruta(routeOfLoad)
|
||||
} else {
|
||||
route = bundle.getSerializable("route") as Ruta
|
||||
routeOfLoad = route!!.id.toString()
|
||||
|
|
|
@ -51,6 +51,9 @@ public class Ruta implements Serializable {
|
|||
Chofer = chofer;
|
||||
isLoaded=isloaded;
|
||||
}
|
||||
public Ruta(String id) {
|
||||
Id = id;
|
||||
}
|
||||
|
||||
public Ruta(){}
|
||||
|
||||
|
|
|
@ -9,9 +9,7 @@ import android.content.Context;
|
|||
import android.content.DialogInterface;
|
||||
import android.content.Intent;
|
||||
import android.content.IntentFilter;
|
||||
import android.content.pm.PackageInfo;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.ActivityCompat;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
|
@ -40,7 +38,6 @@ import verdnatura.es.repartoverdnatura.INTERFACES.RestClient;
|
|||
import verdnatura.es.repartoverdnatura.MODELS.Check;
|
||||
import verdnatura.es.repartoverdnatura.MODELS.Ruta;
|
||||
import verdnatura.es.repartoverdnatura.MODELS.SignDataUpload;
|
||||
import verdnatura.es.repartoverdnatura.MODELS.Version;
|
||||
import verdnatura.es.repartoverdnatura.UTILS.ApiUtils;
|
||||
import verdnatura.es.repartoverdnatura.UTILS.LocalStorage;
|
||||
import verdnatura.es.repartoverdnatura.UTILS.Utils;
|
||||
|
@ -343,7 +340,6 @@ public class MainActivity<RouteLoaded> extends AppCompatActivity {
|
|||
}
|
||||
|
||||
|
||||
|
||||
public void logOut(View v) {
|
||||
final MainActivity that = this;
|
||||
|
||||
|
@ -352,8 +348,7 @@ public class MainActivity<RouteLoaded> extends AppCompatActivity {
|
|||
.setIcon(android.R.drawable.ic_dialog_alert)
|
||||
.setTitle("ATENCIÓN")
|
||||
.setMessage("Tienes tickets pendientes de actualizar,¿Estás seguro de cerrar sesión?")
|
||||
.setPositiveButton("Si", new DialogInterface.OnClickListener()
|
||||
{
|
||||
.setPositiveButton("Si", new DialogInterface.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
Utils.logOut(that);
|
||||
|
@ -368,8 +363,7 @@ public class MainActivity<RouteLoaded> extends AppCompatActivity {
|
|||
.setIcon(android.R.drawable.ic_dialog_alert)
|
||||
.setTitle("Cerrar sesión")
|
||||
.setMessage("¿Estás seguro de cerrar sesión?")
|
||||
.setPositiveButton("Si", new DialogInterface.OnClickListener()
|
||||
{
|
||||
.setPositiveButton("Si", new DialogInterface.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
Utils.logOut(that);
|
||||
|
@ -382,13 +376,13 @@ public class MainActivity<RouteLoaded> extends AppCompatActivity {
|
|||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
public void goToInfo(View v) {
|
||||
// startActivity(new Intent(this,InfoActivity.class));
|
||||
Utils.startPicking(this, "info");
|
||||
}
|
||||
|
||||
public void goToFound(View v) {
|
||||
startActivity(new Intent(this, ExpeditionScanActivity.class));
|
||||
}
|
||||
|
@ -476,69 +470,6 @@ public class MainActivity<RouteLoaded> extends AppCompatActivity {
|
|||
}
|
||||
}
|
||||
|
||||
public void checkVersion(){
|
||||
|
||||
String[] userData = new String[1];
|
||||
userData[0] = "delivery";
|
||||
|
||||
final MainActivity that = this;
|
||||
|
||||
//sergio: se cambia llamada Callback porque requeria un objeto y se le pasaba un true o false
|
||||
restClient.getVersion(Utils.getMapWhitUser(this),userData).enqueue(new Callback<Version>() {
|
||||
//restClient.getVersion(Utils.getMapWhitUser(this),userData).enqueue(new Callback<String>() {
|
||||
@Override
|
||||
public void onResponse(Call<Version> call, Response<Version> response) {
|
||||
if (response.isSuccessful()){
|
||||
final Version v = response.body();
|
||||
|
||||
PackageManager manager = that.getPackageManager();
|
||||
try{
|
||||
PackageInfo info = manager.getPackageInfo(that.getPackageName(), 0);
|
||||
|
||||
|
||||
|
||||
if (!v.getVersion().equals(info.versionName)){
|
||||
AlertDialog.Builder builderVersion = new AlertDialog.Builder(that);
|
||||
builderVersion.setMessage("Existe una nueva versión. Se recomienda actualizar.");
|
||||
builderVersion.setCancelable(false);
|
||||
builderVersion.setPositiveButton(
|
||||
"Actualizar",
|
||||
new DialogInterface.OnClickListener() {
|
||||
public void onClick(DialogInterface dialog, int id) {
|
||||
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse(v.getUrl())));
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
if (!v.getVersionIsCritical().equals("1")){
|
||||
builderVersion.setNegativeButton("Cancelar", new DialogInterface.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(DialogInterface dialogInterface, int i) {
|
||||
|
||||
}
|
||||
});
|
||||
}else{
|
||||
builderVersion.setMessage("Existe una nueva versión. Es necesario actualizar para un correcto funcionamiento");
|
||||
}
|
||||
AlertDialog alertVersion = builderVersion.create();
|
||||
alertVersion.show();
|
||||
}
|
||||
}catch (Exception e){
|
||||
|
||||
}
|
||||
|
||||
|
||||
}else{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFailure(Call<Version> call, Throwable t) {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
|
|
|
@ -15,6 +15,8 @@ import android.widget.EditText;
|
|||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import verdnatura.es.repartoverdnatura.LoginActivity;
|
||||
|
||||
public class Utils {
|
||||
|
||||
static SharedPreferences sp;
|
||||
|
@ -212,10 +214,10 @@ public class Utils {
|
|||
|
||||
Intent i = new Intent();
|
||||
//i.setClassName("es.verdnatura", "es.verdnatura.presentation.view.feature.login.activity.LoginActivity")
|
||||
|
||||
i.setClassName("es.verdnatura", "es.verdnatura.presentation.view.feature.main.activity.MainActivity");
|
||||
i.setClassName("es.verdnatura.sfusion", "es.verdnatura.presentation.view.feature.main.activity.MainActivity");
|
||||
i.putExtra("user", getUser(context));
|
||||
i.putExtra("password", getPass(context));
|
||||
i.putExtra("userfk", Utils.getIdUserLogin(context));
|
||||
i.putExtra("menu", option);
|
||||
context.startActivity(i);
|
||||
|
||||
|
|
Loading…
Reference in New Issue