Compare commits
24 Commits
8d91dcdb43
...
ZugferdSer
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ae12ea21f2 | ||
|
|
124cfde45e | ||
|
|
c23a608b6a | ||
|
|
2fabdb90a5 | ||
|
|
0b36700ba1 | ||
|
|
4f75d7eb96 | ||
|
|
a8a9dd84eb | ||
|
|
40b8783af4 | ||
|
|
acaa2e7ad6 | ||
|
|
5ac28e2032 | ||
|
|
0e592de288 | ||
|
|
9623ce8191 | ||
|
|
a69712d94c | ||
|
|
52149cbeb8 | ||
|
|
c9fdf80936 | ||
|
|
b5feec77f7 | ||
|
|
84dab7f5a6 | ||
|
|
7b3dc1bf89 | ||
|
|
3d3a491744 | ||
|
|
322ca23f33 | ||
|
|
6ec458ccdf | ||
|
|
51c1f9f3f7 | ||
|
|
28d2e4241d | ||
|
|
33937a41d3 |
@@ -124,13 +124,13 @@
|
|||||||
<data name="btnPrint.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnPrint.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAFhSURBVEhLvVVBToRAEESNF/+kv+DChRsPICFwMfMFLwa9
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAFhSURBVEhLvVWxToRAEEWNjf+kf0FBRccHkBBozH6CjSHa
|
||||||
6MkHyB6NDzGEA1/Y7IaDOGPX7LQ7DBJmd8VKKlPd6e6a3oUQTCHPc0lUOIuiGJxMxEzT5gchxDkNUL44
|
aGVvuNL4IRIKvuFyFwpx13l7O96ySNi7E1/ysm8mM/N27iAEU8jzXBIVzqIoBicTMdO0+UEIcU4DlC8O
|
||||||
2CBJkstlDYS4WniDR72BlFIPsE8mx8BBBjfFSp1CM2YPcn+PougLT0Xf9+o6r4j3EsU4bW3n3BgabNtW
|
NkiS5HJZAyGuFt7gUW8gpdQD7JPJMXCQwU2xUqfQjNmD3N+jKPrCU9H3vbrOK+K9RDFOW9s5N4YG27bV
|
||||||
P11xHH9mWfYCg59H7y8NzMxeGzBhwIXHkv8T5tIbyIFB13VK3L1SQ6WLd2Z7befcGBq9TdNMG1RVpeq6
|
T1ccx59Zlr3A4OfR+0sDM7PXBkwYcOGx5P+EufQGcmDQdZ0Sd6/UUOnindle2zk3hkZv0zTTBlVVqbqu
|
||||||
lrgFVsVpazvnxtDoLctybLAkBxvMaTvnxlP6fzbQwgB66kZ2zo2nNAbqhE0u8oU7lDXeZnxYVpQYmYC+
|
JW6BVXHa2s65MTR6y7IcGyzJwQZz2s658ZT+nw20MICeupGdc+MpjYE6YZOLfOEOZY23GR+WFSVGJqAv
|
||||||
+K2X2BMfzA8zBooYz28f6skhcgzcFh8p0+oH22AOJxvMbYDaMAwvTKsf3A3cN5dj4NgN1qZ/Fmmabqnl
|
fusl9sQH88OMgSLG89uHenKIHAO3xUfKtPrBNpjDyQZzG6A2DMML0+oHdwP3zeUYOHaDtemfRZqmW2o5
|
||||||
bNfpCboVeRRrbDLDDfHWtDkIgm9JZN4hj8l62wAAAABJRU5ErkJggg==
|
23V6gm5FHsUam8xwQ7w1bQ6C4BuAm93DSGjZ/gAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnFitWidth.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnFitWidth.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
@@ -154,42 +154,42 @@
|
|||||||
<data name="btnMouseMode.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnMouseMode.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHASURBVEhLnZM9LwRRGIU38VVp/AHRahQaZGaEyg+gIqHS
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHASURBVEhLnZM9LwRRGIU38VVp/AFqjUKDzIxQ+QE0IqHS
|
||||||
iAhhZ0ShIDQSEYmWkiXB3I34KGhIiCyFWoKSjpAQrnvGu8nEPWtmPcmTm7nvPWd2Z3cypejpyVU4fr7P
|
iAhhZ0ShIDQSEVFTsiSYuxEfBQ0JkaVQS1DSERLCdc94N5m4Z82sJ3lyM/e958zu7E6mFD09uQrHz/e5
|
||||||
DVToZdV9Q//qhxcoPZe70lija7OPOc7hvESTaRndr3Oy6gxFv906vbX2IM4jJxV/Yz7VHivpnj/SsxuF
|
gQq9rLpv6F/98AKl53JXGmt0bfYxxzmcl2gyLaP7dU5WnaHot1unt9YexHnkpOJvzKfaYyXd80d6dqMQ
|
||||||
aGVz5KSiNN6kclkYPr+9a4CVzSNNXqo4nh8u06AxDptHmrxUcZwJdUGDxjhsDpGXKo4zpp5YEMZhc4i8
|
rWyOnFSUxptULgvD57d3DbCyeaTJSxXH88NlGjTGYfNIk5cqjjOhLmjQGIfNIfJSxXHG1BMLwjhsDpGX
|
||||||
VHG8XvXJgjAOm0eavFTZtE8fV9KQsXMqr69vn/SL+YGx4pqdg1Jn0zx4WcUCcbOr53S/aLtR6myKNzgo
|
Ko7Xqz5ZEMZh80iTlyqb9unjShoydk7l9fXtk34xPzBWXLNzUOpsmgcvq1ggbnb1nO4XbTdKnU3xBgeF
|
||||||
PPzL/MVddBOps2HfAI+if/FE+2vnema9oOc3r6IV19hnj0rqbNI8ojRKnU3jdK6aBcpV6my6hvdqWKBc
|
h3+Zv7iLbiJ1Nuwb4FH0L55of+1cz6wX9PzmVbTiGvvsUUmdTZpHlEaps2mczlWzQLlKnU3X8F4NC5Sr
|
||||||
pc7m52+68sVC6V35kjrOX29yGhPfZCdQhyyYVuSliuP64RALphV5qeK0TezUtgbqkYWTRA55qSqN6+8O
|
1Nn8/E1XvlgovStfUsf5601OY+Kb7ATqkAXTirxUcVw/HGLBtCIvVZy2iZ3a1kA9snCSyCEvVaVx/d0B
|
||||||
sIIkkZOKZFxfLbGSUuK8RNPjBuF408j2GyssijnOSaR8Oqby9U4QLpiyG+NrzBvsYy5HCZnMN4QSuH4A
|
VpAkclKRjOurJVZSSpyXaHrcIBxvGtl+Y4VFMcc5iZRPx1S+3gnCBVN2Y3yNeYN9zOUoIZP5Bl9auHhV
|
||||||
HIXWAAAAAElFTkSuQmCC
|
DRJiAAAAAElFTkSuQmCC
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnFirstPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnFirstPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGiSURBVEhLxVTLSsNAFB3UrkVRXLp324VCMglIf0CkKIq4
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGgSURBVEhLxVRLS8NAEF7UnkVRPHr32oNCsgmof0CkKIp4
|
||||||
69pXMlNEoiCin+DKvSg2M6UILvwBUVDUfxB8bn3mpjc6TNKalFYPXHJzH+fMvSRDOoHxsj+EbnsBxJSJ
|
69lXs1tEgiCiP8GTd1FsdksRPPgHREFR/4Pg8+oz005w2KY1Ka1+MGQyj+/bGZJlncB4MRhCt70AYi7U
|
||||||
HeoePmOIEIvLT9WG5/deMZUa9pIYoFxsG1w8RTyYIoQy7wMMgvDMImCWa4MmE1tB74vOgyWtCQAxZXJz
|
LveOXjDEmCP1F7Xhxf03TCWGu6IGuFQ7llTPEQ+mGOPC/wSDIDzTCNjFyqAt1HbY+2ryYElrAkDMhd4a
|
||||||
lIlHtVf1sTTbikxe7QNia+HgQe/TDVvSTTC2eNxPXX/DYPUdq/WNfGxtLhCemMs1yvx7vS61AARUiwQs
|
FeqJ9lIfS9OtyJblPiB2lg4fzT7TsCXZBGPLJ/3cCzYtUdsxrW/kY2tzgeqJpd7gIngw6xILQIBaJOBI
|
||||||
Llat5cqdnk9rITkgdoqCeIcdx+LauxpP8pE+QaCJr77/Vo/0fyAAgU4Y0v/DBCNcvgV3yqUez2pIn/wf
|
te6slu7NfFKrkgPqTjGhPmDHdXHjncbjfKSPEWji0/ff6pH+DwQg0AlD+n+YYETq9/BOuTLjaQ3p4/+D
|
||||||
FNhJr8HkhOGIc4uvf59erYuejXykTxbAFCkW97uD63cy+NEu9LrUAhBQLemqsL3THptXi1lWh63NJ4jB
|
SXHaawk9ZRXUhSN/Tk/romcjH+njBTDFcrmD7vD6nQ5/tEuzLrEABKjFXRWuf9bjynIuzeqwtfkEdfD9
|
||||||
87qCe3/KWAGhn9VFvaqPHRkFEDCR6cpp061cqb2qj6XpVtQI+dJZznLFjMH9G50HS1qbQEf4MThylrri
|
rvDen7HWQKjWR3upjx0pBRAwke3pWdsrXdNe6mNpshU1QjZ/nnE8NWfJ4NbkwZLWJjBR/RgKep576iZa
|
||||||
OlodptqLfGk3Z3MxZzpHtxjqDGB1dY+QL9R3Ku125ioXAAAAAElFTkSuQmCC
|
Habai2x+L+NKtWAXju8w1BnA6moeY9/IuSrpVj3aVAAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnPreviousPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnPreviousPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHLSURBVEhLY6AZqK9ngrKoC4zTzrDalG0OsS3bdAIqRB1g
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHKSURBVEhLY6AZqK9ngrKoC4zTzrDalG0OsS3bdAIqRB1g
|
||||||
X7+fw7Z8U4pdxeYbQPwfhKFSlAH7/PUCduWbyy1KNz2zLa//BzIYRIMwVAl5wKlqszTQxZ02RZveIBtK
|
X7+fw7Z8U4pdxeYbQPwfhKFSlAH7/PUCduWbyy1KNz2zLa//BzIYRIMwVAl5wKlqszTQxZ02RZveIBtK
|
||||||
sQU2FVvV7Mo2T7esWPsFFhS4MFQLMeA/o1XpBhOb8k0rtSo2/0F3KS42VDMeAExq9hVbXGzLN+yxddn0
|
sQU2FVvV7Mo2T7esWPsFFhS4MFQLMeA/o1XpBhOb8k0rtSo2/0F3KS42VDMeAExq9hVbXGzLN+yxdd70
|
||||||
F9kAiiwIDV3FbFuxKdymdPMpO9fNf0GayMFQ4xDAtXgnNzD9ptuVbryJzUXIfGRxXGyosQwMFoU7hIAp
|
F9kAiiwIDV3FbFuxKdymdPMpO5fNf0GayMFQ4xDAtXgnNzD9ptuVbryJzUXIfGRxXGyosQwMFoU7hIAp
|
||||||
ohSIn+LTgMzHpQaZDTbctnxjg23BmnfEaEDmE6MebIFdxZY064rN9+0qGsCS1MRgC0DAI3cbu33Fplib
|
ohSIn+LTgMzHpQaZDTbctnxjg23BmnfEaEDmE6MebIFdxZY064rN9+0qIJLUxGALQMAjdxu7fcWmWJuy
|
||||||
sg2X8bkImY9LDTIbajwCAMsTFpvKTQHAjHQEpJBSDDUWO7Ar3eBoXb5xh3z8/N8wFyG7EEbjY0ONwg/s
|
DZfxuQiZj0sNMhtqPAIAyxMWm8pNAcCMdASkkFIMNRY7sCvd4GhdvnGHfPz83zAXIbsQRuNjQ43CD+zK
|
||||||
yjcY2pRtXGGbteknsgFUswAGgEWFum355qn6+eu/gwwhBkO1kgZsq7ZLgkpRu4qNb7G5GpkN1UIesKnY
|
NxjalG1cYZu16SeyAVSzAAaARYW6bfnmqfr567+DDCEGQ7WSBmyrtkuCSlG7io1vsbkamQ3VQh6wqdgi
|
||||||
ImhbtrESVA/QxAIYABUvoLxkV7LhLshwZAxVQh0ASuK2pZujgbXbWar6AAMAi3ig672sSzcdhIrQCvxn
|
aFu2sRJUD9DEAhgAFS+gvGRXsuEuyHBkDFVCHQBK4ralm6OBtdtZqvoAAwCLeKDrvaxLNx2EitAK/Gdk
|
||||||
ZGBgYAAAYx2H2ukKpvoAAAAASUVORK5CYII=
|
YGBgAABSZ4fXERBsXgAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnNextPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnNextPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
@@ -197,44 +197,44 @@
|
|||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHCSURBVEhLYwCD+nomCINGwLZs0wmbss0hxmlnWKFC1AV2
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHCSURBVEhLYwCD+nomCINGwLZs0wmbss0hxmlnWKFC1AV2
|
||||||
FZv/Q/EN2/JNKfb1+zmgUtQBtuX1/0AYZAmItijd9MyufHO5ff56AagSygC6BTC2TdGmN0AfdTpVbZaG
|
FZv/Q/EN2/JNKfb1+zmgUtQBtuX1/0AYZAmItijd9MyufHO5ff56AagSygC6BTC2TdGmN0AfdTpVbZaG
|
||||||
KiUPQIMHJ7asWPvFrmzzdJuKrWpQLaQBXD5AZ2tVbP5jU75ppVXpBhMGhv+MUO2EAT5DkdlwMZdNf23L
|
KiUPQIMHJ7asWPvFrmzzdJuKrWpQLaQBXD5AZ2tVbP5jU75ppVXpBhMGhv+MUO2EAT5DkdlwMedNf23L
|
||||||
N+yxr9jiQlQSB2kkC7tu/mtTuvmUbcWm8NDQVcxQ4zABuktxsZHF0Pl2pRtvAvNTumvxTm6osQiAVQOp
|
N+yxr9jiQlQSB2kkC7ts/mtTuvmUbcWm8NDQVcxQ4zABuktxsZHF0Pl2pRtvAvNTumvxTm6osQiAVQOp
|
||||||
FsDZm54CcalF4Q4hqPHUtgDKLljzzrZ8YwPYApAAdXHDP+uKzfftKrakgS3A6Qo0NrIYOh/GtinbcNm+
|
FsDZm54CcalF4Q4hqPHUtgDKLljzzrZ8YwPYApAAdXH9P+uKzfftKrakgS3A6Qo0NrIYOh/GtinbcNm+
|
||||||
YlOsR+42drDhIACSpBiXbT5iU7kpAFiOsUCNRQB8LkJmI4uBsHz8/N/W5Rt32JVucIQahR3ANBBtQdam
|
YlOsR+42drDhIACSpBiXbT5iU7kpAFiOsUCNRQB8LkJmI4uBsHz8/N/W5Rt32JVucIQahR3ANBBtQdam
|
||||||
nzZlG1fYlW8whBqBH4A0EoP189d/ty3fPBVYVKhDtRIH0F2Kyd74FlSq2lZtl4RqIQ1gN3Tzf1C9YFu2
|
nzZlG1fYlW8whBqBH4A0EoP189d/ty3fPBVYVKhDtRIH0F2Kyd74FlSq2lZtl4RqIQ1gN3Tzf1C9YFu2
|
||||||
sdKmYosgVCl5AGQYCi7ZcBeUhrFme3IA3NXlm8/alm6OxprUKAHWpZsOAl3uRcPWBQmVB0mAgQEA9b+H
|
sdKmYosgVCl5AGQYCi7ZcBeUhrFme3IA3NXlm8/alm6OxprUKAHWpZsOAl3uRcPWBQmVB0mAgQEA5X2H
|
||||||
2hvhANgAAAAASUVORK5CYII=
|
142IlcMAAAAASUVORK5CYII=
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnLastPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnLastPage.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAFxSURBVEhLY4ABp8qN4lAmbYBt2dqPtuWbOmlmkV3F5v8g
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAFwSURBVEhLY4ABp8qN4lAmbYBt2dqPtuWbOmlmkV3F5v8g
|
||||||
bF2x6YNtxaYO+6JNIlApooF8/PzfMHNgGCoF9EF5/T+QAIiGsj/ZlG9qs6ncJgpVQhCALEA3ByqF1QIw
|
bF2x6YNtxaYO+6JNIlApooF8/PzfMHNgGCoF9EF5/T+QAIiGsj/ZlG9qs6ncJgpVQhCALEA3ByqF1QIw
|
||||||
27x803vb8s0txFiE1wKQIF5csOYd2KKKLYJQLRiA1CDCYINo63JgHJVtbLQo3CEE1QoHZAURMhtZzLZ8
|
27x803vb8s0txFiE1wKQIF5csOYd2KKKLYJQLRiA1CDCYINo63JgHJVtbLQo3CEE1QoHZAURMhtZzLZ8
|
||||||
41vbis21yD6iLIhw4eINr+wqNlWDzKBKEMHE0PngOHLZ9BddHGo8FSzAwYYaTwcLQIK0wFDjh4APgGXY
|
41vbis21yD6iLIhw4eINr+wqNlWDzKBKEMHE0PngOHLe9BddHGo8FSzAwYYaTwcLQIK0wFDjh4APgGXY
|
||||||
Ja2KzX/QxaHGk+uDhn/WpZvOWZdvDnQp381P7Yx2Hli8B4eGrmKGGkGdjAYKCvuKLaH29ftZoFrhgIKM
|
Ja2KzX/QxaHGk+uD+n/WpZvOWZdvDnQp381P7Yx2Hli8B4eGrmKGGkGdjAYKCvuKLaH29ftZoFrhgIKM
|
||||||
BgyKkk2XgPVEOEN9PRNUCwYgK4hsyjZctinbHIHNxeiApCCyrth4za5sU5Rx2hlWqBKCgIggavhnW7bp
|
BgyKkk2XgPVEOEN9PRNUCwYgK4hsyjZctinbHIHNxeiApCCyrth4za5sU5Rx2hlWqBKCgIggAtpatumq
|
||||||
qm3p5mjkyCMW4PWBTen66/YVm2KN02YS7WKSAClBQTxgYAAAiC0q7TAw7UYAAAAASUVORK5CYII=
|
benmaOTIIxbg9YFN6frr9hWbYo3TZhLtYpIAKUFBPGBgAAB8byrpVSoE5AAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnZoomOut.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnZoomOut.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAMESURBVEhLtVXfS5NRGA6KLuqiKCSCqIsi6Da69qL+Bm/S
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAMESURBVEhLtVVdS1RRFA2KHuqhKCSCqIci6DV69qF+gy9p
|
||||||
kOmmc2oT50DL7bOEwLAwKbFQK60M6qIfhCPKkiAQ1qJY2tymLSNKrNSkltl3et597/l2PudQkx54fc+P
|
iDrqfDiNOA5oOXMtQTAsTEos1Eorg3rog1CiLAkC0TGKSaeZUaaMKLFSk5psuqe15+5zPXdGUZMWbPf5
|
||||||
5zzP+x79jmuyweVy7SopKfE6HI4HyNHS0tIJjOOIh5jX2+32vUxdGWw2Ww4ELuXn5ychqlM4nU6hZo45
|
WGetvY/e47ql4HQ695SUlPiKi4sfIkdLS0snMR5DPMK8xmaz7Wfq6lBQUJAFgcu5ubkJiOoUdrtdqJlj
|
||||||
xHUY7eCjSwPCByCSIKHlRlFR0WfkgyyRHWh9P6qZlhXSYc6zmnbq3ZnzbeNNTS0fab6QQ92iuEMslYni
|
HnEDRrv46PKA8CGIvCOhlUZhYeFn5MMssTTQ+kFUMyMrpMOc5zStPn72QstEQ0PTR5qnc6hbFHeEpTJR
|
||||||
4uItII7KAxQVFRWTTwcGPo1Eo7pQMDo6poffDAm32/1T5SMmYLKTJa0AsYXIMrxe74dwODxPgolEwmIg
|
VFS0DcRxeYCirKxs6ll//6e3kYguFIyNjeuhNyPC4/H8VPmISZjsZkkrQGwisgyfz/chFAolSTAej1sM
|
||||||
57FYTG9vb/+jnkPcZMk0Kisrc+CeaptI5eXlUyROQktFPB7XNU0zr6uwsPB3WVnZPpY2gA07t5gi3ekL
|
5Dwajeqtra1/1HOIWyy5ALfbnQX3VNtEcrlc0yROQstFLBbTNU0zrys/P/+3w+E4wNIGsGHjFlOkuz29
|
||||||
TNDhVLmAOibIucwj0ZjZAWngmjSWNoCFbkmA+6+Z77MW0aUMdPxsOHHSNIHeY5Y2gMXnsoPq6rpJOphb
|
k3Q4VS6gjglyLnMkGjM7IA1ck8bSBrDQKQlw/zX7fc4iupyBjp+1p06bJtB7wtIGsPhCdlBRUT1FB7Or
|
||||||
e0/k1t5HUFbH6poxJ37X1WtmB4hxljYAx1fSAPc5SVVlimU3IPTevqsafGNpA9h4Jg3qjh2f+ZcOOq90
|
7ovsqgcIyupYXTPmxO+4dt3sADHB0gbg+Eoa4D6nqKpMsaUNCN137qkG31jaADaeS4PqEydn/6WD9qud
|
||||||
mwb4nt6ztAFsdNAmBd6f+anpGcu9q2OCnMus45fg82up8xyPWNoAFg7LDojQFwisyGBoeNgUJw1ceT1L
|
pgG+p/csbQAbbbRJgfcnOT0za7l3dUyQc5l1/BL8AS11nuMxSxvAwlHZARF6entXZTAyOmqKkwauvIal
|
||||||
G8DCJmx+kaSqqqr5YDC4LINkMikaGxtNA8QcbmEPS6cBZ7/sgLLP59NDodCiH5eMSCSit7a2mpVz7mFJ
|
DWBhCza/SFJ5eXlycHBwRQaJRELU1dWZBoh53MI+ll4AnAOyA8p+v18PBoOLflwywuGw3tzcbFbOuYsl
|
||||||
K9DFBvprkmQKj8cj+vufiOG3EUsHMXy9wRch4ff7TXFpgF/wIF6CrSxrBTZ3g0SvpdqyOOp2i6bTzeLC
|
rUAXm+ivSZIpvF6v6Ot7iisIWzqI4usdCg6LQCBgiksD/IIH8BJsZ1krsLkXJHot1ZbFcY9HNJxpFBcv
|
||||||
xQ7RfPac8NTU0Adp4aiBQoP0eLKsFWRCnciK1OpkyLXFOHIMnRD942JZKwoKCjaC1ADC14WHVRFU+QO5
|
tYnGc+eFt7KSPkgLRw0UOkSPJ8taQSbUiaxIrU6GXFuMI8fQGaZ/XCxrRV5e3maQakH4mn5YFUGVP5Bb
|
||||||
DWK3Fu7x+CU421g2E3jvN4N4BMQuZHpOwsiD6LAXYxeEtxMvLy9vPdZvkOgi8ToltlrAZC1MexAZ18WU
|
IHY7fY/HL8HZwbKZwHu/FcRjIHYg03MSQh5Ah90YOyG8k3g5OTkbsX6TRBeJ1ymxtQIm62Hahci4Lqas
|
||||||
1QPv2Dp0d/m/GRDYpDN9RU7xF2LPJg/FhemBAAAAAElFTkSuQmCC
|
HXjHNqC7K//NgMAm7QtXZBd/AWaMJXnjHFh9AAAAAElFTkSuQmCC
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="btnZoomIn.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnZoomIn.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
@@ -307,19 +307,19 @@
|
|||||||
<data name="btnSettings.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="btnSettings.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAALCSURBVEhLpVY9aBRBFD5ECxstFLVSq1NOyM9tFptgGsXG
|
YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAALDSURBVEhLpVY9aFNRFA6ig4sOijqpU5QI/XsNLsUsiouD
|
||||||
QtDmVEyXKHe3OzN7qIVwaKGVCEYQsZCgESLZ272ItmJjGgsTLSwCacTGRoVEiDHr++benOPeXTwuHzzm
|
oEP8wW6tkuS9e+8L6lAIOugkghVEHKRohUpe3ktFV3Gxi4OtDg6FLuLiokIr1Jjn+W7Ojdf81JB+cLjn
|
||||||
vW/e+96bmT24jEHenznJroYro+DA6ONfxF9mqnc43sxTR4SJo+JpxAMy7HdVnIDLiXBNJ20Gg8VnPyDY
|
fPec75x77wskYTDilU+yq5GWoX9g/PEv4q8w1T8ct/zUEUHsqGgO8ZAMBtMqisGlRFDTSZvBcO7ZDwh2
|
||||||
zoZk/IjTesdRr74X00IQa74cfmz6IpzgtM3BNBgoT+d0fPX5TnANPiqPVF9v1Ym9wPFm90M8p+IVpjTo
|
slEZPeK0/nHUre7FtBDEOlIIPjZ9EUxz2uZgGgwV5lI6vvZ8J7gGHxYypddbdWI/cNz5/RBPqWiNKQ16
|
||||||
Td6DNzYk4uO81T0cGY3/nTRO8l7tFHhX1I80+CgZUnW6qigZDOJj2As8zxVCJEqphNYb4DqCplyyG2DN
|
k/fgjY2K6Dhv9Q5HhpN/J43iEbdyCnxaVI80+DAeVVW6qjAe9qNj2PNdNy2EiJVSMa03wHUFTbliN8Ca
|
||||||
iqnlhh8lrh++HFFPJofF1K0R9XA3aqTvj1sNXmihTnBU/YQ+vqpN0rd/H34jpvdQ8QJyrqjSmpTyjS4g
|
FLOrDT+M017wMqOezIyJ2VsZ9XA3aqTnTVoNXmihbnBU9YQ+vqrM0Ld/H34jpvdQ0RJyrqp8TUr5RhcQ
|
||||||
kHAMcVipVPrKNPgCOMrtZ6oV+A3gFGjgiplXSpSWlZKJ1BPLNayYvlAo/IYYfD7NnOUnvu8fYslW4MeF
|
SDiCOCyfz39lGvw5cJQ7yFQ78BvAKdAgLcqvlMivKiVjqSeWNayYPpvN/oYYfD7NguXHnucdYsl24MeF
|
||||||
Bo4fzV0S10YDamAL0oTrJsZK3Lrlo8FnlmqPPlXL9gXhHg4zJDhvJjMiJsZqNV9HXCwWd3Fpd8AVQSBl
|
Bo4XLlwW18d9amAL0oR1E2Mlrm75aPCZpTpjQFWSA36wh8MECS6ayYyIibFazeuIc7ncLi7tDbgiCLTY
|
||||||
EyR2h9bVFJ9w2caQ0rtAAnfJ5lFkTblarVa3cJqG53nfTA5OQP5begNB/DCntAIFHazluyeumMppGqe0
|
NIndoXW9hY+5bGNI6V4kgbtkiyiyplwvlUpbOE3Ddd1vJgcnIP8tvYEgfoxT2oGCLtb23ROXa8lpGqe0
|
||||||
ApuYhieyT1DhlCZo2osmx8rTximtoIc9Q4W36ZgLdgN6wC+c0gQJfTI5EMWVkc1S/XVO6QzcN4ptI5HF
|
A5uYhieyT1DklCZo2ksmx8rTxintoIc9Q4W36ZhLdgN6wC+c0gQJfTI5EMWVkc1T/RSndAfuG8W2kciy
|
||||||
IAjOkn+aBvmQ3qe95hfYFWiSn5gMxWZKE2NNXct3LusOVFA3wmY1ZsfGRxM61U0u3xjlcnkHCi1bScUd
|
7/tnyT9Ng3xo3ae95hfYE2iSn5gMxWZKE2NtuZbvXNYbqKBqhM1qzI6NjyZ0qptcvjEKhcIOFFq21hJ3
|
||||||
jZpsZ5mNQclZFNA1PUBcqVT20ZSLmBQ8rUu0dxB75L9j/p8/EP/F2NjYNnY1SAQ/QN2AxO8xrUHcYXZ7
|
NWqynWU2BiUnUUDX9ABxsVjcR1MuY1LwtK7Q3kHskf+O+X/+QPwXExMT29jVIBH8AHUDEr/HtAZxh9nt
|
||||||
Bx3/HMTZzjPdBpnMH4dZZEWrsYs7AAAAAElFTkSuQmCC
|
H3T88xBnu8B0ByQSfwCqJWQA7REYAQAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<metadata name="OpenFileDialog.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="OpenFileDialog.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ Imports Independentsoft.Msg
|
|||||||
Imports DevExpress.Spreadsheet
|
Imports DevExpress.Spreadsheet
|
||||||
Imports GdPicture14
|
Imports GdPicture14
|
||||||
Imports DevExpress
|
Imports DevExpress
|
||||||
|
Imports DevExpress.Office.Utils
|
||||||
|
|
||||||
Public Class DocumentViewer
|
Public Class DocumentViewer
|
||||||
Private Enum ZoomMode
|
Private Enum ZoomMode
|
||||||
@@ -535,4 +536,10 @@ Public Class DocumentViewer
|
|||||||
MagnifierToolStripMenuItem.Checked = True
|
MagnifierToolStripMenuItem.Checked = True
|
||||||
GdViewer.Focus()
|
GdViewer.Focus()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub RichEditControl1_SizeChanged(sender As Object, e As EventArgs) Handles RichEditControl1.SizeChanged
|
||||||
|
Dim oControlWidth = RichEditControl1.Width - 100
|
||||||
|
Dim oPageWidth = Units.DocumentsToPixelsF(RichEditControl1.Document.Sections(0).Page.Width, RichEditControl1.DpiX)
|
||||||
|
RichEditControl1.Views.PrintLayoutView.ZoomFactor = oControlWidth / oPageWidth
|
||||||
|
End Sub
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -78,7 +78,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="PresentationCore" />
|
<Reference Include="PresentationCore" />
|
||||||
<Reference Include="PresentationFramework" />
|
<Reference Include="PresentationFramework" />
|
||||||
|
|||||||
@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
|
|||||||
' übernehmen, indem Sie "*" eingeben:
|
' übernehmen, indem Sie "*" eingeben:
|
||||||
' <Assembly: AssemblyVersion("1.0.*")>
|
' <Assembly: AssemblyVersion("1.0.*")>
|
||||||
|
|
||||||
<Assembly: AssemblyVersion("1.0.1.0")>
|
<Assembly: AssemblyVersion("1.0.2.0")>
|
||||||
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
|
|||||||
' übernehmen, indem Sie "*" eingeben:
|
' übernehmen, indem Sie "*" eingeben:
|
||||||
' <Assembly: AssemblyVersion("1.0.*")>
|
' <Assembly: AssemblyVersion("1.0.*")>
|
||||||
|
|
||||||
<Assembly: AssemblyVersion("1.0.2.1")>
|
<Assembly: AssemblyVersion("1.0.2.2")>
|
||||||
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
||||||
|
|||||||
@@ -157,9 +157,19 @@ Public Class frmLookupGrid
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub gridLookup_KeyUp(sender As Object, e As KeyEventArgs) Handles gridLookup.KeyUp
|
Private Sub gridLookup_KeyUp(sender As Object, e As KeyEventArgs) Handles gridLookup.KeyUp
|
||||||
|
HandleCustomKeys(e)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub gridLookup_EditorKeyUp(sender As Object, e As KeyEventArgs) Handles gridLookup.EditorKeyUp
|
||||||
|
HandleCustomKeys(e)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub HandleCustomKeys(e As KeyEventArgs)
|
||||||
If e.KeyCode = Keys.Escape Then
|
If e.KeyCode = Keys.Escape Then
|
||||||
Close()
|
Close()
|
||||||
ElseIf e.KeyCode = Keys.F2 Then
|
ElseIf e.KeyCode = Keys.F2 Then
|
||||||
|
' Make sure the currently focused row's state is saved
|
||||||
|
viewLookup.PostEditor()
|
||||||
SaveSelectedValues()
|
SaveSelectedValues()
|
||||||
|
|
||||||
DialogResult = DialogResult.OK
|
DialogResult = DialogResult.OK
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -49,7 +49,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
@@ -125,9 +125,7 @@
|
|||||||
<CustomToolNamespace>My</CustomToolNamespace>
|
<CustomToolNamespace>My</CustomToolNamespace>
|
||||||
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||||
</None>
|
</None>
|
||||||
<None Include="packages.config">
|
<None Include="packages.config" />
|
||||||
<SubType>Designer</SubType>
|
|
||||||
</None>
|
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\Modules.Database\Database.vbproj">
|
<ProjectReference Include="..\Modules.Database\Database.vbproj">
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -27,11 +27,10 @@ Public Class ThreadRunner
|
|||||||
|
|
||||||
Private Const TIMER_INTERVAL_MS = 10_000
|
Private Const TIMER_INTERVAL_MS = 10_000
|
||||||
|
|
||||||
Public Sub New(LogConfig As LogConfig, GDPictureKey As String, Firebird As Firebird, Optional MSSQL As MSSQLServer = Nothing)
|
Public Sub New(LogConfig As LogConfig, Firebird As Firebird, Optional MSSQL As MSSQLServer = Nothing)
|
||||||
_logConfig = LogConfig
|
_logConfig = LogConfig
|
||||||
_logger = _logConfig.GetLogger()
|
_logger = _logConfig.GetLogger()
|
||||||
_firebird = Firebird
|
_firebird = Firebird
|
||||||
_zugferd = New ZUGFeRDInterface(_logConfig)
|
|
||||||
_mssql = MSSQL
|
_mssql = MSSQL
|
||||||
|
|
||||||
Dim args As New WorkerArgs()
|
Dim args As New WorkerArgs()
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
11
EDMI.File/Archive.vb
Normal file
11
EDMI.File/Archive.vb
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
|
||||||
|
Public Class Archive
|
||||||
|
Private _LogConfig As LogConfig
|
||||||
|
Private _Logger As Logger
|
||||||
|
|
||||||
|
Public Sub New(LogConfig As LogConfig)
|
||||||
|
_LogConfig = LogConfig
|
||||||
|
_Logger = LogConfig.GetLogger()
|
||||||
|
End Sub
|
||||||
|
End Class
|
||||||
120
EDMI.File/EDMI.File.vbproj
Normal file
120
EDMI.File/EDMI.File.vbproj
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
|
<ProjectGuid>{1477032D-7A02-4C5F-B026-A7117DA4BC6B}</ProjectGuid>
|
||||||
|
<OutputType>Library</OutputType>
|
||||||
|
<RootNamespace>DigitalData.Modules.EDMI.File</RootNamespace>
|
||||||
|
<AssemblyName>DigitalData.Modules.EDMI.File</AssemblyName>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<MyType>Windows</MyType>
|
||||||
|
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||||
|
<Deterministic>true</Deterministic>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<DefineDebug>true</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DocumentationFile>DigitalData.Modules.EDMI.File.xml</DocumentationFile>
|
||||||
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<DefineDebug>false</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DocumentationFile>DigitalData.Modules.EDMI.File.xml</DocumentationFile>
|
||||||
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionExplicit>On</OptionExplicit>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionCompare>Binary</OptionCompare>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionStrict>Off</OptionStrict>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionInfer>On</OptionInfer>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Configuration" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.IO.Compression" />
|
||||||
|
<Reference Include="System.Runtime.Serialization" />
|
||||||
|
<Reference Include="System.ServiceModel" />
|
||||||
|
<Reference Include="System.Transactions" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="System.Net.Http" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Import Include="Microsoft.VisualBasic" />
|
||||||
|
<Import Include="System" />
|
||||||
|
<Import Include="System.Collections" />
|
||||||
|
<Import Include="System.Collections.Generic" />
|
||||||
|
<Import Include="System.Data" />
|
||||||
|
<Import Include="System.Diagnostics" />
|
||||||
|
<Import Include="System.Linq" />
|
||||||
|
<Import Include="System.Xml.Linq" />
|
||||||
|
<Import Include="System.Threading.Tasks" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="Archive.vb" />
|
||||||
|
<Compile Include="My Project\AssemblyInfo.vb" />
|
||||||
|
<Compile Include="My Project\Application.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Application.myapp</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="My Project\Resources.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DesignTime>True</DesignTime>
|
||||||
|
<DependentUpon>Resources.resx</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="My Project\Settings.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Settings.settings</DependentUpon>
|
||||||
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
|
</Compile>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<EmbeddedResource Include="My Project\Resources.resx">
|
||||||
|
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
|
||||||
|
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</EmbeddedResource>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="My Project\Application.myapp">
|
||||||
|
<Generator>MyApplicationCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Application.Designer.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<None Include="My Project\Settings.settings">
|
||||||
|
<Generator>SettingsSingleFileGenerator</Generator>
|
||||||
|
<CustomToolNamespace>My</CustomToolNamespace>
|
||||||
|
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<None Include="packages.config" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\Modules.Logging\Logging.vbproj">
|
||||||
|
<Project>{903B2D7D-3B80-4BE9-8713-7447B704E1B0}</Project>
|
||||||
|
<Name>Logging</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||||
|
</Project>
|
||||||
13
EDMI.File/My Project/Application.Designer.vb
generated
Normal file
13
EDMI.File/My Project/Application.Designer.vb
generated
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
'------------------------------------------------------------------------------
|
||||||
|
' <auto-generated>
|
||||||
|
' Dieser Code wurde von einem Tool generiert.
|
||||||
|
' Laufzeitversion:4.0.30319.42000
|
||||||
|
'
|
||||||
|
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||||
|
' der Code erneut generiert wird.
|
||||||
|
' </auto-generated>
|
||||||
|
'------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Option Strict On
|
||||||
|
Option Explicit On
|
||||||
|
|
||||||
10
EDMI.File/My Project/Application.myapp
Normal file
10
EDMI.File/My Project/Application.myapp
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<MyApplicationData xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
|
||||||
|
<MySubMain>false</MySubMain>
|
||||||
|
<SingleInstance>false</SingleInstance>
|
||||||
|
<ShutdownMode>0</ShutdownMode>
|
||||||
|
<EnableVisualStyles>true</EnableVisualStyles>
|
||||||
|
<AuthenticationMode>0</AuthenticationMode>
|
||||||
|
<ApplicationType>1</ApplicationType>
|
||||||
|
<SaveMySettingsOnExit>true</SaveMySettingsOnExit>
|
||||||
|
</MyApplicationData>
|
||||||
35
EDMI.File/My Project/AssemblyInfo.vb
Normal file
35
EDMI.File/My Project/AssemblyInfo.vb
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
Imports System
|
||||||
|
Imports System.Reflection
|
||||||
|
Imports System.Runtime.InteropServices
|
||||||
|
|
||||||
|
' Allgemeine Informationen über eine Assembly werden über die folgenden
|
||||||
|
' Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern,
|
||||||
|
' die einer Assembly zugeordnet sind.
|
||||||
|
|
||||||
|
' Werte der Assemblyattribute überprüfen
|
||||||
|
|
||||||
|
<Assembly: AssemblyTitle("EDMI.File")>
|
||||||
|
<Assembly: AssemblyDescription("")>
|
||||||
|
<Assembly: AssemblyCompany("")>
|
||||||
|
<Assembly: AssemblyProduct("EDMI.File")>
|
||||||
|
<Assembly: AssemblyCopyright("Copyright © 2020")>
|
||||||
|
<Assembly: AssemblyTrademark("")>
|
||||||
|
|
||||||
|
<Assembly: ComVisible(False)>
|
||||||
|
|
||||||
|
'Die folgende GUID wird für die typelib-ID verwendet, wenn dieses Projekt für COM verfügbar gemacht wird.
|
||||||
|
<Assembly: Guid("2a4f6a80-e6e0-4764-ba6e-91484bda887f")>
|
||||||
|
|
||||||
|
' Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten:
|
||||||
|
'
|
||||||
|
' Hauptversion
|
||||||
|
' Nebenversion
|
||||||
|
' Buildnummer
|
||||||
|
' Revision
|
||||||
|
'
|
||||||
|
' Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden,
|
||||||
|
' indem Sie "*" wie unten gezeigt eingeben:
|
||||||
|
' <Assembly: AssemblyVersion("1.0.*")>
|
||||||
|
|
||||||
|
<Assembly: AssemblyVersion("1.0.0.0")>
|
||||||
|
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
||||||
63
EDMI.File/My Project/Resources.Designer.vb
generated
Normal file
63
EDMI.File/My Project/Resources.Designer.vb
generated
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
'------------------------------------------------------------------------------
|
||||||
|
' <auto-generated>
|
||||||
|
' Dieser Code wurde von einem Tool generiert.
|
||||||
|
' Laufzeitversion:4.0.30319.42000
|
||||||
|
'
|
||||||
|
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||||
|
' der Code erneut generiert wird.
|
||||||
|
' </auto-generated>
|
||||||
|
'------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Option Strict On
|
||||||
|
Option Explicit On
|
||||||
|
|
||||||
|
Imports System
|
||||||
|
|
||||||
|
Namespace My.Resources
|
||||||
|
|
||||||
|
'Diese Klasse wurde von der StronglyTypedResourceBuilder automatisch generiert
|
||||||
|
'-Klasse über ein Tool wie ResGen oder Visual Studio automatisch generiert.
|
||||||
|
'Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
|
||||||
|
'mit der /str-Option erneut aus, oder Sie erstellen Ihr VS-Projekt neu.
|
||||||
|
'''<summary>
|
||||||
|
''' Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
|
||||||
|
'''</summary>
|
||||||
|
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0"), _
|
||||||
|
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
||||||
|
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
|
||||||
|
Global.Microsoft.VisualBasic.HideModuleNameAttribute()> _
|
||||||
|
Friend Module Resources
|
||||||
|
|
||||||
|
Private resourceMan As Global.System.Resources.ResourceManager
|
||||||
|
|
||||||
|
Private resourceCulture As Global.System.Globalization.CultureInfo
|
||||||
|
|
||||||
|
'''<summary>
|
||||||
|
''' Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
|
||||||
|
'''</summary>
|
||||||
|
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||||
|
Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
|
||||||
|
Get
|
||||||
|
If Object.ReferenceEquals(resourceMan, Nothing) Then
|
||||||
|
Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("DigitalData.Modules.EDMI.File.Resources", GetType(Resources).Assembly)
|
||||||
|
resourceMan = temp
|
||||||
|
End If
|
||||||
|
Return resourceMan
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
'''<summary>
|
||||||
|
''' Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
|
||||||
|
''' Ressourcenzuordnungen, die diese stark typisierte Ressourcenklasse verwenden.
|
||||||
|
'''</summary>
|
||||||
|
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||||
|
Friend Property Culture() As Global.System.Globalization.CultureInfo
|
||||||
|
Get
|
||||||
|
Return resourceCulture
|
||||||
|
End Get
|
||||||
|
Set
|
||||||
|
resourceCulture = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
End Module
|
||||||
|
End Namespace
|
||||||
117
EDMI.File/My Project/Resources.resx
Normal file
117
EDMI.File/My Project/Resources.resx
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
73
EDMI.File/My Project/Settings.Designer.vb
generated
Normal file
73
EDMI.File/My Project/Settings.Designer.vb
generated
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
'------------------------------------------------------------------------------
|
||||||
|
' <auto-generated>
|
||||||
|
' Dieser Code wurde von einem Tool generiert.
|
||||||
|
' Laufzeitversion:4.0.30319.42000
|
||||||
|
'
|
||||||
|
' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
||||||
|
' der Code erneut generiert wird.
|
||||||
|
' </auto-generated>
|
||||||
|
'------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Option Strict On
|
||||||
|
Option Explicit On
|
||||||
|
|
||||||
|
|
||||||
|
Namespace My
|
||||||
|
|
||||||
|
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
|
||||||
|
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.4.0.0"), _
|
||||||
|
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||||
|
Partial Friend NotInheritable Class MySettings
|
||||||
|
Inherits Global.System.Configuration.ApplicationSettingsBase
|
||||||
|
|
||||||
|
Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings)
|
||||||
|
|
||||||
|
#Region "Automatische My.Settings-Speicherfunktion"
|
||||||
|
#If _MyType = "WindowsForms" Then
|
||||||
|
Private Shared addedHandler As Boolean
|
||||||
|
|
||||||
|
Private Shared addedHandlerLockObject As New Object
|
||||||
|
|
||||||
|
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
|
||||||
|
Private Shared Sub AutoSaveSettings(sender As Global.System.Object, e As Global.System.EventArgs)
|
||||||
|
If My.Application.SaveMySettingsOnExit Then
|
||||||
|
My.Settings.Save()
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
#End If
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
Public Shared ReadOnly Property [Default]() As MySettings
|
||||||
|
Get
|
||||||
|
|
||||||
|
#If _MyType = "WindowsForms" Then
|
||||||
|
If Not addedHandler Then
|
||||||
|
SyncLock addedHandlerLockObject
|
||||||
|
If Not addedHandler Then
|
||||||
|
AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
|
||||||
|
addedHandler = True
|
||||||
|
End If
|
||||||
|
End SyncLock
|
||||||
|
End If
|
||||||
|
#End If
|
||||||
|
Return defaultInstance
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
End Class
|
||||||
|
End Namespace
|
||||||
|
|
||||||
|
Namespace My
|
||||||
|
|
||||||
|
<Global.Microsoft.VisualBasic.HideModuleNameAttribute(), _
|
||||||
|
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
|
||||||
|
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute()> _
|
||||||
|
Friend Module MySettingsProperty
|
||||||
|
|
||||||
|
<Global.System.ComponentModel.Design.HelpKeywordAttribute("My.Settings")> _
|
||||||
|
Friend ReadOnly Property Settings() As Global.DigitalData.Modules.EDMI.File.My.MySettings
|
||||||
|
Get
|
||||||
|
Return Global.DigitalData.Modules.EDMI.File.My.MySettings.Default
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
End Module
|
||||||
|
End Namespace
|
||||||
7
EDMI.File/My Project/Settings.settings
Normal file
7
EDMI.File/My Project/Settings.settings
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version='1.0' encoding='utf-8'?>
|
||||||
|
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" UseMySettingsClassName="true">
|
||||||
|
<Profiles>
|
||||||
|
<Profile Name="(Default)" />
|
||||||
|
</Profiles>
|
||||||
|
<Settings />
|
||||||
|
</SettingsFile>
|
||||||
4
EDMI.File/packages.config
Normal file
4
EDMI.File/packages.config
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<packages>
|
||||||
|
<package id="NLog" version="4.7.0" targetFramework="net472" />
|
||||||
|
</packages>
|
||||||
@@ -89,7 +89,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="ScintillaNET, Version=3.6.3.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="ScintillaNET, Version=3.6.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\jacobslusser.ScintillaNET.3.6.3\lib\net40\ScintillaNET.dll</HintPath>
|
<HintPath>..\packages\jacobslusser.ScintillaNET.3.6.3\lib\net40\ScintillaNET.dll</HintPath>
|
||||||
@@ -496,9 +496,9 @@
|
|||||||
<Project>{44982f9b-6116-44e2-85d0-f39650b1ef99}</Project>
|
<Project>{44982f9b-6116-44e2-85d0-f39650b1ef99}</Project>
|
||||||
<Name>Config</Name>
|
<Name>Config</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\Modules.EDMIAPI\EDMIAPI.vbproj">
|
<ProjectReference Include="..\Modules.EDMIAPI\EDMI.API.vbproj">
|
||||||
<Project>{5b1171dc-fffe-4813-a20d-786aae47b320}</Project>
|
<Project>{5b1171dc-fffe-4813-a20d-786aae47b320}</Project>
|
||||||
<Name>EDMIAPI</Name>
|
<Name>EDMI.API</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\Modules.Language\Language.vbproj">
|
<ProjectReference Include="..\Modules.Language\Language.vbproj">
|
||||||
<Project>{d3c8cfed-d6f6-43a8-9bdf-454145d0352f}</Project>
|
<Project>{d3c8cfed-d6f6-43a8-9bdf-454145d0352f}</Project>
|
||||||
@@ -512,9 +512,9 @@
|
|||||||
<Project>{903b2d7d-3b80-4be9-8713-7447b704e1b0}</Project>
|
<Project>{903b2d7d-3b80-4be9-8713-7447b704e1b0}</Project>
|
||||||
<Name>Logging</Name>
|
<Name>Logging</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
<ProjectReference Include="..\SERVICES\DDEDM_NetworkService\IDBService.vbproj">
|
<ProjectReference Include="..\SERVICES\DDEDM_NetworkService\EDMIService.vbproj">
|
||||||
<Project>{A8C3F298-76AB-4359-AB3C-986E313B4336}</Project>
|
<Project>{A8C3F298-76AB-4359-AB3C-986E313B4336}</Project>
|
||||||
<Name>IDBService</Name>
|
<Name>EDMIService</Name>
|
||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
|||||||
@@ -3,6 +3,6 @@
|
|||||||
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="FirebirdSql.EntityFrameworkCore.Firebird" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.EntityFrameworkCore.Firebird" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="jacobslusser.ScintillaNET" version="3.6.3" targetFramework="net461" />
|
<package id="jacobslusser.ScintillaNET" version="3.6.3" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
<package id="System.Runtime.Serialization.Primitives" version="4.3.0" targetFramework="net461" />
|
<package id="System.Runtime.Serialization.Primitives" version="4.3.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,20 +45,17 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="DevExpress.Data.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
|
<Reference Include="DevExpress.Data.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DevExpress.Utils.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
|
<Reference Include="DevExpress.Utils.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="DevExpress.XtraBars.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
<Reference Include="DevExpress.XtraBars.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
||||||
<Reference Include="DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
|
<Reference Include="DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -62,7 +62,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -49,7 +49,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net461" />
|
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -25,7 +25,7 @@ Public Class Form1
|
|||||||
_firebird = New Firebird(_logConfig, My.Settings.FB_DATASOURCE, My.Settings.FB_DATABASE, My.Settings.FB_USER, My.Settings.FB_PASS)
|
_firebird = New Firebird(_logConfig, My.Settings.FB_DATASOURCE, My.Settings.FB_DATABASE, My.Settings.FB_USER, My.Settings.FB_PASS)
|
||||||
_mssql = New MSSQLServer(_logConfig, My.Settings.MSSQL_CONNECTIONSTRING)
|
_mssql = New MSSQLServer(_logConfig, My.Settings.MSSQL_CONNECTIONSTRING)
|
||||||
|
|
||||||
_zugferd = New ZUGFeRDInterface(_logConfig)
|
_zugferd = New ZUGFeRDInterface(_logConfig, "")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Function LoadFolderConfig(args As WorkerArgs)
|
Private Function LoadFolderConfig(args As WorkerArgs)
|
||||||
@@ -164,7 +164,7 @@ Public Class Form1
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub Button7_Click(sender As Object, e As EventArgs) Handles Button7.Click
|
Private Sub Button7_Click(sender As Object, e As EventArgs) Handles Button7.Click
|
||||||
Dim oExtractor = New Jobs.PDFAttachments(_logConfig)
|
Dim oExtractor = New PDFAttachments(_logConfig)
|
||||||
Dim oResult = OpenFileDialog1.ShowDialog()
|
Dim oResult = OpenFileDialog1.ShowDialog()
|
||||||
|
|
||||||
If oResult = DialogResult.OK Then
|
If oResult = DialogResult.OK Then
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -55,7 +55,7 @@
|
|||||||
<Reference Include="DevExpress.XtraLayout.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
<Reference Include="DevExpress.XtraLayout.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
|
||||||
<Reference Include="DevExpress.XtraPrinting.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
<Reference Include="DevExpress.XtraPrinting.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -59,7 +59,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Oracle.ManagedDataAccess">
|
<Reference Include="Oracle.ManagedDataAccess">
|
||||||
<HintPath>P:\Visual Studio Projekte\Bibliotheken\Oracle.ManagedDataAccess.dll</HintPath>
|
<HintPath>P:\Visual Studio Projekte\Bibliotheken\Oracle.ManagedDataAccess.dll</HintPath>
|
||||||
|
|||||||
@@ -3,5 +3,5 @@
|
|||||||
<package id="EntityFramework" version="6.2.0" targetFramework="net461" />
|
<package id="EntityFramework" version="6.2.0" targetFramework="net461" />
|
||||||
<package id="EntityFramework.Firebird" version="6.4.0" targetFramework="net461" />
|
<package id="EntityFramework.Firebird" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
This file is automatically generated by Visual Studio .Net. It is
|
||||||
|
used to store generic object data source configuration information.
|
||||||
|
Renaming the file extension or editing the content of this file may
|
||||||
|
cause the file to be unrecognizable by the program.
|
||||||
|
-->
|
||||||
|
<GenericObjectDataSource DisplayName="DocumentResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||||
|
<TypeInfo>DigitalData.Modules.EDMI.API.IDBServiceReference.DocumentResult</TypeInfo>
|
||||||
|
</GenericObjectDataSource>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
This file is automatically generated by Visual Studio .Net. It is
|
||||||
|
used to store generic object data source configuration information.
|
||||||
|
Renaming the file extension or editing the content of this file may
|
||||||
|
cause the file to be unrecognizable by the program.
|
||||||
|
-->
|
||||||
|
<GenericObjectDataSource DisplayName="DocumentResult2" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||||
|
<TypeInfo>DigitalData.Modules.EDMI.API.IDBServiceReference.DocumentResult2</TypeInfo>
|
||||||
|
</GenericObjectDataSource>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
This file is automatically generated by Visual Studio .Net. It is
|
||||||
|
used to store generic object data source configuration information.
|
||||||
|
Renaming the file extension or editing the content of this file may
|
||||||
|
cause the file to be unrecognizable by the program.
|
||||||
|
-->
|
||||||
|
<GenericObjectDataSource DisplayName="IndexResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||||
|
<TypeInfo>DigitalData.Modules.EDMI.API.IDBServiceReference.IndexResult</TypeInfo>
|
||||||
|
</GenericObjectDataSource>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
This file is automatically generated by Visual Studio .Net. It is
|
||||||
|
used to store generic object data source configuration information.
|
||||||
|
Renaming the file extension or editing the content of this file may
|
||||||
|
cause the file to be unrecognizable by the program.
|
||||||
|
-->
|
||||||
|
<GenericObjectDataSource DisplayName="NonQueryResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||||
|
<TypeInfo>DigitalData.Modules.EDMI.API.IDBServiceReference.NonQueryResult</TypeInfo>
|
||||||
|
</GenericObjectDataSource>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
This file is automatically generated by Visual Studio .Net. It is
|
||||||
|
used to store generic object data source configuration information.
|
||||||
|
Renaming the file extension or editing the content of this file may
|
||||||
|
cause the file to be unrecognizable by the program.
|
||||||
|
-->
|
||||||
|
<GenericObjectDataSource DisplayName="ScalarResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||||
|
<TypeInfo>DigitalData.Modules.EDMI.API.IDBServiceReference.ScalarResult</TypeInfo>
|
||||||
|
</GenericObjectDataSource>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
This file is automatically generated by Visual Studio .Net. It is
|
||||||
|
used to store generic object data source configuration information.
|
||||||
|
Renaming the file extension or editing the content of this file may
|
||||||
|
cause the file to be unrecognizable by the program.
|
||||||
|
-->
|
||||||
|
<GenericObjectDataSource DisplayName="TableResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
||||||
|
<TypeInfo>DigitalData.Modules.EDMI.API.IDBServiceReference.TableResult</TypeInfo>
|
||||||
|
</GenericObjectDataSource>
|
||||||
186
Modules.EDMIAPI/EDMI.API.vbproj
Normal file
186
Modules.EDMIAPI/EDMI.API.vbproj
Normal file
@@ -0,0 +1,186 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
|
<ProjectGuid>{5B1171DC-FFFE-4813-A20D-786AAE47B320}</ProjectGuid>
|
||||||
|
<OutputType>Library</OutputType>
|
||||||
|
<RootNamespace>DigitalData.Modules.EDMI.API</RootNamespace>
|
||||||
|
<AssemblyName>DigitalData.Modules.EDMI.API</AssemblyName>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<MyType>Windows</MyType>
|
||||||
|
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<DefineDebug>true</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DocumentationFile>DigitalData.Modules.EDMI.API.xml</DocumentationFile>
|
||||||
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<DefineDebug>false</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DocumentationFile>DigitalData.Modules.EDMI.API.xml</DocumentationFile>
|
||||||
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionExplicit>On</OptionExplicit>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionCompare>Binary</OptionCompare>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionStrict>Off</OptionStrict>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionInfer>On</OptionInfer>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Configuration" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.IO.Compression" />
|
||||||
|
<Reference Include="System.Runtime.Serialization" />
|
||||||
|
<Reference Include="System.ServiceModel" />
|
||||||
|
<Reference Include="System.Transactions" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="System.Net.Http" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Import Include="Microsoft.VisualBasic" />
|
||||||
|
<Import Include="System" />
|
||||||
|
<Import Include="System.Collections" />
|
||||||
|
<Import Include="System.Collections.Generic" />
|
||||||
|
<Import Include="System.Data" />
|
||||||
|
<Import Include="System.Diagnostics" />
|
||||||
|
<Import Include="System.Linq" />
|
||||||
|
<Import Include="System.Xml.Linq" />
|
||||||
|
<Import Include="System.Threading.Tasks" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="Channel.vb" />
|
||||||
|
<Compile Include="Connected Services\IDBServiceReference\Reference.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DesignTime>True</DesignTime>
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Constants.vb" />
|
||||||
|
<Compile Include="Document.vb" />
|
||||||
|
<Compile Include="My Project\AssemblyInfo.vb" />
|
||||||
|
<Compile Include="My Project\Application.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Application.myapp</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="My Project\Resources.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DesignTime>True</DesignTime>
|
||||||
|
<DependentUpon>Resources.resx</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="My Project\Settings.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Settings.settings</DependentUpon>
|
||||||
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
|
</Compile>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<EmbeddedResource Include="My Project\Resources.resx">
|
||||||
|
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
|
||||||
|
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</EmbeddedResource>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="app.config" />
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.EDMI.API.IDBServiceReference.DocumentResult.datasource">
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.EDMI.API.IDBServiceReference.DocumentResult2.datasource">
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.EDMI.API.IDBServiceReference.IndexResult.datasource">
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.EDMI.API.IDBServiceReference.NonQueryResult.datasource">
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.EDMI.API.IDBServiceReference.ScalarResult.datasource">
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.EDMI.API.IDBServiceReference.TableResult.datasource">
|
||||||
|
<DependentUpon>Reference.svcmap</DependentUpon>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Modules.Filesystem.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Services.IDBService.wsdl" />
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Services.IDBService.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\DigitalData.Services.IDBService1.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\service.wsdl" />
|
||||||
|
<None Include="Connected Services\IDBServiceReference\service.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\System.Data.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\System.IO.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\System.xsd">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="My Project\Application.myapp">
|
||||||
|
<Generator>MyApplicationCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Application.Designer.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<None Include="My Project\Settings.settings">
|
||||||
|
<Generator>SettingsSingleFileGenerator</Generator>
|
||||||
|
<CustomToolNamespace>My</CustomToolNamespace>
|
||||||
|
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<None Include="packages.config" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<WCFMetadata Include="Connected Services\" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\Modules.Logging\Logging.vbproj">
|
||||||
|
<Project>{903b2d7d-3b80-4be9-8713-7447b704e1b0}</Project>
|
||||||
|
<Name>Logging</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<WCFMetadataStorage Include="Connected Services\IDBServiceReference\" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\configuration91.svcinfo" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\configuration.svcinfo" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="Connected Services\IDBServiceReference\Reference.svcmap">
|
||||||
|
<Generator>WCF Proxy Generator</Generator>
|
||||||
|
<LastGenOutput>Reference.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||||
|
</Project>
|
||||||
@@ -169,7 +169,6 @@ Public Class File
|
|||||||
|
|
||||||
<DebuggerStepThrough>
|
<DebuggerStepThrough>
|
||||||
Public Sub MoveTo(FilePath As String, NewFileName As String, Directory As String)
|
Public Sub MoveTo(FilePath As String, NewFileName As String, Directory As String)
|
||||||
Dim oFileInfo As New FileInfo(FilePath)
|
|
||||||
IO.File.Move(FilePath, Path.Combine(Directory, NewFileName))
|
IO.File.Move(FilePath, Path.Combine(Directory, NewFileName))
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="protobuf-net, Version=2.4.0.0, Culture=neutral, PublicKeyToken=257b51d87d2e4d67, processorArchitecture=MSIL">
|
<Reference Include="protobuf-net, Version=2.4.0.0, Culture=neutral, PublicKeyToken=257b51d87d2e4d67, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\protobuf-net.2.4.0\lib\net40\protobuf-net.dll</HintPath>
|
<HintPath>..\packages\protobuf-net.2.4.0\lib\net40\protobuf-net.dll</HintPath>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
<package id="protobuf-net" version="2.4.0" targetFramework="net461" />
|
<package id="protobuf-net" version="2.4.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -43,12 +43,15 @@
|
|||||||
<OptionInfer>On</OptionInfer>
|
<OptionInfer>On</OptionInfer>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Reference Include="GdPicture.NET.14">
|
||||||
|
<HintPath>D:\ProgramFiles\GdPicture.NET 14\Redist\GdPicture.NET (.NET Framework 4.5)\GdPicture.NET.14.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
@@ -108,6 +111,10 @@
|
|||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="ZUGFeRDInterface\CrossIndustryDocumentType.vb" />
|
<Compile Include="ZUGFeRDInterface\CrossIndustryDocumentType.vb" />
|
||||||
<Compile Include="ZUGFeRDInterface.vb" />
|
<Compile Include="ZUGFeRDInterface.vb" />
|
||||||
|
<Compile Include="ZUGFeRDInterface\FileGroups.vb" />
|
||||||
|
<Compile Include="ZUGFeRDInterface\PDFAttachments.vb" />
|
||||||
|
<Compile Include="ZUGFeRDInterface\PropertyValues.vb" />
|
||||||
|
<Compile Include="ZUGFeRDInterface\XmlItemProperty.vb" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="My Project\Resources.resx">
|
<EmbeddedResource Include="My Project\Resources.resx">
|
||||||
@@ -128,7 +135,7 @@
|
|||||||
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||||
</None>
|
</None>
|
||||||
<None Include="packages.config" />
|
<None Include="packages.config" />
|
||||||
<None Include="ZUGFeRDInterface\pdf_zugferd_lib.lib">
|
<None Include="ZUGFeRDInterface\pdf_zugferd_lib\pdf_zugferd_lib.lib">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</None>
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
@@ -143,10 +150,10 @@
|
|||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Content Include="ZUGFeRDInterface\pdf_zugferd_lib.dll">
|
<Content Include="ZUGFeRDInterface\pdf_zugferd_lib\pdf_zugferd_lib.dll">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
<Content Include="ZUGFeRDInterface\pdf_zugferd_test.exe">
|
<Content Include="ZUGFeRDInterface\pdf_zugferd_lib\pdf_zugferd_test.exe">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|||||||
@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
|
|||||||
' übernehmen, indem Sie "*" eingeben:
|
' übernehmen, indem Sie "*" eingeben:
|
||||||
' <Assembly: AssemblyVersion("1.0.*")>
|
' <Assembly: AssemblyVersion("1.0.*")>
|
||||||
|
|
||||||
<Assembly: AssemblyVersion("1.0.0.0")>
|
<Assembly: AssemblyVersion("1.0.1.0")>
|
||||||
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
<Assembly: AssemblyFileVersion("1.0.0.0")>
|
||||||
|
|||||||
@@ -1,28 +1,46 @@
|
|||||||
Imports System.Xml
|
Imports System.IO
|
||||||
|
Imports System.Xml
|
||||||
Imports System.Xml.Serialization
|
Imports System.Xml.Serialization
|
||||||
Imports System.Xml.XPath
|
Imports System.Xml.XPath
|
||||||
Imports System.Xml.Xsl
|
Imports System.Xml.Xsl
|
||||||
Imports DigitalData.Modules.Interfaces.Exceptions
|
Imports DigitalData.Modules.Interfaces.Exceptions
|
||||||
Imports DigitalData.Modules.Logging
|
Imports DigitalData.Modules.Logging
|
||||||
|
Imports GdPicture14
|
||||||
|
|
||||||
Public Class ZUGFeRDInterface
|
Public Class ZUGFeRDInterface
|
||||||
Private _logConfig As LogConfig
|
Private _logConfig As LogConfig
|
||||||
Private _logger As Logger
|
Private _logger As Logger
|
||||||
|
|
||||||
Private Const ZUGFERD_CONVERTER_EXE = "ZUGFeRDInterface\pdf_zugferd_test.exe"
|
Private Const ZUGFERD_CONVERTER_EXE = "ZUGFeRDInterface\pdf_zugferd_lib\pdf_zugferd_test.exe"
|
||||||
Private Const ZUGFERD_CONVERTER_SUCCESS_MESSAGE = "Document contains ZUGFeRD data."
|
Private Const ZUGFERD_CONVERTER_SUCCESS_MESSAGE = "Document contains ZUGFeRD data."
|
||||||
|
|
||||||
Public Enum ErrorType
|
Public Enum ErrorType
|
||||||
NoValidFile
|
NoValidFile
|
||||||
NoZugferd
|
NoZugferd
|
||||||
NoValidZugferd
|
NoValidZugferd
|
||||||
|
MissingProperties
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
Public Sub New(LogConfig As LogConfig)
|
Public ReadOnly Property FileGroup As FileGroups
|
||||||
|
Public ReadOnly Property PropertyValues As PropertyValues
|
||||||
|
|
||||||
|
Public Sub New(LogConfig As LogConfig, GDPictureKey As String)
|
||||||
_logConfig = LogConfig
|
_logConfig = LogConfig
|
||||||
_logger = _logConfig.GetLogger()
|
_logger = _logConfig.GetLogger()
|
||||||
|
|
||||||
|
FileGroup = New FileGroups(_logConfig)
|
||||||
|
PropertyValues = New PropertyValues(_logConfig)
|
||||||
|
|
||||||
|
Try
|
||||||
|
Dim oLicenseManager As New LicenseManager
|
||||||
|
oLicenseManager.RegisterKEY(GDPictureKey)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Warn("GDPicture License could not be registered!")
|
||||||
|
_logger.Error(ex)
|
||||||
|
End Try
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
''' <summary>
|
''' <summary>
|
||||||
''' Validates a ZUGFeRD File and extracts the XML Document from it
|
''' Validates a ZUGFeRD File and extracts the XML Document from it
|
||||||
''' </summary>
|
''' </summary>
|
||||||
@@ -30,7 +48,6 @@ Public Class ZUGFeRDInterface
|
|||||||
''' <exception cref="ZUGFeRDExecption"></exception>
|
''' <exception cref="ZUGFeRDExecption"></exception>
|
||||||
''' <returns></returns>
|
''' <returns></returns>
|
||||||
Public Function ExtractZUGFeRDFile(Path As String) As CrossIndustryDocumentType
|
Public Function ExtractZUGFeRDFile(Path As String) As CrossIndustryDocumentType
|
||||||
Dim oException As New Exception
|
|
||||||
Dim oXmlDocument = ValidateZUGFeRDFile(Path)
|
Dim oXmlDocument = ValidateZUGFeRDFile(Path)
|
||||||
|
|
||||||
If IsNothing(oXmlDocument) Then
|
If IsNothing(oXmlDocument) Then
|
||||||
@@ -40,6 +57,25 @@ Public Class ZUGFeRDInterface
|
|||||||
Return SerializeZUGFeRDDocument(oXmlDocument)
|
Return SerializeZUGFeRDDocument(oXmlDocument)
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
Public Function ExtractZUGFeRDFileWithGDPicture(Path As String) As CrossIndustryDocumentType
|
||||||
|
Dim oXmlDocument = ValidateZUGFeRDFileWithGDPicture(Path)
|
||||||
|
|
||||||
|
If IsNothing(oXmlDocument) Then
|
||||||
|
Throw New ZUGFeRDExecption(ErrorType.NoZugferd, "Datei ist keine ZUGFeRD Datei.")
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return SerializeZUGFeRDDocument(oXmlDocument)
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function ExtractZUGFeRDFileWithGDPicture(Stream As Stream) As CrossIndustryDocumentType
|
||||||
|
Dim oXmlDocument = ValidateZUGFeRDFileWithGDPicture(Stream)
|
||||||
|
|
||||||
|
If IsNothing(oXmlDocument) Then
|
||||||
|
Throw New ZUGFeRDExecption(ErrorType.NoZugferd, "Datei ist keine ZUGFeRD Datei.")
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return SerializeZUGFeRDDocument(oXmlDocument)
|
||||||
|
End Function
|
||||||
|
|
||||||
Public Function ValidateZUGFeRDFile(Path As String) As XPathDocument
|
Public Function ValidateZUGFeRDFile(Path As String) As XPathDocument
|
||||||
Dim oProcessOutput, oProcessError As String
|
Dim oProcessOutput, oProcessError As String
|
||||||
@@ -85,6 +121,69 @@ Public Class ZUGFeRDInterface
|
|||||||
Return oXmlDocument
|
Return oXmlDocument
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
Public Function ValidateZUGFeRDFileWithGDPicture(Stream As Stream) As XPathDocument
|
||||||
|
Dim oAttachmentExtractor = New PDFAttachments(_logConfig)
|
||||||
|
Dim oAllowedExtensions = New List(Of String) From {"xml"}
|
||||||
|
|
||||||
|
Try
|
||||||
|
Dim oResults = oAttachmentExtractor.Extract(Stream, oAllowedExtensions)
|
||||||
|
Return HandleAttachments(oResults)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
Throw ex
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function ValidateZUGFeRDFileWithGDPicture(Path As String) As XPathDocument
|
||||||
|
Dim oAttachmentExtractor = New PDFAttachments(_logConfig)
|
||||||
|
Dim oAllowedExtensions = New List(Of String) From {"xml"}
|
||||||
|
|
||||||
|
Try
|
||||||
|
Dim oResults = oAttachmentExtractor.Extract(Path, oAllowedExtensions)
|
||||||
|
Return HandleAttachments(oResults)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
Throw ex
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function HandleAttachments(Results As List(Of PDFAttachments.AttachmentResult)) As XPathDocument
|
||||||
|
Dim oXmlDocument As XPathDocument
|
||||||
|
|
||||||
|
If Results Is Nothing Then
|
||||||
|
Throw New ZUGFeRDExecption(ErrorType.NoZugferd, "Datei ist keine ZUGFeRD Datei.")
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Results.Count = 0 Then
|
||||||
|
Throw New ZUGFeRDExecption(ErrorType.NoZugferd, "Datei ist keine ZUGFeRD Datei.")
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim oFound As Boolean = False
|
||||||
|
Dim oFoundResult As PDFAttachments.AttachmentResult = Nothing
|
||||||
|
|
||||||
|
For Each oResult In Results
|
||||||
|
If oResult.FileName.ToUpper() = PDFAttachments.ZUGFERD_XML_FILENAME.ToUpper() Then
|
||||||
|
oFound = True
|
||||||
|
oFoundResult = oResult
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If Not oFound Then
|
||||||
|
Throw New ZUGFeRDExecption(ErrorType.NoZugferd, "Datei ist keine ZUGFeRD Datei.")
|
||||||
|
End If
|
||||||
|
|
||||||
|
Try
|
||||||
|
Using oStream As New MemoryStream(oFoundResult.FileContents)
|
||||||
|
oXmlDocument = New XPathDocument(oStream)
|
||||||
|
End Using
|
||||||
|
|
||||||
|
Return oXmlDocument
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
Throw ex
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
Public Function SerializeZUGFeRDDocument(Document As XPathDocument) As CrossIndustryDocumentType
|
Public Function SerializeZUGFeRDDocument(Document As XPathDocument) As CrossIndustryDocumentType
|
||||||
Try
|
Try
|
||||||
Dim oNavigator As XPathNavigator = Document.CreateNavigator()
|
Dim oNavigator As XPathNavigator = Document.CreateNavigator()
|
||||||
|
|||||||
82
Modules.Interfaces/ZUGFeRDInterface/FileGroups.vb
Normal file
82
Modules.Interfaces/ZUGFeRDInterface/FileGroups.vb
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
Imports System.IO
|
||||||
|
Imports System.Text.RegularExpressions
|
||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
|
||||||
|
Public Class FileGroups
|
||||||
|
Private _logger As Logger
|
||||||
|
|
||||||
|
Public Sub New(LogConfig As LogConfig)
|
||||||
|
_logger = LogConfig.GetLogger()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
''' <summary>
|
||||||
|
''' Group files by message id. Message id is extracted from filename.
|
||||||
|
''' Filename is expected to be in the form: 1234@subdomain.company.com
|
||||||
|
''' <param name="Files">The list of files to process</param>
|
||||||
|
''' </summary>
|
||||||
|
Public Function GroupFiles(Files As List(Of FileInfo)) As Dictionary(Of String, List(Of FileInfo))
|
||||||
|
Dim oGrouped As New Dictionary(Of String, List(Of FileInfo))
|
||||||
|
|
||||||
|
If Files.Count = 0 Then
|
||||||
|
Return oGrouped
|
||||||
|
End If
|
||||||
|
|
||||||
|
For Each oFile In Files
|
||||||
|
Dim oMessageId = GetMessageIdFromFileName(oFile.Name)
|
||||||
|
|
||||||
|
If oMessageId Is Nothing Then
|
||||||
|
_logger.Warn("File {0} did not have the required filename-format!", oMessageId)
|
||||||
|
Continue For
|
||||||
|
End If
|
||||||
|
|
||||||
|
If oGrouped.ContainsKey(oMessageId) Then
|
||||||
|
oGrouped.Item(oMessageId).Add(oFile)
|
||||||
|
Else
|
||||||
|
oGrouped.Add(oMessageId, New List(Of FileInfo) From {oFile})
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oGrouped
|
||||||
|
End Function
|
||||||
|
|
||||||
|
''' <summary>
|
||||||
|
''' Group files by message id. Message id is created from `FakeMessageIdDomain` and a random string
|
||||||
|
''' </summary>
|
||||||
|
''' <param name="Files">The list of files to process</param>
|
||||||
|
''' <param name="FakeMessageIdDomain">Arbitrary domain for message id generation. Example: sub.company.com</param>
|
||||||
|
''' <returns></returns>
|
||||||
|
Public Function GroupFiles(Files As List(Of FileInfo), FakeMessageIdDomain As String) As Dictionary(Of String, List(Of FileInfo))
|
||||||
|
Dim oGrouped As New Dictionary(Of String, List(Of FileInfo))
|
||||||
|
|
||||||
|
If Files.Count = 0 Then
|
||||||
|
Return oGrouped
|
||||||
|
End If
|
||||||
|
|
||||||
|
For Each oFile In Files
|
||||||
|
Dim oIdentifier = Guid.NewGuid().ToString()
|
||||||
|
Dim oMessageId = $"{oIdentifier}@{FakeMessageIdDomain}"
|
||||||
|
|
||||||
|
If oGrouped.ContainsKey(oMessageId) Then
|
||||||
|
oGrouped.Item(oMessageId).Add(oFile)
|
||||||
|
Else
|
||||||
|
oGrouped.Add(oMessageId, New List(Of FileInfo) From {oFile})
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oGrouped
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function GetMessageIdFromFileName(Filename As String) As String
|
||||||
|
' Regex to find MessageId
|
||||||
|
' See also: https://stackoverflow.com/questions/3968500/regex-to-validate-a-message-id-as-per-rfc2822
|
||||||
|
Dim oRegex = "(((([a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*)|(""(([\x01-\x08\x0B\x0C\x0E-\x1F\x7F]|[\x21\x23-\x5B\x5D-\x7E])|(\\[\x01-\x09\x0B\x0C\x0E-\x7F]))*""))@(([a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*)|(\[(([\x01-\x08\x0B\x0C\x0E-\x1F\x7F]|[\x21-\x5A\x5E-\x7E])|(\\[\x01-\x09\x0B\x0C\x0E-\x7F]))*\]))))~.+"
|
||||||
|
Dim oMatch = Regex.Match(Filename, oRegex, RegexOptions.IgnoreCase)
|
||||||
|
|
||||||
|
If oMatch.Success Then
|
||||||
|
Dim oMessageId = oMatch.Groups(1).Value
|
||||||
|
Return oMessageId
|
||||||
|
Else
|
||||||
|
Return Nothing
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
End Class
|
||||||
136
Modules.Interfaces/ZUGFeRDInterface/PDFAttachments.vb
Normal file
136
Modules.Interfaces/ZUGFeRDInterface/PDFAttachments.vb
Normal file
@@ -0,0 +1,136 @@
|
|||||||
|
Imports System.Collections.Generic
|
||||||
|
Imports System.IO
|
||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
Imports GdPicture14
|
||||||
|
|
||||||
|
Public Class PDFAttachments
|
||||||
|
Private ReadOnly Logger As Logger
|
||||||
|
|
||||||
|
Public Const ZUGFERD_XML_FILENAME = "ZUGFeRD-invoice.xml"
|
||||||
|
|
||||||
|
Public Class AttachmentResult
|
||||||
|
Public FileName As String
|
||||||
|
Public FileContents As Byte()
|
||||||
|
End Class
|
||||||
|
|
||||||
|
Public Sub New(LogConfig As LogConfig)
|
||||||
|
Logger = LogConfig.GetLogger
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
''' <summary>
|
||||||
|
''' Extracts all embedded files from a PDF file.
|
||||||
|
''' Note: This does NOT filter out `ZUGFeRD-invoice.xml` anymore to allow for a more generic use.
|
||||||
|
''' </summary>
|
||||||
|
''' <param name="FilePath">Filepath of the pdf</param>
|
||||||
|
''' <param name="AllowedExtensions">List of allowed extensions to be extracted</param>
|
||||||
|
Public Function Extract(FilePath As String, AllowedExtensions As List(Of String)) As List(Of AttachmentResult)
|
||||||
|
Dim oResults As New List(Of AttachmentResult)
|
||||||
|
Dim oExtensions = AllowedExtensions.ConvertAll(New Converter(Of String, String)(Function(ext) ext.ToUpper))
|
||||||
|
|
||||||
|
Logger.Debug("Extracting embedded files from [{0}]", FilePath)
|
||||||
|
|
||||||
|
Try
|
||||||
|
Using oGDPicturePDF As New GdPicturePDF()
|
||||||
|
If oGDPicturePDF.LoadFromFile(FilePath, False) = GdPictureStatus.OK Then
|
||||||
|
oResults = DoExtract(oGDPicturePDF, oExtensions)
|
||||||
|
Else
|
||||||
|
Dim oMessage = String.Format("The file [{0}] can't be loaded. Status: [{1}]", FilePath, oGDPicturePDF.GetStat().ToString())
|
||||||
|
Throw New ApplicationException(oMessage)
|
||||||
|
End If
|
||||||
|
End Using
|
||||||
|
|
||||||
|
Return oResults
|
||||||
|
Catch ex As Exception
|
||||||
|
Logger.Warn("Unexpected Error while Extracting attachments from File [{0}]", FilePath)
|
||||||
|
Logger.Error(ex)
|
||||||
|
Return Nothing
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
''' <summary>
|
||||||
|
''' Extracts all embedded files from a PDF file.
|
||||||
|
''' Note: This does NOT filter out `ZUGFeRD-invoice.xml` anymore to allow for a more generic use.
|
||||||
|
''' </summary>
|
||||||
|
''' <param name="Stream">Filestream of the pdf</param>
|
||||||
|
''' <param name="AllowedExtensions">List of allowed extensions to be extracted</param>
|
||||||
|
Public Function Extract(Stream As Stream, AllowedExtensions As List(Of String)) As List(Of AttachmentResult)
|
||||||
|
Dim oResults As New List(Of AttachmentResult)
|
||||||
|
Dim oExtensions = AllowedExtensions.ConvertAll(New Converter(Of String, String)(Function(ext) ext.ToUpper))
|
||||||
|
|
||||||
|
Logger.Debug("Extracting embedded files from stream")
|
||||||
|
|
||||||
|
Try
|
||||||
|
Using oGDPicturePDF As New GdPicturePDF()
|
||||||
|
If oGDPicturePDF.LoadFromStream(Stream, False) = GdPictureStatus.OK Then
|
||||||
|
oResults = DoExtract(oGDPicturePDF, oExtensions)
|
||||||
|
Else
|
||||||
|
Dim oMessage = String.Format("The filestream can't be loaded. Status: [{0}]", oGDPicturePDF.GetStat().ToString())
|
||||||
|
Throw New ApplicationException(oMessage)
|
||||||
|
End If
|
||||||
|
End Using
|
||||||
|
|
||||||
|
Return oResults
|
||||||
|
Catch ex As Exception
|
||||||
|
Logger.Warn("Unexpected Error while Extracting attachments from Filestream")
|
||||||
|
Logger.Error(ex)
|
||||||
|
Return Nothing
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function DoExtract(GDPicturePDF As GdPicturePDF, Extensions As List(Of String)) As List(Of AttachmentResult)
|
||||||
|
Dim oResults As New List(Of AttachmentResult)
|
||||||
|
Dim oEmbeddedFileCount As Integer = GDPicturePDF.GetEmbeddedFileCount()
|
||||||
|
|
||||||
|
If GDPicturePDF.GetStat() = GdPictureStatus.OK Then
|
||||||
|
Logger.Debug("Embedded file count is: [{0}]", oEmbeddedFileCount)
|
||||||
|
|
||||||
|
If oEmbeddedFileCount > 0 Then
|
||||||
|
For oIndex = 0 To oEmbeddedFileCount - 1
|
||||||
|
Dim oFileName As String = GDPicturePDF.GetEmbeddedFileName(oIndex)
|
||||||
|
|
||||||
|
If GDPicturePDF.GetStat() = GdPictureStatus.OK Then
|
||||||
|
Logger.Debug("Extracting embedded file [{0}]", oFileName)
|
||||||
|
|
||||||
|
Dim oExtension = New FileInfo(oFileName).Extension.ToUpper.Substring(1)
|
||||||
|
If Extensions.Contains(oExtension) Then
|
||||||
|
Dim oFileSize As Integer = GDPicturePDF.GetEmbeddedFileSize(oIndex)
|
||||||
|
|
||||||
|
If GDPicturePDF.GetStat() = GdPictureStatus.OK Then
|
||||||
|
Logger.Debug("Filesize of embedded file is [{0}]", oFileSize)
|
||||||
|
|
||||||
|
Dim oFileData As Byte() = New Byte(oFileSize) {}
|
||||||
|
Dim oStatus As GdPictureStatus = GDPicturePDF.ExtractEmbeddedFile(oIndex, oFileData)
|
||||||
|
|
||||||
|
If oStatus = GdPictureStatus.OK Then
|
||||||
|
Logger.Debug("Embedded file [{0}] extracted sucessfully!", oFileName)
|
||||||
|
|
||||||
|
oResults.Add(New AttachmentResult() With {
|
||||||
|
.FileContents = oFileData,
|
||||||
|
.FileName = oFileName
|
||||||
|
})
|
||||||
|
Else
|
||||||
|
Logger.Error("The embedded file [{0}] has failed to extract. Status: {1}", oFileName, GDPicturePDF.GetStat().ToString())
|
||||||
|
Continue For
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
Logger.Error("An error occurred getting the file size for [{0}]. Status: {1}", oFileName, GDPicturePDF.GetStat().ToString())
|
||||||
|
Continue For
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
Logger.Warn("File [{0}] was skipped because its extension [{1}] is not allowed.", oFileName, oExtension)
|
||||||
|
Continue For
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
Logger.Error("An error occurred getting the file name for [{0}]. Status: {1}", oFileName, GDPicturePDF.GetStat().ToString())
|
||||||
|
Continue For
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return oResults
|
||||||
|
Else
|
||||||
|
Dim oMessage = String.Format("An error occurred getting the number of embedded files. Status: {0}", GDPicturePDF.GetStat().ToString())
|
||||||
|
Throw New ApplicationException(oMessage)
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
End Class
|
||||||
313
Modules.Interfaces/ZUGFeRDInterface/PropertyValues.vb
Normal file
313
Modules.Interfaces/ZUGFeRDInterface/PropertyValues.vb
Normal file
@@ -0,0 +1,313 @@
|
|||||||
|
Imports System.Reflection
|
||||||
|
Imports System.Text.RegularExpressions
|
||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
|
||||||
|
Public Class PropertyValues
|
||||||
|
Private _logger As Logger
|
||||||
|
Private _logConfig As LogConfig
|
||||||
|
|
||||||
|
Private _indexPattern = "\((\d+)\)"
|
||||||
|
Private _indexRegex As New Regex(_indexPattern)
|
||||||
|
|
||||||
|
Public Sub New(LogConfig As LogConfig)
|
||||||
|
_logConfig = LogConfig
|
||||||
|
_logger = LogConfig.GetLogger()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Class CheckPropertyValuesResult
|
||||||
|
Public MissingProperties As New List(Of String)
|
||||||
|
Public ValidProperties As New List(Of ValidProperty)
|
||||||
|
End Class
|
||||||
|
|
||||||
|
Public Class ValidProperty
|
||||||
|
Public MessageId As String
|
||||||
|
Public TableName As String
|
||||||
|
|
||||||
|
Public GroupCounter As Integer = -1
|
||||||
|
|
||||||
|
Public Description As String
|
||||||
|
Public Value As String
|
||||||
|
End Class
|
||||||
|
|
||||||
|
Public Function CheckPropertyValues(Document As CrossIndustryDocumentType, PropertyMap As Dictionary(Of String, XmlItemProperty), MessageId As String) As CheckPropertyValuesResult
|
||||||
|
Dim oGlobalGroupCounter = 0
|
||||||
|
Dim oMissingProperties As New List(Of String)
|
||||||
|
Dim oResult As New CheckPropertyValuesResult()
|
||||||
|
|
||||||
|
' PropertyMap items with `IsGrouped = False` are handled normally
|
||||||
|
Dim oDefaultProperties As Dictionary(Of String, XmlItemProperty) = PropertyMap.
|
||||||
|
Where(Function(Item) Item.Value.IsGrouped = False).
|
||||||
|
ToDictionary(Function(Item) Item.Key,
|
||||||
|
Function(Item) Item.Value)
|
||||||
|
|
||||||
|
_logger.Debug("Found {0} default properties.", oDefaultProperties.Count)
|
||||||
|
|
||||||
|
' PropertyMap items with `IsGrouped = True` are grouped by group scope
|
||||||
|
Dim oGroupedProperties = PropertyMap.
|
||||||
|
Where(Function(Item) Item.Value.IsGrouped = True).
|
||||||
|
ToLookup(Function(Item) Item.Value.GroupScope, ' Lookup key is group scope
|
||||||
|
Function(Item) Item)
|
||||||
|
|
||||||
|
_logger.Debug("Found {0} properties grouped in {1} group(s)", PropertyMap.Count - oDefaultProperties.Count, oGroupedProperties.Count)
|
||||||
|
' Iterate through groups to get group scope and group items
|
||||||
|
For Each oGroup In oGroupedProperties
|
||||||
|
Dim oGroupScope As String = oGroup.Key
|
||||||
|
Dim oPropertyList As New Dictionary(Of XmlItemProperty, List(Of Object))
|
||||||
|
Dim oRowCount = 0
|
||||||
|
|
||||||
|
_logger.Debug("Fetching Property values for group {0}.", oGroupScope)
|
||||||
|
|
||||||
|
' get properties as a nested object, see `oPropertyList`
|
||||||
|
For Each oProperty As KeyValuePair(Of String, XmlItemProperty) In oGroup
|
||||||
|
Dim oPropertyValues As List(Of Object)
|
||||||
|
|
||||||
|
Try
|
||||||
|
oPropertyValues = GetPropValue(Document, oProperty.Key)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Warn("Unknown error occurred while fetching property [{0}] in group [{1}]:", oProperty.Value.Description, oGroupScope)
|
||||||
|
_logger.Error(ex)
|
||||||
|
oPropertyValues = New List(Of Object)
|
||||||
|
End Try
|
||||||
|
|
||||||
|
' Flatten result value
|
||||||
|
oPropertyValues = GetFinalPropValue(oPropertyValues)
|
||||||
|
|
||||||
|
' Add to list
|
||||||
|
oPropertyList.Add(oProperty.Value, oPropertyValues)
|
||||||
|
|
||||||
|
' check the first batch of values to determine the row count
|
||||||
|
If oRowCount = 0 Then
|
||||||
|
oRowCount = oPropertyValues.Count
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
' Structure of oPropertyList
|
||||||
|
' [ # Propertyname # Row 1 # Row 2
|
||||||
|
' PositionsMenge: [BilledQuantity1, BilledQuantity2, ...],
|
||||||
|
' PositionsSteuersatz: [ApplicablePercent1, ApplicablePercent2, ...],
|
||||||
|
' ...
|
||||||
|
' ]
|
||||||
|
For oRowIndex = 0 To oRowCount - 1
|
||||||
|
_logger.Debug("Processing row {0}", oRowIndex)
|
||||||
|
|
||||||
|
For Each oColumn As KeyValuePair(Of XmlItemProperty, List(Of Object)) In oPropertyList
|
||||||
|
Dim oTableName As String = oColumn.Key.TableName
|
||||||
|
Dim oPropertyDescription As String = oColumn.Key.Description
|
||||||
|
Dim oRowCounter = oRowIndex + oGlobalGroupCounter + 1
|
||||||
|
|
||||||
|
' Returns nothing if oColumn.Value contains an empty list
|
||||||
|
Dim oPropertyValue = oColumn.Value.ElementAtOrDefault(oRowIndex)
|
||||||
|
|
||||||
|
_logger.Debug("Processing property {0}.", oPropertyDescription)
|
||||||
|
|
||||||
|
If IsNothing(oPropertyValue) OrElse String.IsNullOrEmpty(oPropertyValue) Then
|
||||||
|
If oColumn.Key.IsRequired Then
|
||||||
|
_logger.Warn("Property [{0}] is empty or not found but is required. Continuing with Empty String.", oPropertyDescription)
|
||||||
|
oResult.MissingProperties.Add(oPropertyDescription)
|
||||||
|
Else
|
||||||
|
_logger.Debug("Property [{0}] is empty or not found. Continuing with Empty String.", oPropertyDescription)
|
||||||
|
End If
|
||||||
|
|
||||||
|
oPropertyValue = String.Empty
|
||||||
|
End If
|
||||||
|
|
||||||
|
_logger.Debug("Property {0} has value '{1}'", oPropertyDescription, oPropertyValue)
|
||||||
|
|
||||||
|
oResult.ValidProperties.Add(New ValidProperty() With {
|
||||||
|
.MessageId = MessageId,
|
||||||
|
.Description = oPropertyDescription,
|
||||||
|
.Value = oPropertyValue,
|
||||||
|
.GroupCounter = oRowCounter,
|
||||||
|
.TableName = oTableName
|
||||||
|
})
|
||||||
|
Next
|
||||||
|
Next
|
||||||
|
|
||||||
|
oGlobalGroupCounter += oRowCount
|
||||||
|
Next
|
||||||
|
|
||||||
|
' Iterate through default properties
|
||||||
|
For Each oItem As KeyValuePair(Of String, XmlItemProperty) In oDefaultProperties
|
||||||
|
Dim oPropertyValueList As List(Of Object)
|
||||||
|
Dim oPropertyDescription As String = oItem.Value.Description
|
||||||
|
Dim oPropertyValue As Object = Nothing
|
||||||
|
Dim oTableName = oItem.Value.TableName
|
||||||
|
|
||||||
|
Try
|
||||||
|
oPropertyValueList = GetPropValue(Document, oItem.Key)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Warn("Unknown error occurred while fetching property {0} in group {1}:", oPropertyDescription, oItem.Value.GroupScope)
|
||||||
|
_logger.Error(ex)
|
||||||
|
oPropertyValueList = New List(Of Object)
|
||||||
|
End Try
|
||||||
|
|
||||||
|
Try
|
||||||
|
If IsNothing(oPropertyValueList) Then
|
||||||
|
oPropertyValue = Nothing
|
||||||
|
ElseIf TypeOf oPropertyValueList Is List(Of Object) Then
|
||||||
|
Select Case oPropertyValueList.Count
|
||||||
|
Case 0
|
||||||
|
oPropertyValue = Nothing
|
||||||
|
Case Else
|
||||||
|
Dim oList As List(Of Object) = DirectCast(oPropertyValueList, List(Of Object))
|
||||||
|
oPropertyValue = oList.Item(0)
|
||||||
|
|
||||||
|
' This should hopefully show config errors
|
||||||
|
If TypeOf oPropertyValue Is List(Of Object) Then
|
||||||
|
_logger.Warn("Property with Description {0} may be configured incorrectly", oPropertyDescription)
|
||||||
|
oPropertyValue = Nothing
|
||||||
|
End If
|
||||||
|
End Select
|
||||||
|
End If
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Warn("Unknown error occurred while processing property {0}:", oPropertyDescription)
|
||||||
|
_logger.Error(ex)
|
||||||
|
oPropertyValue = Nothing
|
||||||
|
End Try
|
||||||
|
|
||||||
|
If IsNothing(oPropertyValue) OrElse String.IsNullOrEmpty(oPropertyValue) Then
|
||||||
|
If oItem.Value.IsRequired Then
|
||||||
|
_logger.Warn("Property {0} is empty but marked as required! Skipping.", oPropertyDescription)
|
||||||
|
oResult.MissingProperties.Add(oPropertyDescription)
|
||||||
|
Continue For
|
||||||
|
Else
|
||||||
|
_logger.Debug("Property [{0}] is empty or not found. Skipping.", oPropertyDescription)
|
||||||
|
Continue For
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
oResult.ValidProperties.Add(New ValidProperty() With {
|
||||||
|
.MessageId = MessageId,
|
||||||
|
.Description = oPropertyDescription,
|
||||||
|
.Value = oPropertyValue,
|
||||||
|
.TableName = oTableName
|
||||||
|
})
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oResult
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function GetPropValue(Obj As Object, PropertyName As String) As List(Of Object)
|
||||||
|
Dim oNameParts As String() = PropertyName.Split("."c)
|
||||||
|
|
||||||
|
If IsNothing(Obj) Then
|
||||||
|
_logger.Debug("`Obj` is Nothing. Exiting.")
|
||||||
|
Return New List(Of Object)
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
If oNameParts.Length = 1 Then
|
||||||
|
Dim oPropInfo As PropertyInfo = Obj.GetType().GetProperty(PropertyName)
|
||||||
|
|
||||||
|
If IsNothing(oPropInfo) Then
|
||||||
|
_logger.Debug("Property {0} does not exist.", PropertyName)
|
||||||
|
Return New List(Of Object)
|
||||||
|
Else
|
||||||
|
Dim oPropValue = oPropInfo.GetValue(Obj, Nothing)
|
||||||
|
Return New List(Of Object) From {oPropValue}
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
For Each oPart As String In oNameParts
|
||||||
|
Dim oType As Type = Obj.GetType()
|
||||||
|
Dim oPartName = oPart
|
||||||
|
Dim oIndex As Integer = Nothing
|
||||||
|
Dim oHasIndex As Boolean = HasIndex(oPartName)
|
||||||
|
|
||||||
|
If oHasIndex Then
|
||||||
|
oPartName = StripIndex(oPart)
|
||||||
|
oIndex = GetIndex(oPart)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim oInfo As PropertyInfo = oType.GetProperty(oPartName)
|
||||||
|
|
||||||
|
If IsNothing(oInfo) OrElse IsNothing(oInfo.GetValue(Obj, Nothing)) Then
|
||||||
|
_logger.Debug("Property {0} does not exist.", oPartName)
|
||||||
|
Return New List(Of Object)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Obj = oInfo.GetValue(Obj, Nothing)
|
||||||
|
|
||||||
|
If oHasIndex Then
|
||||||
|
Obj = Obj(0)
|
||||||
|
End If
|
||||||
|
|
||||||
|
If IsArray(Obj) And Not oHasIndex Then
|
||||||
|
Dim oCurrentPart As String = oPart
|
||||||
|
Dim oSplitString As String() = New String() {oCurrentPart & "."}
|
||||||
|
Dim oPathFragments = PropertyName.Split(oSplitString, StringSplitOptions.None)
|
||||||
|
Dim oResults As New List(Of Object)
|
||||||
|
|
||||||
|
' if path has no more subitems, return an empty list
|
||||||
|
If oPathFragments.Length = 1 Then
|
||||||
|
Return oResults
|
||||||
|
End If
|
||||||
|
|
||||||
|
For Each oArrayItem In Obj
|
||||||
|
Dim oResult As List(Of Object) = GetPropValue(oArrayItem, oPathFragments(1))
|
||||||
|
|
||||||
|
If Not IsNothing(oResult) Then
|
||||||
|
oResults.Add(oResult)
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oResults
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return New List(Of Object) From {Obj}
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function GetFinalPropValue(List As List(Of Object)) As List(Of Object)
|
||||||
|
Dim oResult As New List(Of Object)
|
||||||
|
|
||||||
|
For Each Item In List
|
||||||
|
Dim oItemValue = DoGetFinalPropValue(Item)
|
||||||
|
|
||||||
|
If Not IsNothing(oItemValue) Then
|
||||||
|
oResult.Add(oItemValue)
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oResult
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function DoGetFinalPropValue(Value As Object) As String
|
||||||
|
If TypeOf Value Is List(Of Object) Then
|
||||||
|
Dim oList = DirectCast(Value, List(Of Object))
|
||||||
|
Dim oCount = oList.Count
|
||||||
|
|
||||||
|
Select Case oCount
|
||||||
|
Case 0
|
||||||
|
Return Nothing
|
||||||
|
Case Else
|
||||||
|
Return DoGetFinalPropValue(oList.First())
|
||||||
|
End Select
|
||||||
|
|
||||||
|
Return DoGetFinalPropValue(Value)
|
||||||
|
Else
|
||||||
|
Return Value.ToString
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function GetIndex(Prop As String) As Integer
|
||||||
|
If Regex.IsMatch(Prop, _indexPattern) Then
|
||||||
|
Dim oMatch = _indexRegex.Match(Prop)
|
||||||
|
Dim oGroup = oMatch.Groups.Item(1)
|
||||||
|
Dim oValue = oGroup.Value
|
||||||
|
|
||||||
|
Return Integer.Parse(oValue)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return Nothing
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function StripIndex(Prop As String) As String
|
||||||
|
Return Regex.Replace(Prop, _indexPattern, "")
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function HasIndex(Prop As String) As Boolean
|
||||||
|
Return Regex.IsMatch(Prop, _indexPattern)
|
||||||
|
End Function
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net461" />
|
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
197
Modules.Jobs/EDMI/ZUGFeRD/EmailFunctions.vb
Normal file
197
Modules.Jobs/EDMI/ZUGFeRD/EmailFunctions.vb
Normal file
@@ -0,0 +1,197 @@
|
|||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
Imports DigitalData.Modules.Database
|
||||||
|
Imports System.Data
|
||||||
|
Imports System.IO
|
||||||
|
|
||||||
|
Public Class EmailFunctions
|
||||||
|
Private ReadOnly _logConfig As LogConfig
|
||||||
|
Private ReadOnly _logger As Logger
|
||||||
|
Private ReadOnly _mssql As MSSQLServer
|
||||||
|
Private ReadOnly _firebird As Firebird
|
||||||
|
|
||||||
|
Public Sub New(LogConfig As LogConfig, MSSQL As MSSQLServer, Firebird As Firebird)
|
||||||
|
_logConfig = LogConfig
|
||||||
|
_logger = _logConfig.GetLogger()
|
||||||
|
_mssql = MSSQL
|
||||||
|
_firebird = Firebird
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Sub AddToEmailQueueFB(MessageId As String, BodyText As String, EmailData As EmailData)
|
||||||
|
If EmailData Is Nothing Then
|
||||||
|
_logger.Warn("EmailData is empty. Email will not be sent!")
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
|
||||||
|
Try
|
||||||
|
Dim oJobId = RandomValue(1, 10000)
|
||||||
|
Dim oReference = MessageId
|
||||||
|
Dim oEmailTo = ""
|
||||||
|
Dim oSubject = EmailStrings.EMAIL_SUBJECT
|
||||||
|
Dim oAccountId = 1
|
||||||
|
Dim oCreatedWho = "ZUGFeRD Service"
|
||||||
|
Dim oFinalBodyText = String.Format(EmailStrings.EMAIL_WRAPPING_TEXT, BodyText)
|
||||||
|
|
||||||
|
Dim oEmailAddress = EmailData.From
|
||||||
|
Dim oAttachment = EmailData.Attachment
|
||||||
|
|
||||||
|
If IsNothing(oEmailAddress) OrElse String.IsNullOrWhiteSpace(oEmailAddress) Then
|
||||||
|
_logger.Warn("Could not find email-address for MessageId {0}", MessageId)
|
||||||
|
oEmailTo = String.Empty
|
||||||
|
Else
|
||||||
|
oEmailTo = oEmailAddress
|
||||||
|
End If
|
||||||
|
|
||||||
|
_logger.Debug("Generated Email:")
|
||||||
|
_logger.Debug("To: {0}", oEmailTo)
|
||||||
|
_logger.Debug("Subject: {0}", oSubject)
|
||||||
|
_logger.Debug("Body {0}", oFinalBodyText)
|
||||||
|
Dim osql = $"select * from TBEDM_EMAIL_QUEUE where REFERENCE1 = '{oReference} and EMAIL_TO = ''{oEmailTo}' and EMAIL_SUBJ = '{oSubject}'"
|
||||||
|
|
||||||
|
Dim oDTResult As DataTable = _firebird.GetDatatable(osql)
|
||||||
|
|
||||||
|
If oDTResult.Rows.Count = 0 Then
|
||||||
|
Dim oSQLInsert = $"INSERT INTO TBEDM_EMAIL_QUEUE "
|
||||||
|
oSQLInsert &= "(JOB_ID, REFERENCE1, EMAIL_ACCOUNT_ID, EMAIL_TO, EMAIL_SUBJ, EMAIL_BODY, CREATEDWHO, EMAIL_ATTMT1) VALUES "
|
||||||
|
oSQLInsert &= $"({oJobId}, '{oReference}', {oAccountId}, '{oEmailTo}', '{oSubject}', '{oFinalBodyText.Replace("'", "''")}', '{oCreatedWho}', '{oAttachment}')"
|
||||||
|
_firebird.ExecuteNonQuery(oSQLInsert)
|
||||||
|
_logger.Debug("Email Queue updated for MessageId {0}.", MessageId, oEmailTo)
|
||||||
|
Else
|
||||||
|
_logger.Debug("Email has already been sent!!")
|
||||||
|
End If
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
End Try
|
||||||
|
End Sub
|
||||||
|
Public Sub AddToEmailQueueMSSQL(MessageId As String, BodyText As String, pEmailData As EmailData, SourceProcedure As String)
|
||||||
|
If pEmailData Is Nothing Then
|
||||||
|
_logger.Warn("EmailData is empty. Email will not be sent!")
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
|
||||||
|
Try
|
||||||
|
Dim oJobId = RandomValue(1, 10000)
|
||||||
|
Dim oReference = MessageId
|
||||||
|
Dim oEmailTo = ""
|
||||||
|
Dim oSubject = EmailStrings.EMAIL_SUBJECT
|
||||||
|
Dim oAccountId = 1
|
||||||
|
Dim oCreatedWho = "ZUGFeRD Service"
|
||||||
|
Dim oFinalBodyText = String.Format(EmailStrings.EMAIL_WRAPPING_TEXT, BodyText)
|
||||||
|
|
||||||
|
Dim oEmailAddress = pEmailData.From
|
||||||
|
Dim oAttachment = pEmailData.Attachment
|
||||||
|
If oAttachment <> String.Empty Then
|
||||||
|
_logger.Debug($"Attachment_String [{oAttachment}]!")
|
||||||
|
If IO.File.Exists(oAttachment) = False Then
|
||||||
|
_logger.Info($"Attachment.File [{oAttachment}] is not existing!!!")
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
If IsNothing(oEmailAddress) OrElse String.IsNullOrWhiteSpace(oEmailAddress) Then
|
||||||
|
_logger.Warn("Could not find email-address for MessageId {0}", MessageId)
|
||||||
|
oEmailTo = String.Empty
|
||||||
|
Else
|
||||||
|
oEmailTo = oEmailAddress
|
||||||
|
End If
|
||||||
|
|
||||||
|
_logger.Debug("Generated Email:")
|
||||||
|
_logger.Debug("To: {0}", oEmailTo)
|
||||||
|
_logger.Debug("Subject: {0}", oSubject)
|
||||||
|
_logger.Debug("Body {0}", oFinalBodyText)
|
||||||
|
Dim osql = $"Select MAX(GUID) FROM TBEMLP_HISTORY WHERE EMAIL_MSGID = '{MessageId}'"
|
||||||
|
Dim oHistoryID = _mssql.GetScalarValue(osql)
|
||||||
|
|
||||||
|
'osql = $"select * from TBEMLP_EMAIL_OUT where REFERENCE_ID = {oHistoryID} and EMAIL_ADRESS = '{oEmailTo}' and EMAIL_SUBJ = '{oSubject}'"
|
||||||
|
|
||||||
|
'Dim oDTResult As DataTable = _mssql.GetDatatable(osql)
|
||||||
|
|
||||||
|
If IsNumeric(oHistoryID) Then
|
||||||
|
Dim oInsert = $"INSERT INTO [dbo].[TBEMLP_EMAIL_OUT] (
|
||||||
|
[REMINDER_TYPE_ID]
|
||||||
|
,[SENDING_PROFILE]
|
||||||
|
,[REFERENCE_ID]
|
||||||
|
,[REFERENCE_STRING]
|
||||||
|
,[WF_ID]
|
||||||
|
,[EMAIL_ADRESS]
|
||||||
|
,[EMAIL_SUBJ]
|
||||||
|
,[EMAIL_BODY]
|
||||||
|
,[COMMENT]
|
||||||
|
,[ADDED_WHO]
|
||||||
|
,EMAIL_ATTMT1)
|
||||||
|
VALUES
|
||||||
|
(77
|
||||||
|
,{oAccountId}
|
||||||
|
,{oHistoryID}
|
||||||
|
,'{MessageId}'
|
||||||
|
,77
|
||||||
|
,'{oEmailTo}'
|
||||||
|
,'{oSubject}'
|
||||||
|
,'{oFinalBodyText}'
|
||||||
|
,'{SourceProcedure}'
|
||||||
|
,'{oCreatedWho}'
|
||||||
|
,'{oAttachment}')"
|
||||||
|
_mssql.ExecuteNonQuery(oInsert)
|
||||||
|
Else
|
||||||
|
'If oDTResult.Rows.Count = 0 Then
|
||||||
|
' _logger.Debug("Email has already been sent!!")
|
||||||
|
'Else
|
||||||
|
_logger.Warn("Could not get oHistoryID in AddToEmailQueueMSSQL!!")
|
||||||
|
' End If
|
||||||
|
End If
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
End Try
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Function GetEmailDataForMessageId(MessageId As String) As EmailData
|
||||||
|
Dim oSQL = $"SELECT EMAIL_FROM, EMAIL_SUBJECT, EMAIL_ATTMT1 FROM TBEDM_EMAIL_PROFILER_HISTORY WHERE EMAIL_MSGID = '{MessageId}'"
|
||||||
|
Try
|
||||||
|
Dim oDatatable = _firebird.GetDatatable(oSQL)
|
||||||
|
Dim oRow As DataRow
|
||||||
|
|
||||||
|
If oDatatable.Rows.Count = 0 Then
|
||||||
|
_logger.Warn("Got no results for MessageId {0}", MessageId)
|
||||||
|
Return Nothing
|
||||||
|
ElseIf oDatatable.Rows.Count > 1 Then
|
||||||
|
_logger.Warn("Got too many results for MessageId {0}. Using last row.", MessageId)
|
||||||
|
End If
|
||||||
|
|
||||||
|
_logger.Debug("Got Email Data for FileId {0}", MessageId)
|
||||||
|
oRow = oDatatable.Rows.Item(oDatatable.Rows.Count - 1)
|
||||||
|
|
||||||
|
Return New EmailData() With {
|
||||||
|
.From = oRow.Item("EMAIL_FROM"),
|
||||||
|
.Attachment = oRow.Item("EMAIL_ATTMT1"),
|
||||||
|
.Subject = oRow.Item("EMAIL_SUBJECT")
|
||||||
|
}
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Warn("Could not fetch Email Data for FileId {0}", MessageId)
|
||||||
|
Return Nothing
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function GetOriginalEmailPath(OriginalEmailDirectory As String, MessageId As String) As String
|
||||||
|
Dim oAttachmentDirectory = OriginalEmailDirectory
|
||||||
|
Dim oAttachmentFile = MessageId & ".eml"
|
||||||
|
Dim oAttachmentPath = Path.Combine(oAttachmentDirectory, oAttachmentFile)
|
||||||
|
|
||||||
|
If IO.File.Exists(oAttachmentPath) Then
|
||||||
|
Return oAttachmentPath
|
||||||
|
Else
|
||||||
|
Return String.Empty
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function GetEmailPathWithSubjectAsName(RejectedEmailDirectory As String, UncleanedSubject As String) As String
|
||||||
|
Dim oCleanSubject = String.Join("", UncleanedSubject.Split(Path.GetInvalidPathChars()))
|
||||||
|
Dim oAttachmentDirectory = RejectedEmailDirectory
|
||||||
|
Dim oAttachmentFile = oCleanSubject & ".eml"
|
||||||
|
Dim oAttachmentPath = Path.Combine(oAttachmentDirectory, oAttachmentFile)
|
||||||
|
|
||||||
|
Return oAttachmentPath
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Function RandomValue(lowerBound As Integer, upperBound As Integer) As Integer
|
||||||
|
Dim oRandomValue = CInt(Math.Floor((upperBound - lowerBound + 1) * Rnd())) + lowerBound
|
||||||
|
Return oRandomValue
|
||||||
|
End Function
|
||||||
|
End Class
|
||||||
18
Modules.Jobs/EDMI/ZUGFeRD/EmailStrings.vb
Normal file
18
Modules.Jobs/EDMI/ZUGFeRD/EmailStrings.vb
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
Public Class EmailStrings
|
||||||
|
Public Const EMAIL_WRAPPING_TEXT = "<html><body style=''font-family:""Arial"";font-size:10.0pt''>Sehr geehrte Damen und Herren,<br>
|
||||||
|
das WISAG-Portal zur Verarbeitung der Eingangsrechnungen im ZUGFeRD-Format konnte die von Ihnen gesandte Rechnung
|
||||||
|
leider nicht verarbeiten! <br><br> Grund: {0}<p>Bitte prüfen Sie die Datei und nehmen Sie bei Bedarf mit uns Kontakt auf.<p>
|
||||||
|
Vielen Dank für Ihr Verständnis.<br>Mit freundlichen Grüßen<br>Ihre IT-Abteilung</body></html>"
|
||||||
|
Public Const EMAIL_SUBJECT = "WISAG ZUGFeRD Portal: Beleg abgelehnt"
|
||||||
|
Public Const EMAIL_MISSINGPROPERTIES_1 = "<p>Die angehängte Datei entspricht nicht dem WISAG ZUGFeRD-Format: {0}</p>"
|
||||||
|
Public Const EMAIL_MISSINGPROPERTIES_2 = "<p>Die folgenden Eigenschaften wurden als ERFORDERLICH eingestuft, wurden aber nicht gefunden:<p/>"
|
||||||
|
Public Const EMAIL_MD5_ERROR = "<p>Die von Ihnen gesendete Rechnung wurde bereits von unserem System verarbeitet.</p>"
|
||||||
|
Public Const EMAIL_TOO_MUCH_FERDS = "<p>Ihre Email enthielt mehr als ein ZUGFeRD-Dokument.</p>"
|
||||||
|
Public Const EMAIL_NO_FERDS = "<p>Ihre Email enthielt keine ZUGFeRD-Dokumente.</p>"
|
||||||
|
Public Const EMAIL_INVALID_DOCUMENT = """
|
||||||
|
<p>Ihre Email enthielt ein ZUGFeRD Dokument, welches aber inkorrekt formatiert wurde.</p>
|
||||||
|
<p>Mögliche Gründe für ein inkorrektes Format:<ul>
|
||||||
|
<li>Betrags-Werte weisen ungültiges Format auf (25,01 anstatt 25.01)</li>
|
||||||
|
</ul></p>
|
||||||
|
"""
|
||||||
|
End Class
|
||||||
@@ -26,106 +26,47 @@ Public Class ImportZUGFeRDFiles
|
|||||||
Public Const ZUGFERD_ATTACHMENTS = "ZUGFeRD Attachments"
|
Public Const ZUGFERD_ATTACHMENTS = "ZUGFeRD Attachments"
|
||||||
Public HISTORY_ID As Integer
|
Public HISTORY_ID As Integer
|
||||||
|
|
||||||
Private Const EMAIL_WRAPPING_TEXT = "<html><body style=''font-family:""Arial"";font-size:10.0pt''>Sehr geehrte Damen und Herren,<br>
|
|
||||||
das WISAG-Portal zur Verarbeitung der Eingangsrechnungen im ZUGFeRD-Format konnte die von Ihnen gesandte Rechnung
|
|
||||||
leider nicht verarbeiten! <br><br> Grund: {0}<p>Bitte prüfen Sie die Datei und nehmen Sie bei Bedarf mit uns Kontakt auf.<p>
|
|
||||||
Vielen Dank für Ihr Verständnis.<br>Mit freundlichen Grüßen<br>Ihre IT-Abteilung</body></html>"
|
|
||||||
Private Const EMAIL_SUBJECT = "WISAG ZUGFeRD Portal: Beleg abgelehnt"
|
|
||||||
Private Const EMAIL_MISSINGPROPERTIES_1 = "<p>Die angehängte Datei entspricht nicht dem WISAG ZUGFeRD-Format: {0}</p>"
|
|
||||||
Private Const EMAIL_MISSINGPROPERTIES_2 = "<p>Die folgenden Eigenschaften wurden als ERFORDERLICH eingestuft, wurden aber nicht gefunden:<p/>"
|
|
||||||
Private Const EMAIL_MD5_ERROR = "<p>Die von Ihnen gesendete Rechnung wurde bereits von unserem System verarbeitet.</p>"
|
|
||||||
Private Const EMAIL_TOO_MUCH_FERDS = "<p>Ihre Email enthielt mehr als ein ZUGFeRD-Dokument.</p>"
|
|
||||||
Private Const EMAIL_NO_FERDS = "<p>Ihre Email enthielt keine ZUGFeRD-Dokumente.</p>"
|
|
||||||
Private Const EMAIL_INVALID_DOCUMENT = """
|
|
||||||
<p>Ihre Email enthielt ein ZUGFeRD Dokument, welches aber inkorrekt formatiert wurde.</p>
|
|
||||||
<p>Mögliche Gründe für ein inkorrektes Format:<ul>
|
|
||||||
<li>Betrags-Werte weisen ungültiges Format auf (25,01 anstatt 25.01)</li>
|
|
||||||
</ul></p>
|
|
||||||
"""
|
|
||||||
|
|
||||||
' List of allowed extensions for PDF/A Attachments
|
' List of allowed extensions for PDF/A Attachments
|
||||||
Private AllowedExtensions = New List(Of String) From {"docx", "doc", "pdf", "xls", "xlsx", "ppt", "pptx", "txt"}
|
Private ReadOnly AllowedExtensions As List(Of String) = New List(Of String) From {"docx", "doc", "pdf", "xls", "xlsx", "ppt", "pptx", "txt"}
|
||||||
|
|
||||||
Private _logger As Logger
|
Private ReadOnly _logger As Logger
|
||||||
Private _logConfig As LogConfig
|
Private ReadOnly _logConfig As LogConfig
|
||||||
Private _zugferd As ZUGFeRDInterface
|
Private ReadOnly _zugferd As ZUGFeRDInterface
|
||||||
Private _firebird As Firebird
|
Private ReadOnly _firebird As Firebird
|
||||||
Private _filesystem As Filesystem.File
|
Private ReadOnly _filesystem As Filesystem.File
|
||||||
Private _mssql As MSSQLServer
|
Private ReadOnly _mssql As MSSQLServer
|
||||||
|
Private ReadOnly _email As EmailFunctions
|
||||||
|
|
||||||
Public Sub New(LogConfig As LogConfig, Firebird As Firebird, Optional MSSQL As MSSQLServer = Nothing)
|
Public Sub New(LogConfig As LogConfig, Firebird As Firebird, Optional MSSQL As MSSQLServer = Nothing)
|
||||||
_logConfig = LogConfig
|
_logConfig = LogConfig
|
||||||
_logger = LogConfig.GetLogger()
|
_logger = LogConfig.GetLogger()
|
||||||
_firebird = Firebird
|
_firebird = Firebird
|
||||||
_filesystem = New Filesystem.File(_logConfig)
|
_filesystem = New Filesystem.File(_logConfig)
|
||||||
_zugferd = New ZUGFeRDInterface(_logConfig)
|
|
||||||
_mssql = MSSQL
|
_mssql = MSSQL
|
||||||
|
_email = New EmailFunctions(LogConfig, _mssql, _firebird)
|
||||||
|
|
||||||
|
_logger.Debug("Registering GDPicture License")
|
||||||
|
If _mssql IsNot Nothing Then
|
||||||
|
Dim oSQL = "SELECT LICENSE FROM TBDD_3RD_PARTY_MODULES WHERE NAME = 'GDPICTURE'"
|
||||||
|
Dim oLicenseKey As String = _mssql.GetScalarValue(oSQL)
|
||||||
|
_zugferd = New ZUGFeRDInterface(_logConfig, oLicenseKey)
|
||||||
|
Else
|
||||||
|
_logger.Warn("GDPicture License could not be registered! MSSQL is not enabled!")
|
||||||
|
Throw New ArgumentNullException("MSSQL")
|
||||||
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Function RandomValue(lowerBound As Integer, upperBound As Integer) As Integer
|
|
||||||
Dim oRandomValue = CInt(Math.Floor((upperBound - lowerBound + 1) * Rnd())) + lowerBound
|
|
||||||
Return oRandomValue
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function GetEmailDataForMessageId(MessageId As String) As EmailData
|
|
||||||
Dim oSQL = $"SELECT EMAIL_FROM, EMAIL_SUBJECT, EMAIL_ATTMT1 FROM TBEDM_EMAIL_PROFILER_HISTORY WHERE EMAIL_MSGID = '{MessageId}'"
|
|
||||||
Try
|
|
||||||
Dim oDatatable = _firebird.GetDatatable(oSQL)
|
|
||||||
Dim oRow As DataRow
|
|
||||||
|
|
||||||
If oDatatable.Rows.Count = 0 Then
|
|
||||||
_logger.Warn("Got no results for MessageId {0}", MessageId)
|
|
||||||
Return Nothing
|
|
||||||
ElseIf oDatatable.Rows.Count > 1 Then
|
|
||||||
_logger.Warn("Got too many results for MessageId {0}. Using last row.", MessageId)
|
|
||||||
End If
|
|
||||||
|
|
||||||
_logger.Debug("Got Email Data for FileId {0}", MessageId)
|
|
||||||
oRow = oDatatable.Rows.Item(oDatatable.Rows.Count - 1)
|
|
||||||
|
|
||||||
Return New EmailData() With {
|
|
||||||
.From = oRow.Item("EMAIL_FROM"),
|
|
||||||
.Attachment = oRow.Item("EMAIL_ATTMT1"),
|
|
||||||
.Subject = oRow.Item("EMAIL_SUBJECT")
|
|
||||||
}
|
|
||||||
Catch ex As Exception
|
|
||||||
_logger.Warn("Could not fetch Email Data for FileId {0}", MessageId)
|
|
||||||
Return Nothing
|
|
||||||
End Try
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function GetOriginalEmailPath(OriginalEmailDirectory As String, MessageId As String) As String
|
|
||||||
Dim oAttachmentDirectory = OriginalEmailDirectory
|
|
||||||
Dim oAttachmentFile = MessageId & ".eml"
|
|
||||||
Dim oAttachmentPath = Path.Combine(oAttachmentDirectory, oAttachmentFile)
|
|
||||||
|
|
||||||
If IO.File.Exists(oAttachmentPath) Then
|
|
||||||
Return oAttachmentPath
|
|
||||||
Else
|
|
||||||
Return String.Empty
|
|
||||||
End If
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function GetEmailPathWithSubjectAsName(RejectedEmailDirectory As String, UncleanedSubject As String) As String
|
|
||||||
Dim oCleanSubject = String.Join("", UncleanedSubject.Split(Path.GetInvalidPathChars()))
|
|
||||||
Dim oAttachmentDirectory = RejectedEmailDirectory
|
|
||||||
Dim oAttachmentFile = oCleanSubject & ".eml"
|
|
||||||
Dim oAttachmentPath = Path.Combine(oAttachmentDirectory, oAttachmentFile)
|
|
||||||
|
|
||||||
Return oAttachmentPath
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function MoveAndRenameEmailToRejected(Args As WorkerArgs, MessageId As String) As EmailData
|
Private Function MoveAndRenameEmailToRejected(Args As WorkerArgs, MessageId As String) As EmailData
|
||||||
Dim oEmailData = GetEmailDataForMessageId(MessageId)
|
Dim oEmailData = _email.GetEmailDataForMessageId(MessageId)
|
||||||
Dim oSource = GetOriginalEmailPath(Args.OriginalEmailDirectory, MessageId)
|
Dim oSource = _email.GetOriginalEmailPath(Args.OriginalEmailDirectory, MessageId)
|
||||||
Dim oDestination As String
|
Dim oDestination As String
|
||||||
|
|
||||||
' If oEmailData is Nothing, TBEDM_EMAIL_PROFILER_HISTORY for MessageId was not found.
|
' If oEmailData is Nothing, TBEDM_EMAIL_PROFILER_HISTORY for MessageId was not found.
|
||||||
' This only should happen when testing and db-tables are deleted frequently
|
' This only should happen when testing and db-tables are deleted frequently
|
||||||
If oEmailData Is Nothing Then
|
If oEmailData Is Nothing Then
|
||||||
oDestination = GetEmailPathWithSubjectAsName(Args.RejectedEmailDirectory, MessageId)
|
oDestination = _email.GetEmailPathWithSubjectAsName(Args.RejectedEmailDirectory, MessageId)
|
||||||
Else
|
Else
|
||||||
oDestination = GetEmailPathWithSubjectAsName(Args.RejectedEmailDirectory, oEmailData.Subject)
|
oDestination = _email.GetEmailPathWithSubjectAsName(Args.RejectedEmailDirectory, oEmailData.Subject)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
_logger.Debug("Destination for eml file is {0}", oDestination)
|
_logger.Debug("Destination for eml file is {0}", oDestination)
|
||||||
@@ -154,179 +95,14 @@ Public Class ImportZUGFeRDFiles
|
|||||||
|
|
||||||
Private Sub AddRejectedState(oMessageID As String, oTitle As String, oTitle1 As String, oComment As String)
|
Private Sub AddRejectedState(oMessageID As String, oTitle As String, oTitle1 As String, oComment As String)
|
||||||
Try
|
Try
|
||||||
|
'PRCUST_ADD_HISTORY_STATE: @MessageID VARCHAR(250), @TITLE1 VARCHAR(250), @TITLE2 VARCHAR(250)
|
||||||
Dim oSQL = $"EXEC PRCUST_ADD_HISTORY_STATE '{oMessageID}','{oTitle}','{oTitle1}','{oComment}'"
|
Dim oSQL = $"EXEC PRCUST_ADD_HISTORY_STATE '{oMessageID}','{oTitle}','{oTitle1}','{oComment}'"
|
||||||
_mssql.NewExecutenonQuery(oSQL)
|
_mssql.NewExecutenonQuery(oSQL)
|
||||||
'@MessageID VARCHAR(250), @TITLE1 VARCHAR(250), @TITLE2 VARCHAR(250)
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
_logger.Error(ex)
|
_logger.Error(ex)
|
||||||
End Try
|
End Try
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub AddToEmailQueueFB(MessageId As String, BodyText As String, EmailData As EmailData)
|
|
||||||
If EmailData Is Nothing Then
|
|
||||||
_logger.Warn("EmailData is empty. Email will not be sent!")
|
|
||||||
Exit Sub
|
|
||||||
End If
|
|
||||||
|
|
||||||
Try
|
|
||||||
Dim oJobId = RandomValue(1, 10000)
|
|
||||||
Dim oReference = MessageId
|
|
||||||
Dim oEmailTo = ""
|
|
||||||
Dim oSubject = EMAIL_SUBJECT
|
|
||||||
Dim oAccountId = 1
|
|
||||||
Dim oCreatedWho = "ZUGFeRD Service"
|
|
||||||
Dim oFinalBodyText = String.Format(EMAIL_WRAPPING_TEXT, BodyText)
|
|
||||||
|
|
||||||
Dim oEmailAddress = EmailData.From
|
|
||||||
Dim oAttachment = EmailData.Attachment
|
|
||||||
|
|
||||||
If IsNothing(oEmailAddress) OrElse String.IsNullOrWhiteSpace(oEmailAddress) Then
|
|
||||||
_logger.Warn("Could not find email-address for MessageId {0}", MessageId)
|
|
||||||
oEmailTo = String.Empty
|
|
||||||
Else
|
|
||||||
oEmailTo = oEmailAddress
|
|
||||||
End If
|
|
||||||
|
|
||||||
_logger.Debug("Generated Email:")
|
|
||||||
_logger.Debug("To: {0}", oEmailTo)
|
|
||||||
_logger.Debug("Subject: {0}", oSubject)
|
|
||||||
_logger.Debug("Body {0}", oFinalBodyText)
|
|
||||||
Dim osql = $"select * from TBEDM_EMAIL_QUEUE where REFERENCE1 = '{oReference} and EMAIL_TO = ''{oEmailTo}' and EMAIL_SUBJ = '{oSubject}'"
|
|
||||||
|
|
||||||
Dim oDTResult As DataTable = _firebird.GetDatatable(osql)
|
|
||||||
|
|
||||||
If oDTResult.Rows.Count = 0 Then
|
|
||||||
Dim oSQLInsert = $"INSERT INTO TBEDM_EMAIL_QUEUE "
|
|
||||||
oSQLInsert &= "(JOB_ID, REFERENCE1, EMAIL_ACCOUNT_ID, EMAIL_TO, EMAIL_SUBJ, EMAIL_BODY, CREATEDWHO, EMAIL_ATTMT1) VALUES "
|
|
||||||
oSQLInsert &= $"({oJobId}, '{oReference}', {oAccountId}, '{oEmailTo}', '{oSubject}', '{oFinalBodyText.Replace("'", "''")}', '{oCreatedWho}', '{oAttachment}')"
|
|
||||||
_firebird.ExecuteNonQuery(oSQLInsert)
|
|
||||||
_logger.Debug("Email Queue updated for MessageId {0}.", MessageId, oEmailTo)
|
|
||||||
Else
|
|
||||||
_logger.Debug("Email has already been sent!!")
|
|
||||||
End If
|
|
||||||
Catch ex As Exception
|
|
||||||
_logger.Error(ex)
|
|
||||||
End Try
|
|
||||||
End Sub
|
|
||||||
Private Sub AddToEmailQueueMSSQL(MessageId As String, BodyText As String, pEmailData As EmailData, SourceProcedure As String)
|
|
||||||
If pEmailData Is Nothing Then
|
|
||||||
_logger.Warn("EmailData is empty. Email will not be sent!")
|
|
||||||
Exit Sub
|
|
||||||
End If
|
|
||||||
|
|
||||||
Try
|
|
||||||
Dim oJobId = RandomValue(1, 10000)
|
|
||||||
Dim oReference = MessageId
|
|
||||||
Dim oEmailTo = ""
|
|
||||||
Dim oSubject = EMAIL_SUBJECT
|
|
||||||
Dim oAccountId = 1
|
|
||||||
Dim oCreatedWho = "ZUGFeRD Service"
|
|
||||||
Dim oFinalBodyText = String.Format(EMAIL_WRAPPING_TEXT, BodyText)
|
|
||||||
|
|
||||||
Dim oEmailAddress = pEmailData.From
|
|
||||||
Dim oAttachment = pEmailData.Attachment
|
|
||||||
If oAttachment <> String.Empty Then
|
|
||||||
_logger.Debug($"Attachment_String [{oAttachment}]!")
|
|
||||||
If IO.File.Exists(oAttachment) = False Then
|
|
||||||
_logger.Info($"Attachment.File [{oAttachment}] is not existing!!!")
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
If IsNothing(oEmailAddress) OrElse String.IsNullOrWhiteSpace(oEmailAddress) Then
|
|
||||||
_logger.Warn("Could not find email-address for MessageId {0}", MessageId)
|
|
||||||
oEmailTo = String.Empty
|
|
||||||
Else
|
|
||||||
oEmailTo = oEmailAddress
|
|
||||||
End If
|
|
||||||
|
|
||||||
_logger.Debug("Generated Email:")
|
|
||||||
_logger.Debug("To: {0}", oEmailTo)
|
|
||||||
_logger.Debug("Subject: {0}", oSubject)
|
|
||||||
_logger.Debug("Body {0}", oFinalBodyText)
|
|
||||||
Dim osql = $"Select MAX(GUID) FROM TBEMLP_HISTORY WHERE EMAIL_MSGID = '{MessageId}'"
|
|
||||||
Dim oHistoryID = _mssql.GetScalarValue(osql)
|
|
||||||
|
|
||||||
'osql = $"select * from TBEMLP_EMAIL_OUT where REFERENCE_ID = {oHistoryID} and EMAIL_ADRESS = '{oEmailTo}' and EMAIL_SUBJ = '{oSubject}'"
|
|
||||||
|
|
||||||
'Dim oDTResult As DataTable = _mssql.GetDatatable(osql)
|
|
||||||
|
|
||||||
If IsNumeric(oHistoryID) Then
|
|
||||||
Dim oInsert = $"INSERT INTO [dbo].[TBEMLP_EMAIL_OUT] (
|
|
||||||
[REMINDER_TYPE_ID]
|
|
||||||
,[SENDING_PROFILE]
|
|
||||||
,[REFERENCE_ID]
|
|
||||||
,[REFERENCE_STRING]
|
|
||||||
,[WF_ID]
|
|
||||||
,[EMAIL_ADRESS]
|
|
||||||
,[EMAIL_SUBJ]
|
|
||||||
,[EMAIL_BODY]
|
|
||||||
,[COMMENT]
|
|
||||||
,[ADDED_WHO]
|
|
||||||
,EMAIL_ATTMT1)
|
|
||||||
VALUES
|
|
||||||
(77
|
|
||||||
,{oAccountId}
|
|
||||||
,{oHistoryID}
|
|
||||||
,'{MessageId}'
|
|
||||||
,77
|
|
||||||
,'{oEmailTo}'
|
|
||||||
,'{oSubject}'
|
|
||||||
,'{oFinalBodyText}'
|
|
||||||
,'{SourceProcedure}'
|
|
||||||
,'{oCreatedWho}'
|
|
||||||
,'{oAttachment}')"
|
|
||||||
_mssql.ExecuteNonQuery(oInsert)
|
|
||||||
Else
|
|
||||||
'If oDTResult.Rows.Count = 0 Then
|
|
||||||
' _logger.Debug("Email has already been sent!!")
|
|
||||||
'Else
|
|
||||||
_logger.Warn("Could not get oHistoryID in AddToEmailQueueMSSQL!!")
|
|
||||||
' End If
|
|
||||||
End If
|
|
||||||
Catch ex As Exception
|
|
||||||
_logger.Error(ex)
|
|
||||||
End Try
|
|
||||||
End Sub
|
|
||||||
Private Function GetMessageIdFromFileName(Filename As String) As String
|
|
||||||
' Regex to find MessageId
|
|
||||||
' See also: https://stackoverflow.com/questions/3968500/regex-to-validate-a-message-id-as-per-rfc2822
|
|
||||||
Dim oRegex = "(((([a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*)|(""(([\x01-\x08\x0B\x0C\x0E-\x1F\x7F]|[\x21\x23-\x5B\x5D-\x7E])|(\\[\x01-\x09\x0B\x0C\x0E-\x7F]))*""))@(([a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*)|(\[(([\x01-\x08\x0B\x0C\x0E-\x1F\x7F]|[\x21-\x5A\x5E-\x7E])|(\\[\x01-\x09\x0B\x0C\x0E-\x7F]))*\]))))~.+"
|
|
||||||
Dim oMatch = Regex.Match(Filename, oRegex, RegexOptions.IgnoreCase)
|
|
||||||
|
|
||||||
If oMatch.Success Then
|
|
||||||
Dim oMessageId = oMatch.Groups(1).Value
|
|
||||||
Return oMessageId
|
|
||||||
Else
|
|
||||||
Return Nothing
|
|
||||||
End If
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function GroupFiles(Files As List(Of FileInfo)) As Dictionary(Of String, List(Of FileInfo))
|
|
||||||
Dim oGrouped As New Dictionary(Of String, List(Of FileInfo))
|
|
||||||
|
|
||||||
If Files.Count = 0 Then
|
|
||||||
Return oGrouped
|
|
||||||
End If
|
|
||||||
|
|
||||||
For Each oFile In Files
|
|
||||||
Dim oMessageId = GetMessageIdFromFileName(oFile.Name)
|
|
||||||
|
|
||||||
If oMessageId Is Nothing Then
|
|
||||||
_logger.Warn("File {0} did not have the required filename-format!", oMessageId)
|
|
||||||
Continue For
|
|
||||||
End If
|
|
||||||
|
|
||||||
If oGrouped.ContainsKey(oMessageId) Then
|
|
||||||
oGrouped.Item(oMessageId).Add(oFile)
|
|
||||||
Else
|
|
||||||
oGrouped.Add(oMessageId, New List(Of FileInfo) From {oFile})
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
Return oGrouped
|
|
||||||
End Function
|
|
||||||
|
|
||||||
|
|
||||||
Public Sub Start(Arguments As Object) Implements IJob.Start
|
Public Sub Start(Arguments As Object) Implements IJob.Start
|
||||||
Dim oArgs As WorkerArgs = Arguments
|
Dim oArgs As WorkerArgs = Arguments
|
||||||
Dim oPropertyExtractor = New PropertyValues(_logConfig)
|
Dim oPropertyExtractor = New PropertyValues(_logConfig)
|
||||||
@@ -334,23 +110,6 @@ Public Class ImportZUGFeRDFiles
|
|||||||
|
|
||||||
_logger.Debug("Starting Job {0}", [GetType].Name)
|
_logger.Debug("Starting Job {0}", [GetType].Name)
|
||||||
|
|
||||||
_logger.Debug("Registering GDPicture License")
|
|
||||||
If _mssql IsNot Nothing Then
|
|
||||||
Try
|
|
||||||
Dim oSQL = "SELECT LICENSE FROM TBDD_3RD_PARTY_MODULES WHERE NAME = 'GDPICTURE'"
|
|
||||||
Dim oLicenseKey As String = _mssql.GetScalarValue(oSQL)
|
|
||||||
Dim oLicenseManager As New LicenseManager
|
|
||||||
oLicenseManager.RegisterKEY(oLicenseKey)
|
|
||||||
Catch ex As Exception
|
|
||||||
_logger.Error(ex)
|
|
||||||
_logger.Warn("GDPicture License could not be retrieved! Query failed! Exiting job.")
|
|
||||||
Exit Sub
|
|
||||||
End Try
|
|
||||||
Else
|
|
||||||
_logger.Warn("GDPicture License could not be retrieved! MSSQL is not enabled! Exiting job.")
|
|
||||||
Exit Sub
|
|
||||||
End If
|
|
||||||
|
|
||||||
Try
|
Try
|
||||||
For Each oPath As String In oArgs.WatchDirectories
|
For Each oPath As String In oArgs.WatchDirectories
|
||||||
Dim oDirInfo As New DirectoryInfo(oPath)
|
Dim oDirInfo As New DirectoryInfo(oPath)
|
||||||
@@ -374,7 +133,7 @@ Public Class ImportZUGFeRDFiles
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
' Group files by messageId
|
' Group files by messageId
|
||||||
Dim oGrouped As Dictionary(Of String, List(Of FileInfo)) = GroupFiles(oFiles)
|
Dim oGrouped As Dictionary(Of String, List(Of FileInfo)) = _zugferd.FileGroup.GroupFiles(oFiles)
|
||||||
|
|
||||||
_logger.Info("Found {0} file groups", oGrouped.Count)
|
_logger.Info("Found {0} file groups", oGrouped.Count)
|
||||||
|
|
||||||
@@ -437,7 +196,8 @@ Public Class ImportZUGFeRDFiles
|
|||||||
End Select
|
End Select
|
||||||
End Try
|
End Try
|
||||||
|
|
||||||
' Extract all attachments other than the zugferd-invoice.xml
|
' Extract all attachments with the extensions specified in `AllowedExtensions`.
|
||||||
|
' If you need to extract and use embedded xml files, you need to filter out the zugferd-invoice.xml yourself.
|
||||||
Dim oAttachments = oAttachmentExtractor.Extract(oFile.FullName, AllowedExtensions)
|
Dim oAttachments = oAttachmentExtractor.Extract(oFile.FullName, AllowedExtensions)
|
||||||
If oAttachments Is Nothing Then
|
If oAttachments Is Nothing Then
|
||||||
_logger.Warn("Attachments for file [{0}] could not be extracted", oFile.FullName)
|
_logger.Warn("Attachments for file [{0}] could not be extracted", oFile.FullName)
|
||||||
@@ -479,157 +239,192 @@ Public Class ImportZUGFeRDFiles
|
|||||||
|
|
||||||
' Since extraction went well, increase the amount of ZUGFeRD files
|
' Since extraction went well, increase the amount of ZUGFeRD files
|
||||||
oZUGFeRDCount += 1
|
oZUGFeRDCount += 1
|
||||||
|
#Region "Check Property Values"
|
||||||
|
' --- BEGIN Check Property Values
|
||||||
|
|
||||||
' PropertyMap items with `IsGrouped = False` are handled normally
|
'' PropertyMap items with `IsGrouped = False` are handled normally
|
||||||
Dim oDefaultProperties As Dictionary(Of String, XmlItemProperty) = oArgs.PropertyMap.
|
'Dim oDefaultProperties As Dictionary(Of String, XmlItemProperty) = oArgs.PropertyMap.
|
||||||
Where(Function(Item) Item.Value.IsGrouped = False).
|
' Where(Function(Item) Item.Value.IsGrouped = True).
|
||||||
ToDictionary(Function(Item) Item.Key,
|
' ToDictionary(Function(Item) Item.Key,
|
||||||
Function(Item) Item.Value)
|
' Function(Item) Item.Value)
|
||||||
|
|
||||||
_logger.Debug("Found {0} default properties.", oDefaultProperties.Count)
|
'_logger.Debug("Found {0} default properties.", oDefaultProperties.Count)
|
||||||
|
|
||||||
' PropertyMap items with `IsGrouped = True` are grouped by group scope
|
'' PropertyMap items with `IsGrouped = True` are grouped by group scope
|
||||||
Dim oGroupedProperties = oArgs.PropertyMap.
|
'Dim oGroupedProperties = oArgs.PropertyMap.
|
||||||
Where(Function(Item) Item.Value.IsGrouped = True).
|
' Where(Function(Item) Item.Value.IsGrouped = True).
|
||||||
ToLookup(Function(Item) Item.Value.GroupScope, ' Lookup key is group scope
|
' ToLookup(Function(Item) Item.Value.GroupScope, ' Lookup key is group scope
|
||||||
Function(Item) Item)
|
' Function(Item) Item)
|
||||||
|
|
||||||
_logger.Debug("Found {0} properties grouped in {1} group(s)", oArgs.PropertyMap.Count - oDefaultProperties.Count, oGroupedProperties.Count)
|
'_logger.Debug("Found {0} properties grouped in {1} group(s)", oArgs.PropertyMap.Count - oDefaultProperties.Count, oGroupedProperties.Count)
|
||||||
' Iterate through groups to get group scope and group items
|
'' Iterate through groups to get group scope and group items
|
||||||
For Each oGroup In oGroupedProperties
|
'For Each oGroup In oGroupedProperties
|
||||||
Dim oGroupScope As String = oGroup.Key
|
' Dim oGroupScope As String = oGroup.Key
|
||||||
Dim oPropertyList As New Dictionary(Of XmlItemProperty, List(Of Object))
|
' Dim oPropertyList As New Dictionary(Of XmlItemProperty, List(Of Object))
|
||||||
Dim oRowCount = 0
|
' Dim oRowCount = 0
|
||||||
|
|
||||||
_logger.Debug("Fetching Property values for group {0}.", oGroupScope)
|
' _logger.Debug("Fetching Property values for group {0}.", oGroupScope)
|
||||||
|
|
||||||
' get properties as a nested object, see `oPropertyList`
|
' ' get properties as a nested object, see `oPropertyList`
|
||||||
For Each oProperty As KeyValuePair(Of String, XmlItemProperty) In oGroup
|
' For Each oProperty As KeyValuePair(Of String, XmlItemProperty) In oGroup
|
||||||
Dim oPropertyValues As List(Of Object)
|
' Dim oPropertyValues As List(Of Object)
|
||||||
|
|
||||||
Try
|
' Try
|
||||||
oPropertyValues = oPropertyExtractor.GetPropValue(oDocument, oProperty.Key)
|
' oPropertyValues = oPropertyExtractor.GetPropValue(oDocument, oProperty.Key)
|
||||||
Catch ex As Exception
|
' Catch ex As Exception
|
||||||
_logger.Warn("Unknown error occurred while fetching property [{0}] in group [{1}]:", oProperty.Value.Description, oGroupScope)
|
' _logger.Warn("Unknown error occurred while fetching property [{0}] in group [{1}]:", oProperty.Value.Description, oGroupScope)
|
||||||
_logger.Error(ex)
|
' _logger.Error(ex)
|
||||||
oPropertyValues = New List(Of Object)
|
' oPropertyValues = New List(Of Object)
|
||||||
End Try
|
' End Try
|
||||||
|
|
||||||
' Flatten result value
|
' ' Flatten result value
|
||||||
oPropertyValues = oPropertyExtractor.GetFinalPropValue(oPropertyValues)
|
' oPropertyValues = oPropertyExtractor.GetFinalPropValue(oPropertyValues)
|
||||||
|
|
||||||
' Add to list
|
' ' Add to list
|
||||||
oPropertyList.Add(oProperty.Value, oPropertyValues)
|
' oPropertyList.Add(oProperty.Value, oPropertyValues)
|
||||||
|
|
||||||
' check the first batch of values to determine the row count
|
' ' check the first batch of values to determine the row count
|
||||||
If oRowCount = 0 Then
|
' If oRowCount = 0 Then
|
||||||
oRowCount = oPropertyValues.Count
|
' oRowCount = oPropertyValues.Count
|
||||||
End If
|
' End If
|
||||||
Next
|
' Next
|
||||||
|
|
||||||
' Structure of oPropertyList
|
' ' Structure of oPropertyList
|
||||||
' [ # Propertyname # Row 1 # Row 2
|
' ' [ # Propertyname # Row 1 # Row 2
|
||||||
' PositionsMenge: [BilledQuantity1, BilledQuantity2, ...],
|
' ' PositionsMenge: [BilledQuantity1, BilledQuantity2, ...],
|
||||||
' PositionsSteuersatz: [ApplicablePercent1, ApplicablePercent2, ...],
|
' ' PositionsSteuersatz: [ApplicablePercent1, ApplicablePercent2, ...],
|
||||||
' ...
|
' ' ...
|
||||||
' ]
|
' ' ]
|
||||||
For oRowIndex = 0 To oRowCount - 1
|
' For oRowIndex = 0 To oRowCount - 1
|
||||||
_logger.Debug("Processing row {0}", oRowIndex)
|
' _logger.Debug("Processing row {0}", oRowIndex)
|
||||||
|
|
||||||
For Each oColumn As KeyValuePair(Of XmlItemProperty, List(Of Object)) In oPropertyList
|
' For Each oColumn As KeyValuePair(Of XmlItemProperty, List(Of Object)) In oPropertyList
|
||||||
Dim oTableName As String = oColumn.Key.TableName
|
' Dim oTableName As String = oColumn.Key.TableName
|
||||||
Dim oPropertyDescription As String = oColumn.Key.Description
|
' Dim oPropertyDescription As String = oColumn.Key.Description
|
||||||
Dim oRowCounter = oRowIndex + oGlobalGroupCounter + 1
|
' Dim oRowCounter = oRowIndex + oGlobalGroupCounter + 1
|
||||||
|
|
||||||
' Returns nothing if oColumn.Value contains an empty list
|
' ' Returns nothing if oColumn.Value contains an empty list
|
||||||
Dim oPropertyValue = oColumn.Value.ElementAtOrDefault(oRowIndex)
|
' Dim oPropertyValue = oColumn.Value.ElementAtOrDefault(oRowIndex)
|
||||||
|
|
||||||
_logger.Debug("Processing property {0}.", oPropertyDescription)
|
' _logger.Debug("Processing property {0}.", oPropertyDescription)
|
||||||
|
|
||||||
If IsNothing(oPropertyValue) OrElse String.IsNullOrEmpty(oPropertyValue) Then
|
' If IsNothing(oPropertyValue) OrElse String.IsNullOrEmpty(oPropertyValue) Then
|
||||||
If oColumn.Key.IsRequired Then
|
' If oColumn.Key.IsRequired Then
|
||||||
_logger.Warn("Property [{0}] is empty or not found but is required. Continuing with Empty String.", oPropertyDescription)
|
' _logger.Warn("Property [{0}] is empty or not found but is required. Continuing with Empty String.", oPropertyDescription)
|
||||||
oMissingProperties.Add(oPropertyDescription)
|
' oMissingProperties.Add(oPropertyDescription)
|
||||||
Else
|
' Else
|
||||||
_logger.Debug("Property [{0}] is empty or not found. Continuing with Empty String.", oPropertyDescription)
|
' _logger.Debug("Property [{0}] is empty or not found. Continuing with Empty String.", oPropertyDescription)
|
||||||
End If
|
' End If
|
||||||
|
|
||||||
oPropertyValue = String.Empty
|
' oPropertyValue = String.Empty
|
||||||
End If
|
' End If
|
||||||
|
|
||||||
_logger.Debug("Property {0} has value '{1}'", oPropertyDescription, oPropertyValue)
|
' _logger.Debug("Property {0} has value '{1}'", oPropertyDescription, oPropertyValue)
|
||||||
|
|
||||||
Dim oCommand = $"INSERT INTO {oTableName} (REFERENCE_GUID, ITEM_DESCRIPTION, ITEM_VALUE, GROUP_COUNTER) VALUES ('{oMessageId}', '{oPropertyDescription}', '{oPropertyValue}', {oRowCounter})"
|
' Dim oCommand = $"INSERT INTO {oTableName} (REFERENCE_GUID, ITEM_DESCRIPTION, ITEM_VALUE, GROUP_COUNTER) VALUES ('{oMessageId}', '{oPropertyDescription}', '{oPropertyValue}', {oRowCounter})"
|
||||||
_logger.Debug("Mapping Property {0} to value {1}. Will be inserted into table {2} with RowCounter {3}", oPropertyDescription, oPropertyValue, oTableName, oRowCounter)
|
' _logger.Debug("Mapping Property {0} to value {1}. Will be inserted into table {2} with RowCounter {3}", oPropertyDescription, oPropertyValue, oTableName, oRowCounter)
|
||||||
|
|
||||||
' Insert into SQL Server
|
' ' Insert into SQL Server
|
||||||
If oArgs.InsertIntoSQLServer = True Then
|
' If oArgs.InsertIntoSQLServer = True Then
|
||||||
Dim oResult = _mssql.NewExecutenonQuery(oCommand)
|
' Dim oResult = _mssql.NewExecutenonQuery(oCommand)
|
||||||
If oResult = False Then
|
' If oResult = False Then
|
||||||
_logger.Warn("SQL Command was not successful. Check the log.")
|
' _logger.Warn("SQL Command was not successful. Check the log.")
|
||||||
End If
|
' End If
|
||||||
End If
|
' End If
|
||||||
|
|
||||||
' Insert into Firebird
|
' ' Insert into Firebird
|
||||||
_firebird.ExecuteNonQueryWithConnection(oCommand, oConnection, Firebird.TransactionMode.ExternalTransaction, oTransaction)
|
' _firebird.ExecuteNonQueryWithConnection(oCommand, oConnection, Firebird.TransactionMode.ExternalTransaction, oTransaction)
|
||||||
Next
|
' Next
|
||||||
Next
|
' Next
|
||||||
|
|
||||||
oGlobalGroupCounter += oRowCount
|
' oGlobalGroupCounter += oRowCount
|
||||||
Next
|
'Next
|
||||||
|
|
||||||
' Iterate through default properties
|
'' Iterate through default properties
|
||||||
For Each Item As KeyValuePair(Of String, XmlItemProperty) In oDefaultProperties
|
'For Each Item As KeyValuePair(Of String, XmlItemProperty) In oDefaultProperties
|
||||||
Dim oPropertyValueList As List(Of Object)
|
' Dim oPropertyValueList As List(Of Object)
|
||||||
Dim oPropertyDescription As String = Item.Value.Description
|
' Dim oPropertyDescription As String = Item.Value.Description
|
||||||
Dim oPropertyValue As Object = Nothing
|
' Dim oPropertyValue As Object = Nothing
|
||||||
|
|
||||||
Try
|
' Try
|
||||||
oPropertyValueList = oPropertyExtractor.GetPropValue(oDocument, Item.Key)
|
' oPropertyValueList = oPropertyExtractor.GetPropValue(oDocument, Item.Key)
|
||||||
Catch ex As Exception
|
' Catch ex As Exception
|
||||||
_logger.Warn("Unknown error occurred while fetching property {0} in group {1}:", oPropertyDescription, Item.Value.GroupScope)
|
' _logger.Warn("Unknown error occurred while fetching property {0} in group {1}:", oPropertyDescription, Item.Value.GroupScope)
|
||||||
_logger.Error(ex)
|
' _logger.Error(ex)
|
||||||
oPropertyValueList = New List(Of Object)
|
' oPropertyValueList = New List(Of Object)
|
||||||
End Try
|
' End Try
|
||||||
|
|
||||||
Try
|
' Try
|
||||||
If IsNothing(oPropertyValueList) Then
|
' If IsNothing(oPropertyValueList) Then
|
||||||
oPropertyValue = Nothing
|
' oPropertyValue = Nothing
|
||||||
ElseIf TypeOf oPropertyValueList Is List(Of Object) Then
|
' ElseIf TypeOf oPropertyValueList Is List(Of Object) Then
|
||||||
Select Case oPropertyValueList.Count
|
' Select Case oPropertyValueList.Count
|
||||||
Case 0
|
' Case 0
|
||||||
oPropertyValue = Nothing
|
' oPropertyValue = Nothing
|
||||||
Case Else
|
' Case Else
|
||||||
Dim oList As List(Of Object) = DirectCast(oPropertyValueList, List(Of Object))
|
' Dim oList As List(Of Object) = DirectCast(oPropertyValueList, List(Of Object))
|
||||||
oPropertyValue = oList.Item(0)
|
' oPropertyValue = oList.Item(0)
|
||||||
|
|
||||||
' This should hopefully show config errors
|
' ' This should hopefully show config errors
|
||||||
If TypeOf oPropertyValue Is List(Of Object) Then
|
' If TypeOf oPropertyValue Is List(Of Object) Then
|
||||||
_logger.Warn("Property with Description {0} may be configured incorrectly", oPropertyDescription)
|
' _logger.Warn("Property with Description {0} may be configured incorrectly", oPropertyDescription)
|
||||||
oPropertyValue = Nothing
|
' oPropertyValue = Nothing
|
||||||
End If
|
' End If
|
||||||
End Select
|
' End Select
|
||||||
End If
|
' End If
|
||||||
Catch ex As Exception
|
' Catch ex As Exception
|
||||||
_logger.Warn("Unknown error occurred while processing property {0}:", oPropertyDescription)
|
' _logger.Warn("Unknown error occurred while processing property {0}:", oPropertyDescription)
|
||||||
_logger.Error(ex)
|
' _logger.Error(ex)
|
||||||
oPropertyValue = Nothing
|
' oPropertyValue = Nothing
|
||||||
End Try
|
' End Try
|
||||||
|
|
||||||
If IsNothing(oPropertyValue) OrElse String.IsNullOrEmpty(oPropertyValue) Then
|
' If IsNothing(oPropertyValue) OrElse String.IsNullOrEmpty(oPropertyValue) Then
|
||||||
If Item.Value.IsRequired Then
|
' If Item.Value.IsRequired Then
|
||||||
_logger.Warn("Property {0} is empty but marked as required! Skipping.", oPropertyDescription)
|
' _logger.Warn("Property {0} is empty but marked as required! Skipping.", oPropertyDescription)
|
||||||
oMissingProperties.Add(oPropertyDescription)
|
' oMissingProperties.Add(oPropertyDescription)
|
||||||
Continue For
|
' Continue For
|
||||||
Else
|
' Else
|
||||||
_logger.Debug("Property [{0}] is empty or not found. Skipping.", oPropertyDescription)
|
' _logger.Debug("Property [{0}] is empty or not found. Skipping.", oPropertyDescription)
|
||||||
Continue For
|
' Continue For
|
||||||
End If
|
' End If
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' Dim oTableName = Item.Value.TableName
|
||||||
|
' Dim oCommand = $"INSERT INTO {oTableName} (REFERENCE_GUID, ITEM_DESCRIPTION, ITEM_VALUE) VALUES ('{oMessageId}', '{oPropertyDescription}', '{oPropertyValue}')"
|
||||||
|
' _logger.Debug("Mapping Property [{0}] to value [{1}] . Will be inserted into table {2}", oPropertyDescription, oPropertyValue, oTableName)
|
||||||
|
|
||||||
|
' ' Insert into SQL Server
|
||||||
|
' If oArgs.InsertIntoSQLServer = True Then
|
||||||
|
' Dim oResult = _mssql.NewExecutenonQuery(oCommand)
|
||||||
|
' If oResult = False Then
|
||||||
|
' _logger.Warn("SQL Command was not successful. Check the log.")
|
||||||
|
' End If
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' ' Insert into Firebird
|
||||||
|
' _firebird.ExecuteNonQueryWithConnection(oCommand, oConnection, Firebird.TransactionMode.ExternalTransaction, oTransaction)
|
||||||
|
'Next
|
||||||
|
|
||||||
|
'--- END Check Property Values
|
||||||
|
#End Region
|
||||||
|
' Check the document against the configured property map and return:
|
||||||
|
' - a List of valid properties
|
||||||
|
' - a List of missing properties
|
||||||
|
Dim oCheckResult = _zugferd.PropertyValues.CheckPropertyValues(oDocument, oArgs.PropertyMap, oMessageId)
|
||||||
|
|
||||||
|
If oCheckResult.MissingProperties.Count > 0 Then
|
||||||
|
Throw New MissingValueException(oFile)
|
||||||
|
End If
|
||||||
|
|
||||||
|
For Each oProperty In oCheckResult.ValidProperties
|
||||||
|
Dim oGroupCounterValue = Nothing
|
||||||
|
|
||||||
|
If oProperty.GroupCounter > -1 Then
|
||||||
|
oGroupCounterValue = oProperty.GroupCounter
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim oTableName = Item.Value.TableName
|
Dim oCommand = $"INSERT INTO {oProperty.TableName} (REFERENCE_GUID, ITEM_DESCRIPTION, ITEM_VALUE, GROUP_COUNTER) VALUES ('{oMessageId}', '{oProperty.Description}', '{oProperty.Value}', {oGroupCounterValue})"
|
||||||
Dim oCommand = $"INSERT INTO {oTableName} (REFERENCE_GUID, ITEM_DESCRIPTION, ITEM_VALUE) VALUES ('{oMessageId}', '{oPropertyDescription}', '{oPropertyValue}')"
|
_logger.Debug("Mapping Property [{0}] to value [{1}] . Will be inserted into table {2}", oProperty.Description, oProperty.Value, oProperty.TableName)
|
||||||
_logger.Debug("Mapping Property [{0}] to value [{1}] . Will be inserted into table {2}", oPropertyDescription, oPropertyValue, oTableName)
|
|
||||||
|
|
||||||
' Insert into SQL Server
|
' Insert into SQL Server
|
||||||
If oArgs.InsertIntoSQLServer = True Then
|
If oArgs.InsertIntoSQLServer = True Then
|
||||||
@@ -642,10 +437,6 @@ Public Class ImportZUGFeRDFiles
|
|||||||
' Insert into Firebird
|
' Insert into Firebird
|
||||||
_firebird.ExecuteNonQueryWithConnection(oCommand, oConnection, Firebird.TransactionMode.ExternalTransaction, oTransaction)
|
_firebird.ExecuteNonQueryWithConnection(oCommand, oConnection, Firebird.TransactionMode.ExternalTransaction, oTransaction)
|
||||||
Next
|
Next
|
||||||
|
|
||||||
If oMissingProperties.Count > 0 Then
|
|
||||||
Throw New MissingValueException(oFile)
|
|
||||||
End If
|
|
||||||
Next
|
Next
|
||||||
|
|
||||||
'Check if there are no ZUGFeRD files
|
'Check if there are no ZUGFeRD files
|
||||||
@@ -674,9 +465,9 @@ Public Class ImportZUGFeRDFiles
|
|||||||
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - Already processed (MD5Hash)' WHERE GUID = '{HISTORY_ID}'"
|
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - Already processed (MD5Hash)' WHERE GUID = '{HISTORY_ID}'"
|
||||||
_firebird.ExecuteNonQuery(oSQL)
|
_firebird.ExecuteNonQuery(oSQL)
|
||||||
|
|
||||||
Dim oBody = EMAIL_MD5_ERROR
|
Dim oBody = EmailStrings.EMAIL_MD5_ERROR
|
||||||
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
||||||
AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "MD5HashException")
|
_email.AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "MD5HashException")
|
||||||
AddRejectedState(oMessageId, "MD5HashException", "Die gesendete Rechnung wurde bereits verarbeitet!", "")
|
AddRejectedState(oMessageId, "MD5HashException", "Die gesendete Rechnung wurde bereits verarbeitet!", "")
|
||||||
Catch ex As InvalidFerdException
|
Catch ex As InvalidFerdException
|
||||||
_logger.Error(ex)
|
_logger.Error(ex)
|
||||||
@@ -684,9 +475,9 @@ Public Class ImportZUGFeRDFiles
|
|||||||
oMoveDirectory = oArgs.ErrorDirectory
|
oMoveDirectory = oArgs.ErrorDirectory
|
||||||
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - ZUGFeRD yes but incorrect format' WHERE GUID = '{HISTORY_ID}'"
|
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - ZUGFeRD yes but incorrect format' WHERE GUID = '{HISTORY_ID}'"
|
||||||
_firebird.ExecuteNonQuery(oSQL)
|
_firebird.ExecuteNonQuery(oSQL)
|
||||||
Dim oBody = EMAIL_INVALID_DOCUMENT
|
Dim oBody = EmailStrings.EMAIL_INVALID_DOCUMENT
|
||||||
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
||||||
AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "InvalidFerdException")
|
_email.AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "InvalidFerdException")
|
||||||
AddRejectedState(oMessageId, "InvalidFerdException", "Inkorrekte Formate", "")
|
AddRejectedState(oMessageId, "InvalidFerdException", "Inkorrekte Formate", "")
|
||||||
Catch ex As TooMuchFerdsException
|
Catch ex As TooMuchFerdsException
|
||||||
_logger.Error(ex)
|
_logger.Error(ex)
|
||||||
@@ -694,9 +485,9 @@ Public Class ImportZUGFeRDFiles
|
|||||||
oMoveDirectory = oArgs.ErrorDirectory
|
oMoveDirectory = oArgs.ErrorDirectory
|
||||||
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - More than one ZUGFeRD-document in email' WHERE GUID = '{HISTORY_ID}'"
|
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - More than one ZUGFeRD-document in email' WHERE GUID = '{HISTORY_ID}'"
|
||||||
_firebird.ExecuteNonQuery(oSQL)
|
_firebird.ExecuteNonQuery(oSQL)
|
||||||
Dim oBody = EMAIL_TOO_MUCH_FERDS
|
Dim oBody = EmailStrings.EMAIL_TOO_MUCH_FERDS
|
||||||
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
||||||
AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "TooMuchFerdsException")
|
_email.AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "TooMuchFerdsException")
|
||||||
AddRejectedState(oMessageId, "TooMuchFerdsException", "Email enthielt mehr als ein ZUGFeRD-Dokument", "")
|
AddRejectedState(oMessageId, "TooMuchFerdsException", "Email enthielt mehr als ein ZUGFeRD-Dokument", "")
|
||||||
Catch ex As NoFerdsException
|
Catch ex As NoFerdsException
|
||||||
_logger.Error(ex)
|
_logger.Error(ex)
|
||||||
@@ -704,9 +495,9 @@ Public Class ImportZUGFeRDFiles
|
|||||||
oMoveDirectory = oArgs.ErrorDirectory
|
oMoveDirectory = oArgs.ErrorDirectory
|
||||||
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - no ZUGFeRD-Document in email' WHERE GUID = '{HISTORY_ID}'"
|
Dim oSQL = $"UPDATE TBEDM_ZUGFERD_HISTORY_IN SET COMMENT = 'REJECTED - no ZUGFeRD-Document in email' WHERE GUID = '{HISTORY_ID}'"
|
||||||
_firebird.ExecuteNonQuery(oSQL)
|
_firebird.ExecuteNonQuery(oSQL)
|
||||||
Dim oBody = EMAIL_NO_FERDS
|
Dim oBody = EmailStrings.EMAIL_NO_FERDS
|
||||||
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
||||||
AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "NoFerdsException")
|
_email.AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "NoFerdsException")
|
||||||
AddRejectedState(oMessageId, "NoFerdsException", " Email enthielt keine ZUGFeRD-Dokumente", "")
|
AddRejectedState(oMessageId, "NoFerdsException", " Email enthielt keine ZUGFeRD-Dokumente", "")
|
||||||
Catch ex As MissingValueException
|
Catch ex As MissingValueException
|
||||||
_logger.Error(ex)
|
_logger.Error(ex)
|
||||||
@@ -721,7 +512,7 @@ Public Class ImportZUGFeRDFiles
|
|||||||
|
|
||||||
Dim oBody = CreateBodyForMissingProperties(ex.File.Name, oMissingProperties)
|
Dim oBody = CreateBodyForMissingProperties(ex.File.Name, oMissingProperties)
|
||||||
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
Dim oEmailData = MoveAndRenameEmailToRejected(oArgs, oMessageId)
|
||||||
AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "MissingValueException")
|
_email.AddToEmailQueueMSSQL(oMessageId, oBody, oEmailData, "MissingValueException")
|
||||||
AddRejectedState(oMessageId, "MissingValueException", "Es fehlten ZugferdSpezifikationen", oMessage)
|
AddRejectedState(oMessageId, "MissingValueException", "Es fehlten ZugferdSpezifikationen", oMessage)
|
||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
@@ -829,11 +620,11 @@ Public Class ImportZUGFeRDFiles
|
|||||||
|
|
||||||
|
|
||||||
Private Function CreateBodyForMissingProperties(OriginalFilename As String, MissingProperties As List(Of String))
|
Private Function CreateBodyForMissingProperties(OriginalFilename As String, MissingProperties As List(Of String))
|
||||||
Dim oBody = String.Format(EMAIL_MISSINGPROPERTIES_1, OriginalFilename)
|
Dim oBody = String.Format(EmailStrings.EMAIL_MISSINGPROPERTIES_1, OriginalFilename)
|
||||||
|
|
||||||
If MissingProperties.Count > 0 Then
|
If MissingProperties.Count > 0 Then
|
||||||
oBody &= $"{vbNewLine}{vbNewLine}"
|
oBody &= $"{vbNewLine}{vbNewLine}"
|
||||||
oBody &= EMAIL_MISSINGPROPERTIES_2
|
oBody &= EmailStrings.EMAIL_MISSINGPROPERTIES_2
|
||||||
oBody &= $"{vbNewLine}{vbNewLine}"
|
oBody &= $"{vbNewLine}{vbNewLine}"
|
||||||
|
|
||||||
For Each prop In MissingProperties
|
For Each prop In MissingProperties
|
||||||
|
|||||||
@@ -1,100 +0,0 @@
|
|||||||
Imports System.Collections.Generic
|
|
||||||
Imports System.IO
|
|
||||||
Imports DigitalData.Modules.Logging
|
|
||||||
Imports GdPicture14
|
|
||||||
|
|
||||||
Public Class PDFAttachments
|
|
||||||
Private Logger As Logger
|
|
||||||
|
|
||||||
Private Const ZUGFERD_XML_FILENAME = "ZUGFeRD-invoice.xml"
|
|
||||||
|
|
||||||
Public Class AttachmentResult
|
|
||||||
Public FileName As String
|
|
||||||
Public FileContents As Byte()
|
|
||||||
End Class
|
|
||||||
|
|
||||||
Public Sub New(LogConfig As LogConfig)
|
|
||||||
Logger = LogConfig.GetLogger
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Function Extract(FileName As String, AllowedExtensions As List(Of String)) As List(Of AttachmentResult)
|
|
||||||
Dim oResults As New List(Of AttachmentResult)
|
|
||||||
Dim oExtensions = AllowedExtensions.ConvertAll(Of String)(New Converter(Of String, String)(Function(ext) ext.ToUpper))
|
|
||||||
|
|
||||||
Try
|
|
||||||
Using oGDPicturePDF As New GdPicturePDF()
|
|
||||||
If oGDPicturePDF.LoadFromFile(FileName, False) = GdPictureStatus.OK Then
|
|
||||||
Dim oEmbeddedFileCount As Integer = oGDPicturePDF.GetEmbeddedFileCount()
|
|
||||||
If oGDPicturePDF.GetStat() = GdPictureStatus.OK Then
|
|
||||||
If oEmbeddedFileCount > 1 Then
|
|
||||||
For index = 0 To oEmbeddedFileCount - 1
|
|
||||||
Dim oFileName As String = oGDPicturePDF.GetEmbeddedFileName(index)
|
|
||||||
|
|
||||||
If oGDPicturePDF.GetStat() = GdPictureStatus.OK Then
|
|
||||||
Dim oExtension = New FileInfo(oFileName).Extension.ToUpper.Substring(1)
|
|
||||||
If oFileName.ToUpper <> ZUGFERD_XML_FILENAME.ToUpper Then
|
|
||||||
If oExtensions.Contains(oExtension) Then
|
|
||||||
Dim FileSize As Integer = oGDPicturePDF.GetEmbeddedFileSize(index)
|
|
||||||
|
|
||||||
If oGDPicturePDF.GetStat() = GdPictureStatus.OK Then
|
|
||||||
Dim oFileData As Byte() = New Byte(FileSize) {}
|
|
||||||
Dim status As GdPictureStatus = oGDPicturePDF.ExtractEmbeddedFile(index, oFileData)
|
|
||||||
|
|
||||||
If status = GdPictureStatus.OK Then
|
|
||||||
oResults.Add(New AttachmentResult() With {
|
|
||||||
.FileContents = oFileData,
|
|
||||||
.FileName = oFileName
|
|
||||||
})
|
|
||||||
Else
|
|
||||||
Logger.Error("The embedded file [{0}] has failed to extract. Status: {1}", oFileName, oGDPicturePDF.GetStat().ToString())
|
|
||||||
Continue For
|
|
||||||
End If
|
|
||||||
|
|
||||||
'If status = GdPictureStatus.OK Then
|
|
||||||
' Dim oVersionedName = Filesystem.GetVersionedFilename(oFileName)
|
|
||||||
' Dim oTempName As String = Path.Combine(Path.GetTempPath(), oVersionedName)
|
|
||||||
' Using oFileStream As New FileStream(oTempName, FileMode.OpenOrCreate)
|
|
||||||
' oFileStream.Write(oFileData, 0, oFileData.Length)
|
|
||||||
' End Using
|
|
||||||
|
|
||||||
' oResults.Add(New FileInfo(oTempName))
|
|
||||||
'Else
|
|
||||||
' Logger.Error("The embedded file [{0}] has failed to extract. Status: {1}", oFileName, oGDPicturePDF.GetStat().ToString())
|
|
||||||
' Continue For
|
|
||||||
'End If
|
|
||||||
Else
|
|
||||||
Logger.Error("An error occurred getting the file size for [{0}]. Status: {1}", oFileName, oGDPicturePDF.GetStat().ToString())
|
|
||||||
Continue For
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
Logger.Warn("File [{0}] was skipped because its extension [{1}] is not allowed.", oFileName, oExtension)
|
|
||||||
Continue For
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
Logger.Debug("File [{0}] was skipped because its name indicates the invoice data file.", oFileName)
|
|
||||||
Continue For
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
Logger.Error("An error occurred getting the file name for [{0}]. Status: {1}", oFileName, oGDPicturePDF.GetStat().ToString())
|
|
||||||
Continue For
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
Logger.Error("An error occurred getting the number of embedded files. Status: {0}", oGDPicturePDF.GetStat().ToString())
|
|
||||||
Return Nothing
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
Logger.Error("The file [{0}] can't be loaded.", FileName)
|
|
||||||
Return Nothing
|
|
||||||
End If
|
|
||||||
End Using
|
|
||||||
|
|
||||||
Return oResults
|
|
||||||
Catch ex As Exception
|
|
||||||
Logger.Warn("Unexpected Error while Extracting attachments from File [{0}]", FileName)
|
|
||||||
Logger.Error(ex)
|
|
||||||
Return Nothing
|
|
||||||
End Try
|
|
||||||
End Function
|
|
||||||
End Class
|
|
||||||
@@ -1,138 +0,0 @@
|
|||||||
Imports System.Collections.Generic
|
|
||||||
Imports System.Linq
|
|
||||||
Imports System.Reflection
|
|
||||||
Imports System.Text.RegularExpressions
|
|
||||||
Imports DigitalData.Modules.Logging
|
|
||||||
|
|
||||||
Public Class PropertyValues
|
|
||||||
Private _indexPattern = "\((\d+)\)"
|
|
||||||
Private _indexRegex As New Regex(_indexPattern)
|
|
||||||
Private _Logger As Logger
|
|
||||||
|
|
||||||
Public Sub New(LogConfig As LogConfig)
|
|
||||||
_Logger = LogConfig.GetLogger()
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Function GetPropValue(Obj As Object, PropertyName As String) As List(Of Object)
|
|
||||||
Dim oNameParts As String() = PropertyName.Split("."c)
|
|
||||||
|
|
||||||
If IsNothing(Obj) Then
|
|
||||||
_Logger.Debug("`Obj` is Nothing. Exiting.")
|
|
||||||
Return New List(Of Object)
|
|
||||||
End If
|
|
||||||
|
|
||||||
|
|
||||||
If oNameParts.Length = 1 Then
|
|
||||||
Dim oPropInfo As PropertyInfo = Obj.GetType().GetProperty(PropertyName)
|
|
||||||
|
|
||||||
If IsNothing(oPropInfo) Then
|
|
||||||
_Logger.Debug("Property {0} does not exist.", PropertyName)
|
|
||||||
Return New List(Of Object)
|
|
||||||
Else
|
|
||||||
Dim oPropValue = oPropInfo.GetValue(Obj, Nothing)
|
|
||||||
Return New List(Of Object) From {oPropValue}
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
For Each oPart As String In oNameParts
|
|
||||||
Dim oType As Type = Obj.GetType()
|
|
||||||
Dim oPartName = oPart
|
|
||||||
Dim oIndex As Integer = Nothing
|
|
||||||
Dim oHasIndex As Boolean = HasIndex(oPartName)
|
|
||||||
|
|
||||||
If oHasIndex Then
|
|
||||||
oPartName = StripIndex(oPart)
|
|
||||||
oIndex = GetIndex(oPart)
|
|
||||||
End If
|
|
||||||
|
|
||||||
Dim oInfo As PropertyInfo = oType.GetProperty(oPartName)
|
|
||||||
|
|
||||||
If IsNothing(oInfo) OrElse IsNothing(oInfo.GetValue(Obj, Nothing)) Then
|
|
||||||
_Logger.Debug("Property {0} does not exist.", oPartName)
|
|
||||||
Return New List(Of Object)
|
|
||||||
End If
|
|
||||||
|
|
||||||
Obj = oInfo.GetValue(Obj, Nothing)
|
|
||||||
|
|
||||||
If oHasIndex Then
|
|
||||||
Obj = Obj(0)
|
|
||||||
End If
|
|
||||||
|
|
||||||
If IsArray(Obj) And Not oHasIndex Then
|
|
||||||
Dim oCurrentPart As String = oPart
|
|
||||||
Dim oSplitString As String() = New String() {oCurrentPart & "."}
|
|
||||||
Dim oPathFragments = PropertyName.Split(oSplitString, StringSplitOptions.None)
|
|
||||||
Dim oResults As New List(Of Object)
|
|
||||||
|
|
||||||
' if path has no more subitems, return an empty list
|
|
||||||
If oPathFragments.Length = 1 Then
|
|
||||||
Return oResults
|
|
||||||
End If
|
|
||||||
|
|
||||||
For Each oArrayItem In Obj
|
|
||||||
Dim oResult As List(Of Object) = GetPropValue(oArrayItem, oPathFragments(1))
|
|
||||||
|
|
||||||
If Not IsNothing(oResult) Then
|
|
||||||
oResults.Add(oResult)
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
Return oResults
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
Return New List(Of Object) From {Obj}
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Public Function GetFinalPropValue(List As List(Of Object)) As List(Of Object)
|
|
||||||
Dim oResult As New List(Of Object)
|
|
||||||
|
|
||||||
For Each Item In List
|
|
||||||
Dim oItemValue = DoGetFinalPropValue(Item)
|
|
||||||
|
|
||||||
If Not IsNothing(oItemValue) Then
|
|
||||||
oResult.Add(oItemValue)
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
Return oResult
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function DoGetFinalPropValue(Value As Object) As String
|
|
||||||
If TypeOf Value Is List(Of Object) Then
|
|
||||||
Dim oList = DirectCast(Value, List(Of Object))
|
|
||||||
Dim oCount = oList.Count
|
|
||||||
|
|
||||||
Select Case oCount
|
|
||||||
Case 0
|
|
||||||
Return Nothing
|
|
||||||
Case Else
|
|
||||||
Return DoGetFinalPropValue(oList.First())
|
|
||||||
End Select
|
|
||||||
|
|
||||||
Return DoGetFinalPropValue(Value)
|
|
||||||
Else
|
|
||||||
Return Value.ToString
|
|
||||||
End If
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function GetIndex(Prop As String) As Integer
|
|
||||||
If Regex.IsMatch(Prop, _indexPattern) Then
|
|
||||||
Dim oMatch = _indexRegex.Match(Prop)
|
|
||||||
Dim oGroup = oMatch.Groups.Item(1)
|
|
||||||
Dim oValue = oGroup.Value
|
|
||||||
|
|
||||||
Return Integer.Parse(oValue)
|
|
||||||
End If
|
|
||||||
|
|
||||||
Return Nothing
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function StripIndex(Prop As String) As String
|
|
||||||
Return Regex.Replace(Prop, _indexPattern, "")
|
|
||||||
End Function
|
|
||||||
|
|
||||||
Private Function HasIndex(Prop As String) As Boolean
|
|
||||||
Return Regex.IsMatch(Prop, _indexPattern)
|
|
||||||
End Function
|
|
||||||
End Class
|
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
Imports System.Collections.Generic
|
Imports System.Collections.Generic
|
||||||
|
Imports DigitalData.Modules.Interfaces
|
||||||
|
|
||||||
Public Class WorkerArgs
|
Public Class WorkerArgs
|
||||||
Public WatchDirectories As List(Of String)
|
Public WatchDirectories As List(Of String)
|
||||||
|
|||||||
@@ -87,11 +87,10 @@
|
|||||||
<Compile Include="EDMI\GraphQL\GraphQLArgs.vb" />
|
<Compile Include="EDMI\GraphQL\GraphQLArgs.vb" />
|
||||||
<Compile Include="EDMI\GraphQL\GraphQLJob.vb" />
|
<Compile Include="EDMI\GraphQL\GraphQLJob.vb" />
|
||||||
<Compile Include="EDMI\ZUGFeRD\EmailData.vb" />
|
<Compile Include="EDMI\ZUGFeRD\EmailData.vb" />
|
||||||
|
<Compile Include="EDMI\ZUGFeRD\EmailFunctions.vb" />
|
||||||
|
<Compile Include="EDMI\ZUGFeRD\EmailStrings.vb" />
|
||||||
<Compile Include="EDMI\ZUGFeRD\ImportZUGFeRDFiles.vb" />
|
<Compile Include="EDMI\ZUGFeRD\ImportZUGFeRDFiles.vb" />
|
||||||
<Compile Include="EDMI\ZUGFeRD\PDFAttachments.vb" />
|
|
||||||
<Compile Include="EDMI\ZUGFeRD\PropertyValues.vb" />
|
|
||||||
<Compile Include="EDMI\ZUGFeRD\WorkerArgs.vb" />
|
<Compile Include="EDMI\ZUGFeRD\WorkerArgs.vb" />
|
||||||
<Compile Include="EDMI\ZUGFeRD\XmlItemProperty.vb" />
|
|
||||||
<Compile Include="Exceptions.vb" />
|
<Compile Include="Exceptions.vb" />
|
||||||
<Compile Include="JobInterface.vb" />
|
<Compile Include="JobInterface.vb" />
|
||||||
<Compile Include="JobBase.vb" />
|
<Compile Include="JobBase.vb" />
|
||||||
@@ -109,12 +108,9 @@
|
|||||||
<Reference Include="FirebirdSql.Data.FirebirdClient, Version=6.4.0.0, Culture=neutral, PublicKeyToken=3750abcc3150b00c, processorArchitecture=MSIL">
|
<Reference Include="FirebirdSql.Data.FirebirdClient, Version=6.4.0.0, Culture=neutral, PublicKeyToken=3750abcc3150b00c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\FirebirdSql.Data.FirebirdClient.6.4.0\lib\net452\FirebirdSql.Data.FirebirdClient.dll</HintPath>
|
<HintPath>..\packages\FirebirdSql.Data.FirebirdClient.6.4.0\lib\net452\FirebirdSql.Data.FirebirdClient.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="GdPicture.NET.14">
|
|
||||||
<HintPath>D:\ProgramFiles\GdPicture.NET 14\Redist\GdPicture.NET (.NET Framework 4.5)\GdPicture.NET.14.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
<package id="FirebirdSql.Data.FirebirdClient" version="6.4.0" targetFramework="net461" />
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -48,7 +48,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="S22.Imap, Version=3.6.0.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="S22.Imap, Version=3.6.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\S22.Imap.3.6.0.0\lib\net40\S22.Imap.dll</HintPath>
|
<HintPath>..\packages\S22.Imap.3.6.0.0\lib\net40\S22.Imap.dll</HintPath>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
<package id="S22.Imap" version="3.6.0.0" targetFramework="net461" />
|
<package id="S22.Imap" version="3.6.0.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -65,7 +65,7 @@
|
|||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Configuration" />
|
<Reference Include="System.Configuration" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
341
SERVICES/DDEDM_NetworkService/EDMIService.vb
Normal file
341
SERVICES/DDEDM_NetworkService/EDMIService.vb
Normal file
@@ -0,0 +1,341 @@
|
|||||||
|
Imports System.ServiceModel
|
||||||
|
Imports DigitalData.Modules.Database
|
||||||
|
Imports DigitalData.Modules.Logging
|
||||||
|
Imports DigitalData.Modules.Filesystem
|
||||||
|
Imports DigitalData.Services.EDMIService
|
||||||
|
Imports System.IO
|
||||||
|
|
||||||
|
<ServiceBehavior(InstanceContextMode:=InstanceContextMode.PerSession)>
|
||||||
|
Public Class EDMIService
|
||||||
|
Implements IEDMIService
|
||||||
|
|
||||||
|
Public Shared LogConfig As LogConfig
|
||||||
|
Public Shared Database As Firebird
|
||||||
|
Public Shared AppConfig As AppConfig
|
||||||
|
|
||||||
|
Private ReadOnly _logger As Logger
|
||||||
|
|
||||||
|
Private _request As Request = Nothing
|
||||||
|
Private _debug As Boolean = False
|
||||||
|
Private _username As String
|
||||||
|
|
||||||
|
Public Sub New()
|
||||||
|
Dim oOperationContext As OperationContext = OperationContext.Current
|
||||||
|
Dim oInstanceContext As InstanceContext = oOperationContext.InstanceContext
|
||||||
|
Dim oUsername = oOperationContext.ServiceSecurityContext.WindowsIdentity.Name
|
||||||
|
|
||||||
|
_username = oUsername
|
||||||
|
_logger = LogConfig.GetLogger()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#Region "Auth"
|
||||||
|
Private Function TestUserAuth() As Boolean
|
||||||
|
Try
|
||||||
|
'Dim oSQL As String = $"SELECT FNIDB_AUTH_USER('{_username}') FROM RDB$DATABASE;"
|
||||||
|
'Dim oResult As Boolean = Database.GetScalarValue(oSQL)
|
||||||
|
'Return oResult
|
||||||
|
Return True
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
Return False
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
#End Region
|
||||||
|
#Region "Heartbeat"
|
||||||
|
Public Function Heartbeat() As Boolean Implements IEDMIService.Heartbeat
|
||||||
|
Return True
|
||||||
|
End Function
|
||||||
|
#End Region
|
||||||
|
#Region "Request"
|
||||||
|
Public Sub CreateRequest(Name As String, Optional Debug As Boolean = False)
|
||||||
|
_request = New Request(Name, _username, Database, Debug)
|
||||||
|
_debug = Debug
|
||||||
|
|
||||||
|
_logger.Info("Creating request {0}/{1}", _request.Name, _request.RequestId)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Function CreateDatabaseRequest(Name As String, Optional Debug As Boolean = False) As String Implements IEDMIService.CreateDatabaseRequest
|
||||||
|
CreateRequest(Name, Debug)
|
||||||
|
|
||||||
|
Return _request.Name
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Sub CloseDatabaseRequest() Implements IEDMIService.CloseDatabaseRequest
|
||||||
|
If IsNothing(_request) Then
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
|
||||||
|
_logger.Info("Closing request {0}", _request.ToString)
|
||||||
|
_request.Connection.Close()
|
||||||
|
_request = Nothing
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region
|
||||||
|
#Region "Database"
|
||||||
|
Private Sub TestRequestCreated()
|
||||||
|
If IsNothing(_request) Then
|
||||||
|
Throw New Exceptions.NoRequestException()
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Function ReturnDatatable(SQL As String) As TableResult Implements IEDMIService.ReturnDatatable
|
||||||
|
Try
|
||||||
|
TestRequestCreated()
|
||||||
|
|
||||||
|
_logger.Info($"ReturnDatatable, SQL: {SQL}")
|
||||||
|
_request.LogDebug($"ReturnDatatable, SQL: {SQL}")
|
||||||
|
|
||||||
|
Dim oResult As DataTable = Database.GetDatatableWithConnection(SQL, _request.Connection)
|
||||||
|
Return New TableResult(oResult)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
_request.LogError(ex.Message)
|
||||||
|
Return New TableResult(ex.Message)
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function ReturnScalar(SQL As String) As ScalarResult Implements IEDMIService.ReturnScalar
|
||||||
|
Try
|
||||||
|
TestRequestCreated()
|
||||||
|
|
||||||
|
_logger.Info($"ReturnScalar, SQL: {SQL}")
|
||||||
|
_request.LogDebug($"ReturnScalar, SQL: {SQL}")
|
||||||
|
|
||||||
|
Dim oResult As Object = Database.GetScalarValueWithConnection(SQL, _request.Connection)
|
||||||
|
Return New ScalarResult(oResult)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
_request.LogError(ex.Message)
|
||||||
|
Return New ScalarResult(ex.Message)
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function ExecuteNonQuery(SQL As String) As NonQueryResult Implements IEDMIService.ExecuteNonQuery
|
||||||
|
Try
|
||||||
|
TestRequestCreated()
|
||||||
|
|
||||||
|
_logger.Info($"ExecuteNonQuery, SQL: {SQL}")
|
||||||
|
_request.LogDebug($"ExecuteNonQuery, SQL: {SQL}")
|
||||||
|
|
||||||
|
Dim oResult As Boolean = Database.ExecuteNonQueryWithConnection(SQL, _request.Connection)
|
||||||
|
Return New NonQueryResult()
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
_request.LogError(ex.Message)
|
||||||
|
Return New NonQueryResult(ex.Message)
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
|
||||||
|
|
||||||
|
#End Region
|
||||||
|
#Region "Document (with FileContainer)"
|
||||||
|
'Public Function NewFile(FileName As String, Contents() As Byte) As DocumentResult Implements IEDMIService.NewFile
|
||||||
|
' Try
|
||||||
|
' Dim oContainer As FileContainer
|
||||||
|
' Dim oContainerId As String
|
||||||
|
|
||||||
|
' If Not TestUserAuth() Then
|
||||||
|
' Throw New Exception($"User {_username} not authorized.")
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' oContainer = FileContainer.Create(LogConfig, AppConfig.ContainerPassword)
|
||||||
|
' oContainerId = oContainer.ContainerId
|
||||||
|
' _logger.Debug("Container created with id {0}", oContainerId)
|
||||||
|
|
||||||
|
' Dim oExtension As String = Path.GetExtension(FileName).Substring(1)
|
||||||
|
' _logger.Debug("File extension of file {0} is {1}", FileName, oExtension)
|
||||||
|
|
||||||
|
' Dim oSQL = $"SELECT FNICM_NEW_DOC('010', '{oContainerId}', '{GetContainerName(oContainerId)}', '{FileName}', '{oExtension}', '{_username}') FROM RDB$DATABASE;"
|
||||||
|
' Dim oDocId As Int64 = Database.GetScalarValue(oSQL)
|
||||||
|
|
||||||
|
' If oDocId = -1 Then
|
||||||
|
' _logger.Warn("Database returned -1 while creating Document Entry. File was not saved!")
|
||||||
|
' Return Nothing
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' _logger.Debug("Database Entry created with DocId {0}", oDocId)
|
||||||
|
|
||||||
|
' oContainer.SetFile(Contents, FileName)
|
||||||
|
' oContainer.SaveAs(GetContainerPath(oContainerId))
|
||||||
|
|
||||||
|
' _logger.Debug("File saved in Container!", FileName)
|
||||||
|
|
||||||
|
' Dim oDocument = New DocumentObject(oContainerId, oDocId, FileName)
|
||||||
|
' Return New DocumentResult(oDocument)
|
||||||
|
' Catch ex As Exception
|
||||||
|
' _logger.Error(ex)
|
||||||
|
' Return New DocumentResult(ex.Message)
|
||||||
|
' End Try
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Public Function UpdateFile(DocObject As DocumentObject, Contents() As Byte) As DocumentResult Implements IEDMIService.UpdateFile
|
||||||
|
' Try
|
||||||
|
' TestFileExists(DocObject.ContainerId)
|
||||||
|
|
||||||
|
' ' TODO: update db
|
||||||
|
|
||||||
|
' Dim oFilePath = GetContainerPath(DocObject.ContainerId)
|
||||||
|
' Dim oFileContainer As FileContainer = FileContainer.Load(LogConfig, AppConfig.ContainerPassword, oFilePath)
|
||||||
|
|
||||||
|
' oFileContainer.SetFile(Contents, oFileContainer.GetFile.FileName)
|
||||||
|
' oFileContainer.Save()
|
||||||
|
|
||||||
|
|
||||||
|
' Return New DocumentResult(DocObject)
|
||||||
|
' Catch ex As Exception
|
||||||
|
' _logger.Error(ex)
|
||||||
|
' Return Nothing
|
||||||
|
' End Try
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Public Function GetFile(DocObject As DocumentObject) As DocumentResult Implements IEDMIService.GetFile
|
||||||
|
' Try
|
||||||
|
' TestFileExists(DocObject.ContainerId)
|
||||||
|
|
||||||
|
' Dim oContainerPath = GetContainerPath(DocObject.ContainerId)
|
||||||
|
' Dim oContainer As FileContainer = FileContainer.Load(LogConfig, AppConfig.ContainerPassword, oContainerPath)
|
||||||
|
' Dim oContents As Byte() = oContainer.GetFile().Contents
|
||||||
|
|
||||||
|
' Return New DocumentResult(DocObject, oContents)
|
||||||
|
' Catch ex As Exception
|
||||||
|
' _logger.Error(ex)
|
||||||
|
' Return New DocumentResult(ex.Message)
|
||||||
|
' End Try
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Public Function DeleteFile(DocObject As DocumentObject) As Boolean Implements IEDMIService.DeleteFile
|
||||||
|
' Try
|
||||||
|
' TestFileExists(DocObject.ContainerId)
|
||||||
|
|
||||||
|
' Dim oFilePath = GetContainerPath(DocObject.ContainerId)
|
||||||
|
' IO.File.Delete(oFilePath)
|
||||||
|
|
||||||
|
' 'TODO: Delete doc from db
|
||||||
|
|
||||||
|
' Return True
|
||||||
|
' Catch ex As Exception
|
||||||
|
' _logger.Error(ex)
|
||||||
|
' Return False
|
||||||
|
' End Try
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Private Function GetContainerPath(ContainerId As String) As String
|
||||||
|
' Return Path.Combine(AppConfig.ContainerPath, GetContainerName(ContainerId))
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Private Function GetContainerName(ContainerId As String) As String
|
||||||
|
' Return ContainerId & ".enc"
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Private Sub TestFileExists(ContainerId)
|
||||||
|
' Dim oContainerPath = GetContainerPath(ContainerId)
|
||||||
|
|
||||||
|
' If Not IO.File.Exists(oContainerPath) Then
|
||||||
|
' Throw New FileNotFoundException("Container existiert nicht", oContainerPath)
|
||||||
|
' End If
|
||||||
|
'End Sub
|
||||||
|
|
||||||
|
'Public Function GetDocumentByDocumentId(DocumentId As Long) As DocumentResult Implements IEDMIService.GetDocumentByDocumentId
|
||||||
|
' Try
|
||||||
|
' Dim oSQL = $"SELECT GUID, CONTAINER_ID, ORIGINAL_FILENAME FROM TBIDB_DOCUMENT WHERE GUID = {DocumentId}"
|
||||||
|
' Dim oTable = Database.GetDatatable(oSQL)
|
||||||
|
|
||||||
|
' If oTable.Rows.Count = 0 Then
|
||||||
|
' Return New DocumentResult("Document not found")
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' Dim oRow As DataRow = oTable.Rows.Item(0)
|
||||||
|
' Dim oDocument As New DocumentObject(
|
||||||
|
' oRow.Item("CONTAINER_ID"),
|
||||||
|
' oRow.Item("GUID"),
|
||||||
|
' oRow.Item("ORIGINAL_FILENAME")
|
||||||
|
' )
|
||||||
|
|
||||||
|
' TestFileExists(oDocument.ContainerId)
|
||||||
|
|
||||||
|
' Dim oContainerPath = GetContainerPath(oDocument.ContainerId)
|
||||||
|
' Dim oContainer As FileContainer = FileContainer.Load(LogConfig, AppConfig.ContainerPassword, oContainerPath)
|
||||||
|
' Dim oContents As Byte() = oContainer.GetFile().Contents
|
||||||
|
|
||||||
|
' Return New DocumentResult(oDocument, oContents)
|
||||||
|
' Catch ex As Exception
|
||||||
|
' Return New DocumentResult(ex.Message)
|
||||||
|
' End Try
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
'Public Function GetDocumentByContainerId(ContainerId As String) As DocumentResult Implements IEDMIService.GetDocumentByContainerId
|
||||||
|
' Try
|
||||||
|
' Dim oSQL = $"SELECT GUID, CONTAINER_ID, ORIGINAL_FILENAME FROM TBIDB_DOCUMENT WHERE CONTAINER_ID = '{ContainerId}'"
|
||||||
|
' Dim oTable = Database.GetDatatable(oSQL)
|
||||||
|
|
||||||
|
' If oTable.Rows.Count = 0 Then
|
||||||
|
' Return New DocumentResult("Document not found")
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' Dim oRow As DataRow = oTable.Rows.Item(0)
|
||||||
|
' Dim oDocument As New DocumentObject(
|
||||||
|
' oRow.Item("CONTAINER_ID"),
|
||||||
|
' oRow.Item("GUID"),
|
||||||
|
' oRow.Item("ORIGINAL_FILENAME")
|
||||||
|
' )
|
||||||
|
|
||||||
|
' TestFileExists(oDocument.ContainerId)
|
||||||
|
|
||||||
|
' Dim oContainerPath = GetContainerPath(oDocument.ContainerId)
|
||||||
|
' Dim oContainer As FileContainer = FileContainer.Load(LogConfig, AppConfig.ContainerPassword, oContainerPath)
|
||||||
|
' Dim oContents As Byte() = oContainer.GetFile().Contents
|
||||||
|
|
||||||
|
' Return New DocumentResult(oDocument, oContents)
|
||||||
|
' Catch ex As Exception
|
||||||
|
' Return New DocumentResult(ex.Message)
|
||||||
|
' End Try
|
||||||
|
'End Function
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
#Region "Document"
|
||||||
|
Public Function ImportFile(FileInfo As FileInfo, Contents() As Byte, [Readonly] As Boolean, RetentionPeriod As Integer) As DocumentResult2 Implements IEDMIService.ImportFile
|
||||||
|
Dim oFilePath = Path.Combine(AppConfig.ContainerPath, FileInfo.Name)
|
||||||
|
Dim oDocument = New DocumentResult2.DocumentObject() With {.FileName = FileInfo.Name}
|
||||||
|
|
||||||
|
Try
|
||||||
|
_logger.Info("Saving file [{0}] to path [{1}]", FileInfo.Name, oFilePath)
|
||||||
|
Using oStream = New FileStream(oFilePath, FileMode.CreateNew)
|
||||||
|
oStream.Write(Contents, 0, Contents.Length)
|
||||||
|
oStream.Flush(True)
|
||||||
|
oStream.Close()
|
||||||
|
End Using
|
||||||
|
|
||||||
|
Dim oAttributes = IO.File.GetAttributes(oFilePath) Or FileAttributes.ReadOnly
|
||||||
|
|
||||||
|
If RetentionPeriod Then
|
||||||
|
_logger.Info("Setting LastAccessTime")
|
||||||
|
IO.File.SetLastAccessTime(oFilePath, Date.Now.AddYears(30))
|
||||||
|
End If
|
||||||
|
|
||||||
|
If [Readonly] Then
|
||||||
|
_logger.Info("Setting ReadOnly Attribute")
|
||||||
|
IO.File.SetAttributes(oFilePath, oAttributes)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return New DocumentResult2(oDocument)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
Return New DocumentResult2(ex.Message)
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
#Region "Index"
|
||||||
|
Public Function NewFileIndex(DocObject As DocumentObject, Syskey As String, LanguageCode As String, Value As String) As IndexResult Implements IEDMIService.NewFileIndex
|
||||||
|
Try
|
||||||
|
Dim oSQL = $"SELECT FNIDB_NEW_DOC_VALUE({DocObject.DocumentId},'{Syskey}','{LanguageCode}','{Value}','{_username}') FROM RDB$DATABASE;"
|
||||||
|
Dim oIndexId As Int64 = Database.GetScalarValue(oSQL)
|
||||||
|
|
||||||
|
Return New IndexResult(oIndexId)
|
||||||
|
Catch ex As Exception
|
||||||
|
_logger.Error(ex)
|
||||||
|
Return New IndexResult(ex.Message)
|
||||||
|
End Try
|
||||||
|
End Function
|
||||||
|
#End Region
|
||||||
|
End Class
|
||||||
166
SERVICES/DDEDM_NetworkService/EDMIService.vbproj
Normal file
166
SERVICES/DDEDM_NetworkService/EDMIService.vbproj
Normal file
@@ -0,0 +1,166 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
|
<ProjectGuid>{A8C3F298-76AB-4359-AB3C-986E313B4336}</ProjectGuid>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<StartupObject>DigitalData.Services.EDMIService.WindowsService</StartupObject>
|
||||||
|
<RootNamespace>DigitalData.Services.EDMIService</RootNamespace>
|
||||||
|
<AssemblyName>EDMIService</AssemblyName>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<MyType>Console</MyType>
|
||||||
|
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
|
||||||
|
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<DefineDebug>true</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DocumentationFile>EDMIService.xml</DocumentationFile>
|
||||||
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<DefineDebug>false</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DocumentationFile>EDMIService.xml</DocumentationFile>
|
||||||
|
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionExplicit>On</OptionExplicit>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionCompare>Binary</OptionCompare>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionStrict>Off</OptionStrict>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<OptionInfer>On</OptionInfer>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="FirebirdSql.Data.FirebirdClient, Version=6.4.0.0, Culture=neutral, PublicKeyToken=3750abcc3150b00c, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\..\packages\FirebirdSql.Data.FirebirdClient.6.4.0\lib\net452\FirebirdSql.Data.FirebirdClient.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Configuration" />
|
||||||
|
<Reference Include="System.Configuration.Install" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.Deployment" />
|
||||||
|
<Reference Include="System.IO.Compression" />
|
||||||
|
<Reference Include="System.Runtime.Serialization" />
|
||||||
|
<Reference Include="System.ServiceModel" />
|
||||||
|
<Reference Include="System.ServiceProcess" />
|
||||||
|
<Reference Include="System.Transactions" />
|
||||||
|
<Reference Include="System.Windows.Forms" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="System.Net.Http" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Import Include="Microsoft.VisualBasic" />
|
||||||
|
<Import Include="System" />
|
||||||
|
<Import Include="System.Collections" />
|
||||||
|
<Import Include="System.Collections.Generic" />
|
||||||
|
<Import Include="System.Data" />
|
||||||
|
<Import Include="System.Diagnostics" />
|
||||||
|
<Import Include="System.Linq" />
|
||||||
|
<Import Include="System.Xml.Linq" />
|
||||||
|
<Import Include="System.Threading.Tasks" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="AppConfig.vb" />
|
||||||
|
<Compile Include="Results\BaseResult.vb" />
|
||||||
|
<Compile Include="Results\ContainerResult.vb" />
|
||||||
|
<Compile Include="Results\DocumentResult.vb" />
|
||||||
|
<Compile Include="Exceptions.vb" />
|
||||||
|
<Compile Include="Results\DatabaseResult.vb" />
|
||||||
|
<Compile Include="EDMIService.vb" />
|
||||||
|
<Compile Include="Results\DocumentResult2.vb" />
|
||||||
|
<Compile Include="Results\IndexResult.vb" />
|
||||||
|
<Compile Include="WindowsService.vb">
|
||||||
|
<SubType>Component</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="IEDMIService.vb" />
|
||||||
|
<Compile Include="My Project\AssemblyInfo.vb" />
|
||||||
|
<Compile Include="My Project\Application.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Application.myapp</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="My Project\Resources.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DesignTime>True</DesignTime>
|
||||||
|
<DependentUpon>Resources.resx</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="My Project\Settings.Designer.vb">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Settings.settings</DependentUpon>
|
||||||
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="ProjectInstaller.vb">
|
||||||
|
<SubType>Component</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Request.vb" />
|
||||||
|
<Compile Include="SettingsModule.vb" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<EmbeddedResource Include="My Project\Resources.resx">
|
||||||
|
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
|
||||||
|
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="ProjectInstaller.resx">
|
||||||
|
<DependentUpon>ProjectInstaller.vb</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="My Project\Application.myapp">
|
||||||
|
<Generator>MyApplicationCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Application.Designer.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<None Include="My Project\Settings.settings">
|
||||||
|
<Generator>SettingsSingleFileGenerator</Generator>
|
||||||
|
<CustomToolNamespace>My</CustomToolNamespace>
|
||||||
|
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<None Include="App.config">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
|
<None Include="packages.config" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\..\Modules.Database\Database.vbproj">
|
||||||
|
<Project>{EAF0EA75-5FA7-485D-89C7-B2D843B03A96}</Project>
|
||||||
|
<Name>Database</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\..\Modules.EDMIAPI\EDMI.API.vbproj">
|
||||||
|
<Project>{5B1171DC-FFFE-4813-A20D-786AAE47B320}</Project>
|
||||||
|
<Name>EDMI.API</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\..\Modules.Filesystem\Filesystem.vbproj">
|
||||||
|
<Project>{991D0231-4623-496D-8BD0-9CA906029CBC}</Project>
|
||||||
|
<Name>Filesystem</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\..\Modules.Logging\Logging.vbproj">
|
||||||
|
<Project>{903B2D7D-3B80-4BE9-8713-7447B704E1B0}</Project>
|
||||||
|
<Name>Logging</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||||
|
</Project>
|
||||||
61
SERVICES/DDEDM_NetworkService/IEDMIService.vb
Normal file
61
SERVICES/DDEDM_NetworkService/IEDMIService.vb
Normal file
@@ -0,0 +1,61 @@
|
|||||||
|
Imports System.IO
|
||||||
|
Imports System.ServiceModel
|
||||||
|
Imports DigitalData.Modules.Filesystem
|
||||||
|
|
||||||
|
<ServiceContract([Namespace]:="http://DigitalData.Services.EDMIService")>
|
||||||
|
Interface IEDMIService
|
||||||
|
|
||||||
|
#Region "Heartbeat"
|
||||||
|
<OperationContract>
|
||||||
|
Function Heartbeat() As Boolean
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
#Region "Database"
|
||||||
|
<OperationContract>
|
||||||
|
Function CreateDatabaseRequest(Name As String, Optional Debug As Boolean = False) As String
|
||||||
|
|
||||||
|
<OperationContract>
|
||||||
|
Sub CloseDatabaseRequest()
|
||||||
|
|
||||||
|
<OperationContract>
|
||||||
|
Function ReturnDatatable(SQL As String) As TableResult
|
||||||
|
|
||||||
|
<OperationContract>
|
||||||
|
Function ReturnScalar(SQL As String) As ScalarResult
|
||||||
|
|
||||||
|
<OperationContract>
|
||||||
|
Function ExecuteNonQuery(SQL As String) As NonQueryResult
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
#Region "Document (with FileContainer)"
|
||||||
|
'<OperationContract>
|
||||||
|
'Function NewFile(FileName As String, Contents As Byte()) As DocumentResult
|
||||||
|
|
||||||
|
'<OperationContract>
|
||||||
|
'Function UpdateFile(DocObject As DocumentObject, Contents As Byte()) As DocumentResult
|
||||||
|
|
||||||
|
'<OperationContract>
|
||||||
|
'Function GetFile(DocObject As DocumentObject) As DocumentResult
|
||||||
|
|
||||||
|
'<OperationContract>
|
||||||
|
'Function DeleteFile(DocObject As DocumentObject) As Boolean
|
||||||
|
|
||||||
|
'<OperationContract>
|
||||||
|
'Function GetDocumentByDocumentId(DocumentId As Int64) As DocumentResult
|
||||||
|
|
||||||
|
'<OperationContract>
|
||||||
|
'Function GetDocumentByContainerId(ContainerId As String) As DocumentResult
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
#Region "Document (New)"
|
||||||
|
<OperationContract>
|
||||||
|
Function ImportFile(FileInfo As FileInfo, Contents As Byte(), [ReadOnly] As Boolean, RetentionTime As Integer) As DocumentResult2
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
|
#Region "Index"
|
||||||
|
<OperationContract>
|
||||||
|
Function NewFileIndex(DocObject As DocumentObject, Syskey As String, LanguageCode As String, Value As String) As IndexResult
|
||||||
|
#End Region
|
||||||
|
|
||||||
|
End Interface
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\NLog.4.6.8\lib\net45\NLog.dll</HintPath>
|
<HintPath>..\packages\NLog.4.7.0\lib\net45\NLog.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Quartz, Version=3.0.7.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL">
|
<Reference Include="Quartz, Version=3.0.7.0, Culture=neutral, PublicKeyToken=f6b8c98a402cc8a4, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Quartz.3.0.7\lib\net452\Quartz.dll</HintPath>
|
<HintPath>..\packages\Quartz.3.0.7\lib\net452\Quartz.dll</HintPath>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="NLog" version="4.6.8" targetFramework="net461" />
|
<package id="NLog" version="4.7.0" targetFramework="net461" />
|
||||||
<package id="Quartz" version="3.0.7" targetFramework="net461" />
|
<package id="Quartz" version="3.0.7" targetFramework="net461" />
|
||||||
</packages>
|
</packages>
|
||||||
12
WEBSERVICES/ZUGFeRDRESTService/.config/dotnet-tools.json
Normal file
12
WEBSERVICES/ZUGFeRDRESTService/.config/dotnet-tools.json
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"version": 1,
|
||||||
|
"isRoot": true,
|
||||||
|
"tools": {
|
||||||
|
"dotnet-ef": {
|
||||||
|
"version": "3.1.3",
|
||||||
|
"commands": [
|
||||||
|
"dotnet-ef"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
15
WEBSERVICES/ZUGFeRDRESTService/Config.cs
Normal file
15
WEBSERVICES/ZUGFeRDRESTService/Config.cs
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace ZUGFeRDRESTService
|
||||||
|
{
|
||||||
|
public class Config
|
||||||
|
{
|
||||||
|
public string Name { get; set; }
|
||||||
|
public string LogPath { get; set; }
|
||||||
|
|
||||||
|
public string MSSQLConnectionString { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,170 @@
|
|||||||
|
using System;
|
||||||
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Microsoft.AspNetCore.Http;
|
||||||
|
using Microsoft.AspNetCore.Mvc;
|
||||||
|
using Microsoft.Extensions.Options;
|
||||||
|
using DigitalData.Modules.Interfaces;
|
||||||
|
using DigitalData.Modules.Logging;
|
||||||
|
using static DigitalData.Modules.Interfaces.Exceptions;
|
||||||
|
using static DigitalData.Modules.Interfaces.ZUGFeRDInterface;
|
||||||
|
|
||||||
|
namespace ZUGFeRDRESTService.Controllers
|
||||||
|
{
|
||||||
|
[Route("api/[controller]")]
|
||||||
|
[ApiController]
|
||||||
|
public class ValidationController : ControllerBase
|
||||||
|
{
|
||||||
|
public static string RESPONSE_OK = "OK";
|
||||||
|
public static string RESPONSE_ERROR = "ERROR";
|
||||||
|
|
||||||
|
private readonly ZUGFeRDInterface _zugferd;
|
||||||
|
private readonly IDatabase _database;
|
||||||
|
|
||||||
|
private readonly DigitalData.Modules.Logging.LogConfig _logConfig;
|
||||||
|
private readonly DigitalData.Modules.Logging.Logger _logger;
|
||||||
|
|
||||||
|
private readonly PropertyValues _props;
|
||||||
|
private readonly Dictionary<String, XmlItemProperty> _propertyMap;
|
||||||
|
|
||||||
|
public class ValidationResponse
|
||||||
|
{
|
||||||
|
public string status;
|
||||||
|
public string message;
|
||||||
|
public List<string> errors;
|
||||||
|
|
||||||
|
public ValidationResponse()
|
||||||
|
{
|
||||||
|
status = RESPONSE_OK;
|
||||||
|
message = string.Empty;
|
||||||
|
errors = new List<string>();
|
||||||
|
}
|
||||||
|
|
||||||
|
public ValidationResponse(string Status, string Message)
|
||||||
|
{
|
||||||
|
status = Status;
|
||||||
|
message = Message;
|
||||||
|
errors = new List<string>();
|
||||||
|
}
|
||||||
|
|
||||||
|
public ValidationResponse(string Status, string Message, List<String> Errors)
|
||||||
|
{
|
||||||
|
status = Status;
|
||||||
|
message = Message;
|
||||||
|
errors = Errors;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public ValidationController(ILogging logging, IDatabase database)
|
||||||
|
{
|
||||||
|
_logConfig = logging.LogConfig;
|
||||||
|
_logger = _logConfig.GetLogger();
|
||||||
|
|
||||||
|
_logger.Debug("Validation Controller initializing");
|
||||||
|
|
||||||
|
_database = database;
|
||||||
|
var oGDPictureKey = database.GetGDPictureKey();
|
||||||
|
var oPropertyMap = database.GetPropertyMap();
|
||||||
|
|
||||||
|
_propertyMap = oPropertyMap;
|
||||||
|
|
||||||
|
_zugferd = new ZUGFeRDInterface(_logConfig, oGDPictureKey);
|
||||||
|
_props = new PropertyValues(_logConfig);
|
||||||
|
|
||||||
|
_logger.Debug("Validation Controller initialized!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// POST: /api/validation
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="files">This parameter's name needs to correspond to the html form's file-input name</param>
|
||||||
|
[HttpPost]
|
||||||
|
public async Task<ValidationResponse> Post(IFormFile file, string user_id)
|
||||||
|
{
|
||||||
|
_logger.Debug("Start processing request to ValidationController");
|
||||||
|
|
||||||
|
CrossIndustryDocumentType oDocument;
|
||||||
|
PropertyValues.CheckPropertyValuesResult oResult = new PropertyValues.CheckPropertyValuesResult();
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
using Stream oStream = file.OpenReadStream();
|
||||||
|
{
|
||||||
|
_logger.Debug("Extracting ZUGFeRD Data from file [{0}]", file.FileName);
|
||||||
|
|
||||||
|
oDocument = _zugferd.ExtractZUGFeRDFileWithGDPicture(oStream);
|
||||||
|
|
||||||
|
_logger.Debug("Checking ZUGFeRD Data against the database");
|
||||||
|
|
||||||
|
oResult = _props.CheckPropertyValues(oDocument, _propertyMap, "MESSAGEID");
|
||||||
|
|
||||||
|
_logger.Debug("Result of checking against the database: {0} valid properties, {1} missing properties",
|
||||||
|
oResult.ValidProperties.Count, oResult.MissingProperties.Count);
|
||||||
|
|
||||||
|
if (oResult.MissingProperties.Count > 0)
|
||||||
|
{
|
||||||
|
throw new ZUGFeRDExecption(ZUGFeRDInterface.ErrorType.MissingProperties,
|
||||||
|
"Die hochgeladene Datei ist eine gültige ZUGFeRD-Rechnung, allerdings fehlen benötigte Daten.");
|
||||||
|
}
|
||||||
|
|
||||||
|
string oMessage = "Die hochgeladene Datei ist eine gültige-ZUGFeRD Rechnung";
|
||||||
|
|
||||||
|
_logger.Debug($"Replying with: [{oMessage}]");
|
||||||
|
|
||||||
|
return new ValidationResponse()
|
||||||
|
{
|
||||||
|
status = RESPONSE_OK,
|
||||||
|
message = oMessage
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
catch (ZUGFeRDExecption ex)
|
||||||
|
{
|
||||||
|
_logger.Error(ex);
|
||||||
|
|
||||||
|
// Determine which message should be sent in the response
|
||||||
|
string oMessage = ex.ErrorType switch
|
||||||
|
{
|
||||||
|
ErrorType.NoValidFile => "Die hochgeladene Datei ist keine gültige Datei.",
|
||||||
|
ErrorType.NoZugferd => "Die hochgeladene Datei ist keine ZUGFeRD-Rechnung.",
|
||||||
|
ErrorType.NoValidZugferd => "Die hochgeladene Datei ist keine gültige ZUGFeRD-Rechnung.",
|
||||||
|
ErrorType.MissingProperties => "Die hochgeladene Datei ist eine gültige ZUGFeRD-Rechnung, jedoch fehlen einige Metadaten",
|
||||||
|
_ => "Die hochgeladene Datei kann nicht validiert werden.",
|
||||||
|
};
|
||||||
|
|
||||||
|
// Determine if any errors should be sent in the response
|
||||||
|
List<string> oErrors = ex.ErrorType switch
|
||||||
|
{
|
||||||
|
// Errors contains the list of missing fields
|
||||||
|
ErrorType.MissingProperties => oResult.MissingProperties,
|
||||||
|
_ => new List<string>()
|
||||||
|
};
|
||||||
|
|
||||||
|
_logger.Debug($"Replying with: [{oMessage}]");
|
||||||
|
|
||||||
|
return new ValidationResponse()
|
||||||
|
{
|
||||||
|
status = RESPONSE_ERROR,
|
||||||
|
message = oMessage,
|
||||||
|
errors = oErrors
|
||||||
|
};
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
_logger.Error(ex);
|
||||||
|
|
||||||
|
string oMessage = "Die hochgeladene Datei kann nicht validiert werden, weil ein unbekannter Fehler aufgetreten ist.";
|
||||||
|
|
||||||
|
_logger.Debug($"Replying with: [{oMessage}]");
|
||||||
|
|
||||||
|
return new ValidationResponse()
|
||||||
|
{
|
||||||
|
status = RESPONSE_ERROR,
|
||||||
|
message = oMessage
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,81 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using Microsoft.AspNetCore.Http;
|
|
||||||
using Microsoft.AspNetCore.Mvc;
|
|
||||||
using System.Text.Json;
|
|
||||||
using System.Text.Json.Serialization;
|
|
||||||
|
|
||||||
namespace ZUGFeRDRESTService.Controllers
|
|
||||||
{
|
|
||||||
[Route("api/[controller]")]
|
|
||||||
[ApiController]
|
|
||||||
public class ZugferdValidationController : ControllerBase
|
|
||||||
{
|
|
||||||
public static string RESPONSE_OK = "OK";
|
|
||||||
public static string RESPONSE_ERROR = "ERROR";
|
|
||||||
|
|
||||||
private readonly IZugferdValidationDataService _dataService;
|
|
||||||
|
|
||||||
public class ZugferdValidationResponse
|
|
||||||
{
|
|
||||||
public string status;
|
|
||||||
public string message;
|
|
||||||
public List<string> errors;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public ZugferdValidationResponse()
|
|
||||||
{
|
|
||||||
status = RESPONSE_OK;
|
|
||||||
message = String.Empty;
|
|
||||||
errors = new List<string>();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public ZugferdValidationController(IZugferdValidationDataService dataService)
|
|
||||||
{
|
|
||||||
_dataService = dataService;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// POST: api/ZugferdValidation
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="files">This parameter's name needs to correspond to the html form's file-input name</param>
|
|
||||||
[HttpPost]
|
|
||||||
public async Task<ZugferdValidationResponse> Post(List<IFormFile> files)
|
|
||||||
{
|
|
||||||
var oFilePaths = new List<String>();
|
|
||||||
var oFileNames = new List<String>();
|
|
||||||
|
|
||||||
if (files.Count == 0) {
|
|
||||||
return new ZugferdValidationResponse()
|
|
||||||
{
|
|
||||||
status = RESPONSE_ERROR,
|
|
||||||
message = "No File received!"
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
foreach (var formFile in files)
|
|
||||||
{
|
|
||||||
var oFilePath = Path.GetTempFileName();
|
|
||||||
oFilePaths.Add(oFilePath);
|
|
||||||
oFileNames.Add(formFile.FileName);
|
|
||||||
|
|
||||||
using (var oStream = new FileStream(oFilePath, FileMode.Create))
|
|
||||||
{
|
|
||||||
await formFile.CopyToAsync(oStream);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var oResponse = new ZugferdValidationResponse
|
|
||||||
{
|
|
||||||
message = "You uploaded the following file: " + oFileNames.First()
|
|
||||||
};
|
|
||||||
|
|
||||||
return oResponse;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
64
WEBSERVICES/ZUGFeRDRESTService/Database.cs
Normal file
64
WEBSERVICES/ZUGFeRDRESTService/Database.cs
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Data;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using DigitalData.Modules.Database;
|
||||||
|
using DigitalData.Modules.Interfaces;
|
||||||
|
using Microsoft.Extensions.Configuration;
|
||||||
|
|
||||||
|
namespace ZUGFeRDRESTService
|
||||||
|
{
|
||||||
|
public class Database: IDatabase
|
||||||
|
{
|
||||||
|
private string _gdPictureKey = null;
|
||||||
|
private Dictionary<String, XmlItemProperty> _propertyMap = null;
|
||||||
|
|
||||||
|
private const string QUERY_GET_GDPICTURE_KEY = "SELECT LICENSE FROM TBDD_3RD_PARTY_MODULES WHERE NAME = 'GDPICTURE'";
|
||||||
|
private const string QUERY_GET_PROPERTY_MAP = "SELECT * FROM TBEDM_XML_ITEMS WHERE SPECIFICATION = '{0}' AND ACTIVE = True ORDER BY XML_PATH";
|
||||||
|
|
||||||
|
public MSSQLServer MSSQL { get; set; }
|
||||||
|
public Firebird Firebird { get; set; }
|
||||||
|
|
||||||
|
public Database(ILogging Logging, IConfiguration Config)
|
||||||
|
{
|
||||||
|
var LogConfig = Logging.LogConfig;
|
||||||
|
var AppConfig = Config.GetSection("Config");
|
||||||
|
var FBConfig = AppConfig.GetSection("Firebird");
|
||||||
|
|
||||||
|
MSSQL = new MSSQLServer(LogConfig, AppConfig["MSSQLConnectionString"]);
|
||||||
|
Firebird = new Firebird(LogConfig, FBConfig["Datasource"], FBConfig["Database"], FBConfig["Username"], FBConfig["Password"]);
|
||||||
|
}
|
||||||
|
|
||||||
|
public string GetGDPictureKey()
|
||||||
|
{
|
||||||
|
if (_gdPictureKey == null)
|
||||||
|
_gdPictureKey = MSSQL.GetScalarValue(QUERY_GET_GDPICTURE_KEY).ToString();
|
||||||
|
|
||||||
|
return _gdPictureKey;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Dictionary<String, XmlItemProperty> GetPropertyMap()
|
||||||
|
{
|
||||||
|
if (_propertyMap == null)
|
||||||
|
{
|
||||||
|
_propertyMap = new Dictionary<string, XmlItemProperty>();
|
||||||
|
var oDatatable = Firebird.GetDatatable(string.Format(QUERY_GET_PROPERTY_MAP, "DEFAULT"));
|
||||||
|
|
||||||
|
foreach (DataRow oRow in oDatatable.Rows)
|
||||||
|
{
|
||||||
|
_propertyMap.Add(oRow["XML_PATH"].ToString(), new XmlItemProperty()
|
||||||
|
{
|
||||||
|
Description = oRow["DESCRIPTION"].ToString(),
|
||||||
|
TableName = oRow["TABLE_NAME"].ToString(),
|
||||||
|
GroupScope = oRow["GROUP_SCOPE"].ToString(),
|
||||||
|
IsRequired = (bool)oRow["IS_REQUIRED"],
|
||||||
|
IsGrouped = (bool)oRow["IS_GROUPED"]
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return _propertyMap;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
16
WEBSERVICES/ZUGFeRDRESTService/IDatabase.cs
Normal file
16
WEBSERVICES/ZUGFeRDRESTService/IDatabase.cs
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using DigitalData.Modules.Database;
|
||||||
|
using DigitalData.Modules.Interfaces;
|
||||||
|
|
||||||
|
namespace ZUGFeRDRESTService
|
||||||
|
{
|
||||||
|
public interface IDatabase
|
||||||
|
{
|
||||||
|
public MSSQLServer MSSQL { get; set; }
|
||||||
|
public Firebird Firebird { get; set; }
|
||||||
|
|
||||||
|
public string GetGDPictureKey();
|
||||||
|
public Dictionary<String, XmlItemProperty> GetPropertyMap();
|
||||||
|
}
|
||||||
|
}
|
||||||
9
WEBSERVICES/ZUGFeRDRESTService/ILogging.cs
Normal file
9
WEBSERVICES/ZUGFeRDRESTService/ILogging.cs
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
using DigitalData.Modules.Logging;
|
||||||
|
|
||||||
|
namespace ZUGFeRDRESTService
|
||||||
|
{
|
||||||
|
public interface ILogging
|
||||||
|
{
|
||||||
|
public LogConfig LogConfig { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user