Hi, i'm testing the new release and it's great. Now I have some questions:
1-How to enable the detail print automatically?, don't click on the button with the name of the table, just appear the register of the detail table.
2-how to change the print template (size sheet, location of the fields, size of the ) for master and detail print? where files need to edit?
3-Finally, how to print in the selected printed (in the messsage dialog) and just not to show the preview of the print when click in print preview?
Appgini 5.50 beta master/detail print
Re: Appgini 5.50 beta master/detail print
1. In hooks/footer-extras.php, try adding this code:
Change tablename and fieldname above to the name of the child table, and the lookup field, respectively.
2. the templates/tablename_templateDVP.html is the main printable detail view template file for a table named 'tablename'. templates/children-tablename-printable.php is the template file for displaying printable child records from a child table named 'tablename'.
3. I'm not sure I understand this part "how to print in the selected printed (in the messsage dialog)" .. kindly clarify.
Code: Select all
<script>
$j(function(){
$j(document).ajaxComplete(function(){
var btn = $j('button#tab_tablename-fieldname');
if(btn.data('run_once')) return;
btn.data('run_once', true).click();
});
});
</script>
2. the templates/tablename_templateDVP.html is the main printable detail view template file for a table named 'tablename'. templates/children-tablename-printable.php is the template file for displaying printable child records from a child table named 'tablename'.
3. I'm not sure I understand this part "how to print in the selected printed (in the messsage dialog)" .. kindly clarify.
AppGini plugins to add more power to your apps:
- DataTalk is an innovative AppGini plugin based on ChatGPT that allows you to interact with your AppGini database using natural language questions, without writing any SQL. Check the demo video
- Mass Update plugin: Update multiple records at once and improve your workflow efficiency.
- Check our other plugins and get a generous discount of up to 30% when buying 2 or more plugins.
Re: Appgini 5.50 beta master/detail print
thanks for answer.
1.- the print enabled works with only one table (detalle_compras), but if I have 2 or more tables with children/parent print, don't shows automatically the child table. I need to click in the button. I added the code you gave to me, please check:
3.-check the picture I send to understand what I say.
Thanks
1.- the print enabled works with only one table (detalle_compras), but if I have 2 or more tables with children/parent print, don't shows automatically the child table. I need to click in the button. I added the code you gave to me, please check:
Code: Select all
<script>
$j(function(){
$j(document).ajaxComplete(function(){
var btn = $j('button#tab_DETALLE_COMPRAS-ID_COMPRA');
if(btn.data('run_once')) return;
btn.data('run_once', true).click();
});
});
</script>
<script>
$j(function(){
$j(document).ajaxComplete(function(){
var btn = $j('button#tab_DETALLE_VENTAS-ID_VENTA');
if(btn.data('run_once')) return;
btn.data('run_once', true).click();
});
});
</script>
Thanks
Re: Appgini 5.50 beta master/detail print
One more thing, how can hide the button to show the children table?
Re: Appgini 5.50 beta master/detail print
here are the pictures
print button acttion hide children table button
print button acttion hide children table button