fix : group
Deskripsi: - validasi tambah group - validasi edit group - load refresh modal No Issues
This commit is contained in:
@@ -48,9 +48,9 @@ export default function HeaderRightGroupList() {
|
||||
if (cat === 'title') {
|
||||
setTitle(val)
|
||||
if (val == "" || val.length < 3) {
|
||||
setError({ ...error, title: true })
|
||||
setError((prev) => ({ ...prev, title: true }))
|
||||
} else {
|
||||
setError({ ...error, title: false })
|
||||
setError((prev) => ({ ...prev, title: false }))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -91,7 +91,7 @@ export default function HeaderRightGroupList() {
|
||||
/>
|
||||
</View>
|
||||
<View>
|
||||
<ButtonForm text="SIMPAN" onPress={() => { onCheck() }} />
|
||||
<ButtonForm text="SIMPAN" disabled={Object.values(error).some((v) => v == true) || title == ""} onPress={() => { onCheck() }} />
|
||||
</View>
|
||||
</View>
|
||||
</DrawerBottom>
|
||||
|
||||
Reference in New Issue
Block a user