@@ -10,6 +10,7 @@ import importExport from '../../plugins/adminforth-import-export/index.js';
1010import InlineCreatePlugin from '../../plugins/adminforth-inline-create/index.js' ;
1111import ListInPlaceEditPlugin from "../../plugins/adminforth-list-in-place-edit/index.js" ;
1212import BulkAiFlowPlugin from '../../plugins/adminforth-bulk-ai-flow/index.js' ;
13+ import ForeignInlineShowPlugin from '../../plugins/adminforth-foreign-inline-show/index.js' ;
1314
1415
1516import CompletionAdapterOpenAIChatGPT from '../../adapters/adminforth-completion-adapter-open-ai-chat-gpt/index.js' ;
@@ -18,7 +19,7 @@ import ImageGenerationAdapterOpenAI from '../../adapters/adminforth-image-genera
1819import AdminForthStorageAdapterLocalFilesystem from "../../adapters/adminforth-storage-adapter-local/index.js" ;
1920import AdminForthAdapterS3Storage from '../../adapters/adminforth-storage-adapter-amazon-s3/index.js' ;
2021import AdminForthImageVisionAdapterOpenAi from '../../adapters/adminforth-image-vision-adapter-openai/index.js' ;
21- import { logger } from 'adminforth'
22+ import { logger } from '../../ adminforth/modules/logger.js' ;
2223import { afLogger } from '../../adminforth/modules/logger.js' ;
2324
2425export default function carsResourseTemplate ( resourceId : string , dataSource : string , pkFileldName : string ) {
@@ -224,7 +225,9 @@ export default function carsResourseTemplate(resourceId: string, dataSource: str
224225 new ListInPlaceEditPlugin ( {
225226 columns : [ "model" , "engine_type" , "price" ] ,
226227 } ) ,
227-
228+ new ForeignInlineShowPlugin ( {
229+ foreignResourceId : 'adminuser' ,
230+ } ) ,
228231 /*********************************************************************************
229232
230233 AI Plugins
@@ -271,16 +274,17 @@ export default function carsResourseTemplate(resourceId: string, dataSource: str
271274 new BulkAiFlowPlugin ( {
272275 actionName : 'Generate description and Price' ,
273276 askConfirmationBeforeGenerating : true ,
274- textCompleteAdapter : new CompletionAdapterGoogleGemini ( {
275- geminiApiKey : process . env . GEMINI_API_KEY as string ,
276- expert : {
277- temperature : 0.7
278- }
279- } ) ,
280- fillPlainFields : {
281- description : "Create a desription for the car with name {{model}} and engine type {{engine_type}}. Desription should be HTML formatted." ,
282- price : "Based on the car model {{model}} and engine type {{engine_type}}, suggest a competitive market price in USD. Return only the numeric value." ,
283- }
277+ textCompleteAdapter : new CompletionAdapterOpenAIChatGPT ( {
278+ openAiApiKey : process . env . OPENAI_API_KEY as string ,
279+ model : "gpt-5.2" ,
280+ expert : {
281+ temperature : 0.7 ,
282+ } ,
283+ } ) ,
284+ fillPlainFields : {
285+ description : "Create a desription for the car with name {{model}} and engine type {{engine_type}}. Desription should be HTML formatted." ,
286+ price : "Based on the car model {{model}} and engine type {{engine_type}}, suggest a competitive market price in USD. Return only the numeric value." ,
287+ }
284288 } ) ,
285289 new BulkAiFlowPlugin ( {
286290 actionName : 'Analyze image' ,
0 commit comments