feat: Implement quick import feature for recipes
- Added QuickImportController and QuickImportService to handle recipe imports from URLs and file paths. - Created QuickImportModule to encapsulate the quick import functionality. - Developed frontend ImportFilePage for users to upload files or enter URLs for recipe import. - Integrated API proxy to communicate with the backend for quick import requests. - Implemented WriteRecipePage for users to manually input recipes with Markdown support. - Added page routing for the new import and write recipe functionalities.
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
import { Controller, Post, Body } from '@nestjs/common';
|
||||
import { QuickImportService } from './quick-import.service';
|
||||
|
||||
@Controller('quick-import')
|
||||
export class QuickImportController {
|
||||
constructor(private readonly quickImportService: QuickImportService) {}
|
||||
|
||||
@Post()
|
||||
async importFromInput(
|
||||
@Body() body: { input: string }
|
||||
) {
|
||||
return this.quickImportService.importFromInput(body.input);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user