Using df_display with insertFromBarCode.html
8 posts
• Page 1 of 1
Hi,
It possible to use df_display with insertFromBarCode.html? For example: $mioPar= array('relationship'=>'Somministrazioni','table' => 'anagrafica','IDAssistito' => $_POST['assistito'],'cursor'=>1 ); df_display($mioPar,"insertFromBarCode.html"); This get me an error, is correct? I can do it? Thx for help!
Sorry, I using my template name.
the code is: $mioPar= array('relationship'=>'Somministrazioni','table' => 'anagrafica','IDAssistito' => $_POST['assistito'],'cursor'=>1 ); df_display($mioPar,"Dataface_Related_Records_List.html"); or if I using template, code of template insertFromBarCode.html: {use_macro file="Dataface_Related_Records_List.html"} {/use_macro} Apologise for my mistake
It would help if you let me know what errors it gave you. The first option would work (df_display($mioPar,"insertFromBarCode.html") as long as you have your insertFromBarCode.html file in your application's templates folder. The second option you mentioned is a little bit more sketchy, because you have to make sure that you are passing the correct inputs to the Dataface_Related_List.html template - and I don't recall off the top of my head what those might be .Ê You would need a little bit of trial and error.Ê What are you trying to achieve here? -Steve
Hi!
the file action.ini is: [insertFromBarCode] template=insertFromBarCode.html The file insertFromBarCode.html in templates folder is: {use_macro file="Dataface_Related_Records_List.html"} {/use_macro} The code that I'm using to load insertFromBarCode.html $mioPar= array('relationship'=>'Somministrazioni','table' => 'anagrafica','IDAssistito' => $_POST['assistito'],'cursor'=>1 ); df_display($mioPar,"insertFromBarCode.html"); The error msg is: Fatal error: No relationship specified for related list.On line 764 of file E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\Dataface\SkinTool.php in function printStackTrace() On line 12 of file E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\Dataface\templates_c\dataface\%%4F^4F5^4F541920%%Dataface_Related_Records_List.html.php in function related_list(array(),Dataface_SkinTool Object) On line 1251 of file E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\lib\Smarty\Smarty.class.php in function include(E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\Dataface\templates_c\dataface\%%4F^4F5^4F541920%) On line 1101 of file E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\lib\Smarty\Smarty.class.php in function fetch(Dataface_Related_Records_List.html,,,1) On line 265 of file E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\Dataface\SkinTool.php in function display(Dataface_Related_Records_List.html) On line 626 of file E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\Dataface\SkinTo in E:\Programmi\OCS Inventory NG\xampp\htdocs\dataface\Dataface\SkinTool.php on line 764 thx for all, Apologise for my English !!
Unfortunately what yoiu are trying to do is not really a recommended approach.Ê Using the Dataface_RelatedRecordsList.html template for an action other thanÊ the Dataface relationship view may have complications (and appears to have complications judging by your error message). What are you trying to achieve? Are you trying to make a new action that shows the same thing as the related list? if so, why not just use the existing related list action? Or are you trying to do something else?
In your action you should be able to forward directly to the page that you want... you just have to tell it the URL to the related record page.
8 posts
• Page 1 of 1
Who is onlineUsers browsing this forum: No registered users and 9 guests |