Skip to content

Commit c9da867

Browse files
author
JelteMX
committed
Adjust verification tabs
1 parent f33a5b6 commit c9da867

File tree

10 files changed

+1896
-1400
lines changed

10 files changed

+1896
-1400
lines changed

.eslintrc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ const base = require("./node_modules/@mendix/pluggable-widgets-tools/configs/esl
33
base["rules"]["@typescript-eslint/explicit-member-accessibility"] = "off";
44
base["rules"]["no-console"] = "warn";
55
base["rules"]["@typescript-eslint/member-ordering"] = "warn";
6+
base["rules"]["@typescript-eslint/no-empty-function"] = "warn";
67
base["rules"]["no-useless-call"] = "off";
78
base["rules"]["@typescript-eslint/ban-ts-ignore"] = "off";
89
base["rules"]["require-atomic-updates"] = "off";

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The Apache License v2.0
22

3-
Copyright Mendix 2019
3+
Copyright Mendix 2019-2020
44

55
Licensed under the Apache License, Version 2.0 (the "License");
66
you may not use this file except in compliance with the License.

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ We include the normal **POST** method (default) which will do a request to the M
6969

7070
### 3. Verification
7171

72-
![configuration3](/assets/configuration3.jpg)
72+
![configuration3a](/assets/configuration3a.png)
73+
![configuration3b](/assets/configuration3b.png)
7374

7475
Verification can be done in two ways:
7576

assets/configuration3.jpg

-231 KB
Binary file not shown.

assets/configuration3a.png

80.6 KB
Loading

assets/configuration3b.png

149 KB
Loading

package-lock.json

Lines changed: 1879 additions & 1389 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
22
"name": "filedropper",
33
"widgetName": "FileDropper",
4-
"version": "1.2.0",
4+
"version": "1.2.1",
55
"description": "Drop files in your Mendix Application",
6-
"copyright": "Mendix 2019",
6+
"copyright": "Mendix 2020",
77
"author": "Jelte Lagendijk",
88
"config": {
99
"widgetPath": "./dist/MxTestProject/widgets",
@@ -29,7 +29,7 @@
2929
},
3030
"license": "Apache-2.0",
3131
"devDependencies": {
32-
"@mendix/pluggable-widgets-tools": "^8.4.0",
32+
"@mendix/pluggable-widgets-tools": "^8.7.0",
3333
"@types/big.js": "^4.0.5",
3434
"@types/enzyme": "^3.1.10",
3535
"@types/enzyme-adapter-react-16": "^1.0.2",

src/FileDropper.xml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -81,22 +81,26 @@ Note 2: When using an Entity that is/inherits 'System.Image', Mime types will al
8181

8282
<!-- VERIFICATION -->
8383

84-
<propertyGroup caption="Verification">
84+
<propertyGroup caption="Verification after upload">
8585
<propertyGroup caption="On File object">
8686
<property key="verificationOnAcceptMicroflow" type="microflow" required="false" entityProperty="dataFileEntity">
8787
<caption>onAccept Mf</caption>
8888
<description>Microflow that will be called to determine if a file is accepted. If not, it should return a false. The Dropzone will remove the file by itself. This microflow will use the entity defined in 'Data'.
8989

90-
Note: This microflow is executed AFTER the file is uploaded. When doing big uploads, it is better to maybe also add a 'beforeAccept Nanoflow'.</description>
90+
Note: This microflow is executed AFTER the file is uploaded. When doing big uploads, it is better to maybe also add a verification before upload.</description>
9191
<returnType type="Boolean" />
9292
</property>
9393
</propertyGroup>
94+
</propertyGroup>
95+
<propertyGroup caption="Verification before upload">
9496
<propertyGroup caption="Verification Entity">
9597
<property key="verificationEntity" type="entity" required="false" allowNonPersistableEntities="true">
9698
<caption>Verification entity</caption>
97-
<description>This entity is used to verify the file BEFORE it is uploaded to the server. The widget will create an object and add the defined attributes. After the 'beforeAccept Microflow/Nanoflow' returns a true (boolean) value, the file itself will be committed and uploaded.
99+
<description>This entity is used to verify the file BEFORE it is uploaded to the server. The widget will create an object and add the defined attributes. After the 'beforeAccept Microflow/Nanoflow' returns an empty string value (this is the error message, empty when no error occurred), the file itself will be committed and uploaded.
98100

99-
Note: Only non-persistent entities are accepted.
101+
Note 1: Only non-persistent entities are accepted, as the widget will create/delete the object itself.
102+
Note 2: For this non-persistent entity, when applying Entity Access, give everyone permissions to create/delete this object, and read/write access on any attributes.
103+
Note 3: To avoid any other problem, make sure this helper object is detached from any other objects. It should be standalone and have zero references to others.
100104
</description>
101105
</property>
102106
</propertyGroup>
@@ -124,7 +128,7 @@ Note: Only non-persistent entities are accepted.
124128
</property>
125129
<property key="verificationSizeAttr" type="attribute" required="false" entityProperty="verificationEntity">
126130
<caption>Size attr.</caption>
127-
<description>Szse of the file in bytes.</description>
131+
<description>Size of the file in bytes.</description>
128132
<attributeTypes>
129133
<attributeType name="Long"/>
130134
</attributeTypes>

src/package.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8" ?>
22
<package xmlns="http://www.mendix.com/package/1.0/">
3-
<clientModule name="FileDropper" version="1.2.0" xmlns="http://www.mendix.com/clientModule/1.0/">
3+
<clientModule name="FileDropper" version="1.2.1" xmlns="http://www.mendix.com/clientModule/1.0/">
44
<widgetFiles>
55
<widgetFile path="FileDropper.xml"/>
66
</widgetFiles>

0 commit comments

Comments
 (0)