diff --git a/fhem/CHANGED b/fhem/CHANGED index 4cf57c6b0..2826964ec 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -1,5 +1,6 @@ # Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Do not insert empty lines here, update check depends on it. + - feature: 42_AptToDate: add Attribut upgradeListReading for Reading in JSON - change: 98_DOIFtools: added shortcut remove_DOIFtoolsLog to commandref - change: 01_FHEMWEB.pm: default plotEmbed to 0 (Forum #82351) - feature: 73_GardenaSmartBridge: 74_GeardenaSmartDevice: add support for diff --git a/fhem/FHEM/42_AptToDate.pm b/fhem/FHEM/42_AptToDate.pm index 2e98ee7bd..dd114fee9 100644 --- a/fhem/FHEM/42_AptToDate.pm +++ b/fhem/FHEM/42_AptToDate.pm @@ -49,7 +49,7 @@ eval "use JSON;1" or $missingModul .= "JSON "; -my $version = "0.2.2"; +my $version = "0.2.4"; @@ -102,6 +102,7 @@ sub AptToDate_Initialize($) { $hash->{AttrFn} = "AptToDate_Attr"; $hash->{AttrList} = "disable:1 ". "disabledForIntervals ". + "upgradeListReading:1 ". $readingFnAttributes; @@ -690,6 +691,7 @@ sub AptToDate_WriteReadings($$) { } readingsBulkUpdateIfChanged($hash,'updatesAvailable',scalar keys %{$decode_json->{packages}}) if( $hash->{".fhem"}{aptget}{cmd} eq 'getUpdateList' ); + readingsBulkUpdateIfChanged($hash,'upgradeListAsJSON',eval{encode_json($hash->{".fhem"}{aptget}{packages})}) if( AttrVal($name,'upgradeListReading','none') ne 'none'); readingsBulkUpdate($hash,'toUpgrade','successful') if( $hash->{".fhem"}{aptget}{cmd} eq 'toUpgrade' and not defined($hash->{".fhem"}{aptget}{'errors'}) and not defined($hash->{".fhem"}{aptget}{'warnings'}) ); if( $hash->{".fhem"}{aptget}{cmd} eq 'getDistribution' ) { @@ -920,6 +922,7 @@ sub AptToDate_ToDay() { Attributes @@ -983,6 +986,7 @@ sub AptToDate_ToDay() { Attributes