Commit e5b81029 authored by Carsten  Rose's avatar Carsten Rose
Browse files

Feature #5080 / Best Practice: Dynamic PDF Letter - preparation

parent df85bb45
......@@ -492,6 +492,7 @@ module.exports = function (grunt) {
production: {
files: {
"extension/Resources/Public/Css/qfq-bs.css": "less/qfq-bs.css.less",
"extension/Resources/Public/Css/qfq-letter.css": "less/qfq-letter.css.less",
"extension/Resources/Public/Css/qfq-plain.css": "less/qfq-plain.css.less",
"extension/Resources/Public/Css/bs-tablesorter.css": "less/bs-tablesorter.less"
},
......@@ -502,6 +503,7 @@ module.exports = function (grunt) {
devel: {
files: {
"css/qfq-bs.css": "less/qfq-bs.css.less",
"css/qfq-letter.css": "less/qfq-letter.css.less",
"css/qfq-plain.css": "less/qfq-plain.css.less",
"css/bs-tablesorter.css": "less/bs-tablesorter.less"
},
......
......@@ -3400,7 +3400,8 @@ Type: sendmail
* For debugging, please check `REDIRECT_ALL_MAIL_TO`_.
Example to attach one file and concatenate PDF files to a single one, whose source are web pages: ::
Example to attach one file1.pdf (with the attachment filename 'readme.pdf') and concatenate two PDF, created on the fly
from the www.example.com and ?export (with the attachment filename 'personal.pdf'): ::
sendMailAttachmemt = F:fileadmin/file1.pdf|d:readme.pdf|C|u:http://www.example.com|p:?id=export&r=123&_sip=1|d:personal.pdf
......
......@@ -38,7 +38,7 @@ i.@{spinner_class} {
margin-top: 10px;
}
/*inline elements in horizontal mode are too much left*/
/* inline elements in horizontal mode are too much left */
.form-horizontal {
.form-inline {
.form-group {
......@@ -496,4 +496,3 @@ i.@{spinner_class} {
a.noclick {
pointer-events: none;
}
// Letter
body {
font-family: Arial, sans-serif;
}
header {
height: 205px;
}
.letter-unit {
position: absolute;
/* background-color: yellow; */
display: inline-block;
font-size: 0.9em;
left: 585px;
top: 0;
width: 285px;
height: 205px;
}
.letter-logo {
position: absolute;
top: 0;
left: 28px;
width: 235px;
}
.letter-title {
font-size: 1.1em;
font-weight: bold;
}
.letter-sender {
position: relative;
display: inline-block;
/* background-color: lime; */
font-size: 0.9em;
left: 118px;
top: 0;
width: 285px;
height: 250px;
}
.letter-receiver {
position: relative;
display: inline-block;
top: -50px;
left: 111px;
width: 455px;
height: 250px;
/* background-color: red; */
}
.letter-date {
position: relative;
display: block;
/* background-color: blue; */
top: -43px;
left: 111px;
width: 750px;
}
.letter-no-break {
page-break-inside: avoid;
}
.letter-body {
margin-left: 111px;
width: 750px;
/* background-color: orange; */
}
.letter-h1 {
font-size: 1em;
font-weight: bold;
}
\ No newline at end of file
<?php
/**
* Created by PhpStorm.
* User: ep
* Date: 12/23/15
* Time: 6:16 PM
*/
namespace qfq;
use qfq;
//use qfq\UserException;
//use qfq\CodeException;
//use qfq\DbException;
require_once(__DIR__ . '/../qfq/QuickFormQuery.php');
require_once(__DIR__ . '/../qfq/exceptions/UserException.php');
require_once(__DIR__ . '/../qfq/exceptions/CodeException.php');
require_once(__DIR__ . '/../qfq/exceptions/DbException.php');
//TODO: unit tests fuer alle abgefangenen Exceptions
/*
*
* @param string $bodytext keyvalue pairs.
*
* @return $string LOAD: the form as HTML, SAVE: success or failure message, or JS redirect to destination page.
*/
function renderForm($bodytext = "") {
try {
$qfq = new QuickFormQuery($bodytext);
echo $qfq->process();
echo "test";
} catch (UserFormException $e) {
echo $e->formatMessage();
} catch (CodeException $e) {
echo $e->formatMessage();
} catch (DbException $e) {
echo $e->formatMessage();
} catch (\Exception $e) {
echo "Generic Exception: " . $e->getMessage();
}
}
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment