flowaaa 1 жил өмнө
parent
commit
06a0c86565

+ 1 - 1
app-angular/src/modules/lesson/attention-detail/attention-detail.component.html

@@ -13,7 +13,7 @@
 </ion-header>
 <ion-content color="light">
     <ion-card>
-        <img alt="角色图" [src]="role?.get('img')" />
+        <img alt="角色图" [src]="attention?.get('img')" />
         <ion-card-header>
             <ion-card-title>{{attention?.get('name')}}</ion-card-title>
             <ion-card-subtitle>作者:{{attention?.get('user')?.get('name')||"某某某"}}</ion-card-subtitle>

+ 1 - 1
app-angular/src/modules/lesson/attention-detail/rattention-detail.component.ts

@@ -28,7 +28,7 @@ export class AttentionDetailComponent {
     }
   }
 
-  role: Parse.Object | undefined;
+  attention: Parse.Object | undefined;
   constructor(private router: ActivatedRoute) {
     this.router.queryParams.subscribe(param => {
       this.getRoleInfoById(param["id"])

+ 10 - 10
app-angular/src/modules/lesson/community/community.component.html

@@ -32,22 +32,22 @@
     <ng-container *ngIf="cate=='推荐'">
         <ion-grid>
             <ion-row>
-                <ng-container *ngFor="let role of recommendList">
+                <ng-container *ngFor="let attention of recommendList">
                     <ion-col size="6">
                         <ion-card class="roleCard" (click)="goRecommendDetail(attention)">
                             <img alt="推荐图" [src]="attention?.get('img')" />
                             <ion-card-header>
                                 <ion-card-title>
-                                    {{role?.get('name')}}
+                                    {{attention?.get('name')}}
                                 </ion-card-title>
                                 <ion-card-subtitle style="font-size:0.7rem;">
-                                    作者:{{role?.get('user')?.get('name')||"无名"}}
+                                    作者:{{attention?.get('user')?.get('name')||"无名"}}
                                 </ion-card-subtitle>
                             </ion-card-header>
                             <div class="metadata-end-wrapper">
                                 <ion-button shape="round" size="small" color="danger">
                                     <ion-icon name="heart-outline" size="small"></ion-icon>
-                                    {{role?.get('like')}}
+                                    {{attention?.get('like')}}
                                 </ion-button>
                             </div>
                         </ion-card>
@@ -62,22 +62,22 @@
     <ng-container *ngIf="cate=='关注'">
         <ion-grid>
             <ion-row>
-                <ng-container *ngFor="let role of attentionList">
+                <ng-container *ngFor="let attention of attentionList">
                     <ion-col size="6">
-                        <ion-card class="roleCard" (click)="goAttentionDetail(role)">
-                            <img alt="关注图" [src]="role?.get('img')" />
+                        <ion-card class="roleCard" (click)="goAttentionDetail(attention)">
+                            <img alt="关注图" [src]="attention?.get('img')" />
                             <ion-card-header>
                                 <ion-card-title>
-                                    {{role?.get('name')}}
+                                    {{attention?.get('name')}}
                                 </ion-card-title>
                                 <ion-card-subtitle style="font-size:0.7rem;">
-                                    作者:{{role?.get('user')?.get('name')||"无名"}}
+                                    作者:{{attention?.get('user')?.get('name')||"无名"}}
                                 </ion-card-subtitle>
                             </ion-card-header>
                             <div class="metadata-end-wrapper">
                                 <ion-button shape="round" size="small" color="danger">
                                     <ion-icon name="heart-outline" size="small"></ion-icon>
-                                    {{role?.get('like')}}
+                                    {{attention?.get('like')}}
                                 </ion-button>
                             </div>
                         </ion-card>

+ 4 - 4
app-angular/src/modules/lesson/community/community.component.ts

@@ -58,15 +58,15 @@ export class CommunityComponent {
     })
   }
 
-  goRecommendDetail(view: Parse.Object) {
+  goRecommendDetail(recommend: Parse.Object) {
     this.router.navigate(["/lesson/community/recommendDetail"], {
-      queryParams: view
+      queryParams: recommend
     })
   }
 
-  goAttentionDetail(role: Parse.Object) {
+  goAttentionDetail(attention: Parse.Object) {
     this.router.navigate(["/lesson/community/attentionDetail"], {
-      queryParams: role
+      queryParams: attention
     })
   }
 

+ 9 - 9
app-angular/src/modules/lesson/me/me.component.html

@@ -112,15 +112,15 @@
 
     <ng-container *ngIf="cate=='推荐'">
         <ion-list [inset]="true" lines="inset">
-            <ng-container *ngFor="let view of myViewList">
+            <ng-container *ngFor="let recommend of myViewList">
                 <ion-item>
                     <ion-thumbnail slot="end">
-                        <img alt="推荐图" [src]="view?.get('img')" />
+                        <img alt="推荐图" [src]="recommend?.get('img')" />
                     </ion-thumbnail>
                     <ion-label>
-                        <h2>{{view?.get('title')}}</h2>
-                        <p>{{view?.get('content')}}</p>
-                        <ion-note slot="start">{{view?.get('createdAt')| date: 'YYYY/MM/dd'||"发布时间"}}</ion-note>
+                        <h2>{{recommend?.get('title')}}</h2>
+                        <p>{{recommend?.get('content')}}</p>
+                        <ion-note slot="start">{{recommend?.get('createdAt')| date: 'YYYY/MM/dd'||"发布时间"}}</ion-note>
                     </ion-label>
                 </ion-item>
             </ng-container>
@@ -131,15 +131,15 @@
     <ng-container *ngIf="cate=='关注'">
         <ion-grid>
             <ion-row>
-                <ng-container *ngFor="let role of myRoleList">
+                <ng-container *ngFor="let attention of myRoleList">
                     <ion-col size="6">
                         <ion-card class="roleCard">
-                            <img alt="关注图" [src]="role?.get('img')" />
+                            <img alt="关注图" [src]="attention?.get('img')" />
                             <ion-card-header>
                                 <ion-card-title>
-                                    {{role?.get('name')}}
+                                    {{attention?.get('name')}}
                                 </ion-card-title>
-                                <ion-card-subtitle>{{role?.get('createdAt')| date:
+                                <ion-card-subtitle>{{attention?.get('createdAt')| date:
                                     'YYYY/MM/dd'||"发布时间"}}</ion-card-subtitle>
                             </ion-card-header>
 

+ 3 - 3
app-angular/src/modules/lesson/recommend-detail/recommend-detail.component.html

@@ -14,7 +14,7 @@
 </ion-header>
 <ion-content color="light">
     <ion-card>
-        <img alt="美景图" [src]="view?.get('img')" />
+        <img alt="美景图" [src]="recommend?.get('img')" />
         <ion-card-header>
             <ion-card-title>{{recommend?.get('name')}}</ion-card-title>
             <ion-card-subtitle>作者:{{recommend?.get('user')?.get('name')||"某某某"}}</ion-card-subtitle>
@@ -22,12 +22,12 @@
             <div class="metadata-end-wrapper">
                 <ion-button fill="clear" color="dark" size="small" class="see">
                     <ion-icon name="eye-outline" size="small"></ion-icon>
-                    <ion-note>{{view?.get('see')}}</ion-note>
+                    <ion-note>{{recommend?.get('see')}}</ion-note>
                 </ion-button>
             </div>
         </ion-card-header>
         <ion-card-content>
-            {{view?.get('content')}}
+            {{recommend?.get('content')}}
         </ion-card-content>
     </ion-card>
     <!-- 评论区 -->

+ 2 - 2
app-angular/src/modules/lesson/recommend-detail/recommend-detail.component.ts

@@ -28,10 +28,10 @@ export class RecommendDetailComponent {
   }
 
   //预设值变量
-  view: Parse.Object | undefined;
+  recommend: Parse.Object | undefined;
   // 依赖注入
   constructor(private route: ActivatedRoute) {
-    // 查询参数获取并赋值给this.view
+    // 查询参数获取并赋值给this.recommend
     this.route.queryParams.subscribe(params => {
       this.getViewInfoById(params["id"])
     })