forked from Techsystech/web
[MIG] Migration to 12.0: web_widget_image_webcam
parent
b6f7a0f3bb
commit
30683492e7
|
@ -41,6 +41,7 @@ Contributors
|
||||||
|
|
||||||
* Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
* Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
||||||
* Kaushal Prajapati <kbprajapati@live.com>
|
* Kaushal Prajapati <kbprajapati@live.com>
|
||||||
|
* Druidoo (<https://www.druidoo.io>)
|
||||||
|
|
||||||
Maintainer
|
Maintainer
|
||||||
----------
|
----------
|
||||||
|
|
|
@ -1,4 +1 @@
|
||||||
# Copyright 2019 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
|
||||||
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
|
||||||
|
|
||||||
from . import models
|
from . import models
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
# Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
# Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
||||||
|
# Copyright (C) 2019-Today: Druidoo (<https://www.druidoo.io>)
|
||||||
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
||||||
{
|
{
|
||||||
"name": "Web Widget - Image WebCam",
|
"name": "Web Widget - Image WebCam",
|
||||||
"summary": "Allows to take image with WebCam",
|
"summary": "Allows to take image with WebCam",
|
||||||
"version": "11.0.1.0.0",
|
"version": "12.0.1.0.0",
|
||||||
"category": "web",
|
"category": "web",
|
||||||
"website": "https://github.com/OCA/web",
|
"website": "https://github.com/OCA/web",
|
||||||
"author": "Tech Receptives, "
|
"author": "Tech Receptives, "
|
||||||
|
|
|
@ -1,4 +1 @@
|
||||||
# Copyright 2019 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
|
||||||
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
|
||||||
|
|
||||||
from . import ir_config_parameter
|
from . import ir_config_parameter
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
# Copyright 2019 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
# Copyright 2019 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
||||||
|
# Copyright 2019-Today: Druidoo (<https://www.druidoo.io>)
|
||||||
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
||||||
|
|
||||||
from odoo.models import api, Model
|
from odoo import api, models
|
||||||
|
|
||||||
|
|
||||||
class IrConfigParameter(Model):
|
class IrConfigParameter(models.Model):
|
||||||
_inherit = "ir.config_parameter"
|
_inherit = "ir.config_parameter"
|
||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
By default, the module works with all `major browsers
|
||||||
|
<https://github.com/jhuckaby/webcamjs#browser-support>`_.
|
||||||
|
|
||||||
|
An important note for **Chrome 47+** users - this module only works with websites delivered over SSL / HTTPS.
|
||||||
|
Visit this for `more info
|
||||||
|
<https://github.com/jhuckaby/webcamjs#important-note-for-chrome-47>`_.
|
||||||
|
|
||||||
|
But, If you still want this module to work with websites without SSL / HTTPS.
|
||||||
|
Here is the steps to do it easily (Always run in Adobe Flash fallback mode, but it is not desirable).
|
||||||
|
|
||||||
|
Set the configuration parameter ``web_widget_image_webcam.flash_fallback_mode`` to ``1``
|
||||||
|
|
||||||
|
Its done! Now this module also work with websites without SSL / HTTPS.
|
|
@ -0,0 +1,5 @@
|
||||||
|
* Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
||||||
|
* Kaushal Prajapati <kbprajapati@live.com>
|
||||||
|
* `Druidoo <https://www.druidoo.io>`_:
|
||||||
|
|
||||||
|
* Iván Todorovich
|
|
@ -0,0 +1 @@
|
||||||
|
This module extends the functionality of the image widget and allows to take snapshots with WebCam.
|
|
@ -1,13 +1,17 @@
|
||||||
/*
|
/*
|
||||||
Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
||||||
|
Copyright 2019-Today: Druidoo (<https://www.druidoo.io>)
|
||||||
License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
|
||||||
*/
|
*/
|
||||||
.o_form_view.o_form_editable .o_form_field_image .o_form_image_controls
|
.o_form_view.o_form_editable .o_form_field_image .o_form_image_controls
|
||||||
.o_form_binary_file_web_cam {
|
.o_form_binary_file_web_cam {
|
||||||
color: inherit;
|
color: inherit;
|
||||||
}
|
}
|
||||||
|
.o_field_widget.o_field_image .o_form_image_controls > .fa {
|
||||||
|
margin: 3px;
|
||||||
|
}
|
||||||
.o_form_view .o_form_field_image .o_form_image_controls > .fa{
|
.o_form_view .o_form_field_image .o_form_image_controls > .fa{
|
||||||
margin:3px;
|
margin: 3px;
|
||||||
}
|
}
|
||||||
.live_webcam_outer_div, .webcam_result_outer_div {
|
.live_webcam_outer_div, .webcam_result_outer_div {
|
||||||
padding-left: 20px;
|
padding-left: 20px;
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<!-- Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
<!-- Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@gmail.com>
|
||||||
|
Copyright 2019-Today: Druidoo (<https://www.druidoo.io>)
|
||||||
License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). -->
|
License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). -->
|
||||||
<template id="template" xml:space="preserve">
|
<template id="template" xml:space="preserve">
|
||||||
|
|
||||||
|
@ -12,7 +13,6 @@
|
||||||
<div t-name="WebCamDialog" id="WebCamModal">
|
<div t-name="WebCamDialog" id="WebCamModal">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-12">
|
|
||||||
<div class="col-md-5 live_webcam_outer_div">
|
<div class="col-md-5 live_webcam_outer_div">
|
||||||
<div id="live_webcam"/>
|
<div id="live_webcam"/>
|
||||||
</div>
|
</div>
|
||||||
|
@ -23,6 +23,5 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -4,12 +4,9 @@
|
||||||
<odoo>
|
<odoo>
|
||||||
<template id="assets_backend" inherit_id="web.assets_backend">
|
<template id="assets_backend" inherit_id="web.assets_backend">
|
||||||
<xpath expr=".">
|
<xpath expr=".">
|
||||||
<script type="text/javascript"
|
<script type="text/javascript" src="/web_widget_image_webcam/static/src/js/webcam.js"/>
|
||||||
src="/web_widget_image_webcam/static/src/js/webcam.js"/>
|
<script type="text/javascript" src="/web_widget_image_webcam/static/src/js/webcam_widget.js"/>
|
||||||
<link rel="stylesheet"
|
<link rel="stylesheet" href="/web_widget_image_webcam/static/src/css/web_widget_image_webcam.css"/>
|
||||||
href="/web_widget_image_webcam/static/src/css/web_widget_image_webcam.css"/>
|
|
||||||
<script type="text/javascript"
|
|
||||||
src="/web_widget_image_webcam/static/src/js/webcam_widget.js"/>
|
|
||||||
</xpath>
|
</xpath>
|
||||||
</template>
|
</template>
|
||||||
</odoo>
|
</odoo>
|
||||||
|
|
Loading…
Reference in New Issue