https://avo.cool logo
Join Discord
Powered by
# avo-2
  • Scopes
    c

    calm-gold-48525

    05/24/2023, 6:56 PM
    I'm attempting to add scopes like I see in the demo. But Avo::Scopes is not found. Is this not available in v2?
    l
    • 2
    • 4
  • Is there anyway to hide the Download
    b

    billowy-easter-81499

    05/24/2023, 9:38 PM
    Is there anyway to hide the Download icon/button for the Fields field, but still allow users to play a video? I recognize the file is downloaded at that point, but would prefer to not display the download button for users...
    g
    l
    • 3
    • 8
  • Disable actions
    w

    wooden-island-51391

    05/25/2023, 9:03 PM
    Is there a way to disable edit and create options across the whole app? I know you can do it for specific users with the authorization config, but we want to disable it completely on community license so that people can just view data and use specific actions we code in.
    l
    l
    • 3
    • 4
  • Build a booking app in less than an hour...
    b

    bumpy-tent-43389

    05/26/2023, 2:17 PM
    Hello, I'm running the bookr demo application (

    https://www.youtube.com/watch?v=BK47E7TMXn0โ–พ

    ) and am facing an issue: any time I use an action (i.e., in the demo, "Delay booking"), the action completes successfully but I have an ugly error message in my logs:
    Copy code
    Unpermitted parameter: :button. Context: { controller: Avo::ActionsController, action: handle, request: #<ActionDispatch::Request:0x00007fb03cbae4f8>, params: {"authenticity_token"=>"[FILTERED]", "action_id"=>"DelayBooking", "fields"=>{"avo_resource_ids"=>"1", "avo_selected_query"=>"", "number_of_hours"=>"1"}, "button"=>"", "controller"=>"avo/actions", "action"=>"handle", "resource_name"=>"bookings"} }
    Unpermitted parameter: :button. Context: { controller: Avo::ActionsController, action: handle, request: #<ActionDispatch::Request:0x00007fb03cbae4f8>, params: {"authenticity_token"=>"[FILTERED]", "action_id"=>"DelayBooking", "fields"=>{"avo_resource_ids"=>"1", "avo_selected_query"=>"", "number_of_hours"=>"1"}, "button"=>"", "controller"=>"avo/actions", "action"=>"handle", "resource_name"=>"bookings"} }
    Unpermitted parameter: :button. Context: { controller: Avo::ActionsController, action: handle, request: #<ActionDispatch::Request:0x00007fb03cbae4f8>, params: {"authenticity_token"=>"[FILTERED]", "action_id"=>"DelayBooking", "fields"=>{"avo_resource_ids"=>"1", "avo_selected_query"=>"", "number_of_hours"=>"1"}, "button"=>"", "controller"=>"avo/actions", "action"=>"handle", "resource_name"=>"bookings"} }
    Is this happening only to me (Ubuntu 22.04 with Avo 2.33.1)?
    l
    • 2
    • 5
  • Not sure if this is a bug or my doing
    c

    calm-gold-48525

    05/26/2023, 8:12 PM
    Not sure if this is a bug or my doing something wrong. 1) enable config.buttons_on_form_footers 2) wrap resource fields in tabs. => top and bottom action buttons appear above the form If this is a bug, I'll disable buttons_on_form_footers and move along for now. ๐Ÿ™‚
    l
    • 2
    • 12
  • c

    calm-gold-48525

    05/26/2023, 8:12 PM
  • Is there any way to access the URL
    a

    alert-toothbrush-24716

    05/28/2023, 3:51 AM
    Is there any way to access the URL parameters from filters in an Action?
    l
    • 2
    • 22
  • Stimulus JS & HTML attributes | Avo docs
    w

    wide-art-99889

    06/06/2023, 7:11 PM
    I have an Action, and I'd like to give it two inputs: a select input for "type of thing" and then a second select that's dynamically populated with record IDs based on the type of thing selected in the first select. This is very similar to the example shown at https://docs.avohq.io/2.0/stimulus-integration.html#custom-stimulus-controllers with the important difference that it's on an action rather than on a resource controller.
    l
    • 2
    • 6
  • Hi guys how are you I think that this
    v

    victorious-kangaroo-12568

    06/06/2023, 8:17 PM
    Hi guys how are you? I think that this new release broken the belongs_to field with polymorphic I got something like that (attachment) My current version (before upgrate) was 2.32.5 that works fine, but when I upgrade to 2.34 I got this issue
    b
    w
    l
    • 4
    • 9
  • Tailwind css install
    w

    wide-art-99889

    06/08/2023, 3:34 PM
    https://github.com/avo-hq/avo/issues/1764#issuecomment-1581787743 I filed this issue, but I'm wondering if anyone else has experienced this behavior: putting directives into
    config/tailwind.config.js
    that seem to be ignored by tailwind. Maybe it's just me?
    l
    • 2
    • 2
  • w

    wide-art-99889

    06/08/2023, 3:35 PM
    if no one else is having this problem I'll close the issue.
  • Police fields
    c

    calm-gold-48525

    06/08/2023, 10:22 PM
    Anybody have a good strategy for handling resources for different user roles? For example, an admin user can edit all the attributes of a Book but an editor is limited to a subset of attributes.
    l
    l
    • 3
    • 22
  • c

    calm-gold-48525

    06/08/2023, 10:24 PM
    Is with_options visible:... with a block a good approach?
  • Can someone help me with this nested
    i

    incalculable-psychiatrist-85460

    06/09/2023, 10:13 PM
    Can someone help me with this nested form? I'm working with a custom resource tool so I can display child **Message**s of a Chat, similar to a normal text chat UI. At the bottom, I want a nested form that allows one to post a new message. Currently, it updates the Chat succcessfully with no changes to the Messages. The message displays do work with
    @resource.model.messages
    , but not with creating new ones. Saving it manually with
    message = @resource.model.messages.new
    ->
    message.save
    does work (after inputting
    role
    and
    content
    values). *Things that didn't work*: -
    :message
    or
    :messages
    as an argument for
    fields_for
    - changing the
    extra_params
    to
    message:
    (unknown attribute) I'm unsure if it's something I have to change in the resource controller, the
    extra_params
    , or the model. # resource tool partial
    Copy code
    ruby
      <% if form.present? %>
      <% form.fields_for @resource.model.messages.new do |message| %>
        <%= form.label :message_content%>
        <%= message.text_field :content, value: 'message name', class: input_classes %>
        <%= message.hidden_field :role, value: 'user' %>
      <% end %>
    <% end %>
    # Chat Custom Resource
    Copy code
    ruby
      self.title = :name
      self.includes = [:messages]
      self.extra_params = [messages: [:content, :role]]
      self.model_class = ::Chat
    *Would like to have*: - any suggestions on how to enable this form on the Show view so it works as a live chat?
    l
    • 2
    • 2
  • b

    billowy-easter-81499

    06/12/2023, 2:24 PM
    I am very interested in offering a similar feature soon! I will follow this!
  • a

    acceptable-cartoon-88076

    06/12/2023, 2:38 PM
    @lemon-wall-20836 I'll bring Avo specific questions over here vs the JSP discord. Do you have any best practices for having two different 'sections' using Avo on the one app? One for Admins, one for regular users?
  • l

    lemon-wall-20836

    06/12/2023, 2:42 PM
    Thereโ€™s no โ€œsectionsโ€ feature for that but it handles that very well using Pundit policies and having a roles system
  • If you override your to param of your
    m

    mammoth-guitar-49791

    06/13/2023, 7:05 AM
    If you override your to_param of your model, how do you have to update your model_resource so that way you can show/edit/destroy using that new field?
    l
    • 2
    • 26
  • Has anybody else had an issue with
    m

    mammoth-guitar-49791

    06/13/2023, 8:54 AM
    Has anybody else had an issue with actions not displaying for their model resource? I generate a toggle_hidden action then define action ToggleHidden in my video_resource I don't define anything in this action but nothing shows up and there is no error. I have defined filters and they work.
    l
    • 2
    • 13
  • Adrian M https main avodemo com avo
    m

    mammoth-guitar-49791

    06/13/2023, 10:15 AM
    @lemon-wall-20836 https://main.avodemo.com/avo/resources/posts The images here are broken on the demo app.
    l
    • 2
    • 3
  • main.avodemo.com/app/avo/resources/team....
    m

    mammoth-guitar-49791

    06/13/2023, 4:34 PM
    @lemon-wall-20836 https://github.com/avo-hq/main.avodemo.com/blob/7598c9114ef47ca198e1b11077109458b8e415db/app/avo/resources/team.rb#L44 record should be model in the current implementation.
    l
    • 2
    • 6
  • File | Avo docs
    m

    mammoth-guitar-49791

    06/13/2023, 5:05 PM
    The docs here https://docs.avohq.io/2.0/fields/file.html
    field :avatar, as: :file, is_image: true
    recommend using this.
    The is_image, is_audio, and is_video options are deprecated in favor of letting Active Storage figure out the type of the attachment. If Active Storage detects a file as an image, Avo will display it as an image. Same for audio and video files.
    but this at the bottom says its depreciated. On my current version the image one display in the index without is_image.
    l
    • 2
    • 1
  • Scopes
    m

    mammoth-guitar-49791

    06/13/2023, 5:28 PM
    Are scopes (tabs with prefilters) on the suer model https://main.avodemo.com/avo/resources/users available at Avo 2.0? I dont' see anything in the documentation.
    l
    • 2
    • 2
  • I have a `dancer` has many couples and
    m

    mammoth-guitar-49791

    06/13/2023, 5:35 PM
    I have a
    dancer
    :has_many couples and has a
    profile_image
    From the couple I would like to display the dancer image. Is there a reference somewhere on how to do something like this? ๐Ÿค”
    l
    • 2
    • 61
  • Filters | Avo docs
    f

    fast-flag-76357

    06/14/2023, 4:57 PM
    @lemon-wall-20836 Hi how are you i hope you are doing well I add filter in my resource and according to that filter i want to generate the request spec here is the article that i followed from the official DOC of avo https://docs.avohq.io/2.0/filters.html#dynamic-filter-options
    l
    • 2
    • 18
  • Is there a simpler way to generate a
    b

    billowy-easter-81499

    06/14/2023, 5:10 PM
    Is there a simpler way to generate a variable number of fields without using nested records recipe approach? Specifically, I want a resource create page to consist of a variable number of text fields.
    l
    • 2
    • 14
  • I am having some code loading issues
    c

    creamy-ghost-62907

    06/15/2023, 1:23 AM
    I am having some code loading issues with an Avo project. Specifically, it's not finding any of my actions. I'm not doing anything with include/eager-loading paths, I've cleared the bootsnap cache. I am monkey-patching
    Avo::TabGroupBuilder
    to add a couple methods, and using
    Rails.configuration.to_prepare
    to include a a couple modules in
    Avo::ApplicationController
    . Could either of those things be causing some interference?
    l
    • 2
    • 4
  • One more day consulting all AVO networks
    m

    microscopic-dream-82397

    06/18/2023, 11:33 AM
    One more day consulting all AVO networks and no version 3 ๐Ÿ˜ญ
    l
    • 2
    • 1
  • Good morning guys Has anyone used the pg
    m

    microscopic-dream-82397

    06/18/2023, 11:39 AM
    Good morning guys. Has anyone used the pg_search gem with AVO to use PostgreSQL FTS (Full Texto Search) and could you tell me how they applied it to the filters or ransack?
    l
    • 2
    • 3
  • Any best practices on allowing enabling
    a

    acceptable-cartoon-88076

    06/18/2023, 4:40 PM
    Any best practices on allowing/enabling user defined dashboards/cards?
    l
    • 2
    • 12
1...596061...64Latest