I am using cordva-camera and successfully figured out to work with it. The problem is that I can send multiple images across my other form variables only if they are base64 encoded.
So my question is how to POST multiple images and other form fields with http.post using Camera.DestinationType.FILE_URI ? How to post using native path the images?
You can transform images into Blob Object by using resolveLocalFilesystemUrl which in File plugin. Then put Blob Object into a FormData and upload it. I solved my problem as same as yours by this article and this.
Related
I'm attempting to create a form in Laravel 9 (Repository pattern) that allows me to upload multiple images and preview them before allowing the user to crop the image and save both files (original and cropped).
Do you have any suggestions for how to approach this?
I guess you would need a combination of frontend javascript and fileupload on the laravel side. For javascript, you can look at filepond.
Alternatively, you can look at laravel filament. Filament is already using filepond as part of its form builder. It allows multiple files upload and resizing. Maybe you can start your approach from there.
I need to create an API in Django that will use to take an XML file.
Main Question:
I have created models and serialization and but files that have not to save in Django after extracting the data file will be deleted. now I can not understand the view part(api) please help.
If you wish to upload a file using DRF, you might want to take a look at this topic. It should give you an idea of what to do
im newbie in Siebel CRM.
I have a task of creating form applet that has functionality of uploading images and also some text records.
What I need to do is: send images and some text via WS(f.e. using SOAP) to external application and also save text information in siebel db.
My problem is that I cant create form applet with upload button and then submit button that processes given record as I described before.
PS: Appreciate if u give detailed information, Thanks !
Such functionality can easily be achieved using Siebel's attachment business components. For instance, under Service Requests, there is an attachments tab. Files can be uploaded here. Later for integration, your could simply use EAI Siebel Adapter BS in a Workflow, that will convert the binary attachment to base64 in the XML, which can be sent out. Users can upload any kind of file in different records.
Siebel OpenUI can show some images in Contact tiles uploaded into urls intead of files:
http://www.brucedaley.com/siebelobserver/2014/02/tiles-and-images.html
It can be done without using attachment BCs, with ordinary JS code in PR/PM file. I had to do it so users can upload PDF files, which had to be base64 encoded and sent via WS afterward but not saved in Siebel. I've used JS FileReader object (MDN) and JS out of the box base64 encoding (MDN docs).
I am using Sorl-Thumbnail to generate thumbnails within pages via template tags.
This all works perfectly fine.
However I have now added a store locator function to the site which feeds into my Google Maps JS via JSON.
In the infowindow popups I would like to put a tiny image of the storefront.
So I need to create another size of thumbnail and I need to include the URL for this within my JSON.
It seemed initially that Sorl doesnt support this due to its requirement for Tags within a page.
I have looked at the low level API version "get_thumbnail" and have tried to implement this within my Model without much luck so far.
I have no problem with my JSON and serialisation, just getting the thumbnail generated and into the model prior to this.
Has anyone had any experience with this scenario previously?
Cheers
Kev
I want to upload images to a gallery app. I want the user to be able to either load images normaly, or upload on zip file containing all the images for that gallery. Then it must be uncompressed and all images must be added to that model. This is for the admin site.
Any ideas?
You could either use the existing django-app django-photologue which enables you to do that or have a look at how it is implemented there: https://code.google.com/p/django-photologue/source/browse/trunk/photologue/models.py.
If you see that photlogue is lacking some of the functionality you need, you could also subclass and extend photologue's models in your app!