Compare commits

..

No commits in common. "5455fef624c8f4758ebe3421739dea82fc5987f6" and "67ad9f0f26ad5707c5a2ce768687152cad930374" have entirely different histories.

46 changed files with 108 additions and 934 deletions

View File

@ -290,7 +290,6 @@
<string name="title_task_number">Номер задания</string> <string name="title_task_number">Номер задания</string>
<string name="status">Статус</string> <string name="status">Статус</string>
<string name="main">Проведение измерения</string> <string name="main">Проведение измерения</string>
<string name="tech">Проведение Тех. осмотра</string>
<string name="message_select_route">Выберите путевой лист или задание</string> <string name="message_select_route">Выберите путевой лист или задание</string>

View File

@ -285,7 +285,6 @@
<string name="title_task_number">Номер задания</string> <string name="title_task_number">Номер задания</string>
<string name="status">Статус</string> <string name="status">Статус</string>
<string name="main">Проведение измерения</string> <string name="main">Проведение измерения</string>
<string name="tech">Проведение Тех. осмотра</string>
<string name="message_select_route">Выберите путевой лист или задание</string> <string name="message_select_route">Выберите путевой лист или задание</string>

View File

@ -335,7 +335,7 @@ interface ApiService {
fun update( fun update(
@Path("uniq_id") uuid: String, @Path("uniq_id") uuid: String,
@Part("uniq_id") uuidPart: RequestBody, @Part("uniq_id") uuidPart: RequestBody,
@Part("data") data: RequestBody?, @Part("data") data: List<CheckupData>?,
@Header("token") token: String? = "iddqd", @Header("token") token: String? = "iddqd",
@Header("Authorization") tokenUser: String? @Header("Authorization") tokenUser: String?
): Single<CheckupShowListResponse> ): Single<CheckupShowListResponse>

View File

@ -1 +1 @@
package ru.tele2med.mobile.data.api.entity.response import ru.tele2med.mobile.domain.entity.* data class CheckupShowListResponse( val af: String, val status: String, val message: String, val data: DataCheckListUpdate ) package ru.tele2med.mobile.data.api.entity.response import ru.tele2med.mobile.domain.entity.* data class CheckupShowListResponse( val af: String, val status: String, val message: String, val data: DataCheckupShow )

View File

@ -1,6 +1,5 @@
package ru.tele2med.mobile.data.repository package ru.tele2med.mobile.data.repository
import com.google.gson.Gson
import ru.tele2med.mobile.domain.repository.QRRepository import ru.tele2med.mobile.domain.repository.QRRepository
import ru.tele2med.mobile.presentation.util.Prefs import ru.tele2med.mobile.presentation.util.Prefs
import io.reactivex.Single import io.reactivex.Single
@ -110,20 +109,20 @@ class TechRepositoryImpl(
.map(dataConverter::toTechShow) .map(dataConverter::toTechShow)
override fun updateCheckList( override fun updateCheckList(
uniq_id: String,
id: String, id: String,
data: List<CheckupData> data: List<CheckupData>
): Single<CheckupShowList> = ): Single<CheckupShowList> =
apiService apiService
.update( .update(
uuid = uniq_id, uuid = id,
uuidPart = RequestBody.create( uuidPart = RequestBody.create(
MediaType.parse("text/plain"), uniq_id MediaType.parse("text/plain"), id
), ),
tokenUser = "Bearer ${prefs.getTokenUser().toString()}", tokenUser = "Bearer ${prefs.getTokenUser().toString()}",
data = RequestBody.create(MediaType.parse("text/plain"), Gson().toJson(data)) data = data,
) )
.map(dataConverter::toCheckupShow) .map(dataConverter::toCheckupShow)
} }

View File

@ -51,9 +51,7 @@ import ru.tele2med.mobile.presentation.ui.menu.items.tech.TechPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.TechListPresenter import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.TechListPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.TechCheckupPresenter import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.TechCheckupPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.TechCheckupInfoPresenter import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.TechCheckupInfoPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.sign.SignPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.TechCheckupTestsPresenter import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.TechCheckupTestsPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test.TestPresenter
import ru.tele2med.mobile.presentation.ui.menu.items.tech.park.ParkPresenter import ru.tele2med.mobile.presentation.ui.menu.items.tech.park.ParkPresenter
import ru.tele2med.mobile.presentation.ui.models.UiConverter import ru.tele2med.mobile.presentation.ui.models.UiConverter
import ru.tele2med.mobile.presentation.ui.splash.SplashPresenter import ru.tele2med.mobile.presentation.ui.splash.SplashPresenter
@ -74,21 +72,13 @@ fun presenterModule() = Kodein.Module(name = "presenterModule") {
} }
bind() from factory { stringId: String -> bind() from factory { stringId: String ->
TechCheckupTestsPresenter(instance(), instance(), instance()) TechCheckupTestsPresenter(instance(), instance(), stringId)
} }
bind() from provider { bind() from provider {
ParkPresenter(instance(), instance(), instance()) ParkPresenter(instance(), instance(), instance())
} }
bind() from provider {
TestPresenter(instance(), instance())
}
bind() from provider {
SignPresenter(instance(), instance())
}
bind() from provider { bind() from provider {
TechPresenter() TechPresenter()
@ -99,6 +89,9 @@ fun presenterModule() = Kodein.Module(name = "presenterModule") {
} }
bind() from provider { bind() from provider {
QrReviewPresenter(instance(), instance(), instance()) QrReviewPresenter(instance(), instance(), instance())
} }

View File

@ -4,5 +4,5 @@ data class CheckupShowList(
val af: String, val af: String,
val status: String, val status: String,
val message: String, val message: String,
val data: DataCheckListUpdate val data: DataCheckupShow
) )

View File

@ -1,13 +0,0 @@
package ru.tele2med.mobile.domain.entity
data class DataCheckListUpdate(
val count_all: String,
val count_checked: Int?,
val check_positive: Int?,
val check_negative: Int?,
val exam_state_description: String?,
val exam_state: Int?,
val exam_state_name: String?
)

View File

@ -9,7 +9,6 @@ data class DataTech(
val waybill_uuid: String, val waybill_uuid: String,
val waybill_name: String, val waybill_name: String,
val organization_id: String, val organization_id: String,
val organization_name: String,
val mechanic_id: String, val mechanic_id: String,
val mechanic_name: String, val mechanic_name: String,
val result_id: String, val result_id: String,

View File

@ -29,11 +29,9 @@ class TechInteractor(
techRepository.showTech(id) techRepository.showTech(id)
fun updateCheckList( fun updateCheckList(
uniq_id: String,
id: String, id: String,
data: List<CheckupData> data: List<CheckupData>
): Single<CheckupShowList> = ): Single<CheckupShowList> =
techRepository.updateCheckList(uniq_id, id, data) techRepository.showCheckup(id, data)
} }

View File

@ -19,7 +19,6 @@ interface TechRepository {
): Single<TechShowList> ): Single<TechShowList>
fun updateCheckList( fun updateCheckList(
uniq_id: String,
id: String, id: String,
data: List<CheckupData> data: List<CheckupData>
): Single<CheckupShowList> ): Single<CheckupShowList>

View File

@ -1,6 +1,5 @@
package ru.tele2med.mobile.presentation.router package ru.tele2med.mobile.presentation.router
import ru.tele2med.mobile.domain.entity.CheckupShowList
import ru.tele2med.mobile.domain.entity.DataQR import ru.tele2med.mobile.domain.entity.DataQR
import ru.tele2med.mobile.domain.entity.DataShow import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech import ru.tele2med.mobile.domain.entity.DataTech
@ -125,12 +124,8 @@ class NavRouter : Router() {
navigateTo(NavScreens.getTechCheckup(dataTech)) navigateTo(NavScreens.getTechCheckup(dataTech))
} }
fun openTestCheckupScreen(test: DataShow, uniq_id: String, dataTech: DataTech, checkupShowList: CheckupShowList?) { fun openTestCheckupScreen(test: DataShow) {
navigateTo(NavScreens.getTestCheckup(test, uniq_id, dataTech, checkupShowList?: null)) navigateTo(NavScreens.getTestCheckup(test))
}
fun openSignScreen(dataTech: DataTech) {
navigateTo(NavScreens.getSign(dataTech))
} }
fun openMedicalCheckupsScreen() { fun openMedicalCheckupsScreen() {

View File

@ -1,6 +1,5 @@
package ru.tele2med.mobile.presentation.router package ru.tele2med.mobile.presentation.router
import ru.tele2med.mobile.domain.entity.CheckupShowList
import ru.tele2med.mobile.domain.entity.DataQR import ru.tele2med.mobile.domain.entity.DataQR
import ru.tele2med.mobile.domain.entity.DataShow import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech import ru.tele2med.mobile.domain.entity.DataTech
@ -42,7 +41,6 @@ import ru.tele2med.mobile.presentation.ui.menu.items.stats.StatsScreen
import ru.tele2med.mobile.presentation.ui.menu.items.status.StatusesScreen import ru.tele2med.mobile.presentation.ui.menu.items.status.StatusesScreen
import ru.tele2med.mobile.presentation.ui.menu.items.tech.TechScreen import ru.tele2med.mobile.presentation.ui.menu.items.tech.TechScreen
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.TechCheckupScreen import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.TechCheckupScreen
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.sign.SignScreen
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test.TestScreen import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test.TestScreen
import ru.tele2med.mobile.presentation.ui.menu.items.tonometr.TonScreen import ru.tele2med.mobile.presentation.ui.menu.items.tonometr.TonScreen
@ -97,9 +95,7 @@ object NavScreens {
fun getTechCheckup(dataTech: DataTech): TechCheckupScreen = TechCheckupScreen(dataTech) fun getTechCheckup(dataTech: DataTech): TechCheckupScreen = TechCheckupScreen(dataTech)
fun getTestCheckup(test: DataShow, uniq_id: String, dataTech: DataTech, checkupShowList: CheckupShowList?): TestScreen = TestScreen(test, uniq_id, dataTech, checkupShowList) fun getTestCheckup(test: DataShow): TestScreen = TestScreen(test)
fun getSign(dataTech: DataTech): SignScreen = SignScreen(dataTech)
fun getTechCheckupInfo(dataTech: DataTech): TechCheckupScreen = TechCheckupScreen(dataTech) fun getTechCheckupInfo(dataTech: DataTech): TechCheckupScreen = TechCheckupScreen(dataTech)

View File

@ -47,7 +47,6 @@ abstract class BaseFragment : MvpAppCompatFragment(), BaseView, KodeinAware {
override fun showLoading() { override fun showLoading() {
progressDialog?.dismiss() progressDialog?.dismiss()
progressDialog = null
progressDialog = ProgressDialog.show(activity, null, getString(R.string.loading), true) progressDialog = ProgressDialog.show(activity, null, getString(R.string.loading), true)
} }

View File

@ -240,7 +240,6 @@ class DrawerAdapter(
ScreenType.TASKS_FOR_TODAY -> image.setImageResource(R.drawable.ic_rectangle) ScreenType.TASKS_FOR_TODAY -> image.setImageResource(R.drawable.ic_rectangle)
ScreenType.NOTIFICATIONS -> image.setImageResource(R.drawable.ic_rectangle) ScreenType.NOTIFICATIONS -> image.setImageResource(R.drawable.ic_rectangle)
ScreenType.MAIN -> image.setImageResource(R.drawable.ic_rectangle) ScreenType.MAIN -> image.setImageResource(R.drawable.ic_rectangle)
ScreenType.TECH -> image.setImageResource(R.drawable.ic_rectangle)
ScreenType.STATUS -> image.setImageResource(R.drawable.ic_rectangle) ScreenType.STATUS -> image.setImageResource(R.drawable.ic_rectangle)
ScreenType.HISTORY -> image.setImageResource(R.drawable.ic_rectangle) ScreenType.HISTORY -> image.setImageResource(R.drawable.ic_rectangle)
ScreenType.CHAT -> image.setImageResource(R.drawable.ic_rectangle) ScreenType.CHAT -> image.setImageResource(R.drawable.ic_rectangle)

View File

@ -363,42 +363,11 @@ class DrawerPresenter(
listOf( listOf(
defaultHeader, defaultHeader,
/* ListItem( ListItem(
ScreenType.MAIN, ScreenType.MAIN,
true, true,
R.string.main, R.string.main,
header = true header = true
), */
ListItem(
ScreenType.REVIEW,
false,
R.string.review_toolbar,
header = true
),
ListItem(
ScreenType.SETTING,
false,
R.string.settings_toolbar,
header = true
)
// ButtonItem
// ButtonItem
)
private var listTechCheckup: List<DrawerItem> =
listOf(
defaultHeader,
ListItem(
ScreenType.TECH,
true,
R.string.tech,
header = true
), ),
@ -422,7 +391,6 @@ class DrawerPresenter(
) )
override fun onFirstViewAttach() { override fun onFirstViewAttach() {
super.onFirstViewAttach() super.onFirstViewAttach()
disposable += changes disposable += changes
@ -448,12 +416,7 @@ class DrawerPresenter(
} else { } else {
viewState.showList(listB) viewState.showList(listB)
} }
} } else {
if (screenType == ScreenType.MAIN) {
viewState.showList(listTechCheckup)
}
else {
if (prefs.getLcMenu() == "true") { if (prefs.getLcMenu() == "true") {
viewState.showList(listCoordinatesA) viewState.showList(listCoordinatesA)
} else { } else {

View File

@ -14,7 +14,6 @@ enum class ScreenType {
WITHOUT_BORDER, WITHOUT_BORDER,
SELECT_ROUTE, SELECT_ROUTE,
QR, QR,
TECH,
PRINT, PRINT,
DASHBOARD, DASHBOARD,
SELECT_TASK, SELECT_TASK,

View File

@ -230,13 +230,8 @@ class MenuActivity : BaseDrawerActivity(), MenuView {
override fun onResumeFragments() { override fun onResumeFragments() {
navigationHolder.setNavigator(navigator) navigationHolder.setNavigator(navigator)
if (webSocketClient.isClosed) { if (webSocketClient.isClosed) {
try {
webSocketClient.connect() webSocketClient.connect()
} }
catch (e: Exception) {
Log.v("LOG", "e = ${e.message}")
}
}
super.onResumeFragments() super.onResumeFragments()
} }
@ -335,7 +330,6 @@ class MenuActivity : BaseDrawerActivity(), MenuView {
settings.setOnClickListener { settings.setOnClickListener {
presenter.onSettingsClick() presenter.onSettingsClick()
} }
} }

View File

@ -16,7 +16,7 @@ import ru.tele2med.mobile.presentation.util.providePresenter
class TechFragment : BaseMenuFragment(), TechView { class TechFragment : BaseMenuFragment(), TechView {
override val screenType: ScreenType override val screenType: ScreenType
get() = ScreenType.TECH get() = ScreenType.TASKS_FOR_TODAY
@InjectPresenter @InjectPresenter
lateinit var presenter: TechPresenter lateinit var presenter: TechPresenter

View File

@ -53,7 +53,7 @@ class TechListAdapter(
fun bind(list: DataTechCheckup) { fun bind(list: DataTechCheckup) {
carName.text = list.vehicle_name carName.text = list.vehicle_name
time.text = list.datetime_ time.text = list.datetime
//fio.text = list.fio //fio.text = list.fio
status.text = list.exam_state_name status.text = list.exam_state_name
/* eye.setImageDrawable( /* eye.setImageDrawable(

View File

@ -5,10 +5,7 @@ import android.view.View
import androidx.recyclerview.widget.LinearLayoutManager import androidx.recyclerview.widget.LinearLayoutManager
import com.arellomobile.mvp.presenter.InjectPresenter import com.arellomobile.mvp.presenter.InjectPresenter
import com.arellomobile.mvp.presenter.ProvidePresenter import com.arellomobile.mvp.presenter.ProvidePresenter
import com.google.gson.Gson
import kotlinx.android.synthetic.main.fragment_medical_checkup.*
import kotlinx.android.synthetic.main.fragment_tech_list.* import kotlinx.android.synthetic.main.fragment_tech_list.*
import kotlinx.android.synthetic.main.fragment_tech_list.refresh
import ru.tele2med.mobile.R import ru.tele2med.mobile.R
import ru.tele2med.mobile.presentation.ui.auth.AuthActivity import ru.tele2med.mobile.presentation.ui.auth.AuthActivity
import ru.tele2med.mobile.presentation.ui.base.BasePresenter import ru.tele2med.mobile.presentation.ui.base.BasePresenter
@ -22,15 +19,13 @@ import kotlinx.android.synthetic.main.toolbar_with_help.*
import org.jetbrains.anko.clearTask import org.jetbrains.anko.clearTask
import org.jetbrains.anko.intentFor import org.jetbrains.anko.intentFor
import org.jetbrains.anko.newTask import org.jetbrains.anko.newTask
import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.domain.entity.DataTechCheckup import ru.tele2med.mobile.domain.entity.DataTechCheckup
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.TechCheckupTestsFragment
class TechListFragment : BaseMenuFragment(), TechListView { class TechListFragment : BaseMenuFragment(), TechListView {
override val screenType: ScreenType override val screenType: ScreenType
get() = ScreenType.TECH get() = ScreenType.HELLO
@InjectPresenter @InjectPresenter
lateinit var presenter: TechListPresenter lateinit var presenter: TechListPresenter
@ -97,29 +92,12 @@ class TechListFragment : BaseMenuFragment(), TechListView {
} }
recyclerView.addOnScrollListener(scrollListener) recyclerView.addOnScrollListener(scrollListener)
initRecycler()
//setName() //setName()
setClickListeners() setClickListeners()
} }
override fun setRefreshing(flag: Boolean) {
println("setRefreshing = $flag")
refresh.isRefreshing = flag
}
private fun initRecycler() {
println("initRecycler")
refresh.setOnRefreshListener {
println("setOnRefreshListener")
presenter.getCheckups()
}
}
override fun showCheckups(list: List<DataTechCheckup>) { override fun showCheckups(list: List<DataTechCheckup>) {
adapter.submitList(list) adapter.submitList(list)

View File

@ -63,14 +63,6 @@ class TechListPresenter(
) )
.map(uiConverter::toUiTechCheckups) .map(uiConverter::toUiTechCheckups)
.ioToMain() .ioToMain()
.doOnSubscribe {
viewState.showLoading()
}
.doAfterTerminate {
viewState.hideLoading()
viewState.setRefreshing(false)
}
.baseLoadingHandle() .baseLoadingHandle()
.baseHandleErrorSubscribe { .baseHandleErrorSubscribe {
currentCheckups.addAll(it.data) currentCheckups.addAll(it.data)

View File

@ -1,7 +1,5 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list package ru.tele2med.mobile.presentation.ui.menu.items.tech.list
import com.arellomobile.mvp.viewstate.strategy.AddToEndSingleStrategy
import com.arellomobile.mvp.viewstate.strategy.StateStrategyType
import ru.tele2med.mobile.domain.entity.DataCheckup import ru.tele2med.mobile.domain.entity.DataCheckup
import ru.tele2med.mobile.domain.entity.DataTechCheckup import ru.tele2med.mobile.domain.entity.DataTechCheckup
import ru.tele2med.mobile.presentation.ui.base.BaseView import ru.tele2med.mobile.presentation.ui.base.BaseView
@ -9,8 +7,4 @@ import ru.tele2med.mobile.presentation.ui.base.BaseView
interface TechListView : BaseView { interface TechListView : BaseView {
fun showCheckups(list: List<DataTechCheckup>) fun showCheckups(list: List<DataTechCheckup>)
@StateStrategyType(AddToEndSingleStrategy::class)
fun setRefreshing(flag: Boolean)
} }

View File

@ -7,10 +7,6 @@ import com.arellomobile.mvp.presenter.InjectPresenter
import com.arellomobile.mvp.presenter.ProvidePresenter import com.arellomobile.mvp.presenter.ProvidePresenter
import com.google.gson.Gson import com.google.gson.Gson
import kotlinx.android.synthetic.main.fragment_tasks.* import kotlinx.android.synthetic.main.fragment_tasks.*
import kotlinx.android.synthetic.main.toolbar_with_help.*
import org.jetbrains.anko.clearTask
import org.jetbrains.anko.intentFor
import org.jetbrains.anko.newTask
import ru.tele2med.mobile.R import ru.tele2med.mobile.R
import ru.tele2med.mobile.domain.entity.DataTech import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.presentation.ui.base.BasePresenter import ru.tele2med.mobile.presentation.ui.base.BasePresenter
@ -23,7 +19,7 @@ import ru.tele2med.mobile.presentation.util.providePresenter
class TechCheckupFragment : BaseMenuFragment(), TechCheckupView { class TechCheckupFragment : BaseMenuFragment(), TechCheckupView {
override val screenType: ScreenType override val screenType: ScreenType
get() = ScreenType.TECH get() = ScreenType.TASKS_FOR_TODAY
@InjectPresenter @InjectPresenter
lateinit var presenter: TechCheckupPresenter lateinit var presenter: TechCheckupPresenter
@ -42,12 +38,6 @@ class TechCheckupFragment : BaseMenuFragment(), TechCheckupView {
super.onViewCreated(view, savedInstanceState) super.onViewCreated(view, savedInstanceState)
(activity as MenuActivity).apply { (activity as MenuActivity).apply {
var dataString = arguments?.getString(DATA_QR) var dataString = arguments?.getString(DATA_QR)
close.visibility = View.VISIBLE
close.setOnClickListener {
startActivity(intentFor<MenuActivity>().newTask().clearTask())
}
phone.visibility = View.GONE
settings.visibility = View.GONE
val gson = Gson() val gson = Gson()
val data = gson.fromJson(dataString, DataTech::class.java) val data = gson.fromJson(dataString, DataTech::class.java)

View File

@ -24,9 +24,6 @@ import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuFragment
import ru.tele2med.mobile.presentation.util.providePresenter import ru.tele2med.mobile.presentation.util.providePresenter
import kotlinx.android.synthetic.main.fragment_tech_checkup.* import kotlinx.android.synthetic.main.fragment_tech_checkup.*
import kotlinx.android.synthetic.main.toolbar_with_help.* import kotlinx.android.synthetic.main.toolbar_with_help.*
import org.jetbrains.anko.clearTask
import org.jetbrains.anko.intentFor
import org.jetbrains.anko.newTask
import ru.tele2med.mobile.domain.entity.DataTech import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.presentation.ui.menu.items.medicalCheckup.MedicalCheckupFragment import ru.tele2med.mobile.presentation.ui.menu.items.medicalCheckup.MedicalCheckupFragment
@ -34,7 +31,7 @@ import ru.tele2med.mobile.presentation.ui.menu.items.medicalCheckup.MedicalCheck
class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView { class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView {
override val screenType: ScreenType override val screenType: ScreenType
get() = ScreenType.TECH get() = ScreenType.QR
@InjectPresenter @InjectPresenter
lateinit var presenter: TechCheckupInfoPresenter lateinit var presenter: TechCheckupInfoPresenter
@ -66,12 +63,6 @@ class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView {
is MenuActivity -> { is MenuActivity -> {
(activity as MenuActivity).apply { (activity as MenuActivity).apply {
// addDrawerToggle() // addDrawerToggle()
close.visibility = View.VISIBLE
close.setOnClickListener {
startActivity(intentFor<MenuActivity>().newTask().clearTask())
}
phone.visibility = View.GONE
settings.visibility = View.GONE
showOrHideHelpButton(false) showOrHideHelpButton(false)
title = "" title = ""
} }
@ -83,25 +74,12 @@ class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView {
Log.v("DATA", "data 32 = $DATA_QR") Log.v("DATA", "data 32 = $DATA_QR")
val gson = Gson() val gson = Gson()
val data = gson.fromJson(DATA_QR, DataTech::class.java) val data = gson.fromJson(dataString, DataTech::class.java)
signButton.setOnClickListener {
presenter.goToSign(data)
}
notTest.setOnClickListener {
presenter.goToSign(data)
}
startTest.setOnClickListener {
presenter.updateTech(data.uniq_id, data)
}
// tvDriverTitle.focusable // tvDriverTitle.focusable
// tvDriverTitle.requestFocus() // tvDriverTitle.requestFocus()
presenter.showCheckUp(data.uniq_id) presenter.showCheckUp()
initRecycler() initRecycler()
@ -115,50 +93,38 @@ class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView {
private fun initRecycler() { private fun initRecycler() {
println("initRecycler") println("initRecycler")
val args = requireArguments().getString(DATA_QR) val args = arguments
val index = args?.toString() // getString("data", "")
Log.v( Log.v(
"TechCheckupInfoFragment", "Z $DATA_QR" "TechCheckupInfoFragment", "data = $index ${args?.getString("data")}"
) )
Log.v("TechCheckupInfoFragment", "args = ${arguments?.getString("data")}")
val gson = Gson() val gson = Gson()
val data = gson.fromJson(DATA_QR, DataTech::class.java) val data = gson.fromJson(DATA_QR, DataTech::class.java)
fillData(data) fillData(data)
refresh.setOnRefreshListener { refresh.setOnRefreshListener {
println("setOnRefreshListener") println("setOnRefreshListener")
presenter.showCheckUp(data.uniq_id) presenter.showCheckUp()
} }
startTest.setOnClickListener {
presenter.updateTech(
data.uniq_id,
data.vehicle_id,
data.date_,
data.time_,
data.result_id
)
}
} }
@SuppressLint("StringFormatInvalid") @SuppressLint("StringFormatInvalid")
override fun fillData(dataTech: DataTech) { override fun fillData(dataTech: DataTech) {
when (dataTech.exam_state) {
"1" -> {
notTest.visibility = View.GONE
signButton.visibility = View.GONE
startTest.text = "Начать проверки"
}
"2" -> {
notTest.visibility = View.GONE
signButton.visibility = View.GONE
startTest.text = "Продолжить проверки"
}
"3" -> {
startTest.visibility = View.GONE
}
"4" -> {
startTest.visibility = View.GONE
notTest.visibility = View.GONE
signButton.visibility = View.GONE
}
else -> startTest.text = "Начать проверки"
}
println("СЕРВЕР = ${dataTech.mechanic_name}") println("СЕРВЕР = ${dataTech.mechanic_name}")
var profilePhoto: String var profilePhoto: String
var profilePhotoUrl: Uri var profilePhotoUrl: Uri
@ -169,7 +135,7 @@ class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView {
tvDriverNumber.text = dataTech.vehicle_name tvDriverNumber.text = dataTech.vehicle_name
tvDrivers.text = dataTech.mechanic_name tvDrivers.text = dataTech.mechanic_name
tvOrgName.text = dataTech.organization_name tvOrgName.text = dataTech.organization_id
tvNumberPL.text = dataTech.waybill_name tvNumberPL.text = dataTech.waybill_name
tvDatePL.text = dataTech.datetime tvDatePL.text = dataTech.datetime
@ -187,22 +153,21 @@ class TechCheckupInfoFragment : BaseMenuFragment(), TechCheckupInfoView {
private var DATA_QR = "DATA_QR" private var DATA_QR = "DATA_QR"
fun getInstance(data: DataTech): TechCheckupInfoFragment { fun getInstance(data: DataTech): TechCheckupInfoFragment {
Log.v("getInstance", "data DataTech = $data")
val gson = Gson() val gson = Gson()
val string: String = gson.toJson(data) val string: String = gson.toJson(data)
DATA_QR = string Log.v("COMP", "data = $data")
this.DATA_QR = string
return TechCheckupInfoFragment().also { return TechCheckupInfoFragment().also {
DATA_QR = string Log.v("COMP", "data2 = $data")
it.arguments = Bundle().apply { it.arguments = Bundle().apply {
Log.v("COMP", "data3 = $data")
putString(DATA_QR, string) putString(DATA_QR, string)
}
Log.v("COMP", "data4 = ${it.requireArguments().getString(DATA_QR)}")
} }
Log.v("getInstance", "data DataTech = ${it.requireArguments().getString(DATA_QR)}")
}
} }

View File

@ -5,47 +5,32 @@ import com.arellomobile.mvp.InjectViewState
import com.google.gson.Gson import com.google.gson.Gson
import ru.tele2med.mobile.presentation.ui.base.BasePresenter import ru.tele2med.mobile.presentation.ui.base.BasePresenter
import ru.tele2med.mobile.presentation.ui.base.entity.RestApiCodes import ru.tele2med.mobile.presentation.ui.base.entity.RestApiCodes
import ru.tele2med.mobile.presentation.util.Prefs
import ru.tele2med.mobile.presentation.util.ioToMain import ru.tele2med.mobile.presentation.util.ioToMain
import io.reactivex.rxkotlin.plusAssign import io.reactivex.rxkotlin.plusAssign
import ru.tele2med.mobile.data.api.entity.exception.ApiException import ru.tele2med.mobile.data.api.entity.exception.ApiException
import ru.tele2med.mobile.domain.entity.DataTech import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.domain.interactor.TechInteractor import ru.tele2med.mobile.domain.interactor.TechInteractor
import ru.tele2med.mobile.presentation.router.NavRouter
@InjectViewState @InjectViewState
class TechCheckupInfoPresenter( class TechCheckupInfoPresenter(
private val techInteractor: TechInteractor, private val techInteractor: TechInteractor,
private val navRouter: NavRouter, private val prefs: Prefs,
private val stringId: String private val stringId: String
) : BasePresenter<TechCheckupInfoView>() { ) : BasePresenter<TechCheckupInfoView>() {
override fun onFirstViewAttach() { fun onRefresh() {
super.onFirstViewAttach()
Log.v(
"LOG",
"onFirstViewAttach in TechCheckupInfoPresenter"
)
} }
fun goToSign(dataTech: DataTech) { fun updateTech(id: String, vehicleId: String, date: String, time: String, resultId: String) {
Log.v( Log.v(
"LOG", "LOG",
"goToSign carName = ${dataTech.vehicle_name}" "it id = $id, vehicleId = $vehicleId date = $date, time = $time, resultId = $resultId"
)
navRouter.openSignScreen(dataTech)
}
fun updateTech(uniq_id: String, dataTech: DataTech) {
Log.v(
"LOG",
"showTech uniq_id = $uniq_id,"
) )
disposable += techInteractor disposable += techInteractor
.showTech(uniq_id) .updateTech(id, vehicleId, date, time, resultId)
.ioToMain() .ioToMain()
.doOnSubscribe { .doOnSubscribe {
Log.v("LOG", "it 2 = $it") Log.v("LOG", "it 2 = $it")
@ -53,12 +38,9 @@ class TechCheckupInfoPresenter(
} }
.doAfterTerminate { .doAfterTerminate {
viewState.hideLoading() viewState.hideLoading()
} }
.subscribe({ it -> .subscribe({
var test = it.data.data.first() Log.v("LOG", "it = $it ${it.message}")
navRouter.openTestCheckupScreen(test, uniq_id, dataTech, null)
}, { }, {
if (it is ApiException) { if (it is ApiException) {
@ -70,18 +52,16 @@ class TechCheckupInfoPresenter(
this.handleError(it) this.handleError(it)
} }
}) })
} }
fun showCheckUp(id: String) {
fun showCheckUp() {
val gson = Gson() val gson = Gson()
val data = gson.fromJson(stringId, DataTech::class.java) val data = gson.fromJson(stringId, DataTech::class.java)
println("data RoleName = ${id}") println("data RoleName = ${data}")
get(id)
// viewState.fillData(data) // viewState.fillData(data)
//viewState.setRefreshing(false) viewState.setRefreshing(false)
} }
fun get(code: String) { fun get(code: String) {
@ -97,7 +77,7 @@ class TechCheckupInfoPresenter(
viewState.hideLoading() viewState.hideLoading()
} }
.subscribe({ .subscribe({
viewState.fillData(it.data)
}, { }, {
if (it is ApiException) { if (it is ApiException) {

View File

@ -1,118 +0,0 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.sign
import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.util.Log
import android.view.View
import com.arellomobile.mvp.presenter.InjectPresenter
import com.arellomobile.mvp.presenter.ProvidePresenter
import com.google.gson.Gson
import kotlinx.android.synthetic.main.fragment_checkup_test.*
import kotlinx.android.synthetic.main.fragment_checkup_test.falseBtn
import kotlinx.android.synthetic.main.fragment_checkup_test.trueBtn
import kotlinx.android.synthetic.main.fragment_checkup_test.tvComment
import kotlinx.android.synthetic.main.fragment_checkup_test.tvStatusName
import kotlinx.android.synthetic.main.fragment_checkup_test.tvTestName
import kotlinx.android.synthetic.main.fragment_sign.*
import ru.tele2med.mobile.R
import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.presentation.ui.base.BasePresenter
import ru.tele2med.mobile.presentation.ui.drawer.entity.ScreenType
import ru.tele2med.mobile.presentation.ui.menu.MenuActivity
import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuFragment
import ru.tele2med.mobile.presentation.util.providePresenter
class SignFragment : BaseMenuFragment(), SignView {
override val screenType: ScreenType
get() = ScreenType.TECH
@InjectPresenter
lateinit var presenter: SignPresenter
private var errorDialog: androidx.appcompat.app.AlertDialog? = null
@ProvidePresenter
fun initPresenter(): SignPresenter = providePresenter()
override fun getPresenter(): BasePresenter<*>? = presenter
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
(activity as MenuActivity).apply {
addDrawerToggle()
title = getString(R.string.test_toolbar)
}
// val args = arguments
// val data = args?.toString() // getString("data", "")
Log.v("TestFragment", "args = ${arguments?.getString(TEST)}")
val gson = Gson()
var stringTech = arguments?.getString(TECH)
val dataTech = gson.fromJson(stringTech, DataTech::class.java)
fillData(dataTech)
}
private fun fillData(data: DataTech) {
Log.v("TestFragment", "data = data.name = ${data.vehicle_name}")
tvCarName.text = data.vehicle_name
tvResult.text = data.result_name?: ""
signBtn.setOnClickListener {
presenter.sign(data)
}
}
override fun toBack() {
activity?.onBackPressed()
}
private fun actions(data: DataShow, uniq_id: String, dataTech: DataTech) {
trueBtn.setOnClickListener {
presenter.setValue(uniq_id, data.uniq_id, data, "1", dataTech)
}
falseBtn.setOnClickListener {
presenter.setValue(uniq_id, data.uniq_id, data, "0", dataTech)
}
}
override val layoutId: Int
get() = R.layout.fragment_sign
companion object {
private var TEST = "TEST"
private var UNIQ_ID = "UNIQ_ID"
private var TECH = "TECH"
fun getInstance(dataTech: DataTech): SignFragment {
val gson = Gson()
val stringTech: String = gson.toJson(dataTech)
TECH = stringTech
return SignFragment().also {
it.arguments = Bundle().apply {
putString(TECH, stringTech)
}
}
}
}
}

View File

@ -1,125 +0,0 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.sign
import android.util.Log
import com.arellomobile.mvp.InjectViewState
import io.reactivex.rxkotlin.plusAssign
import ru.tele2med.mobile.data.api.entity.exception.ApiException
import ru.tele2med.mobile.domain.entity.CheckupData
import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.domain.entity.Position
import ru.tele2med.mobile.domain.interactor.TechInteractor
import ru.tele2med.mobile.presentation.router.NavRouter
import ru.tele2med.mobile.presentation.ui.base.entity.RestApiCodes
import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuPresenter
import ru.tele2med.mobile.presentation.util.ioToMain
@InjectViewState
class SignPresenter(
private val techInteractor: TechInteractor,
private val navRouter: NavRouter,
) : BaseMenuPresenter<SignView>() {
private var position: Position? = null
override fun onFirstViewAttach() {
super.onFirstViewAttach()
}
fun sign(dataTech: DataTech) {
Log.v("SIGN", "Подписание с данными ${dataTech.vehicle_name}")
}
fun setValue(
uniq_id: String,
id: String,
dataShow: DataShow,
value: String,
dataTech: DataTech
) {
var checkup = CheckupData(id, dataShow.name ?: "", value, dataShow.type_id ?: "")
var data: List<CheckupData> = listOf(checkup)
Log.v("LOG", "it checkup = $uniq_id, data = $data")
disposable += techInteractor
.updateCheckList(uniq_id, id, data)
.ioToMain()
.doOnSubscribe {
Log.v("LOG", "it 2 = $it")
viewState.showLoading()
}
.doAfterTerminate {
viewState.hideLoading()
// viewState.toBack()
}
.subscribe({
Log.v("LOG", "it = $it ${it.data}")
showTech(uniq_id, dataTech)
}, {
if (it is ApiException) {
if (it.code == RestApiCodes.NotFound.code) {
} else {
this.handleError(it)
}
} else {
this.handleError(it)
}
})
//router.openPhoneEnterScreen()
}
fun showTech(uniq_id: String, dataTech: DataTech) {
Log.v(
"LOG",
"showTech uniq_id = $uniq_id,"
)
disposable += techInteractor
.showTech(uniq_id)
.ioToMain()
.doOnSubscribe {
Log.v("LOG", "it 2 = $it")
viewState.showLoading()
}
.doAfterTerminate {
viewState.hideLoading()
}
.subscribe({ it ->
Log.v("LOG", "showTech ${it.data.data}")
val newShowTech = mutableListOf<DataShow>()
it.data.data.forEach {
Log.v("LOG", "showTech forEach ${it}")
if ((it.value != "1") && (it.value != "0")) {
newShowTech.add(it)
Log.v("LOG", "showTech openTestCheckupScreen ${newShowTech}")
}
}
if (newShowTech.isNotEmpty()) {
navRouter.openTestCheckupScreen(newShowTech.first(), uniq_id, dataTech, null)
} else {
viewState.toBack()
}
// viewState.showCheckups(it.data.data)
}, {
if (it is ApiException) {
if (it.code == RestApiCodes.NotFound.code) {
} else {
this.handleError(it)
}
} else {
this.handleError(it)
}
})
}
}

View File

@ -1,19 +0,0 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.sign
import androidx.fragment.app.Fragment
import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech
import ru.terrakok.cicerone.android.support.SupportAppScreen
class SignScreen(val dataTech: DataTech) : SupportAppScreen() {
override fun getFragment(): Fragment {
return SignFragment.getInstance(
dataTech
)
}
override fun getScreenKey(): String {
return SignFragment::class.java.name
}
}

View File

@ -1,18 +0,0 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.sign
import com.arellomobile.mvp.viewstate.strategy.OneExecutionStateStrategy
import com.arellomobile.mvp.viewstate.strategy.SkipStrategy
import com.arellomobile.mvp.viewstate.strategy.StateStrategyType
import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.presentation.ui.base.BaseView
interface SignView : BaseView {
fun bindTest(test: DataShow) {
}
@StateStrategyType(OneExecutionStateStrategy::class)
fun toBack()
}

View File

@ -15,6 +15,7 @@ import com.arellomobile.mvp.presenter.ProvidePresenter
import com.bumptech.glide.Glide import com.bumptech.glide.Glide
import com.google.gson.Gson import com.google.gson.Gson
import com.squareup.picasso.Picasso import com.squareup.picasso.Picasso
import kotlinx.android.synthetic.main.fragment_tech_list.*
import ru.tele2med.mobile.R import ru.tele2med.mobile.R
import ru.tele2med.mobile.presentation.ui.base.BasePresenter import ru.tele2med.mobile.presentation.ui.base.BasePresenter
import ru.tele2med.mobile.presentation.ui.drawer.entity.ScreenType import ru.tele2med.mobile.presentation.ui.drawer.entity.ScreenType
@ -25,9 +26,6 @@ import ru.tele2med.mobile.presentation.util.providePresenter
import kotlinx.android.synthetic.main.fragment_test_list.* import kotlinx.android.synthetic.main.fragment_test_list.*
import kotlinx.android.synthetic.main.fragment_test_list.recyclerView import kotlinx.android.synthetic.main.fragment_test_list.recyclerView
import kotlinx.android.synthetic.main.toolbar_with_help.* import kotlinx.android.synthetic.main.toolbar_with_help.*
import org.jetbrains.anko.clearTask
import org.jetbrains.anko.intentFor
import org.jetbrains.anko.newTask
import ru.tele2med.mobile.domain.entity.* import ru.tele2med.mobile.domain.entity.*
import ru.tele2med.mobile.presentation.ui.common.EndlessRecyclerViewScrollListener import ru.tele2med.mobile.presentation.ui.common.EndlessRecyclerViewScrollListener
@ -53,13 +51,7 @@ class TechCheckupTestsFragment : BaseMenuFragment(), TechCheckupTestsView {
private val adapter: TestListAdapter by lazy { private val adapter: TestListAdapter by lazy {
TestListAdapter { test -> TestListAdapter { test ->
val gson = Gson() presenter.get(test)
presenter.get(
test,
gson.fromJson(DATA_QR, DataTech::class.java).uniq_id,
gson.fromJson(DATA_QR, DataTech::class.java)
)
} }
} }
@ -81,12 +73,6 @@ class TechCheckupTestsFragment : BaseMenuFragment(), TechCheckupTestsView {
} }
is MenuActivity -> { is MenuActivity -> {
(activity as MenuActivity).apply { (activity as MenuActivity).apply {
close.visibility = View.VISIBLE
close.setOnClickListener {
startActivity(intentFor<MenuActivity>().newTask().clearTask())
}
phone.visibility = View.GONE
settings.visibility = View.GONE
// addDrawerToggle() // addDrawerToggle()
showOrHideHelpButton(false) showOrHideHelpButton(false)
title = "" title = ""
@ -164,10 +150,7 @@ class TechCheckupTestsFragment : BaseMenuFragment(), TechCheckupTestsView {
putString(TechCheckupTestsFragment.DATA_QR, string) putString(TechCheckupTestsFragment.DATA_QR, string)
} }
Log.v( Log.v("COMP", "data4 = ${it.requireArguments().getString(TechCheckupTestsFragment.DATA_QR)}")
"COMP",
"data4 = ${it.requireArguments().getString(TechCheckupTestsFragment.DATA_QR)}"
)
} }
} }

View File

@ -40,15 +40,12 @@ class TechCheckupTestsPresenter(
} }
.doAfterTerminate { .doAfterTerminate {
viewState.hideLoading() viewState.hideLoading()
viewState.setRefreshing(false)
} }
.subscribe({ .subscribe({
viewState.hideLoading()
Log.v("LOG", "it = $it ${it.data.data}") Log.v("LOG", "it = $it ${it.data.data}")
viewState.showCheckups(it.data.data) viewState.showCheckups(it.data.data)
viewState.setRefreshing(false)
}, { }, {
if (it is ApiException) { if (it is ApiException) {
@ -62,9 +59,9 @@ class TechCheckupTestsPresenter(
}) })
} }
fun get(test: DataShow, uniq_id: String, dataTech: DataTech) { fun get(test: DataShow) {
println("TechCheckupTestsPresenter ${test.uniq_id}") println("TechCheckupTestsPresenter ${test.uniq_id}")
navRouter.openTestCheckupScreen(test, uniq_id, dataTech, null) navRouter.openTestCheckupScreen(test)
} }

View File

@ -1,32 +1,29 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test
import android.os.Bundle import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.util.Log import android.util.Log
import android.view.View import android.view.View
import com.arellomobile.mvp.presenter.InjectPresenter import com.arellomobile.mvp.presenter.InjectPresenter
import com.arellomobile.mvp.presenter.ProvidePresenter import com.arellomobile.mvp.presenter.ProvidePresenter
import com.google.gson.Gson import com.google.gson.Gson
import kotlinx.android.synthetic.main.fragment_checkup_test.* import kotlinx.android.synthetic.main.fragment_checkup_test.*
import kotlinx.android.synthetic.main.toolbar_with_help.*
import org.jetbrains.anko.clearTask
import org.jetbrains.anko.intentFor
import org.jetbrains.anko.newTask
import ru.tele2med.mobile.R import ru.tele2med.mobile.R
import ru.tele2med.mobile.domain.entity.CheckupShowList import ru.tele2med.mobile.domain.entity.Data
import ru.tele2med.mobile.domain.entity.DataShow import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech import ru.tele2med.mobile.domain.entity.DataTech
import ru.tele2med.mobile.presentation.ui.base.BasePresenter import ru.tele2med.mobile.presentation.ui.base.BasePresenter
import ru.tele2med.mobile.presentation.ui.drawer.entity.ScreenType import ru.tele2med.mobile.presentation.ui.drawer.entity.ScreenType
import ru.tele2med.mobile.presentation.ui.menu.MenuActivity import ru.tele2med.mobile.presentation.ui.menu.MenuActivity
import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuFragment import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuFragment
import ru.tele2med.mobile.presentation.ui.menu.items.result.ResFragment
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.TechCheckupFragment
import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.info.TechCheckupInfoFragment
import ru.tele2med.mobile.presentation.util.providePresenter import ru.tele2med.mobile.presentation.util.providePresenter
class TestFragment : BaseMenuFragment(), TestView { class TestFragment : BaseMenuFragment(), TestView {
override val screenType: ScreenType override val screenType: ScreenType
get() = ScreenType.TECH get() = ScreenType.WITHOUT_BORDER
@InjectPresenter @InjectPresenter
lateinit var presenter: TestPresenter lateinit var presenter: TestPresenter
@ -44,82 +41,23 @@ class TestFragment : BaseMenuFragment(), TestView {
(activity as MenuActivity).apply { (activity as MenuActivity).apply {
addDrawerToggle() addDrawerToggle()
title = getString(R.string.test_toolbar) title = getString(R.string.test_toolbar)
close.visibility = View.VISIBLE
close.setOnClickListener {
activity?.onBackPressed()
}
} }
// val args = arguments val args = arguments
// val data = args?.toString() // getString("data", "") val data = args?.toString() // getString("data", "")
Log.v("TestFragment", "args = ${arguments?.getString(TEST)}") Log.v("TestFragment", "args = ${arguments?.getString("data")}")
val gson = Gson() val gson = Gson()
val dataTest = gson.fromJson(TEST, DataShow::class.java)
var stringTech = arguments?.getString(TECH) fillData(dataTest)
val dataTech = gson.fromJson(stringTech, DataTech::class.java)
if (arguments?.getString(TEST) == null) {
Handler(Looper.getMainLooper()).post {
presenter.toTech(dataTech)
// interact with ViewPager here
}
// toBack()
} else {
var dataString = arguments?.getString(TEST)
val data = gson.fromJson(dataString, DataShow::class.java)
var checkupShowList = arguments?.getString(CHECKUP)
val datacheckupShowList = gson.fromJson(checkupShowList, CheckupShowList::class.java)
var uniq_id = arguments?.getString(UNIQ_ID)
// val gson = Gson()
// val dataTest = gson.fromJson(TEST, DataShow::class.java)
fillData(data, datacheckupShowList)
actions(data, uniq_id ?: "", dataTech, datacheckupShowList)
}
} }
private fun fillData(data: DataShow) {
private fun fillData(data: DataShow, checkupShowList: CheckupShowList?) {
Log.v("TestFragment", "data = data.name = ${data.name}") Log.v("TestFragment", "data = data.name = ${data.name}")
tvTestName.text = data.name tvTestName.text = data.name
tvComment.text = data.comment
tvStatusName.text =
checkupShowList?.data?.exam_state_description ?: "Вопрос №${data.order.toInt() + 1}"
}
override fun toBack() {
activity?.onBackPressed()
}
private fun actions(
data: DataShow,
uniq_id: String,
dataTech: DataTech,
checkupShowList: CheckupShowList?
) {
skipBtn.setOnClickListener {
presenter.skipTech(uniq_id, dataTech, checkupShowList, data)
}
trueBtn.setOnClickListener {
presenter.setValue(uniq_id, data.uniq_id, data, "1", dataTech)
}
falseBtn.setOnClickListener {
presenter.setValue(uniq_id, data.uniq_id, data, "0", dataTech)
}
} }
@ -127,35 +65,14 @@ class TestFragment : BaseMenuFragment(), TestView {
get() = R.layout.fragment_checkup_test get() = R.layout.fragment_checkup_test
companion object { companion object {
private var TEST = "TEST" private const val TEST = "TEST"
private var UNIQ_ID = "UNIQ_ID"
private var TECH = "TECH"
private var CHECKUP = "CHECKUP"
fun getInstance(test: DataShow): TestFragment {
fun getInstance(
test: DataShow,
uniq_id: String,
dataTech: DataTech,
checkupShowList: CheckupShowList?
): TestFragment {
val gson = Gson() val gson = Gson()
val string: String = gson.toJson(test) val string: String = gson.toJson(test)
this.TEST = string
val stringTech: String = gson.toJson(dataTech)
this.TECH = stringTech
val checkupShowListCommon: String = gson.toJson(checkupShowList)
this.CHECKUP = checkupShowListCommon
return TestFragment().also { return TestFragment().also {
it.arguments = Bundle().apply { it.arguments = Bundle().apply {
putString(TEST, string) putString(TEST, string)
putString(UNIQ_ID, uniq_id)
putString(TECH, stringTech)
putString(CHECKUP, checkupShowListCommon)
} }
} }

View File

@ -1,203 +1,26 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test
import android.util.Log
import com.arellomobile.mvp.InjectViewState import com.arellomobile.mvp.InjectViewState
import io.reactivex.rxkotlin.plusAssign import ru.tele2med.mobile.domain.entity.Position
import ru.tele2med.mobile.data.api.entity.exception.ApiException import ru.tele2med.mobile.domain.interactor.SosInteractor
import ru.tele2med.mobile.domain.entity.* import ru.tele2med.mobile.presentation.Changes
import ru.tele2med.mobile.domain.interactor.TechInteractor
import ru.tele2med.mobile.presentation.router.NavRouter import ru.tele2med.mobile.presentation.router.NavRouter
import ru.tele2med.mobile.presentation.ui.base.entity.RestApiCodes
import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuPresenter import ru.tele2med.mobile.presentation.ui.menu.base.BaseMenuPresenter
import ru.tele2med.mobile.presentation.util.ioToMain import ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test.TestView
@InjectViewState @InjectViewState
class TestPresenter( class TestPresenter(
private val techInteractor: TechInteractor, private val sosInteractor: SosInteractor,
private val navRouter: NavRouter private val navRouter: NavRouter,
private val changes: Changes
) : BaseMenuPresenter<TestView>() { ) : BaseMenuPresenter<TestView>() {
private var position: Position? = null private var position: Position? = null
override fun onFirstViewAttach() { override fun onFirstViewAttach() {
super.onFirstViewAttach() super.onFirstViewAttach()
}
fun toTech(dataTech: DataTech) {
navRouter.openTechCheckupScreen(dataTech)
} }
fun setValue(
uniq_id: String,
id: String,
dataShow: DataShow,
value: String,
dataTech: DataTech
) {
var checkup = CheckupData(id, dataShow.name ?: "", value, dataShow.type_id ?: "")
var data: List<CheckupData> = listOf(checkup)
Log.v("LOG", "it checkup = $uniq_id, data = $data")
disposable += techInteractor
.updateCheckList(uniq_id, id, data)
.ioToMain()
.doOnSubscribe {
Log.v("LOG", "it 2 = $it")
// viewState.showLoading()
}
.doAfterTerminate {
viewState.hideLoading()
// viewState.toBack()
}
.subscribe({
Log.v("LOG", "it = $it ${it.data}")
if (it.data.count_checked != it.data.count_all.toInt()) {
showTech(uniq_id, dataTech, it, dataShow)
} else {
viewState.toBack()
}
}, {
if (it is ApiException) {
if (it.code == RestApiCodes.NotFound.code) {
} else {
this.handleError(it)
}
} else {
this.handleError(it)
}
})
//router.openPhoneEnterScreen()
}
fun showTech(
uniq_id: String,
dataTech: DataTech,
checkupShowList: CheckupShowList?,
dataShow: DataShow
) {
Log.v(
"LOG",
"showTech uniq_id = $uniq_id,"
)
disposable += techInteractor
.showTech(uniq_id)
.ioToMain()
.doOnSubscribe {
Log.v("LOG", "it 2 = $it")
viewState.showLoading()
}
.doAfterTerminate {
viewState.hideLoading()
}
.subscribe({ it ->
Log.v("LOG", "showTech ${it.data.data}")
val newShowTech = mutableListOf<DataShow>()
it.data.data.forEach {
Log.v("LOG", "showTech forEach ${it}")
if ((it.value != "1") && (it.value != "0") && (it.id != dataShow.id)) {
newShowTech.add(it)
Log.v("LOG", "showTech openTestCheckupScreen ${newShowTech}")
}
}
if (newShowTech.isNotEmpty()) {
navRouter.openTestCheckupScreen(
newShowTech.first(),
uniq_id,
dataTech,
checkupShowList
)
} else {
viewState.toBack()
}
// viewState.showCheckups(it.data.data)
}, {
if (it is ApiException) {
if (it.code == RestApiCodes.NotFound.code) {
} else {
this.handleError(it)
}
} else {
this.handleError(it)
}
})
}
fun skipTech(
uniq_id: String,
dataTech: DataTech,
checkupShowList: CheckupShowList?,
dataShow: DataShow
) {
Log.v(
"LOG",
"skipTech uniq_id = $uniq_id,"
)
disposable += techInteractor
.showTech(uniq_id)
.ioToMain()
.doOnSubscribe {
Log.v("LOG", "it 2 = $it")
// viewState.showLoading()
}
.doAfterTerminate {
viewState.hideLoading()
}
.subscribe({ it ->
Log.v("LOG", "skipTech ${it.data.data}")
val newShowTech = mutableListOf<DataShow>()
for (i in 0 until it.data.data.size) {
if (it.data.data[i] == dataShow) {
if (i+1 != it.data.data.size) {
navRouter.openTestCheckupScreen(
it.data.data[i + 1],
uniq_id,
dataTech,
null
)
}
else {
navRouter.openTestCheckupScreen(
it.data.data[0],
uniq_id,
dataTech,
null
)
}
}
}
}, {
if (it is ApiException) {
if (it.code == RestApiCodes.NotFound.code) {
} else {
this.handleError(it)
}
} else {
this.handleError(it)
}
})
}
} }

View File

@ -1,15 +1,13 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import ru.tele2med.mobile.domain.entity.CheckupShowList
import ru.tele2med.mobile.domain.entity.DataShow import ru.tele2med.mobile.domain.entity.DataShow
import ru.tele2med.mobile.domain.entity.DataTech
import ru.terrakok.cicerone.android.support.SupportAppScreen import ru.terrakok.cicerone.android.support.SupportAppScreen
class TestScreen(val test: DataShow, val uniq_id: String, val dataTech: DataTech, val checkupShowList: CheckupShowList?) : SupportAppScreen() { class TestScreen(val test: DataShow) : SupportAppScreen() {
override fun getFragment(): Fragment { override fun getFragment(): Fragment {
return TestFragment.getInstance(test, uniq_id, dataTech, checkupShowList) return TestFragment.getInstance(test)
} }
override fun getScreenKey(): String { override fun getScreenKey(): String {

View File

@ -1,6 +1,5 @@
package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test package ru.tele2med.mobile.presentation.ui.menu.items.tech.list.techCheckup.tests.test
import com.arellomobile.mvp.viewstate.strategy.OneExecutionStateStrategy
import com.arellomobile.mvp.viewstate.strategy.SkipStrategy import com.arellomobile.mvp.viewstate.strategy.SkipStrategy
import com.arellomobile.mvp.viewstate.strategy.StateStrategyType import com.arellomobile.mvp.viewstate.strategy.StateStrategyType
import ru.tele2med.mobile.domain.entity.DataShow import ru.tele2med.mobile.domain.entity.DataShow
@ -9,10 +8,7 @@ import ru.tele2med.mobile.presentation.ui.base.BaseView
interface TestView : BaseView { interface TestView : BaseView {
fun bindTest(test: DataShow) { fun bindTest(test: DataShow) {
} }
@StateStrategyType(OneExecutionStateStrategy::class)
fun toBack()
} }

View File

@ -14,7 +14,7 @@ import ru.tele2med.mobile.presentation.util.providePresenter
class ParkFragment : BaseMenuFragment(), ParkView { class ParkFragment : BaseMenuFragment(), ParkView {
override val screenType: ScreenType override val screenType: ScreenType
get() = ScreenType.TECH get() = ScreenType.WITHOUT_BORDER
@InjectPresenter @InjectPresenter
lateinit var presenter: ParkPresenter lateinit var presenter: ParkPresenter

View File

@ -36,18 +36,6 @@
android:layout_marginEnd="20dp" android:layout_marginEnd="20dp"
tools:visibility="visible" tools:visibility="visible"
android:layout_marginTop="10dp" android:layout_marginTop="10dp"
app:layout_constraintEnd_toStartOf="@+id/close"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/close"
android:layout_width="26dp"
android:layout_height="26dp"
android:layout_marginEnd="20dp"
android:layout_marginTop="10dp"
android:visibility="gone"
android:src="@drawable/ic_xmark_solid"
tools:visibility="visible"
app:layout_constraintEnd_toStartOf="@+id/settings" app:layout_constraintEnd_toStartOf="@+id/settings"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />
@ -63,8 +51,6 @@
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />
<ImageView <ImageView
android:id="@+id/logo" android:id="@+id/logo"
android:layout_width="188dp" android:layout_width="188dp"

View File

@ -37,22 +37,9 @@
android:layout_marginEnd="20dp" android:layout_marginEnd="20dp"
android:src="@drawable/ic_help_green" android:src="@drawable/ic_help_green"
android:visibility="gone" android:visibility="gone"
app:layout_constraintEnd_toStartOf="@+id/close"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/close"
android:layout_width="26dp"
android:layout_height="26dp"
android:layout_marginTop="10dp"
tools:visibility="visible"
android:layout_marginEnd="20dp"
android:src="@drawable/ic_xmark_solid"
android:visibility="gone"
app:layout_constraintEnd_toStartOf="@+id/settings" app:layout_constraintEnd_toStartOf="@+id/settings"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />
<ImageView <ImageView
android:id="@+id/settings" android:id="@+id/settings"
android:layout_width="26dp" android:layout_width="26dp"

View File

@ -213,12 +213,10 @@
<TextView <TextView
android:id="@+id/tvStatusName" android:id="@+id/tvStatusName"
style="@style/BlockValueStyle" style="@style/BlockValueTitleStyle"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="Проверка 0 из 0" android:text="Проверка 0 из 0"
android:layout_marginBottom="20dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tvStatusInfoTitle" /> app:layout_constraintTop_toBottomOf="@id/tvStatusInfoTitle" />

View File

@ -76,6 +76,7 @@
app:layout_constraintTop_toTopOf="@id/checkupsBody"> app:layout_constraintTop_toTopOf="@id/checkupsBody">
<androidx.constraintlayout.widget.ConstraintLayout <androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content"> android:layout_height="wrap_content">
@ -89,7 +90,6 @@
android:focusable="true" android:focusable="true"
android:focusableInTouchMode="true" android:focusableInTouchMode="true"
android:text="Путевой лист:" android:text="Путевой лист:"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />
@ -171,7 +171,6 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="Номер ПЛ" android:text="Номер ПЛ"
android:visibility="gone"
app:layout_constraintTop_toBottomOf="@+id/divider4" /> app:layout_constraintTop_toBottomOf="@+id/divider4" />
<TextView <TextView
@ -179,7 +178,6 @@
style="@style/BlockValueStyle" style="@style/BlockValueStyle"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:visibility="gone"
app:layout_constraintTop_toBottomOf="@id/tvNumberPLTitle" app:layout_constraintTop_toBottomOf="@id/tvNumberPLTitle"
tools:text="23" /> tools:text="23" />
@ -188,7 +186,6 @@
style="@style/BlockValueDividerStyle" style="@style/BlockValueDividerStyle"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="1dp" android:layout_height="1dp"
android:visibility="gone"
app:layout_constraintTop_toBottomOf="@id/tvNumberPL" /> app:layout_constraintTop_toBottomOf="@id/tvNumberPL" />
<TextView <TextView
@ -197,7 +194,6 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="Дата ПЛ" android:text="Дата ПЛ"
android:visibility="gone"
app:layout_constraintTop_toBottomOf="@+id/divider5" /> app:layout_constraintTop_toBottomOf="@+id/divider5" />
<TextView <TextView
@ -205,7 +201,6 @@
style="@style/BlockValueStyle" style="@style/BlockValueStyle"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:visibility="gone"
app:layout_constraintTop_toBottomOf="@id/tvDatePLTitle" app:layout_constraintTop_toBottomOf="@id/tvDatePLTitle"
tools:text="18.04.2024" /> tools:text="18.04.2024" />
@ -217,6 +212,9 @@
app:layout_constraintTop_toBottomOf="@id/tvDatePL" /> app:layout_constraintTop_toBottomOf="@id/tvDatePL" />
</androidx.constraintlayout.widget.ConstraintLayout> </androidx.constraintlayout.widget.ConstraintLayout>
</com.google.android.material.card.MaterialCardView> </com.google.android.material.card.MaterialCardView>
@ -226,42 +224,17 @@
android:id="@+id/startTest" android:id="@+id/startTest"
android:layout_width="200dp" android:layout_width="200dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:background="@drawable/btn_rounded_blue"
android:text="Начать проверки" android:text="Начать проверки"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="12sp" android:textSize="12sp"
android:background="@drawable/btn_rounded_blue"
android:layout_marginTop="16dp"
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/cvMainInfoContainer" /> app:layout_constraintTop_toBottomOf="@+id/cvMainInfoContainer" />
<Button
android:id="@+id/signButton"
android:layout_width="200dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:background="@drawable/btn_rounded_blue"
android:text="Допустить и подписать"
android:textColor="@color/white"
android:textSize="12sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/startTest" />
<Button
android:id="@+id/notTest"
android:layout_width="200dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:background="@drawable/btn_rounded_blue"
android:text="Не допустить и подписать"
android:textColor="@color/white"
android:textSize="12sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/signButton" />
</androidx.constraintlayout.widget.ConstraintLayout> </androidx.constraintlayout.widget.ConstraintLayout>
@ -273,6 +246,7 @@
app:layout_constraintTop_toBottomOf="@id/checkupsBody"> app:layout_constraintTop_toBottomOf="@id/checkupsBody">
<androidx.constraintlayout.widget.ConstraintLayout <androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content"> android:layout_height="wrap_content">
@ -290,7 +264,7 @@
<TextView <TextView
android:id="@+id/tvStatusName" android:id="@+id/tvStatusName"
style="@style/BlockValueStyle" style="@style/BlockValueTitleStyle"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="В работе" android:text="В работе"
@ -300,12 +274,10 @@
<TextView <TextView
android:id="@+id/tvStatusTest" android:id="@+id/tvStatusTest"
style="@style/BlockValueStyle" style="@style/BlockValueTitleStyle"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginBottom="20dp"
android:text="Продено 2 проверки" android:text="Продено 2 проверки"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tvStatusName" /> app:layout_constraintTop_toBottomOf="@id/tvStatusName" />
@ -316,6 +288,7 @@
</androidx.constraintlayout.widget.ConstraintLayout> </androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView> </ScrollView>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout> </androidx.swiperefreshlayout.widget.SwipeRefreshLayout>

View File

@ -7,12 +7,6 @@
android:orientation="vertical"> android:orientation="vertical">
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/refresh"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<androidx.recyclerview.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView" android:id="@+id/recyclerView"
@ -23,7 +17,6 @@
android:clipToPadding="false" android:clipToPadding="false"
android:paddingTop="4dp" android:paddingTop="4dp"
tools:listitem="@layout/item_checkup" /> tools:listitem="@layout/item_checkup" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</RelativeLayout> </RelativeLayout>

View File

@ -10,8 +10,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:background="@color/white"
android:background="@color/white"> android:layout_height="match_parent">
<TextView <TextView
@ -26,8 +26,8 @@
android:id="@+id/ivEye" android:id="@+id/ivEye"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginEnd="10dp"
android:visibility="gone" android:visibility="gone"
android:layout_marginEnd="10dp"
app:layout_constraintEnd_toStartOf="@+id/tvStatus" app:layout_constraintEnd_toStartOf="@+id/tvStatus"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toTopOf="parent"
tools:src="@drawable/ic_green_eye" /> tools:src="@drawable/ic_green_eye" />
@ -36,9 +36,9 @@
android:id="@+id/ivBattery" android:id="@+id/ivBattery"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="@+id/tvFio" app:layout_constraintBottom_toBottomOf="@+id/tvFio"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
android:visibility="gone"
app:layout_constraintTop_toTopOf="@+id/tvFio" app:layout_constraintTop_toTopOf="@+id/tvFio"
tools:src="@drawable/ic_battery_low" /> tools:src="@drawable/ic_battery_low" />
@ -51,7 +51,7 @@
android:textColor="@color/gray_checkups" android:textColor="@color/gray_checkups"
android:textSize="18sp" android:textSize="18sp"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tvStatus" app:layout_constraintTop_toTopOf="parent"
tools:text="Х727ХХ716 (Aurus)" /> tools:text="Х727ХХ716 (Aurus)" />
<ImageView <ImageView

View File

@ -35,18 +35,6 @@
android:src="@drawable/ic_help_green" android:src="@drawable/ic_help_green"
android:visibility="gone" android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@+id/close"
app:layout_constraintTop_toTopOf="parent"
tools:visibility="visible" />
<ImageView
android:id="@+id/close"
android:layout_width="26dp"
android:layout_height="26dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_xmark_solid"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@+id/settings" app:layout_constraintEnd_toStartOf="@+id/settings"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toTopOf="parent"
tools:visibility="visible" /> tools:visibility="visible" />

View File

@ -286,7 +286,6 @@
<string name="status">Статус</string> <string name="status">Статус</string>
<string name="main">Проведение измерения</string> <string name="main">Проведение измерения</string>
<string name="tech">Проведение Тех. осмотра</string>
<string name="message_select_route">Выберите путевой лист или задание</string> <string name="message_select_route">Выберите путевой лист или задание</string>
<string name="message_select_task">Выберите путевой лист</string> <string name="message_select_task">Выберите путевой лист</string>

View File

@ -286,7 +286,6 @@
<string name="status">Статус</string> <string name="status">Статус</string>
<string name="main">Проведение измерения</string> <string name="main">Проведение измерения</string>
<string name="tech">Проведение Тех. осмотра</string>
<string name="message_select_route">Выберите путевой лист или задание</string> <string name="message_select_route">Выберите путевой лист или задание</string>
<string name="message_select_task">Выберите путевой лист</string> <string name="message_select_task">Выберите путевой лист</string>