Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
typo3
qfq
Commits
3b517707
Commit
3b517707
authored
May 18, 2016
by
Rafael Ostertag
Browse files
Merge remote-tracking branch 'origin/crose_work' into raos_work
parents
597960d8
4a6daf09
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
extension/qfq/qfq/helper/Support.php
View file @
3b517707
...
...
@@ -520,6 +520,8 @@ class Support {
}
/**
* Concatenate URL and Parameter. Depending of if there is a '?' in URL or not, append the param with '?' or '&'..
*
* @param string $url
* @param string $param
* @return string
...
...
extension/qfq/qfq/report/Link.php
View file @
3b517707
This diff is collapsed.
Click to expand it.
extension/qfq/tests/phpunit/LinkTest.php
View file @
3b517707
This diff is collapsed.
Click to expand it.
extension/qfq/tests/phpunit/ReportTest.php
View file @
3b517707
...
...
@@ -122,15 +122,15 @@ class ReportTest extends AbstractDatabaseTest {
// link, checked
$result
=
$this
->
report
->
process
(
"10.sql = SELECT 'u:http://www.example.com|C' AS _link FROM Person ORDER BY id LIMIT 1"
);
$this
->
assertEquals
(
'<a href="http://www.example.com" ><img src="typo3conf/ext/qfq/Resources/Public/icons/checked-green.gif" title="green" >
</a>'
,
$result
);
$this
->
assertEquals
(
'<a href="http://www.example.com" ><img
alt="Checked green"
src="typo3conf/ext/qfq/Resources/Public/icons/checked-green.gif" title="green" ></a>'
,
$result
);
// linck, checked, text
$result
=
$this
->
report
->
process
(
"10.sql = SELECT 'u:http://www.example.com|C|t:Hello World' AS _link FROM Person ORDER BY id LIMIT 1"
);
$this
->
assertEquals
(
'<a href="http://www.example.com" ><img src="typo3conf/ext/qfq/Resources/Public/icons/checked-green.gif" title="green" > Hello World</a>'
,
$result
);
$this
->
assertEquals
(
'<a href="http://www.example.com" ><img
alt="Checked green"
src="typo3conf/ext/qfq/Resources/Public/icons/checked-green.gif" title="green" > Hello World</a>'
,
$result
);
// link, checked, text, tooltip
$result
=
$this
->
report
->
process
(
"10.sql = SELECT 'u:http://www.example.com|C|t:Hello World|o:more information' AS _link FROM Person ORDER BY id LIMIT 1"
);
$this
->
assertEquals
(
'<a href="http://www.example.com" title="more information" ><img src="typo3conf/ext/qfq/Resources/Public/icons/checked-green.gif" title="green" > Hello World</a>'
,
$result
);
$this
->
assertEquals
(
'<a href="http://www.example.com" title="more information" ><img
alt="Checked green"
src="typo3conf/ext/qfq/Resources/Public/icons/checked-green.gif" title="green" > Hello World</a>'
,
$result
);
}
/**
...
...
@@ -171,10 +171,10 @@ class ReportTest extends AbstractDatabaseTest {
// r:0, mailto
$result
=
$this
->
report
->
process
(
"10.sql = SELECT 'm:john.doe@example.com' AS _link FROM Person ORDER BY id LIMIT 1"
);
$this
->
assertEquals
(
'<a href="mailto:john.doe@example.com" >mailto:john.doe@example.com</a>'
,
$result
);
$this
->
assertEquals
(
'<a href="mailto:john.doe@example.com"
class="external"
>mailto:john.doe@example.com</a>'
,
$result
);
$result
=
$this
->
report
->
process
(
"10.sql = SELECT 'm:john.doe@example.com|e:0' AS _link FROM Person ORDER BY id LIMIT 1"
);
$this
->
assertEquals
(
'<a href="mailto:john.doe@example.com" >mailto:john.doe@example.com</a>'
,
$result
);
$this
->
assertEquals
(
'<a href="mailto:john.doe@example.com"
class="external"
>mailto:john.doe@example.com</a>'
,
$result
);
//TODO: enable encryption check
// $result = $this->report->process("10.sql = SELECT 'm:john.doe@example.com|e:1' AS _link FROM Person ORDER BY id LIMIT 1");
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment