Compare commits

...

3 Commits

Author SHA1 Message Date
8a6d77e9cc ui: Force download of XML files
Some checks are pending
continuous-integration/drone/push Build is running
2025-01-14 15:26:04 +01:00
e7b39b0d92 admin: Also fill lastSyncError in autosync 2025-01-14 12:07:11 +01:00
bd5050b24a admin: Fix missing replacement 2025-01-14 10:58:17 +01:00
3 changed files with 4 additions and 2 deletions

View File

@ -284,10 +284,12 @@ func autoSync(c *gin.Context) {
if !IsProductionEnv {
if err := sync.GlobalImporter.Sync(); err != nil {
lastSyncError = err.Error()
log.Println("Unable to sync.GI.Sync:", err.Error())
c.AbortWithStatusJSON(http.StatusInternalServerError, gin.H{"errmsg": "Unable to perform the pull."})
return
}
lastSyncError = ""
}
themes, err := fic.GetThemes()

View File

@ -22,7 +22,7 @@
<div class="badge badge-success align-self-center" ng-if="syncReport" title="{{ syncReport._updated[syncReport._updated.length-1] }}">
Dernier import&nbsp;: {{ syncReport._updated[syncReport._updated.length-1] | date:"medium" }}
</div>
<a ng-if="configro['sync-type'] === 'GitImporter'" href="repositories" class="btn btn-secondary">
<a ng-if="syncStatus['sync-type'] === 'GitImporter'" href="repositories" class="btn btn-secondary">
Voir les dépôts
</a>
</div>

View File

@ -27,7 +27,7 @@
</CardBody>
<ListGroup flush class="border-secondary">
{#each files as file, index}
<ListGroupItem tag="a" href={file.path} target={(file.name.endsWith(".txt") || file.name.endsWith(".jpg") || file.name.endsWith(".png") || file.name.endsWith(".pdf"))?"_blank":"_self"} class="d-flex">
<ListGroupItem tag="a" href={file.path} target={(file.name.endsWith(".txt") || file.name.endsWith(".xml") || file.name.endsWith(".jpg") || file.name.endsWith(".png") || file.name.endsWith(".pdf"))?"_blank":"_self"} class="d-flex">
<h1 class="me-3">
<Icon name="arrow-down-circle" />
</h1>