MCPcopy Create free account
hub / github.com/TaskingAI/TaskingAI / handleEdit

Function handleEdit

frontend/src/components/chunkPage/index.tsx:181–190  ·  view source on GitHub ↗
(record: any)

Source from the content-addressed store, hash-verified

179 setOpenDeleteModal(false)
180 }
181 const handleEdit = async (record: any) => {
182 setLoading(true)
183 setDrawerTitle(`${t('projectChunkEditChunk')}`)
184 setRecordId(record.chunk_id)
185 const res = await getRecord(collectionId, record.chunk_id)
186 setContentValue(res.data.content)
187 setCreateOpenModal(true)
188 setLoading(false)
189
190 }
191 const handleConfirm = async () => {
192 if (!contentValue) {
193 toast.error(`${t('projectChunkContentRequired')}`)

Callers 1

ChunkPageFunction · 0.70

Calls 2

getRecordFunction · 0.90
setLoadingFunction · 0.85

Tested by

no test coverage detected