Commit 2db09f734204076751e63a286e3d983f2bea3115
1 parent
5cafd510
Exists in
master
แก้บัคคอมเม้น
Showing
1 changed file
with
4 additions
and
1 deletions
Show diff stats
src/app/dashboard/short.ts
@@ -8,6 +8,9 @@ export class ShortPipe implements PipeTransform { | @@ -8,6 +8,9 @@ export class ShortPipe implements PipeTransform { | ||
8 | if(value === null){ | 8 | if(value === null){ |
9 | value = ''; | 9 | value = ''; |
10 | } | 10 | } |
11 | - return value.substr(0, 25) + ' ...'; | 11 | + if (value.length > 25) { |
12 | + return value.substr(0, 25) + ' ...'; | ||
13 | + } | ||
14 | + return value; | ||
12 | } | 15 | } |
13 | } | 16 | } |
14 | \ No newline at end of file | 17 | \ No newline at end of file |