thecore_dataentry_commons 1.5.2 → 2.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/higher_level/_barcode_simple_scan.html.erb +1 -1
- data/app/views/rails_admin/main/_dataentry_commons_input_group_logic.html.erb +1 -1
- data/app/views/thecore_utils/_html_helpers.html.erb +65 -0
- data/lib/thecore_dataentry_commons.rb +2 -2
- data/lib/thecore_dataentry_commons/version.rb +1 -1
- metadata +9 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 140f6c75984627fe814a919ee45ae4facfc75a35eed04be189ae93ceec1c8e17
|
4
|
+
data.tar.gz: b395e85fbb57dba18e2eb911ebb48115c88e7ab5d6504b66ab6b7837b265e178
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b311678f7e1a0fc695d5c4e536a5f8a426afb912e155a3a13b69ba9e13f509e0d330be7e5722dd178b838b5e165392ba00f5597c554f6ac4a92dd1d99a4c83e3
|
7
|
+
data.tar.gz: 0725e8e36af25144087d939b75fa919f38326d870408eff03fb4a487e5a78d1b7f9f3f336c2a0595877cfcece3e726787747831da067068b63813bd7e3766e8c
|
@@ -9,10 +9,10 @@
|
|
9
9
|
var returnedData;
|
10
10
|
var additionalData = {};
|
11
11
|
var disableKeyManagement = false;
|
12
|
+
var cleanBarcode = true;
|
12
13
|
|
13
14
|
function resetInfo() {
|
14
15
|
returnedData = code = undefined;
|
15
|
-
$("#barcode").empty();
|
16
16
|
$("#data-info").empty().hide();
|
17
17
|
$("#data-content").empty().hide();
|
18
18
|
<%-unless (hide_action rescue true)%>
|
@@ -0,0 +1,65 @@
|
|
1
|
+
<script>
|
2
|
+
function buildDTPicker(id, label, initialValue, ro, date_only){
|
3
|
+
var html = '<div class="input-group date" default-date="'+initialValue+'">';
|
4
|
+
html += '<label class="input-group-addon">'+label+'</label>';
|
5
|
+
html += '<input class="form-control" type="text" readonly/>';
|
6
|
+
html += '<label class="input-group-addon"><i class="fa fa-fw fa-calendar"></i></label>';
|
7
|
+
html += '</div>';
|
8
|
+
var jqueryObj = $(html);
|
9
|
+
var dtParams = {
|
10
|
+
locale: "<%=I18n.locale%>",
|
11
|
+
defaultDate: initialValue,
|
12
|
+
ignoreReadonly: !ro,
|
13
|
+
allowInputToggle: true,
|
14
|
+
sideBySide: true,
|
15
|
+
icons: {
|
16
|
+
time: 'fa fa-clock',
|
17
|
+
date: 'fa fa-calendar',
|
18
|
+
up: 'fa fa-chevron-up',
|
19
|
+
down: 'fa fa-chevron-down',
|
20
|
+
previous: 'fa fa-chevron-left',
|
21
|
+
next: 'fa fa-chevron-right',
|
22
|
+
today: 'fa fa-calendar-check',
|
23
|
+
clear: 'fa fa-trash',
|
24
|
+
close: 'fa fa-times'
|
25
|
+
}
|
26
|
+
}
|
27
|
+
if(date_only)
|
28
|
+
dtParams.format = "L";
|
29
|
+
jqueryObj.datetimepicker(dtParams).on('dp.change', function (e){
|
30
|
+
returnedData[id.replace(/-/g, '_')] = e.date.format();
|
31
|
+
$(this).datetimepicker('hide');
|
32
|
+
});
|
33
|
+
return jqueryObj;
|
34
|
+
}
|
35
|
+
|
36
|
+
function buildDatePicker(id, initialValue) {
|
37
|
+
var html = '<div class="input-group date" id="' + id + '">';
|
38
|
+
html += '<input type="text" class="form-control" />';
|
39
|
+
html += '<label class="input-group-addon"><i class="fa fa-fw fa-calendar"></i></label>';
|
40
|
+
html += '</div>';
|
41
|
+
var jqueryObj = $(html);
|
42
|
+
var dtParams = {
|
43
|
+
locale: "<%=I18n.locale%>",
|
44
|
+
defaultDate: initialValue,
|
45
|
+
allowInputToggle: true,
|
46
|
+
format: 'L',
|
47
|
+
icons: {
|
48
|
+
time: 'fa fa-clock',
|
49
|
+
date: 'fa fa-calendar',
|
50
|
+
up: 'fa fa-chevron-up',
|
51
|
+
down: 'fa fa-chevron-down',
|
52
|
+
previous: 'fa fa-chevron-left',
|
53
|
+
next: 'fa fa-chevron-right',
|
54
|
+
today: 'fa fa-calendar-check',
|
55
|
+
clear: 'fa fa-trash',
|
56
|
+
close: 'fa fa-times'
|
57
|
+
}
|
58
|
+
}
|
59
|
+
jqueryObj.datetimepicker(dtParams).on('dp.change', function (e){
|
60
|
+
$(this).datetimepicker('hide');
|
61
|
+
//returnedData[id.replace(/-/g, '_')] = e.date.format();
|
62
|
+
});
|
63
|
+
return jqueryObj;
|
64
|
+
}
|
65
|
+
</script>
|
metadata
CHANGED
@@ -1,43 +1,43 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: thecore_dataentry_commons
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriele Tassoni
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: thecore_ui_rails_admin
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '2.0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '2.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: browser
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '4.1'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
40
|
+
version: '4.1'
|
41
41
|
description: This plugin adds some partials to deal with DataWedge WebSocket.
|
42
42
|
email:
|
43
43
|
- gabriele.tassoni@gmail.com
|
@@ -55,6 +55,7 @@ files:
|
|
55
55
|
- app/views/rails_admin/main/_dataentry_commons_input_group_logic.html.erb
|
56
56
|
- app/views/rails_admin/main/_kp.html.erb
|
57
57
|
- app/views/rails_admin/main/_ws.html.erb
|
58
|
+
- app/views/thecore_utils/_html_helpers.html.erb
|
58
59
|
- config/locales/en.thecore_datawedge_websocket_helpers.yml
|
59
60
|
- config/locales/it.thecore_datawedge_websocket_helpers.yml
|
60
61
|
- db/migrate/20170913192906_add_keymode_to_settings.rb
|
@@ -81,7 +82,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
81
82
|
- !ruby/object:Gem::Version
|
82
83
|
version: '0'
|
83
84
|
requirements: []
|
84
|
-
rubygems_version: 3.0.
|
85
|
+
rubygems_version: 3.0.3
|
85
86
|
signing_key:
|
86
87
|
specification_version: 4
|
87
88
|
summary: Some javascripts and partials to handle DW WS.
|