Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 2024-08-21 02:39:36 +0000 #8001

Merged
merged 79 commits into from
Aug 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
79 commits
Select commit Hold shift + click to select a range
cb26a0b
ローカル環境で実施よう
goruchanchan Apr 24, 2024
50245a0
ブログをpublised_atの降順に並べる
Judeeeee Jul 11, 2024
b261f25
コンフリクトを解消し、WIP記事が降順記事の先頭にあることを確認するテストを追加
Judeeeee Jul 11, 2024
004670c
不必要なwithinを使用していたため削除
Judeeeee Jul 11, 2024
f08d0c8
published_atが同じ場合を考慮し、created_atもorderに含めた
Judeeeee Jul 25, 2024
62596b5
「イベントのお知らせ」に記載されるイベントの並び順を開始時間順に変更した
ham-cap Jul 3, 2024
5019368
イベントの並び順をソートするタイミングを変更
ham-cap Jul 17, 2024
603f21b
テストを修正
ham-cap Jul 26, 2024
f4381c5
該当するapiのコントローラを削除しworried_usersをhome_controllerへ移動
motohiro-mm Jul 26, 2024
c8fe376
worried_users一覧ページを実装
motohiro-mm Jul 26, 2024
1cdc1ce
不要なファイル・行を削除
motohiro-mm Jul 26, 2024
628676a
条件分岐を追加
motohiro-mm Jul 26, 2024
dea87ce
パーシャルを追加済み。Vue・React部分の削除はまだ。(メモあり)
nishitatsu-dev Jul 17, 2024
8a1c410
「直近の日報」を非Vue/React化(初版)
nishitatsu-dev Jul 26, 2024
fb50956
直近の日報の不要なdivを削除。見出しの有り無しのルールを修正。日報個別ページのレイアウトの微調整。
machida Jul 31, 2024
44971b6
直近の日報の表示数を10件に統一した。renderの書き方を周囲と統一
nishitatsu-dev Aug 1, 2024
652da2b
Merge pull request #7975 from fjordllc/chore/convert-worried-users-to…
komagata Aug 8, 2024
668d863
Merge pull request #7923 from fjordllc/feature/change-events-order-in…
komagata Aug 8, 2024
495accf
一行が横に長いので改行
Judeeeee Aug 8, 2024
4a3d5fa
インデントのずれを修正
thmz337 Aug 8, 2024
e59f94d
比較が1回で済むように配列同士を比較する
Judeeeee Aug 8, 2024
1189300
検索ワード入力後returnを押すように追加
motohiro-mm Jul 31, 2024
ed5a326
テスト用fixturesの添付ファイルの保存先を設定
motohiro-mm Aug 7, 2024
70f5749
fixtureそれぞれに保存先を指定
motohiro-mm Aug 7, 2024
c9e8359
並列してるプロセスそれぞれに保存先を作成し設定
motohiro-mm Aug 7, 2024
19f294e
テスト終了時に/tmp/storageフォルダと/tmp/storage_fixturesフォルダを削除するよう設定
motohiro-mm Aug 7, 2024
1342612
Rails7で必要な修正をコメントとして追加
motohiro-mm Aug 7, 2024
bd207d2
Discord通知においてイベントが開始時間の早い順に並んでいるか確認するためにdb/fixturesの該当データの開始・終了時間を変更した
ham-cap Aug 10, 2024
85e583f
test/helpers配下のファイル群について、テストファイルとして認識されるようにする
thmz337 Aug 10, 2024
3e082c6
テストとして認識されたファイルの、テストが通過するように変更
thmz337 Aug 10, 2024
a196223
Merge pull request #8004 from fjordllc/feature/change-some-fixtures-d…
komagata Aug 11, 2024
e1d23f3
textarea-markdown npm のバージョン更新
goruchanchan Aug 13, 2024
144f8a4
prettier 警告修正
goruchanchan Aug 13, 2024
a18ade9
Userモデルにexperiencesカラムを追加するマイグレーションファイルを作成
motohiro-mm Jul 12, 2024
9253a27
チェックボックスで複数選択し保存できるよう修正
motohiro-mm Jul 12, 2024
1a52d58
ユーザー非公開情報の「経験」部分をexperiencesに対応するよう修正
motohiro-mm Jul 18, 2024
0409367
データマイグレーションファイルを作成
motohiro-mm Jul 18, 2024
6b9c4c4
未経験用のコメントを追加、クラス名の修正
motohiro-mm Jul 19, 2024
cfd3a3e
ファイル名を_experiences.html.slimに変更、formの対応部分も修正
motohiro-mm Jul 19, 2024
242f9d2
usersコントローラのparamsにexperiencesを追加、不要なexperienceを削除
motohiro-mm Jul 19, 2024
132b126
experienceのvalidateを削除
motohiro-mm Jul 19, 2024
1db2da0
fixturesのexperienceをexperiencesに修正
motohiro-mm Jul 22, 2024
1535da3
システムテスト追加、既存のテストの修正
motohiro-mm Jul 22, 2024
8881a26
プログラミング経験のデザインとフォーム内の文章のブラッシュアップ
machida Jul 31, 2024
0a17088
選択肢の枠内全部がクリックできるよう修正
motohiro-mm Aug 4, 2024
736ea2f
other_languagesに変更
motohiro-mm Aug 7, 2024
dfda897
api/users/list_userの使われていないexperienceを削除
motohiro-mm Aug 15, 2024
e6603ab
other_languagesをlanguages_other_than_ruby_and_javascriptに変更
motohiro-mm Aug 15, 2024
1aadae6
renderの書き方を周囲と統一
nishitatsu-dev Aug 16, 2024
686e4cf
Merge pull request #7997 from fjordllc/chore/fix-flaky-tests
komagata Aug 16, 2024
3fa708a
退会時にカード情報を削除するようにした
komagata Aug 18, 2024
bd49ba8
Merge pull request #8018 from fjordllc/feature/remove-card-at-resign
komagata Aug 18, 2024
60a563b
開催前の定期イベントは次回開催日が表示されないことをテストするテスト作成
MikotoMakizuru Aug 18, 2024
409326e
開催前の定期イベントは次回開催日を表示しないようにした
MikotoMakizuru Aug 18, 2024
043d229
Bump fugit from 1.9.0 to 1.11.1
dependabot[bot] Aug 19, 2024
0176f43
期生別のユーザー人数で現役生がマイナス人数になっているのを修正
komagata Aug 19, 2024
d85e3b3
タイトルが長い質問のテストデータ作成
MikotoMakizuru Aug 20, 2024
def49ca
質問のテストデータ数を増やしたので、質問数をテストする箇所のテスト数も修正
MikotoMakizuru Aug 20, 2024
6a8dbc3
質問タイトルが長い場合、titleタグ内では省略されることを確認するテストを作成
MikotoMakizuru Aug 20, 2024
ceb144e
質問タイトルが長い場合でも「og:title」「og:description」「twitter:description」のmetaタグ内は…
MikotoMakizuru Aug 20, 2024
2cc56bc
質問タイトルが長い場合、titleタグ内では省略されるようにした
MikotoMakizuru Aug 20, 2024
214b9fe
タイトルが長い質問のテストデータ作成
MikotoMakizuru Aug 20, 2024
c8ba15d
質問タイトルが長い場合、titleタグ内では省略されることを確認するテストを作成
MikotoMakizuru Aug 20, 2024
0464663
質問タイトルが長い場合でも「og:title」「og:description」「twitter:description」のmetaタグ内は…
MikotoMakizuru Aug 20, 2024
f0e993d
質問のテストデータ数を増やしたので、質問数をテストする箇所のテスト数も修正
MikotoMakizuru Aug 20, 2024
d8d8af0
未ログイン時のQ&Aページの質問タイトルが長い場合、titleタグ内では省略されるようにした
MikotoMakizuru Aug 20, 2024
213c7b5
Merge pull request #8023 from fjordllc/bug/fix-users-by-generation
komagata Aug 20, 2024
ceb3a2b
Merge pull request #7970 from fjordllc/feature/change_to_checkbox_and…
komagata Aug 21, 2024
c4519c7
Merge pull request #7990 from fjordllc/chore/truncate-qa-title-in-tit…
komagata Aug 21, 2024
02a4bd1
Merge pull request #7991 from fjordllc/chore/truncate-qa-title-in-tit…
komagata Aug 21, 2024
33d3bac
Merge pull request #7995 from fjordllc/feature/next-date-not-displaye…
komagata Aug 21, 2024
e671dc5
Merge pull request #8022 from fjordllc/dependabot/bundler/fugit-1.11.1
komagata Aug 21, 2024
10583a3
Bump elliptic from 6.5.4 to 6.5.7
dependabot[bot] Aug 21, 2024
e473f98
Merge pull request #7955 from fjordllc/feature/order-articles-by-publ…
komagata Aug 21, 2024
122bcc7
Merge pull request #8002 from fjordllc/bug/modification-of-indent
komagata Aug 21, 2024
7149ee3
Merge pull request #8007 from fjordllc/bug/recognize-as-test-file
komagata Aug 21, 2024
389c5a4
Merge pull request #8009 from fjordllc/bug/textarea_image_format_mark…
komagata Aug 21, 2024
0b91ea1
Merge pull request #8024 from fjordllc/dependabot/npm_and_yarn/ellipt…
komagata Aug 21, 2024
507edb8
Merge pull request #7976 from fjordllc/feature/rewrite-recent-reports…
komagata Aug 21, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ GEM
cocoon (1.2.15)
coderay (1.1.3)
commonmarker (0.23.10)
concurrent-ruby (1.2.2)
concurrent-ruby (1.3.4)
connection_pool (2.4.1)
countries (5.7.0)
unaccent (~> 0.3)
Expand Down Expand Up @@ -162,7 +162,7 @@ GEM
domain_name (0.5.20190701)
unf (>= 0.0.5, < 1.0.0)
erubi (1.12.0)
et-orbi (1.2.7)
et-orbi (1.2.11)
tzinfo
event_emitter (0.2.6)
event_stream_parser (0.3.0)
Expand All @@ -176,8 +176,8 @@ GEM
faraday-net_http (3.0.2)
ffi (1.16.3)
foreman (0.87.2)
fugit (1.9.0)
et-orbi (~> 1, >= 1.2.7)
fugit (1.11.1)
et-orbi (~> 1, >= 1.2.11)
raabro (~> 1.4)
globalid (1.2.1)
activesupport (>= 6.1)
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/admin/users_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def user_params
:twitter_account, :facebook_url, :blog_url,
:password, :password_confirmation, :job,
:organization, :os, :study_place,
:experience, :company_id,
{ experiences: [] }, :company_id,
:trainee, :job_seeking, :nda,
:graduated_on, :retired_on, :free,
:job_seeker, :github_collaborator,
Expand Down
9 changes: 0 additions & 9 deletions app/controllers/api/users/worried_controller.rb

This file was deleted.

3 changes: 2 additions & 1 deletion app/controllers/articles_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ def set_article
end

def list_articles
articles = Article.with_attached_thumbnail.includes(user: { avatar_attachment: :blob }).order(created_at: :desc).page(params[:page])
articles = Article.with_attached_thumbnail.includes(user: { avatar_attachment: :blob })
.order(published_at: :desc, created_at: :desc).page(params[:page])
admin_or_mentor_login? ? articles : articles.where(wip: false)
end

Expand Down
2 changes: 1 addition & 1 deletion app/controllers/current_user_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def user_params
:github_account, :twitter_account, :facebook_url,
:blog_url, :password, :password_confirmation,
:job, :organization, :os,
:experience, :editor, :other_editor, :company_id,
{ experiences: [] }, :editor, :other_editor, :company_id,
:nda, :avatar, :trainee,
:mail_notification, :job_seeker, :tag_list,
:after_graduation_hope, :training_ends_on, :profile_image,
Expand Down
4 changes: 3 additions & 1 deletion app/controllers/mentor/home_controller.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# frozen_string_literal: true

class Mentor::HomeController < MentorController
def index; end
def index
@worried_users = User.delayed.order(completed_at: :asc)
end
end
1 change: 1 addition & 0 deletions app/controllers/products_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ def show
@practice = find_practice
@learning = @product.learning # decoratorメソッド用にcontrollerでインスタンス変数化
@tweet_url = @practice.tweet_url(practice_completion_url(@practice.id))
@recent_reports = Report.list.where(user_id: @product.user.id).limit(10)
respond_to do |format|
format.html
format.md
Expand Down
1 change: 1 addition & 0 deletions app/controllers/reports_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ def index

def show
@products = @report.user.products.not_wip.order(published_at: :desc)
@recent_reports = Report.list.where(user_id: @report.user.id).limit(10)
respond_to do |format|
format.html
format.md
Expand Down
37 changes: 22 additions & 15 deletions app/controllers/retirement_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,12 @@ def create
user = current_user
current_user.delete_and_assign_new_organizer
Newspaper.publish(:retirement_create, { user: })
begin
UserMailer.retire(user).deliver_now
rescue Postmark::InactiveRecipientError => e
logger.warn "[Postmark] 受信者由来のエラーのためメールを送信できませんでした。:#{e.message}"
end

destroy_subscription
notify_to_admins
notify_to_mentors

destroy_subscription(user)
destroy_card(user)
notify_to_user(user)
notify_to_admins(user)
notify_to_mentors(user)
logout
redirect_to retirement_url
else
Expand All @@ -37,19 +34,29 @@ def retire_reason_params
params.require(:user).permit(:retire_reason, :satisfaction, :opinion, retire_reasons: [])
end

def destroy_subscription
Subscription.new.destroy(current_user.subscription_id) if current_user.subscription_id
def destroy_subscription(user)
Subscription.new.destroy(user.subscription_id) if user.subscription_id?
end

def destroy_card(user)
Card.destroy_all(user.customer_id) if user.customer_id?
end

def notify_to_user(user)
UserMailer.retire(user).deliver_now
rescue Postmark::InactiveRecipientError => e
logger.warn "[Postmark] 受信者由来のエラーのためメールを送信できませんでした。:#{e.message}"
end

def notify_to_admins
def notify_to_admins(user)
User.admins.each do |admin_user|
ActivityDelivery.with(sender: current_user, receiver: admin_user).notify(:retired)
ActivityDelivery.with(sender: user, receiver: admin_user).notify(:retired)
end
end

def notify_to_mentors
def notify_to_mentors(user)
User.mentor.each do |mentor_user|
ActivityDelivery.with(sender: current_user, receiver: mentor_user).notify(:retired)
ActivityDelivery.with(sender: user, receiver: mentor_user).notify(:retired)
end
end
end
2 changes: 1 addition & 1 deletion app/controllers/users_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ def user_params
:github_account, :twitter_account,
:facebook_url, :blog_url, :password,
:password_confirmation, :job, :organization,
:os, :experience, :editor, :other_editor,
:os, { experiences: [] }, :editor, :other_editor,
:company_id, :nda, :avatar,
:trainee, :adviser, :job_seeker,
:tag_list, :after_graduation_hope, :feed_url,
Expand Down
78 changes: 0 additions & 78 deletions app/javascript/components/user-recent-reports.vue

This file was deleted.

25 changes: 0 additions & 25 deletions app/javascript/components/worried-user.vue

This file was deleted.

64 changes: 0 additions & 64 deletions app/javascript/components/worried-users.vue

This file was deleted.

4 changes: 0 additions & 4 deletions app/javascript/packs/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,10 @@ import '../invitation-url-updater.js'
import VueMounter from '../VueMounter.js'
import Books from '../components/books.vue'
import Questions from '../components/questions.vue'
import WorriedUsers from '../components/worried-users.vue'
import UsersAnswers from '../components/users-answers.vue'
import User from '../components/user.vue'
import Watches from '../components/watches.vue'
import WatchToggle from '../components/watch-toggle.vue'
import UserRecentReports from '../components/user-recent-reports.vue'
import Footprints from '../components/footprints.vue'
import QuestionAnswers from '../components/question-answers.vue'
import SadReports from '../components/sad_reports.vue'
Expand All @@ -78,12 +76,10 @@ import '../stylesheets/application'
const mounter = new VueMounter()
mounter.addComponent(Books)
mounter.addComponent(Questions)
mounter.addComponent(WorriedUsers)
mounter.addComponent(UsersAnswers)
mounter.addComponent(User)
mounter.addComponent(Watches)
mounter.addComponent(WatchToggle)
mounter.addComponent(UserRecentReports)
mounter.addComponent(Footprints)
mounter.addComponent(QuestionAnswers)
mounter.addComponent(SadReports)
Expand Down
4 changes: 2 additions & 2 deletions app/javascript/textarea-initializer.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ export default class {
responseKey: 'url',
csrfToken: CSRF.getToken(),
placeholder: '%filenameをアップロード中...',
// uploadImageTag:
// '<img src=%url width="100" height="100" loading="lazy" decoding="async" alt="%filename">\n',
uploadImageTag:
'<img src=%url width="%width" height="%height" loading="lazy" decoding="async" alt="%filename">\n',
afterPreview: () => {
autosize.update(textarea)

Expand Down
17 changes: 17 additions & 0 deletions app/models/card.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,23 @@
# frozen_string_literal: true

class Card
def self.all(customer_id)
Stripe::Customer.list_sources(customer_id)&.data || []
end

def self.destroy_all(customer_id)
all(customer_id).each do |card|
destroy(customer_id, card['id'])
end
end

def self.destroy(customer_id, card_id)
Stripe::Customer.delete_source(
customer_id,
card_id
)
end

def create(user, card_token, idempotency_key = SecureRandom.uuid)
Stripe::Customer.create({
email: user.email,
Expand Down
2 changes: 0 additions & 2 deletions app/models/generation.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ def target_users(target)
end

def count_classmates_by_target(target)
return classmates.students.count - classmates.hibernated.count if target == :students

classmates.send(target).count
end
end
Loading
Loading