Displaying 20 results from an estimated 22949 matches for "uploads".
Did you mean:
upload
2011 May 06
3
Rails 3 Routing problems
I have an UploadsController and UsersController where Users''
has_many :uploads'' via polymorphic attachment in uploads.rb.
Now we i navigate to http://localhost:3000/users/1/uploads
I get re-routed to Uploads#index and rendered is called multiple times
as shown below:
Started GET "/users/1/...
2006 Aug 01
3
Upload file to file system and sql insert date errors
...insert them into the
database.
My last effort was to try and use a sql statement in the model, but
have not got that to work yet.
Any pointers?
Thank you.
Greg
--------------------------
# model
class Upload < ActiveRecord::Base
def self.insert(upload)
"INSERT INTO ''uploads'' VALUES
(#{upload[''title'']},#{upload[''description'']})"
end
def self.save(upload)
if !File.exists?("./traces/#{upload[''name'']}")
Dir.mkdir("./traces/#{upload[''name'']}")
end...
2006 Jul 22
7
Validation with has_many
I have two problems. I have a comment that has_many uploads. Before
saving the comment, I want to be sure that the upload(s) has passed
validation, but I also need to validate in other ways. For example, I
do not want to save the comment if there is no comment or upload. Or, I
do not want to save the comment if the image has been uploaded
previously...
2006 Apr 24
1
Upload Progress Bar not showing
...the view.
I also have my Rails application set up for Apache, so when I try the
same thing, upload a file, I get the same message, "Upload starting..."
then "Upload finished", only I don''t get a redirect and the file I
uploaded isn''t there.
This is what my uploads controller looks like:
class UploadsController < ApplicationController
before_filter :authorize
upload_status_for :new
[...]
def new
if request.get?
@upload = Upload.new
else
@upload = Upload.new(@params["upload"])
if @upload.save
flash[:notic...
2006 Jan 05
4
testing file uploads
Hi all,
I was wondering about the class used when rails receives file uploads.
Sometimes it appears to be a File, and other times it is a StringIO.
Also it has methods such as original_filename that don''t appear to
belong to either of these classes. I ask because I''m trying to work out
how to test my fil upload related models and controllers.
Is there some...
2006 Jan 06
4
Upload Progress Bar Problems
...upload
case @request.method
when :post
@message = ''File uploaded: '' +
params[:document][:file].size.to_s
upload_progress.message = "Simulating some file processing
stage 1..."
session.update
# Dump information about uploads
@session[:uploads].each {|k,v| logger.debug("Debug:
#{k}----->#{v.completed_percent}")}
sleep(3)
upload_progress.message = "Continuing processing stage 2..."
session.update
sleep(3)
redirect_to :action => '...
2019 Nov 18
15
[PATCH v2 00/11] rvh-upload: Various fixes and cleanups
This series extract oVirt SDK and imageio code to make it eaiser to follow the
code and improve error handing in open() and close().
Tested with virt-v2v master.
Changes since v1:
- Rebase on merged patches from v1
- Fix regression introduced by "rhv-upload: Fix cleanup after errors"
- Remove "rhv-upload: Try to remove disk on timeout" since it cannot
succeed
- Add more
2019 Nov 17
23
[PATCH 00/18] rvh-upload: Various fixes and cleanups
This series extract oVirt SDK and imageio code to make it eaiser to follow the
code and improve error handing in open() and close().
The first small patches can be consider as fixes for downstream.
Tested based on libguestfs v1.41.5, since I had trouble building virt-v2v and
libguestfs from master.
Nir Soffer (18):
rhv-upload: Remove unused exception class
rhv-upload: Check status more
2010 Mar 26
2
file upload error(can't convert Tempfile into String)
...= link_to_close edit_list_path(@list)
.section
%small
#{t :add_contacts_from_file}
%table{ :width => 500, :cellpadding => 0, :cellspacing => 0 }
%tr
%td{ :valign => :top }
.label.top.req #{t :upload_new}:
=f.file_field :uploads, :style => "width:240px"
.buttonbar
= f.submit "#{t:save_contacts}", :onclick => "this.disabled =
true"
#{t :or}
= link_to_cancel edit_list_path(@list)
i created amodel contact list and nclude amethod as given below
class Contact...
2011 Mar 11
12
A file-upload suddenly seems to be nil
...m/forum/?hl=de#!topic/carrierwave/ergk9LaO68k>at
the carrierwave-group, but I''m beginning to think this rather is a
rails-issue than a problem with carrierwave. The problem''s this:
I have 2 models, ''article'' and ''upload''. article has_many :uploads. In my
article_controller i have an action named upload:
def upload
@article = Article.find(params[:id])
@article.uploads.create(params[:file])
render :nothing => true
end
this should save a file-upload to article.uploads. I''m using carrierwave to
save uploads in the upload-mo...
2006 Jul 02
4
how to use upload progress?
...h seems like it patches the
mongrel_upload_progress plugin
The following blog entry makes it seem as though the upload_progress
gem plugin is unfinished:
http://weblog.techno-weenie.net/2006/6/18/rails-deployment
And on the following site:
http://redhanded.hobix.com/cult/mongrel0313WithLargeFileUploadsConditionalHttpUploadProgressPatchAllAreGoodThings.html
it links to a patch
(http://rubyforge.org/pipermail/mongrel-users/attachments/20060511/8ba26353/attachment.obj)
which looks like it patches the mongrel code directly (not using a
plugin)
so there seems to be two patches and a plugin. I'&...
2018 Oct 01
2
[PATCH] v2v: -o rhv-upload: skip test-v2v-o-rhv-upload.sh w/o nbdkit
-o rhv-upload requires nbdkit, so skip this test if it is not installed.
---
v2v/test-v2v-o-rhv-upload.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/v2v/test-v2v-o-rhv-upload.sh b/v2v/test-v2v-o-rhv-upload.sh
index 8bda7cc0b..29214a9db 100755
--- a/v2v/test-v2v-o-rhv-upload.sh
+++ b/v2v/test-v2v-o-rhv-upload.sh
@@ -28,6 +28,7 @@ set -x
$TEST_FUNCTIONS
skip_if_skipped
skip_if_backend
2006 Jul 24
4
Mongrel + BackgrounDRb + File Column = Upload Progress Bar?
...@progress = 100
end
end
end
end
def progress
puts "Rails is fetching progress: #{@progress}"
Integer(@progress)
end
end
Are there any good tutorials out there that walk through the implementation
of backgroundrb (specifically covering file uploads)? Am I close to getting
this thing to work?
Thank you,
Dave Hoefler
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060724/9a48feda/attachment-0001.html
2006 Dec 25
4
Definitive guide for upload progress
...''mongrel'' => GemPlugin::INCLUDE
DRb.start_service ''druby://0.0.0.0:2999'', Mongrel::UploadProgress.new
DRb.thread.join
And all I get during upload ajax process are raised errors: "A
NameError occurred in upload#progress: uninitialized constant
Mongrel::Uploads". Status remains at 0% and picture is uploaded.
The DRb client always lists an empty array during uploads (get_status.list).
And in the rails controller I tried:
def progress
render :update do |page|
@status = Mongrel::Uploads.instance.check(params[:upload_id])
page.upload_...
2019 Sep 19
1
Re: [PATCH 2/2] v2v: -o rhv-upload: use same tmpdir for Python scripts
On Thu, Sep 19, 2019 at 02:30:05PM +0200, Pino Toscano wrote:
> Make use of the temporary directory of the rhv-upload mode also for the
> Python scripts that the mode creates, instead of creating new
> directories.
> ---
> v2v/output_rhv_upload.ml | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/v2v/output_rhv_upload.ml
2019 Nov 19
2
Re: [PATCH v2 00/11] rvh-upload: Various fixes and cleanups
On Tue, Nov 19, 2019 at 11:17 AM Martin Kletzander <mkletzan@redhat.com> wrote:
>
> On Mon, Nov 18, 2019 at 11:53:39PM +0200, Nir Soffer wrote:
> >This series extract oVirt SDK and imageio code to make it eaiser to follow the
> >code and improve error handing in open() and close().
> >
> >Tested with virt-v2v master.
> >
> >Changes since v1:
>
2018 Oct 01
2
[PATCH v2] v2v: -o rhv-upload: test-v2v-o-rhv-upload.sh: add more skip checks
-o rhv-upload requires python3, and nbdkit with the python3 plugin, so
skip this test if they are not installed.
---
v1 is:
https://www.redhat.com/archives/libguestfs/2018-October/msg00008.html
v2v/test-v2v-o-rhv-upload.sh | 2 ++
1 file changed, 2 insertions(+)
diff --git a/v2v/test-v2v-o-rhv-upload.sh b/v2v/test-v2v-o-rhv-upload.sh
index 8bda7cc0b..23d2ad7a0 100755
---
2019 Aug 12
1
[PATCH] v2v: -o rhv-upload: fix the phony ovirtsdk4 module
- add a no-op Connection.close(), as it called explicitly in the
close() callback of the nbdkit plugin (rhv-upload-plugin.py)
- fix the types of the 'id' variables, which are strings
---
v2v/test-v2v-o-rhv-upload-module/ovirtsdk4/__init__.py | 3 +++
v2v/test-v2v-o-rhv-upload-module/ovirtsdk4/types.py | 4 ++--
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git
2006 Aug 06
2
file upload with form_remote_tag
Is there a way to use form_remote_tag and to upload a file? The default
behavior ignores the upload when the Javascript serializes the form to
create the parameter list.
Basically, i''m just looking for an ajax file upload capability. Any help
would be appreciated.
thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
2019 Nov 17
0
Re: [PATCH 00/18] rvh-upload: Various fixes and cleanups
On Mon, Nov 18, 2019 at 1:04 AM Nir Soffer <nirsof@gmail.com> wrote:
>
> This series extract oVirt SDK and imageio code to make it eaiser to follow the
> code and improve error handing in open() and close().
>
> The first small patches can be consider as fixes for downstream.
I forgot to add Pino, who also did some fixes in this area.
>
> Tested based on libguestfs