diff --git a/ng6-seed/package-lock.json b/ng6-seed/package-lock.json
index 0b81ab213..ed7e8f852 100644
--- a/ng6-seed/package-lock.json
+++ b/ng6-seed/package-lock.json
@@ -4294,12 +4294,14 @@
"balanced-match": {
"version": "1.0.0",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"brace-expansion": {
"version": "1.1.11",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@@ -4314,17 +4316,20 @@
"code-point-at": {
"version": "1.1.0",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"concat-map": {
"version": "0.0.1",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"console-control-strings": {
"version": "1.1.0",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"core-util-is": {
"version": "1.0.2",
@@ -4441,7 +4446,8 @@
"inherits": {
"version": "2.0.3",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"ini": {
"version": "1.3.5",
@@ -4453,6 +4459,7 @@
"version": "1.0.0",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"number-is-nan": "^1.0.0"
}
@@ -4467,6 +4474,7 @@
"version": "3.0.4",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"brace-expansion": "^1.1.7"
}
@@ -4474,12 +4482,14 @@
"minimist": {
"version": "0.0.8",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"minipass": {
"version": "2.2.4",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"safe-buffer": "^5.1.1",
"yallist": "^3.0.0"
@@ -4498,6 +4508,7 @@
"version": "0.5.1",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"minimist": "0.0.8"
}
@@ -4578,7 +4589,8 @@
"number-is-nan": {
"version": "1.0.1",
"bundled": true,
- "dev": true
+ "dev": true,
+ "optional": true
},
"object-assign": {
"version": "4.1.1",
@@ -4590,6 +4602,7 @@
"version": "1.4.0",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"wrappy": "1"
}
@@ -4711,6 +4724,7 @@
"version": "1.0.2",
"bundled": true,
"dev": true,
+ "optional": true,
"requires": {
"code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0",
diff --git a/ng6-seed/src/app/dashboard/dashboard.component.html b/ng6-seed/src/app/dashboard/dashboard.component.html
index 058c6c795..af25828e4 100644
--- a/ng6-seed/src/app/dashboard/dashboard.component.html
+++ b/ng6-seed/src/app/dashboard/dashboard.component.html
@@ -1,108 +1,101 @@
-
-
-
-
-
-
-
- {{dashboardTitle}}
-
-
-
-
-
-
-
-
-
-
- {{myControl.value ? myControl.value[0].name : ''}}
- 1" >
- (+{{myControl.value.length - 1}} {{myControl.value?.length === 2 ? 'other' : 'others'}})
-
-
- {{ cd.name }} / {{cd.state_name}}
-
-
-
-
-
-
+
+
+
+
+
+ {{dashboardTitle}}
-
-
-
- {{myControl2.value ? myControl2.value[0].short_name : ''}}
- 1" >
- (+{{myControl2.value.length - 1}} {{myControl2.value?.length === 2 ? 'other' : 'others'}})
-
-
-
- {{ ld.full_name }} ({{ ld.short_name }})
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+ {{myControl.value != null && myControl.value != '' ? myControl.value[0].name : ''}}
+ 1" >
+ (+{{myControl.value.length - 1}} {{myControl.value?.length === 2 ? 'other' : 'others'}})
+
+
+ {{ cd.name }} / {{cd.state_name}}
+
+
+
-
-
-
-
-
-
-
-
- - Draft
- - Triggered
- - Allocated
- - Scheduled
- - InProgress
- - Completed
- - QC Completed
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+ {{myControl2.value != null && myControl2.value != '' ? myControl2.value[0].short_name : ''}}
+ 1" >
+ (+{{myControl2.value.length - 1}} {{myControl2.value?.length === 2 ? 'other' : 'others'}})
+
+
+
+ {{ ld.full_name }} ({{ ld.short_name }})
+
+
+
+
+
+
+
+
+
+
+
+
+ - Draft
+ - Triggered
+ - Allocated
+ - Scheduled
+ - InProgress
+ - Completed
+ - QC Completed
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/ng6-seed/src/app/dashboard/dashboard.component.scss b/ng6-seed/src/app/dashboard/dashboard.component.scss
index 69e8f2f0f..28e26b986 100644
--- a/ng6-seed/src/app/dashboard/dashboard.component.scss
+++ b/ng6-seed/src/app/dashboard/dashboard.component.scss
@@ -5,34 +5,17 @@ $p: 12px;
mat-card-title{
background-color:#E00201 !important;
color:#fff;
- //padding-bottom: 1rem;
- //margin-bottom: 0px;
}
.mat-input-wrapper {
background: #fff;
}
-// .example-form {
-// min-width: 150px;
-// max-width: 500px;
-// width: 95%;
-// }
+
li
{
- display:block;
- float:left;
+ display:inline-block;
+ //float:left;
}
-
-//::ng-deep {
- // .mat-form-field-appearance-outline .mat-form-field-outline {
- // color: white;
- //}
- //mat-form-field {
- // .mat-hint, input, ::placeholder, .mat-form-field-label {
- // color: white;
- //}
- //}
- //}
-
+
.example-full-width {
width: 95%;
}
@@ -47,25 +30,23 @@ li
color: #fff;
}
-.lengend-list {
- list-style-type: none;
- margin: 0;
- padding: 0;
- overflow: hidden;
- text-align:justify;
-}
+//.lengend-list {
+ // list-style-type: none;
+ //margin: 0;
+ // padding: 0;
+ // overflow: hidden;
+ // text-align:justify;
+//}
.lengend-element {
- font-size: 1rem;
+ font-size: 1rem !important;
padding-right: 3%;
}
.donut-inner{
margin-top: -171px;
margin-left: 120px;
- //margin-bottom: 154px;
- //margin-top: -221px;
- //margin-left: 145px;
+
}
.donut-inner h5 {
@@ -77,545 +58,10 @@ li
font-size:1rems;
}
-// .profile {
-// position: relative;
-// width: 100%;
-// height: 100%;
-// background: rgba(white, .25);
-// border-radius: 2px;
-// overflow: hidden;
-// box-shadow: 0 0 20px rgba(darken($red, 40%), .2);
-// &.pre-enter {
-// transform-origin: center center;
-// transform: scaleY(0);
-// .avatar {
-// transform-origin: center top;
-// transform: scaleY(0);
-// }
-// h1,
-// h2,
-// a.follow,
-// a.link {
-// opacity: 0;
-// transform: translateY(300px);
-// }
-// }
-// &.on-enter {
-// animation: scaleYIn 1000ms ease-out forwards;
-// .avatar {
-// animation: scaleYIn-small 750ms ease-out forwards 1000ms;
-// }
-// h1,
-// h2,
-// a.follow,
-// a.link {
-// opacity: 1;
-// animation: slideInUp 1000ms ease-out forwards;
-// }
-// h1 {
-// animation-delay: 1050ms;
-// }
-// h2 {
-// animation-delay: 1100ms;
-// }
-// a.follow {
-// animation-delay: 1250ms;
-// }
-// li {
-// &:nth-child(1) {
-// a.link {
-// animation-delay: 1300ms;
-// }
-// }
-// &:nth-child(2) {
-// a.link {
-// animation-delay: 1350ms;
-// }
-// }
-// &:nth-child(3) {
-// a.link {
-// animation-delay: 1400ms;
-// }
-// }
-// }
-// }
-// }
-
-// .background {
-// position: absolute;
-// top: 0;
-// left: 0;
-// width: 100%;
-// height: 100%;
-// background: white;
-// border-radius: 2px;
-// }
-
-// .avatar,
-// .info {
-// width: 100%;
-// height: 50%;
-// }
-
-// .avatar {
-// background: url('../../assets/images/1.jpg') no-repeat center center / cover;
-// clip-path: polygon(0 0, 100% 0, 100% 75%, 0% 100%);
-// }
-
-// .prof-list {
-// li {
-// display: inline-block;
-// list-style: none;
-// }
-// }
-
-// .info {
-// display: flex;
-// flex-flow: row wrap;
-// align-items: center;
-// align-content: center;
-// justify-content: center;
-// position: relative;
-// text-align: center;
-// h1 {
-// padding: $p $p 0;
-// width: 100%;
-// font-size: 24px;
-// font-weight: 800;
-// letter-spacing: 2px;
-// text-transform: uppercase;
-// }
-// h2,
-// a.follow {
-// display: block;
-
-// border-radius: 2px;
-// padding: $p/2;
-// color: white;
-// font-size: 12px;
-// font-weight: 500;
-// letter-spacing: 1px;
-// text-transform: uppercase;
-// }
-// h2 {
-// background: $red;
-// background: linear-gradient(135deg, rgba(#f5825f, 1) 0%, rgba(#f5005f, 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f5825f', endColorstr='#f5005f', GradientType=1);
-// }
-// a.follow {
-// margin-left: $p;
-// background: $blue;
-// background: linear-gradient(135deg, rgba(#05c8e0, 1) 0%, rgba(#057fe0, 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#05c8e0', endColorstr='#057fe0', GradientType=1);
-// &:hover,
-// &:focus {
-// background: #05c8e0;
-// background: linear-gradient(135deg, rgba(lighten(#05c8e0, 10%), 1) 0%, rgba(lighten(#057fe0, 10%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='lighten(#05c8e0, 10%)', endColorstr='lighten(#057fe0, 10%)', GradientType=1);
-// }
-// &:active {
-// background: #057fe0;
-// background: linear-gradient(135deg, rgba(darken(#05c8e0, 5%), 1) 0%, rgba(darken(#057fe0, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='darken(#05c8e0, 5%)', endColorstr='darken(#057fe0, 5%)', GradientType=1);
-// }
-// }
-// ul {
-// display: flex;
-// justify-content: center;
-// padding: $p/2;
-// width: 100%;
-// li {
-// padding: $p/2;
-// }
-// }
-// a.link {
-// display: block;
-// border-radius: 100%;
-// background: $blue;
-// width: 30px;
-// height: 30px;
-// line-height: 30px;
-// display: block;
-// }
-// }
-
-// a.link {
-// &.portfolio {
-// background: #f5c8bf;
-// background: linear-gradient(135deg, rgba(#f5c8bf, 1) 0%, rgba(#f58dbf, 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f5c8bf', endColorstr='#f58dbf', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(#f58dbf, .5);
-// &:hover,
-// &:focus {
-// background: lighten(#f5c8bf, 5%);
-// background: linear-gradient(135deg, rgba(lighten(#f5c8bf, 5%), 1) 0%, rgba(lighten(#f58dbf, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='lighten(#f5c8bf, 5%)', endColorstr='lighten(#f58dbf, 5%)', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(lighten(#f58dbf, 5%), .5);
-// }
-// &:active {
-// background: darken(#f5c8bf, 5%);
-// background: linear-gradient(135deg, rgba(darken(#f5c8bf, 5%), 1) 0%, rgba(darken(#f58dbf, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='darken(#f5c8bf, 5%)', endColorstr='darken(#f58dbf, 5%)', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(darken(#f58dbf, 5%), .5);
-// }
-// }
-// &.codepen {
-// background: #fcd000;
-// background: linear-gradient(135deg, rgba(#fcd000, 1) 0%, rgba(#fc9a00, 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#fcd000', endColorstr='#fc9a00', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(#fc9a00, .5);
-// &:hover,
-// &:focus {
-// background: lighten(#fcd000, 5%);
-// background: linear-gradient(135deg, rgba(lighten(#fcd000, 5%), 1) 0%, rgba(lighten(#fc9a00, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='lighten(#fcd000, 5%)', endColorstr='lighten(#fc9a00, 5%)', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(lighten(#fc9a00, 5%), .5);
-// }
-// &:active {
-// background: darken(#fcd000, 5%);
-// background: linear-gradient(135deg, rgba(darken(#fcd000, 5%), 1) 0%, rgba(darken(#fc9a00, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='darken(#fcd000, 5%)', endColorstr='darken(#fc9a00, 5%)', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(darken(#fc9a00, 5%), .5);
-// }
-// }
-// &.github {
-// background: #41adc4;
-// background: linear-gradient(135deg, rgba(#41adc4, 1) 0%, rgba(#4183c4, 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#41adc4', endColorstr='#4183c4', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(#4183c4, .5);
-// &:hover,
-// &:focus {
-// background: lighten(#41adc4, 5%);
-// background: linear-gradient(135deg, rgba(lighten(#41adc4, 5%), 1) 0%, rgba(lighten(#4183c4, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='lighten(#41adc4, 5%)', endColorstr='lighten(#4183c4, 5%)', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(lighten(#4183c4, 5%), .5);
-// }
-// &:active {
-// background: darken(#41adc4, 5%);
-// background: linear-gradient(135deg, rgba(darken(#41adc4, 5%), 1) 0%, rgba(darken(#4183c4, 5%), 1) 100%);
-// filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='darken(#41adc4, 5%)', endColorstr='darken(#4183c4, 5%)', GradientType=1);
-// box-shadow: inset 0 0 10px rgba(darken(#4183c4, 5%), .5);
-// }
-// }
-// }
-
-// @media only screen and (min-width: 470px) {
-// .profile {
-// display: flex;
-// &.pre-enter {
-// transform: scaleX(0);
-// .avatar {
-// transform-origin: left center;
-// transform: scaleX(0);
-// }
-// h1,
-// h2,
-// a.follow,
-// a.link {
-// transform: translateX(300px);
-// }
-// }
-// &.on-enter {
-// animation-name: scaleXIn;
-// .avatar {
-// animation-name: scaleXIn-small;
-// }
-// h1,
-// h2,
-// a.follow,
-// a.link {
-// animation-name: slideInLeft;
-// }
-// }
-// }
-// .background {
-// mix-blend-mode: overlay;
-// }
-// .avatar,
-// .info {
-// width: 50%;
-// height: 100%;
-// }
-// .avatar {
-// clip-path: polygon(0 0, 100% 0, 75% 100%, 0% 100%);
-// }
-// }
-
-// @media only screen and (min-width: 470px) and (min-height: 600px) {
-// .profile {
-// max-height: 400px;
-// }
-// }
-
-
-// /* https://goo.gl/jIUq3E */
-
-// @keyframes scaleXIn {
-// 0% {
-// transform: matrix3d(0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 4.7% {
-// transform: matrix3d(0.45, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 9.41% {
-// transform: matrix3d(0.883, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 14.11% {
-// transform: matrix3d(1.141, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 18.72% {
-// transform: matrix3d(1.212, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 24.32% {
-// transform: matrix3d(1.151, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 29.93% {
-// transform: matrix3d(1.048, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 35.54% {
-// transform: matrix3d(0.979, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 41.04% {
-// transform: matrix3d(0.961, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 52.15% {
-// transform: matrix3d(0.991, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 63.26% {
-// transform: matrix3d(1.007, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 85.49% {
-// transform: matrix3d(0.999, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 100% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// }
-
-
-// /* https://goo.gl/auuhcg */
-
-// @keyframes scaleYIn {
-// 0% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 4.7% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.45, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 9.41% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.883, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 14.11% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1.141, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 18.72% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1.212, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 24.32% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1.151, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 29.93% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1.048, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 35.54% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.979, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 41.04% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.961, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 52.15% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.991, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 63.26% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1.007, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 85.49% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.999, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 100% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// }
-
-
-// /* https://goo.gl/dNBqrt */
-
-// @keyframes scaleXIn-small {
-// 0% {
-// transform: matrix3d(0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 6.31% {
-// transform: matrix3d(0.384, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 12.51% {
-// transform: matrix3d(0.621, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 18.82% {
-// transform: matrix3d(0.771, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 25.03% {
-// transform: matrix3d(0.862, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 37.54% {
-// transform: matrix3d(0.952, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 50.05% {
-// transform: matrix3d(0.984, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 75.08% {
-// transform: matrix3d(0.999, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 100% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// }
-
-
-// /* https://goo.gl/jZL0uj */
-
-// @keyframes scaleYIn-small {
-// 0% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 6.31% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.384, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 12.51% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.621, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 18.82% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.771, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 25.03% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.862, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 37.54% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.952, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 50.05% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.984, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 75.08% {
-// transform: matrix3d(1, 0, 0, 0, 0, 0.999, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// 100% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// }
-
-
-// /* https://goo.gl/Ne0Mkr */
-
-// @keyframes slideInLeft {
-// 0% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 300, 0, 0, 1);
-// }
-// 6.31% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 184.858, 0, 0, 1);
-// }
-// 12.51% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 113.68, 0, 0, 1);
-// }
-// 18.82% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 68.663, 0, 0, 1);
-// }
-// 25.03% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 41.37, 0, 0, 1);
-// }
-// 37.54% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 14.382, 0, 0, 1);
-// }
-// 50.05% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 4.724, 0, 0, 1);
-// }
-// 75.08% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0.381, 0, 0, 1);
-// }
-// 100% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// }
-
-
-// /* https://goo.gl/MSqtd5 */
-
-// @keyframes slideInUp {
-// 0% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 300, 0, 1);
-// }
-// 6.31% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 184.858, 0, 1);
-// }
-// 12.51% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 113.68, 0, 1);
-// }
-// 18.82% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 68.663, 0, 1);
-// }
-// 25.03% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 41.37, 0, 1);
-// }
-// 37.54% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 14.382, 0, 1);
-// }
-// 50.05% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 4.724, 0, 1);
-// }
-// 75.08% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0.381, 0, 1);
-// }
-// 100% {
-// transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
-// }
-// }
-
-// //wheather
-// .card-wheather {
-// height: 220px;
-// color: #fff;
-// }
-
-
-
-// .city {
-
-// font-size: 26px;
-// }
-
-// .date {
-// font-size: 20px;
-// line-height: 40px;
-// }
-
-// .sun {
-// height: 70px;
-// }
-
-// .grad-blue {
-// background: linear-gradient(58deg, #f44336, #673ab7);
-// color: #fff;
-// }
-
-// .grad-green {
-// background: linear-gradient(58deg, #009688, #673ab7);
-// color: #fff;
-// }
-
-// .grad-red {
-// background: linear-gradient(58deg, #f44336, #673ab7);
-// color: #fff;
-// }
-// .card-wheather{
-// padding: 2rem;
-// }
-// .temp {
-// font-size: 50px;
-// display: inline-block;
-// }
+
mat-card-content{
min-height: 400px;
}
.chart{
-
- padding: 0.8rem;
+ padding: 0.8rem;
}
\ No newline at end of file
diff --git a/ng6-seed/src/app/dashboard/dashboard.component.ts b/ng6-seed/src/app/dashboard/dashboard.component.ts
index 5d0e576f0..c773c9964 100644
--- a/ng6-seed/src/app/dashboard/dashboard.component.ts
+++ b/ng6-seed/src/app/dashboard/dashboard.component.ts
@@ -1,16 +1,11 @@
//import { Component } from '@angular/core';
import {Component, NgModule, ElementRef, Inject, Injectable, ViewChild} from '@angular/core'
import { FormBuilder, FormGroup, Validators , ValidatorFn, AbstractControl, FormControl} from '@angular/forms'
-import { HttpClient } from '@angular/common/http';
-import {BrowserModule} from '@angular/platform-browser'
import {ChartsModule, Color} from 'ng2-charts';
-import {Observable} from 'rxjs';
-import {map, startWith, debounceTime, distinctUntilChanged, switchMap} from 'rxjs/operators';
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 { DatePipe } from '@angular/common';
@Component({
selector: 'app-dashboard',
@@ -32,10 +27,12 @@ export class DashboardComponent {
dashboardTitle = 'PD Status';
/** Declaration Part Of Doughnut Chart */
- @ViewChild('mycanvas') canvas:ElementRef;
+ //@ViewChild('BaseChartDirective') canvas ;
+ @ViewChild(BaseChartDirective) FullCanvas: BaseChartDirective;
+ @ViewChild(BaseChartDirective) TeleCanvas: BaseChartDirective;
+ @ViewChild(BaseChartDirective) SmartCanvas: BaseChartDirective;
//myChart: BaseChartDirective;
-
doughnutChartType = 'doughnut';
doughnutChartLabels: string[] = ['Draft','Triggered','Allocated','Scheduled','InProgress','Completed','QC Completed'];
@@ -50,9 +47,6 @@ export class DashboardComponent {
total1: number = 0;
total2: number = 0;
total3: number = 0;
- total4: number = 0;
- total5: number = 0;
- total6: number = 0;
flag : number = 0;
// doughnutChartColors: any[] = [{
@@ -72,14 +66,8 @@ export class DashboardComponent {
}
};
- /** Declaration Part Of SubCard Section */
-
- cityWisePD : any=[];
- lenderWisePD :any=[];
- alertMessage : any=[];
+ /** Declaration Part Of Title Section */
- selectedCity : any=[];
- selectedLender : any=[];
/** Declaration Part Of Title Form Section */
myControl = new FormControl();
@@ -89,6 +77,8 @@ export class DashboardComponent {
lenderData : any[];
cityData : any[];
+ selectedCity : any=[];
+ selectedLender : any=[];
constructor(private _dashboardService: DashboardService,
private _masterService: MastersService) {
@@ -117,9 +107,9 @@ export class DashboardComponent {
ngOnInit(){
-
- this.getDoughnutChartData();
-
+ this.getDoughnutChartData();
+
+
const today = new Date();
const fromMin = new Date(today.getFullYear(), today.getMonth()-2, 1);
const fromMax = new Date(today.getFullYear(), today.getMonth()+1, 0);
@@ -129,12 +119,12 @@ export class DashboardComponent {
const LastDateForPreMonth = new Date(today.getFullYear(), today.getMonth(), 0);
const FirstDateForPreMonth = new Date(today.getFullYear(), today.getMonth()-1, 1);
- console.log('FromDateMin:',fromMin);
- console.log('FromDateMax:',fromMax);
- console.log('ToDateMin',toMin);
- console.log('ToDateMax',toMax);
- console.log('LastDateForPreMonth',LastDateForPreMonth);
- console.log('FirstDateForPreMonth',FirstDateForPreMonth);
+ // console.log('FromDateMin:',fromMin);
+ // console.log('FromDateMax:',fromMax);
+ // console.log('ToDateMin',toMin);
+ // console.log('ToDateMax',toMax);
+ // console.log('LastDateForPreMonth',LastDateForPreMonth);
+ // console.log('FirstDateForPreMonth',FirstDateForPreMonth);
// const resetRange = {fromDate: today, toDate: today};
// this.dateRangePicker.resetDates(resetRange); // will trigger selectedDateRangeChanged
@@ -144,7 +134,7 @@ export class DashboardComponent {
this.options = {
presets: this.presets,
format: 'mediumDate',
- range: {fromDate:toMin, toDate: fromMax},
+ range: {fromDate:FirstDateForPreMonth, toDate: fromMax},
applyLabel: "Submit",
calendarOverlayConfig: {
shouldCloseOnBackdropClick: false,
@@ -159,7 +149,6 @@ export class DashboardComponent {
}
updateRange(range: Range){
-
this.range = range;
this.onChange(this.range,1);
}
@@ -202,10 +191,7 @@ getDoughnutChartData(){
this._dashboardService.getPDDetailForDoughnut(fromdate,todate,cityarr,lenderarr).subscribe(data => {
this.flag = 1;
- console.log(' ***** Doughnut Chart Data *****');
- console.log('Whole Data',data);
- console.log('Monthly Status',data.records.current_month);
-
+ console.log(' ***** Doughnut Chart Data *****',data);
let DraftIndexvalue = this.doughnutChartLabels.indexOf('Draft');
let TriggedIndexvalue = this.doughnutChartLabels.indexOf('Triggered');
@@ -227,9 +213,8 @@ getDoughnutChartData(){
if(DraftFullPDvalue.length != '0'){
//console.log('console triggered value',TriggerFullPDvalue);
for(let FPD of DraftFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[DraftIndexvalue] = y;
+
+ this.tempDataFullPD[DraftIndexvalue] = +FPD.count;
}
}
else{
@@ -238,11 +223,10 @@ getDoughnutChartData(){
let TriggerFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'TRIGGERED');
if(TriggerFullPDvalue.length != '0'){
- //console.log('console triggered value',TriggerFullPDvalue);
+
for(let FPD of TriggerFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[TriggedIndexvalue] = y;
+
+ this.tempDataFullPD[TriggedIndexvalue] = +FPD.count;
}
}
else{
@@ -252,9 +236,8 @@ getDoughnutChartData(){
let AllocatedFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'ALLOCATED');
if(AllocatedFullPDvalue.length != '0'){
for(let FPD of AllocatedFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[AllocatedIndexvalue] = y;
+
+ this.tempDataFullPD[AllocatedIndexvalue] = +FPD.count;
}
}
else{
@@ -264,11 +247,10 @@ getDoughnutChartData(){
let ScheduledFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'SCHEDULED');
if(ScheduledFullPDvalue.length != '0'){
for(let FPD of ScheduledFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[ScheduledIndexvalue] = y;
+
+ this.tempDataFullPD[ScheduledIndexvalue] = +FPD.count;
}
- //let y = +ScheduledFullPDvalue.count;
+
}
else{
@@ -278,9 +260,8 @@ getDoughnutChartData(){
let InProgressFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'INPROGRESS');
if(InProgressFullPDvalue.length != '0'){
for(let FPD of InProgressFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[InProgressIndexvalue] = y;
+
+ this.tempDataFullPD[InProgressIndexvalue] = +FPD.count;
}
//let y = +InProgressFullPDvalue.count;
@@ -292,9 +273,8 @@ getDoughnutChartData(){
let CompletedFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'COMPLETED');
if(CompletedFullPDvalue.length != '0'){
for(let FPD of CompletedFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[CompletedIndexvalue] = y;
+
+ this.tempDataFullPD[CompletedIndexvalue] = +FPD.count;
}
//let y = +CompletedFullPDvalue.count;
@@ -306,9 +286,8 @@ getDoughnutChartData(){
let QCCompletedFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == "QC_COMPLETED");
if(QCCompletedFullPDvalue.length != '0'){
for(let FPD of QCCompletedFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[QCCompletedIndexvalue] = y;
+
+ this.tempDataFullPD[QCCompletedIndexvalue] = +FPD.count;
}
//let y = +QCCompletedFullPDvalue.count;
@@ -321,9 +300,8 @@ getDoughnutChartData(){
if(DraftSmartPDvalue.length != '0'){
//console.log('console triggered value',TriggerFullPDvalue);
for(let FPD of DraftSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[DraftIndexvalue] = y;
+
+ this.tempDataSmartPD[DraftIndexvalue] = +FPD.count;
}
}
else{
@@ -334,9 +312,7 @@ getDoughnutChartData(){
if(TriggerSmartPDvalue.length != '0'){
for(let FPD of TriggerSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[TriggedIndexvalue] = y;
+ this.tempDataSmartPD[TriggedIndexvalue] = +FPD.count;
}
}
else{
@@ -346,9 +322,8 @@ getDoughnutChartData(){
let AllocatedSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'ALLOCATED');
if(AllocatedSmartPDvalue.length != '0'){
for(let FPD of AllocatedSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[AllocatedIndexvalue] = y;
+
+ this.tempDataSmartPD[AllocatedIndexvalue] = +FPD.count;
}
}
else{
@@ -358,9 +333,8 @@ getDoughnutChartData(){
let ScheduledSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'SCHEDULED');
if(ScheduledSmartPDvalue.length != '0'){
for(let FPD of ScheduledSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[ScheduledIndexvalue] = y;
+
+ this.tempDataSmartPD[ScheduledIndexvalue] = +FPD.count;
}
//let y = +ScheduledFullPDvalue.count;
@@ -372,9 +346,8 @@ getDoughnutChartData(){
let InProgressSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'INPROGRESS');
if(InProgressSmartPDvalue.length != '0'){
for(let FPD of InProgressSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[InProgressIndexvalue] = y;
+
+ this.tempDataSmartPD[InProgressIndexvalue] = +FPD.count;
}
//let y = +InProgressFullPDvalue.count;
@@ -386,9 +359,8 @@ getDoughnutChartData(){
let CompletedSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'COMPLETED');
if(CompletedSmartPDvalue.length != '0'){
for(let FPD of CompletedSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[CompletedIndexvalue] = y;
+
+ this.tempDataSmartPD[CompletedIndexvalue] = +FPD.count;
}
//let y = +CompletedFullPDvalue.count;
@@ -400,9 +372,8 @@ getDoughnutChartData(){
let QCCompletedSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == "QC_COMPLETED");
if(QCCompletedSmartPDvalue.length != '0'){
for(let FPD of QCCompletedSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[QCCompletedIndexvalue] = y;
+
+ this.tempDataSmartPD[QCCompletedIndexvalue] = +FPD.count;
}
//let y = +QCCompletedFullPDvalue.count;
@@ -416,9 +387,8 @@ getDoughnutChartData(){
if(DraftTelePDvalue.length != '0'){
for(let FPD of DraftTelePDvalue){
- let y = +FPD.count;
- this.total1 = this.total3+y;
- this.tempDataTelePD[DraftIndexvalue] = y;
+
+ this.tempDataTelePD[DraftIndexvalue] = +FPD.count;
}
}
else{
@@ -429,9 +399,8 @@ getDoughnutChartData(){
if(TriggerTelePDvalue.length != '0'){
//console.log('console triggered value',TriggerTelePDvalue);
for(let FPD of TriggerTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[TriggedIndexvalue] = y;
+
+ this.tempDataTelePD[TriggedIndexvalue] = +FPD.count;
}
}
else{
@@ -441,9 +410,8 @@ getDoughnutChartData(){
let AllocatedTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'ALLOCATED');
if(AllocatedTelePDvalue.length != '0'){
for(let FPD of AllocatedTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[AllocatedIndexvalue] = y;
+
+ this.tempDataTelePD[AllocatedIndexvalue] = +FPD.count;
}
}
else{
@@ -453,9 +421,8 @@ getDoughnutChartData(){
let ScheduledTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'SCHEDULED');
if(ScheduledTelePDvalue.length != '0'){
for(let FPD of ScheduledTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[ScheduledIndexvalue] = y;
+
+ this.tempDataTelePD[ScheduledIndexvalue] = +FPD.count;
}
//let y = +ScheduledFullPDvalue.count;
@@ -467,9 +434,8 @@ getDoughnutChartData(){
let InProgressTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'INPROGRESS');
if(InProgressTelePDvalue.length != '0'){
for(let FPD of InProgressTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[InProgressIndexvalue] = y;
+
+ this.tempDataTelePD[InProgressIndexvalue] = +FPD.count;
}
//let y = +InProgressFullPDvalue.count;
@@ -481,9 +447,8 @@ getDoughnutChartData(){
let CompletedTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'COMPLETED');
if(CompletedTelePDvalue.length != '0'){
for(let FPD of CompletedTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[CompletedIndexvalue] = y;
+
+ this.tempDataTelePD[CompletedIndexvalue] = +FPD.count;
}
//let y = +CompletedFullPDvalue.count;
@@ -495,9 +460,8 @@ getDoughnutChartData(){
let QCCompletedTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == "QC_COMPLETED");
if(QCCompletedTelePDvalue.length != '0'){
for(let FPD of QCCompletedTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[QCCompletedIndexvalue] = y;
+
+ this.tempDataTelePD[QCCompletedIndexvalue] = +FPD.count;
}
//let y = +QCCompletedFullPDvalue.count;
@@ -508,23 +472,22 @@ getDoughnutChartData(){
}
else{
- //console.log('Else Condition month');
+ this.tempDataFullPD = [0,0,0,0,0,0,0];
+ this.tempDataSmartPD = [0,0,0,0,0,0,0];
+ this.tempDataTelePD = [0,0,0,0,0,0,0];
}
+
this.doughnutChartDataForFullPD = this.tempDataFullPD;
this.doughnutChartDataForSmartPD = this.tempDataSmartPD;
this.doughnutChartDataForTelePD = this.tempDataTelePD;
+ this.total1 = this.tempDataFullPD.reduce((a, b) => a + b, 0);
+ this.total2 = this.tempDataSmartPD.reduce((a, b) => a + b, 0);
+ this.total3 = this.tempDataTelePD.reduce((a, b) => a + b, 0);
- console.log('Final full Data Completed',this.doughnutChartDataForFullPD);
- console.log('temp full Data',this.tempDataFullPD);
- console.log('Final Smart Data Completed',this.doughnutChartDataForSmartPD);
- console.log('temp Smart Data',this.tempDataSmartPD);
- console.log('Final Tele Data Completed',this.doughnutChartDataForTelePD);
- console.log('temp Tele Data',this.tempDataTelePD);
- console.log('total3',this.total3);
- console.log('total2',this.total2);
- console.log('total1',this.total1);
-
-
+ console.log('Final Full Data '+ this.doughnutChartDataForFullPD+'Temp Data'+this.tempDataFullPD+'Full Total '+this.total1);
+ console.log('Final Smart Data '+ this.doughnutChartDataForSmartPD+' Temp Data '+this.tempDataSmartPD+'Smart Total '+this.total2);
+ console.log('Final Tele Data '+ this.doughnutChartDataForTelePD+' Temp Data'+this.tempDataTelePD+'Tele Total '+this.total3);
+
})
}
@@ -538,10 +501,17 @@ doughnutOptions: any = Object.assign({
centertext:'One'
},this.globalChartOptions);
+// ngOnChanges(){
+// // this.barChartData=this.chartData;
+// this.barChartLabel=this.chartLabel;
+// }
+
+
onChange(e :any,flag: any) {
+
let fromdate;
let todate;
- console.log('flag',flag);
+
if(flag == 1){
fromdate = new Date(e.fromDate);
@@ -553,7 +523,7 @@ onChange(e :any,flag: any) {
let data = e.source.value.city_id;
e.source._selected == true ? this.selectedCity.push(data)
: this.selectedCity.splice(this.selectedCity.indexOf(data),1);
- console.log(this.selectedCity);
+
}
if(flag == 3){
@@ -561,24 +531,29 @@ onChange(e :any,flag: any) {
e.source._selected == true ? this.selectedLender.push(data)
: this.selectedLender.splice(this.selectedLender.indexOf(data),1);
- console.log(this.selectedLender);
+
}
-
- this._dashboardService.getPDDetailForDoughnut(fromdate,todate,this.selectedLender,this.selectedCity).subscribe(data => {
- console.log(' *****Updated Date Doughnut Chart Data *****');
- console.log('Whole Data',data);
+
+ this._dashboardService.getPDDetailForDoughnut(fromdate,todate,this.selectedCity,this.selectedLender).subscribe(data => {
+
+ console.log(' *****Updated Date Doughnut Chart Data *****',data);
+
if(data.records.current_month.length != 0){
this.total1 = 0;
this.total2 = 0;
this.total3 = 0;
}
+
this.doughnutChartDataForFullPD = [];
this.doughnutChartDataForSmartPD = [];
this.doughnutChartDataForTelePD = [];
+ this.tempDataFullPD = [];
+ this.tempDataSmartPD =[];
+ this.tempDataTelePD = [];
let DraftIndexvalue = this.doughnutChartLabels.indexOf('Draft');
@@ -614,9 +589,8 @@ onChange(e :any,flag: any) {
if(TriggerFullPDvalue.length != '0'){
for(let FPD of TriggerFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[TriggedIndexvalue] = y;
+
+ this.tempDataFullPD[TriggedIndexvalue] = +FPD.count;
}
}
else{
@@ -626,9 +600,8 @@ onChange(e :any,flag: any) {
let AllocatedFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'ALLOCATED');
if(AllocatedFullPDvalue.length != '0'){
for(let FPD of AllocatedFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[AllocatedIndexvalue] = y;
+
+ this.tempDataFullPD[AllocatedIndexvalue] = +FPD.count;
}
}
else{
@@ -638,9 +611,8 @@ onChange(e :any,flag: any) {
let ScheduledFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'SCHEDULED');
if(ScheduledFullPDvalue.length != '0'){
for(let FPD of ScheduledFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[ScheduledIndexvalue] = y;
+
+ this.tempDataFullPD[ScheduledIndexvalue] = +FPD.count;
}
//let y = +ScheduledFullPDvalue.count;
@@ -652,9 +624,8 @@ onChange(e :any,flag: any) {
let InProgressFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'INPROGRESS');
if(InProgressFullPDvalue.length != '0'){
for(let FPD of InProgressFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[InProgressIndexvalue] = y;
+
+ this.tempDataFullPD[InProgressIndexvalue] = +FPD.count;
}
//let y = +InProgressFullPDvalue.count;
@@ -666,9 +637,8 @@ onChange(e :any,flag: any) {
let CompletedFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == 'COMPLETED');
if(CompletedFullPDvalue.length != '0'){
for(let FPD of CompletedFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[CompletedIndexvalue] = y;
+
+ this.tempDataFullPD[CompletedIndexvalue] = +FPD.count;
}
//let y = +CompletedFullPDvalue.count;
@@ -680,9 +650,8 @@ onChange(e :any,flag: any) {
let QCCompletedFullPDvalue = MonthlyFullPDArr.filter(arr=>arr.pd_status == "QC_COMPLETED");
if(QCCompletedFullPDvalue.length != '0'){
for(let FPD of QCCompletedFullPDvalue){
- let y = +FPD.count;
- this.total1 = this.total1+y;
- this.tempDataFullPD[QCCompletedIndexvalue] = y;
+
+ this.tempDataFullPD[QCCompletedIndexvalue] = +FPD.count;
}
//let y = +QCCompletedFullPDvalue.count;
@@ -695,9 +664,8 @@ onChange(e :any,flag: any) {
if(DraftSmartPDvalue.length != '0'){
//console.log('console triggered value',TriggerFullPDvalue);
for(let FPD of DraftSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[DraftIndexvalue] = y;
+
+ this.tempDataSmartPD[DraftIndexvalue] = +FPD.count;
}
}
else{
@@ -708,9 +676,8 @@ onChange(e :any,flag: any) {
if(TriggerSmartPDvalue.length != '0'){
for(let FPD of TriggerSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[TriggedIndexvalue] = y;
+
+ this.tempDataSmartPD[TriggedIndexvalue] = +FPD.count;
}
}
else{
@@ -720,9 +687,8 @@ onChange(e :any,flag: any) {
let AllocatedSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'ALLOCATED');
if(AllocatedSmartPDvalue.length != '0'){
for(let FPD of AllocatedSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[AllocatedIndexvalue] = y;
+
+ this.tempDataSmartPD[AllocatedIndexvalue] = +FPD.count;
}
}
else{
@@ -732,9 +698,8 @@ onChange(e :any,flag: any) {
let ScheduledSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'SCHEDULED');
if(ScheduledSmartPDvalue.length != '0'){
for(let FPD of ScheduledSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[ScheduledIndexvalue] = y;
+
+ this.tempDataSmartPD[ScheduledIndexvalue] = +FPD.count;
}
//let y = +ScheduledFullPDvalue.count;
@@ -746,9 +711,8 @@ onChange(e :any,flag: any) {
let InProgressSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'INPROGRESS');
if(InProgressSmartPDvalue.length != '0'){
for(let FPD of InProgressSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[InProgressIndexvalue] = y;
+
+ this.tempDataSmartPD[InProgressIndexvalue] = +FPD.count;
}
//let y = +InProgressFullPDvalue.count;
@@ -760,9 +724,8 @@ onChange(e :any,flag: any) {
let CompletedSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == 'COMPLETED');
if(CompletedSmartPDvalue.length != '0'){
for(let FPD of CompletedSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[CompletedIndexvalue] = y;
+
+ this.tempDataSmartPD[CompletedIndexvalue] = +FPD.count;
}
//let y = +CompletedFullPDvalue.count;
@@ -774,9 +737,8 @@ onChange(e :any,flag: any) {
let QCCompletedSmartPDvalue = MonthlySmartPDArr.filter(arr=>arr.pd_status == "QC_COMPLETED");
if(QCCompletedSmartPDvalue.length != '0'){
for(let FPD of QCCompletedSmartPDvalue){
- let y = +FPD.count;
- this.total2 = this.total2+y;
- this.tempDataSmartPD[QCCompletedIndexvalue] = y;
+
+ this.tempDataSmartPD[QCCompletedIndexvalue] = +FPD.count;
}
//let y = +QCCompletedFullPDvalue.count;
@@ -790,9 +752,8 @@ onChange(e :any,flag: any) {
if(DraftTelePDvalue.length != '0'){
for(let FPD of DraftTelePDvalue){
- let y = +FPD.count;
- this.total1 = this.total3+y;
- this.tempDataTelePD[DraftIndexvalue] = y;
+
+ this.tempDataTelePD[DraftIndexvalue] = +FPD.count;
}
}
else{
@@ -803,9 +764,8 @@ onChange(e :any,flag: any) {
if(TriggerTelePDvalue.length != '0'){
//console.log('console triggered value',TriggerTelePDvalue);
for(let FPD of TriggerTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[TriggedIndexvalue] = y;
+
+ this.tempDataTelePD[TriggedIndexvalue] = +FPD.count;
}
}
else{
@@ -815,9 +775,8 @@ onChange(e :any,flag: any) {
let AllocatedTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'ALLOCATED');
if(AllocatedTelePDvalue.length != '0'){
for(let FPD of AllocatedTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[AllocatedIndexvalue] = y;
+
+ this.tempDataTelePD[AllocatedIndexvalue] = +FPD.count;
}
}
else{
@@ -827,9 +786,8 @@ onChange(e :any,flag: any) {
let ScheduledTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'SCHEDULED');
if(ScheduledTelePDvalue.length != '0'){
for(let FPD of ScheduledTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[ScheduledIndexvalue] = y;
+
+ this.tempDataTelePD[ScheduledIndexvalue] = +FPD.count;
}
//let y = +ScheduledFullPDvalue.count;
@@ -841,9 +799,8 @@ onChange(e :any,flag: any) {
let InProgressTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'INPROGRESS');
if(InProgressTelePDvalue.length != '0'){
for(let FPD of InProgressTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[InProgressIndexvalue] = y;
+
+ this.tempDataTelePD[InProgressIndexvalue] = +FPD.count;
}
//let y = +InProgressFullPDvalue.count;
@@ -855,9 +812,8 @@ onChange(e :any,flag: any) {
let CompletedTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == 'COMPLETED');
if(CompletedTelePDvalue.length != '0'){
for(let FPD of CompletedTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[CompletedIndexvalue] = y;
+
+ this.tempDataTelePD[CompletedIndexvalue] = +FPD.count;
}
//let y = +CompletedFullPDvalue.count;
@@ -869,9 +825,8 @@ onChange(e :any,flag: any) {
let QCCompletedTelePDvalue = MonthlyTelePDArr.filter(arr=>arr.pd_status == "QC_COMPLETED");
if(QCCompletedTelePDvalue.length != '0'){
for(let FPD of QCCompletedTelePDvalue){
- let y = +FPD.count;
- this.total3 = this.total3+y;
- this.tempDataTelePD[QCCompletedIndexvalue] = y;
+
+ this.tempDataTelePD[QCCompletedIndexvalue] = +FPD.count;
}
//let y = +QCCompletedFullPDvalue.count;
@@ -882,24 +837,28 @@ onChange(e :any,flag: any) {
}
else{
- //console.log('Else Condition month');
+ this.tempDataFullPD = [0,0,0,0,0,0,0];
+ this.tempDataSmartPD = [0,0,0,0,0,0,0];
+ this.tempDataTelePD = [0,0,0,0,0,0,0];
}
- this.doughnutChartDataForFullPD = this.tempDataFullPD;
+
+ this.doughnutChartDataForFullPD= this.tempDataFullPD;
this.doughnutChartDataForSmartPD = this.tempDataSmartPD;
this.doughnutChartDataForTelePD = this.tempDataTelePD;
+ this.doughnutChartLabels = this.doughnutChartLabels;
+ this.total1 = this.tempDataFullPD.reduce((a, b) => a + b, 0);
+ this.total2 = this.tempDataSmartPD.reduce((a, b) => a + b, 0);
+ this.total3 = this.tempDataTelePD.reduce((a, b) => a + b, 0);
+
+ this.FullCanvas.chart.update();
+ this.SmartCanvas.chart.update();
+ this.TeleCanvas.chart.update();
+
+ console.log('Final Full Data '+ this.doughnutChartDataForFullPD+'Temp Data'+this.tempDataFullPD+'Full Total '+this.total1);
+ console.log('Final Smart Data '+ this.doughnutChartDataForSmartPD+' Temp Data '+this.tempDataSmartPD+'Smart Total '+this.total2);
+ console.log('Final Tele Data '+ this.doughnutChartDataForTelePD+' Temp Data'+this.tempDataTelePD+'Tele Total '+this.total3);
- console.log('Final full Data Completed',this.doughnutChartDataForFullPD);
- console.log('temp full Data',this.tempDataFullPD);
- console.log('Final Smart Data Completed',this.doughnutChartDataForSmartPD);
- console.log('temp Smart Data',this.tempDataSmartPD);
- console.log('Final Tele Data Completed',this.doughnutChartDataForTelePD);
- console.log('temp Tele Data',this.tempDataTelePD);
- console.log('total3',this.total3);
- console.log('total2',this.total2);
- console.log('total1',this.total1);
-
-
- })
+ })
}
}
\ No newline at end of file
diff --git a/ng6-seed/src/app/dashboard/dashboard.service.ts b/ng6-seed/src/app/dashboard/dashboard.service.ts
index f9c663f5c..282adb26d 100644
--- a/ng6-seed/src/app/dashboard/dashboard.service.ts
+++ b/ng6-seed/src/app/dashboard/dashboard.service.ts
@@ -21,7 +21,6 @@ const currentdate = new Date().toJSON().slice(0,19).replace('T',' ');
export class DashboardService {
private apiUrl = environment.apiEndpoint;
- //private apiUrl = 'http://localhost/sparqapi/api/';
constructor(private _http: HttpClient,
private _aws:AwsService) { }
@@ -53,17 +52,13 @@ export class DashboardService {
// }
getPDDetailForDoughnut(fromdate,todate,cityarr,lenderarr): Observable {
- console.log(')))))');
-console.log(fromdate);
-console.log(todate);
-console.log(cityarr);
-console.log(lenderarr);
-console.log('(((');
+
+console.log(' From : ' + fromdate + ' To : ' + todate + ' Lender Array : ' + lenderarr + ' City Array : ' + cityarr);
+
return this._http.post(this.apiUrl+'getDashBoardMaster', {
- "fromdate":fromdate,
- "todate": todate,
- "cityarr":cityarr,
- "lenderarr": lenderarr})
+ "fromdate":fromdate != '' && fromdate != null && fromdate != undefined ? fromdate : '',
+ "todate": todate != '' && todate != null && todate != undefined ? todate : '',
+ "cityarr":cityarr,"lenderarr": lenderarr})
.pipe(catchError(this.handleError('role', []))
)
diff --git a/ng6-seed/src/app/layouts/admin/admin-layout.component.html b/ng6-seed/src/app/layouts/admin/admin-layout.component.html
index 93218012f..3b54dc446 100644
--- a/ng6-seed/src/app/layouts/admin/admin-layout.component.html
+++ b/ng6-seed/src/app/layouts/admin/admin-layout.component.html
@@ -312,7 +312,7 @@
-
+
Not Yet Scheduled
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html
index 58a8e09a6..a2701b740 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.html
@@ -87,7 +87,7 @@
-
+
Enter valid amount.
@@ -126,9 +126,9 @@
-
+
- Enter Valid Pincode.
+ Enter Valid Pincode.
@@ -158,19 +158,25 @@
Main Applicant
-
-
Name is Required.
-
-
-
- Enter Valid Mobile Number.
-
-
+
+
+
+
+ Enter Valid Mobile Number.
+
+
+
+
+ Enter Valid Phone Number.
+
+
+
+
@@ -190,24 +196,31 @@
{{coDetails.controls.label.value}} {{i+1}}
-
+
-
-
- Enter Valid Mobile Number.
-
-
-
-
-
+
+
+
+
+ Enter Valid Mobile Number.
+
+
+
+
+ Enter Valid Phone Number.
+
+
+
+
+
{{rel.name}}
-
-
+
+
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts
index 4badcdf6d..e858b0690 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/add-pd/add-pd.component.ts
@@ -77,14 +77,15 @@ export class AddPdComponent implements OnInit, OnDestroy {
fk_customer_segment: [null],
loan_amount: [null,Validators.compose([Validators.pattern('^[0-9]*$')])],
applicant_name: [null],
- mobile_no: [null,Validators.compose([Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
+ mobile_no: [null,Validators.compose([Validators.minLength(10),Validators.maxLength(10),Validators.required])],
+ landline : [null,Validators.compose([Validators.minLength(12),Validators.maxLength(13)])],
email: [null],
 addressline1: [null],
addressline2: [null],
addressline3: [null],
fk_city: [null],
fk_state: [null],
- pincode : [null,Validators.compose([Validators.minLength(6),Validators.maxLength(6),Validators.pattern('^[0-9]*$')])],
+ pincode : [null,Validators.compose([Validators.minLength(6),Validators.maxLength(6)])],
remarks:[null],
 // allocation_type: [null],
 // sub_allocation_type: [null],
@@ -206,7 +207,8 @@ export class AddPdComponent implements OnInit, OnDestroy {
return this._fb.group({
label: ['Co Applicant'],
coapplicantName: [null, Validators.compose([Validators.required])],
- coapplicant_mobile_no: [null, Validators.compose([Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
+ coapplicant_mobile_no: [null,Validators.compose([Validators.minLength(10),Validators.maxLength(10),Validators.required])],
+ coapplicant_landline : [null,Validators.compose([Validators.minLength(12),Validators.maxLength(13)])],
relationship: [null],
});
};
@@ -315,6 +317,7 @@ export class AddPdComponent implements OnInit, OnDestroy {
"applicant_name":formValue.applicant_name,
"email":formValue.email,
"mobile_no":formValue.mobile_no,
+ "landline":formValue.landline,
"applicant_type":1,
"relation":"",
}];
@@ -324,6 +327,7 @@ export class AddPdComponent implements OnInit, OnDestroy {
"relation":itemElement.relationship,
"email":"",
"mobile_no":itemElement.coapplicant_mobile_no,
+ "landline":itemElement.coapplicant_landline,
"applicant_type":0,
}
pd_applicant_details.push(obj1)
@@ -410,4 +414,13 @@ export class AddPdComponent implements OnInit, OnDestroy {
onReset() {
this.loadFormData();
}
+ /** On Key Press Event For Mobile Number */
+ keyPress(event: any) {
+ const pattern = /[0-9/ /./-]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.html
index 3ae92fc5a..4980cad00 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.html
@@ -3,6 +3,7 @@
+
-
-
- Enter Valid Mobile Number.
-
-
+
+
+
+
+ Enter Valid Mobile Number.
+
+
+
+ Enter Valid Phone Number.
+
+
+
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.ts
index ba5b70d88..e1b521fd5 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-applicant/edit-pd-applicant.component.ts
@@ -42,7 +42,8 @@ export class EditPdApplicantComponent implements OnInit {
this._EditApplicantForm = this._fb.group({
fk_applicant_primary_id: [null],
applicant_name: [null, Validators.compose([Validators.required])],
- mobile_no: [null, Validators.compose([Validators.required,Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
+ mobile_no: [null, Validators.compose([Validators.required,Validators.minLength(10),Validators.maxLength(12)])],
+ landline: [null, Validators.compose([Validators.required,Validators.minLength(12),Validators.maxLength(13)])],
email: [null, Validators.compose([Validators.required, CustomValidators.email])],
applicant_type: [1],
coApplicantItems: this._fb.array([]),
@@ -54,7 +55,8 @@ export class EditPdApplicantComponent implements OnInit {
this._EditApplicantForm = this._fb.group({
fk_applicant_primary_id: [this.mainApplicantData[0].pd_co_applicant_id],
applicant_name: [this.mainApplicantData[0].applicant_name, Validators.compose([Validators.required])],
- mobile_no: [this.mainApplicantData[0].mobile_no, Validators.compose([Validators.required,Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
+ mobile_no: [this.mainApplicantData[0].mobile_no, Validators.compose([Validators.required,Validators.minLength(10),Validators.maxLength(12)])],
+ landline: [this.mainApplicantData[0].landline, Validators.compose([Validators.required,Validators.minLength(12),Validators.maxLength(13)])],
email: [this.mainApplicantData[0].email, Validators.compose([Validators.required, CustomValidators.email])],
applicant_type: [this.mainApplicantData[0].applicant_type, Validators.compose([Validators.required])],
coApplicantItems: this._fb.array([]),
@@ -74,6 +76,7 @@ export class EditPdApplicantComponent implements OnInit {
fk_applicant_primary_id: [listData.pd_co_applicant_id],
coapplicantName: [listData.applicant_name, Validators.compose([Validators.required])],
coapplicant_mobile_no: [listData.mobile_no,Validators.compose([Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
+ coapplicant_landline: [listData.landline,Validators.compose([Validators.minLength(12),Validators.maxLength(13)])],
relationship: [listData.relation],
applicant_type: [listData.applicant_type, Validators.compose([Validators.required])],
});
@@ -84,6 +87,7 @@ export class EditPdApplicantComponent implements OnInit {
fk_applicant_primary_id: [null],
coapplicantName: [null, Validators.compose([Validators.required])],
coapplicant_mobile_no: [null, Validators.compose([Validators.minLength(10),Validators.maxLength(12),Validators.pattern('^[0-9]*$')])],
+ coapplicant_landline: [null, Validators.compose([Validators.minLength(12),Validators.maxLength(13)])],
relationship: [null],
applicant_type: [0],
});
@@ -108,6 +112,7 @@ export class EditPdApplicantComponent implements OnInit {
"applicant_name":formValue.applicant_name,
"email":formValue.email,
"mobile_no":formValue.mobile_no,
+ "landline":formValue.landline,
"applicant_type":formValue.applicant_type,
"relation":formValue.relationship,
"isactive":1
@@ -120,6 +125,7 @@ export class EditPdApplicantComponent implements OnInit {
"relation":itemElement.relationship,
"email":"",
"mobile_no":itemElement.coapplicant_mobile_no,
+ "landline":itemElement.coapplicant_landline,
"applicant_type":itemElement.applicant_type,
"isactive":1
}
@@ -164,4 +170,13 @@ export class EditPdApplicantComponent implements OnInit {
closeEditComponent(): void {
this.dialogRef.close();
}
+ /** On Key Press Event For Mobile Number */
+ keyPress(event: any) {
+ const pattern = /[0-9/ /./-]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html
index 294808f73..941ac1f08 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.html
@@ -119,10 +119,8 @@
-
- Enter Valid Pincode.
-
-
+
+ Enter Valid Pincode.
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts
index 2ef8f5a29..79367d614 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/edit-pd-master/edit-pd-master.component.ts
@@ -199,6 +199,15 @@ export class EditPdMasterComponent implements OnInit {
closeEditMasterComponent(): void {
this.dialogRef.close();
}
+ /** On Key Press Event For Mobile Number */
+ keyPress(event: any) {
+ const pattern = /[0-9/ /./-]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-allocation/pd-allocation.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-allocation/pd-allocation.component.html
index 09b7d660a..d7cd16fcc 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-allocation/pd-allocation.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-allocation/pd-allocation.component.html
@@ -13,11 +13,11 @@
0" >
-
+
- ![No Image]()
+ ![No Image]()
{{officer.first_name}}
{{officer.mobile_no}}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.html
new file mode 100644
index 000000000..366f2a5f3
--- /dev/null
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.html
@@ -0,0 +1,45 @@
+
+
+
+
+
+
+
+
+
+
+ {{pdReportRecords.billing_name}}
+
+
+ {{pdReportRecords.product_name}}
+
+
+ {{pdReportRecords.customer_segment_name}}
+
+
+ {{pdReportRecords.pd_type_name}}
+
+
+ {{pdReportRecords.pd_status}}
+
+
+ {{applicants.applicant_name}} ,
+
+
+
+
{{data.Name}}
+
+
{{dataQA.question}}
+
{{dataQA.answer}}
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.scss b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.scss
new file mode 100644
index 000000000..e69de29bb
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.spec.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.spec.ts
new file mode 100644
index 000000000..6629a0598
--- /dev/null
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.spec.ts
@@ -0,0 +1,25 @@
+import { async, ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { PdReportComponent } from './pd-report.component';
+
+describe('PdReportComponent', () => {
+ let component: PdReportComponent;
+ let fixture: ComponentFixture;
+
+ beforeEach(async(() => {
+ TestBed.configureTestingModule({
+ declarations: [ PdReportComponent ]
+ })
+ .compileComponents();
+ }));
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(PdReportComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.ts
new file mode 100644
index 000000000..94f65d910
--- /dev/null
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/pd-report/pd-report.component.ts
@@ -0,0 +1,266 @@
+import {Component, ViewChild, OnInit, ViewEncapsulation, OnDestroy} from '@angular/core';
+import {FormBuilder, FormGroup, Validators, FormControl, FormArray, AbstractControl} from '@angular/forms';
+import {ActivatedRoute, Router} from '@angular/router';
+import {NotifierService} from 'angular-notifier';
+import {ListPdComponent} from './../list-pd.component';
+
+import {PdTrigerService} from '../../../pd-service/pd-triger.service';
+
+@Component({
+ selector: 'app-pd-report',
+ templateUrl: './pd-report.component.html',
+ styleUrls: ['./pd-report.component.scss']
+})
+export class PdReportComponent implements OnInit {
+ startPD: any;
+
+ pdReportRecords:any;
+
+ private notifier: NotifierService;
+ constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
+ private router: Router, public pdTrigerService: PdTrigerService, private listPDComponent: ListPdComponent) {
+ this.startPD = this.route.snapshot.params['pdid'];
+ this.notifier = notifier;
+ }
+
+ ngOnInit() {
+ this.listPDComponent.showListView(false);
+ this.getPdReportDetails();
+ }
+
+ getPdReportDetails() {
+ this.pdTrigerService.getPdFinalReportDetails(this.startPD).subscribe(data => {
+ if (data.status == 200) {
+ // this.pdReportRecords = data.records.question_answers;
+
+ let Records = {
+ "dataStatus": true,
+ "status": 200,
+ "records": {
+ "pd_id": "1",
+ "fk_lender_id": "7",
+ "lender_full_name": "check",
+ "lender_short_name": "check",
+ "fk_entity_billing_id": "1",
+ "billing_name": "ICICI- CHENNAI",
+ "lender_applicant_id": "Le123",
+ "pd_date_of_initiation": "06\/10\/2018",
+ "fk_product_id": "8",
+ "product_name": "Land Loan",
+ "product_abbr": "LL",
+ "fk_subproduct_id": "1",
+ "subproduct_name": "Purchase (Resale) Loan. ",
+ "subproduct_abbr": "HL PUR-RESALE",
+ "fk_pd_type": "1",
+ "pd_type_name": "Full PD ",
+ "pd_status": "COMPLETED",
+ "pd_status_name": null,
+ "pd_specific_clarification": null,
+ "createdon": "06\/10\/2018 05:43:58",
+ "fk_createdby": "1",
+ "updatedon": "16\/11\/2018 11:11:00",
+ "fk_updatedby": "1",
+ "createdby": "Krishna kumar",
+ "updatedby": "Krishna kumar",
+ "fk_pd_allocation_type": "1",
+ "pd_allocation_type_name": "AUTO",
+ "fk_pd_allocated_to": "128",
+ "pd_allocated_to": "VinothKumar S",
+ "executive_id": null,
+ "executive_name": null,
+ "central_pd_officer_id": null,
+ "centralofficer": null,
+ "fk_pd_template_id": "11",
+ "template_name": "TMB",
+ "fk_customer_segment": "2",
+ "customer_segment_name": "Salary Cheque",
+ "customer_segment_abbr": "SAL-CHQ",
+ "pd_officier_final_judgement": null,
+ "pd_agency_id": null,
+ "agency_name": null,
+ "loan_amount": "60000",
+ "addressline1": "MGR Street,Vengaivasal Main Road",
+ "addressline2": "Santhoshpuram",
+ "addressline3": "chennai",
+ "fk_city": "2",
+ "city_name": "Chennai",
+ "fk_state": "2",
+ "state_name": "Tamil Nadu",
+ "pincode": "600100",
+ "pd_contact_person": "Ram",
+ "pd_contact_mobileno": "32131233",
+ "scheduled_on": "31\/12\/2018 12:59 PM",
+ "completed_on": null,
+ "remarks": null,
+ "pd_applicant_details": [
+ {
+ "pd_co_applicant_id": "1",
+ "fk_pd_id": "1",
+ "applicant_name": "Karthi Raj",
+ "applicant_type": "1",
+ "mobile_no": "4234234155",
+ "email": "sivak@gmail.com",
+ "addressline1": null,
+ "addressline2": null,
+ "addressline3": null,
+ "fk_city": null,
+ "fk_state": null,
+ "pincode": null,
+ "relation": "brother",
+ "relation_name": null,
+ "landline": null
+ },
+ {
+ "pd_co_applicant_id": "2",
+ "fk_pd_id": "1",
+ "applicant_name": "ramesh",
+ "applicant_type": "0",
+ "mobile_no": "3123123213",
+ "email": "",
+ "addressline1": null,
+ "addressline2": null,
+ "addressline3": null,
+ "fk_city": null,
+ "fk_state": null,
+ "pincode": null,
+ "relation": "brother",
+ "relation_name": null,
+ "landline": null
+ }
+ ],
+ "question_answers": {
+ "form_details": [
+ {
+ "Name": "Supplied Details",
+ "Details": [
+ {
+ "question": "What are the main raw materials?(MEG Only)",
+ "answer": "check checkcheck"
+ },
+ {
+ "question": "Supplier Name",
+ "answer": "Resico"
+ },
+ {
+ "question": "Contact Person Name",
+ "answer": "Karthick"
+ },
+ {
+ "question": "Contact Mobile Number",
+ "answer": "9874115221"
+ },
+ {
+ "question": "Payment Mode",
+ "answer": "Immediate Or Advanced Payment"
+ },
+ {
+ "question": "% of immediate \/ Advance Payment Purchase to Total Purchase?",
+ "answer": "212"
+ },
+ {
+ "question": "Credit Period",
+ "answer": ""
+ },
+ {
+ "question": "Frequency of Purchase",
+ "answer": "Monthly"
+ },
+ {
+ "question": "Others Details",
+ "answer": ""
+ }
+ ]},
+ {
+ "Name": "Client Details",
+ "Details": [
+ {
+ "question": "Client Name",
+ "answer": "Venba"
+ },
+ {
+ "question": "Contact Person Name",
+ "answer": "test"
+ },
+ {
+ "question": "Contact Mobile Number",
+ "answer": "9685471122"
+ },
+ {
+ "question": "Payment Mode",
+ "answer": "Combination of Both"
+ },
+ {
+ "question": "% of immediate \/ Advance Payment Purchase to Total Purchase?",
+ "answer": "12"
+ },
+ {
+ "question": "Credit Period",
+ "answer": "10"
+ },
+ {
+ "question": "Frequency of Purchase",
+ "answer": "Weekly"
+ },
+ {
+ "question": "Others Details",
+ "answer": ""
+ }
+ ]},
+ { "Name": "Personal Details",
+ "Details": [
+ {
+ "question": "Name",
+ "answer": "Karthi Raj"
+ },
+ {
+ "question": "Age",
+ "answer": "50"
+ },
+ {
+ "question": "Entity",
+ "answer": "Individual"
+ },
+ {
+ "question": "Name",
+ "answer": "ramesh"
+ },
+ {
+ "question": "Age",
+ "answer": "45"
+ },
+ {
+ "question": "Entity",
+ "answer": "Individual"
+ },
+ {
+ "question": "Relationship With Main Applicant",
+ "answer": "Brother"
+ },
+ {
+ "question": "Remarks",
+ "answer": "good"
+ }
+ ]}
+ ],
+ "general_questions": [
+ ]
+ }
+ }
+ }
+
+ this.pdReportRecords = Records.records;
+
+ // this.pdReportRecords = data.records.qu;
+ }
+ }, err=> {
+
+ })
+ }
+
+
+ // load pd view component
+ loadPdViewCompoent() {
+ this.router.navigate(['../../viewpd', this.startPD], {relativeTo: this.route});
+ }
+
+}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/smart-pd-allocation/smart-pd-allocation.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/smart-pd-allocation/smart-pd-allocation.component.html
index 0c7f1b24d..b5711e5a9 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/smart-pd-allocation/smart-pd-allocation.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/smart-pd-allocation/smart-pd-allocation.component.html
@@ -13,7 +13,7 @@
0" >
-
+
+
@@ -142,7 +154,7 @@
Remarks
-
+
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.ts
index 08279586e..02dfce354 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/banking-details/banking-details.component.ts
@@ -29,9 +29,11 @@ import {ActivatedRoute, Router} from "@angular/router";
})
export class BankingDetailsComponent implements OnInit {
@Input() pdid: number;
+ @Input() pd_all_details:any;
public bankingForm: FormGroup;
step: number;
private notifier: NotifierService;
+ public pd_cus_segment:string;
m_accountType= [];
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
@@ -45,6 +47,11 @@ export class BankingDetailsComponent implements OnInit {
this.step = 0;
this.initBankingForm();
this.getM_AccountType();
+ this.pd_cus_segment = this.pd_all_details.pdmaster_details.customer_segment_abbr.toUpperCase();
+ // console.log("(0,3): " + this.pd_cus_segment.substring(0,3));
+ // console.log(this.pd_all_details.pdmaster_details);
+ // console.log(this.pd_cus_segment);
+ this.pd_cus_segment = this.pd_cus_segment.substring(0,3);
let params: any = {};
params.pd_id = this.pdid;
params.pd_form_id = '7';
@@ -98,9 +105,14 @@ export class BankingDetailsComponent implements OnInit {
account_type: ['', Validators.compose([Validators.required])],
salary: ['', Validators.compose([Validators.required])],
limit: ['', Validators.compose([Validators.required])],
- is_main: ['', Validators.compose([Validators.required])],
- vintage: ['', Validators.compose([Validators.required])],
+ //is_main: ['', Validators.compose([Validators.required])],
+ //is_main: [this.pd_cus_segment == 'SAL' ? '' : '', Validators.compose([Validators.required])],
+ //is_main:[''],
+ is_main: this.pd_cus_segment == 'SAL' ? [''] : ['', Validators.compose([Validators.required])],
+ vintage_year: ['', Validators.compose([Validators.required])],
+ vintage_month: ['', Validators.compose([Validators.required])],
});
+
}
addBankdetails(index, event) {
@@ -109,6 +121,10 @@ export class BankingDetailsComponent implements OnInit {
let length = control.length;
this.step = length;
control.push(this.createBankarray());
+ // if(this.pd_cus_segment != 'SAL') {
+ // this.bankingForm.controls.is_main.setValidators([Validators.required]);
+ // this.bankingForm.controls.is_main.updateValueAndValidity();
+ // }
}
deleteBankdetails(index: number) {
@@ -150,4 +166,13 @@ export class BankingDetailsComponent implements OnInit {
}
});
}
+ /** On Key Press Event For Numbers */
+ keyPress(event: any) {
+ const pattern = /[0-9]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.html
index 2e77dd01a..4dc50790e 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.html
@@ -2,25 +2,25 @@
Business Details
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.ts
index 732af4e74..b24341aea 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/business-info/business-info.component.ts
@@ -293,4 +293,15 @@ export class BusinessInfoComponent implements OnInit {
}
});
}
+
+ /** On Key Press Event For Mobile Number */
+ keyPress(event: any) {
+ const pattern = /[0-9]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
+
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.html
index 8ad3212fd..d27fe4526 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.html
@@ -9,34 +9,36 @@
-
+
{{ pm.name }}
-
+
@@ -50,7 +52,7 @@
-
+
{{ feq.name }}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.ts
index 0edbad0cb..683297014 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/client-info/client-info.component.ts
@@ -177,7 +177,7 @@ apiLoadFinish: boolean = false;
return this._formBuilder.group({
client_name: ['', Validators.compose([Validators.required])],
contact_person: ['', Validators.compose([Validators.required])],
- mobile_number: ['', Validators.compose([Validators.required])],
+ mobile_number: ['', Validators.compose([Validators.required, Validators.minLength(10), Validators.maxLength(10)])],
payment_mode: ['', Validators.compose([Validators.required])],
per_of_immediate_advance_payment:[''],
credit_period:[''],
@@ -190,7 +190,7 @@ apiLoadFinish: boolean = false;
return this._formBuilder.group({
client_name: [data.client_name, Validators.compose([Validators.required])],
contact_person: [data.contact_person, Validators.compose([Validators.required])],
- mobile_number: [data.mobile_number, Validators.compose([Validators.required])],
+ mobile_number: [data.mobile_number, Validators.compose([Validators.required, Validators.minLength(10), Validators.maxLength(10)])],
payment_mode: [data.payment_mode, Validators.compose([Validators.required])],
per_of_immediate_advance_payment:[data.per_of_immediate_advance_payment || ''],
credit_period:[data.credit_period || ''],
@@ -280,6 +280,15 @@ var result = Object.keys(supp_data).map(function(key) {
onReset() {
// this._addQuesFrom.reset();
}
+ /** On Key Press Event For Mobile Number */
+ keyPress(event: any) {
+ const pattern = /[0-9]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
// {
// 'main_raw_materials': 'sdkjfal',
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.html
index ec2f92b62..d3ce744d2 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.html
@@ -4,7 +4,7 @@
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts
index 99521e2a6..78dd06331 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/current-loan/current-loan.component.ts
@@ -138,4 +138,13 @@ export class CurrentLoanComponent implements OnInit {
}
});
}
+ /** On Key Press Event For Amount */
+ keyPress(event: any) {
+ const pattern = /[0-9]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.html
index 6ace32f28..afb0576b1 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.html
@@ -2,55 +2,55 @@
Employement Information
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.ts
index 119ac1e7a..860bad2e9 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/employment-info/employment-info.component.ts
@@ -36,10 +36,13 @@ export class EmploymentInfoComponent implements OnInit {
public employmentForm: FormGroup;
private notifier: NotifierService;
public pd_cus_segment:string;
+ public frequency_data:any[];
+
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
private router: Router,
private _pd: PdTrigerService) {
this.notifier = notifier;
+ //getAllMasterDatas();
}
ngOnInit() {
@@ -66,13 +69,25 @@ export class EmploymentInfoComponent implements OnInit {
}
this.employmentForm.controls['attendance_seen'].setValue(value.records.attendance_seen);
this.employmentForm.controls['sal_reg_seen'].setValue(value.records.sal_reg_seen);
+ this.employmentForm.controls['which_date_the_salary_is_rcv'].setValue(value.records.which_date_the_salary_is_rcv);
this.employmentForm.controls['gross_monthly_salary'].setValue(value.records.gross_monthly_salary);
this.employmentForm.controls['net_monthly_salary'].setValue(value.records.net_monthly_salary);
this.employmentForm.controls['bonus_incentive'].setValue(value.records.bonus_incentive);
+ this.employmentForm.controls['bonus_frequency'].setValue(value.records.bonus_frequency);
+ this.employmentForm.controls['bonus_type'].setValue(value.records.bonus_type);
+ this.employmentForm.controls['bonus_type_other'].setValue(value.records.bonus_type_other);
this.employmentForm.controls['any_delays'].setValue(value.records.any_delays);
this.employmentForm.controls['employment_remarks'].setValue(value.records.employment_remarks);
}
})
+ /** For Bonus Frequency Dropdown */
+ this._pd.getAllMasterDatas('FREQUENCY').subscribe(
+ data => {
+ if (data.status == 200) {
+ this.frequency_data = data.records;
+ this.frequency_data = this.frequency_data.filter(freq=>freq.isactive == 1 );
+ }
+ });
}
public initemploymentForm(): void {
this.employmentForm = this.fb.group({
@@ -86,9 +101,13 @@ export class EmploymentInfoComponent implements OnInit {
confirm_salary_amount: [''],
attendance_seen: [this.pd_cus_segment=='SAL-CHQ' ? 'No' : '', Validators.compose([Validators.required])],
sal_reg_seen: [this.pd_cus_segment=='SAL-CHQ' ? 'No' : '', Validators.compose([Validators.required])],
+ which_date_the_salary_is_rcv:[''],
gross_monthly_salary: ['', Validators.compose([Validators.required])],
net_monthly_salary: ['', Validators.compose([Validators.required])],
bonus_incentive: ['', Validators.compose([Validators.required])],
+ bonus_frequency: [''],
+ bonus_type: [''],
+ bonus_type_other: [''],
any_delays: ['', Validators.compose([Validators.required])],
employment_remarks: ['', Validators.compose([Validators.required])],
});
@@ -115,9 +134,13 @@ export class EmploymentInfoComponent implements OnInit {
}
records.attendance_seen = this.employmentForm.controls['attendance_seen'].value;
records.sal_reg_seen = this.employmentForm.controls['sal_reg_seen'].value;
+ records.which_date_the_salary_is_rcv = this.employmentForm.controls['which_date_the_salary_is_rcv'].value;
records.gross_monthly_salary = this.employmentForm.controls['gross_monthly_salary'].value;
records.net_monthly_salary = this.employmentForm.controls['net_monthly_salary'].value;
records.bonus_incentive = this.employmentForm.controls['bonus_incentive'].value;
+ records.bonus_frequency = this.employmentForm.controls['bonus_frequency'].value;
+ records.bonus_type = this.employmentForm.controls['bonus_type'].value;
+ records.bonus_type_other = this.employmentForm.controls['bonus_type_other'].value;
records.any_delays = this.employmentForm.controls['any_delays'].value;
records.employment_remarks = this.employmentForm.controls['employment_remarks'].value;
console.log('data', records);
@@ -128,5 +151,14 @@ export class EmploymentInfoComponent implements OnInit {
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
})
}
+ /** On Key Press Event For Numbers */
+ keyPress(event: any) {
+ const pattern = /[0-9]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/family-details/family-details.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/family-details/family-details.component.html
index 526514332..5053fbe6c 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/family-details/family-details.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/family-details/family-details.component.html
@@ -4,7 +4,7 @@
Family Details
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/financial-info/financial-info.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/financial-info/financial-info.component.ts
index cc3b02487..19b660937 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/financial-info/financial-info.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/financial-info/financial-info.component.ts
@@ -191,4 +191,14 @@ export class FinancialInfoComponent implements OnInit {
}
});
}
+
+ /** On Key Press Event For Input Field */
+ keyPress(event: any) {
+ const pattern = /[0-9\-\.\ ]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html
index db7dbacfa..082d27377 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/loan-details/loan-details.component.html
@@ -2,10 +2,10 @@
Loan Details
-
-
+
+
-
-
+
+
+ Valid Mobile Number Requried
+ Vaild Mobile Number Requried
+
-
+
{{ feq.name }}
+
-
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/supplier-info/supplier-info.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/supplier-info/supplier-info.component.ts
index e359094f9..cc0166ca1 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/supplier-info/supplier-info.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/forms/supplier-info/supplier-info.component.ts
@@ -179,7 +179,7 @@ apiLoadFinish: boolean = false;
return this._formBuilder.group({
supplier_name: ['', Validators.compose([Validators.required])],
contact_person: ['', Validators.compose([Validators.required])],
- mobile_number: ['', Validators.compose([Validators.required])],
+ mobile_number: ['', Validators.compose([Validators.required, Validators.minLength(10), Validators.maxLength(10)])],
payment_mode: ['', Validators.compose([Validators.required])],
per_of_immediate_advance_payment:[''],
credit_period:[''],
@@ -192,7 +192,7 @@ apiLoadFinish: boolean = false;
return this._formBuilder.group({
supplier_name: [data.supplier_name, Validators.compose([Validators.required])],
contact_person: [data.contact_person, Validators.compose([Validators.required])],
- mobile_number: [data.mobile_number, Validators.compose([Validators.required])],
+ mobile_number: [data.mobile_number, Validators.compose([Validators.required, Validators.minLength(10), Validators.maxLength(10)])],
payment_mode: [data.payment_mode, Validators.compose([Validators.required])],
per_of_immediate_advance_payment:[data.per_of_immediate_advance_payment || ''],
credit_period:[data.credit_period || ''],
@@ -284,6 +284,16 @@ apiLoadFinish: boolean = false;
// this._addQuesFrom.reset();
}
+ /** On Key Press Event For Mobile Number */
+ keyPress(event: any) {
+ const pattern = /[0-9]/;
+
+ let inputChar = String.fromCharCode(event.charCode);
+ if (event.keyCode != 8 && !pattern.test(inputChar)) {
+ event.preventDefault();
+ }
+ }
+
// {
// 'main_raw_materials': 'sdkjfal',
// 'supplier_details' ; [
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.html
index 61a3146a5..b426f5d57 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.html
@@ -31,9 +31,12 @@
{{ (formButton.form_name.length>17)? (formButton.form_name | slice:0:17)+'..':(formButton.form_name) }}
-
-
+
+
+
+
+
@@ -407,7 +410,7 @@
-
+
@@ -433,9 +436,12 @@
-
+
+
+
+
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts
index 627291c50..34c87317c 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/start-pd/start-pd.component.ts
@@ -29,6 +29,7 @@ export class StartPdComponent implements OnInit, OnDestroy {
answerList: any = [];
ansPDList: any = [];
relationDetails: any = [1];
+ rentalDetail: any = { form_id: "16", form_name: "Rental Information", isAnswered: true}
// errorMessage:any;
// selectedCategory:any=[];
// categoryList: any=[];
@@ -294,6 +295,7 @@ pdFullDetails:any=[];
this.pdMasterList=data.records.pdmaster_details;
this.categoryList=data.records.question_answers;
this.categoryFormButtons = data.records.template_forms;
+ console.log('formButtons', this.categoryFormButtons);
let filterApplicantName= data.records.pdapplicants_detials.filter(item => item.applicant_type == 1);
this.mainApplicantName = filterApplicantName[0].applicant_name;
this.currentPDStatus = data.records.pdmaster_details.pd_status;
@@ -625,6 +627,7 @@ pdFullDetails:any=[];
OnSelectDirectForms(details: any) {
this.formsCategoryEnable = true;
this.selectedFormsCategory = details;
+ console.log('select..', this.selectedFormsCategory);
}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/tele-pd-allocation/tele-pd-allocation.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/tele-pd-allocation/tele-pd-allocation.component.html
index 125066e83..fc8ef5769 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/tele-pd-allocation/tele-pd-allocation.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/tele-pd-allocation/tele-pd-allocation.component.html
@@ -13,11 +13,11 @@
0" >
-
+
- ![No Image]()
+ ![No Image]()
{{officer.first_name}}
{{officer.mobile_no}}
diff --git a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html
index 34b5b48c5..631982786 100644
--- a/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html
+++ b/ng6-seed/src/app/personal-discussion/manage-pd/list-pd/view-pd/view-pd.component.html
@@ -12,6 +12,9 @@
+
+
+
-
-
diff --git a/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts b/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts
index 1c5c0a727..0207a9a5f 100644
--- a/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts
+++ b/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts
@@ -79,7 +79,8 @@ export class PdNotificationListComponent implements OnInit {
//To get data for listing
getPdNotification() {
- this._MastersService.getAllPDNotification().subscribe(
+ //this._MastersService.getAllPDNotification().subscribe(
+ this._MastersService.getAllMasterData('PDNOTIFICATION').subscribe(
data => {
// console.log(data);
// console.log(data.status);
diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts
index b4e93019b..160249623 100644
--- a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts
+++ b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts
@@ -6,24 +6,26 @@ import { FormBuilder,
import { MatDialog,
MatDialogRef,
MAT_DIALOG_DATA } from '@angular/material';
+
/** Service */
import { MastersService } from '../../service/masters/masters.service';
import { PdTeamService } from '../../service/masters/pd-team.service';
- import { NotifierService } from 'angular-notifier';
+ import { Router } from '@angular/router';
+ import { empty } from 'rxjs';
-import { Router } from '@angular/router';
-import { empty } from 'rxjs';
/**sweet alert */
import Swal from 'sweetalert2';
+
@Component({
selector: 'app-pd-team-add',
templateUrl: './pd-team-add.component.html',
styleUrls: ['./pd-team-add.component.scss']
})
+
export class PdTeamAddComponent implements OnInit {
public _pdTeamForm: FormGroup;
-private notifier: NotifierService;
+
color = 'primary';
errorMessage:string;
@@ -42,17 +44,16 @@ selectedProductDatas : any=[];
selectedSegmentDatas : any=[];
constructor(private _formBuilder: FormBuilder,
- private _notifier: NotifierService,
private _pdTeamService: PdTeamService,
private _router: Router,
private _masterService: MastersService)
{
- this.notifier = _notifier;
+
}
ngOnInit() {
- //console.log(this.notifier);
+
this.PdTeamFormDatas();
/** For Checking City Validation datas - checking purpose - Already exists are not */
@@ -143,15 +144,16 @@ onSubmit() {
this._pdTeamService.addPdTeamDetail(this._pdTeamForm.value).subscribe(
dataresult => {
if(dataresult.dataStatus == true) {
- this.notifier.notify('success', 'Record Saved Successfully.!');
+
Swal('Record Saved Successfully.!','success');
this._router.navigate(['/setting/pdteam/pdteamlist']);
+
}
else {
- this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
- Swal('Wrong.!');
- //alert('Some Thing Wents Wrong Try Again !');
+
+ //Swal('Wrong.!');
+ Swal('Some Thing Wents Wrong Try Again !');
//this.errorMessage = "Some Thing Wents Wrong Try Again !";
}
});
@@ -225,13 +227,12 @@ onChangeEntityId($event){
}
if($event.isUserInput != false){
- //console.log(this.CityValidation,lenderId);
+ //console.log(this.CityValidation,lenderId);
this._pdTeamService.getLenderData(lenderId).subscribe(
dataresult => {
-
if(dataresult.dataStatus == true) {
this.CityValidation = dataresult.records;
- console.log(this.CityValidation);
+ //console.log(this.CityValidation);
}
}, error => this.errorMessage =
error);
}
@@ -263,7 +264,7 @@ onChangeCityDatas($event){
mycheck = 1;
}
}
- }
+ }
if(mycheck == 0){
this.selectedCityDatas.push(cityName.name);
diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html
index 4a7f784b1..c15dee04b 100644
--- a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html
+++ b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html
@@ -1,4 +1,4 @@
-
+