fixed tzb2025报名数调整,短信模板

This commit is contained in:
xxq250 2025-06-24 13:59:40 +08:00
parent 5df886525e
commit 815027fae2
2 changed files with 6 additions and 1 deletions

View File

@ -48,6 +48,10 @@ class CompetitionInfo < ApplicationRecord
self.is_local? ? self.zones_local.to_s.split(",") : self.zones.to_s.split(",")
end
def competition_users_count
self.identifier == "tzb2025" ? self.competition_users.where("competition_users.enroll_template_id is not null").count : self['competition_users_count']
end
def competition_subs
self.sub_competitions.to_s.split(",")
end

View File

@ -36,7 +36,8 @@ module Gitlink
params['mobile'] = mobile
params['text'] = ""
if send_type.nil?
params['text'] = "【红山开源平台】您的验证码是#{code}。如非本人操作,请忽略本短信。"
# params['text'] = "【红山开源平台】您的验证码是#{code}。如非本人操作,请忽略本短信。"
params['text'] = "【大数据先进技术研究院】尊敬的红山开源平台用户您好,您的验证码是#{code}。如非本人操作,请忽略本短信。"
elsif send_type == 'init_password'
# params['text'] = "【红山开源平台】您的初始密码是#{code}。登录后请及时修改密码。"
params['text'] = "【红山开源平台】尊敬的用户您好非常感谢您注册红山开源平台www.osredm.com ,以下是您的账户信息,请妥善保管。账号:#{user_name}(用户账户名)密码:#{code}(随机生成密码)"