mirror of
https://github.com/solidtime-io/solidtime.git
synced 2026-08-16 20:22:15 +01:00
add empty state for members activity, fix organization switch data loading problem
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
import DashboardCard from '@/Components/Dashboard/DashboardCard.vue';
|
||||
import TeamActivityCardEntry from '@/Components/Dashboard/TeamActivityCardEntry.vue';
|
||||
import { UserGroupIcon } from '@heroicons/vue/20/solid';
|
||||
import { router } from '@inertiajs/vue3';
|
||||
import SecondaryButton from '@/Components/SecondaryButton.vue';
|
||||
|
||||
defineProps<{
|
||||
latestTeamActivity: {
|
||||
@@ -24,5 +26,20 @@ defineProps<{
|
||||
:name="activity.name"
|
||||
:description="activity.description"
|
||||
:working="activity.status"></TeamActivityCardEntry>
|
||||
<div
|
||||
v-if="latestTeamActivity.length <= 2"
|
||||
class="text-center flex flex-1 justify-center items-center">
|
||||
<div>
|
||||
<UserGroupIcon
|
||||
class="w-8 text-icon-default inline pb-2"></UserGroupIcon>
|
||||
<h3 class="text-white font-semibold text-sm">
|
||||
Invite your co-workers
|
||||
</h3>
|
||||
<p class="pb-5 text-sm">You can invite your entire team.</p>
|
||||
<SecondaryButton @click="router.visit(route('members'))"
|
||||
>Go to Members
|
||||
</SecondaryButton>
|
||||
</div>
|
||||
</div>
|
||||
</DashboardCard>
|
||||
</template>
|
||||
|
||||
@@ -5,6 +5,7 @@ import DropdownLink from '@/Components/DropdownLink.vue';
|
||||
import { router, usePage } from '@inertiajs/vue3';
|
||||
import type { Organization, User } from '@/types/models';
|
||||
import { isBillingActivated } from '@/utils/billing';
|
||||
import { initializeStores } from '@/utils/init';
|
||||
|
||||
const page = usePage<{
|
||||
jetstream: {
|
||||
@@ -28,6 +29,9 @@ const switchToTeam = (team: Organization) => {
|
||||
},
|
||||
{
|
||||
preserveState: false,
|
||||
onSuccess: () => {
|
||||
initializeStores();
|
||||
},
|
||||
}
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user