Finish v1_0_33(36)
118
.idea/assetWizardSettings.xml
generated
@ -3,6 +3,124 @@
|
||||
<component name="WizardSettings">
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="imageWizard">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="imageAssetPanel">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="actionbar">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="clipArt">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="color" value="000000" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
</map>
|
||||
</option>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="theme" value="HOLO_DARK" />
|
||||
<entry key="themeColor" value="ffffff" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
<entry key="launcher">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="foregroundImage">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="color" value="000000" />
|
||||
<entry key="trimmed" value="true" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
</map>
|
||||
</option>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="backgroundAssetType" value="COLOR" />
|
||||
<entry key="backgroundColor" value="ffffff" />
|
||||
<entry key="foregroundImage" value="C:\Work\Prod_Android\WMS_Native\ext_sources\RoundLogoWithText.png" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
<entry key="launcherLegacy">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="clipArt">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="color" value="000000" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
<entry key="notification">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="children">
|
||||
<map>
|
||||
<entry key="clipArt">
|
||||
<value>
|
||||
<PersistentState>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="color" value="000000" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
</value>
|
||||
</entry>
|
||||
<entry key="vectorWizard">
|
||||
<value>
|
||||
<PersistentState>
|
||||
|
||||
BIN
.idea/caches/build_file_checksums.ser
generated
2
.idea/gradle.xml
generated
@ -10,6 +10,8 @@
|
||||
<option value="$PROJECT_DIR$" />
|
||||
<option value="$PROJECT_DIR$/app" />
|
||||
<option value="$PROJECT_DIR$/barcode_base_library" />
|
||||
<option value="$PROJECT_DIR$/dynamic__base" />
|
||||
<option value="$PROJECT_DIR$/dynamic_vgalimenti" />
|
||||
<option value="$PROJECT_DIR$/pointmobilescannerlibrary" />
|
||||
<option value="$PROJECT_DIR$/waterfall_toolbar" />
|
||||
</set>
|
||||
|
||||
2
.idea/modules.xml
generated
@ -5,6 +5,8 @@
|
||||
<module fileurl="file://$PROJECT_DIR$/WMS_Native.iml" filepath="$PROJECT_DIR$/WMS_Native.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/app/app.iml" filepath="$PROJECT_DIR$/app/app.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/barcode_base_library/barcode_base_library.iml" filepath="$PROJECT_DIR$/barcode_base_library/barcode_base_library.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/dynamic__base/dynamic__base.iml" filepath="$PROJECT_DIR$/dynamic__base/dynamic__base.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/dynamic_vgalimenti/dynamic_vgalimenti.iml" filepath="$PROJECT_DIR$/dynamic_vgalimenti/dynamic_vgalimenti.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/pointmobilescannerlibrary/pointmobilescannerlibrary.iml" filepath="$PROJECT_DIR$/pointmobilescannerlibrary/pointmobilescannerlibrary.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/waterfall_toolbar/waterfall_toolbar.iml" filepath="$PROJECT_DIR$/waterfall_toolbar/waterfall_toolbar.iml" />
|
||||
</modules>
|
||||
|
||||
@ -17,8 +17,8 @@ apply plugin: 'com.google.gms.google-services'
|
||||
|
||||
android {
|
||||
|
||||
def appVersionCode = 35
|
||||
def appVersionName = '1.0.32'
|
||||
def appVersionCode = 36
|
||||
def appVersionName = '1.0.33'
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
@ -37,6 +37,7 @@ android {
|
||||
|
||||
compileSdkVersion 28
|
||||
buildToolsVersion '28.0.3'
|
||||
|
||||
defaultConfig {
|
||||
applicationId "it.integry.integrywmsnative"
|
||||
minSdkVersion 21
|
||||
@ -46,6 +47,7 @@ android {
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
@ -80,6 +82,10 @@ android {
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
dynamicFeatures = [":dynamic__base"]
|
||||
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
@ -89,16 +95,16 @@ dependencies {
|
||||
})
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
||||
implementation 'com.orhanobut:logger:2.2.0'
|
||||
implementation 'com.google.firebase:firebase-core:16.0.6'
|
||||
implementation 'com.google.firebase:firebase-core:16.0.7'
|
||||
implementation 'com.google.firebase:firebase-crash:16.2.1'
|
||||
implementation 'com.google.firebase:firebase-perf:16.2.3'
|
||||
implementation 'com.crashlytics.sdk.android:crashlytics:2.9.8'
|
||||
implementation 'androidx.appcompat:appcompat:1.1.0-alpha01'
|
||||
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
|
||||
implementation 'com.google.android.material:material:1.1.0-alpha02'
|
||||
implementation 'com.google.android.material:material:1.1.0-alpha03'
|
||||
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha3'
|
||||
implementation 'androidx.cardview:cardview:1.0.0'
|
||||
implementation 'androidx.recyclerview:recyclerview:1.1.0-alpha01'
|
||||
implementation 'androidx.recyclerview:recyclerview:1.1.0-alpha02'
|
||||
implementation 'androidx.preference:preference:1.1.0-alpha02'
|
||||
implementation 'com.squareup.okhttp3:okhttp:3.12.1'
|
||||
implementation 'com.squareup.retrofit2:retrofit:2.3.0'
|
||||
@ -108,8 +114,8 @@ dependencies {
|
||||
implementation 'androidx.lifecycle:lifecycle-extensions:2.0.0'
|
||||
implementation 'androidx.lifecycle:lifecycle-common-java8:2.0.0'
|
||||
kapt "androidx.lifecycle:lifecycle-compiler:2.0.0"
|
||||
//implementation "com.emreeran.permissionlivedata:permissionlivedata:1.0.4"
|
||||
//implementation 'com.karumi:dexter:5.0.0'
|
||||
implementation 'com.danielpuiu:ghostfish:2.0.0'
|
||||
annotationProcessor "com.danielpuiu:ghostfish-compiler:2.0.0"
|
||||
//MVVM
|
||||
implementation 'androidx.lifecycle:lifecycle-extensions:2.0.0'
|
||||
annotationProcessor "androidx.lifecycle:lifecycle-compiler:2.0.0"
|
||||
@ -122,7 +128,6 @@ dependencies {
|
||||
annotationProcessor 'com.jakewharton:butterknife-compiler:10.0.0'
|
||||
implementation 'br.com.zbra:android-linq:1.1.0'
|
||||
//FAB
|
||||
//implementation 'com.getbase:floatingactionbutton:1.10.1'
|
||||
implementation 'com.github.clans:fab:1.6.4'
|
||||
//CUSTOM VIEWS
|
||||
implementation 'com.github.NaimishTrivedi:FBToast:1.0'
|
||||
|
||||
@ -12,9 +12,9 @@
|
||||
android:name=".MainApplication"
|
||||
android:allowBackup="true"
|
||||
android:hardwareAccelerated="true"
|
||||
android:icon="@drawable/integry_round_icon"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/app_name"
|
||||
android:roundIcon="@drawable/integry_round_icon"
|
||||
android:roundIcon="@mipmap/ic_launcher_round"
|
||||
android:supportsRtl="true"
|
||||
android:usesCleartextTraffic="true"
|
||||
android:theme="@style/AppTheme">
|
||||
|
||||
BIN
app/src/main/ic_launcher-web.png
Normal file
|
After Width: | Height: | Size: 33 KiB |
@ -1,31 +1,10 @@
|
||||
package it.integry.integrywmsnative;
|
||||
|
||||
import android.app.Application;
|
||||
import android.content.Context;
|
||||
import android.content.res.Configuration;
|
||||
import android.content.res.Resources;
|
||||
import android.text.SpannableString;
|
||||
|
||||
import com.crashlytics.android.Crashlytics;
|
||||
import com.google.firebase.perf.FirebasePerformance;
|
||||
import com.google.firebase.perf.metrics.Trace;
|
||||
import com.orhanobut.logger.AndroidLogAdapter;
|
||||
import com.orhanobut.logger.Logger;
|
||||
|
||||
import io.fabric.sdk.android.Fabric;
|
||||
import it.integry.integrywmsnative.core.REST.watcher.ServerStatusChecker;
|
||||
import it.integry.integrywmsnative.core.barcode_reader.BarcodeManager;
|
||||
import it.integry.integrywmsnative.core.context.AppContext;
|
||||
import it.integry.integrywmsnative.core.exception.ExceptionsHandler;
|
||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||
import it.integry.integrywmsnative.core.settings.Stash;
|
||||
import it.integry.integrywmsnative.core.update.UpdatesManager;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityResources;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityString;
|
||||
import it.integry.integrywmsnative.view.dialogs.DialogSimpleMessageHelper;
|
||||
import it.integry.integrywmsnative.view.dialogs.exception.DialogException;
|
||||
|
||||
public class MainApplication extends Application {
|
||||
|
||||
public static Resources res;
|
||||
|
||||
@ -39,6 +39,8 @@ public class RESTBuilder {
|
||||
clientBuilder.readTimeout(timeout, TimeUnit.SECONDS);
|
||||
clientBuilder.writeTimeout(timeout, TimeUnit.SECONDS);
|
||||
|
||||
clientBuilder.retryOnConnectionFailure(true);
|
||||
|
||||
if(addInterceptors) clientBuilder.addInterceptor(new HttpInterceptor());
|
||||
|
||||
OkHttpClient client = clientBuilder.build();
|
||||
|
||||
@ -0,0 +1,80 @@
|
||||
package it.integry.integrywmsnative.core.class_router;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.Pair;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
|
||||
public class ClassRouter {
|
||||
|
||||
public enum PATH {
|
||||
FILTRO_ORDINI_VENDITA,
|
||||
ORDINI_VENDITA
|
||||
}
|
||||
|
||||
private static Context context;
|
||||
|
||||
private static List<Pair<PATH, Class>> mRouteClasses = new ArrayList<>();
|
||||
|
||||
public static void init(Context context) {
|
||||
ClassRouter.context = context;
|
||||
}
|
||||
|
||||
private static boolean checkIClassExists(PATH path) {
|
||||
boolean methodAlreadyDeclared = false;
|
||||
|
||||
for(int i = 0; i < mRouteClasses.size() && !methodAlreadyDeclared; i++) {
|
||||
if(mRouteClasses.get(i).first == path) methodAlreadyDeclared = true;
|
||||
}
|
||||
|
||||
return methodAlreadyDeclared;
|
||||
}
|
||||
|
||||
|
||||
private static int getClassIndex(PATH path) {
|
||||
for(int i = 0; i < mRouteClasses.size(); i++) {
|
||||
if(mRouteClasses.get(i).first == path) return i;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public static void registerPath(PATH path, Class clazz) {
|
||||
if(checkIClassExists(path)) {
|
||||
//throw new MethodPathAlreadyDeclaredException(path);
|
||||
}
|
||||
|
||||
mRouteClasses.add(new Pair<>(path, clazz));
|
||||
}
|
||||
|
||||
public static void deregisterPath(PATH path) {
|
||||
if(checkIClassExists(path)) {
|
||||
mRouteClasses.remove(getClassIndex(path));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static <T> T getIstance(PATH path) {
|
||||
try {
|
||||
|
||||
if (!checkIClassExists(path)) {
|
||||
//throw new MethodPathNotRegisteredException(path);
|
||||
}
|
||||
|
||||
Class clazz = mRouteClasses.get(getClassIndex(path)).second;
|
||||
|
||||
return (T)clazz.newInstance();
|
||||
|
||||
} catch (Exception ex) {
|
||||
UtilityExceptions.defaultException(context, ex, true);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
package it.integry.integrywmsnative.core.class_router.interfaces;
|
||||
|
||||
public interface IFiltroOrdiniVendita {
|
||||
|
||||
boolean shoudShowCodMdepFilter();
|
||||
|
||||
}
|
||||
@ -0,0 +1,15 @@
|
||||
package it.integry.integrywmsnative.core.class_router.interfaces;
|
||||
|
||||
import android.app.ProgressDialog;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.gest.vendita.dto.OrdineVenditaGroupedInevasoDTO;
|
||||
|
||||
public interface IOrdiniVendita {
|
||||
|
||||
void distribuisciCollo(ProgressDialog progress, MtbColt mtbColt, List<OrdineVenditaGroupedInevasoDTO> testateOrdini, RunnableArgs<List<MtbColt>> onComplete, RunnableArgs<Exception> onFailed);
|
||||
|
||||
}
|
||||
@ -8,16 +8,11 @@ import com.orhanobut.logger.Logger;
|
||||
|
||||
import io.fabric.sdk.android.Fabric;
|
||||
import it.integry.integrywmsnative.BuildConfig;
|
||||
import it.integry.integrywmsnative.core.REST.consumers.ColliMagazzinoRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.REST.model.DistribuzioneColloDTO;
|
||||
import it.integry.integrywmsnative.core.REST.watcher.ServerStatusChecker;
|
||||
import it.integry.integrywmsnative.core.barcode_reader.BarcodeManager;
|
||||
import it.integry.integrywmsnative.core.data_recover.ColliDataRecover;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.model.secondary.GestioneEnum;
|
||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||
import it.integry.integrywmsnative.core.settings.Stash;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityResources;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityString;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityToast;
|
||||
@ -90,4 +85,5 @@ public class AppContext {
|
||||
ColliDataRecover.init(mContext);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -1,9 +1,14 @@
|
||||
package it.integry.integrywmsnative.core.context;
|
||||
|
||||
import android.content.Context;
|
||||
import android.text.SpannableString;
|
||||
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import it.integry.integrywmsnative.core.class_router.ClassRouter;
|
||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.integrywmsnative.view.dialogs.DialogSimpleMessageHelper;
|
||||
|
||||
public class MainContext {
|
||||
@ -19,6 +24,8 @@ public class MainContext {
|
||||
this.initDBData(() -> {
|
||||
onContextInitialized.run();
|
||||
});
|
||||
|
||||
this.initReflections();
|
||||
}
|
||||
|
||||
|
||||
@ -30,4 +37,28 @@ public class MainContext {
|
||||
);
|
||||
}
|
||||
|
||||
private void initReflections() {
|
||||
ClassRouter.init(mContext);
|
||||
|
||||
try {
|
||||
String initMethod = "init";
|
||||
|
||||
Class dynamicContextClass = Class.forName("it.integry.wms.dynamic_customization.DynamicContext");
|
||||
|
||||
Method[] methods = dynamicContextClass.getMethods();
|
||||
for (Method m : methods) {
|
||||
if (initMethod.equals(m.getName())) {
|
||||
// for static methods we can use null as instance of class
|
||||
final Object newInstance = dynamicContextClass.newInstance();
|
||||
|
||||
m.invoke(newInstance, (Context) mContext);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
} catch (Exception e) {
|
||||
UtilityExceptions.defaultException(mContext, e, true);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -30,7 +30,12 @@ public class UtilityExceptions {
|
||||
|
||||
public static void defaultException(Context context, Exception ex, boolean sendEmail){
|
||||
|
||||
if(ex.getMessage() != null) {
|
||||
Logger.e(ex, ex.getMessage());
|
||||
} else {
|
||||
Logger.e(ex, "Errore");
|
||||
}
|
||||
|
||||
String errorMessage = CommonRESTException.tryRecognizeThenGetMessage(ex);
|
||||
|
||||
if(errorMessage == null) errorMessage = ex.getMessage();
|
||||
|
||||
@ -547,12 +547,15 @@ public class PickingLiberoViewModel implements IRecyclerItemClicked<MtbColr> {
|
||||
|
||||
private void deleteCollo(ProgressDialog progress) {
|
||||
|
||||
ColliMagazzinoRESTConsumer.deleteCollo(this.mtbColt.get(), () -> {
|
||||
//La delete è stata commentata poichè visto che nel WMS vengono sempre presi i RESIDUI,
|
||||
//controllare che non ci siano righe per poter cancellare il collo era errato.
|
||||
//Venivano cancellati colli completamente svuotati perché il residuo dei colli è 0
|
||||
|
||||
// ColliMagazzinoRESTConsumer.deleteCollo(this.mtbColt.get(), () -> {
|
||||
this.mtbColt.set(null);
|
||||
|
||||
progress.dismiss();
|
||||
}, ex -> UtilityExceptions.defaultException(mContext, ex, progress)
|
||||
);
|
||||
// }, ex -> UtilityExceptions.defaultException(mContext, ex, progress));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@ -433,10 +433,10 @@ public class RettificaGiacenzeViewModel implements IRecyclerItemClicked<MtbColr>
|
||||
}
|
||||
} else {
|
||||
|
||||
ColliMagazzinoRESTConsumer.deleteCollo(mtbColt.get(), () -> {
|
||||
// ColliMagazzinoRESTConsumer.deleteCollo(mtbColt.get(), () -> {
|
||||
progress.dismiss();
|
||||
resetMtbColt(openNewOne);
|
||||
}, ex -> UtilityExceptions.defaultException(mContext, ex, progress));
|
||||
// }, ex -> UtilityExceptions.defaultException(mContext, ex, progress));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -35,6 +35,7 @@ import it.integry.integrywmsnative.core.interfaces.IFilterableFragment;
|
||||
import it.integry.integrywmsnative.core.interfaces.IScrollableFragment;
|
||||
import it.integry.integrywmsnative.core.interfaces.ISelectAllFragment;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.model.secondary.GestioneEnum;
|
||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityToast;
|
||||
@ -211,6 +212,7 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
rigaOrdine
|
||||
.setData(ord.getDataOrdS())
|
||||
.setNumero(ord.getNumOrd())
|
||||
.setCodMdep(ord.getCodMdep())
|
||||
.setCodAnagOrd(ord.getCodAnagOrd())
|
||||
.setCodAnagClie(groupedOrdine.codAnagClie)
|
||||
.setRagSocOrd(ord.getRagSocOrd())
|
||||
@ -328,11 +330,14 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
final ProgressDialog progress = ProgressDialog.show(getActivity(), getText(R.string.waiting),
|
||||
getText(R.string.loading) + " ...", true);
|
||||
|
||||
mHelper.retrievePickingList(barcodes, dataCons, new VenditaHelper.ILoadPickingListCallback() {
|
||||
|
||||
final String finalDataCons = dataCons;
|
||||
checkSelectedOrders(selectedOrders, () -> {
|
||||
|
||||
mHelper.retrievePickingList(barcodes, finalDataCons, new VenditaHelper.ILoadPickingListCallback() {
|
||||
@Override
|
||||
public void onLoadSuccess(final List<PickingObjectDTO> ordini) {
|
||||
|
||||
|
||||
mHelper.getBancaliVenditaGiaRegistrati(selectedOrders, mtbColtList -> {
|
||||
|
||||
progress.dismiss();
|
||||
@ -344,6 +349,9 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
|
||||
int alreadyRegisteredUL = mtbColtList.size();
|
||||
|
||||
|
||||
|
||||
|
||||
DialogSimpleMessageHelper.makeInfoDialog(getActivity(),
|
||||
getText(R.string.orders).toString(),
|
||||
Html.fromHtml(String.format(getActivity().getResources().getQuantityString(R.plurals.loaded_orders_message, barcodes.size()), barcodes.size())
|
||||
@ -352,11 +360,8 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
+ "<br />" +
|
||||
"<b>" + alreadyRegisteredUL + "</b> " + getActivity().getResources().getQuantityString(R.plurals.already_registered_lu, alreadyRegisteredUL)),
|
||||
null,
|
||||
() -> {
|
||||
|
||||
startVenditaActivity(ordini, selectedOrders, mtbColtList);
|
||||
|
||||
}).show();
|
||||
() -> startVenditaActivity(ordini, selectedOrders, mtbColtList)
|
||||
).show();
|
||||
|
||||
}, ex -> UtilityExceptions.defaultException(getActivity(), ex, progress));
|
||||
|
||||
@ -369,6 +374,9 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
});
|
||||
|
||||
|
||||
}, () -> {
|
||||
progress.dismiss();
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@ -411,8 +419,45 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
}).show();
|
||||
}
|
||||
|
||||
private void startVenditaActivity(List<PickingObjectDTO> ordini, List<OrdineVenditaGroupedInevasoDTO> selectedOrders, List<MtbColt> mtbColtList) {
|
||||
private void checkSelectedOrders(List<OrdineVenditaGroupedInevasoDTO> selectedOrders, Runnable onComplete, Runnable onFailed) {
|
||||
if(selectedOrders != null && selectedOrders.size() > 0) {
|
||||
List<OrdineVenditaGroupedInevasoDTO.Ordine> flatOrderArray = new ArrayList<>();
|
||||
|
||||
Stream.of(selectedOrders).forEach(x -> flatOrderArray.addAll(x.ordini));
|
||||
|
||||
//Definizione della gestione collo di default
|
||||
List<GestioneEnum> foundGestioni = Stream.of(flatOrderArray)
|
||||
.map(OrdineVenditaGroupedInevasoDTO.Ordine::getGestioneEnum)
|
||||
.withoutNulls()
|
||||
.distinctBy(x -> x)
|
||||
.toList();
|
||||
|
||||
if (foundGestioni != null && foundGestioni.size() > 1) {
|
||||
DialogSimpleMessageHelper.makeErrorDialog(getContext(), new SpannableString(getString(R.string.error_multiple_gest_ordv)), null, () -> {
|
||||
onFailed.run();
|
||||
}).show();
|
||||
return;
|
||||
}
|
||||
|
||||
//Definizione del deposito di default
|
||||
List<String> foundCodMdep = Stream.of(flatOrderArray)
|
||||
.map(OrdineVenditaGroupedInevasoDTO.Ordine::getCodMdep)
|
||||
.withoutNulls()
|
||||
.distinctBy(x -> x)
|
||||
.toList();
|
||||
|
||||
if (foundCodMdep != null && foundCodMdep.size() > 1) {
|
||||
DialogSimpleMessageHelper.makeErrorDialog(getContext(), new SpannableString(getString(R.string.error_multiple_cod_mdep_ordv)), null, () -> {
|
||||
onFailed.run();
|
||||
}).show();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
onComplete.run();
|
||||
}
|
||||
|
||||
private void startVenditaActivity(List<PickingObjectDTO> ordini, List<OrdineVenditaGroupedInevasoDTO> selectedOrders, List<MtbColt> mtbColtList) {
|
||||
Intent myIntent = new Intent(getActivity(), VenditaOrdineInevasoActivity.class);
|
||||
|
||||
String keyPickingList = DataCache.addItem(ordini);
|
||||
@ -425,9 +470,5 @@ public class MainVenditaFragment extends Fragment implements ITitledFragment, IS
|
||||
myIntent.putExtra("keyColliRegistrati", keyColliRegistrati);
|
||||
|
||||
getActivity().startActivity(myIntent);
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -7,6 +7,7 @@ import android.content.Context;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.widget.ArrayAdapter;
|
||||
import android.widget.Button;
|
||||
|
||||
@ -18,6 +19,8 @@ import java.util.GregorianCalendar;
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.class_router.ClassRouter;
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.IFiltroOrdiniVendita;
|
||||
import it.integry.integrywmsnative.core.di.BindableString;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgss;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityDate;
|
||||
@ -37,6 +40,7 @@ public class DialogVenditaFiltroAvanzato {
|
||||
private List<OrdineVenditaInevasoDTO> currentOrderList;
|
||||
private List<OrdineVenditaInevasoDTO> currentFilteredOrderList;
|
||||
|
||||
private Predicate<OrdineVenditaInevasoDTO> currentDepositoPredicate = null;
|
||||
private Predicate<OrdineVenditaInevasoDTO> currentNumOrdsPredicate = null;
|
||||
private Predicate<OrdineVenditaInevasoDTO> currentClientePredicate = null;
|
||||
private Predicate<OrdineVenditaInevasoDTO> currentDataConsPredicate = null;
|
||||
@ -87,7 +91,6 @@ public class DialogVenditaFiltroAvanzato {
|
||||
|
||||
Button button = ((AlertDialog) dialogInterface).getButton(AlertDialog.BUTTON_NEUTRAL);
|
||||
button.setOnClickListener(view -> {
|
||||
// TODO Do something
|
||||
resetAll(viewModel);
|
||||
});
|
||||
});
|
||||
@ -101,7 +104,7 @@ public class DialogVenditaFiltroAvanzato {
|
||||
}
|
||||
|
||||
private void resetAll(DialogVenditaFiltroAvanzatoViewModel viewModel) {
|
||||
viewModel.numOrds.set(null);
|
||||
viewModel.deposito.set(null);
|
||||
viewModel.numOrds.set(null);
|
||||
viewModel.cliente.set(null);
|
||||
viewModel.dataConsegna.set(null);
|
||||
@ -111,6 +114,7 @@ public class DialogVenditaFiltroAvanzato {
|
||||
}
|
||||
|
||||
private void initView(DialogVenditaFiltroAvanzatoBinding bindings, DialogVenditaFiltroAvanzatoViewModel viewModel) {
|
||||
IFiltroOrdiniVendita filtroOrdiniVendita = ClassRouter.getIstance(ClassRouter.PATH.FILTRO_ORDINI_VENDITA);
|
||||
|
||||
bindings.inputDataCons.setOnClickListener(view -> {
|
||||
Calendar c = Calendar.getInstance();
|
||||
@ -133,6 +137,22 @@ public class DialogVenditaFiltroAvanzato {
|
||||
datePickerDialog.show();
|
||||
});
|
||||
|
||||
bindings.inputCodMdep.setVisibility(filtroOrdiniVendita.shoudShowCodMdepFilter() ? View.VISIBLE : View.GONE);
|
||||
bindings.inputCodMdep.setOnClickListener(view -> {
|
||||
|
||||
AlertDialog.Builder builderSingle = new AlertDialog.Builder(currentContext);
|
||||
builderSingle.setTitle(R.string.deposit);
|
||||
|
||||
final ArrayAdapter<String> arrayAdapter = new ArrayAdapter(currentContext, android.R.layout.select_dialog_singlechoice);
|
||||
arrayAdapter.addAll(getAvailableCodMdeps());
|
||||
|
||||
builderSingle.setAdapter(arrayAdapter, (dialogInterface, i) -> {
|
||||
viewModel.deposito.set(arrayAdapter.getItem(i));
|
||||
});
|
||||
builderSingle.show();
|
||||
|
||||
});
|
||||
|
||||
bindings.inputTermCons.setOnClickListener(view -> {
|
||||
|
||||
AlertDialog.Builder builderSingle = new AlertDialog.Builder(currentContext);
|
||||
@ -188,7 +208,6 @@ public class DialogVenditaFiltroAvanzato {
|
||||
BindableString.registerListener(viewModel.numOrds, value -> {
|
||||
if(UtilityString.isNullOrEmpty(value)) currentNumOrdsPredicate = null;
|
||||
else {
|
||||
//String numOrdTrimmed = value.replaceAll(" ", "");
|
||||
String[] numOrdsSplitted = value.split("[,\\ ]");
|
||||
|
||||
|
||||
@ -227,6 +246,18 @@ public class DialogVenditaFiltroAvanzato {
|
||||
viewModel.cliente.refresh();
|
||||
|
||||
|
||||
BindableString.resetListeners(viewModel.deposito);
|
||||
BindableString.registerListener(viewModel.deposito, value -> {
|
||||
if(UtilityString.isNullOrEmpty(value)) currentDepositoPredicate = null;
|
||||
else {
|
||||
currentDepositoPredicate = o -> o.getCodMdep().toLowerCase().contains(value);
|
||||
}
|
||||
|
||||
if(!firstInit) refreshList();
|
||||
});
|
||||
viewModel.deposito.refresh();
|
||||
|
||||
|
||||
|
||||
|
||||
BindableString.resetListeners(viewModel.dataConsegna);
|
||||
@ -285,8 +316,8 @@ public class DialogVenditaFiltroAvanzato {
|
||||
|
||||
}
|
||||
|
||||
private List<String> getAvailableTermCons() {
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentAutomezzoPredicate == null && currentVettorePredicate == null){
|
||||
private List<String> getAvailableCodMdeps() {
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentAutomezzoPredicate == null && currentVettorePredicate == null && currentTermConsPredicate == null){
|
||||
currentFilteredOrderList = currentOrderList;
|
||||
} else {
|
||||
Stream<OrdineVenditaInevasoDTO> tmpStream = Stream.of(currentOrderList)
|
||||
@ -295,7 +326,28 @@ public class DialogVenditaFiltroAvanzato {
|
||||
(currentClientePredicate == null || (currentClientePredicate != null && currentClientePredicate.test(x))) &&
|
||||
(currentDataConsPredicate == null || (currentDataConsPredicate != null && currentDataConsPredicate.test(x))) &&
|
||||
(currentVettorePredicate == null || (currentVettorePredicate != null && currentVettorePredicate.test(x))) &&
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate.test(x)))
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate.test(x))) &&
|
||||
(currentTermConsPredicate == null || (currentTermConsPredicate != null && currentTermConsPredicate.test(x)))
|
||||
);
|
||||
|
||||
currentFilteredOrderList = tmpStream.toList();
|
||||
}
|
||||
|
||||
return Stream.of(currentFilteredOrderList).map(OrdineVenditaInevasoDTO::getCodMdep).distinct().withoutNulls().toList();
|
||||
}
|
||||
|
||||
private List<String> getAvailableTermCons() {
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentAutomezzoPredicate == null && currentVettorePredicate == null && currentDepositoPredicate == null){
|
||||
currentFilteredOrderList = currentOrderList;
|
||||
} else {
|
||||
Stream<OrdineVenditaInevasoDTO> tmpStream = Stream.of(currentOrderList)
|
||||
.filter(x ->
|
||||
(currentNumOrdsPredicate == null || (currentNumOrdsPredicate != null && currentNumOrdsPredicate.test(x))) &&
|
||||
(currentClientePredicate == null || (currentClientePredicate != null && currentClientePredicate.test(x))) &&
|
||||
(currentDataConsPredicate == null || (currentDataConsPredicate != null && currentDataConsPredicate.test(x))) &&
|
||||
(currentVettorePredicate == null || (currentVettorePredicate != null && currentVettorePredicate.test(x))) &&
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate.test(x))) &&
|
||||
(currentDepositoPredicate == null || (currentDepositoPredicate != null && currentDepositoPredicate.test(x)))
|
||||
);
|
||||
|
||||
currentFilteredOrderList = tmpStream.toList();
|
||||
@ -305,7 +357,7 @@ public class DialogVenditaFiltroAvanzato {
|
||||
}
|
||||
|
||||
private List<String> getAvailableVettori() {
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentTermConsPredicate == null && currentAutomezzoPredicate == null){
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentTermConsPredicate == null && currentAutomezzoPredicate == null && currentDepositoPredicate == null){
|
||||
currentFilteredOrderList = currentOrderList;
|
||||
} else {
|
||||
Stream<OrdineVenditaInevasoDTO> tmpStream = Stream.of(currentOrderList)
|
||||
@ -314,7 +366,8 @@ public class DialogVenditaFiltroAvanzato {
|
||||
(currentClientePredicate == null || (currentClientePredicate != null && currentClientePredicate.test(x))) &&
|
||||
(currentDataConsPredicate == null || (currentDataConsPredicate != null && currentDataConsPredicate.test(x))) &&
|
||||
(currentTermConsPredicate == null || (currentTermConsPredicate != null && currentTermConsPredicate.test(x))) &&
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate .test(x)))
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate .test(x))) &&
|
||||
(currentDepositoPredicate == null || (currentDepositoPredicate != null && currentDepositoPredicate.test(x)))
|
||||
);
|
||||
|
||||
currentFilteredOrderList = tmpStream.toList();
|
||||
@ -324,7 +377,7 @@ public class DialogVenditaFiltroAvanzato {
|
||||
}
|
||||
|
||||
private List<String> getAvailableAutomezzi() {
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentTermConsPredicate == null && currentVettorePredicate == null){
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentTermConsPredicate == null && currentVettorePredicate == null && currentDepositoPredicate == null){
|
||||
currentFilteredOrderList = currentOrderList;
|
||||
} else {
|
||||
Stream<OrdineVenditaInevasoDTO> tmpStream = Stream.of(currentOrderList)
|
||||
@ -333,7 +386,8 @@ public class DialogVenditaFiltroAvanzato {
|
||||
(currentClientePredicate == null || (currentClientePredicate != null && currentClientePredicate.test(x))) &&
|
||||
(currentDataConsPredicate == null || (currentDataConsPredicate != null && currentDataConsPredicate.test(x))) &&
|
||||
(currentTermConsPredicate == null || (currentTermConsPredicate != null && currentTermConsPredicate.test(x))) &&
|
||||
(currentVettorePredicate == null || (currentVettorePredicate != null && currentVettorePredicate.test(x)))
|
||||
(currentVettorePredicate == null || (currentVettorePredicate != null && currentVettorePredicate.test(x))) &&
|
||||
(currentDepositoPredicate == null || (currentDepositoPredicate != null && currentDepositoPredicate.test(x)))
|
||||
);
|
||||
|
||||
currentFilteredOrderList = tmpStream.toList();
|
||||
@ -344,7 +398,7 @@ public class DialogVenditaFiltroAvanzato {
|
||||
|
||||
private void refreshList() {
|
||||
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentTermConsPredicate == null && currentVettorePredicate == null && currentAutomezzoPredicate == null){
|
||||
if(currentNumOrdsPredicate == null && currentClientePredicate == null && currentDataConsPredicate == null && currentTermConsPredicate == null && currentVettorePredicate == null && currentAutomezzoPredicate == null && currentDepositoPredicate == null){
|
||||
currentFilteredOrderList = currentOrderList;
|
||||
} else {
|
||||
Stream<OrdineVenditaInevasoDTO> tmpStream = Stream.of(currentOrderList)
|
||||
@ -354,7 +408,8 @@ public class DialogVenditaFiltroAvanzato {
|
||||
(currentDataConsPredicate == null || (currentDataConsPredicate != null && currentDataConsPredicate.test(x))) &&
|
||||
(currentTermConsPredicate == null || (currentTermConsPredicate != null && currentTermConsPredicate.test(x))) &&
|
||||
(currentVettorePredicate == null || (currentVettorePredicate != null && currentVettorePredicate.test(x))) &&
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate.test(x)))
|
||||
(currentAutomezzoPredicate == null || (currentAutomezzoPredicate != null && currentAutomezzoPredicate.test(x))) &&
|
||||
(currentDepositoPredicate == null || (currentDepositoPredicate != null && currentDepositoPredicate.test(x)))
|
||||
);
|
||||
|
||||
currentFilteredOrderList = tmpStream.toList();
|
||||
|
||||
@ -6,6 +6,7 @@ import it.integry.integrywmsnative.core.di.BindableString;
|
||||
|
||||
public class DialogVenditaFiltroAvanzatoViewModel {
|
||||
|
||||
public BindableString deposito = new BindableString();
|
||||
public BindableString numOrds = new BindableString();
|
||||
public BindableString cliente = new BindableString();
|
||||
public BindableString dataConsegna = new BindableString();
|
||||
|
||||
@ -26,6 +26,7 @@ public class OrdineVenditaGroupedInevasoDTO implements Cloneable, Serializable,
|
||||
public static class Ordine implements Parcelable{
|
||||
private String data;
|
||||
private int numero;
|
||||
private String codMdep;
|
||||
private String codAnagOrd = "";
|
||||
private String ragSocOrd = "";
|
||||
private Float pesoTotale;
|
||||
@ -76,6 +77,15 @@ public class OrdineVenditaGroupedInevasoDTO implements Cloneable, Serializable,
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMdep() {
|
||||
return codMdep;
|
||||
}
|
||||
|
||||
public Ordine setCodMdep(String codMdep) {
|
||||
this.codMdep = codMdep;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodAnagOrd() {
|
||||
return codAnagOrd;
|
||||
}
|
||||
@ -217,6 +227,7 @@ public class OrdineVenditaGroupedInevasoDTO implements Cloneable, Serializable,
|
||||
}
|
||||
gestione = in.readString();
|
||||
colliRiservati = in.readInt();
|
||||
codMdep = in.readString();
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -248,6 +259,7 @@ public class OrdineVenditaGroupedInevasoDTO implements Cloneable, Serializable,
|
||||
}
|
||||
dest.writeString(gestione);
|
||||
dest.writeInt(colliRiservati);
|
||||
dest.writeString(codMdep);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
|
||||
@ -18,6 +18,7 @@ public class OrdineVenditaInevasoDTO implements Parcelable {
|
||||
private String listino;
|
||||
private String termCons;
|
||||
private String codAuto;
|
||||
private String codMdep;
|
||||
private String descrizioneAuto;
|
||||
private String codVvet;
|
||||
private String descrizioneVettore;
|
||||
@ -57,6 +58,7 @@ public class OrdineVenditaInevasoDTO implements Parcelable {
|
||||
listino = in.readString();
|
||||
termCons = in.readString();
|
||||
codAuto = in.readString();
|
||||
codMdep = in.readString();
|
||||
descrizioneAuto = in.readString();
|
||||
codVvet = in.readString();
|
||||
descrizioneVettore = in.readString();
|
||||
@ -102,6 +104,7 @@ public class OrdineVenditaInevasoDTO implements Parcelable {
|
||||
dest.writeString(listino);
|
||||
dest.writeString(termCons);
|
||||
dest.writeString(codAuto);
|
||||
dest.writeString(codMdep);
|
||||
dest.writeString(descrizioneAuto);
|
||||
dest.writeString(codVvet);
|
||||
dest.writeString(descrizioneVettore);
|
||||
@ -212,6 +215,15 @@ public class OrdineVenditaInevasoDTO implements Parcelable {
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMdep() {
|
||||
return codMdep;
|
||||
}
|
||||
|
||||
public OrdineVenditaInevasoDTO setCodMdep(String codMdep) {
|
||||
this.codMdep = codMdep;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDescrizioneAuto() {
|
||||
return descrizioneAuto;
|
||||
}
|
||||
|
||||
@ -26,8 +26,9 @@ import it.integry.integrywmsnative.core.REST.consumers.ColliMagazzinoRESTConsume
|
||||
import it.integry.integrywmsnative.core.REST.consumers.ISimpleOperationCallback;
|
||||
import it.integry.integrywmsnative.core.REST.consumers.PosizioneRESTonsumer;
|
||||
import it.integry.integrywmsnative.core.REST.consumers.PrinterRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.REST.model.DistribuzioneColloDTO;
|
||||
import it.integry.integrywmsnative.core.barcode_reader.BarcodeManager;
|
||||
import it.integry.integrywmsnative.core.class_router.ClassRouter;
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.IOrdiniVendita;
|
||||
import it.integry.integrywmsnative.core.data_recover.ColliDataRecover;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
import it.integry.integrywmsnative.core.model.CommonModelConsts;
|
||||
@ -50,7 +51,6 @@ import it.integry.integrywmsnative.gest.vendita_ordine_inevaso.VenditaOrdineInev
|
||||
import it.integry.integrywmsnative.gest.vendita_ordine_inevaso.core.VenditaOrdineInevasoHelper;
|
||||
import it.integry.integrywmsnative.gest.vendita_ordine_inevaso.core.MainListOrdineVenditaInevasoAdapter;
|
||||
import it.integry.integrywmsnative.gest.vendita_ordine_inevaso.core.interfaces.IOnOrdineVenditaRowDispatched;
|
||||
import it.integry.integrywmsnative.ui.StatusBarAlert;
|
||||
import it.integry.integrywmsnative.view.bottomsheet.interfaces.IOnColloClosedCallback;
|
||||
import it.integry.integrywmsnative.view.bottomsheet.viewmodel.ArticoliInColloBottomSheetViewModel;
|
||||
|
||||
@ -76,6 +76,7 @@ public class VenditaOrdineInevasoViewModel implements IOnColloClosedCallback, IO
|
||||
private MainListOrdineVenditaInevasoAdapter mAdapter;
|
||||
|
||||
private GestioneEnum defaultGestioneOfUL = null;
|
||||
private String defaultCodMdepOfUL = null;
|
||||
private List<FiltroOrdineDTO> defaultFiltroOrdine = new ArrayList<>();
|
||||
private String defaultCodAnagOfUL = null;
|
||||
private String defaultRifOrdOfUL = null;
|
||||
@ -150,11 +151,9 @@ public class VenditaOrdineInevasoViewModel implements IOnColloClosedCallback, IO
|
||||
.toList();
|
||||
|
||||
if(foundGestioni != null && foundGestioni.size() > 1){
|
||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString("Impossibile caricare ordini di diverse gestioni"), null, () -> {
|
||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(mActivity.getString(R.string.error_multiple_gest_ordv)), null, () -> {
|
||||
mActivity.finish();
|
||||
}).show();
|
||||
// UtilityExceptions.defaultException(mActivity, new Exception("Impossibile caricare ordini di diverse gestioni"));
|
||||
// mActivity.finish();
|
||||
return;
|
||||
} else if(foundGestioni != null && foundGestioni.size() == 1){
|
||||
defaultGestioneOfUL = foundGestioni.get(0);
|
||||
@ -162,6 +161,24 @@ public class VenditaOrdineInevasoViewModel implements IOnColloClosedCallback, IO
|
||||
defaultGestioneOfUL = GestioneEnum.VENDITA;
|
||||
}
|
||||
|
||||
//Definizione del deposito di default
|
||||
List<String> foundCodMdep = Stream.of(flatOrderArray)
|
||||
.map(OrdineVenditaGroupedInevasoDTO.Ordine::getCodMdep)
|
||||
.withoutNulls()
|
||||
.distinctBy(x -> x)
|
||||
.toList();
|
||||
|
||||
// if(foundCodMdep != null && foundCodMdep.size() > 1){
|
||||
// DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(mActivity.getString(R.string.error_multiple_cod_mdep_ordv)), null, () -> {
|
||||
// mActivity.finish();
|
||||
// }).show();
|
||||
// return;
|
||||
// } else if(foundCodMdep != null && foundCodMdep.size() == 1){
|
||||
// defaultCodMdepOfUL = foundCodMdep.get(0);
|
||||
// } else {
|
||||
defaultCodMdepOfUL = SettingsManager.i().userSession.depo.getCodMdep();
|
||||
// }
|
||||
|
||||
|
||||
|
||||
//Definizione del filtro ordine da applicare a tutti i colli generati
|
||||
@ -717,6 +734,7 @@ public class VenditaOrdineInevasoViewModel implements IOnColloClosedCallback, IO
|
||||
.setNumOrd(defaultNumOrdOfUL)
|
||||
.setDataOrdD(defaultDataOrdOfUL)
|
||||
.setCodAnag(defaultCodAnagOfUL)
|
||||
.setCodMdep(defaultCodMdepOfUL)
|
||||
.setOperation(CommonModelConsts.OPERATION.INSERT_OR_UPDATE);
|
||||
|
||||
if(customNumCollo != null) {
|
||||
@ -825,12 +843,14 @@ public class VenditaOrdineInevasoViewModel implements IOnColloClosedCallback, IO
|
||||
|
||||
MtbColt cloneMtbColt = (MtbColt) mArticoliInColloBottomSheetViewModel.mtbColt.get().clone();
|
||||
|
||||
ColliMagazzinoRESTConsumer.distribuisciCollo(cloneMtbColt, SettingsManager.iDB().getDefaultCriterioDistribuzione(),
|
||||
mtbColts -> {
|
||||
IOrdiniVendita ordiniVendita = ClassRouter.getIstance(ClassRouter.PATH.ORDINI_VENDITA);
|
||||
|
||||
ordiniVendita.distribuisciCollo(progress, cloneMtbColt, mTestateOrdini, mtbColts -> {
|
||||
if(mtbColtSessionID != null) ColliDataRecover.closeSession(mtbColtSessionID);
|
||||
onComplete.run(mtbColts);
|
||||
},
|
||||
ex -> UtilityExceptions.defaultException(mActivity, ex, progress));
|
||||
}, ex -> {
|
||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||
});
|
||||
}
|
||||
|
||||
private void printCollo(ProgressDialog progress, List<MtbColt> mtbColtsToPrint) {
|
||||
|
||||
@ -6,6 +6,7 @@
|
||||
android:id="@+id/drawer_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/full_white"
|
||||
android:fitsSystemWindows="true"
|
||||
tools:openDrawer="start">
|
||||
|
||||
|
||||
@ -179,6 +179,7 @@
|
||||
android:visibility="@{viewmodel.isFabVisible ? View.VISIBLE : View.GONE}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
||||
fab:menu_animationDelayPerItem="50"
|
||||
fab:menu_backgroundColor="@color/white_bg_alpha"
|
||||
fab:menu_buttonSpacing="0dp"
|
||||
|
||||
@ -31,6 +31,23 @@
|
||||
android:layout_marginBottom="12dp"/>
|
||||
|
||||
|
||||
<!--<com.google.android.material.textfield.TextInputLayout-->
|
||||
<!--android:layout_width="match_parent"-->
|
||||
<!--android:layout_height="wrap_content"-->
|
||||
<!--app:hintTextAppearance="@style/hint_text">-->
|
||||
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/input_cod_mdep"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textNoSuggestions"
|
||||
android:hint="@string/deposit"
|
||||
android:focusable="false"
|
||||
app:binding="@{viewmodel.deposito}"/>
|
||||
|
||||
<!--</com.google.android.material.textfield.TextInputLayout>-->
|
||||
|
||||
<!--<com.google.android.material.textfield.TextInputLayout-->
|
||||
<!--android:layout_width="match_parent"-->
|
||||
<!--android:layout_height="wrap_content"-->
|
||||
|
||||
5
app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@color/ic_launcher_background"/>
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
|
||||
</adaptive-icon>
|
||||
5
app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@color/ic_launcher_background"/>
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
|
||||
</adaptive-icon>
|
||||
|
Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.3 KiB |
BIN
app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
|
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 5.3 KiB |
|
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.3 KiB |
BIN
app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
Normal file
|
After Width: | Height: | Size: 3.5 KiB |
|
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 4.5 KiB |
BIN
app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
Normal file
|
After Width: | Height: | Size: 7.8 KiB |
|
Before Width: | Height: | Size: 6.0 KiB After Width: | Height: | Size: 7.4 KiB |
|
Before Width: | Height: | Size: 7.5 KiB After Width: | Height: | Size: 6.9 KiB |
BIN
app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 9.8 KiB After Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.4 KiB |
BIN
app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
Normal file
|
After Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 14 KiB After Width: | Height: | Size: 16 KiB |
@ -157,6 +157,7 @@
|
||||
<string name="ship_date">Data consegna</string>
|
||||
<string name="terms_of_delivery">Termini di consegna</string>
|
||||
<string name="vehicle">Automezzo</string>
|
||||
<string name="deposit">Deposito</string>
|
||||
<string name="carrier">Vettore</string>
|
||||
|
||||
<string name="no_items_found_message">Nessun articolo trovato</string>
|
||||
@ -177,6 +178,8 @@
|
||||
<string name="free_picking_suggestion_1">Per iniziare clicca sul + in basso a destra</string>
|
||||
<string name="free_picking_suggestion_2">Scansiona un articolo per iniziare</string>
|
||||
<string name="free_picking_title_fragment">Picking libero</string>
|
||||
<string name="error_multiple_gest_ordv">Impossibile caricare ordini di diverse <b>gestioni</b></string>
|
||||
<string name="error_multiple_cod_mdep_ordv">Impossibile caricare ordini di diversi <b>depositi</b></string>
|
||||
|
||||
<string name="recovering_data">Recupero dati</string>
|
||||
<string name="wait_a_moment">Attendi qualche istante</string>
|
||||
|
||||
4
app/src/main/res/values/ic_launcher_background.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<color name="ic_launcher_background">#FFFFFF</color>
|
||||
</resources>
|
||||
@ -163,6 +163,7 @@
|
||||
<string name="ship_date">Ship date</string>
|
||||
<string name="terms_of_delivery">Terms of delivery</string>
|
||||
<string name="vehicle">Vehicle</string>
|
||||
<string name="deposit">Deposit</string>
|
||||
<string name="carrier">Carrier</string>
|
||||
|
||||
<string name="no_items_found_message">No items found</string>
|
||||
@ -179,8 +180,12 @@
|
||||
<string name="free_picking">Free Picking</string>
|
||||
<string name="free_picking_suggestion_1">Please press + button to start with picking</string>
|
||||
<string name="free_picking_suggestion_2">Scan an item to start</string>
|
||||
<string name="error_multiple_gest_ordv">Can\'t load orders of different type</string>
|
||||
<string name="error_multiple_cod_mdep_ordv">Can\'t load orders of different deposits</string>
|
||||
|
||||
<string name="recovering_data">Recovering data</string>
|
||||
<string name="wait_a_moment">Wait a moment</string>
|
||||
<string name="title_dynamic_vgalimenti">VGAlimenti customization</string>
|
||||
<string name="title_dynamic__base">Base customization</string>
|
||||
|
||||
</resources>
|
||||
|
||||
@ -15,7 +15,7 @@ buildscript {
|
||||
google()
|
||||
}
|
||||
dependencies {
|
||||
classpath "com.android.tools.build:gradle:3.3.0"
|
||||
classpath 'com.android.tools.build:gradle:3.3.1'
|
||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||
classpath 'com.google.gms:google-services:4.2.0'
|
||||
classpath 'com.google.firebase:firebase-plugins:1.1.5'
|
||||
|
||||
2
build_all.bat
Normal file
@ -0,0 +1,2 @@
|
||||
call build_azienda.bat _base
|
||||
call build_azienda.bat vgalimenti
|
||||
51
build_azienda.bat
Normal file
@ -0,0 +1,51 @@
|
||||
@echo off
|
||||
|
||||
SET nome_azienda=%1
|
||||
|
||||
setlocal enabledelayedexpansion
|
||||
set INTEXTFILE=build.gradle
|
||||
set OUTTEXTFILE=build_out.gradle
|
||||
set SEARCHTEXT=:dynamic__base
|
||||
set REPLACETEXT=:dynamic_%nome_azienda%
|
||||
set OUTPUTLINE=
|
||||
|
||||
cd app
|
||||
|
||||
for /f "tokens=1,* delims=¶" %%A in ( '"findstr /n ^^ %INTEXTFILE%"') do (
|
||||
SET string=%%A
|
||||
for /f "delims=: tokens=1,*" %%a in ("!string!") do set "string=%%b"
|
||||
if "!string!" == "" (
|
||||
echo.>>%OUTTEXTFILE%
|
||||
) else (
|
||||
SET modified=!string:%SEARCHTEXT%=%REPLACETEXT%!
|
||||
echo !modified! >> %OUTTEXTFILE%
|
||||
)
|
||||
)
|
||||
del %INTEXTFILE%
|
||||
rename %OUTTEXTFILE% %INTEXTFILE%
|
||||
|
||||
cd ..
|
||||
|
||||
call gradlew app:build --stacktrace
|
||||
|
||||
cd app
|
||||
|
||||
for /f "tokens=1,* delims=¶" %%A in ( '"findstr /n ^^ %INTEXTFILE%"') do (
|
||||
SET string=%%A
|
||||
for /f "delims=: tokens=1,*" %%a in ("!string!") do set "string=%%b"
|
||||
if "!string!" == "" (
|
||||
echo.>>%OUTTEXTFILE%
|
||||
) else (
|
||||
SET modified=!string:%REPLACETEXT%=%SEARCHTEXT%!
|
||||
echo !modified! >> %OUTTEXTFILE%
|
||||
)
|
||||
)
|
||||
del %INTEXTFILE%
|
||||
rename %OUTTEXTFILE% %INTEXTFILE%
|
||||
|
||||
cd ..
|
||||
|
||||
mkdir app\build\outputs\apk\release\%nome_azienda%
|
||||
|
||||
move app\build\outputs\apk\release\*.apk app\build\outputs\apk\release\%nome_azienda%\
|
||||
move app\build\outputs\apk\release\*.txt app\build\outputs\apk\release\%nome_azienda%\
|
||||
|
Before Width: | Height: | Size: 572 KiB |
|
Before Width: | Height: | Size: 1.5 MiB |
1
dynamic__base/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
/build
|
||||
25
dynamic__base/build.gradle
Normal file
@ -0,0 +1,25 @@
|
||||
apply plugin: 'com.android.dynamic-feature'
|
||||
|
||||
android {
|
||||
compileSdkVersion 28
|
||||
|
||||
|
||||
|
||||
defaultConfig {
|
||||
minSdkVersion 21
|
||||
targetSdkVersion 28
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
|
||||
|
||||
}
|
||||
compileOptions {
|
||||
sourceCompatibility = '1.8'
|
||||
targetCompatibility = '1.8'
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(include: ['*.jar'], dir: 'libs')
|
||||
implementation project(':app')
|
||||
}
|
||||
12
dynamic__base/src/main/AndroidManifest.xml
Normal file
@ -0,0 +1,12 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:dist="http://schemas.android.com/apk/distribution"
|
||||
package="it.integry.wms.dynamic__base">
|
||||
|
||||
<dist:module
|
||||
dist:instant="false"
|
||||
dist:onDemand="true"
|
||||
dist:title="@string/title_dynamic__base">
|
||||
<dist:fusing dist:include="true" />
|
||||
</dist:module>
|
||||
</manifest>
|
||||
|
||||
@ -0,0 +1,27 @@
|
||||
package it.integry.wms.dynamic_customization;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.Log;
|
||||
|
||||
import it.integry.integrywmsnative.core.class_router.ClassRouter;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.wms.dynamic_customization.extensions.FiltroOrdiniVendita;
|
||||
import it.integry.wms.dynamic_customization.extensions.OrdiniVendita;
|
||||
|
||||
public class DynamicContext {
|
||||
|
||||
public void init(Context context) {
|
||||
Log.d("DynamicContext", "Caricamento personalizzazioni per Azienda BASE");
|
||||
|
||||
try {
|
||||
ClassRouter.registerPath(ClassRouter.PATH.FILTRO_ORDINI_VENDITA, FiltroOrdiniVendita.class);
|
||||
ClassRouter.registerPath(ClassRouter.PATH.ORDINI_VENDITA, OrdiniVendita.class);
|
||||
} catch (Exception ex) {
|
||||
UtilityExceptions.defaultException(context, ex);
|
||||
}
|
||||
|
||||
Log.d("DynamicContext", "Caricamento personalizzazioni per Azienda BASE COMPLETATO");
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,11 @@
|
||||
package it.integry.wms.dynamic_customization.extensions;
|
||||
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.IFiltroOrdiniVendita;
|
||||
|
||||
public class FiltroOrdiniVendita implements IFiltroOrdiniVendita {
|
||||
|
||||
@Override
|
||||
public boolean shoudShowCodMdepFilter() {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package it.integry.wms.dynamic_customization.extensions;
|
||||
|
||||
import android.app.ProgressDialog;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.core.REST.consumers.ColliMagazzinoRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityToast;
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.IOrdiniVendita;
|
||||
import it.integry.integrywmsnative.gest.vendita.dto.OrdineVenditaGroupedInevasoDTO;
|
||||
|
||||
public class OrdiniVendita implements IOrdiniVendita {
|
||||
|
||||
|
||||
@Override
|
||||
public void distribuisciCollo(ProgressDialog progress, MtbColt mtbColt, List<OrdineVenditaGroupedInevasoDTO> testateOrdini, RunnableArgs<List<MtbColt>> onComplete, RunnableArgs<Exception> onFailed) {
|
||||
UtilityToast.showToast("Avviato metodo in BaseFeature");
|
||||
|
||||
ColliMagazzinoRESTConsumer.distribuisciCollo(mtbColt, SettingsManager.iDB().getDefaultCriterioDistribuzione(),
|
||||
onComplete,
|
||||
onFailed);
|
||||
}
|
||||
}
|
||||
1
dynamic_vgalimenti/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
/build
|
||||
BIN
dynamic_vgalimenti/Integry.jks
Normal file
23
dynamic_vgalimenti/build.gradle
Normal file
@ -0,0 +1,23 @@
|
||||
apply plugin: 'com.android.dynamic-feature'
|
||||
|
||||
android {
|
||||
compileSdkVersion 28
|
||||
defaultConfig {
|
||||
minSdkVersion 21
|
||||
targetSdkVersion 28
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
|
||||
|
||||
}
|
||||
buildToolsVersion '28.0.3'
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(include: ['*.jar'], dir: 'libs')
|
||||
implementation project(':app')
|
||||
}
|
||||
12
dynamic_vgalimenti/src/main/AndroidManifest.xml
Normal file
@ -0,0 +1,12 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:dist="http://schemas.android.com/apk/distribution"
|
||||
package="it.integry.wms.dynamic_customization">
|
||||
|
||||
<dist:module
|
||||
dist:instant="false"
|
||||
dist:onDemand="true"
|
||||
dist:title="@string/title_dynamic_vgalimenti">
|
||||
<dist:fusing dist:include="true" />
|
||||
</dist:module>
|
||||
</manifest>
|
||||
|
||||
@ -0,0 +1,27 @@
|
||||
package it.integry.wms.dynamic_customization;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.Log;
|
||||
|
||||
import it.integry.integrywmsnative.core.class_router.ClassRouter;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.wms.dynamic_customization.extensions.FiltroOrdiniVendita;
|
||||
import it.integry.wms.dynamic_customization.extensions.OrdiniVendita;
|
||||
|
||||
public class DynamicContext {
|
||||
|
||||
public void init(Context context) {
|
||||
Log.d("DynamicContext", "Caricamento personalizzazioni per VGAlimenti");
|
||||
|
||||
try {
|
||||
ClassRouter.registerPath(ClassRouter.PATH.FILTRO_ORDINI_VENDITA, FiltroOrdiniVendita.class);
|
||||
ClassRouter.registerPath(ClassRouter.PATH.ORDINI_VENDITA, OrdiniVendita.class);
|
||||
} catch (Exception ex) {
|
||||
UtilityExceptions.defaultException(context, ex);
|
||||
}
|
||||
|
||||
Log.d("DynamicContext", "Caricamento personalizzazioni per VGAlimenti COMPLETATO");
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,12 @@
|
||||
package it.integry.wms.dynamic_customization.extensions;
|
||||
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.IFiltroOrdiniVendita;
|
||||
|
||||
public class FiltroOrdiniVendita implements IFiltroOrdiniVendita {
|
||||
|
||||
|
||||
@Override
|
||||
public boolean shoudShowCodMdepFilter() {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,45 @@
|
||||
package it.integry.wms.dynamic_customization.extensions;
|
||||
|
||||
import android.app.ProgressDialog;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.core.REST.consumers.ColliMagazzinoRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.REST.model.DistribuzioneColloDTO;
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.IOrdiniVendita;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityString;
|
||||
import it.integry.integrywmsnative.gest.vendita.dto.OrdineVenditaGroupedInevasoDTO;
|
||||
|
||||
public class OrdiniVendita implements IOrdiniVendita {
|
||||
|
||||
@Override
|
||||
public void distribuisciCollo(ProgressDialog progress, MtbColt mtbColt, List<OrdineVenditaGroupedInevasoDTO> testateOrdini, RunnableArgs<List<MtbColt>> onComplete, RunnableArgs<Exception> onFailed) {
|
||||
|
||||
|
||||
|
||||
String codMdepOrder = testateOrdini.get(0).ordini.get(0).getCodMdep();
|
||||
|
||||
//Se il deposito del collo è diverso dal deposito dell'utente allora sto "evadendo" la merce per una vendita presente
|
||||
//su un altro deposito
|
||||
if(!UtilityString.isNullOrEmpty(codMdepOrder) &&
|
||||
!codMdepOrder.equalsIgnoreCase(SettingsManager.i().userSession.depo.getCodMdep())) {
|
||||
|
||||
ColliMagazzinoRESTConsumer.distribuisciCollo(mtbColt,
|
||||
DistribuzioneColloDTO.CriterioDistribuzione.UPDATE,
|
||||
onComplete,
|
||||
onFailed);
|
||||
|
||||
} else {
|
||||
|
||||
ColliMagazzinoRESTConsumer.distribuisciCollo(mtbColt,
|
||||
SettingsManager.iDB().getDefaultCriterioDistribuzione(),
|
||||
onComplete,
|
||||
onFailed);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
BIN
ext_sources/RoundLogoWithText.png
Normal file
|
After Width: | Height: | Size: 11 KiB |
27
ext_sources/RoundLogoWithText.svg
Normal file
@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Generator: Adobe Illustrator 23.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
||||
<svg version="1.1" id="Livello_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
|
||||
<style type="text/css">
|
||||
.st0{fill:#FF9900;}
|
||||
.st1{fill:#EC0200;}
|
||||
.st2{fill:#349933;}
|
||||
.st3{fill:#0199CB;}
|
||||
.st4{fill:none;}
|
||||
.st5{font-family:'HandelGothicBT-Regular';}
|
||||
.st6{font-size:126px;}
|
||||
.st7{letter-spacing:-5;}
|
||||
</style>
|
||||
<g>
|
||||
<path class="st0" d="M443.6,222.35C427.8,132.93,349.71,65,255.76,65c-23.88,0-46.73,4.39-67.8,12.4l14.34,36.4
|
||||
c16.04-5.81,33.35-8.98,51.4-8.98c74.13,0,135.77,53.43,148.53,123.87L443.6,222.35z"/>
|
||||
<path class="st1" d="M250.88,446.45c1.62,0.04,3.25,0.06,4.88,0.06c105.35,0,190.76-85.41,190.76-190.76c0-3.32-0.09-6.62-0.25-9.9
|
||||
l-41.84,1.45c0.15,2.8,0.23,5.63,0.23,8.47c0,83.37-69.55,150.94-152.92,150.94L250.88,446.45"/>
|
||||
<path class="st2" d="M126.14,395.71c26.02,24.11,58.77,41.05,95.11,47.69l6.61-38.87c-28.78-4.96-55.35-18.7-76.09-37.5
|
||||
L126.14,395.71"/>
|
||||
<path class="st3" d="M160.64,90.37C103.48,123.32,65,185.04,65,255.76c0,45.27,15.77,86.86,42.12,119.57l29.71-23.99
|
||||
c-21.3-26.03-34.09-59.3-34.09-95.56c0-56.37,30.9-105.53,76.69-131.45L160.64,90.37"/>
|
||||
</g>
|
||||
<rect x="113.4" y="205" class="st4" width="357.88" height="141.31"/>
|
||||
<text transform="matrix(1 0 0 1 113.4048 295.4663)" class="st5 st6 st7">wms</text>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.5 KiB |
@ -1 +1 @@
|
||||
include ':app', ':pointmobilescannerlibrary', ':waterfall_toolbar', ':barcode_base_library'
|
||||
include ':app', ':pointmobilescannerlibrary', ':waterfall_toolbar', ':barcode_base_library', ':dynamic_vgalimenti', ':dynamic__base'
|
||||
|
||||