Revised remote manifest updates

This commit is contained in:
MikeMaximus
2018-03-03 20:04:59 -06:00
parent 9a024349f5
commit 9907565145
3 changed files with 13 additions and 19 deletions
+5 -3
View File
@@ -48,10 +48,12 @@ Public Class mgrBackup
oItem.CheckSum = sCheckSum
'Save Remote Manifest
If mgrManifest.DoSpecificManifestCheck(oItem, mgrSQLite.Database.Remote) Then
mgrManifest.DoManifestUpdateByManifestID(oItem, mgrSQLite.Database.Remote)
If Not oGameInfo.AppendTimeStamp Then
If Not mgrManifest.DoUpdateLatestManifest(oItem, mgrSQLite.Database.Remote) Then
mgrManifest.DoManifestAdd(oItem, mgrSQLite.Database.Remote)
End If
Else
mgrManifest.DoManifestAdd(oItem, mgrSQLite.Database.Remote)
mgrManifest.DoManifestAdd(oItem, mgrSQLite.Database.Remote)
End If
'Save Local Manifest
+8 -11
View File
@@ -114,25 +114,22 @@
Return oBackupItem
End Function
'This should only be used to update specific entries in the remote manifest
Public Shared Function DoSpecificManifestCheck(ByRef oItem As clsBackup, ByVal iSelectDB As mgrSQLite.Database) As Boolean
Public Shared Function DoUpdateLatestManifest(ByRef oItem As clsBackup, ByVal iSelectDB As mgrSQLite.Database) As Boolean
Dim oDatabase As New mgrSQLite(iSelectDB)
Dim oData As DataSet
Dim oData As Object
Dim sSQL As String
Dim hshParams As New Hashtable
sSQL = "SELECT * FROM manifest NATURAL JOIN monitorlist "
sSQL &= "WHERE MonitorID = @MonitorID AND FileName = @FileName"
sSQL = "SELECT ManifestID FROM manifest NATURAL JOIN monitorlist "
sSQL &= "WHERE MonitorID = @MonitorID ORDER BY DateUpdated DESC LIMIT 1"
hshParams.Add("MonitorID", oItem.MonitorID)
hshParams.Add("FileName", oItem.FileName)
oData = oDatabase.ReadParamData(sSQL, hshParams)
oData = oDatabase.ReadSingleValue(sSQL, hshParams)
If oData.Tables(0).Rows.Count > 0 Then
For Each dr As DataRow In oData.Tables(0).Rows
oItem.ManifestID = CStr(dr("ManifestID"))
Next
If Not oData Is Nothing Then
oItem.ManifestID = CStr(oData)
DoManifestUpdateByManifestID(oItem, mgrSQLite.Database.Remote)
Return True
Else
Return False
-5
View File
@@ -42,10 +42,5 @@ Linux Only:
- GBM now uses notify-send (libnotify) if it's available to display notifications on Linux.
- Mono style notifications will be displayed if notify-send is not available.
- The GBM icon will be displayed on notifications if it's been installed to the correct location (via makefile or deb).
Known Issues:
- After upgrading to v1.1.0, backup manifest entries and files created with prior versions are not overwritten when a new backup is created.
The entire version history of GBM releases is available at http://mikemaximus.github.io/gbm-web/versionhistory.html