show.html.haml
1.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/Author Igor Portela - www.igorportela.com
.span9
%p#notice= notice
%p
%b
= t('users.name')
\:
= @user.name
%p
%b
= t('users.email')
\:
= @user.email
%p
%b
= t('users.address') if @user.address.present?
= @user.address
%p
%b
= t('users.zipcode') if @user.zipcode.present?
= @user.zipcode
%p
%b
= t('users.phone') if @user.phone.present?
= @user.phone
- if @user.videos.present?
%p
= @user.videos.size
%b
= t('shared.videos')
\:
%table.table.table-hover
%thead
%tr
%th= t('shared.user')
%th= t('videos.url')
%th= t('videos.subtitle')
%th= t('shared.created_at')
%th= t('shared.updated_at')
%th
%th
%th
- @user.videos.each do |video|
%tbody
%tr
%td= video.user.name if video.user.present?
%td= format_video(video.url, "url")
%td= video.legend
%td= video.created_at
%td= video.updated_at
%td= link_to '', admin_video_path(video), class: "icon-search"
%td= link_to '', video, confirm: 'Tem certeza?', method: :delete, class: 'icon-remove'
- else
.alert
%strong Não existe vídeos para este usuário
%p
= link_to t('shared.back'), admin_users_path, :class => 'btn btn-primary'
- content_for :sidebar, render(:partial => 'admin/sidebar')