Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-#130 Show in the playlist all tracks duration #135

Merged
merged 2 commits into from
Mar 13, 2024
Merged

Conversation

nicolasparrague
Copy link
Collaborator

No description provided.

@nicolasparrague nicolasparrague self-assigned this Mar 12, 2024
@nicolasparrague nicolasparrague linked an issue Mar 12, 2024 that may be closed by this pull request
Copy link
Owner

@santiagoparradev santiagoparradev left a comment

Choose a reason for hiding this comment

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

I assume this cannot be achieve using a Roll up summary field because is not a master detail am I right?

@@ -41,6 +41,10 @@
<behavior>Edit</behavior>
<field>Public__c</field>
</layoutItems>
<layoutItems>
<behavior>Edit</behavior>
Copy link
Owner

Choose a reason for hiding this comment

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

Shouñd be read only

@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8" ?>
<CustomField xmlns="http://soap.sforce.com/2006/04/metadata">
<fullName>TotalTracksDuration__c</fullName>
Copy link
Owner

Choose a reason for hiding this comment

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

Just name it Duration

@@ -119,6 +119,11 @@
<field>Playlist__c.SpotifyId__c</field>
<readable>true</readable>
</fieldPermissions>
<fieldPermissions>
<editable>true</editable>
<field>Playlist__c.TotalTracksDuration__c</field>
Copy link
Owner

Choose a reason for hiding this comment

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

Read only

@@ -37,16 +37,27 @@ public class SyncPlaylist {
.replaceAll('"public" :', '"publicField" :'));

for (SimplefiedPlaylistObject playlist : playlists.items) {
Integer TotalTracksDuration = 0;
Copy link
Owner

Choose a reason for hiding this comment

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

Use camel case

@nicolasparrague
Copy link
Collaborator Author

I assume this cannot be achieve using a Roll up summary field because is not a master detail am I right?

yes, only is master detail the object playlistTrack or there is another way?

@nicolasparrague nicolasparrague merged commit fefbe1d into dev Mar 13, 2024
@nicolasparrague nicolasparrague deleted the SpotifyApp_130 branch March 13, 2024 05:25
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.

show playlist duration (sum of all tracks duration)
2 participants