Returning actor birth and residence data. Fixed campaign scenes not updating with filters.

This commit is contained in:
DebaucheryLibrarian 2024-06-12 03:28:40 +02:00
parent 50ff352067
commit aef0198cab
3 changed files with 8 additions and 2 deletions

View File

@ -136,7 +136,7 @@
</template>
<script setup>
import { ref, inject } from 'vue';
import { ref, computed, inject } from 'vue';
import { parse } from 'path-to-regexp';
import navigate from '#/src/navigate.js';
@ -208,7 +208,8 @@ const filters = ref({
const campaign = pageProps.campaigns?.scenes;
const campaignIndex = pageProps.campaigns?.index;
const campaignScenes = scenes.value.flatMap((scene, index) => (index === campaignIndex ? ['campaign', scene] : scene));
const campaignScenes = computed(() => scenes.value.flatMap((scene, index) => (index === campaignIndex ? ['campaign', scene] : scene)));
function getPath(targetScope, preserveQuery) {
const path = parse(routeParams.path).map((segment) => {

View File

@ -47,6 +47,8 @@ export function curateActor(actor, context = {}) {
name: actor.birth_country_name,
alias: actor.birth_country_alias,
},
city: actor.birth_city,
state: actor.birth_state,
},
residence: actor.residence_country_alpha2 && {
country: actor.residence_country_alpha2 && {
@ -54,6 +56,8 @@ export function curateActor(actor, context = {}) {
name: actor.residence_country_name,
alias: actor.residence_country_alias,
},
city: actor.residence_city,
state: actor.residence_state,
},
avatar: curateMedia(actor.avatar),
profiles: context.profiles?.map((profile) => ({

View File

@ -12,5 +12,6 @@ export function curateMedia(media) {
width: media.width,
height: media.height,
index: media.index,
credit: media.credit,
};
}