Skip to content

Instantly share code, notes, and snippets.

@boratanrikulu
Created July 30, 2019 12:24
Show Gist options
  • Save boratanrikulu/b42a9ea813f9c76ec6b833f215c8b91c to your computer and use it in GitHub Desktop.
Save boratanrikulu/b42a9ea813f9c76ec6b833f215c8b91c to your computer and use it in GitHub Desktop.
Blog Ödevi Devamı

Blog Ödevi Devamı

  • Bir Article silindiğinde Comment'lerinde silinmesi sağlanmalı.
  • Article#Show'da Comment'lerin listelendiği bir kısım (direkt düz yazı olarak)
  • Comment ekle tuşu olcak. Comment tuşuna tıklandığında Comment yazma sayfasına gidilecek.
  • Comment oluşturulduğunda Article#Show'a geri gidilecek. JS kullanılmayacak.
 ------------------
|   Article#Show   |
| .................|                         Article Sayfasına Geri Gider
| ..............   |      <---------------------------------------------------------------|
| ................ |                                                                      |
| ...............  |                                                                      |
|                  |                     -->  ---------------------------------           |
| Comments         |                    |    |  Article ..... İçin Comment At  |          |
| ............     |                    |    |                                 |          |
| .........        |                    |    |  ....................           |          |
| ...........      |                    |    |  ..................             |          |
|                  |  Commment Ekleme   |    |  ...................            |          |
| Comment ekle     |--------------------     |                                 |          |
|                  |  Sayfasına Gider        |                  Comment Ekle   | ---------
 ------------------                           ---------------------------------
  • Article'e published diye bir alan eklenecek. Tipi boolean olacak.
  • Welcome sayfasında published'i true olanlar listelenecek. (bunu scope ile yapıcaz.)
  • Articles'in index sayfasında ise hepsi görünecek.
  • Articles'in index sayfasında yeni bir kolon oluşturularak published ifadesi hakkında bilgi verilecek.
  • Article oluşturma ekranında(formuna) published ifadesi için bir checkbox konulacak.
  • Comments controller'ı oluşturulacak. Scaffold kullanılmadan yapılacak. Comments Controller'ın tek işlevi form göstermek ve kaydetmek.
 ---------------------------------------------------
|   Articles                                        |
|   Title       Published     Actions               |
|                                                   |
|   .....        True         Show - Edit - Delete  |
|   .........    False        Show - Edit - Delete  | 
|   .......      False        Show - Edit - Delete  |
|   ........     True         Show - Edit - Delete  |
|   ....         False        Show - Edit - Delete  |
|                                                   |
 ---------------------------------------------------
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment