diff --git a/HRM.DA/DA/SearchReport/SearchEmployeeDA.cs b/HRM.DA/DA/SearchReport/SearchEmployeeDA.cs index d0347e3..1981e04 100644 --- a/HRM.DA/DA/SearchReport/SearchEmployeeDA.cs +++ b/HRM.DA/DA/SearchReport/SearchEmployeeDA.cs @@ -231,7 +231,11 @@ END;"; { string orderby = "name"; string sqlClause = ""; - sqlClause = SQLParser.TagSQL(sqlClause) + SQLParser.MakeSQL("PayrollTypeID =%n AND Status = %n", payrollTypeID, EnumStatus.Active); + //Previous Code For only Live Employee + //sqlClause = SQLParser.TagSQL(sqlClause) + SQLParser.MakeSQL("PayrollTypeID =%n AND Status = %n", payrollTypeID, EnumStatus.Active); + + //New Code For live And Waitiong for join Employee + sqlClause = SQLParser.TagSQL(sqlClause) + SQLParser.MakeSQL("PayrollTypeID =%n AND Status = %n OR Status = %n", payrollTypeID, EnumEmployeeStatus.Live, EnumEmployeeStatus.Waitingforjoin); if (code != string.Empty) { sqlClause = SQLParser.TagSQL(sqlClause) + SQLParser.MakeSQL("EmployeeNo LIKE %s", ("%" + code + "%")); diff --git a/HRM.UI/ClientApp/src/app/_models/Employee/employee.ts b/HRM.UI/ClientApp/src/app/_models/Employee/employee.ts index 18eb0f3..6e9e09d 100644 --- a/HRM.UI/ClientApp/src/app/_models/Employee/employee.ts +++ b/HRM.UI/ClientApp/src/app/_models/Employee/employee.ts @@ -138,7 +138,7 @@ export class Employee { this.taxCircle = EnumTaxCircle.CityCorporation; this.isConfirmed = false; this.endOfContractDate = null; - this.status = EnumEmployeeStatus.Live; + this.status = EnumEmployeeStatus.Waitingforjoin; this.statusName = ''; this.isShownInTaxSheet = false; this.pfMemberType = EnumPFMembershipType.NotYetLive; @@ -219,6 +219,9 @@ export class Employee { case EnumEmployeeStatus.Discontinued: str = "Discontinued"; break; + case EnumEmployeeStatus.Waitingforjoin: + str = "Waiting For Join"; + break; default: } diff --git a/HRM.UI/ClientApp/src/app/picker/employee-picker.component.ts b/HRM.UI/ClientApp/src/app/picker/employee-picker.component.ts index 96239a9..763a9ba 100644 --- a/HRM.UI/ClientApp/src/app/picker/employee-picker.component.ts +++ b/HRM.UI/ClientApp/src/app/picker/employee-picker.component.ts @@ -602,10 +602,18 @@ export class EmployeePickerComponent implements OnInit { } if (this.checkLive === true) { + //Previous Code For Only Live Employee srcManager.Parameter.AddParam(EnumSearchParameter.Status, EnumSearchObjDataType.Number, 1, EnumSQLOperator.EqualTo); + + //New Code For Live And Waiting For Join + // srcManager.Parameter.AddParam(EnumSearchParameter.Status, EnumSearchObjDataType.Number, '1,6', EnumSQLOperator.In); } if (this.checkLiveNo === true) { - srcManager.Parameter.AddParam(EnumSearchParameter.Status, EnumSearchObjDataType.Number, 2, EnumSQLOperator.EqualTo); + //Previous Code For Only Not Live + // srcManager.Parameter.AddParam(EnumSearchParameter.Status, EnumSearchObjDataType.Number, 2, EnumSQLOperator.EqualTo); + + //New Code For Live And Waiting For Join + srcManager.Parameter.AddParam(EnumSearchParameter.Status, EnumSearchObjDataType.Number, '2,6', EnumSQLOperator.In); } if (this.checkIA === true) srcManager.Parameter.AddParam(EnumSearchParameter.Status, EnumSearchObjDataType.Number, EnumEmployeeStatus.IA, EnumSQLOperator.EqualTo);