bye
This commit is contained in:
parent
6c2224d040
commit
c8b695332d
|
@ -12,7 +12,7 @@ data class UserData (
|
|||
|
||||
data class Data (
|
||||
val id: Long? = null,
|
||||
val name: String? = null,
|
||||
var name: String? = null,
|
||||
val email: String? = null,
|
||||
|
||||
@SerializedName("phone_number")
|
||||
|
|
|
@ -157,13 +157,11 @@ class AddSiteFragment : Fragment() {
|
|||
if (imageUri != null) {
|
||||
binding.llUploadImage.gone()
|
||||
binding.cardImage.visible()
|
||||
binding.ivSetImage.setImageURI(imageUri)
|
||||
Glide.with(this).load(imageUri).into(binding.ivSetImage)
|
||||
binding.ivCloseImage.visible()
|
||||
} else {
|
||||
Toast.makeText(requireContext(), "Image URI is null", Toast.LENGTH_SHORT).show()
|
||||
|
||||
fileToUpload=uriToFile(imageUri!!,requireActivity());
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(requireContext(), "Failed to capture image", Toast.LENGTH_SHORT).show()
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -23,6 +23,7 @@ import androidx.core.content.FileProvider
|
|||
import androidx.core.net.toUri
|
||||
import androidx.fragment.app.viewModels
|
||||
import androidx.lifecycle.Observer
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import androidx.navigation.fragment.findNavController
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.consultantapp.data.network.responseUtil.Status
|
||||
|
@ -45,6 +46,8 @@ import com.example.fieldagent.utils.uriToFile
|
|||
import com.example.fieldagent.utils.visible
|
||||
import com.google.gson.Gson
|
||||
import dagger.hilt.android.AndroidEntryPoint
|
||||
import kotlinx.coroutines.delay
|
||||
import kotlinx.coroutines.launch
|
||||
import okhttp3.MediaType.Companion.toMediaType
|
||||
import okhttp3.MultipartBody
|
||||
import okhttp3.RequestBody
|
||||
|
@ -91,6 +94,7 @@ class DamageDetailsFragment : Fragment() {
|
|||
private var from="add";
|
||||
private var clickPosition=-1;
|
||||
private var damageId:String="";
|
||||
|
||||
override fun onCreateView(
|
||||
inflater: LayoutInflater, container: ViewGroup?,
|
||||
savedInstanceState: Bundle?
|
||||
|
@ -99,6 +103,46 @@ class DamageDetailsFragment : Fragment() {
|
|||
return binding.root
|
||||
}
|
||||
|
||||
/* override fun onSaveInstanceState(outState: Bundle) {
|
||||
super.onSaveInstanceState(outState)
|
||||
outState.putString("etItemValue", binding.etItemValue.text.toString())
|
||||
outState.putString("etItemQuantity", binding.etItemQuantity.text.toString())
|
||||
outState.putString("autoCompleteMain", binding.autoCompleteMain.text.toString())
|
||||
outState.putString("autoCompleteSub", binding.autoCompleteSub.text.toString())
|
||||
outState.putString("autoCompleteUnits", binding.autoCompleteUnits.text.toString())
|
||||
Log.e("Checkkkkkkkskksks=2=>","${binding.autoCompleteSub.text.toString()}")
|
||||
val positionToReplace = imageList.indexOfFirst { it == null }
|
||||
if (positionToReplace != -1) {
|
||||
imageList[positionToReplace] = imageUri.toString()
|
||||
}
|
||||
outState.putStringArrayList("imageList", imageList.filterNotNull() as ArrayList<String>)
|
||||
}
|
||||
|
||||
override fun onViewStateRestored(savedInstanceState: Bundle?) {
|
||||
super.onViewStateRestored(savedInstanceState)
|
||||
Log.e("Checkkkkkkkskksks=1=>","ssss")
|
||||
if (savedInstanceState == null) return
|
||||
Log.e("Checkkkkkkkskksks=1=>","ssss3333")
|
||||
binding.etItemValue.setText(savedInstanceState.getString("etItemValue", ""))
|
||||
binding.etItemQuantity.setText(savedInstanceState.getString("etItemQuantity", ""))
|
||||
binding.autoCompleteMain.setText(savedInstanceState.getString("autoCompleteMain", ""), false)
|
||||
binding.autoCompleteSub.setText(savedInstanceState.getString("autoCompleteSub", ""), false)
|
||||
binding.autoCompleteUnits.setText(savedInstanceState.getString("autoCompleteUnits", ""), false)
|
||||
Log.e("Checkkkkkkkskksks=1=>","sss555s")
|
||||
|
||||
val restoredImageList = savedInstanceState.getStringArrayList("imageList")
|
||||
if (restoredImageList != null) {
|
||||
imageList.clear()
|
||||
imageList.addAll(restoredImageList)
|
||||
while (imageList.size < 5) {
|
||||
imageList.add(null) // fill up to 5 slots
|
||||
}
|
||||
|
||||
adapter.notifyDataSetChanged()
|
||||
|
||||
}
|
||||
}*/
|
||||
|
||||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
||||
super.onViewCreated(view, savedInstanceState)
|
||||
|
||||
|
@ -120,32 +164,36 @@ class DamageDetailsFragment : Fragment() {
|
|||
inspectionId = arguments?.getString("id").toString()
|
||||
viewModel.getCategoryList()
|
||||
}else{
|
||||
from="edit"
|
||||
val jsonString = arguments?.getString("damageData")
|
||||
val damageData = Gson().fromJson(jsonString, Damage::class.java)
|
||||
inspectionId = arguments?.getString("id").toString()
|
||||
viewModel.getCategoryList()
|
||||
|
||||
Log.e("CheckkkkDama==>","${damageData}")
|
||||
binding.etItemValue.setText(damageData.itemValue.toString())
|
||||
binding.etItemValue.setSelection(damageData.itemValue.toString().length)
|
||||
binding.etItemQuantity.setText(damageData.itemQuantity.toString())
|
||||
binding.autoCompleteMain.setText(damageData.categoryName,false)
|
||||
damageId=damageData.id.toString()
|
||||
if(damageData.images!=null)
|
||||
{
|
||||
if(damageData.images.isNotEmpty())
|
||||
from="edit"
|
||||
val jsonString = arguments?.getString("damageData")
|
||||
val damageData = Gson().fromJson(jsonString, Damage::class.java)
|
||||
inspectionId = arguments?.getString("id").toString()
|
||||
viewModel.getCategoryList()
|
||||
|
||||
|
||||
binding.etItemValue.setText("SAR "+damageData.itemValue.toString())
|
||||
binding.etItemValue.setSelection(damageData.itemValue.toString().length)
|
||||
binding.etItemQuantity.setText(damageData.itemQuantity.toString())
|
||||
binding.autoCompleteMain.setText(damageData.categoryName,false)
|
||||
damageId=damageData.id.toString()
|
||||
if(damageData.images!=null)
|
||||
{
|
||||
if(damageData.images.isNotEmpty())
|
||||
{
|
||||
|
||||
for ((index, item) in damageData.images.withIndex()) {
|
||||
for ((index, item) in damageData.images.withIndex()) {
|
||||
|
||||
imageList.add(IMAGE_BASE_URL +item)
|
||||
imageList.add(IMAGE_BASE_URL +item)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
val hashMap = HashMap<String, String>()
|
||||
hashMap["id"] = damageData.categoryID.toString()
|
||||
viewModel.getSelectCategoryList(hashMap)
|
||||
val hashMap = HashMap<String, String>()
|
||||
hashMap["id"] = damageData.categoryID.toString()
|
||||
viewModel.getSelectCategoryList(hashMap)
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -201,7 +249,45 @@ class DamageDetailsFragment : Fragment() {
|
|||
}
|
||||
}
|
||||
|
||||
galleryLauncher = registerForActivityResult(ActivityResultContracts.GetContent()) { uri ->
|
||||
|
||||
galleryLauncher = registerForActivityResult(ActivityResultContracts.GetMultipleContents()) { uris ->
|
||||
uris.let {
|
||||
try {
|
||||
if (it.size + imageList.filterNotNull().size > 5) {
|
||||
|
||||
val getCount=imageList.filterNotNull().size - 5
|
||||
|
||||
if(getCount==1)
|
||||
{
|
||||
Toast.makeText(requireContext(), getString(R.string.select_upto_one_images), Toast.LENGTH_SHORT).show()
|
||||
}else{
|
||||
Toast.makeText(requireContext(), getString(R.string.select_upto_five_images,getCount), Toast.LENGTH_SHORT).show()
|
||||
}
|
||||
|
||||
} else {
|
||||
for (uri in it) {
|
||||
val positionToReplace = imageList.indexOfFirst { it == null }
|
||||
if (positionToReplace != -1) {
|
||||
imageList[positionToReplace] = uri.toString()
|
||||
adapter.notifyItemChanged(positionToReplace)
|
||||
} else {
|
||||
|
||||
imageList.add(uri.toString())
|
||||
adapter.notifyItemInserted(imageList.size - 1)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val currentFocus = requireActivity().currentFocus
|
||||
currentFocus?.clearFocus()
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace() // Handle exceptions properly
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* galleryLauncher = registerForActivityResult(ActivityResultContracts.GetContent()) { uri ->
|
||||
uri?.let {
|
||||
|
||||
try {
|
||||
|
@ -224,7 +310,7 @@ class DamageDetailsFragment : Fragment() {
|
|||
|
||||
|
||||
}
|
||||
}
|
||||
}*/
|
||||
binding.etItemValue.addTextChangedListener(object : TextWatcher {
|
||||
private var isEditing = false
|
||||
|
||||
|
@ -429,8 +515,11 @@ class DamageDetailsFragment : Fragment() {
|
|||
binding.autoCompleteUnits.setText(subCategoryList[0].unit, false)
|
||||
selectSubId=subCategoryList[0].id.toString()
|
||||
}else{
|
||||
binding.autoCompleteSub.setText("", false)
|
||||
binding.autoCompleteUnits.setText("", false)
|
||||
binding.llUnits.gone()
|
||||
binding.llSubItem.gone()
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -195,6 +195,8 @@ class HomeFragment : Fragment() {
|
|||
|
||||
popupView.txtAll.setOnClickListener {
|
||||
refreshPagination()
|
||||
click=""
|
||||
selectStatus=""
|
||||
binding.txtStatusShow.gone()
|
||||
val hashMap = HashMap<String, String>()
|
||||
hashMap[LIMIT_TEXT] = PER_PAGE_LOAD
|
||||
|
|
|
@ -4,6 +4,7 @@ import android.app.Activity
|
|||
import android.content.Intent
|
||||
import android.content.res.Resources
|
||||
import android.os.Bundle
|
||||
import android.text.InputType
|
||||
import android.util.Log
|
||||
import android.util.Patterns
|
||||
import android.view.Gravity
|
||||
|
@ -19,6 +20,7 @@ import com.example.fieldagent.data.network.ApisRespHandler
|
|||
import com.example.fieldagent.databinding.ActivityLoginBinding
|
||||
import com.example.fieldagent.ui.homescreen.HomeActivity
|
||||
import androidx.lifecycle.Observer
|
||||
import com.example.fieldagent.data.network.responseUtil.AppError
|
||||
import com.example.fieldagent.utils.PrefsManager
|
||||
import com.example.fieldagent.utils.REFRESH_TOKEN
|
||||
import com.example.fieldagent.utils.TOKEN
|
||||
|
@ -40,6 +42,7 @@ class LoginActivity : AppCompatActivity() {
|
|||
lateinit var prefsManager: PrefsManager
|
||||
private val viewModel: LoginViewModel by viewModels()
|
||||
private lateinit var progressDialog: ProgressDialog
|
||||
private var isPasswordVisible = false
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
binding = ActivityLoginBinding.inflate(layoutInflater)
|
||||
|
@ -70,6 +73,21 @@ class LoginActivity : AppCompatActivity() {
|
|||
}
|
||||
|
||||
private fun listeners(){
|
||||
|
||||
|
||||
binding.tilPassword.setEndIconOnClickListener {
|
||||
isPasswordVisible = !isPasswordVisible
|
||||
|
||||
if (isPasswordVisible) {
|
||||
binding.etPassword.inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD
|
||||
binding.tilPassword.setEndIconDrawable(R.drawable.eye_icon) // Your open eye icon
|
||||
} else {
|
||||
binding.etPassword.inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_PASSWORD
|
||||
binding.tilPassword.setEndIconDrawable(R.drawable.eye_close) // Your closed eye icon
|
||||
}
|
||||
|
||||
binding.etPassword.setSelection(binding.etPassword.text?.length ?: 0)
|
||||
}
|
||||
binding.btnSigIn.setOnClickListener {
|
||||
|
||||
|
||||
|
@ -118,7 +136,23 @@ class LoginActivity : AppCompatActivity() {
|
|||
}
|
||||
Status.ERROR -> {
|
||||
progressDialog.setLoading(false)
|
||||
ApisRespHandler.handleError(it.error,this)
|
||||
|
||||
|
||||
val error = it.error
|
||||
if (error is AppError.ApiError) {
|
||||
|
||||
binding.etPassword.showSnackBar(error.message)
|
||||
} else if (error is AppError.ApiFailure) {
|
||||
if (error.message.contains("Failed to connect to",true) ||
|
||||
error.message.contains("Unable to resolve host",true) ||
|
||||
error.message.contains("No address associated with hostname",true))
|
||||
binding.etPassword.showSnackBar(getString(R.string.check_internet))
|
||||
else
|
||||
binding.etPassword.showSnackBar(error.message)
|
||||
|
||||
} else {
|
||||
binding.etPassword.showSnackBar(getString(R.string.check_internet))
|
||||
}
|
||||
}
|
||||
Status.LOADING -> {
|
||||
progressDialog.setLoading(true)
|
||||
|
@ -126,4 +160,5 @@ class LoginActivity : AppCompatActivity() {
|
|||
}
|
||||
})
|
||||
}
|
||||
|
||||
}
|
|
@ -4,7 +4,10 @@ import android.app.AlertDialog
|
|||
import android.content.Intent
|
||||
import android.content.res.Resources
|
||||
import android.os.Bundle
|
||||
import android.text.Editable
|
||||
import android.text.InputType
|
||||
import android.text.TextUtils
|
||||
import android.text.TextWatcher
|
||||
import android.util.Log
|
||||
import android.view.Gravity
|
||||
import androidx.fragment.app.Fragment
|
||||
|
@ -54,6 +57,10 @@ class ProfileFragment : Fragment() {
|
|||
private lateinit var progressDialog: ProgressDialog
|
||||
|
||||
private var userId="";
|
||||
private var userName="";
|
||||
private var isPasswordVisible = false
|
||||
private var isConfirmPasswordVisible = false
|
||||
private var isClickName = false
|
||||
override fun onCreateView(
|
||||
inflater: LayoutInflater, container: ViewGroup?,
|
||||
savedInstanceState: Bundle?
|
||||
|
@ -79,6 +86,7 @@ class ProfileFragment : Fragment() {
|
|||
|
||||
userId=userData.id.toString()
|
||||
binding.etName.setText(userData.name)
|
||||
userName=userData.name.toString()
|
||||
binding.etEmail.setText(userData.email)
|
||||
binding.etPhone.setText(userData.phoneNumber)
|
||||
|
||||
|
@ -100,6 +108,7 @@ class ProfileFragment : Fragment() {
|
|||
binding.etConfirmPassword.gravity = Gravity.START
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
@ -121,15 +130,125 @@ class ProfileFragment : Fragment() {
|
|||
|
||||
}
|
||||
|
||||
binding.btnAdd.setOnClickListener {
|
||||
binding.etName.addTextChangedListener(object : TextWatcher {
|
||||
override fun beforeTextChanged(s: CharSequence?, start: Int, count: Int, after: Int) {}
|
||||
|
||||
override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) {
|
||||
val newName = s.toString()
|
||||
|
||||
|
||||
if (newName.isNotEmpty() && newName != userName) {
|
||||
binding.btnName.isEnabled = true
|
||||
|
||||
} else {
|
||||
binding.btnName.isEnabled = false
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
override fun afterTextChanged(s: Editable?) {}
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
binding.tilPassword.setEndIconOnClickListener {
|
||||
isPasswordVisible = !isPasswordVisible
|
||||
|
||||
if (isPasswordVisible) {
|
||||
binding.etPassword.inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD
|
||||
binding.tilPassword.setEndIconDrawable(R.drawable.eye_icon) // Your open eye icon
|
||||
} else {
|
||||
binding.etPassword.inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_PASSWORD
|
||||
binding.tilPassword.setEndIconDrawable(R.drawable.eye_close) // Your closed eye icon
|
||||
}
|
||||
|
||||
binding.etPassword.setSelection(binding.etPassword.text?.length ?: 0)
|
||||
}
|
||||
|
||||
binding.tilConfirmPassword.setEndIconOnClickListener {
|
||||
isConfirmPasswordVisible = !isConfirmPasswordVisible
|
||||
|
||||
if (isConfirmPasswordVisible) {
|
||||
binding.etPassword.inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD
|
||||
binding.tilConfirmPassword.setEndIconDrawable(R.drawable.eye_icon) // Your open eye icon
|
||||
} else {
|
||||
binding.etPassword.inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_PASSWORD
|
||||
binding.tilConfirmPassword.setEndIconDrawable(R.drawable.eye_close) // Your closed eye icon
|
||||
}
|
||||
|
||||
binding.etConfirmPassword.setSelection(binding.etConfirmPassword.text?.length ?: 0)
|
||||
}
|
||||
|
||||
|
||||
val watcher = object : TextWatcher {
|
||||
override fun afterTextChanged(s: Editable?) {
|
||||
val password = binding.etPassword.text.toString()
|
||||
val confirmPassword = binding.etConfirmPassword.text.toString()
|
||||
|
||||
val isValid = password.isNotEmpty() &&
|
||||
confirmPassword.isNotEmpty() &&
|
||||
password == confirmPassword
|
||||
|
||||
binding.btnPassword.isEnabled = isValid
|
||||
binding.btnPassword.setBackgroundResource(
|
||||
if (isValid) R.drawable.bg_button_enabled
|
||||
else R.drawable.bg_button_disabled
|
||||
)
|
||||
}
|
||||
|
||||
override fun beforeTextChanged(s: CharSequence?, start: Int, count: Int, after: Int) {}
|
||||
override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) {}
|
||||
}
|
||||
|
||||
binding.etPassword.addTextChangedListener(watcher)
|
||||
binding.etConfirmPassword.addTextChangedListener(watcher)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
binding.btnName.setOnClickListener {
|
||||
|
||||
if(!binding.btnName.isEnabled) return@setOnClickListener
|
||||
when{
|
||||
isConnectedToInternet(requireActivity(), true) -> {
|
||||
isClickName=true;
|
||||
val hashMap = HashMap<String, String>()
|
||||
hashMap["name"] = binding.etName.text.toString()
|
||||
viewModel.updateProfile(userId,hashMap)
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
binding.btnPassword.setOnClickListener {
|
||||
|
||||
if(!binding.btnPassword.isEnabled) return@setOnClickListener
|
||||
when{
|
||||
isConnectedToInternet(requireActivity(), true) -> {
|
||||
isClickName=false
|
||||
val hashMap = HashMap<String, String>()
|
||||
if (binding.etPassword.text.toString().isNotEmpty())
|
||||
{
|
||||
hashMap["password"] = binding.etPassword.text.toString()
|
||||
}
|
||||
|
||||
|
||||
viewModel.updateProfile(userId,hashMap)
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* binding.btnAdd.setOnClickListener {
|
||||
|
||||
when{
|
||||
binding.etName.text.isEmpty()->{
|
||||
binding.etName.showSnackBar(getString(R.string.please_enter_agent_name))
|
||||
}
|
||||
/*binding.etPassword.text.toString().isEmpty()->{
|
||||
*//*binding.etPassword.text.toString().isEmpty()->{
|
||||
binding.etPassword.showSnackBar(getString(R.string.please_enter_password))
|
||||
}*/
|
||||
}*//*
|
||||
|
||||
binding.etPassword.text.toString().isNotEmpty() && !binding.etPassword.text.toString().matches(Regex("^(?=.*[A-Z])(?=.*\\d)(?=.*[@#\$%^&+=!]).{6,}$"))->{
|
||||
binding.etPassword.showSnackBar(getString(R.string.please_enter_valid_password))
|
||||
|
@ -155,7 +274,7 @@ class ProfileFragment : Fragment() {
|
|||
|
||||
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
|
||||
|
@ -166,16 +285,39 @@ class ProfileFragment : Fragment() {
|
|||
Status.SUCCESS -> {
|
||||
progressDialog.setLoading(false)
|
||||
|
||||
requireContext().showUpdateDialog(
|
||||
if(isClickName)
|
||||
{
|
||||
val jsonString = prefsManager.getString(USER_DATA, "")
|
||||
val userDataCheck = Gson().fromJson(jsonString, Data::class.java)
|
||||
|
||||
|
||||
userDataCheck.name = binding.etName.text.toString()
|
||||
|
||||
val updatedUserDataJson = Gson().toJson(userDataCheck)
|
||||
prefsManager.saveString(USER_DATA, updatedUserDataJson)
|
||||
userName=binding.etName.text.toString()
|
||||
|
||||
binding.btnName.isEnabled = false
|
||||
requireContext().showUpdateDialog(
|
||||
title = getString(R.string.profile_updated_successfully)
|
||||
) {
|
||||
prefsManager.removeAll()
|
||||
|
||||
val intent = Intent(requireContext(), LoginActivity::class.java)
|
||||
intent.flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK
|
||||
startActivity(intent)
|
||||
}
|
||||
|
||||
}else{
|
||||
requireContext().showUpdateDialog(
|
||||
title = getString(R.string.password_updated_successfully)
|
||||
) {
|
||||
prefsManager.removeAll()
|
||||
|
||||
val intent = Intent(requireContext(), LoginActivity::class.java)
|
||||
intent.flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK
|
||||
startActivity(intent)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
Status.ERROR -> {
|
||||
progressDialog.setLoading(false)
|
||||
|
|
5
app/src/main/res/drawable/bg_button_disabled.xml
Normal file
5
app/src/main/res/drawable/bg_button_disabled.xml
Normal file
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
|
||||
<solid android:color="@color/edit_text_color" />
|
||||
<corners android:radius="8dp"/>
|
||||
</shape>
|
5
app/src/main/res/drawable/bg_button_enabled.xml
Normal file
5
app/src/main/res/drawable/bg_button_enabled.xml
Normal file
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
|
||||
<solid android:color="@color/main_color" />
|
||||
<corners android:radius="8dp"/>
|
||||
</shape>
|
48
app/src/main/res/drawable/eye_close.xml
Normal file
48
app/src/main/res/drawable/eye_close.xml
Normal file
|
@ -0,0 +1,48 @@
|
|||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:pathData="M14.53,9.47L9.47,14.53C8.82,13.88 8.42,12.99 8.42,12C8.42,10.02 10.02,8.42 12,8.42C12.99,8.42 13.88,8.82 14.53,9.47Z"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="1.5"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#8A8A8A"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M17.82,5.77C16.07,4.45 14.07,3.73 12,3.73C8.47,3.73 5.18,5.81 2.89,9.41C1.99,10.82 1.99,13.19 2.89,14.6C3.68,15.84 4.6,16.91 5.6,17.77"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="1.5"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#8A8A8A"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M8.42,19.53C9.56,20.01 10.77,20.27 12,20.27C15.53,20.27 18.82,18.19 21.11,14.59C22.01,13.18 22.01,10.81 21.11,9.4C20.78,8.88 20.42,8.39 20.05,7.93"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="1.5"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#8A8A8A"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M15.51,12.7C15.25,14.11 14.1,15.26 12.69,15.52"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="1.5"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#8A8A8A"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M9.47,14.53L2,22"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="1.5"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#8A8A8A"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M22,2L14.53,9.47"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="1.5"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#8A8A8A"
|
||||
android:strokeLineCap="round"/>
|
||||
</vector>
|
12
app/src/main/res/drawable/eye_icon.xml
Normal file
12
app/src/main/res/drawable/eye_icon.xml
Normal file
|
@ -0,0 +1,12 @@
|
|||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:pathData="M12,16.33C9.61,16.33 7.67,14.39 7.67,12C7.67,9.61 9.61,7.67 12,7.67C14.39,7.67 16.33,9.61 16.33,12C16.33,14.39 14.39,16.33 12,16.33ZM12,9.17C10.44,9.17 9.17,10.44 9.17,12C9.17,13.56 10.44,14.83 12,14.83C13.56,14.83 14.83,13.56 14.83,12C14.83,10.44 13.56,9.17 12,9.17Z"
|
||||
android:fillColor="#8A8A8A"/>
|
||||
<path
|
||||
android:pathData="M12,21.02C8.24,21.02 4.69,18.82 2.25,15C1.19,13.35 1.19,10.66 2.25,9C4.7,5.18 8.25,2.98 12,2.98C15.75,2.98 19.3,5.18 21.74,9C22.8,10.65 22.8,13.34 21.74,15C19.3,18.82 15.75,21.02 12,21.02ZM12,4.48C8.77,4.48 5.68,6.42 3.52,9.81C2.77,10.98 2.77,13.02 3.52,14.19C5.68,17.58 8.77,19.52 12,19.52C15.23,19.52 18.32,17.58 20.48,14.19C21.23,13.02 21.23,10.98 20.48,9.81C18.32,6.42 15.23,4.48 12,4.48Z"
|
||||
android:fillColor="#8A8A8A"/>
|
||||
</vector>
|
|
@ -1,153 +1,172 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
|
||||
<ScrollView 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"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:scrollbars="none"
|
||||
android:background="@color/white"
|
||||
tools:context=".ui.login.LoginActivity">
|
||||
android:layout_height="match_parent">
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/topGuide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintGuide_percent="0.15" />
|
||||
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/leftGuide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_begin="@dimen/dp_16" />
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/rightGuide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_end="@dimen/dp_16" />
|
||||
<ImageView
|
||||
android:id="@+id/ivAppLogo"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_100"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/topGuide"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:src="@drawable/app_logo"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txtSignIn"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:text="@string/sign_in"
|
||||
android:textSize="@dimen/sp_18"
|
||||
android:fontFamily="@font/montserratbold"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ivAppLogo"
|
||||
android:layout_marginTop="@dimen/dp_64"
|
||||
/>
|
||||
<TextView
|
||||
android:id="@+id/txtSignInContinue"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/sign_in_to_continue"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:background="@color/white"
|
||||
tools:context=".ui.login.LoginActivity">
|
||||
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/txtSignIn"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/etEmail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
app:layout_constraintTop_toBottomOf="@+id/txtSignInContinue"
|
||||
android:hint="@string/email_address"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:textColor="@color/edit_text_color"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:layout_marginTop="@dimen/dp_36"
|
||||
android:background="@drawable/rounded_background"
|
||||
android:maxLines="1"
|
||||
android:inputType="textEmailAddress"
|
||||
android:singleLine="true"
|
||||
android:imeOptions="actionDone"
|
||||
|
||||
/>
|
||||
<!-- <EditText
|
||||
android:id="@+id/etPassword"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:autofillHints=""
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
app:layout_constraintTop_toBottomOf="@+id/etEmail"
|
||||
android:hint="@string/password"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:textColor="@color/edit_text_color"
|
||||
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:background="@drawable/rounded_background"
|
||||
/>-->
|
||||
|
||||
<com.google.android.material.textfield.TextInputLayout
|
||||
android:id="@+id/tilPassword"
|
||||
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:endIconMode="password_toggle"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
app:layout_constraintTop_toBottomOf="@+id/etEmail"
|
||||
|
||||
app:hintEnabled="false"
|
||||
>
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/etPassword"
|
||||
android:layout_width="match_parent"
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/topGuide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:inputType="textPassword"
|
||||
android:textColor="@color/edit_text_color"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintGuide_percent="0.15" />
|
||||
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/leftGuide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_begin="@dimen/dp_16" />
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/rightGuide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_end="@dimen/dp_16" />
|
||||
<ImageView
|
||||
android:id="@+id/ivAppLogo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_100"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/topGuide"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:src="@drawable/app_logo"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txtSignIn"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:text="@string/sign_in"
|
||||
android:textSize="@dimen/sp_18"
|
||||
android:fontFamily="@font/montserratbold"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ivAppLogo"
|
||||
android:layout_marginTop="@dimen/dp_64"
|
||||
/>
|
||||
<TextView
|
||||
android:id="@+id/txtSignInContinue"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/sign_in_to_continue"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:maxLines="1"
|
||||
android:singleLine="true"
|
||||
android:hint="@string/password"
|
||||
android:gravity="start"
|
||||
android:imeOptions="actionDone"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:background="@drawable/rounded_background" />
|
||||
</com.google.android.material.textfield.TextInputLayout>
|
||||
<Button
|
||||
android:id="@+id/btnSigIn"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
android:textSize="@dimen/sp_16"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tilPassword"
|
||||
android:layout_marginTop="@dimen/dp_28"
|
||||
android:text="@string/sign_in"
|
||||
android:paddingTop="@dimen/dp_10"
|
||||
android:paddingBottom="@dimen/dp_10"
|
||||
android:fontFamily="@font/montserratsemibold"
|
||||
android:background="@drawable/rounded_background"
|
||||
android:textColor="#FFFFFF"/>
|
||||
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/txtSignIn"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/etEmail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
app:layout_constraintTop_toBottomOf="@+id/txtSignInContinue"
|
||||
android:hint="@string/email_address"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:textColor="@color/edit_text_color"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:layout_marginTop="@dimen/dp_36"
|
||||
android:background="@drawable/rounded_background"
|
||||
android:maxLines="1"
|
||||
android:inputType="textEmailAddress"
|
||||
android:singleLine="true"
|
||||
android:imeOptions="actionDone"
|
||||
|
||||
/>
|
||||
<!-- <EditText
|
||||
android:id="@+id/etPassword"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:autofillHints=""
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
app:layout_constraintTop_toBottomOf="@+id/etEmail"
|
||||
android:hint="@string/password"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:textColor="@color/edit_text_color"
|
||||
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:background="@drawable/rounded_background"
|
||||
/>-->
|
||||
|
||||
<com.google.android.material.textfield.TextInputLayout
|
||||
android:id="@+id/tilPassword"
|
||||
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
app:layout_constraintTop_toBottomOf="@+id/etEmail"
|
||||
|
||||
app:endIconMode="custom"
|
||||
app:endIconDrawable="@drawable/eye_close"
|
||||
app:hintEnabled="false"
|
||||
>
|
||||
|
||||
<com.google.android.material.textfield.TextInputEditText
|
||||
android:id="@+id/etPassword"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/edit_text_color"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:maxLines="1"
|
||||
android:singleLine="true"
|
||||
android:inputType="textPassword"
|
||||
android:hint="@string/password"
|
||||
android:gravity="start"
|
||||
android:imeOptions="actionDone"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:background="@drawable/rounded_background" />
|
||||
</com.google.android.material.textfield.TextInputLayout>
|
||||
<Button
|
||||
android:id="@+id/btnSigIn"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toEndOf="@id/leftGuide"
|
||||
app:layout_constraintEnd_toStartOf="@id/rightGuide"
|
||||
android:textSize="@dimen/sp_16"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tilPassword"
|
||||
android:layout_marginTop="@dimen/dp_28"
|
||||
android:text="@string/sign_in"
|
||||
android:paddingTop="@dimen/dp_10"
|
||||
android:paddingBottom="@dimen/dp_10"
|
||||
android:fontFamily="@font/montserratsemibold"
|
||||
android:background="@drawable/rounded_background"
|
||||
android:textColor="#FFFFFF"/>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_1"
|
||||
app:layout_constraintTop_toBottomOf="@+id/btnSigIn"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</ScrollView>
|
||||
|
|
|
@ -209,12 +209,17 @@
|
|||
android:layout_gravity="end"
|
||||
android:gravity="end"
|
||||
>
|
||||
<ImageView
|
||||
android:layout_width="@dimen/dp_16"
|
||||
android:layout_height="@dimen/dp_16"
|
||||
android:src="@drawable/arab"
|
||||
android:layout_marginTop="@dimen/dp_2"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
<TextView
|
||||
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="SAR"
|
||||
android:textAlignment="textEnd"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:fontFamily="@font/montserratregular"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:layout_marginEnd="@dimen/dp_4"
|
||||
/>
|
||||
<TextView
|
||||
android:id="@+id/txtValue"
|
||||
|
@ -304,12 +309,18 @@
|
|||
android:layout_gravity="end"
|
||||
android:gravity="end"
|
||||
>
|
||||
<ImageView
|
||||
android:layout_width="@dimen/dp_16"
|
||||
android:layout_height="@dimen/dp_16"
|
||||
android:src="@drawable/arab"
|
||||
android:layout_marginTop="@dimen/dp_4"
|
||||
android:layout_marginEnd="@dimen/dp_2"
|
||||
|
||||
<TextView
|
||||
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="SAR"
|
||||
android:textAlignment="textEnd"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:fontFamily="@font/montserratmedium"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:layout_marginEnd="@dimen/dp_4"
|
||||
/>
|
||||
<TextView
|
||||
android:id="@+id/txtTotal"
|
||||
|
|
|
@ -3,22 +3,47 @@
|
|||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:background="@android:color/transparent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/fullscreen_image"
|
||||
<LinearLayout
|
||||
android:id="@+id/close_button"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="end"
|
||||
android:background="@color/white"
|
||||
>
|
||||
<ImageView
|
||||
|
||||
android:layout_width="@dimen/dp_48"
|
||||
android:layout_height="@dimen/dp_48"
|
||||
android:elevation="@dimen/dp_8"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:padding="@dimen/dp_4"
|
||||
android:src="@drawable/close_circle"
|
||||
/>
|
||||
</LinearLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/imageCard"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:scaleType="fitCenter" />
|
||||
android:layout_gravity="center"
|
||||
app:cardBackgroundColor="@color/white"
|
||||
android:layout_below="@+id/close_button"
|
||||
app:cardCornerRadius="12dp"
|
||||
app:cardElevation="6dp"
|
||||
|
||||
android:background="@android:color/white">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/fullscreen_image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitCenter"
|
||||
/>
|
||||
</RelativeLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/close_button"
|
||||
android:layout_width="@dimen/dp_48"
|
||||
android:layout_height="@dimen/dp_48"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:elevation="@dimen/dp_8"
|
||||
android:layout_margin="16dp"
|
||||
android:padding="@dimen/dp_4"
|
||||
android:src="@drawable/close_circle"
|
||||
/>
|
||||
</RelativeLayout>
|
|
@ -221,12 +221,28 @@
|
|||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnName"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:layout_marginTop="@dimen/dp_30"
|
||||
android:text="@string/update_profile"
|
||||
android:paddingTop="@dimen/dp_10"
|
||||
android:paddingBottom="@dimen/dp_10"
|
||||
android:fontFamily="@font/montserratsemibold"
|
||||
android:enabled="false"
|
||||
android:background="@drawable/rounded_background"
|
||||
android:textColor="#FFFFFF"/>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/llPassword"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
android:layout_marginTop="@dimen/dp_4"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<TextView
|
||||
|
@ -245,9 +261,10 @@
|
|||
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:endIconMode="password_toggle"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
|
||||
app:endIconMode="custom"
|
||||
app:endIconDrawable="@drawable/eye_close"
|
||||
app:hintEnabled="false"
|
||||
>
|
||||
|
||||
|
@ -291,12 +308,14 @@
|
|||
|
||||
<com.google.android.material.textfield.TextInputLayout
|
||||
|
||||
android:id="@+id/tilConfirmPassword"
|
||||
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:endIconMode="password_toggle"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
|
||||
app:endIconMode="custom"
|
||||
app:endIconDrawable="@drawable/eye_close"
|
||||
app:hintEnabled="false"
|
||||
>
|
||||
|
||||
|
@ -321,18 +340,25 @@
|
|||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnAdd"
|
||||
android:id="@+id/btnPassword"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:layout_marginTop="@dimen/dp_56"
|
||||
android:text="@string/save"
|
||||
android:layout_marginTop="@dimen/dp_30"
|
||||
android:text="@string/change_password"
|
||||
android:paddingTop="@dimen/dp_10"
|
||||
android:paddingBottom="@dimen/dp_10"
|
||||
android:enabled="false"
|
||||
android:fontFamily="@font/montserratsemibold"
|
||||
android:background="@drawable/rounded_background"
|
||||
android:textColor="#FFFFFF"/>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_30"/>
|
||||
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
|
||||
|
|
|
@ -112,7 +112,12 @@
|
|||
<string name="new_password">كلمة المرور الجديدة</string>
|
||||
<string name="please_enter_new_password">الرجاء إدخال كلمة المرور الجديدة</string>
|
||||
<string name="camera_permission_denied">تم رفض إذن Cemera</string>
|
||||
<string name="change_password">تغيير كلمة المرور</string>
|
||||
<string name="update_profile">تحديث الملف الشخصي</string>
|
||||
<string name="password_updated_successfully">تم تحديث كلمة المرور بنجاح</string>
|
||||
<string name="all">الجميع</string>
|
||||
<string name="select_upto_five_images">يمكنك اختيار ما يصل إلى %d صورة فقط.</string>
|
||||
<string name="select_upto_one_images">يمكنك تحديد ما يصل إلى 1 صور فقط.</string>
|
||||
<string-array name="availability">
|
||||
<item>@string/yes</item>
|
||||
<item>@string/no</item>
|
||||
|
|
|
@ -98,6 +98,7 @@
|
|||
<string name="password_and_confirm_password_not_match">Password and confirm password do not match</string>
|
||||
<string name="save">Save</string>
|
||||
<string name="profile_updated_successfully">Profile updated successfully</string>
|
||||
<string name="password_updated_successfully">Password updated successfully</string>
|
||||
<string name="are_you_sure_you_want_to_delete">Are you sure you want to delete?</string>
|
||||
<string name="damage_report_table">Damage Report Table</string>
|
||||
<string name="no.">No.</string>
|
||||
|
@ -111,6 +112,10 @@
|
|||
<string name="pdf_saved">PDF saved to Documents!</string>
|
||||
<string name="pdf_failed">Failed to save PDF!</string>
|
||||
<string name="please_try_again_later">Please try again later</string>
|
||||
<string name="change_password">Change Password</string>
|
||||
<string name="update_profile">Update Profile</string>
|
||||
<string name="select_upto_five_images">You can only select up to %d images.</string>
|
||||
<string name="select_upto_one_images">You can only select up to 1 image.</string>
|
||||
<string name="contact_number_length_error">Please enter a valid contact number with 7 to 11 digits</string>
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue