このリポジトリは2023-09-09にアーカイブされています。 ファイルの閲覧とクローンは可能ですが、プッシュ、イシューの作成、プルリクエストはできません。
076server/resources/assets/js/components/Home/Hot.vue

49 行
1.3 KiB
Vue

<template>
<div class="container">
<div class="row">
<span v-for="item in items">
<div class="col-md-2">
<a :href="'/entry/' + item.id">
<img :src="'/assets/store/' + item.id + '/screens/1.png'" width="100px" height="100px" />
<br />
{{ item.title }}
</a>
<br />
<a href="/profile/0">
Name
</a>
<br />
Downloads: {{ item.downloads }}
</div>
</span>
</div>
</div>
</template>
<script>
export default {
name: 'hot-items',
data: function () {
return {
items: []
}
},
created: function () {
axios.get('/api/rpc/file/gethotfiles').then(data => {
data.data.forEach(cb => {
this.items.push({
'id': cb.id,
'title': cb.title,
'downloads': cb.downloads
});
});
})
}
}
</script>
<style>
.col {
text-align: center;
}
</style>