Skip to content

Conversation

@scottmcdonnell
Copy link
Contributor

Looking at assets - assets can be assigned to one episode when created or edited which sets the parent_id for the entity, but also assets can be linked to an episode using breakdown (entity_link).

Problem
When we look at the asset list for a given episode it shows all assets linked to the episode but when you go into a task type for the asset you see only the assets parented to the episode. The lists differ.

Sometimes we want to see all assets linked to the episode via breakdown and sometimes we want to be able to see just the assets that are unique to this episode.

Solution
Option added to display settings to toggle on/off the linked assets.

image

filter added to view to combine filter for linked assets with shared assets.

… to be toggled off, filtering the list of assets to only those parented to the episode_id.
@NicoPennec NicoPennec self-requested a review January 27, 2026 09:12
Comment on lines 478 to 501
// Filter the displayed assets by the display settings
displayedAssetsByTypeFiltered() {
if (
this.displaySettings.showSharedAssets &&
this.displaySettings.showLinkedAssets
) {
return this.displayedAssetsByType
}
const episodeId = this.currentEpisode?.id

return this.displayedAssetsByType.map(typeList => {
return typeList.filter(asset => {
if (!this.displaySettings.showSharedAssets && asset.shared) {
return false
}
if (
!this.displaySettings.showLinkedAssets &&
!['all', asset.episode_id || 'main'].includes(episodeId)
) {
return false
}
return true
})
})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For a production without episodes (eg, a feature film), it does not seem to work.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This filter is based on the similar behaviour when you look at the task type page so they are consistent -https://github.com/cgwire/kitsu/blob/main/src/components/pages/TaskType.vue#L1331

It probably needs the checks this.isTVShow and maybe this.isEpisodesSection - and for the displaySettings too. Let me take a look

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed this issue and added a few more things.

I have updated the assets list to show the correct info at the bottom for number of assets, days spent etc. This changed from using the store assets.js and replicated the approach in the task list.

I have also added display settings to the TaskType page so you can do the same filter there for Display Breakdown Assets - to make the list of tasks consistent between Assets.vue and TaskType.vue

number: 'asset | assets',
restore_text: 'Are you sure you want to restore {name} from your archive?',
restore_error: 'An error occurred while restoring this asset.',
show_linked: 'Display Linked Assets',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This label seems unclear: linked by what?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe there is a better way of wording? These are Assets linked via breakdown (one to many) as distinct from assets linked via parenting to episode (one to one).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about "Display Breakdown Assets" ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants