CLT Invoice Description Fix Issue #271

CLT Invoice Description Fix Issue #271
pull/274/head
Shahana Farooqui 4 years ago
parent 6a7926b750
commit be320184a1

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 114 KiB

File diff suppressed because it is too large Load Diff

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="610px" height="524px" viewBox="0 0 610 524" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
<title>RTL-Logo-Single</title>
<desc>Created with Sketch.</desc>
<defs>
<polygon id="path-1" points="0.451852397 0.2573 52.6803 0.2573 52.6803 52 0.451852397 52"></polygon>
</defs>
<g id="RTL-Logo-Single" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="BY_-_RTL_logo_wht" transform="translate(58.000000, 54.000000)">
<g id="Group-3" transform="translate(0.000000, 0.737000)" fill="#FFFFFE">
<path d="M360.6201,52.8608 C362.5721,57.4638 363.3541,61.1008 363.2471,63.1018 C355.6871,58.5468 344.3161,54.6748 338.1131,53.5648 C334.0751,52.8408 347.2931,49.6338 360.6201,52.8608 M371.6051,222.1978 C373.9431,221.7028 376.2931,221.2298 378.6451,220.7688 C381.1041,220.2858 383.5691,219.8228 386.0431,219.3858 C384.0591,218.1358 382.0681,216.8978 380.0641,215.6788 C354.6091,200.1908 327.4751,187.0398 300.6651,174.3118 C283.7451,166.2788 266.5131,158.2938 248.9661,151.0968 C264.2721,130.9078 283.8701,113.7738 304.8171,99.0968 C304.8351,99.0848 304.9201,99.0258 305.0521,98.9328 C309.6371,105.1898 315.4331,109.4478 318.3391,111.0478 C324.0201,114.1778 331.1751,117.1028 337.7531,117.9968 C350.6891,119.7558 361.3701,119.4848 373.1871,117.4478 C374.2521,117.2648 375.3251,117.1348 376.3931,116.9568 C383.9711,115.6898 388.8201,115.4978 393.2591,115.4148 C399.1381,115.3048 402.0501,116.5498 402.7421,116.7298 C404.8421,117.2728 406.6271,118.1718 407.6191,119.3778 C408.7711,120.8458 410.0021,122.2308 411.3211,123.4988 C415.2771,127.4358 419.2051,129.6158 424.9041,130.2408 C432.2391,131.0448 437.4311,128.1758 441.1021,123.4128 C442.8361,121.1638 442.0011,117.6318 441.8111,116.9388 C440.8481,113.3958 438.6251,108.2418 437.0161,103.4438 C436.5991,102.2038 434.5781,98.3918 432.1461,95.8048 C431.3431,94.9488 430.5351,94.0948 429.7281,93.2418 C425.9511,89.2468 422.1441,85.2818 418.3701,81.2898 C403.3111,65.3718 386.9861,50.7158 370.1561,36.7028 C368.4121,35.2508 366.6651,33.7948 364.9151,32.3418 C363.6461,31.2868 362.3721,30.2378 361.1001,29.1868 C360.4531,28.6528 359.8071,28.1198 359.1581,27.5868 C357.7891,26.4608 356.4161,25.3428 355.0401,24.2258 C354.4971,23.7858 353.9521,23.3488 353.4081,22.9098 C352.5511,22.2198 350.5951,20.5728 348.9481,19.2538 C354.4071,13.8118 358.8121,10.4238 366.6311,5.3008 C367.7521,4.5668 373.7921,1.3448 373.5791,0.5268 C373.4511,0.0328 363.5341,0.1448 352.1711,1.6088 C348.1791,2.1228 325.8041,5.4268 310.4411,8.7748 C294.0871,12.3378 276.8181,17.3188 260.9121,22.3258 C214.9671,36.7898 171.0961,56.3918 130.9221,83.0318 C107.8341,98.3418 86.2221,115.2368 65.3621,133.4398 C55.6411,141.9208 45.9791,150.5378 36.5451,159.3928 C35.0671,160.7798 33.6011,162.1788 32.1351,163.5788 C34.1441,163.9548 36.1521,164.3478 38.1561,164.7598 C54.7691,168.1718 71.2001,172.7318 87.1751,177.2978 C106.7131,182.8818 126.4791,188.9018 145.5921,196.2918 C134.7011,206.6528 124.0761,217.2688 113.9611,228.5028 C94.9141,249.6538 77.1581,271.9988 60.5891,295.1368 C38.9991,325.2848 20.5681,357.7988 4.5021,391.3058 C2.9801,394.4758 1.4761,397.6528 0.0001,400.8388 C2.9721,398.4598 5.9621,396.1018 8.9741,393.7648 C34.9841,373.5938 62.4081,354.9428 89.7891,336.9238 C128.3171,311.5688 169.6651,290.6218 212.5711,273.7668 C264.2991,253.4468 317.1251,233.7338 371.6051,222.1978" id="Fill-1"></path>
</g>
<g id="Group-24" transform="translate(172.000000, 352.737000)">
<mask id="mask-2" fill="white">
<use xlink:href="#path-1"></use>
</mask>
<g id="Clip-23"></g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.8 KiB

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="610px" height="524px" viewBox="0 0 610 524" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
<title>RTL-Logo-Single</title>
<desc>Created with Sketch.</desc>
<defs>
<polygon id="path-1" points="0.451852397 0.2573 52.6803 0.2573 52.6803 52 0.451852397 52"></polygon>
</defs>
<g id="RTL-Logo-Single" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="BY_-_RTL_logo_wht" transform="translate(58.000000, 54.000000)">
<g id="Group-3" transform="translate(0.000000, 0.737000)" fill="#000001">
<path d="M360.6201,52.8608 C362.5721,57.4638 363.3541,61.1008 363.2471,63.1018 C355.6871,58.5468 344.3161,54.6748 338.1131,53.5648 C334.0751,52.8408 347.2931,49.6338 360.6201,52.8608 M371.6051,222.1978 C373.9431,221.7028 376.2931,221.2298 378.6451,220.7688 C381.1041,220.2858 383.5691,219.8228 386.0431,219.3858 C384.0591,218.1358 382.0681,216.8978 380.0641,215.6788 C354.6091,200.1908 327.4751,187.0398 300.6651,174.3118 C283.7451,166.2788 266.5131,158.2938 248.9661,151.0968 C264.2721,130.9078 283.8701,113.7738 304.8171,99.0968 C304.8351,99.0848 304.9201,99.0258 305.0521,98.9328 C309.6371,105.1898 315.4331,109.4478 318.3391,111.0478 C324.0201,114.1778 331.1751,117.1028 337.7531,117.9968 C350.6891,119.7558 361.3701,119.4848 373.1871,117.4478 C374.2521,117.2648 375.3251,117.1348 376.3931,116.9568 C383.9711,115.6898 388.8201,115.4978 393.2591,115.4148 C399.1381,115.3048 402.0501,116.5498 402.7421,116.7298 C404.8421,117.2728 406.6271,118.1718 407.6191,119.3778 C408.7711,120.8458 410.0021,122.2308 411.3211,123.4988 C415.2771,127.4358 419.2051,129.6158 424.9041,130.2408 C432.2391,131.0448 437.4311,128.1758 441.1021,123.4128 C442.8361,121.1638 442.0011,117.6318 441.8111,116.9388 C440.8481,113.3958 438.6251,108.2418 437.0161,103.4438 C436.5991,102.2038 434.5781,98.3918 432.1461,95.8048 C431.3431,94.9488 430.5351,94.0948 429.7281,93.2418 C425.9511,89.2468 422.1441,85.2818 418.3701,81.2898 C403.3111,65.3718 386.9861,50.7158 370.1561,36.7028 C368.4121,35.2508 366.6651,33.7948 364.9151,32.3418 C363.6461,31.2868 362.3721,30.2378 361.1001,29.1868 C360.4531,28.6528 359.8071,28.1198 359.1581,27.5868 C357.7891,26.4608 356.4161,25.3428 355.0401,24.2258 C354.4971,23.7858 353.9521,23.3488 353.4081,22.9098 C352.5511,22.2198 350.5951,20.5728 348.9481,19.2538 C354.4071,13.8118 358.8121,10.4238 366.6311,5.3008 C367.7521,4.5668 373.7921,1.3448 373.5791,0.5268 C373.4511,0.0328 363.5341,0.1448 352.1711,1.6088 C348.1791,2.1228 325.8041,5.4268 310.4411,8.7748 C294.0871,12.3378 276.8181,17.3188 260.9121,22.3258 C214.9671,36.7898 171.0961,56.3918 130.9221,83.0318 C107.8341,98.3418 86.2221,115.2368 65.3621,133.4398 C55.6411,141.9208 45.9791,150.5378 36.5451,159.3928 C35.0671,160.7798 33.6011,162.1788 32.1351,163.5788 C34.1441,163.9548 36.1521,164.3478 38.1561,164.7598 C54.7691,168.1718 71.2001,172.7318 87.1751,177.2978 C106.7131,182.8818 126.4791,188.9018 145.5921,196.2918 C134.7011,206.6528 124.0761,217.2688 113.9611,228.5028 C94.9141,249.6538 77.1581,271.9988 60.5891,295.1368 C38.9991,325.2848 20.5681,357.7988 4.5021,391.3058 C2.9801,394.4758 1.4761,397.6528 0.0001,400.8388 C2.9721,398.4598 5.9621,396.1018 8.9741,393.7648 C34.9841,373.5938 62.4081,354.9428 89.7891,336.9238 C128.3171,311.5688 169.6651,290.6218 212.5711,273.7668 C264.2991,253.4468 317.1251,233.7338 371.6051,222.1978" id="Fill-1"></path>
</g>
<g id="Group-24" transform="translate(172.000000, 352.737000)">
<mask id="mask-2" fill="#000000">
<use xlink:href="#path-1"></use>
</mask>
<g id="Clip-23"></g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.8 KiB

@ -0,0 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="496.56pt" height="403.737pt" viewBox="0 0 496.56 403.737" version="1.1">
<defs>
<clipPath id="clip1">
<path d="M 461 290 L 496.558594 290 L 496.558594 336 L 461 336 Z M 461 290 "/>
</clipPath>
<clipPath id="clip2">
<path d="M 172 351 L 225 351 L 225 403.738281 L 172 403.738281 Z M 172 351 "/>
</clipPath>
<clipPath id="clip3">
<path d="M 438 351 L 491 351 L 491 403.738281 L 438 403.738281 Z M 438 351 "/>
</clipPath>
</defs>
<g id="surface1">
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 360.621094 52.597656 C 362.570313 57.199219 363.355469 60.835938 363.246094 62.839844 C 355.6875 58.285156 344.316406 54.410156 338.113281 53.300781 C 334.074219 52.578125 347.292969 49.371094 360.621094 52.597656 M 371.605469 221.933594 C 373.941406 221.441406 376.292969 220.96875 378.644531 220.503906 C 381.105469 220.023438 383.570313 219.558594 386.042969 219.121094 C 384.058594 217.871094 382.066406 216.636719 380.0625 215.414063 C 354.609375 199.929688 327.476563 186.777344 300.664063 174.046875 C 283.746094 166.015625 266.511719 158.03125 248.964844 150.832031 C 264.273438 130.644531 283.871094 113.511719 304.816406 98.832031 C 304.835938 98.820313 304.921875 98.761719 305.050781 98.667969 C 309.636719 104.925781 315.433594 109.183594 318.339844 110.785156 C 324.019531 113.914063 331.175781 116.839844 337.753906 117.734375 C 350.6875 119.492188 361.371094 119.222656 373.1875 117.183594 C 374.253906 117 375.324219 116.871094 376.394531 116.695313 C 383.972656 115.425781 388.820313 115.234375 393.257813 115.152344 C 399.136719 115.042969 402.050781 116.285156 402.742188 116.46875 C 404.84375 117.011719 406.628906 117.910156 407.617188 119.113281 C 408.769531 120.582031 410.003906 121.96875 411.320313 123.234375 C 415.277344 127.171875 419.207031 129.351563 424.902344 129.976563 C 432.238281 130.78125 437.429688 127.914063 441.101563 123.148438 C 442.835938 120.902344 442 117.367188 441.8125 116.675781 C 440.847656 113.132813 438.625 107.980469 437.015625 103.179688 C 436.597656 101.941406 434.578125 98.128906 432.144531 95.542969 C 431.34375 94.6875 430.535156 93.832031 429.726563 92.980469 C 425.949219 88.984375 422.144531 85.019531 418.371094 81.027344 C 403.3125 65.109375 386.984375 50.453125 370.15625 36.441406 C 368.410156 34.988281 366.664063 33.53125 364.914063 32.078125 C 363.644531 31.023438 362.371094 29.976563 361.101563 28.921875 C 360.453125 28.390625 359.808594 27.855469 359.15625 27.324219 C 357.789063 26.199219 356.417969 25.078125 355.039063 23.960938 C 354.496094 23.523438 353.953125 23.085938 353.40625 22.648438 C 352.550781 21.957031 350.59375 20.308594 348.949219 18.992188 C 354.40625 13.546875 358.8125 10.160156 366.632813 5.039063 C 367.753906 4.304688 373.792969 1.082031 373.578125 0.265625 C 373.449219 -0.230469 363.535156 -0.117188 352.171875 1.347656 C 348.179688 1.859375 325.804688 5.164063 310.441406 8.511719 C 294.085938 12.074219 276.816406 17.054688 260.910156 22.0625 C 214.96875 36.527344 171.097656 56.128906 130.921875 82.769531 C 107.835938 98.078125 86.222656 114.972656 65.363281 133.175781 C 55.640625 141.65625 45.980469 150.273438 36.546875 159.128906 C 35.066406 160.515625 33.601563 161.914063 32.136719 163.316406 C 34.144531 163.691406 36.152344 164.085938 38.15625 164.496094 C 54.769531 167.910156 71.199219 172.46875 87.175781 177.035156 C 106.714844 182.617188 126.480469 188.640625 145.59375 196.027344 C 134.699219 206.390625 124.074219 217.003906 113.960938 228.238281 C 94.914063 249.390625 77.15625 271.734375 60.589844 294.875 C 39 325.023438 20.566406 357.535156 4.503906 391.042969 C 2.980469 394.210938 1.476563 397.390625 0 400.574219 C 2.972656 398.195313 5.960938 395.839844 8.972656 393.5 C 34.984375 373.332031 62.40625 354.679688 89.789063 336.660156 C 128.316406 311.304688 169.664063 290.359375 212.570313 273.503906 C 264.300781 253.183594 317.125 233.472656 371.605469 221.933594 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 257.601563 306.0625 C 257.03125 309.375 254.542969 311.796875 251.488281 311.796875 L 243.84375 311.796875 L 245.882813 300.332031 L 252.890625 300.332031 C 256.265625 300.332031 258.175781 302.75 257.601563 306.0625 M 267.792969 306.703125 C 268.558594 302.496094 267.601563 298.800781 264.925781 295.621094 C 262.25 292.371094 258.8125 290.777344 254.542969 290.777344 L 237.347656 290.777344 L 229.515625 335.359375 L 239.707031 335.359375 L 242.253906 320.710938 L 247.792969 320.710938 L 253.589844 335.359375 L 263.910156 335.359375 L 257.410156 319.3125 C 262.824219 317.210938 266.710938 312.625 267.792969 306.703125 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 280.019531 335.359375 L 287.851563 290.777344 L 277.664063 290.777344 L 269.828125 335.359375 Z M 280.019531 335.359375 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 322.4375 312.75 C 321.738281 316.636719 320.082031 319.691406 317.40625 322.050781 C 314.730469 324.40625 311.480469 325.550781 307.722656 325.550781 L 300.71875 325.550781 L 305.113281 300.585938 L 312.753906 300.585938 C 319.886719 300.585938 323.773438 305.171875 322.4375 312.75 M 314.476563 290.777344 L 296.640625 290.777344 L 288.808594 335.359375 L 306.640625 335.359375 C 313.074219 335.359375 318.679688 333.324219 323.457031 329.3125 C 328.234375 325.234375 331.164063 320.011719 332.246094 313.707031 C 333.328125 307.402344 332.117188 302.050781 328.550781 297.527344 C 325.046875 293.007813 320.335938 290.777344 314.476563 290.777344 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 348.609375 317.589844 L 364.535156 317.589844 L 366.253906 308.039063 L 350.265625 308.039063 L 351.605469 300.585938 L 369.121094 300.585938 L 370.839844 290.777344 L 343.132813 290.777344 L 335.300781 335.363281 L 363.324219 335.363281 L 365.042969 325.550781 L 347.210938 325.550781 Z M 348.609375 317.589844 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 400.773438 335.359375 L 406.886719 300.585938 L 418.351563 300.585938 L 420.070313 290.777344 L 386.953125 290.777344 L 385.234375 300.585938 L 396.695313 300.585938 L 390.582031 335.359375 Z M 400.773438 335.359375 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 435.863281 290.777344 L 425.671875 290.777344 L 417.839844 335.359375 L 428.03125 335.359375 L 431.148438 317.65625 L 445.164063 317.65625 L 442.042969 335.359375 L 452.230469 335.359375 L 460.066406 290.777344 L 449.875 290.777344 L 446.882813 307.847656 L 432.871094 307.847656 Z M 435.863281 290.777344 "/>
<g clip-path="url(#clip1)" clip-rule="nonzero">
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 494.839844 300.585938 L 496.558594 290.777344 L 468.855469 290.777344 L 461.019531 335.359375 L 489.042969 335.359375 L 490.765625 325.550781 L 472.929688 325.550781 L 474.332031 317.589844 L 490.253906 317.589844 L 491.972656 308.039063 L 475.988281 308.039063 L 477.324219 300.585938 Z M 494.839844 300.585938 "/>
</g>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 133.351563 352.988281 L 121.980469 352.988281 L 115.15625 391.796875 L 113.238281 402.742188 L 142.378906 402.742188 L 144.296875 391.796875 L 126.527344 391.796875 Z M 133.351563 352.988281 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 148.984375 402.742188 L 160.355469 402.742188 L 169.101563 352.988281 L 157.726563 352.988281 Z M 148.984375 402.742188 "/>
<g clip-path="url(#clip2)" clip-rule="nonzero">
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 198.027344 384.972656 L 210.820313 384.972656 C 208.191406 390.089844 203.355469 392.648438 196.25 392.648438 C 191.84375 392.648438 188.503906 391.296875 186.300781 388.597656 C 184.097656 385.898438 183.457031 382.34375 184.238281 377.867188 C 185.019531 373.386719 186.9375 369.832031 189.996094 367.132813 C 193.125 364.433594 196.820313 363.082031 201.15625 363.082031 C 206.628906 363.082031 210.464844 365.214844 212.742188 369.410156 L 223.1875 363.933594 C 219.492188 356.328125 212.242188 351.996094 202.363281 351.996094 C 194.96875 351.996094 188.503906 354.339844 182.960938 359.101563 C 177.484375 363.863281 174.074219 369.832031 172.867188 377.15625 C 171.660156 384.546875 173.082031 390.800781 177.273438 395.992188 C 181.464844 401.179688 187.4375 403.738281 195.113281 403.738281 C 202.503906 403.738281 208.832031 401.605469 214.089844 397.269531 C 219.421875 392.933594 222.691406 386.890625 223.96875 379.285156 L 224.679688 375.023438 L 199.734375 375.023438 Z M 198.027344 384.972656 "/>
</g>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 260.285156 372.035156 L 244.648438 372.035156 L 247.992188 352.988281 L 236.617188 352.988281 L 227.878906 402.742188 L 239.25 402.742188 L 242.730469 382.984375 L 258.367188 382.984375 L 254.886719 402.742188 L 266.257813 402.742188 L 275 352.988281 L 263.628906 352.988281 Z M 260.285156 372.035156 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 318.566406 352.988281 L 281.605469 352.988281 L 279.6875 363.933594 L 292.480469 363.933594 L 285.660156 402.742188 L 297.03125 402.742188 L 303.851563 363.933594 L 316.648438 363.933594 Z M 318.566406 352.988281 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 347.988281 380.921875 L 333.703125 352.988281 L 325.175781 352.988281 L 316.429688 402.742188 L 327.800781 402.742188 L 332.777344 374.808594 L 346.992188 402.742188 L 355.523438 402.742188 L 364.265625 352.988281 L 352.890625 352.988281 Z M 347.988281 380.921875 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 365.683594 402.742188 L 377.054688 402.742188 L 385.800781 352.988281 L 374.425781 352.988281 Z M 365.683594 402.742188 "/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 418.777344 380.921875 L 404.492188 352.988281 L 395.960938 352.988281 L 387.21875 402.742188 L 398.589844 402.742188 L 403.566406 374.808594 L 417.78125 402.742188 L 426.308594 402.742188 L 435.050781 352.988281 L 423.679688 352.988281 Z M 418.777344 380.921875 "/>
<g clip-path="url(#clip3)" clip-rule="nonzero">
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 463.980469 384.972656 L 476.773438 384.972656 C 474.144531 390.089844 469.308594 392.648438 462.203125 392.648438 C 457.796875 392.648438 454.457031 391.296875 452.25 388.597656 C 450.046875 385.898438 449.410156 382.34375 450.191406 377.867188 C 450.972656 373.386719 452.890625 369.832031 455.949219 367.132813 C 459.074219 364.433594 462.773438 363.082031 467.105469 363.082031 C 472.578125 363.082031 476.417969 365.214844 478.691406 369.410156 L 489.140625 363.933594 C 485.445313 356.328125 478.195313 351.996094 468.316406 351.996094 C 460.921875 351.996094 454.457031 354.339844 448.910156 359.101563 C 443.4375 363.863281 440.027344 369.832031 438.820313 377.15625 C 437.609375 384.546875 439.03125 390.800781 443.226563 395.992188 C 447.417969 401.179688 453.386719 403.738281 461.066406 403.738281 C 468.457031 403.738281 474.785156 401.605469 480.042969 397.269531 C 485.375 392.933594 488.640625 386.890625 489.921875 379.285156 L 490.632813 375.023438 L 465.683594 375.023438 Z M 463.980469 384.972656 "/>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/mstile-150x150.png"/>
<TileColor>#da532c</TileColor>
</tile>
</msapplication>
</browserconfig>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1009 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

@ -0,0 +1,44 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="610.000000pt" height="610.000000pt" viewBox="0 0 610.000000 610.000000"
preserveAspectRatio="xMidYMid meet">
<metadata>
Created by potrace 1.11, written by Peter Selinger 2001-2013
</metadata>
<g transform="translate(0.000000,610.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M4167 5114 c-1 -1 -29 -4 -62 -8 -33 -3 -73 -8 -90 -11 -111 -18
-172 -29 -260 -46 -96 -19 -117 -23 -214 -49 -24 -7 -51 -13 -60 -15 -33 -6
-140 -38 -276 -82 -77 -25 -144 -46 -150 -47 -5 -2 -18 -6 -27 -9 -10 -4 -26
-10 -35 -14 -10 -3 -22 -7 -28 -8 -12 -3 -143 -52 -170 -64 -65 -28 -81 -35
-90 -37 -50 -12 -570 -269 -595 -294 -3 -3 -21 -14 -40 -24 -19 -11 -75 -46
-124 -78 -49 -32 -92 -58 -95 -58 -3 0 -18 -11 -33 -25 -15 -14 -30 -25 -33
-25 -6 0 -66 -40 -75 -51 -3 -3 -48 -37 -101 -76 -54 -39 -107 -80 -119 -90
-40 -33 -57 -48 -101 -83 -77 -63 -240 -205 -310 -270 -21 -19 -67 -61 -104
-94 -36 -32 -65 -62 -65 -66 0 -4 21 -11 48 -15 57 -10 51 -9 135 -30 37 -9
73 -18 80 -19 77 -16 589 -165 642 -186 11 -5 61 -23 110 -41 50 -17 93 -34
97 -38 5 -4 -41 -55 -100 -113 -112 -111 -168 -169 -262 -278 -30 -35 -60 -68
-65 -74 -6 -6 -49 -58 -95 -116 -47 -58 -89 -110 -95 -116 -5 -6 -19 -23 -30
-38 -11 -16 -40 -54 -65 -86 -95 -124 -290 -403 -290 -416 0 -3 -11 -20 -25
-38 -14 -18 -25 -36 -25 -40 0 -4 -12 -26 -27 -49 -43 -66 -53 -81 -60 -97 -4
-8 -16 -31 -28 -50 -12 -19 -44 -78 -72 -130 -28 -52 -60 -112 -71 -132 -12
-21 -18 -38 -14 -38 4 0 3 -4 -3 -8 -11 -8 -118 -222 -111 -222 3 0 11 6 18
13 10 10 258 195 368 274 58 43 244 170 350 241 63 42 117 80 118 84 2 5 8 8
13 8 6 0 36 17 67 39 55 37 163 104 229 142 18 11 50 29 70 41 264 151 619
318 953 448 74 28 144 56 155 61 21 9 123 47 285 106 252 92 679 229 770 247
14 3 41 10 60 16 19 6 46 13 60 16 14 3 39 9 55 14 17 5 46 12 65 16 19 3 40
7 45 8 13 4 75 16 100 21 11 2 30 4 43 4 12 1 22 5 22 10 0 6 -170 110 -255
155 -11 6 -28 17 -37 25 -10 8 -18 11 -18 7 0 -3 -17 4 -37 17 -84 51 -698
347 -721 347 -5 0 -15 7 -22 15 -7 8 -18 15 -26 15 -7 0 -46 15 -86 34 -40 19
-85 38 -100 41 -16 4 -28 11 -28 15 0 5 -7 10 -16 12 -12 2 -10 10 13 35 15
18 36 42 45 54 77 98 311 309 451 406 l38 26 29 -35 c58 -70 187 -138 297
-155 91 -14 375 -5 405 13 17 11 198 12 233 3 23 -7 57 -29 83 -55 56 -56 93
-75 156 -81 99 -8 172 47 162 122 -7 56 -58 176 -93 216 -91 107 -442 446
-563 545 -19 16 -40 33 -46 39 -6 5 -30 26 -55 47 -24 20 -72 60 -107 88 l-63
52 33 30 c47 43 154 118 167 118 6 0 11 4 11 8 0 5 10 14 23 20 18 9 7 11 -56
9 -43 0 -79 -2 -80 -3z m10 -516 c12 -1 39 -85 30 -94 -3 -3 -22 3 -44 14 -45
23 -160 63 -185 65 -28 2 -21 15 10 19 24 4 157 1 189 -4z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

@ -0,0 +1,19 @@
{
"name": "",
"short_name": "",
"icons": [
{
"src": "/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
],
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone"
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/mstile-150x150.png"/>
<TileColor>#da532c</TileColor>
</tile>
</msapplication>
</browserconfig>

Binary file not shown.

After

Width:  |  Height:  |  Size: 992 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

@ -0,0 +1,44 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="610.000000pt" height="610.000000pt" viewBox="0 0 610.000000 610.000000"
preserveAspectRatio="xMidYMid meet">
<metadata>
Created by potrace 1.11, written by Peter Selinger 2001-2013
</metadata>
<g transform="translate(0.000000,610.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M4167 5114 c-1 -1 -29 -4 -62 -8 -33 -3 -73 -8 -90 -11 -111 -18
-172 -29 -260 -46 -96 -19 -117 -23 -214 -49 -24 -7 -51 -13 -60 -15 -33 -6
-140 -38 -276 -82 -77 -25 -144 -46 -150 -47 -5 -2 -18 -6 -27 -9 -10 -4 -26
-10 -35 -14 -10 -3 -22 -7 -28 -8 -12 -3 -143 -52 -170 -64 -65 -28 -81 -35
-90 -37 -50 -12 -570 -269 -595 -294 -3 -3 -21 -14 -40 -24 -19 -11 -75 -46
-124 -78 -49 -32 -92 -58 -95 -58 -3 0 -18 -11 -33 -25 -15 -14 -30 -25 -33
-25 -6 0 -66 -40 -75 -51 -3 -3 -48 -37 -101 -76 -54 -39 -107 -80 -119 -90
-40 -33 -57 -48 -101 -83 -77 -63 -240 -205 -310 -270 -21 -19 -67 -61 -104
-94 -36 -32 -65 -62 -65 -66 0 -4 21 -11 48 -15 57 -10 51 -9 135 -30 37 -9
73 -18 80 -19 77 -16 589 -165 642 -186 11 -5 61 -23 110 -41 50 -17 93 -34
97 -38 5 -4 -41 -55 -100 -113 -112 -111 -168 -169 -262 -278 -30 -35 -60 -68
-65 -74 -6 -6 -49 -58 -95 -116 -47 -58 -89 -110 -95 -116 -5 -6 -19 -23 -30
-38 -11 -16 -40 -54 -65 -86 -95 -124 -290 -403 -290 -416 0 -3 -11 -20 -25
-38 -14 -18 -25 -36 -25 -40 0 -4 -12 -26 -27 -49 -43 -66 -53 -81 -60 -97 -4
-8 -16 -31 -28 -50 -12 -19 -44 -78 -72 -130 -28 -52 -60 -112 -71 -132 -12
-21 -18 -38 -14 -38 4 0 3 -4 -3 -8 -11 -8 -118 -222 -111 -222 3 0 11 6 18
13 10 10 258 195 368 274 58 43 244 170 350 241 63 42 117 80 118 84 2 5 8 8
13 8 6 0 36 17 67 39 55 37 163 104 229 142 18 11 50 29 70 41 264 151 619
318 953 448 74 28 144 56 155 61 21 9 123 47 285 106 252 92 679 229 770 247
14 3 41 10 60 16 19 6 46 13 60 16 14 3 39 9 55 14 17 5 46 12 65 16 19 3 40
7 45 8 13 4 75 16 100 21 11 2 30 4 43 4 12 1 22 5 22 10 0 6 -170 110 -255
155 -11 6 -28 17 -37 25 -10 8 -18 11 -18 7 0 -3 -17 4 -37 17 -84 51 -698
347 -721 347 -5 0 -15 7 -22 15 -7 8 -18 15 -26 15 -7 0 -46 15 -86 34 -40 19
-85 38 -100 41 -16 4 -28 11 -28 15 0 5 -7 10 -16 12 -12 2 -10 10 13 35 15
18 36 42 45 54 77 98 311 309 451 406 l38 26 29 -35 c58 -70 187 -138 297
-155 91 -14 375 -5 405 13 17 11 198 12 233 3 23 -7 57 -29 83 -55 56 -56 93
-75 156 -81 99 -8 172 47 162 122 -7 56 -58 176 -93 216 -91 107 -442 446
-563 545 -19 16 -40 33 -46 39 -6 5 -30 26 -55 47 -24 20 -72 60 -107 88 l-63
52 33 30 c47 43 154 118 167 118 6 0 11 4 11 8 0 5 10 14 23 20 18 9 7 11 -56
9 -43 0 -79 -2 -80 -3z m10 -516 c12 -1 39 -85 30 -94 -3 -3 -22 3 -44 14 -45
23 -160 63 -185 65 -28 2 -21 15 10 19 24 4 157 1 189 -4z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

@ -0,0 +1,19 @@
{
"name": "",
"short_name": "",
"icons": [
{
"src": "/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
],
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone"
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 676 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

@ -1 +0,0 @@
{"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}

@ -5,12 +5,15 @@
<title>RTL</title>
<base href="/rtl/">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="apple-touch-icon" sizes="180x180" href="assets/images/favicon/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="assets/images/favicon/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="assets/images/favicon/favicon-16x16.png">
<link rel="manifest" href="assets/images/favicon/site.webmanifest">
<link rel="stylesheet" href="styles.c452c40f97742816928a.css"></head>
<link rel="apple-touch-icon" sizes="180x180" href="assets/images/favicon-light/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="assets/images/favicon-light/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="assets/images/favicon-light/favicon-16x16.png">
<link rel="manifest" href="assets/images/favicon-light/site.webmanifest">
<link rel="mask-icon" href="assets/images/favicon-light/safari-pinned-tab.svg" color="#5bbad5">
<meta name="msapplication-TileColor" content="#da532c">
<meta name="theme-color" content="#ffffff">
<link rel="stylesheet" href="styles.d944e28a09351c044329.css"></head>
<body>
<rtl-app></rtl-app>
<script src="runtime.4495f30fc49914e01eca.js" defer></script><script src="polyfills-es5.2ae7ace69949ec0a3f00.js" nomodule defer></script><script src="polyfills.3302e98effc5e50a54c2.js" defer></script><script src="main.069a18898a8fb5efffe7.js" defer></script></body>
<script src="runtime.d324cb9ce055cdfad42a.js" defer></script><script src="polyfills-es5.2ae7ace69949ec0a3f00.js" nomodule defer></script><script src="polyfills.3302e98effc5e50a54c2.js" defer></script><script src="main.6078c58378efda053404.js" defer></script></body>
</html>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1 +1 @@
!function(e){function r(r){for(var n,a,i=r[0],c=r[1],f=r[2],p=0,s=[];p<i.length;p++)a=i[p],Object.prototype.hasOwnProperty.call(o,a)&&o[a]&&s.push(o[a][0]),o[a]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(l&&l(r);s.length;)s.shift()();return u.push.apply(u,f||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,i=1;i<t.length;i++)0!==o[t[i]]&&(n=!1);n&&(u.splice(r--,1),e=a(a.s=t[0]))}return e}var n={},o={0:0},u=[];function a(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,a),t.l=!0,t.exports}a.e=function(e){var r=[],t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise((function(r,n){t=o[e]=[r,n]}));r.push(t[2]=n);var u,i=document.createElement("script");i.charset="utf-8",i.timeout=120,a.nc&&i.setAttribute("nonce",a.nc),i.src=function(e){return a.p+""+({}[e]||e)+"."+{1:"a69b5e7729a9d343f7d1",6:"6a316c85440aa1f75686",7:"f6c61e0cb5d1c68ec635"}[e]+".js"}(e);var c=new Error;u=function(r){i.onerror=i.onload=null,clearTimeout(f);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),u=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,t[1](c)}o[e]=void 0}};var f=setTimeout((function(){u({type:"timeout",target:i})}),12e4);i.onerror=i.onload=u,document.head.appendChild(i)}return Promise.all(r)},a.m=e,a.c=n,a.d=function(e,r,t){a.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.t=function(e,r){if(1&r&&(e=a(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(a.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)a.d(t,n,(function(r){return e[r]}).bind(null,n));return t},a.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(r,"a",r),r},a.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},a.p="",a.oe=function(e){throw console.error(e),e};var i=window.webpackJsonp=window.webpackJsonp||[],c=i.push.bind(i);i.push=r,i=i.slice();for(var f=0;f<i.length;f++)r(i[f]);var l=c;t()}([]);
!function(e){function r(r){for(var n,a,i=r[0],c=r[1],f=r[2],p=0,s=[];p<i.length;p++)a=i[p],Object.prototype.hasOwnProperty.call(o,a)&&o[a]&&s.push(o[a][0]),o[a]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(l&&l(r);s.length;)s.shift()();return u.push.apply(u,f||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,i=1;i<t.length;i++)0!==o[t[i]]&&(n=!1);n&&(u.splice(r--,1),e=a(a.s=t[0]))}return e}var n={},o={0:0},u=[];function a(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,a),t.l=!0,t.exports}a.e=function(e){var r=[],t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise((function(r,n){t=o[e]=[r,n]}));r.push(t[2]=n);var u,i=document.createElement("script");i.charset="utf-8",i.timeout=120,a.nc&&i.setAttribute("nonce",a.nc),i.src=function(e){return a.p+""+({}[e]||e)+"."+{1:"7265422b6fd577fc6798",6:"ba6a125e1b449192ae1c",7:"7189929795574f12346d"}[e]+".js"}(e);var c=new Error;u=function(r){i.onerror=i.onload=null,clearTimeout(f);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),u=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,t[1](c)}o[e]=void 0}};var f=setTimeout((function(){u({type:"timeout",target:i})}),12e4);i.onerror=i.onload=u,document.head.appendChild(i)}return Promise.all(r)},a.m=e,a.c=n,a.d=function(e,r,t){a.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.t=function(e,r){if(1&r&&(e=a(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(a.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)a.d(t,n,(function(r){return e[r]}).bind(null,n));return t},a.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(r,"a",r),r},a.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},a.p="",a.oe=function(e){throw console.error(e),e};var i=window.webpackJsonp=window.webpackJsonp||[],c=i.push.bind(i);i.push=r,i=i.slice();for(var f=0;f<i.length;f++)r(i[f]);var l=c;t()}([]);

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -37,6 +37,7 @@ const onChainCLRoutes = require("./routes/c-lightning/onchain");
const paymentsCLRoutes = require("./routes/c-lightning/payments");
const peersCLRoutes = require("./routes/c-lightning/peers");
const networkCLRoutes = require("./routes/c-lightning/network");
const messageCLRoutes = require("./routes/c-lightning/message");
app.use(cookieParser(common.secret_key));
app.use(bodyParser.json());
@ -85,6 +86,7 @@ app.use(apiCLRoot + "onchain", onChainCLRoutes);
app.use(apiCLRoot + "payments", paymentsCLRoutes);
app.use(apiCLRoot + "peers", peersCLRoutes);
app.use(apiCLRoot + "network", networkCLRoutes);
app.use(apiCLRoot + "message", messageCLRoutes);
app.use((req, res, next) => {
res.sendFile(path.join(__dirname, "angular", "index.html"));

@ -20,7 +20,6 @@ common.getSelLNServerUrl = () => {
common.getOptions = () => {
common.selectedNode.options.method = 'GET';
// common.selectedNode.options.form = {};
common.selectedNode.options.qs = {};
return common.selectedNode.options;
};
@ -55,7 +54,7 @@ common.updateSelectedNodeOptions = () => {
}
common.setOptions = () => {
if (undefined !== common.nodes[0].options && undefined !== common.nodes[0].options.headers) { return; }
if ( common.nodes[0].options && common.nodes[0].options.headers) { return; }
if (common.nodes && common.nodes.length > 0) {
common.nodes.forEach(node => {
node.options = {

@ -191,7 +191,7 @@ connect.validateNodeConfig = (config) => {
}
connect.setSSOParams(config);
if (errMsg !== '') { throw new Error(errMsg); }
if (errMsg && errMsg.trim() !== '') { throw new Error(errMsg); }
}
connect.setSSOParams = (config) => {
@ -215,7 +215,8 @@ connect.setSSOParams = (config) => {
} else {
common.rtl_cookie_path = common.rtl_conf_file_path + '/cookies/auth.cookie';
}
if (common.rtl_cookie_path === '') {
if (!common.rtl_cookie_path || common.rtl_cookie_path.trim() === '') {
errMsg = 'Please set rtlCookiePath value for single sign on option!';
} else {
connect.readCookie(common.rtl_cookie_path);

@ -174,10 +174,10 @@ exports.getConfig = (req, res, next) => {
exports.getCurrencyRates = (req, res, next) => {
options.url = 'https://blockchain.info/ticker';
request(options).then((body) => {
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Rates Failed!",
error: (undefined === body) ? 'Error From External Server!' : body.error
error: (!body) ? 'Error From External Server!' : body.error
});
} else {
res.status(200).json(body);

@ -8,19 +8,19 @@ exports.getBalance = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/getBalance';
request(options).then((body) => {
logger.info({fileName: 'Balance', msg: ' Balance Received: ' + JSON.stringify(body)});
if(undefined === body.totalBalance) {
if(!body.totalBalance) {
body.totalBalance = 0;
body.btc_totalBalance = 0;
} else {
body.btc_totalBalance = common.convertToBTC(body.totalBalance);
}
if(undefined === body.confBalance) {
if(!body.confBalance) {
body.confBalance = 0;
body.btc_confBalance = 0;
} else {
body.btc_confBalance = common.convertToBTC(body.confBalance);
}
if(undefined === body.unconfBalance) {
if(!body.unconfBalance) {
body.unconfBalance = 0;
body.btc_unconfBalance = 0;
} else {

@ -32,10 +32,10 @@ exports.openChannel = (req, res, next) => {
logger.info({fileName: 'Channels', msg: 'Open Channel Options: ' + JSON.stringify(options.body)});
request.post(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Open Channel Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'Open Channel Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);
@ -57,10 +57,10 @@ exports.setChannelFee = (req, res, next) => {
logger.info({fileName: 'Channels', msg: 'Update Channel Policy Options: ' + JSON.stringify(options.body)});
request.post(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Update Channel Policy: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'Update Channel Policy Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);
@ -82,10 +82,10 @@ exports.closeChannel = (req, res, next) => {
logger.info({fileName: 'Channels', msg: 'Closing Channel: ' + options.url});
request.delete(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Close Channel Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'Close Channel Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(204).json(body);
@ -105,13 +105,13 @@ exports.getLocalRemoteBalance = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/channel/localremotebal';
request(options).then(function (body) {
logger.info({fileName: 'Channels', msg: 'Local Remote Balance: ' + JSON.stringify(body)});
if(undefined === body.localBalance) {
if(!body.localBalance) {
body.localBalance = 0;
body.btc_localBalance = 0;
} else {
body.btc_localBalance = common.convertToBTC(body.localBalance);
}
if(undefined === body.remoteBalance) {
if(!body.remoteBalance) {
body.remoteBalance = 0;
body.btc_remoteBalance = 0;
} else {
@ -134,17 +134,17 @@ exports.listForwards = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/channel/listForwards/';
request.get(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Forwarding History Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
logger.error({fileName: 'Channels', lineNum: 27, msg: 'Forwarding History Error: ' + JSON.stringify((undefined === body) ? 'Error From Server!' : body.error)});
if(!body || body.error) {
logger.error({fileName: 'Channels', lineNum: 27, msg: 'Forwarding History Error: ' + JSON.stringify((!body) ? 'Error From Server!' : body.error)});
res.status(500).json({
message: "Forwarding History Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
if (body && body.length > 0) {
body.forEach(event => {
event.received_time_str = (undefined === event.received_time) ? '' : common.convertTimestampToDate(event.received_time);
event.resolved_time_str = (undefined === event.resolved_time) ? '' : common.convertTimestampToDate(event.resolved_time);
event.received_time_str = (!event.received_time) ? '' : common.convertTimestampToDate(event.received_time);
event.resolved_time_str = (!event.resolved_time) ? '' : common.convertTimestampToDate(event.resolved_time);
});
body = common.sortDescByKey(body, 'received_time');
}

@ -8,13 +8,13 @@ exports.getFees = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/getFees';
request(options).then((body) => {
logger.info({fileName: 'Fees', msg: 'Fee Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching fee failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
if(undefined === body.feeCollected) {
if(!body.feeCollected) {
body.feeCollected = 0;
body.btc_feeCollected = 0;
} else {

@ -11,12 +11,12 @@ exports.getInfo = (req, res, next) => {
logger.info({fileName: 'GetInfo', msg: 'Calling getinfo from c-lightning server url: ' + options.url});
request(options).then((body) => {
logger.info({fileName: 'GetInfo', msg: JSON.stringify(body)});
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
if(undefined === body || search_idx > -1 || body.error) {
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching Info failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
body.currency_unit = 'BTC';

@ -9,10 +9,10 @@ exports.deleteExpiredInvoice = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/invoice/delExpiredInvoice' + queryStr;
request.delete(options).then((body) => {
logger.info({fileName: 'Invoice', msg: 'Invoices Deleted: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Deleting Invoice Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
res.status(204).json({status: 'Invoice Deleted Successfully'});
@ -31,16 +31,16 @@ exports.listInvoices = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/invoice/listInvoices' + labelQuery;
request(options).then((body) => {
logger.info({fileName: 'Invoice', msg: 'Invoices List Received: ' + body});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Invoice Info failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
if (undefined !== body.invoices && body.invoices.length > 0) {
if ( body.invoices && body.invoices.length > 0) {
body.invoices.forEach(invoice => {
invoice.paid_at_str = (undefined === invoice.paid_at) ? '' : common.convertTimestampToDate(invoice.paid_at);
invoice.expires_at_str = (undefined === invoice.expires_at) ? '' : common.convertTimestampToDate(invoice.expires_at);
invoice.paid_at_str = (!invoice.paid_at) ? '' : common.convertTimestampToDate(invoice.paid_at);
invoice.expires_at_str = (!invoice.expires_at) ? '' : common.convertTimestampToDate(invoice.expires_at);
});
body.invoices = common.sortDescByKey(body.invoices, 'expires_at');
}
@ -62,10 +62,10 @@ exports.addInvoice = (req, res, next) => {
options.body = req.body;
request.post(options).then((body) => {
logger.info({fileName: 'Invoice', msg: 'Add Invoice Responce: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Add Invoice Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);

@ -0,0 +1,51 @@
var request = require('request-promise');
var common = require('../../common');
var logger = require('../logger');
var options = {};
exports.signMessage = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/utility/signMessage';
options.form = { message: req.body.message };
request.post(options, (error, response, body) => {
logger.info({fileName: 'Messages', msg: 'Message Signed: ' + JSON.stringify(body)});
if(!body || body.error) {
res.status(500).json({
message: "Sign message failed!",
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);
}
})
.catch(function (err) {
logger.error({fileName: 'Messages', lineNum: 24, msg: 'Sign Message Failed: ' + JSON.stringify(err)});
return res.status(500).json({
message: 'Sign Message Failed!',
error: err.error
});
});
};
exports.verifyMessage = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/utility/checkMessage/' + req.body.message + '/' + req.body.signature;
request.get(options, (error, response, body) => {
logger.info({fileName: 'Messages', msg: 'Message Verified: ' + JSON.stringify(body)});
if(!body || body.error) {
res.status(500).json({
message: "Verify message failed!",
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);
}
})
.catch(function (err) {
logger.error({fileName: 'Messages', lineNum: 24, msg: 'Message Verification Failed: ' + JSON.stringify(err)});
return res.status(500).json({
message: 'Verify Message Failed!',
error: err.error
});
});
};

@ -8,10 +8,10 @@ exports.getRoute = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/network/getRoute/' + req.params.destPubkey + '/' + req.params.amount;
request(options).then((body) => {
logger.info({fileName: 'Network', msg: 'Query Routes Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Query Routes Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
res.status(200).json({routes: body});

@ -24,10 +24,10 @@ exports.onChainWithdraw = (req, res, next) => {
logger.info({fileName: 'OnChain', msg: 'OnChain Withdraw Options: ' + JSON.stringify(options.body)});
request.post(options).then((body) => {
logger.info({fileName: 'OnChain', msg: 'OnChain Withdraw Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'OnChain Withdraw Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);

@ -8,15 +8,15 @@ exports.listPayments = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/pay/listPayments';
request(options).then((body) => {
logger.info({fileName: 'Payments', msg: 'Payment List Received: ' + JSON.stringify(body.payments)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Payments List Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
if (undefined !== body && undefined !== body.payments && body.payments.length > 0) {
if ( body && body.payments && body.payments.length > 0) {
body.payments.forEach(payment => {
payment.created_at_str = (undefined === payment.created_at) ? '' : common.convertTimestampToDate(payment.created_at);
payment.created_at_str = (!payment.created_at) ? '' : common.convertTimestampToDate(payment.created_at);
});
body.payments = common.sortDescByKey(body.payments, 'created_at');
}
@ -36,14 +36,14 @@ exports.decodePayment = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/pay/decodePay/' + req.params.invoice;
request(options).then((body) => {
logger.info({fileName: 'Payments', msg: 'Payment Decode Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Payment Request Decode Failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
body.created_at_str = (undefined === body.created_at) ? '' : common.convertTimestampToDate(body.created_at);
body.expire_at_str = (undefined === body.created_at || undefined === body.expiry) ? '' : common.convertTimestampToDate(body.created_at + body.expiry);
body.created_at_str = (!body.created_at) ? '' : common.convertTimestampToDate(body.created_at);
body.expire_at_str = (!body.created_at || !body.expiry) ? '' : common.convertTimestampToDate(body.created_at + body.expiry);
res.status(200).json(body);
}
})
@ -61,10 +61,10 @@ exports.postPayment = (req, res, next) => {
options.body = req.body;
request.post(options).then((body) => {
logger.info({fileName: 'Payments', msg: 'Payment Post Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Payment Post Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);

@ -7,7 +7,7 @@ exports.getPeers = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/peer/listPeers';
request(options).then(function (body) {
let peers = (undefined !== body) ? common.sortDescByKey(body, 'alias') : [];
let peers = ( body) ? common.sortDescByKey(body, 'alias') : [];
logger.info({fileName: 'Peers', msg: 'Peers with Alias: ' + JSON.stringify(peers)});
res.status(200).json(peers);
})
@ -24,16 +24,16 @@ exports.postPeer = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/peer/connect';
options.body = req.body;
request.post(options, (error, response, body) => {
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Adding peer failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
logger.info({fileName: 'Peers', msg: 'Peer Added: ' + JSON.stringify(body)});
options.url = common.getSelLNServerUrl() + '/peer/listPeers';
request(options).then(function (body) {
let peers = (undefined !== body) ? common.sortDescByKey(body, 'alias') : [];
let peers = ( body) ? common.sortDescByKey(body, 'alias') : [];
peers = common.newestOnTop(peers, 'id', req.body.id);
logger.info({fileName: 'Peers', msg: 'Peer with Newest On Top: ' + JSON.stringify(peers)});
logger.info({fileName: 'Peers', msg: 'Peer Added Successfully'});
@ -53,10 +53,10 @@ exports.deletePeer = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/peer/disconnect/' + req.params.peerId + '?force=' + req.query.force;
request.delete(options).then((body) => {
logger.info({fileName: 'Peers', msg: 'Detach Peer Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Detach peer failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
logger.info({fileName: 'Peers', msg: 'Peer Detached: ' + req.params.peerId});

@ -10,7 +10,7 @@ exports.getBalance = (req, res, next) => {
options.qs = req.query;
request(options).then((body) => {
logger.info({fileName: 'Balance', msg: 'Request params: ' + JSON.stringify(req.params) + 'Request Query: ' + JSON.stringify(req.query) + ' Balance Received: ' + JSON.stringify(body)});
if(undefined !== body) {
if( body) {
if (upperCase(req.params.source) === 'BLOCKCHAIN') {
if (!body.total_balance) { body.total_balance = 0; }
if (!body.confirmed_balance) { body.confirmed_balance = 0; }

@ -23,7 +23,7 @@ exports.getAllChannels = (req, res, next) => {
let remote = 0;
let total = 0;
request(options).then(function (body) {
logger.info({fileName: 'Channels', msg: 'All Channels Received: ' + JSON.stringify(body)});
logger.info({fileName: 'Channels', msg: 'All Channels Received: ' + JSON.stringify(body)});
if(body.channels) {
Promise.all(
body.channels.map(channel => {
@ -65,7 +65,7 @@ exports.getPendingChannels = (req, res, next) => {
options.qs = req.query;
request(options).then(function (body) {
let channels = [];
if (undefined === body.total_limbo_balance) {
if (!body.total_limbo_balance) {
body.total_limbo_balance = 0;
body.btc_total_limbo_balance = 0;
} else {
@ -91,9 +91,9 @@ exports.getClosedChannels = (req, res, next) => {
let channels = [];
if (body.channels && body.channels.length > 0) {
body.channels.forEach(channel => {
channel.close_type = (undefined === channel.close_type) ? 'COOPERATIVE_CLOSE' : channel.close_type;
channel.close_type = (!channel.close_type) ? 'COOPERATIVE_CLOSE' : channel.close_type;
});
body.channels = common.sortDescByKey(body.channels, 'close_type');
body.channels = common.sortDescByKey(body.channels, 'close_height');
}
logger.info({fileName: 'Channels', msg: 'Closed Channels: ' + JSON.stringify(body)});
res.status(200).json(body);
@ -124,10 +124,10 @@ exports.postChannel = (req, res, next) => {
options.form = JSON.stringify(options.form);
request.post(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Channel Open Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'Open Channel Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);
@ -198,10 +198,10 @@ exports.closeChannel = (req, res, next) => {
logger.info({fileName: 'Channels', msg: 'Closing Channel: ' + options.url});
request.delete(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Close Channel Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'Close Channel Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(204).json({message: 'Channel Closed!'});
@ -240,10 +240,10 @@ exports.postChanPolicy = (req, res, next) => {
logger.info({fileName: 'Channels', msg: 'Update Channel Policy Options: ' + JSON.stringify(options.form)});
request.post(options).then((body) => {
logger.info({fileName: 'Channels', msg: 'Update Channel Policy: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: 'Update Channel Failed!',
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);

@ -10,7 +10,7 @@ function getFilesList(callback) {
let response = {all_restore_exists: false, files: []};
fs.readdir(common.selectedNode.channel_backup_path + common.path_separator + 'restore', function (err, files) {
if (err && err.code !== 'ENOENT' && err.errno !== -4058) { response = { message: 'Channels Restore List Failed!', error: err } }
if(undefined !== files && files.length > 0) {
if( files && files.length > 0) {
files.forEach(file => {
if (!file.includes('.restored')) {
if (file === 'channel-all.bak') {

@ -9,25 +9,25 @@ exports.getFees = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/fees';
request(options).then((body) => {
logger.info({fileName: 'Fees', msg: 'Fee Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching fee failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
if (undefined === body.day_fee_sum) {
if (!body.day_fee_sum) {
body.day_fee_sum = 0;
body.btc_day_fee_sum = 0;
} else {
body.btc_day_fee_sum = common.convertToBTC(body.day_fee_sum);
}
if (undefined === body.week_fee_sum) {
if (!body.week_fee_sum) {
body.week_fee_sum = 0;
body.btc_week_fee_sum = 0;
} else {
body.btc_week_fee_sum = common.convertToBTC(body.week_fee_sum);
}
if (undefined === body.month_fee_sum) {
if (!body.month_fee_sum) {
body.month_fee_sum = 0;
body.btc_month_fee_sum = 0;
} else {

@ -20,12 +20,12 @@ exports.getInfo = (req, res, next) => {
logger.info({fileName: 'GetInfo', msg: 'Calling getinfo from lnd server url: ' + options.url});
request(options).then((body) => {
logger.info({fileName: 'GetInfo', msg: JSON.stringify(body)});
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
if(undefined === body || search_idx > -1 || body.error) {
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching Info Failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
res.status(200).json(body);

@ -20,13 +20,13 @@ exports.getDescribeGraph = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/graph';
request.get(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
logger.info({fileName: 'Graph', msg: 'Describe Graph Received: ' + body_str});
if(undefined === body || search_idx > -1 || body.error) {
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching Describe Graph Failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
res.status(200).json(body);
@ -44,19 +44,19 @@ exports.getGraphInfo = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/graph/info';
request.get(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
logger.info({fileName: 'Graph', msg: 'Network Info Received: ' + body_str});
if(undefined === body || search_idx > -1 || body.error) {
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching network Info failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
body.btc_total_network_capacity = (undefined === body.total_network_capacity) ? 0 : common.convertToBTC(body.total_network_capacity);
body.btc_avg_channel_size = (undefined === body.avg_channel_size) ? 0 : common.convertToBTC(body.avg_channel_size);
body.btc_min_channel_size = (undefined === body.min_channel_size) ? 0 : common.convertToBTC(body.min_channel_size);
body.btc_max_channel_size = (undefined === body.max_channel_size) ? 0 : common.convertToBTC(body.max_channel_size);
body.btc_total_network_capacity = (!body.total_network_capacity) ? 0 : common.convertToBTC(body.total_network_capacity);
body.btc_avg_channel_size = (!body.avg_channel_size) ? 0 : common.convertToBTC(body.avg_channel_size);
body.btc_min_channel_size = (!body.min_channel_size) ? 0 : common.convertToBTC(body.min_channel_size);
body.btc_max_channel_size = (!body.max_channel_size) ? 0 : common.convertToBTC(body.max_channel_size);
logger.info({fileName: 'Graph', msg: 'Network Information After Rounding and Conversion: ' + body_str});
res.status(200).json(body);
}
@ -74,14 +74,14 @@ exports.getGraphNode = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/graph/node/' + req.params.pubKey;
request(options).then((body) => {
logger.info({fileName: 'Graph', msg: 'Node Info Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching node Info failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
if (undefined !== body) {
body.node.last_update_str = (undefined === body.node.last_update) ? '' : common.convertTimestampToDate(body.node.last_update);
if ( body) {
body.node.last_update_str = (!body.node.last_update) ? '' : common.convertTimestampToDate(body.node.last_update);
}
res.status(200).json(body);
})
@ -98,14 +98,14 @@ exports.getGraphEdge = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/graph/edge/' + req.params.chanid;
request(options).then((body) => {
logger.info({fileName: 'Graph', msg: 'Edge Info Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Edge Info Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
if (undefined !== body) {
body.last_update_str = (undefined === body.last_update) ? '' : common.convertTimestampToDate(body.last_update);
if ( body) {
body.last_update_str = (!body.last_update) ? '' : common.convertTimestampToDate(body.last_update);
}
res.status(200).json(body);
})
@ -120,20 +120,21 @@ exports.getGraphEdge = (req, res, next) => {
exports.getQueryRoutes = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/graph/routes/' + req.params.destPubkey + '/' + req.params.amount;
if(req.query.outgoingChanId) {
options.url = options.url + '?outgoing_chan_id=' + req.query.outgoingChanId;
if(req.query.outgoing_chan_id) {
options.url = options.url + '?outgoing_chan_id=' + req.query.outgoing_chan_id;
}
logger.info({fileName: 'Graph', msg: 'Query Routes URL: ' + options.url});
request(options).then((body) => {
logger.info({fileName: 'Graph', msg: 'Query Routes Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Query Routes Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
if (undefined !== body.routes && body.routes.length > 0) {
if ( body.routes && body.routes.length > 0) {
body.routes.forEach(route => {
if (undefined !== route.hops) {
if ( route.hops) {
Promise.all(
route.hops.map((hop, i) => {
hop.hop_sequence = i + 1;
@ -166,14 +167,14 @@ exports.getRemoteFeePolicy = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/graph/edge/' + req.params.chanid;
request(options).then((body) => {
logger.info({fileName: 'Graph', msg: 'Edge Info Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Edge Info Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
if (undefined !== body) {
body.last_update_str = (undefined === body.last_update) ? '' : common.convertTimestampToDate(body.last_update);
if ( body) {
body.last_update_str = (!body.last_update) ? '' : common.convertTimestampToDate(body.last_update);
}
remoteNodeFee = {};

@ -6,18 +6,18 @@ exports.getGraphInfo = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/graph/info';
request(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
if(undefined === body || search_idx > -1 || body.error) {
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching network Info failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
body.btc_total_network_capacity = (undefined === body.total_network_capacity) ? 0 : common.convertToBTC(body.total_network_capacity);
body.btc_avg_channel_size = (undefined === body.avg_channel_size) ? 0 : common.convertToBTC(body.avg_channel_size);
body.btc_min_channel_size = (undefined === body.min_channel_size) ? 0 : common.convertToBTC(body.min_channel_size);
body.btc_max_channel_size = (undefined === body.max_channel_size) ? 0 : common.convertToBTC(body.max_channel_size);
body.btc_total_network_capacity = (!body.total_network_capacity) ? 0 : common.convertToBTC(body.total_network_capacity);
body.btc_avg_channel_size = (!body.avg_channel_size) ? 0 : common.convertToBTC(body.avg_channel_size);
body.btc_min_channel_size = (!body.min_channel_size) ? 0 : common.convertToBTC(body.min_channel_size);
body.btc_max_channel_size = (!body.max_channel_size) ? 0 : common.convertToBTC(body.max_channel_size);
res.status(200).json(body);
}
});

@ -8,10 +8,10 @@ exports.getInvoice = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/invoice/' + req.params.rHashStr;
request(options).then((body) => {
logger.info({fileName: 'Invoice', msg: 'Invoice Info Received: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Fetching Invoice Info Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
}
res.status(200).json(body);
@ -29,21 +29,21 @@ exports.listInvoices = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/invoices?num_max_invoices=' + req.query.num_max_invoices + '&index_offset=' + req.query.index_offset +
'&reversed=' + req.query.reversed;
request(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
logger.info({fileName: 'Invoice', msg: 'Invoices List Received: ' + body_str});
if(undefined === body || search_idx > -1 || body.error) {
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching Invoice Info failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
if (body.invoices && body.invoices.length > 0) {
body.invoices.forEach(invoice => {
invoice.creation_date_str = (undefined === invoice.creation_date) ? '' : common.convertTimestampToDate(invoice.creation_date);
invoice.settle_date_str = (undefined === invoice.settle_date) ? '' : common.convertTimestampToDate(invoice.settle_date);
invoice.btc_value = (undefined === invoice.value) ? 0 : common.convertToBTC(invoice.value);
invoice.btc_amt_paid_sat = (undefined === invoice.amt_paid_sat) ? 0 : common.convertToBTC(invoice.amt_paid_sat);
invoice.creation_date_str = (!invoice.creation_date) ? '' : common.convertTimestampToDate(invoice.creation_date);
invoice.settle_date_str = (!invoice.settle_date || invoice.settle_date === '0') ? '' : common.convertTimestampToDate(invoice.settle_date);
invoice.btc_value = (!invoice.value) ? 0 : common.convertToBTC(invoice.value);
invoice.btc_amt_paid_sat = (!invoice.amt_paid_sat) ? 0 : common.convertToBTC(invoice.amt_paid_sat);
});
body.invoices = common.sortDescByKey(body.invoices, 'creation_date');
}
@ -75,10 +75,10 @@ exports.addInvoice = (req, res, next) => {
options.form = JSON.stringify(options.form);
request.post(options).then((body) => {
logger.info({fileName: 'Invoice', msg: 'Add Invoice Responce: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Add Invoice Failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);

@ -7,13 +7,13 @@ exports.getNewAddress = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/newaddress?type=' + req.query.type;
request(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
logger.info({fileName: 'NewAddress', msg: 'New Address Received: ' + body_str});
if(undefined === body || search_idx > -1 || body.error) {
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching new address failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
res.status(200).json(body);

@ -7,18 +7,18 @@ exports.getPayments = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/payments';
request(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
logger.info({fileName: 'Payments', msg: 'Payment Decoded Received: ' + body_str});
if(undefined === body || search_idx > -1 || body.error) {
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Payments List Failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
if (undefined !== body.payments && body.payments.length > 0) {
if ( body.payments && body.payments.length > 0) {
body.payments.forEach(payment => {
payment.creation_date_str = (undefined === payment.creation_date) ? '' : common.convertTimestampToDate(payment.creation_date);
payment.creation_date_str = (!payment.creation_date) ? '' : common.convertTimestampToDate(payment.creation_date);
});
body.payments = common.sortDescByKey(body.payments, 'creation_date');
}

@ -20,15 +20,15 @@ exports.getPeers = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/peers';
request(options).then(function (body) {
logger.info({fileName: 'Peers', msg: 'Peers Received: ' + JSON.stringify(body)});
let peers = (undefined === body.peers) ? [] : body.peers;
logger.info({fileName: 'Peers', msg: 'Peers Received: ' + JSON.stringify(body)});
let peers = !body.peers ? [] : body.peers;
Promise.all(
peers.map(peer => {
return getAliasForPeers(peer);
}))
.then(function(values) {
logger.info({fileName: 'Peers', msg: 'Peers with Alias before Sort: ' + JSON.stringify(body)});
if (undefined !== body.peers) {
logger.info({fileName: 'Peers', msg: 'Peers with Alias before Sort: ' + JSON.stringify(body)});
if (body.peers) {
body.peers = common.sortDescByKey(body.peers, 'alias');
}
logger.info({fileName: 'Peers', msg: 'Peers with Alias after Sort: ' + JSON.stringify(body)});
@ -36,7 +36,7 @@ exports.getPeers = (req, res, next) => {
});
})
.catch((err) => {
logger.error({fileName: 'Peers', lineNum: 39, msg: 'Peers List Failed: ' + JSON.stringify(err.error)});
logger.error({fileName: 'Peers', lineNum: 39, msg: 'Peers List Failed: ' + JSON.stringify(err)});
return res.status(500).json({
message: "Peers List Failed!",
error: err.error
@ -53,21 +53,21 @@ exports.postPeer = (req, res, next) => {
});
request.post(options, (error, response, body) => {
logger.info({fileName: 'Peers', msg: 'Peer Added: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Adding peer failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
options.url = common.getSelLNServerUrl() + '/peers';
request(options).then(function (body) {
let peers = (undefined === body.peers) ? [] : body.peers;
let peers = (!body.peers) ? [] : body.peers;
Promise.all(
peers.map(peer => {
return getAliasForPeers(peer);
}))
.then(function(values) {
if (undefined !== body.peers) {
if ( body.peers) {
body.peers = common.sortDescByKey(body.peers, 'alias');
logger.info({fileName: 'Peers', msg: 'Peer with Alias: ' + JSON.stringify(body)});
body.peers = common.newestOnTop(body.peers, 'pub_key', req.body.pubkey);
@ -92,10 +92,10 @@ exports.deletePeer = (req, res, next) => {
options.url = common.getSelLNServerUrl() + '/peers/' + req.params.peerPubKey;
request.delete(options).then((body) => {
logger.info({fileName: 'Peers', msg: 'Detach Peer Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Detach peer failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
logger.info({fileName: 'Peers', msg: 'Peer Detached: ' + req.params.peerPubKey});
@ -108,4 +108,4 @@ exports.deletePeer = (req, res, next) => {
error: err.error
});
});
};
};

@ -7,18 +7,18 @@ exports.getTransactions = (req, res, next) => {
options = common.getOptions();
options.url = common.getSelLNServerUrl() + '/transactions';
request(options).then((body) => {
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
logger.info({fileName: 'Transactions', msg: 'Transaction Received: ' + body_str});
if(undefined === body || search_idx > -1 || body.error) {
if(!body || search_idx > -1 || body.error) {
res.status(500).json({
message: "Fetching Transactions Failed!",
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
error: (!body || search_idx > -1) ? 'Error From Server!' : body.error
});
} else {
if (undefined !== body.transactions && body.transactions.length > 0) {
if ( body.transactions && body.transactions.length > 0) {
body.transactions.forEach(transaction => {
transaction.time_stamp_str = (undefined === transaction.time_stamp) ? '' : common.convertTimestampToDate(transaction.time_stamp);
transaction.time_stamp_str = (!transaction.time_stamp) ? '' : common.convertTimestampToDate(transaction.time_stamp);
});
body.transactions = common.sortDescByKey(body.transactions, 'time_stamp');
}
@ -48,10 +48,10 @@ exports.postTransactions = (req, res, next) => {
options.form = JSON.stringify(options.form);
request.post(options).then((body) => {
logger.info({fileName: 'Transactions', msg: 'Transaction Post Response: ' + JSON.stringify(body)});
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Transactions post failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(201).json(body);

@ -6,16 +6,16 @@ var options = {};
exports.genSeed = (req, res, next) => {
options = common.getOptions();
if (undefined !== req.params.passphrase) {
if ( req.params.passphrase) {
options.url = common.getSelLNServerUrl() + '/genseed?aezeed_passphrase=' + Buffer.from(atob(req.params.passphrase)).toString('base64');
} else {
options.url = common.getSelLNServerUrl() + '/genseed';
}
request(options).then((body) => {
if(undefined === body || body.error) {
if(!body || body.error) {
res.status(500).json({
message: "Genseed failed!",
error: (undefined === body) ? 'Error From Server!' : body.error
error: (!body) ? 'Error From Server!' : body.error
});
} else {
res.status(200).json(body);
@ -32,7 +32,7 @@ exports.genSeed = (req, res, next) => {
exports.operateWallet = (req, res, next) => {
options = common.getOptions();
options.method = 'POST';
if (undefined === req.params.operation || req.params.operation === 'unlockwallet') {
if (!req.params.operation || req.params.operation === 'unlockwallet') {
options.url = common.getSelLNServerUrl() + '/unlockwallet';
options.form = JSON.stringify({
wallet_password: Buffer.from(atob(req.body.wallet_password)).toString('base64')
@ -40,7 +40,7 @@ exports.operateWallet = (req, res, next) => {
err_message = 'Unlocking wallet failed! Verify that lnd is running and the wallet is locked!';
} else {
options.url = common.getSelLNServerUrl() + '/initwallet';
if (undefined !== req.body.aezeed_passphrase && req.body.aezeed_passphrase !== '') {
if ( req.body.aezeed_passphrase && req.body.aezeed_passphrase !== '') {
options.form = JSON.stringify({
wallet_password: Buffer.from(atob(req.body.wallet_password)).toString('base64'),
cipher_seed_mnemonic: req.body.cipher_seed_mnemonic,
@ -56,9 +56,9 @@ exports.operateWallet = (req, res, next) => {
}
request(options).then((body) => {
logger.info({fileName: 'Wallet', msg: 'Wallet Response: ' + JSON.stringify(body)});
const body_str = (undefined === body) ? '' : JSON.stringify(body);
const search_idx = (undefined === body) ? -1 : body_str.search('Not Found');
if(undefined === body) {
const body_str = (!body) ? '' : JSON.stringify(body);
const search_idx = (!body) ? -1 : body_str.search('Not Found');
if(!body) {
res.status(500).json({
message: err_message,
error: (error) ? error : err_message

@ -13,11 +13,11 @@ We believe UX improvement is a never-ending cycle. And, we must keep the UI/UX f
As the functional complexity increases, we need to add automated testing to ensure quality and less bugs. Another area, where developer contribution is more than welcome.
### LND Loop Integration
LND's Loop-Out and Loop-In are important tools for channel re-balancing and will be integrated with RTL UI in the near future.
* Loop-Out
LND's Loop Out and Loop In are important tools for channel re-balancing and will be integrated with RTL UI in the near future.
* Loop Out
![](../screenshots/Loop-Out-info.png)
* Loop-In
* Loop In
![](../screenshots/Loop-In-info.png)

333
package-lock.json generated

@ -1,6 +1,6 @@
{
"name": "rtl",
"version": "0.6.7-beta",
"version": "0.6.8-beta",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@ -4429,12 +4429,6 @@
"integrity": "sha512-mLQ4i2QO1ytvGWFWmcngKO//JXAQueZvwEKtjgQFM4jIK0kU+ytMfplL8j+n5mspOfjHwoAg+9yhb7BwAHm36g==",
"dev": true
},
"base64id": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/base64id/-/base64id-1.0.0.tgz",
"integrity": "sha1-R2iMuZu2gE8OBtPnY7HDLlfY5rY=",
"dev": true
},
"batch": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/batch/-/batch-0.6.1.tgz",
@ -6104,102 +6098,6 @@
"once": "^1.4.0"
}
},
"engine.io": {
"version": "3.2.1",
"resolved": "https://registry.npmjs.org/engine.io/-/engine.io-3.2.1.tgz",
"integrity": "sha512-+VlKzHzMhaU+GsCIg4AoXF1UdDFjHHwMmMKqMJNDNLlUlejz58FCy4LBqB2YVJskHGYl06BatYWKP2TVdVXE5w==",
"dev": true,
"requires": {
"accepts": "~1.3.4",
"base64id": "1.0.0",
"cookie": "0.3.1",
"debug": "~3.1.0",
"engine.io-parser": "~2.1.0",
"ws": "~3.3.1"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
},
"ws": {
"version": "3.3.3",
"resolved": "https://registry.npmjs.org/ws/-/ws-3.3.3.tgz",
"integrity": "sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==",
"dev": true,
"requires": {
"async-limiter": "~1.0.0",
"safe-buffer": "~5.1.0",
"ultron": "~1.1.0"
}
}
}
},
"engine.io-client": {
"version": "3.2.1",
"resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-3.2.1.tgz",
"integrity": "sha512-y5AbkytWeM4jQr7m/koQLc5AxpRKC1hEVUb/s1FUAWEJq5AzJJ4NLvzuKPuxtDi5Mq755WuDvZ6Iv2rXj4PTzw==",
"dev": true,
"requires": {
"component-emitter": "1.2.1",
"component-inherit": "0.0.3",
"debug": "~3.1.0",
"engine.io-parser": "~2.1.1",
"has-cors": "1.1.0",
"indexof": "0.0.1",
"parseqs": "0.0.5",
"parseuri": "0.0.5",
"ws": "~3.3.1",
"xmlhttprequest-ssl": "~1.5.4",
"yeast": "0.1.2"
},
"dependencies": {
"component-emitter": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz",
"integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=",
"dev": true
},
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
},
"ws": {
"version": "3.3.3",
"resolved": "https://registry.npmjs.org/ws/-/ws-3.3.3.tgz",
"integrity": "sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==",
"dev": true,
"requires": {
"async-limiter": "~1.0.0",
"safe-buffer": "~5.1.0",
"ultron": "~1.1.0"
}
}
}
},
"engine.io-parser": {
"version": "2.1.3",
"resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-2.1.3.tgz",
"integrity": "sha512-6HXPre2O4Houl7c4g7Ic/XzPnHBvaEmN90vtRO9uLmwtRqQmTOw0QMevL1TOfL2Cpu1VzsaTmMotQgMdkzGkVA==",
"dev": true,
"requires": {
"after": "0.8.2",
"arraybuffer.slice": "~0.0.7",
"base64-arraybuffer": "0.1.5",
"blob": "0.0.5",
"has-binary2": "~1.0.2"
}
},
"enhanced-resolve": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-4.1.0.tgz",
@ -8503,6 +8401,12 @@
}
}
},
"base64id": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/base64id/-/base64id-1.0.0.tgz",
"integrity": "sha1-R2iMuZu2gE8OBtPnY7HDLlfY5rY=",
"dev": true
},
"binary-extensions": {
"version": "1.13.1",
"resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.13.1.tgz",
@ -8547,12 +8451,73 @@
"upath": "^1.1.1"
}
},
"component-emitter": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz",
"integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=",
"dev": true
},
"core-js": {
"version": "2.6.11",
"resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.11.tgz",
"integrity": "sha512-5wjnpaT/3dV+XB4borEsnAYQchn00XSgTAWKDkEqv+K8KevjbzmofK6hfJ9TZIlpj2N0xQpazy7PiRQiWHqzWg==",
"dev": true
},
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
},
"engine.io": {
"version": "3.2.1",
"resolved": "https://registry.npmjs.org/engine.io/-/engine.io-3.2.1.tgz",
"integrity": "sha512-+VlKzHzMhaU+GsCIg4AoXF1UdDFjHHwMmMKqMJNDNLlUlejz58FCy4LBqB2YVJskHGYl06BatYWKP2TVdVXE5w==",
"dev": true,
"requires": {
"accepts": "~1.3.4",
"base64id": "1.0.0",
"cookie": "0.3.1",
"debug": "~3.1.0",
"engine.io-parser": "~2.1.0",
"ws": "~3.3.1"
}
},
"engine.io-client": {
"version": "3.2.1",
"resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-3.2.1.tgz",
"integrity": "sha512-y5AbkytWeM4jQr7m/koQLc5AxpRKC1hEVUb/s1FUAWEJq5AzJJ4NLvzuKPuxtDi5Mq755WuDvZ6Iv2rXj4PTzw==",
"dev": true,
"requires": {
"component-emitter": "1.2.1",
"component-inherit": "0.0.3",
"debug": "~3.1.0",
"engine.io-parser": "~2.1.1",
"has-cors": "1.1.0",
"indexof": "0.0.1",
"parseqs": "0.0.5",
"parseuri": "0.0.5",
"ws": "~3.3.1",
"xmlhttprequest-ssl": "~1.5.4",
"yeast": "0.1.2"
}
},
"engine.io-parser": {
"version": "2.1.3",
"resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-2.1.3.tgz",
"integrity": "sha512-6HXPre2O4Houl7c4g7Ic/XzPnHBvaEmN90vtRO9uLmwtRqQmTOw0QMevL1TOfL2Cpu1VzsaTmMotQgMdkzGkVA==",
"dev": true,
"requires": {
"after": "0.8.2",
"arraybuffer.slice": "~0.0.7",
"base64-arraybuffer": "0.1.5",
"blob": "0.0.5",
"has-binary2": "~1.0.2"
}
},
"extend-shallow": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz",
@ -9150,6 +9115,12 @@
"kind-of": "^3.0.2"
}
},
"isarray": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.1.tgz",
"integrity": "sha1-o32U7ZzaLVmGXJ92/llu4fM4dB4=",
"dev": true
},
"kind-of": {
"version": "3.2.2",
"resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz",
@ -9176,6 +9147,53 @@
"readable-stream": "^2.0.2"
}
},
"socket.io": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/socket.io/-/socket.io-2.1.1.tgz",
"integrity": "sha512-rORqq9c+7W0DAK3cleWNSyfv/qKXV99hV4tZe+gGLfBECw3XEhBy7x85F3wypA9688LKjtwO9pX9L33/xQI8yA==",
"dev": true,
"requires": {
"debug": "~3.1.0",
"engine.io": "~3.2.0",
"has-binary2": "~1.0.2",
"socket.io-adapter": "~1.1.0",
"socket.io-client": "2.1.1",
"socket.io-parser": "~3.2.0"
}
},
"socket.io-client": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-2.1.1.tgz",
"integrity": "sha512-jxnFyhAuFxYfjqIgduQlhzqTcOEQSn+OHKVfAxWaNWa7ecP7xSNk2Dx/3UEsDcY7NcFafxvNvKPmmO7HTwTxGQ==",
"dev": true,
"requires": {
"backo2": "1.0.2",
"base64-arraybuffer": "0.1.5",
"component-bind": "1.0.0",
"component-emitter": "1.2.1",
"debug": "~3.1.0",
"engine.io-client": "~3.2.0",
"has-binary2": "~1.0.2",
"has-cors": "1.1.0",
"indexof": "0.0.1",
"object-component": "0.0.3",
"parseqs": "0.0.5",
"parseuri": "0.0.5",
"socket.io-parser": "~3.2.0",
"to-array": "0.1.4"
}
},
"socket.io-parser": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.2.0.tgz",
"integrity": "sha512-FYiBx7rc/KORMJlgsXysflWx/RIvtqZbyGLlHZvjfmPTPeuD/I8MaW7cfFrj5tRltICJdgwflhfZ3NVVbVLFQA==",
"dev": true,
"requires": {
"component-emitter": "1.2.1",
"debug": "~3.1.0",
"isarray": "2.0.1"
}
},
"source-map": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
@ -9191,6 +9209,17 @@
"is-number": "^3.0.0",
"repeat-string": "^1.6.1"
}
},
"ws": {
"version": "3.3.3",
"resolved": "https://registry.npmjs.org/ws/-/ws-3.3.3.tgz",
"integrity": "sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==",
"dev": true,
"requires": {
"async-limiter": "~1.0.0",
"safe-buffer": "~5.1.0",
"ultron": "~1.1.0"
}
}
}
},
@ -12634,110 +12663,12 @@
}
}
},
"socket.io": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/socket.io/-/socket.io-2.1.1.tgz",
"integrity": "sha512-rORqq9c+7W0DAK3cleWNSyfv/qKXV99hV4tZe+gGLfBECw3XEhBy7x85F3wypA9688LKjtwO9pX9L33/xQI8yA==",
"dev": true,
"requires": {
"debug": "~3.1.0",
"engine.io": "~3.2.0",
"has-binary2": "~1.0.2",
"socket.io-adapter": "~1.1.0",
"socket.io-client": "2.1.1",
"socket.io-parser": "~3.2.0"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
}
},
"socket.io-adapter": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/socket.io-adapter/-/socket.io-adapter-1.1.2.tgz",
"integrity": "sha512-WzZRUj1kUjrTIrUKpZLEzFZ1OLj5FwLlAFQs9kuZJzJi5DKdU7FsWc36SNmA8iDOtwBQyT8FkrriRM8vXLYz8g==",
"dev": true
},
"socket.io-client": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-2.1.1.tgz",
"integrity": "sha512-jxnFyhAuFxYfjqIgduQlhzqTcOEQSn+OHKVfAxWaNWa7ecP7xSNk2Dx/3UEsDcY7NcFafxvNvKPmmO7HTwTxGQ==",
"dev": true,
"requires": {
"backo2": "1.0.2",
"base64-arraybuffer": "0.1.5",
"component-bind": "1.0.0",
"component-emitter": "1.2.1",
"debug": "~3.1.0",
"engine.io-client": "~3.2.0",
"has-binary2": "~1.0.2",
"has-cors": "1.1.0",
"indexof": "0.0.1",
"object-component": "0.0.3",
"parseqs": "0.0.5",
"parseuri": "0.0.5",
"socket.io-parser": "~3.2.0",
"to-array": "0.1.4"
},
"dependencies": {
"component-emitter": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz",
"integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=",
"dev": true
},
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
}
},
"socket.io-parser": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.2.0.tgz",
"integrity": "sha512-FYiBx7rc/KORMJlgsXysflWx/RIvtqZbyGLlHZvjfmPTPeuD/I8MaW7cfFrj5tRltICJdgwflhfZ3NVVbVLFQA==",
"dev": true,
"requires": {
"component-emitter": "1.2.1",
"debug": "~3.1.0",
"isarray": "2.0.1"
},
"dependencies": {
"component-emitter": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz",
"integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=",
"dev": true
},
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
},
"isarray": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.1.tgz",
"integrity": "sha1-o32U7ZzaLVmGXJ92/llu4fM4dB4=",
"dev": true
}
}
},
"sockjs": {
"version": "0.3.19",
"resolved": "https://registry.npmjs.org/sockjs/-/sockjs-0.3.19.tgz",

@ -1,6 +1,6 @@
{
"name": "rtl",
"version": "0.6.7-beta",
"version": "0.6.8-beta",
"license": "MIT",
"scripts": {
"ng": "ng",

@ -0,0 +1,9 @@
const MessagesController = require("../../controllers/c-lightning/message");
const express = require("express");
const router = express.Router();
const authCheck = require("../authCheck");
router.post("/sign", authCheck, MessagesController.signMessage);
router.post("/verify", authCheck, MessagesController.verifyMessage);
module.exports = router;

@ -35,7 +35,7 @@ const onListening = () => {
};
const server = http.createServer(app);
server.on("error", onError);
server.on("listening", onListening);
server.listen(common.port);

@ -78,7 +78,7 @@ export class AppComponent implements OnInit, AfterViewInit, OnDestroy {
this.settings = this.selNode.settings;
this.appConfig = rtlStore.appConfig;
this.information = rtlStore.nodeData;
this.flgLoading[0] = (undefined !== this.information.identity_pubkey) ? false : true;
this.flgLoading[0] = ( this.information.identity_pubkey) ? false : true;
this.logger.info(this.settings);
if (!this.sessionService.getItem('token')) {
this.flgLoading[0] = false;
@ -102,6 +102,8 @@ export class AppComponent implements OnInit, AfterViewInit, OnDestroy {
this.userIdle.onTimeout().pipe(takeUntil(this.unSubs[3])).subscribe(() => {
if (this.sessionService.getItem('token')) {
this.logger.warn('Time limit exceeded for session inactivity.');
this.store.dispatch(new RTLActions.CloseAlert());
this.store.dispatch(new RTLActions.CloseConfirmation(false));
this.store.dispatch(new RTLActions.OpenAlert({ data: {
type: AlertTypeEnum.WARNING,
alertTitle: 'Logging out',

@ -7,6 +7,7 @@ import { StoreModule } from '@ngrx/store';
import { EffectsModule } from '@ngrx/effects';
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
import { MatDialogModule, MAT_DIALOG_DEFAULT_OPTIONS } from '@angular/material';
import { UserIdleModule } from 'angular-user-idle';
import { OverlayContainer } from '@angular/cdk/overlay';
import { routing } from './app.routing';
@ -27,6 +28,18 @@ import { RTLEffects } from './store/rtl.effects';
import { LNDEffects } from './lnd/store/lnd.effects';
import { CLEffects } from './clightning/store/cl.effects';
import { LayoutModule } from '@angular/cdk/layout';
import { CLOpenChannelComponent } from './clightning/peers-channels/channels/open-channel-modal/open-channel.component';
import { CLInvoiceInformationComponent } from './clightning/transactions/invoice-information-modal/invoice-information.component';
import { InvoiceInformationComponent } from './lnd/transactions/invoice-information-modal/invoice-information.component';
import { ChannelRebalanceComponent } from './lnd/peers-channels/channels/channel-rebalance-modal/channel-rebalance.component';
import { CloseChannelComponent } from './lnd/peers-channels/channels/close-channel-modal/close-channel.component';
import { OpenChannelComponent } from './lnd/peers-channels/channels/open-channel-modal/open-channel.component';
import { ShowPubkeyComponent } from './shared/components/data-modal/show-pubkey/show-pubkey.component';
import { OnChainGeneratedAddressComponent } from './shared/components/data-modal/on-chain-generated-address/on-chain-generated-address.component';
import { SpinnerDialogComponent } from './shared/components/data-modal/spinner-dialog/spinner-dialog.component';
import { AlertMessageComponent } from './shared/components/data-modal/alert-message/alert-message.component';
import { ConfirmationMessageComponent } from './shared/components/data-modal/confirmation-message/confirmation-message.component';
import { ErrorMessageComponent } from './shared/components/data-modal/error-message/error-message.component';
@NgModule({
imports: [
@ -38,15 +51,44 @@ import { LayoutModule } from '@angular/cdk/layout';
StoreModule.forRoot(RTLReducer),
EffectsModule.forRoot([RTLEffects, LNDEffects, CLEffects]),
!environment.production ? StoreDevtoolsModule.instrument() : [],
LayoutModule
LayoutModule,
MatDialogModule
],
declarations: [
AppComponent
AppComponent,
CLInvoiceInformationComponent,
InvoiceInformationComponent,
ChannelRebalanceComponent,
OnChainGeneratedAddressComponent,
CLOpenChannelComponent,
OpenChannelComponent,
ShowPubkeyComponent,
SpinnerDialogComponent,
AlertMessageComponent,
ConfirmationMessageComponent,
ErrorMessageComponent,
CloseChannelComponent
],
entryComponents: [
CLInvoiceInformationComponent,
InvoiceInformationComponent,
ChannelRebalanceComponent,
OnChainGeneratedAddressComponent,
CLOpenChannelComponent,
OpenChannelComponent,
ShowPubkeyComponent,
SpinnerDialogComponent,
AlertMessageComponent,
ConfirmationMessageComponent,
ErrorMessageComponent,
CloseChannelComponent
],
providers: [
{ provide: LoggerService, useClass: ConsoleLoggerService },
{ provide: OverlayContainer, useClass: ThemeOverlay },
{ provide: HTTP_INTERCEPTORS, useClass: AuthInterceptor, multi: true },
{ provide: HTTP_INTERCEPTORS, useClass: AuthInterceptor, multi: true },
{ provide: HTTP_INTERCEPTORS, useClass: AuthInterceptor, multi: true },
{ provide: MAT_DIALOG_DEFAULT_OPTIONS, useValue: { hasBackdrop: true, autoFocus: true, disableClose: true, role: 'dialog', width: '55%' } },
CommonService, AuthGuard, SessionService, DataService
],
bootstrap: [AppComponent]

@ -33,6 +33,9 @@ import { CLChannelCapacityInfoComponent } from './home/channel-capacity-info/cha
import { CLChannelLiquidityInfoComponent } from './home/channel-liquidity-info/channel-liquidity-info.component';
import { CLNetworkInfoComponent } from './network-info/network-info.component';
import { CLFeeRatesComponent } from './network-info/fee-rates/fee-rates.component';
import { CLSignVerifyMessageComponent } from './sign-verify-message/sign-verify-message.component';
import { CLSignComponent } from './sign-verify-message/sign/sign.component';
import { CLVerifyComponent } from './sign-verify-message/verify/verify.component';
import { CLUnlockedGuard } from '../shared/services/auth.guard';
@ -71,7 +74,10 @@ import { CLUnlockedGuard } from '../shared/services/auth.guard';
CLChannelCapacityInfoComponent,
CLChannelLiquidityInfoComponent,
CLNetworkInfoComponent,
CLFeeRatesComponent
CLFeeRatesComponent,
CLSignVerifyMessageComponent,
CLSignComponent,
CLVerifyComponent
],
providers: [
CLUnlockedGuard

@ -9,6 +9,7 @@ import { CLTransactionsComponent } from '../clightning/transactions/transactions
import { CLRoutingComponent } from '../clightning/routing/routing.component';
import { CLLookupsComponent } from './lookups/lookups.component';
import { CLNetworkInfoComponent } from './network-info/network-info.component';
import { CLSignVerifyMessageComponent } from './sign-verify-message/sign-verify-message.component';
import { CLUnlockedGuard } from '../shared/services/auth.guard';
import { NotFoundComponent } from '../shared/components/not-found/not-found.component';
@ -22,6 +23,7 @@ export const ClRoutes: Routes = [
{ path: 'routing', component: CLRoutingComponent, canActivate: [CLUnlockedGuard] },
{ path: 'lookups', component: CLLookupsComponent, canActivate: [CLUnlockedGuard] },
{ path: 'rates', component: CLNetworkInfoComponent, canActivate: [CLUnlockedGuard] },
{ path: 'signverify', component: CLSignVerifyMessageComponent, canActivate: [CLUnlockedGuard] },
{ path: '**', component: NotFoundComponent },
{ path: 'network', redirectTo: 'rates' },
{ path: 'wallet', redirectTo: 'home' },

@ -132,7 +132,7 @@ export class CLHomeComponent implements OnInit, OnDestroy {
this.selNode = rtlStore.nodeSettings;
this.information = rtlStore.information;
if (this.flgLoading[0] !== 'error') {
this.flgLoading[0] = (undefined !== this.information.id) ? false : true;
this.flgLoading[0] = ( this.information.id) ? false : true;
}
this.fees = rtlStore.fees;
@ -141,7 +141,7 @@ export class CLHomeComponent implements OnInit, OnDestroy {
this.fees.totalTxCount = rtlStore.forwardingHistory.forwarding_events.filter(event => event.status === 'settled').length
}
if (this.flgLoading[1] !== 'error') {
this.flgLoading[1] = (undefined !== this.fees.feeCollected) ? false : true;
this.flgLoading[1] = ( this.fees.feeCollected) ? false : true;
}
this.totalBalance = rtlStore.balance;
@ -164,7 +164,7 @@ export class CLHomeComponent implements OnInit, OnDestroy {
this.feeRatesPerKB = rtlStore.feeRatesPerKB;
this.feeRatesPerKW = rtlStore.feeRatesPerKW;
if (this.flgLoading[4] !== 'error') {
this.flgLoading[4] = (undefined !== this.feeRatesPerKB && undefined !== this.feeRatesPerKW) ? false : true;
this.flgLoading[4] = ( this.feeRatesPerKB && this.feeRatesPerKW) ? false : true;
}
this.channelsStatus = {

@ -82,7 +82,7 @@ export class CLNetworkInfoComponent implements OnInit, OnDestroy {
this.selNode = rtlStore.nodeSettings;
this.information = rtlStore.information;
if (this.flgLoading[0] !== 'error') {
this.flgLoading[0] = (undefined !== this.information.id) ? false : true;
this.flgLoading[0] = ( this.information.id) ? false : true;
}
this.fees = rtlStore.fees;
@ -91,7 +91,7 @@ export class CLNetworkInfoComponent implements OnInit, OnDestroy {
this.fees.totalTxCount = rtlStore.forwardingHistory.forwarding_events.filter(event => event.status === 'settled').length
}
if (this.flgLoading[1] !== 'error') {
this.flgLoading[1] = (undefined !== this.fees.feeCollected) ? false : true;
this.flgLoading[1] = ( this.fees.feeCollected) ? false : true;
}
this.channelsStatus = {
@ -103,7 +103,7 @@ export class CLNetworkInfoComponent implements OnInit, OnDestroy {
this.feeRatesPerKB = rtlStore.feeRatesPerKB;
this.feeRatesPerKW = rtlStore.feeRatesPerKW;
if (this.flgLoading[2] !== 'error') {
this.flgLoading[2] = (undefined !== this.feeRatesPerKB && undefined !== this.feeRatesPerKW) ? false : true;
this.flgLoading[2] = ( this.feeRatesPerKB && this.feeRatesPerKW) ? false : true;
}
this.logger.info(rtlStore);

@ -103,9 +103,9 @@ export class CLOnChainSendComponent implements OnInit, OnDestroy {
}
get invalidValues(): boolean {
return (undefined === this.transaction.address || this.transaction.address === '')
|| ((undefined === this.transaction.satoshis || this.transaction.satoshis <= 0))
|| (this.flgMinConf && (undefined === this.transaction.minconf || this.transaction.minconf <= 0));
return (!this.transaction.address || this.transaction.address === '')
|| ((!this.transaction.satoshis || this.transaction.satoshis <= 0))
|| (this.flgMinConf && (!this.transaction.minconf || this.transaction.minconf <= 0));
}
resetData() {

@ -53,7 +53,7 @@ export class CLChannelManageComponent implements OnInit, OnDestroy {
this.information = rtlStore.information;
this.peers = rtlStore.peers;
this.peers.forEach(peer => {
if (undefined === peer.alias || peer.alias === '') {
if (!peer.alias || peer.alias === '') {
peer.alias = peer.id.substring(0, 15) + '...';
}
});

@ -63,6 +63,7 @@
<mat-select placeholder="Actions" tabindex="1" class="mr-0">
<mat-select-trigger></mat-select-trigger>
<mat-option (click)="onChannelUpdate('all')">Update Fee Policy</mat-option>
<mat-option (click)="onDownloadCSV()">Download CSV</mat-option>
</mat-select>
</div>
</th>

@ -21,8 +21,5 @@
}
.mat-column-actions {
width: 100%;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
min-height: 4.8rem;
}

@ -117,7 +117,7 @@ export class CLChannelOpenTableComponent implements OnInit, OnDestroy {
type: AlertTypeEnum.CONFIRM,
alertTitle: 'Update Fee Policy',
noBtnText: 'Cancel',
yesBtnText: 'Update All Channels',
yesBtnText: 'Update All',
message: confirmationMsg,
titleMessage: 'Update fee policy for all channels',
flgShowInput: true,
@ -158,7 +158,7 @@ export class CLChannelOpenTableComponent implements OnInit, OnDestroy {
type: AlertTypeEnum.CONFIRM,
alertTitle: 'Update Fee Policy',
noBtnText: 'Cancel',
yesBtnText: 'Update Channel',
yesBtnText: 'Update',
message: confirmationMsg,
titleMessage: titleMsg,
flgShowInput: true,
@ -249,6 +249,12 @@ export class CLChannelOpenTableComponent implements OnInit, OnDestroy {
this.logger.info(this.channels);
}
onDownloadCSV() {
if(this.channels.data && this.channels.data.length > 0) {
this.commonService.downloadCSV(this.channels.data, 'Open-channels');
}
}
ngOnDestroy() {
this.unSubs.forEach(completeSub => {
completeSub.next();

@ -44,7 +44,14 @@
{{channel?.spendable_msatoshi | number}} </span></td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef class="pr-3"><span fxLayoutAlign="end center">Actions</span></th>
<th mat-header-cell *matHeaderCellDef class="pr-3">
<div class="bordered-box table-actions-select">
<mat-select placeholder="Actions" tabindex="1" class="mr-0">
<mat-select-trigger></mat-select-trigger>
<mat-option (click)="onDownloadCSV()">Download CSV</mat-option>
</mat-select>
</div>
</th>
<td mat-cell *matCellDef="let channel"><span fxLayoutAlign="end center">
<button mat-stroked-button color="primary" type="button" tabindex="4" (click)="onChannelClick(channel, $event)">View Info</button>
</span></td>

@ -130,6 +130,12 @@ export class CLChannelPendingTableComponent implements OnInit, OnDestroy {
this.logger.info(this.channels);
}
onDownloadCSV() {
if(this.channels.data && this.channels.data.length > 0) {
this.commonService.downloadCSV(this.channels.data, 'Pending-inactive-channels');
}
}
ngOnDestroy() {
this.unSubs.forEach(completeSub => {
completeSub.next();

@ -2,9 +2,9 @@ import { Component, OnInit, Inject } from '@angular/core';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
import { Store } from '@ngrx/store';
import { PeerCL, GetInfoCL } from '../../../models/clModels';
import { CLOpenChannelAlert } from '../../../models/alertData';
import { FEE_RATE_TYPES } from '../../../services/consts-enums-functions';
import { PeerCL, GetInfoCL } from '../../../../shared/models/clModels';
import { CLOpenChannelAlert } from '../../../../shared/models/alertData';
import { FEE_RATE_TYPES } from '../../../../shared/services/consts-enums-functions';
import * as RTLActions from '../../../../store/rtl.actions';
import * as fromRTLReducer from '../../../../store/rtl.reducers';

@ -26,13 +26,13 @@
<table mat-table #table [dataSource]="peers" matSort [ngClass]="{'overflow-auto error-border': flgLoading[0]==='error','overflow-auto': true}">
<ng-container matColumnDef="id">
<th mat-header-cell *matHeaderCellDef mat-sort-header> ID </th>
<td mat-cell *matCellDef="let peer" [ngStyle]="{'max-width': (screenSize === screenSizeEnum.XS) ? '10rem' : '15rem'}">
<td mat-cell *matCellDef="let peer" [ngStyle]="{'max-width': (screenSize === screenSizeEnum.XS) ? '10rem' : '30rem'}">
{{peer?.id}}
</td>
</ng-container>
<ng-container matColumnDef="alias">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Alias </th>
<td mat-cell *matCellDef="let peer" [ngStyle]="{'max-width': (screenSize === screenSizeEnum.XS) ? '10rem' : '15rem'}"> {{peer?.alias}} </td>
<th mat-header-cell *matHeaderCellDef mat-sort-header class="px-3"> Alias </th>
<td mat-cell *matCellDef="let peer" class="px-3" [ngStyle]="{'max-width': (screenSize === screenSizeEnum.XS) ? '10rem' : '25rem'}"> {{peer?.alias}} </td>
</ng-container>
<ng-container matColumnDef="connected">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Connected </th>
@ -40,7 +40,7 @@
</ng-container>
<ng-container matColumnDef="netaddr">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Network Address </th>
<td mat-cell *matCellDef="let peer">
<td mat-cell *matCellDef="let peer" [ngStyle]="{'max-width': (screenSize === screenSizeEnum.XS) ? '10rem' : '20rem'}">
<span *ngFor="let addr of peer?.netaddr; last as isLast">{{ addr}}<span *ngIf="!isLast">,<br></span></span>
</td>
</ng-container>
@ -53,8 +53,15 @@
<td mat-cell *matCellDef="let peer"> {{peer?.localfeatures}} </td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef class="px-3"><span fxLayoutAlign="end center">Actions</span></th>
<td mat-cell *matCellDef="let peer" fxLayoutAlign="end center" class="pl-3">
<th mat-header-cell *matHeaderCellDef class="px-3">
<div class="bordered-box table-actions-select">
<mat-select placeholder="Actions" tabindex="1" class="mr-0">
<mat-select-trigger></mat-select-trigger>
<mat-option (click)="onDownloadCSV()">Download CSV</mat-option>
</mat-select>
</div>
</th>
<td mat-cell *matCellDef="let peer" fxLayoutAlign="end center" class="px-3">
<div fxFlex="100" class="bordered-box table-actions-select" fxLayoutAlign="center center">
<mat-select placeholder="Actions" tabindex="1" class="mr-0">
<mat-select-trigger></mat-select-trigger>

@ -12,3 +12,12 @@
text-overflow: ellipsis;
padding-left: 2rem;
}
.mat-column-netaddr {
flex: 1 1 15%;
width: 15%;
}
.mat-column-actions {
min-height: 4.8rem;
}

@ -11,7 +11,7 @@ import { PeerCL, GetInfoCL } from '../../../shared/models/clModels';
import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, AlertTypeEnum, ScreenSizeEnum } from '../../../shared/services/consts-enums-functions';
import { LoggerService } from '../../../shared/services/logger.service';
import { CommonService } from '../../../shared/services/common.service';
import { CLOpenChannelComponent } from '../../../shared/components/data-modal/open-channel-cl/open-channel.component';
import { CLOpenChannelComponent } from '../channels/open-channel-modal/open-channel.component';
import { newlyAddedRowAnimation } from '../../../shared/animation/row-animation';
import { CLEffects } from '../../store/cl.effects';
import { RTLEffects } from '../../../store/rtl.effects';
@ -77,7 +77,7 @@ export class CLPeersComponent implements OnInit, OnDestroy {
this.availableBalance = rtlStore.balance.totalBalance || 0;
this.peers = new MatTableDataSource([]);
this.peers.data = [];
if (undefined !== rtlStore.peers) {
if ( rtlStore.peers) {
this.peers = new MatTableDataSource<PeerCL>([...rtlStore.peers]);
this.peers.data = rtlStore.peers;
setTimeout(() => { this.flgAnimate = false; }, 3000);
@ -168,6 +168,12 @@ export class CLPeersComponent implements OnInit, OnDestroy {
this.peers.filter = selFilter;
}
onDownloadCSV() {
if(this.peers.data && this.peers.data.length > 0) {
this.commonService.downloadCSV(this.peers.data, 'Peers');
}
}
ngOnDestroy() {
this.unSubs.forEach(completeSub => {
completeSub.next();

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save