refactor(frontend) : trim product edit page under 500 lines
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -298,20 +298,12 @@ const canSubmit = computed(() =>
|
|||||||
|
|
||||||
const structurePreview = computed(() => formatProductStructurePreview(structure.value))
|
const structurePreview = computed(() => formatProductStructurePreview(structure.value))
|
||||||
|
|
||||||
|
|
||||||
const openPreview = (doc: any) => {
|
const openPreview = (doc: any) => {
|
||||||
if (!doc || !canPreviewDocument(doc)) {
|
if (!doc || !canPreviewDocument(doc)) return
|
||||||
return
|
|
||||||
}
|
|
||||||
previewDocument.value = doc
|
previewDocument.value = doc
|
||||||
previewVisible.value = true
|
previewVisible.value = true
|
||||||
}
|
}
|
||||||
|
const closePreview = () => { previewVisible.value = false; previewDocument.value = null }
|
||||||
const closePreview = () => {
|
|
||||||
previewVisible.value = false
|
|
||||||
previewDocument.value = null
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
const loadProduct = async () => {
|
const loadProduct = async () => {
|
||||||
const id = route.params.id
|
const id = route.params.id
|
||||||
|
|||||||
Reference in New Issue
Block a user