Ejemplo n.º 1
0
 class Meta:
     model = Story
     fields = ['name',
               'story_description',
               'project',
               'collaborate',
               'collaborate_with',
               'embargo',
               'embargo_datetime',
               'sensitive',
               'share',
               'ready_to_share',
               'share_with',
               'share_with_date',
               'archived',
               ]
     widgets = {
         'name': TextInput(attrs={'class': 'form-control', 'placeholder': 'Story Name'}),
         'story_description': Textarea(
             attrs={'class': 'form-control', 'placeholder': 'Description'}),
         'collaborate_with': ArrayFieldSelectMultiple(
             attrs={'class': 'chosen-select', 'id': 'collaborate-with',
                    'data-placeholder': 'Select Partners'}),
         'share_with': ArrayFieldSelectMultiple(
             attrs={'class': 'chosen-select', 'id': 'share-with',
                    'data-placeholder': 'Select Networks'}),
         'project': Select(attrs={'class': 'c-select', 'id': 'story-project'}),
     }
Ejemplo n.º 2
0
 class Meta:
     model = Series
     fields = [
         'name',
         'description',
         'collaborate',
         'collaborate_with',
     ]
     widgets = {
         'name':
         TextInput(attrs={
             'class': 'form-control',
             'placeholder': 'Series Name'
         }),
         'description':
         Textarea(attrs={
             'class': 'form-control',
             'placeholder': 'Description'
         }),
         'collaborate_with':
         ArrayFieldSelectMultiple(
             attrs={
                 'class': 'chosen-select form-control facet-select',
                 'id': 'collaborate-with',
                 'data-placeholder': 'Select Collaborators'
             }),
     }
Ejemplo n.º 3
0
 class Meta:
     model = Task
     fields = [
         'name',
         'text',
         'assigned_to',
         'status',
         'important',
         'due_date',
         'project',
         'story',
         'event',
     ]
     widgets = {
         'name': Textarea(
             attrs={'class': 'form-control', 'rows': 2, 'placeholder': 'Name'}),
         'text': Textarea(attrs={'class': 'form-control', 'id': 'task-text', 'rows': 17,
                                 'placeholder': 'Details'}),
         'assigned_to': ArrayFieldSelectMultiple(
             attrs={'class': 'chosen-select form-control task-assign-select',
                    'id': 'task-team', 'data-placeholder': 'Assign to'}),
         'status': Select(attrs={'class': 'custom-select', 'id': 'task-status'}),
         'important': CheckboxInput(attrs={'class': ''}),
         'project': Select(attrs={'class': 'custom-select', 'id': 'task-projects'}),
         'story': Select(attrs={'class': 'custom-select', 'id': 'task-stories'}),
         'event': Select(attrs={'class': 'custom-select', 'id': 'task-events'}),
     }
Ejemplo n.º 4
0
 class Meta:
     model = Story
     fields = ['team']
     widgets = {
         'team': ArrayFieldSelectMultiple(
             attrs={'class': 'chosen-select', 'id': 'story-team',
                    'data-placeholder': 'Select Team'}),
     }
Ejemplo n.º 5
0
    class Meta:
        model = PlatformAccount

        fields = [
            'id',
            'user',
            'name',
            'platform',
            'url',
            'description',
            'team',
            'organization',
            'project',
        ]

        widgets = {
            'id':
            HiddenInput(),
            'name':
            TextInput(attrs={
                'class': 'form-control',
                'placeholder': 'Name'
            }),
            'platform':
            Select(attrs={
                'class': 'c-select',
                'id': 'account-platform'
            }),
            'url':
            TextInput(attrs={
                'class': 'form-control',
                'placeholder': 'URL'
            }),
            'description':
            TextInput(attrs={
                'class': 'form-control',
                'placeholder': 'Description'
            }),
            'team':
            ArrayFieldSelectMultiple(
                attrs={
                    'class': 'chosen-select',
                    'id': 'share-with',
                    'data-placeholder': 'Select Team'
                }),
            'user':
            HiddenInput(),
            'organization':
            HiddenInput(),
            'project':
            Select(attrs={
                'class': 'c-select',
                'id': 'account-project'
            }),
        }
Ejemplo n.º 6
0
 class Meta:
     model = Series
     fields = ['team']
     widgets = {
         'team':
         ArrayFieldSelectMultiple(
             attrs={
                 'class': 'chosen-select form-control facet-select',
                 'id': 'series-team',
                 'data-placeholder': 'Select Series Team'
             }),
     }
Ejemplo n.º 7
0
    class Meta:
        model = Event

        fields = [
            'name',
            'text',
            'team',
            'event_type',
            'event_date',
            'venue',
            # 'evt_organization',
            'project',
            'story',
        ]

        widgets = {
            'name':
            Textarea(attrs={
                'class': 'form-control',
                'rows': 1,
                'placeholder': 'Name'
            }),
            'text':
            Textarea(
                attrs={
                    'class': 'form-control',
                    'id': 'task-text',
                    'rows': 15,
                    'placeholder': 'Details'
                }),
            'venue':
            Textarea(attrs={
                'class': 'form-control',
                'rows': 1,
                'placeholder': 'Venue'
            }),
            'team':
            ArrayFieldSelectMultiple(
                attrs={
                    'class': 'chosen-select form-control facet-select',
                    'id': 'event-team',
                    'data-placeholder': 'Team'
                }),
            'event_type':
            Select(attrs={
                'class': 'custom-select',
                'id': 'task-status'
            }),
            # 'evt_organization': Select(
            #     attrs={'class': 'custom-select', 'id': 'event-organization'}),
            'project':
            Select(attrs={
                'class': 'custom-select',
                'id': 'event-project'
            }),
            'story':
            Select(attrs={
                'class': 'custom-select',
                'id': 'event-story'
            }),
        }
Ejemplo n.º 8
0
        class Meta:
            model = Facet

            fields = list(COMMON_FIELDS) + ['template'] + extra_fields

            widgets = {
                'name':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Label'
                }),
                'headline':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Headline'
                }),
                'description':
                Textarea(
                    attrs={
                        'class': 'form-control',
                        'rows': 3,
                        'placeholder': 'Description'
                    }),
                'editor':
                ArrayFieldSelectMultiple(
                    attrs={
                        'class': 'chosen-select form-control facet-select',
                        'id': 'facet-editor',
                        'data-placeholder': 'Select Editing Team'
                    }),
                'credit':
                ArrayFieldSelectMultiple(
                    attrs={
                        'class': 'chosen-select form-control facet-select',
                        'id': 'facet-credit',
                        'data-placeholder': 'Select Credited Team'
                    }),
                'status':
                Select(attrs={'class': 'form-control'}),
                'keywords':
                TextInput(attrs={
                    'class': 'form-control',
                    'placeholder': 'Keywords'
                }),
                # template field
                'template':
                Select(attrs={'class': 'form-control'}),
                # Optional Fields
                'excerpt':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Excerpt'
                }),
                'update_note':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Updates to this facet.'
                    }),
                'share_note':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Notes for sharing this facet.'
                    }),
                'edit_note':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Notes on editing this facet'
                    }),
                'dateline':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Dateline'
                }),
                'topic_code':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Topic'
                }),
                'internal_code':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Internal code'
                    }),
                'length':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Length (time)'
                    }),
                'wordcount':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Wordcount'
                }),
                'content_license':
                Select(attrs={'class': 'form-control'}),
                'related_links':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Related links (urls)'
                    }),
                'github_link':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Github Link'
                    }),
                'sources':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Sources in this story'
                    }),
                'pronounciations':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Pronounciations'
                    }),
                'sponsors':
                TextInput(attrs={
                    'class': 'form-control',
                    'rows': 2,
                    'placeholder': 'Sponsors'
                }),
                'pull_quotes':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Pull quotes'
                    }),
                'embeds':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Embeds (html)'
                    }),
                'sidebar_content':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Sidebar content'
                    }),
                'producer':
                Select(attrs={'class': 'form-control'}),
                'series_title':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Series Title'
                    }),
                'episode_number':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Episode Number'
                    }),
                'usage_rights':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Usage Rights'
                    }),
                'locations':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Filming Locations'
                    }),
                'custom_one':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Custom Info One'
                    }),
                'custom_two':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Custom Info Two'
                    }),
                'custom_three':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Custom Info Three'
                    }),
                'custom_four':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Custom Info Four'
                    }),
                'custom_five':
                TextInput(
                    attrs={
                        'class': 'form-control',
                        'rows': 2,
                        'placeholder': 'Custom Info Five'
                    }),
            }