Compare commits
27 Commits
c959517369
...
873d84ede0
| Author | SHA1 | Date | |
|---|---|---|---|
| 873d84ede0 | |||
|
|
07c06d2d5f | ||
|
|
b0c82236aa | ||
|
|
c19f3651c5 | ||
|
|
5c984bb60e | ||
|
|
efabb48222 | ||
|
|
c638e580cb | ||
|
|
d43fc619d5 | ||
|
|
7468d94b64 | ||
|
|
e3f73ac2dd | ||
|
|
ac9a74740d | ||
|
|
bc2aaf180e | ||
|
|
dd98349f7f | ||
|
|
6aff60b57d | ||
|
|
42735388b7 | ||
|
|
a1a5c532f7 | ||
|
|
f85d1820cf | ||
|
|
6615306b8b | ||
|
|
0c3ed5ddce | ||
|
|
c0b1a9723c | ||
|
|
b3124ed8e4 | ||
|
|
a87dd3be33 | ||
|
|
88e0dcb717 | ||
|
|
887105b081 | ||
|
|
77ddd77ac1 | ||
|
|
a948eaf878 | ||
|
|
5077dfb95e |
@ -6,7 +6,7 @@ const nextConfig = {
|
|||||||
styledComponents: true,
|
styledComponents: true,
|
||||||
},
|
},
|
||||||
images: {
|
images: {
|
||||||
domains: ["kluppdevelopment.s3.sa-east-1.amazonaws.com", "api.energiasmart.com.br"]
|
domains: ["kluppdevelopment.s3.sa-east-1.amazonaws.com", "http://127.0.0.1:8000"]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
20745
package-lock.json
generated
9
public-2022-08-23/SUL.svg
Normal file
|
After Width: | Height: | Size: 16 KiB |
3
public-2022-08-23/assets/Vector4.svg
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<svg width="380" height="1" viewBox="0 0 380 1" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M0.272217 0.564575L379.052 0.564556" stroke="#E1E1E1" stroke-width="0.7"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 187 B |
BIN
public-2022-08-23/assets/banners/aboutUs.jpg
Normal file
|
After Width: | Height: | Size: 282 KiB |
BIN
public-2022-08-23/assets/banners/aboutUsBanner.png
Normal file
|
After Width: | Height: | Size: 3.6 MiB |
BIN
public-2022-08-23/assets/banners/faq.jpg
Normal file
|
After Width: | Height: | Size: 67 KiB |
BIN
public-2022-08-23/assets/banners/faq1.png
Normal file
|
After Width: | Height: | Size: 394 KiB |
BIN
public-2022-08-23/assets/banners/infoSetorial.jpg
Normal file
|
After Width: | Height: | Size: 52 KiB |
BIN
public-2022-08-23/assets/banners/news.png
Normal file
|
After Width: | Height: | Size: 588 KiB |
BIN
public-2022-08-23/assets/banners/newsBanner.webp
Normal file
|
After Width: | Height: | Size: 440 KiB |
BIN
public-2022-08-23/assets/banners/notificacoes.jpg
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
public-2022-08-23/assets/banners/sectoriaInf.jpg
Normal file
|
After Width: | Height: | Size: 438 KiB |
BIN
public-2022-08-23/assets/graphical.png
Normal file
|
After Width: | Height: | Size: 599 KiB |
5
public-2022-08-23/assets/hamburgerModal.svg
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<svg width="26" height="19" viewBox="0 0 26 19" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<rect y="0.118652" width="26" height="2.93413" rx="1.46706" fill="#3E4954"/>
|
||||||
|
<rect y="7.94299" width="26" height="2.93413" rx="1.46706" fill="#3E4954"/>
|
||||||
|
<rect y="15.7673" width="26" height="2.93413" rx="1.46706" fill="#3E4954"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 332 B |
BIN
public-2022-08-23/assets/headerName.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
public-2022-08-23/assets/iconePDF.png
Normal file
|
After Width: | Height: | Size: 6.3 KiB |
3
public-2022-08-23/assets/less-icon.svg
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<svg width="33" height="33" viewBox="0 0 33 33" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M8.4917 16.1553H24.8894" stroke="#254F7F" stroke-width="1.2" stroke-linecap="round"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 198 B |
11
public-2022-08-23/assets/listIcon.svg
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
<svg width="32" height="33" viewBox="0 0 32 33" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M0 16.0497C0 7.21311 7.16344 0.00195312 16 0.00195312C24.8366 0.00195312 32 7.21311 32 16.0497C32 24.8862 24.8366 32.0974 16 32.0974C7.16344 32.0974 0 24.8862 0 16.0497Z" fill="#F2F4F7"/>
|
||||||
|
<g clip-path="url(#clip0_125_1603)">
|
||||||
|
<path d="M16.6667 9.33496L10 17.335H16L15.3333 22.6683L22 14.6683H16L16.6667 9.33496Z" stroke="#475467" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
|
</g>
|
||||||
|
<defs>
|
||||||
|
<clipPath id="clip0_125_1603">
|
||||||
|
<rect width="16" height="16" fill="white" transform="translate(8 8.00195)"/>
|
||||||
|
</clipPath>
|
||||||
|
</defs>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 653 B |
9
public-2022-08-23/assets/logo.svg
Normal file
|
After Width: | Height: | Size: 859 KiB |
BIN
public-2022-08-23/assets/logose.png
Normal file
|
After Width: | Height: | Size: 5.0 KiB |
3
public-2022-08-23/assets/logout.svg
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<svg width="24px" height="24px" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path fill="none" stroke="#F00" stroke-width="2" d="M13,9 L13,2 L1,2 L1,22 L13,22 L13,15 M22,12 L5,12 M17,7 L22,12 L17,17"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 222 B |
BIN
public-2022-08-23/assets/marca1.png
Normal file
|
After Width: | Height: | Size: 126 KiB |
4
public-2022-08-23/assets/plus-icon.svg
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
<svg width="33" height="33" viewBox="0 0 33 33" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M8.49219 16.79H24.8899" stroke="black" stroke-width="1.2" stroke-linecap="round"/>
|
||||||
|
<path d="M16.6909 8.5918L16.6909 24.9895" stroke="black" stroke-width="1.2" stroke-linecap="round"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 296 B |
BIN
public-2022-08-23/assets/png/copel.png
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
public-2022-08-23/assets/png/copel.xcf
Normal file
3
public-2022-08-23/assets/sidebar/aboutUs.svg
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" className="h-5 w-5" viewBox="0 0 20 20" fill="white" stroke='gray'>
|
||||||
|
<path d="M13 6a3 3 0 11-6 0 3 3 0 016 0zM18 8a2 2 0 11-4 0 2 2 0 014 0zM14 15a4 4 0 00-8 0v3h8v-3zM6 8a2 2 0 11-4 0 2 2 0 014 0zM16 18v-3a5.972 5.972 0 00-.75-2.906A3.005 3.005 0 0119 15v3h-3zM4.75 12.094A5.973 5.973 0 004 15v3H1v-3a3 3 0 013.75-2.906z" />
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 372 B |
6
public-2022-08-23/assets/sidebar/consumptionIcon.svg
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M17.25 23.3618C17.8465 23.3612 18.4185 23.1239 18.8403 22.7021C19.2621 22.2803 19.4993 21.7084 19.5 21.1118V18.0766C19.5 17.8777 19.421 17.687 19.2803 17.5463C19.1397 17.4057 18.9489 17.3266 18.75 17.3266C18.5511 17.3266 18.3603 17.4057 18.2197 17.5463C18.079 17.687 18 17.8777 18 18.0766V21.1118C17.9998 21.3107 17.9207 21.5013 17.7801 21.6419C17.6395 21.7826 17.4489 21.8616 17.25 21.8618H3.75C3.55114 21.8616 3.36048 21.7826 3.21987 21.6419C3.07925 21.5013 3.00018 21.3107 3 21.1118V4.61182C3.00018 4.41296 3.07925 4.2223 3.21987 4.08168C3.36048 3.94107 3.55114 3.862 3.75 3.86182H17.25C17.4489 3.862 17.6395 3.94107 17.7801 4.08168C17.9207 4.2223 17.9998 4.41296 18 4.61182V6.92482C18 7.12373 18.079 7.31449 18.2197 7.45515C18.3603 7.5958 18.5511 7.67482 18.75 7.67482C18.9489 7.67482 19.1397 7.5958 19.2803 7.45515C19.421 7.31449 19.5 7.12373 19.5 6.92482V4.61182C19.4993 4.01528 19.2621 3.44336 18.8403 3.02155C18.4185 2.59973 17.8465 2.36247 17.25 2.36182H3.75C3.15346 2.36247 2.58155 2.59973 2.15973 3.02155C1.73792 3.44336 1.50066 4.01528 1.5 4.61182V21.1118C1.50066 21.7084 1.73792 22.2803 2.15973 22.7021C2.58155 23.1239 3.15346 23.3612 3.75 23.3618H17.25Z" fill="#969BA0"/>
|
||||||
|
<path d="M5.25 15.1118C5.05109 15.1118 4.86032 15.1908 4.71967 15.3315C4.57902 15.4721 4.5 15.6629 4.5 15.8618C4.5 16.0607 4.57902 16.2515 4.71967 16.3921C4.86032 16.5328 5.05109 16.6118 5.25 16.6118H8.25C8.44891 16.6118 8.63968 16.5328 8.78033 16.3921C8.92098 16.2515 9 16.0607 9 15.8618C9 15.6629 8.92098 15.4721 8.78033 15.3315C8.63968 15.1908 8.44891 15.1118 8.25 15.1118H5.25Z" fill="#969BA0"/>
|
||||||
|
<path d="M19.9548 8.78575C19.8142 8.64515 19.6234 8.56616 19.4246 8.56616C19.2257 8.56616 19.0349 8.64515 18.8943 8.78575L11.4698 16.2103C11.4001 16.2799 11.3448 16.3626 11.3071 16.4536C11.2694 16.5446 11.25 16.6421 11.25 16.7406V18.1117H5.25C5.05109 18.1117 4.86032 18.1907 4.71967 18.3314C4.57902 18.472 4.5 18.6628 4.5 18.8617C4.5 19.0606 4.57902 19.2514 4.71967 19.392C4.86032 19.5327 5.05109 19.6117 5.25 19.6117H14.1215C14.3203 19.6117 14.5111 19.5326 14.6517 19.392L22.0767 11.9674C22.2173 11.8268 22.2963 11.636 22.2963 11.4372C22.2963 11.2383 22.2173 11.0475 22.0767 10.9069L19.9548 8.78575ZM13.811 18.1117H12.75V17.0511L19.4246 10.3766L20.4855 11.4372L13.811 18.1117Z" fill="#969BA0"/>
|
||||||
|
<path d="M11.25 8.73682C11.25 8.06931 11.0521 7.41678 10.6812 6.86177C10.3104 6.30675 9.78326 5.87417 9.16656 5.61872C8.54986 5.36328 7.87126 5.29644 7.21657 5.42667C6.56189 5.55689 5.96052 5.87833 5.48852 6.35033C5.01651 6.82233 4.69508 7.4237 4.56485 8.07839C4.43463 8.73307 4.50146 9.41167 4.75691 10.0284C5.01235 10.6451 5.44494 11.1722 5.99995 11.543C6.55497 11.9139 7.20749 12.1118 7.875 12.1118C8.7698 12.1108 9.62767 11.7549 10.2604 11.1222C10.8931 10.4895 11.249 9.63162 11.25 8.73682ZM7.875 10.6118C7.50416 10.6118 7.14165 10.5019 6.83331 10.2958C6.52497 10.0898 6.28464 9.79696 6.14273 9.45435C6.00081 9.11174 5.96368 8.73474 6.03603 8.37102C6.10838 8.00731 6.28695 7.67322 6.54918 7.41099C6.8114 7.14877 7.14549 6.97019 7.50921 6.89785C7.87292 6.8255 8.24992 6.86263 8.59253 7.00454C8.93514 7.14646 9.22798 7.38678 9.43401 7.69512C9.64003 8.00347 9.75 8.36598 9.75 8.73682C9.74949 9.23394 9.55178 9.71055 9.20026 10.0621C8.84874 10.4136 8.37212 10.6113 7.875 10.6118Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 3.3 KiB |
6
public-2022-08-23/assets/sidebar/dashboardIcon.svg
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M12 22.6118C14.5859 22.6118 17.0658 21.5846 18.8943 19.7561C20.7228 17.9276 21.75 15.4477 21.75 12.8618C21.75 10.276 20.7228 7.79601 18.8943 5.96753C17.0658 4.13905 14.5859 3.11182 12 3.11182C11.8011 3.11182 11.6103 3.19083 11.4697 3.33149C11.329 3.47214 11.25 3.6629 11.25 3.86182V6.11182C11.25 6.31073 11.329 6.50149 11.4697 6.64215C11.6103 6.7828 11.8011 6.86182 12 6.86182C12.1989 6.86182 12.3897 6.7828 12.5303 6.64215C12.671 6.50149 12.75 6.31073 12.75 6.11182V4.64549C14.3112 4.78811 15.7995 5.37263 17.0405 6.33058C18.2816 7.28853 19.2239 8.58026 19.7573 10.0545C20.2907 11.5287 20.393 13.1244 20.0522 14.6546C19.7114 16.1849 18.9417 17.5864 17.8331 18.6949C16.7245 19.8035 15.3231 20.5732 13.7928 20.914C12.2626 21.2548 10.6669 21.1525 9.19266 20.6191C7.71844 20.0858 6.42672 19.1434 5.46877 17.9024C4.51081 16.6613 3.9263 15.1731 3.78367 13.6118H5.25C5.44891 13.6118 5.63968 13.5328 5.78033 13.3921C5.92098 13.2515 6 13.0607 6 12.8618C6 12.6629 5.92098 12.4721 5.78033 12.3315C5.63968 12.1908 5.44891 12.1118 5.25 12.1118H3C2.80109 12.1118 2.61032 12.1908 2.46967 12.3315C2.32902 12.4721 2.25 12.6629 2.25 12.8618C2.25292 15.4468 3.28108 17.925 5.10893 19.7529C6.93678 21.5807 9.41503 22.6089 12 22.6118Z" fill="#969BA0"/>
|
||||||
|
<path d="M10.5559 12.4782C10.5206 12.6031 10.5018 12.732 10.5 12.8618C10.5 13.1584 10.588 13.4485 10.7528 13.6951C10.9176 13.9418 11.1519 14.1341 11.426 14.2476C11.7001 14.3611 12.0017 14.3908 12.2926 14.3329C12.5836 14.2751 12.8509 14.1322 13.0607 13.9224C13.2705 13.7127 13.4133 13.4454 13.4712 13.1544C13.5291 12.8634 13.4994 12.5618 13.3858 12.2877C13.2723 12.0137 13.08 11.7794 12.8334 11.6146C12.5867 11.4497 12.2967 11.3618 12 11.3618C11.8703 11.3635 11.7413 11.3823 11.6165 11.4177L6.15525 5.95651C6.08607 5.88487 6.00331 5.82774 5.9118 5.78843C5.8203 5.74912 5.72189 5.72843 5.6223 5.72757C5.52272 5.7267 5.42396 5.74568 5.33179 5.78339C5.23961 5.8211 5.15587 5.87679 5.08545 5.94721C5.01503 6.01763 4.95934 6.10137 4.92163 6.19354C4.88392 6.28571 4.86495 6.38447 4.86581 6.48406C4.86668 6.58364 4.88737 6.68206 4.92667 6.77356C4.96598 6.86506 5.02312 6.94782 5.09475 7.01701L10.5559 12.4782Z" fill="#969BA0"/>
|
||||||
|
<path d="M15.75 12.8618C15.75 13.0607 15.829 13.2515 15.9697 13.3921C16.1103 13.5328 16.3011 13.6118 16.5 13.6118H18C18.1989 13.6118 18.3897 13.5328 18.5303 13.3921C18.671 13.2515 18.75 13.0607 18.75 12.8618C18.75 12.6629 18.671 12.4721 18.5303 12.3315C18.3897 12.1908 18.1989 12.1118 18 12.1118H16.5C16.3011 12.1118 16.1103 12.1908 15.9697 12.3315C15.829 12.4721 15.75 12.6629 15.75 12.8618Z" fill="#969BA0"/>
|
||||||
|
<path d="M15.7125 8.08847L14.6514 9.1492C14.5817 9.21883 14.5264 9.30151 14.4887 9.39251C14.451 9.48351 14.4315 9.58105 14.4315 9.67956C14.4315 9.77807 14.4508 9.87562 14.4885 9.96665C14.5262 10.0577 14.5814 10.1404 14.651 10.2101C14.7207 10.2798 14.8033 10.335 14.8943 10.3728C14.9853 10.4105 15.0829 10.4299 15.1814 10.43C15.2799 10.43 15.3775 10.4106 15.4685 10.373C15.5595 10.3353 15.6422 10.2801 15.7119 10.2104L16.7732 9.14995C16.8429 9.0803 16.8982 8.9976 16.936 8.90659C16.9737 8.81557 16.9931 8.71801 16.9932 8.61947C16.9932 8.52094 16.9738 8.42337 16.9362 8.33232C16.8985 8.24128 16.8433 8.15854 16.7736 8.08885C16.704 8.01915 16.6213 7.96385 16.5302 7.92611C16.4392 7.88837 16.3417 7.86893 16.2431 7.8689C16.1446 7.86886 16.047 7.88823 15.956 7.92591C15.8649 7.96358 15.7822 8.01882 15.7125 8.08847Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 3.4 KiB |
5
public-2022-08-23/assets/sidebar/economyIcon.svg
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M9.75 13.6118C10.3433 13.6118 10.9234 13.4359 11.4167 13.1062C11.9101 12.7766 12.2946 12.308 12.5216 11.7599C12.7487 11.2117 12.8081 10.6085 12.6924 10.0265C12.5766 9.4446 12.2909 8.91006 11.8713 8.4905C11.4518 8.07094 10.9172 7.78522 10.3353 7.66946C9.75333 7.55371 9.15013 7.61312 8.60195 7.84018C8.05377 8.06724 7.58524 8.45176 7.25559 8.94511C6.92595 9.43846 6.75 10.0185 6.75 10.6118C6.75077 11.4072 7.06709 12.1698 7.62954 12.7323C8.19198 13.2947 8.95459 13.611 9.75 13.6118ZM9.75 9.11182C10.0467 9.11182 10.3367 9.19979 10.5834 9.36461C10.83 9.52944 11.0223 9.7637 11.1358 10.0378C11.2494 10.3119 11.2791 10.6135 11.2212 10.9045C11.1633 11.1954 11.0204 11.4627 10.8107 11.6725C10.6009 11.8823 10.3336 12.0251 10.0426 12.083C9.75166 12.1409 9.45006 12.1112 9.17598 11.9976C8.90189 11.8841 8.66762 11.6918 8.5028 11.4452C8.33797 11.1985 8.25 10.9085 8.25 10.6118C8.25054 10.2142 8.40874 9.83294 8.68993 9.55175C8.97112 9.27056 9.35234 9.11235 9.75 9.11182Z" fill="#969BA0"/>
|
||||||
|
<path d="M21.468 15.5393C21.7156 15.2077 21.881 14.8221 21.9506 14.4142C22.0203 14.0063 21.9922 13.5876 21.8686 13.1927L21.3925 11.6436C21.169 10.9089 20.7146 10.2658 20.0967 9.80978C19.4789 9.35372 18.7304 9.10897 17.9625 9.11184H14.5972C14.3983 9.11184 14.2075 9.19086 14.0668 9.33151C13.9262 9.47216 13.8472 9.66293 13.8472 9.86184C13.8472 10.0608 13.9262 10.2515 14.0668 10.3922C14.2075 10.5328 14.3983 10.6118 14.5972 10.6118H17.9625C18.4094 10.6103 18.8448 10.7528 19.2043 11.0183C19.5638 11.2837 19.8282 11.6579 19.9583 12.0854L20.4344 13.6338C20.487 13.8046 20.4987 13.9853 20.4687 14.1615C20.4387 14.3376 20.3678 14.5043 20.2616 14.648C20.1555 14.7918 20.0171 14.9087 19.8576 14.9892C19.6981 15.0698 19.5219 15.1118 19.3432 15.1118H12.4666C12.4453 15.1118 12.4276 15.1221 12.4066 15.1239C12.3562 15.122 12.3075 15.1118 12.2563 15.1118H7.55384C6.7204 15.1088 5.9082 15.3746 5.2378 15.8698C4.56741 16.3649 4.07456 17.0631 3.83241 17.8606L3.27246 19.6793C3.14167 20.105 3.11256 20.5553 3.18746 20.9943C3.26236 21.4332 3.4392 21.8484 3.70375 22.2066C3.9683 22.5647 4.31318 22.8558 4.71069 23.0565C5.10819 23.2571 5.54722 23.3617 5.99249 23.3618H13.8172C14.2625 23.3617 14.7015 23.2572 15.0991 23.0566C15.4966 22.856 15.8415 22.5649 16.1061 22.2067C16.3707 21.8485 16.5476 21.4333 16.6225 20.9943C16.6974 20.5554 16.6683 20.105 16.5375 19.6793L15.9779 17.8607C15.8362 17.4078 15.613 16.9846 15.3193 16.6118H19.3432C19.757 16.6137 20.1652 16.5175 20.5346 16.3311C20.9039 16.1447 21.2238 15.8733 21.468 15.5393ZM14.8996 21.3152C14.7753 21.4854 14.6123 21.6237 14.4241 21.7187C14.236 21.8137 14.028 21.8628 13.8172 21.8618H5.99249C5.78189 21.8618 5.57423 21.8124 5.38622 21.7175C5.19821 21.6226 5.0351 21.4849 4.91 21.3155C4.7849 21.146 4.7013 20.9496 4.66594 20.742C4.63058 20.5344 4.64443 20.3214 4.70639 20.1201L5.26596 18.3015C5.41462 17.8112 5.71752 17.3819 6.12964 17.0775C6.54176 16.7731 7.04111 16.6098 7.55346 16.6118H12.256C12.7683 16.6098 13.2677 16.7731 13.6798 17.0775C14.0919 17.3819 14.3948 17.8112 14.5435 18.3015L15.103 20.1201C15.1661 20.3212 15.1806 20.5345 15.1452 20.7423C15.1099 20.9501 15.0257 21.1465 14.8996 21.3155V21.3152Z" fill="#969BA0"/>
|
||||||
|
<path d="M16.125 7.61181C16.6442 7.61181 17.1517 7.45786 17.5834 7.16942C18.015 6.88098 18.3515 6.47101 18.5502 5.99136C18.7489 5.5117 18.8008 4.9839 18.6996 4.4747C18.5983 3.9655 18.3483 3.49777 17.9812 3.13066C17.614 2.76355 17.1463 2.51354 16.6371 2.41226C16.1279 2.31097 15.6001 2.36295 15.1205 2.56163C14.6408 2.76031 14.2308 3.09677 13.9424 3.52844C13.654 3.96012 13.5 4.46764 13.5 4.98681C13.5008 5.68275 13.7777 6.34994 14.2698 6.84205C14.7619 7.33415 15.4291 7.61098 16.125 7.61181ZM16.125 3.86182C16.3475 3.86182 16.565 3.9278 16.75 4.05141C16.935 4.17503 17.0792 4.35073 17.1644 4.5563C17.2495 4.76186 17.2718 4.98806 17.2284 5.20629C17.185 5.42452 17.0778 5.62497 16.9205 5.78231C16.7632 5.93964 16.5627 6.04679 16.3445 6.0902C16.1262 6.1336 15.9 6.11133 15.6945 6.02618C15.4889 5.94103 15.3132 5.79683 15.1896 5.61183C15.066 5.42682 15 5.20932 15 4.98681C15.0003 4.68855 15.119 4.4026 15.3299 4.19169C15.5408 3.98079 15.8267 3.86215 16.125 3.86182Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 4.1 KiB |
6
public-2022-08-23/assets/sidebar/newsIcon.svg
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M21.75 10.6118H16.5V4.61182C16.4993 4.01528 16.2621 3.44336 15.8403 3.02155C15.4185 2.59973 14.8465 2.36247 14.25 2.36182H3.75C3.15346 2.36247 2.58155 2.59973 2.15973 3.02155C1.73792 3.44336 1.50066 4.01528 1.5 4.61182V21.1118C1.50066 21.7084 1.73792 22.2803 2.15973 22.7021C2.58155 23.1239 3.15346 23.3612 3.75 23.3618H18.75C19.7442 23.3606 20.6973 22.9652 21.4004 22.2622C22.1034 21.5592 22.4988 20.606 22.5 19.6118V11.3618C22.5 11.1629 22.421 10.9721 22.2803 10.8315C22.1397 10.6908 21.9489 10.6118 21.75 10.6118ZM3 21.1118V4.61182C3.00018 4.41296 3.07925 4.2223 3.21987 4.08168C3.36048 3.94107 3.55114 3.862 3.75 3.86182H14.25C14.4489 3.862 14.6395 3.94107 14.7801 4.08168C14.9207 4.2223 14.9998 4.41296 15 4.61182V21.8618H3.75C3.55114 21.8616 3.36048 21.7826 3.21987 21.6419C3.07925 21.5013 3.00018 21.3107 3 21.1118ZM21 19.6118C20.9993 20.2084 20.7621 20.7803 20.3403 21.2021C19.9185 21.6239 19.3465 21.8612 18.75 21.8618H16.5V12.1118H21V19.6118Z" fill="#969BA0"/>
|
||||||
|
<path d="M12.3 7.01182L9.72405 8.94322L7.91602 7.73782C7.79279 7.65577 7.64805 7.61199 7.5 7.61199C7.35195 7.61199 7.20721 7.65577 7.08397 7.73782L4.83397 9.23782C4.75104 9.29202 4.67967 9.36211 4.62398 9.44404C4.56829 9.52598 4.52939 9.61814 4.50952 9.71519C4.48965 9.81225 4.4892 9.91228 4.50821 10.0095C4.52721 10.1067 4.5653 10.1992 4.62025 10.2817C4.67521 10.3641 4.74595 10.4348 4.82839 10.4898C4.91084 10.5447 5.00335 10.5828 5.10058 10.6017C5.19782 10.6207 5.29785 10.6202 5.3949 10.6003C5.49195 10.5805 5.5841 10.5415 5.66602 10.4858L7.5 9.26309L9.33398 10.4856C9.46295 10.572 9.61561 10.6161 9.77078 10.6119C9.92596 10.6076 10.076 10.5552 10.2 10.4618L13.2 8.21182C13.2788 8.15272 13.3452 8.07869 13.3954 7.99394C13.4455 7.90919 13.4785 7.81538 13.4925 7.71788C13.5064 7.62038 13.501 7.52109 13.4765 7.42568C13.4521 7.33027 13.4091 7.24061 13.35 7.16182C13.2909 7.08302 13.2169 7.01664 13.1321 6.96646C13.0474 6.91628 12.9536 6.88328 12.8561 6.86935C12.7586 6.85543 12.6593 6.86084 12.5639 6.88528C12.4685 6.90972 12.3788 6.95272 12.3 7.01182Z" fill="#969BA0"/>
|
||||||
|
<path d="M5.25 15.1118H9C9.19891 15.1118 9.38968 15.0328 9.53033 14.8921C9.67098 14.7515 9.75 14.5607 9.75 14.3618C9.75 14.1629 9.67098 13.9721 9.53033 13.8315C9.38968 13.6908 9.19891 13.6118 9 13.6118H5.25C5.05109 13.6118 4.86032 13.6908 4.71967 13.8315C4.57902 13.9721 4.5 14.1629 4.5 14.3618C4.5 14.5607 4.57902 14.7515 4.71967 14.8921C4.86032 15.0328 5.05109 15.1118 5.25 15.1118Z" fill="#969BA0"/>
|
||||||
|
<path d="M12 16.6118H5.25C5.05109 16.6118 4.86032 16.6908 4.71967 16.8315C4.57902 16.9721 4.5 17.1629 4.5 17.3618C4.5 17.5607 4.57902 17.7515 4.71967 17.8921C4.86032 18.0328 5.05109 18.1118 5.25 18.1118H12C12.1989 18.1118 12.3897 18.0328 12.5303 17.8921C12.671 17.7515 12.75 17.5607 12.75 17.3618C12.75 17.1629 12.671 16.9721 12.5303 16.8315C12.3897 16.6908 12.1989 16.6118 12 16.6118Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.9 KiB |
3
public-2022-08-23/assets/sidebar/notificationsIcon.svg
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M22 15.076V12.6826C21.9975 10.8306 21.3044 9.04597 20.0561 7.67779C18.8078 6.30962 17.0941 5.45622 15.25 5.28446V3.75001C15.25 3.5511 15.171 3.36033 15.0303 3.21967C14.8897 3.07902 14.6989 3 14.5 3C14.3011 3 14.1103 3.07902 13.9697 3.21967C13.829 3.36033 13.75 3.5511 13.75 3.75001V5.28461C11.9059 5.45637 10.1923 6.30974 8.94395 7.67789C7.69565 9.04603 7.00249 10.8306 7 12.6826V15.0758C6.15363 15.2498 5.39311 15.7102 4.84663 16.3796C4.30016 17.0489 4.00115 17.8861 4 18.7502C4.00066 19.3468 4.23792 19.9187 4.65973 20.3405C5.08155 20.7623 5.65346 20.9996 6.25 21.0002H10.8258C10.9988 21.8471 11.4589 22.6082 12.1284 23.1548C12.7979 23.7014 13.6357 24 14.5 24C15.3643 24 16.2021 23.7014 16.8716 23.1548C17.5411 22.6082 18.0012 21.8471 18.1742 21.0002H22.75C23.3465 20.9996 23.9185 20.7623 24.3403 20.3405C24.7621 19.9187 24.9993 19.3468 25 18.7502C24.9988 17.8862 24.6998 17.0489 24.1533 16.3797C23.6068 15.7104 22.8463 15.2499 22 15.076ZM8.5 12.6826C8.50198 11.1098 9.12765 9.602 10.2398 8.48986C11.3519 7.37771 12.8597 6.75204 14.4325 6.75005H14.5675C16.1403 6.75204 17.6481 7.37771 18.7602 8.48986C19.8723 9.602 20.498 11.1098 20.5 12.6826V15.0002H8.5V12.6826ZM14.5 22.5003C14.0362 22.4988 13.5842 22.3539 13.2061 22.0853C12.828 21.8167 12.5423 21.4377 12.3882 21.0002H16.6118C16.4577 21.4377 16.172 21.8167 15.7939 22.0853C15.4158 22.3539 14.9638 22.4988 14.5 22.5003ZM22.75 19.5002H6.25C6.05112 19.5001 5.86043 19.4211 5.7198 19.2804C5.57918 19.1398 5.50012 18.9491 5.5 18.7502C5.50066 18.1537 5.73792 17.5818 6.15973 17.1599C6.58155 16.7381 7.15346 16.5008 7.75 16.5002H21.25C21.8465 16.5008 22.4185 16.7381 22.8403 17.1599C23.2621 17.5818 23.4993 18.1537 23.5 18.7502C23.4999 18.9491 23.4208 19.1398 23.2802 19.2804C23.1396 19.4211 22.9489 19.5001 22.75 19.5002Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.9 KiB |
5
public-2022-08-23/assets/sidebar/saqIcon.svg
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<svg width="29" height="25" viewBox="0 0 29 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M22.6092 4H6.38886C5.75551 4.00073 5.1483 4.26507 4.70045 4.73503C4.2526 5.20498 4.0007 5.84217 4 6.50678V18.2051C4.0007 18.8697 4.2526 19.5069 4.70045 19.9769C5.1483 20.4468 5.75551 20.7112 6.38886 20.7119C6.60001 20.712 6.80247 20.8001 6.95178 20.9568C7.10108 21.1135 7.18502 21.3259 7.18514 21.5475V23.3288C7.18514 23.6313 7.26338 23.9281 7.41151 24.1876C7.55964 24.4471 7.7721 24.6595 8.02625 24.8023C8.2804 24.945 8.56669 25.0127 8.85461 24.9981C9.14253 24.9834 9.42127 24.8871 9.66112 24.7193L15.1885 20.8523C15.3191 20.7604 15.4729 20.7115 15.6302 20.7119H19.512C20.0337 20.7109 20.5408 20.5315 20.9565 20.2009C21.3723 19.8704 21.674 19.4066 21.8161 18.8799L24.9141 7.17835C25.0119 6.80574 25.0264 6.41449 24.9565 6.03503C24.8866 5.65558 24.7342 5.29817 24.5112 4.99062C24.2882 4.68307 24.0005 4.43368 23.6706 4.26186C23.3407 4.09005 22.9775 4.00043 22.6092 4ZM23.3783 6.73448L20.2818 18.432C20.2339 18.6074 20.1329 18.7617 19.994 18.8715C19.8551 18.9814 19.686 19.0408 19.512 19.0407H15.6302C15.1584 19.0401 14.6972 19.1866 14.3051 19.4618L8.77772 23.3288V21.5475C8.77702 20.8829 8.52511 20.2457 8.07727 19.7757C7.62942 19.3058 7.02221 19.0414 6.38886 19.0407C6.17771 19.0406 5.97524 18.9525 5.82594 18.7958C5.67663 18.6391 5.5927 18.4267 5.59257 18.2051V6.50678C5.5927 6.28521 5.67663 6.07275 5.82594 5.91608C5.97524 5.7594 6.17771 5.67132 6.38886 5.67119H22.6092C22.7323 5.67152 22.8536 5.70164 22.9638 5.75922C23.074 5.8168 23.17 5.90028 23.2444 6.00316C23.3188 6.10604 23.3696 6.22556 23.3928 6.3524C23.4161 6.47924 23.4111 6.61 23.3783 6.73448Z" fill="#969BA0"/>
|
||||||
|
<path d="M8.77772 11.5203H12.7591C12.9703 11.5203 13.1729 11.4323 13.3222 11.2756C13.4715 11.1189 13.5554 10.9063 13.5554 10.6847C13.5554 10.4631 13.4715 10.2506 13.3222 10.0939C13.1729 9.93716 12.9703 9.84912 12.7591 9.84912H8.77772C8.56653 9.84912 8.36399 9.93716 8.21466 10.0939C8.06532 10.2506 7.98143 10.4631 7.98143 10.6847C7.98143 10.9063 8.06532 11.1189 8.21466 11.2756C8.36399 11.4323 8.56653 11.5203 8.77772 11.5203Z" fill="#969BA0"/>
|
||||||
|
<path d="M15.9443 13.1914H8.77772C8.56653 13.1914 8.36399 13.2794 8.21466 13.4361C8.06532 13.5929 7.98143 13.8054 7.98143 14.027C7.98143 14.2486 8.06532 14.4612 8.21466 14.6179C8.36399 14.7746 8.56653 14.8626 8.77772 14.8626H15.9443C16.1555 14.8626 16.358 14.7746 16.5073 14.6179C16.6567 14.4612 16.7406 14.2486 16.7406 14.027C16.7406 13.8054 16.6567 13.5929 16.5073 13.4361C16.358 13.2794 16.1555 13.1914 15.9443 13.1914Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.5 KiB |
6
public-2022-08-23/assets/sidebar/sectorialInfoIcon.svg
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M21.75 10.6118H16.5V4.61182C16.4993 4.01528 16.2621 3.44336 15.8403 3.02155C15.4185 2.59973 14.8465 2.36247 14.25 2.36182H3.75C3.15346 2.36247 2.58155 2.59973 2.15973 3.02155C1.73792 3.44336 1.50066 4.01528 1.5 4.61182V21.1118C1.50066 21.7084 1.73792 22.2803 2.15973 22.7021C2.58155 23.1239 3.15346 23.3612 3.75 23.3618H18.75C19.7442 23.3606 20.6973 22.9652 21.4004 22.2622C22.1034 21.5592 22.4988 20.606 22.5 19.6118V11.3618C22.5 11.1629 22.421 10.9721 22.2803 10.8315C22.1397 10.6908 21.9489 10.6118 21.75 10.6118ZM3 21.1118V4.61182C3.00018 4.41296 3.07925 4.2223 3.21987 4.08168C3.36048 3.94107 3.55114 3.862 3.75 3.86182H14.25C14.4489 3.862 14.6395 3.94107 14.7801 4.08168C14.9207 4.2223 14.9998 4.41296 15 4.61182V21.8618H3.75C3.55114 21.8616 3.36048 21.7826 3.21987 21.6419C3.07925 21.5013 3.00018 21.3107 3 21.1118ZM21 19.6118C20.9993 20.2084 20.7621 20.7803 20.3403 21.2021C19.9185 21.6239 19.3465 21.8612 18.75 21.8618H16.5V12.1118H21V19.6118Z" fill="#969BA0"/>
|
||||||
|
<path d="M12.3 7.01182L9.72405 8.94322L7.91602 7.73782C7.79279 7.65577 7.64805 7.61199 7.5 7.61199C7.35195 7.61199 7.20721 7.65577 7.08397 7.73782L4.83397 9.23782C4.75104 9.29202 4.67967 9.36211 4.62398 9.44404C4.56829 9.52598 4.52939 9.61814 4.50952 9.71519C4.48965 9.81225 4.4892 9.91228 4.50821 10.0095C4.52721 10.1067 4.5653 10.1992 4.62025 10.2817C4.67521 10.3641 4.74595 10.4348 4.82839 10.4898C4.91084 10.5447 5.00335 10.5828 5.10058 10.6017C5.19782 10.6207 5.29785 10.6202 5.3949 10.6003C5.49195 10.5805 5.5841 10.5415 5.66602 10.4858L7.5 9.26309L9.33398 10.4856C9.46295 10.572 9.61561 10.6161 9.77078 10.6119C9.92596 10.6076 10.076 10.5552 10.2 10.4618L13.2 8.21182C13.2788 8.15272 13.3452 8.07869 13.3954 7.99394C13.4455 7.90919 13.4785 7.81538 13.4925 7.71788C13.5064 7.62038 13.501 7.52109 13.4765 7.42568C13.4521 7.33027 13.4091 7.24061 13.35 7.16182C13.2909 7.08302 13.2169 7.01664 13.1321 6.96646C13.0474 6.91628 12.9536 6.88328 12.8561 6.86935C12.7586 6.85543 12.6593 6.86084 12.5639 6.88528C12.4685 6.90972 12.3788 6.95272 12.3 7.01182Z" fill="#969BA0"/>
|
||||||
|
<path d="M5.25 15.1118H9C9.19891 15.1118 9.38968 15.0328 9.53033 14.8921C9.67098 14.7515 9.75 14.5607 9.75 14.3618C9.75 14.1629 9.67098 13.9721 9.53033 13.8315C9.38968 13.6908 9.19891 13.6118 9 13.6118H5.25C5.05109 13.6118 4.86032 13.6908 4.71967 13.8315C4.57902 13.9721 4.5 14.1629 4.5 14.3618C4.5 14.5607 4.57902 14.7515 4.71967 14.8921C4.86032 15.0328 5.05109 15.1118 5.25 15.1118Z" fill="#969BA0"/>
|
||||||
|
<path d="M12 16.6118H5.25C5.05109 16.6118 4.86032 16.6908 4.71967 16.8315C4.57902 16.9721 4.5 17.1629 4.5 17.3618C4.5 17.5607 4.57902 17.7515 4.71967 17.8921C4.86032 18.0328 5.05109 18.1118 5.25 18.1118H12C12.1989 18.1118 12.3897 18.0328 12.5303 17.8921C12.671 17.7515 12.75 17.5607 12.75 17.3618C12.75 17.1629 12.671 16.9721 12.5303 16.8315C12.3897 16.6908 12.1989 16.6118 12 16.6118Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.9 KiB |
@ -0,0 +1,3 @@
|
|||||||
|
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M15.375 5.23013L12.375 3.49831C12.261 3.43248 12.1317 3.39783 12 3.39783C11.8683 3.39783 11.739 3.43248 11.625 3.49831L8.625 5.23013C8.51101 5.29594 8.41635 5.3906 8.35052 5.50458C8.2847 5.61856 8.25003 5.74786 8.25 5.87948V8.93445L5.32913 14.7762C5.30706 14.8305 5.29167 14.8872 5.2833 14.9452L2.625 16.4801C2.51101 16.5459 2.41635 16.6406 2.35052 16.7546C2.2847 16.8686 2.25003 16.9978 2.25 17.1295V20.5945C2.24998 20.7261 2.28462 20.8555 2.35045 20.9695C2.41628 21.0836 2.51097 21.1783 2.625 21.2441L5.625 22.9759C5.73904 23.0417 5.86836 23.0763 6 23.0763C6.13164 23.0763 6.26096 23.0417 6.375 22.9759L9.375 21.2441C9.48903 21.1783 9.58372 21.0836 9.64955 20.9695C9.71538 20.8555 9.75002 20.7261 9.75 20.5945V19.612H14.25V20.5945C14.25 20.7261 14.2846 20.8555 14.3504 20.9695C14.4163 21.0836 14.511 21.1783 14.625 21.2441L17.625 22.9759C17.739 23.0417 17.8684 23.0763 18 23.0763C18.1316 23.0763 18.261 23.0417 18.375 22.9759L21.375 21.2441C21.489 21.1783 21.5837 21.0836 21.6496 20.9695C21.7154 20.8555 21.75 20.7261 21.75 20.5945V17.1295C21.75 16.9978 21.7154 16.8684 21.6496 16.7544C21.5837 16.6404 21.489 16.5457 21.375 16.4798L18.7167 14.9452C18.7083 14.8872 18.6929 14.8305 18.6709 14.7762L15.75 8.93475V5.87948C15.75 5.74786 15.7153 5.61856 15.6495 5.50458C15.5837 5.3906 15.489 5.29594 15.375 5.23013ZM9.75 6.31306L12 5.01406L14.25 6.31306V8.9109L12 10.2099L9.75 8.9109V6.31306ZM8.25 20.1609L6 21.4599L3.75 20.1609V17.563L6 16.264L8.25 17.563V20.1609ZM9.75 18.112V17.1295C9.75002 16.9978 9.71538 16.8684 9.64955 16.7544C9.58372 16.6404 9.48903 16.5457 9.375 16.4798L6.87585 15.0374L9.225 10.34L11.625 11.7257C11.739 11.7914 11.8684 11.826 12 11.826C12.1316 11.826 12.261 11.7914 12.375 11.7257L14.7754 10.34L17.1241 15.0374L14.625 16.4801C14.511 16.546 14.4163 16.6407 14.3504 16.7547C14.2846 16.8687 14.25 16.9981 14.25 17.1298V18.112H9.75ZM20.25 20.1609L18 21.4599L15.75 20.1609V17.563L18 16.264L20.25 17.563V20.1609Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.0 KiB |
6
public-2022-08-23/assets/sidebar/telemetryIcon.svg
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M21.75 9.75H16.5V3.75C16.4993 3.15346 16.2621 2.58155 15.8403 2.15973C15.4185 1.73792 14.8465 1.50066 14.25 1.5H3.75C3.15346 1.50066 2.58155 1.73792 2.15973 2.15973C1.73792 2.58155 1.50066 3.15346 1.5 3.75V20.25C1.50066 20.8465 1.73792 21.4185 2.15973 21.8403C2.58155 22.2621 3.15346 22.4993 3.75 22.5H18.75C19.7442 22.4988 20.6973 22.1034 21.4004 21.4004C22.1034 20.6973 22.4988 19.7442 22.5 18.75V10.5C22.5 10.3011 22.421 10.1103 22.2803 9.96967C22.1397 9.82902 21.9489 9.75 21.75 9.75ZM3 20.25V3.75C3.00018 3.55114 3.07925 3.36048 3.21987 3.21987C3.36048 3.07925 3.55114 3.00018 3.75 3H14.25C14.4489 3.00018 14.6395 3.07925 14.7801 3.21987C14.9207 3.36048 14.9998 3.55114 15 3.75V21H3.75C3.55114 20.9998 3.36048 20.9207 3.21987 20.7801C3.07925 20.6395 3.00018 20.4489 3 20.25ZM21 18.75C20.9993 19.3465 20.7621 19.9185 20.3403 20.3403C19.9185 20.7621 19.3465 20.9993 18.75 21H16.5V11.25H21V18.75Z" fill="#969BA0"/>
|
||||||
|
<path d="M12.3 6.15L9.72405 8.0814L7.91602 6.876C7.79279 6.79395 7.64805 6.75017 7.5 6.75017C7.35195 6.75017 7.20721 6.79395 7.08397 6.876L4.83397 8.376C4.75104 8.4302 4.67967 8.50029 4.62398 8.58223C4.56829 8.66416 4.52939 8.75632 4.50952 8.85338C4.48965 8.95043 4.4892 9.05047 4.50821 9.14769C4.52721 9.24492 4.5653 9.33742 4.62025 9.41985C4.67521 9.50228 4.74595 9.57301 4.82839 9.62794C4.91084 9.68288 5.00335 9.72094 5.10058 9.73992C5.19782 9.7589 5.29785 9.75843 5.3949 9.73853C5.49195 9.71864 5.5841 9.67971 5.66602 9.624L7.5 8.40127L9.33398 9.62378C9.46295 9.71017 9.61561 9.7543 9.77078 9.75004C9.92596 9.74578 10.076 9.69334 10.2 9.6L13.2 7.35C13.2788 7.29091 13.3452 7.21687 13.3954 7.13212C13.4455 7.04737 13.4785 6.95357 13.4925 6.85607C13.5064 6.75856 13.501 6.65927 13.4765 6.56386C13.4521 6.46845 13.4091 6.37879 13.35 6.3C13.2909 6.22121 13.2169 6.15482 13.1321 6.10464C13.0474 6.05446 12.9536 6.02147 12.8561 6.00754C12.7586 5.99361 12.6593 5.99902 12.5639 6.02346C12.4685 6.04791 12.3788 6.0909 12.3 6.15Z" fill="#969BA0"/>
|
||||||
|
<path d="M5.25 14.25H9C9.19891 14.25 9.38968 14.171 9.53033 14.0303C9.67098 13.8897 9.75 13.6989 9.75 13.5C9.75 13.3011 9.67098 13.1103 9.53033 12.9697C9.38968 12.829 9.19891 12.75 9 12.75H5.25C5.05109 12.75 4.86032 12.829 4.71967 12.9697C4.57902 13.1103 4.5 13.3011 4.5 13.5C4.5 13.6989 4.57902 13.8897 4.71967 14.0303C4.86032 14.171 5.05109 14.25 5.25 14.25Z" fill="#969BA0"/>
|
||||||
|
<path d="M12 15.75H5.25C5.05109 15.75 4.86032 15.829 4.71967 15.9697C4.57902 16.1103 4.5 16.3011 4.5 16.5C4.5 16.6989 4.57902 16.8897 4.71967 17.0303C4.86032 17.171 5.05109 17.25 5.25 17.25H12C12.1989 17.25 12.3897 17.171 12.5303 17.0303C12.671 16.8897 12.75 16.6989 12.75 16.5C12.75 16.3011 12.671 16.1103 12.5303 15.9697C12.3897 15.829 12.1989 15.75 12 15.75Z" fill="#969BA0"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.8 KiB |
BIN
public-2022-08-23/assets/stamps/blueStamp.png
Normal file
|
After Width: | Height: | Size: 173 KiB |
BIN
public-2022-08-23/assets/stamps/whiteStamp.png
Normal file
|
After Width: | Height: | Size: 196 KiB |
9
public-2022-08-23/copel.svg
Normal file
|
After Width: | Height: | Size: 53 KiB |
57
public-2022-08-23/eye-svgrepo-com.svg
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 16.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||||
|
<svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||||
|
width="442.04px" height="442.04px" viewBox="0 0 442.04 442.04" style="enable-background:new 0 0 442.04 442.04;"
|
||||||
|
xml:space="preserve">
|
||||||
|
<g>
|
||||||
|
<g>
|
||||||
|
<path d="M221.02,341.304c-49.708,0-103.206-19.44-154.71-56.22C27.808,257.59,4.044,230.351,3.051,229.203
|
||||||
|
c-4.068-4.697-4.068-11.669,0-16.367c0.993-1.146,24.756-28.387,63.259-55.881c51.505-36.777,105.003-56.219,154.71-56.219
|
||||||
|
c49.708,0,103.207,19.441,154.71,56.219c38.502,27.494,62.266,54.734,63.259,55.881c4.068,4.697,4.068,11.669,0,16.367
|
||||||
|
c-0.993,1.146-24.756,28.387-63.259,55.881C324.227,321.863,270.729,341.304,221.02,341.304z M29.638,221.021
|
||||||
|
c9.61,9.799,27.747,27.03,51.694,44.071c32.83,23.361,83.714,51.212,139.688,51.212s106.859-27.851,139.688-51.212
|
||||||
|
c23.944-17.038,42.082-34.271,51.694-44.071c-9.609-9.799-27.747-27.03-51.694-44.071
|
||||||
|
c-32.829-23.362-83.714-51.212-139.688-51.212s-106.858,27.85-139.688,51.212C57.388,193.988,39.25,211.219,29.638,221.021z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path d="M221.02,298.521c-42.734,0-77.5-34.767-77.5-77.5c0-42.733,34.766-77.5,77.5-77.5c18.794,0,36.924,6.814,51.048,19.188
|
||||||
|
c5.193,4.549,5.715,12.446,1.166,17.639c-4.549,5.193-12.447,5.714-17.639,1.166c-9.564-8.379-21.844-12.993-34.576-12.993
|
||||||
|
c-28.949,0-52.5,23.552-52.5,52.5s23.551,52.5,52.5,52.5c28.95,0,52.5-23.552,52.5-52.5c0-6.903,5.597-12.5,12.5-12.5
|
||||||
|
s12.5,5.597,12.5,12.5C298.521,263.754,263.754,298.521,221.02,298.521z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path d="M221.02,246.021c-13.785,0-25-11.215-25-25s11.215-25,25-25c13.786,0,25,11.215,25,25S234.806,246.021,221.02,246.021z"/>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.0 KiB |
BIN
public-2022-08-23/favicon.ico
Normal file
|
After Width: | Height: | Size: 25 KiB |
10
public-2022-08-23/graphLineIcon.svg
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
<svg width="23" height="15" viewBox="0 0 23 15" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M1.2514 13.6099C2.28739 12.4426 5.64973 9.01062 7.45851 7.15065L14.2299 10.3803L22.1298 0.691376" stroke="#2BC155" stroke-width="2"/>
|
||||||
|
<path d="M7.45851 7.15065C5.64973 9.01062 2.28739 12.4426 1.2514 13.6099H22.1298V0.691376L14.2299 10.3803L7.45851 7.15065Z" fill="url(#paint0_linear_49_8)"/>
|
||||||
|
<defs>
|
||||||
|
<linearGradient id="paint0_linear_49_8" x1="11.6906" y1="2.30619" x2="12.4612" y2="13.6151" gradientUnits="userSpaceOnUse">
|
||||||
|
<stop stop-color="#2BC155" stop-opacity="0.73"/>
|
||||||
|
<stop offset="1" stop-color="#2BC155" stop-opacity="0"/>
|
||||||
|
</linearGradient>
|
||||||
|
</defs>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 667 B |
3
public-2022-08-23/icon.svg
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<svg width="206" height="56" viewBox="0 0 206 56" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<rect y="0.297363" width="206" height="54.7704" rx="8" fill="#254F7F"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 177 B |
9
public-2022-08-23/mapSample.svg
Normal file
|
After Width: | Height: | Size: 20 KiB |
4
public-2022-08-23/moneyIcon.svg
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
<svg width="96" height="91" viewBox="0 0 96 91" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<ellipse cx="48.2566" cy="45.8947" rx="47.3997" ry="44.9474" fill="#DEE4FF"/>
|
||||||
|
<path d="M56.9224 50.1495C56.9224 51.4295 56.6024 52.6561 55.9624 53.8295C55.3224 54.9761 54.3757 55.9361 53.1224 56.7095C51.8957 57.4828 50.4157 57.9228 48.6824 58.0295V61.2695H46.5224V58.0295C44.0957 57.8161 42.1224 57.0428 40.6024 55.7095C39.0824 54.3495 38.3091 52.6295 38.2824 50.5495H42.1624C42.2691 51.6695 42.6824 52.6428 43.4024 53.4695C44.1491 54.2961 45.1891 54.8161 46.5224 55.0295V45.0295C44.7357 44.5761 43.2957 44.1095 42.2024 43.6295C41.1091 43.1495 40.1757 42.4028 39.4024 41.3895C38.6291 40.3761 38.2424 39.0161 38.2424 37.3095C38.2424 35.1495 38.9891 33.3628 40.4824 31.9495C42.0024 30.5361 44.0157 29.7495 46.5224 29.5895V26.2695H48.6824V29.5895C50.9491 29.7761 52.7757 30.5095 54.1624 31.7895C55.5491 33.0428 56.3491 34.6828 56.5624 36.7095H52.6824C52.5491 35.7761 52.1357 34.9361 51.4424 34.1895C50.7491 33.4161 49.8291 32.9095 48.6824 32.6695V42.4295C50.4424 42.8828 51.8691 43.3495 52.9624 43.8295C54.0824 44.2828 55.0157 45.0161 55.7624 46.0295C56.5357 47.0428 56.9224 48.4161 56.9224 50.1495ZM41.9624 37.1095C41.9624 38.4161 42.3491 39.4161 43.1224 40.1095C43.8957 40.8028 45.0291 41.3761 46.5224 41.8295V32.5895C45.1357 32.7228 44.0291 33.1761 43.2024 33.9495C42.3757 34.6961 41.9624 35.7495 41.9624 37.1095ZM48.6824 55.0695C50.1224 54.9095 51.2424 54.3895 52.0424 53.5095C52.8691 52.6295 53.2824 51.5761 53.2824 50.3495C53.2824 49.0428 52.8824 48.0428 52.0824 47.3495C51.2824 46.6295 50.1491 46.0561 48.6824 45.6295V55.0695Z" fill="#2F4CDD"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.6 KiB |
9
public-2022-08-23/nordeste.svg
Normal file
|
After Width: | Height: | Size: 15 KiB |
9
public-2022-08-23/norte.svg
Normal file
|
After Width: | Height: | Size: 18 KiB |
4
public-2022-08-23/vercel.svg
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
<svg width="283" height="64" viewBox="0 0 283 64" fill="none"
|
||||||
|
xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M141.04 16c-11.04 0-19 7.2-19 18s8.96 18 20 18c6.67 0 12.55-2.64 16.19-7.09l-7.65-4.42c-2.02 2.21-5.09 3.5-8.54 3.5-4.79 0-8.86-2.5-10.37-6.5h28.02c.22-1.12.35-2.28.35-3.5 0-10.79-7.96-17.99-19-17.99zm-9.46 14.5c1.25-3.99 4.67-6.5 9.45-6.5 4.79 0 8.21 2.51 9.45 6.5h-18.9zM248.72 16c-11.04 0-19 7.2-19 18s8.96 18 20 18c6.67 0 12.55-2.64 16.19-7.09l-7.65-4.42c-2.02 2.21-5.09 3.5-8.54 3.5-4.79 0-8.86-2.5-10.37-6.5h28.02c.22-1.12.35-2.28.35-3.5 0-10.79-7.96-17.99-19-17.99zm-9.45 14.5c1.25-3.99 4.67-6.5 9.45-6.5 4.79 0 8.21 2.51 9.45 6.5h-18.9zM200.24 34c0 6 3.92 10 10 10 4.12 0 7.21-1.87 8.8-4.92l7.68 4.43c-3.18 5.3-9.14 8.49-16.48 8.49-11.05 0-19-7.2-19-18s7.96-18 19-18c7.34 0 13.29 3.19 16.48 8.49l-7.68 4.43c-1.59-3.05-4.68-4.92-8.8-4.92-6.07 0-10 4-10 10zm82.48-29v46h-9V5h9zM36.95 0L73.9 64H0L36.95 0zm92.38 5l-27.71 48L73.91 5H84.3l17.32 30 17.32-30h10.39zm58.91 12v9.69c-1-.29-2.06-.49-3.2-.49-5.81 0-10 4-10 10V51h-9V17h9v9.2c0-5.08 5.91-9.2 13.2-9.2z" fill="#000"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.1 KiB |
@ -233,9 +233,6 @@ export default function ClientTable({
|
|||||||
const [search, setSearch] = useState('')
|
const [search, setSearch] = useState('')
|
||||||
const [units, setUnits] = useState([])
|
const [units, setUnits] = useState([])
|
||||||
|
|
||||||
// Avoid a layout jump when reaching the last page with empty rows.
|
|
||||||
const emptyRows =
|
|
||||||
page > 0 ? Math.max(0, (1 + page) * rowsPerPage - clients.length) : 0
|
|
||||||
|
|
||||||
const formData = new FormData()
|
const formData = new FormData()
|
||||||
|
|
||||||
@ -244,6 +241,10 @@ export default function ClientTable({
|
|||||||
.slice(page * rowsPerPage, page * rowsPerPage + rowsPerPage)
|
.slice(page * rowsPerPage, page * rowsPerPage + rowsPerPage)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// Avoid a layout jump when reaching the last page with empty rows.
|
||||||
|
const emptyRows =
|
||||||
|
page > 0 ? Math.max(0, (1 + page) * rowsPerPage - listClients.length) : 0
|
||||||
|
|
||||||
const imageURLS = images.map((img) => URL.createObjectURL(img))
|
const imageURLS = images.map((img) => URL.createObjectURL(img))
|
||||||
|
|
||||||
// const handleOpen = () => setOpen(true)
|
// const handleOpen = () => setOpen(true)
|
||||||
@ -402,7 +403,7 @@ export default function ClientTable({
|
|||||||
orderBy={orderBy}
|
orderBy={orderBy}
|
||||||
onSelectAllClick={handleSelectAllClick}
|
onSelectAllClick={handleSelectAllClick}
|
||||||
onRequestSort={handleRequestSort}
|
onRequestSort={handleRequestSort}
|
||||||
rowCount={clients.length}
|
rowCount={listClients.length}
|
||||||
/>
|
/>
|
||||||
<TableBody>
|
<TableBody>
|
||||||
{listClients.map((row, index) => {
|
{listClients.map((row, index) => {
|
||||||
|
|||||||
@ -58,9 +58,12 @@ export default function Sidebar() {
|
|||||||
}, [router.pathname])
|
}, [router.pathname])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
api.post('/notify').then(res => {
|
api.post('/notify')
|
||||||
setNotificationsCount(res.data)
|
.then(({ data: { data: notifyCount } }) => setNotificationsCount(notifyCount))
|
||||||
})
|
.catch(err => {
|
||||||
|
console.log(err)
|
||||||
|
setNotificationsCount(0)
|
||||||
|
})
|
||||||
}, [])
|
}, [])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@ -42,9 +42,7 @@ export function AuthProvider({children}: {children: React.ReactNode}) {
|
|||||||
logout()
|
logout()
|
||||||
}
|
}
|
||||||
|
|
||||||
async function signIn({email, password}: SignInData) {
|
async function signIn({ email, password }: SignInData) {
|
||||||
signOut()
|
|
||||||
|
|
||||||
const { token, user, exception }: any = await signInRequest({
|
const { token, user, exception }: any = await signInRequest({
|
||||||
email,
|
email,
|
||||||
password
|
password
|
||||||
|
|||||||
@ -22,3 +22,4 @@ export default function clients() {
|
|||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -237,8 +237,6 @@ export const getServerSideProps: GetServerSideProps = async (ctx) => {
|
|||||||
await apiClient.post('/economy/grossAnnual').then(res => {
|
await apiClient.post('/economy/grossAnnual').then(res => {
|
||||||
grossAnualGraph = res.data.data
|
grossAnualGraph = res.data.data
|
||||||
})
|
})
|
||||||
.then(console.log)
|
|
||||||
.catch(console.log)
|
|
||||||
|
|
||||||
await apiClient.post('/economy/grossMonthly').then(res => {
|
await apiClient.post('/economy/grossMonthly').then(res => {
|
||||||
grossMensalGraph = res.data.data
|
grossMensalGraph = res.data.data
|
||||||
|
|||||||
@ -17,7 +17,7 @@ export default function commonQuestions({faqData, userName}) {
|
|||||||
<title>Smart Energia - FAQ</title>
|
<title>Smart Energia - FAQ</title>
|
||||||
</Head>
|
</Head>
|
||||||
<Header name={userName}>
|
<Header name={userName}>
|
||||||
<PageTitle title='Perguntas Frequentes' subtitle='Aqui estão algumas das perguntas que mais recebemos!'/>
|
<PageTitle title='Perguntas Frequentes!!' subtitle='Aqui estão algumas das perguntas que mais recebemos!'/>
|
||||||
</Header>
|
</Header>
|
||||||
<FaqView>
|
<FaqView>
|
||||||
{/* <Banner title='Perguntas Frequentes' subtitle='Aqui estão algumas das perguntas que mais recebemos!' imgSource='/assets/banners/faq1.png'/> */}
|
{/* <Banner title='Perguntas Frequentes' subtitle='Aqui estão algumas das perguntas que mais recebemos!' imgSource='/assets/banners/faq1.png'/> */}
|
||||||
|
|||||||
@ -1,103 +1,108 @@
|
|||||||
import FormControl from '@mui/material/FormControl';
|
import FormControl from '@mui/material/FormControl'
|
||||||
import IconButton from '@mui/material/IconButton';
|
import IconButton from '@mui/material/IconButton'
|
||||||
import InputAdornment from '@mui/material/InputAdornment';
|
import InputAdornment from '@mui/material/InputAdornment'
|
||||||
import InputLabel from '@mui/material/InputLabel';
|
import InputLabel from '@mui/material/InputLabel'
|
||||||
import OutlinedInput from '@mui/material/OutlinedInput';
|
import OutlinedInput from '@mui/material/OutlinedInput'
|
||||||
import TextField from '@mui/material/TextField';
|
import TextField from '@mui/material/TextField'
|
||||||
import Head from 'next/head';
|
import Head from 'next/head'
|
||||||
import Image from 'next/image';
|
import Image from 'next/image'
|
||||||
import Link from 'next/link';
|
import Link from 'next/link'
|
||||||
import { useRouter } from 'next/router'
|
import { useRouter } from 'next/router'
|
||||||
import { useContext, useState, useEffect, useCallback, useRef, forwardRef } from 'react'
|
import {
|
||||||
import { AiOutlineEye, AiOutlineEyeInvisible } from 'react-icons/ai';
|
useContext,
|
||||||
import RenderIf from '../utils/renderIf';
|
useState,
|
||||||
import Snackbar from '@mui/material/Snackbar';
|
useEffect,
|
||||||
|
useCallback,
|
||||||
|
useRef,
|
||||||
|
forwardRef
|
||||||
|
} from 'react'
|
||||||
|
import { AiOutlineEye, AiOutlineEyeInvisible } from 'react-icons/ai'
|
||||||
|
import RenderIf from '../utils/renderIf'
|
||||||
|
import Snackbar from '@mui/material/Snackbar'
|
||||||
|
|
||||||
import LoginButton from '../components/buttons/loginButton/LoginButton';
|
import LoginButton from '../components/buttons/loginButton/LoginButton'
|
||||||
import { AuthContext } from '../contexts/AuthContext';
|
import { AuthContext } from '../contexts/AuthContext'
|
||||||
import { api } from '../services/api';
|
import { api } from '../services/api'
|
||||||
import { LoginContainer, LoginView } from '../styles/layouts/login/LoginView';
|
import { LoginContainer, LoginView } from '../styles/layouts/login/LoginView'
|
||||||
import Dashboard from './dashboard';
|
import Dashboard from './dashboard'
|
||||||
import MuiAlert, { AlertProps } from '@mui/material/Alert';
|
import MuiAlert, { AlertProps } from '@mui/material/Alert'
|
||||||
import { GetServerSideProps } from 'next';
|
import { GetServerSideProps } from 'next'
|
||||||
import { parseCookies } from 'nookies';
|
import { parseCookies } from 'nookies'
|
||||||
|
import { AxiosError } from 'axios'
|
||||||
|
|
||||||
const Alert = forwardRef<HTMLDivElement, AlertProps>(function Alert(
|
const Alert = forwardRef<HTMLDivElement, AlertProps>(function Alert(
|
||||||
props,
|
props,
|
||||||
ref,
|
ref
|
||||||
) {
|
) {
|
||||||
return <MuiAlert elevation={6} ref={ref} variant="filled" {...props} />;
|
return <MuiAlert elevation={6} ref={ref} variant="filled" {...props} />
|
||||||
});
|
})
|
||||||
|
|
||||||
export default function Home() {
|
export default function Home() {
|
||||||
const [openSnackSuccess, setOpenSnackSuccess] = useState<boolean>(false);
|
const [openSnackSuccess, setOpenSnackSuccess] = useState<boolean>(false)
|
||||||
const [openSnackError, setOpenSnackError] = useState<boolean>(false);
|
const [openSnackError, setOpenSnackError] = useState<boolean>(false)
|
||||||
|
|
||||||
const field = useRef(null)
|
const field = useRef(null)
|
||||||
|
|
||||||
const [state, setstate] = useState(false);
|
const [state, setstate] = useState(false)
|
||||||
const [focus, setFocus] = useState('email');
|
const [focus, setFocus] = useState('email')
|
||||||
|
|
||||||
const [values, setValues] = useState({
|
const [values, setValues] = useState({
|
||||||
password: null,
|
password: null,
|
||||||
showPassword: false,
|
showPassword: false
|
||||||
});
|
})
|
||||||
|
|
||||||
const [email, setEmail] = useState<string>("")
|
const [email, setEmail] = useState<string>('')
|
||||||
const [password, setPassword] = useState<string>()
|
const [password, setPassword] = useState<string>()
|
||||||
|
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const rota = router.pathname
|
const rota = router.pathname
|
||||||
|
|
||||||
const handleChange = (prop) => (event) => {
|
const handleChange = (prop) => (event) => {
|
||||||
setValues({ ...values, [prop]: event.target.value });
|
setValues({ ...values, [prop]: event.target.value })
|
||||||
setPassword(event.target.value);
|
setPassword(event.target.value)
|
||||||
};
|
}
|
||||||
|
|
||||||
const handleClickShowPassword = () => {
|
const handleClickShowPassword = () => {
|
||||||
setValues({
|
setValues({
|
||||||
...values,
|
...values,
|
||||||
showPassword: !values.showPassword,
|
showPassword: !values.showPassword
|
||||||
});
|
})
|
||||||
};
|
}
|
||||||
|
|
||||||
const handleMouseDownPassword = (event) => {
|
const handleMouseDownPassword = (event) => {
|
||||||
event.preventDefault();
|
event.preventDefault()
|
||||||
};
|
}
|
||||||
|
|
||||||
const { signIn } = useContext(AuthContext)
|
const { signIn } = useContext(AuthContext)
|
||||||
|
|
||||||
async function handleSignIn() {
|
async function handleSignIn() {
|
||||||
if (email === "" || password === ""){
|
try {
|
||||||
|
if ([email, password].some(v => !v.trim())) return setOpenSnackError(true);
|
||||||
|
|
||||||
|
await signIn({ email, password })
|
||||||
|
} catch (ex) {
|
||||||
setOpenSnackError(true)
|
setOpenSnackError(true)
|
||||||
}else{
|
|
||||||
try {
|
|
||||||
await signIn({email, password}).then((res: any) => {
|
|
||||||
if (res.response.status === 422 || res.response.status === 401 || res.response.status === 500 ) {
|
|
||||||
setOpenSnackError(true)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} catch (exception) {
|
|
||||||
console.log(exception)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleCloseSnack = (event?: React.SyntheticEvent | Event, reason?: string) => {
|
const handleCloseSnack = (
|
||||||
|
event?: React.SyntheticEvent | Event,
|
||||||
|
reason?: string
|
||||||
|
) => {
|
||||||
if (reason === 'clickaway') {
|
if (reason === 'clickaway') {
|
||||||
return;
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
setOpenSnackError(false);
|
setOpenSnackError(false)
|
||||||
setOpenSnackSuccess(false);
|
setOpenSnackSuccess(false)
|
||||||
};
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setValues({
|
setValues({
|
||||||
password: (''),
|
password: '',
|
||||||
showPassword: null,
|
showPassword: null
|
||||||
});
|
})
|
||||||
setEmail("")
|
setEmail('')
|
||||||
}, [rota])
|
}, [rota])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@ -105,40 +110,62 @@ export default function Home() {
|
|||||||
<Head>
|
<Head>
|
||||||
<title>Smart Energia</title>
|
<title>Smart Energia</title>
|
||||||
</Head>
|
</Head>
|
||||||
<Snackbar open={openSnackSuccess} autoHideDuration={4000} onClose={handleCloseSnack}>
|
<Snackbar
|
||||||
<Alert onClose={handleCloseSnack} severity="success" sx={{ width: '100%' }}>
|
open={openSnackSuccess}
|
||||||
|
autoHideDuration={4000}
|
||||||
|
onClose={handleCloseSnack}
|
||||||
|
>
|
||||||
|
<Alert
|
||||||
|
onClose={handleCloseSnack}
|
||||||
|
severity="success"
|
||||||
|
sx={{ width: '100%' }}
|
||||||
|
>
|
||||||
notificação cadastrada com sucesso!
|
notificação cadastrada com sucesso!
|
||||||
</Alert>
|
</Alert>
|
||||||
</Snackbar>
|
</Snackbar>
|
||||||
<Snackbar open={openSnackError} autoHideDuration={4000} onClose={handleCloseSnack}>
|
<Snackbar
|
||||||
<Alert onClose={handleCloseSnack} severity="error" sx={{ width: '100%' }}>
|
open={openSnackError}
|
||||||
Prencha os Campos corretamente!
|
autoHideDuration={4000}
|
||||||
|
onClose={handleCloseSnack}
|
||||||
|
>
|
||||||
|
<Alert
|
||||||
|
onClose={handleCloseSnack}
|
||||||
|
severity="error"
|
||||||
|
sx={{ width: '100%' }}
|
||||||
|
>
|
||||||
|
Preencha os campos corretamente!
|
||||||
</Alert>
|
</Alert>
|
||||||
</Snackbar>
|
</Snackbar>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<Image src='/assets/marca1.png' width={500} height={340} />
|
<Image src="/assets/marca1.png" width={500} height={340} />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<LoginContainer>
|
<LoginContainer>
|
||||||
<h1>Bem-Vindo</h1>
|
<h1>Bem-Vindo</h1>
|
||||||
<h2>Estratégias Inteligentes em<br /> Gestão de Energia</h2>
|
<h2>
|
||||||
|
Estratégias Inteligentes em
|
||||||
|
<br /> Gestão de Energia
|
||||||
|
</h2>
|
||||||
|
|
||||||
|
<TextField
|
||||||
<TextField id="outlined-basic"
|
id="outlined-basic"
|
||||||
sx={{ m: 1, width: '90%' }} label="Login" value={email} variant="outlined" onKeyDown={(e) => e.key==='Enter'? field.current.children[0].focus() : null}
|
sx={{ m: 1, width: '90%' }}
|
||||||
onChange={value => {
|
label="Login"
|
||||||
setEmail(value.target.value.toLowerCase())
|
value={email}
|
||||||
}}/>
|
variant="outlined"
|
||||||
|
onKeyDown={(e) => e.key === 'Enter' && field.current.children[0].focus()}
|
||||||
|
onChange={(value) => setEmail(value.target.value.trim())}
|
||||||
|
/>
|
||||||
<FormControl sx={{ m: 1, width: '90%' }} variant="outlined">
|
<FormControl sx={{ m: 1, width: '90%' }} variant="outlined">
|
||||||
<InputLabel htmlFor="outlined-adornment-password" >Senha</InputLabel>
|
<InputLabel htmlFor="outlined-adornment-password">Senha</InputLabel>
|
||||||
<OutlinedInput
|
<OutlinedInput
|
||||||
id="outlined-adornment-password"
|
id="outlined-adornment-password"
|
||||||
type={values.showPassword ? 'text' : 'password'}
|
type={values.showPassword ? 'text' : 'password'}
|
||||||
value={values.password}
|
value={values.password}
|
||||||
onChange={handleChange('password')}
|
onChange={handleChange('password')}
|
||||||
ref={field}
|
ref={field}
|
||||||
onKeyDown={(e) => e.key==='Enter'? handleSignIn() : null}
|
onKeyDown={(e) => (e.key === 'Enter' ? handleSignIn() : null)}
|
||||||
endAdornment={
|
endAdornment={
|
||||||
<InputAdornment position="end">
|
<InputAdornment position="end">
|
||||||
<IconButton
|
<IconButton
|
||||||
@ -147,22 +174,36 @@ export default function Home() {
|
|||||||
onMouseDown={handleMouseDownPassword}
|
onMouseDown={handleMouseDownPassword}
|
||||||
edge="end"
|
edge="end"
|
||||||
>
|
>
|
||||||
{values.showPassword ? <AiOutlineEye /> : <AiOutlineEyeInvisible />}
|
{values.showPassword ? (
|
||||||
|
<AiOutlineEye />
|
||||||
|
) : (
|
||||||
|
<AiOutlineEyeInvisible />
|
||||||
|
)}
|
||||||
</IconButton>
|
</IconButton>
|
||||||
</InputAdornment>
|
</InputAdornment>
|
||||||
}
|
}
|
||||||
label="Senha"
|
label="Senha"
|
||||||
/>
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<Link href='verifyEmail'>Esqueceu a senha ?</Link>
|
<Link href="verifyEmail">Esqueceu a senha ?</Link>
|
||||||
|
|
||||||
<LoginButton title='ENTRAR' onClick={() => handleSignIn()}/>
|
<LoginButton title="ENTRAR" onClick={() => handleSignIn()} />
|
||||||
|
|
||||||
<fieldset className="line">
|
<fieldset className="line">
|
||||||
<legend className="text">Ou</legend>
|
<legend className="text">Ou</legend>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<p><a href='tel:+55(41) 3012-5900' >+55(41) 3012-5900</a><br/><a href='https://www.energiasmart.com.br' target="_blank" rel="noreferrer" >www.energiasmart.com.br</a></p>
|
<p>
|
||||||
|
<a href="tel:+55(41) 3012-5900">+55(41) 3012-5900</a>
|
||||||
|
<br />
|
||||||
|
<a
|
||||||
|
href="https://www.energiasmart.com.br"
|
||||||
|
target="_blank"
|
||||||
|
rel="noreferrer"
|
||||||
|
>
|
||||||
|
www.energiasmart.com.br
|
||||||
|
</a>
|
||||||
|
</p>
|
||||||
</LoginContainer>
|
</LoginContainer>
|
||||||
</LoginView>
|
</LoginView>
|
||||||
)
|
)
|
||||||
@ -170,6 +211,17 @@ export default function Home() {
|
|||||||
|
|
||||||
// export const getServerSideProps: GetServerSideProps = async (ctx) => {
|
// export const getServerSideProps: GetServerSideProps = async (ctx) => {
|
||||||
// const { ['@smartAuth-token']: token } = parseCookies(ctx)
|
// const { ['@smartAuth-token']: token } = parseCookies(ctx)
|
||||||
|
// if (token) {
|
||||||
|
// return {
|
||||||
|
// redirect: {
|
||||||
|
// destination: '/dashboard',
|
||||||
|
// permanent: false
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
/*export const getServerSideProps: GetServerSideProps = async (ctx) => {
|
||||||
|
const { ['@smartAuth-token']: token } = parseCookies(ctx)
|
||||||
|
|
||||||
// if (token) {
|
// if (token) {
|
||||||
// return {
|
// return {
|
||||||
@ -179,8 +231,8 @@ export default function Home() {
|
|||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
|
return {
|
||||||
// return {
|
props: {}
|
||||||
// props: {}
|
};
|
||||||
// };
|
}
|
||||||
// }
|
*/
|
||||||
|
|||||||
@ -37,12 +37,12 @@ interface pldInterface {
|
|||||||
clientMonth: any
|
clientMonth: any
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
export default function pld({ tableData, userName, clientMonth }: pldInterface) {
|
||||||
const { pldMenu, setPldMenu } = useContext(MenuContext)
|
const { pldMenu, setPldMenu } = useContext(MenuContext)
|
||||||
|
|
||||||
const dateFormated = new Date()
|
const dateFormated = new Date()
|
||||||
|
|
||||||
const year_Month = `0${dateFormated.getMonth()+1}/${dateFormated.getFullYear()}`
|
const year_Month = `0${dateFormated.getMonth() + 1}/${dateFormated.getFullYear()}`
|
||||||
|
|
||||||
const [date, setDate] = useState<any>(new Date());
|
const [date, setDate] = useState<any>(new Date());
|
||||||
const [select, setSelect] = useState('SUDESTE');
|
const [select, setSelect] = useState('SUDESTE');
|
||||||
@ -56,9 +56,11 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
const [norte, setNorte] = useState([])
|
const [norte, setNorte] = useState([])
|
||||||
const [sudeste, setSudeste] = useState([])
|
const [sudeste, setSudeste] = useState([])
|
||||||
const [nordeste, setNordeste] = useState([])
|
const [nordeste, setNordeste] = useState([])
|
||||||
const [ pageYPosition, setPageYPosition ] = useState(0);
|
const [pageYPosition, setPageYPosition] = useState(0);
|
||||||
|
|
||||||
function getPageYAfterScroll(){
|
console.log(tableData?.data)
|
||||||
|
|
||||||
|
function getPageYAfterScroll() {
|
||||||
setPageYPosition(window.scrollY);
|
setPageYPosition(window.scrollY);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -76,9 +78,9 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
function getDataByDay() {
|
function getDataByDay() {
|
||||||
api.post('/pld/daily', {
|
api.post('/pld/daily', {
|
||||||
"filters": [
|
"filters": [
|
||||||
{"type" : "=", "field" : "year_month_formatted", "value": month, "row": true},
|
{ "type": "=", "field": "year_month_formatted", "value": month, "row": true },
|
||||||
{"type" : "=", "field" : "submarket", "value": select}
|
{ "type": "=", "field": "submarket", "value": select }
|
||||||
],
|
],
|
||||||
"order": [{ "field": "day_calc", "direction": "asc" }]
|
"order": [{ "field": "day_calc", "direction": "asc" }]
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
setDataByDay(res.data.data)
|
setDataByDay(res.data.data)
|
||||||
@ -92,9 +94,9 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
"limit": 20,
|
"limit": 20,
|
||||||
"offset": 0,
|
"offset": 0,
|
||||||
"filters": [
|
"filters": [
|
||||||
{"type" : "=", "field" : "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true},
|
{ "type": "=", "field": "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true },
|
||||||
{"type" : "=", "field" : "submercado", "value": "SUL"}
|
{ "type": "=", "field": "submercado", "value": "SUL" }
|
||||||
],
|
],
|
||||||
"order": [{ "field": "hour", "direction": "asc" }]
|
"order": [{ "field": "hour", "direction": "asc" }]
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
setSul(res.data.data)
|
setSul(res.data.data)
|
||||||
@ -106,9 +108,9 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
"limit": 20,
|
"limit": 20,
|
||||||
"offset": 0,
|
"offset": 0,
|
||||||
"filters": [
|
"filters": [
|
||||||
{"type" : "=", "field" : "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true},
|
{ "type": "=", "field": "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true },
|
||||||
{"type" : "=", "field" : "submercado", "value": "SUDESTE"}
|
{ "type": "=", "field": "submercado", "value": "SUDESTE" }
|
||||||
],
|
],
|
||||||
"order": [{ "field": "hour", "direction": "asc" }]
|
"order": [{ "field": "hour", "direction": "asc" }]
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
setSudeste(res.data.data)
|
setSudeste(res.data.data)
|
||||||
@ -120,9 +122,9 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
"limit": 20,
|
"limit": 20,
|
||||||
"offset": 0,
|
"offset": 0,
|
||||||
"filters": [
|
"filters": [
|
||||||
{"type" : "=", "field" : "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true},
|
{ "type": "=", "field": "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true },
|
||||||
{"type" : "=", "field" : "submercado", "value": "NORTE"}
|
{ "type": "=", "field": "submercado", "value": "NORTE" }
|
||||||
],
|
],
|
||||||
"order": [{ "field": "hour", "direction": "asc" }]
|
"order": [{ "field": "hour", "direction": "asc" }]
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
setNorte(res.data.data)
|
setNorte(res.data.data)
|
||||||
@ -134,9 +136,9 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
"limit": 20,
|
"limit": 20,
|
||||||
"offset": 0,
|
"offset": 0,
|
||||||
"filters": [
|
"filters": [
|
||||||
{"type" : "=", "field" : "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true},
|
{ "type": "=", "field": "dia_num", "value": date.toLocaleDateString().split('/').reverse().join('-'), "row": true },
|
||||||
{"type" : "=", "field" : "submercado", "value": "NORDESTE"}
|
{ "type": "=", "field": "submercado", "value": "NORDESTE" }
|
||||||
],
|
],
|
||||||
"order": [{ "field": "hour", "direction": "asc" }]
|
"order": [{ "field": "hour", "direction": "asc" }]
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
setNordeste(res.data.data)
|
setNordeste(res.data.data)
|
||||||
@ -150,14 +152,14 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
return ''
|
return ''
|
||||||
else if (value >= tableData.result[0][`${region}_max`])
|
else if (value >= tableData.result[0][`${region}_max`])
|
||||||
return ''
|
return ''
|
||||||
else if (tableData.result[0][`${region}_max`] - value > tableData.result[0][`${region}_max`]/2)
|
else if (tableData.result[0][`${region}_max`] - value > tableData.result[0][`${region}_max`] / 2)
|
||||||
return ''
|
return ''
|
||||||
else if (tableData.result[1][`${region}_min`] - value <= tableData.result[1][`${region}_min`])
|
else if (tableData.result[1][`${region}_min`] - value <= tableData.result[1][`${region}_min`])
|
||||||
return ''
|
return ''
|
||||||
}
|
}
|
||||||
|
|
||||||
function downloadCSVFile(csv, filename) {
|
function downloadCSVFile(csv, filename) {
|
||||||
const csv_file = new Blob(["\ufeff",csv], {type: "text/csv"});
|
const csv_file = new Blob(["\ufeff", csv], { type: "text/csv" });
|
||||||
|
|
||||||
const download_link = document.createElement("a");
|
const download_link = document.createElement("a");
|
||||||
|
|
||||||
@ -177,7 +179,7 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
const rows = document.querySelectorAll("table tr");
|
const rows = document.querySelectorAll("table tr");
|
||||||
// const rows = document.getElementsByClassName('tabela');
|
// const rows = document.getElementsByClassName('tabela');
|
||||||
|
|
||||||
for (let i = rows.length/2; i < rows.length; i++) {
|
for (let i = rows.length / 2; i < rows.length; i++) {
|
||||||
const row = [], cols: any = rows[i].querySelectorAll("td, th");
|
const row = [], cols: any = rows[i].querySelectorAll("td, th");
|
||||||
|
|
||||||
for (let j = 0; j < cols.length; j++) {
|
for (let j = 0; j < cols.length; j++) {
|
||||||
@ -200,31 +202,31 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
}, [])
|
}, [])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<main style={{width: '100%'}}>
|
<main style={{ width: '100%' }}>
|
||||||
<Head>
|
<Head>
|
||||||
<title>Smart Energia - PLD</title>
|
<title>Smart Energia - PLD</title>
|
||||||
</Head>
|
</Head>
|
||||||
<div id='title'/>
|
<div id='title' />
|
||||||
<Header name={userName}>
|
<Header name={userName}>
|
||||||
<PageTitle title='PLD' subtitle='Evolução PLD - Valores em R$/MWh'/>
|
<PageTitle title='PLD' subtitle='Evolução PLD - Valores em R$/MWh' />
|
||||||
</Header>
|
</Header>
|
||||||
<TableHeader>
|
<TableHeader>
|
||||||
<Tabs value={pldMenu} onChange={(e, nv) => setPldMenu(nv)} aria-label="">
|
<Tabs value={pldMenu} onChange={(e, nv) => setPldMenu(nv)} aria-label="">
|
||||||
<Tab label="Pld Histórico"/>
|
<Tab label="Pld Histórico" />
|
||||||
<Tab label="Valores Diários"/>
|
<Tab label="Valores Diários" />
|
||||||
<Tab label="Valores Horários"/>
|
<Tab label="Valores Horários" />
|
||||||
</Tabs>
|
</Tabs>
|
||||||
<div className='btnDownload'>
|
<div className='btnDownload'>
|
||||||
<RenderIf isTrue={pldMenu === 0}>
|
<RenderIf isTrue={pldMenu === 0}>
|
||||||
<BasicButton onClick={() => {
|
<BasicButton onClick={() => {
|
||||||
const html = document.querySelector("table").outerHTML;
|
const html = document.querySelector("table").outerHTML;
|
||||||
htmlToCSV(html, "tabela_PLD.csv");
|
htmlToCSV(html, "tabela_PLD.csv");
|
||||||
}} title='Download'/>
|
}} title='Download' />
|
||||||
</RenderIf>
|
</RenderIf>
|
||||||
</div>
|
</div>
|
||||||
</TableHeader>
|
</TableHeader>
|
||||||
|
|
||||||
<RenderIf isTrue={pldMenu===0}>
|
<RenderIf isTrue={pldMenu === 0}>
|
||||||
<PldTableView>
|
<PldTableView>
|
||||||
<table className='tg'>
|
<table className='tg'>
|
||||||
<thead>
|
<thead>
|
||||||
@ -238,17 +240,17 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
{
|
{
|
||||||
tableData.data.map(data => {
|
tableData?.data?.map(data => (
|
||||||
return <>
|
<>
|
||||||
<tr className={data.year_month_formatted==year_Month? 'actual' : ''}>
|
<tr className={data.year_month_formatted == year_Month ? 'actual' : ''}>
|
||||||
<td className='tg-gceh'>{data.year_month_formatted}</td>
|
<td className='tg-gceh'>{data.year_month_formatted}</td>
|
||||||
<td className={`tg-uulg`}>{parseFloat(data.nordeste).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-uulg`}>{parseFloat(data.nordeste).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className={`tg-gceh`}>{parseFloat(data.norte).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-gceh`}>{parseFloat(data.norte).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className={`tg-gceh`}>{parseFloat(data.sudeste).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-gceh`}>{parseFloat(data.sudeste).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className={`tg-uulg`}>{parseFloat(data.sul).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-uulg`}>{parseFloat(data.sul).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
})
|
))
|
||||||
}
|
}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@ -261,31 +263,31 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
if (index === 0) {
|
if (index === 0) {
|
||||||
return <>
|
return <>
|
||||||
<tr>
|
<tr>
|
||||||
<td style={{borderTopLeftRadius: 8}} className='tg-gceh'>Máximo</td>
|
<td style={{ borderTopLeftRadius: 8 }} className='tg-gceh'>Máximo</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.nordeste_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.nordeste_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.norte_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.norte_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.sudeste_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.sudeste_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.sul_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.sul_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
} else if (index===1) {
|
} else if (index === 1) {
|
||||||
return <>
|
return <>
|
||||||
<tr>
|
<tr>
|
||||||
<td className='tg-gceh'>Mínimo</td>
|
<td className='tg-gceh'>Mínimo</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.nordeste_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.nordeste_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.norte_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.norte_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.sudeste_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.sudeste_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.sul_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.sul_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
} else if (index===2) {
|
} else if (index === 2) {
|
||||||
return <>
|
return <>
|
||||||
<tr>
|
<tr>
|
||||||
<td className='tg-gceh' style={{borderBottomColor: 'transparent'}}>Desv. Padrão</td>
|
<td className='tg-gceh' style={{ borderBottomColor: 'transparent' }}>Desv. Padrão</td>
|
||||||
<td className='tg-uulg' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.nordeste_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-uulg' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.nordeste_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.norte_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-gceh' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.norte_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.sudeste_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-gceh' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.sudeste_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-uulg' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.sul_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-uulg' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.sul_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
}
|
}
|
||||||
@ -296,7 +298,7 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
</PldTableMinMaxView>
|
</PldTableMinMaxView>
|
||||||
|
|
||||||
<PldTableView display={false}>
|
<PldTableView display={false}>
|
||||||
<table className="tg tabela" style={{display: 'none'}}>
|
<table className="tg tabela" style={{ display: 'none' }}>
|
||||||
<thead>
|
<thead>
|
||||||
<tr className='tr'>
|
<tr className='tr'>
|
||||||
<th className='tg-8oo6'>Mês</th>
|
<th className='tg-8oo6'>Mês</th>
|
||||||
@ -308,14 +310,14 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
{
|
{
|
||||||
tableData.data.map(data => {
|
tableData?.data?.map(data => {
|
||||||
return <>
|
return <>
|
||||||
<tr className={`${data.year_month_formatted==year_Month? 'actual' : ''} tr`}>
|
<tr className={`${data.year_month_formatted == year_Month ? 'actual' : ''} tr`}>
|
||||||
<td className='tg-gceh'>{data.year_month_formatted}</td>
|
<td className='tg-gceh'>{data.year_month_formatted}</td>
|
||||||
<td className={`tg-uulg`}>{parseFloat(data.nordeste).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-uulg`}>{parseFloat(data.nordeste).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className={`tg-gceh`}>{parseFloat(data.norte).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-gceh`}>{parseFloat(data.norte).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className={`tg-gceh`}>{parseFloat(data.sudeste).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-gceh`}>{parseFloat(data.sudeste).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className={`tg-uulg`}>{parseFloat(data.sul).toLocaleString('pt-br',{currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className={`tg-uulg`}>{parseFloat(data.sul).toLocaleString('pt-br', { currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
})
|
})
|
||||||
@ -325,31 +327,31 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
if (index === 0) {
|
if (index === 0) {
|
||||||
return <>
|
return <>
|
||||||
<tr className='tr'>
|
<tr className='tr'>
|
||||||
<td style={{borderTopLeftRadius: 8}} className='tg-gceh'>Máximo</td>
|
<td style={{ borderTopLeftRadius: 8 }} className='tg-gceh'>Máximo</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.nordeste_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.nordeste_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.norte_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.norte_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.sudeste_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.sudeste_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.sul_max).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.sul_max).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
} else if (index===1) {
|
} else if (index === 1) {
|
||||||
return <>
|
return <>
|
||||||
<tr className='tr'>
|
<tr className='tr'>
|
||||||
<td className='tg-gceh'>Mínimo</td>
|
<td className='tg-gceh'>Mínimo</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.nordeste_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.nordeste_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.norte_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.norte_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh'>{parseFloat(data.sudeste_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-gceh'>{parseFloat(data.sudeste_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-uulg'>{parseFloat(data.sul_min).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2})}</td>
|
<td className='tg-uulg'>{parseFloat(data.sul_min).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2, maximumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
} else if (index===2) {
|
} else if (index === 2) {
|
||||||
return <>
|
return <>
|
||||||
<tr className='tr'>
|
<tr className='tr'>
|
||||||
<td className='tg-gceh' style={{borderBottomColor: 'transparent'}}>Desv. Padrão</td>
|
<td className='tg-gceh' style={{ borderBottomColor: 'transparent' }}>Desv. Padrão</td>
|
||||||
<td className='tg-uulg' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.nordeste_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-uulg' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.nordeste_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.norte_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-gceh' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.norte_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-gceh' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.sudeste_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-gceh' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.sudeste_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
<td className='tg-uulg' style={{borderBottomColor: 'transparent'}}>{parseFloat(data.sul_desv_pad).toLocaleString('pt-br',{style: 'currency', currency: 'BRL', minimumFractionDigits: 2})}</td>
|
<td className='tg-uulg' style={{ borderBottomColor: 'transparent' }}>{parseFloat(data.sul_desv_pad).toLocaleString('pt-br', { style: 'currency', currency: 'BRL', minimumFractionDigits: 2 })}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</>
|
</>
|
||||||
}
|
}
|
||||||
@ -361,24 +363,24 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
</RenderIf>
|
</RenderIf>
|
||||||
|
|
||||||
{/* grafico de grafico por seleção de data (mês) (diario)*/}
|
{/* grafico de grafico por seleção de data (mês) (diario)*/}
|
||||||
<RenderIf isTrue={pldMenu===1}>
|
<RenderIf isTrue={pldMenu === 1}>
|
||||||
<PldGraphView>
|
<PldGraphView>
|
||||||
<section className='toolsbar2'>
|
<section className='toolsbar2'>
|
||||||
<FormControl sx={{
|
<FormControl sx={{
|
||||||
width: '320px'
|
width: '320px'
|
||||||
}}>
|
}}>
|
||||||
<InputLabel id="demo-simple-select-label">Região</InputLabel>
|
<InputLabel id="demo-simple-select-label">Região</InputLabel>
|
||||||
<Select
|
<Select
|
||||||
value={select}
|
value={select}
|
||||||
onChange={handleChange}
|
onChange={handleChange}
|
||||||
displayEmpty
|
displayEmpty
|
||||||
label='Região'
|
label='Região'
|
||||||
>
|
>
|
||||||
<MenuItem value={'NORTE'}>Norte</MenuItem>
|
<MenuItem value={'NORTE'}>Norte</MenuItem>
|
||||||
<MenuItem value={'NORDESTE'}>Nordeste</MenuItem>
|
<MenuItem value={'NORDESTE'}>Nordeste</MenuItem>
|
||||||
<MenuItem value={'SUL'}>Sul</MenuItem>
|
<MenuItem value={'SUL'}>Sul</MenuItem>
|
||||||
<MenuItem value={'SUDESTE'}>Sudeste</MenuItem>
|
<MenuItem value={'SUDESTE'}>Sudeste</MenuItem>
|
||||||
</Select>
|
</Select>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<FormControl sx={{
|
<FormControl sx={{
|
||||||
width: '320px',
|
width: '320px',
|
||||||
@ -386,39 +388,39 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
}}>
|
}}>
|
||||||
<InputLabel id="demo-simple-select-label">Mês</InputLabel>
|
<InputLabel id="demo-simple-select-label">Mês</InputLabel>
|
||||||
<Select
|
<Select
|
||||||
value={month}
|
value={month}
|
||||||
onChange={handleChangeDay}
|
onChange={handleChangeDay}
|
||||||
displayEmpty
|
displayEmpty
|
||||||
placeholder='dia'
|
placeholder='dia'
|
||||||
label="Age"
|
label="Age"
|
||||||
>
|
>
|
||||||
<MenuItem value={'0'}>Nenhum</MenuItem>
|
<MenuItem value={'0'}>Nenhum</MenuItem>
|
||||||
{
|
{
|
||||||
clientMonth.sort((a, b) => {
|
clientMonth.sort((a, b) => {
|
||||||
if (a.mes_ref.split('/')[0] < b.mes_ref.split('/')[0]) return 1
|
if (a.mes_ref.split('/')[0] < b.mes_ref.split('/')[0]) return 1
|
||||||
if (a.mes_ref.split('/')[0] > b.mes_ref.split('/')[0]) return -1
|
if (a.mes_ref.split('/')[0] > b.mes_ref.split('/')[0]) return -1
|
||||||
}).sort((a, b) => {
|
}).sort((a, b) => {
|
||||||
if (a.mes_ref.split('/')[1] < b.mes_ref.split('/')[1]) return 1
|
if (a.mes_ref.split('/')[1] < b.mes_ref.split('/')[1]) return 1
|
||||||
if (a.mes_ref.split('/')[1] > b.mes_ref.split('/')[1]) return -1
|
if (a.mes_ref.split('/')[1] > b.mes_ref.split('/')[1]) return -1
|
||||||
}).map((data, index) => {
|
}).map((data, index) => {
|
||||||
return <MenuItem key={index} value={data.mes_ref}>{data.mes_ref}</MenuItem>
|
return <MenuItem key={index} value={data.mes_ref}>{data.mes_ref}</MenuItem>
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
</Select>
|
</Select>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
</section>
|
</section>
|
||||||
<LineBarChart
|
<LineBarChart
|
||||||
data1={dataByDay.map(value => value.mmovel)} data3={dataByDay}
|
data1={dataByDay.map(value => value.mmovel)} data3={dataByDay}
|
||||||
dataset1={'Média'} dataset2={'barra1'} dataset3={'Diario'}
|
dataset1={'Média'} dataset2={'barra1'} dataset3={'Diario'}
|
||||||
label={dataByDay.map((value, index) => {
|
label={dataByDay.map((value, index) => {
|
||||||
return value.day_formatted
|
return value.day_formatted
|
||||||
})}
|
})}
|
||||||
title='' subtitle='' />
|
title='' subtitle='' />
|
||||||
</PldGraphView>
|
</PldGraphView>
|
||||||
</RenderIf>
|
</RenderIf>
|
||||||
|
|
||||||
{/* grafico de grafico por seleção de data INTEIRA (horario)*/}
|
{/* grafico de grafico por seleção de data INTEIRA (horario)*/}
|
||||||
<RenderIf isTrue={pldMenu===2}>
|
<RenderIf isTrue={pldMenu === 2}>
|
||||||
<PldGraphView>
|
<PldGraphView>
|
||||||
<section className='toolsbar2'>
|
<section className='toolsbar2'>
|
||||||
{/* <p>Selecione a data: </p> */}
|
{/* <p>Selecione a data: </p> */}
|
||||||
@ -429,7 +431,7 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
inputFormat="dd/MM/yyyy"
|
inputFormat="dd/MM/yyyy"
|
||||||
value={date}
|
value={date}
|
||||||
onChange={handleChangeDate}
|
onChange={handleChangeDate}
|
||||||
renderInput={(params) => <TextField {...params} style={{minWidth: '320px'}}/>}
|
renderInput={(params) => <TextField {...params} style={{ minWidth: '320px' }} />}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</LocalizationProvider>
|
</LocalizationProvider>
|
||||||
@ -441,7 +443,7 @@ export default function pld({tableData, userName, clientMonth}: pldInterface) {
|
|||||||
/>
|
/>
|
||||||
</PldGraphView>
|
</PldGraphView>
|
||||||
</RenderIf>
|
</RenderIf>
|
||||||
{pageYPosition > 300 && <a href="#title" style={{position: 'fixed', right: '50px', bottom: '100px'}}>
|
{pageYPosition > 300 && <a href="#title" style={{ position: 'fixed', right: '50px', bottom: '100px' }}>
|
||||||
<Fab aria-label="add">
|
<Fab aria-label="add">
|
||||||
<NavigationIcon />
|
<NavigationIcon />
|
||||||
</Fab>
|
</Fab>
|
||||||
@ -455,11 +457,11 @@ export const getServerSideProps: GetServerSideProps = async (ctx) => {
|
|||||||
const { ['@smartAuth-token']: token } = parseCookies(ctx)
|
const { ['@smartAuth-token']: token } = parseCookies(ctx)
|
||||||
const { ['user-name']: userName } = parseCookies(ctx)
|
const { ['user-name']: userName } = parseCookies(ctx)
|
||||||
|
|
||||||
let tableData = [];
|
let tableData = { data: [], result: [] };
|
||||||
let clientMonth = [];
|
let clientMonth = [];
|
||||||
|
|
||||||
await apiClient.post('/pld/list').then(res => {
|
await apiClient.post('/pld/list').then(res => {
|
||||||
tableData = res.data
|
tableData = res.data.data
|
||||||
})
|
})
|
||||||
|
|
||||||
await apiClient.post('/pld', {
|
await apiClient.post('/pld', {
|
||||||
|
|||||||
@ -30,7 +30,7 @@ export default function ResumoOperacao({
|
|||||||
clientMonth
|
clientMonth
|
||||||
}: any) {
|
}: any) {
|
||||||
const [month, setMonth] = useState('')
|
const [month, setMonth] = useState('')
|
||||||
const [unidade, setUnidade] = useState(clients[0].cod_smart_unidade)
|
const [unidade, setUnidade] = useState(clients?.[0]?.cod_smart_unidade ?? 0)
|
||||||
const [tableDataState, setTableDataState] = useState<any>([])
|
const [tableDataState, setTableDataState] = useState<any>([])
|
||||||
|
|
||||||
const { ['user-id']: id } = parseCookies()
|
const { ['user-id']: id } = parseCookies()
|
||||||
|
|||||||
@ -61,7 +61,7 @@ const months = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
export default function Telemetria({ userName, clients }: any) {
|
export default function Telemetria({ userName, clients }: any) {
|
||||||
const [unity, setUnity] = useState(clients[0]?.codigo_scde)
|
const [unity, setUnity] = useState(clients?.[0]?.codigo_scde ?? 0)
|
||||||
const [startDate, setStartDate] = useState(new Date())
|
const [startDate, setStartDate] = useState(new Date())
|
||||||
const [endDate, setEndDate] = useState(new Date())
|
const [endDate, setEndDate] = useState(new Date())
|
||||||
const [month, setMonth] = useState(new Date().getMonth())
|
const [month, setMonth] = useState(new Date().getMonth())
|
||||||
@ -915,7 +915,6 @@ export const getServerSideProps: GetServerSideProps = async (ctx) => {
|
|||||||
distinct: true
|
distinct: true
|
||||||
})
|
})
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
console.log(res.data)
|
|
||||||
clients = res.data.data
|
clients = res.data.data
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@ -1,23 +1,23 @@
|
|||||||
import { api } from "./api";
|
import { api } from './api'
|
||||||
|
|
||||||
export const TOKEN_KEY = "@smartAuth-token";
|
export const TOKEN_KEY = '@smartAuth-token'
|
||||||
|
|
||||||
interface SignInRequestData {
|
interface SignInRequestData {
|
||||||
email: string,
|
email: string
|
||||||
password: string
|
password: string
|
||||||
}
|
}
|
||||||
|
|
||||||
type UserObjectType = {
|
type UserObjectType = {
|
||||||
name: string;
|
name: string
|
||||||
email: string;
|
email: string
|
||||||
client_id: number;
|
client_id: number
|
||||||
id: number;
|
id: number
|
||||||
role: number;
|
role: number
|
||||||
profile_picture?: string
|
profile_picture?: string
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function signInRequest(data: SignInRequestData) {
|
export async function signInRequest(data: SignInRequestData) {
|
||||||
let user: UserObjectType, token: string, exception: any = null
|
let user: UserObjectType, token: string
|
||||||
|
|
||||||
await api
|
await api
|
||||||
.post('/auth/login', {
|
.post('/auth/login', {
|
||||||
@ -36,9 +36,6 @@ export async function signInRequest(data: SignInRequestData) {
|
|||||||
profile_picture: res.data.user.profile_picture
|
profile_picture: res.data.user.profile_picture
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch((res) => {
|
|
||||||
exception = res
|
|
||||||
})
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
token,
|
token,
|
||||||
@ -49,15 +46,14 @@ export async function signInRequest(data: SignInRequestData) {
|
|||||||
id: user?.id,
|
id: user?.id,
|
||||||
role: user?.role,
|
role: user?.role,
|
||||||
profile_picture: user?.profile_picture
|
profile_picture: user?.profile_picture
|
||||||
},
|
}
|
||||||
exception
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default async function recoverUserInformation(id) {
|
export default async function recoverUserInformation(id) {
|
||||||
let user: UserObjectType
|
let user: UserObjectType
|
||||||
|
|
||||||
await api.get(`/user/${id}`).then(res => {
|
await api.get(`/user/${id}`).then((res) => {
|
||||||
user = {
|
user = {
|
||||||
name: res.data.user.name,
|
name: res.data.user.name,
|
||||||
email: res.data.user.email,
|
email: res.data.user.email,
|
||||||
@ -80,7 +76,8 @@ export default async function recoverUserInformation(id) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export async function logout() {
|
export async function logout() {
|
||||||
await api.post('/auth/logout', {})
|
await api
|
||||||
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
.post('/auth/logout', {})
|
||||||
.then(res => {})
|
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
||||||
|
.then((res) => {})
|
||||||
}
|
}
|
||||||
|
|||||||
@ -20,7 +20,10 @@ export default function getAPIClient(
|
|||||||
const api = axios.create({
|
const api = axios.create({
|
||||||
// baseURL: 'https://api.energiasmart.com.br/api'
|
// baseURL: 'https://api.energiasmart.com.br/api'
|
||||||
// baseURL: 'https://api.energiasmart.klupp.com.br/api'
|
// baseURL: 'https://api.energiasmart.klupp.com.br/api'
|
||||||
baseURL: 'http://api-smart.test/api'
|
baseURL:
|
||||||
|
process.env.NODE_ENV === 'production'
|
||||||
|
? 'https://api.energiasmart.com.br/api'
|
||||||
|
: 'http://127.0.0.1:8000/api'
|
||||||
})
|
})
|
||||||
|
|
||||||
api.interceptors.request.use((config) => {
|
api.interceptors.request.use((config) => {
|
||||||
|
|||||||