Conversation
これから、user-showの画面実装を行います。 作業量重めのため、3日間工程で良いでしょうか?(月曜日夜完成予定)
# Conflicts: # Gemfile # app/assets/stylesheets/application.scss # app/assets/stylesheets/homes.scss
|
#WHAT |
|
レビューに出す時は[WIP]外しましょう〜! |
|
userのサムネイルって今の状態でuserに合わせて変わる状態ですか? |
ryosuke071111
left a comment
There was a problem hiding this comment.
html/cssは完璧だと思うのですが、rails関連の記述は直した方が良いと思う箇所がいくつかありました!
| .user-show-left-contents-1 | ||
| #user-show-left-contents-2 | ||
| #user-media-container | ||
| %img#user-show-img{alt: "", src: "https://s3-ap-northeast-1.amazonaws.com/airbnb-images-to-s3/sample_user_image3.png"}/ |
There was a problem hiding this comment.
%img#user-show-img{alt: "", src: "https://s3-ap-northeast-1.amazonaws.com/airbnb-images-to-s3/sample_user_image3.png"}/
ここって@userの変数展開は要らないんでしたっけ。。?
|
|
||
| .listing-detail | ||
| リスティング | ||
| %small.small-number (6) |
There was a problem hiding this comment.
@user.homesみたいなやつ。。?
| .panel-body | ||
| %dl.space-2.language-box | ||
| %dt.col-middle.dtbold 言語 | ||
| %dd.col-middle.dtpadding English, Français |
There was a problem hiding this comment.
@user.languageみたいなやつ。。?
| %li.listings-item | ||
| %a.listings-item-image{href: "/users"} | ||
| .text-relative | ||
| %img.img-responsive-height{alt: "appartamento con giardino e piscina", height: "144", src: "https://a0.muscache.com/im/pictures/17758895/9908f050_original.jpg?aki_policy=small", title: "appartamento con giardino e piscina", width: "225"} |
There was a problem hiding this comment.
@user.home.listing_photoみたいな。。?
|
|
||
| .user-show-right-contents-1 | ||
| .user-info-box | ||
| %h1.greeting-1 こんにちは、Mauroです! |
There was a problem hiding this comment.
@user.nameを入れられると思います。
| .user-show-right-contents-1 | ||
| .user-info-box | ||
| %h1.greeting-1 こんにちは、Mauroです! | ||
| .address-startday San Salvatore Monferrato, イタリア · 2013年1月からメンバー |
There was a problem hiding this comment.
@user.prefecture
@user.country_id.name
| .self-information-2 | ||
| .self-information-3{style: "margin-top:0;margin-bottom:24px;margin-right:25px"} | ||
| %img.image-attribute{alt: "", height: "50", src: "https://a0.muscache.com/airbnb/static/badges/super_host_50_new-e5e09829e1fc5ffefdb2d7387590c462.png", width: "28"} | ||
| %span._mstzcu.host-box-1 スーパーホスト |
There was a problem hiding this comment.
@user.superhostの有無で条件分岐できるかと!
| = "(#{@users.count})" | ||
| .reviews_section.as_host ゲストからのレビュー | ||
|
|
||
| - @users.each do |user| |
| get 'search', to: 'homes#search' | ||
| resources :home_reservations, only: [:new, :create, :edit, :update] | ||
| # For details on the DSL available within this file, see http://guides.rubyonrails.org/routing.html | ||
| get 'users' => 'users#show' |
There was a problem hiding this comment.
これだとユーザーのID別でuser#showの出し分けができないと思います。。!
| class UsersController < ApplicationController | ||
|
|
||
| def show | ||
| @users = User.all |
There was a problem hiding this comment.
userのidを取得できる記述を書いた方が良いかと思います。。!
| class UsersController < ApplicationController | ||
|
|
||
| def show | ||
| @users = User.all |
There was a problem hiding this comment.
ここはできればそのリスティングのuser_idを取得してその人のshowだけ表示するにしたいところ...!
| %i.fa.fa-flag-o このユーザーを報告 | ||
| %p.self-imformation-1 Here we are, Pina and Mauro. Our adventure began thirty years ago with the house on the hill, the refuge of the family: two daughters, a grandmother with a passion for the vegetable garden and lots of animals! We offer a discreet hospitality, genuine lifestyle and enjoyment of uncontaminated nature. There you will meet us collecting fruits or eggs from our hens, while we dry herbs for infusions, or in the cellar to bottle the wine. | ||
| .self-information-2 | ||
| .self-information-3{style: "margin-top:0;margin-bottom:24px;margin-right:25px"} |
| .self-information-3{style: "margin-top:0;margin-bottom:24px;margin-right:25px"} | ||
| %a._t8unl0{href: "/users/show/4655535#reviews", rel: "noopener noreferrer nofollow"} | ||
| ._1lhqvjz | ||
| #undefined_count._186vx4j |
| @@ -0,0 +1,5 @@ | |||
| class AddAvatarToUsers < ActiveRecord::Migration[5.1] | |||
| def change | |||
| add_column :users, :avatar, :string | |||
There was a problem hiding this comment.
stringで問題なさそうです。
(AWSのS3から画像引っ張ってくるなら、255ビット超えないだろうと、、、)
| get 'search', to: 'homes#search' | ||
| resources :home_reservations, only: [:new, :create, :edit, :update] | ||
| # For details on the DSL available within this file, see http://guides.rubyonrails.org/routing.html | ||
| get 'users' => 'users#show' |




WHAT
user/show画面の実装
WHY
必須画面の為