Sha256: ca60604ead9ca73b1525422061e414cca4803f6bfac190eacfc1d7376ff65aa4

Contents?: true

Size: 535 Bytes

Versions: 55

Compression:

Stored size: 535 Bytes

Contents

module Comee
  module Core
    class AdditionalServicesController < ApplicationController
      include Common

      def index
        super do
          AdditionalService.where(sales_order_id: params[:id])
        end
      end

      def filter
        services = AdditionalService.includes(:sales_order).ransack(params[:q]).result
        render_content(services)
      end

      private

      def model_params
        params.require(:payload).permit(:sales_order_id, :name, :unit, :quantity, :price)
      end
    end
  end
end

Version data entries

55 entries across 55 versions & 1 rubygems

Version Path
comee_core-0.3.62 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.61 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.60 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.59 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.58 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.57 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.56 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.55 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.54 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.53 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.51 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.50 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.49 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.48 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.47 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.46 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.45 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.44 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.43 app/controllers/comee/core/additional_services_controller.rb
comee_core-0.3.42 app/controllers/comee/core/additional_services_controller.rb