mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 03:06:37 +00:00
%EVTPART added
git-svn-id: https://svn.fhem.de/fhem/trunk@999 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
8746e85298
commit
c4ecbbf695
@ -6701,10 +6701,11 @@ href="http://www.elv.de/output/controller.aspx?cid=74&detail=10&detail2=29870">U
|
|||||||
<li>To use % or @ in the text itself, use the double mode (%% or @@).</li>
|
<li>To use % or @ in the text itself, use the double mode (%% or @@).</li>
|
||||||
|
|
||||||
<li>Instead of <code>%</code> and <code>@</code>, the parameters
|
<li>Instead of <code>%</code> and <code>@</code>, the parameters
|
||||||
<code>%EVENT</code> (same as <code>%</code>), <code>%NAME</code>
|
<code>%EVENT</code> (same as <code>%</code>), <code>%NAME</code> (same as
|
||||||
(same as <code>@</code>) and <code>%TYPE</code> (contains the device
|
<code>@</code>) and <code>%TYPE</code> (contains the device type, e.g.
|
||||||
type, e.g. <code>FHT</code>) can be used. A single <code>%</code>
|
<code>FHT</code>) can be used. The space separated event "parts" are
|
||||||
looses its special meaning if any of these parameters appears in the
|
available as %EVTPART0, %EVTPART1, etc. A single <code>%</code> looses
|
||||||
|
its special meaning if any of these parameters appears in the
|
||||||
definition.</li>
|
definition.</li>
|
||||||
|
|
||||||
<li><code><pattern></code> may also be a compound of
|
<li><code><pattern></code> may also be a compound of
|
||||||
|
11
fhem/fhem.pl
11
fhem/fhem.pl
@ -167,7 +167,7 @@ my $nextat; # Time when next timer will be triggered.
|
|||||||
my $intAtCnt=0;
|
my $intAtCnt=0;
|
||||||
my %duplicate; # Pool of received msg for multi-fhz/cul setups
|
my %duplicate; # Pool of received msg for multi-fhz/cul setups
|
||||||
my $duplidx=0; # helper for the above pool
|
my $duplidx=0; # helper for the above pool
|
||||||
my $cvsid = '$Id: fhem.pl,v 1.150 2011-08-16 18:06:38 rudolfkoenig Exp $';
|
my $cvsid = '$Id: fhem.pl,v 1.151 2011-09-12 15:22:06 rudolfkoenig Exp $';
|
||||||
my $namedef =
|
my $namedef =
|
||||||
"where <name> is either:\n" .
|
"where <name> is either:\n" .
|
||||||
"- a single device name\n" .
|
"- a single device name\n" .
|
||||||
@ -1981,6 +1981,14 @@ EvalSpecials($%)
|
|||||||
$exec = SemicolonEscape($exec);
|
$exec = SemicolonEscape($exec);
|
||||||
|
|
||||||
$exec =~ s/%%/____/g;
|
$exec =~ s/%%/____/g;
|
||||||
|
|
||||||
|
# %EVTPART due to HM remote logic
|
||||||
|
my $idx = 0;
|
||||||
|
foreach my $part (split(" ", $specials{"%EVENT"})) {
|
||||||
|
$specials{"%EVTPART$idx"} = $part;
|
||||||
|
$idx++;
|
||||||
|
}
|
||||||
|
|
||||||
# perform macro substitution
|
# perform macro substitution
|
||||||
my $extsyntax= 0;
|
my $extsyntax= 0;
|
||||||
foreach my $special (keys %specials) {
|
foreach my $special (keys %specials) {
|
||||||
@ -2482,6 +2490,7 @@ addToAttrList($)
|
|||||||
$attr{global}{userattr} = join(" ", sort keys %hash);
|
$attr{global}{userattr} = join(" ", sort keys %hash);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# $dir: 0 = User to Fhem (i.e. set), 1 = Fhem to User (i.e trigger)
|
||||||
sub
|
sub
|
||||||
ReplaceEventMap($$$)
|
ReplaceEventMap($$$)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user