mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-01-12 12:03:03 +01:00
Compare commits
1305 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0c73cdb129 | ||
|
|
1d6893e928 | ||
|
|
6132843586 | ||
|
|
a848069178 | ||
|
|
73cd5e144b | ||
|
|
c306e8ebe9 | ||
|
|
e1334f34b6 | ||
|
|
83f9451b43 | ||
|
|
a249f4f35a | ||
|
|
90d1b2d349 | ||
|
|
1282494211 | ||
|
|
9c535d6d7e | ||
|
|
0e2c27d795 | ||
|
|
e5f6a64846 | ||
|
|
a84bc05f01 | ||
|
|
1efee54541 | ||
|
|
8acc5e1486 | ||
|
|
6bcb63c53d | ||
|
|
ff6b5c768d | ||
|
|
dbbebba497 | ||
|
|
8b3c872f2a | ||
|
|
3b1143df91 | ||
|
|
ff3707b650 | ||
|
|
78052e3239 | ||
|
|
a143635f53 | ||
|
|
25823d7b90 | ||
|
|
ff9070ff9c | ||
|
|
9f9ace0565 | ||
|
|
cb94216098 | ||
|
|
414a2366fb | ||
|
|
0e1353733d | ||
|
|
d8a33b46de | ||
|
|
4428e2b18e | ||
|
|
87c8d917e9 | ||
|
|
c888ce08c1 | ||
|
|
7d14cde45e | ||
|
|
d8c262691b | ||
|
|
e9fa5a647d | ||
|
|
cdd2c165ef | ||
|
|
3f862bf43e | ||
|
|
1b55935577 | ||
|
|
3006cf770c | ||
|
|
b58b3a4932 | ||
|
|
c5f73ec12a | ||
|
|
91c594a66a | ||
|
|
041decaf93 | ||
|
|
4bba124c3f | ||
|
|
2576973dc3 | ||
|
|
83e32f96b7 | ||
|
|
c16ed62ada | ||
|
|
8b6de8fe26 | ||
|
|
6ab723e85c | ||
|
|
e9b5a52a4f | ||
|
|
3132877349 | ||
|
|
d3d0617996 | ||
|
|
3b050c3452 | ||
|
|
fc1d8a2c5b | ||
|
|
99ccfee9ed | ||
|
|
d023afb66f | ||
|
|
188ed6984f | ||
|
|
08aa3eac00 | ||
|
|
9ef5f26624 | ||
|
|
d80709a7b9 | ||
|
|
758d91b4a3 | ||
|
|
726e0ceff0 | ||
|
|
80714d8d6d | ||
|
|
244ee05a9c | ||
|
|
4f73d26f6a | ||
|
|
413fc95f9a | ||
|
|
62622a2065 | ||
|
|
1a52eb5ffa | ||
|
|
099fcd7e4e | ||
|
|
33964c659e | ||
|
|
d637bbd7e9 | ||
|
|
c63a124d1c | ||
|
|
2f98d8035c | ||
|
|
19a5caf212 | ||
|
|
2be157c91f | ||
|
|
8dfe39258b | ||
|
|
76fb64e8fe | ||
|
|
dd70bee773 | ||
|
|
e431b5aacb | ||
|
|
35448e3307 | ||
|
|
9a754625bd | ||
|
|
ae2b61d5ef | ||
|
|
9b6b1e055c | ||
|
|
86e853f27d | ||
|
|
2acf2353a3 | ||
|
|
5aba1f9ccd | ||
|
|
0e684abceb | ||
|
|
a55d23f363 | ||
|
|
12b3b72fe3 | ||
|
|
640cf50b7f | ||
|
|
755de9fff2 | ||
|
|
a0fe2a8abc | ||
|
|
560d401cff | ||
|
|
a81b3a0d61 | ||
|
|
0917b37bb9 | ||
|
|
b2d790b46a | ||
|
|
d69ce5b917 | ||
|
|
a8cdecf1b8 | ||
|
|
6b61545189 | ||
|
|
2baeec1537 | ||
|
|
7195a6880f | ||
|
|
a109dd8948 | ||
|
|
c4f8e81d5d | ||
|
|
1cd0f71c09 | ||
|
|
33a0cf078c | ||
|
|
440f923b01 | ||
|
|
8b9287055e | ||
|
|
1d5182adf0 | ||
|
|
871691bf69 | ||
|
|
fb14f7c0b8 | ||
|
|
60ab32c7fb | ||
|
|
d3cbcedce3 | ||
|
|
fd5948f716 | ||
|
|
727751e0c1 | ||
|
|
0fa7134bd1 | ||
|
|
ea47a55144 | ||
|
|
1cf86931b3 | ||
|
|
11100b3017 | ||
|
|
7e30812529 | ||
|
|
2b9ce6995f | ||
|
|
33d7998a96 | ||
|
|
e5ef455628 | ||
|
|
77f213832e | ||
|
|
080ffa6a51 | ||
|
|
f17474a8de | ||
|
|
788ef257a9 | ||
|
|
fe7be8362f | ||
|
|
a3fd6f07e9 | ||
|
|
243b227c33 | ||
|
|
24c926b32f | ||
|
|
8ca639b79f | ||
|
|
1b7d194e18 | ||
|
|
1aa7e4adeb | ||
|
|
0dc182553e | ||
|
|
2a31ca969f | ||
|
|
8918299364 | ||
|
|
42e45d4a7a | ||
|
|
93323f6d61 | ||
|
|
8f1617884a | ||
|
|
679948e207 | ||
|
|
654cf2d990 | ||
|
|
9e50a06f2b | ||
|
|
a955df21bf | ||
|
|
170814c718 | ||
|
|
7f21332533 | ||
|
|
17306bc715 | ||
|
|
d3bc6aadec | ||
|
|
7372a18283 | ||
|
|
33b138b5ba | ||
|
|
99066eaf5c | ||
|
|
4f2c6e2901 | ||
|
|
fead1b7e86 | ||
|
|
35d74035be | ||
|
|
142800f951 | ||
|
|
2be2cdaadf | ||
|
|
cf324f75d7 | ||
|
|
f9ae8acbc7 | ||
|
|
99b977a08e | ||
|
|
5164a96aa0 | ||
|
|
e8ba4de832 | ||
|
|
ca557cfacd | ||
|
|
e44b14364a | ||
|
|
19ee163f31 | ||
|
|
50b5226d10 | ||
|
|
4b9bb824d0 | ||
|
|
92a4314779 | ||
|
|
6f15683709 | ||
|
|
2f932330d3 | ||
|
|
7161ca9e70 | ||
|
|
58e33c59f4 | ||
|
|
5709216427 | ||
|
|
ca6899c138 | ||
|
|
1960c712df | ||
|
|
bb22f2ccaf | ||
|
|
d892d8c3c7 | ||
|
|
e190b010d3 | ||
|
|
8ad5dc81de | ||
|
|
f462f68056 | ||
|
|
fd4dab495f | ||
|
|
d46eb08083 | ||
|
|
a8d15fafd2 | ||
|
|
65edc377c3 | ||
|
|
40d19e6c36 | ||
|
|
79da047802 | ||
|
|
1ec763fc14 | ||
|
|
c6c697cb43 | ||
|
|
9e04217e35 | ||
|
|
a336e45098 | ||
|
|
0e2b7d8b3c | ||
|
|
c3326a0963 | ||
|
|
49a1268ba1 | ||
|
|
26791714ce | ||
|
|
d2af03856c | ||
|
|
3abceadb86 | ||
|
|
739695c442 | ||
|
|
360a85cbbc | ||
|
|
60d8fb4719 | ||
|
|
7d1d588225 | ||
|
|
8658f903fa | ||
|
|
77c335c5f3 | ||
|
|
f273273129 | ||
|
|
33f8c53cca | ||
|
|
8c87050703 | ||
|
|
ba86448bce | ||
|
|
31790e255c | ||
|
|
a61c07a205 | ||
|
|
22b2247442 | ||
|
|
f10c69680c | ||
|
|
c97fcaec87 | ||
|
|
b5db5f7474 | ||
|
|
f79dec80e6 | ||
|
|
73dfa7d44a | ||
|
|
768e143188 | ||
|
|
b04cc22350 | ||
|
|
f0d787debb | ||
|
|
6bbc25e8c3 | ||
|
|
27542ed8ed | ||
|
|
36d6b472ce | ||
|
|
10ac74162e | ||
|
|
1c32f44814 | ||
|
|
cb2c1f3ece | ||
|
|
17bd362d3c | ||
|
|
9ca2e98a66 | ||
|
|
b80bd8d1f8 | ||
|
|
7a93c11ae0 | ||
|
|
943f1022c0 | ||
|
|
5f9b53004b | ||
|
|
56c32e3c81 | ||
|
|
4f79fdb4ab | ||
|
|
7886a6e838 | ||
|
|
04c233c229 | ||
|
|
35b3d4f40a | ||
|
|
ac34fce015 | ||
|
|
4fc57d096e | ||
|
|
57b3b3db3a | ||
|
|
2592344601 | ||
|
|
b3d49c4dce | ||
|
|
4fcd3fe493 | ||
|
|
ad4a8eac52 | ||
|
|
bcf4f65cc9 | ||
|
|
7360fcd03e | ||
|
|
89854ea137 | ||
|
|
75b8794d72 | ||
|
|
51128c1d55 | ||
|
|
34e7943d09 | ||
|
|
4e72543fde | ||
|
|
111d6aa621 | ||
|
|
996e01fe6a | ||
|
|
485fe0fc62 | ||
|
|
617c9f7ea9 | ||
|
|
7c77a0d84b | ||
|
|
ee9c938ea2 | ||
|
|
669205af1c | ||
|
|
f871ade545 | ||
|
|
7ad70c7c21 | ||
|
|
d1c66059cd | ||
|
|
12b15a3d90 | ||
|
|
3770eef8dc | ||
|
|
c1b6e58bbd | ||
|
|
49db52134b | ||
|
|
e0b737b622 | ||
|
|
c69821794e | ||
|
|
aeda250df4 | ||
|
|
283d4742f4 | ||
|
|
bc7cb4a148 | ||
|
|
46bb49c490 | ||
|
|
628257d771 | ||
|
|
223205cf9d | ||
|
|
d22646e6ae | ||
|
|
2c9e490853 | ||
|
|
ddf82f3e7a | ||
|
|
b9461322d9 | ||
|
|
575bb7d420 | ||
|
|
5218550014 | ||
|
|
7685ed8295 | ||
|
|
94d57cd462 | ||
|
|
c752bfe1a6 | ||
|
|
d712e1e6d4 | ||
|
|
7a5a6a14f0 | ||
|
|
0a24298385 | ||
|
|
ac30348081 | ||
|
|
df48704154 | ||
|
|
8a7f7b3551 | ||
|
|
a1428c963b | ||
|
|
c8eaa4743c | ||
|
|
ac29db92cb | ||
|
|
35766fb5bf | ||
|
|
068587fcee | ||
|
|
af4f473c93 | ||
|
|
0ad6ee209a | ||
|
|
b324425db8 | ||
|
|
0fd865d8af | ||
|
|
17d5bb5cd4 | ||
|
|
589da1d4b9 | ||
|
|
bc1dc1e9f0 | ||
|
|
8d64485705 | ||
|
|
a2dca42965 | ||
|
|
4918b41384 | ||
|
|
662fe4c358 | ||
|
|
1c4876b417 | ||
|
|
3caf65ce6f | ||
|
|
5ec351911d | ||
|
|
fde7c4ffb3 | ||
|
|
627d09d75e | ||
|
|
7870a33fd3 | ||
|
|
9ee37153f7 | ||
|
|
560194c3b9 | ||
|
|
4f762cf73d | ||
|
|
0046bfc53f | ||
|
|
58eaef37d2 | ||
|
|
d45fe6c17f | ||
|
|
d3a2aa664f | ||
|
|
df17c2f26a | ||
|
|
c6b2ee57ca | ||
|
|
5ed2bbb204 | ||
|
|
4a5cdd0092 | ||
|
|
ac3c129735 | ||
|
|
26f07992a9 | ||
|
|
6de24e0c2e | ||
|
|
4da4499569 | ||
|
|
b043442b91 | ||
|
|
22c2cfd9ec | ||
|
|
dfa161ca30 | ||
|
|
3ccc9d3e57 | ||
|
|
bd780a8c51 | ||
|
|
f91226a9f0 | ||
|
|
168e35a035 | ||
|
|
16e3baeff2 | ||
|
|
551256b779 | ||
|
|
c9371e9eb0 | ||
|
|
a734e1caa7 | ||
|
|
3f1c00dcb2 | ||
|
|
9b1dbf8d2a | ||
|
|
d17ecbeccd | ||
|
|
7eec1155a0 | ||
|
|
faa33f2d3c | ||
|
|
817de18a5d | ||
|
|
14ea3a1697 | ||
|
|
53208e620e | ||
|
|
6042b8df4e | ||
|
|
69ea0ea791 | ||
|
|
c7d886c918 | ||
|
|
890f7a0602 | ||
|
|
5822fcfbed | ||
|
|
9cb5673c36 | ||
|
|
c5278197fb | ||
|
|
e7dbc8407f | ||
|
|
fbc911aea1 | ||
|
|
3c84962891 | ||
|
|
6c75997b27 | ||
|
|
f7228d96af | ||
|
|
823e399d8d | ||
|
|
4ae121d870 | ||
|
|
6ce006f853 | ||
|
|
217aa9c420 | ||
|
|
8ac3d5f9bf | ||
|
|
7fdc63faa6 | ||
|
|
556888d55c | ||
|
|
5e1cd459b1 | ||
|
|
b9192744cc | ||
|
|
30681f9179 | ||
|
|
f101b3e43d | ||
|
|
dff5b13700 | ||
|
|
44c5988853 | ||
|
|
2425cf82d3 | ||
|
|
0c37d31e04 | ||
|
|
0764cb2abd | ||
|
|
777ae9af9b | ||
|
|
02158928cc | ||
|
|
dd46ca9c3c | ||
|
|
2907df8253 | ||
|
|
ad05451427 | ||
|
|
b16af0a7c3 | ||
|
|
2db08c8e0d | ||
|
|
73df033000 | ||
|
|
fb27c98f9c | ||
|
|
8458025e1d | ||
|
|
4a5c7d299f | ||
|
|
59abed9153 | ||
|
|
18d4840f85 | ||
|
|
c529a92b92 | ||
|
|
bf27c56fa7 | ||
|
|
0a078da8e4 | ||
|
|
617c930574 | ||
|
|
2f11f4e104 | ||
|
|
a017943083 | ||
|
|
047785b273 | ||
|
|
4689d42afd | ||
|
|
6080e5335f | ||
|
|
9380ea4bc5 | ||
|
|
a5328f4230 | ||
|
|
6bb598498e | ||
|
|
4b7c8a0d1d | ||
|
|
e505586926 | ||
|
|
1f483d7c28 | ||
|
|
3ce7a23c70 | ||
|
|
a39ff26def | ||
|
|
bae05bbe7d | ||
|
|
f25a6b2e67 | ||
|
|
400acf9f65 | ||
|
|
2cdbfa2048 | ||
|
|
72160deef7 | ||
|
|
ad922bfde6 | ||
|
|
49ccf2a3cb | ||
|
|
45f834cb15 | ||
|
|
63a03cdad6 | ||
|
|
41b938047d | ||
|
|
9113ecedfa | ||
|
|
623cb54480 | ||
|
|
a4d2927f82 | ||
|
|
d9ca9fe22d | ||
|
|
2deb1e6107 | ||
|
|
61cb99117a | ||
|
|
5504e3b236 | ||
|
|
1a02504792 | ||
|
|
f51b02026c | ||
|
|
840ca73464 | ||
|
|
f5a156ee06 | ||
|
|
1b5bcaccc6 | ||
|
|
ec0c8e0c79 | ||
|
|
263b679af4 | ||
|
|
925669ee33 | ||
|
|
f22017080d | ||
|
|
d7ac505cd0 | ||
|
|
e79a061c19 | ||
|
|
ee4a827627 | ||
|
|
d7225327e7 | ||
|
|
2a386b6fea | ||
|
|
91cf5de54d | ||
|
|
980cb095da | ||
|
|
5e2962ef38 | ||
|
|
b1b7a7c725 | ||
|
|
89dcbfae82 | ||
|
|
c3f0f3cc4a | ||
|
|
20c00d0c43 | ||
|
|
a4af2e94a9 | ||
|
|
f02a35d398 | ||
|
|
6363a6cd60 | ||
|
|
47dfe633f9 | ||
|
|
866934e6c5 | ||
|
|
a33d34a165 | ||
|
|
027c5582c3 | ||
|
|
5943e784ec | ||
|
|
00b49dba18 | ||
|
|
ffc961599c | ||
|
|
da4f3fab14 | ||
|
|
7806bdabb3 | ||
|
|
214cd2c99b | ||
|
|
43fd659d2a | ||
|
|
12289ceb9e | ||
|
|
e57cd74f22 | ||
|
|
f18a13b2d4 | ||
|
|
78a52eda96 | ||
|
|
50ede5224a | ||
|
|
c58d3d0cf7 | ||
|
|
ca66df2a7b | ||
|
|
3ee618d736 | ||
|
|
2c2142ddba | ||
|
|
adeddc70ca | ||
|
|
3f839c2a96 | ||
|
|
fd1f5bbe01 | ||
|
|
5694a19c6a | ||
|
|
1b82b6af4d | ||
|
|
9dfc08d2bd | ||
|
|
ec0da6921a | ||
|
|
6bc0630c5f | ||
|
|
baa86d773b | ||
|
|
b80d135fcb | ||
|
|
02ef5ad3b9 | ||
|
|
b6db71e5e6 | ||
|
|
b02c734c69 | ||
|
|
d21f51a35e | ||
|
|
309691f1e7 | ||
|
|
680ae60b6f | ||
|
|
7080c8491d | ||
|
|
bedfb7ac8d | ||
|
|
50da1cd95e | ||
|
|
cf4ea4168d | ||
|
|
377c44eeab | ||
|
|
53a76dc01f | ||
|
|
edbf4dc375 | ||
|
|
0e25843baa | ||
|
|
c9a73cc380 | ||
|
|
62420c5e7b | ||
|
|
e0e4da481a | ||
|
|
d9aa83e699 | ||
|
|
15bbba3f52 | ||
|
|
e811a9b13e | ||
|
|
b4581b6af8 | ||
|
|
594d9e321e | ||
|
|
a17c391efe | ||
|
|
cfcac7e053 | ||
|
|
a826e328c1 | ||
|
|
31f1ab73b1 | ||
|
|
72505b2ad4 | ||
|
|
10a3786bab | ||
|
|
c8936f9919 | ||
|
|
3369379ba1 | ||
|
|
34dd486b6c | ||
|
|
0f435f9901 | ||
|
|
a9117fe864 | ||
|
|
1795ec6a9d | ||
|
|
8ce929d509 | ||
|
|
c2ad40043f | ||
|
|
648efbc0cb | ||
|
|
ca93f732c8 | ||
|
|
b9e6b188bc | ||
|
|
10a8ce82a9 | ||
|
|
5a52534675 | ||
|
|
37749e8e9c | ||
|
|
88df2ef36d | ||
|
|
9775728b7d | ||
|
|
a232a19e7d | ||
|
|
732f236c32 | ||
|
|
d521ad6db4 | ||
|
|
46a31f443d | ||
|
|
56db7d6c64 | ||
|
|
509819c119 | ||
|
|
93a97492ae | ||
|
|
0a9293c9c6 | ||
|
|
a96c193ab0 | ||
|
|
be79791561 | ||
|
|
7605cb1871 | ||
|
|
70790009a9 | ||
|
|
c9e62845e8 | ||
|
|
d9074e70e1 | ||
|
|
e23a289553 | ||
|
|
b0641e6d69 | ||
|
|
a5e195d1c7 | ||
|
|
13dfa56c2f | ||
|
|
d4fd71d0b3 | ||
|
|
529dfb8dfb | ||
|
|
b09a618f38 | ||
|
|
a2d242356a | ||
|
|
f2fafe04b6 | ||
|
|
fb3d18f962 | ||
|
|
6bba249935 | ||
|
|
e7992131ec | ||
|
|
6277422115 | ||
|
|
a9a519e890 | ||
|
|
4eddcb7503 | ||
|
|
3d68ab4059 | ||
|
|
75290d1bd4 | ||
|
|
c3a02d0391 | ||
|
|
b9aee876e9 | ||
|
|
32d823c739 | ||
|
|
b9cbd84d4e | ||
|
|
4a3ffbb6d4 | ||
|
|
d283e8f649 | ||
|
|
1691fcedfb | ||
|
|
d3b6ada4eb | ||
|
|
f1f1f2b9c8 | ||
|
|
496d429dcd | ||
|
|
57702a1fb1 | ||
|
|
d40dea8084 | ||
|
|
bf7d5b56fb | ||
|
|
0b9783b7ed | ||
|
|
efd5924bdc | ||
|
|
231a866838 | ||
|
|
06bec1bff0 | ||
|
|
3b7b4312cb | ||
|
|
c7784076c5 | ||
|
|
e854cce158 | ||
|
|
3bf12ca193 | ||
|
|
74ae9a2618 | ||
|
|
84105e996a | ||
|
|
04f8de4188 | ||
|
|
b0d20f92dc | ||
|
|
e247b2de61 | ||
|
|
6933b7ec9c | ||
|
|
989074f13a | ||
|
|
496150d747 | ||
|
|
8d3ebad52b | ||
|
|
a68ba1704b | ||
|
|
63415e9728 | ||
|
|
ca16606b4f | ||
|
|
dd1904c521 | ||
|
|
f217959740 | ||
|
|
ca0dcb4db0 | ||
|
|
5ed7b43214 | ||
|
|
9e48920e1d | ||
|
|
ae16b45a5b | ||
|
|
08afb586f8 | ||
|
|
f7e5079e4e | ||
|
|
71ab4c4a70 | ||
|
|
78cf3c24c1 | ||
|
|
af2bd76500 | ||
|
|
69660d1a9d | ||
|
|
331db5e367 | ||
|
|
26a2fea8c7 | ||
|
|
e9c101349b | ||
|
|
3840d6c0a7 | ||
|
|
272b98faab | ||
|
|
711339945c | ||
|
|
88714cfb18 | ||
|
|
cee28d0253 | ||
|
|
cdc9d3dd1b | ||
|
|
8d08290f21 | ||
|
|
0fa139f4e3 | ||
|
|
4d134ade72 | ||
|
|
ea3f9e5e64 | ||
|
|
2625b94c83 | ||
|
|
2f5a2d0e28 | ||
|
|
f15ee475f1 | ||
|
|
f5f2ea57e3 | ||
|
|
a2efdee865 | ||
|
|
2f89d526eb | ||
|
|
aaad3c3b75 | ||
|
|
4e16db1e5f | ||
|
|
3f78d8fe25 | ||
|
|
676d70d86d | ||
|
|
e558dc3f27 | ||
|
|
c16cd91d8e | ||
|
|
259737f082 | ||
|
|
29414251f5 | ||
|
|
a6dcf5f1c1 | ||
|
|
628978be53 | ||
|
|
43c167f0c8 | ||
|
|
6c1700d84a | ||
|
|
1b5a0ce3bf | ||
|
|
57b7666bf1 | ||
|
|
e388123a3a | ||
|
|
4a7df01339 | ||
|
|
0b82860582 | ||
|
|
5c9ad3ec9b | ||
|
|
5ff7e37696 | ||
|
|
b6b2553501 | ||
|
|
10ce4029d7 | ||
|
|
9c49123a1f | ||
|
|
fcbc48fa28 | ||
|
|
0dcd85485a | ||
|
|
7a9332815c | ||
|
|
f92f8d0fc4 | ||
|
|
d38c557fba | ||
|
|
019a825bf4 | ||
|
|
93af72c272 | ||
|
|
5a93628611 | ||
|
|
80ec1ad69f | ||
|
|
905f676c71 | ||
|
|
dd8b5ce023 | ||
|
|
693a8430a5 | ||
|
|
0fc6e9b84f | ||
|
|
fcfe5423f4 | ||
|
|
6d7f5ef0a8 | ||
|
|
438e884c01 | ||
|
|
c4ef21a8f2 | ||
|
|
3ca379c9e6 | ||
|
|
83bb3bdb00 | ||
|
|
dc562be441 | ||
|
|
f8065eb4ed | ||
|
|
74c452678a | ||
|
|
4decf20aaa | ||
|
|
5d3168c2a0 | ||
|
|
37c9afebd9 | ||
|
|
8740778aa8 | ||
|
|
f09aea90df | ||
|
|
56a9f5c48b | ||
|
|
0b2aa2b01d | ||
|
|
07556e061d | ||
|
|
19c0738b14 | ||
|
|
f453e43cca | ||
|
|
142a27d472 | ||
|
|
5d8b9056b4 | ||
|
|
ca52b5755f | ||
|
|
55e3f8365e | ||
|
|
6928b6543c | ||
|
|
bc457ebb66 | ||
|
|
23c4cfe913 | ||
|
|
3182537566 | ||
|
|
09558d0ce9 | ||
|
|
40acd8a386 | ||
|
|
907a1b56e6 | ||
|
|
33d7e766b6 | ||
|
|
1344874e43 | ||
|
|
e1d117b52d | ||
|
|
06a73539fe | ||
|
|
afc6155783 | ||
|
|
06d31e8b9a | ||
|
|
4c6b0ed5b5 | ||
|
|
701b83db38 | ||
|
|
b2288ad2d9 | ||
|
|
a891211f78 | ||
|
|
c40ec37b60 | ||
|
|
c3ba8f7843 | ||
|
|
18b20a5587 | ||
|
|
d0698735d6 | ||
|
|
0d9d9498e2 | ||
|
|
a4fb16b4f3 | ||
|
|
76fc8330a3 | ||
|
|
1c523abbd8 | ||
|
|
5ea3f09e17 | ||
|
|
709542e27d | ||
|
|
990af9d5cf | ||
|
|
ae857e7008 | ||
|
|
ec13d3811e | ||
|
|
d44952011f | ||
|
|
0bdd1c0c17 | ||
|
|
134369ada9 | ||
|
|
29a45c46d5 | ||
|
|
e41afeacf4 | ||
|
|
8fc9b78b47 | ||
|
|
04329c38b3 | ||
|
|
05a2fc6186 | ||
|
|
358f8357f9 | ||
|
|
0cccaa7271 | ||
|
|
7944c21fe5 | ||
|
|
59d5391c2a | ||
|
|
b517050e17 | ||
|
|
c3ac446cf2 | ||
|
|
5c34b26f39 | ||
|
|
4a60725f6c | ||
|
|
87d9dfa009 | ||
|
|
5a0622c906 | ||
|
|
6bd6b285fd | ||
|
|
23accef5c2 | ||
|
|
86ce4315be | ||
|
|
e7e05f47ac | ||
|
|
ca6e57b2f7 | ||
|
|
5dee3b5b2f | ||
|
|
92e231e121 | ||
|
|
10d3405219 | ||
|
|
a2db403abe | ||
|
|
2e7f588cac | ||
|
|
2e609d448c | ||
|
|
e21b3f6681 | ||
|
|
9bd5ed627f | ||
|
|
bb92e64e43 | ||
|
|
b0a15f958f | ||
|
|
c17bc8b3c8 | ||
|
|
162da37f1a | ||
|
|
134a47a93f | ||
|
|
ffb3d810de | ||
|
|
4c0e1d20d6 | ||
|
|
f8bd7946a5 | ||
|
|
e4e5ca3934 | ||
|
|
84b2929604 | ||
|
|
eb0c76f613 | ||
|
|
723a263cd3 | ||
|
|
68286199eb | ||
|
|
c25463a4ba | ||
|
|
173ad057f9 | ||
|
|
4d622316a8 | ||
|
|
215085e0e6 | ||
|
|
7ddf85cd33 | ||
|
|
a5d1f1f68f | ||
|
|
ad63434f3e | ||
|
|
e52d71a880 | ||
|
|
00fce1d18a | ||
|
|
57951e1285 | ||
|
|
c6bdd27d4c | ||
|
|
593f3b81e5 | ||
|
|
e95361fed4 | ||
|
|
dda5775dd6 | ||
|
|
84a096e234 | ||
|
|
243f59b9e9 | ||
|
|
9b3f13458f | ||
|
|
9268955256 | ||
|
|
0adf267f66 | ||
|
|
05d82a0684 | ||
|
|
ff621cb146 | ||
|
|
9da4946955 | ||
|
|
0944e8b156 | ||
|
|
8115acbf82 | ||
|
|
d765b03bd1 | ||
|
|
f819509442 | ||
|
|
74eac1d06a | ||
|
|
38d53cc03d | ||
|
|
49f8a6e733 | ||
|
|
4fa6d86127 | ||
|
|
03557b69c2 | ||
|
|
7a183ea026 | ||
|
|
b44d6744f9 | ||
|
|
7eb003c684 | ||
|
|
7a53e191a9 | ||
|
|
e32b99fb21 | ||
|
|
b1b88676b0 | ||
|
|
6685cc5bc8 | ||
|
|
9b7691c8d2 | ||
|
|
bf28201685 | ||
|
|
015e1a8dab | ||
|
|
b6af947042 | ||
|
|
065ace5301 | ||
|
|
76315fa6ac | ||
|
|
dd87362ce3 | ||
|
|
646d5cc9c8 | ||
|
|
881a9b7c04 | ||
|
|
bd5e35c15f | ||
|
|
142ce7c03f | ||
|
|
eba4d44c81 | ||
|
|
95c25bc1b7 | ||
|
|
fbb162aa9b | ||
|
|
b4d2bf98fa | ||
|
|
6b36502e1e | ||
|
|
fbd4323dd8 | ||
|
|
3556004f02 | ||
|
|
d4a502629e | ||
|
|
d21bda604d | ||
|
|
e685a96716 | ||
|
|
e3beec3e1f | ||
|
|
c63d54631c | ||
|
|
5952ae28b8 | ||
|
|
487d26c7db | ||
|
|
68b6fdb508 | ||
|
|
0245eb102c | ||
|
|
69d73ac528 | ||
|
|
8bfa6df1a6 | ||
|
|
6e1702c1a5 | ||
|
|
86a31d17a5 | ||
|
|
5a6f459db5 | ||
|
|
a76d4daff8 | ||
|
|
657e6a2037 | ||
|
|
4c0785e996 | ||
|
|
03e8a0737c | ||
|
|
65ceaac42e | ||
|
|
d5acc85ef0 | ||
|
|
6851e24c3b | ||
|
|
fe0b1c5ee4 | ||
|
|
52f20a1047 | ||
|
|
39a422ef94 | ||
|
|
056a503200 | ||
|
|
2b393d04e1 | ||
|
|
d35c7ed49b | ||
|
|
9e8ed3bf54 | ||
|
|
48323059e8 | ||
|
|
04be66eab7 | ||
|
|
f385e02c53 | ||
|
|
d784c621c9 | ||
|
|
990217fcb0 | ||
|
|
7ce1d36b59 | ||
|
|
f22398a9d3 | ||
|
|
355d62e7db | ||
|
|
3eb23d3325 | ||
|
|
4e6b7289f2 | ||
|
|
b1735b0f80 | ||
|
|
c4d8a25c5a | ||
|
|
f014365b65 | ||
|
|
10df9777b5 | ||
|
|
6e01ffd5ac | ||
|
|
dde83c8fcc | ||
|
|
deabfcf403 | ||
|
|
537b58b446 | ||
|
|
b5749af5b4 | ||
|
|
4855b49698 | ||
|
|
030df58fea | ||
|
|
795754273e | ||
|
|
bd5c4603e3 | ||
|
|
e69616110d | ||
|
|
0dda5ca4d6 | ||
|
|
00804c1020 | ||
|
|
dec0e418e3 | ||
|
|
dd773d33fd | ||
|
|
ada7b74ba1 | ||
|
|
5482a3134a | ||
|
|
ac48576b88 | ||
|
|
7e629d7ef4 | ||
|
|
71a6cf1207 | ||
|
|
f132f272f2 | ||
|
|
4376ca4c94 | ||
|
|
47cf447310 | ||
|
|
68a3716fd2 | ||
|
|
2cdb17a110 | ||
|
|
ed6acfa1e7 | ||
|
|
c52c4229c5 | ||
|
|
284378232b | ||
|
|
921be56379 | ||
|
|
022fb23cee | ||
|
|
16828b8cec | ||
|
|
edd19419ad | ||
|
|
61e194bb6d | ||
|
|
582ae36e6c | ||
|
|
c2b03e49e1 | ||
|
|
dcec2516ae | ||
|
|
c6ee80eefd | ||
|
|
46cafcc445 | ||
|
|
3e6ae9bebf | ||
|
|
53acd8cffd | ||
|
|
215242a4a1 | ||
|
|
da59bb811f | ||
|
|
37f1b27bd2 | ||
|
|
01babc452c | ||
|
|
5b0d04609c | ||
|
|
b40177a8c8 | ||
|
|
fbcf95ba02 | ||
|
|
641d9a6565 | ||
|
|
ce960c8d0d | ||
|
|
0b7aec1fa0 | ||
|
|
73ea5b0e2d | ||
|
|
12b9a73ca5 | ||
|
|
4785e84c43 | ||
|
|
2fd430bd2c | ||
|
|
ef0f7cfa6f | ||
|
|
375fe3f3e8 | ||
|
|
9cb5735165 | ||
|
|
c8bff3a71e | ||
|
|
1cf3422e05 | ||
|
|
24a9a5ac2d | ||
|
|
fb5b29a32b | ||
|
|
76624122dd | ||
|
|
0884678264 | ||
|
|
eefa2bcaba | ||
|
|
9d4e672475 | ||
|
|
a3f7cbd63d | ||
|
|
70d68669d2 | ||
|
|
587ca48312 | ||
|
|
8d88217434 | ||
|
|
70ad2fcee0 | ||
|
|
7a077a2d99 | ||
|
|
1a62a36b86 | ||
|
|
7b6ef7aca8 | ||
|
|
20a11b0f46 | ||
|
|
5d20f47473 | ||
|
|
e16fd45972 | ||
|
|
11f14b8fe5 | ||
|
|
9a5d0ab0a2 | ||
|
|
30560397e4 | ||
|
|
241a97fd19 | ||
|
|
83a9be2428 | ||
|
|
3c85d27e1f | ||
|
|
39a5583930 | ||
|
|
4587031481 | ||
|
|
bd8e8a4087 | ||
|
|
b0cafd47a0 | ||
|
|
f11accf4c2 | ||
|
|
085fe5f7ba | ||
|
|
2076d18825 | ||
|
|
08167b959c | ||
|
|
2aaae47aef | ||
|
|
13202dfc7c | ||
|
|
0e03578e91 | ||
|
|
96581ef1f4 | ||
|
|
81467e1d09 | ||
|
|
f62717a16a | ||
|
|
778a856adb | ||
|
|
2d192431bc | ||
|
|
b6a3938921 | ||
|
|
8c34acbf55 | ||
|
|
defbd26f95 | ||
|
|
c2bb0431f0 | ||
|
|
576363f353 | ||
|
|
d59bcd3f5b | ||
|
|
bbfca90260 | ||
|
|
55f3a8b4f8 | ||
|
|
9926eac192 | ||
|
|
e64b8eaf40 | ||
|
|
72b2fb442b | ||
|
|
63b15dd1b6 | ||
|
|
b026896a98 | ||
|
|
c35a103694 | ||
|
|
66d4b7372e | ||
|
|
ecfdb4bbac | ||
|
|
5e6254634f | ||
|
|
1edfa4a4fb | ||
|
|
b57ec55812 | ||
|
|
608656ae89 | ||
|
|
9aa9852e85 | ||
|
|
8c4b4e233d | ||
|
|
91db3b9344 | ||
|
|
817912ea40 | ||
|
|
328a25abea | ||
|
|
3bfd7644a4 | ||
|
|
0b46fcb4f8 | ||
|
|
0d71cd4279 | ||
|
|
f80b54e573 | ||
|
|
d4e21538db | ||
|
|
255dc71823 | ||
|
|
448cd1cd36 | ||
|
|
9a9eef428b | ||
|
|
e7fedd5c2d | ||
|
|
0bf678e09e | ||
|
|
618c85ceb1 | ||
|
|
8b879ee23b | ||
|
|
54410189bc | ||
|
|
3eb8796b0d | ||
|
|
9dc904f0a5 | ||
|
|
491f72accc | ||
|
|
d08b3513dc | ||
|
|
6a5427ee4f | ||
|
|
3d79950c27 | ||
|
|
2c12a761ee | ||
|
|
8045cff888 | ||
|
|
930ae84dac | ||
|
|
ab4b1b1f29 | ||
|
|
4a291f181f | ||
|
|
c93a4c7fc0 | ||
|
|
566f683c54 | ||
|
|
eaef99b7af | ||
|
|
f2390e85b9 | ||
|
|
454a804b4e | ||
|
|
878b268a5e | ||
|
|
377e331e6a | ||
|
|
6bd450dcd0 | ||
|
|
3c6eb5e0e2 | ||
|
|
b3b3042afc | ||
|
|
d9191c74d8 | ||
|
|
cb8c8a1d50 | ||
|
|
d2e730f8e5 | ||
|
|
85c5f423b1 | ||
|
|
391fcc799b | ||
|
|
44cfb77622 | ||
|
|
41483df689 | ||
|
|
c4b3781df0 | ||
|
|
8ee5b16e89 | ||
|
|
d214dbb5fd | ||
|
|
b480fb2dfc | ||
|
|
9f0c3b0db1 | ||
|
|
45eca85bae | ||
|
|
d46d34915e | ||
|
|
4e4f0a4575 | ||
|
|
98064f7329 | ||
|
|
ee55b82a8d | ||
|
|
8c06e3577d | ||
|
|
25994e61bc | ||
|
|
6d8060bc50 | ||
|
|
19b550009b | ||
|
|
9798bb1b30 | ||
|
|
0011e09248 | ||
|
|
26c253113b | ||
|
|
714481f7e5 | ||
|
|
d945ef67e1 | ||
|
|
353e99c26a | ||
|
|
cdf7261c7e | ||
|
|
378c45fe5c | ||
|
|
93348630bf | ||
|
|
dd86c21382 | ||
|
|
573feed66f | ||
|
|
c48a294a2b | ||
|
|
e3126ec999 | ||
|
|
1bd00ac775 | ||
|
|
960416f9bf | ||
|
|
b82b6736d1 | ||
|
|
6d4b113c72 | ||
|
|
d6f1a897f6 | ||
|
|
f68be08c67 | ||
|
|
a6e728a4d8 | ||
|
|
4e4e737ff2 | ||
|
|
fb1c226e56 | ||
|
|
cd5982e45f | ||
|
|
ff4ec934e9 | ||
|
|
943e7c988f | ||
|
|
c699d71abc | ||
|
|
6261fa191f | ||
|
|
8273dbcd49 | ||
|
|
94498b191b | ||
|
|
e0d22b739d | ||
|
|
db9fc264d9 | ||
|
|
34a9eee7a6 | ||
|
|
0f4e00a2a3 | ||
|
|
99935ce11f | ||
|
|
431b207dab | ||
|
|
0890b15077 | ||
|
|
c6c1830e70 | ||
|
|
e5a16c530d | ||
|
|
921e904acc | ||
|
|
55e65bbabf | ||
|
|
fc1de5b4f3 | ||
|
|
7bc683b234 | ||
|
|
255bd6b26c | ||
|
|
e2592d9049 | ||
|
|
fe0c37f43d | ||
|
|
55298317e3 | ||
|
|
734a6de996 | ||
|
|
2c5e96bb28 | ||
|
|
3cdabbaaff | ||
|
|
c2030a7db5 | ||
|
|
d598039f20 | ||
|
|
521c4679d9 | ||
|
|
f26a64fb88 | ||
|
|
48adeb9dd7 | ||
|
|
6fdd5ea73a | ||
|
|
ee74740384 | ||
|
|
16d486e211 | ||
|
|
32410b59c4 | ||
|
|
3069eaa5c0 | ||
|
|
c30491284f | ||
|
|
1e6273b92d | ||
|
|
f3e3c47af3 | ||
|
|
15cdb3ed79 | ||
|
|
ac92a9fa40 | ||
|
|
a252c87c82 | ||
|
|
384cb22d3a | ||
|
|
f61b6a1c31 | ||
|
|
cbc8187616 | ||
|
|
eef66ae6ed | ||
|
|
bb4543167f | ||
|
|
ecfcbeef26 | ||
|
|
f07a1a6d1e | ||
|
|
6ad8145645 | ||
|
|
3e55699275 | ||
|
|
d2e528d8c1 | ||
|
|
3148a181e7 | ||
|
|
1bc1fd4cb4 | ||
|
|
f4074428f8 | ||
|
|
72e0250117 | ||
|
|
1173059e7b | ||
|
|
96d26be1d4 | ||
|
|
045fbad616 | ||
|
|
32e4635e84 | ||
|
|
7b5072a21b | ||
|
|
2f8968478d | ||
|
|
6aae68bb07 | ||
|
|
eede2f9944 | ||
|
|
73aa91af8b | ||
|
|
c3375b176d | ||
|
|
ff5a2d459d | ||
|
|
071b909d38 | ||
|
|
79a6246666 | ||
|
|
86744a2e0c | ||
|
|
7cdb832c24 | ||
|
|
a36c6a8dda | ||
|
|
2cc7e88f8e | ||
|
|
7fdccf4eb8 | ||
|
|
e8dd99a9cd | ||
|
|
d18188d565 | ||
|
|
fd95551940 | ||
|
|
25509e74d3 | ||
|
|
cb7f78e9d3 | ||
|
|
6b5f46624c | ||
|
|
b8721e0c64 | ||
|
|
6ed2ae188e | ||
|
|
f756864670 | ||
|
|
49faaf750f | ||
|
|
ce1649233d | ||
|
|
8589e122c6 | ||
|
|
56c90c289a | ||
|
|
1dfd2d565b | ||
|
|
edb4aac8d3 | ||
|
|
37401df106 | ||
|
|
f2adc3de4f | ||
|
|
0894dd6d74 | ||
|
|
67c164df07 | ||
|
|
415398fc66 | ||
|
|
e13d3ce657 | ||
|
|
f72a836231 | ||
|
|
4dcc073b3a | ||
|
|
3939a640e9 | ||
|
|
61a7f54877 | ||
|
|
7d7ef1e72a | ||
|
|
471f3e66e6 | ||
|
|
6a41d5bba8 | ||
|
|
21bec139ca | ||
|
|
b4cd670b09 | ||
|
|
091fbb2824 | ||
|
|
9b1163cfb8 | ||
|
|
1e9ae1bc02 | ||
|
|
2629a98851 | ||
|
|
1399ac9b41 | ||
|
|
053a1a2230 | ||
|
|
056aa81ed3 | ||
|
|
466b7e84ef | ||
|
|
b76828df9f | ||
|
|
b33e639099 | ||
|
|
9cd8c3738f | ||
|
|
8df431f525 | ||
|
|
54a77a604c | ||
|
|
d18ce3b39e | ||
|
|
9057559ab5 | ||
|
|
b726e96f4b | ||
|
|
03ae31eced | ||
|
|
335a767f22 | ||
|
|
1c19c97cf2 | ||
|
|
9912ffd555 | ||
|
|
4819e58d06 | ||
|
|
dd9cb8e781 | ||
|
|
e256ce5c4b | ||
|
|
61c60b50fd | ||
|
|
636f1e642d | ||
|
|
4fba3ec872 | ||
|
|
03aa4873d1 | ||
|
|
b88e159495 | ||
|
|
ec98ffb492 | ||
|
|
59049cd047 | ||
|
|
8d8695ccd7 | ||
|
|
53c5ec51b8 | ||
|
|
ca66eac76c | ||
|
|
4f5c5356c5 | ||
|
|
18fa4c4105 | ||
|
|
fd617658ef | ||
|
|
b45bfd258d | ||
|
|
bce0a93227 | ||
|
|
836ccfd595 | ||
|
|
9c504c1b3d | ||
|
|
0ea55209ae | ||
|
|
0a13e03792 | ||
|
|
d24c6f7a81 | ||
|
|
75409e3ed0 | ||
|
|
77b0800633 | ||
|
|
6c01cc16f8 | ||
|
|
16b327f106 | ||
|
|
642e75c3dd | ||
|
|
a5431a40da | ||
|
|
46eb744b34 | ||
|
|
d76ca6f569 | ||
|
|
d6ded950ac | ||
|
|
ae0c738980 | ||
|
|
d3c23428d5 | ||
|
|
324c8e9b54 | ||
|
|
92a36dbeee | ||
|
|
cc132775f3 | ||
|
|
92f4744d11 | ||
|
|
5e259d26ab | ||
|
|
e2a9743dd4 | ||
|
|
5f2486049e | ||
|
|
5f37f54675 | ||
|
|
918e669c98 | ||
|
|
5afd518718 | ||
|
|
4f1ac84a19 | ||
|
|
6553c40bea | ||
|
|
9bb0ef04f5 | ||
|
|
f34a3785f0 | ||
|
|
3d8d55a531 | ||
|
|
b64fc7dc3f | ||
|
|
5b3670f300 | ||
|
|
8bb11039dc | ||
|
|
7c4e737668 | ||
|
|
68b4866438 | ||
|
|
eb30f6ed1a | ||
|
|
5d65b5f660 | ||
|
|
600a24346a | ||
|
|
a5893db106 | ||
|
|
70efaa4235 | ||
|
|
95729e2375 | ||
|
|
8dee17446d | ||
|
|
960512acd9 | ||
|
|
1194c61857 | ||
|
|
dfb7c3e194 | ||
|
|
cf899364f3 | ||
|
|
d98c54c445 | ||
|
|
08b3cc5033 | ||
|
|
a11f7d1070 | ||
|
|
b3fdb9f168 | ||
|
|
4dfd016504 | ||
|
|
2de1433818 | ||
|
|
731978fda6 | ||
|
|
194b92e70f | ||
|
|
41c6155922 | ||
|
|
d5324ff3db | ||
|
|
90bcc64547 | ||
|
|
443558e3a2 | ||
|
|
3655f6f407 | ||
|
|
6df049e05c | ||
|
|
0eac798674 | ||
|
|
347667b346 | ||
|
|
8e324c36ff | ||
|
|
ee0bdde8c1 | ||
|
|
d6346522b8 | ||
|
|
f4494db73f | ||
|
|
29ba9c82c3 | ||
|
|
858a751eef | ||
|
|
1bc07994f6 | ||
|
|
e99ab329fd | ||
|
|
0c60c9fd0d | ||
|
|
62f55b8549 | ||
|
|
ccfe6f18fe | ||
|
|
18c23680f7 | ||
|
|
bbb8c9418e | ||
|
|
02e022ebfa | ||
|
|
ffaf7068d5 | ||
|
|
2865d6bd15 | ||
|
|
de62037ba5 | ||
|
|
77868ad2a3 | ||
|
|
a7f022dcea | ||
|
|
8c1af0fdb8 | ||
|
|
1762e10e69 | ||
|
|
a854d955b8 | ||
|
|
0363717476 | ||
|
|
7c992eac5e | ||
|
|
d05c60baf0 | ||
|
|
4d2cbf7006 | ||
|
|
566c1aaf84 | ||
|
|
a8c91069b2 | ||
|
|
df297f89d0 | ||
|
|
058a0d4fa7 | ||
|
|
ee5ebdb6ef | ||
|
|
4202a71381 | ||
|
|
eb7dd74026 | ||
|
|
88f6c71e88 | ||
|
|
d41f2dcd86 | ||
|
|
5bae9db0a8 | ||
|
|
d27bbe5232 | ||
|
|
15359afa1c | ||
|
|
479de9a7d3 | ||
|
|
4eb50ac339 | ||
|
|
02c67fe2fa | ||
|
|
1591b76050 | ||
|
|
a05ea83c5c | ||
|
|
8d900baa82 | ||
|
|
e3b9012486 | ||
|
|
2749f1726c | ||
|
|
a44ffbf40c | ||
|
|
b8586d4950 | ||
|
|
db00366c5d | ||
|
|
896891130d | ||
|
|
5e4a412ec7 | ||
|
|
20fd489194 | ||
|
|
13c3a8d3b3 | ||
|
|
ee3226900c | ||
|
|
1041a58cb9 | ||
|
|
df89db3ed6 | ||
|
|
6929efc417 | ||
|
|
0d4c784a0e | ||
|
|
232f201007 | ||
|
|
145caacbea |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -16,6 +16,7 @@ default.properties
|
||||
.DS_Store
|
||||
.idea
|
||||
*.iml
|
||||
*.orig
|
||||
Thumbs.db
|
||||
/dolibarr_genesis.mp4
|
||||
# Log files
|
||||
|
||||
78
.travis.yml
78
.travis.yml
@@ -5,7 +5,7 @@
|
||||
# We use dist: xenial to have php 5.6+ available
|
||||
os: linux
|
||||
dist: xenial
|
||||
sudo: required
|
||||
#dist: bionic
|
||||
|
||||
language: php
|
||||
|
||||
@@ -31,53 +31,25 @@ addons:
|
||||
# We need pgloader for import mysql database into pgsql
|
||||
- pgloader
|
||||
|
||||
php:
|
||||
- '5.6'
|
||||
- '7.0'
|
||||
- '7.1'
|
||||
- '7.2'
|
||||
- '7.3'
|
||||
- '7.4'
|
||||
- nightly
|
||||
|
||||
env:
|
||||
global:
|
||||
# Set to true for very verbose output
|
||||
- DEBUG=false
|
||||
jobs:
|
||||
# MariaDB overrides MySQL installation so it's not possible to test both yet
|
||||
#- DB=mariadb
|
||||
- DB=mysql
|
||||
- DB=postgresql
|
||||
# See https://docs.travis-ci.com/user/languages/php/#Apache-%2B-PHP
|
||||
#- WS=apache
|
||||
# See https://github.com/DracoBlue/travis-ci-nginx-php-fpm-test
|
||||
#- WS=nginx
|
||||
|
||||
jobs:
|
||||
fast_finish: true
|
||||
allow_failures:
|
||||
- php: nightly
|
||||
# We exclude some combinations not usefull to save Travis CPU
|
||||
exclude:
|
||||
- php: '7.0'
|
||||
env: DB=mysql
|
||||
- php: '7.1'
|
||||
env: DB=mysql
|
||||
- php: '7.2'
|
||||
env: DB=mysql
|
||||
- php: '7.3'
|
||||
env: DB=mysql
|
||||
- php: '7.0'
|
||||
env: DB=postgresql
|
||||
- php: '7.1'
|
||||
env: DB=postgresql
|
||||
- php: '7.2'
|
||||
env: DB=postgresql
|
||||
- php: '7.3'
|
||||
env: DB=postgresql
|
||||
- php: nightly
|
||||
env: DB=postgresql
|
||||
include:
|
||||
- if: type = push
|
||||
php: '5.6'
|
||||
env: DB=postgresql
|
||||
- if: type = pull_request OR type = push
|
||||
php: '7.4'
|
||||
env: DB=mysql
|
||||
- if: type = push AND branch = develop
|
||||
php: nightly
|
||||
env: DB=mysql
|
||||
|
||||
notifications:
|
||||
email:
|
||||
@@ -110,11 +82,11 @@ install:
|
||||
echo "Updating Composer"
|
||||
rm $TRAVIS_BUILD_DIR/composer.json
|
||||
rm $TRAVIS_BUILD_DIR/composer.lock
|
||||
composer -V
|
||||
composer self-update
|
||||
# To have composer making parallel downloads
|
||||
composer global require hirak/prestissimo
|
||||
composer -n init
|
||||
composer -n config vendor-dir htdocs/includes
|
||||
composer -n config -g vendor-dir htdocs/includes
|
||||
echo
|
||||
|
||||
- |
|
||||
@@ -143,6 +115,9 @@ install:
|
||||
- |
|
||||
echo "Adding path of binaries tools installed by composer to the PATH"
|
||||
export PATH="$TRAVIS_BUILD_DIR/htdocs/includes/bin:$PATH"
|
||||
echo $PATH
|
||||
ls $TRAVIS_BUILD_DIR/vendor
|
||||
ls $TRAVIS_BUILD_DIR/htdocs/includes/bin
|
||||
echo
|
||||
|
||||
|
||||
@@ -169,15 +144,20 @@ before_script:
|
||||
|
||||
- |
|
||||
echo "Versions information"
|
||||
echo
|
||||
# Check PHP
|
||||
echo "PHP version"
|
||||
php -i | head -
|
||||
# Check PHP CodeSniffer installation
|
||||
# Check Parallel-lint version
|
||||
echo "Parallel-lint version"
|
||||
which parallel-lint
|
||||
parallel-lint -V
|
||||
# Check PHP CodeSniffer version
|
||||
echo "PHPCS version"
|
||||
which phpcs
|
||||
phpcs --version | head -
|
||||
phpcs -i | head -
|
||||
# Check PHPUnit installation
|
||||
# Check PHPUnit version
|
||||
echo "PHPUnit version"
|
||||
which phpunit
|
||||
phpunit --version | head -
|
||||
@@ -282,17 +262,18 @@ script:
|
||||
# Ensure we catch errors
|
||||
set -e
|
||||
#parallel-lint --exclude htdocs/includes --blame .
|
||||
parallel-lint --exclude dev/namespacemig --exclude htdocs/includes/myclabs --exclude htdocs/includes/webmozart --exclude htdocs/includes/phpspec --exclude dev/initdata/dbf/includes --exclude htdocs/includes/sabre --exclude htdocs/includes/phpoffice/phpexcel/Classes/PHPExcel/Shared --exclude htdocs/includes/phpoffice/PhpSpreadsheet --exclude htdocs/includes/sebastian --exclude htdocs/includes/squizlabs/php_codesniffer --exclude htdocs/includes/jakub-onderka --exclude htdocs/includes/mike42/escpos-php/example --exclude htdocs/includes/phpunit/ --exclude htdocs/includes/composer/autoload_static.php --blame .
|
||||
parallel-lint --exclude dev/namespacemig --exclude htdocs/includes/composer --exclude htdocs/includes/myclabs --exclude htdocs/includes/webmozart --exclude htdocs/includes/phpspec --exclude dev/initdata/dbf/includes --exclude htdocs/includes/sabre --exclude htdocs/includes/phpoffice/phpexcel/Classes/PHPExcel/Shared --exclude htdocs/includes/phpoffice/PhpSpreadsheet --exclude htdocs/includes/sebastian --exclude htdocs/includes/squizlabs/php_codesniffer --exclude htdocs/includes/jakub-onderka --exclude htdocs/includes/mike42/escpos-php/example --exclude htdocs/includes/phpunit/ --exclude htdocs/includes/composer/autoload_static.php --blame .
|
||||
set +e
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Checking coding style (excluding Pull Requests builds)"
|
||||
echo "Checking coding style (excluding Pull Requests builds to not overload travis, excluding also some jobs to avoid duplicate tests)"
|
||||
# Ensure we catch errors
|
||||
set -e
|
||||
# Exclusions are defined in the ruleset.xml file
|
||||
#phpcs -s -n -p -d memory_limit=-1 --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 .
|
||||
if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then phpcs -s -p -d memory_limit=-1 --extensions=php --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 --runtime-set ignore_warnings_on_exit true .; fi
|
||||
if [ "$TRAVIS_PULL_REQUEST" = "false" ] && [ "$TRAVIS_PHP_VERSION" = "7.4" ] && [ "$DB" = "mysql" ]; then
|
||||
phpcs -s -p -d memory_limit=-1 --extensions=php --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 --runtime-set ignore_warnings_on_exit true .;
|
||||
fi
|
||||
set +e
|
||||
echo
|
||||
|
||||
@@ -404,6 +385,7 @@ script:
|
||||
php upgrade.php 11.0.0 12.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade11001200.log
|
||||
php upgrade2.php 11.0.0 12.0.0 > $TRAVIS_BUILD_DIR/upgrade11001200-2.log
|
||||
php step5.php 11.0.0 12.0.0 > $TRAVIS_BUILD_DIR/upgrade11001200-3.log
|
||||
|
||||
# Enable modules not enabled into original dump
|
||||
php upgrade2.php 0.0.0 0.0.0 MAIN_MODULE_API,MAIN_MODULE_SUPPLIERPROPOSAL,MAIN_MODULE_WEBSITE,MAIN_MODULE_TICKETSUP,MAIN_MODULE_ACCOUNTING > $TRAVIS_BUILD_DIR/enablemodule.log
|
||||
echo $?
|
||||
@@ -424,7 +406,7 @@ script:
|
||||
|
||||
after_script:
|
||||
- |
|
||||
echo "After script - Output lines of dolibarr.log"
|
||||
echo "After script - Output last lines of dolibarr.log"
|
||||
ls $TRAVIS_BUILD_DIR/documents
|
||||
#cat $TRAVIS_BUILD_DIR/documents/dolibarr.log
|
||||
sudo tail -n 50 $TRAVIS_BUILD_DIR/documents/dolibarr.log
|
||||
|
||||
354
ChangeLog
354
ChangeLog
@@ -3,6 +3,299 @@ English Dolibarr ChangeLog
|
||||
--------------------------------------------------------------
|
||||
|
||||
|
||||
***** ChangeLog for 12.0.5 compared to 12.0.4 *****
|
||||
FIX: before crediting a withdrawal receipt, check whether it has been credited already
|
||||
FIX: mandatory extrafields of type sellist
|
||||
FIX: when a mandatory extrafield of type sellist contains '0' it should be considered empty and trigger an error message upon insertion
|
||||
FIX: when a new intervention is created from an object, a new $extrafields object is instantiated but not initialized
|
||||
FIX: "openall" filter on ticket list does not include read tickets
|
||||
FIX: ticket - extrafields of type 'date' are not saved
|
||||
FIX: ticket - the "openall" filter on the ticket list does not include tickets with status READ
|
||||
FIX: #14290 #15900
|
||||
FIX: #15388 #15891
|
||||
FIX: #15465 External user sees last 5 shipments to other customers in the dashboard
|
||||
FIX: #15629
|
||||
FIX: #15751 Miscellaneous payment type change to 0 after updating subledger account
|
||||
FIX: #15946
|
||||
FIX: #15966 #15967
|
||||
FIX: Accountancy - Fix some problems on CEGID export
|
||||
FIX: Accountancy - label_operation is used instead of label_compte
|
||||
FIX: Accountancy - Retire entire opening balance feature
|
||||
FIX: add autofix of count of email target when data is corrupted
|
||||
FIX: add categories params on llxHeader filter
|
||||
FIX: Add critical price patch from 12 to 11.
|
||||
FIX: Bad cleaning of VAT rate when numbers are into code
|
||||
FIX: Bad dates filtering in the ticket list causes sql error
|
||||
FIX: balance starting and ending fiscal month #14197
|
||||
FIX: bom line unit display #13831
|
||||
FIX: cash fence for takepos with multientity
|
||||
FIX: Check of customer/vendor code fails in some cases
|
||||
FIX: create ticket : thirdparty/contact notification #15629
|
||||
FIX: Creation of thirdparty when setup is empty
|
||||
FIX: Dates of sales start in TakePOS
|
||||
FIX: dupliacete customer or supplier code must be error dipslayed with new code proposed
|
||||
FIX: Export FEC - Force Carriage Return Line Feed
|
||||
FIX: Facture Situation Out : status condition
|
||||
FIX: Filter on date of next generation on template invoices
|
||||
FIX: Fix detect dispatched product and set to received completely when the supplier order have services (support STOCK_SUPPORTS_SERVICES)
|
||||
FIX: Invoice Situation Out : status condition
|
||||
FIX: issue 15659 : Missing test if supplier conf is enabled
|
||||
FIX: link to create event when task is in a project with a thirdparty
|
||||
FIX: Localtax must be converted with price2num
|
||||
FIX: manage price min for PRODUIT_CUSTOMER_PRICES
|
||||
FIX: missing GETPOST parameters on card_presend.tpl.php
|
||||
FIX: missing socid into link to create event from project agenda tab
|
||||
FIX: Must delete extrafields before main table on product deletion.
|
||||
FIX: (path) htdocs removed
|
||||
FIX: php alert sms.php
|
||||
FIX: right to show VAT rate in product list
|
||||
FIX: select default mail template
|
||||
FIX: Timeout during import
|
||||
FIX: update order by api
|
||||
FIX: useless tracking number displayed on pdf if empty issue #14501
|
||||
FIX: Visible date of payment
|
||||
FIX: warning when adding a line if $remise_percent is an empty string
|
||||
FIX: When creating a new POS sell, the creation date must be modified.
|
||||
FIX: wrong name for search status param issue #15516
|
||||
|
||||
***** ChangeLog for 12.0.4 compared to 12.0.3 *****
|
||||
FIX: make formConfirm an addreplace-type hook
|
||||
FIX: regex to remove 'action' parameter: taking feedback from PR#15213 into account
|
||||
FIX: remove 'action' parameter from redirect URL when reordering lines on a document
|
||||
FIX: error when displaying lines on order after adding a line if both MAIN_MULTILANGS and MAIN_DISABLE_PDF_AUTOUPDATE are activated
|
||||
FIX: on survey creation, entity is always set to 1 ⇒ set it to $conf->entity
|
||||
FIX: set entity to $conf->entity (instead of 1 by default) when creating a survey; otherwise the survey cannot be listed from the entity it was created on unless it is the main entity
|
||||
FIX: the stringent XSS protection provided by 'alphanohtml' causes problems with some clients who used basic tags (bold, italic, underline) in product labels. Using 'restricthtml' instead could be a good compromise.
|
||||
FIX: third party of object is not always fetched when initiating the e-mail presend action (e.g. from an order)
|
||||
FIX: when the cronjob 'params' field is empty, the cron method is called with one empty string param instead of no params at all
|
||||
FIX: XSS protection too stringent -> replace 'alphanohtml' with 'restricthtml'
|
||||
FIX: #13067 including opening balance in calculation of displayed balance
|
||||
FIX: #14326
|
||||
FIX: #14649
|
||||
FIX: #14901
|
||||
FIX: #14927 Change ContratLigne property type to product_type
|
||||
FIX: #14979
|
||||
FIX: #15074
|
||||
FIX: #15111 Fix special characters output in PDF
|
||||
FIX: #15161 MO translation conflict
|
||||
FIX: #15163
|
||||
FIX: #15199
|
||||
FIX: #15208
|
||||
FIX: #15303
|
||||
FIX: #15365 export of extrafields for user and resources
|
||||
FIX: #15374 : "New" doesn't clear total amounts
|
||||
FIX: #15501
|
||||
FIX: #15572
|
||||
FIX: #15590
|
||||
FIX: #15618
|
||||
FIX: supplier proposals as linked objects of events are not correctly fetched
|
||||
FIX: when users create an event from a supplier proposal, the "linked objects" section says "Deleted"
|
||||
FIX: Accountancy - Some ajustments on length of the account (general & auxiliary)
|
||||
FIX: admin conf selected
|
||||
FIX: also check if there is a method $object->fetch_thirdparty() before calling it
|
||||
FIX: autofocus on first setup
|
||||
FIX: Bad rigths to send contract
|
||||
FIX: Better error message with IMAP when connection fails
|
||||
FIX: Can create user but not update user with activedirectory
|
||||
FIX: Can receipt of a product that required lot after disabling stock and
|
||||
FIX: Can't create shipment for virtual product. Add
|
||||
FIX: cant empty action comm desc
|
||||
FIX: CA report by product/service : subcategory filter
|
||||
FIX: Clean orphan records in llx_ecm_files into repair script.
|
||||
FIX: default accountancy values and posted values
|
||||
FIX: Deletion of expensereport + other generated object not complete.
|
||||
FIX: disabled users must not be available in sales representative list on societe edit mode
|
||||
FIX: Dol print error : conf usage thirdparty propagate extrafields to
|
||||
FIX: Don't display inactive users in birthday box and company card
|
||||
FIX: empty value is needed on filter list
|
||||
FIX: enable HTML in product labels depending on conf MAIN_SECURITY_ALLOW_UNSECURED_LABELS_WITH_HTML
|
||||
FIX: error 500 on cash closure
|
||||
FIX: excess comma
|
||||
FIX: Export FEC - Remove line at zero
|
||||
FIX: extrafield required error after submit
|
||||
FIX: filter on project list
|
||||
FIX: force payment mode to withdraw
|
||||
FIX: formating of prices with foreign languages
|
||||
FIX: handling $heightforinfotot when he's superior to a page height
|
||||
FIX: if no PDF default model in admin for expense report, do not create a PDF
|
||||
FIX: invoice payment terms edition: error management
|
||||
FIX: list of fields in list of recurring invoices was empty
|
||||
FIX: load default linked options for linked sellist extra fields
|
||||
FIX: Loan - Return on list when you cancel create form or delete a loan
|
||||
FIX: Missing lang trans
|
||||
FIX: no empty value in required extrafield
|
||||
FIX: Param joinfiles not sanitized
|
||||
FIX: Payment by BankTransfer
|
||||
FIX: pdf_getlinetotalwithtax must show total incl tax
|
||||
FIX: Problem on supplier payment card
|
||||
FIX: product auto volume calculation
|
||||
FIX: product customer prices: missing triggers in CRUD class
|
||||
FIX: Request on purchase orders in timeout even on very small databases
|
||||
FIX: set paid on total discount of a product in cash desk
|
||||
FIX: several warning with the barcode use in ODT templates
|
||||
FIX: SHIP MODE install v12 bug insert
|
||||
FIX: stripe for connect mode
|
||||
FIX: subcat filter
|
||||
FIX: supplier invoice: automatically calculate payment term when modifying payment condition
|
||||
FIX: SUPPLIER PROPOSAL v12 bug add
|
||||
FIX: table making extrafield input too small on advance target mailing
|
||||
FIX: table making extrafield too small advtagertmailing
|
||||
FIX: Unable to edit extrafields in expense report
|
||||
FIX: update margins rates on object line edit
|
||||
FIX: uses price2numjs
|
||||
FIX: various payments: bad data handling for subledger account + useless db commit/rollback
|
||||
FIX: virtual products: displayed value is by unit
|
||||
FIX: virtual products: supplier discount was not applied in component list
|
||||
FIX: warning for purchase order delivery late.
|
||||
FIX: Warning on late purchase order delivery
|
||||
FIX: WORKFLOW_ORDER_CLASSIFY_SHIPPED_SHIPPING must not consider services while STOCK_SUPPORTS_SERVICES is empty
|
||||
FIX: wrong tab
|
||||
FIX: Yogosha report 4425 (backport)
|
||||
FIX: Yogosha report 4434 (backport)
|
||||
|
||||
***** ChangeLog for 12.0.3 compared to 12.0.2 *****
|
||||
FIX: 10.0 - when the mime file name is different from the filesystem name, the attachment name should be the mime filename
|
||||
FIX: 11.0 - expenses lines overlapping the total amounts frame
|
||||
FIX: 12.0 - round value of virtual stock on product stock reassort list
|
||||
FIX: #14469
|
||||
FIX: #14474 Error when deleting
|
||||
FIX: #14530
|
||||
FIX: #14703
|
||||
FIX: - Accountancy balance Error SQL on entity
|
||||
FIX: Bad number of subscription (forgotten when member was resiliated)
|
||||
FIX: bad route url to delete subproduct with API
|
||||
FIX: Category for suplements not saved
|
||||
FIX: Compatibility with modules without document generation
|
||||
FIX: Cron load lang
|
||||
FIX: CSS
|
||||
FIX: Error management. Do no try to approve PO if validation fails.
|
||||
FIX: expenses lines overlapping the frame for total amounts.
|
||||
FIX: Filter in "billed" of orders was not saved
|
||||
FIX: infinite fetch object linked loop
|
||||
FIX: Intervention lose html tags when updating
|
||||
FIX: JS CRASH - bad usage of moreparam
|
||||
FIX: lang fr retained warranty
|
||||
FIX: Look and feel v12: First tab must be name of object
|
||||
FIX: missing entity check
|
||||
FIX: missing param for hook
|
||||
FIX: Missing transaction on PO actions
|
||||
FIX: MySql Strict mode
|
||||
FIX: param entity in html form file
|
||||
FIX: Problems on FEC format
|
||||
FIX: round stock value on product list
|
||||
FIX: - Send mail from contact : select mail model
|
||||
FIX: set sales representatives on create company card
|
||||
FIX: Setup of stock increase/decrease
|
||||
FIX: sign of amount with credit note and multicurrencies
|
||||
FIX: Static property called as non static
|
||||
FIX: task leftmenu
|
||||
FIX: title button attribute id empty
|
||||
FIX: unit price divided by quantity when accepting supplier price proposal
|
||||
FIX: Update extrafields on line only if it is supported
|
||||
FIX: Update line of BOM
|
||||
FIX: using decimal on stock correction
|
||||
FIX: Visualization rights correction on last modified contacts box
|
||||
FIX: Wrong redirection
|
||||
FIX: Yogosha report 4425 (backport)
|
||||
|
||||
***** ChangeLog for 12.0.2 compared to 12.0.1 *****
|
||||
FIX: computation of the bottom margin of <body> returns NaN because body is not loaded yet
|
||||
FIX: DebugBar hides content at page bottom
|
||||
FIX: allow more harmless html tags
|
||||
FIX: Bad back to link
|
||||
FIX: Bad param
|
||||
FIX: Can go on page even when module is disabled
|
||||
FIX: Change position of line in BOM
|
||||
FIX: Checkbox "drop table" was not checked when using php method to generate backup dump
|
||||
FIX: ClickToDial tab of users has disappeared
|
||||
FIX: CSS
|
||||
FIX: date in supplier price log tooltip.
|
||||
FIX: Debug module direct debit order. Solve conflict with credit transfer
|
||||
FIX: Debug setup of receipt printer module
|
||||
FIX: dolGetElementUrl and agenda page for external modules
|
||||
FIX: DO not erase variable $key and $label during output of extrafields
|
||||
FIX: duration fields size with firefox
|
||||
FIX: Edit extrafield of type long text loose carriage returns
|
||||
FIX: Fails to retraive accounting code of social contribution sometimes
|
||||
FIX: Filter too large for extrafields with type text or html
|
||||
FIX: If using a rounding step, localtax1+2 not included in total
|
||||
FIX: input field of extrafields must keep data if form submit fails.
|
||||
FIX: Label of opportunities in graph with special chars badly encoded
|
||||
FIX: locataxes lost on lines when cloning a vendor invoice
|
||||
FIX: Look and feel v12
|
||||
FIX: Missing PRODUIT_TEXTS_IN_THIRDPARTY_LANGUAGE conf support in supplier order
|
||||
FIX: Navigation in object fails to find the next ref in some cases
|
||||
FIX: null required
|
||||
FIX: order by amount ht uses wrong column
|
||||
FIX: Order by amount in product propal stats must be done on d.total_ht and not p.total
|
||||
FIX: page for confirmation of payments is empty
|
||||
FIX: Param of fetch_name_optionals_label must be object->table_element
|
||||
FIX: Picto of HRM module
|
||||
FIX: product label and desc were never updated when modifying translation
|
||||
FIX: redirect on contact card from main search
|
||||
FIX: Reposition and nav
|
||||
FIX: search warehouse list
|
||||
FIX: Setup of clicktodial hang on smartphone
|
||||
FIX: Setup of currency limit and accuracy
|
||||
FIX: shipping creation: checks not done on weight and sizes
|
||||
FIX: Should not be able to edit qty on shipment when no stock available
|
||||
FIX: Size of image on the help popup of modules
|
||||
FIX: Sql error on stat by referring entries of a product
|
||||
FIX: Warning if no bank account defined
|
||||
FIX: We need to see unit line on PDF even though it's an option
|
||||
FIX: wrong element var for fetch_name_optionals_label function with expeditions
|
||||
FIX: wrong link to third invoice templates
|
||||
FIX: Disable svg as supported image by default (can contains javascript). Set MAIN_ALLOW_SVG_FILES_AS_IMAGES to 1 to have svg accepted
|
||||
FIX: #14076
|
||||
FIX: #14146
|
||||
FIX: #14209
|
||||
FIX: #14222
|
||||
FIX: #14236
|
||||
FIX: #14241 Mysql 8 compatibility
|
||||
FIX: #14253
|
||||
FIX: #14256
|
||||
FIX: #14259
|
||||
FIX: #14279
|
||||
FIX: #14291
|
||||
FIX: #14292
|
||||
FIX: #14336
|
||||
|
||||
***** ChangeLog for 12.0.1 compared to 12.0.0 *****
|
||||
FIX: reposition was broken if url end with #anchor
|
||||
FIX: $_POST must be GETPOST
|
||||
FIX: 10.0 - fatal with postgreSQL
|
||||
FIX: #14109
|
||||
FIX: #14112
|
||||
FIX: #14142
|
||||
FIX: all extrafields cleared after update of one of them
|
||||
FIX: Avoid warning when creating a module with already existing files
|
||||
FIX: change selected fields on company card
|
||||
FIX: Correct ModuleBuilder left menu
|
||||
FIX: create a deposit with amount using comma didn't work
|
||||
FIX: CSS
|
||||
FIX: Entry from stripe intent were reported into SEPA payments
|
||||
FIX: Filter on status, closing opening status
|
||||
FIX: html lost on html extrafield
|
||||
FIX: Label of popup on thirdparty
|
||||
FIX: missing possibility to change entity when propal cloning
|
||||
FIX: missing setup of extrafields for MO
|
||||
FIX: Missing the tooltip when creating bank account
|
||||
FIX: Missing token
|
||||
FIX: non numeric value on comm/card.php
|
||||
FIX: SQL Problem in customer invoice list
|
||||
FIX: SQL Problem in social contribution list
|
||||
FIX: SQL Problem in supplier invoice list
|
||||
FIX: SQL syntax error when editing extrafields
|
||||
FIX: Sql type
|
||||
FIX: takepos 12 hook
|
||||
FIX: Update form erased extrafields that were hidden
|
||||
FIX: Update of extrafields date
|
||||
FIX: Update of extrafiels on draft object
|
||||
FIX: upload documents into manual ECM was reported a permission error
|
||||
FIX: Use of office365 TLS with SMTPs method.
|
||||
FIX: wrong origin
|
||||
FIX: Permission error during import
|
||||
|
||||
***** ChangeLog for 12.0.0 compared to 11.0.0 *****
|
||||
For users:
|
||||
|
||||
@@ -104,8 +397,8 @@ NEW: class tool for converting units
|
||||
NEW: Close #13011 Add button create thirdparty when creating intervention
|
||||
NEW: Colorful theme for TakePOS
|
||||
NEW: columns units in product list
|
||||
NEW: compatibility of translabel with more dict
|
||||
NEW: Confirm file delete on fracture card
|
||||
NEW: compatibility of translabel with more dictionaries
|
||||
NEW: Confirm file delete on invoice card
|
||||
NEW: "contact_civility" for ODT templates
|
||||
NEW: CUPS printing compatibility for TakePOS
|
||||
NEW: Customer command list - Add date start & date end
|
||||
@@ -113,16 +406,11 @@ NEW: display weight in shipment list
|
||||
NEW: Documentation about PHP support in Dolibarr
|
||||
NEW: Donation - Update FR CERFA to 11580*04
|
||||
NEW: Easier way to setup the different types of tax. Better visibility.
|
||||
NEW: enable put for agendaevents api
|
||||
NEW: Expedition list - Add date start & date end
|
||||
NEW: Experiment supplier packaging with option PRODUCT_USE_SUPPLIER_PACKAGING: Using price according to the minimum quantity
|
||||
NEW: Export module, add extrafields for Contract and Contract line
|
||||
NEW: Extend retained warranty to be available for all invoices
|
||||
NEW: filter by product on supplier order API
|
||||
NEW: French new regions
|
||||
NEW: get documents for categories with RESP API
|
||||
NEW: get proposal by ref with API
|
||||
NEW: Hidden option MAIN_TEMP_DIR
|
||||
NEW: hook and data id
|
||||
NEW: hook on ics generation to add more events in eventarray
|
||||
NEW: hook on product load stats
|
||||
@@ -195,7 +483,6 @@ NEW: API filter bankaccounts by category
|
||||
NEW: API filter contacts by category
|
||||
NEW: API filter members by category
|
||||
NEW: API filter projects by category
|
||||
NEW: API filter thirdpartie by category
|
||||
NEW: API filter thirdparty by category
|
||||
NEW: API filter user by category
|
||||
NEW: API filter warehouses by categorie
|
||||
@@ -209,6 +496,11 @@ NEW: Bookkeeping by account - Add selectfields & hook
|
||||
NEW: Can force position of legend of graph on right (instead of top)
|
||||
NEW: Can change destination of "Back to list" using a "backtolist" parameter
|
||||
NEW: add more category types from hook
|
||||
NEW: enable put for agendaevents api
|
||||
NEW: filter by product on supplier order API
|
||||
NEW: get documents for categories with RESP API
|
||||
NEW: get proposal by ref with API
|
||||
NEW: Hidden option MAIN_TEMP_DIR
|
||||
|
||||
WARNING:
|
||||
|
||||
@@ -242,6 +534,52 @@ Only people that installed Dolibarr using the all-in-one autoinstaller for Windo
|
||||
DoliWAMP remains a solution for fast test or demo purposes.
|
||||
|
||||
|
||||
***** ChangeLog for 11.0.5 compared to 11.0.4 *****
|
||||
FIX: $arraydefaultmessage is an object, as well as in /htdocs/core/class/html.formmail.class.php
|
||||
FIX: 10.0 - pagination in prelevement/bons.php
|
||||
FIX: 10.0 - undefined $langs if template file copy fails during activation of modContrat
|
||||
FIX: 11.0 - fatal with postgres on contact/agenda.php
|
||||
FIX: 11.0 - multicurrency amount not fetched when fetching payments from llx_paiement or llx_paiementfourn
|
||||
FIX: 11.0 - when using pdftk as per hidden conf USE_PDFTK_FOR_PDF_CONCAT, check that the file exists before displaying a success message
|
||||
FIX: #13841
|
||||
FIX: #13877 - Can validate invoice if there is a credit note with VAT 0% on an invoice with other lines with a VAT non 0%
|
||||
FIX: #13968
|
||||
FIX: #14001
|
||||
FIX: #14002
|
||||
FIX: 9.0 - delete unused mandatory argument from migrate_clean_association: argument count mismatch causes a fatal error since php7
|
||||
FIX: 9.0 - fatal during migration from 3.1 using PHP 7
|
||||
FIX: Accountancy - Binding index - Add a filter on sql request for module Subtotal & Jalon
|
||||
FIX: avoid error "Call to undefined function measuringUnitString()"
|
||||
FIX: BlindBoolean SQL injection reported by Christian Weiler
|
||||
FIX: Can create a credit note on situation invoice if previous is also
|
||||
FIX: can install module even if (x) was appended during download.
|
||||
FIX: copy value date of VariousPayment onto the new AccountLine
|
||||
FIX: count of open day when date and start are not open should be 0
|
||||
FIX: Default bank account was not loaded for document generation.
|
||||
FIX: Do not show stats panel if the user does not have permissions
|
||||
FIX: Fix link of the button to create a credit note and fix the awareness of a error that happen when wo create a credit note
|
||||
FIX: force rounding 2 on export ld compta
|
||||
FIX: free text on cash desk
|
||||
FIX: links into emails of notifications
|
||||
FIX: missing file manifest.json.php
|
||||
FIX: missing GetNomURL Hook in warehouse class
|
||||
FIX: missing hook init + table class + $page not set
|
||||
FIX: missing rollbacks on trigger bad return
|
||||
FIX: missing translation value for key "NoMorePredefinedProductToDispatch"
|
||||
FIX: percent must be displayed on one line
|
||||
FIX: php error if multicompany disabled
|
||||
FIX: Privilege escalation reported by wizlynx WLX-2020-011
|
||||
FIX: replace filter parameter "none" by "restricthtml"
|
||||
FIX: Rounding Total TVA in "crabe" model pdf
|
||||
FIX: Show ref_customer, amount on contract link object
|
||||
FIX: Site ec.europa.eu has moved to https://
|
||||
FIX: Tickets mail models doesn't work
|
||||
FIX: vulnerability reported by wizlynx WLX-2020-012
|
||||
FIX: We must only rename current bank receipt
|
||||
FIX: when creating a VariousPayment, the value date is not copied onto the AccountLine that gets created at the same time, so the bank transaction's value date will be the payment date instead of the payment's value date
|
||||
FIX: wrong url param
|
||||
FIX: XSS using the renaming of .noexe files - reported by Nolan.
|
||||
|
||||
***** ChangeLog for 11.0.4 compared to 11.0.3 *****
|
||||
FIX: #13749
|
||||
FIX: #7594 Expense report multi pagebreak
|
||||
|
||||
@@ -91,14 +91,15 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog)
|
||||
- Products and/or Services catalog
|
||||
- Commercial proposals management
|
||||
- Customer & Supplier Orders management
|
||||
- Invoices and payment management
|
||||
- Shipping management
|
||||
- Warehouse/Stock management
|
||||
- Invoices and payment management
|
||||
- Standing orders management (European SEPA)
|
||||
- Manufacturing Orders
|
||||
- Bank accounts management
|
||||
- Direct debit orders management (European SEPA)
|
||||
- Accounting management
|
||||
- Shared calendar/agenda (with ical and vcal export for third party tools integration)
|
||||
- Opportunities and/or project management
|
||||
- Opportunities or Leads management
|
||||
- Projects & Tasks management
|
||||
- Contracts management
|
||||
- Interventions management
|
||||
|
||||
@@ -14,7 +14,7 @@ Architecture: all
|
||||
Depends: libapache2-mod-php5 | libapache2-mod-php5filter | php5-cgi | php5-fpm | php5 | libapache2-mod-php | libapache2-mod-phpfilter | php-cgi | php-fpm | php,
|
||||
php5-cli | php-cli,
|
||||
# Required PHP extensions
|
||||
php5-mysql | php5-mysqli | php-mysql | php-mysqli, php5-curl | php-curl, php5-gd | php-gd, php5-ldap | php-gd,
|
||||
php5-mysql | php5-mysqli | php-mysql | php-mysqli, php5-curl | php-curl, php5-gd | php-gd, php5-ldap | php-gd, php5-zip | php-zip,
|
||||
# Required PHP libraries
|
||||
php-pear, php-mail-mime,
|
||||
# php-tcpdf,
|
||||
|
||||
@@ -5,7 +5,7 @@ File added into doxygen generated documentation
|
||||
|
||||
|
||||
<hr class="footer" />
|
||||
<address class="footer"><small>Generated on $datetime for <a href="https://www.dolibarr.org">$projectname</a> by Doxygen $doxygenversion </small></address>
|
||||
<address class="footer"><small>Generated on $datetime for <a href="https://www.dolibarr.org" title="ERP and CRM open source software">$projectname</a> by Doxygen $doxygenversion </small></address>
|
||||
|
||||
|
||||
<br>
|
||||
@@ -22,31 +22,5 @@ File added into doxygen generated documentation
|
||||
gtag('config', 'UA-9049390-16');
|
||||
</script>
|
||||
|
||||
|
||||
<!-- Facebook Pixel Code -->
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '1998533953704960');
|
||||
fbq('track', "PageView");</script>
|
||||
<noscript><img height="1" width="1" style="display:none"
|
||||
src="https://www.facebook.com/tr?id=1998533953704960&ev=PageView&noscript=1"
|
||||
/></noscript>
|
||||
<!-- End Facebook Pixel Code -->
|
||||
|
||||
|
||||
<!-- Twitter ad collector -->
|
||||
<script src="//static.ads-twitter.com/oct.js" type="text/javascript"></script>
|
||||
<script type="text/javascript">twttr.conversion.trackPid('ntm4n', { tw_sale_amount: 0, tw_order_quantity: 0 });</script>
|
||||
<noscript>
|
||||
<img height="1" width="1" style="display:none;" alt="" src="https://analytics.twitter.com/i/adsct?txn_id=ntm4n&p_id=Twitter&tw_sale_amount=0&tw_order_quantity=0" />
|
||||
<img height="1" width="1" style="display:none;" alt="" src="//t.co/i/adsct?txn_id=ntm4n&p_id=Twitter&tw_sale_amount=0&tw_order_quantity=0" />
|
||||
</noscript>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -12,21 +12,6 @@
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<!-- End from dolibarr.org -->
|
||||
|
||||
<!-- Facebook Pixel Code -->
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '1998533953704960');
|
||||
fbq('track', "PageView");</script>
|
||||
<noscript><img height="1" width="1" style="display:none"
|
||||
src="https://www.facebook.com/tr?id=1998533953704960&ev=PageView&noscript=1"
|
||||
/></noscript>
|
||||
<!-- End Facebook Pixel Code -->
|
||||
</head>
|
||||
|
||||
<body>
|
||||
@@ -48,15 +33,6 @@ src="https://www.facebook.com/tr?id=1998533953704960&ev=PageView&noscript=1"
|
||||
<div class="bannergroupmybanner">
|
||||
|
||||
<div class="banneritemmybanner">
|
||||
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
|
||||
<!-- BAN_728x90_DOXYGEN -->
|
||||
<ins class="adsbygoogle"
|
||||
style="display:inline-block;width:728px;height:90px"
|
||||
data-ad-client="ca-pub-1465985984238664"
|
||||
data-ad-slot="4297390217"></ins>
|
||||
<script>
|
||||
(adsbygoogle = window.adsbygoogle || []).push({});
|
||||
</script>
|
||||
<div class="clr"></div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -32,6 +32,7 @@ PortAlreadyInUse=Port %1 seems to be already in use. You should cancel to go bac
|
||||
|
||||
FirefoxDetected=Firefox has been detected on your computer. Would you like to use it as the default browser for Dolibarr ?
|
||||
ChromeDetected=Chrome has been detected on your computer. Would you like to use it as the default browser for Dolibarr ?
|
||||
MicrosoftEdgeDetected=Microsoft Edge has been detected on your computer. Would you like to use it as the default browser for Dolibarr ?
|
||||
ChooseDefaultBrowser=Please choose your default browser (iexplore.exe, firefox.exe, chrome.exe, MicrosoftEdge.exe...). If you are not sure, just click Open :
|
||||
|
||||
LaunchNow=Launch Dolibarr now
|
||||
|
||||
@@ -104,8 +104,8 @@ Source: "build\exe\doliwamp\UsedPort.exe"; DestDir: "{app}\"; Flags: ignoreversi
|
||||
; Value OK: apache 2.2.6, php 5.2.5 (5.2.11, 5.3.0 and 5.3.1 fails if php_exif, php_pgsql, php_zip is on), mysql 5.0.45
|
||||
; Value OK: apache 2.2.11, php 5.3.0 (if no php_exif, php_pgsql, php_zip), mysql 5.0.45
|
||||
; Value OK: apache 2.4.9, php 5.5.12, mysql 5.0.45 instead of 5.6.17 (wampserver2.5-Apache-2.4.9-Mysql-5.6.17-php5.5.12-32b.exe)
|
||||
; Value To test: apache 2.4.41, php 7.3.12, mariadb10.4.10 (wampserver3.2.0_x64.exe)
|
||||
Source: "C:\Program Files\Wamp\apps\phpmyadmin4.1.14\*.*"; DestDir: "{app}\apps\phpmyadmin4.1.14"; Flags: ignoreversion recursesubdirs; Excludes: "config.inc.php,wampserver.conf,*.log,*_log,darkblue_orange"
|
||||
; Value OK: apache 2.4.41, php 7.3.12, mariadb10.4.10 (wampserver3.2.0_x64.exe)
|
||||
Source: "C:\wamp64\apps\phpmyadmin4.9.2\*.*"; DestDir: "{app}\apps\phpmyadmin4.9.2"; Flags: ignoreversion recursesubdirs; Excludes: "config.inc.php,wampserver.conf,*.log,*_log,darkblue_orange"
|
||||
;Source: "C:\Program Files\Wamp\bin\apache\apache2.4.9\*.*"; DestDir: "{app}\bin\apache\apache2.4.9"; Flags: ignoreversion recursesubdirs; Excludes: "php.ini,httpd.conf,wampserver.conf,*.log,*_log"
|
||||
Source: "C:\wamp64\bin\apache\apache2.4.41\*.*"; DestDir: "{app}\bin\apache\apache2.4.41"; Flags: ignoreversion recursesubdirs; Excludes: "php.ini,httpd.conf,wampserver.conf,*.log,*_log"
|
||||
;Source: "C:\Program Files\Wamp\bin\php\php5.5.12\*.*"; DestDir: "{app}\bin\php\php5.5.12"; Flags: ignoreversion recursesubdirs; Excludes: "php.ini,phpForApache.ini,wampserver.conf,*.log,*_log"
|
||||
@@ -519,7 +519,7 @@ begin
|
||||
// check that we don't try an upgrade (mysql upgrade no supported)
|
||||
//----------------------------------------------
|
||||
|
||||
if FileExists (pathWithSlashes+'/bin/mysql/mysql5.0.45'+phpVersion+'/bin/mysqld-nt.exe') then
|
||||
if FileExists (pathWithSlashes+'/bin/mysql/mysql5.0.45/bin/mysqld-nt.exe') then
|
||||
begin
|
||||
MsgBox('An existing installation using an old version of Mysql exists. Sorry, upgrade with this installer is not possible.', mbInformation, MB_OK);
|
||||
Abort();
|
||||
@@ -588,15 +588,26 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
if browser = 'iexplore.exe' then
|
||||
begin
|
||||
if FileExists (winPath+'/SystemApps/Microsoft.MicrosoftEdge_8wekyb3d8bbwe/MicrosoftEdge.exe') then
|
||||
begin
|
||||
if MsgBox(CustomMessage('MicrosoftEdgeDetected'),mbConfirmation,MB_YESNO) = IDYES then
|
||||
begin
|
||||
browser := winPath+'/SystemApps/Microsoft.MicrosoftEdge_8wekyb3d8bbwe/MicrosoftEdge.exe';
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
if browser = 'iexplore.exe' then
|
||||
begin
|
||||
if FileExists (pfPath+'/Internet Explorer/iexplore.exe') then
|
||||
begin
|
||||
GetOpenFileName(CustomMessage('ChooseDefaultBrowser'), browser, pfPath+'/Internet Explorer','exe files (*.exe)|*.exe|All files (*.*)|*.*' ,'exe');
|
||||
GetOpenFileName(CustomMessage('ChooseDefaultBrowser'), browser, pfPath+'/Internet Explorer', 'exe files (*.exe)|*.exe|All files (*.*)|*.*' ,'exe');
|
||||
end
|
||||
else
|
||||
begin
|
||||
GetOpenFileName(CustomMessage('ChooseDefaultBrowser'), browser, winPath,'exe files (*.exe)|*.exe|All files (*.*)|*.*' ,'exe');
|
||||
GetOpenFileName(CustomMessage('ChooseDefaultBrowser'), browser, winPath, 'exe files (*.exe)|*.exe|All files (*.*)|*.*' ,'exe');
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@ ALL:
|
||||
Check "@CHANGE"
|
||||
|
||||
|
||||
|
||||
PrestaShopWebservice:
|
||||
---------------------
|
||||
Replace
|
||||
@@ -27,6 +28,19 @@ With
|
||||
|
||||
|
||||
|
||||
DEBUGBAR:
|
||||
---------
|
||||
|
||||
Move
|
||||
this.options = {
|
||||
bodyMarginBottom: true,
|
||||
bodyMarginBottomHeight: parseInt($('body').css('margin-bottom')),
|
||||
};
|
||||
few line lower in the
|
||||
initialize: function() {
|
||||
|
||||
|
||||
|
||||
ESCPOS:
|
||||
-------
|
||||
Replace
|
||||
@@ -306,7 +320,7 @@ SELECT2
|
||||
Edit CSS to restore line removed between 4.0.5 and 4.0.6. It generates this bug: https://github.com/select2/select2/issues/5832
|
||||
|
||||
.select2-hidden-accessible {
|
||||
margin: -1px !important; /* line to restore */
|
||||
margin: -10000px !important; /* line to restore */
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1326,7 +1326,7 @@ CREATE TABLE `llx_boxes_def` (
|
||||
|
||||
LOCK TABLES `llx_boxes_def` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_boxes_def` DISABLE KEYS */;
|
||||
INSERT INTO `llx_boxes_def` VALUES (188,'box_services_vendus.php',1,'2013-08-05 20:40:27',NULL),(323,'box_actions.php',2,'2015-03-13 15:29:19',NULL),(324,'box_clients.php',2,'2015-03-13 20:21:35',NULL),(325,'box_prospect.php',2,'2015-03-13 20:21:35',NULL),(326,'box_contacts.php',2,'2015-03-13 20:21:35',NULL),(327,'box_activity.php',2,'2015-03-13 20:21:35','(WarningUsingThisBoxSlowDown)'),(328,'box_propales.php',2,'2015-03-13 20:32:38',NULL),(329,'box_comptes.php',2,'2015-03-13 20:33:09',NULL),(330,'box_factures_imp.php',2,'2015-03-13 20:33:09',NULL),(331,'box_factures.php',2,'2015-03-13 20:33:09',NULL),(332,'box_produits.php',2,'2015-03-13 20:33:09',NULL),(333,'box_produits_alerte_stock.php',2,'2015-03-13 20:33:09',NULL),(347,'box_clients.php',1,'2017-11-15 22:05:57',NULL),(348,'box_prospect.php',1,'2017-11-15 22:05:57',NULL),(349,'box_contacts.php',1,'2017-11-15 22:05:57',NULL),(350,'box_activity.php',1,'2017-11-15 22:05:57','(WarningUsingThisBoxSlowDown)'),(374,'box_services_contracts.php',1,'2017-11-15 22:38:37',NULL),(377,'box_project.php',1,'2017-11-15 22:38:44',NULL),(378,'box_task.php',1,'2017-11-15 22:38:44',NULL),(388,'box_contracts.php',1,'2017-11-15 22:39:52',NULL),(389,'box_services_expired.php',1,'2017-11-15 22:39:52',NULL),(390,'box_ficheinter.php',1,'2017-11-15 22:39:56',NULL),(392,'box_graph_propales_permonth.php',1,'2017-11-15 22:41:47',NULL),(393,'box_propales.php',1,'2017-11-15 22:41:47',NULL),(396,'box_graph_product_distribution.php',1,'2017-11-15 22:41:47',NULL),(403,'box_goodcustomers.php',1,'2018-07-30 11:13:20','(WarningUsingThisBoxSlowDown)'),(404,'box_external_rss.php',1,'2018-07-30 11:15:25','1 (Dolibarr.org News)'),(409,'box_produits.php',1,'2018-07-30 13:38:11',NULL),(410,'box_produits_alerte_stock.php',1,'2018-07-30 13:38:11',NULL),(411,'box_commandes.php',1,'2018-07-30 13:38:11',NULL),(412,'box_graph_orders_permonth.php',1,'2018-07-30 13:38:11',NULL),(413,'box_graph_invoices_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(414,'box_graph_orders_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(415,'box_fournisseurs.php',1,'2018-07-30 13:38:11',NULL),(416,'box_factures_fourn_imp.php',1,'2018-07-30 13:38:11',NULL),(417,'box_factures_fourn.php',1,'2018-07-30 13:38:11',NULL),(418,'box_supplier_orders.php',1,'2018-07-30 13:38:11',NULL),(419,'box_actions.php',1,'2018-07-30 15:42:32',NULL),(424,'box_factures_imp.php',1,'2017-02-07 18:56:12',NULL),(425,'box_factures.php',1,'2017-02-07 18:56:12',NULL),(426,'box_graph_invoices_permonth.php',1,'2017-02-07 18:56:12',NULL),(427,'box_comptes.php',1,'2017-02-07 18:56:12',NULL),(429,'box_lastlogin.php',1,'2017-08-27 13:29:14',NULL),(430,'box_bookmarks.php',1,'2018-01-19 11:27:34',NULL),(431,'box_members.php',1,'2018-01-19 11:27:56',NULL),(432,'box_birthdays.php',1,'2019-06-05 08:45:40',NULL),(433,'box_last_ticket',1,'2019-06-05 09:15:29',NULL),(434,'box_last_modified_ticket',1,'2019-06-05 09:15:29',NULL),(436,'box_accountancy_last_manual_entries.php',1,'2019-11-28 11:52:58',NULL),(437,'box_accountancy_suspense_account.php',1,'2019-11-28 11:52:58',NULL),(438,'box_supplier_orders_awaiting_reception.php',1,'2019-11-28 11:52:59',NULL),(439,'box_mos.php',1,'2019-11-29 08:57:42',NULL),(445,'box_shipments.php',1,'2020-01-13 14:38:20',NULL);
|
||||
INSERT INTO `llx_boxes_def` VALUES (323,'box_actions.php',2,'2015-03-13 15:29:19',NULL),(324,'box_clients.php',2,'2015-03-13 20:21:35',NULL),(325,'box_prospect.php',2,'2015-03-13 20:21:35',NULL),(326,'box_contacts.php',2,'2015-03-13 20:21:35',NULL),(327,'box_activity.php',2,'2015-03-13 20:21:35','(WarningUsingThisBoxSlowDown)'),(328,'box_propales.php',2,'2015-03-13 20:32:38',NULL),(329,'box_comptes.php',2,'2015-03-13 20:33:09',NULL),(330,'box_factures_imp.php',2,'2015-03-13 20:33:09',NULL),(331,'box_factures.php',2,'2015-03-13 20:33:09',NULL),(332,'box_produits.php',2,'2015-03-13 20:33:09',NULL),(333,'box_produits_alerte_stock.php',2,'2015-03-13 20:33:09',NULL),(347,'box_clients.php',1,'2017-11-15 22:05:57',NULL),(348,'box_prospect.php',1,'2017-11-15 22:05:57',NULL),(349,'box_contacts.php',1,'2017-11-15 22:05:57',NULL),(350,'box_activity.php',1,'2017-11-15 22:05:57','(WarningUsingThisBoxSlowDown)'),(374,'box_services_contracts.php',1,'2017-11-15 22:38:37',NULL),(377,'box_project.php',1,'2017-11-15 22:38:44',NULL),(378,'box_task.php',1,'2017-11-15 22:38:44',NULL),(388,'box_contracts.php',1,'2017-11-15 22:39:52',NULL),(389,'box_services_expired.php',1,'2017-11-15 22:39:52',NULL),(390,'box_ficheinter.php',1,'2017-11-15 22:39:56',NULL),(392,'box_graph_propales_permonth.php',1,'2017-11-15 22:41:47',NULL),(393,'box_propales.php',1,'2017-11-15 22:41:47',NULL),(396,'box_graph_product_distribution.php',1,'2017-11-15 22:41:47',NULL),(403,'box_goodcustomers.php',1,'2018-07-30 11:13:20','(WarningUsingThisBoxSlowDown)'),(404,'box_external_rss.php',1,'2018-07-30 11:15:25','1 (Dolibarr.org News)'),(409,'box_produits.php',1,'2018-07-30 13:38:11',NULL),(410,'box_produits_alerte_stock.php',1,'2018-07-30 13:38:11',NULL),(411,'box_commandes.php',1,'2018-07-30 13:38:11',NULL),(412,'box_graph_orders_permonth.php',1,'2018-07-30 13:38:11',NULL),(413,'box_graph_invoices_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(414,'box_graph_orders_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(415,'box_fournisseurs.php',1,'2018-07-30 13:38:11',NULL),(416,'box_factures_fourn_imp.php',1,'2018-07-30 13:38:11',NULL),(417,'box_factures_fourn.php',1,'2018-07-30 13:38:11',NULL),(418,'box_supplier_orders.php',1,'2018-07-30 13:38:11',NULL),(419,'box_actions.php',1,'2018-07-30 15:42:32',NULL),(424,'box_factures_imp.php',1,'2017-02-07 18:56:12',NULL),(425,'box_factures.php',1,'2017-02-07 18:56:12',NULL),(426,'box_graph_invoices_permonth.php',1,'2017-02-07 18:56:12',NULL),(427,'box_comptes.php',1,'2017-02-07 18:56:12',NULL),(429,'box_lastlogin.php',1,'2017-08-27 13:29:14',NULL),(430,'box_bookmarks.php',1,'2018-01-19 11:27:34',NULL),(431,'box_members.php',1,'2018-01-19 11:27:56',NULL),(432,'box_birthdays.php',1,'2019-06-05 08:45:40',NULL),(433,'box_last_ticket',1,'2019-06-05 09:15:29',NULL),(434,'box_last_modified_ticket',1,'2019-06-05 09:15:29',NULL),(436,'box_accountancy_last_manual_entries.php',1,'2019-11-28 11:52:58',NULL),(437,'box_accountancy_suspense_account.php',1,'2019-11-28 11:52:58',NULL),(438,'box_supplier_orders_awaiting_reception.php',1,'2019-11-28 11:52:59',NULL),(439,'box_mos.php',1,'2019-11-29 08:57:42',NULL),(445,'box_shipments.php',1,'2020-01-13 14:38:20',NULL);
|
||||
/*!40000 ALTER TABLE `llx_boxes_def` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
172
dev/resources/sepa/sample-credit-transfer.xml
Normal file
172
dev/resources/sepa/sample-credit-transfer.xml
Normal file
@@ -0,0 +1,172 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Document xmlns="urn:iso:std:iso:20022:tech:xsd:pain.001.001.03">
|
||||
<CstmrCdtTrfInitn>
|
||||
<GrpHdr>
|
||||
<MsgId>message-id-001</MsgId>
|
||||
<CreDtTm>2010-09-28T14:07:00</CreDtTm>
|
||||
<NbOfTxs>1</NbOfTxs>
|
||||
<CtrlSum>10.1</CtrlSum>
|
||||
<InitgPty>
|
||||
<Nm>Bedrijfsnaam</Nm>
|
||||
<Id>
|
||||
<OrgId>
|
||||
<Othr>
|
||||
<Id>123456789123456</Id>
|
||||
</Othr>
|
||||
</OrgId>
|
||||
</Id>
|
||||
</InitgPty>
|
||||
</GrpHdr>
|
||||
<PmtInf>
|
||||
<PmtInfId>minimaal gevuld</PmtInfId>
|
||||
<PmtMtd>TRF</PmtMtd>
|
||||
<NbOfTxs>1</NbOfTxs>
|
||||
<CtrlSum>10.1</CtrlSum>
|
||||
<ReqdExctnDt>2009-11-01</ReqdExctnDt>
|
||||
<Dbtr>
|
||||
<Nm>Naam</Nm>
|
||||
</Dbtr>
|
||||
<DbtrAcct>
|
||||
<Id>
|
||||
<IBAN>NL44RABO0123456789</IBAN>
|
||||
</Id>
|
||||
</DbtrAcct>
|
||||
<DbtrAgt>
|
||||
<FinInstnId>
|
||||
<BIC>RABONL2U</BIC>
|
||||
</FinInstnId>
|
||||
</DbtrAgt>
|
||||
<CdtTrfTxInf>
|
||||
<PmtId>
|
||||
<EndToEndId>non ref</EndToEndId>
|
||||
</PmtId>
|
||||
<Amt>
|
||||
<InstdAmt Ccy="EUR">10.1</InstdAmt>
|
||||
</Amt>
|
||||
<ChrgBr>SLEV</ChrgBr>
|
||||
<CdtrAgt>
|
||||
<FinInstnId>
|
||||
<BIC>ABNANL2A</BIC>
|
||||
</FinInstnId>
|
||||
</CdtrAgt>
|
||||
<Cdtr>
|
||||
<Nm>Naam creditor</Nm>
|
||||
</Cdtr>
|
||||
<CdtrAcct>
|
||||
<Id>
|
||||
<IBAN>NL90ABNA0111111111</IBAN>
|
||||
</Id>
|
||||
</CdtrAcct>
|
||||
<RmtInf>
|
||||
<Ustrd>vrije tekst</Ustrd>
|
||||
</RmtInf>
|
||||
</CdtTrfTxInf>
|
||||
</PmtInf>
|
||||
<PmtInf>
|
||||
<PmtInfId>maximaal gevuld</PmtInfId>
|
||||
<PmtMtd>TRF</PmtMtd>
|
||||
<BtchBookg>true</BtchBookg>
|
||||
<NbOfTxs>1</NbOfTxs>
|
||||
<CtrlSum>20.2</CtrlSum>
|
||||
<PmtTpInf>
|
||||
<InstrPrty>NORM</InstrPrty>
|
||||
<SvcLvl>
|
||||
<Cd>SEPA</Cd>
|
||||
</SvcLvl>
|
||||
<LclInstrm>
|
||||
<Cd>IDEAL</Cd>
|
||||
</LclInstrm>
|
||||
<CtgyPurp>
|
||||
<Cd>SECU</Cd>
|
||||
</CtgyPurp>
|
||||
</PmtTpInf>
|
||||
<ReqdExctnDt>2009-11-01</ReqdExctnDt>
|
||||
<Dbtr>
|
||||
<Nm>Naam</Nm>
|
||||
<PstlAdr>
|
||||
<Ctry>NL</Ctry>
|
||||
<AdrLine>Debtor straat 1</AdrLine>
|
||||
<AdrLine>9999 XX Plaats debtor</AdrLine>
|
||||
</PstlAdr>
|
||||
</Dbtr>
|
||||
<DbtrAcct>
|
||||
<Id>
|
||||
<IBAN>NL44RABO0123456789</IBAN>
|
||||
</Id>
|
||||
</DbtrAcct>
|
||||
<DbtrAgt>
|
||||
<FinInstnId>
|
||||
<BIC>RABONL2U</BIC>
|
||||
</FinInstnId>
|
||||
</DbtrAgt>
|
||||
<UltmtDbtr>
|
||||
<Id>
|
||||
<OrgId>
|
||||
<Othr>
|
||||
<Id>12345678</Id>
|
||||
<SchmeNm>
|
||||
<Prtry>klantnummer</Prtry>
|
||||
</SchmeNm>
|
||||
<Issr>klantnummer uitgifte instantie</Issr>
|
||||
</Othr>
|
||||
</OrgId>
|
||||
</Id>
|
||||
</UltmtDbtr>
|
||||
<ChrgBr>SLEV</ChrgBr>
|
||||
<CdtTrfTxInf>
|
||||
<PmtId>
|
||||
<InstrId>debtor-to-debtor-bank-01</InstrId>
|
||||
<EndToEndId>End-to-end-id-debtor-to-creditor-01</EndToEndId>
|
||||
</PmtId>
|
||||
<Amt>
|
||||
<InstdAmt Ccy="EUR">20.2</InstdAmt>
|
||||
</Amt>
|
||||
<CdtrAgt>
|
||||
<FinInstnId>
|
||||
<BIC>ABNANL2A</BIC>
|
||||
</FinInstnId>
|
||||
</CdtrAgt>
|
||||
<Cdtr>
|
||||
<Nm>Naam creditor</Nm>
|
||||
<PstlAdr>
|
||||
<Ctry>NL</Ctry>
|
||||
<AdrLine>Straat creditor 1</AdrLine>
|
||||
<AdrLine>9999 XX Plaats creditor</AdrLine>
|
||||
</PstlAdr>
|
||||
</Cdtr>
|
||||
<CdtrAcct>
|
||||
<Id>
|
||||
<IBAN>NL90ABNA0111111111</IBAN>
|
||||
</Id>
|
||||
</CdtrAcct>
|
||||
<UltmtCdtr>
|
||||
<Id>
|
||||
<PrvtId>
|
||||
<DtAndPlcOfBirth>
|
||||
<BirthDt>1969-07-03</BirthDt>
|
||||
<CityOfBirth>PLAATS</CityOfBirth>
|
||||
<CtryOfBirth>NL</CtryOfBirth>
|
||||
</DtAndPlcOfBirth>
|
||||
</PrvtId>
|
||||
</Id>
|
||||
</UltmtCdtr>
|
||||
<Purp>
|
||||
<Cd>CHAR</Cd>
|
||||
</Purp>
|
||||
<RmtInf>
|
||||
<Strd>
|
||||
<CdtrRefInf>
|
||||
<Tp>
|
||||
<CdOrPrtry>
|
||||
<Cd>SCOR</Cd>
|
||||
</CdOrPrtry>
|
||||
<Issr>CUR</Issr>
|
||||
</Tp>
|
||||
<Ref>1234567</Ref>
|
||||
</CdtrRefInf>
|
||||
</Strd>
|
||||
</RmtInf>
|
||||
</CdtTrfTxInf>
|
||||
</PmtInf>
|
||||
</CstmrCdtTrfInitn>
|
||||
</Document>
|
||||
@@ -1,2 +1,8 @@
|
||||
Spec for credit transfer:
|
||||
https://docs.oracle.com/cd/E39124_01/doc.91/e60210/fields_sepa_pay_file_appx.htm#EOAEL00515
|
||||
|
||||
To validate a SEPA file:
|
||||
xmllint --schema pain.001.001.03.xsd T200801.xml --noout
|
||||
|
||||
To test a SEPA file:
|
||||
https://www.mesfluxdepaiement.fr/testez-vos-fichiers-sepa
|
||||
|
||||
@@ -618,7 +618,7 @@ if ($result)
|
||||
if (empty($defaultvalue)) $defaultvalue = $compta_prodbuy;
|
||||
$codesell = length_accountg($obj->accountancy_code_buy);
|
||||
if (!empty($obj->aaid)) $defaultvalue = ''; // Do not suggest default new value is code is already valid
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1);
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1, 0, 'maxwidth300 maxwidthonsmartphone productforselect');
|
||||
print '</td>';
|
||||
} elseif ($accounting_product_mode == 'ACCOUNTANCY_BUY_INTRA') {
|
||||
// Accounting account buy intra (In EEC)
|
||||
@@ -628,7 +628,7 @@ if ($result)
|
||||
$codesell = length_accountg($obj->accountancy_code_buy_intra);
|
||||
//var_dump($defaultvalue.' - '.$codesell.' - '.$compta_prodsell);
|
||||
if (!empty($obj->aaid)) $defaultvalue = ''; // Do not suggest default new value is code is already valid
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1);
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1, 0, 'maxwidth300 maxwidthonsmartphone productforselect');
|
||||
print '</td>';
|
||||
} elseif ($accounting_product_mode == 'ACCOUNTANCY_BUY_EXPORT') {
|
||||
// Accounting account buy export (Out of EEC)
|
||||
@@ -638,7 +638,7 @@ if ($result)
|
||||
$codesell = length_accountg($obj->accountancy_code_buy_export);
|
||||
//var_dump($defaultvalue.' - '.$codesell.' - '.$compta_prodsell);
|
||||
if (!empty($obj->aaid)) $defaultvalue = ''; // Do not suggest default new value is code is already valid
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1);
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1, 0, 'maxwidth300 maxwidthonsmartphone productforselect');
|
||||
print '</td>';
|
||||
} elseif ($accounting_product_mode == 'ACCOUNTANCY_SELL') {
|
||||
// Accounting account sell
|
||||
@@ -648,7 +648,7 @@ if ($result)
|
||||
$codesell = length_accountg($obj->accountancy_code_sell);
|
||||
//var_dump($defaultvalue.' - '.$codesell.' - '.$compta_prodsell);
|
||||
if (!empty($obj->aaid)) $defaultvalue = ''; // Do not suggest default new value is code is already valid
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1);
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1, 0, 'maxwidth300 maxwidthonsmartphone productforselect');
|
||||
print '</td>';
|
||||
} elseif ($accounting_product_mode == 'ACCOUNTANCY_SELL_INTRA') {
|
||||
// Accounting account sell intra (In EEC)
|
||||
@@ -658,7 +658,7 @@ if ($result)
|
||||
$codesell = length_accountg($obj->accountancy_code_sell_intra);
|
||||
//var_dump($defaultvalue.' - '.$codesell.' - '.$compta_prodsell);
|
||||
if (!empty($obj->aaid)) $defaultvalue = ''; // Do not suggest default new value is code is already valid
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1);
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1, 0, 'maxwidth300 maxwidthonsmartphone productforselect');
|
||||
print '</td>';
|
||||
} else {
|
||||
// Accounting account sell export (Out of EEC)
|
||||
@@ -667,13 +667,13 @@ if ($result)
|
||||
if (empty($defaultvalue)) $defaultvalue = $compta_prodsell;
|
||||
$codesell = length_accountg($obj->accountancy_code_sell_export);
|
||||
if (!empty($obj->aaid)) $defaultvalue = ''; // Do not suggest default new value is code is already valid
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1);
|
||||
print $form->select_account($defaultvalue, 'codeventil_'.$product_static->id, 1, array(), 1, 0, 'maxwidth300 maxwidthonsmartphone productforselect');
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
// Checkbox select
|
||||
print '<td class="center">';
|
||||
print '<input type="checkbox" class="checkforselect" name="chk_prod[]" value="'.$obj->rowid.'"/></td>';
|
||||
print '<input type="checkbox" class="checkforselect productforselectcodeventil_'.$product_static->id.'" name="chk_prod[]" value="'.$obj->rowid.'"/></td>';
|
||||
print "</tr>";
|
||||
$i++;
|
||||
}
|
||||
@@ -697,7 +697,17 @@ if ($result)
|
||||
if (atleastoneselected) jQuery("#changeaccount").attr(\'class\',\'button\');
|
||||
else jQuery("#changeaccount").attr(\'class\',\'button\');
|
||||
}
|
||||
jQuery(".checkforselect, #checkallactions").click(function() {
|
||||
|
||||
jQuery(".checkforselect").change(function() {
|
||||
init_savebutton();
|
||||
});
|
||||
jQuery(".productforselect").change(function() {
|
||||
console.log($(this).attr("id")+" "+$(this).val());
|
||||
if ($(this).val() && $(this).val() != -1) {
|
||||
$(".productforselect"+$(this).attr("id")).prop(\'checked\', true);
|
||||
} else {
|
||||
$(".productforselect"+$(this).attr("id")).prop(\'checked\', false);
|
||||
}
|
||||
init_savebutton();
|
||||
});
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@ $form = new Form($db);
|
||||
if (empty($search_date_start) && !GETPOSTISSET('formfilteraction'))
|
||||
{
|
||||
$sql = "SELECT date_start, date_end from ".MAIN_DB_PREFIX."accounting_fiscalyear ";
|
||||
$sql .= " where date_start < '".$db->idate(dol_now())."' and date_end > '".$db->idate(dol_now())."'";
|
||||
$sql .= " WHERE date_start < '".$db->idate(dol_now())."' AND date_end > '".$db->idate(dol_now())."'";
|
||||
$sql .= $db->plimit(1);
|
||||
$res = $db->query($sql);
|
||||
if ($res->num_rows > 0) {
|
||||
@@ -87,6 +87,7 @@ if (empty($search_date_start) && !GETPOSTISSET('formfilteraction'))
|
||||
} else {
|
||||
$month_start = ($conf->global->SOCIETE_FISCAL_MONTH_START ? ($conf->global->SOCIETE_FISCAL_MONTH_START) : 1);
|
||||
$year_start = dol_print_date(dol_now(), '%Y');
|
||||
if (dol_print_date(dol_now(), '%m') < $month_start) $year_start--; // If current month is lower that starting fiscal month, we start last year
|
||||
$year_end = $year_start + 1;
|
||||
$month_end = $month_start - 1;
|
||||
if ($month_end < 1)
|
||||
@@ -237,7 +238,8 @@ if ($action != 'export_csv')
|
||||
print '<table class="liste '.($moreforfilter ? "listwithfilterbefore" : "").'">';
|
||||
|
||||
print '<tr class="liste_titre_filter">';
|
||||
print '<td class="liste_titre" colspan="6">';
|
||||
$colspan = (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE) ? 6 : 5);
|
||||
print '<td class="liste_titre" colspan="'.$colspan.'">';
|
||||
print $langs->trans('From');
|
||||
print $formaccounting->select_account($search_accountancy_code_start, 'search_accountancy_code_start', 1, array(), 1, 1, '');
|
||||
print ' ';
|
||||
@@ -254,7 +256,7 @@ if ($action != 'export_csv')
|
||||
print '<tr class="liste_titre">';
|
||||
print_liste_field_titre("AccountAccounting", $_SERVER['PHP_SELF'], "t.numero_compte", "", $param, "", $sortfield, $sortorder);
|
||||
print_liste_field_titre("Label", $_SERVER['PHP_SELF'], "t.label_operation", "", $param, "", $sortfield, $sortorder);
|
||||
print_liste_field_titre("OpeningBalance", $_SERVER['PHP_SELF'], "", $param, "", 'class="right"', $sortfield, $sortorder);
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) print_liste_field_titre("OpeningBalance", $_SERVER['PHP_SELF'], "", $param, "", 'class="right"', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Debit", $_SERVER['PHP_SELF'], "t.debit", "", $param, 'class="right"', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Credit", $_SERVER['PHP_SELF'], "t.credit", "", $param, 'class="right"', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Balance", $_SERVER["PHP_SELF"], "", $param, "", 'class="right"', $sortfield, $sortorder);
|
||||
@@ -265,16 +267,28 @@ if ($action != 'export_csv')
|
||||
$total_credit = 0;
|
||||
$sous_total_debit = 0;
|
||||
$sous_total_credit = 0;
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) {
|
||||
$total_opening_balance = 0;
|
||||
$sous_total_opening_balance = 0;
|
||||
}
|
||||
$displayed_account = "";
|
||||
|
||||
$sql = "select t.numero_compte, (SUM(t.debit) - SUM(t.credit)) as opening_balance from ".MAIN_DB_PREFIX."accounting_bookkeeping as t where entity in ".$conf->entity;
|
||||
$sql .= " AND t.doc_date < '".$db->idate($search_date_start)."' GROUP BY t.numero_compte";
|
||||
$resql = $db->query($sql);
|
||||
$nrows = $resql->num_rows;
|
||||
$opening_balances = array();
|
||||
for ($i = 0; $i < $nrows; $i++) {
|
||||
$arr = $resql->fetch_array();
|
||||
$opening_balances["'".$arr['numero_compte']."'"] = $arr['opening_balance'];
|
||||
// TODO Debug - In French accounting, this functionality is dangerous, it takes all the entries and adds all the accounts
|
||||
// without time and class limits (Class 6 and 7 accounts ???) and does not take into account the "a-nouveau" journal.
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) {
|
||||
$sql = "SELECT t.numero_compte, (SUM(t.debit) - SUM(t.credit)) as opening_balance";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "accounting_bookkeeping as t";
|
||||
$sql .= " WHERE t.entity = " . $conf->entity; // Never do sharing into accounting features
|
||||
$sql .= " AND t.doc_date < '" . $db->idate($search_date_start) . "'";
|
||||
$sql .= " GROUP BY t.numero_compte";
|
||||
|
||||
$resql = $db->query($sql);
|
||||
$nrows = $resql->num_rows;
|
||||
$opening_balances = array();
|
||||
for ($i = 0; $i < $nrows; $i++) {
|
||||
$arr = $resql->fetch_array();
|
||||
$opening_balances["'" . $arr['numero_compte'] . "'"] = $arr['opening_balance'];
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($object->lines as $line)
|
||||
@@ -284,53 +298,84 @@ if ($action != 'export_csv')
|
||||
$total_credit += $line->credit;
|
||||
$description = $object->get_compte_desc($line->numero_compte); // Search description of the account
|
||||
$root_account_description = $object->get_compte_racine($line->numero_compte);
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) {
|
||||
$opening_balance = isset($opening_balances["'".$line->numero_compte."'"]) ? $opening_balances["'".$line->numero_compte."'"] : 0;
|
||||
$total_opening_balance += $opening_balance;
|
||||
}
|
||||
if (empty($description)) {
|
||||
$link = '<a href="'.DOL_URL_ROOT.'/accountancy/admin/card.php?action=create&accountingaccount='.length_accountg($line->numero_compte).'">'.img_edit_add().'</a>';
|
||||
}
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
// Permet d'afficher le compte comptable
|
||||
// Display the accounting account
|
||||
if (empty($displayed_account) || $root_account_description != $displayed_account)
|
||||
{
|
||||
// Affiche un Sous-Total par compte comptable
|
||||
// Display a sub-total per account
|
||||
if ($displayed_account != "") {
|
||||
print '<tr class="liste_total"><td class="right" colspan="3">'.$langs->trans("SubTotal").':</td><td class="nowrap right">'.price($sous_total_debit).'</td><td class="nowrap right">'.price($sous_total_credit).'</td><td class="nowrap right">'.price(price2num($sous_total_credit - $sous_total_debit)).'</td>';
|
||||
print '<tr class="liste_total"><td class="right" colspan="2">'.$langs->trans("SubTotal").':</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) print '<td class="nowrap right">'.price($sous_total_opening_balance).'</td>';
|
||||
print '<td class="nowrap right">'.price($sous_total_debit).'</td>';
|
||||
print '<td class="nowrap right">'.price($sous_total_credit).'</td>';
|
||||
print '<td class="nowrap right">'.price(price2num($sous_total_credit - $sous_total_debit)).'</td>';
|
||||
print "<td> </td>\n";
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
// Show first line of a break
|
||||
print '<tr class="trforbreak">';
|
||||
print '<td colspan="7" style="font-weight:bold; border-bottom: 1pt solid black;">'.$line->numero_compte.($root_account_description ? ' - '.$root_account_description : '').'</td>';
|
||||
$colspan = (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE) ? 7 : 6);
|
||||
print '<td colspan="'.$colspan.'" style="font-weight:bold; border-bottom: 1pt solid black;">'.$line->numero_compte.($root_account_description ? ' - '.$root_account_description : '').'</td>';
|
||||
print '</tr>';
|
||||
|
||||
$displayed_account = $root_account_description;
|
||||
$sous_total_debit = 0;
|
||||
$sous_total_credit = 0;
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) $sous_total_opening_balance = 0;
|
||||
}
|
||||
|
||||
// $object->get_compte_racine($line->numero_compte);
|
||||
|
||||
print '<td>'.length_accountg($line->numero_compte).'</td>';
|
||||
print '<td>'.$description.'</td>';
|
||||
print '<td class="nowraponall right">'.price($opening_balances["'".$line->numero_compte."'"]).'</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) print '<td class="nowraponall right">'.price($opening_balance).'</td>';
|
||||
print '<td class="nowraponall right">'.price($line->debit).'</td>';
|
||||
print '<td class="nowraponall right">'.price($line->credit).'</td>';
|
||||
print '<td class="nowraponall right">'.price($line->debit - $line->credit).'</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) {
|
||||
print '<td class="nowraponall right">'.price($opening_balance + $line->debit - $line->credit).'</td>';
|
||||
} else {
|
||||
print '<td class="nowraponall right">'.price($line->debit - $line->credit).'</td>';
|
||||
}
|
||||
print '<td class="center">'.$link;
|
||||
print '</td>';
|
||||
print "</tr>\n";
|
||||
|
||||
// Comptabilise le sous-total
|
||||
// Records the sub-total
|
||||
$sous_total_debit += $line->debit;
|
||||
$sous_total_credit += $line->credit;
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) $sous_total_opening_balance += $opening_balance;
|
||||
}
|
||||
|
||||
print '<tr class="liste_total"><td class="right" colspan="3">'.$langs->trans("SubTotal").':</td><td class="nowrap right">'.price($sous_total_debit).'</td><td class="nowrap right">'.price($sous_total_credit).'</td><td class="nowrap right">'.price(price2num($sous_total_debit - $sous_total_credit)).'</td>';
|
||||
print '<tr class="liste_total"><td class="right" colspan="2">'.$langs->trans("SubTotal").':</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) print '<td class="nowrap right">'.price($sous_total_opening_balance).'</td>';
|
||||
print '<td class="nowrap right">'.price($sous_total_debit).'</td>';
|
||||
print '<td class="nowrap right">'.price($sous_total_credit).'</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) {
|
||||
print '<td class="nowrap right">' . price(price2num($sous_total_opening_balance + $sous_total_debit - $sous_total_credit, 'MT')) . '</td>';
|
||||
} else {
|
||||
print '<td class="nowrap right">' . price(price2num($sous_total_debit - $sous_total_credit, 'MT')) . '</td>';
|
||||
}
|
||||
print "<td> </td>\n";
|
||||
print '</tr>';
|
||||
|
||||
print '<tr class="liste_total"><td class="right" colspan="3">'.$langs->trans("AccountBalance").':</td><td class="nowrap right">'.price($total_debit).'</td><td class="nowrap right">'.price($total_credit).'</td><td class="nowrap right">'.price(price2num($total_debit - $total_credit)).'</td>';
|
||||
print '<tr class="liste_total"><td class="right" colspan="2">'.$langs->trans("AccountBalance").':</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) print '<td class="nowrap right">'.price($total_opening_balance).'</td>';
|
||||
print '<td class="nowrap right">'.price($total_debit).'</td>';
|
||||
print '<td class="nowrap right">'.price($total_credit).'</td>';
|
||||
if (!empty($conf->global->ACCOUNTANCY_SHOW_OPENING_BALANCE)) {
|
||||
print '<td class="nowrap right">' . price(price2num($total_opening_balance + $total_debit - $total_credit, 'MT')) . '</td>';
|
||||
} else {
|
||||
print '<td class="nowrap right">' . price(price2num($total_debit - $total_credit, 'MT')) . '</td>';
|
||||
}
|
||||
print "<td> </td>\n";
|
||||
print '</tr>';
|
||||
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
/* Copyright (C) 2016 Neil Orley <neil.orley@oeris.fr>
|
||||
* Copyright (C) 2013-2016 Olivier Geffroy <jeff@jeffinfo.com>
|
||||
* Copyright (C) 2013-2016 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2013-2020 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@@ -31,6 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/bookkeeping.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingjournal.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formaccounting.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
|
||||
@@ -293,6 +294,7 @@ if ($action == 'delmouvconfirm' && $user->rights->accounting->mouvements->suppri
|
||||
*/
|
||||
|
||||
$formaccounting = new FormAccounting($db);
|
||||
$formfile = new FormFile($db);
|
||||
$formother = new FormOther($db);
|
||||
$form = new Form($db);
|
||||
|
||||
@@ -551,7 +553,7 @@ while ($i < min($num, $limit))
|
||||
|
||||
// Show the break account
|
||||
print "<tr>";
|
||||
print '<td colspan="'.$totalarray['nbfield'].'" style="font-weight:bold; border-bottom: 1pt solid black;">';
|
||||
print '<td colspan="'.($totalarray['nbfield'] ? $totalarray['nbfield'] : 9).'" style="font-weight:bold; border-bottom: 1pt solid black;">';
|
||||
if ($line->numero_compte != "" && $line->numero_compte != '-1') print length_accountg($line->numero_compte).' : '.$object->get_compte_desc($line->numero_compte);
|
||||
else print '<span class="error">'.$langs->trans("Unknown").'</span>';
|
||||
print '</td>';
|
||||
|
||||
@@ -332,9 +332,9 @@ class AccountancyExport
|
||||
print length_accountg($line->numero_compte).$separator;
|
||||
print length_accounta($line->subledger_account).$separator;
|
||||
print $line->sens.$separator;
|
||||
print price($line->montant).$separator;
|
||||
print $line->label_operation.$separator;
|
||||
print $line->doc_ref;
|
||||
print price2fec(abs($line->montant)).$separator;
|
||||
print dol_string_unaccent($line->label_operation).$separator;
|
||||
print dol_string_unaccent($line->doc_ref);
|
||||
print $end_line;
|
||||
}
|
||||
}
|
||||
@@ -386,6 +386,7 @@ class AccountancyExport
|
||||
|
||||
foreach ($objectLines as $line) {
|
||||
$date = dol_print_date($line->doc_date, '%d/%m/%Y');
|
||||
|
||||
print $date.$separator;
|
||||
print $line->code_journal.$separator;
|
||||
print length_accountg($line->numero_compte).$separator;
|
||||
@@ -394,7 +395,7 @@ class AccountancyExport
|
||||
print price($line->debit).$separator;
|
||||
print price($line->credit).$separator;
|
||||
print 'E'.$separator;
|
||||
print length_accountg($line->subledger_account).$separator;
|
||||
print length_accounta($line->subledger_account).$separator;
|
||||
print $end_line;
|
||||
}
|
||||
}
|
||||
@@ -784,7 +785,7 @@ class AccountancyExport
|
||||
public function exportFEC($objectLines)
|
||||
{
|
||||
$separator = "\t";
|
||||
$end_line = "\n";
|
||||
$end_line = "\r\n";
|
||||
|
||||
print "JournalCode".$separator;
|
||||
print "JournalLib".$separator;
|
||||
@@ -807,65 +808,70 @@ class AccountancyExport
|
||||
print $end_line;
|
||||
|
||||
foreach ($objectLines as $line) {
|
||||
$date_creation = dol_print_date($line->date_creation, '%Y%m%d');
|
||||
$date_doc = dol_print_date($line->doc_date, '%Y%m%d');
|
||||
$date_valid = dol_print_date($line->date_validated, '%Y%m%d');
|
||||
if ($line->debit == 0 && $line->credit == 0) {
|
||||
unset($array[$line]);
|
||||
} else {
|
||||
$date_creation = dol_print_date($line->date_creation, '%Y%m%d');
|
||||
$date_document = dol_print_date($line->doc_date, '%Y%m%d');
|
||||
$date_lettering = dol_print_date($line->date_lettering, '%Y%m%d');
|
||||
$date_validation = dol_print_date($line->date_validated, '%Y%m%d');
|
||||
|
||||
// FEC:JournalCode
|
||||
print $line->code_journal.$separator;
|
||||
// FEC:JournalCode
|
||||
print $line->code_journal.$separator;
|
||||
|
||||
// FEC:JournalLib
|
||||
print $line->journal_label.$separator;
|
||||
// FEC:JournalLib
|
||||
print $line->journal_label.$separator;
|
||||
|
||||
// FEC:EcritureNum
|
||||
print $line->piece_num.$separator;
|
||||
// FEC:EcritureNum
|
||||
print $line->piece_num.$separator;
|
||||
|
||||
// FEC:EcritureDate
|
||||
print $date_creation.$separator;
|
||||
// FEC:EcritureDate
|
||||
print $date_document . $separator;
|
||||
|
||||
// FEC:CompteNum
|
||||
print $line->numero_compte.$separator;
|
||||
// FEC:CompteNum
|
||||
print $line->numero_compte.$separator;
|
||||
|
||||
// FEC:CompteLib
|
||||
print $line->label_compte.$separator;
|
||||
// FEC:CompteLib
|
||||
print dol_string_unaccent($line->label_compte) . $separator;
|
||||
|
||||
// FEC:CompAuxNum
|
||||
print $line->subledger_account.$separator;
|
||||
// FEC:CompAuxNum
|
||||
print $line->subledger_account.$separator;
|
||||
|
||||
// FEC:CompAuxLib
|
||||
print $line->subledger_label.$separator;
|
||||
// FEC:CompAuxLib
|
||||
print dol_string_unaccent($line->subledger_label).$separator;
|
||||
|
||||
// FEC:PieceRef
|
||||
print $line->doc_ref.$separator;
|
||||
// FEC:PieceRef
|
||||
print $line->doc_ref.$separator;
|
||||
|
||||
// FEC:PieceDate
|
||||
print $date_doc.$separator;
|
||||
// FEC:PieceDate
|
||||
print $date_creation.$separator;
|
||||
|
||||
// FEC:EcritureLib
|
||||
print $line->label_operation.$separator;
|
||||
// FEC:EcritureLib
|
||||
print dol_string_unaccent($line->label_operation).$separator;
|
||||
|
||||
// FEC:Debit
|
||||
print price2fec($line->debit).$separator;
|
||||
// FEC:Debit
|
||||
print price2fec($line->debit).$separator;
|
||||
|
||||
// FEC:Credit
|
||||
print price2fec($line->credit).$separator;
|
||||
// FEC:Credit
|
||||
print price2fec($line->credit).$separator;
|
||||
|
||||
// FEC:EcritureLet
|
||||
print $line->lettering_code.$separator;
|
||||
// FEC:EcritureLet
|
||||
print $line->lettering_code.$separator;
|
||||
|
||||
// FEC:DateLet
|
||||
print $line->date_lettering.$separator;
|
||||
// FEC:DateLet
|
||||
print $date_lettering.$separator;
|
||||
|
||||
// FEC:ValidDate
|
||||
print $date_valid.$separator;
|
||||
// FEC:ValidDate
|
||||
print $date_validation.$separator;
|
||||
|
||||
// FEC:Montantdevise
|
||||
print $line->multicurrency_amount.$separator;
|
||||
// FEC:Montantdevise
|
||||
print $line->multicurrency_amount.$separator;
|
||||
|
||||
// FEC:Idevise
|
||||
print $line->multicurrency_code;
|
||||
// FEC:Idevise
|
||||
print $line->multicurrency_code;
|
||||
|
||||
print $end_line;
|
||||
print $end_line;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -488,7 +488,7 @@ class AccountingAccount extends CommonObject
|
||||
{
|
||||
if (!empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER))
|
||||
{
|
||||
$label = $langs->trans("ShowAccoutingAccount");
|
||||
$label = $langs->trans("ShowAccountingAccount");
|
||||
$linkclose .= ' alt="'.dol_escape_htmltag($label, 1).'"';
|
||||
}
|
||||
$linkclose .= ' title="'.dol_escape_htmltag($label, 1).'"';
|
||||
|
||||
@@ -365,7 +365,7 @@ class BookKeeping extends CommonObject
|
||||
$sql .= ", ".(!empty($this->subledger_account) ? ("'".$this->db->escape($this->subledger_account)."'") : "NULL");
|
||||
$sql .= ", ".(!empty($this->subledger_label) ? ("'".$this->db->escape($this->subledger_label)."'") : "NULL");
|
||||
$sql .= ", '".$this->db->escape($this->numero_compte)."'";
|
||||
$sql .= ", ".(!empty($this->label_operation) ? ("'".$this->db->escape($this->label_operation)."'") : "NULL");
|
||||
$sql .= ", ".(!empty($this->label_compte) ? ("'".$this->db->escape($this->label_compte)."'") : "NULL");
|
||||
$sql .= ", '".$this->db->escape($this->label_operation)."'";
|
||||
$sql .= ", ".$this->debit;
|
||||
$sql .= ", ".$this->credit;
|
||||
|
||||
@@ -31,6 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
||||
@@ -64,9 +65,9 @@ $sortfield = GETPOST('sortfield', 'alpha');
|
||||
$sortorder = GETPOST('sortorder', 'alpha');
|
||||
$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int');
|
||||
if (empty($page) || $page < 0) $page = 0;
|
||||
$offset = $limit * $page;
|
||||
$pageprev = $page - 1;
|
||||
$pagenext = $page + 1;
|
||||
$offset = $limit * $page;
|
||||
if (!$sortfield)
|
||||
$sortfield = "f.datef, f.ref, fd.rowid";
|
||||
if (!$sortorder) {
|
||||
@@ -91,7 +92,7 @@ $formaccounting = new FormAccounting($db);
|
||||
// Purge search criteria
|
||||
if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) // All tests are required to be compatible with all browsers
|
||||
{
|
||||
$search_societe='';
|
||||
$search_societe = '';
|
||||
$search_lineid = '';
|
||||
$search_ref = '';
|
||||
$search_invoice = '';
|
||||
@@ -175,7 +176,8 @@ print '<script type="text/javascript">
|
||||
$sql = "SELECT f.rowid as facid, f.ref as ref, f.type, f.datef, f.ref_client,";
|
||||
$sql .= " fd.rowid, fd.description, fd.product_type as line_type, fd.total_ht, fd.total_tva, fd.tva_tx, fd.vat_src_code, fd.total_ttc,";
|
||||
$sql .= " s.rowid as socid, s.nom as name, s.code_compta, s.code_client,";
|
||||
$sql .= " p.rowid as product_id, p.fk_product_type as product_type, p.ref as product_ref, p.label as product_label, p.accountancy_code_sell, aa.rowid as fk_compte, aa.account_number, aa.label as label_compte,";
|
||||
$sql .= " p.rowid as product_id, p.fk_product_type as product_type, p.ref as product_ref, p.label as product_label, p.accountancy_code_sell,";
|
||||
$sql .= " aa.rowid as fk_compte, aa.account_number, aa.label, aa.labelshort,";
|
||||
$sql .= " fd.situation_percent,";
|
||||
$sql .= " co.code as country_code, co.label as country,";
|
||||
$sql .= " s.rowid as socid, s.nom as name, s.tva_intra, s.email, s.town, s.zip, s.fk_pays, s.client, s.fournisseur, s.code_client, s.code_fournisseur, s.code_compta as code_compta_client, s.code_compta_fournisseur";
|
||||
@@ -343,16 +345,17 @@ if ($result) {
|
||||
print_liste_field_titre("Country", $_SERVER["PHP_SELF"], "co.label", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("VATIntra", $_SERVER["PHP_SELF"], "s.tva_intra", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Account", $_SERVER["PHP_SELF"], "aa.account_number", "", $param, '', $sortfield, $sortorder);
|
||||
$clickpicto = $form->showCheckAddButtons();
|
||||
print_liste_field_titre($clickpicto, '', '', '', '', '', '', '', 'center ');
|
||||
$checkpicto = $form->showCheckAddButtons();
|
||||
print_liste_field_titre($checkpicto, '', '', '', '', '', '', '', 'center ');
|
||||
print "</tr>\n";
|
||||
|
||||
$thirdpartystatic=new Societe($db);
|
||||
$facture_static = new Facture($db);
|
||||
$product_static = new Product($db);
|
||||
$thirdpartystatic = new Societe($db);
|
||||
$facture_static = new Facture($db);
|
||||
$product_static = new Product($db);
|
||||
$accountingaccountstatic = new AccountingAccount($db);
|
||||
|
||||
while ($objp = $db->fetch_object($result)) {
|
||||
$codecompta = length_accountg($objp->account_number).' - <span class="opacitymedium">'.$objp->label_compte.'</span>';
|
||||
while ($i < min($num_lines, $limit)) {
|
||||
$objp = $db->fetch_object($result);
|
||||
|
||||
$facture_static->ref = $objp->ref;
|
||||
$facture_static->id = $objp->facid;
|
||||
@@ -374,6 +377,11 @@ if ($result) {
|
||||
$product_static->label = $objp->product_label;
|
||||
$product_static->type = $objp->line_type;
|
||||
|
||||
$accountingaccountstatic->rowid = $objp->fk_compte;
|
||||
$accountingaccountstatic->label = $objp->label;
|
||||
$accountingaccountstatic->labelshort = $objp->labelshort;
|
||||
$accountingaccountstatic->account_number = $objp->account_number;
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
// Line id
|
||||
@@ -386,7 +394,7 @@ if ($result) {
|
||||
print '<td class="center">'.dol_print_date($db->jdate($objp->datef), 'day').'</td>';
|
||||
|
||||
// Ref Product
|
||||
print '<td>';
|
||||
print '<td class="tdoverflowmax100">';
|
||||
if ($product_static->id > 0) print $product_static->getNomUrl(1);
|
||||
if ($product_static->id > 0 && $objp->product_label) print '<br>';
|
||||
if ($objp->product_label) print '<span class="opacitymedium">'.$objp->product_label.'</span>';
|
||||
@@ -416,19 +424,16 @@ if ($result) {
|
||||
print '<td>'.$objp->tva_intra.'</td>';
|
||||
|
||||
print '<td>';
|
||||
print $codecompta.' <a class="editfielda" href="./card.php?id='.$objp->rowid.'&backtopage='.urlencode($_SERVER["PHP_SELF"].($param ? '?'.$param : '')).'">';
|
||||
print $accountingaccountstatic->getNomUrl(0, 1, 1).' <a class="editfielda" href="./card.php?id='.$objp->rowid.'&backtopage='.urlencode($_SERVER["PHP_SELF"].($param ? '?'.$param : '')).'">';
|
||||
print img_edit();
|
||||
print '</a>';
|
||||
print '</td>';
|
||||
|
||||
print '</a></td>';
|
||||
print '<td class="center"><input type="checkbox" class="checkforaction" name="changeaccount[]" value="'.$objp->rowid.'"/></td>';
|
||||
|
||||
print "</tr>";
|
||||
print '</tr>';
|
||||
$i++;
|
||||
}
|
||||
|
||||
print "</table>";
|
||||
print "</div>";
|
||||
print '</table>';
|
||||
print "</div>";
|
||||
|
||||
if ($nbtotalofrecords > $limit) {
|
||||
print_barre_liste('', $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num_lines, $nbtotalofrecords, '', 0, '', '', $limit, 1);
|
||||
|
||||
@@ -27,10 +27,10 @@
|
||||
require '../../main.inc.php';
|
||||
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formaccounting.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
|
||||
// Load translation files required by the page
|
||||
@@ -162,7 +162,7 @@ print '<script type="text/javascript">
|
||||
*/
|
||||
$sql = "SELECT er.ref, er.rowid as erid,";
|
||||
$sql .= " erd.rowid, erd.fk_c_type_fees, erd.comments, erd.total_ht, erd.fk_code_ventilation, erd.tva_tx, erd.vat_src_code, erd.date,";
|
||||
$sql .= " aa.label, aa.account_number,";
|
||||
$sql .= " aa.label, aa.labelshort, aa.account_number,";
|
||||
$sql .= " f.id as type_fees_id, f.code as type_fees_code, f.label as type_fees_label";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."expensereport as er";
|
||||
$sql .= " , ".MAIN_DB_PREFIX."accounting_account as aa";
|
||||
@@ -265,8 +265,7 @@ if ($result) {
|
||||
print '<td class="liste_titre right"><input type="text" class="flat maxwidth50" name="search_amount" value="'.dol_escape_htmltag($search_amount).'"></td>';
|
||||
print '<td class="liste_titre center"><input type="text" class="flat maxwidth50" name="search_vat" size="1" placeholder="%" value="'.dol_escape_htmltag($search_vat).'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat maxwidth50" name="search_account" value="'.dol_escape_htmltag($search_account).'"></td>';
|
||||
print '<td class="liste_titre right"></td>';
|
||||
print '<td class="liste_titre right">';
|
||||
print '<td class="liste_titre center">';
|
||||
$searchpicto = $form->showFilterButtons();
|
||||
print $searchpicto;
|
||||
print '</td>';
|
||||
@@ -284,20 +283,24 @@ if ($result) {
|
||||
print_liste_field_titre("Amount", $_SERVER["PHP_SELF"], "erd.total_ht", "", $param, '', $sortfield, $sortorder, 'right ');
|
||||
print_liste_field_titre("VATRate", $_SERVER["PHP_SELF"], "erd.tva_tx", "", $param, '', $sortfield, $sortorder, 'center ');
|
||||
print_liste_field_titre("Account", $_SERVER["PHP_SELF"], "aa.account_number", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre('');
|
||||
$checkpicto = $form->showCheckAddButtons();
|
||||
$checkpicto = $form->showCheckAddButtons();
|
||||
print_liste_field_titre($checkpicto, '', '', '', '', '', '', '', 'center ');
|
||||
print "</tr>\n";
|
||||
|
||||
$expensereport_static = new ExpenseReport($db);
|
||||
$expensereport_static = new ExpenseReport($db);
|
||||
$accountingaccountstatic = new AccountingAccount($db);
|
||||
|
||||
while ($i < min($num_lines, $limit)) {
|
||||
$objp = $db->fetch_object($result);
|
||||
$codeCompta = length_accountg($objp->account_number).' - <span class="opacitymedium">'.$objp->label.'</span>';
|
||||
|
||||
$expensereport_static->ref = $objp->ref;
|
||||
$expensereport_static->id = $objp->erid;
|
||||
|
||||
$accountingaccountstatic->rowid = $objp->fk_compte;
|
||||
$accountingaccountstatic->label = $objp->label;
|
||||
$accountingaccountstatic->labelshort = $objp->labelshort;
|
||||
$accountingaccountstatic->account_number = $objp->account_number;
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
print '<td>'.$objp->rowid.'</td>';
|
||||
@@ -324,12 +327,10 @@ if ($result) {
|
||||
|
||||
print '<td class="center">'.vatrate($objp->tva_tx.($objp->vat_src_code ? ' ('.$objp->vat_src_code.')' : '')).'</td>';
|
||||
|
||||
print '<td>'.$codeCompta.'</td>';
|
||||
|
||||
print '<td class="left"><a class="editfielda" href="./card.php?id='.$objp->rowid.'&backtopage='.urlencode($_SERVER["PHP_SELF"].($param ? '?'.$param : '')).'">';
|
||||
print '<td>';
|
||||
print $accountingaccountstatic->getNomUrl(0, 1, 1).' <a class="editfielda" href="./card.php?id='.$objp->rowid.'&backtopage='.urlencode($_SERVER["PHP_SELF"].($param ? '?'.$param : '')).'">';
|
||||
print img_edit();
|
||||
print '</a></td>';
|
||||
|
||||
print '<td class="center"><input type="checkbox" class="checkforaction" name="changeaccount[]" value="'.$objp->rowid.'"/></td>';
|
||||
|
||||
print "</tr>";
|
||||
|
||||
@@ -254,6 +254,8 @@ if ($result) {
|
||||
} else {
|
||||
$tabpay[$obj->rowid]["lib"] = dol_trunc($obj->label, 60);
|
||||
}
|
||||
|
||||
// Load of url links to the line into llx_bank
|
||||
$links = $object->get_url($obj->rowid); // Get an array('url'=>, 'url_id'=>, 'label'=>, 'type'=> 'fk_bank'=> )
|
||||
|
||||
//var_dump($i);
|
||||
@@ -320,6 +322,7 @@ if ($result) {
|
||||
$chargestatic->ref = $links[$key]['url_id'];
|
||||
|
||||
$tabpay[$obj->rowid]["lib"] .= ' '.$chargestatic->getNomUrl(2);
|
||||
$reg = array();
|
||||
if (preg_match('/^\((.*)\)$/i', $links[$key]['label'], $reg)) {
|
||||
if ($reg[1] == 'socialcontribution')
|
||||
$reg[1] = 'SocialContribution';
|
||||
@@ -331,11 +334,13 @@ if ($result) {
|
||||
$tabpay[$obj->rowid]["soclib"] = $chargestatic->getNomUrl(1, 30);
|
||||
$tabpay[$obj->rowid]["paymentscid"] = $chargestatic->id;
|
||||
|
||||
// Retreive the accounting code of the social contribution of the payment from link of payment.
|
||||
// Note: We have the social contribution id, it can be faster to get accounting code from social contribution id.
|
||||
$sqlmid = 'SELECT cchgsoc.accountancy_code';
|
||||
$sqlmid .= " FROM ".MAIN_DB_PREFIX."c_chargesociales cchgsoc ";
|
||||
$sqlmid .= " FROM ".MAIN_DB_PREFIX."c_chargesociales cchgsoc";
|
||||
$sqlmid .= " INNER JOIN ".MAIN_DB_PREFIX."chargesociales as chgsoc ON chgsoc.fk_type=cchgsoc.id";
|
||||
$sqlmid .= " INNER JOIN ".MAIN_DB_PREFIX."paiementcharge as paycharg ON paycharg.fk_charge=chgsoc.rowid";
|
||||
$sqlmid .= " INNER JOIN ".MAIN_DB_PREFIX."bank_url as bkurl ON bkurl.url_id=paycharg.rowid";
|
||||
$sqlmid .= " INNER JOIN ".MAIN_DB_PREFIX."bank_url as bkurl ON bkurl.url_id=paycharg.rowid AND bkurl.type = 'payment_sc'";
|
||||
$sqlmid .= " WHERE bkurl.fk_bank=".$obj->rowid;
|
||||
|
||||
dol_syslog("accountancy/journal/bankjournal.php:: sqlmid=".$sqlmid, LOG_DEBUG);
|
||||
@@ -858,7 +863,7 @@ if ($action == 'exportcsv') { // ISO and not UTF8 !
|
||||
print '"'.$date.'"'.$sep;
|
||||
print '"'.$val["type_payment"].'"'.$sep;
|
||||
print '"'.length_accountg(html_entity_decode($k)).'"'.$sep;
|
||||
print '"'.length_accountg(html_entity_decode($k)).'"'.$sep;
|
||||
print '"'.length_accounta(html_entity_decode($k)).'"'.$sep;
|
||||
print " ".$sep;
|
||||
print '"'.$reflabel.'"'.$sep;
|
||||
print '"'.($mt >= 0 ? price($mt) : '').'"'.$sep;
|
||||
@@ -888,7 +893,7 @@ if ($action == 'exportcsv') { // ISO and not UTF8 !
|
||||
print '"'.$key.'"'.$sep;
|
||||
print '"'.$date.'"'.$sep;
|
||||
print '"'.$val["type_payment"].'"'.$sep;
|
||||
print '"'.length_accounta(html_entity_decode($k)).'"'.$sep;
|
||||
print '"'.length_accountg(html_entity_decode($k)).'"'.$sep;
|
||||
if ($tabtype[$key] == 'payment_supplier') {
|
||||
print '"'.$conf->global->ACCOUNTING_ACCOUNT_SUPPLIER.'"'.$sep;
|
||||
} elseif ($tabtype[$key] == 'payment') {
|
||||
@@ -898,7 +903,7 @@ if ($action == 'exportcsv') { // ISO and not UTF8 !
|
||||
} elseif ($tabtype[$key] == 'payment_salary') {
|
||||
print '"'.$conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT.'"'.$sep;
|
||||
} else {
|
||||
print '"'.length_accounta(html_entity_decode($k)).'"'.$sep;
|
||||
print '"'.length_accountg(html_entity_decode($k)).'"'.$sep;
|
||||
}
|
||||
print '"'.length_accounta(html_entity_decode($k)).'"'.$sep;
|
||||
print '"'.$reflabel.'"'.$sep;
|
||||
@@ -921,7 +926,7 @@ if ($action == 'exportcsv') { // ISO and not UTF8 !
|
||||
print '"'.$date.'"'.$sep;
|
||||
print '"'.$val["type_payment"].'"'.$sep;
|
||||
print '"'.length_accountg($conf->global->ACCOUNTING_ACCOUNT_SUSPENSE).'"'.$sep;
|
||||
print '"'.length_accountg($conf->global->ACCOUNTING_ACCOUNT_SUSPENSE).'"'.$sep;
|
||||
print '"'.length_accounta($conf->global->ACCOUNTING_ACCOUNT_SUSPENSE).'"'.$sep;
|
||||
print "".$sep;
|
||||
print '"'.$reflabel.'"'.$sep;
|
||||
print '"'.($mt < 0 ? price(-$mt) : '').'"'.$sep;
|
||||
@@ -1125,7 +1130,7 @@ if (empty($action) || $action == 'view') {
|
||||
if ($tabtype[$key] == 'payment_vat') $account_ledger = $conf->global->ACCOUNTING_VAT_PAY_ACCOUNT;
|
||||
if ($tabtype[$key] == 'member') $account_ledger = $conf->global->ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT;
|
||||
if ($tabtype[$key] == 'payment_various') $account_ledger = $tabpay[$key]["account_various"];
|
||||
$accounttoshow = length_accounta($account_ledger);
|
||||
$accounttoshow = length_accountg($account_ledger);
|
||||
if (empty($accounttoshow) || $accounttoshow == 'NotDefined')
|
||||
{
|
||||
if ($tabtype[$key] == 'unknown')
|
||||
|
||||
@@ -265,7 +265,7 @@ if ($action == 'writebookkeeping') {
|
||||
$bookkeeping->montant = $mt;
|
||||
$bookkeeping->sens = ($mt < 0) ? 'C' : 'D';
|
||||
$bookkeeping->debit = ($mt > 0) ? $mt : 0;
|
||||
$bookkeeping->credit = ($mt <= 0) ? $mt : 0;
|
||||
$bookkeeping->credit = ($mt <= 0) ? -$mt : 0;
|
||||
$bookkeeping->code_journal = $journal;
|
||||
$bookkeeping->journal_label = $journal_label;
|
||||
$bookkeeping->fk_user_author = $user->id;
|
||||
@@ -325,7 +325,7 @@ if ($action == 'writebookkeeping') {
|
||||
$bookkeeping->montant = $mt;
|
||||
$bookkeeping->sens = ($mt < 0) ? 'C' : 'D';
|
||||
$bookkeeping->debit = ($mt > 0) ? $mt : 0;
|
||||
$bookkeeping->credit = ($mt <= 0) ? $mt : 0;
|
||||
$bookkeeping->credit = ($mt <= 0) ? -$mt : 0;
|
||||
$bookkeeping->code_journal = $journal;
|
||||
$bookkeeping->journal_label = $journal_label;
|
||||
$bookkeeping->fk_user_author = $user->id;
|
||||
@@ -625,7 +625,7 @@ if (empty($action) || $action == 'view') {
|
||||
else print $accountoshow;
|
||||
print '</td>';
|
||||
print "<td>".$userstatic->getNomUrl(0, 'user', 16).' - '.$langs->trans("SubledgerAccount")."</td>";
|
||||
print '<td class="right nowraponall">'.($mt < 0 ? -price(-$mt) : '')."</td>";
|
||||
print '<td class="right nowraponall">'.($mt < 0 ? price(-$mt) : '')."</td>";
|
||||
print '<td class="right nowraponall">'.($mt >= 0 ? price($mt) : '')."</td>";
|
||||
print "</tr>";
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.product.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
||||
@@ -177,7 +177,7 @@ print '<script type="text/javascript">
|
||||
*/
|
||||
$sql = "SELECT f.rowid as facid, f.ref as ref, f.ref_supplier, f.libelle as invoice_label, f.datef, f.fk_soc,";
|
||||
$sql .= " l.rowid, l.fk_product, l.product_type as line_type, l.description, l.total_ht , l.qty, l.tva_tx, l.vat_src_code,";
|
||||
$sql .= " aa.label, aa.account_number, ";
|
||||
$sql .= " aa.label, aa.labelshort, aa.account_number, ";
|
||||
$sql .= " p.rowid as product_id, p.fk_product_type as product_type, p.ref as product_ref, p.label as product_label, p.fk_product_type as type,";
|
||||
$sql .= " co.code as country_code, co.label as country,";
|
||||
$sql .= " s.rowid as socid, s.nom as name, s.tva_intra, s.email, s.town, s.zip, s.fk_pays, s.client, s.fournisseur, s.code_client, s.code_fournisseur, s.code_compta as code_compta_client, s.code_compta_fournisseur";
|
||||
@@ -261,9 +261,8 @@ if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
|
||||
|
||||
$sql .= $db->plimit($limit + 1, $offset);
|
||||
|
||||
dol_syslog('accountancy/supplier/lines.php');
|
||||
dol_syslog("accountancy/supplier/lines.php", LOG_DEBUG);
|
||||
$result = $db->query($sql);
|
||||
|
||||
if ($result) {
|
||||
$num_lines = $db->num_rows($result);
|
||||
$i = 0;
|
||||
@@ -271,7 +270,7 @@ if ($result) {
|
||||
$param = '';
|
||||
if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param .= '&contextpage='.urlencode($contextpage);
|
||||
if ($limit > 0 && $limit != $conf->liste_limit) $param .= '&limit='.urlencode($limit);
|
||||
if ($search_societe) $param .= "&search_societe=" . urlencode($search_societe);
|
||||
if ($search_societe) $param .= "&search_societe=".urlencode($search_societe);
|
||||
if ($search_invoice) $param .= "&search_invoice=".urlencode($search_invoice);
|
||||
if ($search_ref) $param .= "&search_ref=".urlencode($search_ref);
|
||||
if ($search_label) $param .= "&search_label=".urlencode($search_label);
|
||||
@@ -294,12 +293,11 @@ if ($result) {
|
||||
print '<input type="hidden" name="page" value="'.$page.'">';
|
||||
|
||||
print_barre_liste($langs->trans("InvoiceLinesDone"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num_lines, $nbtotalofrecords, 'title_accountancy', 0, '', '', $limit);
|
||||
|
||||
print '<span class="opacitymedium">'.$langs->trans("DescVentilDoneSupplier").'</span><br>';
|
||||
|
||||
print '<br><div class="inline-block divButAction">'.$langs->trans("ChangeAccount").'<br>';
|
||||
print $formaccounting->select_account($account_parent, 'account_parent', 2, array(), 0, 0, 'maxwidth300 maxwidthonsmartphone valignmiddle');
|
||||
print '<input type="submit" class="button valignmiddle" value="'.$langs->trans("ChangeBinding").'" /></div>';
|
||||
print '<input type="submit" class="button valignmiddle" value="'.$langs->trans("ChangeBinding").'"/></div>';
|
||||
|
||||
$moreforfilter = '';
|
||||
|
||||
@@ -328,10 +326,9 @@ if ($result) {
|
||||
print '<td class="liste_titre"><input type="text" class="flat maxwidth50" name="search_tvaintra" value="'.dol_escape_htmltag($search_tvaintra).'"></td>';
|
||||
print '<td class="liste_titre center"><input type="text" class="flat maxwidth50" name="search_account" value="'.dol_escape_htmltag($search_account).'"></td>';
|
||||
print '<td class="liste_titre center">';
|
||||
$searchpicto = $form->showFilterButtons();
|
||||
print $searchpicto;
|
||||
print '</td>';
|
||||
print "</tr>\n";
|
||||
$searchpicto = $form->showFilterButtons();
|
||||
print $searchpicto;
|
||||
print "</td></tr>\n";
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
print_liste_field_titre("LineId", $_SERVER["PHP_SELF"], "l.rowid", "", $param, '', $sortfield, $sortorder);
|
||||
@@ -351,15 +348,14 @@ if ($result) {
|
||||
print_liste_field_titre($checkpicto, '', '', '', '', '', '', '', 'center ');
|
||||
print "</tr>\n";
|
||||
|
||||
$thirdpartystatic = new Societe($db);
|
||||
$facturefournisseur_static = new FactureFournisseur($db);
|
||||
$product_static = new ProductFournisseur($db);
|
||||
$thirdpartystatic = new Societe($db);
|
||||
$facturefournisseur_static = new FactureFournisseur($db);
|
||||
$product_static = new ProductFournisseur($db);
|
||||
$accountingaccountstatic = new AccountingAccount($db);
|
||||
|
||||
while ($i < min($num_lines, $limit)) {
|
||||
$objp = $db->fetch_object($result);
|
||||
|
||||
$codecompta = length_accountg($objp->account_number).' - <span class="opacitymedium">'.$objp->label.'</span>';
|
||||
|
||||
$facturefournisseur_static->ref = $objp->ref;
|
||||
$facturefournisseur_static->id = $objp->facid;
|
||||
|
||||
@@ -379,6 +375,11 @@ if ($result) {
|
||||
$product_static->label = $objp->product_label;
|
||||
$product_static->type = $objp->line_type;
|
||||
|
||||
$accountingaccountstatic->rowid = $objp->fk_compte;
|
||||
$accountingaccountstatic->label = $objp->label;
|
||||
$accountingaccountstatic->labelshort = $objp->labelshort;
|
||||
$accountingaccountstatic->account_number = $objp->account_number;
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
// Line id
|
||||
@@ -394,15 +395,14 @@ if ($result) {
|
||||
// Date invoice
|
||||
print '<td class="center">'.dol_print_date($db->jdate($objp->datef), 'day').'</td>';
|
||||
|
||||
// Ref product
|
||||
// Ref Product
|
||||
print '<td class="tdoverflowmax100">';
|
||||
if ($product_static->id > 0) print $product_static->getNomUrl(1);
|
||||
if ($product_static->id > 0 && $objp->product_label) print '<br>';
|
||||
if ($objp->product_label) print '<span class="opacitymedium">'.$objp->product_label.'</span>';
|
||||
print '</td>';
|
||||
|
||||
// Description
|
||||
print '<td>';
|
||||
print '<td class="tdoverflowonsmartphone">';
|
||||
$text = dolGetFirstLineOfText(dol_string_nohtmltag($objp->description));
|
||||
$trunclength = empty($conf->global->ACCOUNTING_LENGTH_DESCRIPTION) ? 32 : $conf->global->ACCOUNTING_LENGTH_DESCRIPTION;
|
||||
print $form->textwithtooltip(dol_trunc($text, $trunclength), $objp->description);
|
||||
@@ -426,7 +426,7 @@ if ($result) {
|
||||
print '<td>'.$objp->tva_intra.'</td>';
|
||||
|
||||
print '<td>';
|
||||
print $codecompta.' <a class="editfielda" href="./card.php?id='.$objp->rowid.'&backtopage='.urlencode($_SERVER["PHP_SELF"].($param ? '?'.$param : '')).'">';
|
||||
print $accountingaccountstatic->getNomUrl(0, 1, 1).' <a class="editfielda" href="./card.php?id='.$objp->rowid.'&backtopage='.urlencode($_SERVER["PHP_SELF"].($param ? '?'.$param : '')).'">';
|
||||
print img_edit();
|
||||
print '</a></td>';
|
||||
print '<td class="center"><input type="checkbox" class="checkforaction" name="changeaccount[]" value="'.$objp->rowid.'"/></td>';
|
||||
|
||||
@@ -93,6 +93,7 @@ if ($action == 'update' || $action == 'add')
|
||||
$constnote = (GETPOSTISSET('constnote_'.$constname) ? GETPOST('constnote_'.$constname, 'none') : GETPOST('constnote'));
|
||||
|
||||
$typetouse = empty($oldtypetonewone[$consttype]) ? $consttype : $oldtypetonewone[$consttype];
|
||||
$constvalue = preg_replace('/:member$/', '', $constvalue);
|
||||
|
||||
$res = dolibarr_set_const($db, $constname, $constvalue, $typetouse, 0, $constnote, $conf->entity);
|
||||
|
||||
@@ -108,26 +109,6 @@ if ($action == 'update' || $action == 'add')
|
||||
}
|
||||
}
|
||||
|
||||
// Action to enable a submodule of the adherent module
|
||||
if ($action == 'set')
|
||||
{
|
||||
$result = dolibarr_set_const($db, GETPOST('name', 'alpha'), GETPOST('value'), '', 0, '', $conf->entity);
|
||||
if ($result < 0)
|
||||
{
|
||||
print $db->error();
|
||||
}
|
||||
}
|
||||
|
||||
// Action to disable a submodule of the adherent module
|
||||
if ($action == 'unset')
|
||||
{
|
||||
$result = dolibarr_del_const($db, GETPOST('name', 'alpha'), $conf->entity);
|
||||
if ($result < 0)
|
||||
{
|
||||
print $db->error();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*
|
||||
|
||||
@@ -286,7 +286,7 @@ if (empty($reshook))
|
||||
$object->firstname = trim(GETPOST("firstname", 'alphanohtml'));
|
||||
$object->lastname = trim(GETPOST("lastname", 'alphanohtml'));
|
||||
$object->gender = trim(GETPOST("gender", 'alphanohtml'));
|
||||
$object->login = trim(GETPOST("login", 'alpha'));
|
||||
$object->login = trim(GETPOST("login", 'alphanohtml'));
|
||||
$object->pass = trim(GETPOST("pass", 'alpha'));
|
||||
|
||||
$object->societe = trim(GETPOST("societe", 'alphanohtml')); // deprecated
|
||||
@@ -459,7 +459,7 @@ if (empty($reshook))
|
||||
// $facebook=GETPOST("member_facebook", 'alpha');
|
||||
// $linkedin=GETPOST("member_linkedin", 'alpha');
|
||||
$email = preg_replace('/\s+/', '', GETPOST("member_email", 'alpha'));
|
||||
$login = GETPOST("member_login", 'alpha');
|
||||
$login = GETPOST("member_login", 'alphanohtml');
|
||||
$pass = GETPOST("password", 'alpha');
|
||||
$photo = GETPOST("photo", 'alpha');
|
||||
//$comment=GETPOST("comment",'none');
|
||||
@@ -941,7 +941,7 @@ else
|
||||
// Login
|
||||
if (empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED))
|
||||
{
|
||||
print '<tr><td><span class="fieldrequired">'.$langs->trans("Login").' / '.$langs->trans("Id").'</span></td><td><input type="text" name="member_login" class="minwidth300" maxlength="50" value="'.(isset($_POST["member_login"]) ?GETPOST("member_login", 'alpha', 2) : $object->login).'" autofocus="autofocus"></td></tr>';
|
||||
print '<tr><td><span class="fieldrequired">'.$langs->trans("Login").' / '.$langs->trans("Id").'</span></td><td><input type="text" name="member_login" class="minwidth300" maxlength="50" value="'.(GETPOSTISSET("member_login") ? GETPOST("member_login", 'alphanohtml', 2) : $object->login).'" autofocus="autofocus"></td></tr>';
|
||||
}
|
||||
|
||||
// Password
|
||||
@@ -996,7 +996,8 @@ else
|
||||
print '</td></tr>';
|
||||
|
||||
// EMail
|
||||
print '<tr><td>'.img_picto('', 'object_email').' '.($conf->global->ADHERENT_MAIL_REQUIRED ? '<span class="fieldrequired">' : '').$langs->trans("EMail").($conf->global->ADHERENT_MAIL_REQUIRED ? '</span>' : '').'</td><td><input type="text" name="member_email" class="minwidth300" maxlength="255" value="'.(GETPOSTISSET('member_email') ? GETPOST('member_email', 'alpha') : $object->email).'"></td></tr>';
|
||||
print '<tr><td>'.($conf->global->ADHERENT_MAIL_REQUIRED ? '<span class="fieldrequired">' : '').$langs->trans("EMail").($conf->global->ADHERENT_MAIL_REQUIRED ? '</span>' : '').'</td>';
|
||||
print '<td>'.img_picto('', 'object_email').' <input type="text" name="member_email" class="minwidth300" maxlength="255" value="'.(GETPOSTISSET('member_email') ? GETPOST('member_email', 'alpha') : $object->email).'"></td></tr>';
|
||||
|
||||
// Address
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Address").'</td><td>';
|
||||
@@ -1033,13 +1034,16 @@ else
|
||||
}
|
||||
|
||||
// Pro phone
|
||||
print '<tr><td>'.img_picto('', 'object_phoning').' '.$langs->trans("PhonePro").'</td><td><input type="text" name="phone" size="20" value="'.(GETPOSTISSET('phone') ? GETPOST('phone', 'alpha') : $object->phone).'"></td></tr>';
|
||||
print '<tr><td>'.$langs->trans("PhonePro").'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning').' <input type="text" name="phone" size="20" value="'.(GETPOSTISSET('phone') ? GETPOST('phone', 'alpha') : $object->phone).'"></td></tr>';
|
||||
|
||||
// Personal phone
|
||||
print '<tr><td>'.img_picto('', 'object_phoning').' '.$langs->trans("PhonePerso").'</td><td><input type="text" name="phone_perso" size="20" value="'.(GETPOSTISSET('phone_perso') ? GETPOST('phone_perso', 'alpha') : $object->phone_perso).'"></td></tr>';
|
||||
print '<tr><td>'.$langs->trans("PhonePerso").'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning').' <input type="text" name="phone_perso" size="20" value="'.(GETPOSTISSET('phone_perso') ? GETPOST('phone_perso', 'alpha') : $object->phone_perso).'"></td></tr>';
|
||||
|
||||
// Mobile phone
|
||||
print '<tr><td>'.img_picto('', 'object_phoning_mobile').' '.$langs->trans("PhoneMobile").'</td><td><input type="text" name="phone_mobile" size="20" value="'.(GETPOSTISSET('phone_mobile') ? GETPOST('phone_mobile', 'alpha') : $object->phone_mobile).'"></td></tr>';
|
||||
print '<tr><td>'.$langs->trans("PhoneMobile").'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning_mobile').' <input type="text" name="phone_mobile" size="20" value="'.(GETPOSTISSET('phone_mobile') ? GETPOST('phone_mobile', 'alpha') : $object->phone_mobile).'"></td></tr>';
|
||||
|
||||
if (!empty($conf->socialnetworks->enabled)) {
|
||||
foreach ($socialnetworks as $key => $value) {
|
||||
@@ -1181,7 +1185,7 @@ else
|
||||
// Login
|
||||
if (empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED))
|
||||
{
|
||||
print '<tr><td><span class="fieldrequired">'.$langs->trans("Login").' / '.$langs->trans("Id").'</span></td><td><input type="text" name="login" class="minwidth300" maxlength="50" value="'.(isset($_POST["login"]) ?GETPOST("login", 'alpha', 2) : $object->login).'"></td></tr>';
|
||||
print '<tr><td><span class="fieldrequired">'.$langs->trans("Login").' / '.$langs->trans("Id").'</span></td><td><input type="text" name="login" class="minwidth300" maxlength="50" value="'.(GETPOSTISSET("login") ? GETPOST("login", 'alphanohtml', 2) : $object->login).'"></td></tr>';
|
||||
}
|
||||
|
||||
// Password
|
||||
@@ -1249,7 +1253,8 @@ else
|
||||
print '</td></tr>';
|
||||
|
||||
// EMail
|
||||
print '<tr><td>'.img_picto('', 'object_email').' '.($conf->global->ADHERENT_MAIL_REQUIRED ? '<span class="fieldrequired">' : '').$langs->trans("EMail").($conf->global->ADHERENT_MAIL_REQUIRED ? '</span>' : '').'</td><td><input type="text" name="member_email" class="minwidth300" maxlength="255" value="'.(isset($_POST["member_email"]) ?GETPOST("member_email", '', 2) : $object->email).'"></td></tr>';
|
||||
print '<tr><td>'.($conf->global->ADHERENT_MAIL_REQUIRED ? '<span class="fieldrequired">' : '').$langs->trans("EMail").($conf->global->ADHERENT_MAIL_REQUIRED ? '</span>' : '').'</td>';
|
||||
print '<td>'.img_picto('', 'object_email').' <input type="text" name="member_email" class="minwidth300" maxlength="255" value="'.(isset($_POST["member_email"]) ?GETPOST("member_email", '', 2) : $object->email).'"></td></tr>';
|
||||
|
||||
// Address
|
||||
print '<tr><td>'.$langs->trans("Address").'</td><td>';
|
||||
@@ -1279,13 +1284,16 @@ else
|
||||
}
|
||||
|
||||
// Pro phone
|
||||
print '<tr><td>'.img_picto('', 'object_phoning').' '.$langs->trans("PhonePro").'</td><td><input type="text" name="phone" size="20" value="'.(GETPOSTISSET("phone") ? GETPOST("phone") : $object->phone).'"></td></tr>';
|
||||
print '<tr><td>'.$langs->trans("PhonePro").'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning').' <input type="text" name="phone" value="'.(GETPOSTISSET("phone") ? GETPOST("phone") : $object->phone).'"></td></tr>';
|
||||
|
||||
// Personal phone
|
||||
print '<tr><td>'.img_picto('', 'object_phoning').' '.$langs->trans("PhonePerso").'</td><td><input type="text" name="phone_perso" size="20" value="'.(GETPOSTISSET("phone_perso") ? GETPOST("phone_perso") : $object->phone_perso).'"></td></tr>';
|
||||
print '<tr><td>'.$langs->trans("PhonePerso").'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning').' <input type="text" name="phone_perso" value="'.(GETPOSTISSET("phone_perso") ? GETPOST("phone_perso") : $object->phone_perso).'"></td></tr>';
|
||||
|
||||
// Mobile phone
|
||||
print '<tr><td>'.img_picto('', 'object_phoning_mobile').' '.$langs->trans("PhoneMobile").'</td><td><input type="text" name="phone_mobile" size="20" value="'.(GETPOSTISSET("phone_mobile") ? GETPOST("phone_mobile") : $object->phone_mobile).'"></td></tr>';
|
||||
print '<tr><td>'.img_picto('', 'object_phoning_mobile').' '.$langs->trans("PhoneMobile").'</td>';
|
||||
print '<td>'.img_picto('', 'object_phoning_mobile').' <input type="text" name="phone_mobile" value="'.(GETPOSTISSET("phone_mobile") ? GETPOST("phone_mobile") : $object->phone_mobile).'"></td></tr>';
|
||||
|
||||
if (!empty($conf->socialnetworks->enabled)) {
|
||||
foreach ($socialnetworks as $key => $value) {
|
||||
|
||||
@@ -68,7 +68,7 @@ class AdherentStats extends Stats
|
||||
|
||||
$this->field = 'subscription';
|
||||
|
||||
$this->where .= " m.statut != 0";
|
||||
$this->where .= " m.statut != -1";
|
||||
$this->where .= " AND p.fk_adherent = m.rowid AND m.entity IN (".getEntity('adherent').")";
|
||||
//if (!$user->rights->societe->client->voir && !$user->socid) $this->where .= " AND p.fk_soc = sc.fk_soc AND sc.fk_user = " .$user->id;
|
||||
if ($this->memberid)
|
||||
|
||||
@@ -257,13 +257,18 @@ class Subscription extends CommonObject
|
||||
{
|
||||
$error = 0;
|
||||
|
||||
if (!is_numeric($this->amount)) {
|
||||
$this->error = 'BadValueForParameterAmount';
|
||||
return -1;
|
||||
}
|
||||
|
||||
$this->db->begin();
|
||||
|
||||
$sql = "UPDATE ".MAIN_DB_PREFIX."subscription SET ";
|
||||
$sql .= " fk_type = ".$this->fk_type.",";
|
||||
$sql .= " fk_adherent = ".$this->fk_adherent.",";
|
||||
$sql .= " note=".($this->note ? "'".$this->db->escape($this->note)."'" : 'null').",";
|
||||
$sql .= " subscription = '".price2num($this->amount)."',";
|
||||
$sql .= " subscription = ".price2num($this->amount).",";
|
||||
$sql .= " dateadh='".$this->db->idate($this->dateh)."',";
|
||||
$sql .= " datef='".$this->db->idate($this->datef)."',";
|
||||
$sql .= " datec='".$this->db->idate($this->datec)."',";
|
||||
|
||||
@@ -108,19 +108,19 @@ dol_fiche_head($head, 'statsbyproperties', $langs->trans("Statistics"), -1, 'use
|
||||
// Print title
|
||||
if (!count($data))
|
||||
{
|
||||
print $langs->trans("NoValidatedMemberYet").'<br>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("NoValidatedMemberYet").'</span><br>';
|
||||
print '<br>';
|
||||
}
|
||||
else
|
||||
{
|
||||
print $langs->trans("MembersByNature").'<br>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("MembersByNature").'</span><br>';
|
||||
print '<br>';
|
||||
}
|
||||
|
||||
// Print array
|
||||
print '<table class="liste centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Nature").'</td>';
|
||||
print '<td>'.$langs->trans("MemberNature").'</td>';
|
||||
print '<td class="right">'.$langs->trans("NbOfMembers").'</td>';
|
||||
print '<td class="center">'.$langs->trans("LastMemberDate").'</td>';
|
||||
print '<td class="center">'.$langs->trans("LatestSubscriptionDate").'</td>';
|
||||
|
||||
@@ -221,13 +221,13 @@ if ($mode && !count($data))
|
||||
}
|
||||
else
|
||||
{
|
||||
if ($mode == 'memberbycountry') print $langs->trans("MembersByCountryDesc").'<br>';
|
||||
elseif ($mode == 'memberbystate') print $langs->trans("MembersByStateDesc").'<br>';
|
||||
elseif ($mode == 'memberbytown') print $langs->trans("MembersByTownDesc").'<br>';
|
||||
elseif ($mode == 'memberbyregion') print $langs->trans("MembersByRegion").'<br>'; //+
|
||||
if ($mode == 'memberbycountry') print '<span class="opacitymedium">'.$langs->trans("MembersByCountryDesc").'</span><br>';
|
||||
elseif ($mode == 'memberbystate') print '<span class="opacitymedium">'.$langs->trans("MembersByStateDesc").'</span><br>';
|
||||
elseif ($mode == 'memberbytown') print '<span class="opacitymedium">'.$langs->trans("MembersByTownDesc").'</span><br>';
|
||||
elseif ($mode == 'memberbyregion') print '<span class="opacitymedium">'.$langs->trans("MembersByRegion").'</span><br>'; //+
|
||||
else
|
||||
{
|
||||
print $langs->trans("MembersStatisticsDesc").'<br>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("MembersStatisticsDesc").'</span><br>';
|
||||
print '<br>';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?mode=memberbycountry">'.$langs->trans("MembersStatisticsByCountries").'</a><br>';
|
||||
print '<br>';
|
||||
|
||||
@@ -183,9 +183,9 @@ foreach ($data as $val)
|
||||
$oldyear--;
|
||||
print '<tr class="oddeven" height="24">';
|
||||
print '<td class="center">';
|
||||
print '<a href="month.php?year='.$oldyear.'&mode='.$mode.'">';
|
||||
//print '<a href="month.php?year='.$oldyear.'&mode='.$mode.'">';
|
||||
print $oldyear;
|
||||
print '</a>';
|
||||
//print '</a>';
|
||||
print '</td>';
|
||||
print '<td class="right">0</td>';
|
||||
print '<td class="right">0</td>';
|
||||
|
||||
@@ -66,6 +66,7 @@ if (($action == 'update' && !GETPOST("cancel", 'alpha'))
|
||||
|
||||
if ($action != 'updateedit' && !$error)
|
||||
{
|
||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
||||
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||
exit;
|
||||
}
|
||||
|
||||
113
htdocs/admin/bom_extrafields.php
Normal file
113
htdocs/admin/bom_extrafields.php
Normal file
@@ -0,0 +1,113 @@
|
||||
<?php
|
||||
/* Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2012 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/admin/bom_extrafields.php
|
||||
* \ingroup bom
|
||||
* \brief Page to setup extra fields of BOM
|
||||
*/
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/bom/lib/bom.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('mrp', 'admin'));
|
||||
|
||||
$extrafields = new ExtraFields($db);
|
||||
$form = new Form($db);
|
||||
|
||||
// List of supported format
|
||||
$tmptype2label = ExtraFields::$type2label;
|
||||
$type2label = array('');
|
||||
foreach ($tmptype2label as $key => $val) $type2label[$key] = $langs->transnoentitiesnoconv($val);
|
||||
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$attrname = GETPOST('attrname', 'alpha');
|
||||
$elementtype = 'bom_bom';
|
||||
|
||||
if (!$user->admin) accessforbidden();
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
*/
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/actions_extrafields.inc.php';
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
|
||||
llxHeader('', $langs->trans("BOMsSetup"), $help_url);
|
||||
|
||||
|
||||
$linkback = '<a href="'.DOL_URL_ROOT.'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans("BackToModuleList").'</a>';
|
||||
print load_fiche_titre($langs->trans("BOMsSetup"), $linkback, 'title_setup');
|
||||
|
||||
|
||||
$head = bomAdminPrepareHead(null);
|
||||
|
||||
dol_fiche_head($head, 'bom_extrafields', $langs->trans("ExtraFields"), -1, 'account');
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
|
||||
// Buttons
|
||||
if ($action != 'create' && $action != 'edit')
|
||||
{
|
||||
print '<div class="tabsAction">';
|
||||
print "<a class=\"butAction\" href=\"".$_SERVER["PHP_SELF"]."?action=create#newattrib\">".$langs->trans("NewAttribute")."</a>";
|
||||
print "</div>";
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Creation of an optional field
|
||||
*/
|
||||
if ($action == 'create')
|
||||
{
|
||||
print '<br><div id="newattrib"></div>';
|
||||
print load_fiche_titre($langs->trans('NewAttribute'));
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_add.tpl.php';
|
||||
}
|
||||
|
||||
/*
|
||||
* Edition of an optional field
|
||||
*/
|
||||
if ($action == 'edit' && !empty($attrname))
|
||||
{
|
||||
print "<br>";
|
||||
print load_fiche_titre($langs->trans("FieldEdition", $attrname));
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php';
|
||||
}
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
@@ -97,8 +97,10 @@ if ($action == 'add') {
|
||||
{
|
||||
if (!$error && $fk_user != '')
|
||||
{
|
||||
$arrayofexistingboxid = array();
|
||||
$nbboxonleft = $nbboxonright = 0;
|
||||
$sql = "SELECT box_order FROM ".MAIN_DB_PREFIX."boxes WHERE position = ".$pos." AND fk_user = ".$fk_user." AND entity = ".$conf->entity;
|
||||
$sql = "SELECT box_id, box_order FROM ".MAIN_DB_PREFIX."boxes";
|
||||
$sql .= " WHERE position = ".$pos." AND fk_user = ".$fk_user." AND entity = ".$conf->entity;
|
||||
dol_syslog("boxes.php activate box", LOG_DEBUG);
|
||||
$resql = $db->query($sql);
|
||||
if ($resql)
|
||||
@@ -108,22 +110,27 @@ if ($action == 'add') {
|
||||
$boxorder = $obj->box_order;
|
||||
if (preg_match('/A/', $boxorder)) $nbboxonleft++;
|
||||
if (preg_match('/B/', $boxorder)) $nbboxonright++;
|
||||
$arrayofexistingboxid[$obj->box_id] = 1;
|
||||
}
|
||||
}
|
||||
else dol_print_error($db);
|
||||
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."boxes (";
|
||||
$sql .= "box_id, position, box_order, fk_user, entity";
|
||||
$sql .= ") values (";
|
||||
$sql .= $boxid['value'].", ".$pos.", '".(($nbboxonleft > $nbboxonright) ? 'B01' : 'A01')."', ".$fk_user.", ".$conf->entity;
|
||||
$sql .= ")";
|
||||
if (empty($arrayofexistingboxid[$boxid['value']])) {
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."boxes (";
|
||||
$sql .= "box_id, position, box_order, fk_user, entity";
|
||||
$sql .= ") values (";
|
||||
$sql .= $boxid['value'].", ".$pos.", '".(($nbboxonleft > $nbboxonright) ? 'B01' : 'A01')."', ".$fk_user.", ".$conf->entity;
|
||||
$sql .= ")";
|
||||
|
||||
dol_syslog("boxes.php activate box", LOG_DEBUG);
|
||||
$resql = $db->query($sql);
|
||||
if (!$resql)
|
||||
{
|
||||
setEventMessages($db->lasterror(), null, 'errors');
|
||||
$error++;
|
||||
dol_syslog("boxes.php activate box", LOG_DEBUG);
|
||||
$resql = $db->query($sql);
|
||||
if (!$resql)
|
||||
{
|
||||
setEventMessages($db->lasterror(), null, 'errors');
|
||||
$error++;
|
||||
}
|
||||
} else {
|
||||
dol_syslog("boxes.php activate box - already exists in database", LOG_DEBUG);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -324,7 +331,7 @@ $boxactivated = InfoBox::listBoxes($db, 'activated', -1, null);
|
||||
|
||||
print "<br>\n";
|
||||
print "\n\n".'<!-- Boxes Available -->'."\n";
|
||||
print load_fiche_titre($langs->trans("BoxesAvailable"));
|
||||
print load_fiche_titre($langs->trans("BoxesAvailable"), '', '');
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">'."\n";
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">'."\n";
|
||||
@@ -353,7 +360,7 @@ foreach ($boxtoadd as $box)
|
||||
|
||||
print "\n".'<!-- Box '.$box->boxcode.' -->'."\n";
|
||||
print '<tr class="oddeven">'."\n";
|
||||
print '<td>'.img_object("", $logo).' '.$langs->transnoentitiesnoconv($box->boxlabel);
|
||||
print '<td>'.img_object("", $logo, 'height="14px"').' '.$langs->transnoentitiesnoconv($box->boxlabel);
|
||||
if (!empty($box->class) && preg_match('/graph_/', $box->class)) print ' ('.$langs->trans("Graph").')';
|
||||
print '</td>'."\n";
|
||||
print '<td>';
|
||||
@@ -368,7 +375,7 @@ foreach ($boxtoadd as $box)
|
||||
|
||||
// For each possible position, an activation link is displayed if the box is not already active for that position
|
||||
print '<td class="center">';
|
||||
print $form->selectarray("boxid[".$box->box_id."][pos]", $pos_name, 0, 1, 0, 0, '', 1)."\n";
|
||||
print $form->selectarray("boxid[".$box->box_id."][pos]", $pos_name, -1, 1, 0, 0, '', 1)."\n";
|
||||
print '<input type="hidden" name="boxid['.$box->box_id.'][value]" value="'.$box->box_id.'">'."\n";
|
||||
print '</td>';
|
||||
|
||||
@@ -390,7 +397,7 @@ print "\n".'<!-- End Boxes Available -->'."\n";
|
||||
|
||||
//var_dump($boxactivated);
|
||||
print "<br>\n\n";
|
||||
print load_fiche_titre($langs->trans("BoxesActivated"));
|
||||
print load_fiche_titre($langs->trans("BoxesActivated"), '', '');
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="tagtable liste">'."\n";
|
||||
@@ -418,7 +425,7 @@ foreach ($boxactivated as $key => $box)
|
||||
|
||||
print "\n".'<!-- Box '.$box->boxcode.' -->'."\n";
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.img_object("", $logo).' '.$langs->transnoentitiesnoconv($box->boxlabel);
|
||||
print '<td>'.img_object("", $logo, 'height="14px"').' '.$langs->transnoentitiesnoconv($box->boxlabel);
|
||||
if (!empty($box->class) && preg_match('/graph_/', $box->class)) print ' ('.$langs->trans("Graph").')';
|
||||
print '</td>';
|
||||
print '<td>';
|
||||
@@ -452,7 +459,7 @@ print '<br>';
|
||||
// Other parameters
|
||||
|
||||
print "\n\n".'<!-- Other Const -->'."\n";
|
||||
print load_fiche_titre($langs->trans("Other"));
|
||||
print load_fiche_titre($langs->trans("Other"), '', '');
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="addconst">';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2005-2011 Laurent Destailleur <eldy@users.sourceforge.org>
|
||||
* Copyright (C) 2005-2020 Laurent Destailleur <eldy@users.sourceforge.org>
|
||||
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -33,6 +33,10 @@ if (!$user->admin) accessforbidden();
|
||||
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
|
||||
if (! in_array('clicktodial', $conf->modules)) {
|
||||
accessforbidden($langs->trans("WarningModuleNotActive", $langs->transnoentitiesnoconv("Module58Name")));
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
@@ -58,6 +62,8 @@ if ($action == 'setvalue' && $user->admin)
|
||||
* View
|
||||
*/
|
||||
|
||||
$form = new Form($db);
|
||||
|
||||
$user->fetch_clicktodial();
|
||||
|
||||
$wikihelp = 'EN:Module_ClickToDial_En|FR:Module_ClickToDial|ES:Módulo_ClickTodial_Es';
|
||||
@@ -73,6 +79,7 @@ print '<form method="post" action="clicktodial.php">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="setvalue">';
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Name").'</td>';
|
||||
@@ -105,6 +112,7 @@ print $langs->trans("Example").':<br>http://myphoneserver/mypage?login=__LOGIN__
|
||||
print '</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
print '</div>';
|
||||
|
||||
print '<div class="center"><br><input type="submit" class="button" value="'.$langs->trans("Modify").'"></div>';
|
||||
|
||||
|
||||
@@ -111,6 +111,12 @@ if (($action == 'update' && !GETPOST("cancel", 'alpha'))
|
||||
|
||||
foreach ($arrayofimages as $varforimage)
|
||||
{
|
||||
if ($_FILES[$varforimage]["name"] && ! preg_match('/(\.jpeg|\.jpg|\.png)$/i', $_FILES[$varforimage]["name"])) { // Logo can be used on a lot of different places. Only jpg and png can be supported.
|
||||
$langs->load("errors");
|
||||
setEventMessages($langs->trans("ErrorBadImageFormat"), null, 'errors');
|
||||
break;
|
||||
}
|
||||
|
||||
if ($_FILES[$varforimage]["tmp_name"])
|
||||
{
|
||||
$reg = array();
|
||||
@@ -250,6 +256,7 @@ if (($action == 'update' && !GETPOST("cancel", 'alpha'))
|
||||
|
||||
if (!$error)
|
||||
{
|
||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
||||
$db->commit();
|
||||
}
|
||||
else
|
||||
@@ -415,7 +422,7 @@ print '<tr class="liste_titre"><th class="titlefield wordbreak">'.$langs->trans(
|
||||
|
||||
// Name
|
||||
print '<tr class="oddeven"><td class="fieldrequired wordbreak"><label for="name">'.$langs->trans("CompanyName").'</label></td><td>';
|
||||
print '<input name="nom" id="name" class="minwidth200" value="'.dol_escape_htmltag($conf->global->MAIN_INFO_SOCIETE_NOM ? $conf->global->MAIN_INFO_SOCIETE_NOM : GETPOST("nom", 'nohtml')).'"'.(empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER) ? '' : ' autofocus="autofocus"').'></td></tr>'."\n";
|
||||
print '<input name="nom" id="name" class="minwidth200" value="'.dol_escape_htmltag($conf->global->MAIN_INFO_SOCIETE_NOM ? $conf->global->MAIN_INFO_SOCIETE_NOM : GETPOST("nom", 'nohtml')).'"'.(empty($conf->global->MAIN_INFO_SOCIETE_NOM) ? ' autofocus="autofocus"' : '').'></td></tr>'."\n";
|
||||
|
||||
// Address
|
||||
print '<tr class="oddeven"><td><label for="MAIN_INFO_SOCIETE_ADDRESS">'.$langs->trans("CompanyAddress").'</label></td><td>';
|
||||
@@ -494,10 +501,17 @@ if (!empty($mysoc->logo_mini)) {
|
||||
print '</div>';
|
||||
}
|
||||
print '<div class="inline-block valignmiddle marginrightonly"><a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=removelogo">'.img_delete($langs->trans("Delete"), '', 'marginleftonly').'</a></div>';
|
||||
} else {
|
||||
print '<div class="inline-block valignmiddle">';
|
||||
print '<img height="60" src="'.DOL_URL_ROOT.'/public/theme/common/nophoto.png">';
|
||||
print '</div>';
|
||||
} elseif (!empty($mysoc->logo)) {
|
||||
if (file_exists($conf->mycompany->dir_output.'/logos/'.$mysoc->logo)) {
|
||||
print '<div class="inline-block valignmiddle">';
|
||||
print '<img style="max-height: 60px" src="'.DOL_URL_ROOT.'/viewimage.php?modulepart=mycompany&file='.urlencode('logos/'.$mysoc->logo).'">';
|
||||
print '</div>';
|
||||
print '<div class="inline-block valignmiddle marginrightonly"><a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=removelogo">'.img_delete($langs->trans("Delete"), '', 'marginleftonly').'</a></div>';
|
||||
} else {
|
||||
print '<div class="inline-block valignmiddle">';
|
||||
print '<img height="60" src="'.DOL_URL_ROOT.'/public/theme/common/nophoto.png">';
|
||||
print '</div>';
|
||||
}
|
||||
}
|
||||
print '</div>';
|
||||
print '</td></tr>';
|
||||
@@ -514,10 +528,18 @@ if (!empty($mysoc->logo_squarred_mini)) {
|
||||
print '</div>';
|
||||
}
|
||||
print '<div class="inline-block valignmiddle marginrightonly"><a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=removelogosquarred">'.img_delete($langs->trans("Delete"), '', 'marginleftonly').'</a></div>';
|
||||
} else {
|
||||
print '<div class="inline-block valignmiddle">';
|
||||
print '<img height="60" src="'.DOL_URL_ROOT.'/public/theme/common/nophoto.png">';
|
||||
print '</div>';
|
||||
} elseif (!empty($mysoc->logo_squarred)) {
|
||||
if (file_exists($conf->mycompany->dir_output.'/logos/'.$mysoc->logo_squarred)) {
|
||||
print '<div class="inline-block valignmiddle">';
|
||||
print '<img style="max-height: 60px" src="'.DOL_URL_ROOT.'/viewimage.php?modulepart=mycompany&file='.urlencode('logos/'.$mysoc->logo_squarred).'">';
|
||||
print '</div>';
|
||||
print '<div class="inline-block valignmiddle marginrightonly"><a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=removelogosquarred">'.img_delete($langs->trans("Delete"), '', 'marginleftonly').'</a></div>';
|
||||
}
|
||||
else {
|
||||
print '<div class="inline-block valignmiddle">';
|
||||
print '<img height="60" src="'.DOL_URL_ROOT.'/public/theme/common/nophoto.png">';
|
||||
print '</div>';
|
||||
}
|
||||
}
|
||||
print '</div>';
|
||||
print '</td></tr>';
|
||||
|
||||
@@ -93,7 +93,7 @@ print load_fiche_titre($langs->trans("SendingsSetup"), $linkback, 'title_setup')
|
||||
print '<br>';
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'general', $langs->trans("Sendings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'general', $langs->trans("Sendings"), -1, 'shipment');
|
||||
|
||||
// Miscellaneous parameters
|
||||
|
||||
|
||||
@@ -577,6 +577,7 @@ if ($id == 11)
|
||||
// 'contract' => $langs->trans('Contract'),
|
||||
'project' => $langs->trans('Project'),
|
||||
'project_task' => $langs->trans('Task'),
|
||||
'ticket' => $langs->trans('Ticket'),
|
||||
'agenda' => $langs->trans('Agenda'),
|
||||
'dolresource' => $langs->trans('Resource'),
|
||||
// old deprecated
|
||||
@@ -757,8 +758,11 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
||||
$keycode = $listfieldvalue[$i];
|
||||
if (empty($keycode)) $keycode = $value;
|
||||
|
||||
if ($value == 'price' || preg_match('/^amount/i', $value) || $value == 'taux') {
|
||||
$_POST[$keycode] = price2num($_POST[$keycode], 'MU');
|
||||
if ($value == 'price' || preg_match('/^amount/i', $value)) {
|
||||
$_POST[$keycode] = price2num(GETPOST($keycode), 'MU');
|
||||
}
|
||||
elseif ($value == 'taux' || $value == 'localtax1' || $value == 'localtax2') {
|
||||
$_POST[$keycode] = price2num(GETPOST($keycode), 8);
|
||||
}
|
||||
elseif ($value == 'entity') {
|
||||
$_POST[$keycode] = getEntity($tabname[$id]);
|
||||
@@ -790,7 +794,7 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
||||
if ($result) // Add is ok
|
||||
{
|
||||
setEventMessages($langs->transnoentities("RecordSaved"), null, 'mesgs');
|
||||
$_POST = array('id'=>$id); // Clean $_POST array, we keep only
|
||||
$_POST = array('id'=>$id); // Clean $_POST array, we keep only id
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -823,8 +827,11 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
||||
$keycode = $listfieldvalue[$i];
|
||||
if (empty($keycode)) $keycode = $field;
|
||||
|
||||
if ($field == 'price' || preg_match('/^amount/i', $field) || $field == 'taux') {
|
||||
$_POST[$keycode] = price2num($_POST[$keycode], 'MU');
|
||||
if ($field == 'price' || preg_match('/^amount/i', $field)) {
|
||||
$_POST[$keycode] = price2num(GETPOST($keycode), 'MU');
|
||||
}
|
||||
elseif ($field == 'taux' || $field == 'localtax1' || $field == 'localtax2') {
|
||||
$_POST[$keycode] = price2num(GETPOST($keycode), 8);
|
||||
}
|
||||
elseif ($field == 'entity') {
|
||||
$_POST[$keycode] = getEntity($tabname[$id]);
|
||||
@@ -1454,6 +1461,7 @@ if ($id)
|
||||
foreach ($fieldlist as $field => $value)
|
||||
{
|
||||
//var_dump($fieldlist);
|
||||
|
||||
$class = '';
|
||||
$showfield = 1;
|
||||
$valuetoshow = $obj->{$fieldlist[$field]};
|
||||
|
||||
@@ -448,6 +448,8 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
if (!$connection)
|
||||
{
|
||||
$morehtml .= 'Failed to open IMAP connection '.$connectstringsource;
|
||||
$morehtml .= '<br>'.imap_last_error();
|
||||
//var_dump(imap_errors())
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -197,7 +197,7 @@ print load_fiche_titre($langs->trans("SendingsSetup"), $linkback, 'title_setup')
|
||||
print '<br>';
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'shipment', $langs->trans("Sendings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'shipment', $langs->trans("Sendings"), -1, 'shipment');
|
||||
|
||||
// Shipment numbering model
|
||||
|
||||
|
||||
@@ -76,7 +76,7 @@ print "<br>\n";
|
||||
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'attributes_shipment', $langs->trans("Sendings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'attributes_shipment', $langs->trans("Sendings"), -1, 'shipment');
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@ print "<br>\n";
|
||||
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'attributeslines_shipment', $langs->trans("Sendings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'attributeslines_shipment', $langs->trans("Sendings"), -1, 'shipment');
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||
|
||||
|
||||
@@ -104,12 +104,7 @@ $arrayAvailableType = array(
|
||||
Facture::TYPE_SITUATION => $langs->trans("InvoiceSituation"),
|
||||
Facture::TYPE_STANDARD.'+'.Facture::TYPE_SITUATION => $langs->trans("InvoiceSituation").' + '.$langs->trans("InvoiceStandard"),
|
||||
);
|
||||
$selected = array();
|
||||
$implodeglue = '+';
|
||||
if (!empty($conf->global->{$confkey}) && !is_array($conf->global->{$confkey})) {
|
||||
$selected = explode('+', $conf->global->{$confkey});
|
||||
}
|
||||
|
||||
$selected = $conf->global->$confkey;
|
||||
$curentInput = (empty($inputCount) ? 1 : ($inputCount + 1));
|
||||
$formSelectInvoiceType = $form->selectarray('value'.$curentInput, $arrayAvailableType, $selected, 1);
|
||||
_printInputFormPart($confkey, $langs->trans('AllowedInvoiceForRetainedWarranty'), '', array(), $formSelectInvoiceType);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2007-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2007-2020 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2009-2018 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2010 Juanjo Menent <jmenent@2byte.es>
|
||||
*
|
||||
@@ -34,11 +34,21 @@ if (!$user->admin) accessforbidden();
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$currencycode = GETPOST('currencycode', 'alpha');
|
||||
|
||||
if (!empty($conf->multicurrency->enabled) && !empty($conf->global->MULTICURRENCY_USE_LIMIT_BY_CURRENCY)) {
|
||||
// When MULTICURRENCY_USE_LIMIT_BY_CURRENCY is on, we use always a defined currency code instead of '' even for default.
|
||||
$currencycode = (!empty($currencycode) ? $currencycode : $conf->currency);
|
||||
}
|
||||
|
||||
$mainmaxdecimalsunit = 'MAIN_MAX_DECIMALS_UNIT'.(!empty($currencycode) ? '_'.$currencycode : '');
|
||||
$mainmaxdecimalstot = 'MAIN_MAX_DECIMALS_TOT'.(!empty($currencycode) ? '_'.$currencycode : '');
|
||||
$mainmaxdecimalsshown = 'MAIN_MAX_DECIMALS_SHOWN'.(!empty($currencycode) ? '_'.$currencycode : '');
|
||||
$mainroundingruletot = 'MAIN_ROUNDING_RULE_TOT'.(!empty($currencycode) ? '_'.$currencycode : '');
|
||||
|
||||
$valmainmaxdecimalsunit = GETPOST($mainmaxdecimalsunit, 'int');
|
||||
$valmainmaxdecimalstot = GETPOST($mainmaxdecimalstot, 'int');
|
||||
$valmainmaxdecimalsshown = GETPOST($mainmaxdecimalsshown, 'int');
|
||||
$valmainroundingruletot = price2num(GETPOST($mainroundingruletot, 'alpha'));
|
||||
|
||||
if ($action == 'update')
|
||||
{
|
||||
$error = 0;
|
||||
@@ -60,9 +70,9 @@ if ($action == 'update')
|
||||
setEventMessages($langs->trans("ErrorNegativeValueNotAllowed"), null, 'errors');
|
||||
}
|
||||
|
||||
if ($_POST[$mainroundingruletot])
|
||||
if ($valmainroundingruletot)
|
||||
{
|
||||
if ($_POST[$mainroundingruletot] * pow(10, $_POST[$mainmaxdecimalstot]) < 1)
|
||||
if ($valmainroundingruletot * pow(10, $valmainmaxdecimalstot) < 1)
|
||||
{
|
||||
$langs->load("errors");
|
||||
$error++;
|
||||
@@ -72,11 +82,11 @@ if ($action == 'update')
|
||||
|
||||
if (!$error)
|
||||
{
|
||||
dolibarr_set_const($db, $mainmaxdecimalsunit, $_POST[$mainmaxdecimalsunit], 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, $mainmaxdecimalstot, $_POST[$mainmaxdecimalstot], 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, $mainmaxdecimalsshown, $_POST[$mainmaxdecimalsshown], 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, $mainmaxdecimalsunit, $valmainmaxdecimalsunit, 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, $mainmaxdecimalstot, $valmainmaxdecimalstot, 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, $mainmaxdecimalsshown, $valmainmaxdecimalsshown, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
dolibarr_set_const($db, $mainroundingruletot, $_POST[$mainroundingruletot], 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, $mainroundingruletot, $valmainroundingruletot, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
header("Location: ".$_SERVER["PHP_SELF"]."?mainmenu=home&leftmenu=setup".(!empty($currencycode) ? '¤cycode='.$currencycode : ''));
|
||||
exit;
|
||||
@@ -94,7 +104,6 @@ llxHeader();
|
||||
|
||||
print load_fiche_titre($langs->trans("LimitsSetup"), '', 'title_setup');
|
||||
|
||||
$currencycode = (!empty($currencycode) ? $currencycode : $conf->currency);
|
||||
$aCurrencies = array($conf->currency); // Default currency always first position
|
||||
|
||||
if (!empty($conf->multicurrency->enabled) && !empty($conf->global->MULTICURRENCY_USE_LIMIT_BY_CURRENCY))
|
||||
@@ -162,9 +171,7 @@ if ($action == 'edit')
|
||||
|
||||
print '</form>';
|
||||
print '<br>';
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre"><td>'.$langs->trans("Parameter").'</td><td>'.$langs->trans("Value").'</td></tr>';
|
||||
|
||||
@@ -203,9 +210,7 @@ if (empty($mysoc->country_code))
|
||||
$langs->load("errors");
|
||||
$warnpicto = img_warning($langs->trans("WarningMandatorySetupNotComplete"));
|
||||
print '<br><a href="'.DOL_URL_ROOT.'/admin/company.php?mainmenu=home">'.$warnpicto.' '.$langs->trans("WarningMandatorySetupNotComplete").'</a>';
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
// Show examples
|
||||
print load_fiche_titre($langs->trans("ExamplesWithCurrentSetup"), '', '');
|
||||
|
||||
@@ -236,9 +241,9 @@ else
|
||||
// Add vat rates examples specific to country
|
||||
$vat_rates = array();
|
||||
|
||||
$sql = "SELECT taux as vat_rate";
|
||||
$sql = "SELECT taux as vat_rate, t.code as vat_code, t.localtax1 as localtax_rate1, t.localtax2 as localtax_rate2";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c";
|
||||
$sql .= " WHERE t.active=1 AND t.fk_pays = c.rowid AND c.code='".$mysoc->country_code."' AND t.taux <> 0";
|
||||
$sql .= " WHERE t.active=1 AND t.fk_pays = c.rowid AND c.code='".$mysoc->country_code."' AND (t.taux <> 0 OR t.localtax1 <>0 OR t.localtax2 <>0)";
|
||||
$sql .= " ORDER BY t.taux ASC";
|
||||
$resql = $db->query($sql);
|
||||
if ($resql)
|
||||
@@ -249,96 +254,54 @@ else
|
||||
for ($i = 0; $i < $num; $i++)
|
||||
{
|
||||
$obj = $db->fetch_object($resql);
|
||||
$vat_rates[$i] = $obj->vat_rate;
|
||||
$vat_rates[] = array('vat_rate'=>$obj->vat_rate, 'code'=>$obj->vat_code, 'localtax_rate1'=>$obj->localtax_rate1, 'locltax_rate2'=>$obj->localtax_rate2);
|
||||
}
|
||||
}
|
||||
}
|
||||
else dol_print_error($db);
|
||||
} else dol_print_error($db);
|
||||
|
||||
if (count($vat_rates))
|
||||
{
|
||||
foreach ($vat_rates as $vat)
|
||||
foreach ($vat_rates as $vatarray)
|
||||
{
|
||||
$vat = $vatarray['vat_rate'];
|
||||
for ($qty = 1; $qty <= 2; $qty++)
|
||||
{
|
||||
$vattxt = $vat.($vatarray['code'] ? ' ('.$vatarray['code'].')' : '');
|
||||
|
||||
$localtax_array = getLocalTaxesFromRate($vattxt, 0, $mysoc, $mysoc);
|
||||
|
||||
$s = 10 / 3;
|
||||
$tmparray = calcul_price_total(1, $qty * price2num($s, 'MU'), 0, $vat, 0, 0, 0, 'HT', 0, 0, $mysoc);
|
||||
$tmparray = calcul_price_total($qty, price2num($s, 'MU'), 0, $vat, -1, -1, 0, 'HT', 0, 0, $mysoc, $localtax_array);
|
||||
print '<span class="opacitymedium">'.$langs->trans("UnitPriceOfProduct").":</span> ".price2num($s, 'MU');
|
||||
print " x ".$langs->trans("Quantity").": ".$qty;
|
||||
print " - ".$langs->trans("VAT").": ".$vat.'%';
|
||||
print ' -> <span class="opacitymedium">'.$langs->trans("TotalPriceAfterRounding").":</span> ".$tmparray[0].' / '.$tmparray[1].' / '.$tmparray[2]."<br>\n";
|
||||
print ($vatarray['code'] ? ' ('.$vatarray['code'].')' : '');
|
||||
print ' -> <span class="opacitymedium">'.$langs->trans("TotalPriceAfterRounding").":</span> ";
|
||||
print $tmparray[0].' / '.$tmparray[1].($tmparray[9] ? '+'.$tmparray[9] : '').($tmparray[10] ? '+'.$tmparray[10] : '').' / '.$tmparray[2];
|
||||
print "<br>\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
// More examples if not specific vat rate found
|
||||
// This example must be kept for test purpose with current value because value used (2/7, 10/3, and vat 0, 10)
|
||||
// were calculated to show all possible cases of rounding. If we change this, examples becomes useless or show the same rounding rule.
|
||||
|
||||
$localtax_array = array();
|
||||
|
||||
$s = 10 / 3; $qty = 1; $vat = 10;
|
||||
$tmparray = calcul_price_total(1, $qty * price2num($s, 'MU'), 0, $vat, 0, 0, 0, 'HT', 0, 0, $mysoc);
|
||||
$tmparray = calcul_price_total($qty, price2num($s, 'MU'), 0, $vat, -1, -1, 0, 'HT', 0, 0, $mysoc, $localtax_array);
|
||||
print '<span class="opacitymedium">'.$langs->trans("UnitPriceOfProduct").":</span> ".price2num($s, 'MU');
|
||||
print " x ".$langs->trans("Quantity").": ".$qty;
|
||||
print " - ".$langs->trans("VAT").": ".$vat.'%';
|
||||
print ' -> <span class="opacitymedium">'.$langs->trans("TotalPriceAfterRounding").": ".$tmparray[0].' / '.$tmparray[1].' / '.$tmparray[2]."<br>\n";
|
||||
print ' -> <span class="opacitymedium">'.$langs->trans("TotalPriceAfterRounding").":</span> ".$tmparray[0].' / '.$tmparray[1].' / '.$tmparray[2]."<br>\n";
|
||||
|
||||
$s = 10 / 3; $qty = 2; $vat = 10;
|
||||
$tmparray = calcul_price_total(1, $qty * price2num($s, 'MU'), 0, $vat, 0, 0, 0, 'HT', 0, 0, $mysoc);
|
||||
$tmparray = calcul_price_total($qty, price2num($s, 'MU'), 0, $vat, -1, -1, 0, 'HT', 0, 0, $mysoc, $localtax_array);
|
||||
print '<span class="opacitymedium">'.$langs->trans("UnitPriceOfProduct").":</span> ".price2num($s, 'MU');
|
||||
print " x ".$langs->trans("Quantity").": ".$qty;
|
||||
print " - ".$langs->trans("VAT").": ".$vat.'%';
|
||||
print ' -> <span class="opacitymedium">'.$langs->trans("TotalPriceAfterRounding").":</span> ".$tmparray[0].' / '.$tmparray[1].' / '.$tmparray[2]."<br>\n";
|
||||
}
|
||||
|
||||
// Important: can debug rounding, to simulate the rounded total
|
||||
/*
|
||||
print '<br><b>'.$langs->trans("VATRoundedByLine").' ('.$langs->trans("DolibarrDefault").')</b><br>';
|
||||
|
||||
foreach($vat_rates as $vat)
|
||||
{
|
||||
for ($qty=1; $qty<=2; $qty++)
|
||||
{
|
||||
$s1=10/3;
|
||||
$s2=2/7;
|
||||
|
||||
// Round by line
|
||||
$tmparray1=calcul_price_total(1,$qty*price2num($s1,'MU'),0,$vat,0,0,0,'HT',0, 0,$mysoc);
|
||||
$tmparray2=calcul_price_total(1,$qty*price2num($s2,'MU'),0,$vat,0,0,0,'HT',0, 0,$mysoc);
|
||||
$total_ht = $tmparray1[0] + $tmparray2[0];
|
||||
$total_tva = $tmparray1[1] + $tmparray2[1];
|
||||
$total_ttc = $tmparray1[2] + $tmparray2[2];
|
||||
|
||||
print $langs->trans("UnitPriceOfProduct").": ".(price2num($s1,'MU') + price2num($s2,'MU'));
|
||||
print " x ".$langs->trans("Quantity").": ".$qty;
|
||||
print " - ".$langs->trans("VAT").": ".$vat.'%';
|
||||
print " -> ".$langs->trans("TotalPriceAfterRounding").": ".$total_ht.' / '.$total_tva.' / '.$total_ttc."<br>\n";
|
||||
}
|
||||
}
|
||||
|
||||
print '<br><b>'.$langs->trans("VATRoundedOnTotal").'</b><br>';
|
||||
|
||||
foreach($vat_rates as $vat)
|
||||
{
|
||||
for ($qty=1; $qty<=2; $qty++)
|
||||
{
|
||||
$s1=10/3;
|
||||
$s2=2/7;
|
||||
|
||||
// Global round
|
||||
$subtotal_ht = (($qty*price2num($s1,'MU')) + ($qty*price2num($s2,'MU')));
|
||||
$tmparray3=calcul_price_total(1,$subtotal_ht,0,$vat,0,0,0,'HT',0, 0,$mysoc);
|
||||
$total_ht = $tmparray3[0];
|
||||
$total_tva = $tmparray3[1];
|
||||
$total_ttc = $tmparray3[2];
|
||||
|
||||
print $langs->trans("UnitPriceOfProduct").": ".price2num($s1+$s2,'MU');
|
||||
print " x ".$langs->trans("Quantity").": ".$qty;
|
||||
print " - ".$langs->trans("VAT").": ".$vat.'%';
|
||||
print " -> ".$langs->trans("TotalPriceAfterRounding").": ".$total_ht.' / '.$total_tva.' / '.$total_ttc."<br>\n";
|
||||
}
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
// End of page
|
||||
|
||||
@@ -187,7 +187,7 @@ print load_fiche_titre($langs->trans("SendingsSetup"), $linkback, 'title_setup')
|
||||
print '<br>';
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'receivings', $langs->trans("Receivings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'receivings', $langs->trans("Receivings"), -1, 'shipment');
|
||||
|
||||
|
||||
// Delivery numbering model
|
||||
|
||||
@@ -76,7 +76,7 @@ print "<br>\n";
|
||||
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'attributes_receivings', $langs->trans("Receivings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'attributes_receivings', $langs->trans("Receivings"), -1, 'shipment');
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@ print "<br>\n";
|
||||
|
||||
$head = expedition_admin_prepare_head();
|
||||
|
||||
dol_fiche_head($head, 'attributeslines_receivings', $langs->trans("Receivings"), -1, 'sending');
|
||||
dol_fiche_head($head, 'attributeslines_receivings', $langs->trans("Receivings"), -1, 'shipment');
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@ print '</td></tr>';
|
||||
|
||||
print '<tr class="oddeven"><td>';
|
||||
print $langs->trans("MailingDelay").'</td><td>';
|
||||
print '<input size="32" type="text" name="MAILING_DELAY" value="'.$conf->global->MAILING_DELAY.'">';
|
||||
print '<input class="width75" type="text" name="MAILING_DELAY" value="'.$conf->global->MAILING_DELAY.'">';
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
|
||||
@@ -720,7 +720,7 @@ else
|
||||
{
|
||||
if (function_exists('fsockopen') && $port && $server)
|
||||
{
|
||||
print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?action=testconnect#formmailbeforetitle">'.$langs->trans("DoTestServerAvailability").'</a>';
|
||||
print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?action=testconnect&date='.dol_now().'#formmailbeforetitle">'.$langs->trans("DoTestServerAvailability").'</a>';
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -764,11 +764,17 @@ else
|
||||
|
||||
if ($conf->global->MAIN_MAIL_SENDMODE == 'mail')
|
||||
{
|
||||
// MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS is list of IPs where email is sent from. Example: '1.2.3.4, [aaaa:bbbb:cccc:dddd]'.
|
||||
if (!empty($conf->global->MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS))
|
||||
if (!empty($conf->global->MAIN_EXTERNAL_MAIL_SPF_STRING_TO_ADD))
|
||||
{
|
||||
// List of IP show as record to add in SPF if we use the mail method
|
||||
$text .= ($text ? '<br><br>' : '').$langs->trans("WarningPHPMailSPF", $conf->global->MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS);
|
||||
// List of string to add in SPF if the setup use the mail method
|
||||
$text .= ($text ? '<br><br>' : '').$langs->trans("WarningPHPMailSPF", $conf->global->MAIN_EXTERNAL_MAIL_SPF_STRING_TO_ADD);
|
||||
} else {
|
||||
// MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS is list of IPs where email is sent from. Example: '1.2.3.4, [aaaa:bbbb:cccc:dddd]'.
|
||||
if (!empty($conf->global->MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS))
|
||||
{
|
||||
// List of IP show as record to add in SPF if we use the mail method
|
||||
$text .= ($text ? '<br><br>' : '').$langs->trans("WarningPHPMailSPF", $conf->global->MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (!empty($conf->global->MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS))
|
||||
@@ -776,7 +782,7 @@ else
|
||||
// List of IP show as record to add as allowed IP if we use the smtp method
|
||||
$text .= ($text ? '<br><br>' : '').$langs->trans("WarningPHPMail2", $conf->global->MAIN_EXTERNAL_SMTP_CLIENT_IP_ADDRESS);
|
||||
}
|
||||
if (!empty($conf->global->MAIN_EXTERNAL_SMTP_SPF_STRING_TO_ADD))
|
||||
if (!empty($conf->global->MAIN_EXTERNAL_SMTP_SPF_STRING_TO_ADD)) // Should be required only if you have set to use your own SMTP and wat to warn users to update their domain name to match your SMTP server.
|
||||
{
|
||||
// List of string to add in SPF if we use the smtp method
|
||||
$text .= ($text ? '<br><br>' : '').$langs->trans("WarningPHPMailSPF", $conf->global->MAIN_EXTERNAL_SMTP_SPF_STRING_TO_ADD);
|
||||
@@ -790,6 +796,7 @@ else
|
||||
// Run the test to connect
|
||||
if ($action == 'testconnect')
|
||||
{
|
||||
print '<div id="formmailaftertstconnect" name="formmailaftertstconnect"></div>';
|
||||
print load_fiche_titre($langs->trans("DoTestServerAvailability"));
|
||||
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
|
||||
@@ -805,6 +812,7 @@ else
|
||||
}
|
||||
|
||||
setEventMessages($errormsg, null, 'errors');
|
||||
print $errormsg;
|
||||
}
|
||||
print '<br>';
|
||||
}
|
||||
|
||||
@@ -155,20 +155,20 @@ $sourceList = array();
|
||||
|
||||
// We save list of template email Dolibarr can manage. This list can found by a grep into code on "->param['models']"
|
||||
$elementList = array();
|
||||
if ($conf->propal->enabled) $elementList['propal_send'] = $langs->trans('MailToSendProposal');
|
||||
if ($conf->commande->enabled) $elementList['order_send'] = $langs->trans('MailToSendOrder');
|
||||
if ($conf->facture->enabled) $elementList['facture_send'] = $langs->trans('MailToSendInvoice');
|
||||
if ($conf->propal->enabled && $user->rights->propal->lire) $elementList['propal_send'] = $langs->trans('MailToSendProposal');
|
||||
if ($conf->commande->enabled && $user->rights->commande->lire) $elementList['order_send'] = $langs->trans('MailToSendOrder');
|
||||
if ($conf->facture->enabled && $user->rights->facture->lire) $elementList['facture_send'] = $langs->trans('MailToSendInvoice');
|
||||
if ($conf->expedition->enabled) $elementList['shipping_send'] = $langs->trans('MailToSendShipment');
|
||||
if ($conf->reception->enabled) $elementList['reception_send'] = $langs->trans('MailToSendReception');
|
||||
if ($conf->ficheinter->enabled) $elementList['fichinter_send'] = $langs->trans('MailToSendIntervention');
|
||||
if ($conf->supplier_proposal->enabled) $elementList['supplier_proposal_send'] = $langs->trans('MailToSendSupplierRequestForQuotation');
|
||||
if ($conf->fournisseur->enabled && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || $conf->supplier_order->enabled) $elementList['order_supplier_send'] = $langs->trans('MailToSendSupplierOrder');
|
||||
if ($conf->fournisseur->enabled && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || $conf->supplier_invoice->enabled) $elementList['invoice_supplier_send'] = $langs->trans('MailToSendSupplierInvoice');
|
||||
if ($conf->societe->enabled) $elementList['thirdparty'] = $langs->trans('MailToThirdparty');
|
||||
if ($conf->adherent->enabled) $elementList['member'] = $langs->trans('MailToMember');
|
||||
if ($conf->contrat->enabled) $elementList['contract'] = $langs->trans('MailToSendContract');
|
||||
if (($conf->fournisseur->enabled && $user->rights->fournisseur->commande->lire && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || ($conf->supplier_order->enabled && $user->rights->supplier_order->lire)) $elementList['order_supplier_send'] = $langs->trans('MailToSendSupplierOrder');
|
||||
if (($conf->fournisseur->enabled && $user->rights->fournisseur->facture->lire && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || ($conf->supplier_invoice->enabled && $user->rights->supplier_invoice->lire)) $elementList['invoice_supplier_send'] = $langs->trans('MailToSendSupplierInvoice');
|
||||
if ($conf->societe->enabled && $user->rights->societe->lire) $elementList['thirdparty'] = $langs->trans('MailToThirdparty');
|
||||
if ($conf->adherent->enabled && $user->rights->adherent->lire) $elementList['member'] = $langs->trans('MailToMember');
|
||||
if ($conf->contrat->enabled && $user->rights->contrat->lire) $elementList['contract'] = $langs->trans('MailToSendContract');
|
||||
if ($conf->projet->enabled) $elementList['project'] = $langs->trans('MailToProject');
|
||||
if ($conf->ticket->enabled) $elementList['ticket_send'] = $langs->trans('MailToTicket');
|
||||
if ($conf->ticket->enabled && $user->rights->ticket->read) $elementList['ticket_send'] = $langs->trans('MailToTicket');
|
||||
$elementList['user'] = $langs->trans('MailToUser');
|
||||
|
||||
$parameters = array('elementList'=>$elementList);
|
||||
@@ -280,7 +280,7 @@ if (empty($reshook))
|
||||
elseif ($keycode == 'content') {
|
||||
$sql .= "'".$db->escape(GETPOST($keycode, 'restricthtml'))."'";
|
||||
}
|
||||
elseif (in_array($keycode, array('joinfile', 'private', 'position', 'scale'))) {
|
||||
elseif (in_array($keycode, array('joinfiles', 'private', 'position', 'scale'))) {
|
||||
$sql .= (int) GETPOST($keycode, 'int');
|
||||
}
|
||||
else {
|
||||
@@ -558,6 +558,7 @@ if (!empty($conf->global->MAIN_EMAIL_TEMPLATES_FOR_OBJECT_LINES)) { $fieldsforco
|
||||
foreach ($fieldsforcontent as $tmpfieldlist)
|
||||
{
|
||||
print '<tr class="impair nodrag nodrop nohover"><td colspan="6" class="nobottom">';
|
||||
|
||||
// Label
|
||||
if ($tmpfieldlist == 'topic')
|
||||
{
|
||||
@@ -571,6 +572,7 @@ foreach ($fieldsforcontent as $tmpfieldlist)
|
||||
print $form->textwithpicto($langs->trans("Content"), $tabhelp[$id][$tmpfieldlist], 1, 'help', '', 0, 2, $tmpfieldlist).'<br>';
|
||||
if ($tmpfieldlist == 'content_lines')
|
||||
print $form->textwithpicto($langs->trans("ContentForLines"), $tabhelp[$id][$tmpfieldlist], 1, 'help', '', 0, 2, $tmpfieldlist).'<br>';
|
||||
|
||||
// Input field
|
||||
if ($tmpfieldlist == 'topic') {
|
||||
print '<input type="text" class="flat minwidth500" name="'.$tmpfieldlist.'" value="'.(!empty($obj->{$tmpfieldlist}) ? $obj->{$tmpfieldlist} : '').'">';
|
||||
@@ -652,33 +654,34 @@ if ($resql)
|
||||
|
||||
// Title line with search boxes
|
||||
print '<tr class="liste_titre">';
|
||||
|
||||
$filterfound = 0;
|
||||
foreach ($fieldlist as $field => $value)
|
||||
{
|
||||
if ($value == 'label') print '<td class="liste_titre"><input type="text" name="search_label" class="maxwidth100" value="'.dol_escape_htmltag($search_label).'"></td>';
|
||||
elseif ($value == 'lang')
|
||||
{
|
||||
if ($value == 'label') {
|
||||
print '<td class="liste_titre"><input type="text" name="search_label" class="maxwidth100" value="'.dol_escape_htmltag($search_label).'"></td>';
|
||||
} elseif ($value == 'lang') {
|
||||
print '<td class="liste_titre">';
|
||||
print $formadmin->select_language($search_lang, 'search_lang', 0, null, 1, 0, 0, 'maxwidth100');
|
||||
print '</td>';
|
||||
}
|
||||
elseif ($value == 'fk_user')
|
||||
{
|
||||
} elseif ($value == 'fk_user') {
|
||||
print '<td class="liste_titre">';
|
||||
$restrictid = array();
|
||||
if (!$user->admin) $restrictid = array($user->id);
|
||||
//var_dump($restrictid);
|
||||
print $form->select_dolusers($search_fk_user, 'search_fk_user', 1, null, 0, 'hierarchyme', null, 0, 0, 1, '', 0, '', 'maxwidth100');
|
||||
print '</td>';
|
||||
}
|
||||
elseif ($value == 'topic') print '<td class="liste_titre"><input type="text" name="search_topic" value="'.dol_escape_htmltag($search_topic).'"></td>';
|
||||
elseif ($value == 'type_template')
|
||||
{
|
||||
} elseif ($value == 'topic') {
|
||||
print '<td class="liste_titre"><input type="text" name="search_topic" value="'.dol_escape_htmltag($search_topic).'"></td>';
|
||||
} elseif ($value == 'type_template') {
|
||||
print '<td class="liste_titre">'.$form->selectarray('search_type_template', $elementList, $search_type_template, 1, 0, 0, '', 0, 0, 0, '', 'maxwidth100 maxwidth100onsmartphone').'</td>';
|
||||
} elseif (!in_array($value, array('content', 'content_lines'))) {
|
||||
print '<td class="liste_titre"></td>';
|
||||
}
|
||||
elseif (!in_array($value, array('content', 'content_lines'))) print '<td class="liste_titre"></td>';
|
||||
}
|
||||
|
||||
if (empty($conf->global->MAIN_EMAIL_TEMPLATES_FOR_OBJECT_LINES)) print '<td class="liste_titre"></td>';
|
||||
|
||||
// Action column
|
||||
print '<td class="liste_titre right" width="64">';
|
||||
$searchpicto = $form->showFilterButtons();
|
||||
|
||||
@@ -153,7 +153,7 @@ print '<form method="post" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="update">';
|
||||
|
||||
dol_fiche_head($head, 'handler', $langs->trans("Menus"), -1);
|
||||
dol_fiche_head($head, 'handler', '', -1);
|
||||
|
||||
print '<span class="opacitymedium">'.$langs->trans("MenusDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
|
||||
@@ -235,7 +235,7 @@ $head[$h][1] = $langs->trans("Miscellaneous");
|
||||
$head[$h][2] = 'misc';
|
||||
$h++;
|
||||
|
||||
dol_fiche_head($head, 'editor', $langs->trans("Menus"), -1);
|
||||
dol_fiche_head($head, 'editor', '', -1);
|
||||
|
||||
print '<span class="opacitymedium">'.$langs->trans("MenusEditorDesc")."</span><br>\n";
|
||||
print "<br>\n";
|
||||
@@ -328,18 +328,18 @@ if ($conf->use_javascript_ajax)
|
||||
$entry = '<table class="nobordernopadding centpercent"><tr><td>';
|
||||
$entry .= '<strong> <a href="edit.php?menu_handler='.$menu_handler_to_search.'&action=edit&menuId='.$menu['rowid'].'">'.$titre.'</a></strong>';
|
||||
$entry .= '</td><td class="right">';
|
||||
$entry .= '<a href="edit.php?menu_handler='.$menu_handler_to_search.'&action=edit&menuId='.$menu['rowid'].'">'.img_edit('default', 0, 'class="menuEdit" id="edit'.$menu['rowid'].'"').'</a> ';
|
||||
$entry .= '<a href="edit.php?menu_handler='.$menu_handler_to_search.'&action=create&menuId='.$menu['rowid'].'">'.img_edit_add('default').'</a> ';
|
||||
$entry .= '<a href="index.php?menu_handler='.$menu_handler_to_search.'&action=delete&menuId='.$menu['rowid'].'">'.img_delete('default').'</a> ';
|
||||
$entry .= '<a class="editfielda marginleftonly marginrightonly" href="edit.php?menu_handler='.$menu_handler_to_search.'&action=edit&menuId='.$menu['rowid'].'">'.img_edit('default', 0, 'class="menuEdit" id="edit'.$menu['rowid'].'"').'</a> ';
|
||||
$entry .= '<a class="marginleftonly marginrightonly" href="edit.php?menu_handler='.$menu_handler_to_search.'&action=create&menuId='.$menu['rowid'].'">'.img_edit_add('default').'</a> ';
|
||||
$entry .= '<a class="marginleftonly marginrightonly" href="index.php?menu_handler='.$menu_handler_to_search.'&action=delete&menuId='.$menu['rowid'].'">'.img_delete('default').'</a> ';
|
||||
$entry .= ' ';
|
||||
$entry .= '<a href="index.php?menu_handler='.$menu_handler_to_search.'&action=up&menuId='.$menu['rowid'].'">'.img_picto("Up", "1uparrow").'</a><a href="index.php?menu_handler='.$menu_handler_to_search.'&action=down&menuId='.$menu['rowid'].'">'.img_picto("Down", "1downarrow").'</a>';
|
||||
$entry .= '<a class="marginleftonly marginrightonly" href="index.php?menu_handler='.$menu_handler_to_search.'&action=up&menuId='.$menu['rowid'].'">'.img_picto("Up", "1uparrow").'</a><a href="index.php?menu_handler='.$menu_handler_to_search.'&action=down&menuId='.$menu['rowid'].'">'.img_picto("Down", "1downarrow").'</a>';
|
||||
$entry .= '</td></tr></table>';
|
||||
|
||||
$buttons = '<a href="edit.php?menu_handler='.$menu_handler_to_search.'&action=edit&menuId='.$menu['rowid'].'">'.img_edit('default', 0, 'class="menuEdit" id="edit'.$menu['rowid'].'"').'</a> ';
|
||||
$buttons .= '<a href="edit.php?menu_handler='.$menu_handler_to_search.'&action=create&menuId='.$menu['rowid'].'">'.img_edit_add('default').'</a> ';
|
||||
$buttons .= '<a href="index.php?menu_handler='.$menu_handler_to_search.'&action=delete&menuId='.$menu['rowid'].'">'.img_delete('default').'</a> ';
|
||||
$buttons = '<a class="editfielda marginleftonly marginrightonly" href="edit.php?menu_handler='.$menu_handler_to_search.'&action=edit&menuId='.$menu['rowid'].'">'.img_edit('default', 0, 'class="menuEdit" id="edit'.$menu['rowid'].'"').'</a> ';
|
||||
$buttons .= '<a class="marginleftonly marginrightonly" href="edit.php?menu_handler='.$menu_handler_to_search.'&action=create&menuId='.$menu['rowid'].'">'.img_edit_add('default').'</a> ';
|
||||
$buttons .= '<a class="marginleftonly marginrightonly" href="index.php?menu_handler='.$menu_handler_to_search.'&action=delete&menuId='.$menu['rowid'].'">'.img_delete('default').'</a> ';
|
||||
$buttons .= ' ';
|
||||
$buttons .= '<a href="index.php?menu_handler='.$menu_handler_to_search.'&action=up&menuId='.$menu['rowid'].'">'.img_picto("Up", "1uparrow").'</a><a href="index.php?menu_handler='.$menu_handler_to_search.'&action=down&menuId='.$menu['rowid'].'">'.img_picto("Down", "1downarrow").'</a>';
|
||||
$buttons .= '<a class="marginleftonly marginrightonly" href="index.php?menu_handler='.$menu_handler_to_search.'&action=up&menuId='.$menu['rowid'].'">'.img_picto("Up", "1uparrow").'</a><a href="index.php?menu_handler='.$menu_handler_to_search.'&action=down&menuId='.$menu['rowid'].'">'.img_picto("Down", "1downarrow").'</a>';
|
||||
|
||||
$data[] = array(
|
||||
'rowid'=>$menu['rowid'],
|
||||
|
||||
@@ -76,7 +76,7 @@ $head[$h][1] = $langs->trans("Miscellaneous");
|
||||
$head[$h][2] = 'misc';
|
||||
$h++;
|
||||
|
||||
dol_fiche_head($head, 'misc', $langs->trans("Menus"), -1);
|
||||
dol_fiche_head($head, 'misc', '', -1);
|
||||
|
||||
|
||||
// Other Options
|
||||
|
||||
@@ -272,7 +272,7 @@ print '<div class="centpercent">';
|
||||
|
||||
$picto = 'object_'.$objMod->picto;
|
||||
|
||||
print load_fiche_titre(($modulename ? $modulename : $moduledesc), $moreinfo, $picto);
|
||||
print load_fiche_titre(($modulename ? $modulename : $moduledesc), $moreinfo, $picto, 0, '', 'titlemodulehelp');
|
||||
print '<br>';
|
||||
|
||||
dol_fiche_head($head, $mode, '', -1);
|
||||
|
||||
@@ -38,7 +38,7 @@ require_once DOL_DOCUMENT_ROOT.'/admin/dolistore/class/dolistore.class.php';
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("errors", "admin", "modulebuilder"));
|
||||
|
||||
$mode = GETPOSTISSET('mode') ? GETPOST('mode', 'alpha') : 'commonkanban';
|
||||
$mode = GETPOSTISSET('mode') ? GETPOST('mode', 'alpha') : (empty($conf->global->MAIN_MODULE_SETUP_ON_LIST_BY_DEFAULT) ? 'commonkanban' : 'common');
|
||||
if (empty($mode)) $mode = 'common';
|
||||
$action = GETPOST('action', 'alpha');
|
||||
//var_dump($_POST);exit;
|
||||
|
||||
113
htdocs/admin/mrp_extrafields.php
Normal file
113
htdocs/admin/mrp_extrafields.php
Normal file
@@ -0,0 +1,113 @@
|
||||
<?php
|
||||
/* Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2012 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/admin/mrp_extrafields.php
|
||||
* \ingroup mrp
|
||||
* \brief Page to setup extra fields of MOs
|
||||
*/
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/mrp/lib/mrp.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('mrp', 'admin'));
|
||||
|
||||
$extrafields = new ExtraFields($db);
|
||||
$form = new Form($db);
|
||||
|
||||
// List of supported format
|
||||
$tmptype2label = ExtraFields::$type2label;
|
||||
$type2label = array('');
|
||||
foreach ($tmptype2label as $key => $val) $type2label[$key] = $langs->transnoentitiesnoconv($val);
|
||||
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$attrname = GETPOST('attrname', 'alpha');
|
||||
$elementtype = 'mrp_mo';
|
||||
|
||||
if (!$user->admin) accessforbidden();
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
*/
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/actions_extrafields.inc.php';
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
|
||||
llxHeader('', $langs->trans("MrpSetupPage"), $help_url);
|
||||
|
||||
|
||||
$linkback = '<a href="'.DOL_URL_ROOT.'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans("BackToModuleList").'</a>';
|
||||
print load_fiche_titre($langs->trans("MrpSetupPage"), $linkback, 'title_setup');
|
||||
|
||||
|
||||
$head = mrpAdminPrepareHead(null);
|
||||
|
||||
dol_fiche_head($head, 'mrp_extrafields', $langs->trans("ExtraFields"), -1, 'account');
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
|
||||
// Buttons
|
||||
if ($action != 'create' && $action != 'edit')
|
||||
{
|
||||
print '<div class="tabsAction">';
|
||||
print "<a class=\"butAction\" href=\"".$_SERVER["PHP_SELF"]."?action=create#newattrib\">".$langs->trans("NewAttribute")."</a>";
|
||||
print "</div>";
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Creation of an optional field
|
||||
*/
|
||||
if ($action == 'create')
|
||||
{
|
||||
print '<br><div id="newattrib"></div>';
|
||||
print load_fiche_titre($langs->trans('NewAttribute'));
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_add.tpl.php';
|
||||
}
|
||||
|
||||
/*
|
||||
* Edition of an optional field
|
||||
*/
|
||||
if ($action == 'edit' && !empty($attrname))
|
||||
{
|
||||
print "<br>";
|
||||
print load_fiche_titre($langs->trans("FieldEdition", $attrname));
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php';
|
||||
}
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
@@ -57,6 +57,7 @@ if (($action == 'update' && !GETPOST("cancel", 'alpha'))
|
||||
|
||||
if ($action != 'updateedit' && !$error)
|
||||
{
|
||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
||||
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||
exit;
|
||||
}
|
||||
|
||||
@@ -39,6 +39,8 @@ if (!$user->admin) accessforbidden();
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$type = 'paymentorder';
|
||||
|
||||
$error = 0;
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
@@ -74,35 +76,28 @@ if ($action == "set")
|
||||
else $error++;
|
||||
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_ICS", GETPOST("PRELEVEMENT_ICS"), 'chaine', 0, '', $conf->entity);
|
||||
if (!$res > 0) $error++;
|
||||
if (! ($res > 0)) $error++;
|
||||
|
||||
if (GETPOST("PRELEVEMENT_USER") > 0)
|
||||
{
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_USER", GETPOST("PRELEVEMENT_USER"), 'chaine', 0, '', $conf->entity);
|
||||
if (!$res > 0) $error++;
|
||||
}
|
||||
if (GETPOST("PRELEVEMENT_END_TO_END") || GETPOST("PRELEVEMENT_END_TO_END") == "")
|
||||
{
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_END_TO_END", GETPOST("PRELEVEMENT_END_TO_END"), 'chaine', 0, '', $conf->entity);
|
||||
if (!$res > 0) $error++;
|
||||
}
|
||||
if (GETPOST("PRELEVEMENT_USTRD") || GETPOST("PRELEVEMENT_USTRD") == "")
|
||||
{
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_USTRD", GETPOST("PRELEVEMENT_USTRD"), 'chaine', 0, '', $conf->entity);
|
||||
if (!$res > 0) $error++;
|
||||
}
|
||||
if (GETPOST("PRELEVEMENT_USER") > 0) {
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_USER", GETPOST("PRELEVEMENT_USER"), 'chaine', 0, '', $conf->entity);
|
||||
if (! ($res > 0)) $error++;
|
||||
}
|
||||
if (GETPOST("PRELEVEMENT_END_TO_END") || GETPOST("PRELEVEMENT_END_TO_END") == "") {
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_END_TO_END", GETPOST("PRELEVEMENT_END_TO_END"), 'chaine', 0, '', $conf->entity);
|
||||
if (! ($res > 0)) $error++;
|
||||
}
|
||||
if (GETPOST("PRELEVEMENT_USTRD") || GETPOST("PRELEVEMENT_USTRD") == "") {
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_USTRD", GETPOST("PRELEVEMENT_USTRD"), 'chaine', 0, '', $conf->entity);
|
||||
if (! ($res > 0)) $error++;
|
||||
}
|
||||
|
||||
if (GETPOST("PRELEVEMENT_ADDDAYS") || GETPOST("PRELEVEMENT_ADDDAYS") == "")
|
||||
{
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_ADDDAYS", GETPOST("PRELEVEMENT_ADDDAYS"), 'chaine', 0, '', $conf->entity);
|
||||
if (!$res > 0) $error++;
|
||||
} elseif (!$error)
|
||||
{
|
||||
$res = dolibarr_set_const($db, "PRELEVEMENT_ADDDAYS", GETPOST("PRELEVEMENT_ADDDAYS"), 'chaine', 0, '', $conf->entity);
|
||||
if (! ($res > 0)) $error++;
|
||||
|
||||
if (! $error) {
|
||||
$db->commit();
|
||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
$db->rollback();
|
||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
||||
}
|
||||
@@ -196,9 +191,10 @@ print '</td></tr>';
|
||||
//ADDDAYS
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("ADDDAYS").'</td>';
|
||||
print '<td class="left">';
|
||||
if (!$conf->global->PRELEVEMENT_ADDDAYS) $conf->global->PRELEVEMENT_ADDDAYS = 0;
|
||||
if (empty($conf->global->PRELEVEMENT_ADDDAYS)) $conf->global->PRELEVEMENT_ADDDAYS = 0;
|
||||
print '<input type="text" name="PRELEVEMENT_ADDDAYS" value="'.$conf->global->PRELEVEMENT_ADDDAYS.'" size="5" ></td>';
|
||||
print '</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
print '<br>';
|
||||
|
||||
|
||||
@@ -65,13 +65,13 @@ if (!function_exists('gzdecode')) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Action
|
||||
*/
|
||||
|
||||
if ($action == 'addprinter' && $user->admin) {
|
||||
$error = 0;
|
||||
$db->begin();
|
||||
if (empty($printername)) {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("PrinterNameEmpty"), null, 'errors');
|
||||
@@ -82,7 +82,8 @@ if ($action == 'addprinter' && $user->admin) {
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$result = $printer->addPrinter($printername, GETPOST('printertypeid', 'int'), GETPOST('printerprofileid', 'int'), $parameter);
|
||||
$db->begin();
|
||||
$result = $printer->addPrinter($printername, GETPOST('printertypeid', 'int'), GETPOST('printerprofileid', 'int'), $parameter);
|
||||
if ($result > 0) $error++;
|
||||
|
||||
if (!$error)
|
||||
@@ -101,14 +102,14 @@ if ($action == 'addprinter' && $user->admin) {
|
||||
|
||||
if ($action == 'deleteprinter' && $user->admin) {
|
||||
$error = 0;
|
||||
$db->begin();
|
||||
if (empty($printerid)) {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("PrinterIdEmpty"), null, 'errors');
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$result = $printer->deletePrinter($printerid);
|
||||
$db->begin();
|
||||
$result = $printer->deletePrinter($printerid);
|
||||
if ($result > 0) $error++;
|
||||
|
||||
if (!$error)
|
||||
@@ -127,14 +128,14 @@ if ($action == 'deleteprinter' && $user->admin) {
|
||||
|
||||
if ($action == 'updateprinter' && $user->admin) {
|
||||
$error = 0;
|
||||
$db->begin();
|
||||
if (empty($printerid)) {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("PrinterIdEmpty"), null, 'errors');
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$result = $printer->updatePrinter($printername, GETPOST('printertypeid', 'int'), GETPOST('printerprofileid', 'int'), $parameter, $printerid);
|
||||
$db->begin();
|
||||
$result = $printer->updatePrinter($printername, GETPOST('printertypeid', 'int'), GETPOST('printerprofileid', 'int'), $parameter, $printerid);
|
||||
if ($result > 0) $error++;
|
||||
|
||||
if (!$error) {
|
||||
@@ -193,14 +194,14 @@ if ($action == 'testtemplate' && $user->admin) {
|
||||
|
||||
if ($action == 'updatetemplate' && $user->admin) {
|
||||
$error = 0;
|
||||
$db->begin();
|
||||
if (empty($templateid)) {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("TemplateIdEmpty"), null, 'errors');
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$result = $printer->updateTemplate($templatename, $template, $templateid);
|
||||
$db->begin();
|
||||
$result = $printer->updateTemplate($templatename, $template, $templateid);
|
||||
if ($result > 0) $error++;
|
||||
|
||||
if (!$error) {
|
||||
@@ -216,14 +217,14 @@ if ($action == 'updatetemplate' && $user->admin) {
|
||||
|
||||
if ($action == 'addtemplate' && $user->admin) {
|
||||
$error = 0;
|
||||
$db->begin();
|
||||
if (empty($templatename)) {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("TemplateNameEmpty"), null, 'errors');
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$result = $printer->addTemplate($templatename, $template);
|
||||
$db->begin();
|
||||
$result = $printer->addTemplate($templatename, $template);
|
||||
if ($result > 0) $error++;
|
||||
|
||||
if (!$error) {
|
||||
@@ -237,6 +238,29 @@ if ($action == 'addtemplate' && $user->admin) {
|
||||
$action = '';
|
||||
}
|
||||
|
||||
if ($action == 'deletetemplate' && $user->admin) {
|
||||
$error = 0;
|
||||
if (empty($templateid)) {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("TemplateIdEmpty"), null, 'errors');
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$db->begin();
|
||||
$result = $printer->deleteTemplate($templateid);
|
||||
if ($result > 0) $error++;
|
||||
|
||||
if (!$error) {
|
||||
$db->commit();
|
||||
setEventMessages($langs->trans("TemplateDeleted", $templatename), null);
|
||||
} else {
|
||||
$db->rollback();
|
||||
dol_print_error($db);
|
||||
}
|
||||
}
|
||||
$action = '';
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
@@ -251,6 +275,7 @@ print load_fiche_titre($langs->trans("ReceiptPrinterSetup"), $linkback, 'title_s
|
||||
|
||||
$head = receiptprinteradmin_prepare_head($mode);
|
||||
|
||||
// mode = config
|
||||
if ($mode == 'config' && $user->admin) {
|
||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?mode=config" autocomplete="off">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
@@ -263,7 +288,7 @@ if ($mode == 'config' && $user->admin) {
|
||||
|
||||
dol_fiche_head($head, $mode, $langs->trans("ModuleSetup"), -1, 'technic');
|
||||
|
||||
print $langs->trans("ReceiptPrinterDesc")."<br><br>\n";
|
||||
print '<span class="opacitymedium">'.$langs->trans("ReceiptPrinterDesc")."</span><br><br>\n";
|
||||
|
||||
print '<table class="noborder centpercent">'."\n";
|
||||
print '<tr class="liste_titre">';
|
||||
@@ -276,6 +301,22 @@ if ($mode == 'config' && $user->admin) {
|
||||
$ret = $printer->listprinters();
|
||||
$nbofprinters = count($printer->listprinters);
|
||||
|
||||
if ($action != 'editprinter') {
|
||||
print '<tr>';
|
||||
print '<td><input size="50" type="text" name="printername"></td>';
|
||||
$ret = $printer->selectTypePrinter();
|
||||
print '<td>'.$printer->resprint.'</td>';
|
||||
$ret = $printer->selectProfilePrinter();
|
||||
print '<td>'.$printer->profileresprint.'</td>';
|
||||
print '<td><input size="60" type="text" name="parameter"></td>';
|
||||
print '<td class="right">';
|
||||
if ($action != 'editprinter') {
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Add")).'"></div>';
|
||||
}
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
if ($ret > 0) {
|
||||
setEventMessages($printer->error, $printer->errors, 'errors');
|
||||
} else {
|
||||
@@ -289,7 +330,9 @@ if ($mode == 'config' && $user->admin) {
|
||||
$ret = $printer->selectProfilePrinter($printer->listprinters[$line]['fk_profile']);
|
||||
print '<td>'.$printer->profileresprint.'</td>';
|
||||
print '<td><input size="60" type="text" name="parameter" value="'.$printer->listprinters[$line]['parameter'].'"></td>';
|
||||
print '<td></td>';
|
||||
print '<td>';
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Save")).'"></div>';
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
} else {
|
||||
print '<td>'.$printer->listprinters[$line]['name'].'</td>';
|
||||
@@ -297,15 +340,15 @@ if ($mode == 'config' && $user->admin) {
|
||||
print '<td>'.$langs->trans($printer->listprinters[$line]['fk_profile_name']).'</td>';
|
||||
print '<td>'.$printer->listprinters[$line]['parameter'].'</td>';
|
||||
// edit icon
|
||||
print '<td><a href="'.$_SERVER['PHP_SELF'].'?mode=config&action=editprinter&printerid='.$printer->listprinters[$line]['rowid'].'">';
|
||||
print '<td class="right"><a class="editfielda marginrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=config&action=editprinter&printerid='.$printer->listprinters[$line]['rowid'].'">';
|
||||
print img_picto($langs->trans("Edit"), 'edit');
|
||||
print '</a>';
|
||||
// delete icon
|
||||
print '<a href="'.$_SERVER['PHP_SELF'].'?mode=config&action=deleteprinter&printerid='.$printer->listprinters[$line]['rowid'].'&printername='.$printer->listprinters[$line]['name'].'">';
|
||||
print '<a class="marginrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=config&action=deleteprinter&printerid='.$printer->listprinters[$line]['rowid'].'&printername='.$printer->listprinters[$line]['name'].'">';
|
||||
print img_picto($langs->trans("Delete"), 'delete');
|
||||
print '</a>';
|
||||
// test icon
|
||||
print '<a href="'.$_SERVER['PHP_SELF'].'?mode=config&action=testprinter&printerid='.$printer->listprinters[$line]['rowid'].'&printername='.$printer->listprinters[$line]['name'].'">';
|
||||
print '<a class="marginrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=config&action=testprinter&printerid='.$printer->listprinters[$line]['rowid'].'&printername='.$printer->listprinters[$line]['name'].'">';
|
||||
print img_picto($langs->trans("TestPrinter"), 'printer');
|
||||
print '</a></td>';
|
||||
print '</tr>';
|
||||
@@ -313,38 +356,10 @@ if ($mode == 'config' && $user->admin) {
|
||||
}
|
||||
}
|
||||
|
||||
if ($action != 'editprinter') {
|
||||
if ($nbofprinters > 0) {
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th>'.$langs->trans("Name").'</th>';
|
||||
print '<th>'.$langs->trans("Type").'</th>';
|
||||
print '<th>'.$langs->trans("Profile").'</th>';
|
||||
print '<th>'.$langs->trans("Parameters").'</th>';
|
||||
print '<th></th>';
|
||||
print "</tr>\n";
|
||||
}
|
||||
|
||||
print '<tr>';
|
||||
print '<td><input size="50" type="text" name="printername"></td>';
|
||||
$ret = $printer->selectTypePrinter();
|
||||
print '<td>'.$printer->resprint.'</td>';
|
||||
$ret = $printer->selectProfilePrinter();
|
||||
print '<td>'.$printer->profileresprint.'</td>';
|
||||
print '<td><input size="60" type="text" name="parameter"></td>';
|
||||
print '<td></td>';
|
||||
print '<td></td>';
|
||||
print '<td></td>';
|
||||
print '</tr>';
|
||||
}
|
||||
print '</table>';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
if ($action != 'editprinter') {
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Add")).'"></div>';
|
||||
} else {
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Save")).'"></div>';
|
||||
}
|
||||
print '</form>';
|
||||
|
||||
print '<br>';
|
||||
@@ -374,8 +389,11 @@ if ($mode == 'config' && $user->admin) {
|
||||
print '</table>';
|
||||
}
|
||||
|
||||
// mode = template
|
||||
if ($mode == 'template' && $user->admin) {
|
||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?mode=template" autocomplete="off">';
|
||||
dol_fiche_head($head, $mode, $langs->trans("ModuleSetup"), -1, 'technic');
|
||||
|
||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?mode=template" autocomplete="off">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
if ($action != 'edittemplate') {
|
||||
print '<input type="hidden" name="action" value="addtemplate">';
|
||||
@@ -383,16 +401,11 @@ if ($mode == 'template' && $user->admin) {
|
||||
print '<input type="hidden" name="action" value="updatetemplate">';
|
||||
}
|
||||
|
||||
|
||||
print load_fiche_titre($langs->trans("ReceiptPrinterTemplateDesc"), '', '')."<br><br>\n";
|
||||
|
||||
print '<table class="noborder centpercent">'."\n";
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th>'.$langs->trans("Name").'</th>';
|
||||
print '<th>'.$langs->trans("Template").'</th>';
|
||||
print '<th></th>';
|
||||
print '<th></th>';
|
||||
print '<th></th>';
|
||||
print "</tr>\n";
|
||||
$ret = $printer->listPrintersTemplates();
|
||||
//print '<pre>'.print_r($printer->listprinterstemplates, true).'</pre>';
|
||||
@@ -405,22 +418,23 @@ if ($mode == 'template' && $user->admin) {
|
||||
if ($action == 'edittemplate' && $printer->listprinterstemplates[$line]['rowid'] == $templateid) {
|
||||
print '<input type="hidden" name="templateid" value="'.$printer->listprinterstemplates[$line]['rowid'].'">';
|
||||
print '<td><input size="50" type="text" name="templatename" value="'.$printer->listprinterstemplates[$line]['name'].'"></td>';
|
||||
print '<td><textarea name="template" wrap="soft" cols="120" rows="12">'.$printer->listprinterstemplates[$line]['template'].'</textarea>';
|
||||
print '<td>';
|
||||
print '<textarea name="template" wrap="soft" cols="120" rows="12">'.$printer->listprinterstemplates[$line]['template'].'</textarea>';
|
||||
print '</td>';
|
||||
print '<td></td>';
|
||||
} else {
|
||||
print '<td>'.$printer->listprinterstemplates[$line]['name'].'</td>';
|
||||
print '<td>'.nl2br(htmlentities($printer->listprinterstemplates[$line]['template'])).'</td>';
|
||||
// edit icon
|
||||
print '<td><a class="editfielda paddingleftonly paddingrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=template&action=edittemplate&templateid='.$printer->listprinterstemplates[$line]['rowid'].'">';
|
||||
print '<td><a class="editfielda paddingleftonly marginrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=template&action=edittemplate&templateid='.$printer->listprinterstemplates[$line]['rowid'].'">';
|
||||
print img_picto($langs->trans("Edit"), 'edit');
|
||||
print '</a>';
|
||||
// delete icon
|
||||
print '<a class="paddingleftonly paddingrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=template&action=deletetemplate&templateid='.$printer->listprinterstemplates[$line]['rowid'].'&templatename='.$printer->listprinterstemplates[$line]['name'].'">';
|
||||
print '<a class="paddingleftonly marginrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=template&action=deletetemplate&templateid='.$printer->listprinterstemplates[$line]['rowid'].'&templatename='.$printer->listprinterstemplates[$line]['name'].'">';
|
||||
print img_picto($langs->trans("Delete"), 'delete');
|
||||
print '</a>';
|
||||
// test icon
|
||||
print '<a class="paddingleftonly paddingrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=template&action=testtemplate&templateid='.$printer->listprinterstemplates[$line]['rowid'].'&templatename='.$printer->listprinterstemplates[$line]['name'].'">';
|
||||
print '<a class="paddingleftonly marginrightonly" href="'.$_SERVER['PHP_SELF'].'?mode=template&action=testtemplate&templateid='.$printer->listprinterstemplates[$line]['rowid'].'&templatename='.$printer->listprinterstemplates[$line]['name'].'">';
|
||||
print img_picto($langs->trans("TestPrinterTemplate"), 'printer');
|
||||
print '</a></td>';
|
||||
}
|
||||
@@ -428,20 +442,30 @@ if ($mode == 'template' && $user->admin) {
|
||||
}
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
if ($action != 'edittemplate') {
|
||||
print '<input type="hidden" name="templateid" value="'.$printer->listprinterstemplates[$line]['rowid'].'">';
|
||||
print '<tr>';
|
||||
print '<td><input size="50" type="text" name="templatename" value="'.$printer->listprinterstemplates[$line]['name'].'"></td>';
|
||||
print '<td><textarea name="template" wrap="soft" cols="120" rows="12">'.$printer->listprinterstemplates[$line]['template'].'</textarea>';
|
||||
print '<td>';
|
||||
print '<textarea name="template" wrap="soft" cols="120" rows="12">';
|
||||
print GETPOSTISSET('template') ? GETPOST('template', 'alpha') : $printer->listprinterstemplates[$line]['template'];
|
||||
print '</textarea>';
|
||||
print '</td>';
|
||||
print '<td></td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Add")).'"></div>';
|
||||
print '</table>';
|
||||
|
||||
if ($action != 'edittemplate') {
|
||||
print '<input type="hidden" name="templateid" value="'.$printer->listprinterstemplates[$line]['rowid'].'">';
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Add")).'"></div>';
|
||||
} else {
|
||||
print '<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("Save")).'"></div>';
|
||||
}
|
||||
print '</form>';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
print '<br>';
|
||||
|
||||
print '<table class="noborder centpercent">'."\n";
|
||||
|
||||
@@ -28,7 +28,7 @@ require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/ajax.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/resource.lib.php';
|
||||
if (!empty($conf->resouce->enabled)) require_once DOL_DOCUMENT_ROOT.'/resource/class/html.formresource.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/resource/class/html.formresource.class.php';
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("admin", "resource"));
|
||||
|
||||
@@ -310,7 +310,7 @@ else
|
||||
$formsms->withfromreadonly = 0;
|
||||
$formsms->withsubstit = 0;
|
||||
$formsms->withfrom = 1;
|
||||
$formsms->withto = (isset($_POST['sendto']) ? $_POST['sendto'] : $user->user_mobile ? $user->user_mobile : 1);
|
||||
$formsms->withto = (isset($_POST['sendto']) ? $_POST['sendto'] : ($user->user_mobile ? $user->user_mobile : 1));
|
||||
$formsms->withbody = (isset($_POST['message']) ? (empty($_POST['message']) ? 1 : $_POST['message']) : $langs->trans("ThisIsATestMessage"));
|
||||
$formsms->withbodyreadonly = 0;
|
||||
$formsms->withcancel = 1;
|
||||
|
||||
@@ -41,12 +41,31 @@ $action = GETPOST('action', 'alpha');
|
||||
/*
|
||||
* Action
|
||||
*/
|
||||
|
||||
$reg = array();
|
||||
|
||||
if (preg_match('/set_([a-z0-9_\-]+)/i', $action, $reg))
|
||||
{
|
||||
$code = $reg[1];
|
||||
|
||||
// If constant is for a unique choice, delete other choices
|
||||
if (in_array($code, array('STOCK_CALCULATE_ON_BILL', 'STOCK_CALCULATE_ON_VALIDATE_ORDER', 'STOCK_CALCULATE_ON_SHIPMENT', 'STOCK_CALCULATE_ON_SHIPMENT_CLOSE'))) {
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_BILL', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_VALIDATE_ORDER', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_SHIPMENT', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_SHIPMENT_CLOSE', $conf->entity);
|
||||
}
|
||||
if (in_array($code, array('STOCK_CALCULATE_ON_SUPPLIER_BILL', 'STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER', 'STOCK_CALCULATE_ON_RECEPTION', 'STOCK_CALCULATE_ON_RECEPTION_CLOSE', 'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER'))) {
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_SUPPLIER_BILL', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_RECEPTION', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_RECEPTION_CLOSE', $conf->entity);
|
||||
dolibarr_del_const($db, 'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER', $conf->entity);
|
||||
}
|
||||
|
||||
if (dolibarr_set_const($db, $code, 1, 'chaine', 0, '', $conf->entity) > 0)
|
||||
{
|
||||
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||
exit;
|
||||
}
|
||||
else
|
||||
@@ -114,7 +133,7 @@ print '<td class="right">';
|
||||
if (!empty($conf->facture->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_BILL');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_BILL', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_BILL", $arrval, $conf->global->STOCK_CALCULATE_ON_BILL);
|
||||
@@ -134,7 +153,7 @@ print '<td class="right">';
|
||||
if (!empty($conf->commande->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_VALIDATE_ORDER');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_VALIDATE_ORDER', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_VALIDATE_ORDER", $arrval, $conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER);
|
||||
@@ -156,7 +175,7 @@ print '<td class="right">';
|
||||
if (!empty($conf->expedition->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SHIPMENT');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SHIPMENT', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_SHIPMENT", $arrval, $conf->global->STOCK_CALCULATE_ON_SHIPMENT);
|
||||
@@ -176,7 +195,7 @@ print '<td class="right">';
|
||||
if (!empty($conf->expedition->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SHIPMENT_CLOSE');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SHIPMENT_CLOSE', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_SHIPMENT_CLOSE", $arrval, $conf->global->STOCK_CALCULATE_ON_SHIPMENT_CLOSE);
|
||||
@@ -189,18 +208,12 @@ else
|
||||
print "</td>\n</tr>\n";
|
||||
$found++;
|
||||
|
||||
/*if (! $found)
|
||||
{
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td colspan="2">'.$langs->trans("NoModuleToManageStockDecrease").'</td>';
|
||||
print "</tr>\n";
|
||||
}*/
|
||||
|
||||
print '</table>';
|
||||
|
||||
|
||||
print '<br>';
|
||||
|
||||
|
||||
// Title rule for stock increase
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
@@ -216,7 +229,7 @@ print '<td class="right">';
|
||||
if (!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_BILL');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_BILL', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_SUPPLIER_BILL", $arrval, $conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL);
|
||||
@@ -237,7 +250,7 @@ print '<td class="right">';
|
||||
if (!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER", $arrval, $conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER);
|
||||
@@ -257,7 +270,7 @@ if (!empty($conf->reception->enabled))
|
||||
print '<td class="right">';
|
||||
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_RECEPTION');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_RECEPTION', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_RECEPTION", $arrval, $conf->global->STOCK_CALCULATE_ON_RECEPTION);
|
||||
@@ -272,7 +285,7 @@ if (!empty($conf->reception->enabled))
|
||||
print '<td class="right">';
|
||||
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_RECEPTION_CLOSE');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_RECEPTION_CLOSE', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_RECEPTION_CLOSE", $arrval, $conf->global->STOCK_CALCULATE_ON_RECEPTION_CLOSE);
|
||||
@@ -288,7 +301,7 @@ else
|
||||
if (!empty($conf->fournisseur->enabled))
|
||||
{
|
||||
if ($conf->use_javascript_ajax) {
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER');
|
||||
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER', array(), null, 0, 0, 0, 2, 1);
|
||||
} else {
|
||||
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||
print $form->selectarray("STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER", $arrval, $conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER);
|
||||
|
||||
@@ -28,21 +28,27 @@ require '../../main.inc.php';
|
||||
|
||||
$langs->load("admin");
|
||||
|
||||
if (!$user->admin)
|
||||
if (!$user->admin) {
|
||||
accessforbidden();
|
||||
}
|
||||
|
||||
$action = GETPOST('action', 'alpha');
|
||||
|
||||
|
||||
if ($action == 'convert')
|
||||
{
|
||||
$sql = "ALTER TABLE ".$db->escape(GETPOST("table", "aZ09"))." ENGINE=INNODB";
|
||||
$sql = "ALTER TABLE ".$db->escape(GETPOST("table", "aZ09"))." ENGINE=INNODB";
|
||||
$db->query($sql);
|
||||
}
|
||||
if ($action == 'convertutf8')
|
||||
{
|
||||
$sql = "ALTER TABLE ".$db->escape(GETPOST("table", "aZ09"))." CHARACTER SET utf8 COLLATE utf8_unicode_ci";
|
||||
$db->query($sql);
|
||||
$sql = "ALTER TABLE ".$db->escape(GETPOST("table", "aZ09"))." CHARACTER SET utf8 COLLATE utf8_unicode_ci";
|
||||
$db->query($sql);
|
||||
}
|
||||
if ($action == 'convertdynamic')
|
||||
{
|
||||
$sql = "ALTER TABLE ".$db->escape(GETPOST("table", "aZ09"))." ROW_FORMAT=DYNAMIC;";
|
||||
$db->query($sql);
|
||||
}
|
||||
|
||||
|
||||
@@ -87,8 +93,8 @@ else
|
||||
{
|
||||
if ($base == 1)
|
||||
{
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("TableName").'</td>';
|
||||
print '<td colspan="2">'.$langs->trans("Type").'</td>';
|
||||
@@ -119,13 +125,19 @@ else
|
||||
print '<td>'.$obj->Engine.'</td>';
|
||||
if (isset($obj->Engine) && $obj->Engine == "MyISAM")
|
||||
{
|
||||
print '<td><a class="reposition" href="database-tables.php?action=convert&table='.$obj->Name.'">'.$langs->trans("Convert").' InnoDB</a></td>';
|
||||
print '<td><a class="reposition" href="database-tables.php?action=convert&table='.$obj->Name.'">'.$langs->trans("Convert").' InnoDb</a></td>';
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<td> </td>';
|
||||
}
|
||||
print '<td>'.$obj->Row_format.'</td>';
|
||||
print '<td>';
|
||||
print $obj->Row_format;
|
||||
if (isset($obj->Row_format) && (in_array($obj->Row_format, array("Compact"))))
|
||||
{
|
||||
print '<br><a class="reposition" href="database-tables.php?action=convertdynamic&table='.$obj->Name.'">'.$langs->trans("Convert").' Dynamic</a>';
|
||||
}
|
||||
print '</td>';
|
||||
print '<td align="right">'.$obj->Rows.'</td>';
|
||||
print '<td align="right">'.$obj->Avg_row_length.'</td>';
|
||||
print '<td align="right">'.$obj->Data_length.'</td>';
|
||||
@@ -136,7 +148,7 @@ else
|
||||
print '<td align="right">'.$obj->Collation;
|
||||
if (isset($obj->Collation) && (in_array($obj->Collation, array("utf8mb4_general_ci", "utf8mb4_unicode_ci", "latin1_swedish_ci"))))
|
||||
{
|
||||
print '<br><a class="reposition" href="database-tables.php?action=convertutf8&table='.$obj->Name.'">'.$langs->trans("Convert").' UTF8</a>';
|
||||
print '<br><a class="reposition" href="database-tables.php?action=convertutf8&table='.$obj->Name.'">'.$langs->trans("Convert").' UTF8</a>';
|
||||
}
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
@@ -149,8 +161,8 @@ else
|
||||
|
||||
if ($base == 2)
|
||||
{
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("TableName").'</td>';
|
||||
print '<td>Nb of tuples</td>';
|
||||
@@ -189,8 +201,8 @@ else
|
||||
if ($base == 4)
|
||||
{
|
||||
// Sqlite by PDO or by Sqlite3
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("TableName").'</td>';
|
||||
print '<td>'.$langs->trans("NbOfRecord").'</td>';
|
||||
|
||||
@@ -83,17 +83,23 @@ else
|
||||
if (DOL_VERSION != $conf->global->MAIN_VERSION_LAST_UPGRADE) print ' '.img_warning($langs->trans("RunningUpdateProcessMayBeRequired", DOL_VERSION, $conf->global->MAIN_VERSION_LAST_UPGRADE));
|
||||
}
|
||||
|
||||
$version = DOL_VERSION;
|
||||
if (preg_match('/[a-z]+/i', $version)) $version = 'develop'; // If version contains text, it is not an official tagged version, so we use the full change log.
|
||||
print ' <a href="https://raw.githubusercontent.com/Dolibarr/dolibarr/'.$version.'/ChangeLog" target="_blank">'.$langs->trans("SeeChangeLog").'</a>';
|
||||
|
||||
$newversion = '';
|
||||
if (function_exists('curl_init'))
|
||||
{
|
||||
$conf->global->MAIN_USE_RESPONSE_TIMEOUT = 10;
|
||||
print ' - ';
|
||||
if ($action == 'getlastversion')
|
||||
{
|
||||
if ($sfurl)
|
||||
{
|
||||
if ($sfurl) {
|
||||
$i = 0;
|
||||
while (!empty($sfurl->channel[0]->item[$i]->title) && $i < 10000)
|
||||
{
|
||||
$title = $sfurl->channel[0]->item[$i]->title;
|
||||
$reg = array();
|
||||
if (preg_match('/([0-9]+\.([0-9\.]+))/', $title, $reg))
|
||||
{
|
||||
$newversion = $reg[1];
|
||||
@@ -107,25 +113,23 @@ if (function_exists('curl_init'))
|
||||
|
||||
// Show version
|
||||
print $langs->trans("LastStableVersion").' : <b>'.(($version != '0.0') ? $version : $langs->trans("Unknown")).'</b>';
|
||||
}
|
||||
else
|
||||
{
|
||||
if ($version != '0.0') {
|
||||
print ' <a href="https://raw.githubusercontent.com/Dolibarr/dolibarr/'.$version.'/ChangeLog" target="_blank">'.$langs->trans("SeeChangeLog").'</a>';
|
||||
}
|
||||
} else {
|
||||
print $langs->trans("LastStableVersion").' : <b>'.$langs->trans("UpdateServerOffline").'</b>';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
print $langs->trans("LastStableVersion").' : <a href="'.$_SERVER["PHP_SELF"].'?action=getlastversion" class="butAction">'.$langs->trans("Check").'</a>';
|
||||
}
|
||||
}
|
||||
|
||||
// Now show link to the changelog
|
||||
print ' - ';
|
||||
//print ' - ';
|
||||
|
||||
$version = DOL_VERSION;
|
||||
if (preg_match('/[a-z]+/i', $version)) $version = 'develop'; // If version contains text, it is not an official tagged version, so we use the full change log.
|
||||
|
||||
print '<a href="https://raw.githubusercontent.com/Dolibarr/dolibarr/'.$version.'/ChangeLog" target="_blank">'.$langs->trans("SeeChangeLog").'</a>';
|
||||
print '</td></tr>'."\n";
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("VersionLastUpgrade").' ('.$langs->trans("Database").')</td><td>'.$conf->global->MAIN_VERSION_LAST_UPGRADE.'</td></tr>'."\n";
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("VersionLastInstall").'</td><td>'.$conf->global->MAIN_VERSION_LAST_INSTALL.'</td></tr>'."\n";
|
||||
@@ -221,7 +225,7 @@ if (($thousand != ',' && $thousand != '.') || ($thousand != ' '))
|
||||
print '<tr class="oddeven"><td> => price(1234.56)</td><td>'.price(1234.56).'</td></tr>'."\n";
|
||||
// Timezone
|
||||
$txt = $langs->trans("OSTZ").' (variable system TZ): '.(!empty($_ENV["TZ"]) ? $_ENV["TZ"] : $langs->trans("NotDefined")).'<br>'."\n";
|
||||
$txt .= $langs->trans("PHPTZ").' (php.ini date.timezone): '.(ini_get("date.timezone") ?ini_get("date.timezone") : $langs->trans("NotDefined")).''."<br>\n"; // date.timezone must be in valued defined in http://fr3.php.net/manual/en/timezones.europe.php
|
||||
$txt .= $langs->trans("PHPTZ").' (date_default_timezone_get() / php.ini date.timezone): '.(getServerTimeZoneString()." / ".(ini_get("date.timezone") ? ini_get("date.timezone") : $langs->trans("NotDefined")))."<br>\n"; // date.timezone must be in valued defined in http://fr3.php.net/manual/en/timezones.europe.php
|
||||
$txt .= $langs->trans("Dolibarr constant MAIN_SERVER_TZ").': '.(empty($conf->global->MAIN_SERVER_TZ) ? $langs->trans("NotDefined") : $conf->global->MAIN_SERVER_TZ);
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("CurrentTimeZone").'</td><td>'; // Timezone server PHP
|
||||
$a = getServerTimeZoneInt('now');
|
||||
@@ -376,8 +380,7 @@ foreach ($configfileparameters as $key => $value)
|
||||
print "<td>";
|
||||
if ($newkey == 'dolibarr_main_db_pass') print preg_replace('/./i', '*', ${$newkey});
|
||||
elseif ($newkey == 'dolibarr_main_url_root' && preg_match('/__auto__/', ${$newkey})) print ${$newkey}.' => '.constant('DOL_MAIN_URL_ROOT');
|
||||
elseif ($newkey == 'dolibarr_main_document_root_alt')
|
||||
{
|
||||
elseif ($newkey == 'dolibarr_main_document_root_alt') {
|
||||
$tmparray = explode(',', ${$newkey});
|
||||
$i = 0;
|
||||
foreach ($tmparray as $value2)
|
||||
@@ -391,9 +394,7 @@ foreach ($configfileparameters as $key => $value)
|
||||
}
|
||||
++$i;
|
||||
}
|
||||
}
|
||||
elseif ($newkey == 'dolibarr_main_instance_unique_id')
|
||||
{
|
||||
} elseif ($newkey == 'dolibarr_main_instance_unique_id') {
|
||||
//print $conf->file->instance_unique_id;
|
||||
global $dolibarr_main_cookie_cryptkey;
|
||||
$valuetoshow = ${$newkey} ? ${$newkey} : $dolibarr_main_cookie_cryptkey; // Use $dolibarr_main_instance_unique_id first then $dolibarr_main_cookie_cryptkey
|
||||
@@ -402,9 +403,14 @@ foreach ($configfileparameters as $key => $value)
|
||||
print img_warning("EditConfigFileToAddEntry", 'dolibarr_main_instance_unique_id');
|
||||
}
|
||||
print ' <span class="opacitymedium">('.$langs->trans("HashForPing").'='.md5('dolibarr'.$valuetoshow).')</span>';
|
||||
}
|
||||
else
|
||||
{
|
||||
} elseif ($newkey == 'dolibarr_main_prod') {
|
||||
print ${$newkey};
|
||||
|
||||
$valuetoshow = ${$newkey};
|
||||
if (empty($valuetoshow)) {
|
||||
print img_warning($langs->trans('SwitchThisForABetterSecurity'));
|
||||
}
|
||||
} else {
|
||||
print ${$newkey};
|
||||
}
|
||||
if ($newkey == 'dolibarr_main_url_root' && ${$newkey} != DOL_MAIN_URL_ROOT) print ' (currently overwritten by autodetected value: '.DOL_MAIN_URL_ROOT.')';
|
||||
|
||||
@@ -273,7 +273,7 @@ if (!$error && $xml)
|
||||
}
|
||||
else
|
||||
{
|
||||
$out .= '<tr class="oddeven"><td colspan="3" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
$out .= '<tr class="oddeven"><td colspan="4" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
}
|
||||
$out .= '</table>';
|
||||
$out .= '</div>';
|
||||
@@ -328,7 +328,7 @@ if (!$error && $xml)
|
||||
}
|
||||
else
|
||||
{
|
||||
$out .= '<tr class="oddeven"><td colspan="6" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
$out .= '<tr class="oddeven"><td colspan="7" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
}
|
||||
$out .= '</table>';
|
||||
$out .= '</div>';
|
||||
@@ -383,7 +383,7 @@ if (!$error && $xml)
|
||||
}
|
||||
else
|
||||
{
|
||||
$out .= '<tr class="oddeven"><td colspan="5" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
$out .= '<tr class="oddeven"><td colspan="6" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
}
|
||||
$out .= '</table>';
|
||||
$out .= '</div>';
|
||||
|
||||
@@ -552,13 +552,6 @@ else
|
||||
}
|
||||
print '<br>';
|
||||
|
||||
// Database statistics update
|
||||
/*
|
||||
print '<br>';
|
||||
print '<strong>'.$langs->trans("DatabaseStatistics").'</strong>: ';
|
||||
print '<br>';
|
||||
*/
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
|
||||
@@ -137,7 +137,7 @@ print '</table>';
|
||||
|
||||
print '<br>';
|
||||
|
||||
$activatedExtensions = array_map('strtolower', getActivatedExtensions());
|
||||
$activatedExtensions = array();
|
||||
$loadedExtensions = array_map('strtolower', get_loaded_extensions(false));
|
||||
|
||||
print '<table class="noborder centpercent">';
|
||||
@@ -154,7 +154,6 @@ $name = "GD";
|
||||
|
||||
print "<tr>";
|
||||
print "<td>".$name."</td>";
|
||||
//print getTableColumn($name, $activatedExtensions);
|
||||
print getTableColumn($name, $loadedExtensions);
|
||||
print getTableColumnFunction($functions);
|
||||
print getResultColumn($name, $activatedExtensions, $loadedExtensions, $functions);
|
||||
@@ -165,7 +164,6 @@ $name = "Curl";
|
||||
|
||||
print "<tr>";
|
||||
print "<td>".$name."</td>";
|
||||
//print getTableColumn($name, $activatedExtensions);
|
||||
print getTableColumn($name, $loadedExtensions);
|
||||
print getTableColumnFunction($functions);
|
||||
print getResultColumn($name, $activatedExtensions, $loadedExtensions, $functions);
|
||||
@@ -178,7 +176,6 @@ if (empty($_SERVER["SERVER_ADMIN"]) || $_SERVER["SERVER_ADMIN"] != 'doliwamp@loc
|
||||
|
||||
print "<tr>";
|
||||
print "<td>".$name."</td>";
|
||||
//print getTableColumn($name, $activatedExtensions);
|
||||
print getTableColumn($name, $loadedExtensions);
|
||||
print getTableColumnFunction($functions);
|
||||
print getResultColumn($name, $activatedExtensions, $loadedExtensions, $functions);
|
||||
@@ -191,7 +188,6 @@ $name = "xDebug";
|
||||
|
||||
print "<tr>";
|
||||
print "<td>".$name."</td>";
|
||||
//print getTableColumn($name, $activatedExtensions);
|
||||
print getTableColumn($name, $loadedExtensions);
|
||||
print getTableColumnFunction($functions);
|
||||
print getResultColumn($name, $activatedExtensions, $loadedExtensions, $functions);
|
||||
@@ -221,7 +217,7 @@ foreach ($phparray as $key => $value)
|
||||
print '<td>'.$keyparam.'</td>';
|
||||
$valtoshow = $keyvalue;
|
||||
if ($keyparam == 'X-ChromePhp-Data') $valtoshow = dol_trunc($keyvalue, 80);
|
||||
print '<td colspan="2">';
|
||||
print '<td colspan="2" class="wordbreak">';
|
||||
if ($keyparam == 'Path') $valtoshow = implode('; ', explode(';', trim($valtoshow)));
|
||||
if ($keyparam == 'PATH') $valtoshow = implode('; ', explode(';', trim($valtoshow)));
|
||||
if ($keyparam == '_SERVER["PATH"]') $valtoshow = implode('; ', explode(';', trim($valtoshow)));
|
||||
@@ -232,7 +228,7 @@ foreach ($phparray as $key => $value)
|
||||
else
|
||||
{
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.$keyparam.'</td>';
|
||||
print '<td class="wordbreak">'.$keyparam.'</td>';
|
||||
$i = 0;
|
||||
foreach ($keyvalue as $keyparam2 => $keyvalue2)
|
||||
{
|
||||
@@ -256,78 +252,6 @@ foreach ($phparray as $key => $value)
|
||||
llxFooter();
|
||||
$db->close();
|
||||
|
||||
/**
|
||||
* Return all list with all activated, but possible not loaded PHP extensions
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
function getActivatedExtensions()
|
||||
{
|
||||
$file = getConfigFilePath();
|
||||
$handle = fopen(GetConfigFilePath(), "r");
|
||||
$content = fread($handle, filesize($file));
|
||||
|
||||
fclose($handle);
|
||||
|
||||
$configLines = explode("\r", $content);
|
||||
|
||||
$extensions = array();
|
||||
$lastLine = "";
|
||||
|
||||
foreach ($configLines as $line)
|
||||
{
|
||||
$line = trim($line);
|
||||
|
||||
// ignore comment lines
|
||||
if (substr($line, 0, 1) === ";")
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
// extension
|
||||
if (substr($line, 0, 9) === "extension" && substr($line, 0, 10) !== "extension_")
|
||||
{
|
||||
$value = trim(end(explode("=", $line)));
|
||||
|
||||
$extensions[] = $value === "gd2" ? "gd" : $value;
|
||||
}
|
||||
|
||||
// zend_extension
|
||||
if (substr($line, 0, 14) === "zend_extension")
|
||||
{
|
||||
$extensions[] = str_replace("[", "", str_replace("]", "", $lastLine));
|
||||
}
|
||||
|
||||
$lastLine = $line;
|
||||
}
|
||||
|
||||
return array_unique($extensions);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the path to the current used php config file
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function getConfigFilePath()
|
||||
{
|
||||
$phparray = phpinfo_array();
|
||||
|
||||
foreach ($phparray as $value)
|
||||
{
|
||||
foreach ($value as $keyparam => $keyvalue)
|
||||
{
|
||||
if (strtolower($keyparam) !== "loaded configuration file")
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
return $keyvalue;
|
||||
}
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a table column with a indicator (okay or warning), based on the given name and list
|
||||
@@ -400,7 +324,7 @@ function getTableColumnFunction(array $functions)
|
||||
* Return a result column with a translated result text
|
||||
*
|
||||
* @param string $name The name of the PHP extension
|
||||
* @param array $activated A list with all activated PHP extensions
|
||||
* @param array $activated A list with all activated PHP extensions. Deprecated.
|
||||
* @param array $loaded A list with all loaded PHP extensions
|
||||
* @param array $functions A list with all PHP functions to check
|
||||
*
|
||||
|
||||
@@ -350,7 +350,7 @@ if (empty($conf->global->FCKEDITOR_ENABLE_MAIL)) {
|
||||
// @todo Use module notification instead...
|
||||
|
||||
// Email d'envoi des notifications
|
||||
print '<tr class="oddeven"><td class="fieldrequired">'.$langs->trans("TicketEmailNotificationFrom").'</td>';
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("TicketEmailNotificationFrom").'</td>';
|
||||
print '<td class="left">';
|
||||
print '<input type="text" class="minwidth200" name="TICKET_NOTIFICATION_EMAIL_FROM" value="'.$conf->global->TICKET_NOTIFICATION_EMAIL_FROM.'"></td>';
|
||||
print '<td class="center">';
|
||||
|
||||
@@ -241,7 +241,8 @@ if (in_array($type, array('mysql', 'mysqli'))) {
|
||||
print '<input type="checkbox" name="sql_structure" value="structure" id="checkbox_sql_structure" checked />';
|
||||
print '<label for="checkbox_sql_structure">'.$langs->trans('ExportStructure').'</label>';
|
||||
print '</legend>';
|
||||
print '<input type="checkbox" name="drop"'.(((!isset($_GET["drop"]) && !isset($_POST["drop"])) || GETPOST('drop')) ? ' checked' : '').' id="checkbox_dump_drop" />';
|
||||
|
||||
print '<input type="checkbox" name="drop"'.((! GETPOSTISSET("drop") || GETPOST('drop')) ? ' checked' : '').' id="checkbox_dump_drop" />';
|
||||
print '<label for="checkbox_dump_drop">'.$langs->trans("AddDropTable").'</label>';
|
||||
print '<br>';
|
||||
print '</fieldset>';
|
||||
|
||||
@@ -34,7 +34,7 @@ $action = GETPOST('action', 'alpha');
|
||||
$what = GETPOST('what', 'alpha');
|
||||
$export_type = GETPOST('export_type', 'alpha');
|
||||
$file = trim(GETPOST('zipfilename_template', 'alpha'));
|
||||
$compression = GETPOST('compression');
|
||||
$compression = GETPOST('compression', 'aZ09');
|
||||
|
||||
$file = dol_sanitizeFileName($file);
|
||||
$file = preg_replace('/(\.zip|\.tar|\.tgz|\.gz|\.tar\.gz|\.bz2)$/i', '', $file);
|
||||
|
||||
@@ -40,7 +40,7 @@ $transkey = GETPOST('transkey', 'alphanohtml');
|
||||
$transvalue = GETPOST('transvalue', 'none');
|
||||
|
||||
|
||||
$mode = GETPOST('mode', 'aZ09') ?GETPOST('mode', 'aZ09') : 'overwrite';
|
||||
$mode = GETPOST('mode', 'aZ09') ?GETPOST('mode', 'aZ09') : 'searchkey';
|
||||
|
||||
$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit;
|
||||
$sortfield = GETPOST("sortfield", 'alpha');
|
||||
@@ -514,7 +514,7 @@ if ($mode == 'searchkey')
|
||||
if ($i > ($offset + $limit)) break;
|
||||
print '<tr class="oddeven"><td>'.$langcode.'</td><td>'.$key.'</td><td>';
|
||||
print dol_escape_htmltag($val);
|
||||
print '</td><td class="right">';
|
||||
print '</td><td class="right nowraponall">';
|
||||
if (!empty($newlangfileonly->tab_translate[$key]))
|
||||
{
|
||||
if ($val != $newlangfileonly->tab_translate[$key])
|
||||
@@ -534,7 +534,7 @@ if ($mode == 'searchkey')
|
||||
print ' ';
|
||||
print '<a href="'.$_SERVER['PHP_SELF'].'?rowid='.$obj->rowid.'&entity='.$conf->entity.'&action=delete">'.img_delete().'</a>';
|
||||
print ' ';
|
||||
$htmltext = $langs->trans("OriginalValueWas", $newlangfileonly->tab_translate[$key]);
|
||||
$htmltext = $langs->trans("OriginalValueWas", '<i>'.$newlangfileonly->tab_translate[$key].'</i>');
|
||||
print $form->textwithpicto('', $htmltext, 1, 'info');
|
||||
}
|
||||
elseif (!empty($conf->global->MAIN_ENABLE_OVERWRITE_TRANSLATION))
|
||||
@@ -549,7 +549,7 @@ if ($mode == 'searchkey')
|
||||
//$transifexurl = 'https://www.transifex.com/dolibarr-association/dolibarr/translate/#'.$langcode.'/'.$transifexlangfile.'?key='.$key;
|
||||
$transifexurl = 'https://www.transifex.com/dolibarr-association/dolibarr/translate/#'.$langcode.'/'.$transifexlangfile.'?q=key%3A'.$key;
|
||||
|
||||
print ' <a href="'.$transifexurl.'" target="transifex">'.img_picto('FixOnTransifex', 'globe').'</a>';
|
||||
print ' <a href="'.$transifexurl.'" target="transifex">'.img_picto($langs->trans('FixOnTransifex'), 'globe').'</a>';
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
|
||||
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2015 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2020 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@@ -42,6 +43,8 @@ $action = GETPOST('action', 'alpha');
|
||||
$backtopage = GETPOST('backtopage', 'alpha');
|
||||
|
||||
$value = GETPOST('value', 'alpha');
|
||||
$label = GETPOST('label', 'alpha');
|
||||
$scandir = GETPOST('scandir', 'alpha');
|
||||
$type = 'user';
|
||||
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ class DolibarrApi
|
||||
/**
|
||||
* @var DoliDb $db Database object
|
||||
*/
|
||||
protected static $db;
|
||||
protected $db;
|
||||
|
||||
/**
|
||||
* @var Restler $r Restler object
|
||||
|
||||
@@ -254,15 +254,17 @@ if (!empty($reg[1]) && ($reg[1] != 'explorer' || ($reg[2] != '/swagger.json' &&
|
||||
if ($tmpmodule != 'api')
|
||||
$tmpmodule = preg_replace('/api$/i', '', $tmpmodule);
|
||||
$classfile = str_replace('_', '', $tmpmodule);
|
||||
if ($module == 'supplierproposals')
|
||||
|
||||
// Special cases that does not match name rules conventions
|
||||
if ($moduleobject == 'supplierproposals')
|
||||
$classfile = 'supplier_proposals';
|
||||
if ($module == 'supplierorders')
|
||||
if ($moduleobject == 'supplierorders')
|
||||
$classfile = 'supplier_orders';
|
||||
if ($module == 'supplierinvoices')
|
||||
if ($moduleobject == 'supplierinvoices')
|
||||
$classfile = 'supplier_invoices';
|
||||
if ($module == 'ficheinter')
|
||||
if ($moduleobject == 'ficheinter')
|
||||
$classfile = 'interventions';
|
||||
if ($module == 'interventions')
|
||||
if ($moduleobject == 'interventions')
|
||||
$classfile = 'interventions';
|
||||
|
||||
$dir_part_file = dol_buildpath('/'.$moduledirforclass.'/class/api_'.$classfile.'.class.php', 0, 2);
|
||||
|
||||
@@ -132,7 +132,7 @@ if ($object->id > 0)
|
||||
|
||||
// Object card
|
||||
// ------------------------------------------------------------
|
||||
$linkback = '<a href="'.dol_buildpath('/bom/myobject_list.php', 1).'?restore_lastsearch_values=1'.(!empty($socid) ? '&socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>';
|
||||
$linkback = '<a href="'.dol_buildpath('/bom/bom_list.php', 1).'?restore_lastsearch_values=1'.(!empty($socid) ? '&socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>';
|
||||
|
||||
$morehtmlref = '<div class="refidno">';
|
||||
/*
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2017-2020 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2019 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -183,6 +183,10 @@ if (empty($reshook))
|
||||
unset($_POST['qty']);
|
||||
unset($_POST['qty_frozen']);
|
||||
unset($_POST['disable_stock_change']);
|
||||
|
||||
$object->fetchLines();
|
||||
|
||||
$object->calculateCosts();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -194,10 +198,10 @@ if (empty($reshook))
|
||||
$error = 0;
|
||||
|
||||
// Set if we used free entry or predefined product
|
||||
$qty = GETPOST('qty', 'int');
|
||||
$qty = price2num(GETPOST('qty', 'alpha'));
|
||||
$qty_frozen = GETPOST('qty_frozen', 'int');
|
||||
$disable_stock_change = GETPOST('disable_stock_change', 'int');
|
||||
$efficiency = GETPOST('efficiency', 'int');
|
||||
$efficiency = price2num(GETPOST('efficiency', 'int'));
|
||||
|
||||
if ($qty == '') {
|
||||
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Qty')), null, 'errors');
|
||||
@@ -223,6 +227,10 @@ if (empty($reshook))
|
||||
unset($_POST['qty']);
|
||||
unset($_POST['qty_frozen']);
|
||||
unset($_POST['disable_stock_change']);
|
||||
|
||||
$object->fetchLines();
|
||||
|
||||
$object->calculateCosts();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -545,7 +553,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
|
||||
if (!empty($object->table_element_line))
|
||||
{
|
||||
print ' <form name="addproduct" id="addproduct" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.(($action != 'editline') ? '#addline' : '#line_'.GETPOST('lineid', 'int')).'" method="POST">
|
||||
print ' <form name="addproduct" id="addproduct" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.(($action != 'editline') ? '#addline' : '').'" method="POST">
|
||||
<input type="hidden" name="token" value="' . newToken().'">
|
||||
<input type="hidden" name="action" value="' . (($action != 'editline') ? 'addline' : 'updateline').'">
|
||||
<input type="hidden" name="mode" value="">
|
||||
|
||||
@@ -333,8 +333,10 @@ class BOM extends CommonObject
|
||||
public function fetch($id, $ref = null)
|
||||
{
|
||||
$result = $this->fetchCommon($id, $ref);
|
||||
|
||||
if ($result > 0 && !empty($this->table_element_line)) $this->fetchLines();
|
||||
$this->calculateCosts();
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
@@ -943,6 +945,7 @@ class BOM extends CommonObject
|
||||
global $conf, $langs;
|
||||
|
||||
$langs->load("mrp");
|
||||
$outputlangs->load("products");
|
||||
|
||||
if (!dol_strlen($modele)) {
|
||||
$modele = 'standard';
|
||||
|
||||
@@ -41,6 +41,11 @@ function bomAdminPrepareHead()
|
||||
$head[$h][2] = 'settings';
|
||||
$h++;
|
||||
|
||||
$head[$h][0] = dol_buildpath("/admin/bom_extrafields.php", 1);
|
||||
$head[$h][1] = $langs->trans("ExtraFields");
|
||||
$head[$h][2] = 'bom_extrafields';
|
||||
$h++;
|
||||
|
||||
/*$head[$h][0] = DOL_URL_ROOT."/bom/admin/about.php";
|
||||
$head[$h][1] = $langs->trans("About");
|
||||
$head[$h][2] = 'about';
|
||||
|
||||
@@ -116,7 +116,6 @@ if ($conf->global->PRODUCT_USE_UNITS)
|
||||
{
|
||||
$coldisplay++;
|
||||
print '<td class="nobottom linecoluseunit left">';
|
||||
print $form->selectUnits($line->fk_unit, "units");
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
|
||||
@@ -112,7 +112,6 @@ if ($conf->global->PRODUCT_USE_UNITS)
|
||||
{
|
||||
$coldisplay++;
|
||||
print '<td class="nobottom linecoluseunit left">';
|
||||
print $form->selectUnits($line->fk_unit, "units");
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@ print '<td class="linecoldisablestockchange right">'.$form->textwithpicto($langs
|
||||
print '<td class="linecolefficiency right">'.$form->textwithpicto($langs->trans('ManufacturingEfficiency'), $langs->trans('ValueOfMeansLoss')).'</td>';
|
||||
|
||||
// Cost
|
||||
print '<td class="linecolcost right">'.$langs->trans('CostPrice').'</td>';
|
||||
print '<td class="linecolcost right">'.$form->textwithpicto($langs->trans("TotalCost"), $langs->trans("BOMTotalCost")).'</td>';
|
||||
|
||||
print '<td class="linecoledit"></td>'; // No width to allow autodim
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@ print '</td>';
|
||||
if ($conf->global->PRODUCT_USE_UNITS)
|
||||
{
|
||||
print '<td class="linecoluseunit nowrap left">';
|
||||
$label = $line->getLabelOfUnit('short');
|
||||
$label = $tmpproduct->getLabelOfUnit('short');
|
||||
if ($label !== '') {
|
||||
print $langs->trans($label);
|
||||
}
|
||||
@@ -113,7 +113,7 @@ if ($this->status == 0 && ($object_rights->write) && $action != 'selectlines') {
|
||||
$coldisplay++;
|
||||
if (($line->info_bits & 2) == 2 || !empty($disableedit)) {
|
||||
} else {
|
||||
print '<a class="editfielda reposition" href="'.$_SERVER["PHP_SELF"].'?id='.$this->id.'&action=editline&lineid='.$line->id.'#line_'.$line->id.'">'.img_edit().'</a>';
|
||||
print '<a class="editfielda reposition" href="'.$_SERVER["PHP_SELF"].'?id='.$this->id.'&action=editline&lineid='.$line->id.'">'.img_edit().'</a>';
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
|
||||
@@ -151,6 +151,7 @@ if ($action == 'create')
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST" enctype="multipart/form-data">'."\n";
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="add">';
|
||||
print '<input type="hidden" name="backtopage" value="'.$backtopage.'">';
|
||||
|
||||
print load_fiche_titre($langs->trans("NewBookmark"));
|
||||
|
||||
|
||||
@@ -158,7 +158,7 @@ print '<input type="hidden" name="sortorder" value="'.$sortorder.'">';
|
||||
print '<input type="hidden" name="contextpage" value="'.$contextpage.'">';
|
||||
|
||||
$newcardbutton = '';
|
||||
$newcardbutton .= dolGetButtonTitle($langs->trans('New'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/bookmarks/card.php?action=create', '', !empty($user->rights->bookmark->creer));
|
||||
$newcardbutton .= dolGetButtonTitle($langs->trans('New'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/bookmarks/card.php?action=create&backtopage='.urlencode(DOL_URL_ROOT.'/bookmarks/list.php'), '', !empty($user->rights->bookmark->creer));
|
||||
|
||||
print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'bookmark', 0, $newcardbutton, '', $limit, 0, 0, 1);
|
||||
|
||||
|
||||
@@ -846,8 +846,8 @@ class Categorie extends CommonObject
|
||||
|
||||
$objs = array();
|
||||
|
||||
$tmpclass = $this->MAP_OBJ_CLASS[$type];
|
||||
$obj = new $tmpclass($this->db);
|
||||
$classnameforobj = $this->MAP_OBJ_CLASS[$type];
|
||||
$obj = new $classnameforobj($this->db);
|
||||
|
||||
$sql = "SELECT c.fk_".(empty($this->MAP_CAT_FK[$type]) ? $type : $this->MAP_CAT_FK[$type]);
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."categorie_".(empty($this->MAP_CAT_TABLE[$type]) ? $type : $this->MAP_CAT_TABLE[$type])." as c";
|
||||
@@ -875,8 +875,11 @@ class Categorie extends CommonObject
|
||||
}
|
||||
else
|
||||
{
|
||||
$obj = new $this->MAP_OBJ_CLASS[$type]($this->db);
|
||||
$classnameforobj = $this->MAP_OBJ_CLASS[$type];
|
||||
|
||||
$obj = new $classnameforobj($this->db);
|
||||
$obj->fetch($rec['fk_'.(empty($this->MAP_CAT_FK[$type]) ? $type : $this->MAP_CAT_FK[$type])]);
|
||||
|
||||
$objs[] = $obj;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -157,7 +157,7 @@ print '</tr>';
|
||||
// Description
|
||||
print '<tr>';
|
||||
print '<td>'.$langs->trans("Description").'</td>';
|
||||
print '<td >';
|
||||
print '<td>';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
$doleditor = new DolEditor('description', $object->description, '', 200, 'dolibarr_notes', '', false, true, $conf->fckeditor->enabled, ROWS_6, '90%');
|
||||
$doleditor->Create();
|
||||
@@ -166,7 +166,7 @@ print '</td></tr>';
|
||||
// Color
|
||||
print '<tr>';
|
||||
print '<td>'.$langs->trans("Color").'</td>';
|
||||
print '<td >';
|
||||
print '<td>';
|
||||
print $formother->selectColor($object->color, 'color');
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@@ -269,16 +269,19 @@ dol_fiche_end();
|
||||
*/
|
||||
|
||||
print "<div class='tabsAction'>\n";
|
||||
$reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
||||
if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||
if (empty($reshook)) {
|
||||
if ($user->rights->categorie->creer)
|
||||
{
|
||||
$socid = ($object->socid ? "&socid=".$object->socid : "");
|
||||
print "<a class='butAction' href='edit.php?id=".$object->id.$socid."&type=".$type."'>".$langs->trans("Modify")."</a>";
|
||||
}
|
||||
|
||||
if ($user->rights->categorie->creer)
|
||||
{
|
||||
$socid = ($object->socid ? "&socid=".$object->socid : "");
|
||||
print "<a class='butAction' href='edit.php?id=".$object->id.$socid."&type=".$type."'>".$langs->trans("Modify")."</a>";
|
||||
}
|
||||
|
||||
if ($user->rights->categorie->supprimer)
|
||||
{
|
||||
print "<a class='butActionDelete' href='".DOL_URL_ROOT."/categories/viewcat.php?action=delete&id=".$object->id."&type=".$type."'>".$langs->trans("Delete")."</a>";
|
||||
if ($user->rights->categorie->supprimer)
|
||||
{
|
||||
print "<a class='butActionDelete' href='".DOL_URL_ROOT."/categories/viewcat.php?action=delete&id=".$object->id."&type=".$type."'>".$langs->trans("Delete")."</a>";
|
||||
}
|
||||
}
|
||||
|
||||
print "</div>";
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2014 Cedric GROSS <c.gross@kreiz-it.fr>
|
||||
* Copyright (C) 2015 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2018-2019 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2015 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2018-2019 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2019 Ferran Marcet <fmarcet@2byte.es>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -111,6 +111,7 @@ $parameters = array('socid' => $socid);
|
||||
$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
||||
if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
*/
|
||||
@@ -317,7 +318,7 @@ if (empty($reshook) && $action == 'add')
|
||||
if (GETPOST("doneby") > 0) $object->userdoneid = GETPOST("doneby", "int");
|
||||
}
|
||||
|
||||
$object->note_private = trim(GETPOST("note"));
|
||||
$object->note_private = trim(GETPOST("note", "none"));
|
||||
|
||||
if (isset($_POST["contactid"])) $object->contact = $contact;
|
||||
|
||||
@@ -444,8 +445,8 @@ if (empty($reshook) && $action == 'update')
|
||||
$object->fetch_userassigned();
|
||||
$object->oldcopy = clone $object;
|
||||
|
||||
$datep = dol_mktime($fulldayevent ? '00' : $aphour, $fulldayevent ? '00' : $apmin, 0, $_POST["apmonth"], $_POST["apday"], $_POST["apyear"]);
|
||||
$datef = dol_mktime($fulldayevent ? '23' : $p2hour, $fulldayevent ? '59' : $p2min, $fulldayevent ? '59' : '0', $_POST["p2month"], $_POST["p2day"], $_POST["p2year"]);
|
||||
$datep = dol_mktime($fulldayevent ? '00' : $aphour, $fulldayevent ? '00' : $apmin, 0, GETPOST("apmonth", 'int'), GETPOST("apday", 'int'), GETPOST("apyear", 'int'));
|
||||
$datef = dol_mktime($fulldayevent ? '23' : $p2hour, $fulldayevent ? '59' : $p2min, $fulldayevent ? '59' : '0', GETPOST("p2month", 'int'), GETPOST("p2day", 'int'), GETPOST("p2year", 'int'));
|
||||
|
||||
$object->type_id = dol_getIdFromCode($db, GETPOST("actioncode", 'aZ09'), 'c_actioncomm');
|
||||
$object->label = GETPOST("label", "alphanohtml");
|
||||
@@ -465,10 +466,9 @@ if (empty($reshook) && $action == 'update')
|
||||
$object->contactid = key($object->socpeopleassigned);
|
||||
}
|
||||
$object->fk_project = GETPOST("projectid", 'int');
|
||||
$object->note_private = GETPOST("note", "none");
|
||||
$object->note_private = trim(GETPOST("note", "none"));
|
||||
$object->fk_element = GETPOST("fk_element", "int");
|
||||
$object->elementtype = GETPOST("elementtype", "alphanohtml");
|
||||
|
||||
if (!$datef && $percentage == 100)
|
||||
{
|
||||
$error++; $donotclearsession = 1;
|
||||
@@ -815,6 +815,7 @@ if ($action == 'create')
|
||||
}
|
||||
setdatefields();
|
||||
$("#fullday").change(function() {
|
||||
console.log("setdatefields");
|
||||
setdatefields();
|
||||
});
|
||||
$("#selectcomplete").change(function() {
|
||||
@@ -869,9 +870,7 @@ if ($action == 'create')
|
||||
if (GETPOST('datep', 'int', 1)) $datep = dol_stringtotime(GETPOST('datep', 'int', 1), 0);
|
||||
print '<tr><td class="nowrap"><span class="fieldrequired">'.$langs->trans("DateActionStart").'</span></td><td>';
|
||||
if (GETPOST("afaire") == 1) {
|
||||
print $form->selectDate($datep, 'ap', 1, 1, 0, "action", 1, 2, 0, 'fulldayend');
|
||||
} elseif (GETPOST("afaire") == 2) {
|
||||
print $form->selectDate($datep, 'ap', 1, 1, 1, "action", 1, 2, 0, 'fulldayend');
|
||||
print $form->selectDate($datep, 'ap', 1, 1, 0, "action", 1, 2, 0, 'fulldaystart'); // Empty value not allowed for start date and hours if "todo"
|
||||
} else {
|
||||
print $form->selectDate($datep, 'ap', 1, 1, 1, "action", 1, 2, 0, 'fulldaystart');
|
||||
}
|
||||
@@ -886,11 +885,9 @@ if ($action == 'create')
|
||||
}
|
||||
print '<tr><td><span id="dateend"'.(GETPOST("actioncode", 'aZ09') == 'AC_RDV' ? ' class="fieldrequired"' : '').'>'.$langs->trans("DateActionEnd").'</span></td><td>';
|
||||
if (GETPOST("afaire") == 1) {
|
||||
print $form->selectDate($datef, 'p2', 1, 1, 1, "action", 1, 1, 0, 'fulldayend');
|
||||
} elseif (GETPOST("afaire") == 2) {
|
||||
print $form->selectDate($datef, 'p2', 1, 1, 1, "action", 1, 1, 0, 'fulldayend');
|
||||
print $form->selectDate($datef, 'p2', 1, 1, 1, "action", 1, 2, 0, 'fulldayend');
|
||||
} else {
|
||||
print $form->selectDate($datef, 'p2', 1, 1, 1, "action", 1, 1, 0, 'fulldayend');
|
||||
print $form->selectDate($datef, 'p2', 1, 1, 1, "action", 1, 2, 0, 'fulldayend');
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
@@ -1059,14 +1056,13 @@ if ($action == 'create')
|
||||
// Project
|
||||
if (!empty($conf->projet->enabled))
|
||||
{
|
||||
// Projet associe
|
||||
$langs->load("projects");
|
||||
|
||||
$projectid = GETPOST('projectid', 'int');
|
||||
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("Project").'</td><td id="project-input-container" >';
|
||||
|
||||
$numproject = $formproject->select_projects((!empty($societe->id) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1);
|
||||
$numproject = $formproject->select_projects((!empty($societe->id) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
|
||||
|
||||
print ' <a href="'.DOL_URL_ROOT.'/projet/card.php?socid='.$societe->id.'&action=create"><span class="fa fa-plus-circle valignmiddle paddingleft" title="'.$langs->trans("AddProject").'"></span></a>';
|
||||
$urloption = '?action=create&donotclearsession=1';
|
||||
@@ -1108,6 +1104,7 @@ if ($action == 'create')
|
||||
print '<input type="hidden" name="origin" size="10" value="'.GETPOST('origin').'">';
|
||||
}
|
||||
|
||||
$reg = array();
|
||||
if (GETPOST("datep") && preg_match('/^([0-9][0-9][0-9][0-9])([0-9][0-9])([0-9][0-9])$/', GETPOST("datep"), $reg))
|
||||
{
|
||||
$object->datep = dol_mktime(0, 0, 0, $reg[2], $reg[3], $reg[1]);
|
||||
@@ -1121,7 +1118,7 @@ if ($action == 'create')
|
||||
// Description
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td><td>';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
$doleditor = new DolEditor('note', (GETPOST('note', 'none') ?GETPOST('note', 'none') : $object->note_private), '', 180, 'dolibarr_notes', 'In', true, true, $conf->fckeditor->enabled, ROWS_4, '90%');
|
||||
$doleditor = new DolEditor('note', (GETPOST('note', 'none') ? GETPOST('note', 'none') : $object->note_private), '', 180, 'dolibarr_notes', 'In', true, true, $conf->fckeditor->enabled, ROWS_4, '90%');
|
||||
$doleditor->Create();
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@@ -983,7 +983,7 @@ class ActionComm extends CommonObject
|
||||
|
||||
// Clean parameters
|
||||
$this->label = trim($this->label);
|
||||
$this->note_private = dol_htmlcleanlastbr(trim(empty($this->note_private) ? $this->note : $this->note_private));
|
||||
$this->note_private = dol_htmlcleanlastbr(trim(!isset($this->note_private) ? $this->note : $this->note_private));
|
||||
if (empty($this->percentage)) $this->percentage = 0;
|
||||
if (empty($this->priority) || !is_numeric($this->priority)) $this->priority = 0;
|
||||
if (empty($this->transparency)) $this->transparency = 0;
|
||||
@@ -1201,13 +1201,20 @@ class ActionComm extends CommonObject
|
||||
}
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a";
|
||||
if (!$user->rights->societe->client->voir && !$user->socid) $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe_commerciaux as sc ON a.fk_soc = sc.fk_soc";
|
||||
if (!$user->rights->agenda->allactions->read) {
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."actioncomm_resources AS ar ON a.id = ar.fk_actioncomm AND ar.element_type ='user' AND ar.fk_element = ".$user->id;
|
||||
}
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s ON a.fk_soc = s.rowid";
|
||||
$sql .= " WHERE 1 = 1";
|
||||
if (empty($load_state_board)) $sql .= " AND a.percent >= 0 AND a.percent < 100";
|
||||
$sql .= " AND a.entity IN (".getEntity('agenda').")";
|
||||
if (!$user->rights->societe->client->voir && !$user->socid) $sql .= " AND (a.fk_soc IS NULL OR sc.fk_user = ".$user->id.")";
|
||||
if ($user->socid) $sql .= " AND a.fk_soc = ".$user->socid;
|
||||
if (!$user->rights->agenda->allactions->read) $sql .= " AND (a.fk_user_author = ".$user->id." OR a.fk_user_action = ".$user->id." OR a.fk_user_done = ".$user->id.")";
|
||||
if (!$user->rights->agenda->allactions->read) {
|
||||
$sql .= " AND (a.fk_user_author = ".$user->id." OR a.fk_user_action = ".$user->id." OR a.fk_user_done = ".$user->id;
|
||||
$sql .= " OR ar.fk_element = ".$user->id; // Added by PV
|
||||
$sql .= ")";
|
||||
}
|
||||
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
|
||||
@@ -1704,7 +1704,7 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
|
||||
if ($event->type_code == 'ICALEVENT') print '<br>('.dol_trunc($event->icalname, $maxnbofchar).')';
|
||||
|
||||
$thirdparty_id = ($event->thirdparty_id > 0 ? $event->thirdparty_id : ((is_object($event->societe) && $event->societe->id > 0) ? $event->societe->id : 0));
|
||||
$contact_id = ($event->contact_id > 0 ? $event->contact_id : ((is_object($event->contact) && $event->cotact->id > 0) ? $event->contact->id : 0));
|
||||
$contact_id = ($event->contact_id > 0 ? $event->contact_id : ((is_object($event->contact) && $event->contact->id > 0) ? $event->contact->id : 0));
|
||||
|
||||
// If action related to company / contact
|
||||
$linerelatedto = '';
|
||||
|
||||
@@ -35,8 +35,8 @@ require_once DOL_DOCUMENT_ROOT.'/core/modules/action/rapport.pdf.php';
|
||||
$langs->loadLangs(array("agenda", "commercial"));
|
||||
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$month = GETPOST('month');
|
||||
$year = GETPOST('year');
|
||||
$month = GETPOST('month', 'int');
|
||||
$year = GETPOST('year', 'int');
|
||||
|
||||
$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit;
|
||||
$sortfield = GETPOST("sortfield", 'alpha');
|
||||
@@ -119,9 +119,8 @@ if ($resql)
|
||||
print '<input type="hidden" name="action" value="list">';
|
||||
print '<input type="hidden" name="sortfield" value="'.$sortfield.'">';
|
||||
print '<input type="hidden" name="sortorder" value="'.$sortorder.'">';
|
||||
print '<input type="hidden" name="page" value="'.$page.'">';
|
||||
|
||||
print_barre_liste($langs->trans("EventReports"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'title_agenda', 0, '', '', $limit);
|
||||
print_barre_liste($langs->trans("EventReports"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'title_agenda', 0, '', '', $limit, 0, 0, 1);
|
||||
|
||||
$moreforfilter = '';
|
||||
|
||||
@@ -154,7 +153,7 @@ if ($resql)
|
||||
|
||||
// Button to build doc
|
||||
print '<td class="center">';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?action=builddoc&page='.$page.'&month='.$obj->month.'&year='.$obj->year.'">'.img_picto($langs->trans('BuildDoc'), 'filenew').'</a>';
|
||||
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=builddoc&page='.$page.'&month='.$obj->month.'&year='.$obj->year.'">'.img_picto($langs->trans('BuildDoc'), 'filenew').'</a>';
|
||||
print '</td>';
|
||||
|
||||
$name = "actions-".$obj->month."-".$obj->year.".pdf";
|
||||
|
||||
@@ -86,6 +86,7 @@ $extrafields->fetch_name_optionals_label($object->table_element);
|
||||
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
|
||||
$hookmanager->initHooks(array('thirdpartycomm', 'globalcard'));
|
||||
|
||||
$now = dol_now();
|
||||
|
||||
|
||||
/*
|
||||
@@ -268,7 +269,10 @@ if ($object->id > 0)
|
||||
print '<tr><td>';
|
||||
print $langs->trans('CustomerCode').'</td><td>';
|
||||
print $object->code_client;
|
||||
if ($object->check_codeclient() <> 0) print ' <font class="error">('.$langs->trans("WrongCustomerCode").')</font>';
|
||||
$tmpcheck = $object->check_codeclient();
|
||||
if ($tmpcheck != 0 && $tmpcheck != -5) {
|
||||
print ' <font class="error">('.$langs->trans("WrongCustomerCode").')</font>';
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr>';
|
||||
@@ -528,6 +532,7 @@ if ($object->id > 0)
|
||||
|
||||
print "</table>";
|
||||
|
||||
// Prospection level and status
|
||||
if ($object->client == 2 || $object->client == 3)
|
||||
{
|
||||
print '<br>';
|
||||
@@ -540,7 +545,7 @@ if ($object->id > 0)
|
||||
print '<table width="100%" class="nobordernopadding"><tr><td class="nowrap">';
|
||||
print $langs->trans('ProspectLevel');
|
||||
print '<td>';
|
||||
if ($action != 'editlevel' && $user->rights->societe->creer) print '<td class="right"><a class="editfielda" href="'.$_SERVER["PHP_SELF"].'?action=editlevel&socid='.$object->id.'">'.img_edit($langs->trans('Modify'), 1).'</a></td>';
|
||||
if ($action != 'editlevel' && $user->rights->societe->creer) print '<td class="right"><a class="editfielda reposition" href="'.$_SERVER["PHP_SELF"].'?action=editlevel&socid='.$object->id.'">'.img_edit($langs->trans('Modify'), 1).'</a></td>';
|
||||
print '</tr></table>';
|
||||
print '</td><td>';
|
||||
if ($action == 'editlevel')
|
||||
@@ -563,7 +568,7 @@ if ($object->id > 0)
|
||||
{
|
||||
$titlealt = 'default';
|
||||
if (!empty($val['code']) && !in_array($val['code'], array('ST_NO', 'ST_NEVER', 'ST_TODO', 'ST_PEND', 'ST_DONE'))) $titlealt = $val['label'];
|
||||
if ($object->stcomm_id != $val['id']) print '<a class="pictosubstatus" href="'.$_SERVER["PHP_SELF"].'?socid='.$object->id.'&stcomm='.$val['code'].'&action=setstcomm">'.img_action($titlealt, $val['code']).'</a>';
|
||||
if ($object->stcomm_id != $val['id']) print '<a class="pictosubstatus reposition" href="'.$_SERVER["PHP_SELF"].'?socid='.$object->id.'&stcomm='.$val['code'].'&action=setstcomm">'.img_action($titlealt, $val['code']).'</a>';
|
||||
}
|
||||
print '</div></td></tr>';
|
||||
print "</table>";
|
||||
@@ -580,7 +585,7 @@ if ($object->id > 0)
|
||||
// Lien recap
|
||||
$boxstat .= '<div class="box">';
|
||||
$boxstat .= '<table summary="'.dol_escape_htmltag($langs->trans("DolibarrStateBoard")).'" class="border boxtable boxtablenobottom boxtablenotop" width="100%">';
|
||||
$boxstat .= '<tr class="impair"><td colspan="2" class="tdboxstats nohover">';
|
||||
$boxstat .= '<tr class="impair nohover"><td colspan="2" class="tdboxstats nohover">';
|
||||
|
||||
if (!empty($conf->propal->enabled) && $user->rights->propal->lire)
|
||||
{
|
||||
@@ -664,7 +669,6 @@ if ($object->id > 0)
|
||||
|
||||
print $boxstat;
|
||||
|
||||
$now = dol_now();
|
||||
|
||||
/*
|
||||
* Latest proposals
|
||||
@@ -677,7 +681,7 @@ if ($object->id > 0)
|
||||
$sql .= ", p.tva as total_tva";
|
||||
$sql .= ", p.total as total_ttc";
|
||||
$sql .= ", p.ref, p.ref_client, p.remise";
|
||||
$sql .= ", p.datep as dp, p.fin_validite as datelimite";
|
||||
$sql .= ", p.datep as dp, p.fin_validite as date_limit";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."propal as p, ".MAIN_DB_PREFIX."c_propalst as c";
|
||||
$sql .= " WHERE p.fk_soc = s.rowid AND p.fk_statut = c.id";
|
||||
$sql .= " AND s.rowid = ".$object->id;
|
||||
@@ -716,7 +720,7 @@ if ($object->id > 0)
|
||||
$propal_static->total_tva = $objp->total_tva;
|
||||
$propal_static->total_ttc = $objp->total_ttc;
|
||||
print $propal_static->getNomUrl(1);
|
||||
if (($db->jdate($objp->datelimite) < ($now - $conf->propal->cloture->warning_delay)) && $objp->fk_statut == 1) {
|
||||
if (($db->jdate($objp->date_limit) < ($now - $conf->propal->cloture->warning_delay)) && $objp->fk_statut == $propal_static::STATUS_VALIDATED) {
|
||||
print " ".img_warning();
|
||||
}
|
||||
print '</td><td class="right" width="80px">'.dol_print_date($db->jdate($objp->dp), 'day')."</td>\n";
|
||||
@@ -898,11 +902,11 @@ if ($object->id > 0)
|
||||
}
|
||||
|
||||
/*
|
||||
* Latest linked contracts
|
||||
* Latest contracts
|
||||
*/
|
||||
if (!empty($conf->contrat->enabled) && $user->rights->contrat->lire)
|
||||
{
|
||||
$sql = "SELECT s.nom, s.rowid, c.rowid as id, c.ref as ref, c.statut, c.datec as dc, c.date_contrat as dcon, c.ref_customer as refcus, c.ref_supplier as refsup";
|
||||
$sql = "SELECT s.nom, s.rowid, c.rowid as id, c.ref as ref, c.statut as contract_status, c.datec as dc, c.date_contrat as dcon, c.ref_customer as refcus, c.ref_supplier as refsup";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."contrat as c";
|
||||
$sql .= " WHERE c.fk_soc = s.rowid ";
|
||||
$sql .= " AND s.rowid = ".$object->id;
|
||||
@@ -921,7 +925,7 @@ if ($object->id > 0)
|
||||
print '<table class="noborder centpercent lastrecordtable">';
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td colspan="6"><table width="100%" class="nobordernopadding"><tr><td>'.$langs->trans("LastContracts", ($num <= $MAXLIST ? "" : $MAXLIST)).'</td>';
|
||||
print '<td colspan="5"><table width="100%" class="nobordernopadding"><tr><td>'.$langs->trans("LastContracts", ($num <= $MAXLIST ? "" : $MAXLIST)).'</td>';
|
||||
print '<td class="right"><a class="notasortlink" href="'.DOL_URL_ROOT.'/contrat/list.php?socid='.$object->id.'">'.$langs->trans("AllContracts").'<span class="badge marginleftonlyshort">'.$num.'</span></a></td>';
|
||||
//print '<td width="20px" class="right"><a href="'.DOL_URL_ROOT.'/contract/stats/index.php?socid='.$object->id.'">'.img_picto($langs->trans("Statistics"),'stats').'</a></td>';
|
||||
print '</tr></table></td>';
|
||||
@@ -937,15 +941,24 @@ if ($object->id > 0)
|
||||
$contrat->ref = $objp->ref ? $objp->ref : $objp->id;
|
||||
$contrat->ref_customer = $objp->refcus;
|
||||
$contrat->ref_supplier = $objp->refsup;
|
||||
$contrat->statut = $objp->contract_status;
|
||||
$contrat->fetch_lines();
|
||||
|
||||
$late = '';
|
||||
foreach ($contrat->lines as $line) {
|
||||
if ($contrat->statut == Contrat::STATUS_VALIDATED && $line->statut == ContratLigne::STATUS_OPEN) {
|
||||
if (((!empty($line->date_fin_validite)?$line->date_fin_validite:0) + $conf->contrat->services->expires->warning_delay) < $now) $late = img_warning($langs->trans("Late"));
|
||||
}
|
||||
}
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td class="nowrap">';
|
||||
print $contrat->getNomUrl(1, 12);
|
||||
print $late;
|
||||
print "</td>\n";
|
||||
print '<td class="nowrap">'.dol_trunc($objp->refsup, 12)."</td>\n";
|
||||
print '<td class="right" width="80px">'.dol_print_date($db->jdate($objp->dc), 'day')."</td>\n";
|
||||
print '<td class="right" width="80px">'.dol_print_date($db->jdate($objp->dcon), 'day')."</td>\n";
|
||||
//print '<td class="right" width="80px"><span title="'.$langs->trans("DateCreation").'">'.dol_print_date($db->jdate($objp->dc), 'day')."</span></td>\n";
|
||||
print '<td class="right" width="80px"><span title="'.$langs->trans("DateContract").'">'.dol_print_date($db->jdate($objp->dcon), 'day')."</span></td>\n";
|
||||
print '<td width="20"> </td>';
|
||||
print '<td class="nowraponall right">';
|
||||
print $contrat->getLibStatut(4);
|
||||
@@ -1137,7 +1150,7 @@ if ($object->id > 0)
|
||||
}
|
||||
|
||||
/*
|
||||
* Last invoices
|
||||
* Latest invoices
|
||||
*/
|
||||
if (!empty($conf->facture->enabled) && $user->rights->facture->lire)
|
||||
{
|
||||
|
||||
@@ -346,7 +346,7 @@ if (empty($reshook))
|
||||
if (!empty($conf->global->MAILING_DELAY))
|
||||
{
|
||||
dol_syslog("Wait a delay of MAILING_DELAY=".$conf->global->MAILING_DELAY);
|
||||
sleep($conf->global->MAILING_DELAY);
|
||||
usleep((float) $conf->global->MAILING_DELAY * 1000000);
|
||||
}
|
||||
|
||||
//test if CHECK READ change statut prospect contact
|
||||
|
||||
@@ -481,11 +481,27 @@ if ($object->fetch($id) >= 0)
|
||||
$sql .= " mc.source_url, mc.source_id, mc.source_type, mc.error_text";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."mailing_cibles as mc";
|
||||
$sql .= " WHERE mc.fk_mailing=".$object->id;
|
||||
if ($search_lastname) $sql .= natural_search("mc.lastname", $search_lastname);
|
||||
if ($search_firstname) $sql .= natural_search("mc.firstname", $search_firstname);
|
||||
if ($search_email) $sql .= natural_search("mc.email", $search_email);
|
||||
if ($search_other) $sql .= natural_search("mc.other", $search_other);
|
||||
if ($search_dest_status != '' && $search_dest_status >= -1) $sql .= " AND mc.statut=".$db->escape($search_dest_status)." ";
|
||||
$asearchcriteriahasbeenset = 0;
|
||||
if ($search_lastname) {
|
||||
$sql .= natural_search("mc.lastname", $search_lastname);
|
||||
$asearchcriteriahasbeenset++;
|
||||
}
|
||||
if ($search_firstname) {
|
||||
$sql .= natural_search("mc.firstname", $search_firstname);
|
||||
$asearchcriteriahasbeenset++;
|
||||
}
|
||||
if ($search_email) {
|
||||
$sql .= natural_search("mc.email", $search_email);
|
||||
$asearchcriteriahasbeenset++;
|
||||
}
|
||||
if ($search_other) {
|
||||
$sql .= natural_search("mc.other", $search_other);
|
||||
$asearchcriteriahasbeenset++;
|
||||
}
|
||||
if ($search_dest_status != '' && $search_dest_status >= -1) {
|
||||
$sql .= " AND mc.statut=".$db->escape($search_dest_status)." ";
|
||||
$asearchcriteriahasbeenset++;
|
||||
}
|
||||
$sql .= $db->order($sortfield, $sortorder);
|
||||
|
||||
// Count total nb of records
|
||||
@@ -499,6 +515,18 @@ if ($object->fetch($id) >= 0)
|
||||
$page = 0;
|
||||
$offset = 0;
|
||||
}
|
||||
|
||||
// Fix/update nbemail on emailing record if it differs (may happen if user edit lines from database directly)
|
||||
if (empty($asearchcriteriahasbeenset)) {
|
||||
if ($nbtotalofrecords != $object->email) {
|
||||
dol_syslog("We found a difference in nb of record in target table and the property ->nbemail, we fix ->nbemail");
|
||||
//print "nbemail=".$object->nbemail." nbtotalofrecords=".$nbtotalofrecords;
|
||||
$resultrefresh = $object->refreshNbOfTargets();
|
||||
if ($resultrefresh < 0) {
|
||||
dol_print_error($db, $object->error, $object->errors);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//$nbtotalofrecords=$object->nbemail; // nbemail is a denormalized field storing nb of targets
|
||||
|
||||
@@ -461,6 +461,8 @@ class Mailing extends CommonObject
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$this->refreshNbOfTargets();
|
||||
|
||||
return 1;
|
||||
}
|
||||
else
|
||||
@@ -532,6 +534,38 @@ class Mailing extends CommonObject
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Refresh denormalized value ->nbemail into emailing record
|
||||
* Note: There is also the method update_nb into modules_mailings that is used for this.
|
||||
*
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function refreshNbOfTargets()
|
||||
{
|
||||
$sql = "SELECT COUNT(rowid) as nb FROM ".MAIN_DB_PREFIX."mailing_cibles";
|
||||
$sql .= " WHERE fk_mailing = ".$this->id;
|
||||
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql) {
|
||||
$obj = $this->db->fetch_object($resql);
|
||||
if ($obj) {
|
||||
$nbforupdate = $obj->nb;
|
||||
|
||||
$sql = 'UPDATE '.MAIN_DB_PREFIX.'mailing SET nbemail = '.((int) $nbforupdate);
|
||||
$sql .= ' WHERE rowid = '.$this->id;
|
||||
|
||||
$resqlupdate = $this->db->query($sql);
|
||||
if (! $resqlupdate) {
|
||||
$this->error = $this->db->lasterror();
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$this->error = $this->db->lasterror();
|
||||
return -1;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a link to the object card (with optionally the picto)
|
||||
|
||||
@@ -194,7 +194,7 @@ if (empty($reshook))
|
||||
}
|
||||
}
|
||||
|
||||
$result = $object->createFromClone($user, $socid);
|
||||
$result = $object->createFromClone($user, $socid, (GETPOSTISSET('entity') ? GETPOST('entity', 'int') : null));
|
||||
if ($result > 0) {
|
||||
header("Location: ".$_SERVER['PHP_SELF'].'?id='.$result);
|
||||
exit();
|
||||
@@ -236,6 +236,7 @@ if (empty($reshook))
|
||||
$outputlangs->setDefaultLang($newlang);
|
||||
}
|
||||
$ret = $object->fetch($id); // Reload to get new records
|
||||
if ($ret > 0) $object->fetch_thirdparty();
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
|
||||
@@ -803,6 +804,7 @@ if (empty($reshook))
|
||||
$outputlangs->setDefaultLang($newlang);
|
||||
}
|
||||
$ret = $object->fetch($id); // Reload to get new records
|
||||
if ($ret > 0) $object->fetch_thirdparty();
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
}
|
||||
@@ -822,7 +824,7 @@ if (empty($reshook))
|
||||
elseif ($action == 'addline' && $usercancreate) {
|
||||
// Set if we used free entry or predefined product
|
||||
$predef = '';
|
||||
$product_desc = (GETPOST('dp_desc') ?GETPOST('dp_desc') : '');
|
||||
$product_desc = (GETPOST('dp_desc', 'none') ?GETPOST('dp_desc', 'none') : '');
|
||||
$price_ht = GETPOST('price_ht');
|
||||
$price_ht_devise = GETPOST('multicurrency_price_ht');
|
||||
$prod_entry_mode = GETPOST('prod_entry_mode');
|
||||
@@ -940,6 +942,7 @@ if (empty($reshook))
|
||||
if (count($prodcustprice->lines) > 0) {
|
||||
$pu_ht = price($prodcustprice->lines[0]->price);
|
||||
$pu_ttc = price($prodcustprice->lines[0]->price_ttc);
|
||||
$price_min = price($prodcustprice->lines[0]->price_min);
|
||||
$price_base_type = $prodcustprice->lines[0]->price_base_type;
|
||||
$tva_tx = ($prodcustprice->lines[0]->default_vat_code ? $prodcustprice->lines[0]->tva_tx.' ('.$prodcustprice->lines[0]->default_vat_code.' )' : $prodcustprice->lines[0]->tva_tx);
|
||||
if ($prodcustprice->lines[0]->default_vat_code && !preg_match('/\(.*\)/', $tva_tx)) $tva_tx .= ' ('.$prodcustprice->lines[0]->default_vat_code.')';
|
||||
@@ -1138,6 +1141,9 @@ if (empty($reshook))
|
||||
$outputlangs->setDefaultLang($newlang);
|
||||
}
|
||||
$ret = $object->fetch($id); // Reload to get new records
|
||||
if ($ret > 0) {
|
||||
$object->fetch_thirdparty();
|
||||
}
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
|
||||
@@ -1281,6 +1287,7 @@ if (empty($reshook))
|
||||
$outputlangs->setDefaultLang($newlang);
|
||||
}
|
||||
$ret = $object->fetch($id); // Reload to get new records
|
||||
if ($ret > 0) $object->fetch_thirdparty();
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
|
||||
@@ -1832,10 +1839,9 @@ if ($action == 'create')
|
||||
|
||||
print '<tr><td class="tdtop"><input type="radio" name="createmode" value="empty" checked></td>';
|
||||
print '<td valign="top" colspan="2">'.$langs->trans("CreateEmptyPropal").'</td></tr>';
|
||||
print '</table>';
|
||||
}
|
||||
|
||||
if (!empty($conf->global->PROPAL_CLONE_ON_CREATE_PAGE)) print '</table>';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
$langs->load("bills");
|
||||
@@ -1878,11 +1884,11 @@ if ($action == 'create')
|
||||
if ($action == 'clone') {
|
||||
// Create an array for form
|
||||
$formquestion = array(
|
||||
// 'text' => $langs->trans("ConfirmClone"),
|
||||
// array('type' => 'checkbox', 'name' => 'clone_content', 'label' => $langs->trans("CloneMainAttributes"), 'value' => 1),
|
||||
// array('type' => 'checkbox', 'name' => 'update_prices', 'label' => $langs->trans("PuttingPricesUpToDate"), 'value' =>
|
||||
// 1),
|
||||
array('type' => 'other', 'name' => 'socid', 'label' => $langs->trans("SelectThirdParty"), 'value' => $form->select_company(GETPOST('socid', 'int'), 'socid', '(s.client=1 OR s.client=2 OR s.client=3)')));
|
||||
// 'text' => $langs->trans("ConfirmClone"),
|
||||
// array('type' => 'checkbox', 'name' => 'clone_content', 'label' => $langs->trans("CloneMainAttributes"), 'value' => 1),
|
||||
// array('type' => 'checkbox', 'name' => 'update_prices', 'label' => $langs->trans("PuttingPricesUpToDate"), 'value' => 1),
|
||||
array('type' => 'other', 'name' => 'socid', 'label' => $langs->trans("SelectThirdParty"), 'value' => $form->select_company(GETPOST('socid', 'int'), 'socid', '(s.client=1 OR s.client=2 OR s.client=3)'))
|
||||
);
|
||||
if (!empty($conf->global->PROPAL_CLONE_DATE_DELIVERY) && !empty($object->date_livraison)) {
|
||||
$formquestion[] = array('type' => 'date', 'name' => 'date_delivery', 'label' => $langs->trans("DeliveryDate"), 'value' => $object->date_livraison);
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
* Copyright (C) 2005-2013 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
|
||||
* Copyright (C) 2008 Raphael Bertrand <raphael.bertrand@resultic.fr>
|
||||
* Copyright (C) 2010-2019 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2010-2020 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2010-2017 Philippe Grand <philippe.grand@atoo-net.com>
|
||||
* Copyright (C) 2012-2014 Christophe Battarel <christophe.battarel@altairis.fr>
|
||||
* Copyright (C) 2012 Cedric Salvador <csalvador@gpcsolutions.fr>
|
||||
@@ -483,6 +483,7 @@ class Propal extends CommonObject
|
||||
else
|
||||
{
|
||||
$this->error = $line->error;
|
||||
$this->errors = $line->errors;
|
||||
$this->db->rollback();
|
||||
return -2;
|
||||
}
|
||||
@@ -602,6 +603,7 @@ class Propal extends CommonObject
|
||||
|
||||
// Clean vat code
|
||||
$vat_src_code = '';
|
||||
$reg = array();
|
||||
if (preg_match('/\((.*)\)/', $txtva, $reg))
|
||||
{
|
||||
$vat_src_code = $reg[1];
|
||||
@@ -726,6 +728,7 @@ class Propal extends CommonObject
|
||||
else
|
||||
{
|
||||
$this->error = $this->line->error;
|
||||
$this->errors = $this->line->errors;
|
||||
$this->db->rollback();
|
||||
return -2;
|
||||
}
|
||||
@@ -779,7 +782,9 @@ class Propal extends CommonObject
|
||||
$qty = price2num($qty);
|
||||
$pu = price2num($pu);
|
||||
$pu_ht_devise = price2num($pu_ht_devise);
|
||||
$txtva = price2num($txtva);
|
||||
if (!preg_match('/\((.*)\)/', $txtva)) {
|
||||
$txtva = price2num($txtva); // $txtva can have format '5.0(XXX)' or '5'
|
||||
}
|
||||
$txlocaltax1 = price2num($txlocaltax1);
|
||||
$txlocaltax2 = price2num($txlocaltax2);
|
||||
$pa_ht = price2num($pa_ht);
|
||||
@@ -921,7 +926,7 @@ class Propal extends CommonObject
|
||||
else
|
||||
{
|
||||
$this->error = $this->line->error;
|
||||
|
||||
$this->errors = $this->line->errors;
|
||||
$this->db->rollback();
|
||||
return -1;
|
||||
}
|
||||
@@ -1324,9 +1329,10 @@ class Propal extends CommonObject
|
||||
*
|
||||
* @param User $user User making the clone
|
||||
* @param int $socid Id of thirdparty
|
||||
* @param int $forceentity Entity id to force
|
||||
* @return int New id of clone
|
||||
*/
|
||||
public function createFromClone(User $user, $socid = 0)
|
||||
public function createFromClone(User $user, $socid = 0, $forceentity = null)
|
||||
{
|
||||
global $conf, $hookmanager;
|
||||
|
||||
@@ -1343,7 +1349,6 @@ class Propal extends CommonObject
|
||||
|
||||
// Load source object
|
||||
$object->fetch($this->id);
|
||||
$object->fetch_lines();
|
||||
|
||||
$objsoc = new Societe($this->db);
|
||||
|
||||
@@ -1382,6 +1387,7 @@ class Propal extends CommonObject
|
||||
|
||||
$object->id = 0;
|
||||
$object->ref = '';
|
||||
$object->entity = (! empty($forceentity) ? $forceentity : $object->entity);
|
||||
$object->statut = self::STATUS_DRAFT;
|
||||
|
||||
// Clear fields
|
||||
@@ -1537,7 +1543,9 @@ class Propal extends CommonObject
|
||||
$this->note = $obj->note_private; // TODO deprecated
|
||||
$this->note_private = $obj->note_private;
|
||||
$this->note_public = $obj->note_public;
|
||||
$this->statut = (int) $obj->fk_statut;
|
||||
|
||||
$this->status = (int) $obj->fk_statut;
|
||||
$this->statut = $this->status; // deprecated
|
||||
$this->statut_libelle = $obj->statut_label;
|
||||
|
||||
$this->datec = $this->db->jdate($obj->datec); // TODO deprecated
|
||||
@@ -1734,7 +1742,7 @@ class Propal extends CommonObject
|
||||
$sql = 'SELECT d.rowid, d.fk_propal, d.fk_parent_line, d.label as custom_label, d.description, d.price, d.vat_src_code, d.tva_tx, d.localtax1_tx, d.localtax2_tx, d.localtax1_type, d.localtax2_type, d.qty, d.fk_remise_except, d.remise_percent, d.subprice, d.fk_product,';
|
||||
$sql .= ' d.info_bits, d.total_ht, d.total_tva, d.total_localtax1, d.total_localtax2, d.total_ttc, d.fk_product_fournisseur_price as fk_fournprice, d.buy_price_ht as pa_ht, d.special_code, d.rang, d.product_type,';
|
||||
$sql .= ' d.fk_unit,';
|
||||
$sql .= ' p.ref as product_ref, p.description as product_desc, p.fk_product_type, p.label as product_label, p.tobatch as product_batch,';
|
||||
$sql .= ' p.ref as product_ref, p.description as product_desc, p.fk_product_type, p.label as product_label, p.tobatch as product_tobatch, p.barcode as product_barcode,';
|
||||
$sql .= ' p.weight, p.weight_units, p.volume, p.volume_units,';
|
||||
$sql .= ' d.date_start, d.date_end,';
|
||||
$sql .= ' d.fk_multicurrency, d.multicurrency_code, d.multicurrency_subprice, d.multicurrency_total_ht, d.multicurrency_total_tva, d.multicurrency_total_ttc';
|
||||
@@ -1796,11 +1804,14 @@ class Propal extends CommonObject
|
||||
$line->fk_product = $objp->fk_product;
|
||||
|
||||
$line->ref = $objp->product_ref; // deprecated
|
||||
$line->product_ref = $objp->product_ref;
|
||||
$line->libelle = $objp->product_label; // deprecated
|
||||
|
||||
$line->product_ref = $objp->product_ref;
|
||||
$line->product_label = $objp->product_label;
|
||||
$line->product_desc = $objp->product_desc; // Description produit
|
||||
$line->product_tobatch = $objp->product_tobatch;
|
||||
$line->product_barcode = $objp->product_barcode;
|
||||
|
||||
$line->fk_product_type = $objp->fk_product_type; // deprecated
|
||||
$line->fk_unit = $objp->fk_unit;
|
||||
$line->weight = $objp->weight;
|
||||
@@ -2999,9 +3010,9 @@ class Propal extends CommonObject
|
||||
|
||||
if (!$error)
|
||||
{
|
||||
$main = MAIN_DB_PREFIX.'propaldet';
|
||||
$ef = $main."_extrafields";
|
||||
$sqlef = "DELETE FROM $ef WHERE fk_object IN (SELECT rowid FROM $main WHERE fk_propal = ".$this->id.")";
|
||||
$main = MAIN_DB_PREFIX.'propaldet';
|
||||
$ef = $main."_extrafields";
|
||||
$sqlef = "DELETE FROM $ef WHERE fk_object IN (SELECT rowid FROM $main WHERE fk_propal = ".$this->id.")";
|
||||
$sql = "DELETE FROM ".MAIN_DB_PREFIX."propaldet WHERE fk_propal = ".$this->id;
|
||||
if ($this->db->query($sqlef) && $this->db->query($sql))
|
||||
{
|
||||
@@ -3018,6 +3029,9 @@ class Propal extends CommonObject
|
||||
|
||||
if (!$error)
|
||||
{
|
||||
// Delete record into ECM index (Note that delete is also done when deleting files with the dol_delete_dir_recursive
|
||||
$this->deleteEcmFiles();
|
||||
|
||||
// We remove directory
|
||||
$ref = dol_sanitizeFileName($this->ref);
|
||||
if ($conf->propal->multidir_output[$this->entity] && !empty($this->ref))
|
||||
@@ -3783,6 +3797,7 @@ class Propal extends CommonObject
|
||||
global $conf, $langs;
|
||||
|
||||
$langs->load("propale");
|
||||
$outputlangs->load("products");
|
||||
|
||||
if (!dol_strlen($modele)) {
|
||||
$modele = 'azur';
|
||||
@@ -3916,6 +3931,18 @@ class PropaleLigne extends CommonObjectLine
|
||||
*/
|
||||
public $product_desc;
|
||||
|
||||
/**
|
||||
* Product use lot
|
||||
* @var string
|
||||
*/
|
||||
public $product_tobatch;
|
||||
|
||||
/**
|
||||
* Product barcode
|
||||
* @var string
|
||||
*/
|
||||
public $product_barcode;
|
||||
|
||||
public $localtax1_tx; // Local tax 1
|
||||
public $localtax2_tx; // Local tax 2
|
||||
public $localtax1_type; // Local tax 1 type
|
||||
|
||||
@@ -282,7 +282,7 @@ $help_url = 'EN:Commercial_Proposals|FR:Proposition_commerciale|ES:Presupuestos'
|
||||
//llxHeader('',$langs->trans('Proposal'),$help_url);
|
||||
|
||||
$sql = 'SELECT';
|
||||
if ($sall || $search_product_category > 0) $sql = 'SELECT DISTINCT';
|
||||
if ($sall || $search_product_category > 0 || $search_user > 0) $sql = 'SELECT DISTINCT';
|
||||
$sql .= ' s.rowid as socid, s.nom as name, s.email, s.town, s.zip, s.fk_pays, s.client, s.code_client, ';
|
||||
$sql .= " typent.code as typent_code,";
|
||||
$sql .= " ava.rowid as availability,";
|
||||
|
||||
@@ -37,11 +37,11 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
$WIDTH = DolGraph::getDefaultGraphSizeForStats('width');
|
||||
$HEIGHT = DolGraph::getDefaultGraphSizeForStats('height');
|
||||
|
||||
$mode = GETPOST("mode") ?GETPOST("mode") : 'customer';
|
||||
$mode = GETPOSTISSET("mode") ? GETPOST("mode", 'aZ09') : 'customer';
|
||||
if ($mode == 'customer' && !$user->rights->propale->lire) accessforbidden();
|
||||
if ($mode == 'supplier' && !$user->rights->supplier_proposal->lire) accessforbidden();
|
||||
|
||||
$object_status = GETPOST('object_status');
|
||||
$object_status = GETPOST('object_status', 'intcomma');
|
||||
$typent_id = GETPOST('typent_id', 'int');
|
||||
$categ_id = GETPOST('categ_id', 'categ_id');
|
||||
|
||||
@@ -55,7 +55,7 @@ if ($user->socid > 0)
|
||||
}
|
||||
|
||||
$nowyear = strftime("%Y", dol_now());
|
||||
$year = GETPOST('year') > 0 ?GETPOST('year') : $nowyear;
|
||||
$year = GETPOST('year') > 0 ? GETPOST('year', 'int') : $nowyear;
|
||||
//$startyear=$year-2;
|
||||
$startyear = $year - 1;
|
||||
$endyear = $year;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user