-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
#91/feature/jsp/app enhancement3
- Loading branch information
Showing
52 changed files
with
692 additions
and
167 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
app/src/main/java/com/android/mediproject/NetworkStateDialogFragment.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package com.android.mediproject | ||
|
||
import android.os.Bundle | ||
import android.view.LayoutInflater | ||
import android.view.View | ||
import android.view.ViewGroup | ||
import com.android.mediproject.databinding.ViewNetworkStateBinding | ||
import com.google.android.material.bottomsheet.BottomSheetDialogFragment | ||
import dagger.hilt.android.AndroidEntryPoint | ||
|
||
@AndroidEntryPoint | ||
class NetworkStateDialogFragment : BottomSheetDialogFragment() { | ||
|
||
private var _binding: ViewNetworkStateBinding? = null | ||
|
||
private val binding get() = _binding!! | ||
|
||
override fun onCreateView( | ||
inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle? | ||
): View = ViewNetworkStateBinding.inflate(layoutInflater, container, false).also { | ||
_binding = it | ||
}.root | ||
|
||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) { | ||
super.onViewCreated(view, savedInstanceState) | ||
binding.okButton.setOnClickListener { | ||
dismiss() | ||
requireActivity().finish() | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
style="@style/ModalBottomSheetDialog" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:backgroundTint="@color/white" | ||
android:gravity="center" | ||
android:orientation="vertical" | ||
android:paddingHorizontal="24dp" | ||
android:paddingVertical="24dp" | ||
app:layout_behavior="com.google.android.material.bottomsheet.BottomSheetBehavior"> | ||
|
||
<TextView | ||
android:id="@+id/messageTextView" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:layout_marginBottom="16dp" | ||
android:gravity="center" | ||
android:text="@string/noInternetConnection" | ||
android:textSize="22sp" /> | ||
|
||
<Button | ||
android:id="@+id/okButton" | ||
android:layout_width="match_parent" | ||
android:layout_height="wrap_content" | ||
android:backgroundTint="@color/main" | ||
android:text="@string/confirm" /> | ||
|
||
</LinearLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,15 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<resources> | ||
|
||
<style name="ModalBottomSheet" parent="Widget.Material3.BottomSheet.Modal"> | ||
<item name="android:backgroundTint">@color/white</item> | ||
<item name="behavior_hideable">false</item> | ||
<item name="behavior_draggable">false</item> | ||
</style> | ||
|
||
<style name="ModalBottomSheetDialog" parent="ThemeOverlay.Material3.BottomSheetDialog"> | ||
<item name="bottomSheetStyle">@style/ModalBottomSheet</item> | ||
</style> | ||
|
||
|
||
</resources> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 12 additions & 2 deletions
14
...m/android/mediproject/core/data/remote/interestedmedicine/InterestedMedicineRepository.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,19 @@ | ||
package com.android.mediproject.core.data.remote.interestedmedicine | ||
|
||
|
||
import com.android.mediproject.core.model.medicine.InterestedMedicine.InterestedMedicineListResponse | ||
import com.android.mediproject.core.model.interestedmedicine.DeleteInterestedMedicineResponse | ||
import com.android.mediproject.core.model.interestedmedicine.InterestedMedicineListResponse | ||
import com.android.mediproject.core.model.interestedmedicine.IsInterestedMedicineResponse | ||
import com.android.mediproject.core.model.interestedmedicine.NewInterestedMedicineResponse | ||
import com.android.mediproject.core.model.requestparameters.AddInterestedMedicineParameter | ||
import kotlinx.coroutines.flow.Flow | ||
|
||
interface InterestedMedicineRepository { | ||
suspend fun getInterestedMedicineList() : Flow<Result<List<InterestedMedicineListResponse.Medicine>>> | ||
suspend fun getInterestedMedicineList(): Flow<Result<List<InterestedMedicineListResponse.Medicine>>> | ||
|
||
fun addInterestedMedicine(addInterestedMedicineParameter: AddInterestedMedicineParameter): Flow<Result<NewInterestedMedicineResponse>> | ||
|
||
fun deleteInterestedMedicine(medicineId: Long): Flow<Result<DeleteInterestedMedicineResponse>> | ||
|
||
fun isInterestedMedicine(itemSeq: Long): Flow<Result<IsInterestedMedicineResponse>> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.