湖州项目前端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
415 B

8 months ago
import FileService from '../service/FileService';
class FileController {
private service: FileService = new FileService();
upload = async (ctx) => {
const files = ctx.request.files.file;
console.log(files);
if (files.length === undefined) {
this.service.upload(ctx, files, false);
} else {
this.service.upload(ctx, files, true);
}
};
}
export default new FileController();