Addchild key when parent adding child

Logging-out user when success is 4 for session expired

WebView for Terms and conditions and privacy policy

DisclaimerActivity and showing static content

Notification count view and showing count from user data

MoreActivity - Song api integration and showing songs
This commit is contained in:
2024-06-07 20:35:58 +05:30
parent 8cf0ee1c28
commit e4c050eec7
30 changed files with 742 additions and 82 deletions

View File

@@ -78,7 +78,7 @@ class SelectAvatarFragment : Fragment() {
val registerRequestData = with(viewModel){
RegisterRequestData(
add_child = "0",
add_child = if (viewModel.addChildIntent) "1" else "0",
avtar = adapter?.avatarList?.get(selectedAvatarPos!!)?.avatar_name,
birthdate = SimpleDateFormat("yyyy-MM-dd", Locale.getDefault()).format(selectedDOB.time),
email = email,

View File

@@ -132,6 +132,7 @@ class SignUpFragment : Fragment() {
passwordTitle.text = getString(R.string.password)
viewModel.email = email
viewModel.addChildIntent = true
}
}
}

View File

@@ -95,9 +95,13 @@ class SplashFragment : Fragment(), Observer<ApiResult<UserDataResponse>?> {
if (userPrefs?.userType == UserType.NONE){
// none of the user is logged in
// going through normal onboard process
val extras = FragmentNavigatorExtras(binding.logo to "logo")
findNavController().navigate(R.id.action_splashFragment_to_languageFragment,
null, null, extras)
try {
val extras = FragmentNavigatorExtras(binding.logo to "logo")
findNavController().navigate(R.id.action_splashFragment_to_languageFragment,
null, null, extras)
} catch (e: Exception) {
// do nothing
}
}else{
// going to home activity as any of the user is logged in
activity?.let {

View File

@@ -36,6 +36,8 @@ class OnboardViewModel: ViewModel(){
var name: String? = null
var password: String? = null
var addChildIntent: Boolean = false
var childList: List<Child>? = null
val interestTopics = mutableSetOf<Int>()