Announcement

Collapse
No announcement yet.

Problem printing to PDF.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problem printing to PDF.

    Hello everyone.
    I'm developing an application for personal use, using EspoCRM.
    I have a small mechanic workshop, and I always kept all the files in handwriting, or as a last resort, in an excel sheet.
    After studying how EspoCRM works, and because I'm very interested in technologies, I tried to create a program simply to record the maintenance I do on cars.
    So, I'm using the entity (I don't know if it's correct to call it that), Account, Task (Modified to register mechanic services), and I've created 3 basic entities, one called "vehicle" (which I register the vehicles, and I assign to an account as parent and child), another called "Marks" where I simply use the "name" field to register the brand of the vehicle that can be obtained from a list, by the entity "Vehicles", and finally, the entity "Services", where I also only use the name field, to register services that I can select from a list, for example:
    - oil change.
    - changing filters...
    (Linked to an Task as One to Many)

    What I tried, finally, was to create a PDF with a record of the services to be performed... so I could print it and put it next to the car to know what to do.
    I created a template for the Task entity, and inserted the necessary fields.
    It turns out that when I select the field {{serviceNames}}, it just returns a field [object Object] when i print to pdf.
    I registered 3 jobs in the Task. If I print {{servicosIds}}, it shows 3 codes separated by commas, but it wasn't even the IDs I needed, I really need the text in the names...
    Can you help me?
    Everything in my application is working as intended. simple but it works. Only the PDF does not work properly.


    I don't know if it matters, I'm using xampp as an internal server. The application is for personal use, without the need to be shared with anyone else, or to be "online".​

    I'm sorry if I made any typos, English is not my native language.​

  • #2
    Hi sacrus,

    Perhaps the following threads will be helpful:

    One of the most common requirements all users of a CRM system have is saving the copies of the needed invoices, reports or other types of documents in PDF format in order to be able to send them as an email attachment to the customer or just print them out.

    Auf YouTube findest du die angesagtesten Videos und Tracks. Außerdem kannst du eigene Inhalte hochladen und mit Freunden oder gleich der ganzen Welt teilen.

    Comment


    • #3
      It object because it is an array (multiple item: like vehicle ford, vehicle honda, vehicle toyota, etc).

      So you have to use the #each command if I remember right, you can look through the Documentation Vadym post.

      And well done trying to join this journey, when I see mechanic I just feel like you some old Elder. Anyway just plugging the 'wiki', you may be able to find some interesting information here:
      Contribute to o-data/EspoCRM-Learning-and-Design development by creating an account on GitHub.

      Comment


      • #4
        Hi
        I tried to user {pageNumber} and {totalpageNumber} on QUOTE PDF template (TCPDF engine) but it doesn't work. Can someone post a simple HTML code to be placed in the bottom of my pdf template to enum pages? Thanks a lot.
        Michele​

        Comment


        • #5
          This works for me:

          Code:
          <br><br><hr><p style="text-align:center; font-size: 10px;">Mietvertrag Kunstwerke - Page {pageNumber} of {totalPageNumber}</p>
          Looks like this:



          Comment


          • #6
            Originally posted by Vadym View Post
            Hi sacrus,

            Perhaps the following threads will be helpful:

            One of the most common requirements all users of a CRM system have is saving the copies of the needed invoices, reports or other types of documents in PDF format in order to be able to send them as an email attachment to the customer or just print them out.

            https://www.youtube.com/watch?v=FrgqkwxZpiI
            Thanks you for your time.
            I'll try to find the solution in the documentation you sent me, and learn some new things.
            I was hoping that the solution was something simple or logical, something that I wasn't doing well... I quickly learned to work with EspoCRM, of course I didn't become an expert, but I managed to get results in a few days. I think 1 week.
            Most of the time, the problems i found were errors that when searching online, I discovered it was so simple, I just couldn't see the solution...

            Comment


            • #7
              Originally posted by espcrm View Post
              It object because it is an array (multiple item: like vehicle ford, vehicle honda, vehicle toyota, etc).

              So you have to use the #each command if I remember right, you can look through the Documentation Vadym post.

              And well done trying to join this journey, when I see mechanic I just feel like you some old Elder. Anyway just plugging the 'wiki', you may be able to find some interesting information here:
              Contribute to o-data/EspoCRM-Learning-and-Design development by creating an account on GitHub.
              Thanks.
              I'll search. I'm not just a mechanic... a few years ago I took a computer course, I have experience with programming in Visual Basic 6, with access databases...
              That's what we taught in the course in 2003. But that's been a long time without using and/or practicing.
              I'm in my 40s, I don't consider myself elderly.
              I don't have much experience with MySQL, PHP, or HTML... but I'm reading and modifying as I need to... I even tried to start an application in Visual Basic and Database Access, but it consumes a lot of time, and as I no longer I remember half, I have to constantly google it.
              Besides, I spent 2 days just trying to get around the difficulties of installing and using Visual Basic 6 in Windows 10...

              Comment


              • esforim
                esforim commented
                Editing a comment
                There plenty of thing you can do with the GUI of EspoCRM, majority of it I do through GUI. And referencing the official Documents help with a slightly more complex stuff (Formula).

                As for Coding, unless there is a video tutorial or detail guide I skip it.

                When you mention "register vehicle", in my mind, Mechanic. I guess too early
            Working...
            X