How to change jsreport logo to our own logo



  • Hi sir,

    Is it possible to change jsreport logo to our own logo while printing a report.
    0_1663695514410_upload-44e4ce9f-04be-4e74-aa79-fab00625aaa6

    Could you please show me one example?



  • The image you refer to is a favicon, that isn't configurable.
    You can only manually replace the following file in your deployment
    node_modules/jsreport-studio/static/favicon.ico



  • hi sir i just manually replaced the favicon.ico from node_modules (by running localhost) then i render report using jsreport-browser-client package but icon is not replaced.

    0_1664383030978_upload-8a6fcfbc-35bc-4b61-b70b-72b7c0073467

    0_1664383504173_upload-4139614f-8196-4e9a-a59e-727db9d24f73

    Actually icon is replaced but folder image is still jsreport.



  • The browsers do cache the favicon... You will need to clear it.



  • Hi sir,
    i have cleared the cache but still its not displaying the favicon (Even jsreport favicon itself not displaying).

    code :

    import jsreport from '@jsreport/browser-client';

    var request = {
    template: {
    recipe: 'html',
    shortid: 'rkJTnK2ce',
    }
    };

    jsreport["serverUrl"] = 'http://localhost:5460';

            jsreport.render(request )
                .then((res: any) => {
                   res.openInWindow();
                }, (error) => {
                    console.log(error);
                });
    

    Result

    0_1664390951750_upload-f7acac2d-df53-4b17-85cf-b15b3311d959



  • But if i try to render report directly from studio favicon changed

    0_1664392165439_upload-3d4358b9-2138-4234-8333-5b1c45ec611e
    0_1664392187024_upload-82130521-0ff8-452f-9102-cbc514a9e6fc

    But we are rendering our using jsreport-browser client it doesnt changed code ,
    var request = {
    template: {
    recipe: 'html',
    shortid: 'rkJTnK2ce',
    }
    };

    jsreport["serverUrl"] = 'http://localhost:5460';

        jsreport.render(request )
            .then((res: any) => {
               res.openInWindow();
            }, (error) => {
                console.log(error);
            });
    

    Is favicon works in blob report? we are returning our report in blob like this,
    0_1664394248115_upload-c4b09309-ae33-4ad8-b3ad-4f9cd88bb360



  • Yes, I see. I apologize, I din't carefully check the screenshot when mentioning cache.

    The browser may skip favicon load when displaying blob. Likely not much to do about it I am afraid. I haven't found a reference to it.

    However, If you find a reference on what we can do about it, we will happily check it out.



  • Ok sir .Also sir i have one doubt ,

    Our Application is Multi-Tenant Application so each client have their own folder in jsreport studio for keeping their templates and also one global templates and global Helper (where we use to store templates and helpers common for all client}.This is our folder structure in studio. Right now we are developing our application in development and later on we will deploy those global folders and global helper to production so how to export only specific folder (global folder and global helper) from Development (jsreport studio) to Production (Jsreport studio) .

    Folder structure in Development is like this,


    0_1664397289896_upload-3e5bbf88-b422-45f6-ab39-ca1104c12b11 0_1664397146540_upload-af21df11-2af2-43da-a3f8-5c5fbed2c119

    Folder Structure in Production is like this,


    0_1664397347167_upload-3c5b8191-c84a-41a3-b387-26f8ec1ecdb9

    We are using mongo db for storing templates. Right now we are exporting the whole templates from dev to production (By right click on the studio then it will generate an export file) and manually change the client templates in production but it is very hectic work.Is there any other way to deploy only specific folder from dev to production?

    So,

    • If i export only global templates and global helper from dev to production should i have to manually change the parent shortid of this imported global folders from dev in production and manually assign the root folder short id of production folder?

    • Could you please suggest me any solution about how to deploy templates from development server to production ?


Log in to reply
 

Looks like your connection to jsreport forum was lost, please wait while we try to reconnect.