Browse Source

fix: dirs with study case

RyaneMax 9 months ago
parent
commit
d682a541a9
29 changed files with 65 additions and 24 deletions
  1. 3 3
      src/app/app-routing.module.ts
  2. 38 8
      src/app/tab1/tab1.page.html
  3. 1 0
      src/app/tab1/tab1.page.ts
  4. 0 0
      src/modules/study/case-angular/comps/edit-ratio-star/README.md
  5. 0 0
      src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.html
  6. 0 0
      src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.scss
  7. 0 0
      src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.spec.ts
  8. 0 0
      src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.ts
  9. 0 0
      src/modules/study/case-angular/pages/case-edit/case-edit-routing.module.ts
  10. 1 1
      src/modules/study/case-angular/pages/case-edit/case-edit.module.ts
  11. 0 0
      src/modules/study/case-angular/pages/case-edit/case-edit.page.html
  12. 0 0
      src/modules/study/case-angular/pages/case-edit/case-edit.page.scss
  13. 0 0
      src/modules/study/case-angular/pages/case-edit/case-edit.page.spec.ts
  14. 0 0
      src/modules/study/case-angular/pages/case-edit/case-edit.page.ts
  15. 0 0
      src/modules/study/case-angular/pages/tsdatatype/tsdatatype-routing.module.ts
  16. 0 0
      src/modules/study/case-angular/pages/tsdatatype/tsdatatype.module.ts
  17. 0 0
      src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.html
  18. 0 0
      src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.scss
  19. 0 0
      src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.spec.ts
  20. 0 0
      src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.ts
  21. 22 0
      src/modules/study/case-js-module/case-edit/case-edit.module.ts
  22. 0 0
      src/modules/study/case-js-module/pages/slider/README.md
  23. 0 0
      src/modules/study/case-js-module/pages/slider/slider-routing.module.ts
  24. 0 0
      src/modules/study/case-js-module/pages/slider/slider.module.ts
  25. 0 0
      src/modules/study/case-js-module/pages/slider/slider.page.html
  26. 0 0
      src/modules/study/case-js-module/pages/slider/slider.page.scss
  27. 0 0
      src/modules/study/case-js-module/pages/slider/slider.page.spec.ts
  28. 0 0
      src/modules/study/case-js-module/pages/slider/slider.page.ts
  29. 0 12
      src/modules/study/study.module.ts

+ 3 - 3
src/app/app-routing.module.ts

@@ -16,15 +16,15 @@ const routes: Routes = [
   },
   {
     path: 'tsdatatype',
-    loadChildren: () => import('./tsdatatype/tsdatatype.module').then( m => m.TsdatatypePageModule)
+    loadChildren: () => import('../modules/study/case-angular/pages/tsdatatype/tsdatatype.module').then( m => m.TsdatatypePageModule)
   },
   {
     path: 'slider',
-    loadChildren: () => import('./slider/slider.module').then( m => m.SliderPageModule)
+    loadChildren: () => import('../modules/study/case-js-module/pages/slider/slider.module').then( m => m.SliderPageModule)
   },
   {
     path: 'case-edit',
-    loadChildren: () => import('./case-edit/case-edit.module').then( m => m.CaseEditPageModule)
+    loadChildren: () => import('../modules/study/case-angular/pages/case-edit/case-edit.module').then( m => m.CaseEditPageModule)
   }
 ];
 @NgModule({

+ 38 - 8
src/app/tab1/tab1.page.html

@@ -1,7 +1,7 @@
 <ion-header [translucent]="true">
   <ion-toolbar>
     <ion-title>
-      使用说明
+      教学案例库
     </ion-title>
   </ion-toolbar>
 </ion-header>
@@ -9,15 +9,45 @@
 <ion-content [fullscreen]="true">
   <ion-header collapse="condense">
     <ion-toolbar>
-      <ion-title size="large">使用说明</ion-title>
+      <ion-title size="large">教学案例库</ion-title>
     </ion-toolbar>
   </ion-header>
 
+  <ion-segment [(ngModel)]="currentTab">
+    <ion-segment-button value="static">
+      纯静态案例
+    </ion-segment-button>
+    <ion-segment-button value="parse">
+      微服务案例
+    </ion-segment-button>
+  </ion-segment>
   <div *ngIf="safeHTML" [innerHTML]="safeHTML"></div>
-  <ion-button expand="block" routerLink="/tsdatatype">示例:TS数据类型与模板</ion-button>
-  <ion-button expand="block" routerLink="/slider">示例:Swiper轮播图插件</ion-button>
-  <ion-button expand="block" routerLink="/case-edit">示例:输入编辑组件</ion-button>
-  <ion-button expand="block" routerLink="/tabs/tab2">示例:通讯录列表</ion-button>
-  <ion-button expand="block" (click)="openGit()">代码:study-ng-contact</ion-button>
-  <ion-button expand="block" routerLink="/aigc/chat">示例:AI对话示例</ion-button>
+  
+  <ion-card>
+    <ion-card-title>纯静态案例</ion-card-title>
+    <ion-card-content>
+      <ion-button expand="block" routerLink="/tsdatatype">语法:TS数据类型与模板</ion-button>
+      <ion-button expand="block" routerLink="/case-edit">交互:输入编辑组件</ion-button>
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card>
+    <ion-card-title>第三方组件(非Angular)</ion-card-title>
+    <ion-card-subtitle>
+      该类组件,一般为js组件,通过types实现的兼容调用
+    </ion-card-subtitle>
+    <ion-card-content>
+      <ion-button expand="block" routerLink="/slider">展示:Swiper轮播图插件</ion-button>
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card>
+    <ion-card-title>微服务案例</ion-card-title>
+    <ion-card-content>
+      <ion-button expand="block" (click)="openGit()">代码:study-ng-contact</ion-button>
+      <ion-button expand="block" routerLink="/tabs/tab2">示例:通讯录列表</ion-button>
+      <ion-button expand="block" routerLink="/aigc/chat">示例:AI对话示例</ion-button>
+    </ion-card-content>
+  </ion-card>
+
 </ion-content>

+ 1 - 0
src/app/tab1/tab1.page.ts

@@ -8,6 +8,7 @@ import { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';
 })
 export class Tab1Page {
 
+  currentTab:string = "static"
   safeHTML: SafeResourceUrl|undefined
   constructor(private domSan:DomSanitizer) {
     this.safeHTML = domSan.bypassSecurityTrustHtml(``)

+ 0 - 0
src/app/edit-ratio-star/README.md → src/modules/study/case-angular/comps/edit-ratio-star/README.md


+ 0 - 0
src/app/edit-ratio-star/edit-ratio-star.component.html → src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.html


+ 0 - 0
src/app/edit-ratio-star/edit-ratio-star.component.scss → src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.scss


+ 0 - 0
src/app/edit-ratio-star/edit-ratio-star.component.spec.ts → src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.spec.ts


+ 0 - 0
src/app/edit-ratio-star/edit-ratio-star.component.ts → src/modules/study/case-angular/comps/edit-ratio-star/edit-ratio-star.component.ts


+ 0 - 0
src/app/case-edit/case-edit-routing.module.ts → src/modules/study/case-angular/pages/case-edit/case-edit-routing.module.ts


+ 1 - 1
src/app/case-edit/case-edit.module.ts → src/modules/study/case-angular/pages/case-edit/case-edit.module.ts

@@ -7,7 +7,7 @@ import { IonicModule } from '@ionic/angular';
 import { CaseEditPageRoutingModule } from './case-edit-routing.module';
 
 import { CaseEditPage } from './case-edit.page';
-import { EditRatioStarComponent } from '../edit-ratio-star/edit-ratio-star.component';
+import { EditRatioStarComponent } from '../../comps/edit-ratio-star/edit-ratio-star.component';
 
 @NgModule({
   imports: [

+ 0 - 0
src/app/case-edit/case-edit.page.html → src/modules/study/case-angular/pages/case-edit/case-edit.page.html


+ 0 - 0
src/app/case-edit/case-edit.page.scss → src/modules/study/case-angular/pages/case-edit/case-edit.page.scss


+ 0 - 0
src/app/case-edit/case-edit.page.spec.ts → src/modules/study/case-angular/pages/case-edit/case-edit.page.spec.ts


+ 0 - 0
src/app/case-edit/case-edit.page.ts → src/modules/study/case-angular/pages/case-edit/case-edit.page.ts


+ 0 - 0
src/app/tsdatatype/tsdatatype-routing.module.ts → src/modules/study/case-angular/pages/tsdatatype/tsdatatype-routing.module.ts


+ 0 - 0
src/app/tsdatatype/tsdatatype.module.ts → src/modules/study/case-angular/pages/tsdatatype/tsdatatype.module.ts


+ 0 - 0
src/app/tsdatatype/tsdatatype.page.html → src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.html


+ 0 - 0
src/app/tsdatatype/tsdatatype.page.scss → src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.scss


+ 0 - 0
src/app/tsdatatype/tsdatatype.page.spec.ts → src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.spec.ts


+ 0 - 0
src/app/tsdatatype/tsdatatype.page.ts → src/modules/study/case-angular/pages/tsdatatype/tsdatatype.page.ts


+ 22 - 0
src/modules/study/case-js-module/case-edit/case-edit.module.ts

@@ -0,0 +1,22 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+
+import { IonicModule } from '@ionic/angular';
+
+import { CaseEditPageRoutingModule } from './case-edit-routing.module';
+
+import { CaseEditPage } from './case-edit.page';
+import { EditRatioStarComponent } from '../../case-angular/comps/edit-ratio-star/edit-ratio-star.component';
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    CaseEditPageRoutingModule,
+    EditRatioStarComponent
+  ],
+  declarations: [CaseEditPage]
+})
+export class CaseEditPageModule {}

+ 0 - 0
src/app/slider/README.md → src/modules/study/case-js-module/pages/slider/README.md


+ 0 - 0
src/app/slider/slider-routing.module.ts → src/modules/study/case-js-module/pages/slider/slider-routing.module.ts


+ 0 - 0
src/app/slider/slider.module.ts → src/modules/study/case-js-module/pages/slider/slider.module.ts


+ 0 - 0
src/app/slider/slider.page.html → src/modules/study/case-js-module/pages/slider/slider.page.html


+ 0 - 0
src/app/slider/slider.page.scss → src/modules/study/case-js-module/pages/slider/slider.page.scss


+ 0 - 0
src/app/slider/slider.page.spec.ts → src/modules/study/case-js-module/pages/slider/slider.page.spec.ts


+ 0 - 0
src/app/slider/slider.page.ts → src/modules/study/case-js-module/pages/slider/slider.page.ts


+ 0 - 12
src/modules/study/study.module.ts

@@ -1,12 +0,0 @@
-import { NgModule } from '@angular/core';
-import { CommonModule } from '@angular/common';
-
-
-
-@NgModule({
-  declarations: [],
-  imports: [
-    CommonModule
-  ]
-})
-export class StudyModule { }