Merge branch 'dev_auth' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_auth

dev_auth
杨树林 5 years ago
commit ce8f8eb217

@ -4,7 +4,7 @@ class Competitions::PrizesController < Competitions::BaseController
def show
self_prizes = current_competition.competition_prize_users.where(user_id: current_user.id).includes(:competition_team)
@leader = self_prizes.any?(&:leader?) # 是否为队长
@leader = self_prizes.any?{ |prize_user| prize_user.leader? && prize_user.competition_prize.category == 'bonus' } # 是否为队长并且有奖金奖励
if @leader
@bank_account = self_prizes.find(&:leader?).extra
@bank_account_editable = self_prizes.select(&:leader?).all?(&:pending?)

@ -14,6 +14,11 @@
<td><%= display_text prize_user.approver&.real_name %></td>
<td class="action-container">
<% if prize_user.leader? && prize_user.competition_prize.category == 'bonus' %>
<% bank_content = [prize_user.extra&.[]('bank'), prize_user.extra&.[]('second_bank'), prize_user.extra&.[]('card_no')].compact.join('<br>').presence || '无' %>
<%= javascript_void_link('查看银行账户', data: { toggle: 'popover', title: '银行账号', content: bank_content.html_safe }) %>
<% end %>
<% if prize_user.pending? %>
<%= link_to('审批通过', approve_admins_competition_competition_prize_user_path(prize_user.competition, prize_user),
data: { confirm: '确认审批通过吗?' },

@ -87,7 +87,7 @@ class CompetitionContentspdfdownload extends Component{
dataIndex: 'certify',
render: (text, record) => (
<span>
{record.professional_auth==="authed"?<span className={"pdfdownloadfont00CC5F"}>已认证</span>:record.real_name_auth==="authing"?<span className={"pdfdownloadfontFF6602"}></span>:record.real_name_auth==="not_authed"?<span className={"color-red"}></span>:""}
{record.professional_auth==="authed"?<span className={"pdfdownloadfont00CC5F"}>已认证</span>:record.professional_auth==="authing"?<span className={"pdfdownloadfontFF6602"}></span>:record.professional_auth==="not_authed"?<span className={"color-red"}></span>:""}
</span>
),
},

Loading…
Cancel
Save