Miglioramento UI di recupero materiale
This commit is contained in:
parent
6a848e081a
commit
60978167c2
@ -31,12 +31,12 @@ android {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
compileSdkVersion 31
|
compileSdkVersion 32
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "it.integry.integrywmsnative"
|
applicationId "it.integry.integrywmsnative"
|
||||||
minSdkVersion 21
|
minSdkVersion 21
|
||||||
targetSdkVersion 31
|
targetSdkVersion 32
|
||||||
versionCode appVersionCode
|
versionCode appVersionCode
|
||||||
versionName appVersionName
|
versionName appVersionName
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|||||||
@ -99,7 +99,21 @@ public class UtilityDate {
|
|||||||
|
|
||||||
|
|
||||||
public static Date getDateInstance() {
|
public static Date getDateInstance() {
|
||||||
return getCalendarInstance().getTime();
|
return getDateInstance(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static Date getDateInstance(boolean removeTime) {
|
||||||
|
var calendar = getCalendarInstance();
|
||||||
|
|
||||||
|
if(removeTime) {
|
||||||
|
calendar.set(Calendar.HOUR_OF_DAY, 0);
|
||||||
|
calendar.set(Calendar.MINUTE, 0);
|
||||||
|
calendar.set(Calendar.SECOND, 0);
|
||||||
|
calendar.set(Calendar.MILLISECOND, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
return calendar.getTime();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Calendar getCalendarInstance() {
|
public static Calendar getCalendarInstance() {
|
||||||
|
|||||||
@ -35,6 +35,7 @@ public class UtilityNumber {
|
|||||||
decimalFormat.setMaximumFractionDigits(decimal);
|
decimalFormat.setMaximumFractionDigits(decimal);
|
||||||
decimalFormat.setDecimalFormatSymbols(otherSymbols);
|
decimalFormat.setDecimalFormatSymbols(otherSymbols);
|
||||||
decimalFormat.setGroupingUsed(false);
|
decimalFormat.setGroupingUsed(false);
|
||||||
|
decimalFormat.setMinimumFractionDigits(2);
|
||||||
|
|
||||||
return decimalFormat.format(floatValue);
|
return decimalFormat.format(floatValue);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -277,7 +277,7 @@ public class ProdDettaglioLineaActivity extends BaseActivity implements ProdDett
|
|||||||
getSupportFragmentManager()
|
getSupportFragmentManager()
|
||||||
.beginTransaction()
|
.beginTransaction()
|
||||||
.add(R.id.frame_layout_container,
|
.add(R.id.frame_layout_container,
|
||||||
ProdRecuperoMaterialeFragment.newInstance(mViewModel.getLineaProd().getCodJfas(), DATA_KEY_FRAGMENT_LISTENER))
|
ProdRecuperoMaterialeFragment.newInstance(null, DATA_KEY_FRAGMENT_LISTENER))
|
||||||
.addToBackStack("ProdRecuperoMaterialeFragment")
|
.addToBackStack("ProdRecuperoMaterialeFragment")
|
||||||
.commit();
|
.commit();
|
||||||
|
|
||||||
|
|||||||
@ -9,10 +9,8 @@ import android.view.View;
|
|||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
import androidx.appcompat.widget.AppCompatTextView;
|
import androidx.appcompat.widget.AppCompatTextView;
|
||||||
import androidx.databinding.DataBindingUtil;
|
|
||||||
import androidx.databinding.ObservableArrayList;
|
import androidx.databinding.ObservableArrayList;
|
||||||
import androidx.fragment.app.Fragment;
|
import androidx.fragment.app.Fragment;
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
|
||||||
|
|
||||||
import com.annimon.stream.Stream;
|
import com.annimon.stream.Stream;
|
||||||
|
|
||||||
@ -88,7 +86,7 @@ public class ProdRecuperoMaterialeFragment extends BaseFragment implements ITitl
|
|||||||
@Override
|
@Override
|
||||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
Bundle savedInstanceState) {
|
Bundle savedInstanceState) {
|
||||||
mBinding = DataBindingUtil.inflate(inflater, R.layout.fragment_prod_recupero_materiale, container, false);
|
mBinding = FragmentProdRecuperoMaterialeBinding.inflate(inflater, container, false);
|
||||||
|
|
||||||
MainApplication.appComponent
|
MainApplication.appComponent
|
||||||
.prodRecuperoMaterialeComponent()
|
.prodRecuperoMaterialeComponent()
|
||||||
@ -168,8 +166,6 @@ public class ProdRecuperoMaterialeFragment extends BaseFragment implements ITitl
|
|||||||
private void initRecyclerView() {
|
private void initRecyclerView() {
|
||||||
this.mViewModel.getOrderList().observe(getViewLifecycleOwner(), this::refreshList);
|
this.mViewModel.getOrderList().observe(getViewLifecycleOwner(), this::refreshList);
|
||||||
|
|
||||||
mBinding.prodRecuperoMaterialeMainList.setLayoutManager(new LinearLayoutManager(getActivity()));
|
|
||||||
|
|
||||||
HistoryULsListAdapter adapter = new HistoryULsListAdapter(getActivity(), mHistoryULMutableData)
|
HistoryULsListAdapter adapter = new HistoryULsListAdapter(getActivity(), mHistoryULMutableData)
|
||||||
.setOnItemClicked(data -> this.mViewModel.dispatchItem(data.getOriginalModel(), null));
|
.setOnItemClicked(data -> this.mViewModel.dispatchItem(data.getOriginalModel(), null));
|
||||||
|
|
||||||
|
|||||||
@ -247,6 +247,7 @@ public class ProdRecuperMaterialeRESTConsumer extends _BaseRESTConsumer {
|
|||||||
.setCodCol(restDTO.getCodCol())
|
.setCodCol(restDTO.getCodCol())
|
||||||
.setCodTagl(restDTO.getCodTagl())
|
.setCodTagl(restDTO.getCodTagl())
|
||||||
.setCodJfas(restDTO.getCodJfas())
|
.setCodJfas(restDTO.getCodJfas())
|
||||||
|
.setDescrizioneArt(restDTO.getDescrizioneArt())
|
||||||
.setDescrizioneFase(restDTO.getDescrizioneFase())
|
.setDescrizioneFase(restDTO.getDescrizioneFase())
|
||||||
.setQtaCol(qtaColTot)
|
.setQtaCol(qtaColTot)
|
||||||
.setNumCnf(numCnfColTot)
|
.setNumCnf(numCnfColTot)
|
||||||
|
|||||||
@ -22,7 +22,9 @@
|
|||||||
android:background="@android:color/white"
|
android:background="@android:color/white"
|
||||||
android:id="@+id/prod_recupero_materiale_main_list"
|
android:id="@+id/prod_recupero_materiale_main_list"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent" />
|
android:layout_height="match_parent"
|
||||||
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
|
tools:listitem="@layout/prod_recupero_materiale_list_item"/>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/empty_view"
|
android:id="@+id/empty_view"
|
||||||
@ -54,25 +56,25 @@
|
|||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
app:layout_constraintStart_toEndOf="@id/guideline_empty_left"
|
android:orientation="vertical"
|
||||||
app:layout_constraintEnd_toStartOf="@id/guideline_empty_right"
|
app:layout_constraintEnd_toStartOf="@id/guideline_empty_right"
|
||||||
|
app:layout_constraintStart_toEndOf="@id/guideline_empty_left"
|
||||||
app:layout_constraintTop_toTopOf="@id/guideline_empty_top">
|
app:layout_constraintTop_toTopOf="@id/guideline_empty_top">
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:layout_width="72dp"
|
android:layout_width="72dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:src="@drawable/ic_playlist_add_check_24dp"
|
android:adjustViewBounds="true"
|
||||||
android:adjustViewBounds="true"/>
|
android:src="@drawable/ic_playlist_add_check_24dp" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
|
android:text="@string/no_item_in_recupera_materiale"
|
||||||
android:textColor="@android:color/black"
|
android:textColor="@android:color/black"
|
||||||
android:textSize="18sp"
|
android:textSize="18sp" />
|
||||||
android:text="@string/no_item_in_recupera_materiale"/>
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|||||||
@ -2,29 +2,17 @@
|
|||||||
|
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools">
|
<layout xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
<androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
android:orientation="vertical" android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.AppCompatTextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:background="@android:color/white"
|
|
||||||
android:layout_marginTop="16dp">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
|
||||||
android:id="@+id/recuper_materiale_main_list_group_header"
|
android:id="@+id/recuper_materiale_main_list_group_header"
|
||||||
|
style="@style/TextAppearance.Material3.HeadlineSmall"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
tools:text="LINEA1"
|
android:layout_marginHorizontal="16dp"
|
||||||
android:textSize="16sp"
|
android:layout_marginVertical="8dp"
|
||||||
android:textStyle="bold"
|
android:paddingTop="8dp"
|
||||||
android:textAllCaps="true"
|
android:textAllCaps="true"
|
||||||
android:textColor="@color/colorPrimary"
|
android:textColor="@color/colorPrimary"
|
||||||
android:layout_marginStart="16dp"
|
tools:text="Linea 1" />
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
android:layout_marginBottom="8dp"/>
|
|
||||||
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
|
||||||
</layout>
|
</layout>
|
||||||
|
|||||||
@ -1,47 +1,41 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout>
|
<layout>
|
||||||
<RelativeLayout
|
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:background="@android:color/white"
|
|
||||||
android:paddingTop="8dp"
|
|
||||||
android:paddingBottom="8dp">
|
|
||||||
|
|
||||||
<LinearLayout
|
<androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:id="@+id/left_content"
|
android:id="@+id/left_content"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal"
|
android:orientation="horizontal"
|
||||||
android:layout_alignParentStart="true"
|
android:paddingVertical="8dp"
|
||||||
android:paddingEnd="8dp">
|
android:paddingEnd="8dp">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
|
||||||
android:layout_marginStart="16dp"
|
android:layout_marginStart="16dp"
|
||||||
android:layout_marginEnd="16dp">
|
android:layout_marginEnd="16dp"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_horizontal"
|
android:layout_gravity="center_horizontal"
|
||||||
android:layout_marginBottom="-8dp"
|
android:layout_marginBottom="-8dp"
|
||||||
android:text="@string/logistic_unit"/>
|
android:text="@string/logistic_unit" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/num_collo"
|
android:id="@+id/num_collo"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
tools:text="22"
|
android:layout_gravity="center_vertical"
|
||||||
android:textColor="@android:color/black"
|
android:textColor="@android:color/black"
|
||||||
android:textStyle="bold"
|
|
||||||
android:textSize="22sp"
|
android:textSize="22sp"
|
||||||
android:layout_gravity="center_vertical"/>
|
android:textStyle="bold"
|
||||||
|
tools:text="22" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -53,34 +47,31 @@
|
|||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/cod_mart"
|
android:id="@+id/cod_mart"
|
||||||
|
style="@style/TextAppearance.Material3.TitleMedium"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="18sp"
|
tools:text="150101-040" />
|
||||||
tools:text="150101-040"
|
|
||||||
android:textColor="@android:color/black"
|
|
||||||
/>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/partita_mag"
|
android:id="@+id/partita_mag"
|
||||||
|
style="@style/TextAppearance.Material3.TitleSmall"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textColor="@color/gray_700"
|
|
||||||
tools:text="Lotto articolo"
|
|
||||||
android:layout_marginStart="4dp"
|
|
||||||
android:layout_toEndOf="@id/cod_mart"
|
|
||||||
android:layout_toStartOf="@id/right_content"
|
|
||||||
android:layout_alignBottom="@id/cod_mart"
|
android:layout_alignBottom="@id/cod_mart"
|
||||||
|
android:layout_marginStart="4dp"
|
||||||
|
android:layout_marginEnd="6dp"
|
||||||
|
android:layout_toStartOf="@id/right_content"
|
||||||
|
android:layout_toEndOf="@id/cod_mart"
|
||||||
android:ellipsize="end"
|
android:ellipsize="end"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
android:layout_marginEnd="6dp"
|
tools:text="Lotto articolo" />
|
||||||
/>
|
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:id="@+id/right_content"
|
android:id="@+id/right_content"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_alignParentEnd="true"
|
|
||||||
android:layout_alignBottom="@id/cod_mart"
|
android:layout_alignBottom="@id/cod_mart"
|
||||||
|
android:layout_alignParentEnd="true"
|
||||||
android:paddingEnd="8dp">
|
android:paddingEnd="8dp">
|
||||||
|
|
||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
@ -90,18 +81,18 @@
|
|||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/qta_versata"
|
android:id="@+id/qta_versata"
|
||||||
|
style="@style/TextAppearance.Material3.BodyLarge"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="18sp"
|
tools:text="27" />
|
||||||
tools:text="27"/>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/unt_mis_qta_versata"
|
android:id="@+id/unt_mis_qta_versata"
|
||||||
|
style="@style/TextAppearance.Material3.BodyMedium"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="4dp"
|
android:layout_marginStart="2dp"
|
||||||
android:textSize="18sp"
|
tools:text="PZ" />
|
||||||
tools:text="PZ"/>
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
@ -112,18 +103,14 @@
|
|||||||
android:id="@+id/descrizione"
|
android:id="@+id/descrizione"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textColor="@color/gray_700"
|
|
||||||
tools:text="Descrizione estesa articolo"
|
|
||||||
android:ellipsize="end"
|
android:ellipsize="end"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
/>
|
style="@style/TextAppearance.Material3.BodySmall"
|
||||||
|
tools:text="Descrizione estesa articolo" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</LinearLayout>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</RelativeLayout>
|
|
||||||
|
|
||||||
</layout>
|
</layout>
|
||||||
Loading…
x
Reference in New Issue
Block a user