Compare commits
10 Commits
v1.19.0(24
...
v1.19.2(24
| Author | SHA1 | Date | |
|---|---|---|---|
| 21f9a9819a | |||
| 4059335e61 | |||
| 14252f0f4b | |||
| c13eee355e | |||
| 51528fda6f | |||
| 1486d39eb8 | |||
| 1951d8e2a4 | |||
| 420fdf6b4c | |||
| a14a593e4f | |||
| 5d7ffa02c4 |
@@ -6,8 +6,8 @@ apply plugin: 'com.google.gms.google-services'
|
||||
|
||||
android {
|
||||
|
||||
def appVersionCode = 241
|
||||
def appVersionName = '1.19.0'
|
||||
def appVersionCode = 243
|
||||
def appVersionName = '1.19.2'
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
@@ -160,7 +160,6 @@ dependencies {
|
||||
|
||||
implementation 'com.github.RaviKoradiya:LiveAdapter:1.3.4'
|
||||
implementation 'org.reflections:reflections:0.10.2'
|
||||
|
||||
}
|
||||
|
||||
repositories {
|
||||
|
||||
@@ -2,7 +2,6 @@ package it.integry.integrywmsnative.core.class_router;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import it.integry.integrywmsnative.core.class_router.configs.MenuConfiguration;
|
||||
import it.integry.integrywmsnative.core.class_router.interfaces.ICustomConfiguration;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityHashMap;
|
||||
|
||||
@@ -10,14 +9,12 @@ public class BaseCustomConfiguration implements ICustomConfiguration {
|
||||
|
||||
|
||||
public static class Keys {
|
||||
public static int MENU_CONFIGURATION = 0;
|
||||
public static int FLAG_SHOW_COD_FORN_IN_SPEDIZIONE = 1;
|
||||
public static int CUSTOM_DYNAMIC_VERSION_PATH = 2;
|
||||
public static int FLAG_SPEDIZIONE_GROUP_BY_GRP_MERC = 3;
|
||||
}
|
||||
|
||||
protected HashMap<Integer, Object> configurations = new HashMap<Integer, Object>() {{
|
||||
put(Keys.MENU_CONFIGURATION, new MenuConfiguration());
|
||||
protected HashMap<Integer, Object> configurations = new HashMap<>() {{
|
||||
put(Keys.FLAG_SHOW_COD_FORN_IN_SPEDIZIONE, true);
|
||||
put(Keys.FLAG_SPEDIZIONE_GROUP_BY_GRP_MERC, false);
|
||||
}};
|
||||
|
||||
@@ -477,7 +477,7 @@ public class Converters {
|
||||
|
||||
|
||||
@BindingAdapter("visibility")
|
||||
public static void bindView(View view, final ObservableField<Boolean> bindableBoolean) {
|
||||
public static void bindViewVisibility(View view, final ObservableField<Boolean> bindableBoolean) {
|
||||
if (view.getTag(R.id.bound_observable) != bindableBoolean) {
|
||||
view.setTag(R.id.bound_observable, bindableBoolean);
|
||||
}
|
||||
@@ -492,6 +492,38 @@ public class Converters {
|
||||
}
|
||||
|
||||
|
||||
@BindingAdapter({"reverse_visibility"})
|
||||
public static void bindViewReverseVisibility(View view, final BindableBoolean bindableBoolean) {
|
||||
if (view.getTag(R.id.bound_observable) != bindableBoolean) {
|
||||
view.setTag(R.id.bound_observable, bindableBoolean);
|
||||
}
|
||||
bindableBoolean.addOnPropertyChangedCallback(new Observable.OnPropertyChangedCallback() {
|
||||
@Override
|
||||
public void onPropertyChanged(Observable sender, int propertyId) {
|
||||
view.setVisibility(bindableBoolean.get() ? View.GONE : View.VISIBLE);
|
||||
}
|
||||
});
|
||||
|
||||
view.setVisibility(bindableBoolean.get() ? View.GONE : View.VISIBLE);
|
||||
}
|
||||
|
||||
|
||||
@BindingAdapter("reverse_visibility")
|
||||
public static void bindViewReverseVisibility(View view, final ObservableField<Boolean> bindableBoolean) {
|
||||
if (view.getTag(R.id.bound_observable) != bindableBoolean) {
|
||||
view.setTag(R.id.bound_observable, bindableBoolean);
|
||||
}
|
||||
bindableBoolean.addOnPropertyChangedCallback(new Observable.OnPropertyChangedCallback() {
|
||||
@Override
|
||||
public void onPropertyChanged(Observable sender, int propertyId) {
|
||||
view.setVisibility(bindableBoolean.get() ? View.GONE : View.VISIBLE);
|
||||
}
|
||||
});
|
||||
|
||||
view.setVisibility(bindableBoolean.get() ? View.GONE : View.VISIBLE);
|
||||
}
|
||||
|
||||
|
||||
@BindingAdapter("android:layout_weight")
|
||||
public static void setLayoutWeight(View view, final Float weight) {
|
||||
|
||||
|
||||
@@ -65,10 +65,7 @@ public class MainAccettazioneFragment extends BaseFragment implements ISearcable
|
||||
}
|
||||
|
||||
public static MainAccettazioneFragment newInstance() {
|
||||
MainAccettazioneFragment fragment = new MainAccettazioneFragment();
|
||||
Bundle args = new Bundle();
|
||||
fragment.setArguments(args);
|
||||
return fragment;
|
||||
return new MainAccettazioneFragment();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -786,9 +786,12 @@ public class AccettazionePickingViewModel {
|
||||
}
|
||||
|
||||
private void printCollo(Runnable onComplete) {
|
||||
MtbColt cloneMtbColt = (MtbColt) mCurrentMtbColt.clone();
|
||||
cloneMtbColt.setGestione(cloneMtbColt.getGestioneEnum() == GestioneEnum.LAVORAZIONE ? GestioneEnum.PRODUZIONE : cloneMtbColt.getGestioneEnum());
|
||||
|
||||
this.mPrinterRESTConsumer.printCollo(
|
||||
PrinterRESTConsumer.Type.SECONDARIA,
|
||||
mCurrentMtbColt,
|
||||
cloneMtbColt,
|
||||
() -> {
|
||||
this.sendLUSuccessfullyPrinted();
|
||||
onComplete.run();
|
||||
|
||||
@@ -27,7 +27,6 @@ import javax.inject.Inject;
|
||||
|
||||
import it.integry.integrywmsnative.MainApplication;
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.class_router.BaseCustomConfiguration;
|
||||
import it.integry.integrywmsnative.core.class_router.ClassRouter;
|
||||
import it.integry.integrywmsnative.core.class_router.configs.BaseMenuConfiguration;
|
||||
import it.integry.integrywmsnative.core.class_router.configs.MenuConfiguration;
|
||||
@@ -242,7 +241,7 @@ public class MainActivity extends BaseActivity
|
||||
|
||||
private MenuConfiguration.MenuItem getMenuItem(@IdRes int menuId) {
|
||||
ICustomConfiguration customConfiguration = ClassRouter.getInstance(ClassRouter.PATH.CUSTOM_CONFIGURATION);
|
||||
BaseMenuConfiguration menuConfiguration = customConfiguration.getConfig(BaseCustomConfiguration.Keys.MENU_CONFIGURATION);
|
||||
BaseMenuConfiguration menuConfiguration = new MenuConfiguration();
|
||||
List<MenuConfiguration.MenuGroup> menuGroups = menuConfiguration.getGroups();
|
||||
|
||||
BaseMenuConfiguration.MenuItem menuItemToReturn = null;
|
||||
|
||||
@@ -276,9 +276,7 @@ public class MainFragment extends Fragment implements ITitledFragment, IScrollab
|
||||
groupBinding.mainList.setAdapter(menuListAdapter);
|
||||
groupBinding.mainList.setNestedScrollingEnabled(false);
|
||||
|
||||
menuListAdapter.setClickListener((view, position) -> {
|
||||
onMenuClick(menuGroup.getItems().get(position));
|
||||
});
|
||||
menuListAdapter.setClickListener(this::onMenuClick);
|
||||
|
||||
mBindings.menuContainer.addView(groupBinding.getRoot());
|
||||
|
||||
|
||||
@@ -14,14 +14,15 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.class_router.configs.BaseMenuConfiguration;
|
||||
import it.integry.integrywmsnative.core.class_router.configs.MenuConfiguration;
|
||||
|
||||
public class MenuListAdapter extends RecyclerView.Adapter<MenuListAdapter.ViewHolder> {
|
||||
|
||||
private Context mContext;
|
||||
private final Context mContext;
|
||||
|
||||
private List<MenuConfiguration.MenuItem> mDataset;
|
||||
private LayoutInflater mInflater;
|
||||
private final List<MenuConfiguration.MenuItem> mDataset;
|
||||
private final LayoutInflater mInflater;
|
||||
private ItemClickListener mClickListener;
|
||||
|
||||
// data is passed into the constructor
|
||||
@@ -44,6 +45,10 @@ public class MenuListAdapter extends RecyclerView.Adapter<MenuListAdapter.ViewHo
|
||||
public void onBindViewHolder(@NonNull ViewHolder holder, int position) {
|
||||
holder.mIcon.setImageDrawable(ResourcesCompat.getDrawable(mContext.getResources(), mDataset.get(position).getTitleIcon(), null));
|
||||
holder.mTitle.setText(mContext.getResources().getString(mDataset.get(position).getTitleText()));
|
||||
|
||||
holder.itemView.setOnClickListener(v -> {
|
||||
if (mClickListener != null) mClickListener.onItemClick(mDataset.get(position));
|
||||
});
|
||||
}
|
||||
|
||||
// total number of cells
|
||||
@@ -54,20 +59,14 @@ public class MenuListAdapter extends RecyclerView.Adapter<MenuListAdapter.ViewHo
|
||||
|
||||
|
||||
// stores and recycles views as they are scrolled off screen
|
||||
public class ViewHolder extends RecyclerView.ViewHolder implements View.OnClickListener {
|
||||
private TextView mTitle;
|
||||
private ImageView mIcon;
|
||||
public static class ViewHolder extends RecyclerView.ViewHolder {
|
||||
private final TextView mTitle;
|
||||
private final ImageView mIcon;
|
||||
|
||||
ViewHolder(View itemView) {
|
||||
super(itemView);
|
||||
mTitle = itemView.findViewById(R.id.menu_title);
|
||||
mIcon = itemView.findViewById(R.id.menu_icon);
|
||||
itemView.setOnClickListener(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
if (mClickListener != null) mClickListener.onItemClick(view, getAdapterPosition());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -79,6 +78,6 @@ public class MenuListAdapter extends RecyclerView.Adapter<MenuListAdapter.ViewHo
|
||||
|
||||
// parent activity will implement this method to respond to click events
|
||||
public interface ItemClickListener {
|
||||
void onItemClick(View view, int position);
|
||||
void onItemClick(BaseMenuConfiguration.MenuItem menuItem);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterAgenteLayoutView extends FilterLayoutView {
|
||||
private List<String> allAgenti;
|
||||
private List<String> availableAgenti;
|
||||
private List<String> preSelectedAgenti = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<String> hiddenAgenti = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<String>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,25 @@ public class FilterAgenteLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_agente, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenAgenti = Stream.of(allAgenti)
|
||||
.filter(x -> !x.toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_agente__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +71,21 @@ public class FilterAgenteLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllAgenti())
|
||||
listModel.setValue(Stream.of(getAllAgenti())
|
||||
.filter(x -> !hiddenAgenti.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedAgenti.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableAgenti.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_agente__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterAutomezzoLayoutView extends FilterLayoutView {
|
||||
private List<String> allAutomezzi;
|
||||
private List<String> availableAutomezzi;
|
||||
private List<String> preSelectedAutomezzi = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<String> hiddenAutomezzi = new ArrayList<>();
|
||||
private MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<String>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,24 @@ public class FilterAutomezzoLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_automezzo, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenAutomezzi = Stream.of(allAutomezzi)
|
||||
.filter(x -> !x.toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_automezzo__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +70,21 @@ public class FilterAutomezzoLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllAutomezzi())
|
||||
listModel.setValue(Stream.of(getAllAutomezzi())
|
||||
.filter(x -> !hiddenAutomezzi.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedAutomezzi.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableAutomezzi.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_automezzo__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterClienteLayoutView extends FilterLayoutView {
|
||||
private List<String> allClienti;
|
||||
private List<String> availableClienti;
|
||||
private List<String> preSelectedClienti = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<String> hiddenClienti = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<String>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,24 @@ public class FilterClienteLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_cliente, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenClienti = Stream.of(allClienti)
|
||||
.filter(x -> !x.toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_cliente__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +70,21 @@ public class FilterClienteLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllClienti())
|
||||
listModel.setValue(Stream.of(getAllClienti())
|
||||
.filter(x -> !hiddenClienti.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedClienti.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableClienti.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_cliente__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -32,7 +35,8 @@ public class FilterDepositoLayoutView extends FilterLayoutView {
|
||||
private List<MtbDepo> allCodMdeps;
|
||||
private List<MtbDepo> availableCodMdeps;
|
||||
private List<MtbDepo> preSelectedCodMdeps = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<MtbDepo> hiddenDepos = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<MtbDepo>> onFilterApplied;
|
||||
|
||||
@@ -42,23 +46,19 @@ public class FilterDepositoLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_deposito, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> UtilityBoolean.toInt(x.getEnabled().get()) - UtilityBoolean.toInt(y.getEnabled().get())))
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().getCodMdep().compareToIgnoreCase(x.getOriginalModel().getCodMdep())))
|
||||
.reversed();
|
||||
refreshList();
|
||||
|
||||
|
||||
listModel = Stream.of(getAllCodMdeps())
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedCodMdeps.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableCodMdeps.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenDepos = Stream.of(allCodMdeps)
|
||||
.filter(x -> !x.getCodMdep().toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)) &&
|
||||
!x.getDescrizione().toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_deposito__list_item)
|
||||
.into(this.mBindings.recyclerviewDepositi);
|
||||
|
||||
@@ -69,7 +69,7 @@ public class FilterDepositoLayoutView extends FilterLayoutView {
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
@@ -77,6 +77,25 @@ public class FilterDepositoLayoutView extends FilterLayoutView {
|
||||
dismiss();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> UtilityBoolean.toInt(x.getEnabled().get()) - UtilityBoolean.toInt(y.getEnabled().get())))
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().getCodMdep().compareToIgnoreCase(x.getOriginalModel().getCodMdep())))
|
||||
.reversed();
|
||||
|
||||
|
||||
listModel.setValue(Stream.of(getAllCodMdeps())
|
||||
.filter(x -> !hiddenDepos.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedCodMdeps.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableCodMdeps.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList());
|
||||
}
|
||||
|
||||
public List<MtbDepo> getAllCodMdeps() {
|
||||
return allCodMdeps;
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -32,7 +35,8 @@ public class FilterGruppoMercLayoutView extends FilterLayoutView {
|
||||
private List<MtbGrup> allGroupMerc;
|
||||
private List<MtbGrup> availableGroupMerc;
|
||||
private List<MtbGrup> preSelectedGroupMerc = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<MtbGrup> hiddenGroupMerc = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<MtbGrup>> onFilterApplied;
|
||||
|
||||
@@ -43,6 +47,26 @@ public class FilterGruppoMercLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_gruppo_merc, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenGroupMerc = Stream.of(allGroupMerc)
|
||||
.filter(x -> !x.getCodMgrp().toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)) &&
|
||||
!x.getDescrizione().toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_gruppo_merc__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -50,27 +74,21 @@ public class FilterGruppoMercLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().getCodMgrp().compareTo(x.getOriginalModel().getCodMgrp())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllGroupMerc())
|
||||
listModel.setValue(Stream.of(getAllGroupMerc())
|
||||
.filter(x -> !hiddenGroupMerc.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedGroupMerc.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableGroupMerc.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_gruppo_merc__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterNumeroOrdineLayoutView extends FilterLayoutView {
|
||||
private List<Integer> allNumOrds;
|
||||
private List<Integer> availableNumOrds;
|
||||
private List<Integer> preSelectedNumOrds = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<Integer> hiddenNumOrds = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<Integer>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,25 @@ public class FilterNumeroOrdineLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_numero_ordine, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenNumOrds = Stream.of(allNumOrds)
|
||||
.filter(x -> !x.toString().contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_numero_ordine__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +71,21 @@ public class FilterNumeroOrdineLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllNumOrds())
|
||||
listModel.setValue(Stream.of(getAllNumOrds())
|
||||
.filter(x -> !hiddenNumOrds.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedNumOrds.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableNumOrds.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_numero_ordine__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterPaeseLayoutView extends FilterLayoutView {
|
||||
private List<String> allPaesi;
|
||||
private List<String> availablePaesi;
|
||||
private List<String> preSelectedPaesi = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<String> hiddenPaesi = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<String>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,25 @@ public class FilterPaeseLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_paese, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenPaesi = Stream.of(allPaesi)
|
||||
.filter(x -> !x.toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_paese__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +71,21 @@ public class FilterPaeseLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllPaesi())
|
||||
listModel.setValue(Stream.of(getAllPaesi())
|
||||
.filter(x -> !hiddenPaesi.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedPaesi.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availablePaesi.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_paese__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterTermConsLayoutView extends FilterLayoutView {
|
||||
private List<String> allTermCons;
|
||||
private List<String> availableTermCons;
|
||||
private List<String> preSelectedTermCons = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<String> hiddenSelectedTermCons = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<String>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,25 @@ public class FilterTermConsLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_term_cons, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenSelectedTermCons = Stream.of(allTermCons)
|
||||
.filter(x -> !x.toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_term_cons__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +71,21 @@ public class FilterTermConsLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllTermCons())
|
||||
listModel.setValue(Stream.of(getAllTermCons())
|
||||
.filter(x -> !hiddenSelectedTermCons.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedTermCons.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableTermCons.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_term_cons__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterVettoreLayoutView extends FilterLayoutView {
|
||||
private List<String> allVettori;
|
||||
private List<String> availableVettori;
|
||||
private List<String> preSelectedVettori = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<String> hiddenSelectedVettori = new ArrayList<>();
|
||||
private final MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<String>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,26 @@ public class FilterVettoreLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_vettore, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenSelectedVettori = Stream.of(allVettori)
|
||||
.filter(x -> !x.toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_vettore__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +72,21 @@ public class FilterVettoreLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllVettori())
|
||||
listModel.setValue(Stream.of(getAllVettori())
|
||||
.filter(x -> !hiddenSelectedVettori.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedVettori.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableVettori.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_vettore__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.ViewGroup;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
import androidx.lifecycle.MutableLiveData;
|
||||
|
||||
import com.annimon.stream.ComparatorCompat;
|
||||
import com.annimon.stream.Stream;
|
||||
@@ -15,6 +16,8 @@ import com.ravikoradiya.liveadapter.LiveAdapter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
@@ -31,7 +34,8 @@ public class FilterViaggioLayoutView extends FilterLayoutView {
|
||||
private List<Integer> allIDViaggio;
|
||||
private List<Integer> availableIDViaggio;
|
||||
private List<Integer> preSelectedIDViaggio = new ArrayList<>();
|
||||
private List<ListModel> listModel;
|
||||
private List<Integer> hiddenIDViaggio = new ArrayList<>();
|
||||
private MutableLiveData<List<ListModel>> listModel = new MutableLiveData<>();
|
||||
|
||||
private RunnableArgs<List<Integer>> onFilterApplied;
|
||||
|
||||
@@ -41,6 +45,25 @@ public class FilterViaggioLayoutView extends FilterLayoutView {
|
||||
mBindings = DataBindingUtil.inflate(inflater, R.layout.layout_filter_viaggio, container, false);
|
||||
this.mBindings.setView(this);
|
||||
|
||||
refreshList();
|
||||
|
||||
this.setSearchView(this.mBindings.searchView, newFilter -> {
|
||||
hiddenIDViaggio = Stream.of(allIDViaggio)
|
||||
.filter(x -> !x.toString().toUpperCase(Locale.ROOT).contains(newFilter.toUpperCase(Locale.ROOT)))
|
||||
.toList();
|
||||
|
||||
refreshList();
|
||||
});
|
||||
|
||||
|
||||
new LiveAdapter(listModel, getViewLifecycleOwner(), BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_viaggio__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
}
|
||||
|
||||
private void refreshList() {
|
||||
ComparatorCompat<ListModel> c =
|
||||
ComparatorCompat
|
||||
.chain(new ComparatorCompat<ListModel>((x, y) -> UtilityBoolean.toInt(x.getSelected().get()) - UtilityBoolean.toInt(y.getSelected().get())))
|
||||
@@ -48,27 +71,21 @@ public class FilterViaggioLayoutView extends FilterLayoutView {
|
||||
.thenComparing(new ComparatorCompat<>((x, y) -> y.getOriginalModel().compareTo(x.getOriginalModel())))
|
||||
.reversed();
|
||||
|
||||
listModel = Stream.of(getAllIDViaggio())
|
||||
listModel.setValue(Stream.of(getAllIDViaggio())
|
||||
.filter(x -> !hiddenIDViaggio.contains(x))
|
||||
.map(x -> new ListModel()
|
||||
.setSelected(new BindableBoolean(preSelectedIDViaggio.contains(x)))
|
||||
.setEnabled(new BindableBoolean(availableIDViaggio.contains(x)))
|
||||
.setOriginalModel(x))
|
||||
.sorted(c)
|
||||
.toList();
|
||||
|
||||
|
||||
new LiveAdapter(listModel, BR.item)
|
||||
.map(ListModel.class, R.layout.layout_filter_viaggio__list_item)
|
||||
.into(this.mBindings.recyclerview);
|
||||
|
||||
return mBindings.getRoot();
|
||||
.toList());
|
||||
}
|
||||
|
||||
|
||||
public void onConfirm() {
|
||||
if (onFilterApplied == null) return;
|
||||
|
||||
this.onFilterApplied.run(Stream.of(listModel)
|
||||
this.onFilterApplied.run(Stream.of(Objects.requireNonNull(listModel.getValue()))
|
||||
.filter(x -> x.selected.get())
|
||||
.map(x -> x.originalModel)
|
||||
.toList());
|
||||
|
||||
@@ -6,6 +6,8 @@ import androidx.lifecycle.MutableLiveData;
|
||||
import com.annimon.stream.Stream;
|
||||
import com.annimon.stream.function.Predicate;
|
||||
|
||||
import org.apache.commons.lang3.time.DateUtils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
@@ -103,7 +105,7 @@ public class VenditaFiltroOrdiniViewModel {
|
||||
|
||||
if (dataConsegna == null) currentDataConsPredicate.set(null);
|
||||
else {
|
||||
currentDataConsPredicate.set(o -> o.getDataConsD().equals(dataConsegna));
|
||||
currentDataConsPredicate.set(o -> DateUtils.isSameDay(o.getDataConsD(), dataConsegna));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,15 +1,74 @@
|
||||
package it.integry.integrywmsnative.ui.filter_chips;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
import android.widget.RelativeLayout;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.widget.SearchView;
|
||||
|
||||
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
|
||||
|
||||
import it.integry.integrywmsnative.core.di.BindableBoolean;
|
||||
import it.integry.integrywmsnative.core.di.BindableString;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
|
||||
public abstract class FilterLayoutView extends BottomSheetDialogFragment {
|
||||
|
||||
protected BindableString filterName = new BindableString();
|
||||
protected Context mContext;
|
||||
private final BindableString filterName = new BindableString();
|
||||
private final BindableBoolean enabledSearch = new BindableBoolean();
|
||||
|
||||
private SearchView mSearchView;
|
||||
private RunnableArgs<String> mOnFilterChanged;
|
||||
|
||||
|
||||
@Override
|
||||
public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) {
|
||||
super.onViewCreated(view, savedInstanceState);
|
||||
|
||||
if (mSearchView != null) this.initSearchView();
|
||||
}
|
||||
|
||||
protected void initSearchView() {
|
||||
|
||||
mSearchView.setOnSearchClickListener(v -> {
|
||||
this.setEnabledSearch(true);
|
||||
mSearchView.setLayoutParams(new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.MATCH_PARENT, RelativeLayout.LayoutParams.WRAP_CONTENT));
|
||||
});
|
||||
|
||||
mSearchView.setOnCloseListener(() -> {
|
||||
setEnabledSearch(false);
|
||||
var layoutParams = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT);
|
||||
layoutParams.addRule(RelativeLayout.ALIGN_PARENT_END);
|
||||
|
||||
mSearchView.setLayoutParams(layoutParams);
|
||||
return false;
|
||||
});
|
||||
|
||||
this.mSearchView.setOnQueryTextListener(new SearchView.OnQueryTextListener() {
|
||||
@Override
|
||||
public boolean onQueryTextSubmit(String query) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onQueryTextChange(String newText) {
|
||||
if (mOnFilterChanged != null) mOnFilterChanged.run(newText);
|
||||
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
// mSearchView.setQuery("", true);
|
||||
// mSearchView.setIconified(true);
|
||||
// mSearchView.clearFocus();
|
||||
//
|
||||
// mSearchView.getRootView().invalidate();
|
||||
}
|
||||
|
||||
|
||||
public Context getContext() {
|
||||
return mContext;
|
||||
@@ -28,4 +87,19 @@ public abstract class FilterLayoutView extends BottomSheetDialogFragment {
|
||||
this.filterName.set(filterName);
|
||||
return this;
|
||||
}
|
||||
|
||||
public BindableBoolean getEnabledSearch() {
|
||||
return enabledSearch;
|
||||
}
|
||||
|
||||
public FilterLayoutView setEnabledSearch(boolean enabledSearch) {
|
||||
this.enabledSearch.set(enabledSearch);
|
||||
return this;
|
||||
}
|
||||
|
||||
public FilterLayoutView setSearchView(SearchView searchView, RunnableArgs<String> onFilterChanged) {
|
||||
this.mSearchView = searchView;
|
||||
this.mOnFilterChanged = onFilterChanged;
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterAgenteLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginEnd="16dp">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,28 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="270dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterAutomezzoLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginEnd="16dp">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white"/>
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,28 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterClienteLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,29 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterDepositoLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,28 @@
|
||||
android:id="@+id/recyclerview_depositi"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterGruppoMercLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,29 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterNumeroOrdineLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,27 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterPaeseLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,28 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterTermConsLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,29 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterVettoreLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,29 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -14,32 +14,28 @@
|
||||
type="it.integry.integrywmsnative.gest.ordini_uscita_elenco.filters.FilterViaggioLayoutView" />
|
||||
</data>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="4dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:layout_toStartOf="@id/search_view"
|
||||
app:reverse_visibility="@{view.enabledSearch}">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
@@ -68,6 +64,16 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<androidx.appcompat.widget.SearchView
|
||||
android:id="@+id/search_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:backgroundTint="@android:color/white" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -81,30 +87,29 @@
|
||||
android:id="@+id/recyclerview"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
android:focusableInTouchMode="true"
|
||||
android:orientation="vertical"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="300dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/save_btn"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/confirm"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
style="@style/Button.PrimaryFull"
|
||||
android:text="@string/confirm"
|
||||
app:singleClick="@{() -> view.onConfirm()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</layout>
|
||||
@@ -15,6 +15,8 @@
|
||||
<item name="materialCalendarFullscreenTheme">@style/ThemeOverlay.MaterialComponents.MaterialCalendar.Fullscreen</item>
|
||||
<item name="materialCalendarTheme">@style/ThemeOverlay.MaterialComponents.MaterialCalendar</item>
|
||||
|
||||
<item name="bottomSheetDialogTheme">@style/CustomBottomSheetDialog</item>
|
||||
|
||||
</style>
|
||||
|
||||
<style name="AppTheme.NoActionBar">
|
||||
@@ -134,6 +136,8 @@
|
||||
<item name="materialCalendarStyle">@style/Widget.MaterialComponents.MaterialCalendar</item>
|
||||
<item name="materialCalendarFullscreenTheme">@style/ThemeOverlay.MaterialComponents.MaterialCalendar.Fullscreen</item>
|
||||
<item name="materialCalendarTheme">@style/ThemeOverlay.MaterialComponents.MaterialCalendar</item>
|
||||
|
||||
<item name="bottomSheetDialogTheme">@style/CustomBottomSheetDialog</item>
|
||||
</style>
|
||||
|
||||
|
||||
@@ -202,7 +206,21 @@
|
||||
<item name="titleTextAppearance">@style/AppTheme.NewMaterial.Text.ToolbarTitle</item>
|
||||
</style>
|
||||
|
||||
<style name="CustomBottomSheetDialog" parent="@style/ThemeOverlay.MaterialComponents.BottomSheetDialog">
|
||||
<item name="bottomSheetStyle">@style/CustomBottomSheet</item>
|
||||
</style>
|
||||
|
||||
<style name="CustomBottomSheet" parent="Widget.MaterialComponents.BottomSheet">
|
||||
<item name="shapeAppearanceOverlay">@style/CustomShapeAppearanceBottomSheetDialog</item>
|
||||
</style>
|
||||
|
||||
<style name="CustomShapeAppearanceBottomSheetDialog" parent="">
|
||||
<item name="cornerFamily">rounded</item>
|
||||
<item name="cornerSizeTopRight">16dp</item>
|
||||
<item name="cornerSizeTopLeft">16dp</item>
|
||||
<item name="cornerSizeBottomRight">0dp</item>
|
||||
<item name="cornerSizeBottomLeft">0dp</item>
|
||||
</style>
|
||||
|
||||
|
||||
</resources>
|
||||
|
||||
@@ -7,7 +7,6 @@ public class CustomConfiguration extends BaseCustomConfiguration implements ICus
|
||||
|
||||
public CustomConfiguration() {
|
||||
configurations.put(Keys.FLAG_SHOW_COD_FORN_IN_SPEDIZIONE, false);
|
||||
configurations.put(Keys.MENU_CONFIGURATION, new MenuConfigurationVG());
|
||||
configurations.put(Keys.FLAG_SPEDIZIONE_GROUP_BY_GRP_MERC, true);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,70 +0,0 @@
|
||||
package it.integry.wms.dynamic_customization.extensions;
|
||||
|
||||
import it.integry.integrywmsnative.core.class_router.configs.BaseMenuConfiguration;
|
||||
import it.integry.integrywmsnative.core.model.secondary.GestioneEnum;
|
||||
import it.integry.integrywmsnative.gest.accettazione.MainAccettazioneFragment;
|
||||
import it.integry.integrywmsnative.gest.ordini_uscita_elenco.OrdiniUscitaElencoFragment;
|
||||
import it.integry.integrywmsnative.gest.picking_libero.PickingLiberoFragment;
|
||||
import it.integry.integrywmsnative.gest.rettifica_giacenze.RettificaGiacenzeFragment;
|
||||
import it.integry.integrywmsnative.gest.versamento_merce.VersamentoMerceFragment;
|
||||
|
||||
public class MenuConfigurationVG extends BaseMenuConfiguration {
|
||||
|
||||
public MenuConfigurationVG() {
|
||||
|
||||
this
|
||||
.addGroup(
|
||||
new MenuGroup()
|
||||
.setGroupText(it.integry.integrywmsnative.R.string.purchase)
|
||||
.setGroupId(it.integry.integrywmsnative.R.id.nav_group_acquisto)
|
||||
|
||||
.addItem(new MenuItem()
|
||||
.setID(it.integry.integrywmsnative.R.id.nav_accettazione)
|
||||
.setTitleText(it.integry.integrywmsnative.R.string.accettazione_title_fragment)
|
||||
.setTitleIcon(it.integry.integrywmsnative.R.drawable.ic_dashboard_accettazione)
|
||||
.setDrawerIcon(it.integry.integrywmsnative.R.drawable.ic_black_download)
|
||||
.setFragmentFactory(MainAccettazioneFragment::newInstance))
|
||||
).addGroup(
|
||||
new MenuGroup()
|
||||
.setGroupText(it.integry.integrywmsnative.R.string.checkout)
|
||||
.setGroupId(it.integry.integrywmsnative.R.id.nav_group_spedizione)
|
||||
|
||||
.addItem(new MenuItem()
|
||||
.setID(it.integry.integrywmsnative.R.id.nav_spedizione)
|
||||
.setTitleText(it.integry.integrywmsnative.R.string.vendita_title_fragment)
|
||||
.setTitleIcon(it.integry.integrywmsnative.R.drawable.ic_dashboard_spedizione)
|
||||
.setDrawerIcon(it.integry.integrywmsnative.R.drawable.ic_black_upload)
|
||||
.setFragmentFactory(() -> OrdiniUscitaElencoFragment.newInstance(GestioneEnum.VENDITA, null, -1, null)))
|
||||
|
||||
.addItem(new MenuItem()
|
||||
.setID(it.integry.integrywmsnative.R.id.nav_free_picking)
|
||||
.setTitleText(it.integry.integrywmsnative.R.string.free_picking)
|
||||
.setTitleIcon(it.integry.integrywmsnative.R.drawable.ic_dashboard_picking_libero)
|
||||
.setDrawerIcon(it.integry.integrywmsnative.R.drawable.ic_black_barcode_scanner)
|
||||
.setFragmentFactory(() -> PickingLiberoFragment.newInstance(GestioneEnum.VENDITA)))
|
||||
)
|
||||
.addGroup(
|
||||
new MenuGroup()
|
||||
.setGroupText(it.integry.integrywmsnative.R.string.internal_handling)
|
||||
.setGroupId(it.integry.integrywmsnative.R.id.nav_group_movimentazione_interna)
|
||||
|
||||
.addItem(new MenuItem()
|
||||
.setID(it.integry.integrywmsnative.R.id.nav_versamento_merce)
|
||||
.setTitleText(it.integry.integrywmsnative.R.string.versamento_merce_fragment_title)
|
||||
.setTitleIcon(it.integry.integrywmsnative.R.drawable.ic_dashboard_versamento_merce)
|
||||
.setDrawerIcon(it.integry.integrywmsnative.R.drawable.ic_black_load_shelf)
|
||||
.setFragmentFactory(VersamentoMerceFragment::newInstance))
|
||||
|
||||
.addItem(new MenuItem()
|
||||
.setID(it.integry.integrywmsnative.R.id.nav_rettifica_giacenze)
|
||||
.setTitleText(it.integry.integrywmsnative.R.string.rettifica_giacenze_fragment_title)
|
||||
.setTitleIcon(it.integry.integrywmsnative.R.drawable.ic_dashboard_rettifica_giacenze)
|
||||
.setDrawerIcon(it.integry.integrywmsnative.R.drawable.ic_black_empty_box)
|
||||
.setFragmentFactory(RettificaGiacenzeFragment::newInstance))
|
||||
|
||||
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user