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

Ref Task #7144: Submit question #11

Merged
merged 1 commit into from
Mar 1, 2019

Conversation

DUCXDO
Copy link
Contributor

@DUCXDO DUCXDO commented Mar 1, 2019

  • Tạo chức năng đăng câu hỏi:
  • Chuyển sang trang riêng với các trường để nhập:
    1. Tiêu đề câu hỏi
    2. Ô chọn tag
    3. Editor để người dùng nhập nội dung câu hỏi

@DUCXDO
Copy link
Contributor Author

DUCXDO commented Mar 1, 2019

ready

@@ -8,6 +8,7 @@ def new

def create
@post = current_user.posts.build post_params
@post.post_type = 1
Copy link
Contributor

Choose a reason for hiding this comment

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

dùng enum text để chỉ định đi, ko dùng số thế này, khó hiểu lắm


def create
@question = current_user.posts.build question_params
@question.post_type = 2
Copy link
Contributor

Choose a reason for hiding this comment

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

đây nữa, dùng enum text

@@ -1,5 +1,6 @@
class Ckeditor::Picture < Ckeditor::Asset
mount_uploader :data, CkeditorPictureUploader, mount_on: :data_file_name
self.inheritance_column = nil
Copy link
Contributor

Choose a reason for hiding this comment

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

cần type cho cái gì vậy?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cái upload ảnh của em nó bị lỗi nên em thêm để sửa đấy mà :3
galetahub/ckeditor#739
which tells Rails to ignore the type column with respect to STI.
Để thằng rails nó bỏ qua cái cột type ạ :3

@DUCXDO DUCXDO force-pushed the submit_questions branch from 0586fb6 to 413a372 Compare March 1, 2019 09:42
@DUCXDO
Copy link
Contributor Author

DUCXDO commented Mar 1, 2019

ready

@thanhhungchu95 thanhhungchu95 merged commit 6cebb8f into awesome-academy:master Mar 1, 2019
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.

2 participants