Help Hiển thị màu group user trong disccusion_list

thuandtp

Gefreiter
Tham gia
08/03/2016
Bài viết
50
Được Like
48
Chào các pro,
- Up cái hình minh họa rồi hỏi cho dễ hiểu

Capture.PNG

- Trong hình là mình đang xem ở phần Disccusion list
- Giả sử mình chọn màu của nick cho Group trong List User Group của thành viên @@phongnam là đỏ và @@sonvfx là xanh
- Tuy nhiên khi xem ở chế độ như hình thì màu của nick không hiển thị tự động theo màu mình đã chọn cho Group
- Mình có tìm hiểu thì thấy phần user này nằm trong template thread_list_item và ở đoạn

Mã:
<dl class="lastPostInfo">
                <dt><xen:if is="{xen:helper isIgnored, $thread.last_post_user_id}">{xen:phrase ignored_member}<xen:else /><xen:username user="$thread.lastPostInfo" /></xen:if></dt>
                <dd class="muted"><a{xen:if '{$visitor.user_id}', ' href="{xen:link posts, $thread.lastPostInfo}" title="{xen:phrase go_to_last_message}"'} class="dateTime"><xen:datetime time="$thread.lastPostInfo.post_date" /></a></dd>
            </dl>

- Mình thấy cái Thống kê của TopX của VT.Lai nó tự nhận được màu của nick và nó trong file modal.php ở đoạn

Mã:
            $thread['user']=array('user_id'=>$thread['last_post_user_id'],'username'=>$thread['last_post_username']);
            if(isset($thread['user_group_id']))
                $thread['user']['user_group_id']=$thread['user_group_id'];
            if(isset($thread['display_style_group_id']))
                $thread['user']['display_style_group_id']=$thread['display_style_group_id'];
            $thread['forum']=array('node_id'=>$thread['node_id'],'title'=>$thread['forum_title']);

- Mình không biết cần thêm code gì vào phần template thread_list_item (hoặc thêm vào đâu khác) để nó tự nhận biết màu của nick trong Group mình đã chọn nhỉ?
PRO NÀO BIẾT XIN CHỈ GIÚP. CẢM ƠN NHIỀU NHÉ!
 
Sửa lần cuối:

namhbnam

MasterCorporal
Tham gia
23/03/2016
Bài viết
322
Được Like
162
thêm màu nick từng thành viên kiểu gì vậy bạn
 

PVS

Super Moderator
Thành viên BQT
Tham gia
28/02/2015
Bài viết
16,735
Được Like
12,681
ok :)
 
  • Like
Reactions: THB

Hướng dẫn sử dụng

XenForo 1 XenForo 2
Translate by PVS

Dịch vụ XenForo của VNXF

Mr. Tuấn

Mobile/Zalo: 0988 488 096

Telegram: bluekpro

Email: [email protected]

Nhà Tài Trợ

Mút Xốp Không Gian
pallet Thịnh Phát
Top Bottom