Merge branch 'master' of https://bitbucket.org/sriramv18/sparqsineedge
This commit is contained in:
commit
d602d11346
3
.vscode/settings.json
vendored
3
.vscode/settings.json
vendored
@ -1,3 +1,4 @@
|
||||
{
|
||||
"javascript.implicitProjectConfig.experimentalDecorators": true
|
||||
"javascript.implicitProjectConfig.experimentalDecorators": true,
|
||||
"git.ignoreLimitWarning": true
|
||||
}
|
||||
283
ng6-seed/package-lock.json
generated
283
ng6-seed/package-lock.json
generated
@ -1551,7 +1551,6 @@
|
||||
"version": "1.3.7",
|
||||
"resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz",
|
||||
"integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"mime-types": "~2.1.24",
|
||||
"negotiator": "0.6.2"
|
||||
@ -1590,8 +1589,7 @@
|
||||
"after": {
|
||||
"version": "0.8.2",
|
||||
"resolved": "https://registry.npmjs.org/after/-/after-0.8.2.tgz",
|
||||
"integrity": "sha1-/ts5T58OAqqXaOcCvaI7UF+ufh8=",
|
||||
"dev": true
|
||||
"integrity": "sha1-/ts5T58OAqqXaOcCvaI7UF+ufh8="
|
||||
},
|
||||
"agent-base": {
|
||||
"version": "4.3.0",
|
||||
@ -1938,6 +1936,11 @@
|
||||
"resolved": "https://registry.npmjs.org/async-foreach/-/async-foreach-0.1.3.tgz",
|
||||
"integrity": "sha1-NhIfhFwFeBct5Bmpfb6x0W7DRUI="
|
||||
},
|
||||
"async-limiter": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
|
||||
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ=="
|
||||
},
|
||||
"asynckit": {
|
||||
"version": "0.4.0",
|
||||
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
|
||||
@ -2151,8 +2154,7 @@
|
||||
"backo2": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/backo2/-/backo2-1.0.2.tgz",
|
||||
"integrity": "sha1-MasayLEpNjRj41s+u2n038+6eUc=",
|
||||
"dev": true
|
||||
"integrity": "sha1-MasayLEpNjRj41s+u2n038+6eUc="
|
||||
},
|
||||
"balanced-match": {
|
||||
"version": "1.0.0",
|
||||
@ -2217,8 +2219,7 @@
|
||||
"base64-arraybuffer": {
|
||||
"version": "0.1.5",
|
||||
"resolved": "https://registry.npmjs.org/base64-arraybuffer/-/base64-arraybuffer-0.1.5.tgz",
|
||||
"integrity": "sha1-c5JncZI7Whl0etZmqlzUv5xunOg=",
|
||||
"dev": true
|
||||
"integrity": "sha1-c5JncZI7Whl0etZmqlzUv5xunOg="
|
||||
},
|
||||
"base64-js": {
|
||||
"version": "1.3.1",
|
||||
@ -2249,7 +2250,6 @@
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/better-assert/-/better-assert-1.0.2.tgz",
|
||||
"integrity": "sha1-QIZrnhueC1W0gYlDEeaPr/rrxSI=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"callsite": "1.0.0"
|
||||
}
|
||||
@ -2642,8 +2642,7 @@
|
||||
"callsite": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/callsite/-/callsite-1.0.0.tgz",
|
||||
"integrity": "sha1-KAOY5dZkvXQDi28JBRU+borxvCA=",
|
||||
"dev": true
|
||||
"integrity": "sha1-KAOY5dZkvXQDi28JBRU+borxvCA="
|
||||
},
|
||||
"callsites": {
|
||||
"version": "2.0.0",
|
||||
@ -2975,8 +2974,7 @@
|
||||
"component-bind": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/component-bind/-/component-bind-1.0.0.tgz",
|
||||
"integrity": "sha1-AMYIq33Nk4l8AAllGx06jh5zu9E=",
|
||||
"dev": true
|
||||
"integrity": "sha1-AMYIq33Nk4l8AAllGx06jh5zu9E="
|
||||
},
|
||||
"component-emitter": {
|
||||
"version": "1.3.0",
|
||||
@ -2987,8 +2985,7 @@
|
||||
"component-inherit": {
|
||||
"version": "0.0.3",
|
||||
"resolved": "https://registry.npmjs.org/component-inherit/-/component-inherit-0.0.3.tgz",
|
||||
"integrity": "sha1-ZF/ErfWLcrZJ1crmUTVhnbJv8UM=",
|
||||
"dev": true
|
||||
"integrity": "sha1-ZF/ErfWLcrZJ1crmUTVhnbJv8UM="
|
||||
},
|
||||
"compressible": {
|
||||
"version": "2.0.18",
|
||||
@ -6342,11 +6339,25 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"has-binary2": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "https://registry.npmjs.org/has-binary2/-/has-binary2-1.0.3.tgz",
|
||||
"integrity": "sha512-G1LWKhDSvhGeAQ8mPVQlqNcOB2sJdwATtZKl2pDKKHfpf/rYj24lkinxf69blJbnsvtqqNU+L3SL50vzZhXOnw==",
|
||||
"requires": {
|
||||
"isarray": "2.0.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"isarray": {
|
||||
"version": "2.0.1",
|
||||
"resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.1.tgz",
|
||||
"integrity": "sha1-o32U7ZzaLVmGXJ92/llu4fM4dB4="
|
||||
}
|
||||
}
|
||||
},
|
||||
"has-cors": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npmjs.org/has-cors/-/has-cors-1.1.0.tgz",
|
||||
"integrity": "sha1-XkdHk/fqmEPRu5nCPu9J/xJv/zk=",
|
||||
"dev": true
|
||||
"integrity": "sha1-XkdHk/fqmEPRu5nCPu9J/xJv/zk="
|
||||
},
|
||||
"has-flag": {
|
||||
"version": "3.0.0",
|
||||
@ -6758,8 +6769,7 @@
|
||||
"indexof": {
|
||||
"version": "0.0.1",
|
||||
"resolved": "https://registry.npmjs.org/indexof/-/indexof-0.0.1.tgz",
|
||||
"integrity": "sha1-gtwzbSMrkGIXnQWrMpOmYFn9Q10=",
|
||||
"dev": true
|
||||
"integrity": "sha1-gtwzbSMrkGIXnQWrMpOmYFn9Q10="
|
||||
},
|
||||
"inflight": {
|
||||
"version": "1.0.6",
|
||||
@ -8197,6 +8207,14 @@
|
||||
"tslib": "^1.9.0"
|
||||
}
|
||||
},
|
||||
"mat-video": {
|
||||
"version": "2.7.2",
|
||||
"resolved": "https://registry.npmjs.org/mat-video/-/mat-video-2.7.2.tgz",
|
||||
"integrity": "sha512-rwZt9+gxhyQeUYkWq+7JPwYdMEDMI4iT9mIdhO00TDnihbdv20WHiMZ4yYLudzFnuJIeXzgDrA9yltGWjG3vMw==",
|
||||
"requires": {
|
||||
"tslib": "^1.9.0"
|
||||
}
|
||||
},
|
||||
"math-random": {
|
||||
"version": "1.0.4",
|
||||
"resolved": "https://registry.npmjs.org/math-random/-/math-random-1.0.4.tgz",
|
||||
@ -8552,8 +8570,7 @@
|
||||
"negotiator": {
|
||||
"version": "0.6.2",
|
||||
"resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz",
|
||||
"integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==",
|
||||
"dev": true
|
||||
"integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw=="
|
||||
},
|
||||
"neo-async": {
|
||||
"version": "2.6.1",
|
||||
@ -8651,6 +8668,213 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"ngx-socket-io": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/ngx-socket-io/-/ngx-socket-io-3.0.1.tgz",
|
||||
"integrity": "sha512-6+99AULDEcdrsFSd9FVo5mUSpQMa2KL6twPbteoEv3qWO0Hh2kdrzTjvPdsC2jeTuEuqa8R9l5/3eGYdiLZyWQ==",
|
||||
"requires": {
|
||||
"core-js": "^3.0.0",
|
||||
"reflect-metadata": "^0.1.10",
|
||||
"socket.io": "^2.2.0",
|
||||
"socket.io-client": "^2.2.0",
|
||||
"tslib": "^1.9.0",
|
||||
"zone.js": "^0.10.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"arraybuffer.slice": {
|
||||
"version": "0.0.7",
|
||||
"resolved": "https://registry.npmjs.org/arraybuffer.slice/-/arraybuffer.slice-0.0.7.tgz",
|
||||
"integrity": "sha512-wGUIVQXuehL5TCqQun8OW81jGzAWycqzFF8lFp+GOM5BXLYj3bKNsYC4daB7n6XjCqxQA/qgTJ+8ANR3acjrog=="
|
||||
},
|
||||
"base64id": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/base64id/-/base64id-2.0.0.tgz",
|
||||
"integrity": "sha512-lGe34o6EHj9y3Kts9R4ZYs/Gr+6N7MCaMlIFA3F1R2O5/m7K06AxfSeO5530PEERE6/WyEg3lsuyw4GHlPZHog=="
|
||||
},
|
||||
"blob": {
|
||||
"version": "0.0.5",
|
||||
"resolved": "https://registry.npmjs.org/blob/-/blob-0.0.5.tgz",
|
||||
"integrity": "sha512-gaqbzQPqOoamawKg0LGVd7SzLgXS+JH61oWprSLH+P+abTczqJbhTR8CmJ2u9/bUYNmHTGJx/UEmn6doAvvuig=="
|
||||
},
|
||||
"component-emitter": {
|
||||
"version": "1.2.1",
|
||||
"resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz",
|
||||
"integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY="
|
||||
},
|
||||
"cookie": {
|
||||
"version": "0.3.1",
|
||||
"resolved": "https://registry.npmjs.org/cookie/-/cookie-0.3.1.tgz",
|
||||
"integrity": "sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s="
|
||||
},
|
||||
"core-js": {
|
||||
"version": "3.6.5",
|
||||
"resolved": "https://registry.npmjs.org/core-js/-/core-js-3.6.5.tgz",
|
||||
"integrity": "sha512-vZVEEwZoIsI+vPEuoF9Iqf5H7/M3eeQqWlQnYa8FSKKePuYTf5MWnxb5SDAzCa60b3JBRS5g9b+Dq7b1y/RCrA=="
|
||||
},
|
||||
"debug": {
|
||||
"version": "4.1.1",
|
||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
|
||||
"integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
|
||||
"requires": {
|
||||
"ms": "^2.1.1"
|
||||
}
|
||||
},
|
||||
"engine.io": {
|
||||
"version": "3.4.1",
|
||||
"resolved": "https://registry.npmjs.org/engine.io/-/engine.io-3.4.1.tgz",
|
||||
"integrity": "sha512-8MfIfF1/IIfxuc2gv5K+XlFZczw/BpTvqBdl0E2fBLkYQp4miv4LuDTVtYt4yMyaIFLEr4vtaSgV4mjvll8Crw==",
|
||||
"requires": {
|
||||
"accepts": "~1.3.4",
|
||||
"base64id": "2.0.0",
|
||||
"cookie": "0.3.1",
|
||||
"debug": "~4.1.0",
|
||||
"engine.io-parser": "~2.2.0",
|
||||
"ws": "^7.1.2"
|
||||
}
|
||||
},
|
||||
"engine.io-client": {
|
||||
"version": "3.4.1",
|
||||
"resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-3.4.1.tgz",
|
||||
"integrity": "sha512-RJNmA+A9Js+8Aoq815xpGAsgWH1VoSYM//2VgIiu9lNOaHFfLpTjH4tOzktBpjIs5lvOfiNY1dwf+NuU6D38Mw==",
|
||||
"requires": {
|
||||
"component-emitter": "1.2.1",
|
||||
"component-inherit": "0.0.3",
|
||||
"debug": "~4.1.0",
|
||||
"engine.io-parser": "~2.2.0",
|
||||
"has-cors": "1.1.0",
|
||||
"indexof": "0.0.1",
|
||||
"parseqs": "0.0.5",
|
||||
"parseuri": "0.0.5",
|
||||
"ws": "~6.1.0",
|
||||
"xmlhttprequest-ssl": "~1.5.4",
|
||||
"yeast": "0.1.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"ws": {
|
||||
"version": "6.1.4",
|
||||
"resolved": "https://registry.npmjs.org/ws/-/ws-6.1.4.tgz",
|
||||
"integrity": "sha512-eqZfL+NE/YQc1/ZynhojeV8q+H050oR8AZ2uIev7RU10svA9ZnJUddHcOUZTJLinZ9yEfdA2kSATS2qZK5fhJA==",
|
||||
"requires": {
|
||||
"async-limiter": "~1.0.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"engine.io-parser": {
|
||||
"version": "2.2.0",
|
||||
"resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-2.2.0.tgz",
|
||||
"integrity": "sha512-6I3qD9iUxotsC5HEMuuGsKA0cXerGz+4uGcXQEkfBidgKf0amsjrrtwcbwK/nzpZBxclXlV7gGl9dgWvu4LF6w==",
|
||||
"requires": {
|
||||
"after": "0.8.2",
|
||||
"arraybuffer.slice": "~0.0.7",
|
||||
"base64-arraybuffer": "0.1.5",
|
||||
"blob": "0.0.5",
|
||||
"has-binary2": "~1.0.2"
|
||||
}
|
||||
},
|
||||
"isarray": {
|
||||
"version": "2.0.1",
|
||||
"resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.1.tgz",
|
||||
"integrity": "sha1-o32U7ZzaLVmGXJ92/llu4fM4dB4="
|
||||
},
|
||||
"ms": {
|
||||
"version": "2.1.2",
|
||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
|
||||
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
|
||||
},
|
||||
"socket.io": {
|
||||
"version": "2.3.0",
|
||||
"resolved": "https://registry.npmjs.org/socket.io/-/socket.io-2.3.0.tgz",
|
||||
"integrity": "sha512-2A892lrj0GcgR/9Qk81EaY2gYhCBxurV0PfmmESO6p27QPrUK1J3zdns+5QPqvUYK2q657nSj0guoIil9+7eFg==",
|
||||
"requires": {
|
||||
"debug": "~4.1.0",
|
||||
"engine.io": "~3.4.0",
|
||||
"has-binary2": "~1.0.2",
|
||||
"socket.io-adapter": "~1.1.0",
|
||||
"socket.io-client": "2.3.0",
|
||||
"socket.io-parser": "~3.4.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=="
|
||||
},
|
||||
"socket.io-client": {
|
||||
"version": "2.3.0",
|
||||
"resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-2.3.0.tgz",
|
||||
"integrity": "sha512-cEQQf24gET3rfhxZ2jJ5xzAOo/xhZwK+mOqtGRg5IowZsMgwvHwnf/mCRapAAkadhM26y+iydgwsXGObBB5ZdA==",
|
||||
"requires": {
|
||||
"backo2": "1.0.2",
|
||||
"base64-arraybuffer": "0.1.5",
|
||||
"component-bind": "1.0.0",
|
||||
"component-emitter": "1.2.1",
|
||||
"debug": "~4.1.0",
|
||||
"engine.io-client": "~3.4.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.3.0",
|
||||
"to-array": "0.1.4"
|
||||
},
|
||||
"dependencies": {
|
||||
"ms": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
|
||||
"integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
|
||||
},
|
||||
"socket.io-parser": {
|
||||
"version": "3.3.0",
|
||||
"resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.3.0.tgz",
|
||||
"integrity": "sha512-hczmV6bDgdaEbVqhAeVMM/jfUfzuEZHsQg6eOmLgJht6G3mPKMxYm75w2+qhAQZ+4X+1+ATZ+QFKeOZD5riHng==",
|
||||
"requires": {
|
||||
"component-emitter": "1.2.1",
|
||||
"debug": "~3.1.0",
|
||||
"isarray": "2.0.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"debug": {
|
||||
"version": "3.1.0",
|
||||
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
|
||||
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
|
||||
"requires": {
|
||||
"ms": "2.0.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"socket.io-parser": {
|
||||
"version": "3.4.0",
|
||||
"resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.4.0.tgz",
|
||||
"integrity": "sha512-/G/VOI+3DBp0+DJKW4KesGnQkQPFmUCbA/oO2QGT6CWxU7hLGWqU3tyuzeSK/dqcyeHsQg1vTe9jiZI8GU9SCQ==",
|
||||
"requires": {
|
||||
"component-emitter": "1.2.1",
|
||||
"debug": "~4.1.0",
|
||||
"isarray": "2.0.1"
|
||||
}
|
||||
},
|
||||
"ws": {
|
||||
"version": "7.2.5",
|
||||
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.5.tgz",
|
||||
"integrity": "sha512-C34cIU4+DB2vMyAbmEKossWq2ZQDr6QEyuuCzWrM9zfw1sGc0mYiJ0UnG9zzNykt49C2Fi34hvr2vssFQRS6EA=="
|
||||
},
|
||||
"xmlhttprequest-ssl": {
|
||||
"version": "1.5.5",
|
||||
"resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-1.5.5.tgz",
|
||||
"integrity": "sha1-wodrBhaKrcQOV9l+gRkayPQ5iz4="
|
||||
},
|
||||
"zone.js": {
|
||||
"version": "0.10.3",
|
||||
"resolved": "https://registry.npmjs.org/zone.js/-/zone.js-0.10.3.tgz",
|
||||
"integrity": "sha512-LXVLVEq0NNOqK/fLJo3d0kfzd4sxwn2/h67/02pjCjfKDxgx1i9QqpvtHD8CrBnSSwMw5+dy11O7FRX5mkO7Cg=="
|
||||
}
|
||||
}
|
||||
},
|
||||
"ngx-viewer": {
|
||||
"version": "1.0.5",
|
||||
"resolved": "https://registry.npmjs.org/ngx-viewer/-/ngx-viewer-1.0.5.tgz",
|
||||
@ -9011,8 +9235,7 @@
|
||||
"object-component": {
|
||||
"version": "0.0.3",
|
||||
"resolved": "https://registry.npmjs.org/object-component/-/object-component-0.0.3.tgz",
|
||||
"integrity": "sha1-8MaapQ78lbhmwYb0AKM3acsvEpE=",
|
||||
"dev": true
|
||||
"integrity": "sha1-8MaapQ78lbhmwYb0AKM3acsvEpE="
|
||||
},
|
||||
"object-copy": {
|
||||
"version": "0.1.0",
|
||||
@ -9522,7 +9745,6 @@
|
||||
"version": "0.0.5",
|
||||
"resolved": "https://registry.npmjs.org/parseqs/-/parseqs-0.0.5.tgz",
|
||||
"integrity": "sha1-1SCKNzjkZ2bikbouoXNoSSGouJ0=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"better-assert": "~1.0.0"
|
||||
}
|
||||
@ -9531,7 +9753,6 @@
|
||||
"version": "0.0.5",
|
||||
"resolved": "https://registry.npmjs.org/parseuri/-/parseuri-0.0.5.tgz",
|
||||
"integrity": "sha1-gCBKUNTbt3m/3G6+J3jZDkvOMgo=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"better-assert": "~1.0.0"
|
||||
}
|
||||
@ -10253,6 +10474,11 @@
|
||||
"readable-stream": "^2.0.2"
|
||||
}
|
||||
},
|
||||
"recordrtc": {
|
||||
"version": "5.5.9",
|
||||
"resolved": "https://registry.npmjs.org/recordrtc/-/recordrtc-5.5.9.tgz",
|
||||
"integrity": "sha512-6T1tn80nRfsXrAoYWINwz+hBKk+pB5Im4I0BS52Og1ruQvrEdV3IUcm+AKwLMHNyBAhJ2DaVa+9pukTRxMF/uA=="
|
||||
},
|
||||
"redent": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/redent/-/redent-1.0.0.tgz",
|
||||
@ -10265,8 +10491,7 @@
|
||||
"reflect-metadata": {
|
||||
"version": "0.1.13",
|
||||
"resolved": "https://registry.npmjs.org/reflect-metadata/-/reflect-metadata-0.1.13.tgz",
|
||||
"integrity": "sha512-Ts1Y/anZELhSsjMcU605fU9RE4Oi3p5ORujwbIKXfWa+0Zxs510Qrmrce5/Jowq3cHSZSJqBjypxmHarc+vEWg==",
|
||||
"dev": true
|
||||
"integrity": "sha512-Ts1Y/anZELhSsjMcU605fU9RE4Oi3p5ORujwbIKXfWa+0Zxs510Qrmrce5/Jowq3cHSZSJqBjypxmHarc+vEWg=="
|
||||
},
|
||||
"regenerate": {
|
||||
"version": "1.4.0",
|
||||
@ -12071,8 +12296,7 @@
|
||||
"to-array": {
|
||||
"version": "0.1.4",
|
||||
"resolved": "https://registry.npmjs.org/to-array/-/to-array-0.1.4.tgz",
|
||||
"integrity": "sha1-F+bBH3PdTz10zaek/zI46a2b+JA=",
|
||||
"dev": true
|
||||
"integrity": "sha1-F+bBH3PdTz10zaek/zI46a2b+JA="
|
||||
},
|
||||
"to-arraybuffer": {
|
||||
"version": "1.0.1",
|
||||
@ -13311,8 +13535,7 @@
|
||||
"yeast": {
|
||||
"version": "0.1.2",
|
||||
"resolved": "https://registry.npmjs.org/yeast/-/yeast-0.1.2.tgz",
|
||||
"integrity": "sha1-AI4G2AlDIMNy28L47XagymyKxBk=",
|
||||
"dev": true
|
||||
"integrity": "sha1-AI4G2AlDIMNy28L47XagymyKxBk="
|
||||
},
|
||||
"yn": {
|
||||
"version": "2.0.0",
|
||||
|
||||
@ -54,6 +54,7 @@
|
||||
"karma-jasmine": "^1.1.1",
|
||||
"leaflet": "^1.6.0",
|
||||
"mat-table-exporter": "^1.2.5",
|
||||
"mat-video": "^2.7.2",
|
||||
"moment": "^2.24.0",
|
||||
"ng-pick-datetime": "^6.0.16",
|
||||
"ng2-charts": "1.6.0",
|
||||
@ -67,10 +68,12 @@
|
||||
"ngx-mat-daterange-picker": "^1.1.4",
|
||||
"ngx-mat-select-search": "^1.8.0",
|
||||
"ngx-perfect-scrollbar": "5.0.0-7",
|
||||
"ngx-socket-io": "^3.0.1",
|
||||
"ngx-viewer": "^1.0.5",
|
||||
"node-sass": "^4.13.0",
|
||||
"perfect-scrollbar": "^1.3.0",
|
||||
"quill": "^1.3.7",
|
||||
"recordrtc": "^5.5.9",
|
||||
"rxjs": "^6.5.4",
|
||||
"rxjs-compat": "^6.5.4",
|
||||
"screenfull": "^3.2.2",
|
||||
|
||||
7
ng6-seed/proxy.conf.json
Normal file
7
ng6-seed/proxy.conf.json
Normal file
@ -0,0 +1,7 @@
|
||||
{
|
||||
"/api/": {
|
||||
"target": "http://localhost/",
|
||||
"secure": false,
|
||||
"changeOrigin": true
|
||||
}
|
||||
}
|
||||
@ -34,7 +34,7 @@ import {MatSelectModule} from '@angular/material/select';
|
||||
import {MatCardModule} from '@angular/material/card';
|
||||
import {MatBadgeModule} from '@angular/material/badge';
|
||||
import {ChangePasswordDialog} from './settings/users/user-profile/user-profile.component';
|
||||
import { MatFormFieldModule,MatProgressSpinnerModule } from '@angular/material';
|
||||
import { MatFormFieldModule,MatProgressSpinnerModule, MatDialogModule, MatTooltipModule, MatButtonModule } from '@angular/material';
|
||||
import { AppRoutes } from './app.routing';
|
||||
import { AppComponent } from './app.component';
|
||||
import { AdminLayoutComponent } from './layouts/admin/admin-layout.component';
|
||||
@ -58,7 +58,12 @@ import { AsyncPipe } from '../../node_modules/@angular/common';
|
||||
import { PdTrigerService } from './personal-discussion/pd-service/pd-triger.service';
|
||||
import { HttpLoaderComponent } from './layouts/http-loader/http-loader.component';
|
||||
import { LoaderService } from './shared/loaderService/loader.service';
|
||||
|
||||
import {SocketIoConfig, SocketIoModule} from 'ngx-socket-io';
|
||||
import { IncomingCallComponent } from './video-chat/incoming-call/incoming-call.component';
|
||||
import { VideoChatComponent } from './video-chat/video-chat.component'
|
||||
import { PushNotifyService } from './shared/push-notify.service';
|
||||
import { MatVideoModule } from 'mat-video';
|
||||
import { VideoPlayerComponent } from './video-chat/video-player/video-player.component';
|
||||
|
||||
export function HttpLoaderFactory(http: HttpClient) {
|
||||
return new TranslateHttpLoader(http);
|
||||
@ -72,14 +77,17 @@ const DEFAULT_PERFECT_SCROLLBAR_CONFIG: PerfectScrollbarConfigInterface = {
|
||||
suppressScrollX: true
|
||||
};
|
||||
|
||||
const socketConfig: SocketIoConfig = { url: environment.socketServerUrl, options: {} };
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
AppComponent,
|
||||
AdminLayoutComponent,
|
||||
AuthLayoutComponent,
|
||||
NewPasswordDialog,ForgotPass,ChangePasswordDialog, RoleMenuItemsPipe, HttpLoaderComponent
|
||||
NewPasswordDialog,ForgotPass,ChangePasswordDialog, RoleMenuItemsPipe, HttpLoaderComponent, IncomingCallComponent, VideoChatComponent, VideoPlayerComponent
|
||||
],
|
||||
imports: [
|
||||
MatDialogModule,
|
||||
BrowserModule,
|
||||
BrowserAnimationsModule,
|
||||
SharedModule,
|
||||
@ -89,12 +97,15 @@ const DEFAULT_PERFECT_SCROLLBAR_CONFIG: PerfectScrollbarConfigInterface = {
|
||||
MatSidenavModule,
|
||||
MatInputModule,
|
||||
MatIconModule,
|
||||
MatButtonModule,
|
||||
MatListModule,
|
||||
MatMenuModule,
|
||||
MatToolbarModule,
|
||||
MatTabsModule,
|
||||
MatCheckboxModule,
|
||||
MatProgressBarModule,MatProgressSpinnerModule,
|
||||
MatTooltipModule,
|
||||
|
||||
MatSelectModule,
|
||||
MatCardModule,
|
||||
MatBadgeModule,
|
||||
@ -114,6 +125,8 @@ const DEFAULT_PERFECT_SCROLLBAR_CONFIG: PerfectScrollbarConfigInterface = {
|
||||
AngularFireAuthModule,
|
||||
AngularFireMessagingModule,
|
||||
AngularFireModule.initializeApp(environment.firebase),
|
||||
SocketIoModule.forRoot(socketConfig),
|
||||
MatVideoModule
|
||||
],
|
||||
providers: [
|
||||
{
|
||||
@ -123,6 +136,7 @@ const DEFAULT_PERFECT_SCROLLBAR_CONFIG: PerfectScrollbarConfigInterface = {
|
||||
AwsService,AuthGuard,
|
||||
TranslateService,
|
||||
PdTrigerService,
|
||||
PushNotifyService,
|
||||
// {
|
||||
// provide: PERFECT_SCROLLBAR_CONFIG,
|
||||
// useValue: DEFAULT_PERFECT_SCROLLBAR_CONFIG
|
||||
@ -134,7 +148,7 @@ const DEFAULT_PERFECT_SCROLLBAR_CONFIG: PerfectScrollbarConfigInterface = {
|
||||
},
|
||||
MessagingService, AsyncPipe,LoaderService
|
||||
],
|
||||
entryComponents: [NewPasswordDialog,ForgotPass,ChangePasswordDialog],
|
||||
entryComponents: [NewPasswordDialog,ForgotPass,ChangePasswordDialog,IncomingCallComponent,VideoChatComponent,VideoPlayerComponent],
|
||||
bootstrap: [AppComponent]
|
||||
})
|
||||
export class AppModule { }
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
<!-- <button mat-raised-button (click) ="openPlayer()">player</button> -->
|
||||
<div class="pad-wrap" [style.minHeight]="'100%'">
|
||||
<div fxFlex.gt-sm="100" fxFlex.gt-xs="100" fxFlex="100">
|
||||
<mat-card *ngIf="access; else unauthorized;">
|
||||
|
||||
@ -6,7 +6,8 @@ import { MastersService } from '../settings/service/masters/masters.service';
|
||||
import { DashboardService } from './dashboard.service';
|
||||
import { NgxDrpOptions, PresetItem, Range } from 'ngx-mat-daterange-picker';
|
||||
import { BaseChartDirective } from 'ng2-charts/ng2-charts';
|
||||
|
||||
import { VideoPlayerComponent } from 'app/video-chat/video-player/video-player.component';
|
||||
import { MatDialog } from '@angular/material';
|
||||
@Component({
|
||||
selector: 'app-dashboard',
|
||||
templateUrl: './dashboard.component.html',
|
||||
@ -40,7 +41,7 @@ export class DashboardComponent {
|
||||
// }];
|
||||
|
||||
|
||||
constructor(private _dashboardService: DashboardService) {}
|
||||
constructor(private _dashboardService: DashboardService,private dialog:MatDialog) {}
|
||||
|
||||
|
||||
ngOnInit(){
|
||||
@ -360,5 +361,4 @@ getDoughnutChartData(){
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
@ -15,6 +15,11 @@ import { AwsService } from '../../AwsService/aws.service';
|
||||
import { RoleMenuItemsPipe } from './../role-menu-items.pipe';
|
||||
import 'rxjs/add/observable/interval';
|
||||
import { MessagingService } from 'app/shared/messaging.service';
|
||||
import { IncomingCallComponent } from '../../video-chat/incoming-call/incoming-call.component';
|
||||
import { Socket } from 'ngx-socket-io';
|
||||
import { MatDialog } from '@angular/material';
|
||||
import { VideoChatComponent } from 'app/video-chat/video-chat.component';
|
||||
import { PushNotifyService } from 'app/shared/push-notify.service';
|
||||
|
||||
|
||||
|
||||
@ -59,8 +64,9 @@ export class AdminLayoutComponent implements OnInit, OnDestroy {
|
||||
permissionDeined : boolean = true;
|
||||
alertTAT: any;
|
||||
countTAT: number;
|
||||
|
||||
constructor(private router: Router, public menuItems: MenuItems, public horizontalMenuItems : HorizontalMenuItems, public translate: TranslateService,public aws:AwsService,public users:UserService,private _dashboardService: DashboardService,private messagingService:MessagingService) {
|
||||
incomingDialogOpened:boolean = false
|
||||
constructor(private router: Router, public menuItems: MenuItems, public horizontalMenuItems : HorizontalMenuItems, public translate: TranslateService,public aws:AwsService,public users:UserService,private _dashboardService: DashboardService,private messagingService:MessagingService,private socket:Socket,private matDialog:MatDialog,
|
||||
private _notificationService:PushNotifyService) {
|
||||
|
||||
const browserLang: string = translate.getBrowserLang();
|
||||
translate.use(browserLang.match(/en|fr/) ? browserLang : 'en');
|
||||
@ -112,6 +118,8 @@ export class AdminLayoutComponent implements OnInit, OnDestroy {
|
||||
|
||||
});
|
||||
// this.alertForTAT();
|
||||
this._notificationService.requestPermission();
|
||||
console.log("constructor called")
|
||||
}
|
||||
|
||||
ngOnInit(): void {
|
||||
@ -138,7 +146,14 @@ export class AdminLayoutComponent implements OnInit, OnDestroy {
|
||||
// Ps.update(elemContent);
|
||||
}
|
||||
});
|
||||
|
||||
setTimeout(()=>{
|
||||
this.listenForCalls()
|
||||
},5000)
|
||||
// this.openIncomingDialog();
|
||||
console.log("Ng On Init")
|
||||
}
|
||||
ngAfterViewInit() {
|
||||
console.log("Ng After view init")
|
||||
}
|
||||
|
||||
@HostListener('click', ['$event'])
|
||||
@ -293,6 +308,7 @@ export class AdminLayoutComponent implements OnInit, OnDestroy {
|
||||
this.aws.logout().subscribe(res=>{
|
||||
//alert("res");
|
||||
localStorage.removeItem('user_role');
|
||||
localStorage.removeItem('pd_short_info');
|
||||
this.messagingService.unsubscribeNotification()
|
||||
setTimeout(()=>{
|
||||
this.router.navigate(['/authentication/login']);
|
||||
@ -311,4 +327,75 @@ export class AdminLayoutComponent implements OnInit, OnDestroy {
|
||||
break;
|
||||
}
|
||||
}
|
||||
// FOR LISTENING TO RECIEVE CALLS FROM CALLER
|
||||
listenForCalls() {
|
||||
// this.socket.on('BackOffer', this.connectPeer)
|
||||
let userrole = localStorage.getItem('user_role')
|
||||
if(userrole == '5') {
|
||||
this.socket.fromEvent('BackOffer').subscribe((res:any)=>{
|
||||
let pd_short_info:any = localStorage.getItem('pd_short_info')
|
||||
pd_short_info = JSON.parse(pd_short_info);
|
||||
console.log(res)
|
||||
if(res && res.hasOwnProperty('random_string') && res.random_string && res.hasOwnProperty('user_type') && res.user_type != 'officer'){
|
||||
if(pd_short_info.filter(val=>val.random_string == res.random_string).length > 0){
|
||||
let curr_pd_info= pd_short_info.filter(val=>val.random_string == res.random_string)[0]
|
||||
if(curr_pd_info && curr_pd_info.pd_type == '3') {
|
||||
this.connectPeer(res,curr_pd_info);
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
connectPeer(offer,curr_pd_info) {
|
||||
console.log(offer)
|
||||
// alert("Offer is listened");
|
||||
this.notify('Incoming Call','Calling from ' + curr_pd_info.applicant_name + ' (' +curr_pd_info.pd_sno+ ')')
|
||||
this.openIncomingDialog(offer,curr_pd_info);
|
||||
}
|
||||
openIncomingDialog(offer?,curr_pd_info?) {
|
||||
offer.pd_id = curr_pd_info.pd_id
|
||||
if(this.incomingDialogOpened == true) {
|
||||
return;
|
||||
}
|
||||
this.incomingDialogOpened = true
|
||||
const dialogRef = this.matDialog.open(IncomingCallComponent,{
|
||||
// minWidth:'25%',
|
||||
// maxWidth:'30%',
|
||||
data:curr_pd_info,
|
||||
disableClose: true,
|
||||
backdropClass: 'incoming-call-background' ,
|
||||
panelClass:'incoming-call-background'
|
||||
})
|
||||
dialogRef.afterClosed().subscribe(data=>{
|
||||
console.log(data)
|
||||
if(data == 'decline'){
|
||||
this.incomingDialogOpened = false
|
||||
this.socket.emit('callStatus',{random_string:curr_pd_info.random_string,status:'declined',status_code:3})
|
||||
}
|
||||
else {
|
||||
this.incomingDialogOpened = false
|
||||
this.openVideoChatDialog(offer)
|
||||
}
|
||||
})
|
||||
}
|
||||
openVideoChatDialog(offer) {
|
||||
let dialogRef = this.matDialog.open(VideoChatComponent,{
|
||||
data:offer,
|
||||
maxWidth: '100vw',
|
||||
maxHeight: '100vh',
|
||||
height: '100%',
|
||||
width: '100%',
|
||||
disableClose: true,
|
||||
panelClass:'video-chat'
|
||||
})
|
||||
}
|
||||
notify(title,approval) {
|
||||
let data: Array < any >= [];
|
||||
data.push({
|
||||
'title': title,
|
||||
'body': approval
|
||||
});
|
||||
this._notificationService.generateNotificationWithTitle(data);
|
||||
}
|
||||
}
|
||||
|
||||
@ -26,5 +26,7 @@
|
||||
<button mat-raised-button mat-dialog-close><strong> No </strong></button>
|
||||
</mat-dialog-actions>
|
||||
<mat-dialog-actions align="end" *ngIf="!CompletenessCheck">
|
||||
<button mat-raised-button color="primary" (click)="overwritten_pd()"
|
||||
*ngIf="fk_pd_type == '3'"> <strong>Complete anyway </strong></button>
|
||||
<button mat-raised-button mat-dialog-close><strong> Ok </strong></button>
|
||||
</mat-dialog-actions>
|
||||
@ -21,6 +21,8 @@ export class PdStatusChangeDialogueComponent implements OnInit {
|
||||
addonStatus: string ="ADD_ON_PENDING";
|
||||
public Loading: boolean;
|
||||
public masterRandomString : string;
|
||||
fk_pd_type: any;
|
||||
pd_completeness_override: String = '0';
|
||||
|
||||
constructor(notifier: NotifierService , private pd: PdTrigerService,private dialogRef: MatDialogRef<PdStatusChangeDialogueComponent>,@Inject(MAT_DIALOG_DATA) public data: any)
|
||||
{
|
||||
@ -31,6 +33,8 @@ export class PdStatusChangeDialogueComponent implements OnInit {
|
||||
this.CompletenessCheck = this.data.pd_status=='INPROGRESS' ? true : this.data.pd_status=='COMPLETED' ? false : true;
|
||||
this.Loading = this.data.pd_status=='INPROGRESS' ? false : this.data.pd_status=='COMPLETED' ? true : false;
|
||||
this.masterRandomString = this.data.random_string;
|
||||
this.fk_pd_type = this.data.pd_type
|
||||
console.log("sdf@@@@@@@@@@2",this.fk_pd_type)
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
@ -60,9 +64,10 @@ export class PdStatusChangeDialogueComponent implements OnInit {
|
||||
}
|
||||
|
||||
changePDStatus(status: string): void {
|
||||
let update_status = {
|
||||
let update_status:any = {
|
||||
"pd_id":this.data.pdid,
|
||||
};
|
||||
update_status.pd_completeness_override = this.pd_completeness_override
|
||||
this.pd.editPdMasterDetails(update_status, status,this.masterRandomString).subscribe(result => {
|
||||
if (result.status == 200) {
|
||||
this.dialogRef.close({update_status:true});
|
||||
@ -77,5 +82,17 @@ export class PdStatusChangeDialogueComponent implements OnInit {
|
||||
this.notifier.notify('error', 'Something Went Wrong Try Again.! \t\"' + (error.error_type == 2 ? error.error_status + ' ( ' + error.error_text + ' ) ' : ' ( ' + error.error_text + ' ) ') +'\" Error Occur.!');
|
||||
});
|
||||
}
|
||||
|
||||
overwritten_pd() {
|
||||
// this.changePDStatus(this.data.pd_status,'1');
|
||||
let params: any={};
|
||||
params.pd_id = this.data.pdid;
|
||||
this.CompletenessCheck = true;
|
||||
this.pd_completeness_override = '1'
|
||||
// this.Loading = false;
|
||||
this.pd.getPDCompleteDetails(params).subscribe(result => {
|
||||
if (result.dataStatus === true) {
|
||||
this.enableAddonPD = result.records.address_count>0 ? true: false;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@ -1210,8 +1210,10 @@ export class BusinessAssetsInfoComponent implements OnInit {
|
||||
if (flag == 1) {
|
||||
if (value == 'yes') {
|
||||
item.controls.business_years.setValidators([Validators.required]);
|
||||
if(this.fk_pd_type != '3') {
|
||||
item.controls.business_is_pd_visited.setValidators([Validators.required]);
|
||||
item.controls.business_pd_visited_remark.setValidators([Validators.required]);
|
||||
}
|
||||
item.controls.business_ownership_type.setValidators([Validators.required]);
|
||||
}
|
||||
else {
|
||||
|
||||
@ -41,7 +41,7 @@
|
||||
</mat-select>
|
||||
<mat-error *ngIf="_finalRemarkForm.controls['is_service_provided'].hasError('required')">Service Provided Required</mat-error>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 100%">
|
||||
<mat-form-field style="width: 90%">
|
||||
<input matInput placeholder="Personal feedback or market intelligence on the case (if any)" formControlName="market_intelligence">
|
||||
</mat-form-field>
|
||||
</mat-card-content>
|
||||
@ -156,7 +156,7 @@
|
||||
<mat-error *ngIf="_finalRemarkForm.controls['mode_of_transport_during_visit'].hasError('required')">Specify the Mode of Transport Used to Visit the PD address Required</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-card *ngIf="lender_short_name == 'CLIX' || lender_short_name == 'MWISE' || prod_catagory == 'LAEP'">
|
||||
<mat-card *ngIf="(lender_short_name == 'CLIX' || lender_short_name == 'MWISE' || prod_catagory == 'LAEP') && fk_pd_type != '3'">
|
||||
<mat-card-content>
|
||||
<mat-card-subtitle *ngIf="lender_short_name == 'CLIX'">CLIX</mat-card-subtitle>
|
||||
<mat-card-subtitle *ngIf="lender_short_name == 'MWISE'">MWISE</mat-card-subtitle>
|
||||
|
||||
@ -256,7 +256,7 @@ export class FinalRemarksComponent implements OnInit {
|
||||
this._finalRemarkForm.controls.market_intelligence.setValue(data.records.market_intelligence || '');
|
||||
|
||||
|
||||
if(this.lender_short_name == 'CLIX' || this.lender_short_name == 'MWISE' || this.prod_catagory == 'LAEP'){
|
||||
if(this.fk_pd_type != '3' && (this.lender_short_name == 'CLIX' || this.lender_short_name == 'MWISE' || this.prod_catagory == 'LAEP')){
|
||||
|
||||
if(this.prod_catagory == 'LAEP') {this._finalRemarkForm.controls.outlet_location.setValue(this.prod_catagory == 'LAEP' ? data.records.outlet_location : ''); }
|
||||
this._finalRemarkForm.controls.is_competition.setValue(data.records.is_competition);
|
||||
|
||||
@ -500,7 +500,7 @@
|
||||
</div><br/>
|
||||
<div style="width:auto" *ngIf="financialForm.value.kuccha_records_shown == 'yes'">
|
||||
<mat-label *ngIf="fk_pd_type != '3'">Photograph of Kuchha bills allowed</mat-label><br/>
|
||||
<mat-label *ngIf="fk_pd_type == '3'">Photographs of kuccha bills uploded</mat-label><br/>
|
||||
<mat-label *ngIf="fk_pd_type == '3'">Photographs of kuccha bills uploaded</mat-label><br/>
|
||||
<mat-radio-group formControlName="kuccha_bill_allowed" >
|
||||
<mat-radio-button value="yes">Yes
|
||||
</mat-radio-button>
|
||||
|
||||
@ -37,14 +37,16 @@
|
||||
</mat-cell>
|
||||
</ng-container>
|
||||
<ng-container matColumnDef="is_person_met">
|
||||
<mat-header-cell *matHeaderCellDef> Is Person Met </mat-header-cell>
|
||||
<mat-header-cell *matHeaderCellDef> <span *ngIf="pd_all_details.pdmaster_details.fk_pd_type == '3'">Person Contacted</span>
|
||||
<span *ngIf="pd_all_details.pdmaster_details.fk_pd_type != '3'">Is Person Met</span> </mat-header-cell>
|
||||
<mat-cell *matCellDef="let details;let i = index;" [formGroupName]="i">
|
||||
<mat-checkbox class="table-checkbox" color="primary"
|
||||
formControlName="is_person_met" (change)="split_customer_abbr == 'SAL' ? salariedcheck() : ''"></mat-checkbox>
|
||||
</mat-cell>
|
||||
</ng-container>
|
||||
<ng-container matColumnDef="is_applicant">
|
||||
<mat-header-cell *matHeaderCellDef> Is Applicant </mat-header-cell>
|
||||
<mat-header-cell *matHeaderCellDef> <span *ngIf="pd_all_details.pdmaster_details.fk_pd_type == '3'">Is Loan applicant</span>
|
||||
<span *ngIf="pd_all_details.pdmaster_details.fk_pd_type != '3'"> Is Applicant </span></mat-header-cell>
|
||||
<mat-cell *matCellDef="let details;let i = index;" [formGroupName]="i">
|
||||
<mat-checkbox class="table-checkbox" color="primary"
|
||||
formControlName="is_applicant" (change)="split_customer_abbr == 'SAL' ? salariedcheck() : ''"></mat-checkbox>
|
||||
|
||||
@ -44,7 +44,10 @@
|
||||
display:flex;
|
||||
justify-content:flex-end;
|
||||
}
|
||||
|
||||
mat-cell:nth-child(1),
|
||||
mat-header-cell:nth-child(1) {
|
||||
flex: 0 0 20%;
|
||||
}
|
||||
mat-cell:nth-child(5),
|
||||
mat-header-cell:nth-child(5) {
|
||||
flex: 0 0 17%;
|
||||
@ -52,12 +55,21 @@
|
||||
|
||||
mat-cell:nth-child(6),
|
||||
mat-header-cell:nth-child(6) {
|
||||
flex: 0 0 20%;
|
||||
flex: 0 0 15%;
|
||||
}
|
||||
|
||||
mat-cell:nth-child(3),
|
||||
mat-header-cell:nth-child(3),
|
||||
mat-cell:nth-child(2),
|
||||
mat-header-cell:nth-child(2) {
|
||||
margin-left: 1%;
|
||||
margin-right: 1%;
|
||||
}
|
||||
|
||||
mat-cell:nth-child(7),
|
||||
mat-header-cell:nth-child(7) {
|
||||
justify-content: end;
|
||||
flex: 0 0 19%;
|
||||
}
|
||||
|
||||
.capitalize{
|
||||
@ -172,4 +184,7 @@ $product-bg-color-hover: rgba(103, 58, 183, 0.7);
|
||||
// }
|
||||
}
|
||||
}
|
||||
// .mat-column-is_applicant {
|
||||
// width: 12%;
|
||||
// }
|
||||
|
||||
@ -9,8 +9,8 @@ import { MatDialog, MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
|
||||
/** Service */
|
||||
import { PdTrigerService } from '../../../../../pd-service/pd-triger.service';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { analyzeAndValidateNgModules } from '@angular/compiler';
|
||||
import { ImageCropComponent } from '../dialogue/image-crop/image-crop.component';
|
||||
// import { analyzeAndValidateNgModules } from '@angular/compiler';
|
||||
// import { ImageCropComponent } from '../dialogue/image-crop/image-crop.component';
|
||||
|
||||
@Component({
|
||||
// changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
@ -90,6 +90,8 @@ export class StockComponent implements OnInit {
|
||||
this.fk_pd_type = this.pd_all_details.pdmaster_details.fk_pd_type;
|
||||
if(this.fk_pd_type == '3'){
|
||||
this.SPsufficientList.push({value:"not able to assess",isdisplayvalue:"Not able to assess",isdisabled:false})
|
||||
this.TGsufficientList.push({value:"not able to assess",isdisplayvalue:"Not able to assess",isdisabled:false})
|
||||
this.RMsufficientList.push({value:"not able to assess",isdisplayvalue:"Not able to assess",isdisabled:false})
|
||||
}
|
||||
this.image_doc_params={pdid:this.pdid,form_id:this.form_id,company_id:this.company_id}
|
||||
}
|
||||
|
||||
@ -140,7 +140,7 @@ export class StartPdComponent implements OnInit, OnDestroy {
|
||||
// load pd status change dialogue
|
||||
pdStatusDialogue(status: string, checkType: number): void {
|
||||
const dialogRef = this.dialog.open(PdStatusChangeDialogueComponent, {
|
||||
data: { pdid: this.startPD, pd_status: status ,random_string:this.randomString },
|
||||
data: { pdid: this.startPD, pd_status: status ,random_string:this.randomString,pd_type:this.pdMasterList.fk_pd_type },
|
||||
disableClose: true,
|
||||
minWidth:'30%',
|
||||
maxWidth:'40%',
|
||||
|
||||
@ -0,0 +1,52 @@
|
||||
import {
|
||||
animate,
|
||||
keyframes,
|
||||
query,
|
||||
stagger,
|
||||
state,
|
||||
style,
|
||||
transition,
|
||||
trigger
|
||||
} from '@angular/animations';
|
||||
|
||||
export const speedDialFabAnimations = [
|
||||
trigger('fabToggler', [
|
||||
state('inactive', style({
|
||||
transform: 'rotate(0deg)'
|
||||
})),
|
||||
state('active', style({
|
||||
transform: 'rotate(225deg)'
|
||||
})),
|
||||
transition('* <=> *', animate('200ms cubic-bezier(0.4, 0.0, 0.2, 1)')),
|
||||
]),
|
||||
trigger('speedDialStagger', [
|
||||
transition('* => *', [
|
||||
|
||||
query(':enter', style({ opacity: 0 }), {optional: true}),
|
||||
|
||||
query(':enter', stagger('40ms',
|
||||
[
|
||||
animate('200ms cubic-bezier(0.4, 0.0, 0.2, 1)',
|
||||
keyframes(
|
||||
[
|
||||
style({opacity: 0, transform: 'translateY(10px)'}),
|
||||
style({opacity: 1, transform: 'translateY(0)'}),
|
||||
]
|
||||
)
|
||||
)
|
||||
]
|
||||
), {optional: true}),
|
||||
|
||||
query(':leave',
|
||||
animate('200ms cubic-bezier(0.4, 0.0, 0.2, 1)',
|
||||
keyframes([
|
||||
style({opacity: 1}),
|
||||
style({opacity: 0}),
|
||||
])
|
||||
), {optional: true}
|
||||
)
|
||||
|
||||
])
|
||||
])
|
||||
];
|
||||
|
||||
@ -0,0 +1,26 @@
|
||||
<div id="fab-dismiss"
|
||||
*ngIf="fabTogglerState==='active'"
|
||||
(click)="onToggleFab()">
|
||||
</div>
|
||||
|
||||
<div class="fab-container">
|
||||
<button mat-icon-button mat-raised-button class="fab-toggler mr-1 mb-1 hover-icon" color="optblue"
|
||||
(click)="onToggleFab()" matTooltip="Copy Customer Link" matTooltipPosition="above">
|
||||
<!-- <i class="material-icons" [@fabToggler]="{value: fabTogglerState}">link</i> -->
|
||||
<mat-icon [@fabToggler]="{value: fabTogglerState}">link</mat-icon>
|
||||
</button>
|
||||
<div [@speedDialStagger]="buttons.length">
|
||||
<button *ngFor="let btn of buttons" (click)="onBtnClick(btn)"
|
||||
mat-mini-fab
|
||||
class="fab-secondary mr-1 mb-1 hover-icon"
|
||||
color="secondary"
|
||||
[matTooltip]="btn.placeholder" matTooltipPosition="above">
|
||||
<mat-icon>{{btn.icon}}</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <button *ngIf="master.fk_pd_type == '3'"
|
||||
mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" (click)="copyCusURL(master.random_string)"
|
||||
matTooltip="Copy Customer Link" matTooltipPosition="above">
|
||||
<mat-icon>link</mat-icon>
|
||||
</button> -->
|
||||
@ -0,0 +1,50 @@
|
||||
.fab-container {
|
||||
position: absolute;
|
||||
// top: 1%;
|
||||
// right: 35%;
|
||||
z-index: 100;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
|
||||
> div {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
// margin-top: 5px;
|
||||
// margin-top: 5px;
|
||||
position: absolute;
|
||||
right: 67px;
|
||||
// top: -13px;
|
||||
|
||||
button {
|
||||
// margin-top: 17px;
|
||||
background: #cfdd49;
|
||||
margin-left:10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
@media(max-width:580px) {
|
||||
.fab-container {
|
||||
> div {
|
||||
flex-direction: column !important;
|
||||
right: 0px;
|
||||
top: 53px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.fab-toggler {
|
||||
float: right;
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
#fab-dismiss {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
z-index: 99;
|
||||
}
|
||||
|
||||
@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { SpeedDialFabComponent } from './speed-dial-fab.component';
|
||||
|
||||
describe('SpeedDialFabComponent', () => {
|
||||
let component: SpeedDialFabComponent;
|
||||
let fixture: ComponentFixture<SpeedDialFabComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ SpeedDialFabComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(SpeedDialFabComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,42 @@
|
||||
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
|
||||
import { speedDialFabAnimations } from './speed-dial-fab.animations';
|
||||
|
||||
@Component({
|
||||
selector: 'app-speed-dial-fab',
|
||||
templateUrl: './speed-dial-fab.component.html',
|
||||
styleUrls: ['./speed-dial-fab.component.scss'],
|
||||
animations: speedDialFabAnimations
|
||||
})
|
||||
export class SpeedDialFabComponent implements OnInit {
|
||||
|
||||
@Input() options;
|
||||
@Output() fabClick = new EventEmitter()
|
||||
buttons = [];
|
||||
fabTogglerState = 'inactive';
|
||||
|
||||
constructor() { }
|
||||
|
||||
ngOnInit() {
|
||||
const maxButtons = 6;
|
||||
if (this.options.buttons.length > maxButtons) {
|
||||
this.options.buttons.splice(5, this.options.buttons.length - maxButtons);
|
||||
}
|
||||
}
|
||||
|
||||
showItems() {
|
||||
this.fabTogglerState = 'active';
|
||||
this.buttons = this.options.buttons;
|
||||
}
|
||||
|
||||
hideItems() {
|
||||
this.fabTogglerState = 'inactive';
|
||||
this.buttons = [];
|
||||
}
|
||||
|
||||
onToggleFab() {
|
||||
this.buttons.length ? this.hideItems() : this.showItems();
|
||||
}
|
||||
onBtnClick(btnValue) {
|
||||
this.fabClick.emit(btnValue)
|
||||
}
|
||||
}
|
||||
@ -125,22 +125,38 @@
|
||||
</mat-card>
|
||||
</div>
|
||||
<div fxFlex.xs="100" fxFlex.sm="100" fxFlex.md="60" fxFlex.lg="70" fxFlex.xl="70" class="content-data" *ngFor="let master of pdMasterData">
|
||||
<div fxLayout="row">
|
||||
<div fxFlex="100" align="right">
|
||||
<button mat-raised-button class="mr-1 mb-1" color="primary" style="cursor: not-allowed !important;">
|
||||
<div fxLayout="row" fxLayoutAlign="flex-end" fxLayoutGap="68px" fxLayoutGap.xs="8px">
|
||||
<div fxLayout="column">
|
||||
<app-speed-dial-fab fxFlex="30" class="fab-group" *ngIf="master.fk_pd_type == '3'" [options]="FabOptions" (fabClick)="copyCusURL($event)"></app-speed-dial-fab>
|
||||
</div>
|
||||
<div align="right" >
|
||||
<!-- <button mat-raised-button class="mr-1 mb-1" color="primary" style="cursor: not-allowed !important;">
|
||||
<strong> {{master.pd_status==pdStatusCheck.QC_COMPLETED ? 'QC Completed' : master.pd_status==pdStatusCheck.ADD_ON_PENDING ? 'Addon Pending' : master.pd_status | titlecase}}</strong>
|
||||
</button>
|
||||
<span> <button *ngIf="master.fk_pd_type == '3'"
|
||||
</button> -->
|
||||
<!-- <span> <button *ngIf="master.fk_pd_type == '3'"
|
||||
mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" (click)="copyCusURL(master.random_string)"
|
||||
matTooltip="Copy Customer Link" matTooltipPosition="above">
|
||||
<mat-icon>link</mat-icon>
|
||||
</button></span>
|
||||
</button></span> -->
|
||||
<!-- <app-speed-dial-fab class="fab-group" *ngIf="master.fk_pd_type == '3'" [options]="FabOptions" (fabClick)="copyCusURL($event)"></app-speed-dial-fab> -->
|
||||
<span> <button *ngIf="master.fk_pd_type == '3'"
|
||||
mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" (click)="onClickSmsLink(master)"
|
||||
matTooltip="Send Link Via SMS" matTooltipPosition="above">
|
||||
<mat-icon>sms</mat-icon>
|
||||
</button></span>
|
||||
|
||||
</button> </span>
|
||||
<!-- <div class="fab-group" *ngIf="master.fk_pd_type == '3'"> -->
|
||||
<!-- </div> -->
|
||||
<button *ngIf="master.fk_pd_type == '3'" mat-stroked-button class="mr-1 mb-1" color="primary" (click)="openPlayer()">
|
||||
<mat-icon>play_circle_filled</mat-icon>
|
||||
<strong>Play</strong>
|
||||
</button>
|
||||
<button *ngIf="master.fk_pd_type == '3'" mat-button mat-raised-button class="mr-1 mb-1" color="primary" (click)="openVideoChat()">
|
||||
<mat-icon>videocam</mat-icon>
|
||||
<strong>Call</strong>
|
||||
</button>
|
||||
<button mat-raised-button class="mr-1 mb-1" color="primary" style="cursor: not-allowed !important;">
|
||||
<strong> {{master.pd_status==pdStatusCheck.QC_COMPLETED ? 'QC Completed' : master.pd_status==pdStatusCheck.ADD_ON_PENDING ? 'Addon Pending' : master.pd_status | titlecase}}</strong>
|
||||
</button>
|
||||
<span *ngIf="userRoleID == 10 || userRoleID == 3"><button *ngIf="roleAccessDetails.trigger && currentPDStatus==pdStatusCheck.DRAFT || currentPDStatus==pdStatusCheck.TRIGGERED || currentPDStatus==pdStatusCheck.ALLOCATED || currentPDStatus==pdStatusCheck.SCHEDULED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" (click)="editPdMaster(master)" matTooltipPosition="above" matTooltip="Edit PD Master"><mat-icon>edit</mat-icon></button>
|
||||
<button *ngIf="roleAccessDetails.trigger && currentPDStatus==pdStatusCheck.DRAFT" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Trigger" matTooltipPosition="above" (click)="directTriggerPD(mandatoryFieldsValidations,master)"><mat-icon>flash_on</mat-icon></button>
|
||||
</span>
|
||||
|
||||
@ -79,3 +79,11 @@
|
||||
// }
|
||||
|
||||
|
||||
.fab-group{
|
||||
// app-speed-dial-fab {
|
||||
position: absolute;
|
||||
@media(min-width:500px) {
|
||||
// right: 415px;
|
||||
}
|
||||
// }
|
||||
}
|
||||
@ -19,6 +19,9 @@ import { InitiateAdditionalPdComponent } from './../initiate-additional-pd/initi
|
||||
|
||||
/**sweet alert */
|
||||
import Swal from 'sweetalert2';
|
||||
import { VideoChatComponent } from 'app/video-chat/video-chat.component';
|
||||
import { MastersComponent } from 'app/settings/masters/masters.component';
|
||||
import { VideoPlayerComponent } from 'app/video-chat/video-player/video-player.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-view-pd',
|
||||
@ -100,6 +103,32 @@ export class ViewPdComponent implements OnInit, OnDestroy {
|
||||
public _EditPDtriggerForm: FormGroup;
|
||||
existPDs: any=[];
|
||||
// no_qc_remarks: boolean;
|
||||
|
||||
FabOptions = {
|
||||
buttons: [
|
||||
{
|
||||
icon: 'camera',
|
||||
placeholder:'Image Capture',
|
||||
btnValue:'image'
|
||||
},
|
||||
{
|
||||
icon: 'videocam',
|
||||
placeholder:'Video Chat',
|
||||
btnValue:'video'
|
||||
},
|
||||
// {
|
||||
// icon: 'room'
|
||||
// },
|
||||
// {
|
||||
// icon: 'lightbulb_outline'
|
||||
// },
|
||||
// {
|
||||
// icon: 'lock'
|
||||
// }
|
||||
]
|
||||
};
|
||||
videoSrc: any = null;
|
||||
|
||||
constructor(notifier: NotifierService, private dialog: MatDialog, private _fb: FormBuilder,
|
||||
private _pd: PdTrigerService, private route: ActivatedRoute, private router: Router, private ListPdComponent: ListPdComponent) {
|
||||
this.notifier = notifier;
|
||||
@ -118,7 +147,7 @@ export class ViewPdComponent implements OnInit, OnDestroy {
|
||||
// this.masterRandomString = this.route.snapshot.params['rdmstr'];
|
||||
this.viewPdDetails(this.viewID,this.masterRandomString);
|
||||
this.getAllNotes();
|
||||
|
||||
this.getVideoUrl(this.viewID,this.masterRandomString)
|
||||
}
|
||||
pd_QC_Rating: Number;
|
||||
|
||||
@ -559,12 +588,21 @@ export class ViewPdComponent implements OnInit, OnDestroy {
|
||||
})
|
||||
|
||||
}
|
||||
copyCusURL(randomStr) {
|
||||
copyCusURL(event) {
|
||||
// console.log(window.location);
|
||||
let cus_link = window.location.origin+'/customer/#/pd-images/'+randomStr;
|
||||
console.log(randomStr)
|
||||
console.log(event)
|
||||
let cus_link;
|
||||
if(event && event.btnValue == 'video') {
|
||||
cus_link = window.location.origin+'/vchat/#/chat/'+this.pdMasterData[0].random_string;
|
||||
}
|
||||
else if(event && event.btnValue == 'image') {
|
||||
cus_link = window.location.origin+'/customer/#/pd-images/'+this.pdMasterData[0].random_string;
|
||||
}
|
||||
// return;
|
||||
// let cus_link = window.location.origin+'/customer/#/pd-images/'+randomStr;
|
||||
// console.log(randomStr)
|
||||
this._pd.copyToClipBoard(cus_link);
|
||||
this.notifier.notify('info','Customer link copied');
|
||||
this.notifier.notify('info',event.placeholder+' Customer link copied');
|
||||
}
|
||||
|
||||
onClickSmsLink(master){
|
||||
@ -581,4 +619,37 @@ export class ViewPdComponent implements OnInit, OnDestroy {
|
||||
})
|
||||
}
|
||||
|
||||
openVideoChat(){
|
||||
let dialogRef = this.dialog.open(VideoChatComponent,{
|
||||
data:{type:'init',random_string:this.pdMasterData[0].random_string},
|
||||
maxWidth: '100vw',
|
||||
maxHeight: '100vh',
|
||||
height: '100%',
|
||||
width: '100%',
|
||||
disableClose: true,
|
||||
panelClass:'video-chat'
|
||||
})
|
||||
}
|
||||
openPlayer(){
|
||||
if(this.videoSrc == null) {
|
||||
this.notifier.notify('info',"No Videos Found");
|
||||
return;
|
||||
}
|
||||
let dialogRef = this.dialog.open(VideoPlayerComponent,{
|
||||
data:{videoUrl:this.videoSrc},
|
||||
maxWidth: '100vw',
|
||||
maxHeight: '100vh',
|
||||
height: '80%',
|
||||
width: '80%',
|
||||
disableClose: false,
|
||||
panelClass:'video-player'
|
||||
})
|
||||
}
|
||||
getVideoUrl(pd_id,randomStr){
|
||||
let params = {"pd_id":pd_id,"random_string":randomStr}
|
||||
this._pd.getRecordedPlaybackUrl(params).subscribe(result=>{
|
||||
this.videoSrc=result['url'];
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
@ -129,6 +129,7 @@ import {AngularSplitModule} from 'angular-split';
|
||||
import { ImageDocsComponent } from './list-pd/start-pd/forms/image-docs/image-docs.component'
|
||||
import { environment } from 'environments/environment'
|
||||
import { CustomTitleCaseDirective } from '../pd-directive/custom-title-case.directive';
|
||||
import { SpeedDialFabComponent } from './list-pd/view-pd/speed-dial-fab/speed-dial-fab.component';
|
||||
|
||||
/**
|
||||
* Custom angular notifier options
|
||||
@ -175,7 +176,7 @@ const pdCustomNotifierOptions: NotifierOptions = {
|
||||
};
|
||||
|
||||
@NgModule({
|
||||
declarations: [TelePdAllocationComponent, FinancialInfoComponent, BusinessInfoComponent, EmploymentInfoComponent, StockComponent, BankingDetailsComponent, ListPdComponent, FamilyDetailsComponent, AddressComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, CurrentLoanComponent, AssetsInfoComponent, LoanDetailsComponent, OtherIncomeComponent, SupplierInfoComponent, PersonalInfoComponent, LenderRepresentativeComponent, PdReportComponent, AssessedIncomeComponent, AllocationViewMoreComponent, PdRequirementComponent,PdCollectedDocsComponent, GeneralInfoComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent, BusinessInfoGroupComponent, SearchRelationPipe, RupeeCurrencyFormatPipe, NumberToWordsPipe, DeleteRecordsCountPipe, BusinessAssetsInfoComponent, BusinessBankingDetailsComponent, SalesDetailsComponent, DailySalesDetailsComponent, SalesCalculationComponent, ManageSalesComponent, PurchaseDetailsComponent, BusinessExpenseDetailsComponent, HouseHoldDetailsComponent, OtherBusinessIncomeDetailsComponent, ManagePurchaseComponent, ManageBusinesExpenseComponent, ManageHouseHoldComponent, ManageOtherBusinessIncomeComponent, GrossProfitCalculationComponent, ManageDailySalesComponent, PdStatusChangeDialogueComponent, PdLocatedMapViewDirective, ViewLocationComponent, GetAnswerableFormsPipe, ConfirmAiDetailsComponent, RentalVerificationComponent, InitiateAdditionalPdComponent ,ManageDailyPurchaseComponent, DailyPurchaseDetailsComponent, ManageRentalVerificationComponent, FuturePlansAndBusinessEnvironmentComponent, ImageCropComponent,PurchaseCalculationComponent,QueriesDocsComponent, ImageDocsComponent,CustomTitleCaseDirective],
|
||||
declarations: [TelePdAllocationComponent, FinancialInfoComponent, BusinessInfoComponent, EmploymentInfoComponent, StockComponent, BankingDetailsComponent, ListPdComponent, FamilyDetailsComponent, AddressComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, CurrentLoanComponent, AssetsInfoComponent, LoanDetailsComponent, OtherIncomeComponent, SupplierInfoComponent, PersonalInfoComponent, LenderRepresentativeComponent, PdReportComponent, AssessedIncomeComponent, AllocationViewMoreComponent, PdRequirementComponent,PdCollectedDocsComponent, GeneralInfoComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent, BusinessInfoGroupComponent, SearchRelationPipe, RupeeCurrencyFormatPipe, NumberToWordsPipe, DeleteRecordsCountPipe, BusinessAssetsInfoComponent, BusinessBankingDetailsComponent, SalesDetailsComponent, DailySalesDetailsComponent, SalesCalculationComponent, ManageSalesComponent, PurchaseDetailsComponent, BusinessExpenseDetailsComponent, HouseHoldDetailsComponent, OtherBusinessIncomeDetailsComponent, ManagePurchaseComponent, ManageBusinesExpenseComponent, ManageHouseHoldComponent, ManageOtherBusinessIncomeComponent, GrossProfitCalculationComponent, ManageDailySalesComponent, PdStatusChangeDialogueComponent, PdLocatedMapViewDirective, ViewLocationComponent, GetAnswerableFormsPipe, ConfirmAiDetailsComponent, RentalVerificationComponent, InitiateAdditionalPdComponent ,ManageDailyPurchaseComponent, DailyPurchaseDetailsComponent, ManageRentalVerificationComponent, FuturePlansAndBusinessEnvironmentComponent, ImageCropComponent,PurchaseCalculationComponent,QueriesDocsComponent, ImageDocsComponent,CustomTitleCaseDirective, SpeedDialFabComponent],
|
||||
imports: [
|
||||
CommonModule,
|
||||
ManagePdRoutingModule,
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
/** Common Import Section */
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable, of, forkJoin } from 'rxjs';
|
||||
import { HttpClient, HttpParams } from '@angular/common/http';
|
||||
import { HttpClient, HttpParams, HttpHeaders } from '@angular/common/http';
|
||||
import { catchError, map } from 'rxjs/operators';
|
||||
|
||||
/** Imported Service Files Are., */
|
||||
@ -184,7 +184,20 @@ export class PdTrigerService {
|
||||
|
||||
// get pd details
|
||||
getPdDetails(): Observable<any> {
|
||||
return this._http.get<any>(this.apiUrl + "listLessPDDetails/get")
|
||||
let userrole = localStorage.getItem('user_role')
|
||||
let params
|
||||
if(userrole == '5') {
|
||||
let userid = this._aws.getlocale()
|
||||
params = new HttpParams().set("pdofficerid",userid); //Create new HttpParams
|
||||
}
|
||||
return this._http.get<any>(this.apiUrl + "listLessPDDetails/get", {params: params})
|
||||
.map(res=>{
|
||||
if(res['dataStatus']) {
|
||||
let pd_det = res['records'].map(val=>{ return {applicant_name:val.applicant_name,pd_id:val.pd_id,random_string:val.random_string,pd_sno:val.pd_sno,pd_type:val.fk_pd_type}})
|
||||
localStorage.setItem('pd_short_info',JSON.stringify(pd_det));
|
||||
return res
|
||||
}
|
||||
})
|
||||
.pipe(
|
||||
catchError(this.handleError('operation', []))
|
||||
)
|
||||
@ -192,9 +205,25 @@ export class PdTrigerService {
|
||||
|
||||
// get status based pd list
|
||||
getTabStatusPdDetails(status: string): Observable<any> {
|
||||
const tabStatus = status ?
|
||||
let userrole = localStorage.getItem('user_role')
|
||||
let tabStatus
|
||||
if(userrole == '5') {
|
||||
let userid = this._aws.getlocale()
|
||||
tabStatus = new HttpParams().set("pdofficerid",userid).set('status', status); //Create new HttpParams
|
||||
tabStatus = { params: new HttpParams().set("pdofficerid",userid).set('status', status) };
|
||||
}
|
||||
else {
|
||||
tabStatus = status ?
|
||||
{ params: new HttpParams().set('status', status) } : {};
|
||||
}
|
||||
return this._http.get<any[]>(this.apiUrl + "listLessPDDetails/get", tabStatus)
|
||||
// .map(res=>{
|
||||
// if(res['dataStatus']) {
|
||||
// let pd_det = res['records'].map(val=>{ return {applicant_name:val.applicant_name,pd_id:val.pd_id,random_string:val.random_string,pd_sno:val.pd_sno,pd_type:val.fk_pd_type}})
|
||||
// localStorage.setItem('pd_short_info',JSON.stringify(pd_det));
|
||||
// return res
|
||||
// }
|
||||
// })
|
||||
.pipe(
|
||||
catchError(this.handleError('operation', []))
|
||||
)
|
||||
@ -683,8 +712,21 @@ export class PdTrigerService {
|
||||
*/
|
||||
|
||||
overAllSearchFormDetails(searchItem) {
|
||||
let userrole = localStorage.getItem('user_role')
|
||||
if(userrole == '5') {
|
||||
let userid = this._aws.getlocale()
|
||||
searchItem.pd_officer_id = userid
|
||||
}
|
||||
let records = { 'records': searchItem };
|
||||
return this._http.post(this.apiUrl + 'filterPDList', records).pipe(
|
||||
return this._http.post(this.apiUrl + 'filterPDList', records)
|
||||
.map(res=>{
|
||||
if(res['dataStatus']) {
|
||||
let pd_det = res['records'].map(val=>{ return {applicant_name:val.applicant_name,pd_id:val.pd_id,random_string:val.random_string,pd_sno:val.pd_sno,pd_type:val.fk_pd_type}})
|
||||
localStorage.setItem('pd_short_info',JSON.stringify(pd_det));
|
||||
return res
|
||||
}
|
||||
})
|
||||
.pipe(
|
||||
catchError(this.handleError('operation', []))
|
||||
);
|
||||
}
|
||||
@ -847,4 +889,20 @@ export class PdTrigerService {
|
||||
document.execCommand('copy');
|
||||
document.body.removeChild(selBox);
|
||||
}
|
||||
// saveVideo(params) {
|
||||
// const httpOptions = {
|
||||
// headers: new HttpHeaders({
|
||||
// 'Content-Type': 'application/json',
|
||||
// 'Access-Control-Allow-Origin': '*',
|
||||
// 'Access-Control-Allow-Credentials': 'true'
|
||||
// })
|
||||
// };
|
||||
// return this._http.post('http://localhost/newCode/saveVideo',params,httpOptions);
|
||||
// }
|
||||
saveCusVideo(params) {
|
||||
return this._http.post(this.apiUrl+'saveCusVideo',params);
|
||||
}
|
||||
getRecordedPlaybackUrl(params){
|
||||
return this._http.post(this.apiUrl+'getVideoURL',params)
|
||||
}
|
||||
}
|
||||
|
||||
@ -193,7 +193,7 @@ export class QcViewComponent implements OnInit, OnDestroy {
|
||||
// pd allocation to
|
||||
pdAllocationTo(pdData:any,childData: any) {
|
||||
pdData.pd_id = childData.assigned_pd;
|
||||
if(pdData.fk_pd_type == 1){
|
||||
if (pdData.fk_pd_type == 1 || pdData.fk_pd_type == 3) {
|
||||
const dialogRef = this.dialog.open(PdAllocationComponent, {
|
||||
data: pdData,
|
||||
position: { right: '0'},
|
||||
@ -220,20 +220,20 @@ export class QcViewComponent implements OnInit, OnDestroy {
|
||||
this.viewPdDetails(this.viewID,this.masterRandomString)
|
||||
});
|
||||
}
|
||||
else if(pdData.fk_pd_type == 3){
|
||||
const dialogRef = this.dialog.open(TelePdAllocationComponent, {
|
||||
data: pdData,
|
||||
position: { right: '0'},
|
||||
width: '80%',
|
||||
disableClose: true,
|
||||
});
|
||||
dialogRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
// this.notifier.notify('success', 'Successfully allocated.!');
|
||||
// else if(pdData.fk_pd_type == 3){
|
||||
// const dialogRef = this.dialog.open(TelePdAllocationComponent, {
|
||||
// data: pdData,
|
||||
// position: { right: '0'},
|
||||
// width: '80%',
|
||||
// disableClose: true,
|
||||
// });
|
||||
// dialogRef.afterClosed()
|
||||
// .subscribe(dataresult => {
|
||||
// // this.notifier.notify('success', 'Successfully allocated.!');
|
||||
|
||||
this.viewPdDetails(this.viewID,this.masterRandomString)
|
||||
});
|
||||
}
|
||||
// this.viewPdDetails(this.viewID,this.masterRandomString)
|
||||
// });
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -68,6 +68,18 @@ export class PushNotifyService {
|
||||
let notify = self.create('', options).subscribe();
|
||||
})
|
||||
}
|
||||
generateNotificationWithTitle(source: Array < any > ): void {
|
||||
let self = this;
|
||||
source.forEach((item) => {
|
||||
let options = {
|
||||
body: item.body,
|
||||
icon: item.icon,
|
||||
sound:'src/assets/spinner/notify.mp3',
|
||||
sticky:true
|
||||
};
|
||||
let notify = self.create(item.title, options).subscribe();
|
||||
})
|
||||
}
|
||||
}
|
||||
export declare type Permission = 'denied' | 'granted' | 'default';
|
||||
export interface PushNotification {
|
||||
|
||||
@ -0,0 +1,26 @@
|
||||
<div fxLayout="column" fxLayoutGap="50px">
|
||||
<div class="label" fxLayoutAlign="center center">
|
||||
Incoming Call
|
||||
</div>
|
||||
<div class="call-animation">
|
||||
<div fxFlex="135px" fxLayout.xs ="100%">
|
||||
<img class="img-circle" src="assets/spinner/notfound_blue.png" alt="Image"/>
|
||||
</div>
|
||||
</div>
|
||||
<div fxLayout="column" class="user-name" fxLayoutAlign="center center">
|
||||
<!-- <div > -->
|
||||
<h5>{{this.pd_info.applicant_name}}</h5>
|
||||
<h6>{{this.pd_info.pd_sno}}</h6>
|
||||
<!-- </div> -->
|
||||
</div>
|
||||
<div fxLayout="row" fxLayoutAlign="center center" fxLayoutGap="30px" fxLayoutGap.xs="5px">
|
||||
<div fxLayout="column">
|
||||
<button mat-raised-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Answer" matTooltipPosition="above" (click)="answer_call()"><mat-icon>call</mat-icon>
|
||||
Answer</button>
|
||||
</div>
|
||||
<div fxLayout="column">
|
||||
<button mat-raised-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Decline" matTooltipPosition="above" (click)="closeDialog()"><mat-icon>call_end</mat-icon>
|
||||
Decline</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -0,0 +1,59 @@
|
||||
::ng-deep { .incoming-call-background > mat-dialog-container {
|
||||
background: #71AFFF;
|
||||
padding: 15px;
|
||||
}
|
||||
}
|
||||
.label{
|
||||
margin-bottom: 5% !important;
|
||||
color: white
|
||||
}
|
||||
.user-name {
|
||||
margin: 8% !important;
|
||||
h5{
|
||||
font-weight: bold;
|
||||
}
|
||||
h6{
|
||||
margin-top: 8px;
|
||||
}
|
||||
color: white
|
||||
}
|
||||
.call-animation {
|
||||
background: #fff;
|
||||
width: 135px;
|
||||
height: 135px;
|
||||
position: relative;
|
||||
margin: 0px auto !important;
|
||||
border-radius: 100%;
|
||||
border: solid 5px #fff;
|
||||
animation: play 2s ease infinite;
|
||||
-webkit-backface-visibility: hidden;
|
||||
-moz-backface-visibility: hidden;
|
||||
-ms-backface-visibility: hidden;
|
||||
backface-visibility: hidden;
|
||||
|
||||
}
|
||||
img {
|
||||
width: 135px;
|
||||
height: 135px;
|
||||
border-radius: 100%;
|
||||
position: absolute;
|
||||
left: 0px;
|
||||
top: 0px;
|
||||
}
|
||||
@keyframes play {
|
||||
|
||||
0% {
|
||||
transform: scale(1);
|
||||
}
|
||||
15% {
|
||||
box-shadow: 0 0 0 5px rgba(255, 255, 255, 0.4);
|
||||
}
|
||||
25% {
|
||||
box-shadow: 0 0 0 10px rgba(255, 255, 255, 0.4), 0 0 0 20px rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
25% {
|
||||
box-shadow: 0 0 0 15px rgba(255, 255, 255, 0.4), 0 0 0 30px rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { IncomingCallComponent } from './incoming-call.component';
|
||||
|
||||
describe('IncomingCallComponent', () => {
|
||||
let component: IncomingCallComponent;
|
||||
let fixture: ComponentFixture<IncomingCallComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ IncomingCallComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(IncomingCallComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,23 @@
|
||||
import { Component, OnInit, Inject } from '@angular/core';
|
||||
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
|
||||
|
||||
@Component({
|
||||
selector: 'app-incoming-call',
|
||||
templateUrl: './incoming-call.component.html',
|
||||
styleUrls: ['./incoming-call.component.scss']
|
||||
})
|
||||
export class IncomingCallComponent implements OnInit {
|
||||
|
||||
constructor(private dialogRef:MatDialogRef<IncomingCallComponent>, @Inject(MAT_DIALOG_DATA) public pd_info:any) {
|
||||
console.log(this.pd_info)
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
}
|
||||
closeDialog(){
|
||||
this.dialogRef.close('decline');
|
||||
}
|
||||
answer_call(){
|
||||
this.dialogRef.close('answered');
|
||||
}
|
||||
}
|
||||
80
ng6-seed/src/app/video-chat/video-chat.component.html
Normal file
80
ng6-seed/src/app/video-chat/video-chat.component.html
Normal file
@ -0,0 +1,80 @@
|
||||
<div fxLayout="column">
|
||||
<div align="end" style="float:right;padding: 10px !important;" fxLayoutAlign="flex-end">
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="reset"
|
||||
matTooltipPosition="right" (click)="clearRandomString()" *ngIf="!is_video_enable" >
|
||||
<mat-icon>cached</mat-icon>
|
||||
</button>
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close"
|
||||
matTooltipPosition="right" (click)="close_all()">
|
||||
<mat-icon>close</mat-icon>
|
||||
</button>
|
||||
|
||||
<!-- <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close"
|
||||
matTooltipPosition="right" (click)="stopRecording()">
|
||||
<mat-icon>stop</mat-icon>
|
||||
</button> -->
|
||||
</div>
|
||||
<!-- <mat-dialog-content> -->
|
||||
<!-- <div fxLayout="row"> -->
|
||||
<div [style.visibility] ="is_video_enable? 'visible' : 'hidden'" >
|
||||
<!-- <div class="my_video"> -->
|
||||
<video #myvideo id="myvideo" [style.visibility]="myVideoEnable? 'visible' : 'hidden'" muted></video>
|
||||
<!-- </div> -->
|
||||
<div class="peer_video" fxLayoutAlign="center" [ngStyle] = "{'height': !peerVideoEnable ? '5%': ''}">
|
||||
<video id="peervideo" #peervideo [style.visibility]="peerVideoEnable? 'visible' : 'hidden'"></video>
|
||||
</div>
|
||||
<!-- <input type="text" ><br/> -->
|
||||
<!-- {{peerVideoEnable}} -->
|
||||
<div class="peer_message" *ngIf="peerVideoEnable == false" fxLayoutAlign="center">
|
||||
<p style="text-align: center"> {{user_msg}} </p><br/>
|
||||
</div>
|
||||
<!-- <div class="input-group mb-3">
|
||||
<label>Paste the JSON String</label>
|
||||
<input type="text" class="form-control" [(ngModel)]="targetpeer" placeholder="JSON String" aria-label="Username" aria-describedby="basic-addon1">
|
||||
</div> -->
|
||||
<!-- <button type="button" class="btn btn-primary" (click)="connect()" >Connect</button> -->
|
||||
<!-- <button type="button" (click)="message()">Send Message</button> -->
|
||||
<div style="text-align: center;float:center" fxLayout="row" fxLayoutAlign="center" fxLayoutGap = "35px" >
|
||||
<!-- <button type="button" style="width: 90px" (click)="switch_camera()" class="btn btn-primary btn-lg" disabled #camera_switch>Switch</button> -->
|
||||
<!-- <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Switch Camera"
|
||||
matTooltipPosition="above" (click)="switch_camera()" disabled #camera_switch >
|
||||
<mat-icon>switch_camera</mat-icon>
|
||||
</button> -->
|
||||
<!-- <button type="button" style="width: 90px" (click)="start_Calling('init')" class="btn btn-primary btn-lg" *ngIf="!peerVideoEnable">Call</button><br/> -->
|
||||
<!-- <button type="button" style="width: 90px" (click)="start_Calling('notinit')" class="btn btn-primary btn-lg" *ngIf="!peerVideoEnable">Recieve</button><br/> -->
|
||||
<!-- <button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Disconnect"
|
||||
matTooltipPosition="above" *ngIf="peerVideoEnable"><mat-icon>call_end</mat-icon></button><br/> -->
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Video Off / On"
|
||||
matTooltipPosition="above" (click)="videoHandling()" *ngIf="peerVideoEnable">
|
||||
<mat-icon *ngIf="!video_mute">videocam_off</mat-icon>
|
||||
<mat-icon *ngIf="video_mute">videocam</mat-icon>
|
||||
</button>
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Mic Off / On"
|
||||
matTooltipPosition="above" (click)="micMuteHandling()" *ngIf="peerVideoEnable">
|
||||
<mat-icon *ngIf="!mic_mute">mic_off</mat-icon>
|
||||
<mat-icon *ngIf="mic_mute">mic</mat-icon>
|
||||
</button>
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Disconnect"
|
||||
matTooltipPosition="above" (click)="disconnect()" >
|
||||
<mat-icon>call_end</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div fxLayoutAlign="center center" *ngIf="!is_video_enable" >
|
||||
<div fxLayout="column" fxLayoutAlign="center center" style="position: absolute;bottom: 30%">
|
||||
<div fxLayout="row" *ngIf="start_btn_enable">
|
||||
<button mat-raised-button type="button" matTooltip="Start Video Chat" matTooltipPosition = "above" (click)="start_Calling('init')">
|
||||
<mat-icon>videocam</mat-icon>
|
||||
Start Video Chat
|
||||
</button>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
<!-- <div fxLayout="column"> -->
|
||||
<div class="note-label">
|
||||
<p>{{displayMsg}}</p>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
</div>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
<!-- </mat-dialog-content> -->
|
||||
79
ng6-seed/src/app/video-chat/video-chat.component.scss
Normal file
79
ng6-seed/src/app/video-chat/video-chat.component.scss
Normal file
@ -0,0 +1,79 @@
|
||||
::ng-deep { .video-chat > mat-dialog-container {
|
||||
background: #eee;
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@media(max-width:500px) {
|
||||
|
||||
video#myvideo {
|
||||
max-width: 32%;
|
||||
// min-width: 150px;
|
||||
position: absolute;
|
||||
border: 2px solid #9E9E9E;
|
||||
top:0;
|
||||
left: 0;
|
||||
// /* top: 20px;
|
||||
}
|
||||
.body-container {
|
||||
padding: 0px !important;
|
||||
}
|
||||
video#peervideo {
|
||||
/* height: 498px; */
|
||||
// position: relative;
|
||||
// margin-top: 126px;
|
||||
width: 100%;
|
||||
margin-top: 5%;
|
||||
|
||||
}
|
||||
|
||||
// .peer_message{
|
||||
// font-size: 20px;
|
||||
// position: absolute;
|
||||
// top: 11%;
|
||||
// bottom: 10%;
|
||||
// float: right;
|
||||
// padding: 57px;
|
||||
// /* border: 2px solid lavender; */
|
||||
// left: 8%;
|
||||
// p{
|
||||
// text-align: center;
|
||||
// }
|
||||
// }
|
||||
}
|
||||
@media(min-width:500px) {
|
||||
.peer_video{
|
||||
max-height: 80vh;
|
||||
}
|
||||
video#myvideo {
|
||||
max-width: 22%;
|
||||
// min-width: 150px;
|
||||
position: absolute;
|
||||
border: 2px solid #9E9E9E;
|
||||
top:0;
|
||||
left: 0;
|
||||
// max-width: 45%;
|
||||
// text-align: center;
|
||||
// margin-left:3%;
|
||||
// margin-top:1%;
|
||||
// min-width: 150px;
|
||||
// position: absolute;
|
||||
// border: 2px solid #9E9E9E;
|
||||
// /* top: 20px;
|
||||
}
|
||||
|
||||
video#peervideo {
|
||||
/* height: 498px; */
|
||||
max-width: 100%;
|
||||
text-align: center;
|
||||
margin-left:3%;
|
||||
margin-top:1%;
|
||||
// position: relative;
|
||||
// margin-top: 126px;
|
||||
// width: 100%;
|
||||
}
|
||||
}
|
||||
body{
|
||||
margin:10px !important;
|
||||
}
|
||||
25
ng6-seed/src/app/video-chat/video-chat.component.spec.ts
Normal file
25
ng6-seed/src/app/video-chat/video-chat.component.spec.ts
Normal file
@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { VideoChatComponent } from './video-chat.component';
|
||||
|
||||
describe('VideoChatComponent', () => {
|
||||
let component: VideoChatComponent;
|
||||
let fixture: ComponentFixture<VideoChatComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ VideoChatComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(VideoChatComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
600
ng6-seed/src/app/video-chat/video-chat.component.ts
Normal file
600
ng6-seed/src/app/video-chat/video-chat.component.ts
Normal file
@ -0,0 +1,600 @@
|
||||
import { Component, OnInit, ChangeDetectorRef, ViewChild, Inject, HostListener } from '@angular/core';
|
||||
import { Observable } from 'rxjs';
|
||||
import { PushNotifyService } from 'app/shared/push-notify.service';
|
||||
import { Socket } from 'ngx-socket-io';
|
||||
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
|
||||
import { PdTrigerService } from 'app/personal-discussion/pd-service/pd-triger.service';
|
||||
@Component({
|
||||
selector: 'app-video-chat',
|
||||
templateUrl: './video-chat.component.html',
|
||||
styleUrls: ['./video-chat.component.scss']
|
||||
})
|
||||
export class VideoChatComponent implements OnInit {
|
||||
MediaStream
|
||||
title = 'simple-peer-video-chat';
|
||||
peer:any;
|
||||
targetpeer: string;
|
||||
enableBtn: boolean;
|
||||
@ViewChild('myvideo') myVideo: any;
|
||||
@ViewChild('peervideo') peervideo: any;
|
||||
@ViewChild('camera_switch') camereSwitchBtn: any;
|
||||
// @ViewChild('textToCopy',{static:true}) textCopyElement: any;
|
||||
n = <any>navigator.mediaDevices;
|
||||
// public textToCopy:any;
|
||||
myVideoEnable: boolean = false;
|
||||
peerVideoEnable: boolean = false;
|
||||
shouldFaceUser: boolean = true;
|
||||
userCallType: any;
|
||||
is_video_enable:boolean = false;
|
||||
mic_mute: boolean = true;
|
||||
video_mute: boolean = true;
|
||||
user_msg: string;
|
||||
recorder: any;
|
||||
start_btn_enable:boolean = true
|
||||
displayMsg:string = "Note : Make sure the Reciever is waiting for your call before start Calling"
|
||||
arr_of_blobs: any = [];
|
||||
constructor(private _notificationService:PushNotifyService,
|
||||
private cdRef: ChangeDetectorRef,private socket: Socket,
|
||||
private dialogRef: MatDialogRef<VideoChatComponent>,
|
||||
@Inject(MAT_DIALOG_DATA) public chat_info:any,private pdTriggerService:PdTrigerService) {
|
||||
this._notificationService.requestPermission();
|
||||
// this.notify('Approval','This is First Alert -- By Debasis Saha')
|
||||
console.log("Version #8")
|
||||
}
|
||||
notify(title,approval) {
|
||||
let data: Array < any >= [];
|
||||
data.push({
|
||||
'title': title,
|
||||
'body': approval
|
||||
});
|
||||
this._notificationService.generateNotificationWithTitle(data);
|
||||
}
|
||||
// ngOnInit() {
|
||||
// setTimeout(()=>{
|
||||
// console.log("ngOninti")
|
||||
// this.peer = new SimplePeer({
|
||||
// initiator: location.hash === '#init',
|
||||
// trickle: false
|
||||
// })
|
||||
// console.log(this.peer)
|
||||
// this.peer.on('signal', function(data) {
|
||||
// console.log(JSON.stringify(data));
|
||||
|
||||
// this.targetpeer = data;
|
||||
// })
|
||||
// this.peer.on('error', err => console.log('error', err))
|
||||
// this.peer.on('data', function(data) {
|
||||
// console.log('Recieved message:' + data);
|
||||
// this.notify('notify',data)
|
||||
// })
|
||||
// this.peer.on('connect', () => {
|
||||
// console.log('CONNECT')
|
||||
// this.peer.send('whatever' + Math.random())
|
||||
// })
|
||||
// setTimeout(()=>{
|
||||
// console.log("updated")
|
||||
// this.enableBtn=true
|
||||
// this.notify('notify','enabled')
|
||||
// },1000)
|
||||
// },3000)
|
||||
// }
|
||||
|
||||
ngOnInit() {
|
||||
console.log(this.chat_info);
|
||||
if(this.chat_info) {
|
||||
if(this.chat_info.type == 'offer' && this.chat_info.hasOwnProperty('JSON_to_connect') && this.chat_info.JSON_to_connect) {
|
||||
this.is_video_enable = true;
|
||||
this.start_Calling('receive')
|
||||
}
|
||||
}
|
||||
// this.start_Calling('receive')
|
||||
}
|
||||
start_Calling(option) {
|
||||
this.user_msg ="Establishing Connection..."
|
||||
this.userCallType = option
|
||||
// let texk=this.textCopyElement.nativeElement
|
||||
let video = this.myVideo.nativeElement;
|
||||
let peerVideo = this.peervideo.nativeElement
|
||||
let peerx: any;
|
||||
let copyMessageText
|
||||
this.n.getUserMedia = (this.n.getUserMedia || this.n.webkitGetUserMedia || this.n.mozGetUserMedia || this.n.msGetUserMedia);
|
||||
if(this.n.getUserMedia == undefined || this.n.getUserMedia == null, this.n.getUserMedia == ''){
|
||||
alert("unable to get the camera access. please close the browser and come back again")
|
||||
}
|
||||
console.log(this.n)
|
||||
let defaultsOpts = { audio: true, video: {
|
||||
facingMode: this.shouldFaceUser ? 'user' : 'environment'
|
||||
}
|
||||
}
|
||||
this.n.getUserMedia(defaultsOpts).then(stream=> {
|
||||
this.socket.emit('NewClient')
|
||||
video.load();
|
||||
video.muted = true;
|
||||
this.fetchVideoAndPlay(stream,video);
|
||||
this.myVideoEnable = true
|
||||
this.MediaStream = stream
|
||||
this.is_video_enable = true;
|
||||
// let switchCameraBtn= this.camereSwitchBtn.nativeElement
|
||||
let supports = navigator.mediaDevices.getSupportedConstraints();
|
||||
console.log(supports)
|
||||
if( supports['facingMode'] === true ) {
|
||||
// switchCameraBtn.disabled = false;
|
||||
}
|
||||
console.log("entered",stream);
|
||||
peerx = new SimplePeer ({
|
||||
initiator: option === 'init',
|
||||
stream: stream,
|
||||
reconnectTimer: 1000,
|
||||
iceTransportPolicy: 'relay',
|
||||
trickle: false,
|
||||
config: {
|
||||
iceServers: [
|
||||
{
|
||||
"urls": "stun:numb.viagenie.ca",
|
||||
"username": 'fairoj@venbainfotech.com',
|
||||
"credential": '0987123400'
|
||||
},
|
||||
{
|
||||
"urls": "turn:numb.viagenie.ca",
|
||||
"username": "fairoj@venbainfotech.com",
|
||||
"credential": "0987123400"
|
||||
}
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
// function InitPeer(type) {
|
||||
peerx.on('signal',(data)=> {
|
||||
|
||||
console.log(JSON.stringify(data));
|
||||
if(data.hasOwnProperty('type') && data.type == 'offer'){
|
||||
console.log("entered!!!!!!!!!!!!!!!!1");
|
||||
this.user_msg = "Calling..."
|
||||
let event_data = {JSON_to_connect:data,type:'offer',random_string:this.chat_info.random_string,user_type:"officer"}
|
||||
this.socket.emit('Offer', event_data)
|
||||
}
|
||||
else if(data.type == 'answer' ){
|
||||
this.user_msg = "Waiting For Connection..."
|
||||
let event_data = {JSON_to_connect:data,type:'answer',random_string:this.chat_info.random_string,user_type:"officer"}
|
||||
this.socket.emit('Answer', event_data)
|
||||
}
|
||||
// copyMessage(JSON.stringify(data))
|
||||
copyMessageText = JSON.stringify(data);
|
||||
// update()
|
||||
// this.copyMessage(copyMessageText,data.type)
|
||||
// this.targetpeer = data;
|
||||
})
|
||||
// }
|
||||
peerx.on('data', function(data) {
|
||||
console.log('Recieved message:' + data);
|
||||
})
|
||||
peerx.on('close', (data) => {
|
||||
console.log("Peer Connection is closed ",data);
|
||||
this.disconnect();
|
||||
// alert("Peer Connection is closed " +JSON.stringify(data))
|
||||
this.notify("Connection Closed",'Peer Connection Closed')
|
||||
})
|
||||
peerx.on('error', (err) => {
|
||||
console.log("Fatal Error ",err);
|
||||
this.disconnect();
|
||||
alert("Fatal Error" +JSON.stringify(err))
|
||||
})
|
||||
peerx.on('stream', (stream)=> {
|
||||
console.log("@##################33",stream)
|
||||
if ('srcObject' in peerVideo) {
|
||||
peerVideo.srcObject = stream
|
||||
} else {
|
||||
peerVideo.src = window.URL.createObjectURL(stream) // for older browsers
|
||||
}
|
||||
// video.play();
|
||||
|
||||
// console.log(this.peerVideoEnable);
|
||||
peerVideo.load();
|
||||
this. fetchVideoAndPlay(stream,peerVideo,true);
|
||||
// setTimeout(()=>{
|
||||
// // this.peerVideoEnable = true;
|
||||
// // console.log(this.peerVideoEnable)
|
||||
// },2000)
|
||||
// CreateVideo(stream)
|
||||
})
|
||||
// fetchVideoAndPlay(stream,videotype) {
|
||||
// fetch('')
|
||||
// .then(response => response.blob())
|
||||
// .then(blob => {
|
||||
// videotype.srcObject = stream;
|
||||
// return videotype.play();
|
||||
// })
|
||||
// .then(_ => {
|
||||
// // Video playback started ;)
|
||||
// })
|
||||
// .catch(e => {
|
||||
// // Video playback failed ;(
|
||||
// })
|
||||
// }
|
||||
|
||||
// function CreateVideo(stream) {
|
||||
// // CreateDiv()
|
||||
|
||||
// let video = document.createElement('video')
|
||||
// video.id = 'peerVideo'
|
||||
// video.srcObject = stream
|
||||
// video.setAttribute('class', 'embed-responsive-item')
|
||||
// document.querySelector('#peervideo').appendChild(video)
|
||||
// video.play()
|
||||
// //wait for 1 sec
|
||||
// }
|
||||
function connectPeer(answer) {
|
||||
console.log("$$$$$$$$$$$$$$44");
|
||||
console.log(answer);
|
||||
setTimeout(()=>{
|
||||
peerx.signal(answer.JSON_to_connect);
|
||||
},1000)
|
||||
}
|
||||
// function getPeer(){
|
||||
// return JSON.stringify(copyMessageText)
|
||||
// }
|
||||
// if(JSON.parse(copyMessageText).hasOwnProperty('type') && JSON.parse(copyMessageText).type == 'offer')
|
||||
// {
|
||||
// setTimeout(()=>{
|
||||
// this.socket.on('BackOffer', getPeer)
|
||||
// },2000)
|
||||
// }
|
||||
if(this.chat_info.type == 'offer' && this.chat_info.JSON_to_connect && this.chat_info.JSON_to_connect != undefined) {
|
||||
connectPeer(this.chat_info)
|
||||
}
|
||||
// let tt = this.socket.on('BackOffer', connectPeer)
|
||||
// console.log(tt);
|
||||
this.socket.on('BackAnswer', connectPeer)
|
||||
}, err=>{
|
||||
console.log('Failed to get stream', err);
|
||||
alert('Failed to get stream '+err);
|
||||
});
|
||||
this.socket.on('callStatusMessage',this.updateTheMsg)
|
||||
this.socket.fromEvent('callStatusMessage').subscribe(res=>{
|
||||
if(res) {
|
||||
this.updateTheMsg(res)
|
||||
}
|
||||
})
|
||||
// function update(){
|
||||
// console.log(copyMessageText)
|
||||
// setTimeout(()=>{
|
||||
// // texk.value = copyMessageText
|
||||
// },2000)
|
||||
// }
|
||||
setTimeout(() => {
|
||||
this.peer = peerx;
|
||||
|
||||
// this.copyMessage(JSON.stringify(this.targetpeer))
|
||||
console.log(this.peer);
|
||||
// console.log(copyMessageText)
|
||||
// this.targetpeer = copyMessageText
|
||||
// this.textToCopy = copyMessageText
|
||||
// this.copyMessage(copyMessageText)
|
||||
}, 5000);
|
||||
|
||||
// socket.on('SessionActive', SessionActive)
|
||||
// socket.on('CreatePeer', MakePeer)
|
||||
// socket.on('Disconnect', RemovePeer)
|
||||
}
|
||||
updateTheMsg(msg_obj) {
|
||||
console.log("CallstatusMsg",msg_obj)
|
||||
if(msg_obj && msg_obj.status_code == 2){
|
||||
console.log("entered");
|
||||
this.start_btn_enable = false
|
||||
this.displayMsg = msg_obj.msg
|
||||
// this.cdRef.detectChanges();
|
||||
this.disconnect();
|
||||
|
||||
}
|
||||
}
|
||||
fetchVideoAndPlay(stream,videotype,enablePeerVideo?) {
|
||||
console.log("12@@@@@@@@@2",enablePeerVideo)
|
||||
|
||||
fetch('')
|
||||
.then(response => response.blob())
|
||||
.then(blob => {
|
||||
videotype.srcObject = stream;
|
||||
return videotype.play();
|
||||
})
|
||||
.then(_ => {
|
||||
// Video playback started ;)
|
||||
if(enablePeerVideo) {
|
||||
if(this.peervideo.nativeElement.videoHeight >= 500) {
|
||||
this.peervideo.nativeElement.style.marginTop = '0px'
|
||||
}
|
||||
this.peerVideoEnable = enablePeerVideo
|
||||
this.socket.emit('callStatus',{random_string:this.chat_info.random_string,status:'connected',status_code:1})
|
||||
// this.camereSwitchBtn.nativeElement.disabled = true;
|
||||
console.log("peervideo check",this.peerVideoEnable,this.peervideo.nativeElement.videoWidth,this.peervideo.nativeElement.videoHeight);
|
||||
this.cdRef.detectChanges();
|
||||
this.startRecording(stream)
|
||||
// this.addVideoToRecorder(stream)
|
||||
// this.addVideoToRecorder(this.MediaStream)
|
||||
}
|
||||
})
|
||||
.catch(e => {
|
||||
// Video playback failed ;(
|
||||
})
|
||||
}
|
||||
async startRecording(stream) {
|
||||
// console.log("start",stream,this.peervideo)
|
||||
this.recorder = []
|
||||
this.recorder = new RecordRTCPromisesHandler(stream, {
|
||||
type: 'video',
|
||||
mimeType: 'video/webm\;codecs=vp9', // or video/webm\;codecs=h264 or video/webm\;codecs=vp9
|
||||
// timeSlice: 10000,
|
||||
// ondataavailable: (blob=> { this.sendPartVideo(blob) }),
|
||||
audioBitsPerSecond: 128000,
|
||||
videoBitsPerSecond: 128000,
|
||||
bitsPerSecond: 128000 // if this line is provided, skip above
|
||||
});
|
||||
this.recorder.startRecording();
|
||||
// const sleep = m => new Promise(r => setTimeout(r, m));
|
||||
// await sleep(3000);
|
||||
setTimeout(()=>{
|
||||
this.stopRecording(true);
|
||||
},120000);
|
||||
// var file = new File([blob], 'video.mp4', {
|
||||
// type: 'video/mp4'
|
||||
// });
|
||||
// console.log(file)
|
||||
// const fileURL = window.URL.createObjectURL(file);
|
||||
// window.open(fileURL);
|
||||
// videotype.srcObject = null;
|
||||
// videotype.muted = false;
|
||||
// videotype.volume = 1;
|
||||
// videotype.srcObject = file;
|
||||
|
||||
|
||||
// recorder.camera.stop();
|
||||
// recorder.destroy();
|
||||
// recorder = null;
|
||||
// let recorder = RecordRTC(stream, {
|
||||
// type: 'video'
|
||||
// });
|
||||
// recorder.startRecording();
|
||||
|
||||
// const sleep = m => new Promise(r => setTimeout(r, m));
|
||||
// sleep(10000);
|
||||
|
||||
// recorder.stopRecording(function() {
|
||||
// let blob = recorder.getBlob();
|
||||
// // invokeSaveAsDialog(blob);
|
||||
// console.log(blob);
|
||||
// });
|
||||
|
||||
// blob.then(resul=>{
|
||||
// console.log(resul);
|
||||
// })
|
||||
// const fileURL = window.URL.createObjectURL(blob);
|
||||
// console.log(fileURL);
|
||||
// window.open(fileURL);
|
||||
// invokeSaveAsDialog(blob);
|
||||
}
|
||||
// sendPartVideo(blob){
|
||||
// this.arr_of_blobs.push(blob);
|
||||
// console.log("Blob",blob,JSON.stringify(blob));
|
||||
// var file = new File([blob], 'video.mp4', {
|
||||
// type: 'video/mp4'
|
||||
// });
|
||||
// console.log(file,JSON.stringify(file));
|
||||
// let formData = new FormData();
|
||||
// formData.append('video', blob);
|
||||
// const fileURL1 = window.URL.createObjectURL(blob);
|
||||
// console.log('video'+this.arr_of_blobs.length+'.mp4',fileURL1);
|
||||
// formData.append('filename','video'+this.arr_of_blobs.length+'.mp4');
|
||||
// formData.append('random_string',this.chat_info.random_string);
|
||||
// console.log(formData);
|
||||
// this.pdTriggerService.saveVideo(formData).subscribe(result=>{
|
||||
// console.log(result);
|
||||
// })
|
||||
// }
|
||||
async stopRecording(autostarRec?) {
|
||||
await this.recorder.stopRecording();
|
||||
// console.log(this.recorder);
|
||||
let blob = await this.recorder.getBlob();
|
||||
if(autostarRec) {
|
||||
await this.startRecording(this.peervideo.nativeElement.srcObject)
|
||||
}
|
||||
// setTimeout(()=>{
|
||||
console.log(typeof(blob),blob);
|
||||
console.log(RecordRTC,RecordRTCPromisesHandler)
|
||||
await RecordRTC.getSeekableBlob(blob, seekableBlob=> {
|
||||
console.log(seekableBlob)
|
||||
const fileURL = window.URL.createObjectURL(seekableBlob);
|
||||
console.log("seekable file",fileURL)
|
||||
this.arr_of_blobs.push(seekableBlob)
|
||||
console.log("----------------------------")
|
||||
console.log("video "+this.arr_of_blobs.length, fileURL)
|
||||
console.log("----------------------------")
|
||||
this.sendVideoToServer(seekableBlob)
|
||||
})
|
||||
|
||||
// var file = new File([blob], 'video.mp4', {
|
||||
// type: 'video/mp4'
|
||||
// });
|
||||
// const fileURL = window.URL.createObjectURL(blob);
|
||||
// this.arr_of_blobs.push(blob)
|
||||
// console.log("----------------------------")
|
||||
// console.log("video "+this.arr_of_blobs.length, fileURL)
|
||||
// console.log("----------------------------")
|
||||
if(!autostarRec) {
|
||||
let mergedVideos=this.arr_of_blobs.reduce((a, b)=> new Blob([a, b], {type: "video/webm"}));
|
||||
console.log("merged",mergedVideos,this.arr_of_blobs);
|
||||
const fileURL1 = window.URL.createObjectURL(mergedVideos);
|
||||
// localStorage.setItem('blob_url',fileURL1)
|
||||
console.log("File url 11111",fileURL1)
|
||||
window.open(fileURL1)
|
||||
}
|
||||
|
||||
// let formData= new FormData();
|
||||
// formData.append('videoFile',file);
|
||||
// console.log(formData);
|
||||
// alert("saved Recording will be opened in a new window");
|
||||
// window.open(fileURL);
|
||||
// },3000);
|
||||
// this.recorder.getDataURL().then(dataURL=>{
|
||||
// console.log("@@@@@",dataURL)
|
||||
|
||||
// })
|
||||
}
|
||||
sendVideoToServer(blob) {
|
||||
let formData = new FormData();
|
||||
formData.append('video_file', blob);
|
||||
let params = {
|
||||
filename:'video'+this.arr_of_blobs.length+'.mp4',
|
||||
random_string:this.chat_info.random_string,
|
||||
pd_id:this.chat_info.pd_id
|
||||
}
|
||||
formData.append('records',JSON.stringify(params))
|
||||
// formData.append('filename','video'+this.arr_of_blobs.length+'.mp4');
|
||||
// formData.append('random_string',this.chat_info.random_string);
|
||||
// formData.append('pd_id',this.chat_info.pd_id);
|
||||
this.pdTriggerService.saveCusVideo(formData).subscribe(result=>{
|
||||
console.log(result);
|
||||
})
|
||||
}
|
||||
connect() {
|
||||
this.peer.signal(JSON.parse(this.targetpeer));
|
||||
}
|
||||
RemovePeer() {
|
||||
document.getElementById("peerVideo").remove();
|
||||
// document.getElementById("muteText").remove();
|
||||
// if (client.peer) {
|
||||
// client.peer.destroy()
|
||||
// }
|
||||
}
|
||||
|
||||
message() {
|
||||
this.peer.send('Hello world');
|
||||
}
|
||||
disconnect() {
|
||||
console.log(this.peer)
|
||||
if(this.peer) {
|
||||
this.peer.destroy();
|
||||
this.peerVideoEnable = false
|
||||
this.targetpeer = ''
|
||||
this.peer = ''
|
||||
// this.cdRef.detectChanges();
|
||||
this.socket.emit('callStatus',{random_string:this.chat_info.random_string,status:'disconnected',status_code:0})
|
||||
this.peervideo.nativeElement.pause();
|
||||
this.stopRecording().then(res=>{
|
||||
|
||||
})
|
||||
// this.stopAndGetSingleBlob(function(blob) {
|
||||
// var url = URL.createObjectURL(blob);
|
||||
// // previewVideo.src = url;
|
||||
// console.log(blob,url);
|
||||
// // or
|
||||
// window.open(url);
|
||||
|
||||
// // or
|
||||
// // invokeSaveAsDialog(blob);
|
||||
// });
|
||||
}
|
||||
console.log(this.MediaStream.getTracks())
|
||||
// this.MediaStream.stop()
|
||||
// var track = this.MediaStream.getTracks()[0]; // if only one media track
|
||||
// ...
|
||||
// track.stop();
|
||||
this.MediaStream.getTracks().forEach(function(track) {
|
||||
track.stop();
|
||||
});
|
||||
console.log(this.peervideo);
|
||||
// this.peervideo.nativeElement.videoWidth = 0
|
||||
// this.peervideo.nativeElement.videoHeight = 0
|
||||
this.myVideo.nativeElement.pause();
|
||||
this.is_video_enable = false
|
||||
this.cdRef.detectChanges();
|
||||
console.log(this.peer)
|
||||
}
|
||||
copyMessage(val: string,message?){
|
||||
const selBox = document.createElement('textarea');
|
||||
selBox.style.position = 'fixed';
|
||||
selBox.style.left = '0';
|
||||
selBox.style.top = '0';
|
||||
selBox.style.opacity = '0';
|
||||
selBox.value = val;
|
||||
document.body.appendChild(selBox);
|
||||
selBox.focus();
|
||||
selBox.select();
|
||||
document.execCommand('copy');
|
||||
document.body.removeChild(selBox);
|
||||
// alert(message+ " JSON is copied to clipboard. Paste the JSON to another window")
|
||||
this.notify("JSON copied to clipboard",message+ ' JSON');
|
||||
}
|
||||
switch_camera() {
|
||||
this.shouldFaceUser = !this.shouldFaceUser;
|
||||
console.log(this.userCallType);
|
||||
this.peer.destroy();
|
||||
this.start_Calling(this.userCallType)
|
||||
}
|
||||
close_all() {
|
||||
if(this.peer) {
|
||||
this.disconnect();
|
||||
}
|
||||
if(this.MediaStream && this.MediaStream.active) {
|
||||
console.log(this.MediaStream.getTracks())
|
||||
// this.MediaStream.stop()
|
||||
// var track = this.MediaStream.getTracks()[0]; // if only one media track
|
||||
// ...
|
||||
// track.stop();
|
||||
this.MediaStream.getTracks().forEach(function(track) {
|
||||
track.stop();
|
||||
});
|
||||
}
|
||||
this.dialogRef.close();
|
||||
}
|
||||
micMuteHandling(){
|
||||
this.mic_mute = !this.mic_mute
|
||||
this.cdRef.detectChanges();
|
||||
this.MediaStream.getAudioTracks()[0].enabled = this.mic_mute;
|
||||
}
|
||||
videoHandling(){
|
||||
this.video_mute = !this.video_mute
|
||||
this.cdRef.detectChanges();
|
||||
this.MediaStream.getVideoTracks()[0].enabled = this.video_mute;
|
||||
}
|
||||
clearRandomString() {
|
||||
if(this.peer) {
|
||||
this.disconnect() }
|
||||
else{
|
||||
this.socket.emit('callStatus',{random_string:this.chat_info.random_string,status:'disconnected',status_code:0})
|
||||
}
|
||||
}
|
||||
|
||||
@HostListener('window:beforeunload', ['$event'])
|
||||
unloadHandler(event) {
|
||||
console.log("unload caled",event);
|
||||
if(this.peerVideoEnable) {
|
||||
this.disconnect();
|
||||
}
|
||||
}
|
||||
// RECORDING MULTIPLE VIDEOS
|
||||
|
||||
// addVideoToRecorder(stream) {
|
||||
// // var stream = video.captureStream();
|
||||
|
||||
// if (!this.recorder) {
|
||||
// this.recorder = RecordRTC([stream], {
|
||||
// type: 'video'
|
||||
// });
|
||||
// this.recorder.startRecording();
|
||||
// } else {
|
||||
// this.recorder.getInternalRecorder().addStreams([stream]);
|
||||
// }
|
||||
// }
|
||||
|
||||
// async stopAndGetSingleBlob(callback) {
|
||||
// if (!this.recorder) return;
|
||||
// await this.recorder.stopRecording(()=> {
|
||||
// // setTimeout(()=>{
|
||||
// callback(this.recorder.getBlob());
|
||||
// setTimeout(()=>{
|
||||
// console.log(this.recorder.getBlob());
|
||||
// },3000)
|
||||
// // })
|
||||
// this.recorder = null;
|
||||
// });
|
||||
// }
|
||||
}
|
||||
@ -0,0 +1,22 @@
|
||||
<div align="end" style="position: absolute;right: 10%;z-index: 999" fxLayoutAlign="flex-end">
|
||||
<!-- <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="reset"
|
||||
matTooltipPosition="right" (click)="clearRandomString()" *ngIf="!is_video_enable" >
|
||||
<mat-icon>cached</mat-icon>
|
||||
</button> -->
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close"
|
||||
matTooltipPosition="right" mat-dialog-close>
|
||||
<mat-icon>close</mat-icon>
|
||||
</button>
|
||||
|
||||
<!-- <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close"
|
||||
matTooltipPosition="right" (click)="stopRecording()">
|
||||
<mat-icon>stop</mat-icon>
|
||||
</button> -->
|
||||
</div>
|
||||
<!-- <mat-video src="http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4"></mat-video> -->
|
||||
<mat-video title="Recorded Video" [autoplay]="true" [preload]="true" [fullscreen]="true" [download]="false" color="primary" spinner="spin" poster="../../assets/images/img/video-icon.png">
|
||||
<source matVideoSource [src]="videoSrc" type="video/webm">
|
||||
<!-- <source src="tutorial.webm" type="video/webm"> -->
|
||||
<!-- <track matVideoTrack src="subtitles_en.vtt" kind="subtitles" srclang="en" label="English"> -->
|
||||
<!-- <track src="subtitles_no.vtt" kind="subtitles" srclang="no" label="Norwegian"> -->
|
||||
</mat-video>
|
||||
@ -0,0 +1,9 @@
|
||||
::ng-deep { .video-player > mat-dialog-container {
|
||||
background: rgba(255, 0, 0, 0.705);
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
.mat-raised-button{
|
||||
color: #ffffff;
|
||||
background: #ffffff5c;
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { VideoPlayerComponent } from './video-player.component';
|
||||
|
||||
describe('VideoPlayerComponent', () => {
|
||||
let component: VideoPlayerComponent;
|
||||
let fixture: ComponentFixture<VideoPlayerComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ VideoPlayerComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(VideoPlayerComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,29 @@
|
||||
import { Component, OnInit, Inject } from '@angular/core';
|
||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material';
|
||||
|
||||
@Component({
|
||||
selector: 'app-video-player',
|
||||
templateUrl: './video-player.component.html',
|
||||
styleUrls: ['./video-player.component.scss']
|
||||
})
|
||||
export class VideoPlayerComponent implements OnInit {
|
||||
videoSrc
|
||||
// = 'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4'
|
||||
// = 'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ForBiggerFun.mp4'
|
||||
constructor( @Inject(MAT_DIALOG_DATA) public data:any,private matDialogRef:MatDialogRef<VideoPlayerComponent>) {
|
||||
if(data) {
|
||||
if(data.hasOwnProperty('videoUrl') && data.videoUrl && data.videoUrl != null) {
|
||||
this.videoSrc = data.videoUrl
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
let video_blob = localStorage.getItem('blob_url');
|
||||
if(video_blob) {
|
||||
// this.videoSrc = video_blob;
|
||||
console.log(this.videoSrc);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
BIN
ng6-seed/src/assets/images/img/video-icon.png
Normal file
BIN
ng6-seed/src/assets/images/img/video-icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 22 KiB |
BIN
ng6-seed/src/assets/spinner/notfound.jpg
Normal file
BIN
ng6-seed/src/assets/spinner/notfound.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 68 KiB |
BIN
ng6-seed/src/assets/spinner/notfound2.jpg
Normal file
BIN
ng6-seed/src/assets/spinner/notfound2.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 75 KiB |
BIN
ng6-seed/src/assets/spinner/notfound_blue.png
Normal file
BIN
ng6-seed/src/assets/spinner/notfound_blue.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 23 KiB |
BIN
ng6-seed/src/assets/spinner/notify.mp3
Normal file
BIN
ng6-seed/src/assets/spinner/notify.mp3
Normal file
Binary file not shown.
@ -4,6 +4,7 @@ export const environment = {
|
||||
environmentName: 'Production Environment',//Live Environment.
|
||||
|
||||
apiEndpoint: 'https://api.pdgenie.com/sparqprod/api/',
|
||||
socketServerUrl:'https://morning-garden-90282.herokuapp.com',
|
||||
|
||||
authorization: 'TnAwuc64pVpcB9xf',
|
||||
login_string: "cognito-idp.ap-south-1.amazonaws.com/ap-south-1_MlTee1O5V",
|
||||
|
||||
@ -4,6 +4,7 @@ export const environment = {
|
||||
environmentName: 'Testing Environment',//Test Environment.
|
||||
|
||||
apiEndpoint: 'https://apitest.pdgenie.com/sparqtest/api/',
|
||||
socketServerUrl:'https://morning-garden-90282.herokuapp.com',
|
||||
|
||||
authorization: 'sparqvenba2018',
|
||||
login_string: "cognito-idp.ap-south-1.amazonaws.com/ap-south-1_qQ85yQZJO",
|
||||
|
||||
@ -14,6 +14,7 @@ export const environment = {
|
||||
// apiEndpoint: 'https://demo.pdgenie.com/sparqapi/api/',
|
||||
apiEndpoint:'https://apitest.pdgenie.com/sparqtest/api/',
|
||||
// apiEndpoint:'http://localhost/sineEdge/sparqapi/api/',
|
||||
socketServerUrl:'https://morning-garden-90282.herokuapp.com',
|
||||
|
||||
authorization: 'sparqvenba2018',
|
||||
|
||||
|
||||
@ -9,6 +9,11 @@
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="manifest" href="/manifest.json">
|
||||
<!-- For Video chat -->
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/simple-peer/9.7.0/simplepeer.min.js"></script>
|
||||
<!-- <script src="node_modules/recordrtc/RecordRTC.js"></script> -->
|
||||
<script src="https://www.WebRTC-Experiment.com/RecordRTC.js"></script>
|
||||
<script src="https://www.webrtc-experiment.com/EBML.js"></script>
|
||||
<!-- <title>Optima - Angular 6 Material Admin Template</title> -->
|
||||
<title> PD Genie </title>
|
||||
|
||||
|
||||
5
ng6-seed/src/typings.d.ts
vendored
5
ng6-seed/src/typings.d.ts
vendored
@ -6,4 +6,7 @@ interface NodeModule {
|
||||
declare module 'quill';
|
||||
declare module 'leaflet';
|
||||
declare module 'perfect-scrollbar';
|
||||
declare module 'screenfull';
|
||||
declare module 'screenfull';
|
||||
declare var SimplePeer: any;
|
||||
declare var RecordRTCPromisesHandler:any;
|
||||
declare var RecordRTC:any;
|
||||
Loading…
Reference in New Issue
Block a user