feat: UI improvements

This commit is contained in:
Vlad Stan 2023-01-16 16:26:31 +02:00
parent 2da466f0c8
commit e8bed9cd90
2 changed files with 11 additions and 26 deletions

View File

@ -171,36 +171,20 @@
group="extras"
icon="download"
:label="release.description"
:caption="'Version: ' + release.version"
:caption="release.version"
:content-inset-level="0.5"
>
<q-expansion-item
group="api"
dense
expand-separator
label="List pay links"
>
<q-card>
<q-card-section>
<h5 class="text-caption q-mt-sm q-mb-none">Headers</h5>
</q-card-section>
</q-card>
</q-expansion-item>
<q-expansion-item
group="api"
dense
expand-separator
label="Get a pay link"
>
<q-card>
<q-card-section> </q-card-section>
</q-card>
</q-expansion-item>
<q-card>
<q-card-section>
<h5 class="text-caption q-mt-sm q-mb-none">Headers</h5>
</q-card-section>
</q-card>
</q-expansion-item>
</q-list>
</q-card-section>
</q-card>
</div>
<q-spinner v-else color="primary" size="2.55em"></q-spinner>
<div class="row q-mt-lg">
<q-btn v-close-popup flat color="grey" class="q-ml-auto">Close</q-btn>
</div>
@ -325,7 +309,7 @@
console.log('### showUpgrade')
this.selectedExtension = extension
this.showUpgradeDialog = true
this.selectedExtensionRepos = []
this.selectedExtensionRepos = null
const {data} = await LNbits.api.request(
'GET',
`/api/v1/extension/${extension.id}/releases?usr=${this.g.user.id}`,

View File

@ -109,19 +109,20 @@ class ExtensionRelease(BaseModel):
source_repo: str
hash: Optional[str]
published_at: Optional[str]
url: Optional[str]
html_url: Optional[str]
description: Optional[str]
@classmethod
def from_github_release(cls, source_repo: str, r: dict) -> "ExtensionRelease":
return ExtensionRelease(
name=r["name"],
description=r["name"],
version=r["tag_name"],
archive=r["zipball_url"],
source_repo=source_repo,
# description=r["body"], # bad for JSON
published_at=r["published_at"],
url=r["html_url"],
html_url=r["html_url"],
)
@classmethod