
lucasgaitzsch/pdf-turtle --> |go to model tab| MO(paste an<br> example model) click O href "[***]" "[***]" O --> |go to body tab| B(design the body) O --> |go to header tab| H(design the header) O --> |go to footer tab| F(design the footer) O --> |go in asstes menu| A(put your assets) OPT(set your<br> options) MO --> OPT B --> OPT H --> OPT F --> OPT A --> OPT OPT --> S(fa:fa-file-zipper save as<br> ZIP bundle) end subgraph YP[your fancy project] direction TB PA(provide as asset) PA-->CL(use clent lib) PA-->SGC(use swagger to<br> build or generate client) R(render PDF with<br> bundle and your model) CL-->R SGC-->R R-->BH(fa:fa-smile be happy!) end S-->|copy zip bundle<br> to your project|YP %%PG-->YP
Choose the fitting client lib for your language or generate / build your own by the OpenApi (Swagger) description.
Go to 🐢PdfTurtle-Playground, put an example model as JSON and design your PDF. Download the bundle as ZIP file and put it in your resources/assets.
!PdfTurtleBundle-Workflow
Send a request to a PdfTurtle instance with your bundle and your model. You will get a rendered PDF.
And thats it.
If you want to have the same header for all documents, you can create a ZIP file with with only the header.html and the required assets. Now you can call the Service with multiple bundle files. The service will assemble the files together. Single files can be send as bundle-component without compressing to a ZIP file. All files with other names than "index.html", "header.html", "footer.html" and "options.json" will be put to the folder "/assets/".
You can write and test templates with the builtin playground.
Use Swagger-UI under /swagger/index.html as API documentation.
You can use the swagger description (/swagger/doc.json or ./server/docs/swagger.json) to generate a API client for the language of your choice.
You can import the swagger file to test the service with Postman or an alternative.
| Template style | Package | PdfTurtle key | URL |
|---|---|---|---|
| Golang | html/template | golang | [***] |
| Django-syntax like (require model. prefix) | pongo2 | django | [***] |
| Handlebars-syntax like | raymond | handlebars | [***] |
| Function name | Parameters | Description |
|---|---|---|
| marshal | object | Encodes provided object as JSON string |
| barcodeQr | content | Renders a SVG QR code from content |
| barcodeEan | content | Renders a SVG EAN code from content |
| strContains | haystack, needle | Does the haystack contains the needle |
| strHasPrefix | haystack, needle | Does the first string starts with the second |
| strHasSuffix | haystack, needle | Does the first string end with the second |
| add | float64, float64 | Adds two float64 numbers |
| subtract | float64, float64 | Subtracts two float64 numbers |
| multiply | float64, float64 | Multiplies two float64 numbers |
| divide | float64, float64 | Divides two float64 numbers |
| float64ToInt | float64 | Convert a int to float64 |
| intToFloat64 | int | Convert a float64 to int |
| bitwiseAnd | int, int | a & b |
See README_DEV.md.
Contributors are welcome! Feel you free to fork the project and open a pull request.
If you wrote a client lib for a uncovered language please contact me. I will create a repo for you or link your client lib in this readme file.
探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式
通过 Docker 登录认证访问私有仓库
无需登录使用专属域名
Kubernetes 集群配置 Containerd
K3s 轻量级 Kubernetes 镜像加速
VS Code Dev Containers 配置
Podman 容器引擎配置
HPC 科学计算容器配置
ghcr、Quay、nvcr 等镜像仓库
Harbor Proxy Repository 对接专属域名
Portainer Registries 加速拉取
Nexus3 Docker Proxy 内网缓存
需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单
manifest unknown
no matching manifest(架构)
invalid tar header(解压)
TLS 证书失败
DNS 超时
410 Gone 排查
402 与流量用尽
401 认证失败
429 限流
D-Bus 凭证提示
413 与超大单层
来自真实用户的反馈,见证轩辕镜像的优质服务