Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@mrsus
Copy link
Contributor

@mrsus mrsus commented Aug 9, 2019

No description provided.


export class RangeDatePipe implements PipeTransform {
transform(rangeDates: any, args?: any): any {
if (rangeDates) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be part of shared.module.ts
We can reuse this pipe somewhere else

MatSelectModule,
MatToolbarModule
MatRippleModule,
MatSnackBarModule
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

file name should be kebab-case


export class ApiService {

FB_APP_ID = '303059286557418';
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need this file to handle constants.
Instead, we should use environment files.

let user = this.cookieService.getCookie("townscript-user");
console.log("got user from cookie" + user);
if (user != null && user.length > 0) {
this.updateUser(JSON.parse(user));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove console

}
return null;
}

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It can be part of shared module

</div>
<div class="flex items-center cursor-pointer" (click)="userMenu=!userMenu" *ngIf="user" matRipple>
<img class="rounded-full mr-2" width="36"
[src]="'https://s3.ap-south-1.amazonaws.com/townscript-testing/images/'+user?.s3imagename" />
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove hardcoding of baseUrl

<div class="flex items-center border-b py-2 border-gray-300">
<div class="mr-1 leading-none">
<img class="rounded-full mr-2" width="45"
[src]="'https://s3.ap-south-1.amazonaws.com/townscript-testing/images/'+user?.s3imagename" />
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove hardcoding of baseUrl

<img
src="https://s3.ap-southeast-1.amazonaws.com/common-resources/assets/facebook-min-new.png" />
</div>
<div class="text-sm">
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove hardcoding of baseUrl

export class UserMenuComponent implements OnInit {

@Input("panelOpen1") panelOpen1: boolean = false;
@Input("panelOpen2") panelOpen2: boolean = false;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wrong naming convention

}
logout() {
this.close.emit();
this.cookieService.deleteCookie("townscript-user");
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can have one method like - deleteUserCookie to avoid passing the name of cookie

@mrsus
Copy link
Contributor Author

mrsus commented Aug 12, 2019

@sid6323 @prabir09

sid6323 pushed a commit that referenced this pull request Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants