Browse Source

上传文件至 ''

0225221 7 months ago
parent
commit
4bf31f4e87
5 changed files with 112 additions and 0 deletions
  1. 20 0
      tab3.module.ts
  2. 40 0
      tab3.page.html
  3. BIN
      tab3.page.scss
  4. 26 0
      tab3.page.spec.ts
  5. 26 0
      tab3.page.ts

+ 20 - 0
tab3.module.ts

@@ -0,0 +1,20 @@
+import { IonicModule } from '@ionic/angular';
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Tab3Page } from './tab3.page';
+import { ExploreContainerComponentModule } from '../explore-container/explore-container.module';
+
+import { Tab3PageRoutingModule } from './tab3-routing.module';
+
+@NgModule({
+  imports: [
+    IonicModule,
+    CommonModule,
+    FormsModule,
+    ExploreContainerComponentModule,
+    Tab3PageRoutingModule
+  ],
+  declarations: [Tab3Page]
+})
+export class Tab3PageModule {}

+ 40 - 0
tab3.page.html

@@ -0,0 +1,40 @@
+<ion-header [translucent]="true">
+    <ion-toolbar>
+      <ion-title>
+        个人中心
+      </ion-title>
+    </ion-toolbar>
+  </ion-header>
+  
+  
+  
+  <ion-header>
+    <ion-toolbar>
+      <ion-title class="ion-text-center">个人主页</ion-title>
+    </ion-toolbar>
+  </ion-header>
+  
+  <ion-content>
+    <ion-list>
+      <ion-item>
+        <ion-label position="floating">姓名</ion-label>
+        <ion-input type="text" value="" disabled></ion-input>
+      </ion-item>
+      <ion-item>
+        <ion-label position="floating">个性签名</ion-label>
+        <ion-input type="text" value="这是我的个性签名" disabled></ion-input>
+      </ion-item>
+      <ion-item>
+        <ion-label position="floating">性别</ion-label>
+        <ion-input type="text" value="" disabled></ion-input>
+      </ion-item>
+      <ion-item>
+        <ion-label position="floating">邮箱</ion-label>
+        <ion-input type="email" value="" disabled></ion-input>
+      </ion-item>
+      <ion-button expand="full" (click)="goToSecuritySettings()">安全设置</ion-button>
+      <ion-button expand="full" (click)="goToEditPage()">进入编辑</ion-button>
+      <ion-button expand="full" (click)="leftToEditPage()">退出编辑</ion-button>
+    </ion-list>
+  </ion-content>
+  

BIN
tab3.page.scss


+ 26 - 0
tab3.page.spec.ts

@@ -0,0 +1,26 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+import { IonicModule } from '@ionic/angular';
+
+import { ExploreContainerComponentModule } from '../explore-container/explore-container.module';
+
+import { Tab3Page } from './tab3.page';
+
+describe('Tab3Page', () => {
+  let component: Tab3Page;
+  let fixture: ComponentFixture<Tab3Page>;
+
+  beforeEach(async () => {
+    await TestBed.configureTestingModule({
+      declarations: [Tab3Page],
+      imports: [IonicModule.forRoot(), ExploreContainerComponentModule]
+    }).compileComponents();
+
+    fixture = TestBed.createComponent(Tab3Page);
+    component = fixture.componentInstance;
+    fixture.detectChanges();
+  });
+
+  it('should create', () => {
+    expect(component).toBeTruthy();
+  });
+});

+ 26 - 0
tab3.page.ts

@@ -0,0 +1,26 @@
+import { Component } from '@angular/core';
+import { NavController } from '@ionic/angular';
+@Component({
+  selector: 'app-tab3',
+  templateUrl: 'tab3.page.html',
+  styleUrls: ['tab3.page.scss']
+})
+export class Tab3Page {
+
+  constructor(private navCtrl: NavController) {}
+
+  goToEditPage() {
+    this.navCtrl.navigateForward('/profile-edit');
+  }
+  leftToEditPage()
+  {
+    this.navCtrl.navigateForward('/tabs');
+  }
+
+  goToSecuritySettings() {
+    // 导航到安全设置页面的逻辑
+    this.navCtrl.navigateForward('/security-settings');
+  }
+}