| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 278 |
| Technical Name |
image_capture_upload_widget |
| License | AGPL-3 |
| Website | https://www.cybrosys.com |
| Versions | 15.0 16.0 17.0 18.0 |
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 278 |
| Technical Name |
image_capture_upload_widget |
| License | AGPL-3 |
| Website | https://www.cybrosys.com |
| Versions | 15.0 16.0 17.0 18.0 |
Image Capture Widget
Image Capture Widget
Explore This Module
Overview
Features
Enterprise and Community compatible.
Capturing Image from webcam
Screenshots
Configuration
Add the 'capture_image' as the widget of an image field
Click the camera button to open the camera
Click the 'Capture' button capture images.
Click the 'Save image' button saving the image.
Related Products
Our Services
Odoo Customization
Odoo Implementation
Odoo Support
Hire Odoo Developer
Odoo Integration
Odoo Migration
Odoo Consultancy
Odoo Implementation
Odoo Licensing Consultancy
Our Industries
Trading
Easily procure and sell your products
POS
Easy configuration and convivial experience
Education
A platform for educational management
Manufacturing
Plan, track and schedule your operations
E-commerce & Website
Mobile friendly, awe-inspiring product pages
Service Management
Keep track of services and invoice
Restaurant
Run your bar or restaurant methodically
Hotel Management
An all-inclusive hotel management application
Support
Say hi to us on WhatsApp!
+91 86068 27707
Please log in to comment on this module
Thank you
For free module it's great, but this only can work if you have the record already and editing existing record (since it need record_id), it would be great if we can capture the image together while we input the data.
Re: Thank you
We have updated the module with the same.
change the js file as below if you faced Error
Fixed Code for OnClickCaptureImage()
Replace your OnClickCaptureImage function with this safe version:
async OnClickCaptureImage() {
// Safely get DOM elements
var player = document.getElementById('player');
var snapshot = document.getElementById('snapshot');
var save_image = document.getElementById('save_image');
var image = document.getElementById('image');
var camera = document.getElementById('camera');
var canvas = document.getElementById('snapshot');
// Check if elements exist
if (!player || !snapshot || !canvas || !save_image || !image) {
this.notification.add(_lt("Camera or canvas element not found. Please check widget setup."), { type: "danger" });
return;
}
// Now proceed safely
var context = snapshot.getContext('2d');
save_image.classList.remove('d-none');
context.drawImage(player, 0, 0, 320, 240);
image.value = context.canvas.toDataURL();
canvas.classList.remove('d-none');
this.url = context.canvas.toDataURL();
console.log(context.canvas.toDataURL());
}
Re: change the js file as below if you faced Error
Thanks for the input. We have updated the app with your lines. We apreciate the effort.
Great feature, but
Hi,
This module is great indeed, specifically for a free module.
However, it only works with one image per form :-)
Would be nice if we could use more.
Good work anyway