图片上传逻辑
API
1 | import { request } from "@/apis/axios"; |
函数
1 | const handleFileChange = async (event, serial_num: number) => { |
模板
1 | <input type="file" class="file-input file-input-bordered file-input-sm w-7/12" @change="handleFileChange($event, item.serial_num)" /> |
怕忘记,遂写,希望以后能记下来
写于综合阅览室