On Jul 23, 2010, at 1:19 PM, David LeBer wrote:

> 
> Well that will update an ajax update container with the id 
> 'attachmentUploadContainer'

Well that clears that much up.  Unfortunately, this didn't actually solve 
anything.

> 
>> Also, I don't know where the default css is.
> 
> Because ERAttachmentFlexibleUpload is based on AjaxFlexibleFileUpload the 
> default css is in the Ajax framework: default_ajaxupload.css

Thanks.  I didn't even think of that.  I'll look there.

> 
>> The main problem is that when I delete an attachment (by setting it to null 
>> in the communication's edit component), then I want to add another 
>> attachment, the old filename appears, with a clear link below it.  I have no 
>> idea why that is, or where that is happening.
> 
> It is not clear what you are doing here. How and where are you deleting the 
> attachment again?

Basically, I have an edit component which contains the AjaxModalDialog 
containing the subcomponent with the Flexible Uploader

The edit component edits the communication in general, and as part of that, the 
user can attach up to 5 files.  These appear in an inline worepetition with a 
close button.  Clicking close tells the attachment represented by that index to 
be set to null.  e.g. click the close button for attachment1 sends 
communcation.setAttachment1(null)

There are also links at the end of the repetition to add more attachments.  
Clicking one opens the AjaxModalDialog containing the subcomponent with the 
ERAttachmentFlexibleUploader.

The first time you click "Add File" the dialog appears with the choose file 
button reflected as a shrunken version of my standard "prettyButton" . . . 
presumably it's shrunken because of something in the CSS.  Once you choose a 
file, it's uploaded and it appears with a red "x" close button.  Presumably 
also in the CSS.  (I originally didn't set the choose button class and got a 
blue "choose" button which apparently didn't have a grey background, so the 
corners are a little weird.  Hence I tried to use our button class)

After you upload a file, and click my "Attach" button (which simply sets the 
attachmentItem into the first available spot for the communication's 
attachments -- e.g. communication().setAttachment1(attachmentItem).  This 
appears to work.  The dialog goes away and the attachment appears.  

If you click our close button for it, it disappears.  Then if you click attach 
files again, the old attachment's filename appears, with a "Clear" link under 
it.

I'd rather have it just open an empty one uploader with a default button 
instead of a clear link.

Sorry I wasn't clearer earlier, Dave A was harassing me to go to lunch.  I 
can't disappoint Dave.

> 
> Have you looked at using ERAttachmentFlexibleEditor? It uploading adding 
> *and* removing/replacing attachments.

I was originally looking at using the editor, but they actively didn't want to 
see the uploaded file (dunno why) so I went back to the Flexible Uploader.

I will look at the other things you mentioned, and hopefully that will explain 
things better for me

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to