def edit
      @edit = true
      @record = Post.find(params[:id])

      # add breadcrumb and set title
      add_breadcrumb I18n.t("controllers.admin.pages.edit.breadcrumb")
      set_title(I18n.t("controllers.admin.pages.edit.title", post_title: @record.post_title))
      @action = 'update'
    end
def edit
      @edit = true
      @record = Post.find(params[:id])

      # add breadcrumb and set title
      add_breadcrumb I18n.t("controllers.admin.pages.edit.breadcrumb")
      set_title(I18n.t("controllers.admin.pages.edit.title", post_title: @record.post_title))
      @action = 'update'
    end
gets and displays the post object with the necessary dependencies