@@ -105,7 +105,7 @@ public override bool Execute()
105
105
// Relative path (starting from project directory
106
106
baseLocation = FileSystem . Instance . Path . GetFullPath ( FileSystem . Instance . Path . Combine ( preparedData . Project . ProjectDirectory , BaseOutputPath ) ) ;
107
107
}
108
-
108
+
109
109
string destinationFilePath = FileSystem . Instance . Path . Combine ( baseLocation , Configuration , $ "{ PackageId } .{ PackageVersion } .dmapp") ;
110
110
111
111
// Create directories in case they don't exist yet
@@ -212,7 +212,7 @@ private void PackageCatalogReferences(PackageCreationData preparedData, AppPacka
212
212
}
213
213
214
214
// TODO: Handle catalog references
215
-
215
+
216
216
Log . LogWarning ( $ "Not supported yet: { catalogReferencesFile } could not be added to the package.") ;
217
217
}
218
218
@@ -230,13 +230,21 @@ private void PackageBasicFiles(PackageCreationData preparedData, AppPackage.AppP
230
230
appPackageBuilder . WithCompanionFiles ( companionFilesDirectory ) ;
231
231
232
232
// Include LowCodeApps
233
- string lowCodeAppDirectory =
234
- FileSystem . Instance . Path . Combine ( packageContentPath , "LowCodeApps" ) ;
235
- foreach ( string lcaZip in FileSystem . Instance . Directory . GetFiles ( lowCodeAppDirectory , "*.zip" ) )
233
+ IncludeFromPackageContent ( appPackageBuilder , packageContentPath , "LowCodeApps" , ZipType . LowCodeApp ) ;
234
+
235
+ // Include Dashboards
236
+ IncludeFromPackageContent ( appPackageBuilder , packageContentPath , "Dashboards" , ZipType . Dashboard ) ;
237
+ }
238
+
239
+ private void IncludeFromPackageContent ( AppPackage . AppPackageBuilder appPackageBuilder , string packageContentPath , string contentFolderName , ZipType contentType )
240
+ {
241
+ string directory =
242
+ FileSystem . Instance . Path . Combine ( packageContentPath , contentFolderName ) ;
243
+
244
+ foreach ( string zipFile in FileSystem . Instance . Directory . GetFiles ( directory , "*.zip" ) )
236
245
{
237
- Log . LogWarning ( $ "Not supported yet: { lcaZip } could not be added to the package.") ;
238
- // TODO: Handle zip LCA's
239
- //appPackageBuilder.WithLowCodeApp(lcaZip);
246
+ appPackageBuilder . WithZip ( zipFile , contentType ) ;
247
+ Log . LogWarning ( $ "Added { contentType } : { zipFile } ") ;
240
248
}
241
249
}
242
250
0 commit comments