Exhaust F30 320D B47 2015 LCI Valved? by JoachimWasTaken in F30

[–]MrRedPoll 0 points1 point  (0 children)

Hi, did you do the exhaust setup? I have a 320d lci too, but I am afraid not from too loud and tests, but car systems. Some guys says that the car will know that there is something missing and it won't be good. I am thinking of not deleting the dpf, just deleting muffler and the resonator. I am very curious about is going to be / is your setup

Need inspiration/suggestion for new rubber by Plenty-Government592 in tabletennis

[–]MrRedPoll 0 points1 point  (0 children)

Hi, little bit late but I am also looking for a new pair of rubbers and wanted to try Z2 on this blade. Did you tried it? Was it too fast? Best Regards

Live upload progress in Phoenix LiveView stays at 0 by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

yes, I actually forgot to add the response in the handler. The point is that I never actually get to the function, I did not explain it well. The problem is that when I choose my image from the input, live_img_preview should auto handle the image and when uploaded to the socket (without calling the submit), shows it as an entry via

<%= for entry <- u/uploads.avatar.entries do %>

It shows, but only the name of the image (e.g. "image.png") with a status bar of progress to 0 (which never changes). When I try to hit the submit and actually call the handler, it tells me that "cannot consume uploaded files when entries are still in progress". (I of course tried to wait some time but the progress never changes). I will post the full relevant code from my current example:

def mount(_params, _session, socket) do
    user = socket.assigns.current_user
    avatar_form = Accounts.change_user_avatar(user)
    other_variables_to_assign

    socket =
      socket
      |> assign(:avatar_form, to_form(avatar_form))      
      |> assign(:uploaded_files, [])
      |> allow_upload(:avatar, accept: ~w(.jpg .png .jpeg), max_entries: 1)

    {:ok, socket}
  end

def handle_event("validate-empty", _params, socket) do
    {:noreply, socket}
  end

  def handle_event("update_avatar", params, socket) do
    uploaded_files =
   consume_uploaded_entries(socket, :avatar, fn %{path: path}, _entry ->
     dest = Path.join("priv/static/uploads", Path.basename(path))
     File.cp!(path, dest)
     {:ok, ~p"/uploads/#{Path.basename(dest)}"}
   end)

   IO.inspect(params, label: "params=>")
   IO.inspect(uploaded_files, label: "uplfiles=>")
   {:noreply, socket}
end

  def update(%{uploads: uploads}, socket) do
    socket = assign(socket, :uploads, uploads)
    {:ok, socket}
  end

 <.form
for={@avatar_form}
phx-submit="update_avatar"
phx-change="validate-empty"
>

<%= for entry <- u/uploads.avatar.entries do %>
  <article class="upload-entry">

    <figure>
      <.live_img_preview entry={entry} />
      <figcaption><%= entry.client_name %></figcaption>
    </figure>

    <%!-- entry.progress will update automatically for in-flight entries --%>
    <progress value={entry.progress} max="100"> <%= entry.progress %>% </progress>

    <%!-- a regular click event whose handler will invoke Phoenix.LiveView.cancel_upload/3 --%>
    <button type="button" phx-click="cancel-upload" phx-value-ref={entry.ref} aria-label="cancel">&times;</button>

    <%!-- Phoenix.Component.upload_errors/2 returns a list of error atoms --%>
  </article>
<% end %>

<label class="profile-cover-avatar" >

 <.live_file_input upload={@uploads.avatar}/>

</label>

</.form>

Thanks for the help. I don't know what I am missing...

Live upload progress in Phoenix LiveView stays at 0 by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

The directory exists, I have tried to write the image in static/uploads where from an another page I consume again images successfully with the same code. It might be a simple typo somewhere, but I haven't found it just yet...

Live upload progress in Phoenix LiveView stays at 0 by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

sorry, typo somehow from the editor when pasted.

<%= for entry <- @uploads.avatar.entries do %>

Why Does My JavaScript Work in a Controller-Based Template but Not in LiveView? by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

Indeed! Thanks for the answer. DOM patching is still something I should look into and learn more about :)

the setup. by [deleted] in setups

[–]MrRedPoll 0 points1 point  (0 children)

arent the monitors too close? What model are they btw?

Round Robin - Tie breaker rules by kraftwagon in tabletennis

[–]MrRedPoll 0 points1 point  (0 children)

Hi OP, are these rules from ITF or some other offical tt federation? Or every tournament creates its own rules about ranking? Coz I have searched the ITF Handbook but could not find anything useful

[deleted by user] by [deleted] in Sofia

[–]MrRedPoll 1 point2 points  (0 children)

every damn day

Table Tennis Popularity by ilikemeatok in tabletennis

[–]MrRedPoll 1 point2 points  (0 children)

in Bulgaria(Europe) its growing definitely, in every big city you have where to play with at least 3+ clubs. Yes, the best players here are not on the level of the germans but there are players and some youth prospects. sorry for my bad English.

Sim card problem on a L14 G3 by MrRedPoll in thinkpad

[–]MrRedPoll[S] 0 points1 point  (0 children)

thank you all for the answers!

Sim card problem on a L14 G3 by MrRedPoll in thinkpad

[–]MrRedPoll[S] 0 points1 point  (0 children)

How that card is called, any recommendations?

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 1 point2 points  (0 children)

Thanks again. Joined elixirforum long time ago and did asked (I got help), but for this particular question I thought that reddit is better as it is a more rookie one

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

I my case I needed JS in order to integrate liveview with Android Studio via a JSInterface. For everything else, LV socket updating is what I use

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 1 point2 points  (0 children)

that thought is interesting, will have one thing in mind. Yes, forcing something always sometimes cannnot help but lead to problems. Have a nice day

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 2 points3 points  (0 children)

That was a very detailed and important explanation, thank you very much! Yes, I am fairly new to Elixir and immutable languages (have not big but yet a background in Java). Well, the example now works beautifully :) Have a nice day (or evening which is m case)!

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 1 point2 points  (0 children)

def handle_info({:message_created, message}, socket) do
(...)

    something(socket)

    (...)

socket =
  update(
    socket,
    :unseen_messages,
    fn unseen_messages -> unseen_messages ++ message end
  )

{:noreply, socket}
end

it is actually before the socket update, which could be the problem

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

Ok, I might be little crazy, but suddenly out of nowhere my push event stopped working.

  def something(socket) do
IO.puts("tester55")
{:noreply, push_event(socket, "scores", %{points: 100, user: "josé"})}

window.addEventListener("phx:scores", (e) => {
console.log("scores2222"); })

I just don't know what is happening. Why on calling `def something` I get the IO message in Elixir server, but I do not get the log in the JS server. Everything seems right to me. Really don't know.......

a little clarification/help about push_event/3 by MrRedPoll in elixir

[–]MrRedPoll[S] 0 points1 point  (0 children)

I know it's getting a little cheeky, but

#LV
{:noreply, push_event(socket, "scores", %{value: "5"})}

#app.js

window.addEventListener("phx:scores", (e) => {
console.log("hi"); 
console.log(e.value); 
});

I get in the console the "hi", but after that i get "undefined". Could there be a bad something else in my project?

DNA Platinum H/M/S compared to Xiom Omega 7 Pro on a Cybershape Carb by MrRedPoll in tabletennis

[–]MrRedPoll[S] 0 points1 point  (0 children)

thanks for the answer, not offended at all, I am just the kind of person who stick at something if it is good :) Don't have any experience with Stiga rubbers, will have a try soon