Announcement

Collapse
No announcement yet.

PDF issue / question

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

  • PDF issue / question

    Hello everyone,

    I was hoping someone has resolved the following issue and willing to assist.

    I produce a lot of interview transcripts within my espocrm. I currently have a PDF report that is exported for each transcript. However, I would like to add line numbers to the report. The following is an example:

    1. Someone: I was walking down the street.

    2.

    3. Second person: What did you see?

    4.

    5. Someone: I did not see anything.

    6.

    7.


    This type of line numbering is the same as seen on US legal documents.

    Has anyone dealt with this issue?

  • #2
    Hi, it is difficult to understand, what exactly you want. What is your entity output? Which fields do you want to use in the PDF? And what is static?

    Comment


    • #3
      Consider the numbers displayed on the edge of a code editor that provides a reference for the line of text. I need to show the same numbers on my PDF

      Comment


      • #4
        As I understand, you need a template with a fixed first column of numbers, of which all or some are followed by values from your entity.. If so, I would create a table in the PDF template and in the first column you put the numbers, in the next column(s) the field placeholders of the referenced fields.

        Comment


        • #5
          Something like this I presume? https://digital.library.unt.edu/ark:...dc851840/m1/4/

          Not possible by default I believe, shalmaxb solution might work if you have any coding experience.

          I most likely won't be using this but I like the idea behind it if I ever want to produce Transcript Logs style.

          Comment


          • #6
            Yes. espcrm is right, you can't do that without additional coding. EspoCRM is using TCPDF as engine for generating PDF's. I've checked few things in google and i thing it's possible.
            First thing: https://stackoverflow.com/questions/...mbers-to-tcpdf
            Second is builtin function called getNumLines, maybe it'll help you. You can find more information by searching "TCPDF::getNumLines"

            If you'll search anything about that, add to string "TCPDF", i saw few examples in google, but i didn't test them.
            Also please remember that if you want to change anything in espocrm, don't do that in application folder, because it don't be safe from updates. You should do that in custom directory

            Comment


            • espcrm
              espcrm commented
              Editing a comment
              Thanks emillod, quick question if you can help answer. I know the answer lying somewhere in the forum but I have no idea how to search for it. I'm just creating this section here: https://forum.espocrm.com/forum/gene...5114#post55114

              Call Administration Details / Server Developer; I already added what you just said (TCPDF) and Bootscrap (based on telecastg thread), but do you know which coding language it is? Or is there any other "library" that being used in EspoCRM?

            • emillod
              emillod commented
              Editing a comment
              espcrm if i'm understanding you correctly, you should add there:
              1. html/css - bootstrap
              2. JS
              3. many files are there in json(whole structure of fields in entityDefs etc)
              4. Object Oriented PHP

            • espcrm
              espcrm commented
              Editing a comment
              Thank you; updated. Hopefully we get more developer in future.

              Not sure what to write for your #3 though, here is the update and I welcome any "Pull request"

              HTML/CSS: Bootstrap - https://getbootstrap.com/
              Print-to-PDF_ Template: TCPDF - https://tcpdf.org/
              Language/Code: Object Oriented PHP / JS (Javascript)
              API: ResAPI v1 / JSON - https://docs.openshift.com/container...api/index.html
              Last edited by espcrm; 09-10-2020, 08:21 AM.
          Working...
          X