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

席予約機能の追加 #1230

Merged
merged 38 commits into from May 14, 2020
Merged

席予約機能の追加 #1230

merged 38 commits into from May 14, 2020

Conversation

s4na
Copy link
Member

@s4na s4na commented Nov 11, 2019

Ref: #1148

変更内容

席予約機能の追加

  • 席予約一覧での予約一覧表示・追加・削除
  • 席予約一覧でのカレンダーメモ表示
  • (管理者のみ)席予約一覧での、カレンダーメモ追加・更新・削除
  • 管理画面での、席追加・更新・削除

画面

席予約一覧画面(管理者)

スクリーンショット 2019-11-19 15 27 11

席予約一覧画面(非管理者)

スクリーンショット 2019-11-11 17 51 34

席一覧画面

スクリーンショット 2019-11-11 17 51 48

komagataさんレビュー後の作業予定

machidaさんにデザインを依頼

内容

  • 席予約一覧デザイン
  • 席予約一覧に、座席画像の追加(リンク?)

イメージ

スクリーンショット 2019-11-11 17 59 23

@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 11, 2019 08:47 Inactive
@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 11, 2019 09:09 Inactive
@s4na s4na requested a review from komagata November 11, 2019 09:19
@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 12, 2019 03:00 Inactive
@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 12, 2019 04:02 Inactive
@@ -0,0 +1,48 @@
# frozen_string_literal: true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

この画面だったらメモも遷移せずにかけるといいかもですね。

Copy link
Member Author

@s4na s4na Nov 13, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@komagata

確認させてください🙇‍♂️

「管理ページ」じゃなくて、「席予約一覧」に管理者だけ「メモ追加欄」が表示するような実装でしょうか?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@s4na はい。

@machida 僕はそのような認識だったのですが町田さんはどうですか?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@s4na メモ追加は日にちにメモするためのもので、座席にメモをするものではないので、

「席予約一覧」に管理者だけ「メモ追加欄」が表示するような実装

の認識でした。

ユースケースは、今日は工事があるのでオフィスが使えません、午後はXXXがあってオフィスが使えません、のようなことを書き込むのに使う予定でした。

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@komagata @machida

かしこまりました!
実装してみます!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@machida 日にちにメモするというのは僕も同じ認識です。

UI的に下記のどちらなのかというのが気になっているところです。

  • メモ一覧ページで入力する。
  • カレンダーが表示されてるページでメモが入力できる。

僕は後者の認識でした〜

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@komagata

machidaさんに確認したところ、「後者」の認識でしたので、「カレンダーが表示されてるページでメモが入力できる。」で実装します!

render :create, status: :created
else
if @reservation.errors.nil?
head :bad_request
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

これってどういう場合でしょう?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@komagata

すいません勘違いしてました
なさそうなので、分岐削除しました。
ご確認お願いいたします。

@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 13, 2019 06:37 Inactive
@s4na
Copy link
Member Author

s4na commented Nov 18, 2019

要件

machidaさん

  • メモ欄のデザインはモータルで実装するので、それを前提に「入力するテキストボックスとボタンの下に、登録したテキストが表示されるようにしてほしい」
  • 「カレンダーメモの作成・編集・削除ボタンの表示・非表示は私(machidaさん)の方で対応します」

@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 19, 2019 06:31 Inactive
@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 19, 2019 06:41 Inactive
@s4na s4na requested a review from komagata November 19, 2019 06:53
@komagata
Copy link
Member

@s4na mergeコミットができちゃってるのでrebaseでお願いします。

conflictの解消お願いします。

@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 26, 2019 06:02 Inactive
@s4na
Copy link
Member Author

s4na commented Nov 26, 2019

@s4na mergeコミットができちゃってるのでrebaseでお願いします。

conflictの解消お願いします。

解消しました!

# frozen_string_literal: true

class API::ReservationsController < API::BaseController
before_action :require_login
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API::BaseControllerの方にあれば必要ないかも。(もしなければそちらに移していいかもです。)

Copy link
Member Author

@s4na s4na Nov 28, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@komagata ありがとうございます!修正しました!

@komagata
Copy link
Member

@s4na こちら古い状態でrebaseされているようなので現在のmasterでのrebaseお願いします〜

if memo.save
render json: { status: 201, id: memo.id, body: memo.body }, status: :created
else
head :bad_request
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

一律:bad_requestではなく、

render json: memo.errors, status: :unprocessable_entity

のようにエラーの内容も返せるようなものがいいです〜

Copy link
Member Author

@s4na s4na Nov 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@komagata

ありがとうございます!

reservations_controllerに合わせて、下記のように修正してみました。

render status: :unprocessable_entity, json: { status: 422, message: memo.errors.full_messages }

@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 27, 2019 04:03 Inactive
@s4na
Copy link
Member Author

s4na commented Nov 27, 2019

@s4na こちら古い状態でrebaseされているようなので現在のmasterでのrebaseお願いします〜

すいません!

新しい状態でのrebaseやってみました!

@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 27, 2019 07:58 Inactive
@komagata komagata temporarily deployed to bootcamp-fjord-jp-pr-1230 November 28, 2019 05:26 Inactive
@komagata komagata had a problem deploying to bootcamp-fjord-jp-pr-1230 November 28, 2019 05:29 Failure
@komagata komagata had a problem deploying to bootcamp-fjord-jp-pr-1230 November 28, 2019 05:35 Failure
@s4na s4na self-assigned this Nov 28, 2019
@komagata komagata force-pushed the add_seat_reservation branch 2 times, most recently from 43d97b1 to ef293e7 Compare May 13, 2020 21:14
@komagata komagata changed the title [Feature Branch][WIP]席予約機能の追加 [Feature Branch]席予約機能の追加 May 14, 2020
@komagata komagata changed the title [Feature Branch]席予約機能の追加 席予約機能の追加 May 14, 2020
@komagata komagata merged commit 000ff6e into master May 14, 2020
@komagata komagata deleted the add_seat_reservation branch May 14, 2020 03:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants