refs #5135 feat: refactor animation.
This commit is contained in:
parent
d787d8e861
commit
b33511a3ed
|
@ -127,44 +127,113 @@
|
||||||
</select>
|
</select>
|
||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="fa688d1c-dbee-4864-9e33-4d84ef9afca8" name="Default Changelist" comment="version 24.2Beta">
|
<list default="true" id="fa688d1c-dbee-4864-9e33-4d84ef9afca8" name="Default Changelist" comment="refs #5135 feat: refactor animation. HotFix phones cambiar a String(varchar en bbdd)">
|
||||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/beta/release/output-metadata.json" beforeDir="false" afterPath="$PROJECT_DIR$/app/beta/release/output-metadata.json" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/beta/release/output-metadata.json" beforeDir="false" afterPath="$PROJECT_DIR$/app/beta/release/output-metadata.json" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/build.gradle" beforeDir="false" afterPath="$PROJECT_DIR$/app/build.gradle" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/build.gradle" beforeDir="false" afterPath="$PROJECT_DIR$/app/build.gradle" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/MobileApplication.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/MobileApplication.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/domain/SalixService.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/domain/SalixService.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/domain/SalixService.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/domain/SalixService.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragmentSalix.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragmentSalix.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/base/BaseFragmentSalix.kt" beforeDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/buffer/fragment/BufferFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/buffer/fragment/BufferFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/common/UICallbacks.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/common/UICallbacks.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/testing/testPrint.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/testing/testPrint.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ajustes/fragment/AjustesFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ajustes/fragment/AjustesFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ajustes/fragment/AjustesViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ajustes/fragment/AjustesViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/articulo/fragment/ItemCardFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/articulo/fragment/ItemCardFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/articulo/fragment/ItemCardViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/articulo/fragment/ItemCardViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/articulo/fragment/ItemProposalFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/articulo/fragment/ItemProposalFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/buffer/fragment/BufferFragmentViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/buffer/fragment/BufferFragmentViewModel.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/buffer/fragment/BufferFragmentViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/buffer/fragment/BufferFragmentViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/claim/fragment/ClaimFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/claim/fragment/ClaimFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/claim/fragment/ClaimViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/claim/fragment/ClaimViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/adapter/SaleAdapter.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/adapter/SaleAdapter.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/adapter/SaleAdapterNew.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/adapter/SaleAdapterNew.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/adapter/SaleAdapterNew.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/adapter/SaleAdapterNew.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPicker.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPicker.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPickerNew.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPickerNew.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPickerNew.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPickerNew.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPreChecker.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionFragmentPreChecker.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoUsuarioFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoUsuarioFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/collection/fragment/CollectionViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlador/fragment/ControladorViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlador/fragment/ControladorViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlador/fragment/WebFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlador/fragment/WebFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoViewModel.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/controlvehiculo/fragment/ControlVehiculoViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/InfoFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/InfoFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/activity/SignedActivity.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/activity/SignedActivity.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/LoadUnloadFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/LoadUnloadFragment.kt" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/LogExpeditionFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/LogExpeditionFragment.kt" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/RoutesFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/RoutesFragment.kt" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/SummaryFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/SummaryFragment.kt" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/TicketsFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/TicketsFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/TicketsFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/fragments/TicketsFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/model/ClientTicket.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/model/ClientTicket.kt" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/viewmodels/DeliveryViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/viewmodels/DeliveryViewModel.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/viewmodels/DeliveryViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/delivery/viewmodels/DeliveryViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/CmrExpeditionPalletFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/CmrExpeditionPalletFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/historicoarticulo/fragment/HistoricoArticuloFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/historicoarticulo/fragment/HistoricoArticuloFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/CmrExpeditionPalletViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/CmrExpeditionPalletViewModel.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/historicoarticulo/fragment/HistoricoArticuloViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/historicoarticulo/fragment/HistoricoArticuloViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanSorterFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanSorterFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/inventario/fragment/InventaryViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/inventario/fragment/InventaryViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanSorterViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanSorterViewModel.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/login/activity/LoginActivity.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/login/activity/LoginActivity.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/login/fragment/LoginFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/login/fragment/LoginFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/login/fragment/LoginViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/login/fragment/LoginViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/main/activity/MainActivity.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/main/activity/MainActivity.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/ObservFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/ObservFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/PackagingCountFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/PackagingCountFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/PackagingSummaryFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/PackagingSummaryFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/PackagingViewModel/SupplierViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/PackagingViewModel/SupplierViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/SupplierFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packaging/fragment/SupplierFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packingHolland/fragment/PackingHollandFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/packingHolland/fragment/PackingHollandFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/adapter/ExpeditionListAdapter.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/adapter/ExpeditionListAdapter.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/adapter/ExpeditionPalletAdapter.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/adapter/ExpeditionPalletAdapter.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/adapter/ExpeditionScanAdapter.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/adapter/ExpeditionScanAdapter.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionPalletDetailFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionPalletDetailFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionPalletDetailViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionPalletDetailViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/ExpeditionScanViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanFragment.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanViewModel.kt" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/paletizador/fragment/PalletScanViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buffer.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buffer.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/parking/fragment/ParkingFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/parking/fragment/ParkingFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buffer_loadexpedition.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buffer_loadexpedition.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/pasillero/adapter/PasillerosAdapter.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/pasillero/adapter/PasillerosAdapter.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_loadunload_delivery.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_loadunload_delivery.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/photos/fragment/PhotosViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/photos/fragment/PhotosViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_log_delivery.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_log_delivery.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/precontrol/PreControladorFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/precontrol/PreControladorFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_summary.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_summary.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/precontrol/PreControladorViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/precontrol/PreControladorViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expeditionscan_sorter.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expeditionscan_sorter.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/presacador/fragment/EndSacadorFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/presacador/fragment/EndSacadorFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_info_delivery.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_info_delivery.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/presacador/fragment/InitPreSacadorFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/presacador/fragment/InitPreSacadorFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_route.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_route.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/presacador/fragment/PreSacadorViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/presacador/fragment/PreSacadorViewModel.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_tickets.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_tickets.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/qr/QrFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/qr/QrFragment.kt" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_vehiclecontrol_user.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_vehiclecontrol_user.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/reubication/fragment/ReubicationFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/reubication/fragment/ReubicationFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/SacadorFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/SacadorFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/SacadorFragmentNew.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/SacadorFragmentNew.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/SacadorViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/SacadorViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/showticket/ShowTicketFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/sacador/fragment/showticket/ShowTicketFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ticket/fragment/TicketAdvanceFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ticket/fragment/TicketAdvanceFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ticket/fragment/TicketViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ticket/fragment/TicketViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/transferencia/fragment/TransferenciaFragment.kt" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/transferencia/fragment/TransferenciaViewModel.kt" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/AutomaticAddItemFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/AutomaticAddItemFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/AutomaticAddItemFragmentTEST.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/AutomaticAddItemFragmentTEST.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/AutomaticAddItemViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/AutomaticAddItemViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/UbicadorFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/UbicadorFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/UbicadorViewModel.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/ubicador/fragment/UbicadorViewModel.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/workermistake/fragment/PackingMistakeFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/workermistake/fragment/PackingMistakeFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/workermistake/fragment/WorkermistakeFragment.kt" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/java/es/verdnatura/presentation/view/feature/workermistake/fragment/WorkermistakeFragment.kt" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/activity_login.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/activity_login.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/activity_sign.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/activity_sign.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/buyers_fragment.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_ajustes.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_ajustes.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_automatic_add_item.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_automatic_add_item.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buffer_load.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buffer_load.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_buscar_item_all.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_pallet_detail.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_pallet_detail.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_scan.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_expedition_scan.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_general_black.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_general_black.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_historico.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_historico.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_inventary_old.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_itemproposal.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_itemproposal.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_itemshelvingdayofsale.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_login.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_login.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging_count.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging_count.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging_obs.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging_obs.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging_summary.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_packaging_summary.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_qr.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_qr.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_sacador.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_sacador.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_sacador_associatesmarttag.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_shelving_parking.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_testing_print.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_testing_print.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_transferencia.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_ubicador.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_ubicador.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/fragment_web.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/fragment_web.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/reposicion_fragment.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/app/src/main/res/layout/toolbar_fragment.xml" beforeDir="false" afterPath="$PROJECT_DIR$/app/src/main/res/layout/toolbar_fragment.xml" afterDir="false" />
|
||||||
</list>
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
|
@ -178,7 +247,7 @@
|
||||||
<component name="CodeInsightWorkspaceSettings">
|
<component name="CodeInsightWorkspaceSettings">
|
||||||
<option name="optimizeImportsOnTheFly" value="true" />
|
<option name="optimizeImportsOnTheFly" value="true" />
|
||||||
</component>
|
</component>
|
||||||
<component name="ExecutionTargetManager" SELECTED_TARGET="device_and_snapshot_combo_box_target[21114523025303]" />
|
<component name="ExecutionTargetManager" SELECTED_TARGET="device_and_snapshot_combo_box_target[C:\Users\sergiodt\.android\avd\Pixel_6a_API_24.avd]" />
|
||||||
<component name="ExportToHTMLSettings">
|
<component name="ExportToHTMLSettings">
|
||||||
<option name="OPEN_IN_BROWSER" value="true" />
|
<option name="OPEN_IN_BROWSER" value="true" />
|
||||||
<option name="OUTPUT_DIRECTORY" value="C:\Program Files\Android\Android Studio\inspections" />
|
<option name="OUTPUT_DIRECTORY" value="C:\Program Files\Android\Android Studio\inspections" />
|
||||||
|
@ -323,44 +392,44 @@
|
||||||
<option name="showLibraryContents" value="true" />
|
<option name="showLibraryContents" value="true" />
|
||||||
<option name="showMembers" value="true" />
|
<option name="showMembers" value="true" />
|
||||||
</component>
|
</component>
|
||||||
<component name="PropertiesComponent"><![CDATA[{
|
<component name="PropertiesComponent">{
|
||||||
"keyToString": {
|
"keyToString": {
|
||||||
"ApkExportedModule": "Gestor_Almacén.app",
|
"ApkExportedModule": "Gestor_Almacén.app",
|
||||||
"ExportApk.ApkPathForGestor_Almacén.app": "C:\\Users\\sergiodt\\AndroidStudioProjects\\vn-warehouseManager\\app",
|
"ExportApk.ApkPathForGestor_Almacén.app": "C:\\Users\\sergiodt\\AndroidStudioProjects\\vn-warehouseManager\\app",
|
||||||
"KotlinFunctionFindUsagesOptions.isSearchForTextOccurrences": "true",
|
"KotlinFunctionFindUsagesOptions.isSearchForTextOccurrences": "true",
|
||||||
"PROJECT_TRUSTED_KEY": "true",
|
"PROJECT_TRUSTED_KEY": "true",
|
||||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||||
"RunOnceActivity.cidr.known.project.marker": "true",
|
"RunOnceActivity.cidr.known.project.marker": "true",
|
||||||
"SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
"SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||||
"ScreenRecorder.SavePath": "C:\\Users\\sergiodt",
|
"ScreenRecorder.SavePath": "C:\\Users\\sergiodt",
|
||||||
"android-custom-viewC:/Users/sergiodt/.gradle/caches/modules-2/files-2.1/androidx.recyclerview/recyclerview/1.2.1/f0f93e67af3f7417bdd560d5142f6dec4fe629c3/recyclerview-1.2.1-sources.jar!/androidx/recyclerview/widget/RecyclerView.java_SELECTED": "RecyclerView",
|
"android-custom-viewC:/Users/sergiodt/.gradle/caches/modules-2/files-2.1/androidx.recyclerview/recyclerview/1.2.1/f0f93e67af3f7417bdd560d5142f6dec4fe629c3/recyclerview-1.2.1-sources.jar!/androidx/recyclerview/widget/RecyclerView.java_SELECTED": "RecyclerView",
|
||||||
"android-custom-viewC:/Users/sergiodt/AppData/Local/Android/Sdk/sources/android-29/android/widget/TextView.java_SELECTED": "TextView",
|
"android-custom-viewC:/Users/sergiodt/AppData/Local/Android/Sdk/sources/android-29/android/widget/TextView.java_SELECTED": "TextView",
|
||||||
"android-custom-viewC:/Users/sergiodt/AppData/Local/Android/Sdk/sources/android-33/android/view/View.java_SELECTED": "View",
|
"android-custom-viewC:/Users/sergiodt/AppData/Local/Android/Sdk/sources/android-33/android/view/View.java_SELECTED": "View",
|
||||||
"cidr.known.project.marker": "true",
|
"cidr.known.project.marker": "true",
|
||||||
"com.android.tools.idea.devicemanager.tab": "Physical",
|
"com.android.tools.idea.devicemanager.tab": "Physical",
|
||||||
"com.developerphil.adbidea.selecteddevices": "21114523025303",
|
"com.developerphil.adbidea.selecteddevices": "21114523025303",
|
||||||
"com.google.services.firebase.aqiPopupShown": "true",
|
"com.google.services.firebase.aqiPopupShown": "true",
|
||||||
"git-widget-placeholder": "dev",
|
"git-widget-placeholder": "dev",
|
||||||
"last_opened_file_path": "C:/Users/sergiodt/AndroidStudioProjects/vn-warehouseManager/app/src/main/res/drawable",
|
"last_opened_file_path": "C:/Users/sergiodt/AndroidStudioProjects/vn-warehouseManager/app/src/main/res/drawable",
|
||||||
"project.structure.last.edited": "Suggestions",
|
"project.structure.last.edited": "Suggestions",
|
||||||
"project.structure.proportion": "0.17",
|
"project.structure.proportion": "0.17",
|
||||||
"project.structure.side.proportion": "0.2",
|
"project.structure.side.proportion": "0.2",
|
||||||
"run.code.analysis.last.selected.profile": "pProject Default",
|
"run.code.analysis.last.selected.profile": "pProject Default",
|
||||||
"settings.editor.selected.configurable": "preferences.sourceCode.Kotlin"
|
"settings.editor.selected.configurable": "preferences.sourceCode.Kotlin"
|
||||||
},
|
},
|
||||||
"keyToStringList": {
|
"keyToStringList": {
|
||||||
"ExportApk.BuildVariants": [
|
"ExportApk.BuildVariants": [
|
||||||
"betaRelease"
|
"betaRelease"
|
||||||
],
|
],
|
||||||
"com.android.tools.idea.sqlite.queryhistory": [
|
"com.android.tools.idea.sqlite.queryhistory": [
|
||||||
"select * from expedition where routeFk=182933;",
|
"select * from expedition where routeFk=182933;",
|
||||||
"select * from expedition;",
|
"select * from expedition;",
|
||||||
"select * from expeditionPending;",
|
"select * from expeditionPending;",
|
||||||
"select * from expedition where id = 7753995;\n\n",
|
"select * from expedition where id = 7753995;\n\n",
|
||||||
"\nselect * from expedition where id = 7753995;"
|
"\nselect * from expedition where id = 7753995;"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}]]></component>
|
}</component>
|
||||||
<component name="PsdUISettings">
|
<component name="PsdUISettings">
|
||||||
<option name="MODULE_TAB" value="Properties" />
|
<option name="MODULE_TAB" value="Properties" />
|
||||||
<option name="LAST_EDITED_SIGNING_CONFIG" value="debug" />
|
<option name="LAST_EDITED_SIGNING_CONFIG" value="debug" />
|
||||||
|
@ -532,13 +601,6 @@
|
||||||
<option name="presentableId" value="Default" />
|
<option name="presentableId" value="Default" />
|
||||||
<updated>1618825571576</updated>
|
<updated>1618825571576</updated>
|
||||||
</task>
|
</task>
|
||||||
<task id="LOCAL-00181" summary="refs #5764 modify dayOfSale">
|
|
||||||
<created>1694769010620</created>
|
|
||||||
<option name="number" value="00181" />
|
|
||||||
<option name="presentableId" value="LOCAL-00181" />
|
|
||||||
<option name="project" value="LOCAL" />
|
|
||||||
<updated>1694769010621</updated>
|
|
||||||
</task>
|
|
||||||
<task id="LOCAL-00182" summary="refs #5134 Refactor silex→salix">
|
<task id="LOCAL-00182" summary="refs #5134 Refactor silex→salix">
|
||||||
<created>1695100583023</created>
|
<created>1695100583023</created>
|
||||||
<option name="number" value="00182" />
|
<option name="number" value="00182" />
|
||||||
|
@ -875,7 +937,14 @@
|
||||||
<option name="project" value="LOCAL" />
|
<option name="project" value="LOCAL" />
|
||||||
<updated>1704875974711</updated>
|
<updated>1704875974711</updated>
|
||||||
</task>
|
</task>
|
||||||
<option name="localTasksCounter" value="230" />
|
<task id="LOCAL-00230" summary="refs #5135 feat: refactor animation. HotFix phones cambiar a String(varchar en bbdd)">
|
||||||
|
<created>1705049073158</created>
|
||||||
|
<option name="number" value="00230" />
|
||||||
|
<option name="presentableId" value="LOCAL-00230" />
|
||||||
|
<option name="project" value="LOCAL" />
|
||||||
|
<updated>1705049073160</updated>
|
||||||
|
</task>
|
||||||
|
<option name="localTasksCounter" value="231" />
|
||||||
<servers />
|
<servers />
|
||||||
</component>
|
</component>
|
||||||
<component name="Vcs.Log.History.Properties">
|
<component name="Vcs.Log.History.Properties">
|
||||||
|
@ -976,7 +1045,6 @@
|
||||||
</component>
|
</component>
|
||||||
<component name="VcsManagerConfiguration">
|
<component name="VcsManagerConfiguration">
|
||||||
<option name="ADD_EXTERNAL_FILES_SILENTLY" value="true" />
|
<option name="ADD_EXTERNAL_FILES_SILENTLY" value="true" />
|
||||||
<MESSAGE value="refs #5890" />
|
|
||||||
<MESSAGE value="refs #5802 ticketSetState" />
|
<MESSAGE value="refs #5802 ticketSetState" />
|
||||||
<MESSAGE value="version 23.40.1-hotFix OrderPrevia" />
|
<MESSAGE value="version 23.40.1-hotFix OrderPrevia" />
|
||||||
<MESSAGE value="version 23.40.1-hotFix Ubicador" />
|
<MESSAGE value="version 23.40.1-hotFix Ubicador" />
|
||||||
|
@ -1001,7 +1069,8 @@
|
||||||
<MESSAGE value="version 24.2Beta" />
|
<MESSAGE value="version 24.2Beta" />
|
||||||
<MESSAGE value="refs #6275 fix: filter getTickets y driver" />
|
<MESSAGE value="refs #6275 fix: filter getTickets y driver" />
|
||||||
<MESSAGE value="refs #5135 feat: refactor animation" />
|
<MESSAGE value="refs #5135 feat: refactor animation" />
|
||||||
<option name="LAST_COMMIT_MESSAGE" value="refs #5135 feat: refactor animation" />
|
<MESSAGE value="refs #5135 feat: refactor animation. HotFix phones cambiar a String(varchar en bbdd)" />
|
||||||
|
<option name="LAST_COMMIT_MESSAGE" value="refs #5135 feat: refactor animation. HotFix phones cambiar a String(varchar en bbdd)" />
|
||||||
</component>
|
</component>
|
||||||
<component name="XDebuggerManager">
|
<component name="XDebuggerManager">
|
||||||
<breakpoint-manager>
|
<breakpoint-manager>
|
||||||
|
|
|
@ -12,7 +12,9 @@ import es.verdnatura.domain.SalixService
|
||||||
import es.verdnatura.domain.VerdnaturaService
|
import es.verdnatura.domain.VerdnaturaService
|
||||||
import es.verdnatura.domain.toast
|
import es.verdnatura.domain.toast
|
||||||
import es.verdnatura.presentation.common.InteceptorListener
|
import es.verdnatura.presentation.common.InteceptorListener
|
||||||
|
import es.verdnatura.presentation.common.LoginListener
|
||||||
import es.verdnatura.presentation.common.MainActivityListener
|
import es.verdnatura.presentation.common.MainActivityListener
|
||||||
|
import es.verdnatura.presentation.common.SignListener
|
||||||
import es.verdnatura.presentation.view.component.CustomDialogMainActivity
|
import es.verdnatura.presentation.view.component.CustomDialogMainActivity
|
||||||
import org.koin.android.ext.koin.androidContext
|
import org.koin.android.ext.koin.androidContext
|
||||||
import org.koin.core.context.loadKoinModules
|
import org.koin.core.context.loadKoinModules
|
||||||
|
@ -21,10 +23,20 @@ import org.koin.core.context.startKoin
|
||||||
class MobileApplication : Application(), InteceptorListener {
|
class MobileApplication : Application(), InteceptorListener {
|
||||||
private lateinit var interceptoreListener: InteceptorListener
|
private lateinit var interceptoreListener: InteceptorListener
|
||||||
private var mainActivityListener: MainActivityListener? = null
|
private var mainActivityListener: MainActivityListener? = null
|
||||||
|
private var loginListener: LoginListener? = null
|
||||||
|
private var signListener: SignListener? = null
|
||||||
fun setMainListener(listener: MainActivityListener) {
|
fun setMainListener(listener: MainActivityListener) {
|
||||||
mainActivityListener = listener
|
mainActivityListener = listener
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fun setLoginListener(listener: LoginListener) {
|
||||||
|
loginListener = listener
|
||||||
|
}
|
||||||
|
|
||||||
|
fun setSignListener(listener: SignListener) {
|
||||||
|
signListener = listener
|
||||||
|
}
|
||||||
|
|
||||||
lateinit var silex: VerdnaturaService
|
lateinit var silex: VerdnaturaService
|
||||||
lateinit var salix: SalixService
|
lateinit var salix: SalixService
|
||||||
var userId: Int? = null
|
var userId: Int? = null
|
||||||
|
@ -90,11 +102,19 @@ class MobileApplication : Application(), InteceptorListener {
|
||||||
override fun onInterceptionResult(visibility: Int) {
|
override fun onInterceptionResult(visibility: Int) {
|
||||||
if (mainActivityListener != null) {
|
if (mainActivityListener != null) {
|
||||||
handler.post {
|
handler.post {
|
||||||
val mainActivityListener = this.mainActivityListener
|
(this.mainActivityListener)?.onApplicationEventAnimation(visibility)
|
||||||
mainActivityListener?.onApplicationEventAnimation(visibility)
|
}
|
||||||
|
}
|
||||||
|
if (loginListener != null) {
|
||||||
|
handler.post {
|
||||||
|
(this.loginListener)?.onApplicationEventAnimation(visibility)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (signListener != null) {
|
||||||
|
handler.post {
|
||||||
|
(this.signListener)?.onApplicationEventAnimation(visibility)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
|
@ -73,18 +73,6 @@ interface SalixService {
|
||||||
fun getCurrentUserData(
|
fun getCurrentUserData(
|
||||||
): Call<DataUserSalix>
|
): Call<DataUserSalix>
|
||||||
|
|
||||||
/* @POST("chats/sendCheckingPresence")
|
|
||||||
fun sendChekingPresence(
|
|
||||||
@Body params: SalixMessageVO
|
|
||||||
):
|
|
||||||
Call<Boolean>
|
|
||||||
|
|
||||||
@POST("chats/send")
|
|
||||||
fun sendGroup(
|
|
||||||
@Body params: SalixGrupo
|
|
||||||
):
|
|
||||||
Call<Boolean>*/
|
|
||||||
|
|
||||||
@GET("collections/getSectors")
|
@GET("collections/getSectors")
|
||||||
fun getSectorsSalix(
|
fun getSectorsSalix(
|
||||||
): Call<List<SectorItemVO>>
|
): Call<List<SectorItemVO>>
|
||||||
|
|
|
@ -62,9 +62,6 @@ abstract class BaseFragment<T : ViewDataBinding, V : BaseViewModel>(
|
||||||
|
|
||||||
protected val ITEMPACKING = "itemPackingType"
|
protected val ITEMPACKING = "itemPackingType"
|
||||||
protected val ITEMPACKINGFK = "itemPackingTypeFk"
|
protected val ITEMPACKINGFK = "itemPackingTypeFk"
|
||||||
|
|
||||||
//protected val VOZ = "voz"
|
|
||||||
//nuevo campo número carros ajustes y campos para guardar el buyerid y buyernickname
|
|
||||||
protected val BUYER = "buyernickname"
|
protected val BUYER = "buyernickname"
|
||||||
protected val BUYERID = "buyerid"
|
protected val BUYERID = "buyerid"
|
||||||
protected val WAGON = "wagon"
|
protected val WAGON = "wagon"
|
||||||
|
|
|
@ -1,591 +0,0 @@
|
||||||
package es.verdnatura.presentation.base
|
|
||||||
|
|
||||||
|
|
||||||
import android.content.Context
|
|
||||||
import android.content.SharedPreferences
|
|
||||||
import android.os.Bundle
|
|
||||||
import android.view.LayoutInflater
|
|
||||||
import android.view.View
|
|
||||||
import android.view.ViewGroup
|
|
||||||
import android.widget.LinearLayout
|
|
||||||
import androidx.annotation.LayoutRes
|
|
||||||
import androidx.databinding.DataBindingUtil
|
|
||||||
import androidx.databinding.ViewDataBinding
|
|
||||||
import androidx.fragment.app.Fragment
|
|
||||||
import androidx.preference.PreferenceManager
|
|
||||||
import androidx.room.Room
|
|
||||||
import com.google.gson.Gson
|
|
||||||
import com.google.gson.reflect.TypeToken
|
|
||||||
import es.verdnatura.MobileApplication
|
|
||||||
import es.verdnatura.R
|
|
||||||
import es.verdnatura.databinding.ToolbarFragmentBinding
|
|
||||||
import es.verdnatura.db.DeliveryDatabase
|
|
||||||
import es.verdnatura.domain.ConstAndValues.SECTORFKDEFAULT
|
|
||||||
import es.verdnatura.domain.ConstAndValues.WAREHOUSEFKDEFAULT
|
|
||||||
import es.verdnatura.presentation.view.feature.login.model.OperatorSalix
|
|
||||||
import es.verdnatura.presentation.view.feature.login.model.WorkForms
|
|
||||||
import es.verdnatura.presentation.view.feature.main.activity.MainActivity
|
|
||||||
import org.json.JSONObject
|
|
||||||
import org.koin.androidx.viewmodel.ext.android.viewModel
|
|
||||||
import java.util.*
|
|
||||||
import kotlin.collections.Map.*
|
|
||||||
import kotlin.reflect.KClass
|
|
||||||
|
|
||||||
|
|
||||||
abstract class BaseFragmentSalix<T : ViewDataBinding, V : BaseViewModel, W : BaseViewModel>(
|
|
||||||
viewModelClass: KClass<V>,
|
|
||||||
viewModelClass2: KClass<W>
|
|
||||||
) : Fragment() {
|
|
||||||
protected lateinit var mobileApplication: MobileApplication
|
|
||||||
protected val TAG = "VERDNATURA::"
|
|
||||||
protected val PREFS_USER = "es.verdnatura.user.prefs"
|
|
||||||
protected val PREFS_SERVER = "es.verdnatura.server.prefs"
|
|
||||||
protected val USERFK = "userFk"
|
|
||||||
protected val USER = "user"
|
|
||||||
protected val PASSWORD = "password"
|
|
||||||
protected val TOKEN = "token"
|
|
||||||
protected val TTL = "ttl"
|
|
||||||
protected val TOKENCREATED = "tokenCreated"
|
|
||||||
protected val SECTORDESCRIP = "sectordescrip"
|
|
||||||
protected val SECTORFK = "sectorFk"
|
|
||||||
protected val NUMBEROFWAGONS = "operatorNumberOfWagons"
|
|
||||||
protected val PRINTERNAME = "printername"
|
|
||||||
protected val PRINTERFK = "printerFk"
|
|
||||||
protected val WAREHOUSEFK = "warehouseFk"
|
|
||||||
protected val REMEMBER = "recordar"
|
|
||||||
protected val ANDROID_ID = "ANDROID_ID"
|
|
||||||
protected val DEVICENAME = "devicename"
|
|
||||||
protected val TRAINNAME = "trainName"
|
|
||||||
protected val TRAINFK = "trainFk"
|
|
||||||
protected val WORKFORMSELECTED = "workFormSelected"
|
|
||||||
protected val SUPPLIERID = "SUPPLIERID"
|
|
||||||
protected val ITEMPACKING = "itemPackingType"
|
|
||||||
protected val ITEMPACKINGFK = "itemPackingTypeFk"
|
|
||||||
protected val BUYER = "buyernickname"
|
|
||||||
protected val BUYERID = "buyerid"
|
|
||||||
protected val WAGON = "wagon"
|
|
||||||
protected val TAGSTYPE = "tagstype"
|
|
||||||
protected val WAREHOUSEFK_DEFAULT = 60
|
|
||||||
protected val DATENOVEHICLE = "DATENOVEHICLE"
|
|
||||||
protected val DEPARTMENTMISTAKE = "DEPARTMENTMISTAKE"
|
|
||||||
protected val DEPARTMENTMISTAKEID = "DEPARTMENTMISTAKEID"
|
|
||||||
|
|
||||||
protected val viewModel: V by viewModel(viewModelClass)
|
|
||||||
protected val viewModelSalix: W by viewModel(viewModelClass2)
|
|
||||||
|
|
||||||
protected lateinit var binding: T
|
|
||||||
protected lateinit var ma: MainActivity
|
|
||||||
protected lateinit var layoutAnimation:LinearLayout
|
|
||||||
|
|
||||||
override fun onAttach(context: Context) {
|
|
||||||
super.onAttach(context)
|
|
||||||
|
|
||||||
if ((requireActivity().componentName).toString().contains("MainActivity")) {
|
|
||||||
|
|
||||||
ma = activity as MainActivity
|
|
||||||
}
|
|
||||||
mobileApplication = requireActivity().application as MobileApplication
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onCreateView(
|
|
||||||
inflater: LayoutInflater,
|
|
||||||
container: ViewGroup?,
|
|
||||||
savedInstanceState: Bundle?
|
|
||||||
): View? = inflater.inflate(getLayoutId(), container, false)
|
|
||||||
|
|
||||||
|
|
||||||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
|
||||||
super.onViewCreated(view, savedInstanceState)
|
|
||||||
initDataBinding()
|
|
||||||
observeViewModel()
|
|
||||||
init()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@LayoutRes
|
|
||||||
abstract fun getLayoutId(): Int
|
|
||||||
open fun init() {}
|
|
||||||
open fun observeViewModel() {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
open fun stopAnimation(){
|
|
||||||
if (::layoutAnimation.isInitialized)
|
|
||||||
layoutAnimation.visibility = View.GONE
|
|
||||||
}
|
|
||||||
private fun initDataBinding() {
|
|
||||||
binding = DataBindingUtil.bind<T>(requireView())!!
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun callBack(function:Unit, splashProgress: LinearLayout = layoutAnimation) {
|
|
||||||
splashProgress.visibility = View.VISIBLE
|
|
||||||
function
|
|
||||||
stopAnimation()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun textScanned_filterDouble(textScanned: String): String {
|
|
||||||
|
|
||||||
if (textScanned.length > 13) {
|
|
||||||
val size = textScanned.length
|
|
||||||
if (textScanned.substring((size / 2), size) == textScanned.substring(0, size / 2)
|
|
||||||
) {
|
|
||||||
return textScanned.substring(0, size / 2)
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
return textScanned
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getTooltip(image: Int): String {
|
|
||||||
|
|
||||||
return when (image) {
|
|
||||||
//itemCard
|
|
||||||
R.drawable.ic_autorenew_black_24dp -> {
|
|
||||||
getString(R.string.reloadItemData)
|
|
||||||
}
|
|
||||||
|
|
||||||
R.drawable.ic_history_black_24dp -> getString(R.string.showHistoricalItem)
|
|
||||||
//presacador
|
|
||||||
R.drawable.ic_local_parking_black_24dp -> getString(R.string.allowParking)
|
|
||||||
//collection
|
|
||||||
R.drawable.ic_print_black_24dp -> getString(R.string.printTicket)
|
|
||||||
R.drawable.ic_playlist_add_black_24dp -> getString(R.string.addItem)
|
|
||||||
R.drawable.ic_worker -> getString(R.string.showFacePicker)
|
|
||||||
R.drawable.phone_call -> getString(R.string.callPicker)
|
|
||||||
R.drawable.car -> getString(R.string.allowSelectVehicle)
|
|
||||||
R.drawable.car_off -> getString(R.string.allowTakeoffVehicle)
|
|
||||||
//REPETIDO:R.drawable.ic_history_black_24dp->"Realiza llamada al sacador"
|
|
||||||
//sacador
|
|
||||||
R.drawable.ic_add_black_24dp -> getString(R.string.newCollection)
|
|
||||||
//REPETIDO: R.drawable.car->"Permite coger vehículo"
|
|
||||||
//ubicador:
|
|
||||||
//REPETIDO: R.drawable.ic_add_black_24dp->"Genera colección para sacar"
|
|
||||||
//REPETIDO: ic_autorenew_black_24dp
|
|
||||||
//historico articulo
|
|
||||||
R.drawable.ic_transaction -> getString(R.string.showFilter)
|
|
||||||
R.drawable.alpha_f_circle_outline -> getString(R.string.showFaults)
|
|
||||||
R.drawable.alpha_b_circle_outline -> getString(R.string.showTrash)
|
|
||||||
|
|
||||||
R.drawable.filter_outline -> getString(R.string.filterFlower)
|
|
||||||
|
|
||||||
R.drawable.ic_mode_edit_black_24dp -> getString(R.string.allowChangeShelving)
|
|
||||||
R.drawable.ic_delete_forever_black_24dp -> getString(R.string.deleteAllitems)
|
|
||||||
R.drawable.ic_flash_auto_black_24dp -> getString(R.string.allowAutomaticAddItem)
|
|
||||||
R.drawable.ic_logo_salix -> getString(R.string.accessSalix)
|
|
||||||
R.drawable.ic_eye_ui -> getString(R.string.icViewCollection)
|
|
||||||
R.drawable.ic_collection -> getString(R.string.icViewCollection)
|
|
||||||
R.drawable.ic_ubicator_check -> getString(R.string.checkerUbication)
|
|
||||||
R.drawable.ic_delivery_truck -> getString(R.string.loadRoute)
|
|
||||||
R.drawable.ic_confirm -> getString(R.string.confirmDescription)
|
|
||||||
|
|
||||||
R.drawable.camion -> getString(R.string.openLoadingConsignee)
|
|
||||||
R.drawable.exit -> getString(R.string.exitScreen)
|
|
||||||
R.drawable.ic_image_upload -> getString(R.string.messageUpload)
|
|
||||||
|
|
||||||
R.drawable.expedition_find -> getString(R.string.showLogExpedition)
|
|
||||||
R.drawable.ic_info_refresh -> getString(R.string.udpateRoutes)
|
|
||||||
R.drawable.ic_info_delivery -> getString(R.string.info)
|
|
||||||
R.drawable.ic_filter_inventory -> getString(R.string.filterNoReview)
|
|
||||||
R.drawable.ic_remove_checks -> getString(R.string.resetReviewItems)
|
|
||||||
R.drawable.ic_eye_inventory -> getString(R.string.inventoryShowParking)
|
|
||||||
R.drawable.ic_sort -> getString(R.string.sortRouteSalix)
|
|
||||||
R.drawable.ic_sign_ticket -> getString(R.string.signed)
|
|
||||||
R.drawable.ic_send -> getString(R.string.sendDriverRoute)
|
|
||||||
|
|
||||||
else -> {
|
|
||||||
""
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun hideBackButton(tool: ToolbarFragmentBinding) {
|
|
||||||
tool.backButton.visibility = View.INVISIBLE
|
|
||||||
}
|
|
||||||
|
|
||||||
private fun getDefaults(key: String?, context: Context?): String? {
|
|
||||||
val preferences = PreferenceManager.getDefaultSharedPreferences(context)
|
|
||||||
return preferences.getString(key, null)
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getDataInt(name: String): Int {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
return when (name) {
|
|
||||||
SECTORFK -> prefs.getInt(name, SECTORFKDEFAULT)
|
|
||||||
WAREHOUSEFK -> prefs.getInt(name, WAREHOUSEFKDEFAULT)
|
|
||||||
PRINTERFK -> prefs.getInt(name, 0)
|
|
||||||
USERFK -> prefs.getInt(USERFK, 0)
|
|
||||||
SUPPLIERID -> prefs.getInt(SUPPLIERID, 0)
|
|
||||||
else -> {
|
|
||||||
0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getData(name: String): String {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
return when (name) {
|
|
||||||
TOKEN -> prefs.getString(name, "").toString()
|
|
||||||
ANDROID_ID -> prefs.getString(name, "0").toString()
|
|
||||||
USERFK -> prefs.getString(USERFK, "").toString() //el id
|
|
||||||
USER -> prefs.getString(USER, "").toString()
|
|
||||||
PASSWORD -> prefs.getString(PASSWORD, "").toString()
|
|
||||||
SECTORFK -> prefs.getInt(name, SECTORFKDEFAULT).toString()
|
|
||||||
WAREHOUSEFK -> prefs.getInt(name, WAREHOUSEFKDEFAULT).toString()
|
|
||||||
WAGON -> prefs.getInt(name, 2).toString()
|
|
||||||
TAGSTYPE -> prefs.getString(name, getString(R.string.stickers)).toString()
|
|
||||||
SECTORDESCRIP -> prefs.getString(name, getString(R.string.Sinsector)).toString()
|
|
||||||
BUYER -> prefs.getString(name, "").toString()
|
|
||||||
BUYERID -> prefs.getString(name, "").toString()
|
|
||||||
DATENOVEHICLE -> prefs.getString(name, "0").toString()
|
|
||||||
DEPARTMENTMISTAKE -> prefs.getString(name, "").toString()
|
|
||||||
DEPARTMENTMISTAKEID -> prefs.getInt(name, 0).toString()
|
|
||||||
PRINTERFK -> prefs.getInt(name, 0).toString()
|
|
||||||
PRINTERNAME -> prefs.getString(name, getString(R.string.noprinter)).toString()
|
|
||||||
NUMBEROFWAGONS -> prefs.getInt(name, 1).toString()
|
|
||||||
TRAINFK -> prefs.getString(name, "").toString()
|
|
||||||
TRAINNAME -> prefs.getString(name, "").toString()
|
|
||||||
ITEMPACKING -> prefs.getString(name, "").toString()
|
|
||||||
ITEMPACKINGFK -> prefs.getString(name, "").toString()
|
|
||||||
WORKFORMSELECTED -> prefs.getString(name, "Producción").toString()
|
|
||||||
"SUPPLIERNAME" -> prefs.getString(name, "").toString()
|
|
||||||
"SUPPLIERID" -> prefs.getInt(name, 0).toString()
|
|
||||||
"ENTRYTYPE" -> prefs.getString(name, "").toString()
|
|
||||||
"ENTRYNUMBERIMAGES" -> prefs.getString(name, "0").toString()
|
|
||||||
"ENTRYOBSERVATIONS" -> prefs.getString(name, "").toString()
|
|
||||||
"SERIALNUMBER" -> prefs.getString(name, "").toString()
|
|
||||||
|
|
||||||
"base_url" -> {
|
|
||||||
val preferences = PreferenceManager.getDefaultSharedPreferences(context)
|
|
||||||
preferences.getString(getString(R.string.baseurl), "").toString()
|
|
||||||
}
|
|
||||||
|
|
||||||
"base_urlSalix" -> {
|
|
||||||
val preferences = PreferenceManager.getDefaultSharedPreferences(context)
|
|
||||||
var serverSalix =
|
|
||||||
preferences.getString(getString(R.string.base_urlSalix), "").toString()
|
|
||||||
if (serverSalix.isNullOrEmpty()) {
|
|
||||||
serverSalix = "https://salix.verdnatura.es"
|
|
||||||
}
|
|
||||||
return serverSalix
|
|
||||||
}
|
|
||||||
|
|
||||||
else -> {
|
|
||||||
prefs.getString(name, "").toString()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun removeSector() {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
editor.remove(SECTORFK).commit()
|
|
||||||
editor.remove(SECTORDESCRIP).commit()
|
|
||||||
editor.remove(WAREHOUSEFK).commit()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun setDefaults(key: String?, value: String?, context: Context?) {
|
|
||||||
|
|
||||||
val preferences: SharedPreferences = PreferenceManager.getDefaultSharedPreferences(context)
|
|
||||||
val editor = preferences.edit()
|
|
||||||
editor.putString(key, value)
|
|
||||||
editor.commit()
|
|
||||||
}
|
|
||||||
|
|
||||||
fun removePrinter() {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
editor.remove(PRINTERFK).commit()
|
|
||||||
editor.remove(PRINTERNAME).commit()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveWorkForm(workForm: WorkForms) {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_SERVER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
val gson = Gson()
|
|
||||||
val json = gson.toJson(workForm)
|
|
||||||
editor.putString(workForm.name, json)
|
|
||||||
editor.commit()
|
|
||||||
|
|
||||||
saveData("base_url", workForm.urlSilex)
|
|
||||||
saveData("base_urlSalix", workForm.urlSalix)
|
|
||||||
}
|
|
||||||
|
|
||||||
fun deleteWorkForm(nameWorkForm: String) {
|
|
||||||
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_SERVER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
|
|
||||||
if (nameWorkForm == "all") {
|
|
||||||
editor.clear().apply()
|
|
||||||
} else {
|
|
||||||
editor.remove(nameWorkForm).commit()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getWorkForm(): List<WorkForms> {
|
|
||||||
val listForms: ArrayList<WorkForms> = ArrayList()
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_SERVER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
|
|
||||||
val keys: Map<String, *> = prefs.all
|
|
||||||
for (Map in keys) {
|
|
||||||
|
|
||||||
|
|
||||||
val json2 = JSONObject(Map.value.toString())
|
|
||||||
|
|
||||||
listForms.add(
|
|
||||||
WorkForms(
|
|
||||||
Map.key,
|
|
||||||
json2.get("urlSilex").toString(),
|
|
||||||
json2.get("urlSalix").toString(),
|
|
||||||
json2.get("isShowDelete").toString().toBoolean(),
|
|
||||||
json2.get("created") as Long
|
|
||||||
|
|
||||||
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
editor.commit()
|
|
||||||
if (listForms.isEmpty()) {
|
|
||||||
createWorksDefault()
|
|
||||||
}
|
|
||||||
|
|
||||||
return listForms.sortedBy { it.created }
|
|
||||||
}
|
|
||||||
|
|
||||||
fun createWorksDefault() {
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"Producción",
|
|
||||||
"https://app.verdnatura.es",
|
|
||||||
"https://salix.verdnatura.es"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"Test",
|
|
||||||
"https://test-app.verdnatura.es",
|
|
||||||
urlSalix = "https://test-salix.verdnatura.es"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
val working_in_test = true
|
|
||||||
if (working_in_test) {
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"TestLocalhost",
|
|
||||||
"http://10.1.4.42:9000",
|
|
||||||
urlSalix = "https://test-salix.verdnatura.es"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"TestHome",
|
|
||||||
"http://192.168.1.132:9000",
|
|
||||||
urlSalix = "https://test-salix.verdnatura.es"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"TestLOCAL",
|
|
||||||
"http://10.1.4.42:9000",
|
|
||||||
urlSalix = "http://10.1.4.42:3000"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"TestLOCALHOME",
|
|
||||||
"http://192.168.1.132:9000",
|
|
||||||
urlSalix = "http://192.168.1.132:3000"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
deleteWorkForm("all")
|
|
||||||
}
|
|
||||||
saveWorkForm(
|
|
||||||
WorkForms(
|
|
||||||
"Añadir...",
|
|
||||||
"",
|
|
||||||
"",
|
|
||||||
created = Calendar.getInstance().timeInMillis + Calendar.getInstance().timeInMillis
|
|
||||||
|
|
||||||
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveData(name: String, value: Any) {
|
|
||||||
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
|
|
||||||
when (name) {
|
|
||||||
|
|
||||||
"base_url" -> {
|
|
||||||
val preferences = PreferenceManager.getDefaultSharedPreferences(context)
|
|
||||||
val editorPref = preferences.edit()
|
|
||||||
editorPref.putString("base_url", value.toString())
|
|
||||||
editorPref.commit()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
"base_urlSalix" -> {
|
|
||||||
val preferences = PreferenceManager.getDefaultSharedPreferences(context)
|
|
||||||
val editorPref = preferences.edit()
|
|
||||||
editorPref.putString("base_urlSalix", value.toString())
|
|
||||||
editorPref.commit()
|
|
||||||
}
|
|
||||||
|
|
||||||
DEPARTMENTMISTAKEID -> {
|
|
||||||
editor.putInt(name, value as Int)
|
|
||||||
}
|
|
||||||
|
|
||||||
"SUPPLIERID" -> {
|
|
||||||
editor.putString(name, value.toString())
|
|
||||||
}
|
|
||||||
|
|
||||||
else -> {
|
|
||||||
editor.putString(name, value.toString())
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
editor.commit()
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveDataInt(name: String, value: Int) {
|
|
||||||
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
|
|
||||||
when (name) {
|
|
||||||
name -> editor.putInt(name, value)
|
|
||||||
}
|
|
||||||
editor.apply()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveDataOperator(operator: OperatorSalix) {
|
|
||||||
if (operator.sector == null) {
|
|
||||||
removeSector()
|
|
||||||
} else {
|
|
||||||
saveDataInt(SECTORFK, operator.sector.id)
|
|
||||||
saveData(SECTORDESCRIP, operator.sector.description)
|
|
||||||
saveDataInt(WAREHOUSEFK, operator.sector.warehouseFk)
|
|
||||||
}
|
|
||||||
if (operator.printer == null) {
|
|
||||||
removePrinter()
|
|
||||||
} else {
|
|
||||||
saveDataInt(PRINTERFK, operator.printer.id)
|
|
||||||
saveData(PRINTERNAME, operator.printer.name)
|
|
||||||
}
|
|
||||||
if (operator.train != null) {
|
|
||||||
saveData(TRAINNAME, operator.train.name)
|
|
||||||
}
|
|
||||||
saveDataInt(NUMBEROFWAGONS, operator.numberOfWagons)
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
fun saveDataLong(name: String, value: Long) {
|
|
||||||
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
|
|
||||||
when (name) {
|
|
||||||
name -> editor.putLong(name, value)
|
|
||||||
}
|
|
||||||
editor.apply()
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveWorkingForms(list: ArrayList<String>) {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
editor.putString("workingForms", list.toString())
|
|
||||||
editor.apply()
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getWorkingForms(): Array<String> {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val jsonStr: String? = prefs.getString("workingForms", null)
|
|
||||||
val gson = Gson()
|
|
||||||
val lista: Array<String> = gson.fromJson(jsonStr, Array<String>::class.java)
|
|
||||||
return lista
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveBuyer(buyernickname: String) {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
editor.putString(BUYER, buyernickname)
|
|
||||||
editor.apply()
|
|
||||||
}
|
|
||||||
|
|
||||||
fun saveBuyerId(buyerid: String) {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val editor = prefs.edit()
|
|
||||||
editor.putString(BUYERID, buyerid)
|
|
||||||
editor.apply()
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getIMEI(): String {
|
|
||||||
val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER, 0)
|
|
||||||
val imei = prefs.getString("IMEI", "0")
|
|
||||||
return imei.toString()
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
fun getMessageFromJSON(json: String): String {
|
|
||||||
val gson = Gson()
|
|
||||||
var message = ""
|
|
||||||
// val mapType = object : TypeToken<Map<String, Any>>() {}.type
|
|
||||||
|
|
||||||
val tutorialMap: Map<String, Any> =
|
|
||||||
gson.fromJson(json, object : TypeToken<Map<String, Any>>() {}.type)
|
|
||||||
tutorialMap.forEach {
|
|
||||||
if (it.key.equals("Message")) {
|
|
||||||
message = it.value.toString()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return message
|
|
||||||
}
|
|
||||||
|
|
||||||
fun getListFromJSON(json: String): List<String> {
|
|
||||||
val gson = Gson()
|
|
||||||
val list = mutableListOf<String>()
|
|
||||||
|
|
||||||
// val mapType = object : TypeToken<Map<String, Any>>() {}.type
|
|
||||||
|
|
||||||
val tutorialMap: Map<String, Any> =
|
|
||||||
gson.fromJson(json, object : TypeToken<Map<String, Any>>() {}.type)
|
|
||||||
tutorialMap.forEach {
|
|
||||||
|
|
||||||
list.add(it.key + ":" + it.value)
|
|
||||||
|
|
||||||
}
|
|
||||||
return list
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fun databaseNew(myContext: Context): DeliveryDatabase {
|
|
||||||
|
|
||||||
val db = Room.databaseBuilder(
|
|
||||||
myContext,
|
|
||||||
DeliveryDatabase::class.java, "expediciones.db"
|
|
||||||
).build()
|
|
||||||
return db
|
|
||||||
}
|
|
|
@ -30,16 +30,18 @@ interface OnOptionsSelectedListener {
|
||||||
fun onOptionsItemSelected(item: Drawable)
|
fun onOptionsItemSelected(item: Drawable)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
interface OnPasillerosItemClickListener {
|
interface OnPasillerosItemClickListener {
|
||||||
fun onPasillerosItemClickListener(item: PasillerosItemVO, entryPoint: String,param:Any? =null)
|
fun onPasillerosItemClickListener(
|
||||||
|
item: PasillerosItemVO,
|
||||||
|
entryPoint: String,
|
||||||
|
param: Any? = null
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface onMistakeWorkerClickListener {
|
interface onMistakeWorkerClickListener {
|
||||||
fun onMistakeWorkerClickListener(item: WorkerFromMistake)
|
fun onMistakeWorkerClickListener(item: WorkerFromMistake)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
interface hideBottomNavigation {
|
interface hideBottomNavigation {
|
||||||
fun hideBottomNavigation(entryPoint: String)
|
fun hideBottomNavigation(entryPoint: String)
|
||||||
}
|
}
|
||||||
|
@ -48,7 +50,6 @@ interface OnAjustesItemClickListener {
|
||||||
fun onAjustesItemClickListener(item: AjustesItemVO)
|
fun onAjustesItemClickListener(item: AjustesItemVO)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
interface OnItemCardRowClickListener {
|
interface OnItemCardRowClickListener {
|
||||||
fun onItemCardRowClickListener(item: ItemCardRowVO)
|
fun onItemCardRowClickListener(item: ItemCardRowVO)
|
||||||
}
|
}
|
||||||
|
@ -175,17 +176,19 @@ interface OnQuantityClickSaleListener {
|
||||||
interface onPackingClickListener {
|
interface onPackingClickListener {
|
||||||
fun onPackingClick(sale: SaleVO)
|
fun onPackingClick(sale: SaleVO)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface OnPackingClickSaleListener {
|
interface OnPackingClickSaleListener {
|
||||||
fun onPackingClick(sale: Sale)
|
fun onPackingClick(sale: Sale)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
interface OnSaleClickListener {
|
interface OnSaleClickListener {
|
||||||
fun onSaleClick(sale: SaleVO)
|
fun onSaleClick(sale: SaleVO)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface OnSaleClickSaleListener {
|
interface OnSaleClickSaleListener {
|
||||||
fun onSaleClick(sale: Sale)
|
fun onSaleClick(sale: Sale)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface OnReubicationClickListener {
|
interface OnReubicationClickListener {
|
||||||
fun onReubicationClick(reubication: Reubication)
|
fun onReubicationClick(reubication: Reubication)
|
||||||
}
|
}
|
||||||
|
@ -197,6 +200,7 @@ interface OnMistakeClickListener {
|
||||||
interface OnTicketClickListener {
|
interface OnTicketClickListener {
|
||||||
fun onTicketClickListener(sale: SaleVO)
|
fun onTicketClickListener(sale: SaleVO)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface OnTicketClickSaleListener {
|
interface OnTicketClickSaleListener {
|
||||||
fun onTicketClickListener(sale: Sale)
|
fun onTicketClickListener(sale: Sale)
|
||||||
}
|
}
|
||||||
|
@ -216,10 +220,19 @@ interface onVehicleSelected {
|
||||||
interface OnClickDynamic {
|
interface OnClickDynamic {
|
||||||
fun onClickDynamic(addressFK: Int)
|
fun onClickDynamic(addressFK: Int)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface InteceptorListener {
|
interface InteceptorListener {
|
||||||
fun onInterceptionResult(visibility: Int)
|
fun onInterceptionResult(visibility: Int)
|
||||||
}
|
}
|
||||||
|
|
||||||
interface MainActivityListener {
|
interface MainActivityListener {
|
||||||
fun onApplicationEventAnimation(visibility: Int)
|
fun onApplicationEventAnimation(visibility: Int)
|
||||||
|
}
|
||||||
|
|
||||||
|
interface LoginListener {
|
||||||
|
fun onApplicationEventAnimation(visibility: Int)
|
||||||
|
}
|
||||||
|
|
||||||
|
interface SignListener {
|
||||||
|
fun onApplicationEventAnimation(visibility: Int)
|
||||||
}
|
}
|
|
@ -12,13 +12,12 @@ import android.os.Bundle
|
||||||
import android.os.Parcel
|
import android.os.Parcel
|
||||||
import android.os.ParcelFileDescriptor
|
import android.os.ParcelFileDescriptor
|
||||||
import android.os.ResultReceiver
|
import android.os.ResultReceiver
|
||||||
import android.util.Log
|
|
||||||
import android.view.View
|
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.lifecycle.Observer
|
import androidx.lifecycle.Observer
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
import es.verdnatura.databinding.FragmentTestingPrintBinding
|
import es.verdnatura.databinding.FragmentTestingPrintBinding
|
||||||
|
import es.verdnatura.domain.toast
|
||||||
import es.verdnatura.presentation.base.BaseFragment
|
import es.verdnatura.presentation.base.BaseFragment
|
||||||
import es.verdnatura.presentation.view.component.CustomDialog
|
import es.verdnatura.presentation.view.component.CustomDialog
|
||||||
import es.verdnatura.presentation.view.feature.qr.QrFragmentViewModel
|
import es.verdnatura.presentation.view.feature.qr.QrFragmentViewModel
|
||||||
|
@ -46,12 +45,9 @@ class testPrint(
|
||||||
|
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
|
|
||||||
setToolbar()
|
setToolbar()
|
||||||
setEvents()
|
setEvents()
|
||||||
|
|
||||||
val i = Intent()
|
val i = Intent()
|
||||||
i.setClassName("verdnatura.es.repartoverdnatura", "verdnatura.es.repartoverdnatura.MainActivity")
|
i.setClassName("verdnatura.es.repartoverdnatura", "verdnatura.es.repartoverdnatura.MainActivity")
|
||||||
i.putExtra("token",getData(TOKEN))
|
i.putExtra("token",getData(TOKEN))
|
||||||
|
@ -110,10 +106,6 @@ class testPrint(
|
||||||
|
|
||||||
goBack = false
|
goBack = false
|
||||||
if (!binding.scanInput.text.isNullOrEmpty()) {
|
if (!binding.scanInput.text.isNullOrEmpty()) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
/* viewModel.qr_getCall(
|
|
||||||
binding.scanInput.text.toString()
|
|
||||||
)*/
|
|
||||||
itemscaned = binding.scanInput.text.toString()
|
itemscaned = binding.scanInput.text.toString()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -313,9 +305,9 @@ class testPrint(
|
||||||
// Convert template ZPL string to a UTF-8 encoded byte array, which will be sent as an extra with the intent
|
// Convert template ZPL string to a UTF-8 encoded byte array, which will be sent as an extra with the intent
|
||||||
//templateBytes = templateData.getBytes("UTF-8");
|
//templateBytes = templateData.getBytes("UTF-8");
|
||||||
templateBytes = templateData.toByteArray()
|
templateBytes = templateData.toByteArray()
|
||||||
} catch (e: UnsupportedEncodingException) {
|
} catch (ex: UnsupportedEncodingException) {
|
||||||
// Handle exception
|
// Handle exception
|
||||||
Log.d("VERDNATURA::","Error"+e.message)
|
ex.toast(requireContext())
|
||||||
}
|
}
|
||||||
val intent = Intent()
|
val intent = Intent()
|
||||||
intent.component = ComponentName(
|
intent.component = ComponentName(
|
||||||
|
@ -402,7 +394,6 @@ class testPrint(
|
||||||
"com.zebra.printconnect",
|
"com.zebra.printconnect",
|
||||||
"com.zebra.printconnect.print.GetPrinterStatusService"
|
"com.zebra.printconnect.print.GetPrinterStatusService"
|
||||||
)
|
)
|
||||||
Log.d("VERDNATURA::","Entrando en prinStatus")
|
|
||||||
intent.putExtra(
|
intent.putExtra(
|
||||||
"com.zebra.printconnect.PrintService.RESULT_RECEIVER",
|
"com.zebra.printconnect.PrintService.RESULT_RECEIVER",
|
||||||
buildIPCSafeReceiver(object : ResultReceiver(null) {
|
buildIPCSafeReceiver(object : ResultReceiver(null) {
|
||||||
|
@ -411,7 +402,6 @@ class testPrint(
|
||||||
super.onReceiveResult(resultCode, resultData)
|
super.onReceiveResult(resultCode, resultData)
|
||||||
|
|
||||||
if (resultCode == 0) {
|
if (resultCode == 0) {
|
||||||
Log.d("VERDNATURA::","Result 0")
|
|
||||||
// Result code 0 indicates success
|
// Result code 0 indicates success
|
||||||
val printerStatusMap =
|
val printerStatusMap =
|
||||||
resultData!!.getSerializable("PrinterStatusMap") as HashMap<String, String>?
|
resultData!!.getSerializable("PrinterStatusMap") as HashMap<String, String>?
|
||||||
|
@ -419,7 +409,6 @@ class testPrint(
|
||||||
} else {
|
} else {
|
||||||
// Handle unsuccessful print
|
// Handle unsuccessful print
|
||||||
// Error message (null on successful print)
|
// Error message (null on successful print)
|
||||||
Log.d("VERDNATURA::","Result <>0")
|
|
||||||
val errorMessage =
|
val errorMessage =
|
||||||
resultData?.getString("com.zebra.printconnect.PrintService.ERROR_MESSAGE")
|
resultData?.getString("com.zebra.printconnect.PrintService.ERROR_MESSAGE")
|
||||||
Toast.makeText(context, errorMessage, Toast.LENGTH_LONG).show()
|
Toast.makeText(context, errorMessage, Toast.LENGTH_LONG).show()
|
||||||
|
@ -477,7 +466,6 @@ class testPrint(
|
||||||
|
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
qrresponse.observe(viewLifecycleOwner, Observer {
|
qrresponse.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
|
|
||||||
ma.messageWithSound(it.errorMessage + " " + itemscaned, true, false)
|
ma.messageWithSound(it.errorMessage + " " + itemscaned, true, false)
|
||||||
|
|
|
@ -7,7 +7,6 @@ import android.content.Context.CLIPBOARD_SERVICE
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import android.view.View.VISIBLE
|
|
||||||
import androidx.appcompat.widget.TooltipCompat.setTooltipText
|
import androidx.appcompat.widget.TooltipCompat.setTooltipText
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
import es.verdnatura.MobileApplication
|
import es.verdnatura.MobileApplication
|
||||||
|
@ -64,8 +63,8 @@ class AjustesFragment :
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
binding.mainToolbar.toolbarTitle.text = getString(R.string.settings)
|
binding.mainToolbar.toolbarTitle.text = getString(R.string.settings)
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
hideBackButton(binding.mainToolbar)
|
hideBackButton(binding.mainToolbar)
|
||||||
|
|
||||||
viewModel.worker_isF11Allowed()
|
viewModel.worker_isF11Allowed()
|
||||||
|
|
||||||
binding.userText.text = mobileApplication.userName
|
binding.userText.text = mobileApplication.userName
|
||||||
|
@ -78,11 +77,9 @@ class AjustesFragment :
|
||||||
|
|
||||||
// Tarea 4815
|
// Tarea 4815
|
||||||
binding.serialNumber.text = mobileApplication.serialNumber
|
binding.serialNumber.text = mobileApplication.serialNumber
|
||||||
|
// binding.txtserver.setText(getData(getString(R.string.baseurl)))
|
||||||
binding.txtserver.setText(getData(getString(R.string.baseurl)))
|
|
||||||
super.init()
|
|
||||||
|
|
||||||
setEvents()
|
setEvents()
|
||||||
|
super.init()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -116,7 +113,6 @@ class AjustesFragment :
|
||||||
if (item.action) {
|
if (item.action) {
|
||||||
|
|
||||||
if (item.id == 0) {
|
if (item.id == 0) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.getSectorsSalix()
|
viewModel.getSectorsSalix()
|
||||||
} else if (item.id == 5) {
|
} else if (item.id == 5) {
|
||||||
requireActivity().onBackPressed()
|
requireActivity().onBackPressed()
|
||||||
|
@ -149,7 +145,6 @@ class AjustesFragment :
|
||||||
)
|
)
|
||||||
|
|
||||||
} else if (item.id == 6) {
|
} else if (item.id == 6) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.train_get()
|
viewModel.train_get()
|
||||||
} else if (item.id == 7) {
|
} else if (item.id == 7) {
|
||||||
viewModel.getItemPackingTypeSalix()
|
viewModel.getItemPackingTypeSalix()
|
||||||
|
@ -160,7 +155,6 @@ class AjustesFragment :
|
||||||
})
|
})
|
||||||
|
|
||||||
operatorGetItemPackingType.observe(viewLifecycleOwner) {
|
operatorGetItemPackingType.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
ma.messageWithSound(it.errorMessage, it.isError, true)
|
ma.messageWithSound(it.errorMessage, it.isError, true)
|
||||||
|
@ -173,7 +167,6 @@ class AjustesFragment :
|
||||||
|
|
||||||
|
|
||||||
workerAllowedResponse.observe(viewLifecycleOwner) {
|
workerAllowedResponse.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
ma.messageWithSound(it.errorMessage, it.isError, true)
|
ma.messageWithSound(it.errorMessage, it.isError, true)
|
||||||
|
@ -198,7 +191,6 @@ class AjustesFragment :
|
||||||
}
|
}
|
||||||
|
|
||||||
actionUpdate.observe(viewLifecycleOwner) {
|
actionUpdate.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
ma.messageWithSound(
|
ma.messageWithSound(
|
||||||
if (it.isError) it.errorMessage else {
|
if (it.isError) it.errorMessage else {
|
||||||
|
@ -206,7 +198,6 @@ class AjustesFragment :
|
||||||
}, it.isError, false
|
}, it.isError, false
|
||||||
)
|
)
|
||||||
|
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
messagePrinter =
|
messagePrinter =
|
||||||
getString(R.string.Selecccionaimpresoara) + "\n" + getString(R.string.printerRemoved)
|
getString(R.string.Selecccionaimpresoara) + "\n" + getString(R.string.printerRemoved)
|
||||||
viewModel.printer_get()
|
viewModel.printer_get()
|
||||||
|
@ -214,15 +205,13 @@ class AjustesFragment :
|
||||||
}
|
}
|
||||||
loadUpdatePacking.observe(viewLifecycleOwner) { event ->
|
loadUpdatePacking.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
actionUpdatePacking.observe(viewLifecycleOwner) {
|
actionUpdatePacking.observe(viewLifecycleOwner) {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
ma.messageWithSound(
|
ma.messageWithSound(
|
||||||
if (it.isError) it.errorMessage else {
|
if (it.isError) it.errorMessage else {
|
||||||
getString(R.string.itemUpdated)
|
getString(R.string.itemUpdated)
|
||||||
|
@ -230,20 +219,12 @@ class AjustesFragment :
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
isLoadingProgress.observe(viewLifecycleOwner) {
|
|
||||||
binding.splashProgress.visibility = it
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
binding.ajustessItems.adapter = ajustesAdapter
|
binding.ajustessItems.adapter = ajustesAdapter
|
||||||
binding.ajustessItems.layoutManager =
|
binding.ajustessItems.layoutManager =
|
||||||
LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
||||||
|
|
||||||
loadSectorList.observe(viewLifecycleOwner) { event ->
|
loadSectorList.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = View.INVISIBLE
|
|
||||||
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
||||||
customDialog.setTitle(getString(R.string.error))
|
customDialog.setTitle(getString(R.string.error))
|
||||||
.setDescription(it.list.get(0).errorMessage)
|
.setDescription(it.list.get(0).errorMessage)
|
||||||
|
@ -276,7 +257,6 @@ class AjustesFragment :
|
||||||
}
|
}
|
||||||
loadItemPackingList.observe(viewLifecycleOwner) { event ->
|
loadItemPackingList.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = View.INVISIBLE
|
|
||||||
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
||||||
customDialog.setTitle(getString(R.string.error))
|
customDialog.setTitle(getString(R.string.error))
|
||||||
.setDescription(it.list.get(0).errorMessage)
|
.setDescription(it.list.get(0).errorMessage)
|
||||||
|
@ -307,7 +287,6 @@ class AjustesFragment :
|
||||||
}
|
}
|
||||||
loadPrintersList.observe(viewLifecycleOwner) { event ->
|
loadPrintersList.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = View.INVISIBLE
|
|
||||||
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
||||||
customDialog.setTitle(getString(R.string.error))
|
customDialog.setTitle(getString(R.string.error))
|
||||||
.setDescription(it.list.get(0).errorMessage)
|
.setDescription(it.list.get(0).errorMessage)
|
||||||
|
@ -338,7 +317,7 @@ class AjustesFragment :
|
||||||
}
|
}
|
||||||
loadTrainList.observe(viewLifecycleOwner) { event ->
|
loadTrainList.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
||||||
customDialog.setTitle(getString(R.string.error))
|
customDialog.setTitle(getString(R.string.error))
|
||||||
.setDescription(it.list.get(0).errorMessage)
|
.setDescription(it.list.get(0).errorMessage)
|
||||||
|
@ -385,6 +364,7 @@ class AjustesFragment :
|
||||||
actionIsAllowed = actionIsAllowed
|
actionIsAllowed = actionIsAllowed
|
||||||
|
|
||||||
)
|
)
|
||||||
|
binding.splashProgress.visibility = View.GONE
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun showDialogPrinters(array: Array<String>) {
|
private fun showDialogPrinters(array: Array<String>) {
|
||||||
|
@ -436,7 +416,6 @@ class AjustesFragment :
|
||||||
editor.apply()
|
editor.apply()
|
||||||
|
|
||||||
viewModel.ajustesitem[3].selected = it.name
|
viewModel.ajustesitem[3].selected = it.name
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.operatorUpdateTrain(
|
viewModel.operatorUpdateTrain(
|
||||||
workerId = mobileApplication.userId!!,
|
workerId = mobileApplication.userId!!,
|
||||||
trainFk = it.id!!
|
trainFk = it.id!!
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
package es.verdnatura.presentation.view.feature.ajustes.fragment
|
package es.verdnatura.presentation.view.feature.ajustes.fragment
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.view.View.GONE
|
|
||||||
import android.view.View.VISIBLE
|
|
||||||
import androidx.lifecycle.LiveData
|
import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import androidx.lifecycle.Transformations
|
import androidx.lifecycle.Transformations
|
||||||
|
@ -10,7 +8,6 @@ import com.google.gson.JsonObject
|
||||||
import es.verdnatura.MobileApplication
|
import es.verdnatura.MobileApplication
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
import es.verdnatura.presentation.base.nameofFunction
|
||||||
|
@ -89,6 +86,7 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
val loadTrainList = Transformations.map(_trainList) { Event(it) }
|
val loadTrainList = Transformations.map(_trainList) { Event(it) }
|
||||||
val loadUpdatePacking = Transformations.map(_actionUpdatePackingTicket) { Event(it) }
|
val loadUpdatePacking = Transformations.map(_actionUpdatePackingTicket) { Event(it) }
|
||||||
|
|
||||||
|
/*
|
||||||
private val _isLoadingProgress by lazy { MutableLiveData<Int>() }
|
private val _isLoadingProgress by lazy { MutableLiveData<Int>() }
|
||||||
val isLoadingProgress: LiveData<Int>
|
val isLoadingProgress: LiveData<Int>
|
||||||
get() = _isLoadingProgress
|
get() = _isLoadingProgress
|
||||||
|
@ -96,6 +94,7 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun ProgressLoading(visibility: Int) {
|
fun ProgressLoading(visibility: Int) {
|
||||||
_isLoadingProgress.value = visibility
|
_isLoadingProgress.value = visibility
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
fun inititializeDefaultAjusts(
|
fun inititializeDefaultAjusts(
|
||||||
sectorDescrip: String,
|
sectorDescrip: String,
|
||||||
|
@ -233,7 +232,7 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun getSectorsSalix() {
|
fun getSectorsSalix() {
|
||||||
salix.getSectorsSalix().enqueue(object : SilexCallback<List<SectorItemVO>>(context) {
|
salix.getSectorsSalix().enqueue(object : SalixCallback<List<SectorItemVO>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
||||||
val listError: ArrayList<SectorItemVO> = ArrayList()
|
val listError: ArrayList<SectorItemVO> = ArrayList()
|
||||||
|
@ -263,7 +262,7 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun printer_get() {
|
fun printer_get() {
|
||||||
//Tarea 6276
|
//Tarea 6276
|
||||||
//salix.getprinters().enqueue(object : SalixCallback<List<Printers>>(context) {
|
//salix.getprinters().enqueue(object : SalixCallback<List<Printers>>(context) {
|
||||||
silex.printer_get().enqueue(object : SilexCallback<List<Printers>>(context) {
|
silex.printer_get().enqueue(object : SalixCallback<List<Printers>>(context) {
|
||||||
override fun onSuccess(response: Response<List<Printers>>) {
|
override fun onSuccess(response: Response<List<Printers>>) {
|
||||||
if (response.body() != null) {
|
if (response.body() != null) {
|
||||||
_printerList.value = response.body()?.let { PrintersList(it) }
|
_printerList.value = response.body()?.let { PrintersList(it) }
|
||||||
|
@ -290,7 +289,7 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun train_get() {
|
fun train_get() {
|
||||||
salix.getTrain().enqueue(object : SilexCallback<List<Train>>(context) {
|
salix.getTrain().enqueue(object : SalixCallback<List<Train>>(context) {
|
||||||
override fun onSuccess(response: Response<List<Train>>) {
|
override fun onSuccess(response: Response<List<Train>>) {
|
||||||
_trainList.value = response.body()?.let { TrainList(it) }
|
_trainList.value = response.body()?.let { TrainList(it) }
|
||||||
}
|
}
|
||||||
|
@ -307,7 +306,7 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun operator_updateItemPackingType(itemPackingTypeFk: String) {
|
fun operator_updateItemPackingType(itemPackingTypeFk: String) {
|
||||||
|
|
||||||
silex.operator_updateItemPackingType(itemPackingTypeFk)
|
silex.operator_updateItemPackingType(itemPackingTypeFk)
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
||||||
_actionUpdatePacking.value = ResponseItemVO(
|
_actionUpdatePacking.value = ResponseItemVO(
|
||||||
|
@ -330,83 +329,6 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/* fun operator_getNumberOfWagons() {
|
|
||||||
|
|
||||||
silex.operator_getNumberOfWagons()
|
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
|
|
||||||
_operatorGetNumberOfWagons.value = ResponseItemNumber(
|
|
||||||
null,
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
|
||||||
if (response.body() != null)
|
|
||||||
_operatorGetNumberOfWagons.value =
|
|
||||||
ResponseItemNumber(
|
|
||||||
if (response.body() is Number) {
|
|
||||||
(response.body() as Double).roundToInt()
|
|
||||||
} else {
|
|
||||||
0
|
|
||||||
}, isError = false
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
/* fun operator_getTrain() {
|
|
||||||
|
|
||||||
silex.operator_getTrain()
|
|
||||||
.enqueue(object : SilexCallback<String?>(context) {
|
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_operatorGetTrainResponse.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<String?>) {
|
|
||||||
_operatorGetTrainResponse.value =
|
|
||||||
ResponseItemVO(
|
|
||||||
if (response.body().toString() == "false") "" else {
|
|
||||||
response.body().toString()
|
|
||||||
}, false
|
|
||||||
)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}*/
|
|
||||||
|
|
||||||
/* fun operator_getItemPackingType() {
|
|
||||||
|
|
||||||
silex.operator_getItemPackingType()
|
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_operatorGetItemPackingType.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
|
||||||
|
|
||||||
_operatorGetItemPackingType.value =
|
|
||||||
ResponseItemVO(
|
|
||||||
if (response.body().toString() == "false") "" else {
|
|
||||||
response.body().toString()
|
|
||||||
}, false
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}*/
|
|
||||||
|
|
||||||
fun worker_isF11Allowed() {
|
fun worker_isF11Allowed() {
|
||||||
salix.worker_isF11Allowed("""{"where":{"id":${(context as MobileApplication).userId}},"fields":{"isF11Allowed":true}}""")
|
salix.worker_isF11Allowed("""{"where":{"id":${(context as MobileApplication).userId}},"fields":{"isF11Allowed":true}}""")
|
||||||
.enqueue(object : SalixCallback<JsonObject>(context) {
|
.enqueue(object : SalixCallback<JsonObject>(context) {
|
||||||
|
@ -417,22 +339,13 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_workerAllowedResponse.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun worker_updateOperatorSalix(entity: String, workerFk: Int, sectorFk: Int?, labelerFk: Int?) {
|
fun worker_updateOperatorSalix(entity: String, workerFk: Int, sectorFk: Int?, labelerFk: Int?) {
|
||||||
ProgressLoading(VISIBLE)
|
|
||||||
salix.update_operator(id = workerFk, Operator(sectorFk, labelerFk))
|
salix.update_operator(id = workerFk, Operator(sectorFk, labelerFk))
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
ProgressLoading(GONE)
|
|
||||||
_actionUpdate.value = ResponseItemVO(
|
_actionUpdate.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
|
@ -441,7 +354,6 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
override fun onSuccess(response: Response<Unit>) {
|
||||||
ProgressLoading(GONE)
|
|
||||||
if (entity == "sector") {
|
if (entity == "sector") {
|
||||||
_actionUpdate.value = ResponseItemVO(
|
_actionUpdate.value = ResponseItemVO(
|
||||||
response = response.message(),
|
response = response.message(),
|
||||||
|
@ -458,16 +370,14 @@ class AjustesViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun operatorUpdateTrain(workerId: Int, trainFk: Int) {
|
fun operatorUpdateTrain(workerId: Int, trainFk: Int) {
|
||||||
ProgressLoading(VISIBLE)
|
|
||||||
salix.update_operator(id = workerId, params = hashMapOf("trainFk" to trainFk))
|
salix.update_operator(id = workerId, params = hashMapOf("trainFk" to trainFk))
|
||||||
.enqueue(object : SalixCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
override fun onSuccess(response: Response<Unit>) {
|
||||||
ProgressLoading(GONE)
|
|
||||||
super.onSuccess(response)
|
super.onSuccess(response)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
ProgressLoading(GONE)
|
|
||||||
throw t
|
throw t
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -240,7 +240,6 @@ class ItemCardFragment(
|
||||||
binding.splashProgress.visibility = GONE
|
binding.splashProgress.visibility = GONE
|
||||||
getItemCard(itemInfoG!!.id.toString())
|
getItemCard(itemInfoG!!.id.toString())
|
||||||
|
|
||||||
|
|
||||||
})
|
})
|
||||||
addressLosesList.observe(viewLifecycleOwner, Observer {
|
addressLosesList.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = GONE
|
binding.splashProgress.visibility = GONE
|
||||||
|
@ -372,7 +371,6 @@ class ItemCardFragment(
|
||||||
action = "updatePacking"
|
action = "updatePacking"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
//sergio: quitar de back cuando ya tengan la app actualizada todos
|
|
||||||
listItemsRow.add(
|
listItemsRow.add(
|
||||||
ItemCardRowVO(
|
ItemCardRowVO(
|
||||||
title = getString(R.string.stems),
|
title = getString(R.string.stems),
|
||||||
|
@ -560,63 +558,63 @@ class ItemCardFragment(
|
||||||
private fun prepareItemStockUpdate2(itemB: ItemCardRowVO, value: Int) {
|
private fun prepareItemStockUpdate2(itemB: ItemCardRowVO, value: Int) {
|
||||||
|
|
||||||
//Tarea 5652 , quitar código cuando está asignada tarea
|
//Tarea 5652 , quitar código cuando está asignada tarea
|
||||||
val test = true
|
/* val test = true
|
||||||
if (test) {
|
if (test) {*/
|
||||||
// binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.getAddress()
|
|
||||||
quantityToDiscard = value
|
|
||||||
|
|
||||||
} else {
|
viewModel.getAddress()
|
||||||
try {
|
quantityToDiscard = value
|
||||||
|
|
||||||
if (itemB.action == "itemStockUpdateRemove") {
|
/* } else {
|
||||||
|
try {
|
||||||
|
|
||||||
customDialogTwo.setTitle(itemB.title!!)
|
if (itemB.action == "itemStockUpdateRemove") {
|
||||||
.setDescription(getString(R.string.deleteStock))
|
|
||||||
.setOkButton(getString(R.string.fault)) {
|
|
||||||
viewModel.itemTrash(
|
|
||||||
itemFk = itemInfoG!!.id,
|
|
||||||
warehouseFk = warehouseFk!!,
|
|
||||||
newValue = value,
|
|
||||||
isTrash = false
|
|
||||||
|
|
||||||
)
|
customDialogTwo.setTitle(itemB.title!!)
|
||||||
showProgress()
|
.setDescription(getString(R.string.deleteStock))
|
||||||
customDialogTwo.dismiss()
|
.setOkButton(getString(R.string.fault)) {
|
||||||
|
viewModel.itemTrash(
|
||||||
|
itemFk = itemInfoG!!.id,
|
||||||
|
warehouseFk = warehouseFk!!,
|
||||||
|
newValue = value,
|
||||||
|
isTrash = false
|
||||||
|
|
||||||
}.setOkButtonTwo(getString(R.string.trash)) {
|
)
|
||||||
viewModel.itemTrash(
|
showProgress()
|
||||||
itemFk = itemInfoG!!.id,
|
customDialogTwo.dismiss()
|
||||||
warehouseFk = warehouseFk!!,
|
|
||||||
newValue = value,
|
|
||||||
isTrash = true
|
|
||||||
)
|
|
||||||
|
|
||||||
showProgress()
|
}.setOkButtonTwo(getString(R.string.trash)) {
|
||||||
customDialogTwo.dismiss()
|
viewModel.itemTrash(
|
||||||
|
itemFk = itemInfoG!!.id,
|
||||||
|
warehouseFk = warehouseFk!!,
|
||||||
|
newValue = value,
|
||||||
|
isTrash = true
|
||||||
|
)
|
||||||
|
|
||||||
}.setKoButton(getString(R.string.cancel)) {
|
showProgress()
|
||||||
|
customDialogTwo.dismiss()
|
||||||
|
|
||||||
customDialogTwo.dismiss()
|
}.setKoButton(getString(R.string.cancel)) {
|
||||||
}.show()
|
|
||||||
|
|
||||||
} else {
|
customDialogTwo.dismiss()
|
||||||
|
}.show()
|
||||||
|
|
||||||
showProgress()
|
} else {
|
||||||
viewModel.itemTrash(
|
|
||||||
itemFk = itemInfoG!!.id,
|
|
||||||
warehouseFk = warehouseFk!!,
|
|
||||||
newValue = (value * -1),
|
|
||||||
isTrash = false
|
|
||||||
|
|
||||||
)
|
showProgress()
|
||||||
}
|
viewModel.itemTrash(
|
||||||
} catch (e: Exception) {
|
itemFk = itemInfoG!!.id,
|
||||||
// binding.itemcardLayout.visibility = View.GONE
|
warehouseFk = warehouseFk!!,
|
||||||
ma.messageWithSound(getString(R.string.errorNotNumber), true, true)
|
newValue = (value * -1),
|
||||||
|
isTrash = false
|
||||||
|
|
||||||
}
|
)
|
||||||
}
|
}
|
||||||
|
} catch (e: Exception) {
|
||||||
|
// binding.itemcardLayout.visibility = View.GONE
|
||||||
|
ma.messageWithSound(getString(R.string.errorNotNumber), true, true)
|
||||||
|
|
||||||
|
}
|
||||||
|
}*/
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun showDialogTrashFault(listAddress: List<AddressLoses>) {
|
private fun showDialogTrashFault(listAddress: List<AddressLoses>) {
|
||||||
|
|
|
@ -98,17 +98,6 @@ class ItemCardViewModel(var context: Context) : BaseViewModel(context) {
|
||||||
ItemProposalList(it)
|
ItemProposalList(it)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
val listError: ArrayList<ItemProposal> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
ItemProposal(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_itemProposallist.value = ItemProposalList(listError)
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -141,10 +130,12 @@ class ItemCardViewModel(var context: Context) : BaseViewModel(context) {
|
||||||
addressFk: Int?,
|
addressFk: Int?,
|
||||||
|
|
||||||
) {
|
) {
|
||||||
|
1
|
||||||
|
|
||||||
salix.setVisibleDiscard(
|
salix.setVisibleDiscard(
|
||||||
ItemDiscardSalixShortage(itemFk, warehouseFk, quantity, addressFk)
|
ItemDiscardSalixShortage(itemFk, warehouseFk, quantity, addressFk)
|
||||||
)
|
)
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_response.value = ResponseItemVO(
|
_response.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -193,18 +184,13 @@ class ItemCardViewModel(var context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun updatePackingTypeSalix(itemFk: Int, itemPackingTypeFk: String) {
|
fun updatePackingTypeSalix(itemFk: Int, itemPackingTypeFk: String) {
|
||||||
salix.updateItem(itemFk, hashMapOf("itemPackingTypeFk" to itemPackingTypeFk))
|
salix.updateItem(itemFk, hashMapOf("itemPackingTypeFk" to itemPackingTypeFk))
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -267,13 +253,7 @@ class ItemCardViewModel(var context: Context) : BaseViewModel(context) {
|
||||||
salix.barcodes_edit(
|
salix.barcodes_edit(
|
||||||
ItemBarCodeSalix(itemFk, barCodeValue)
|
ItemBarCodeSalix(itemFk, barCodeValue)
|
||||||
)
|
)
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value =
|
_response.value =
|
||||||
|
|
|
@ -58,7 +58,6 @@ class ItemProposalFragment(
|
||||||
}
|
}
|
||||||
setToolBar()
|
setToolBar()
|
||||||
setEvents()
|
setEvents()
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.itemGetSimilar(
|
viewModel.itemGetSimilar(
|
||||||
itemFk,
|
itemFk,
|
||||||
getDataInt(WAREHOUSEFK),
|
getDataInt(WAREHOUSEFK),
|
||||||
|
@ -84,7 +83,6 @@ class ItemProposalFragment(
|
||||||
override fun onOptionsItemSelected(item: Drawable) {
|
override fun onOptionsItemSelected(item: Drawable) {
|
||||||
when (item) {
|
when (item) {
|
||||||
iconFilter.drawable -> {
|
iconFilter.drawable -> {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
iconFilter.drawable.setTint(
|
iconFilter.drawable.setTint(
|
||||||
ContextCompat.getColor(
|
ContextCompat.getColor(
|
||||||
context!!,
|
context!!,
|
||||||
|
@ -119,9 +117,7 @@ class ItemProposalFragment(
|
||||||
|
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
itemProposallist.observe(viewLifecycleOwner) { it ->
|
itemProposallist.observe(viewLifecycleOwner) { it ->
|
||||||
binding.splashProgress.visibility = View.INVISIBLE
|
|
||||||
if (hideLoad) {
|
if (hideLoad) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
} else {
|
} else {
|
||||||
hideLoad = true
|
hideLoad = true
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,8 +12,6 @@ import es.verdnatura.presentation.common.ResponseItemVO
|
||||||
import retrofit2.Response
|
import retrofit2.Response
|
||||||
|
|
||||||
class BufferFragmentViewModel(val context: Context) : BaseViewModel(context) {
|
class BufferFragmentViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
/* private val GetPaletizadoresUserCase: GetPaletizadoresUserCase =
|
|
||||||
GetPaletizadoresUserCase(context)*/
|
|
||||||
|
|
||||||
private val _itembuffertype by lazy { MutableLiveData<ResponseItemVO>() }
|
private val _itembuffertype by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
val itembuffertype: LiveData<ResponseItemVO>
|
val itembuffertype: LiveData<ResponseItemVO>
|
||||||
|
|
|
@ -37,7 +37,6 @@ class ClaimFragment(
|
||||||
override fun init() {
|
override fun init() {
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
customDialogList = CustomDialogList(requireContext())
|
customDialogList = CustomDialogList(requireContext())
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
setEvents()
|
setEvents()
|
||||||
setToolBar()
|
setToolBar()
|
||||||
setAdapter()
|
setAdapter()
|
||||||
|
|
|
@ -13,8 +13,6 @@ import retrofit2.Response
|
||||||
|
|
||||||
class ClaimViewModel(val context: Context) : BaseViewModel(context) {
|
class ClaimViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
//private val GetClaimUserCase: GetClaimUserCase = GetClaimUserCase(context)
|
|
||||||
|
|
||||||
private val _responseadd by lazy { MutableLiveData<ResponseItemVO>() }
|
private val _responseadd by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
val responseadd: LiveData<ResponseItemVO>
|
val responseadd: LiveData<ResponseItemVO>
|
||||||
get() = _responseadd
|
get() = _responseadd
|
||||||
|
|
|
@ -155,7 +155,6 @@ class SaleAdapter(
|
||||||
}
|
}
|
||||||
//3969 Refactor collectionColors
|
//3969 Refactor collectionColors
|
||||||
paintTicketcolor(sale.rgb, itemTicketColor)
|
paintTicketcolor(sale.rgb, itemTicketColor)
|
||||||
//paintTicketcolorOld(sale.level, itemTicketColor)
|
|
||||||
|
|
||||||
val backgroundDrawableSac: Drawable = binding.itemArticleRowSemaforoSac.background
|
val backgroundDrawableSac: Drawable = binding.itemArticleRowSemaforoSac.background
|
||||||
val backgroundDrawablePre: Drawable = binding.itemArticleRowSemaforoPre.background
|
val backgroundDrawablePre: Drawable = binding.itemArticleRowSemaforoPre.background
|
||||||
|
@ -165,7 +164,6 @@ class SaleAdapter(
|
||||||
layoutError.visibility = View.GONE
|
layoutError.visibility = View.GONE
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//SEMAFORO
|
//SEMAFORO
|
||||||
if (sale.isPreviousPrepared == "1") {
|
if (sale.isPreviousPrepared == "1") {
|
||||||
DrawableCompat.setTint(
|
DrawableCompat.setTint(
|
||||||
|
|
|
@ -603,12 +603,7 @@ class CollectionFragment(
|
||||||
|
|
||||||
|
|
||||||
if (!goBack) {
|
if (!goBack) {
|
||||||
/* sendSalixMessage(
|
|
||||||
item = dataMessageSalix.item,
|
|
||||||
ticketFk = dataMessageSalix.ticket,
|
|
||||||
quantity = dataMessageSalix.quantity,
|
|
||||||
salePerson = dataMessageSalix.personSale
|
|
||||||
)*/
|
|
||||||
viewModel.collectionTicketGet(
|
viewModel.collectionTicketGet(
|
||||||
collection.collectionFk,
|
collection.collectionFk,
|
||||||
getDataInt(SECTORFK),
|
getDataInt(SECTORFK),
|
||||||
|
@ -616,10 +611,8 @@ class CollectionFragment(
|
||||||
type
|
type
|
||||||
)
|
)
|
||||||
|
|
||||||
// //Log.i("VERDNATURA:","La collection es ${collection.collectionFk}")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// }
|
|
||||||
|
|
||||||
goBack = false
|
goBack = false
|
||||||
|
|
||||||
|
@ -723,18 +716,7 @@ class CollectionFragment(
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
/* responseSaleMove.observe(viewLifecycleOwner, Observer {
|
|
||||||
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(it.errorMessage, isError = true, true)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
if (!goBack)
|
|
||||||
responseSaleMoveSuccesful()
|
|
||||||
goBack = false
|
|
||||||
}
|
|
||||||
|
|
||||||
})*/
|
|
||||||
responseGetExtensionFromUserId.observe(viewLifecycleOwner, Observer {
|
responseGetExtensionFromUserId.observe(viewLifecycleOwner, Observer {
|
||||||
|
|
||||||
binding.splashProgress.visibility = GONE
|
binding.splashProgress.visibility = GONE
|
||||||
|
@ -979,41 +961,9 @@ class CollectionFragment(
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
responseSalixMessage.observe(viewLifecycleOwner, Observer {
|
|
||||||
|
|
||||||
if (it.isError) {
|
|
||||||
if (!goBack) {
|
|
||||||
ma.messageWithSound(
|
|
||||||
getString(R.string.rocketKO) + it.errorMessage,
|
|
||||||
it.isError,
|
|
||||||
false
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
goBack = false
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* private fun responseSaleMoveSuccesful() {
|
|
||||||
sales[positionCollectionSplit].quantity = quantityCollectionSplit
|
|
||||||
|
|
||||||
if (quantityCollectionSplit == 0)
|
|
||||||
markLine(positionCollectionSplit, type)
|
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
|
||||||
|
|
||||||
val ticket =
|
|
||||||
"[" + sales[positionCollectionSplit].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionCollectionSplit].ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.splitSent) + sales[positionCollectionSplit].itemFk + getString(R.string.fromTicket) + ticket
|
|
||||||
|
|
||||||
sendSalixMessageNew(message, sales[positionCollectionSplit].salePersonFk)
|
|
||||||
|
|
||||||
}*/
|
|
||||||
|
|
||||||
private fun callPicker(extensionNumber: String) {
|
private fun callPicker(extensionNumber: String) {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1023,7 +973,7 @@ class CollectionFragment(
|
||||||
|
|
||||||
startActivity(intent)
|
startActivity(intent)
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
// d("VERDNATURA::" + e.message)
|
e.toast(requireContext())
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1039,23 +989,6 @@ class CollectionFragment(
|
||||||
return salePerson
|
return salePerson
|
||||||
}
|
}
|
||||||
|
|
||||||
/* private fun sendSalixMessage(
|
|
||||||
item: String,
|
|
||||||
ticketFk: Int,
|
|
||||||
quantity: String,
|
|
||||||
salePerson: String
|
|
||||||
) {
|
|
||||||
val ticket =
|
|
||||||
"[" + ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.itemAdded) + item + getString(R.string.with) + quantity + getString(R.string.unityTicket) + ticket
|
|
||||||
|
|
||||||
viewModel.sendChekingPresence(
|
|
||||||
workerId = salePerson,
|
|
||||||
message = message
|
|
||||||
)
|
|
||||||
}*/
|
|
||||||
|
|
||||||
//CREATE LIST
|
//CREATE LIST
|
||||||
private fun createCollectionList() {
|
private fun createCollectionList() {
|
||||||
|
|
||||||
|
@ -2337,32 +2270,6 @@ class CollectionFragment(
|
||||||
|
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
saleAdapter!!.notifyDataSetChanged()
|
||||||
|
|
||||||
/*val ticket =
|
|
||||||
"[" + sales[positionCollectionMissing].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionCollectionMissing].ticketFk + "/summary)"
|
|
||||||
|
|
||||||
|
|
||||||
when (typeCollectionMissing) {
|
|
||||||
|
|
||||||
"TRUE" -> {
|
|
||||||
message =
|
|
||||||
"Se ha enviado a Basura " + totalQuantity + getString(R.string.fromItem) + sales[positionCollectionMissing].itemFk + " ticket " + ticket
|
|
||||||
|
|
||||||
}
|
|
||||||
"FALSE" -> {
|
|
||||||
message =
|
|
||||||
"Se ha enviado a Faltas la cantidad de " + totalQuantity + getString(R.string.fromItem) + sales[positionCollectionMissing].itemFk + " ticket " + ticket
|
|
||||||
|
|
||||||
}
|
|
||||||
"reject" -> {
|
|
||||||
message =
|
|
||||||
"Se ha modificado la cantidad de " + sales[positionCollectionMissing].originalQuantity + " del artículo " + sales[positionCollectionMissing].itemFk + " a nueva cantidad: " + sales[positionCollectionMissing].quantity + " del ticket " + ticket
|
|
||||||
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
|
|
||||||
//sergio:ahora desde encajado
|
|
||||||
// sendSalixMessageNew(message, sales[positionCollectionMissing].salePersonFk)
|
|
||||||
|
|
||||||
binding.splashProgress.visibility = VISIBLE
|
binding.splashProgress.visibility = VISIBLE
|
||||||
viewModel.collectionTicketGet(
|
viewModel.collectionTicketGet(
|
||||||
collection.collectionFk,
|
collection.collectionFk,
|
||||||
|
@ -2384,31 +2291,11 @@ class CollectionFragment(
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
}
|
}
|
||||||
saleAdapter?.notifyDataSetChanged()
|
saleAdapter?.notifyDataSetChanged()
|
||||||
//enviar mensaje a salix
|
|
||||||
|
|
||||||
/* val ticket =
|
|
||||||
"[" + sales[positionIncreaseQuantity].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionIncreaseQuantity].ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
"Se ha modificado la cantidad original " + sales[positionIncreaseQuantity].originalQuantity + " del artículo " + sales[positionIncreaseQuantity].itemFk + " a nueva cantidad: " + sales[positionIncreaseQuantity].quantity + " del ticket " + ticket
|
|
||||||
*/
|
|
||||||
|
|
||||||
//sergio: ahora desde encajadores
|
|
||||||
// sendSalixMessageNew(message, sales[positionIncreaseQuantity].salePersonFk)
|
|
||||||
|
|
||||||
sales[positionIncreaseQuantity].originalQuantity = quantityIncrease
|
sales[positionIncreaseQuantity].originalQuantity = quantityIncrease
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
private fun sendSalixMessageNew(message: String, workerId: String) {
|
|
||||||
|
|
||||||
viewModel.sendChekingPresence(
|
|
||||||
workerId = workerId,
|
|
||||||
message = message
|
|
||||||
|
|
||||||
)
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
|
|
||||||
private fun increaseQuantity(position: Int, quantity: Int) {
|
private fun increaseQuantity(position: Int, quantity: Int) {
|
||||||
positionIncreaseQuantity = position
|
positionIncreaseQuantity = position
|
||||||
|
|
|
@ -10,7 +10,6 @@ import android.os.Build
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.os.Parcelable
|
import android.os.Parcelable
|
||||||
import android.text.InputType
|
import android.text.InputType
|
||||||
import android.util.Log
|
|
||||||
import android.util.Log.d
|
import android.util.Log.d
|
||||||
import android.view.KeyEvent
|
import android.view.KeyEvent
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
@ -600,12 +599,7 @@ class CollectionFragmentPicker(
|
||||||
|
|
||||||
|
|
||||||
if (!goBack) {
|
if (!goBack) {
|
||||||
/* sendSalixMessage(
|
|
||||||
item = dataMessageSalix.item,
|
|
||||||
ticketFk = dataMessageSalix.ticket,
|
|
||||||
quantity = dataMessageSalix.quantity,
|
|
||||||
salePerson = dataMessageSalix.personSale
|
|
||||||
)*/
|
|
||||||
viewModel.collectionTicketGet(
|
viewModel.collectionTicketGet(
|
||||||
collection.collectionFk,
|
collection.collectionFk,
|
||||||
getDataInt(SECTORFK),
|
getDataInt(SECTORFK),
|
||||||
|
@ -613,10 +607,8 @@ class CollectionFragmentPicker(
|
||||||
type
|
type
|
||||||
)
|
)
|
||||||
|
|
||||||
// //Log.i("VERDNATURA:","La collection es ${collection.collectionFk}")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// }
|
|
||||||
|
|
||||||
goBack = false
|
goBack = false
|
||||||
|
|
||||||
|
@ -860,27 +852,6 @@ class CollectionFragmentPicker(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* responseItemShelvingUpdate.observe(viewLifecycleOwner, Observer {
|
|
||||||
|
|
||||||
if (it.isError) {
|
|
||||||
|
|
||||||
if (!goBack) {
|
|
||||||
|
|
||||||
ma.messageWithSound(it.errorMessage, it.isError, false)
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
} else {
|
|
||||||
//Test volver atrás
|
|
||||||
if (!goBack){
|
|
||||||
viewModel.saleTrackingDel(
|
|
||||||
saleFk = sales[positionUnmarked].saleFk
|
|
||||||
)}
|
|
||||||
goBack = false
|
|
||||||
}
|
|
||||||
})*/
|
|
||||||
|
|
||||||
responseSaleReplace.observe(viewLifecycleOwner, Observer {
|
responseSaleReplace.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
binding.splashProgress.visibility = View.GONE
|
||||||
|
|
||||||
|
@ -995,23 +966,6 @@ class CollectionFragmentPicker(
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
responseSalixMessage.observe(viewLifecycleOwner, Observer {
|
|
||||||
|
|
||||||
if (it.isError) {
|
|
||||||
if (!goBack) {
|
|
||||||
ma.messageWithSound(
|
|
||||||
getString(R.string.rocketKO) + it.errorMessage,
|
|
||||||
it.isError,
|
|
||||||
false
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
goBack = false
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1022,12 +976,6 @@ class CollectionFragmentPicker(
|
||||||
markLine(positionCollectionSplit, type)
|
markLine(positionCollectionSplit, type)
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
saleAdapter!!.notifyDataSetChanged()
|
||||||
|
|
||||||
/* val ticket =
|
|
||||||
"[" + sales[positionCollectionSplit].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionCollectionSplit].ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.splitSent) + sales[positionCollectionSplit].itemFk + getString(R.string.fromTicket) + ticket
|
|
||||||
|
|
||||||
sendSalixMessageNew(message, sales[positionCollectionSplit].salePersonFk)*/
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1040,7 +988,7 @@ class CollectionFragmentPicker(
|
||||||
|
|
||||||
startActivity(intent)
|
startActivity(intent)
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
// d("VERDNATURA::" + e.message)
|
e.toast(requireContext())
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1056,24 +1004,6 @@ class CollectionFragmentPicker(
|
||||||
return salePerson
|
return salePerson
|
||||||
}
|
}
|
||||||
|
|
||||||
/* private fun sendSalixMessage(
|
|
||||||
item: String,
|
|
||||||
ticketFk: Int,
|
|
||||||
quantity: String,
|
|
||||||
salePerson: String
|
|
||||||
) {
|
|
||||||
val ticket =
|
|
||||||
"[" + ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.itemAdded) + item + getString(R.string.with) + quantity + getString(
|
|
||||||
R.string.unityTicket) + ticket
|
|
||||||
|
|
||||||
viewModel.sendChekingPresence(
|
|
||||||
workerId = salePerson,
|
|
||||||
message = message
|
|
||||||
)
|
|
||||||
}*/
|
|
||||||
|
|
||||||
//CREATE LIST
|
//CREATE LIST
|
||||||
private fun createCollectionList() {
|
private fun createCollectionList() {
|
||||||
|
|
||||||
|
@ -1983,7 +1913,6 @@ class CollectionFragmentPicker(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Log.d("VERDNATURA::", "SAlimos de ver el checkItem")
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2414,33 +2343,8 @@ class CollectionFragmentPicker(
|
||||||
}
|
}
|
||||||
|
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
saleAdapter!!.notifyDataSetChanged()
|
||||||
/*
|
|
||||||
val ticket =
|
|
||||||
"[" + sales[positionCollectionMissing].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionCollectionMissing].ticketFk + "/summary)"
|
|
||||||
|
|
||||||
|
|
||||||
when (typeCollectionMissing) {
|
|
||||||
|
|
||||||
"TRUE" -> {
|
|
||||||
message =
|
|
||||||
"Se ha enviado a Basura " + totalQuantity + getString(R.string.fromItem) + sales[positionCollectionMissing].itemFk + " ticket " + ticket
|
|
||||||
|
|
||||||
}
|
|
||||||
"FALSE" -> {
|
|
||||||
message =
|
|
||||||
"Se ha enviado a Faltas la cantidad de " + totalQuantity + getString(R.string.fromItem) + sales[positionCollectionMissing].itemFk + " ticket " + ticket
|
|
||||||
|
|
||||||
}
|
|
||||||
"reject" -> {
|
|
||||||
message =
|
|
||||||
"Se ha modificado la cantidad de " + sales[positionCollectionMissing].originalQuantity + " del artículo " + sales[positionCollectionMissing].itemFk + " a nueva cantidad: " + sales[positionCollectionMissing].quantity + " del ticket " + ticket
|
|
||||||
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
|
|
||||||
//sergio:ahora desde encajado
|
|
||||||
// sendSalixMessageNew(message, sales[positionCollectionMissing].salePersonFk)
|
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
binding.splashProgress.visibility = View.VISIBLE
|
||||||
viewModel.collectionTicketGet(
|
viewModel.collectionTicketGet(
|
||||||
collection.collectionFk,
|
collection.collectionFk,
|
||||||
|
@ -2462,30 +2366,11 @@ class CollectionFragmentPicker(
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
}
|
}
|
||||||
saleAdapter?.notifyDataSetChanged()
|
saleAdapter?.notifyDataSetChanged()
|
||||||
//enviar mensaje a salix
|
|
||||||
|
|
||||||
/* val ticket =
|
|
||||||
"[" + sales[positionIncreaseQuantity].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionIncreaseQuantity].ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
"Se ha modificado la cantidad original " + sales[positionIncreaseQuantity].originalQuantity + " del artículo " + sales[positionIncreaseQuantity].itemFk + " a nueva cantidad: " + sales[positionIncreaseQuantity].quantity + " del ticket " + ticket
|
|
||||||
*/
|
|
||||||
|
|
||||||
//sergio: ahora desde encajadores
|
|
||||||
// sendSalixMessageNew(message, sales[positionIncreaseQuantity].salePersonFk)
|
|
||||||
|
|
||||||
sales[positionIncreaseQuantity].originalQuantity = quantityIncrease
|
sales[positionIncreaseQuantity].originalQuantity = quantityIncrease
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* private fun sendSalixMessageNew(message: String, workerId: String) {
|
|
||||||
|
|
||||||
viewModel.sendChekingPresence(
|
|
||||||
workerId = workerId,
|
|
||||||
message = message
|
|
||||||
|
|
||||||
)
|
|
||||||
}*/
|
|
||||||
|
|
||||||
private fun increaseQuantity(position: Int, quantity: Int) {
|
private fun increaseQuantity(position: Int, quantity: Int) {
|
||||||
positionIncreaseQuantity = position
|
positionIncreaseQuantity = position
|
||||||
quantityIncrease = quantity
|
quantityIncrease = quantity
|
||||||
|
|
|
@ -621,12 +621,7 @@ class CollectionFragmentPreChecker(
|
||||||
|
|
||||||
|
|
||||||
if (!goBack) {
|
if (!goBack) {
|
||||||
/* sendSalixMessage(
|
|
||||||
item = dataMessageSalix.item,
|
|
||||||
ticketFk = dataMessageSalix.ticket,
|
|
||||||
quantity = dataMessageSalix.quantity,
|
|
||||||
salePerson = dataMessageSalix.personSale
|
|
||||||
)*/
|
|
||||||
viewModel.collectionTicketGet(
|
viewModel.collectionTicketGet(
|
||||||
collection.collectionFk,
|
collection.collectionFk,
|
||||||
getDataInt(SECTORFK),
|
getDataInt(SECTORFK),
|
||||||
|
@ -634,7 +629,7 @@ class CollectionFragmentPreChecker(
|
||||||
type
|
type
|
||||||
)
|
)
|
||||||
|
|
||||||
// //Log.i("VERDNATURA:","La collection es ${collection.collectionFk}")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// }
|
// }
|
||||||
|
@ -996,23 +991,6 @@ class CollectionFragmentPreChecker(
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
responseSalixMessage.observe(viewLifecycleOwner, Observer {
|
|
||||||
|
|
||||||
if (it.isError) {
|
|
||||||
if (!goBack) {
|
|
||||||
ma.messageWithSound(
|
|
||||||
getString(R.string.rocketKO) + it.errorMessage,
|
|
||||||
it.isError,
|
|
||||||
false
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
goBack = false
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1023,13 +1001,6 @@ class CollectionFragmentPreChecker(
|
||||||
markLine(positionCollectionSplit, type)
|
markLine(positionCollectionSplit, type)
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
saleAdapter!!.notifyDataSetChanged()
|
||||||
|
|
||||||
/* val ticket =
|
|
||||||
"[" + sales[positionCollectionSplit].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionCollectionSplit].ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.splitSent) + sales[positionCollectionSplit].itemFk + getString(R.string.fromTicket) + ticket
|
|
||||||
|
|
||||||
sendSalixMessageNew(message, sales[positionCollectionSplit].salePersonFk)*/
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun callPicker(extensionNumber: String) {
|
private fun callPicker(extensionNumber: String) {
|
||||||
|
@ -1057,23 +1028,6 @@ class CollectionFragmentPreChecker(
|
||||||
return salePerson
|
return salePerson
|
||||||
}
|
}
|
||||||
|
|
||||||
/* private fun sendSalixMessage(
|
|
||||||
item: String,
|
|
||||||
ticketFk: Int,
|
|
||||||
quantity: String,
|
|
||||||
salePerson: String
|
|
||||||
) {
|
|
||||||
val ticket =
|
|
||||||
"[" + ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.itemAdded) + item + getString(R.string.with) + quantity + getString(R.string.unityTicket) + ticket
|
|
||||||
|
|
||||||
viewModel.sendChekingPresence(
|
|
||||||
workerId = salePerson,
|
|
||||||
message = message
|
|
||||||
)
|
|
||||||
}*/
|
|
||||||
|
|
||||||
//CREATE LIST
|
//CREATE LIST
|
||||||
private fun createCollectionList() {
|
private fun createCollectionList() {
|
||||||
|
|
||||||
|
@ -1283,7 +1237,7 @@ class CollectionFragmentPreChecker(
|
||||||
if (placementVO.shelving != null && placementVO.visible != null && txtscan.uppercase() == placementVO.shelving.uppercase() && placementVO.visible != "(0)") {
|
if (placementVO.shelving != null && placementVO.visible != null && txtscan.uppercase() == placementVO.shelving.uppercase() && placementVO.visible != "(0)") {
|
||||||
if (mpok != null) mpok!!.start()
|
if (mpok != null) mpok!!.start()
|
||||||
isOk = true
|
isOk = true
|
||||||
//////Log.i("VERDNATURA:","encontrado producto")
|
|
||||||
showShelving(index, shelvingIndex)
|
showShelving(index, shelvingIndex)
|
||||||
isBreak = true
|
isBreak = true
|
||||||
break
|
break
|
||||||
|
@ -1460,7 +1414,6 @@ class CollectionFragmentPreChecker(
|
||||||
//Tarea #4371
|
//Tarea #4371
|
||||||
private fun markLine(position: Int, newType: String) {
|
private fun markLine(position: Int, newType: String) {
|
||||||
state = 0
|
state = 0
|
||||||
//////Log.i("VERDNATURA:","Marcamos linea y enviamos saleTracking")
|
|
||||||
if (type == SACADOR) {
|
if (type == SACADOR) {
|
||||||
sales[position].isPrepared = if (sales[position].isPrepared == "1") "0" else "1"
|
sales[position].isPrepared = if (sales[position].isPrepared == "1") "0" else "1"
|
||||||
if (sales[position].isPrepared == "1") {
|
if (sales[position].isPrepared == "1") {
|
||||||
|
@ -1678,7 +1631,6 @@ class CollectionFragmentPreChecker(
|
||||||
|
|
||||||
@RequiresApi(Build.VERSION_CODES.O)
|
@RequiresApi(Build.VERSION_CODES.O)
|
||||||
private fun printShelvingResult(placementSupplyListVO: PlacementSupplyListVO) {
|
private fun printShelvingResult(placementSupplyListVO: PlacementSupplyListVO) {
|
||||||
//////Log.i("VERDNATURA:","Print CustomDialog")
|
|
||||||
var shelving = ""
|
var shelving = ""
|
||||||
var item = ""
|
var item = ""
|
||||||
var longName = ""
|
var longName = ""
|
||||||
|
@ -1703,7 +1655,6 @@ class CollectionFragmentPreChecker(
|
||||||
placementSupplyListVO.list.forEach {
|
placementSupplyListVO.list.forEach {
|
||||||
if (it.stock != "0")
|
if (it.stock != "0")
|
||||||
listPlacementSupply.add(BarcodeVO(code = it.proposal))
|
listPlacementSupply.add(BarcodeVO(code = it.proposal))
|
||||||
//////Log.i("VERDNATURA:","Array de placementsupply")
|
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
// Log.i("VERDNATURA:","Pulso COGER-1")
|
// Log.i("VERDNATURA:","Pulso COGER-1")
|
||||||
|
@ -1737,12 +1688,7 @@ class CollectionFragmentPreChecker(
|
||||||
onQuantityOfShelvingSelected(itemShelvingFk)
|
onQuantityOfShelvingSelected(itemShelvingFk)
|
||||||
//Log.i("VERDNATURA:","Cantidad seleccionada")
|
//Log.i("VERDNATURA:","Cantidad seleccionada")
|
||||||
mpok?.start()
|
mpok?.start()
|
||||||
/* Se quita para comprobar al final de saleTracking_mark
|
|
||||||
ReviewQuantityForRefreshingAndSorting(
|
|
||||||
customDialogList.getValue().toInt(),
|
|
||||||
sales[storedPosition].quantity!!.toInt(),
|
|
||||||
sales[storedPosition].pickedQuantity.toInt()
|
|
||||||
)*/
|
|
||||||
customDialogList.dismiss()
|
customDialogList.dismiss()
|
||||||
} else {
|
} else {
|
||||||
itemShelvingFkStored = itemShelvingFk
|
itemShelvingFkStored = itemShelvingFk
|
||||||
|
@ -2366,16 +2312,6 @@ class CollectionFragmentPreChecker(
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
}
|
}
|
||||||
saleAdapter?.notifyDataSetChanged()
|
saleAdapter?.notifyDataSetChanged()
|
||||||
//enviar mensaje a salix
|
|
||||||
|
|
||||||
/*val ticket =
|
|
||||||
"[" + sales[positionIncreaseQuantity].ticketFk + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionIncreaseQuantity].ticketFk + "/summary)"
|
|
||||||
val message =
|
|
||||||
"Se ha modificado la cantidad original " + sales[positionIncreaseQuantity].originalQuantity + " del artículo " + sales[positionIncreaseQuantity].itemFk + " a nueva cantidad: " + sales[positionIncreaseQuantity].quantity + " del ticket " + ticket
|
|
||||||
*/
|
|
||||||
|
|
||||||
//sergio: ahora desde encajadores
|
|
||||||
// sendSalixMessageNew(message, sales[positionIncreaseQuantity].salePersonFk)
|
|
||||||
|
|
||||||
sales[positionIncreaseQuantity].originalQuantity = quantityIncrease
|
sales[positionIncreaseQuantity].originalQuantity = quantityIncrease
|
||||||
|
|
||||||
|
@ -2408,7 +2344,6 @@ class CollectionFragmentPreChecker(
|
||||||
state = "PREPARED"
|
state = "PREPARED"
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
////Refactor #4030
|
|
||||||
|
|
||||||
} else if (type == PRECHECKER) {
|
} else if (type == PRECHECKER) {
|
||||||
tickets.forEach {
|
tickets.forEach {
|
||||||
|
|
|
@ -16,9 +16,7 @@ import es.verdnatura.presentation.common.ResponseItemVO
|
||||||
import es.verdnatura.presentation.view.feature.collection.ItemVO
|
import es.verdnatura.presentation.view.feature.collection.ItemVO
|
||||||
import es.verdnatura.presentation.view.feature.collection.SalesModifiedList
|
import es.verdnatura.presentation.view.feature.collection.SalesModifiedList
|
||||||
import es.verdnatura.presentation.view.feature.collection.SalixSaleQuantity
|
import es.verdnatura.presentation.view.feature.collection.SalixSaleQuantity
|
||||||
import es.verdnatura.presentation.view.feature.collection.listSaleSalix
|
|
||||||
import es.verdnatura.presentation.view.feature.collection.mapper.map
|
import es.verdnatura.presentation.view.feature.collection.mapper.map
|
||||||
import es.verdnatura.presentation.view.feature.collection.saleSalix
|
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.CollectionTicket
|
import es.verdnatura.presentation.view.feature.sacador.model.CollectionTicket
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.MistakeTypeListVO
|
import es.verdnatura.presentation.view.feature.sacador.model.MistakeTypeListVO
|
||||||
|
@ -171,9 +169,6 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
val mistakeList: LiveData<MistakeTypeListVO>
|
val mistakeList: LiveData<MistakeTypeListVO>
|
||||||
get() = _mistakeList
|
get() = _mistakeList
|
||||||
|
|
||||||
private val _responseSalixMessage by lazy { MutableLiveData<ResponseItemVO>() }
|
|
||||||
val responseSalixMessage: LiveData<ResponseItemVO>
|
|
||||||
get() = _responseSalixMessage
|
|
||||||
|
|
||||||
private val _item by lazy { MutableLiveData<ItemVO>() }
|
private val _item by lazy { MutableLiveData<ItemVO>() }
|
||||||
val item: LiveData<ItemVO>
|
val item: LiveData<ItemVO>
|
||||||
|
@ -194,6 +189,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
print: String,
|
print: String,
|
||||||
type: String
|
type: String
|
||||||
) {
|
) {
|
||||||
|
//Tarea 6276 Salix collection_getTickets
|
||||||
silex.collection_getTickets(
|
silex.collection_getTickets(
|
||||||
collectionFk,
|
collectionFk,
|
||||||
sectorFk,
|
sectorFk,
|
||||||
|
@ -405,7 +401,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
params = arrayListOf(itemShelvingSaleFk, quantity, isItemShelvingSaleEmpty)
|
params = arrayListOf(itemShelvingSaleFk, quantity, isItemShelvingSaleEmpty)
|
||||||
//salix.itemShelvingSaleSetQuantity(
|
//salix.itemShelvingSaleSetQuantity(
|
||||||
// params = ItemShelvingSaleSalix(itemShelvingSaleFk, quantity, isItemShelvingSaleEmpty)
|
// params = ItemShelvingSaleSalix(itemShelvingSaleFk, quantity, isItemShelvingSaleEmpty)
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseConfirmReservedItemShelvingSale.value = ResponseItemVO(
|
_responseConfirmReservedItemShelvingSale.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -459,7 +455,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
) {
|
) {
|
||||||
salix.itemShelvingsReservedUpdate(
|
salix.itemShelvingsReservedUpdate(
|
||||||
id = itemShelvingSaleFk, params = hashMapOf("isPicked" to isPicked)
|
id = itemShelvingSaleFk, params = hashMapOf("isPicked" to isPicked)
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseConfirmReservedUpdate.value = ResponseItemVO(
|
_responseConfirmReservedUpdate.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -563,7 +559,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
"""where={"ticketFk":$ticketFk}""",
|
"""where={"ticketFk":$ticketFk}""",
|
||||||
hashMapOf("usedShelves" to usedShelves)
|
hashMapOf("usedShelves" to usedShelves)
|
||||||
)
|
)
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
||||||
_responseUsedShelves.value = ResponseItemVO(
|
_responseUsedShelves.value = ResponseItemVO(
|
||||||
|
@ -673,7 +669,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/* fun saleMove(
|
/* fun saleMove(
|
||||||
usuario: String,
|
usuario: String,
|
||||||
password: String,
|
password: String,
|
||||||
saleFk: String,
|
saleFk: String,
|
||||||
|
@ -712,7 +708,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
})
|
})
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
fun transferSalesSalix(
|
/* fun transferSalesSalix(
|
||||||
ticketFk: String,
|
ticketFk: String,
|
||||||
saleFk: Int,
|
saleFk: Int,
|
||||||
quantity: String,
|
quantity: String,
|
||||||
|
@ -748,9 +744,10 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}*/
|
||||||
|
|
||||||
fun saleTrackingDel(saleFk: Int) {
|
fun saleTrackingDel(saleFk: Int) {
|
||||||
|
//Tarea 6276
|
||||||
//salix.saleTrackingDel(SaleTrackingDelSalix(saleFk = saleFk, stateCodes = listOf("CHECKED","OK","PREPARED")))
|
//salix.saleTrackingDel(SaleTrackingDelSalix(saleFk = saleFk, stateCodes = listOf("CHECKED","OK","PREPARED")))
|
||||||
silex.saleTrackingDel(saleFk)
|
silex.saleTrackingDel(saleFk)
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SilexCallback<Any>(context) {
|
||||||
|
@ -832,7 +829,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun getIdFromCodeSalix(code: String) {
|
fun getIdFromCodeSalix(code: String) {
|
||||||
salix.barcodes_toitem(code)
|
salix.barcodes_toitem(code)
|
||||||
.enqueue(object : SilexCallback<String?>(context) {
|
.enqueue(object : SalixCallback<String?>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseCode.value = ResponseItemVO(
|
_responseCode.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -860,7 +857,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
) {
|
) {
|
||||||
salix.collectionIncreaseQuantitySalix(
|
salix.collectionIncreaseQuantitySalix(
|
||||||
SalixSaleQuantity(saleId = saleFk, quantity = quantity.toInt())
|
SalixSaleQuantity(saleId = saleFk, quantity = quantity.toInt())
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseIncQuantity.value = ResponseItemVO(
|
_responseIncQuantity.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -877,47 +874,6 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/* fun sendChekingPresence(
|
|
||||||
workerId: String,
|
|
||||||
message: String
|
|
||||||
|
|
||||||
) {
|
|
||||||
try {
|
|
||||||
salix.sendChekingPresence(
|
|
||||||
SalixMessageVO(
|
|
||||||
workerId = workerId.toInt(),
|
|
||||||
message = message
|
|
||||||
)
|
|
||||||
)
|
|
||||||
.enqueue(object : Callback<Boolean> {
|
|
||||||
override fun onResponse(call: Call<Boolean>, response: Response<Boolean>) {
|
|
||||||
|
|
||||||
if (!response.isSuccessful || response.message() == "false") {
|
|
||||||
_responseSalixMessage.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), response.message()
|
|
||||||
)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onFailure(call: Call<Boolean>, t: Throwable) {
|
|
||||||
_responseSalixMessage.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
//Log.i("Salix Error",""+t.message)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} catch (e: Exception) {
|
|
||||||
}
|
|
||||||
|
|
||||||
}*/
|
|
||||||
|
|
||||||
fun saleMistakeAdd(
|
fun saleMistakeAdd(
|
||||||
saleFk: Int,
|
saleFk: Int,
|
||||||
|
@ -932,7 +888,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
.enqueue(object :
|
.enqueue(object :
|
||||||
SilexCallback<Any>(context) {
|
SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseSaleMistakeAdd.value = ResponseItemVO(
|
_responseSaleMistakeAdd.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -999,7 +955,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
salix.ticketIsOutClosureZone(
|
salix.ticketIsOutClosureZone(
|
||||||
params = arrayListOf(ticketFk)
|
params = arrayListOf(ticketFk)
|
||||||
).enqueue(object :
|
).enqueue(object :
|
||||||
SilexCallback<Any>(context) {
|
SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseTicketClosure.value = ResponseItemVO(
|
_responseTicketClosure.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -1049,7 +1005,7 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
silex.collection_getUncheckedTicket(
|
silex.collection_getUncheckedTicket(
|
||||||
collectionFk
|
collectionFk
|
||||||
).enqueue(object :
|
).enqueue(object :
|
||||||
SilexCallback<String>(context) {
|
SalixCallback<String>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseCollectionUnchecked.value = ResponseItemVO(
|
_responseCollectionUnchecked.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
|
|
@ -29,6 +29,7 @@ class ControladorViewModel(var context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
|
|
||||||
fun collectionTicketGet(collectionFk: Int, sectorFk: Int, print: String, type: String) {
|
fun collectionTicketGet(collectionFk: Int, sectorFk: Int, print: String, type: String) {
|
||||||
|
//Tarea 6276 collection_getTickets
|
||||||
silex.collection_getTickets(collectionFk, sectorFk, print, type).enqueue(object :
|
silex.collection_getTickets(collectionFk, sectorFk, print, type).enqueue(object :
|
||||||
SilexCallback<CollectionVO>(context) {
|
SilexCallback<CollectionVO>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
|
@ -2,14 +2,11 @@ package es.verdnatura.presentation.view.feature.controlador.fragment
|
||||||
|
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
|
||||||
import android.graphics.drawable.Drawable
|
import android.graphics.drawable.Drawable
|
||||||
import android.net.Uri
|
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import android.print.PrintAttributes
|
import android.print.PrintAttributes
|
||||||
import android.print.PrintManager
|
import android.print.PrintManager
|
||||||
import android.webkit.WebChromeClient
|
import android.webkit.WebChromeClient
|
||||||
import android.webkit.WebSettings
|
|
||||||
import android.webkit.WebView
|
import android.webkit.WebView
|
||||||
import android.widget.ImageView
|
import android.widget.ImageView
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
|
@ -46,10 +43,6 @@ class WebFragment(
|
||||||
private fun setWeb() {
|
private fun setWeb() {
|
||||||
|
|
||||||
binding.webView.webChromeClient = WebChromeClient()
|
binding.webView.webChromeClient = WebChromeClient()
|
||||||
|
|
||||||
//binding.webView.getSettings (). setJavaScriptEnabled (true)
|
|
||||||
// sergio:deprecated
|
|
||||||
//webView.getSettings (). setPluginState (WebSettings.PluginState.ON)
|
|
||||||
val webSettings = binding.webView.settings
|
val webSettings = binding.webView.settings
|
||||||
webSettings.javaScriptEnabled = true
|
webSettings.javaScriptEnabled = true
|
||||||
webSettings.domStorageEnabled = true
|
webSettings.domStorageEnabled = true
|
||||||
|
@ -91,7 +84,6 @@ class WebFragment(
|
||||||
|
|
||||||
//listIcons.add(iconPrint)
|
//listIcons.add(iconPrint)
|
||||||
|
|
||||||
|
|
||||||
binding.mainToolbar.toolbarIcons.adapter =
|
binding.mainToolbar.toolbarIcons.adapter =
|
||||||
ToolBarAdapterTooltip(listIcons, object : OnOptionsSelectedListener {
|
ToolBarAdapterTooltip(listIcons, object : OnOptionsSelectedListener {
|
||||||
override fun onOptionsItemSelected(item: Drawable) {
|
override fun onOptionsItemSelected(item: Drawable) {
|
||||||
|
|
|
@ -229,7 +229,7 @@ class ControlVehiculoViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
) {
|
) {
|
||||||
salix.sip_getExtension(
|
salix.sip_getExtension(
|
||||||
workerId
|
workerId
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseGetExtensionFromUserId.value = ResponseItemVO(
|
_responseGetExtensionFromUserId.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
|
|
@ -4,7 +4,6 @@ import android.Manifest
|
||||||
import android.content.pm.PackageManager
|
import android.content.pm.PackageManager
|
||||||
import android.graphics.Bitmap
|
import android.graphics.Bitmap
|
||||||
import android.location.Location
|
import android.location.Location
|
||||||
import android.view.View
|
|
||||||
import androidx.appcompat.app.AlertDialog
|
import androidx.appcompat.app.AlertDialog
|
||||||
import androidx.core.app.ActivityCompat
|
import androidx.core.app.ActivityCompat
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
@ -19,6 +18,7 @@ import es.verdnatura.domain.toast
|
||||||
import es.verdnatura.presentation.base.BaseActivity
|
import es.verdnatura.presentation.base.BaseActivity
|
||||||
import es.verdnatura.presentation.base.LocationUpdateCallback
|
import es.verdnatura.presentation.base.LocationUpdateCallback
|
||||||
import es.verdnatura.presentation.base.database
|
import es.verdnatura.presentation.base.database
|
||||||
|
import es.verdnatura.presentation.common.SignListener
|
||||||
import es.verdnatura.presentation.view.component.CustomDialog
|
import es.verdnatura.presentation.view.component.CustomDialog
|
||||||
import es.verdnatura.presentation.view.feature.delivery.model.ClientTicketSalix
|
import es.verdnatura.presentation.view.feature.delivery.model.ClientTicketSalix
|
||||||
import es.verdnatura.presentation.view.feature.delivery.model.MyLocation
|
import es.verdnatura.presentation.view.feature.delivery.model.MyLocation
|
||||||
|
@ -35,8 +35,7 @@ import java.text.SimpleDateFormat
|
||||||
import java.util.Date
|
import java.util.Date
|
||||||
import java.util.Locale
|
import java.util.Locale
|
||||||
|
|
||||||
|
class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallback, SignListener {
|
||||||
class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallback {
|
|
||||||
|
|
||||||
override fun getLayoutId(): Int = R.layout.activity_sign
|
override fun getLayoutId(): Int = R.layout.activity_sign
|
||||||
|
|
||||||
|
@ -52,15 +51,15 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
|
|
||||||
"ticket" -> {
|
"ticket" -> {
|
||||||
binding.mainToolbar.toolbarTitle.text = getString(R.string.sign)
|
binding.mainToolbar.toolbarTitle.text = getString(R.string.sign)
|
||||||
clientTicket = intent.extras!!.getSerializable("clientTicketList") as ClientTicketSalix
|
clientTicket =
|
||||||
|
intent.extras!!.getSerializable("clientTicketList") as ClientTicketSalix
|
||||||
setViews(clientTicket)
|
setViews(clientTicket)
|
||||||
setLocation()
|
setLocation()
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
setEvents()
|
setEvents()
|
||||||
|
(application as MobileApplication).setSignListener(this)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
db = database(this.applicationContext)
|
db = database(this.applicationContext)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -95,12 +94,16 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (clientTicket.latitude != null && clientTicket.longitude != null) {
|
if (clientTicket.latitude != null && clientTicket.longitude != null) {
|
||||||
if (locationCurrent.distanceTo(locationClient) > 100 ) {
|
if (locationCurrent.distanceTo(locationClient) > 100) {
|
||||||
|
|
||||||
val customDialogDistance = CustomDialog(this)
|
val customDialogDistance = CustomDialog(this)
|
||||||
customDialogDistance.setTitle(getString(R.string.confirm))
|
customDialogDistance.setTitle(getString(R.string.confirm))
|
||||||
.setDescription(getString(R.string.locationDiferent)+ getString(R.string.distance) + locationCurrent.distanceTo(locationClient))
|
.setDescription(
|
||||||
|
getString(R.string.locationDiferent) + getString(R.string.distance) + locationCurrent.distanceTo(
|
||||||
|
locationClient
|
||||||
|
)
|
||||||
|
)
|
||||||
.setOkButton(getString(R.string.keep)) {
|
.setOkButton(getString(R.string.keep)) {
|
||||||
|
|
||||||
uploadImage(MyLocation(locationClient.latitude, locationClient.longitude))
|
uploadImage(MyLocation(locationClient.latitude, locationClient.longitude))
|
||||||
|
@ -111,36 +114,12 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
customDialogDistance.dismiss()
|
customDialogDistance.dismiss()
|
||||||
}
|
}
|
||||||
.show()
|
.show()
|
||||||
}else{
|
} else {
|
||||||
uploadImage(MyLocation(locationClient.longitude, locationClient.latitude))
|
uploadImage(MyLocation(locationClient.longitude, locationClient.latitude))
|
||||||
}
|
}
|
||||||
}else{
|
} else {
|
||||||
uploadImage(lastLocationCurrent)
|
uploadImage(lastLocationCurrent)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* if (locationCurrent.distanceTo(locationClient) > 100 && clientTicket.Latitude != null && clientTicket.Longitude != null) {
|
|
||||||
|
|
||||||
|
|
||||||
val customDialogDistance = CustomDialog(this)
|
|
||||||
customDialogDistance.setTitle(getString(R.string.confirm))
|
|
||||||
.setDescription(getString(R.string.locationDiferent))
|
|
||||||
.setOkButton(getString(R.string.keep)) {
|
|
||||||
|
|
||||||
uploadImage(MyLocation(locationClient.latitude, locationClient.longitude))
|
|
||||||
customDialogDistance.dismiss()
|
|
||||||
|
|
||||||
}.setKoButton(getString(R.string.modify)) {
|
|
||||||
uploadImage(lastLocationCurrent)
|
|
||||||
customDialogDistance.dismiss()
|
|
||||||
}
|
|
||||||
.show()
|
|
||||||
} else {
|
|
||||||
if (locationClient.latitude != null && locationClient.longitude != null) {
|
|
||||||
uploadImage(MyLocation(locationClient.longitude, locationClient.latitude))
|
|
||||||
} else {
|
|
||||||
uploadImage(MyLocation(locationCurrent.longitude, locationCurrent.latitude))
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setEvents() {
|
private fun setEvents() {
|
||||||
|
@ -152,7 +131,6 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private fun setViews(clientTicketList: ClientTicketSalix) {
|
private fun setViews(clientTicketList: ClientTicketSalix) {
|
||||||
|
|
||||||
if (clientTicketList != null) {
|
if (clientTicketList != null) {
|
||||||
|
@ -189,13 +167,11 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
baseContext.externalCacheDir.toString() + "/" + file.name
|
baseContext.externalCacheDir.toString() + "/" + file.name
|
||||||
)
|
)
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
deliveryViewModel.saveSign(
|
deliveryViewModel.saveSign(
|
||||||
mySign.fileName, mySign.queryMapList,
|
mySign.fileName, mySign.queryMapList,
|
||||||
)
|
)
|
||||||
|
|
||||||
deliveryViewModel.responseSign.observe(this) {
|
deliveryViewModel.responseSign.observe(this) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (!it.isError) {
|
if (!it.isError) {
|
||||||
getString(R.string.ok).toast(this)
|
getString(R.string.ok).toast(this)
|
||||||
finish()
|
finish()
|
||||||
|
@ -245,7 +221,6 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
locationUpdateCallback = this
|
locationUpdateCallback = this
|
||||||
requestLocationUpdates(fusedLocationClient)
|
requestLocationUpdates(fusedLocationClient)
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onRequestPermissionsResult(
|
override fun onRequestPermissionsResult(
|
||||||
|
@ -294,7 +269,6 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
111
|
111
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
setNegativeButton(
|
setNegativeButton(
|
||||||
getString(R.string.cancel)
|
getString(R.string.cancel)
|
||||||
|
@ -315,12 +289,14 @@ class SignedActivity : BaseActivity<ActivitySignBinding>(), LocationUpdateCallba
|
||||||
if (location.locations.isNotEmpty()) {
|
if (location.locations.isNotEmpty()) {
|
||||||
lastLocationCurrent.Longitude = location.locations.last().longitude
|
lastLocationCurrent.Longitude = location.locations.last().longitude
|
||||||
lastLocationCurrent.Latitude = location.locations.last().latitude
|
lastLocationCurrent.Latitude = location.locations.last().latitude
|
||||||
println("ubicación - Latitud: $lastLocationCurrent.Latitude, Longitud: $lastLocationCurrent.Longitude")
|
|
||||||
} else {
|
|
||||||
println("ubicación vacía")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun onApplicationEventAnimation(visibility: Int) {
|
||||||
|
binding.splashProgress.visibility = visibility
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -255,11 +255,8 @@ class TicketsFragment(
|
||||||
|
|
||||||
clientTicketList.observe(viewLifecycleOwner) {
|
clientTicketList.observe(viewLifecycleOwner) {
|
||||||
if (it.list.isNotEmpty()) {
|
if (it.list.isNotEmpty()) {
|
||||||
println("llegan los tickets")
|
|
||||||
createLisTickets(it.list)
|
createLisTickets(it.list)
|
||||||
|
|
||||||
}else{
|
|
||||||
println("tickets vacios")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
responseStateAdd.observe(viewLifecycleOwner) {}
|
responseStateAdd.observe(viewLifecycleOwner) {}
|
||||||
|
@ -274,7 +271,6 @@ class TicketsFragment(
|
||||||
setToolBar()
|
setToolBar()
|
||||||
}
|
}
|
||||||
responseLoadList.observe(viewLifecycleOwner) {
|
responseLoadList.observe(viewLifecycleOwner) {
|
||||||
println("tickets responseLoadList")
|
|
||||||
ma.messageWithSound(getString(R.string.offline), true, false, "", true)
|
ma.messageWithSound(getString(R.string.offline), true, false, "", true)
|
||||||
createLisTickets(mutableListOf(), getSaved = true)
|
createLisTickets(mutableListOf(), getSaved = true)
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,7 +5,6 @@ import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import androidx.lifecycle.Transformations
|
import androidx.lifecycle.Transformations
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.domain.formatWithQuotes
|
import es.verdnatura.domain.formatWithQuotes
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.common.Event
|
import es.verdnatura.presentation.common.Event
|
||||||
|
@ -198,25 +197,6 @@ class DeliveryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* fun expeditionState_add(expeditions: Any?, state: String) {
|
|
||||||
silex.expeditionState_add(expeditions, state)
|
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
|
||||||
_responseStateAdd.value = ResponseItemVO(state, false, "", 0)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
super.onError(t)
|
|
||||||
_responseStateAdd.value = ResponseItemVO()
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onFailure(call: Call<Unit>, t: Throwable) {
|
|
||||||
_responseStateList.value = ResponseItemVO("", true, t.message.toString(), 0)
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}*/
|
|
||||||
|
|
||||||
fun expeditionStateAddSalix(expeditions: Any) {
|
fun expeditionStateAddSalix(expeditions: Any) {
|
||||||
|
|
||||||
salix.addExpeditionState(expeditions).enqueue(object : SalixCallback<Unit>(context) {
|
salix.addExpeditionState(expeditions).enqueue(object : SalixCallback<Unit>(context) {
|
||||||
|
@ -305,16 +285,10 @@ class DeliveryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
salix.getTickets("""{"id":$routeId,"order":["priority","id"],"limit":1}""")
|
salix.getTickets("""{"id":$routeId,"order":["priority","id"],"limit":1}""")
|
||||||
.enqueue(object : SalixCallback<MutableList<ClientTicketSalix>>(context) {
|
.enqueue(object : SalixCallback<MutableList<ClientTicketSalix>>(context) {
|
||||||
override fun onSuccess(response: Response<MutableList<ClientTicketSalix>>) {
|
override fun onSuccess(response: Response<MutableList<ClientTicketSalix>>) {
|
||||||
println("ticketsss entrando")
|
|
||||||
for (list in response.body()!!){
|
|
||||||
println("ticketsss ${list.clientFk}")
|
|
||||||
}
|
|
||||||
_clientTicketList.value = response.body()?.let { ClientTicketList(it) }
|
_clientTicketList.value = response.body()?.let { ClientTicketList(it) }
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
println("ticketsss fallando")
|
|
||||||
println("tickets fallando ${t.message}")
|
|
||||||
_responseLoadList.value = ResponseItemVO("", true, t.message.toString(), 0)
|
_responseLoadList.value = ResponseItemVO("", true, t.message.toString(), 0)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -366,7 +340,7 @@ class DeliveryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
file: MultipartBody.Part
|
file: MultipartBody.Part
|
||||||
) {
|
) {
|
||||||
salix.imageUpload(warehouseId, companyId, dmsTypeId, reference, description, hasFile, file)
|
salix.imageUpload(warehouseId, companyId, dmsTypeId, reference, description, hasFile, file)
|
||||||
.enqueue(object : SilexCallback<Any>(context) {})
|
.enqueue(object : SalixCallback<Any>(context) {})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun saveSign(filePath: String, mapQuery: Map<String?, String?>) {
|
fun saveSign(filePath: String, mapQuery: Map<String?, String?>) {
|
||||||
|
|
|
@ -29,9 +29,6 @@ class HistoricoArticuloFragment(
|
||||||
HistoricoArticuloViewModel::class
|
HistoricoArticuloViewModel::class
|
||||||
) {
|
) {
|
||||||
private var adapter: HistoricoAdapter? = null
|
private var adapter: HistoricoAdapter? = null
|
||||||
|
|
||||||
// private lateinit var customDialogInput: CustomDialogInput
|
|
||||||
// private lateinit var customDialog: CustomDialog
|
|
||||||
private var listHistoric: ArrayList<ItemHistoricoVO> = ArrayList()
|
private var listHistoric: ArrayList<ItemHistoricoVO> = ArrayList()
|
||||||
private var listHistoryAux: ArrayList<ItemHistoricoVO> = ArrayList()
|
private var listHistoryAux: ArrayList<ItemHistoricoVO> = ArrayList()
|
||||||
private var filter: String = ""
|
private var filter: String = ""
|
||||||
|
@ -107,7 +104,6 @@ class HistoricoArticuloFragment(
|
||||||
|
|
||||||
private fun viewModelwithFilter(keyfilter: String) {
|
private fun viewModelwithFilter(keyfilter: String) {
|
||||||
filter = keyfilter
|
filter = keyfilter
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
itemFk?.let { viewModel.itemGetBalance(it, getDataInt(WAREHOUSEFK)) }
|
itemFk?.let { viewModel.itemGetBalance(it, getDataInt(WAREHOUSEFK)) }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -131,8 +127,7 @@ class HistoricoArticuloFragment(
|
||||||
listHistoryAux.forEach {
|
listHistoryAux.forEach {
|
||||||
|
|
||||||
if (it.name?.contains(
|
if (it.name?.contains(
|
||||||
binding.filterNameordateitem.text.toString(),
|
binding.filterNameordateitem.text.toString(), true
|
||||||
true
|
|
||||||
) == true
|
) == true
|
||||||
) {
|
) {
|
||||||
listHistoric.add(it)
|
listHistoric.add(it)
|
||||||
|
@ -155,8 +150,6 @@ class HistoricoArticuloFragment(
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
loadHistoricoList.observe(viewLifecycleOwner, Observer { event ->
|
loadHistoricoList.observe(viewLifecycleOwner, Observer { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
listToAdapter(it.list, filter)
|
listToAdapter(it.list, filter)
|
||||||
navigateToToday(it)
|
navigateToToday(it)
|
||||||
|
|
||||||
|
@ -190,6 +183,7 @@ class HistoricoArticuloFragment(
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@RequiresApi(Build.VERSION_CODES.O)
|
||||||
private fun navigateToToday(it: ItemHistoricoListVO) {
|
private fun navigateToToday(it: ItemHistoricoListVO) {
|
||||||
var positionToday = 0
|
var positionToday = 0
|
||||||
val sdf = SimpleDateFormat(getString(R.string.dateFormat))
|
val sdf = SimpleDateFormat(getString(R.string.dateFormat))
|
||||||
|
|
|
@ -6,8 +6,6 @@ import androidx.lifecycle.MutableLiveData
|
||||||
import androidx.lifecycle.Transformations
|
import androidx.lifecycle.Transformations
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
|
||||||
import es.verdnatura.presentation.common.Event
|
import es.verdnatura.presentation.common.Event
|
||||||
import es.verdnatura.presentation.view.feature.historicoarticulo.model.ItemHistoricoListVO
|
import es.verdnatura.presentation.view.feature.historicoarticulo.model.ItemHistoricoListVO
|
||||||
import es.verdnatura.presentation.view.feature.historicoarticulo.model.ItemHistoricoVO
|
import es.verdnatura.presentation.view.feature.historicoarticulo.model.ItemHistoricoVO
|
||||||
|
@ -22,25 +20,14 @@ class HistoricoArticuloViewModel(val context: Context) : BaseViewModel(context)
|
||||||
val loadHistoricoList = Transformations.map(_historicoList) { Event(it) }
|
val loadHistoricoList = Transformations.map(_historicoList) { Event(it) }
|
||||||
|
|
||||||
fun itemGetBalance(itemFk: Int, vWarehouseFk: Int) {
|
fun itemGetBalance(itemFk: Int, vWarehouseFk: Int) {
|
||||||
//salix falla fecha -- No tiene hora.
|
|
||||||
silex.itemDiary(itemFk, vWarehouseFk)
|
salix.itemGetBalance(arrayListOf(itemFk, vWarehouseFk, null))
|
||||||
// salix.itemGetBalance(arrayListOf(itemFk, vWarehouseFk, null))
|
|
||||||
.enqueue(object :
|
.enqueue(object :
|
||||||
SalixCallback<List<ItemHistoricoVO>>(context) {
|
SalixCallback<List<ItemHistoricoVO>>(context) {
|
||||||
override fun onSuccess(response: Response<List<ItemHistoricoVO>>) {
|
override fun onSuccess(response: Response<List<ItemHistoricoVO>>) {
|
||||||
_historicoList.value = response.body()?.let { ItemHistoricoListVO(it) }
|
_historicoList.value = response.body()?.let { ItemHistoricoListVO(it) }
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
val listError: ArrayList<ItemHistoricoVO> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
ItemHistoricoVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_historicoList.value = ItemHistoricoListVO(listError)
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,7 +7,6 @@ import androidx.lifecycle.Transformations
|
||||||
import com.google.gson.JsonObject
|
import com.google.gson.JsonObject
|
||||||
import es.verdnatura.MobileApplication
|
import es.verdnatura.MobileApplication
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.domain.formatWithQuotes
|
import es.verdnatura.domain.formatWithQuotes
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
|
@ -123,13 +122,13 @@ class InventaryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
salix.itemShelvingsUpdate(where, params).enqueue(object : SalixCallback<Any>(context) {
|
salix.itemShelvingsUpdate(where, params).enqueue(object : SalixCallback<Any>(context) {
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responseReset.value =
|
_responseReset.value =
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
ResponseItemVO(isError = false, response = response.message())
|
||||||
super.onSuccess(response)
|
super.onSuccess(response)
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemTrash(
|
fun itemTrash(
|
||||||
|
@ -178,14 +177,14 @@ class InventaryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun workerMistakeTypeGet() {
|
fun workerMistakeTypeGet() {
|
||||||
salix.workerMistakesTypes().enqueue(object : SilexCallback<List<MistakeType>>(context) {
|
salix.workerMistakesTypes().enqueue(object : SalixCallback<List<MistakeType>>(context) {
|
||||||
|
|
||||||
override fun onSuccess(response: Response<List<MistakeType>>) {
|
override fun onSuccess(response: Response<List<MistakeType>>) {
|
||||||
_mistakeWorkerList.value = response.body()?.let { workerMistakeTypeList(it) }
|
_mistakeWorkerList.value = response.body()?.let { workerMistakeTypeList(it) }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun workerMistakeAdd(
|
fun workerMistakeAdd(
|
||||||
|
@ -195,11 +194,10 @@ class InventaryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
.enqueue(object : SalixCallback<Any>(context) {})
|
.enqueue(object : SalixCallback<Any>(context) {})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun expeditionMistake_add(
|
fun expeditionMistakeAdd(
|
||||||
vExpeditionFk: Int,
|
vExpeditionFk: Int,
|
||||||
vTypeFk: String,
|
vTypeFk: String,
|
||||||
) {
|
) {
|
||||||
//Tarea 5134
|
|
||||||
salix.expeditionMistakesAdd(
|
salix.expeditionMistakesAdd(
|
||||||
ExpeditionMistakeSalix(
|
ExpeditionMistakeSalix(
|
||||||
expeditionFk = vExpeditionFk,
|
expeditionFk = vExpeditionFk,
|
||||||
|
@ -207,21 +205,7 @@ class InventaryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
workerFk = (context as MobileApplication).userId!!
|
workerFk = (context as MobileApplication).userId!!
|
||||||
)
|
)
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
})
|
||||||
_responseAddMistake.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
|
||||||
|
|
||||||
// sergio:refactor:solo debería haber un mensaje no un response o errorMessage
|
|
||||||
_responseAddMistake.value = ResponseItemVO(
|
|
||||||
isError = false, response = response.message()
|
|
||||||
)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun getInventoryParking(
|
fun getInventoryParking(
|
||||||
|
@ -393,62 +377,16 @@ class InventaryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
// _inventoryListParking.value = myList
|
|
||||||
|
|
||||||
/*silex.itemShelving_inventory(vParkingFromFk, vParkingToFk)
|
|
||||||
.enqueue(object :
|
|
||||||
SilexCallback<Any>(context) {
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_responseAddMistake.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
|
||||||
|
|
||||||
// sergio:refactor:solo debería haber un mensaje no un response o errorMessage
|
|
||||||
_responseAddMistake.value =
|
|
||||||
ResponseItemVO(
|
|
||||||
isError = false,
|
|
||||||
response = response.message()
|
|
||||||
)
|
|
||||||
}
|
|
||||||
})*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun expeditionMistakeType_get() {
|
fun expeditionMistakeTypeGet() {
|
||||||
// Tarea 5134 pasar a salix
|
|
||||||
salix.getExpeditionMistakeTypes()
|
salix.getExpeditionMistakeTypes()
|
||||||
.enqueue(object : SalixCallback<List<MistakeType>>(context) {
|
.enqueue(object : SalixCallback<List<MistakeType>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
val listError: ArrayList<MistakeType> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
MistakeType(
|
|
||||||
isError = true, errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), t.message!!
|
|
||||||
), description = ""
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_mistakeWorkerList.value = workerMistakeTypeList(listError)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<List<MistakeType>>) {
|
override fun onSuccess(response: Response<List<MistakeType>>) {
|
||||||
|
_mistakeWorkerList.value =
|
||||||
if (response.body() != null) {
|
response.body()?.let { workerMistakeTypeList(it) }
|
||||||
_mistakeWorkerList.value =
|
|
||||||
response.body()?.let { workerMistakeTypeList(it) }
|
|
||||||
} else {
|
|
||||||
val listError: ArrayList<MistakeType> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
MistakeType(
|
|
||||||
isError = true, errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), response.message()
|
|
||||||
), description = ""
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_mistakeWorkerList.value = workerMistakeTypeList(listError)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
|
@ -456,10 +394,10 @@ class InventaryViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun getIdFromCodeSalix(code: String) {
|
fun getIdFromCodeSalix(code: String) {
|
||||||
salix.barcodes_toitem(code).enqueue(object : SalixCallback<String?>(context) {
|
salix.barcodes_toitem(code).enqueue(object : SalixCallback<String?>(context) {
|
||||||
override fun onSuccess(response: Response<String?>) {
|
override fun onSuccess(response: Response<String?>) {
|
||||||
_responseCode.value =
|
_responseCode.value =
|
||||||
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,26 +2,27 @@ package es.verdnatura.presentation.view.feature.login.activity
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
|
import es.verdnatura.MobileApplication
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
import es.verdnatura.databinding.ActivityLoginBinding
|
import es.verdnatura.databinding.ActivityLoginBinding
|
||||||
import es.verdnatura.presentation.base.BaseActivity
|
import es.verdnatura.presentation.base.BaseActivity
|
||||||
|
import es.verdnatura.presentation.common.LoginListener
|
||||||
import es.verdnatura.presentation.common.TAG
|
import es.verdnatura.presentation.common.TAG
|
||||||
import es.verdnatura.presentation.common.addFragment
|
import es.verdnatura.presentation.common.addFragment
|
||||||
import es.verdnatura.presentation.view.feature.login.fragment.LoginFragment
|
import es.verdnatura.presentation.view.feature.login.fragment.LoginFragment
|
||||||
import es.verdnatura.presentation.view.feature.main.activity.MainActivity
|
import es.verdnatura.presentation.view.feature.main.activity.MainActivity
|
||||||
|
|
||||||
|
class LoginActivity : BaseActivity<ActivityLoginBinding>(), LoginListener {
|
||||||
class LoginActivity : BaseActivity<ActivityLoginBinding>() {
|
|
||||||
private var imageUri: Uri? = null
|
private var imageUri: Uri? = null
|
||||||
|
|
||||||
override fun getLayoutId(): Int = R.layout.activity_login
|
override fun getLayoutId(): Int = R.layout.activity_login
|
||||||
|
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
(application as MobileApplication).setLoginListener(this)
|
||||||
val intent = intent
|
val intent = intent
|
||||||
val action = intent.action
|
val action = intent.action
|
||||||
val type = intent.type
|
val type = intent.type
|
||||||
|
|
||||||
//Tarea 5322
|
|
||||||
if (Intent.ACTION_SEND == action && type?.startsWith("image/") == true) {
|
if (Intent.ACTION_SEND == action && type?.startsWith("image/") == true) {
|
||||||
val clipData = intent.clipData
|
val clipData = intent.clipData
|
||||||
if (clipData != null) {
|
if (clipData != null) {
|
||||||
|
@ -38,5 +39,9 @@ class LoginActivity : BaseActivity<ActivityLoginBinding>() {
|
||||||
finish()
|
finish()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun onApplicationEventAnimation(visibility: Int) {
|
||||||
|
binding.splashAnimation.visibility = visibility
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -10,7 +10,6 @@ import android.os.Build
|
||||||
import android.os.Environment
|
import android.os.Environment
|
||||||
import android.provider.Settings
|
import android.provider.Settings
|
||||||
import android.util.Log.d
|
import android.util.Log.d
|
||||||
import android.view.View
|
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
import androidx.lifecycle.Observer
|
import androidx.lifecycle.Observer
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
|
@ -51,14 +50,12 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
|
|
||||||
@RequiresApi(Build.VERSION_CODES.O)
|
@RequiresApi(Build.VERSION_CODES.O)
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
customDialogList = CustomDialogList(requireContext())
|
customDialogList = CustomDialogList(requireContext())
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
createFolderSerial()
|
createFolderSerial()
|
||||||
saveIdentifiers()
|
saveIdentifiers()
|
||||||
checkUser()
|
checkUser()
|
||||||
binding.buttonLogin.setOnClickListener {
|
binding.buttonLogin.setOnClickListener {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.loginSalix(
|
viewModel.loginSalix(
|
||||||
user = binding.edittextUsername.text.toString(),
|
user = binding.edittextUsername.text.toString(),
|
||||||
password = binding.edittextPassword.text.toString()
|
password = binding.edittextPassword.text.toString()
|
||||||
|
@ -250,7 +247,6 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
versionappitem.observe(viewLifecycleOwner) {
|
versionappitem.observe(viewLifecycleOwner) {
|
||||||
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
customDialog.setTitle(getString(R.string.error)).setDescription(it.errorMessage)
|
customDialog.setTitle(getString(R.string.error)).setDescription(it.errorMessage)
|
||||||
.setOkButton(getString(R.string.close)) {
|
.setOkButton(getString(R.string.close)) {
|
||||||
customDialog.dismiss()
|
customDialog.dismiss()
|
||||||
|
@ -295,7 +291,6 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
logindevice.observe(viewLifecycleOwner) {
|
logindevice.observe(viewLifecycleOwner) {
|
||||||
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
customDialog.setTitle(getString(R.string.error)).setDescription(it.errorMessage)
|
customDialog.setTitle(getString(R.string.error)).setDescription(it.errorMessage)
|
||||||
.setOkButton(getString(R.string.close)) {
|
.setOkButton(getString(R.string.close)) {
|
||||||
customDialog.dismiss()
|
customDialog.dismiss()
|
||||||
|
@ -307,11 +302,9 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
.setDescription(it.vMessage!!)
|
.setDescription(it.vMessage!!)
|
||||||
.setOkButton(getString(R.string.close)) {
|
.setOkButton(getString(R.string.close)) {
|
||||||
customDialog.dismiss()
|
customDialog.dismiss()
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
}.show()
|
}.show()
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//sergio: se añade el log
|
|
||||||
|
|
||||||
if (binding.switchRemember.isChecked) {
|
if (binding.switchRemember.isChecked) {
|
||||||
saveRemember(true)
|
saveRemember(true)
|
||||||
|
@ -388,7 +381,6 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
loginSalixItem.observe(viewLifecycleOwner) {
|
loginSalixItem.observe(viewLifecycleOwner) {
|
||||||
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
saveTokenPref("", 0)
|
saveTokenPref("", 0)
|
||||||
customDialog.setTitle(getString(R.string.error))
|
customDialog.setTitle(getString(R.string.error))
|
||||||
|
|
||||||
|
@ -419,7 +411,6 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
loadAccessConfigSalixList.observe(viewLifecycleOwner, Observer { event ->
|
loadAccessConfigSalixList.observe(viewLifecycleOwner, Observer { event ->
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
|
|
||||||
|
@ -475,12 +466,10 @@ class LoginFragment(var imageUri: Uri?) :
|
||||||
val intent = Intent(activity, MainActivity::class.java)
|
val intent = Intent(activity, MainActivity::class.java)
|
||||||
intent.data = imageUri
|
intent.data = imageUri
|
||||||
startActivity(intent)
|
startActivity(intent)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
requireActivity().finish()
|
requireActivity().finish()
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun getVersion() {
|
private fun getVersion() {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.checkVersion(
|
viewModel.checkVersion(
|
||||||
nameApp = getString(R.string.nameApp)
|
nameApp = getString(R.string.nameApp)
|
||||||
|
|
||||||
|
|
|
@ -63,7 +63,7 @@ class LoginViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun loginSalix(user: String, password: String) {
|
fun loginSalix(user: String, password: String) {
|
||||||
salix.login(LoginSalixVO(user, password)).enqueue(
|
salix.login(LoginSalixVO(user, password)).enqueue(
|
||||||
object : SilexCallback<LoginSalixVO>(context) {
|
object : SalixCallback<LoginSalixVO>(context) {
|
||||||
override fun onSuccess(response: Response<LoginSalixVO>) {
|
override fun onSuccess(response: Response<LoginSalixVO>) {
|
||||||
|
|
||||||
val loginSalixVO: LoginSalixVO?
|
val loginSalixVO: LoginSalixVO?
|
||||||
|
@ -149,7 +149,7 @@ class LoginViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
android_id: String,
|
android_id: String,
|
||||||
serialnumber: String? = null
|
serialnumber: String? = null
|
||||||
) {
|
) {
|
||||||
salix.getCurrentUserData().enqueue(object : SilexCallback<DataUserSalix>(context) {
|
salix.getCurrentUserData().enqueue(object : SalixCallback<DataUserSalix>(context) {
|
||||||
override fun onSuccess(response: Response<DataUserSalix>) {
|
override fun onSuccess(response: Response<DataUserSalix>) {
|
||||||
app.userName = response.body()?.nickname
|
app.userName = response.body()?.nickname
|
||||||
app.userId = response.body()?.id
|
app.userId = response.body()?.id
|
||||||
|
@ -194,7 +194,7 @@ class LoginViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
serialNumber = serialnumber
|
serialNumber = serialnumber
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
override fun onSuccess(response: Response<Unit>) {
|
||||||
}
|
}
|
||||||
|
@ -287,7 +287,7 @@ class LoginViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
val filter =
|
val filter =
|
||||||
"""{"fields":["itemPackingTypeFk","numberOfWagons","sectorFk","trainFk","labelerFk"],"include":[{"relation":"sector","scope":{"fields":["description","warehouseFk"]}},{"relation":"printer","scope":{"fields":["name"]}},{"relation":"train","scope":{"fields":["name"]}}]}"""
|
"""{"fields":["itemPackingTypeFk","numberOfWagons","sectorFk","trainFk","labelerFk"],"include":[{"relation":"sector","scope":{"fields":["description","warehouseFk"]}},{"relation":"printer","scope":{"fields":["name"]}},{"relation":"train","scope":{"fields":["name"]}}]}"""
|
||||||
salix.operator_getData(id = workerId, filter)
|
salix.operator_getData(id = workerId, filter)
|
||||||
.enqueue(object : SilexCallback<OperatorSalix>(context) {
|
.enqueue(object : SalixCallback<OperatorSalix>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
||||||
_workerOperator.value = OperatorSalix(
|
_workerOperator.value = OperatorSalix(
|
||||||
|
@ -324,7 +324,7 @@ class LoginViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
) {
|
) {
|
||||||
|
|
||||||
salix.getAccessTokenConfigs()
|
salix.getAccessTokenConfigs()
|
||||||
.enqueue(object : SilexCallback<List<accessConfigSalix>>(context) {
|
.enqueue(object : SalixCallback<List<accessConfigSalix>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
val listError: ArrayList<accessConfigSalix> = ArrayList()
|
val listError: ArrayList<accessConfigSalix> = ArrayList()
|
||||||
listError.add(
|
listError.add(
|
||||||
|
@ -369,7 +369,7 @@ class LoginViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun renewToken(
|
fun renewToken(
|
||||||
) {
|
) {
|
||||||
salix.renewToken()
|
salix.renewToken()
|
||||||
.enqueue(object : SilexCallback<RenewToken>(context) {
|
.enqueue(object : SalixCallback<RenewToken>(context) {
|
||||||
|
|
||||||
override fun onSuccess(response: Response<RenewToken>) {
|
override fun onSuccess(response: Response<RenewToken>) {
|
||||||
|
|
||||||
|
|
|
@ -80,11 +80,10 @@ import es.verdnatura.presentation.view.feature.sacador.fragment.showticket.ShowT
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.CollectionTicket
|
import es.verdnatura.presentation.view.feature.sacador.model.CollectionTicket
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
||||||
import es.verdnatura.presentation.view.feature.ticket.fragment.TicketAdvanceFragment
|
import es.verdnatura.presentation.view.feature.ticket.fragment.TicketAdvanceFragment
|
||||||
import es.verdnatura.presentation.view.feature.ubicador.fragment.AutomaticAddItemFragment
|
|
||||||
import es.verdnatura.presentation.view.feature.ubicador.fragment.AutomaticAddItemFragmentTEST
|
import es.verdnatura.presentation.view.feature.ubicador.fragment.AutomaticAddItemFragmentTEST
|
||||||
import es.verdnatura.presentation.view.feature.ubicador.fragment.UbicadorFragment
|
import es.verdnatura.presentation.view.feature.ubicador.fragment.UbicadorFragment
|
||||||
import es.verdnatura.presentation.view.feature.workermistake.fragment.WorkermistakeFragment
|
|
||||||
import es.verdnatura.presentation.view.feature.workermistake.fragment.PackingMistakeFragment
|
import es.verdnatura.presentation.view.feature.workermistake.fragment.PackingMistakeFragment
|
||||||
|
import es.verdnatura.presentation.view.feature.workermistake.fragment.WorkermistakeFragment
|
||||||
import kotlinx.coroutines.DelicateCoroutinesApi
|
import kotlinx.coroutines.DelicateCoroutinesApi
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.GlobalScope
|
import kotlinx.coroutines.GlobalScope
|
||||||
|
@ -579,9 +578,9 @@ class MainActivity : BaseActivity<ActivityMainBinding>(), OnPasillerosItemClickL
|
||||||
addFragmentOnTop(AutomaticAddItemFragmentTEST.newInstance(entryPoint, item.title))
|
addFragmentOnTop(AutomaticAddItemFragmentTEST.newInstance(entryPoint, item.title))
|
||||||
}
|
}
|
||||||
|
|
||||||
getString(R.string.titleControllersAction) -> {
|
/* getString(R.string.titleControllersAction) -> {
|
||||||
addFragmentOnTop(AutomaticAddItemFragment.newInstance(entryPoint, item.title))
|
addFragmentOnTop(AutomaticAddItemFragment.newInstance(entryPoint, item.title))
|
||||||
}
|
}*/
|
||||||
|
|
||||||
getString(R.string.titlePickers) -> {
|
getString(R.string.titlePickers) -> {
|
||||||
//addFragmentOnTop(SacadorFragment.newInstance())
|
//addFragmentOnTop(SacadorFragment.newInstance())
|
||||||
|
|
|
@ -51,7 +51,6 @@ class ObservFragment(
|
||||||
override fun init() {
|
override fun init() {
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
ma.hideBottomNavigation(View.GONE)
|
ma.hideBottomNavigation(View.GONE)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
setToolBar()
|
setToolBar()
|
||||||
setEvents()
|
setEvents()
|
||||||
super.init()
|
super.init()
|
||||||
|
|
|
@ -56,8 +56,6 @@ class PackagingCountFragment(
|
||||||
getString(R.string.titlePackagingObs)
|
getString(R.string.titlePackagingObs)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
|
|
||||||
customDialogInput = CustomDialogInput(requireContext())
|
customDialogInput = CustomDialogInput(requireContext())
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
ma.hideBottomNavigation(View.GONE)
|
ma.hideBottomNavigation(View.GONE)
|
||||||
|
@ -111,7 +109,6 @@ class PackagingCountFragment(
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
|
|
||||||
itemSupplierList.observe(viewLifecycleOwner) {
|
itemSupplierList.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
adapteritemsupplier =
|
adapteritemsupplier =
|
||||||
ItemSupplierAdapter(it.list, object : OnImageUpdateClickListener {
|
ItemSupplierAdapter(it.list, object : OnImageUpdateClickListener {
|
||||||
|
|
||||||
|
|
|
@ -69,7 +69,6 @@ class PackagingSummaryFragment(
|
||||||
customDialogInput = CustomDialogInput(requireContext())
|
customDialogInput = CustomDialogInput(requireContext())
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
ma.hideBottomNavigation(View.GONE)
|
ma.hideBottomNavigation(View.GONE)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
setToolBar()
|
setToolBar()
|
||||||
setEvents()
|
setEvents()
|
||||||
super.init()
|
super.init()
|
||||||
|
@ -115,14 +114,11 @@ class PackagingSummaryFragment(
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
|
|
||||||
mistakeDepartmentList.observe(viewLifecycleOwner) {
|
mistakeDepartmentList.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
createDepartmentList(it.list)
|
createDepartmentList(it.list)
|
||||||
|
|
||||||
}
|
}
|
||||||
workerFromMistakeList.observe(viewLifecycleOwner) {
|
workerFromMistakeList.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
createWorkerList(it.list)
|
createWorkerList(it.list)
|
||||||
|
|
||||||
adapterworker =
|
adapterworker =
|
||||||
WorkermistakeAdapter(listWorker, object : onMistakeWorkerClickListener {
|
WorkermistakeAdapter(listWorker, object : onMistakeWorkerClickListener {
|
||||||
|
|
||||||
|
@ -148,7 +144,6 @@ class PackagingSummaryFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
mistakeWorkerList.observe(viewLifecycleOwner, {
|
mistakeWorkerList.observe(viewLifecycleOwner, {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
showMistakeList(it.list)
|
showMistakeList(it.list)
|
||||||
//goBack = false
|
//goBack = false
|
||||||
|
|
||||||
|
@ -181,7 +176,6 @@ class PackagingSummaryFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun showMistakeList(list: List<MistakeType>) {
|
private fun showMistakeList(list: List<MistakeType>) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
listMistakes = ArrayList()
|
listMistakes = ArrayList()
|
||||||
list.forEach {
|
list.forEach {
|
||||||
listMistakes.add(BarcodeVO(code = it.description))
|
listMistakes.add(BarcodeVO(code = it.description))
|
||||||
|
|
|
@ -3,15 +3,17 @@ package es.verdnatura.presentation.view.feature.packaging.fragment.PackagingView
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import androidx.lifecycle.LiveData
|
import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import es.verdnatura.domain.SilexCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
import es.verdnatura.presentation.base.nameofFunction
|
||||||
import es.verdnatura.presentation.common.ResponseItemVO
|
import es.verdnatura.presentation.common.ResponseItemVO
|
||||||
import es.verdnatura.presentation.view.feature.packaging.model.*
|
import es.verdnatura.presentation.view.feature.packaging.model.EntrySalix
|
||||||
|
import es.verdnatura.presentation.view.feature.packaging.model.ItemSupplier
|
||||||
|
import es.verdnatura.presentation.view.feature.packaging.model.Supplier
|
||||||
|
import es.verdnatura.presentation.view.feature.packaging.model.SupplierList
|
||||||
|
import es.verdnatura.presentation.view.feature.packaging.model.itemSupplierList
|
||||||
import okhttp3.MultipartBody
|
import okhttp3.MultipartBody
|
||||||
import retrofit2.Call
|
|
||||||
import retrofit2.Callback
|
|
||||||
import retrofit2.Response
|
import retrofit2.Response
|
||||||
|
|
||||||
class PackagingViewModel(val context: Context) : BaseViewModel(context) {
|
class PackagingViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
@ -36,7 +38,7 @@ class PackagingViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun getSuppliers() {
|
fun getSuppliers() {
|
||||||
salix.getSuppliers()
|
salix.getSuppliers()
|
||||||
.enqueue(object :
|
.enqueue(object :
|
||||||
SilexCallback<List<Supplier>>(context) {
|
SalixCallback<List<Supplier>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
val listError: ArrayList<Supplier> = ArrayList()
|
val listError: ArrayList<Supplier> = ArrayList()
|
||||||
listError.add(
|
listError.add(
|
||||||
|
@ -76,7 +78,7 @@ class PackagingViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun supplier_getItems(supplierFk: Int) {
|
fun supplier_getItems(supplierFk: Int) {
|
||||||
|
|
||||||
silex.supplier_getItems(supplierFk)
|
silex.supplier_getItems(supplierFk)
|
||||||
.enqueue(object : SilexCallback<List<ItemSupplier>>(context) {
|
.enqueue(object : SalixCallback<List<ItemSupplier>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
val listError: ArrayList<ItemSupplier> = ArrayList()
|
val listError: ArrayList<ItemSupplier> = ArrayList()
|
||||||
listError.add(
|
listError.add(
|
||||||
|
@ -108,7 +110,7 @@ class PackagingViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun entry_addSalix(entry: EntrySalix) {
|
fun entry_addSalix(entry: EntrySalix) {
|
||||||
salix.Entries(entry = entry)
|
salix.Entries(entry = entry)
|
||||||
.enqueue(object :
|
.enqueue(object :
|
||||||
SilexCallback<EntrySalix> (context){
|
SalixCallback<EntrySalix> (context){
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_entry.value = EntrySalix(
|
_entry.value = EntrySalix(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -138,11 +140,11 @@ class PackagingViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun entry_uploadPhotoSalix(id: Number, warehouseId: Number, companyId: Number, dmsTypeId: Number, reference: String, description: String, hasFile: Boolean, file: MultipartBody.Part) {
|
fun entry_uploadPhotoSalix(id: Number, warehouseId: Number, companyId: Number, dmsTypeId: Number, reference: String, description: String, hasFile: Boolean, file: MultipartBody.Part) {
|
||||||
salix.uploadEntryPhoto(id, warehouseId, companyId, dmsTypeId, reference, description, hasFile, file)
|
salix.uploadEntryPhoto(id, warehouseId, companyId, dmsTypeId, reference, description, hasFile, file)
|
||||||
.enqueue(object : SilexCallback<Any>(context){})
|
.enqueue(object : SalixCallback<Any>(context){})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun entry_addFromBuy(id: Number, item: Number, printedStickers: Number) {
|
fun entry_addFromBuy(id: Number, item: Number, printedStickers: Number) {
|
||||||
salix.addFromBuy(id, item, printedStickers)
|
salix.addFromBuy(id, item, printedStickers)
|
||||||
.enqueue(object : SilexCallback<Any>(context){})
|
.enqueue(object : SalixCallback<Any>(context){})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,6 @@ import okhttp3.MultipartBody
|
||||||
import okhttp3.RequestBody
|
import okhttp3.RequestBody
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
|
|
||||||
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
||||||
class SupplierFragment(
|
class SupplierFragment(
|
||||||
var entryPoint: String = ""
|
var entryPoint: String = ""
|
||||||
|
@ -32,7 +31,6 @@ class SupplierFragment(
|
||||||
private var onBack = false
|
private var onBack = false
|
||||||
private val suppliers = ArrayList<SearchSupplierModel>()
|
private val suppliers = ArrayList<SearchSupplierModel>()
|
||||||
|
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun newInstance(entryPoint: String) = SupplierFragment(entryPoint)
|
fun newInstance(entryPoint: String) = SupplierFragment(entryPoint)
|
||||||
}
|
}
|
||||||
|
@ -52,7 +50,6 @@ class SupplierFragment(
|
||||||
val drawableId: Int =
|
val drawableId: Int =
|
||||||
R.drawable.background_test // Reemplaza "mi_drawable" con el nombre de tu recurso Drawable
|
R.drawable.background_test // Reemplaza "mi_drawable" con el nombre de tu recurso Drawable
|
||||||
|
|
||||||
|
|
||||||
/* val uri: Uri = Uri.parse(
|
/* val uri: Uri = Uri.parse(
|
||||||
ContentResolver.SCHEME_ANDROID_RESOURCE + "://" +
|
ContentResolver.SCHEME_ANDROID_RESOURCE + "://" +
|
||||||
context!!.resources.getResourcePackageName(drawableId) + '/' +
|
context!!.resources.getResourcePackageName(drawableId) + '/' +
|
||||||
|
@ -62,7 +59,6 @@ class SupplierFragment(
|
||||||
|
|
||||||
val rutaAbsoluta: String = uri.toString()*/
|
val rutaAbsoluta: String = uri.toString()*/
|
||||||
|
|
||||||
|
|
||||||
val file =
|
val file =
|
||||||
File("/storage/emulated/0/Android/data/es.verdnatura.sfusion/files/Pictures/test.png")
|
File("/storage/emulated/0/Android/data/es.verdnatura.sfusion/files/Pictures/test.png")
|
||||||
val filePart = MultipartBody.Part.createFormData(
|
val filePart = MultipartBody.Part.createFormData(
|
||||||
|
@ -92,7 +88,6 @@ class SupplierFragment(
|
||||||
|
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
binding.filterSupplier.setOnClickListener {
|
binding.filterSupplier.setOnClickListener {
|
||||||
SimpleSearchDialogCompat(
|
SimpleSearchDialogCompat(
|
||||||
context,
|
context,
|
||||||
|
@ -104,8 +99,6 @@ class SupplierFragment(
|
||||||
binding.filterSupplier.setText((nombre.getName()))
|
binding.filterSupplier.setText((nombre.getName()))
|
||||||
binding.radiobuttonTypePackaging.visibility = View.VISIBLE
|
binding.radiobuttonTypePackaging.visibility = View.VISIBLE
|
||||||
saveData("SUPPLIERNAME", nombre.getName())
|
saveData("SUPPLIERNAME", nombre.getName())
|
||||||
println("el id es " + nombre.getId())
|
|
||||||
println("el nombre es " + nombre.getName())
|
|
||||||
saveDataInt("SUPPLIERID", nombre.getId().toInt())
|
saveDataInt("SUPPLIERID", nombre.getId().toInt())
|
||||||
baseSearchDialogCompat.dismiss()
|
baseSearchDialogCompat.dismiss()
|
||||||
}.show()
|
}.show()
|
||||||
|
@ -142,7 +135,6 @@ class SupplierFragment(
|
||||||
|
|
||||||
}
|
}
|
||||||
if (!onBack) {
|
if (!onBack) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
|
|
||||||
//viewModel.addFromPackaging(getDataInt("SUPPLIERID"), getData("ENTRYTYPE")=="Rec")
|
//viewModel.addFromPackaging(getDataInt("SUPPLIERID"), getData("ENTRYTYPE")=="Rec")
|
||||||
|
|
||||||
|
@ -152,11 +144,9 @@ class SupplierFragment(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
override fun observeViewModel() {
|
override fun observeViewModel() {
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
supplierList.observe(viewLifecycleOwner) {
|
supplierList.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
createSupplierList(it.list)
|
createSupplierList(it.list)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -167,14 +157,12 @@ class SupplierFragment(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
entry.observe(viewLifecycleOwner) {
|
entry.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
println("Entrada")
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
ma.messageWithSound(it.errorMessage, true, false)
|
ma.messageWithSound(it.errorMessage, true, false)
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
saveDataInt("ENTRY", it.id!!)
|
saveDataInt("ENTRY", it.id!!)
|
||||||
println("Entrada" + it.id)
|
|
||||||
ma.onPasillerosItemClickListener(
|
ma.onPasillerosItemClickListener(
|
||||||
PasillerosItemVO(title = getString(R.string.titlePackagingCount)),
|
PasillerosItemVO(title = getString(R.string.titlePackagingCount)),
|
||||||
getString(R.string.titlePackagingCount)
|
getString(R.string.titlePackagingCount)
|
||||||
|
@ -184,7 +172,6 @@ class SupplierFragment(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private fun createSupplierList(list: List<Supplier>) {
|
private fun createSupplierList(list: List<Supplier>) {
|
||||||
suppliers.clear()
|
suppliers.clear()
|
||||||
list.forEach { supplier ->
|
list.forEach { supplier ->
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
package es.verdnatura.presentation.view.feature.packingHolland.fragment
|
package es.verdnatura.presentation.view.feature.packingHolland.fragment
|
||||||
|
|
||||||
import android.text.InputType
|
import android.text.InputType
|
||||||
import android.view.View.GONE
|
|
||||||
import android.view.View.VISIBLE
|
import android.view.View.VISIBLE
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
|
@ -27,7 +26,6 @@ class PackingHollandFragment(var entrypoint: String) :
|
||||||
override fun init() {
|
override fun init() {
|
||||||
customDialogInput = CustomDialogInput(requireContext())
|
customDialogInput = CustomDialogInput(requireContext())
|
||||||
binding.mainToolbar.toolbarTitle.text = entrypoint
|
binding.mainToolbar.toolbarTitle.text = entrypoint
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
binding.scanInput.visibility = VISIBLE
|
binding.scanInput.visibility = VISIBLE
|
||||||
setEvents()
|
setEvents()
|
||||||
super.init()
|
super.init()
|
||||||
|
@ -45,9 +43,7 @@ class PackingHollandFragment(var entrypoint: String) :
|
||||||
|
|
||||||
try {
|
try {
|
||||||
shelvingScaned = itemScanValue(
|
shelvingScaned = itemScanValue(
|
||||||
binding.scanInput.text.toString(),
|
binding.scanInput.text.toString(), "buy", "more"
|
||||||
"buy",
|
|
||||||
"more"
|
|
||||||
).toString().toInt()
|
).toString().toInt()
|
||||||
showQuantityPacking()
|
showQuantityPacking()
|
||||||
} catch (ex: Exception) {
|
} catch (ex: Exception) {
|
||||||
|
@ -69,8 +65,7 @@ class PackingHollandFragment(var entrypoint: String) :
|
||||||
customDialogInput.setInputText(InputType.TYPE_CLASS_NUMBER)
|
customDialogInput.setInputText(InputType.TYPE_CLASS_NUMBER)
|
||||||
customDialogInput.setTitle(getString(R.string.titlePackingHolland))
|
customDialogInput.setTitle(getString(R.string.titlePackingHolland))
|
||||||
customDialogInput.setDescription(getString(R.string.packingQuantity) + shelvingScaned)
|
customDialogInput.setDescription(getString(R.string.packingQuantity) + shelvingScaned)
|
||||||
.setValue("")
|
.setValue("").setOkButton(getString(R.string.modify)) {
|
||||||
.setOkButton(getString(R.string.modify)) {
|
|
||||||
callPacking(customDialogInput.getValue())
|
callPacking(customDialogInput.getValue())
|
||||||
}.setKoButton(getString(R.string.cancel)) {
|
}.setKoButton(getString(R.string.cancel)) {
|
||||||
customDialogInput.dismiss()
|
customDialogInput.dismiss()
|
||||||
|
@ -96,8 +91,7 @@ class PackingHollandFragment(var entrypoint: String) :
|
||||||
ma.hideKeyboard(customDialogInput.getEditText())
|
ma.hideKeyboard(customDialogInput.getEditText())
|
||||||
customDialogInput.dismiss()
|
customDialogInput.dismiss()
|
||||||
viewModel.travelUpdatePacking(
|
viewModel.travelUpdatePacking(
|
||||||
itemFk = shelvingScaned,
|
itemFk = shelvingScaned, packingFk = value.toInt()
|
||||||
packingFk = value.toInt()
|
|
||||||
)
|
)
|
||||||
binding.scanInput.requestFocus()
|
binding.scanInput.requestFocus()
|
||||||
} catch (ex: Exception) {
|
} catch (ex: Exception) {
|
||||||
|
@ -107,6 +101,4 @@ class PackingHollandFragment(var entrypoint: String) :
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,7 @@ class ExpeditionListAdapter (
|
||||||
holder.bind(items[position])
|
holder.bind(items[position])
|
||||||
holder.binding.root.setOnClickListener {
|
holder.binding.root.setOnClickListener {
|
||||||
onTruckClickListener.onTruckClickListener(items[position],"")
|
onTruckClickListener.onTruckClickListener(items[position],"")
|
||||||
////Log.i("VERDNATURA:","3-ontruckClickListener")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -34,8 +34,6 @@ class ExpeditionPalletAdapter (
|
||||||
override fun onBindViewHolder(holder: ItemHolder, position: Int) {
|
override fun onBindViewHolder(holder: ItemHolder, position: Int) {
|
||||||
holder.bind(items[position])
|
holder.bind(items[position])
|
||||||
holder.binding.root.setOnClickListener {
|
holder.binding.root.setOnClickListener {
|
||||||
//Tarea #4125
|
|
||||||
Log.d("VERDNATURA::","Entrando en el pallet")
|
|
||||||
onPalletClickListener.onPalletClickListener(itemExpeditionTruckVO,items[position])
|
onPalletClickListener.onPalletClickListener(itemExpeditionTruckVO,items[position])
|
||||||
}
|
}
|
||||||
holder.binding.root.setOnLongClickListener {
|
holder.binding.root.setOnLongClickListener {
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
package es.verdnatura.presentation.view.feature.paletizador.adapter
|
package es.verdnatura.presentation.view.feature.paletizador.adapter
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.util.Log
|
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.ViewGroup
|
import android.view.ViewGroup
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
|
@ -27,8 +26,6 @@ class ExpeditionScanAdapter (
|
||||||
override fun onBindViewHolder(holder: ItemHolder, position: Int) {
|
override fun onBindViewHolder(holder: ItemHolder, position: Int) {
|
||||||
holder.bind(items[position])
|
holder.bind(items[position])
|
||||||
holder.binding.root.setOnClickListener {
|
holder.binding.root.setOnClickListener {
|
||||||
//Tarea #4125
|
|
||||||
Log.d("VERDNATURA::","ENtranado en las expediciones del pallet")
|
|
||||||
onScanLongClickListener.onScanLongClickListener(items[position])
|
onScanLongClickListener.onScanLongClickListener(items[position])
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
package es.verdnatura.presentation.view.feature.paletizador.fragment
|
package es.verdnatura.presentation.view.feature.paletizador.fragment
|
||||||
|
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.graphics.drawable.Drawable
|
import android.graphics.drawable.Drawable
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
@ -30,13 +29,9 @@ class ExpeditionPalletDetailFragment(
|
||||||
) {
|
) {
|
||||||
|
|
||||||
private var adapter: ExpeditionPalletViewAdapter? = null
|
private var adapter: ExpeditionPalletViewAdapter? = null
|
||||||
|
|
||||||
// private lateinit var customDialogList: CustomDialogList
|
|
||||||
private var onPalletClickListener: OnPalletClickListener? = null
|
private var onPalletClickListener: OnPalletClickListener? = null
|
||||||
|
|
||||||
private lateinit var customDialog: CustomDialog
|
private lateinit var customDialog: CustomDialog
|
||||||
|
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun newInstance(item: ItemExpeditionTruckVO, itemPallet: ItemPalletVO) =
|
fun newInstance(item: ItemExpeditionTruckVO, itemPallet: ItemPalletVO) =
|
||||||
ExpeditionPalletDetailFragment(item, itemPallet)
|
ExpeditionPalletDetailFragment(item, itemPallet)
|
||||||
|
@ -53,20 +48,19 @@ class ExpeditionPalletDetailFragment(
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
binding.expeditionPalletDetailPallet.text =
|
binding.expeditionPalletDetailPallet.text =
|
||||||
getString(R.string.pallet) + " " + itemPallet!!.Pallet
|
getString(R.string.pallet) + " " + itemPallet!!.Pallet
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
ma.hideBottomNavigation(View.GONE)
|
ma.hideBottomNavigation(View.GONE)
|
||||||
binding.mainToolbar.toolbarTitle.text =
|
binding.mainToolbar.toolbarTitle.text =
|
||||||
itemExpeditionTruckVO!!.eta.toString() + " " + if (itemExpeditionTruckVO!!.Destino.isNullOrEmpty()) {
|
itemExpeditionTruckVO!!.eta.toString() + " " + if (itemExpeditionTruckVO!!.Destino.isNullOrEmpty()) {
|
||||||
|
|
||||||
itemExpeditionTruckVO!!.description
|
itemExpeditionTruckVO!!.description
|
||||||
}else{
|
} else {
|
||||||
itemExpeditionTruckVO!!.Destino
|
itemExpeditionTruckVO!!.Destino
|
||||||
}
|
}
|
||||||
|
|
||||||
setToolBar()
|
setToolBar()
|
||||||
setEvents()
|
setEvents()
|
||||||
viewModel.expeditionPalletView(
|
viewModel.expeditionPalletView(
|
||||||
itemPallet!!.Pallet
|
itemPallet!!.Pallet
|
||||||
)
|
)
|
||||||
super.init()
|
super.init()
|
||||||
}
|
}
|
||||||
|
@ -79,7 +73,6 @@ class ExpeditionPalletDetailFragment(
|
||||||
binding.buttonOk.setOnClickListener {
|
binding.buttonOk.setOnClickListener {
|
||||||
requireActivity().onBackPressed()
|
requireActivity().onBackPressed()
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -100,7 +93,6 @@ class ExpeditionPalletDetailFragment(
|
||||||
ToolBarAdapter(listIcons, object : OnOptionsSelectedListener {
|
ToolBarAdapter(listIcons, object : OnOptionsSelectedListener {
|
||||||
override fun onOptionsItemSelected(item: Drawable) {
|
override fun onOptionsItemSelected(item: Drawable) {
|
||||||
if (item == iconReload) {
|
if (item == iconReload) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.expeditionPalletView(
|
viewModel.expeditionPalletView(
|
||||||
itemPallet!!.Pallet
|
itemPallet!!.Pallet
|
||||||
)
|
)
|
||||||
|
@ -114,9 +106,8 @@ class ExpeditionPalletDetailFragment(
|
||||||
customDialog.setTitle(getString(R.string.info))
|
customDialog.setTitle(getString(R.string.info))
|
||||||
customDialog.setDescription(getString(R.string.messageConfirm))
|
customDialog.setDescription(getString(R.string.messageConfirm))
|
||||||
customDialog.setOkButton(getString(R.string.delete)) {
|
customDialog.setOkButton(getString(R.string.delete)) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.expeditionPalletDel(
|
viewModel.expeditionPalletDel(
|
||||||
itemPallet!!.Pallet
|
itemPallet!!.Pallet
|
||||||
)
|
)
|
||||||
customDialog.dismiss()
|
customDialog.dismiss()
|
||||||
}
|
}
|
||||||
|
@ -126,7 +117,6 @@ class ExpeditionPalletDetailFragment(
|
||||||
customDialog.show()
|
customDialog.show()
|
||||||
|
|
||||||
} else if (item == iconPrint) {
|
} else if (item == iconPrint) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
|
|
||||||
if (ma.havePrinter() && ma.haveSector()) {
|
if (ma.havePrinter() && ma.haveSector()) {
|
||||||
(getString(R.string.Imprimiendo) + getData(PRINTERNAME)).toast(
|
(getString(R.string.Imprimiendo) + getData(PRINTERNAME)).toast(
|
||||||
|
@ -174,12 +164,10 @@ class ExpeditionPalletDetailFragment(
|
||||||
})
|
})
|
||||||
|
|
||||||
responsePrintPallet.observe(viewLifecycleOwner, Observer {
|
responsePrintPallet.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
ma.messageWithSound(it.errorMessage, true, true, isToasted = false)
|
ma.messageWithSound(it.errorMessage, true, true, isToasted = false)
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.expeditionStateAddByPallet(
|
viewModel.expeditionStateAddByPallet(
|
||||||
itemPallet!!.Pallet,
|
itemPallet!!.Pallet,
|
||||||
"PALLETIZED"
|
"PALLETIZED"
|
||||||
|
@ -191,7 +179,6 @@ class ExpeditionPalletDetailFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun printExpeditionList(it: ItemPalletViewListVO) {
|
private fun printExpeditionList(it: ItemPalletViewListVO) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
val lm = LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
val lm = LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
||||||
adapter = ExpeditionPalletViewAdapter(it.list)
|
adapter = ExpeditionPalletViewAdapter(it.list)
|
||||||
binding.expeditionPalletRecyclerview.adapter = adapter
|
binding.expeditionPalletRecyclerview.adapter = adapter
|
||||||
|
|
|
@ -5,7 +5,6 @@ import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import androidx.lifecycle.Transformations
|
import androidx.lifecycle.Transformations
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.domain.formatWithQuotes
|
import es.verdnatura.domain.formatWithQuotes
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
|
@ -93,7 +92,7 @@ class ExpeditionPalletDetailViewModel(var context: Context) : BaseViewModel(cont
|
||||||
vPalletFk: Int
|
vPalletFk: Int
|
||||||
) {
|
) {
|
||||||
salix.expeditionPalletPrintLabel(arrayListOf(vPalletFk))
|
salix.expeditionPalletPrintLabel(arrayListOf(vPalletFk))
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responsePrintPallet.value =
|
_responsePrintPallet.value =
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
ResponseItemVO(isError = false, response = response.message())
|
||||||
|
|
|
@ -27,8 +27,8 @@ import java.util.*
|
||||||
|
|
||||||
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
||||||
class ExpeditionScanFragment(
|
class ExpeditionScanFragment(
|
||||||
var itemExpeditionTruckVO: ItemExpeditionTruckVO? = null,
|
private var itemExpeditionTruckVO: ItemExpeditionTruckVO? = null,
|
||||||
var itemPalletVO: ItemPalletVO? = null
|
private var itemPalletVO: ItemPalletVO? = null
|
||||||
) : BaseFragment<FragmentExpeditionScanBinding, ExpeditionScanViewModel>(
|
) : BaseFragment<FragmentExpeditionScanBinding, ExpeditionScanViewModel>(
|
||||||
ExpeditionScanViewModel::class
|
ExpeditionScanViewModel::class
|
||||||
) {
|
) {
|
||||||
|
@ -70,7 +70,6 @@ class ExpeditionScanFragment(
|
||||||
customDialogTwoButtons = CustomDialogTwoButtons(requireContext())
|
customDialogTwoButtons = CustomDialogTwoButtons(requireContext())
|
||||||
binding.expeditionScanDetailPallet.text =
|
binding.expeditionScanDetailPallet.text =
|
||||||
getString(R.string.pallet) + " " + itemPalletVO!!.Pallet
|
getString(R.string.pallet) + " " + itemPalletVO!!.Pallet
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
ma.hideBottomNavigation(View.GONE)
|
ma.hideBottomNavigation(View.GONE)
|
||||||
binding.mainToolbar.toolbarTitle.text =
|
binding.mainToolbar.toolbarTitle.text =
|
||||||
itemExpeditionTruckVO!!.eta.toString() + " " + if (itemExpeditionTruckVO!!.Destino.isNullOrBlank()) {
|
itemExpeditionTruckVO!!.eta.toString() + " " + if (itemExpeditionTruckVO!!.Destino.isNullOrBlank()) {
|
||||||
|
@ -107,7 +106,6 @@ class ExpeditionScanFragment(
|
||||||
ToolBarAdapter(listIcons, object : OnOptionsSelectedListener {
|
ToolBarAdapter(listIcons, object : OnOptionsSelectedListener {
|
||||||
override fun onOptionsItemSelected(item: Drawable) {
|
override fun onOptionsItemSelected(item: Drawable) {
|
||||||
if (item == iconReload) {
|
if (item == iconReload) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.expeditionScanList(itemPalletVO!!.Pallet)
|
viewModel.expeditionScanList(itemPalletVO!!.Pallet)
|
||||||
} else if (item == iconPlus) {
|
} else if (item == iconPlus) {
|
||||||
expeditionScanAdd()
|
expeditionScanAdd()
|
||||||
|
@ -172,7 +170,6 @@ class ExpeditionScanFragment(
|
||||||
|
|
||||||
private fun printExpeditionList(it: ItemExpeditionScanList) {
|
private fun printExpeditionList(it: ItemExpeditionScanList) {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
val lm = LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
val lm = LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
||||||
adapter = ExpeditionScanAdapter(it.list, object : OnScanLongClickListener {
|
adapter = ExpeditionScanAdapter(it.list, object : OnScanLongClickListener {
|
||||||
override fun onScanLongClickListener(itemExpeditionScan: ItemExpeditionScanVO) {
|
override fun onScanLongClickListener(itemExpeditionScan: ItemExpeditionScanVO) {
|
||||||
|
@ -183,7 +180,6 @@ class ExpeditionScanFragment(
|
||||||
)
|
)
|
||||||
.setDescription(getString(R.string.expedit) + itemExpeditionScan.expeditionFk)
|
.setDescription(getString(R.string.expedit) + itemExpeditionScan.expeditionFk)
|
||||||
.setOkButton(getString(R.string.delete)) {
|
.setOkButton(getString(R.string.delete)) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.expeditionScanDel(
|
viewModel.expeditionScanDel(
|
||||||
itemExpeditionScan.id
|
itemExpeditionScan.id
|
||||||
)
|
)
|
||||||
|
@ -201,7 +197,6 @@ class ExpeditionScanFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun expeditionScanAdd() {
|
private fun expeditionScanAdd() {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.expeditionScanAdd(
|
viewModel.expeditionScanAdd(
|
||||||
vPalletFk = itemPalletVO!!.Pallet,
|
vPalletFk = itemPalletVO!!.Pallet,
|
||||||
vTruckFk = itemExpeditionTruckVO!!.id
|
vTruckFk = itemExpeditionTruckVO!!.id
|
||||||
|
@ -212,7 +207,6 @@ class ExpeditionScanFragment(
|
||||||
private fun showScanExpeditions(it: ItemScanList) {
|
private fun showScanExpeditions(it: ItemScanList) {
|
||||||
|
|
||||||
listExpeditions = ArrayList()
|
listExpeditions = ArrayList()
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
it.list.forEach {
|
it.list.forEach {
|
||||||
if (it.expeditionFk != "0")
|
if (it.expeditionFk != "0")
|
||||||
listExpeditions.add(BarcodeVO(code = it.expeditionFk))
|
listExpeditions.add(BarcodeVO(code = it.expeditionFk))
|
||||||
|
|
|
@ -5,7 +5,6 @@ import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import androidx.lifecycle.Transformations
|
import androidx.lifecycle.Transformations
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
import es.verdnatura.presentation.base.nameofFunction
|
||||||
|
@ -82,7 +81,7 @@ class ExpeditionScanViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
fun expeditionScanAdd(vPalletFk: Int, vTruckFk: Int) {
|
fun expeditionScanAdd(vPalletFk: Int, vTruckFk: Int) {
|
||||||
salix.expeditionScanAdd(arrayListOf(vPalletFk, vTruckFk))
|
salix.expeditionScanAdd(arrayListOf(vPalletFk, vTruckFk))
|
||||||
.enqueue(object :
|
.enqueue(object :
|
||||||
SilexCallback<List<ItemScanVO>>(context) {
|
SalixCallback<List<ItemScanVO>>(context) {
|
||||||
override fun onSuccess(response: Response<List<ItemScanVO>>) {
|
override fun onSuccess(response: Response<List<ItemScanVO>>) {
|
||||||
if (response.body() != null) {
|
if (response.body() != null) {
|
||||||
_scanList.value = response.body()?.let { ItemScanList(it) }
|
_scanList.value = response.body()?.let { ItemScanList(it) }
|
||||||
|
@ -179,11 +178,8 @@ class ExpeditionScanViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun expeditionScanDel(vScanFk: Int) {
|
fun expeditionScanDel(vScanFk: Int) {
|
||||||
//Tarea 5134 // no se cambia hasta que se suba test→master 11-17-23
|
|
||||||
salix.expeditionScanDel(vScanFk)
|
salix.expeditionScanDel(vScanFk)
|
||||||
.enqueue(object : SalixCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
//silex.expeditionScanDel(vScanFk)
|
|
||||||
//.enqueue(object : SilexCallback<Any>(context) {
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseDeleteScan.value = ResponseItemVO(
|
_responseDeleteScan.value = ResponseItemVO(
|
||||||
isError = true, errorMessage = getMessageFromAllResponse(
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
|
|
|
@ -29,7 +29,6 @@ class PalletScanFragment(
|
||||||
|
|
||||||
customDialogList = CustomDialogInput(requireContext())
|
customDialogList = CustomDialogInput(requireContext())
|
||||||
ma.hideBottomNavigation(View.GONE)
|
ma.hideBottomNavigation(View.GONE)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
setEvents()
|
setEvents()
|
||||||
setToolBar()
|
setToolBar()
|
||||||
showPalletScan()
|
showPalletScan()
|
||||||
|
|
|
@ -4,7 +4,6 @@ import android.content.Context
|
||||||
import androidx.lifecycle.LiveData
|
import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.domain.formatWithQuotes
|
import es.verdnatura.domain.formatWithQuotes
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
|
@ -33,7 +32,7 @@ class PalletScanViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
vStatePallet
|
vStatePallet
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
)
|
)
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
||||||
_responseScan.value = ResponseItemVO(
|
_responseScan.value = ResponseItemVO(
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
package es.verdnatura.presentation.view.feature.parking.fragment
|
package es.verdnatura.presentation.view.feature.parking.fragment
|
||||||
|
|
||||||
|
|
||||||
import android.media.MediaPlayer
|
import android.media.MediaPlayer
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
|
@ -16,37 +15,36 @@ import es.verdnatura.presentation.view.feature.main.activity.MainActivity
|
||||||
import es.verdnatura.presentation.view.feature.parking.adapter.ParkingAdapter
|
import es.verdnatura.presentation.view.feature.parking.adapter.ParkingAdapter
|
||||||
|
|
||||||
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
||||||
class ParkingFragment (var menuOrigin:String): BaseFragment<FragmentParkingBinding,ParkingViewModel>(ParkingViewModel::class) {
|
class ParkingFragment(var menuOrigin: String) :
|
||||||
|
BaseFragment<FragmentParkingBinding, ParkingViewModel>(ParkingViewModel::class) {
|
||||||
|
|
||||||
// private lateinit var customDialog: CustomDialog
|
private var scanerList: ArrayList<BarcodeVO> = ArrayList()
|
||||||
private var scanerList:ArrayList<BarcodeVO> = ArrayList()
|
private var adapter: ParkingAdapter? = null
|
||||||
private var adapter : ParkingAdapter? = null
|
private var numParking: Int = 0
|
||||||
private var numParking : Int = 0
|
|
||||||
var mperror: MediaPlayer? = null
|
var mperror: MediaPlayer? = null
|
||||||
var mpok: MediaPlayer? = null
|
var mpok: MediaPlayer? = null
|
||||||
|
|
||||||
|
|
||||||
override fun getLayoutId(): Int = R.layout.fragment_parking
|
override fun getLayoutId(): Int = R.layout.fragment_parking
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun newInstance(menuOrigin: String) = ParkingFragment(menuOrigin = menuOrigin)
|
fun newInstance(menuOrigin: String) = ParkingFragment(menuOrigin = menuOrigin)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
override fun init() {
|
override fun init() {
|
||||||
// ma.progressAnimation(View.INVISIBLE)
|
|
||||||
setEvents()
|
setEvents()
|
||||||
binding.mainToolbar.toolbarTitle.text = getString(R.string.Parking)
|
binding.mainToolbar.toolbarTitle.text = getString(R.string.Parking)
|
||||||
|
|
||||||
if (menuOrigin ==getString(R.string.main)){hideBackButton(binding.mainToolbar)}
|
if (menuOrigin == getString(R.string.main)) {
|
||||||
//sergio: después de las últimas actualizaciones se queda activo. Se cambia opción visibilidad.
|
hideBackButton(binding.mainToolbar)
|
||||||
//viewModel.hideProgressLoading()
|
}
|
||||||
// binding.splashProgress.visibility=View.GONE
|
|
||||||
setList()
|
setList()
|
||||||
|
|
||||||
super.init()
|
super.init()
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setEvents(){
|
private fun setEvents() {
|
||||||
binding.scanInput.requestFocus()
|
binding.scanInput.requestFocus()
|
||||||
binding.scanInput.setOnEditorActionListener { v, actionId, event ->
|
binding.scanInput.setOnEditorActionListener { v, actionId, event ->
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0) {
|
||||||
|
@ -66,44 +64,29 @@ class ParkingFragment (var menuOrigin:String): BaseFragment<FragmentParkingBindi
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun observeViewModel() {
|
override fun observeViewModel() {
|
||||||
with(viewModel){
|
with(viewModel) {
|
||||||
response.observe(viewLifecycleOwner, Observer {
|
response.observe(viewLifecycleOwner, Observer {
|
||||||
/* if (it.isError){
|
|
||||||
ma.messageWithSound(it.errorMessage, isError = true,isPlayed = true)
|
|
||||||
|
|
||||||
}else{*/
|
ma.messageWithSound(
|
||||||
ma.messageWithSound(message=getString(R.string.Aparcado), isError = false,isPlayed = false, isToasted = true)
|
message = getString(R.string.Aparcado),
|
||||||
numParking -= 1
|
isError = false,
|
||||||
if (numParking <= 0) {
|
isPlayed = false,
|
||||||
mpok?.start()
|
isToasted = true
|
||||||
setList()
|
)
|
||||||
|
numParking -= 1
|
||||||
|
if (numParking <= 0) {
|
||||||
|
mpok?.start()
|
||||||
|
setList()
|
||||||
|
|
||||||
}
|
}
|
||||||
// }
|
|
||||||
})
|
})
|
||||||
|
|
||||||
/* isLoading.observe(viewLifecycleOwner, Observer {
|
|
||||||
if (it){
|
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
}else{
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
|
||||||
|
|
||||||
isLoadingProgress.observe(viewLifecycleOwner, {
|
|
||||||
|
|
||||||
binding.splashProgress.visibility = it
|
|
||||||
|
|
||||||
})*/
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setList(){
|
private fun setList() {
|
||||||
scanerList = ArrayList()
|
scanerList = ArrayList()
|
||||||
adapter = ParkingAdapter(scanerList,object: OnBarcodeRowClickListener{
|
adapter = ParkingAdapter(scanerList, object : OnBarcodeRowClickListener {
|
||||||
override fun onBarcodeRowClickListener(item: BarcodeVO) {
|
override fun onBarcodeRowClickListener(item: BarcodeVO) {
|
||||||
scanerList.removeAt(scanerList.indexOf(item))
|
scanerList.removeAt(scanerList.indexOf(item))
|
||||||
adapter?.notifyDataSetChanged()
|
adapter?.notifyDataSetChanged()
|
||||||
|
@ -115,31 +98,31 @@ class ParkingFragment (var menuOrigin:String): BaseFragment<FragmentParkingBindi
|
||||||
binding.fragmentParkingScanList.layoutManager = lm
|
binding.fragmentParkingScanList.layoutManager = lm
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun checkScan(txtScan:String){
|
private fun checkScan(txtScan: String) {
|
||||||
var isParking:Boolean = false
|
var isParking = false
|
||||||
if (txtScan.trim().length == 4 && isLetter(txtScan.substring(txtScan.length - 1)) || txtScan.contains("-")){
|
if (txtScan.trim().length == 4 && isLetter(txtScan.substring(txtScan.length - 1)) || txtScan.contains(
|
||||||
|
"-"
|
||||||
|
)
|
||||||
|
) {
|
||||||
isParking = true
|
isParking = true
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isParking){
|
if (isParking) {
|
||||||
numParking = scanerList.size
|
numParking = scanerList.size
|
||||||
scanerList.forEach {
|
scanerList.forEach {
|
||||||
// binding.splashProgress.visibility = View.VSIIBLE
|
|
||||||
viewModel.setParking(
|
viewModel.setParking(
|
||||||
parking = txtScan,
|
parking = txtScan, scanItem = it.code!!
|
||||||
scanItem = it.code!!
|
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}else{
|
} else {
|
||||||
scanerList.add(BarcodeVO(code = txtScan))
|
scanerList.add(BarcodeVO(code = txtScan))
|
||||||
adapter?.notifyDataSetChanged()
|
adapter?.notifyDataSetChanged()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
// val prefs: SharedPreferences = requireActivity().getSharedPreferences(PREFS_USER,0)
|
mperror = MediaPlayer.create((activity as MainActivity), R.raw.error)
|
||||||
mperror = MediaPlayer.create((activity as MainActivity),R.raw.error)
|
mpok = MediaPlayer.create((activity as MainActivity), R.raw.ok)
|
||||||
mpok = MediaPlayer.create((activity as MainActivity),R.raw.ok)
|
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -148,5 +131,4 @@ class ParkingFragment (var menuOrigin:String): BaseFragment<FragmentParkingBindi
|
||||||
return text.matches(getString(R.string.regExp).toRegex())
|
return text.matches(getString(R.string.regExp).toRegex())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,6 @@ package es.verdnatura.presentation.view.feature.pasillero.adapter
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import android.util.Log
|
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.ViewGroup
|
import android.view.ViewGroup
|
||||||
import androidx.databinding.DataBindingUtil
|
import androidx.databinding.DataBindingUtil
|
||||||
|
@ -12,9 +11,9 @@ import es.verdnatura.BR
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
import es.verdnatura.databinding.ItemMainMenuBinding
|
import es.verdnatura.databinding.ItemMainMenuBinding
|
||||||
import es.verdnatura.databinding.ItemPasillerosMainMenuBinding
|
import es.verdnatura.databinding.ItemPasillerosMainMenuBinding
|
||||||
|
import es.verdnatura.domain.toast
|
||||||
import es.verdnatura.presentation.common.OnPasillerosItemClickListener
|
import es.verdnatura.presentation.common.OnPasillerosItemClickListener
|
||||||
import es.verdnatura.presentation.view.feature.pasillero.model.PasillerosItemVO
|
import es.verdnatura.presentation.view.feature.pasillero.model.PasillerosItemVO
|
||||||
import timber.log.Timber.d
|
|
||||||
|
|
||||||
class PasillerosAdapter (
|
class PasillerosAdapter (
|
||||||
private val items: List<PasillerosItemVO>,
|
private val items: List<PasillerosItemVO>,
|
||||||
|
@ -84,7 +83,7 @@ class PasillerosAdapter (
|
||||||
try {
|
try {
|
||||||
(binding as ItemMainMenuBinding).itemImage.setImageResource(item.iconResource)
|
(binding as ItemMainMenuBinding).itemImage.setImageResource(item.iconResource)
|
||||||
}catch(exception:Exception){
|
}catch(exception:Exception){
|
||||||
// d("Exception::"+exception.message)
|
exception.toast(context)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||||
|
@ -97,7 +96,7 @@ class PasillerosAdapter (
|
||||||
try {
|
try {
|
||||||
(binding as ItemPasillerosMainMenuBinding).itemImage.setImageResource(item.iconResource)
|
(binding as ItemPasillerosMainMenuBinding).itemImage.setImageResource(item.iconResource)
|
||||||
}catch(exception:Exception){
|
}catch(exception:Exception){
|
||||||
//d("Exception::"+exception.message)
|
exception.toast(context)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||||
|
@ -106,20 +105,6 @@ class PasillerosAdapter (
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* binding.apply {
|
|
||||||
this.item = item
|
|
||||||
this.title = context?.getString(item.titleToShow)
|
|
||||||
|
|
||||||
try {
|
|
||||||
itemImage.setImageResource(item.iconResource)
|
|
||||||
}catch(exception:Exception){
|
|
||||||
d("Exception::"+exception.message)
|
|
||||||
}
|
|
||||||
|
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
|
||||||
itemImage.tooltipText=item.description
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -3,7 +3,7 @@ package es.verdnatura.presentation.view.feature.photos.fragment
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import androidx.lifecycle.LiveData
|
import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import es.verdnatura.domain.SilexCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
import es.verdnatura.presentation.base.nameofFunction
|
||||||
|
@ -12,11 +12,8 @@ import okhttp3.MediaType
|
||||||
import okhttp3.MultipartBody
|
import okhttp3.MultipartBody
|
||||||
import okhttp3.RequestBody
|
import okhttp3.RequestBody
|
||||||
import retrofit2.Response
|
import retrofit2.Response
|
||||||
import retrofit2.http.Header
|
|
||||||
import retrofit2.http.Part
|
|
||||||
import retrofit2.http.QueryMap
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.util.*
|
import java.util.Date
|
||||||
|
|
||||||
|
|
||||||
class PhotosViewModel(val context: Context) : BaseViewModel(context) {
|
class PhotosViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
@ -44,7 +41,7 @@ class PhotosViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
) {
|
) {
|
||||||
salix.uploadImage("catalog",itemFK,filePart)
|
salix.uploadImage("catalog",itemFK,filePart)
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseinsert.value = ResponseItemVO(
|
_responseinsert.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
|
|
@ -35,7 +35,6 @@ class PreControladorFragment :
|
||||||
|
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
binding.mainToolbar.toolbarTitle.text = getString(R.string.titlePreControl)
|
binding.mainToolbar.toolbarTitle.text = getString(R.string.titlePreControl)
|
||||||
setEvents()
|
setEvents()
|
||||||
super.init()
|
super.init()
|
||||||
|
|
|
@ -16,7 +16,8 @@ class PreControladorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
private val _collectionTicketList by lazy { MutableLiveData<CollectionVO>() }
|
private val _collectionTicketList by lazy { MutableLiveData<CollectionVO>() }
|
||||||
val collectionTicketList: LiveData<CollectionVO>
|
val collectionTicketList: LiveData<CollectionVO>
|
||||||
get() = _collectionTicketList
|
get() = _collectionTicketList
|
||||||
|
//Tarea 6276
|
||||||
|
//a salix
|
||||||
fun collectionTicketGet(collectionFk: String, sectorFk: String, type: String) {
|
fun collectionTicketGet(collectionFk: String, sectorFk: String, type: String) {
|
||||||
silex.collection_getTickets(collectionFk, sectorFk, "0", type).enqueue(object :
|
silex.collection_getTickets(collectionFk, sectorFk, "0", type).enqueue(object :
|
||||||
SilexCallback<CollectionVO>(context) {
|
SilexCallback<CollectionVO>(context) {
|
||||||
|
|
|
@ -189,13 +189,6 @@ class EndSacadorFragment(
|
||||||
} else {
|
} else {
|
||||||
saleTrackingReplace(positionUnmarked)
|
saleTrackingReplace(positionUnmarked)
|
||||||
setTotalLines()
|
setTotalLines()
|
||||||
/* viewModel.saleTrackingDel(
|
|
||||||
getData(USER),
|
|
||||||
getData(PASSWORD),
|
|
||||||
saleFk = sales[positionUnmarked].saleFk,
|
|
||||||
"saleTracking_del"
|
|
||||||
)*/
|
|
||||||
|
|
||||||
goBack = false
|
goBack = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -208,21 +201,6 @@ class EndSacadorFragment(
|
||||||
goBack = false
|
goBack = false
|
||||||
})
|
})
|
||||||
|
|
||||||
responseSalixMessage.observe(viewLifecycleOwner, Observer {
|
|
||||||
if (!goBack) {
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(
|
|
||||||
getString(R.string.rocketKO) + it.errorMessage,
|
|
||||||
true,
|
|
||||||
false
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
goBack = false
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
responseIncQuantity.observe(viewLifecycleOwner, Observer {
|
responseIncQuantity.observe(viewLifecycleOwner, Observer {
|
||||||
|
|
||||||
if (!goBack) {
|
if (!goBack) {
|
||||||
|
@ -401,7 +379,6 @@ class EndSacadorFragment(
|
||||||
|
|
||||||
private fun responseSaleMoveSuccesful() {
|
private fun responseSaleMoveSuccesful() {
|
||||||
|
|
||||||
//Timber.d("responseSaleMove succesful")
|
|
||||||
try {
|
try {
|
||||||
sales[positionCollectionSplit].saldo = quantityCollectionSplit.toInt()
|
sales[positionCollectionSplit].saldo = quantityCollectionSplit.toInt()
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
|
@ -413,19 +390,6 @@ class EndSacadorFragment(
|
||||||
markLine(positionCollectionSplit)
|
markLine(positionCollectionSplit)
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
saleAdapter!!.notifyDataSetChanged()
|
||||||
|
|
||||||
//enviar mensaje a salix
|
|
||||||
/* val ticket =
|
|
||||||
"[" + sales[positionCollectionSplit].id + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionCollectionSplit].id + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.splitSent) + sales[positionCollectionSplit].itemFk + getString(R.string.fromTicket) + ticket*/
|
|
||||||
|
|
||||||
/* viewModel.sendChekingPresence(
|
|
||||||
token = getData(TOKEN),
|
|
||||||
workerId = sales[positionCollectionSplit].salesPersonFk,
|
|
||||||
message = message,
|
|
||||||
"sendChekingPresence"
|
|
||||||
)*/
|
|
||||||
/* sendSalixMessageNew(message, sales[positionCollectionSplit].salesPersonFk)*/
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -439,18 +403,6 @@ class EndSacadorFragment(
|
||||||
|
|
||||||
saleAdapter?.notifyDataSetChanged()
|
saleAdapter?.notifyDataSetChanged()
|
||||||
|
|
||||||
/* val ticket =
|
|
||||||
"[" + sales[positionIncreaseQuantity].id + "](https://salix.verdnatura.es/#!/ticket/" + sales[positionIncreaseQuantity].id + "/summary)"
|
|
||||||
val message =
|
|
||||||
getString(R.string.modifiedQuantityPrevious) + sales[positionIncreaseQuantity].quantity + getString(
|
|
||||||
R.string.fromItem
|
|
||||||
) + sales[positionIncreaseQuantity].itemFk + getString(R.string.toNewQuantity) + quantityIncrease + getString(
|
|
||||||
R.string.fromTicket
|
|
||||||
) + ticket
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
sendSalixMessageNew(message, sales[positionIncreaseQuantity].salesPersonFk)*/
|
|
||||||
searchSaleCollection()
|
searchSaleCollection()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -466,7 +418,7 @@ class EndSacadorFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun searchTicket(ticketFk: Int) {
|
private fun searchTicket(ticketFk: Int) {
|
||||||
//Log.i(TAG, "Escaneamos ticket en previa" + ticketFk)
|
|
||||||
ticket = ticketFk
|
ticket = ticketFk
|
||||||
|
|
||||||
if (ticketFk != 0)
|
if (ticketFk != 0)
|
||||||
|
@ -604,12 +556,10 @@ class EndSacadorFragment(
|
||||||
var isOk = false
|
var isOk = false
|
||||||
|
|
||||||
for (saleVO in sales) {
|
for (saleVO in sales) {
|
||||||
//Timber.tag("VERDNATURA::").d("El item buscado es " + saleVO.itemFk)
|
|
||||||
if (saleVO.quantity != saleVO.picked) {
|
if (saleVO.quantity != saleVO.picked) {
|
||||||
//1- Por carro
|
//1- Por carro
|
||||||
var shelvingIndex = 0
|
var shelvingIndex = 0
|
||||||
for (placementVO in saleVO.carros) {
|
for (placementVO in saleVO.carros) {
|
||||||
//Timber.tag("VERDNATURA::").d("La matric " + placementVO.shelving)
|
|
||||||
if (txtscan.uppercase() == placementVO.shelving.uppercase()) {
|
if (txtscan.uppercase() == placementVO.shelving.uppercase()) {
|
||||||
if (mpok != null) mpok!!.start()
|
if (mpok != null) mpok!!.start()
|
||||||
isOk = true
|
isOk = true
|
||||||
|
@ -703,15 +653,6 @@ class EndSacadorFragment(
|
||||||
saleFk = sales[position].idMovimiento
|
saleFk = sales[position].idMovimiento
|
||||||
)
|
)
|
||||||
positionUnmarked = position
|
positionUnmarked = position
|
||||||
//sergio: anterior previa
|
|
||||||
/* viewModel.saleTrackingDel(
|
|
||||||
usuario =getData(USER),
|
|
||||||
password = getData(PASSWORD),
|
|
||||||
saleFk = sales[position].idMovimiento, "saleTracking_del"
|
|
||||||
)*/
|
|
||||||
//sergio: previa se pone después itemshelving_update
|
|
||||||
//saleTrackingReplace(positionUnmarked)
|
|
||||||
//setTotalLines()
|
|
||||||
scanRequest()
|
scanRequest()
|
||||||
customDialog.dismiss()
|
customDialog.dismiss()
|
||||||
}.setKoButton(getString(R.string.cancel)) {
|
}.setKoButton(getString(R.string.cancel)) {
|
||||||
|
@ -830,7 +771,7 @@ class EndSacadorFragment(
|
||||||
).toString()
|
).toString()
|
||||||
)
|
)
|
||||||
originalItemScan = customDialogList.getValueTwo()
|
originalItemScan = customDialogList.getValueTwo()
|
||||||
////Log.i("VERDNATURA:","el item original es $originalItemScan")
|
|
||||||
|
|
||||||
if (customDialogList.getValueTwo().isNotEmpty()) {
|
if (customDialogList.getValueTwo().isNotEmpty()) {
|
||||||
if (checkItemScan(customDialogList.getValueTwo())) {
|
if (checkItemScan(customDialogList.getValueTwo())) {
|
||||||
|
|
|
@ -24,8 +24,7 @@ import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
||||||
|
|
||||||
class InitPreSacadorFragment(
|
class InitPreSacadorFragment(
|
||||||
var entrypoint: String = ""
|
var entrypoint: String = ""
|
||||||
) :
|
) : BaseFragment<FragmentSacadorBinding, PreSacadorViewModel>(PreSacadorViewModel::class) {
|
||||||
BaseFragment<FragmentSacadorBinding, PreSacadorViewModel>(PreSacadorViewModel::class) {
|
|
||||||
|
|
||||||
private var onCollectionSelectedListener: OnCollectionSelectedListener? = null
|
private var onCollectionSelectedListener: OnCollectionSelectedListener? = null
|
||||||
private var goBack: Boolean = false
|
private var goBack: Boolean = false
|
||||||
|
@ -50,8 +49,6 @@ class InitPreSacadorFragment(
|
||||||
|
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
customDialogInput = CustomDialogInput(requireContext())
|
customDialogInput = CustomDialogInput(requireContext())
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
binding.splashProgressTwo.visibility = View.GONE
|
|
||||||
setToolBar()
|
setToolBar()
|
||||||
setEvents()
|
setEvents()
|
||||||
viewModel.sectorCollectionGet()
|
viewModel.sectorCollectionGet()
|
||||||
|
@ -87,19 +84,13 @@ class InitPreSacadorFragment(
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
listIcons.add(iconAdd)
|
listIcons.add(iconAdd)
|
||||||
// Tarea 4731
|
|
||||||
//listIcons.add(iconPrint)
|
|
||||||
|
|
||||||
binding.mainToolbar.toolbarIcons.adapter =
|
binding.mainToolbar.toolbarIcons.adapter =
|
||||||
ToolBarAdapterTooltip(listIcons, object : OnOptionsSelectedListener {
|
ToolBarAdapterTooltip(listIcons, object : OnOptionsSelectedListener {
|
||||||
override fun onOptionsItemSelected(item: Drawable) {
|
override fun onOptionsItemSelected(item: Drawable) {
|
||||||
|
|
||||||
when (item) {
|
when (item) {
|
||||||
|
|
||||||
iconAdd.drawable -> {
|
iconAdd.drawable -> {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.sectorCollection_new(getDataInt(SECTORFK))
|
viewModel.sectorCollection_new(getDataInt(SECTORFK))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -115,7 +106,6 @@ class InitPreSacadorFragment(
|
||||||
|
|
||||||
private fun print() {
|
private fun print() {
|
||||||
if (ma.havePrinter()) {
|
if (ma.havePrinter()) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
viewModel.ticketPrintLabelPrevious(customDialogInput.getValue().toInt())
|
viewModel.ticketPrintLabelPrevious(customDialogInput.getValue().toInt())
|
||||||
(getString(R.string.Imprimiendo) + getData(PRINTERNAME)).toast(
|
(getString(R.string.Imprimiendo) + getData(PRINTERNAME)).toast(
|
||||||
requireContext()
|
requireContext()
|
||||||
|
@ -129,12 +119,10 @@ class InitPreSacadorFragment(
|
||||||
|
|
||||||
customDialogInput.setInputText(InputType.TYPE_CLASS_NUMBER)
|
customDialogInput.setInputText(InputType.TYPE_CLASS_NUMBER)
|
||||||
customDialogInput.setTitle(getString(R.string.printTicket))
|
customDialogInput.setTitle(getString(R.string.printTicket))
|
||||||
customDialogInput.setDescription(getString(R.string.printPreviousGroup))
|
customDialogInput.setDescription(getString(R.string.printPreviousGroup)).setValue("")
|
||||||
.setValue("")
|
|
||||||
.setOkButton(getString(R.string.print)) {
|
.setOkButton(getString(R.string.print)) {
|
||||||
try {
|
try {
|
||||||
if (customDialogInput.getValue().isNotEmpty()
|
if (customDialogInput.getValue().isNotEmpty()) {
|
||||||
) {
|
|
||||||
print()
|
print()
|
||||||
}
|
}
|
||||||
} catch (ex: Exception) {
|
} catch (ex: Exception) {
|
||||||
|
@ -152,10 +140,9 @@ class InitPreSacadorFragment(
|
||||||
ma.hideKeyboard(customDialogInput.getEditText())
|
ma.hideKeyboard(customDialogInput.getEditText())
|
||||||
|
|
||||||
customDialogInput.getEditText().setOnEditorActionListener { _, actionId, _ ->
|
customDialogInput.getEditText().setOnEditorActionListener { _, actionId, _ ->
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5 || actionId == 6) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
||||||
|
|
||||||
if (customDialogInput.getValue().isNotEmpty()
|
if (customDialogInput.getValue().isNotEmpty()) {
|
||||||
) {
|
|
||||||
print()
|
print()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -177,43 +164,15 @@ class InitPreSacadorFragment(
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
|
|
||||||
collectionList.observe(viewLifecycleOwner, Observer {
|
collectionList.observe(viewLifecycleOwner, Observer {
|
||||||
if (!goBack2) binding.splashProgress.visibility = View.GONE
|
if (!goBack2) createCollectionList(it.list)
|
||||||
createCollectionList(it.list)
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
goBack2 = false
|
goBack2 = false
|
||||||
})
|
})
|
||||||
|
|
||||||
response.observe(viewLifecycleOwner, Observer {
|
response.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgressTwo.visibility = View.GONE
|
if (goBack) addCollectionToList(it.response.toInt())
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(it.errorMessage, true, false)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
if (goBack) addCollectionToList(it.response.toInt())
|
|
||||||
}
|
|
||||||
goBack = false
|
goBack = false
|
||||||
//sergio:para asegurarnos que aparece en pantalla. En mi movil personal y trabajo no hacia falta.
|
|
||||||
//viewModel.PrecollectionGetSalix(token=getData(TOKEN))
|
|
||||||
})
|
})
|
||||||
responseNew.observe(viewLifecycleOwner, Observer {
|
|
||||||
binding.splashProgressTwo.visibility = View.GONE
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(
|
|
||||||
getString(R.string.errorCollectionNew) + it.errorMessage,
|
|
||||||
true,
|
|
||||||
false
|
|
||||||
)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
//if (goBack)
|
|
||||||
viewModel.sectorCollectionGet()
|
|
||||||
}
|
|
||||||
goBack = false
|
|
||||||
//sergio:para asegurarnos que aparece en pantalla. En mi movil personal y trabajo no hacia falta.
|
|
||||||
//viewModel.PrecollectionGetSalix(token=getData(TOKEN))
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -239,8 +198,7 @@ class InitPreSacadorFragment(
|
||||||
if (isNew) {
|
if (isNew) {
|
||||||
collectionsList.add(
|
collectionsList.add(
|
||||||
CollectionVO(
|
CollectionVO(
|
||||||
collectionFk = collection,
|
collectionFk = collection, created = getString(R.string.newCreated)
|
||||||
created = getString(R.string.newCreated)
|
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
adapter?.notifyDataSetChanged()
|
adapter?.notifyDataSetChanged()
|
||||||
|
|
|
@ -12,8 +12,6 @@ import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
import es.verdnatura.presentation.base.nameofFunction
|
||||||
import es.verdnatura.presentation.common.ResponseItemVO
|
import es.verdnatura.presentation.common.ResponseItemVO
|
||||||
import es.verdnatura.presentation.view.feature.collection.SalixSaleQuantity
|
import es.verdnatura.presentation.view.feature.collection.SalixSaleQuantity
|
||||||
import es.verdnatura.presentation.view.feature.collection.listSaleSalix
|
|
||||||
import es.verdnatura.presentation.view.feature.collection.saleSalix
|
|
||||||
import es.verdnatura.presentation.view.feature.presacador.model.PreSacadorItemVO
|
import es.verdnatura.presentation.view.feature.presacador.model.PreSacadorItemVO
|
||||||
import es.verdnatura.presentation.view.feature.sacador.mapper.toDateFormat
|
import es.verdnatura.presentation.view.feature.sacador.mapper.toDateFormat
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.CollectionListVO
|
import es.verdnatura.presentation.view.feature.sacador.model.CollectionListVO
|
||||||
|
@ -68,13 +66,6 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
val responseIncQuantity: LiveData<ResponseItemVO>
|
val responseIncQuantity: LiveData<ResponseItemVO>
|
||||||
get() = _responseIncQuantity
|
get() = _responseIncQuantity
|
||||||
|
|
||||||
private val _responseSalixMessage by lazy { MutableLiveData<ResponseItemVO>() }
|
|
||||||
val responseSalixMessage: LiveData<ResponseItemVO>
|
|
||||||
get() = _responseSalixMessage
|
|
||||||
|
|
||||||
/* private val _responseMissingTrash by lazy { MutableLiveData<ResponseItemVO>() }
|
|
||||||
val responseMissingTrash: LiveData<ResponseItemVO>
|
|
||||||
get() = _responseMissingTrash*/
|
|
||||||
|
|
||||||
private val _responseItemShelvingUpdate by lazy { MutableLiveData<ResponseItemVO>() }
|
private val _responseItemShelvingUpdate by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
val responseItemShelvingUpdate: LiveData<ResponseItemVO>
|
val responseItemShelvingUpdate: LiveData<ResponseItemVO>
|
||||||
|
@ -89,10 +80,6 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
val collectionList: LiveData<CollectionListVO>
|
val collectionList: LiveData<CollectionListVO>
|
||||||
get() = _collectionList
|
get() = _collectionList
|
||||||
|
|
||||||
private val _responseNew by lazy { MutableLiveData<ResponseItemVO>() }
|
|
||||||
val responseNew: LiveData<ResponseItemVO>
|
|
||||||
get() = _responseNew
|
|
||||||
|
|
||||||
private val _responseSaleGroupAdd by lazy { MutableLiveData<ResponseItemVO>() }
|
private val _responseSaleGroupAdd by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
val responseSaleGroupAdd: LiveData<ResponseItemVO>
|
val responseSaleGroupAdd: LiveData<ResponseItemVO>
|
||||||
get() = _responseSaleGroupAdd
|
get() = _responseSaleGroupAdd
|
||||||
|
@ -106,14 +93,12 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
get() = _responseSaleupdateIsChecked
|
get() = _responseSaleupdateIsChecked
|
||||||
|
|
||||||
fun parking(
|
fun parking(
|
||||||
ticketFk: String,
|
ticketFk: String, parking: String
|
||||||
parking: String
|
|
||||||
) {
|
) {
|
||||||
salix.setParking(arrayListOf(ticketFk, parking).formatWithQuotes())
|
salix.setParking(arrayListOf(ticketFk, parking).formatWithQuotes())
|
||||||
.enqueue(object : SalixCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value =
|
_response.value = ResponseItemVO(isError = false, response = response.message())
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
@ -126,18 +111,13 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemPlacementSupplyAiming(
|
fun itemPlacementSupplyAiming(
|
||||||
shelvingFk: String,
|
shelvingFk: String, quantity: Int, itemFk: Int
|
||||||
quantity: Int,
|
|
||||||
itemFk: Int
|
|
||||||
) {
|
) {
|
||||||
salix.itemPlacementSupplyAiming(
|
salix.itemPlacementSupplyAiming(
|
||||||
arrayListOf(
|
arrayListOf(
|
||||||
shelvingFk,
|
shelvingFk, quantity, itemFk
|
||||||
quantity,
|
|
||||||
itemFk
|
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
).enqueue(object :
|
).enqueue(object : SalixCallback<List<PlacementSupplyVO>>(context) {
|
||||||
SalixCallback<List<PlacementSupplyVO>>(context) {
|
|
||||||
override fun onSuccess(response: Response<List<PlacementSupplyVO>>) {
|
override fun onSuccess(response: Response<List<PlacementSupplyVO>>) {
|
||||||
if (response.body() != null) {
|
if (response.body() != null) {
|
||||||
_placementSuppleyList.value = response.body()?.let { PlacementSupplyListVO(it) }
|
_placementSuppleyList.value = response.body()?.let { PlacementSupplyListVO(it) }
|
||||||
|
@ -148,8 +128,7 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
itemShelvingFk = 0,
|
itemShelvingFk = 0,
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(
|
errorMessage = getMessageFromAllResponse(
|
||||||
nameofFunction(this),
|
nameofFunction(this), response.message()
|
||||||
response.message()
|
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -172,17 +151,13 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemShelvingSaleAdd(
|
fun itemShelvingSaleAdd(
|
||||||
itemShelvingFk: Int,
|
itemShelvingFk: Int, saleFk: Int, quantity: Int
|
||||||
saleFk: Int,
|
|
||||||
quantity: Int
|
|
||||||
) {
|
) {
|
||||||
salix.itemShelvingSaleAdd(
|
salix.itemShelvingSaleAdd(
|
||||||
arrayListOf(
|
arrayListOf(
|
||||||
itemShelvingFk,
|
itemShelvingFk, saleFk, quantity
|
||||||
saleFk,
|
|
||||||
quantity
|
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
||||||
_responseItemShelvingSaleSupplyAdd.value =
|
_responseItemShelvingSaleSupplyAdd.value =
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
ResponseItemVO(isError = false, response = response.message())
|
||||||
|
@ -197,7 +172,7 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun saleTrackingReplace(
|
/* fun saleTrackingReplace(
|
||||||
saleFk: String,
|
saleFk: String,
|
||||||
vOriginalQuantity: String,
|
vOriginalQuantity: String,
|
||||||
vStateFk: String,
|
vStateFk: String,
|
||||||
|
@ -206,11 +181,7 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
) {
|
) {
|
||||||
|
|
||||||
silex.saleTrackingReplace(
|
silex.saleTrackingReplace(
|
||||||
saleFk,
|
saleFk, vOriginalQuantity, vStateFk, vIsChecked, vBuyFk
|
||||||
vOriginalQuantity,
|
|
||||||
vStateFk,
|
|
||||||
vIsChecked,
|
|
||||||
vBuyFk
|
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SilexCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_response.value = ResponseItemVO(
|
_response.value = ResponseItemVO(
|
||||||
|
@ -223,64 +194,58 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
_response.value = ResponseItemVO(isError = false, response = "")
|
_response.value = ResponseItemVO(isError = false, response = "")
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}*/
|
||||||
|
|
||||||
fun getIdFromCode(code: String) {
|
fun getIdFromCode(code: String) {
|
||||||
salix.barcodes_toitem(code)
|
salix.barcodes_toitem(code).enqueue(object : SalixCallback<String?>(context) {
|
||||||
.enqueue(object : SilexCallback<String?>(context) {
|
override fun onError(t: Throwable) {
|
||||||
override fun onError(t: Throwable) {
|
_responseCode.value = ResponseItemVO(
|
||||||
|
isError = true,
|
||||||
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onSuccess(response: Response<String?>) {
|
||||||
|
|
||||||
|
//sergio: espera item en el body
|
||||||
|
if (response.body() == null) {
|
||||||
_responseCode.value = ResponseItemVO(
|
_responseCode.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true, errorMessage = context.getString(R.string.itemNotValid)
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
} else {
|
||||||
|
_responseCode.value =
|
||||||
|
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
||||||
}
|
}
|
||||||
|
}
|
||||||
override fun onSuccess(response: Response<String?>) {
|
})
|
||||||
|
|
||||||
//sergio: espera item en el body
|
|
||||||
if (response.body() == null) {
|
|
||||||
_responseCode.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = context.getString(R.string.itemNotValid)
|
|
||||||
)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
_responseCode.value =
|
|
||||||
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun saleTrackingDel(saleFk: String) {
|
/* fun saleTrackingDel(saleFk: String) {
|
||||||
silex.saleTrackingDel(saleFk)
|
silex.saleTrackingDel(saleFk).enqueue(object : SilexCallback<Any>(context) {
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
override fun onError(t: Throwable) {
|
||||||
override fun onError(t: Throwable) {
|
_response.value = ResponseItemVO(
|
||||||
_response.value = ResponseItemVO(
|
isError = true,
|
||||||
isError = true,
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
)
|
||||||
)
|
}
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
|
|
||||||
_response.value =
|
_response.value = ResponseItemVO(isError = false, response = response.message())
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}*/
|
||||||
|
|
||||||
fun collectionIncreaseQuantity(
|
fun collectionIncreaseQuantity(
|
||||||
saleFk: Int,
|
saleFk: Int, quantity: Int
|
||||||
quantity: Int
|
|
||||||
) {
|
) {
|
||||||
salix.collectionIncreaseQuantitySalix(
|
salix.collectionIncreaseQuantitySalix(
|
||||||
SalixSaleQuantity(
|
SalixSaleQuantity(
|
||||||
saleFk,
|
saleFk, quantity
|
||||||
quantity
|
|
||||||
)
|
)
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseIncQuantity.value = ResponseItemVO(
|
_responseIncQuantity.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
|
@ -297,249 +262,169 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun ticketPrintLabelPrevious(ticketFk: Int) {
|
fun ticketPrintLabelPrevious(ticketFk: Int) {
|
||||||
salix.ticketPrintLabelPrevious(arrayListOf(ticketFk))
|
salix.ticketPrintLabelPrevious(arrayListOf(ticketFk))
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun sectorCollectionGet() {
|
fun sectorCollectionGet() {
|
||||||
salix.sectorCollectionGet(params = null).enqueue(object :
|
salix.sectorCollectionGet(params = null)
|
||||||
SalixCallback<List<CollectionVO>>(context) {
|
.enqueue(object : SalixCallback<List<CollectionVO>>(context) {
|
||||||
override fun onSuccess(response: Response<List<CollectionVO>>) {
|
override fun onSuccess(response: Response<List<CollectionVO>>) {
|
||||||
if (response.body() != null) {
|
|
||||||
_collectionList.value =
|
_collectionList.value =
|
||||||
response.body()?.let { CollectionListVO(it.toDateFormat(context)) }
|
response.body()?.let { CollectionListVO(it.toDateFormat(context)) }
|
||||||
} else {
|
|
||||||
val listError: ArrayList<CollectionVO> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
CollectionVO(
|
|
||||||
0,
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this),
|
|
||||||
response.message()
|
|
||||||
)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_collectionList.value = CollectionListVO(listError)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
}
|
||||||
val listError: ArrayList<CollectionVO> = ArrayList()
|
})
|
||||||
listError.add(
|
|
||||||
CollectionVO(
|
|
||||||
0,
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this),
|
|
||||||
t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_collectionList.value = CollectionListVO(listError)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun sectorCollection_new(
|
fun sectorCollection_new(
|
||||||
sectorFk: Int
|
sectorFk: Int
|
||||||
) {
|
) {
|
||||||
salix.sectorCollectionNew(sectorFk).enqueue(
|
salix.sectorCollectionNew(sectorFk).enqueue(object : SalixCallback<Any>(context) {
|
||||||
object :
|
override fun onSuccess(response: Response<Any>) {
|
||||||
SalixCallback<Any>(context) {
|
_response.value = ResponseItemVO(
|
||||||
override fun onSuccess(response: Response<Any>) {
|
isError = false, errorMessage = "" + getMessageFromAllResponse(
|
||||||
_response.value = ResponseItemVO(
|
nameofFunction(this), response.message()
|
||||||
isError = false,
|
|
||||||
errorMessage = "" + getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), response.message()
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
|
)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
})
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value =
|
|
||||||
ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this),
|
|
||||||
t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun sectorCollection_getSale(
|
fun sectorCollection_getSale(
|
||||||
sectorCollectionFK: Int,
|
sectorCollectionFK: Int, sectorFk: Int
|
||||||
sectorFk: Int
|
|
||||||
) {
|
) {
|
||||||
//Tarea 6276
|
//Tarea 6276
|
||||||
//salix.sectorCollectionGetSale(sectorCollectionFK, sectorFk)
|
//salix.sectorCollectionGetSale(sectorCollectionFK, sectorFk)
|
||||||
silex.sectorCollection_getSale(
|
silex.sectorCollection_getSale(
|
||||||
sectorCollectionFK,
|
sectorCollectionFK, sectorFk.toString()
|
||||||
sectorFk.toString()
|
).enqueue(object : SilexCallback<List<PreSacadorItemVO>>(context) {
|
||||||
)
|
override fun onError(t: Throwable) {
|
||||||
.enqueue(object :
|
_salesList.value = listOf()
|
||||||
SilexCallback<List<PreSacadorItemVO>>(context) {
|
}
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
|
override fun onSuccess(response: Response<List<PreSacadorItemVO>>) {
|
||||||
|
if (response.body() != null) {
|
||||||
|
_salesList.value = response.body()?.let { it }
|
||||||
|
|
||||||
|
} else {
|
||||||
_salesList.value = listOf()
|
_salesList.value = listOf()
|
||||||
}
|
}
|
||||||
|
}
|
||||||
override fun onSuccess(response: Response<List<PreSacadorItemVO>>) {
|
})
|
||||||
if (response.body() != null) {
|
|
||||||
_salesList.value = response.body()?.let { it }
|
|
||||||
|
|
||||||
} else {
|
|
||||||
_salesList.value = listOf()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun sectorCollectionSaleGroupAdd(
|
fun sectorCollectionSaleGroupAdd(
|
||||||
vSaleGroupFk: Int,
|
vSaleGroupFk: Int, vSectorCollectionFk: Int
|
||||||
vSectorCollectionFk: Int
|
|
||||||
) {
|
) {
|
||||||
salix.sectorCollectionSaleGroupAdd(
|
salix.sectorCollectionSaleGroupAdd(
|
||||||
arrayListOf(
|
arrayListOf(
|
||||||
vSaleGroupFk,
|
vSaleGroupFk, vSectorCollectionFk
|
||||||
vSectorCollectionFk
|
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
).enqueue(
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
object :
|
override fun onSuccess(response: Response<Any>) {
|
||||||
SalixCallback<Any>(context) {
|
_responseSaleGroupAdd.value = ResponseItemVO(
|
||||||
override fun onSuccess(response: Response<Any>) {
|
isError = false, errorMessage = "" + getMessageFromAllResponse(
|
||||||
_responseSaleGroupAdd.value = ResponseItemVO(
|
nameofFunction(this), response.message()
|
||||||
isError = false,
|
|
||||||
errorMessage = "" + getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), response.message()
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
}
|
)
|
||||||
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_response.value =
|
_response.value = ResponseItemVO(
|
||||||
ResponseItemVO(
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
isError = true,
|
nameofFunction(this), t.message!!
|
||||||
errorMessage = getMessageFromAllResponse(
|
)
|
||||||
nameofFunction(this),
|
)
|
||||||
t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun saleTrackingAddPrevOK(
|
fun saleTrackingAddPrevOK(
|
||||||
sectorCollectionFk: Int
|
sectorCollectionFk: Int
|
||||||
) {
|
) {
|
||||||
salix.saleTrackingAddPrevOK(arrayListOf(sectorCollectionFk))
|
salix.saleTrackingAddPrevOK(arrayListOf(sectorCollectionFk))
|
||||||
.enqueue(
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
object :
|
override fun onError(t: Throwable) {
|
||||||
SilexCallback<Any>(context) {
|
_responseSaleAddPrevOK.value = ResponseItemVO(
|
||||||
override fun onError(t: Throwable) {
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
_responseSaleAddPrevOK.value =
|
nameofFunction(this), t.message!!
|
||||||
ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this),
|
|
||||||
t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
|
||||||
_responseSaleAddPrevOK.value = ResponseItemVO(
|
|
||||||
isError = false,
|
|
||||||
errorMessage = ""
|
|
||||||
+ getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), response.message()
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
}
|
)
|
||||||
})
|
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onSuccess(response: Response<Any>) {
|
||||||
|
_responseSaleAddPrevOK.value = ResponseItemVO(
|
||||||
|
isError = false, errorMessage = "" + getMessageFromAllResponse(
|
||||||
|
nameofFunction(this), response.message()
|
||||||
|
)
|
||||||
|
)
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun saleTrackingUpdateIsChecked(
|
fun saleTrackingUpdateIsChecked(
|
||||||
vSaleFk: Int,
|
vSaleFk: Int, vIsChecked: Boolean, vIsScanned: Boolean?
|
||||||
vIsChecked: Boolean,
|
|
||||||
vIsScanned: Boolean?
|
|
||||||
) {
|
) {
|
||||||
salix.saleTrackingUpdateIsChecked(
|
salix.saleTrackingUpdateIsChecked(
|
||||||
arrayListOf(
|
arrayListOf(
|
||||||
vSaleFk,
|
vSaleFk, vIsChecked, vIsScanned
|
||||||
vIsChecked,
|
|
||||||
vIsScanned
|
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
)
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
.enqueue(
|
override fun onSuccess(response: Response<Any>) {
|
||||||
object :
|
_responseSaleupdateIsChecked.value = ResponseItemVO(
|
||||||
SalixCallback<Any>(context) {
|
isError = false, errorMessage = "" + getMessageFromAllResponse(
|
||||||
override fun onSuccess(response: Response<Any>) {
|
nameofFunction(this), response.message()
|
||||||
_responseSaleupdateIsChecked.value = ResponseItemVO(
|
)
|
||||||
isError = false,
|
)
|
||||||
errorMessage = ""
|
}
|
||||||
+ getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), response.message()
|
|
||||||
)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseSaleupdateIsChecked.value =
|
_responseSaleupdateIsChecked.value = ResponseItemVO(
|
||||||
ResponseItemVO(
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
isError = true,
|
nameofFunction(this), t.message!!
|
||||||
errorMessage = getMessageFromAllResponse(
|
)
|
||||||
nameofFunction(this),
|
)
|
||||||
t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemShelving_updateFromSale(
|
fun itemShelving_updateFromSale(
|
||||||
saleFk: Int
|
saleFk: Int
|
||||||
) {
|
) {
|
||||||
|
//Tarea 6276 pasar a Salix
|
||||||
|
//salix.itemShelvingUpdateFromSale(saleFk). Revisar si ok
|
||||||
|
|
||||||
silex.itemShelving_updateFromSale(
|
silex.itemShelving_updateFromSale(
|
||||||
saleFk
|
saleFk
|
||||||
)
|
).enqueue(object : SilexCallback<Any>(context) {
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
override fun onError(t: Throwable) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
|
|
||||||
_responseItemShelvingUpdate.value = ResponseItemVO(
|
_responseItemShelvingUpdate.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
errorMessage = getMessageFromAllResponse(
|
nameofFunction(this), t.message!!
|
||||||
nameofFunction(this),
|
|
||||||
t.message!!
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
}
|
)
|
||||||
|
}
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responseItemShelvingUpdate.value =
|
_responseItemShelvingUpdate.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun transferSalesSalix(
|
/* fun transferSalesSalix(
|
||||||
ticketFk: String,
|
ticketFk: String,
|
||||||
saleFk: Int,
|
saleFk: Int,
|
||||||
quantity: String,
|
quantity: String,
|
||||||
|
@ -553,10 +438,8 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SilexCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseSplit.value = ResponseItemVO(
|
_responseSplit.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
errorMessage = getMessageFromAllResponse(
|
nameofFunction(this), t.message!!
|
||||||
nameofFunction(this),
|
|
||||||
t.message!!
|
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -565,10 +448,8 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
//segio: salix devuelve id
|
//segio: salix devuelve id
|
||||||
if (response.body() == null) {
|
if (response.body() == null) {
|
||||||
_responseSplit.value = ResponseItemVO(
|
_responseSplit.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
errorMessage = getMessageFromAllResponse(
|
nameofFunction(this), response.message()
|
||||||
nameofFunction(this),
|
|
||||||
response.message()
|
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
|
@ -577,6 +458,6 @@ class PreSacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}*/
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
package es.verdnatura.presentation.view.feature.qr
|
package es.verdnatura.presentation.view.feature.qr
|
||||||
|
|
||||||
|
|
||||||
import android.view.View
|
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
import androidx.lifecycle.Observer
|
import androidx.lifecycle.Observer
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
|
@ -27,9 +26,7 @@ class QrFragment(
|
||||||
|
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
customDialog = CustomDialog(requireContext())
|
customDialog = CustomDialog(requireContext())
|
||||||
|
|
||||||
setToolbar()
|
setToolbar()
|
||||||
setEvents()
|
setEvents()
|
||||||
super.init()
|
super.init()
|
||||||
|
@ -60,8 +57,7 @@ class QrFragment(
|
||||||
|
|
||||||
goBack = false
|
goBack = false
|
||||||
if (!binding.scanInput.text.isNullOrEmpty()) {
|
if (!binding.scanInput.text.isNullOrEmpty()) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
/* viewModel.qr_getCall(
|
||||||
/*viewModel.qr_getCall(
|
|
||||||
binding.scanInput.text.toString()
|
binding.scanInput.text.toString()
|
||||||
)*/
|
)*/
|
||||||
itemscaned = binding.scanInput.text.toString()
|
itemscaned = binding.scanInput.text.toString()
|
||||||
|
@ -79,7 +75,7 @@ class QrFragment(
|
||||||
|
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
qrresponse.observe(viewLifecycleOwner, Observer {
|
qrresponse.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
|
|
||||||
ma.messageWithSound(it.errorMessage + " " + itemscaned, true, false)
|
ma.messageWithSound(it.errorMessage + " " + itemscaned, true, false)
|
||||||
|
|
|
@ -12,7 +12,6 @@ import es.verdnatura.presentation.common.OnCollectionSelectedListener
|
||||||
import es.verdnatura.presentation.view.feature.reubication.model.Reubication
|
import es.verdnatura.presentation.view.feature.reubication.model.Reubication
|
||||||
import es.verdnatura.presentation.view.feature.ubicador.fragment.UbicadorViewModel
|
import es.verdnatura.presentation.view.feature.ubicador.fragment.UbicadorViewModel
|
||||||
|
|
||||||
//Tarea #3754
|
|
||||||
class ReubicationFragment(var entrypoint: String) :
|
class ReubicationFragment(var entrypoint: String) :
|
||||||
BaseFragment<FragmentGeneralBlackBinding, UbicadorViewModel>(
|
BaseFragment<FragmentGeneralBlackBinding, UbicadorViewModel>(
|
||||||
UbicadorViewModel::class
|
UbicadorViewModel::class
|
||||||
|
@ -35,7 +34,6 @@ class ReubicationFragment(var entrypoint: String) :
|
||||||
override fun init() {
|
override fun init() {
|
||||||
|
|
||||||
binding.mainToolbar.toolbarTitle.text = entrypoint
|
binding.mainToolbar.toolbarTitle.text = entrypoint
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
binding.scanInput.visibility = VISIBLE
|
binding.scanInput.visibility = VISIBLE
|
||||||
setEvents()
|
setEvents()
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,6 @@ import es.verdnatura.presentation.view.component.CustomDialogInput
|
||||||
import es.verdnatura.presentation.view.feature.sacador.adapter.CollectionAdapter
|
import es.verdnatura.presentation.view.feature.sacador.adapter.CollectionAdapter
|
||||||
import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
import es.verdnatura.presentation.view.feature.sacador.model.CollectionVO
|
||||||
|
|
||||||
|
|
||||||
class SacadorFragment(
|
class SacadorFragment(
|
||||||
var type: String
|
var type: String
|
||||||
) :
|
) :
|
||||||
|
@ -36,7 +35,6 @@ class SacadorFragment(
|
||||||
private var collectionsList: ArrayList<CollectionVO> = ArrayList()
|
private var collectionsList: ArrayList<CollectionVO> = ArrayList()
|
||||||
private var adapter: CollectionAdapter? = null
|
private var adapter: CollectionAdapter? = null
|
||||||
|
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun newInstance(type: String) = SacadorFragment(type)
|
fun newInstance(type: String) = SacadorFragment(type)
|
||||||
}
|
}
|
||||||
|
@ -59,7 +57,7 @@ class SacadorFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun callBack(type: String) {
|
private fun callBack(type: String) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
when (type) {
|
when (type) {
|
||||||
"PREPARED" -> {
|
"PREPARED" -> {
|
||||||
viewModel.collectionGetSalix()
|
viewModel.collectionGetSalix()
|
||||||
|
@ -70,7 +68,7 @@ class SacadorFragment(
|
||||||
}
|
}
|
||||||
|
|
||||||
else -> {
|
else -> {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -165,7 +163,6 @@ class SacadorFragment(
|
||||||
false
|
false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun printAction() {
|
private fun printAction() {
|
||||||
|
@ -197,23 +194,17 @@ class SacadorFragment(
|
||||||
override fun observeViewModel() {
|
override fun observeViewModel() {
|
||||||
|
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
collectionList.observe(viewLifecycleOwner, Observer {
|
collectionList.observe(viewLifecycleOwner, Observer {
|
||||||
if (!goBack2) binding.splashProgress.visibility = View.GONE
|
if (!goBack2) binding.splashProgress.visibility = View.GONE
|
||||||
createCollectionList(it.list)
|
createCollectionList(it.list)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
goBack2 = false
|
goBack2 = false
|
||||||
})
|
})
|
||||||
|
|
||||||
response.observe(viewLifecycleOwner, Observer {
|
response.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
binding.splashProgress.visibility = View.GONE
|
||||||
if (it.isError) {
|
if (goBack) {
|
||||||
ma.messageWithSound(it.errorMessage, true, false)
|
if (!it.response.isNullOrBlank()) addCollectionToList(it.response.toInt())
|
||||||
|
|
||||||
} else {
|
|
||||||
if (goBack) {
|
|
||||||
if (!it.response.isNullOrBlank()) addCollectionToList(it.response.toInt())
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
goBack = false
|
goBack = false
|
||||||
callBack(type)
|
callBack(type)
|
||||||
|
|
|
@ -51,6 +51,8 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
print: String,
|
print: String,
|
||||||
type: String
|
type: String
|
||||||
) {
|
) {
|
||||||
|
|
||||||
|
//Tarea 6276, falta modificar
|
||||||
silex.collection_getTickets(
|
silex.collection_getTickets(
|
||||||
collectionFk,
|
collectionFk,
|
||||||
sectorFk,
|
sectorFk,
|
||||||
|
@ -123,13 +125,6 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -139,36 +134,24 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
//salix.collectionAssign()
|
//salix.collectionAssign()
|
||||||
silex.collection_assign()
|
silex.collection_assign()
|
||||||
.enqueue(
|
.enqueue(
|
||||||
object :
|
object :
|
||||||
SilexCallback<Int>(context) {
|
SilexCallback<Int>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(
|
ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(
|
errorMessage = getMessageFromAllResponse(
|
||||||
nameofFunction(this),
|
nameofFunction(this),
|
||||||
t.message!!
|
t.message!!
|
||||||
|
)
|
||||||
)
|
)
|
||||||
)
|
}
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Int>) {
|
override fun onSuccess(response: Response<Int>) {
|
||||||
if (response.body() != null) {
|
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
||||||
} else {
|
|
||||||
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this),
|
|
||||||
response.message()
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun collection_assignNew() {
|
fun collection_assignNew() {
|
||||||
|
@ -282,7 +265,7 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun sectorCollectionGet() {
|
fun sectorCollectionGet() {
|
||||||
salix.sectorCollectionGet().enqueue(object :
|
salix.sectorCollectionGet().enqueue(object :
|
||||||
SilexCallback<List<CollectionVO>>(context) {
|
SalixCallback<List<CollectionVO>>(context) {
|
||||||
override fun onSuccess(response: Response<List<CollectionVO>>) {
|
override fun onSuccess(response: Response<List<CollectionVO>>) {
|
||||||
|
|
||||||
if (response.body() != null) {
|
if (response.body() != null) {
|
||||||
|
@ -304,6 +287,7 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
val listError: ArrayList<CollectionVO> = ArrayList()
|
val listError: ArrayList<CollectionVO> = ArrayList()
|
||||||
listError.add(
|
listError.add(
|
||||||
|
@ -323,39 +307,10 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun collectionGetSalix() {
|
fun collectionGetSalix() {
|
||||||
salix.getCollectionSalix().enqueue(object :
|
salix.getCollectionSalix().enqueue(object :
|
||||||
SilexCallback<List<CollectionVO>>(context) {
|
SalixCallback<List<CollectionVO>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
val listError: ArrayList<CollectionVO> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
CollectionVO(
|
|
||||||
0,
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_collectionList.value = CollectionListVO(listError)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<List<CollectionVO>>) {
|
override fun onSuccess(response: Response<List<CollectionVO>>) {
|
||||||
|
_collectionList.value =
|
||||||
if (response.body() != null) {
|
response.body()?.let { CollectionListVO(it.toDateFormat(context)) }
|
||||||
_collectionList.value =
|
|
||||||
response.body()?.let { CollectionListVO(it.toDateFormat(context)) }
|
|
||||||
} else {
|
|
||||||
val listError: ArrayList<CollectionVO> = ArrayList()
|
|
||||||
listError.add(
|
|
||||||
CollectionVO(
|
|
||||||
0,
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this),
|
|
||||||
response.message()
|
|
||||||
)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
_collectionList.value = CollectionListVO(listError)
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
|
@ -363,7 +318,7 @@ class SacadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun collectionGetSalixLocal() {
|
fun collectionGetSalixLocal() {
|
||||||
salix.getCollectionSalixLocal().enqueue(object :
|
salix.getCollectionSalixLocal().enqueue(object :
|
||||||
SilexCallback<List<CollectionTicket>>(context) {
|
SalixCallback<List<CollectionTicket>>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
val listError: ArrayList<CollectionTicket> = ArrayList()
|
val listError: ArrayList<CollectionTicket> = ArrayList()
|
||||||
listError.add(
|
listError.add(
|
||||||
|
|
|
@ -39,8 +39,6 @@ class ShowTicketFragment(var menuOrigin: String) :
|
||||||
binding.scanInput.visibility = View.VISIBLE
|
binding.scanInput.visibility = View.VISIBLE
|
||||||
binding.mainToolbar.toolbarTitle.text = getString(R.string.verticket)
|
binding.mainToolbar.toolbarTitle.text = getString(R.string.verticket)
|
||||||
ma.hideBottomNavigation(View.VISIBLE)
|
ma.hideBottomNavigation(View.VISIBLE)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
if (menuOrigin == getString(R.string.main)) {
|
if (menuOrigin == getString(R.string.main)) {
|
||||||
hideBackButton(binding.mainToolbar)
|
hideBackButton(binding.mainToolbar)
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,13 +1,11 @@
|
||||||
package es.verdnatura.presentation.view.feature.ticket.fragment
|
package es.verdnatura.presentation.view.feature.ticket.fragment
|
||||||
|
|
||||||
import android.view.View.GONE
|
|
||||||
import android.view.View.VISIBLE
|
import android.view.View.VISIBLE
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
import es.verdnatura.databinding.FragmentGeneralBlackBinding
|
import es.verdnatura.databinding.FragmentGeneralBlackBinding
|
||||||
import es.verdnatura.presentation.base.BaseFragment
|
import es.verdnatura.presentation.base.BaseFragment
|
||||||
|
|
||||||
|
|
||||||
class TicketAdvanceFragment(var title: String) :
|
class TicketAdvanceFragment(var title: String) :
|
||||||
BaseFragment<FragmentGeneralBlackBinding, TicketViewModel>(
|
BaseFragment<FragmentGeneralBlackBinding, TicketViewModel>(
|
||||||
TicketViewModel::class
|
TicketViewModel::class
|
||||||
|
@ -24,13 +22,11 @@ class TicketAdvanceFragment(var title: String) :
|
||||||
binding.scanInput.visibility = VISIBLE
|
binding.scanInput.visibility = VISIBLE
|
||||||
binding.scanInput.hint = getString(R.string.scanLabelTicket)
|
binding.scanInput.hint = getString(R.string.scanLabelTicket)
|
||||||
binding.mainToolbar.toolbarTitle.text = title
|
binding.mainToolbar.toolbarTitle.text = title
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
|
|
||||||
setEvents()
|
setEvents()
|
||||||
super.init()
|
super.init()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private fun setEvents() {
|
private fun setEvents() {
|
||||||
|
|
||||||
binding.mainToolbar.backButton.setOnClickListener {
|
binding.mainToolbar.backButton.setOnClickListener {
|
||||||
|
@ -41,10 +37,9 @@ class TicketAdvanceFragment(var title: String) :
|
||||||
binding.scanInput.setOnEditorActionListener { v, actionId, event ->
|
binding.scanInput.setOnEditorActionListener { v, actionId, event ->
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
||||||
if (!binding.scanInput.text.isNullOrEmpty()) {
|
if (!binding.scanInput.text.isNullOrEmpty()) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
viewModel.ticket_advancePackaging(
|
viewModel.ticketAdvancePackaging(
|
||||||
binding.scanInput.text.toString().toInt(),
|
binding.scanInput.text.toString().toInt(),
|
||||||
mobileApplication.userId!!
|
mobileApplication.userId!!
|
||||||
)
|
)
|
||||||
|
@ -61,24 +56,5 @@ class TicketAdvanceFragment(var title: String) :
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun observeViewModel() {
|
|
||||||
with(viewModel) {
|
|
||||||
|
|
||||||
response.observe(viewLifecycleOwner) {
|
|
||||||
|
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
ma.messageWithSound(
|
|
||||||
if (it.isError) {
|
|
||||||
it.errorMessage
|
|
||||||
} else {
|
|
||||||
getString(R.string.ticketAdvancePagkaging)
|
|
||||||
}, it.isError, true, isToasted = true
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,47 +1,18 @@
|
||||||
package es.verdnatura.presentation.view.feature.ticket.fragment
|
package es.verdnatura.presentation.view.feature.ticket.fragment
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import androidx.lifecycle.LiveData
|
import es.verdnatura.domain.SalixCallback
|
||||||
import androidx.lifecycle.MutableLiveData
|
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
|
||||||
import es.verdnatura.presentation.common.ResponseItemVO
|
|
||||||
import es.verdnatura.presentation.common.packingSiteSalix
|
import es.verdnatura.presentation.common.packingSiteSalix
|
||||||
import retrofit2.Response
|
|
||||||
|
|
||||||
class TicketViewModel(val context: Context) : BaseViewModel(context) {
|
class TicketViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
|
fun ticketAdvancePackaging(
|
||||||
private val _response by lazy { MutableLiveData<ResponseItemVO>() }
|
ticketFk: Int, workerFk: Int
|
||||||
val response: LiveData<ResponseItemVO>
|
|
||||||
get() = _response
|
|
||||||
|
|
||||||
|
|
||||||
fun ticket_advancePackaging(
|
|
||||||
ticketFk: Int,
|
|
||||||
workerFk: Int
|
|
||||||
|
|
||||||
) {
|
) {
|
||||||
|
|
||||||
salix.ticket_advancePackaging(packingSiteSalix(ticketFk, workerFk))
|
salix.ticket_advancePackaging(packingSiteSalix(ticketFk, workerFk))
|
||||||
.enqueue(object : SilexCallback<Unit>(context) {
|
.enqueue(object : SalixCallback<Unit>(context) {})
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
|
||||||
_response.value =
|
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
package es.verdnatura.presentation.view.feature.transferencia.fragment
|
|
||||||
|
|
||||||
import es.verdnatura.R
|
|
||||||
import es.verdnatura.databinding.FragmentTransferenciaBinding
|
|
||||||
import es.verdnatura.presentation.base.BaseFragment
|
|
||||||
|
|
||||||
class TransferenciaFragment : BaseFragment<FragmentTransferenciaBinding,TransferenciaViewModel>(TransferenciaViewModel::class) {
|
|
||||||
|
|
||||||
companion object {
|
|
||||||
fun newInstance() = TransferenciaFragment()
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun getLayoutId(): Int = R.layout.fragment_transferencia
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,29 +0,0 @@
|
||||||
package es.verdnatura.presentation.view.feature.transferencia.fragment
|
|
||||||
|
|
||||||
import android.content.Context
|
|
||||||
import androidx.lifecycle.LiveData
|
|
||||||
import androidx.lifecycle.MutableLiveData
|
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
|
||||||
import es.verdnatura.presentation.common.ResponseItemVO
|
|
||||||
|
|
||||||
class TransferenciaViewModel(context: Context) : BaseViewModel(context) {
|
|
||||||
private val _response by lazy { MutableLiveData<ResponseItemVO>() }
|
|
||||||
val response: LiveData<ResponseItemVO>
|
|
||||||
get() = _response
|
|
||||||
|
|
||||||
/* fun itemShelvingTransfer(usuario:String,password:String,itemFk:String,shelvingFk:String){
|
|
||||||
getUbicadorUserCase.itemShelvingTransfer(usuario,password,itemFk,shelvingFk).enqueue(object :
|
|
||||||
Callback<Any> {
|
|
||||||
override fun onFailure(call: Call<Any>, t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(isError = true,errorMessage ="Error en llamada itemShelvingTransfer."+t.message!!)
|
|
||||||
}
|
|
||||||
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
|
||||||
if (!response.isSuccessul == null){
|
|
||||||
_response.value = ResponseItemVO(isError = true,errorMessage = "Error en la llamada itemShelvingTransfer")
|
|
||||||
}else{
|
|
||||||
_response.value = ResponseItemVO(isError = false,response = response.message()!!)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}*/
|
|
||||||
}
|
|
|
@ -106,7 +106,6 @@ class AutomaticAddItemFragment(
|
||||||
listString.add(it.item)
|
listString.add(it.item)
|
||||||
listInt.add(it.item)
|
listInt.add(it.item)
|
||||||
}
|
}
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
|
|
||||||
if (binding.mainToolbar.toolbarTitle.text.equals(getString(R.string.titleChecker))) {
|
if (binding.mainToolbar.toolbarTitle.text.equals(getString(R.string.titleChecker))) {
|
||||||
|
|
||||||
|
@ -133,12 +132,8 @@ class AutomaticAddItemFragment(
|
||||||
override fun observeViewModel() {
|
override fun observeViewModel() {
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
response.observe(viewLifecycleOwner, Observer {
|
response.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(it.errorMessage, true, false)
|
|
||||||
} else {
|
|
||||||
requireActivity().onBackPressed()
|
requireActivity().onBackPressed()
|
||||||
}
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,8 +14,8 @@ import java.lang.Boolean.TRUE
|
||||||
|
|
||||||
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
||||||
class AutomaticAddItemFragmentTEST(
|
class AutomaticAddItemFragmentTEST(
|
||||||
var shelvingFk: String = "",
|
private var shelvingFk: String = "",
|
||||||
var titleAction: String? = null
|
private var titleAction: String? = null
|
||||||
) : BaseFragment<FragmentAutomaticAddItemBinding, AutomaticAddItemViewModel>(
|
) : BaseFragment<FragmentAutomaticAddItemBinding, AutomaticAddItemViewModel>(
|
||||||
AutomaticAddItemViewModel::class
|
AutomaticAddItemViewModel::class
|
||||||
) {
|
) {
|
||||||
|
@ -108,7 +108,7 @@ class AutomaticAddItemFragmentTEST(
|
||||||
listString.add(it)
|
listString.add(it)
|
||||||
listInt.add(it)
|
listInt.add(it)
|
||||||
}
|
}
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
|
|
||||||
if (binding.mainToolbar.toolbarTitle.text.equals(getString(R.string.titleChecker))) {
|
if (binding.mainToolbar.toolbarTitle.text.equals(getString(R.string.titleChecker))) {
|
||||||
|
|
||||||
|
@ -136,12 +136,7 @@ class AutomaticAddItemFragmentTEST(
|
||||||
override fun observeViewModel() {
|
override fun observeViewModel() {
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
response.observe(viewLifecycleOwner, Observer {
|
response.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(it.errorMessage, true, false)
|
|
||||||
} else {
|
|
||||||
requireActivity().onBackPressed()
|
requireActivity().onBackPressed()
|
||||||
}
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,6 @@ import android.content.Context
|
||||||
import androidx.lifecycle.LiveData
|
import androidx.lifecycle.LiveData
|
||||||
import androidx.lifecycle.MutableLiveData
|
import androidx.lifecycle.MutableLiveData
|
||||||
import es.verdnatura.domain.SalixCallback
|
import es.verdnatura.domain.SalixCallback
|
||||||
import es.verdnatura.domain.SilexCallback
|
|
||||||
import es.verdnatura.domain.formatWithQuotes
|
import es.verdnatura.domain.formatWithQuotes
|
||||||
import es.verdnatura.presentation.base.BaseViewModel
|
import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
|
@ -27,7 +26,7 @@ class AutomaticAddItemViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
//salix.itemShelvingMakeMulti(MakeMultiSalix(shelvingFk,items,warehouseFk))
|
//salix.itemShelvingMakeMulti(MakeMultiSalix(shelvingFk,items,warehouseFk))
|
||||||
silex.itemShelvingMake_multi(shelvingFk, items, warehouseFk)
|
silex.itemShelvingMake_multi(shelvingFk, items, warehouseFk)
|
||||||
.enqueue(object :
|
.enqueue(object :
|
||||||
SilexCallback<Any>(context) {
|
SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_response.value = ResponseItemVO(
|
_response.value = ResponseItemVO(
|
||||||
isError = true, errorMessage = getMessageFromAllResponse(
|
isError = true, errorMessage = getMessageFromAllResponse(
|
||||||
|
|
|
@ -7,7 +7,6 @@ import android.media.MediaPlayer
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.text.InputType
|
import android.text.InputType
|
||||||
import android.view.View
|
|
||||||
import android.view.View.GONE
|
import android.view.View.GONE
|
||||||
import android.view.View.VISIBLE
|
import android.view.View.VISIBLE
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
|
@ -31,7 +30,6 @@ import es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorVO
|
||||||
import java.lang.Boolean.TRUE
|
import java.lang.Boolean.TRUE
|
||||||
import kotlin.math.roundToInt
|
import kotlin.math.roundToInt
|
||||||
|
|
||||||
|
|
||||||
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
||||||
class UbicadorFragment(
|
class UbicadorFragment(
|
||||||
var shelvingFk: String = "",
|
var shelvingFk: String = "",
|
||||||
|
@ -59,7 +57,6 @@ class UbicadorFragment(
|
||||||
var mpok: MediaPlayer? = null
|
var mpok: MediaPlayer? = null
|
||||||
var isBack = false
|
var isBack = false
|
||||||
|
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun newInstance(entryPoint: String, autoSelf: Boolean = false) =
|
fun newInstance(entryPoint: String, autoSelf: Boolean = false) =
|
||||||
UbicadorFragment(entryPoint, autoSelf)
|
UbicadorFragment(entryPoint, autoSelf)
|
||||||
|
@ -94,7 +91,6 @@ class UbicadorFragment(
|
||||||
setToolBar()
|
setToolBar()
|
||||||
if (!shelvingFk.isNullOrEmpty()) {
|
if (!shelvingFk.isNullOrEmpty()) {
|
||||||
isShelvinLogfromMainScreen = false
|
isShelvinLogfromMainScreen = false
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
binding.mainToolbar.toolbarTitle.text = shelvingFk
|
binding.mainToolbar.toolbarTitle.text = shelvingFk
|
||||||
viewModel.itemShelvingList(shelvingFk)
|
viewModel.itemShelvingList(shelvingFk)
|
||||||
} else {
|
} else {
|
||||||
|
@ -123,7 +119,6 @@ class UbicadorFragment(
|
||||||
val iconReset = ImageView(context)
|
val iconReset = ImageView(context)
|
||||||
iconReset.setImageResource(R.drawable.ic_remove_checks)
|
iconReset.setImageResource(R.drawable.ic_remove_checks)
|
||||||
|
|
||||||
//Tarea#5052
|
|
||||||
binding.mainToolbar.switchButton.visibility = VISIBLE
|
binding.mainToolbar.switchButton.visibility = VISIBLE
|
||||||
binding.mainToolbar.switchButton.setOnCheckedChangeListener { buttonView, isChecked ->
|
binding.mainToolbar.switchButton.setOnCheckedChangeListener { buttonView, isChecked ->
|
||||||
if (binding.mainToolbar.toolbarTitle.text == getString(R.string.titleUbicator)) {
|
if (binding.mainToolbar.toolbarTitle.text == getString(R.string.titleUbicator)) {
|
||||||
|
@ -143,7 +138,7 @@ class UbicadorFragment(
|
||||||
if (!isChecked) {
|
if (!isChecked) {
|
||||||
listLocalItems.clear()
|
listLocalItems.clear()
|
||||||
listIcons.remove(iconReset)
|
listIcons.remove(iconReset)
|
||||||
}else{
|
} else {
|
||||||
listIcons.add(iconReset)
|
listIcons.add(iconReset)
|
||||||
}
|
}
|
||||||
binding.mainToolbar.toolbarIcons.adapter!!.notifyDataSetChanged()
|
binding.mainToolbar.toolbarIcons.adapter!!.notifyDataSetChanged()
|
||||||
|
@ -180,7 +175,6 @@ class UbicadorFragment(
|
||||||
|
|
||||||
if (!shelvingFk.isNullOrEmpty()) {
|
if (!shelvingFk.isNullOrEmpty()) {
|
||||||
binding.editPrioridad.setText("")
|
binding.editPrioridad.setText("")
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingList(
|
viewModel.itemShelvingList(
|
||||||
shelvingFk
|
shelvingFk
|
||||||
)
|
)
|
||||||
|
@ -192,14 +186,12 @@ class UbicadorFragment(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
iconReset.drawable -> {
|
iconReset.drawable -> {
|
||||||
if (!shelvingFk.isNullOrBlank()) {
|
if (!shelvingFk.isNullOrBlank()) {
|
||||||
customDialog.setTitle(getString(R.string.checkItemShelvingDescrip))
|
customDialog.setTitle(getString(R.string.checkItemShelvingDescrip))
|
||||||
.setDescription(getString(R.string.checkItemShelving))
|
.setDescription(getString(R.string.checkItemShelving))
|
||||||
.setOkButton(getString(R.string.ok)) {
|
.setOkButton(getString(R.string.ok)) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
viewModel.itemShelvingDeleteChecked(shelvingFk)
|
||||||
viewModel.itemShelving_deleteChecked(shelvingFk)
|
|
||||||
customDialog.dismiss()
|
customDialog.dismiss()
|
||||||
}
|
}
|
||||||
.setKoButton(getString(R.string.cancel)) {
|
.setKoButton(getString(R.string.cancel)) {
|
||||||
|
@ -237,22 +229,18 @@ class UbicadorFragment(
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
||||||
if (!binding.editMatricula.text.toString().isNullOrEmpty()) {
|
if (!binding.editMatricula.text.toString().isNullOrEmpty()) {
|
||||||
|
|
||||||
|
|
||||||
/*Tarea 5336 */
|
|
||||||
if (!modeCheckUbication || (modeCheckUbication && binding.editMatricula.text.toString().length == 3 && !binding.editMatricula.text!![0].isDigit())) {
|
if (!modeCheckUbication || (modeCheckUbication && binding.editMatricula.text.toString().length == 3 && !binding.editMatricula.text!![0].isDigit())) {
|
||||||
binding.mainToolbar.toolbarTitle.text =
|
binding.mainToolbar.toolbarTitle.text =
|
||||||
binding.editMatricula.text.toString()
|
binding.editMatricula.text.toString()
|
||||||
shelvingFk = binding.editMatricula.text.toString()
|
shelvingFk = binding.editMatricula.text.toString()
|
||||||
parking = ""
|
parking = ""
|
||||||
binding.editPrioridad.setText("")
|
binding.editPrioridad.setText("")
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
isShelvinLogfromMainScreen = true
|
isShelvinLogfromMainScreen = true
|
||||||
viewModel.itemShelvingList(
|
viewModel.itemShelvingList(
|
||||||
binding.editMatricula.text.toString()
|
binding.editMatricula.text.toString()
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
try {
|
try {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.getIdFromCode(
|
viewModel.getIdFromCode(
|
||||||
code = itemScanValue(
|
code = itemScanValue(
|
||||||
binding.editMatricula.text.toString(),
|
binding.editMatricula.text.toString(),
|
||||||
|
@ -260,8 +248,8 @@ class UbicadorFragment(
|
||||||
"more"
|
"more"
|
||||||
).toString()
|
).toString()
|
||||||
)
|
)
|
||||||
} catch (Ex: Exception) {
|
} catch (ex: Exception) {
|
||||||
ma.messageWithSound(Ex.message.toString(), true, true)
|
ma.messageWithSound(ex.message.toString(), true, true)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -277,11 +265,11 @@ class UbicadorFragment(
|
||||||
binding.editPrioridad.setOnEditorActionListener { v, actionId, event ->
|
binding.editPrioridad.setOnEditorActionListener { v, actionId, event ->
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
||||||
if (!binding.editPrioridad.text.toString().isNullOrEmpty()) {
|
if (!binding.editPrioridad.text.toString().isNullOrEmpty()) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.shelvingPriorityUpdate(
|
viewModel.shelvingPriorityUpdate(
|
||||||
binding.editPrioridad.toInt(),
|
binding.editPrioridad.toInt(),
|
||||||
shelvingFk
|
shelvingFk
|
||||||
)
|
)
|
||||||
|
isBack = false
|
||||||
|
|
||||||
}
|
}
|
||||||
ma.hideKeyboard(binding.editPrioridad)
|
ma.hideKeyboard(binding.editPrioridad)
|
||||||
|
@ -297,7 +285,6 @@ class UbicadorFragment(
|
||||||
|
|
||||||
ma.onPasillerosItemClickListener(
|
ma.onPasillerosItemClickListener(
|
||||||
PasillerosItemVO(title = getString(R.string.titleAuto)),
|
PasillerosItemVO(title = getString(R.string.titleAuto)),
|
||||||
//PasillerosItemVO(title = getString(R.string.titleChecker)),
|
|
||||||
entryPoint = shelvingFk
|
entryPoint = shelvingFk
|
||||||
)
|
)
|
||||||
else
|
else
|
||||||
|
@ -369,7 +356,7 @@ class UbicadorFragment(
|
||||||
|
|
||||||
customDialogInput.getEditText()
|
customDialogInput.getEditText()
|
||||||
.setOnEditorActionListener { v, actionId, event ->
|
.setOnEditorActionListener { v, actionId, event ->
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 ) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0) {
|
||||||
customDialogActionChange()
|
customDialogActionChange()
|
||||||
return@setOnEditorActionListener true
|
return@setOnEditorActionListener true
|
||||||
}
|
}
|
||||||
|
@ -473,7 +460,6 @@ class UbicadorFragment(
|
||||||
binding.automaticImg.tooltipText =
|
binding.automaticImg.tooltipText =
|
||||||
getTooltip(R.drawable.ic_flash_auto_black_24dp)
|
getTooltip(R.drawable.ic_flash_auto_black_24dp)
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -486,147 +472,120 @@ class UbicadorFragment(
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
|
|
||||||
deep = it.list.size
|
deep = it.list.size
|
||||||
if (it.list.isNotEmpty() && it.list.get(0).isError) {
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
listItems = ArrayList()
|
||||||
ma.messageWithSound(
|
var contEtiquetas = 0
|
||||||
it.list.get(0).errorMessage,
|
it.list.forEach { item ->
|
||||||
it.list.get(0).isError,
|
try {
|
||||||
isPlayed = false
|
contEtiquetas += item.stickers.toInt()
|
||||||
|
parking = item.code
|
||||||
|
|
||||||
|
} catch (ex: Exception) {
|
||||||
|
ex.message!!.toast(requireContext())
|
||||||
|
}
|
||||||
|
|
||||||
|
listItems.add(item)
|
||||||
|
|
||||||
|
}
|
||||||
|
etiquetas = contEtiquetas.toString()
|
||||||
|
binding.mainToolbar.toolbarTitle.text =
|
||||||
|
shelvingFk.uppercase() + getString(R.string.pUppercase) + parking + getString(
|
||||||
|
R.string.label
|
||||||
|
) + etiquetas
|
||||||
|
if (it.list.size > 0)
|
||||||
|
binding.editPrioridad.setText(it.list[0].priority)
|
||||||
|
|
||||||
|
for (item in listItems) {
|
||||||
|
for (localItem in listLocalItems) {
|
||||||
|
if (item.item == localItem.item) {
|
||||||
|
item.isNew = localItem.isNew
|
||||||
|
item.checked = localItem.checked
|
||||||
|
if (item.isNew && item.visible != "0") {
|
||||||
|
item.isNew = false
|
||||||
|
item.checked = true
|
||||||
|
}
|
||||||
|
|
||||||
|
binding.locationRecyclerview.postInvalidate()
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!binding.mainToolbar.switchButton.isChecked && listItems.isNotEmpty()) {
|
||||||
|
|
||||||
|
listItems = listItems.asReversed()
|
||||||
|
|
||||||
|
}
|
||||||
|
adapter = UbicadorAdapter(
|
||||||
|
listItems.sortedBy { it.isChecked },
|
||||||
|
onPasillerosItemClickListener = pasillerosItemClickListener!!,
|
||||||
|
onVisibleClickListener = object : OnVisibleClickListener {
|
||||||
|
override fun onVisibleClickListener(item: ItemUbicadorVO) {
|
||||||
|
|
||||||
|
if (!isAutoSelf) {
|
||||||
|
showAddItem(
|
||||||
|
item.item.toString(),
|
||||||
|
item.packing,
|
||||||
|
item.stickers,
|
||||||
|
item.visible,
|
||||||
|
true,
|
||||||
|
item,
|
||||||
|
grouping = if (item.grouping.isNullOrEmpty()) {
|
||||||
|
""
|
||||||
|
} else item.grouping
|
||||||
|
)
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
|
showAutoSelfConsumption(item)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
},
|
||||||
|
onMoreClickListener = object : OnMoreClickListener {
|
||||||
|
override fun onMoreClickListener(item: ItemUbicadorVO) {
|
||||||
|
showMoreOptions(item)
|
||||||
|
}
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
|
binding.locationRecyclerview.adapter = adapter
|
||||||
|
binding.locationRecyclerview.layoutManager =
|
||||||
|
LinearLayoutManager(
|
||||||
|
requireContext(),
|
||||||
|
LinearLayoutManager.VERTICAL,
|
||||||
|
false
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if (isShelvinLogfromMainScreen) {
|
||||||
|
viewModel.shelvinLog_add(shelvingFk)
|
||||||
|
|
||||||
|
}
|
||||||
|
if (modeCheckUbication) {
|
||||||
|
listItems.sortedBy { it.isChecked }
|
||||||
|
.forEachIndexed { index, item ->
|
||||||
|
if (item.item == itemScannedScreen) {
|
||||||
|
binding.locationRecyclerview.scrollToPosition(
|
||||||
|
index
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
listItems = ArrayList()
|
(binding.locationRecyclerview.layoutManager as LinearLayoutManager).scrollToPosition(
|
||||||
var contEtiquetas = 0
|
0
|
||||||
it.list.forEach { item ->
|
)
|
||||||
try {
|
|
||||||
contEtiquetas += item.stickers.toInt()
|
|
||||||
parking = item.code
|
|
||||||
|
|
||||||
} catch (e: Exception) {
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
listItems.add(item)
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
etiquetas = contEtiquetas.toString()
|
|
||||||
binding.mainToolbar.toolbarTitle.text =
|
|
||||||
shelvingFk.uppercase() + getString(R.string.pUppercase) + parking + getString(
|
|
||||||
R.string.label
|
|
||||||
) + etiquetas
|
|
||||||
if (it.list.size > 0)
|
|
||||||
binding.editPrioridad.setText(it.list[0].priority)
|
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
|
|
||||||
|
|
||||||
for (item in listItems) {
|
|
||||||
for (localItem in listLocalItems) {
|
|
||||||
if (item.item == localItem.item) {
|
|
||||||
item.isNew = localItem.isNew
|
|
||||||
item.checked = localItem.checked
|
|
||||||
if (item.isNew && item.visible != "0") {
|
|
||||||
item.isNew = false
|
|
||||||
item.checked = true
|
|
||||||
}
|
|
||||||
|
|
||||||
binding.locationRecyclerview.postInvalidate()
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!binding.mainToolbar.switchButton.isChecked && listItems.isNotEmpty()) {
|
|
||||||
|
|
||||||
listItems = listItems.asReversed()
|
|
||||||
|
|
||||||
}
|
|
||||||
adapter = UbicadorAdapter(
|
|
||||||
listItems.sortedBy { it.isChecked },
|
|
||||||
onPasillerosItemClickListener = pasillerosItemClickListener!!,
|
|
||||||
onVisibleClickListener = object : OnVisibleClickListener {
|
|
||||||
override fun onVisibleClickListener(item: ItemUbicadorVO) {
|
|
||||||
|
|
||||||
if (!isAutoSelf) {
|
|
||||||
showAddItem(
|
|
||||||
item.item.toString(),
|
|
||||||
item.packing,
|
|
||||||
item.stickers,
|
|
||||||
item.visible,
|
|
||||||
true,
|
|
||||||
item,
|
|
||||||
grouping = if (item.grouping.isNullOrEmpty()) {
|
|
||||||
""
|
|
||||||
} else item.grouping
|
|
||||||
)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
|
|
||||||
showAutoSelfConsumption(item)
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
},
|
|
||||||
onMoreClickListener = object : OnMoreClickListener {
|
|
||||||
override fun onMoreClickListener(item: ItemUbicadorVO) {
|
|
||||||
showMoreOptions(item)
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
|
||||||
|
|
||||||
binding.locationRecyclerview.adapter = adapter
|
|
||||||
binding.locationRecyclerview.layoutManager =
|
|
||||||
LinearLayoutManager(
|
|
||||||
requireContext(),
|
|
||||||
LinearLayoutManager.VERTICAL,
|
|
||||||
false
|
|
||||||
)
|
|
||||||
|
|
||||||
if (isShelvinLogfromMainScreen) {
|
|
||||||
viewModel.shelvinLog_add(shelvingFk)
|
|
||||||
|
|
||||||
}
|
|
||||||
if (modeCheckUbication) {
|
|
||||||
listItems.sortedBy { it.isChecked }
|
|
||||||
.forEachIndexed { index, item ->
|
|
||||||
if (item.item == itemScannedScreen) {
|
|
||||||
binding.locationRecyclerview.scrollToPosition(
|
|
||||||
index
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
} else {
|
|
||||||
(binding.locationRecyclerview.layoutManager as LinearLayoutManager).scrollToPosition(
|
|
||||||
0
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
loadAddList.observe(viewLifecycleOwner) { event ->
|
loadAddList.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(it.errorMessage, it.isError, false)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingList(shelvingFk)
|
viewModel.itemShelvingList(shelvingFk)
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
response.observe(viewLifecycleOwner, Observer {
|
response.observe(viewLifecycleOwner, Observer {
|
||||||
if (it.isError) {
|
viewModel.itemShelvingList(shelvingFk)
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
ma.messageWithSound(it.errorMessage, it.isError, true)
|
|
||||||
|
|
||||||
} else {
|
|
||||||
viewModel.itemShelvingList(shelvingFk)
|
|
||||||
ma.messageWithSound("", it.isError, true, isToasted = false)
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
responseLog.observe(viewLifecycleOwner, Observer {
|
responseLog.observe(viewLifecycleOwner, Observer {
|
||||||
|
|
||||||
|
@ -636,7 +595,6 @@ class UbicadorFragment(
|
||||||
})
|
})
|
||||||
loadResponseCode.observe(viewLifecycleOwner) { event ->
|
loadResponseCode.observe(viewLifecycleOwner) { event ->
|
||||||
event.getContentIfNotHandled().notNull {
|
event.getContentIfNotHandled().notNull {
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
if (it.isError) {
|
if (it.isError) {
|
||||||
ma.messageWithSound(it.errorMessage, it.isError, true)
|
ma.messageWithSound(it.errorMessage, it.isError, true)
|
||||||
|
|
||||||
|
@ -646,33 +604,14 @@ class UbicadorFragment(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
responsepriority.observe(viewLifecycleOwner, Observer {
|
|
||||||
if (!isBack) {
|
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
ma.messageWithSound(
|
|
||||||
if (it.isError) it.errorMessage else {
|
|
||||||
getString(R.string.priorityChanged)
|
|
||||||
}, it.isError, true
|
|
||||||
)
|
|
||||||
}
|
|
||||||
isBack = false
|
|
||||||
|
|
||||||
})
|
|
||||||
|
|
||||||
responseMake.observe(viewLifecycleOwner, Observer {
|
responseMake.observe(viewLifecycleOwner, Observer {
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
if (it.isError) {
|
|
||||||
ma.messageWithSound(it.errorMessage, true, true, isToasted = true)
|
|
||||||
} else {
|
|
||||||
if (!shelvingFk.isNullOrEmpty()) {
|
|
||||||
|
|
||||||
binding.mainToolbar.toolbarTitle.text = shelvingFk
|
if (!shelvingFk.isNullOrEmpty()) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
binding.mainToolbar.toolbarTitle.text = shelvingFk
|
||||||
viewModel.itemShelvingList(
|
viewModel.itemShelvingList(
|
||||||
shelvingFk
|
shelvingFk
|
||||||
)
|
)
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -688,7 +627,6 @@ class UbicadorFragment(
|
||||||
.setOkButton(getString(R.string.take)) {
|
.setOkButton(getString(R.string.take)) {
|
||||||
try {
|
try {
|
||||||
if (customDialogInput.getValue().toInt() > 0) {
|
if (customDialogInput.getValue().toInt() > 0) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
var quantity =
|
var quantity =
|
||||||
if (item.visible.toInt() - customDialogInput.getValue()
|
if (item.visible.toInt() - customDialogInput.getValue()
|
||||||
.toInt() > 0
|
.toInt() > 0
|
||||||
|
@ -717,7 +655,6 @@ class UbicadorFragment(
|
||||||
customDialogInput.setFocusText()
|
customDialogInput.setFocusText()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private fun showAddItem(
|
private fun showAddItem(
|
||||||
itemFk: String,
|
itemFk: String,
|
||||||
packing: String,
|
packing: String,
|
||||||
|
@ -878,8 +815,6 @@ class UbicadorFragment(
|
||||||
if (packing != null) {
|
if (packing != null) {
|
||||||
if (updatePacking == null) {
|
if (updatePacking == null) {
|
||||||
if (itemFk != null && visible != null) {
|
if (itemFk != null && visible != null) {
|
||||||
|
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingAdd(
|
viewModel.itemShelvingAdd(
|
||||||
shelvingFk,
|
shelvingFk,
|
||||||
itemFk,
|
itemFk,
|
||||||
|
@ -898,7 +833,6 @@ class UbicadorFragment(
|
||||||
|
|
||||||
} else if (itemFk != null && etiquetas != null) {
|
} else if (itemFk != null && etiquetas != null) {
|
||||||
val visible_calc = (etiquetas * packing!!.toInt())
|
val visible_calc = (etiquetas * packing!!.toInt())
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingAdd(
|
viewModel.itemShelvingAdd(
|
||||||
shelving = shelvingFk,
|
shelving = shelvingFk,
|
||||||
item = itemFk,
|
item = itemFk,
|
||||||
|
@ -923,7 +857,6 @@ class UbicadorFragment(
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (itemFk != null && visible != null && !updatePacking) {
|
if (itemFk != null && visible != null && !updatePacking) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingMakeEdit(
|
viewModel.itemShelvingMakeEdit(
|
||||||
visible,
|
visible,
|
||||||
packing!!.toInt(),
|
packing!!.toInt(),
|
||||||
|
@ -945,7 +878,6 @@ class UbicadorFragment(
|
||||||
visible_calc = (etiquetas * packing.toInt())
|
visible_calc = (etiquetas * packing.toInt())
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
}
|
}
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingMakeEdit(
|
viewModel.itemShelvingMakeEdit(
|
||||||
visible_calc,
|
visible_calc,
|
||||||
packing.toInt(),
|
packing.toInt(),
|
||||||
|
@ -1036,9 +968,8 @@ class UbicadorFragment(
|
||||||
}.show()
|
}.show()
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun customDialogInputAction(item:ItemUbicadorVO) {
|
private fun customDialogInputAction(item: ItemUbicadorVO) {
|
||||||
if (customDialogInput.getValue().isNotEmpty()) {
|
if (customDialogInput.getValue().isNotEmpty()) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
viewModel.itemShelvingTransfer(
|
viewModel.itemShelvingTransfer(
|
||||||
item.id,
|
item.id,
|
||||||
customDialogInput.getValue()
|
customDialogInput.getValue()
|
||||||
|
|
|
@ -20,7 +20,6 @@ import es.verdnatura.presentation.view.feature.reubication.model.ReubicationList
|
||||||
import es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorListVO
|
import es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorListVO
|
||||||
import es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorVO
|
import es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorVO
|
||||||
import retrofit2.Call
|
import retrofit2.Call
|
||||||
import retrofit2.Callback
|
|
||||||
import retrofit2.Response
|
import retrofit2.Response
|
||||||
|
|
||||||
class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
@ -63,28 +62,28 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
vShelvingFk: String
|
vShelvingFk: String
|
||||||
) {
|
) {
|
||||||
salix.itemShelvingList(params = listOf(vShelvingFk.uppercase()).formatWithQuotes()).enqueue(
|
salix.itemShelvingList(params = listOf(vShelvingFk.uppercase()).formatWithQuotes()).enqueue(
|
||||||
object : SalixCallback<List<ItemUbicadorVO>>(context) {
|
object : SalixCallback<List<ItemUbicadorVO>>(context) {
|
||||||
override fun onSuccess(response: Response<List<ItemUbicadorVO>>) {
|
override fun onSuccess(response: Response<List<ItemUbicadorVO>>) {
|
||||||
_shelvingList.value = response.body()?.let { ItemUbicadorListVO(it) }
|
_shelvingList.value = response.body()?.let { ItemUbicadorListVO(it) }
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
val listError: ArrayList<ItemUbicadorVO> = ArrayList()
|
val listError: ArrayList<ItemUbicadorVO> = ArrayList()
|
||||||
listError.add(
|
listError.add(
|
||||||
ItemUbicadorVO(
|
ItemUbicadorVO(
|
||||||
0,
|
0,
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(
|
errorMessage = getMessageFromAllResponse(
|
||||||
nameofFunction(this),
|
nameofFunction(this),
|
||||||
t.message!!,
|
t.message!!,
|
||||||
),
|
|
||||||
),
|
),
|
||||||
)
|
),
|
||||||
_shelvingList.value = ItemUbicadorListVO(listError)
|
)
|
||||||
}
|
_shelvingList.value = ItemUbicadorListVO(listError)
|
||||||
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun shelvingPriorityUpdate(
|
fun shelvingPriorityUpdate(
|
||||||
|
@ -95,17 +94,6 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
where = JsonObject().apply { addProperty("code", shelving) },
|
where = JsonObject().apply { addProperty("code", shelving) },
|
||||||
params = hashMapOf("priority" to priority)
|
params = hashMapOf("priority" to priority)
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_responsepriority.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
|
||||||
_responsepriority.value =
|
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -114,21 +102,13 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
) {
|
) {
|
||||||
salix.itemShelvingAddList(
|
salix.itemShelvingAddList(
|
||||||
arrayListOf(shelving, items, isChecking, warehouse).formatWithQuotes()
|
arrayListOf(shelving, items, isChecking, warehouse).formatWithQuotes()
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responseAddList.value =
|
_responseAddList.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_responseAddList.value = ResponseItemVO(
|
|
||||||
isError = true, errorMessage = getMessageFromAllResponse(
|
|
||||||
nameofFunction(this), t.message!!
|
|
||||||
)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -145,17 +125,11 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
packing,
|
packing,
|
||||||
warehouse,
|
warehouse,
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_responseMake.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
||||||
_responseMake.value =
|
_responseMake.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
|
super.onResponse(call, response)
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
|
@ -169,14 +143,6 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
params = ItemShelvingSalix(visible = quantity, packing = packing, grouping = grouping),
|
params = ItemShelvingSalix(visible = quantity, packing = packing, grouping = grouping),
|
||||||
id = itemShelvingFk,
|
id = itemShelvingFk,
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
|
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_responseMake.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responseMake.value =
|
_responseMake.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
|
@ -189,25 +155,12 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
shelving: String, parking: String
|
shelving: String, parking: String
|
||||||
) {
|
) {
|
||||||
salix.setParking(arrayListOf(shelving, parking).formatWithQuotes())
|
salix.setParking(arrayListOf(shelving, parking).formatWithQuotes())
|
||||||
.enqueue(object : Callback<Any> {
|
.enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
override fun onResponse(call: Call<Any>, response: Response<Any>) {
|
||||||
if (!response.isSuccessful) {
|
_response.value =
|
||||||
_response.value = ResponseItemVO(
|
ResponseItemVO(isError = false, response = response.message())
|
||||||
isError = true, errorMessage = getMessageFromAllResponse(
|
super.onResponse(call, response)
|
||||||
nameofFunction(this), response.message()
|
|
||||||
)
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
_response.value =
|
|
||||||
ResponseItemVO(isError = false, response = response.message())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onFailure(call: Call<Any>, t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -220,34 +173,29 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
where = JsonObject().apply { addProperty("id", vShelf) },
|
where = JsonObject().apply { addProperty("id", vShelf) },
|
||||||
params = hashMapOf("shelvingFk" to vShelvingFk)
|
params = hashMapOf("shelvingFk" to vShelvingFk)
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
super.onSuccess(response)
|
super.onSuccess(response)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemShelving_deleteChecked(
|
fun itemShelvingDeleteChecked(
|
||||||
vShelvingFk: String
|
vShelvingFk: String
|
||||||
|
|
||||||
) {
|
) {
|
||||||
salix.itemShelvingsUpdate(
|
salix.itemShelvingsUpdate(
|
||||||
where = JsonObject().apply { addProperty("shelvingFk", vShelvingFk) },
|
where = JsonObject().apply { addProperty("shelvingFk", vShelvingFk) },
|
||||||
params = hashMapOf("isChecked" to null)
|
params = hashMapOf("isChecked" to null)
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value =
|
_response.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
}
|
super.onSuccess(response)
|
||||||
})
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun shelvinLog_add(
|
fun shelvinLog_add(
|
||||||
|
@ -257,19 +205,19 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
// salix.shelvingLogAdd(hashMapOf("code" to code))
|
// salix.shelvingLogAdd(hashMapOf("code" to code))
|
||||||
silex.shelvingLog_add(code).enqueue(object : SalixCallback<Any>(context) {
|
silex.shelvingLog_add(code).enqueue(object : SalixCallback<Any>(context) {
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responseLog.value =
|
_responseLog.value =
|
||||||
ResponseItemVO(isError = false, response = response.message()!!)
|
ResponseItemVO(isError = false, response = response.message()!!)
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemShelving_return(
|
fun itemShelving_return(
|
||||||
shelvingFk: String,
|
shelvingFk: String,
|
||||||
|
|
||||||
) {
|
) {
|
||||||
//Tarea 6273
|
//Tarea 6276
|
||||||
// salix.itemShelvingReturn(shelvingFk)
|
// salix.itemShelvingReturn(shelvingFk)
|
||||||
silex.itemShelving_return(shelvingFk)
|
silex.itemShelving_return(shelvingFk)
|
||||||
.enqueue(object : SilexCallback<ArrayList<Reubication>>(context) {
|
.enqueue(object : SilexCallback<ArrayList<Reubication>>(context) {
|
||||||
|
@ -316,17 +264,12 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
where = JsonObject().apply { addProperty("shelvingFk", shelvingFk) },
|
where = JsonObject().apply { addProperty("shelvingFk", shelvingFk) },
|
||||||
hashMapOf("visible" to 0)
|
hashMapOf("visible" to 0)
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value = ResponseItemVO(isError = false, response = response.message())
|
_response.value = ResponseItemVO(isError = false, response = response.message())
|
||||||
}
|
super.onSuccess(response)
|
||||||
})
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun shelvingChangeSalix(
|
fun shelvingChangeSalix(
|
||||||
|
@ -338,17 +281,12 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
where = JsonObject().apply { addProperty("shelvingFk", shelvingFkIn) },
|
where = JsonObject().apply { addProperty("shelvingFk", shelvingFkIn) },
|
||||||
hashMapOf("shelvingFk" to shelvingFkOut)
|
hashMapOf("shelvingFk" to shelvingFkOut)
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value = ResponseItemVO(isError = false, response = response.message())
|
_response.value = ResponseItemVO(isError = false, response = response.message())
|
||||||
}
|
super.onSuccess(response)
|
||||||
})
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemShelvingTransfer(
|
fun itemShelvingTransfer(
|
||||||
|
@ -373,19 +311,19 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
|
|
||||||
fun itemShelvingDelete(itemFk: Int) {
|
fun itemShelvingDelete(itemFk: Int) {
|
||||||
salix.itemShelvingsDelete(itemFk).enqueue(object : SalixCallback<Any>(context) {
|
salix.itemShelvingsDelete(itemFk).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
|
||||||
_response.value = ResponseItemVO(
|
_response.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value = ResponseItemVO(isError = false, response = response.message())
|
_response.value = ResponseItemVO(isError = false, response = response.message())
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun itemShelvingSelfConsumption(shelvingFk: String, itemFk: Int, quantity: Int) {
|
fun itemShelvingSelfConsumption(shelvingFk: String, itemFk: Int, quantity: Int) {
|
||||||
|
@ -394,41 +332,33 @@ class UbicadorViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
shelvingFk, itemFk, quantity
|
shelvingFk, itemFk, quantity
|
||||||
).formatWithQuotes()
|
).formatWithQuotes()
|
||||||
).enqueue(object : SalixCallback<Any>(context) {
|
).enqueue(object : SalixCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_response.value = ResponseItemVO(isError = false, response = response.message())
|
_response.value = ResponseItemVO(isError = false, response = response.message())
|
||||||
}
|
}
|
||||||
|
})
|
||||||
override fun onError(t: Throwable) {
|
|
||||||
_response.value = ResponseItemVO(
|
|
||||||
isError = true,
|
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun getIdFromCode(code: String) {
|
fun getIdFromCode(code: String) {
|
||||||
salix.barcodes_toitem(code).enqueue(object : SilexCallback<String?>(context) {
|
salix.barcodes_toitem(code).enqueue(object : SalixCallback<String?>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
|
_responseCode.value = ResponseItemVO(
|
||||||
|
isError = true,
|
||||||
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onSuccess(response: Response<String?>) {
|
||||||
|
|
||||||
|
if (response.body() == null) {
|
||||||
_responseCode.value = ResponseItemVO(
|
_responseCode.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true, errorMessage = context.getString(R.string.itemNotValid)
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
_responseCode.value =
|
||||||
|
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
||||||
}
|
}
|
||||||
|
}
|
||||||
override fun onSuccess(response: Response<String?>) {
|
})
|
||||||
|
|
||||||
if (response.body() == null) {
|
|
||||||
_responseCode.value = ResponseItemVO(
|
|
||||||
isError = true, errorMessage = context.getString(R.string.itemNotValid)
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
_responseCode.value =
|
|
||||||
ResponseItemVO(isError = false, response = response.body()!!.toString())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,8 +3,6 @@ package es.verdnatura.presentation.view.feature.workermistake.fragment
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import android.view.View.GONE
|
|
||||||
import android.view.View.VISIBLE
|
|
||||||
import android.view.inputmethod.EditorInfo
|
import android.view.inputmethod.EditorInfo
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
import es.verdnatura.R
|
import es.verdnatura.R
|
||||||
|
@ -19,7 +17,6 @@ import es.verdnatura.presentation.view.component.CustomDialogList
|
||||||
import es.verdnatura.presentation.view.feature.inventario.fragment.InventaryViewModel
|
import es.verdnatura.presentation.view.feature.inventario.fragment.InventaryViewModel
|
||||||
import es.verdnatura.presentation.view.feature.workermistake.model.MistakeType
|
import es.verdnatura.presentation.view.feature.workermistake.model.MistakeType
|
||||||
|
|
||||||
|
|
||||||
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
@Suppress("UNUSED_ANONYMOUS_PARAMETER")
|
||||||
class PackingMistakeFragment(var menuOrigin: String) :
|
class PackingMistakeFragment(var menuOrigin: String) :
|
||||||
BaseFragment<FragmentGeneralBlackBinding, InventaryViewModel>(
|
BaseFragment<FragmentGeneralBlackBinding, InventaryViewModel>(
|
||||||
|
@ -49,11 +46,8 @@ class PackingMistakeFragment(var menuOrigin: String) :
|
||||||
binding.scanInput.visibility = View.VISIBLE
|
binding.scanInput.visibility = View.VISIBLE
|
||||||
binding.scanInput.hint = getString(R.string.scanLabelExpedition)
|
binding.scanInput.hint = getString(R.string.scanLabelExpedition)
|
||||||
binding.mainToolbar.toolbarTitle.text = getString(R.string.titlePackingMistake)
|
binding.mainToolbar.toolbarTitle.text = getString(R.string.titlePackingMistake)
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
customDialogList = CustomDialogList(requireContext())
|
customDialogList = CustomDialogList(requireContext())
|
||||||
|
|
||||||
setEvents()
|
setEvents()
|
||||||
|
|
||||||
super.init()
|
super.init()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -79,9 +73,8 @@ class PackingMistakeFragment(var menuOrigin: String) :
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH || actionId == EditorInfo.IME_ACTION_DONE || actionId == 0 || actionId == 5) {
|
||||||
goBack = false
|
goBack = false
|
||||||
if (!binding.scanInput.text.isNullOrEmpty()) {
|
if (!binding.scanInput.text.isNullOrEmpty()) {
|
||||||
binding.splashProgress.visibility = View.VISIBLE
|
|
||||||
expeditionScan = binding.scanInput.text.toString()
|
expeditionScan = binding.scanInput.text.toString()
|
||||||
viewModel.expeditionMistakeType_get()
|
viewModel.expeditionMistakeTypeGet()
|
||||||
}
|
}
|
||||||
binding.scanInput.setText("")
|
binding.scanInput.setText("")
|
||||||
ma.hideKeyboard(binding.scanInput)
|
ma.hideKeyboard(binding.scanInput)
|
||||||
|
@ -94,32 +87,12 @@ class PackingMistakeFragment(var menuOrigin: String) :
|
||||||
override fun observeViewModel() {
|
override fun observeViewModel() {
|
||||||
with(viewModel) {
|
with(viewModel) {
|
||||||
mistakeWorkerList.observe(viewLifecycleOwner) {
|
mistakeWorkerList.observe(viewLifecycleOwner) {
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
showMistakeList(it.list)
|
showMistakeList(it.list)
|
||||||
}
|
}
|
||||||
|
|
||||||
responseAddMistake.observe(viewLifecycleOwner) {
|
|
||||||
|
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
ma.messageWithSound(
|
|
||||||
if (it.isError) {
|
|
||||||
if (it.codeError == 403) {
|
|
||||||
getString(R.string.userNotPermission)
|
|
||||||
} else {
|
|
||||||
it.errorMessage
|
|
||||||
}
|
|
||||||
|
|
||||||
} else {
|
|
||||||
getString(R.string.errorCauseRegistered)
|
|
||||||
}, it.isError, true, isToasted = true
|
|
||||||
)
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun showMistakeList(list: List<MistakeType>) {
|
private fun showMistakeList(list: List<MistakeType>) {
|
||||||
binding.splashProgress.visibility = View.GONE
|
|
||||||
listMistakes = ArrayList()
|
listMistakes = ArrayList()
|
||||||
list.forEach {
|
list.forEach {
|
||||||
listMistakes.add(GeneralItem(code = it.code, text = it.description))
|
listMistakes.add(GeneralItem(code = it.code, text = it.description))
|
||||||
|
@ -140,15 +113,13 @@ class PackingMistakeFragment(var menuOrigin: String) :
|
||||||
override fun OnGeneralItemRowClickListener(item: GeneralItem) {
|
override fun OnGeneralItemRowClickListener(item: GeneralItem) {
|
||||||
list.forEach {
|
list.forEach {
|
||||||
if (it.description == item.text) {
|
if (it.description == item.text) {
|
||||||
binding.splashProgress.visibility = VISIBLE
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
viewModel.expeditionMistake_add(
|
viewModel.expeditionMistakeAdd(
|
||||||
vExpeditionFk = expeditionScan.toInt(),
|
vExpeditionFk = expeditionScan.toInt(),
|
||||||
vTypeFk = item.code.toString()
|
vTypeFk = item.code.toString()
|
||||||
)
|
)
|
||||||
} catch (ex: Exception) {
|
} catch (ex: Exception) {
|
||||||
binding.splashProgress.visibility = GONE
|
|
||||||
ma.messageWithSound(
|
ma.messageWithSound(
|
||||||
getString(R.string.formatError),
|
getString(R.string.formatError),
|
||||||
true,
|
true,
|
||||||
|
@ -166,7 +137,6 @@ class PackingMistakeFragment(var menuOrigin: String) :
|
||||||
})
|
})
|
||||||
|
|
||||||
customDialogList.getRecyclerView().adapter = listMistakesAdapter
|
customDialogList.getRecyclerView().adapter = listMistakesAdapter
|
||||||
|
|
||||||
customDialogList.getRecyclerView().layoutManager =
|
customDialogList.getRecyclerView().layoutManager =
|
||||||
LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
||||||
|
|
||||||
|
|
|
@ -156,14 +156,6 @@ class WorkermistakeFragment(
|
||||||
mistakeWorkerList.observe(viewLifecycleOwner) {
|
mistakeWorkerList.observe(viewLifecycleOwner) {
|
||||||
showMistakeList(it.list)
|
showMistakeList(it.list)
|
||||||
}
|
}
|
||||||
/*responseAddMistake.observe(viewLifecycleOwner) {
|
|
||||||
ma.messageWithSound(
|
|
||||||
message = getString(R.string.errorCauseRegistered),
|
|
||||||
it.isError,
|
|
||||||
true,
|
|
||||||
isToasted = true
|
|
||||||
)
|
|
||||||
}*/
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,6 +16,28 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/splash_animation"
|
||||||
|
android:visibility="invisible"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:background="@color/verdnatura_black_8_alpha_6"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
android:gravity="center"
|
||||||
|
>
|
||||||
|
|
||||||
|
<com.airbnb.lottie.LottieAnimationView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="@dimen/verdnatura_logo_large_height"
|
||||||
|
app:lottie_autoPlay="true"
|
||||||
|
app:lottie_loop="true"
|
||||||
|
app:lottie_rawRes="@raw/orange_loading"
|
||||||
|
app:lottie_speed="2" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -2,7 +2,6 @@
|
||||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
@ -20,10 +19,8 @@
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
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">
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
@ -46,7 +43,6 @@
|
||||||
android:textColor="@color/verdnatura_pumpkin_orange"
|
android:textColor="@color/verdnatura_pumpkin_orange"
|
||||||
android:textSize="@dimen/body1" />
|
android:textSize="@dimen/body1" />
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
@ -54,9 +50,7 @@
|
||||||
android:gravity="left"
|
android:gravity="left"
|
||||||
android:text="@string/tickets"
|
android:text="@string/tickets"
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textSize="@dimen/body2"
|
android:textSize="@dimen/body2" />
|
||||||
/>
|
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/idTickets"
|
android:id="@+id/idTickets"
|
||||||
|
@ -87,7 +81,6 @@
|
||||||
android:textColor="@color/verdnatura_pumpkin_orange"
|
android:textColor="@color/verdnatura_pumpkin_orange"
|
||||||
android:textSize="@dimen/body1" />
|
android:textSize="@dimen/body1" />
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
@ -112,7 +105,6 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/linearLayout4" />
|
app:layout_constraintTop_toBottomOf="@+id/linearLayout4" />
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/btnSave"
|
android:id="@+id/btnSave"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -130,8 +122,6 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
'
|
|
||||||
|
|
||||||
<include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
|
@ -147,22 +137,21 @@
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
android:background="@color/verdnatura_black_8_alpha_6"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:visibility="visible"
|
android:visibility="invisible"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
<com.airbnb.lottie.LottieAnimationView
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
android:layout_height="@dimen/verdnatura_logo_large_height"
|
||||||
|
android:visibility="visible"
|
||||||
app:lottie_autoPlay="true"
|
app:lottie_autoPlay="true"
|
||||||
app:lottie_loop="true"
|
app:lottie_loop="true"
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
app:lottie_rawRes="@raw/orange_loading"
|
||||||
app:lottie_speed="2" />
|
app:lottie_speed="2" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,55 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
||||||
xmlns:tools="http://schemas.android.com/tools">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black">
|
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
|
||||||
android:id="@+id/buyers_items"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_height="0dp"
|
|
||||||
android:layout_marginTop="50dp"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
tools:listitem="@layout/item_card_row" />
|
|
||||||
|
|
||||||
<include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="invisible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center"
|
|
||||||
>
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -190,9 +190,9 @@
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/splash_progress"
|
android:id="@+id/splash_progress"
|
||||||
android:visibility="invisible"
|
android:visibility="visible"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="0dp"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="0dp"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
android:background="@color/verdnatura_black_8_alpha_6"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
@ -206,7 +206,6 @@
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
android:layout_height="@dimen/verdnatura_logo_large_height"
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
app:lottie_autoPlay="true"
|
||||||
app:lottie_loop="true"
|
app:lottie_loop="true"
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
app:lottie_rawRes="@raw/orange_loading"
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
<data>
|
<data>
|
||||||
|
|
||||||
<variable
|
<variable
|
||||||
name="viewModel"
|
name="viewModel"
|
||||||
type="es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorVO"/>
|
type="es.verdnatura.presentation.view.feature.ubicador.model.ItemUbicadorVO" />
|
||||||
</data>
|
</data>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -18,17 +18,18 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
|
android:paddingTop="@dimen/toolbar_height"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
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">
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
<com.google.android.material.textfield.TextInputLayout
|
||||||
android:id="@+id/textinputlayout_matricula"
|
android:id="@+id/textinputlayout_matricula"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -48,6 +49,7 @@
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
android:textColorHint="@android:color/darker_gray" />
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
</com.google.android.material.textfield.TextInputLayout>
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/button_finalizar"
|
android:id="@+id/button_finalizar"
|
||||||
style="@style/DefaultButton"
|
style="@style/DefaultButton"
|
||||||
|
@ -70,15 +72,11 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:clipToPadding="false"
|
android:clipToPadding="false"
|
||||||
tools:listitem="@layout/item_escaner_row"/>
|
tools:listitem="@layout/item_escaner_row" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
|
@ -86,34 +84,5 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -8,40 +8,12 @@
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/verdnatura_black">
|
android:background="@color/verdnatura_black">
|
||||||
|
|
||||||
' <include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="visible">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,132 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
|
||||||
android:id="@+id/textinputlayout_username"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:textColorHint="@android:color/darker_gray">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
|
||||||
android:id="@+id/edit_itemFk"
|
|
||||||
style="@style/InputLineTextSearch"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:backgroundTint="@android:color/white"
|
|
||||||
android:hint="@string/Escaneaetiqueta"
|
|
||||||
android:inputType="text"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="Parking"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Matrícula"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Visible"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Fecha"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
</LinearLayout>
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
|
||||||
android:id="@+id/location_all_recyclerview"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:clipToPadding="false"
|
|
||||||
/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -7,8 +7,8 @@
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/verdnatura_black"
|
android:background="@color/verdnatura_black">
|
||||||
>
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/linearLayout"
|
android:id="@+id/linearLayout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -20,15 +20,17 @@
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/main_toolbar">
|
app:layout_constraintTop_toBottomOf="@+id/main_toolbar">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/expedition_pallet_detail_pallet"
|
android:id="@+id/expedition_pallet_detail_pallet"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textColor="@color/verdnatura_pumpkin_orange"
|
|
||||||
android:text="@string/Pallet"
|
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:textSize="@dimen/h6"/>
|
android:text="@string/Pallet"
|
||||||
|
android:textColor="@color/verdnatura_pumpkin_orange"
|
||||||
|
android:textSize="@dimen/h6" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/linearLayout2"
|
android:id="@+id/linearLayout2"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -60,7 +62,6 @@
|
||||||
android:textSize="@dimen/body2" />
|
android:textSize="@dimen/body2" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
@ -77,7 +78,7 @@
|
||||||
tools:listitem="@layout/item_expedition_view_row" />
|
tools:listitem="@layout/item_expedition_view_row" />
|
||||||
|
|
||||||
|
|
||||||
' <include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
@ -99,28 +100,5 @@
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="0dp"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="visible"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -7,8 +7,7 @@
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/verdnatura_black"
|
android:background="@color/verdnatura_black">
|
||||||
>
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/linearLayout"
|
android:id="@+id/linearLayout"
|
||||||
|
@ -21,14 +20,15 @@
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/main_toolbar">
|
app:layout_constraintTop_toBottomOf="@+id/main_toolbar">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/expedition_scan_detail_pallet"
|
android:id="@+id/expedition_scan_detail_pallet"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textColor="@color/verdnatura_pumpkin_orange"
|
|
||||||
android:text="Pallet: "
|
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:textSize="@dimen/h6"/>
|
android:text="Pallet: "
|
||||||
|
android:textColor="@color/verdnatura_pumpkin_orange"
|
||||||
|
android:textSize="@dimen/h6" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
@ -71,7 +71,6 @@
|
||||||
android:textSize="@dimen/body2" />
|
android:textSize="@dimen/body2" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
@ -87,35 +86,12 @@
|
||||||
tools:listitem="@layout/item_expeditionscan_row" />
|
tools:listitem="@layout/item_expeditionscan_row" />
|
||||||
|
|
||||||
|
|
||||||
' <include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="visible"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -38,7 +38,7 @@
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
android:background="@color/verdnatura_black_8_alpha_6"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:visibility="visible">
|
android:visibility="invisible">
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
<com.airbnb.lottie.LottieAnimationView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -12,11 +12,11 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
|
android:paddingTop="@dimen/toolbar_height"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -39,7 +39,6 @@
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
android:textColorHint="@android:color/darker_gray" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
|
|
||||||
android:id="@+id/item_image"
|
android:id="@+id/item_image"
|
||||||
|
@ -50,62 +49,70 @@
|
||||||
android:src="@drawable/ic_chevron_right_black_24dp"
|
android:src="@drawable/ic_chevron_right_black_24dp"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
android:layout_marginTop="@dimen/layout_margin_min"
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
android:layout_marginBottom="@dimen/layout_margin_1"
|
||||||
|
android:orientation="horizontal"
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
android:paddingLeft="@dimen/layout_margin_min"
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
android:paddingRight="@dimen/layout_margin_min">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center"
|
||||||
android:text="@string/Fecha"
|
android:text="@string/Fecha"
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:layout_weight="1"
|
android:textSize="@dimen/body2" />
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center"
|
||||||
android:text="@string/Cliente"
|
android:text="@string/Cliente"
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:layout_weight="1"
|
android:textSize="@dimen/body2" />
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center"
|
||||||
android:text="@string/Entrada"
|
android:text="@string/Entrada"
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:layout_weight="1"
|
android:textSize="@dimen/body2" />
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center"
|
||||||
android:text="@string/Salida"
|
android:text="@string/Salida"
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:layout_weight="1"
|
android:textSize="@dimen/body2" />
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/Balance"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:gravity="center"/>
|
android:gravity="center"
|
||||||
|
android:text="@string/Balance"
|
||||||
|
android:textColor="@color/verdnatura_white"
|
||||||
|
android:textSize="@dimen/body2" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
android:id="@+id/historico_recyclerview"
|
android:id="@+id/historico_recyclerview"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:clipToPadding="false"
|
android:clipToPadding="false"
|
||||||
tools:listitem="@layout/item_historico_row"/>
|
tools:listitem="@layout/item_historico_row" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
|
@ -113,35 +120,5 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,133 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
|
||||||
android:id="@+id/textinputlayout_username"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:textColorHint="@android:color/darker_gray">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
|
||||||
android:id="@+id/filter_itemFk"
|
|
||||||
style="@style/InputLineTextSearch"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:backgroundTint="@android:color/white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:hint="@string/Filtro"
|
|
||||||
android:inputType="text"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"
|
|
||||||
android:text="@string/ubicado"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textSize="@dimen/body2" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"
|
|
||||||
android:text="@string/altillo"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textSize="@dimen/body2" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"
|
|
||||||
android:text="@string/sinubicar"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textSize="@dimen/body2" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
|
||||||
android:id="@+id/location_recyclerview"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:clipToPadding="false"
|
|
||||||
tools:listitem="@layout/item_inventary_row"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -1,8 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -13,20 +12,19 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
|
android:paddingTop="@dimen/toolbar_height"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
android:layout_marginTop="@dimen/layout_margin_min"
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
android:layout_marginBottom="@dimen/layout_margin_1"
|
||||||
|
android:orientation="horizontal"
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
android:paddingLeft="@dimen/layout_margin_min"
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
android:paddingRight="@dimen/layout_margin_min">
|
||||||
|
|
||||||
|
@ -64,47 +62,16 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:clipToPadding="false"
|
android:clipToPadding="false"
|
||||||
tools:listitem="@layout/item_proposal_row"/>
|
tools:listitem="@layout/item_proposal_row" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<include
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,118 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="ItemFk"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="left"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="vDated"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="left"/>
|
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="atShelving"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="balance"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
|
||||||
|
|
||||||
android:id="@+id/itemshelvingdayofsale_recyclerview"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:clipToPadding="false"
|
|
||||||
tools:listitem="@layout/item_shelvingdayofsale_row"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -1,6 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
|
|
||||||
|
|
||||||
|
@ -9,8 +8,6 @@
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@drawable/background_login">
|
android:background="@drawable/background_login">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/constrainlayout_login"
|
android:id="@+id/constrainlayout_login"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -42,25 +39,24 @@
|
||||||
android:layout_marginTop="0dp"
|
android:layout_marginTop="0dp"
|
||||||
android:textColorHint="@android:color/darker_gray"
|
android:textColorHint="@android:color/darker_gray"
|
||||||
app:layout_constraintStart_toStartOf="@id/textview_welcome"
|
app:layout_constraintStart_toStartOf="@id/textview_welcome"
|
||||||
app:layout_constraintTop_toBottomOf="@id/textview_welcome"
|
app:layout_constraintTop_toBottomOf="@id/textview_welcome">
|
||||||
>
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
<com.google.android.material.textfield.TextInputEditText
|
||||||
android:id="@+id/edittext_server"
|
android:id="@+id/edittext_server"
|
||||||
style="@style/InputLineText"
|
style="@style/InputLineText"
|
||||||
|
inputType="none"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_margin="8dp"
|
android:layout_margin="8dp"
|
||||||
android:backgroundTint="@android:color/white"
|
android:backgroundTint="@android:color/white"
|
||||||
android:hint="Server:"
|
|
||||||
inputType="none"
|
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
|
android:drawableRight="@drawable/ic_chevron_right_black_24dp"
|
||||||
|
android:hint="Server:"
|
||||||
android:inputType="text"
|
android:inputType="text"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textColorHint="@android:color/darker_gray"
|
|
||||||
|
|
||||||
android:drawableRight="@drawable/ic_chevron_right_black_24dp" />
|
android:textColorHint="@android:color/darker_gray" />
|
||||||
|
|
||||||
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
</com.google.android.material.textfield.TextInputLayout>
|
||||||
|
@ -176,33 +172,6 @@
|
||||||
app:layout_constraintTop_toBottomOf="@id/button_login" />
|
app:layout_constraintTop_toBottomOf="@id/button_login" />
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="invisible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
</layout>
|
</layout>
|
|
@ -1,6 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
|
|
||||||
|
|
||||||
|
@ -12,11 +11,11 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
|
android:paddingTop="@dimen/toolbar_height"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
<com.google.android.material.textfield.TextInputLayout
|
||||||
android:id="@+id/textinputlayout_username"
|
android:id="@+id/textinputlayout_username"
|
||||||
|
@ -40,10 +39,10 @@
|
||||||
android:inputType="text"
|
android:inputType="text"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:visibility="gone"
|
|
||||||
android:textAlignment="center"
|
android:textAlignment="center"
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
android:textColorHint="@android:color/darker_gray"
|
||||||
|
android:visibility="gone" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/filter_supplier"
|
android:id="@+id/filter_supplier"
|
||||||
|
@ -73,11 +72,12 @@
|
||||||
android:id="@+id/radiobuttonTypePackaging"
|
android:id="@+id/radiobuttonTypePackaging"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:visibility="invisible"
|
|
||||||
android:layout_marginTop="25dp"
|
android:layout_marginTop="25dp"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
|
android:visibility="invisible"
|
||||||
|
|
||||||
>
|
>
|
||||||
|
|
||||||
<RadioButton
|
<RadioButton
|
||||||
android:id="@+id/radioButtonRec"
|
android:id="@+id/radioButtonRec"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
|
@ -96,48 +96,16 @@
|
||||||
android:text="@string/comeback"
|
android:text="@string/comeback"
|
||||||
android:textColor="@color/verdnatura_white" />
|
android:textColor="@color/verdnatura_white" />
|
||||||
|
|
||||||
|
|
||||||
</RadioGroup>
|
</RadioGroup>
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:visibility="visible"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
|
@ -68,9 +68,9 @@
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
android:layout_marginTop="@dimen/layout_margin_min"
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
android:layout_marginBottom="@dimen/layout_margin_1"
|
||||||
|
android:orientation="horizontal"
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
android:paddingLeft="@dimen/layout_margin_min"
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
android:paddingRight="@dimen/layout_margin_min">
|
||||||
|
|
||||||
|
@ -97,10 +97,10 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="0.75"
|
android:layout_weight="0.75"
|
||||||
|
android:paddingStart="@dimen/layout_margin_3"
|
||||||
android:text="Total"
|
android:text="Total"
|
||||||
android:textAlignment="textStart"
|
android:textAlignment="textStart"
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:paddingStart="@dimen/layout_margin_3"
|
|
||||||
android:textSize="@dimen/body2" />
|
android:textSize="@dimen/body2" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
@ -123,30 +123,5 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="invisible"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -40,19 +40,20 @@
|
||||||
android:textSize="18dp"
|
android:textSize="18dp"
|
||||||
app:layout_constraintStart_toEndOf="@+id/observations"
|
app:layout_constraintStart_toEndOf="@+id/observations"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/observations" />
|
app:layout_constraintTop_toBottomOf="@+id/observations" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/textImages"
|
android:id="@+id/textImages"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
android:layout_marginTop="@dimen/layout_margin_min"
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
android:layout_marginBottom="@dimen/layout_margin_1"
|
||||||
|
android:orientation="horizontal"
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
android:paddingLeft="@dimen/layout_margin_min"
|
||||||
android:paddingRight="@dimen/layout_margin_min"
|
android:paddingRight="@dimen/layout_margin_min"
|
||||||
app:layout_constraintStart_toEndOf="@+id/textImage"
|
app:layout_constraintStart_toEndOf="@+id/textImage"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/textImage" >
|
app:layout_constraintTop_toBottomOf="@+id/textImage">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/openPickerImages"
|
android:id="@+id/openPickerImages"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="48dp"
|
android:layout_height="48dp"
|
||||||
|
@ -61,7 +62,7 @@
|
||||||
android:text="Añadir nueva..."
|
android:text="Añadir nueva..."
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textSize="@dimen/body2" />
|
android:textSize="@dimen/body2" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
android:id="@+id/listImagesRecycler"
|
android:id="@+id/listImagesRecycler"
|
||||||
|
@ -70,8 +71,7 @@
|
||||||
android:visibility="visible"
|
android:visibility="visible"
|
||||||
app:layout_constraintStart_toEndOf="@+id/textImages"
|
app:layout_constraintStart_toEndOf="@+id/textImages"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/textImages"
|
app:layout_constraintTop_toBottomOf="@+id/textImages"
|
||||||
tools:listitem="@layout/item_image_row"
|
tools:listitem="@layout/item_image_row" />
|
||||||
/>
|
|
||||||
|
|
||||||
|
|
||||||
<include
|
<include
|
||||||
|
@ -81,25 +81,5 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="visible"
|
|
||||||
tools:layout_editor_absoluteX="0dp"
|
|
||||||
tools:layout_editor_absoluteY="0dp">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -27,7 +27,7 @@
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="horizontal"/>
|
android:orientation="horizontal" />
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
@ -282,27 +282,6 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="visible"
|
|
||||||
tools:layout_editor_absoluteX="0dp"
|
|
||||||
tools:layout_editor_absoluteY="0dp">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,7 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
>
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -9,20 +8,17 @@
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/verdnatura_black">
|
android:background="@color/verdnatura_black">
|
||||||
|
|
||||||
|
<com.google.android.material.textfield.TextInputEditText
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
android:id="@+id/scan_input"
|
||||||
android:id="@+id/scan_input"
|
style="@style/ScanLineTextSearch"
|
||||||
style="@style/ScanLineTextSearch"
|
android:layout_width="match_parent"
|
||||||
android:layout_width="match_parent"
|
android:hint="@string/Escaneaetiqueta"
|
||||||
android:hint="@string/Escaneaetiqueta"
|
android:inputType="textVisiblePassword"
|
||||||
android:inputType="textVisiblePassword"
|
android:lines="1"
|
||||||
android:lines="1"
|
android:maxLines="1"
|
||||||
android:maxLines="1"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintTop_toTopOf="@+id/main_toolbar" />
|
||||||
app:layout_constraintTop_toTopOf="@+id/main_toolbar"/>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<include
|
<include
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
|
@ -31,27 +27,5 @@
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -36,16 +36,16 @@
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/splash_progress"
|
android:id="@+id/splash_progress"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:background="@color/verdnatura_black_8_alpha_6"
|
||||||
|
android:gravity="center"
|
||||||
|
android:orientation="vertical"
|
||||||
android:visibility="visible"
|
android:visibility="visible"
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
<com.airbnb.lottie.LottieAnimationView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
|
@ -56,28 +56,5 @@
|
||||||
app:lottie_speed="2" />
|
app:lottie_speed="2" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress_two"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,118 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black">
|
|
||||||
|
|
||||||
<include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
|
||||||
android:id="@+id/scan"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginStart="25dp"
|
|
||||||
android:layout_marginTop="50dp"
|
|
||||||
android:layout_marginEnd="25dp"
|
|
||||||
android:textColorHint="@android:color/darker_gray"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/main_toolbar">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
|
||||||
android:id="@+id/scan_input"
|
|
||||||
style="@style/InputLineTextSearch"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_marginStart="50dp"
|
|
||||||
android:layout_marginTop="75dp"
|
|
||||||
android:layout_marginEnd="50dp"
|
|
||||||
android:gravity="center_horizontal"
|
|
||||||
android:backgroundTint="@color/colorPrimary"
|
|
||||||
android:hint="@string/ScanPlateOrSmarttag"
|
|
||||||
android:inputType="text"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray"
|
|
||||||
android:textDirection="firstStrong" />
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
|
||||||
android:id="@+id/scan_smarttag"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginStart="25dp"
|
|
||||||
android:layout_marginTop="150dp"
|
|
||||||
android:layout_marginEnd="25dp"
|
|
||||||
android:textColorHint="@android:color/darker_gray"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/main_toolbar">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
|
||||||
android:id="@+id/scan_input_smarttag"
|
|
||||||
style="@style/InputLineTextSearch"
|
|
||||||
android:visibility="invisible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_marginStart="50dp"
|
|
||||||
android:layout_marginTop="100dp"
|
|
||||||
android:layout_marginEnd="50dp"
|
|
||||||
android:backgroundTint="@color/colorPrimary"
|
|
||||||
android:gravity="center_horizontal"
|
|
||||||
|
|
||||||
android:inputType="text"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray"
|
|
||||||
android:textDirection="firstStrong" />
|
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/button_punch"
|
|
||||||
style="@style/DefaultButton"
|
|
||||||
android:layout_width="250dp"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:layout_marginTop="0dp"
|
|
||||||
android:background="@drawable/btn_orange"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:text="ESCANEAR CARROS"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
tools:visibility="gone" />
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="visible">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -1,163 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
|
||||||
android:id="@+id/textinputlayout_username"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:textColorHint="@android:color/darker_gray">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
|
||||||
android:id="@+id/shelvingText"
|
|
||||||
style="@style/InputLineTextSearch"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
|
|
||||||
android:backgroundTint="@android:color/white"
|
|
||||||
android:hint="@string/Escaneashelving"
|
|
||||||
android:inputType="text"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
|
||||||
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
|
||||||
android:id="@+id/textinputlayout_dayrange"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:textColorHint="@android:color/darker_gray">
|
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputEditText
|
|
||||||
android:id="@+id/dayrange"
|
|
||||||
style="@style/InputLineTextSearch"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:backgroundTint="@android:color/white"
|
|
||||||
android:hint="Day Range"
|
|
||||||
android:inputType="number"
|
|
||||||
android:text="1"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal"
|
|
||||||
android:layout_marginTop="@dimen/layout_margin_min"
|
|
||||||
android:layout_marginBottom="@dimen/layout_margin_1"
|
|
||||||
android:paddingLeft="@dimen/layout_margin_min"
|
|
||||||
android:paddingRight="@dimen/layout_margin_min">
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="ItemFk"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Concepto"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/SinServir"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Aparcado"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="center"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
|
||||||
android:id="@+id/location_recyclerview"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:clipToPadding="false"
|
|
||||||
tools:listitem="@layout/item_shelvingparking_row"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -1,8 +1,6 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
||||||
>
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -58,11 +56,13 @@
|
||||||
android:layout_width="200dp"
|
android:layout_width="200dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Print all ZPL" />
|
android:text="Print all ZPL" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/button_print_status"
|
android:id="@+id/button_print_status"
|
||||||
android:layout_width="200dp"
|
android:layout_width="200dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Print status" />
|
android:text="Print status" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/button_print_disconnect"
|
android:id="@+id/button_print_disconnect"
|
||||||
android:layout_width="200dp"
|
android:layout_width="200dp"
|
||||||
|
@ -83,31 +83,5 @@
|
||||||
app:srcCompat="@drawable/alpha_b_circle_outline" />
|
app:srcCompat="@drawable/alpha_b_circle_outline" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="gone"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,156 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent">
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:layout_margin="@dimen/default_layout_margin"
|
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/textView13"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Escaneaetiqueta"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textSize="18sp" />
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/editText7"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:layout_marginRight="10dp"
|
|
||||||
android:layout_marginBottom="10dp"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:background="@color/verdnatura_white"
|
|
||||||
android:ems="10"
|
|
||||||
android:hint="@string/Etiquetas"
|
|
||||||
android:inputType="number"
|
|
||||||
android:padding="8dp" />
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/numEtiquetas"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:layout_marginBottom="10dp"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:background="@color/verdnatura_white"
|
|
||||||
android:ems="10"
|
|
||||||
android:hint="@string/cantidad"
|
|
||||||
android:inputType="number"
|
|
||||||
android:padding="8dp" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/textView19"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/carrodeorigen"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textSize="18sp" />
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/editText10"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:ems="10"
|
|
||||||
android:inputType="textPersonName"
|
|
||||||
android:background="@color/verdnatura_white"
|
|
||||||
android:padding="8dp"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:layout_marginBottom="10dp"
|
|
||||||
android:hint="@string/carrodeorigen"/>
|
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/textView21"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/Carrodestino"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textSize="18sp" />
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/editText11"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:ems="10"
|
|
||||||
android:inputType="textPersonName"
|
|
||||||
android:background="@color/verdnatura_white"
|
|
||||||
android:padding="8dp"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:hint="@string/Carrodestino"/>
|
|
||||||
|
|
||||||
<Button
|
|
||||||
style="@style/DefaultButton"
|
|
||||||
android:id="@+id/button15"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/transfer"
|
|
||||||
android:background="@drawable/btn_orange"
|
|
||||||
android:layout_marginTop="20dp"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:onClick="transferir"/>
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout xmlns:tools="http://schemas.android.com/tools"
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
@ -12,17 +12,18 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
|
android:paddingTop="@dimen/toolbar_height"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
android:paddingTop="@dimen/toolbar_height">
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
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">
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
<com.google.android.material.textfield.TextInputLayout
|
||||||
android:id="@+id/textinputlayout_matricula"
|
android:id="@+id/textinputlayout_matricula"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -42,6 +43,7 @@
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
android:textColorHint="@android:color/darker_gray" />
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
</com.google.android.material.textfield.TextInputLayout>
|
||||||
|
|
||||||
<com.google.android.material.textfield.TextInputLayout
|
<com.google.android.material.textfield.TextInputLayout
|
||||||
android:id="@+id/textinputlayout_prioridad"
|
android:id="@+id/textinputlayout_prioridad"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -61,30 +63,34 @@
|
||||||
android:textColor="@color/verdnatura_white"
|
android:textColor="@color/verdnatura_white"
|
||||||
android:textColorHint="@android:color/darker_gray" />
|
android:textColorHint="@android:color/darker_gray" />
|
||||||
</com.google.android.material.textfield.TextInputLayout>
|
</com.google.android.material.textfield.TextInputLayout>
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/delete_img"
|
android:id="@+id/delete_img"
|
||||||
android:layout_width="@dimen/options_image_width"
|
android:layout_width="@dimen/options_image_width"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:src="@drawable/ic_delete_forever_black_24dp"
|
android:padding="@dimen/options_image_padding"
|
||||||
android:padding="@dimen/options_image_padding"/>
|
android:src="@drawable/ic_delete_forever_black_24dp" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/edit_img"
|
android:id="@+id/edit_img"
|
||||||
android:layout_width="@dimen/options_image_width"
|
android:layout_width="@dimen/options_image_width"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:src="@drawable/ic_mode_edit_black_24dp"
|
android:padding="@dimen/options_image_padding"
|
||||||
android:padding="@dimen/options_image_padding"/>
|
android:src="@drawable/ic_mode_edit_black_24dp" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/parking_img"
|
android:id="@+id/parking_img"
|
||||||
android:layout_width="@dimen/options_image_width"
|
android:layout_width="@dimen/options_image_width"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:src="@drawable/ic_local_parking_black_24dp"
|
android:padding="@dimen/options_image_padding"
|
||||||
android:padding="@dimen/options_image_padding"/>
|
android:src="@drawable/ic_local_parking_black_24dp" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/automatic_img"
|
android:id="@+id/automatic_img"
|
||||||
android:layout_width="@dimen/options_image_width"
|
android:layout_width="@dimen/options_image_width"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:src="@drawable/ic_flash_auto_black_24dp"
|
android:padding="@dimen/options_image_padding"
|
||||||
android:padding="@dimen/options_image_padding"/>
|
android:src="@drawable/ic_flash_auto_black_24dp" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
@ -93,16 +99,11 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:clipToPadding="false"
|
android:clipToPadding="false"
|
||||||
tools:listitem="@layout/item_ubication_row"/>
|
tools:listitem="@layout/item_ubication_row" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<include
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
@ -110,33 +111,5 @@
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -9,43 +9,19 @@
|
||||||
android:background="@color/verdnatura_black">
|
android:background="@color/verdnatura_black">
|
||||||
|
|
||||||
|
|
||||||
|
<include
|
||||||
<include
|
|
||||||
android:id="@+id/main_toolbar"
|
android:id="@+id/main_toolbar"
|
||||||
layout="@layout/toolbar_fragment"
|
layout="@layout/toolbar_fragment"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<LinearLayout
|
<WebView
|
||||||
android:id="@+id/splash_progress"
|
android:id="@+id/webView"
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:layout_marginTop="0dp" />
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
|
|
||||||
<WebView
|
|
||||||
android:id="@+id/webView"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_marginTop="30dp"
|
|
||||||
android:layout_height="match_parent" />
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
android:visibility="invisible"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
|
@ -1,111 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<layout
|
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
||||||
>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@color/verdnatura_black"
|
|
||||||
>
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/scan_input"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:backgroundTint="@android:color/white"
|
|
||||||
android:hint="@string/Escaner"
|
|
||||||
android:inputType="text"
|
|
||||||
android:lines="1"
|
|
||||||
android:maxLines="1"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:textColorHint="@android:color/darker_gray"
|
|
||||||
android:textSize="@dimen/body2"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/main_toolbar"
|
|
||||||
android:paddingLeft="@dimen/default_layout_margin"
|
|
||||||
android:visibility="gone"/>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
|
|
||||||
android:id="@+id/collection_swipe"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_height="0dp"
|
|
||||||
app:layout_constraintBottom_toTopOf="@+id/btn_obtener"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/scan_input">
|
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
|
||||||
android:id="@+id/fragment_sacador_collections"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
tools:listitem="@layout/item_article_row" />
|
|
||||||
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
|
|
||||||
|
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_obtener"
|
|
||||||
style="@style/DefaultButton"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_height="48dp"
|
|
||||||
android:layout_marginStart="16dp"
|
|
||||||
android:layout_marginEnd="16dp"
|
|
||||||
android:layout_marginBottom="16dp"
|
|
||||||
android:background="@drawable/btn_orange"
|
|
||||||
android:text="@string/obtener"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toStartOf="@+id/btn_cancelar"
|
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_cancelar"
|
|
||||||
style="@style/DefaultButton"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_marginEnd="16dp"
|
|
||||||
android:layout_marginBottom="16dp"
|
|
||||||
android:background="@drawable/btn_blue"
|
|
||||||
android:text="@string/cancel"
|
|
||||||
android:textColor="@color/verdnatura_white"
|
|
||||||
android:visibility="gone"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent" />
|
|
||||||
|
|
||||||
' <include
|
|
||||||
android:id="@+id/main_toolbar"
|
|
||||||
layout="@layout/toolbar_fragment"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/splash_progress"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="@color/verdnatura_black_8_alpha_6"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<com.airbnb.lottie.LottieAnimationView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="@dimen/verdnatura_logo_large_height"
|
|
||||||
app:lottie_autoPlay="true"
|
|
||||||
app:lottie_loop="true"
|
|
||||||
app:lottie_rawRes="@raw/orange_loading"
|
|
||||||
app:lottie_speed="2" />
|
|
||||||
</LinearLayout>
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
||||||
</layout>
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue