solved some problems
|
@ -46,13 +46,6 @@
|
|||
<sourceFolder url="file://$MODULE_DIR$/src/debug/java" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/rs" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/shaders" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestDebug/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestDebug/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestDebug/assets" type="java-test-resource" />
|
||||
|
@ -60,18 +53,18 @@
|
|||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestDebug/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestDebug/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTestDebug/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/res" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/assets" type="java-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/main/shaders" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/test/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/test/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/test/assets" type="java-test-resource" />
|
||||
|
@ -79,6 +72,13 @@
|
|||
<sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/test/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/test/shaders" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/generated/not_namespaced_r_class_sources" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/generated/source/r" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/aapt_friendly_merged_manifests" />
|
||||
|
|
|
@ -12,8 +12,9 @@
|
|||
<exclude-output />
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<excludeFolder url="file://$MODULE_DIR$/.gradle" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/build" />
|
||||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="jdk" jdkName="1.8" jdkType="JavaSDK" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
|
@ -131,5 +131,6 @@
|
|||
<orderEntry type="library" name="Gradle: :barcodescanner-release-2.1.5:@aar" level="project" />
|
||||
<orderEntry type="library" name="Gradle: android.arch.core:common:1.1.0@jar" level="project" />
|
||||
<orderEntry type="module" module-name="CordovaLib" />
|
||||
<orderEntry type="module" module-name="CordovaLib" />
|
||||
</component>
|
||||
</module>
|
|
@ -3,7 +3,7 @@
|
|||
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:resizeable="true" android:smallScreens="true" android:xlargeScreens="true" />
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<application android:hardwareAccelerated="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:supportsRtl="true">
|
||||
<activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale" android:label="@string/activity_name" android:launchMode="singleTop" android:name="MainActivity" android:theme="@android:style/Theme.DeviceDefault.NoActionBar" android:windowSoftInputMode="adjustResize">
|
||||
<activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale" android:label="@string/activity_name" android:launchMode="singleTop" android:name="MainActivity" android:theme="@android:style/Theme.DeviceDefault.NoActionBar" android:windowSoftInputMode="adjustResize" android:screenOrientation="portrait">
|
||||
<intent-filter android:label="@string/launcher_name">
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
|
|
|
@ -174,6 +174,21 @@ spam{
|
|||
font-size: 1.2em;
|
||||
padding-top: 14px;
|
||||
}
|
||||
.btnsalix{
|
||||
margin-bottom: 10px;
|
||||
background-color: rgba(0,0,0,.150);
|
||||
background-image: url(../img/salix.png);
|
||||
background-repeat: no-repeat;
|
||||
background-size: 25px;
|
||||
background-position-y: center;
|
||||
background-position-x: 10px;
|
||||
width: 100%;
|
||||
height: 50px;
|
||||
border-radius: 15px;
|
||||
padding-left: 43px;
|
||||
font-size: 1.2em;
|
||||
padding-top: 14px;
|
||||
}
|
||||
label{
|
||||
font-size: 1.5em;
|
||||
margin-bottom: 5px;
|
||||
|
|
After Width: | Height: | Size: 4.3 KiB |
|
@ -9,7 +9,7 @@ var maxCroppedHeight = 2688;
|
|||
var ratio = 1;
|
||||
var maxAspectRatio = 1.5;
|
||||
var image;
|
||||
var saveToPhotoAlbum = true;
|
||||
|
||||
var cropper;
|
||||
|
||||
|
||||
|
@ -70,6 +70,13 @@ $(document).ready(function () {
|
|||
window.location = "index.html";
|
||||
});
|
||||
|
||||
$(".btnsalix").on("click", function () {
|
||||
var target = "_system";
|
||||
var options = "location=no";
|
||||
var url = "https://salix.verdnatura.es";
|
||||
var ref = cordova.InAppBrowser.open(url, target, options);
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
function setManualMode() {
|
||||
|
@ -80,7 +87,7 @@ function setManualMode() {
|
|||
'Article: ' + idArticulo, // message
|
||||
onConfirm, // callback to invoke with index of button pressed
|
||||
'Verdnatura says:', // title
|
||||
['¡Take a picture!', '¡Library!', '¡Other!'] // buttonLabels
|
||||
['¡Take a picture!', '¡Library!', '¡Close!'] // buttonLabels
|
||||
);
|
||||
} else {
|
||||
navigator.notification.alert("Insert manual id or scan article", null, "Verdnatura says:", "¡ups!");
|
||||
|
@ -166,7 +173,7 @@ function scanBarcode() {
|
|||
'Article: ' + result.text, // message
|
||||
onConfirm, // callback to invoke with index of button pressed
|
||||
'Verdnatura says:', // title
|
||||
['¡Take a picture!', '¡Library!', '¡Other!'] // buttonLabels
|
||||
['¡Take a picture!', '¡Library!', '¡Close!'] // buttonLabels
|
||||
);
|
||||
|
||||
},
|
||||
|
@ -203,16 +210,36 @@ function onError() {
|
|||
}
|
||||
function showCamera() {
|
||||
var srcType = Camera.PictureSourceType.CAMERA;
|
||||
saveToPhotoAlbum = true;
|
||||
var options = setOptions(srcType);
|
||||
|
||||
var options = {
|
||||
saveToPhotoAlbum: true,
|
||||
quality: 80,
|
||||
destinationType: Camera.DestinationType.FILE_URI,
|
||||
sourceType: srcType,
|
||||
encodingType: Camera.EncodingType.JPEG,
|
||||
mediaType: Camera.MediaType.PICTURE,
|
||||
allowEdit: false,
|
||||
correctOrientation: true
|
||||
};
|
||||
|
||||
|
||||
|
||||
navigator.camera.getPicture(cameraSuccess, cameraError, options);
|
||||
|
||||
}
|
||||
function showLibrary() {
|
||||
var srcType = Camera.PictureSourceType.PHOTOLIBRARY;
|
||||
saveToPhotoAlbum = false;
|
||||
var options = setOptions(srcType);
|
||||
|
||||
var options = {
|
||||
saveToPhotoAlbum: false,
|
||||
quality: 80,
|
||||
destinationType: Camera.DestinationType.FILE_URI,
|
||||
sourceType: srcType,
|
||||
encodingType: Camera.EncodingType.JPEG,
|
||||
mediaType: Camera.MediaType.PICTURE,
|
||||
allowEdit: false,
|
||||
correctOrientation: true
|
||||
};
|
||||
navigator.camera.getPicture(cameraSuccess, cameraError, options);
|
||||
|
||||
}
|
||||
|
|
|
@ -34,13 +34,15 @@
|
|||
<div class="btnlogout"></div>
|
||||
<img id="logo" src="img/logo.png" alt="verdnatura"/>
|
||||
<br>
|
||||
<label>insert manual id:</label>
|
||||
|
||||
<div class="input">
|
||||
<img src="img/article.png" alt="verdnatura"/>
|
||||
<input type="text" id="txtarticle" placeholder="article id" value=""/>
|
||||
</div>
|
||||
<label>or scan id:</label>
|
||||
|
||||
<div class="btnbarcode">Scan</div>
|
||||
<div class="btnsalix">Salix</div>
|
||||
|
||||
<div class="btn loginbtn" id="btntakepicture">
|
||||
¡Go!
|
||||
</div>
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@mipmap/ic_launcher_background" />
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 3.3 KiB |
|
@ -1,5 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@mipmap/ic_launcher_background" />
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 1.7 KiB |
|
@ -1,5 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@mipmap/ic_launcher_background" />
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 2.5 KiB |
|
@ -1,5 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@mipmap/ic_launcher_background" />
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
Before Width: | Height: | Size: 688 B |
Before Width: | Height: | Size: 12 KiB |
|
@ -1,5 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@mipmap/ic_launcher_background" />
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
Before Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 23 KiB |
|
@ -1,5 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@mipmap/ic_launcher_background" />
|
||||
<foreground android:drawable="@mipmap/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
Before Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 37 KiB |
|
@ -174,6 +174,21 @@ spam{
|
|||
font-size: 1.2em;
|
||||
padding-top: 14px;
|
||||
}
|
||||
.btnsalix{
|
||||
margin-bottom: 10px;
|
||||
background-color: rgba(0,0,0,.150);
|
||||
background-image: url(../img/salix.png);
|
||||
background-repeat: no-repeat;
|
||||
background-size: 25px;
|
||||
background-position-y: center;
|
||||
background-position-x: 10px;
|
||||
width: 100%;
|
||||
height: 50px;
|
||||
border-radius: 15px;
|
||||
padding-left: 43px;
|
||||
font-size: 1.2em;
|
||||
padding-top: 14px;
|
||||
}
|
||||
label{
|
||||
font-size: 1.5em;
|
||||
margin-bottom: 5px;
|
||||
|
|
After Width: | Height: | Size: 4.3 KiB |
|
@ -9,7 +9,7 @@ var maxCroppedHeight = 2688;
|
|||
var ratio = 1;
|
||||
var maxAspectRatio = 1.5;
|
||||
var image;
|
||||
var saveToPhotoAlbum = true;
|
||||
|
||||
var cropper;
|
||||
|
||||
|
||||
|
@ -70,6 +70,13 @@ $(document).ready(function () {
|
|||
window.location = "index.html";
|
||||
});
|
||||
|
||||
$(".btnsalix").on("click", function () {
|
||||
var target = "_system";
|
||||
var options = "location=no";
|
||||
var url = "https://salix.verdnatura.es";
|
||||
var ref = cordova.InAppBrowser.open(url, target, options);
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
function setManualMode() {
|
||||
|
@ -80,7 +87,7 @@ function setManualMode() {
|
|||
'Article: ' + idArticulo, // message
|
||||
onConfirm, // callback to invoke with index of button pressed
|
||||
'Verdnatura says:', // title
|
||||
['¡Take a picture!', '¡Library!', '¡Other!'] // buttonLabels
|
||||
['¡Take a picture!', '¡Library!', '¡Close!'] // buttonLabels
|
||||
);
|
||||
} else {
|
||||
navigator.notification.alert("Insert manual id or scan article", null, "Verdnatura says:", "¡ups!");
|
||||
|
@ -166,7 +173,7 @@ function scanBarcode() {
|
|||
'Article: ' + result.text, // message
|
||||
onConfirm, // callback to invoke with index of button pressed
|
||||
'Verdnatura says:', // title
|
||||
['¡Take a picture!', '¡Library!', '¡Other!'] // buttonLabels
|
||||
['¡Take a picture!', '¡Library!', '¡Close!'] // buttonLabels
|
||||
);
|
||||
|
||||
},
|
||||
|
@ -203,16 +210,36 @@ function onError() {
|
|||
}
|
||||
function showCamera() {
|
||||
var srcType = Camera.PictureSourceType.CAMERA;
|
||||
saveToPhotoAlbum = true;
|
||||
var options = setOptions(srcType);
|
||||
|
||||
var options = {
|
||||
saveToPhotoAlbum: true,
|
||||
quality: 80,
|
||||
destinationType: Camera.DestinationType.FILE_URI,
|
||||
sourceType: srcType,
|
||||
encodingType: Camera.EncodingType.JPEG,
|
||||
mediaType: Camera.MediaType.PICTURE,
|
||||
allowEdit: false,
|
||||
correctOrientation: true
|
||||
};
|
||||
|
||||
|
||||
|
||||
navigator.camera.getPicture(cameraSuccess, cameraError, options);
|
||||
|
||||
}
|
||||
function showLibrary() {
|
||||
var srcType = Camera.PictureSourceType.PHOTOLIBRARY;
|
||||
saveToPhotoAlbum = false;
|
||||
var options = setOptions(srcType);
|
||||
|
||||
var options = {
|
||||
saveToPhotoAlbum: false,
|
||||
quality: 80,
|
||||
destinationType: Camera.DestinationType.FILE_URI,
|
||||
sourceType: srcType,
|
||||
encodingType: Camera.EncodingType.JPEG,
|
||||
mediaType: Camera.MediaType.PICTURE,
|
||||
allowEdit: false,
|
||||
correctOrientation: true
|
||||
};
|
||||
navigator.camera.getPicture(cameraSuccess, cameraError, options);
|
||||
|
||||
}
|
||||
|
|
|
@ -34,13 +34,15 @@
|
|||
<div class="btnlogout"></div>
|
||||
<img id="logo" src="img/logo.png" alt="verdnatura"/>
|
||||
<br>
|
||||
<label>insert manual id:</label>
|
||||
|
||||
<div class="input">
|
||||
<img src="img/article.png" alt="verdnatura"/>
|
||||
<input type="text" id="txtarticle" placeholder="article id" value=""/>
|
||||
</div>
|
||||
<label>or scan id:</label>
|
||||
|
||||
<div class="btnbarcode">Scan</div>
|
||||
<div class="btnsalix">Salix</div>
|
||||
|
||||
<div class="btn loginbtn" id="btntakepicture">
|
||||
¡Go!
|
||||
</div>
|
||||
|
|