profile ing
This commit is contained in:
parent
62c5fa2b99
commit
43169639cd
|
@ -1,42 +1,53 @@
|
||||||
<div class="ui-g">
|
<form [formGroup]="modifyForm" (ngSubmit)="modifyProfile()">
|
||||||
<div class="ui-g-12 ui-md-3">
|
<div class="ui-g">
|
||||||
<p-panel [showHeader]="false">
|
<div class="ui-g-12 ui-md-3">
|
||||||
<div class="ui-g">
|
<p-panel [showHeader]="false">
|
||||||
<div class="ui-g-12 ui-inputgroup ui-bottom-space-10">
|
<div class="ui-g">
|
||||||
|
<div class="ui-g-12 ui-inputgroup ui-bottom-space-10">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="ui-g-12 ui-bottom-space-10">
|
||||||
|
<img class="profile-image" src="assets/layout/images/dark-user-bg.png" />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</p-panel>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="ui-g-12 ui-bottom-space-10">
|
<div class="ui-g form-group">
|
||||||
<img class="profile-image" src="assets/layout/images/dark-user-bg.png" />
|
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</p-panel>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="ui-g form-group">
|
|
||||||
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
|
||||||
<span class="md-inputfield">
|
<span class="md-inputfield">
|
||||||
<input type="text" pInputText readonly value="overflow@loafle.com" [readonly]="true">
|
<input type="text" pInputText readonly value="{{member.email}}">
|
||||||
<label>Email</label>
|
<label>Email</label>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
||||||
<span class="md-inputfield">
|
<span class="md-inputfield">
|
||||||
<input type="text" pInputText readonly value="overflow" >
|
<input type="text" pInputText value="{{member.name}}" >
|
||||||
<label>Name</label>
|
<label>Name</label>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
||||||
<span class="md-inputfield">
|
<span class="md-inputfield">
|
||||||
<input type="text" pInputText readonly value="loafle" >
|
<input type="text" pInputText value="{{member.companyName}}" >
|
||||||
<label>Company Name</label>
|
<label>Company Name</label>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
<div class="ui-g-12 ui-md-6 ui-lg-6">
|
||||||
<span class="md-inputfield">
|
<span class="md-inputfield">
|
||||||
<input type="text" pInputText readonly value="010-4055-6699" >
|
<input type="text" pInputText value="{{member.phone}}" >
|
||||||
<label>Phone</label>
|
<label>Phone</label>
|
||||||
</span>
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="ui-g-12 ui-md-6 ui-lg-6" dir="rtl">
|
||||||
|
<button type="submit" [disabled]="selected" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-icon-left" dir="auto">
|
||||||
|
<span class="ui-button-icon-left ui-c fa fa-fw ui-icon-person"></span>
|
||||||
|
<span class="ui-button-text ui-c">Save</span>
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</form>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,13 @@
|
||||||
import { Component, OnInit } from '@angular/core';
|
import { Component, OnInit } from '@angular/core';
|
||||||
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
|
import { PagesComponent } from 'app/pages/pages.component';
|
||||||
|
|
||||||
|
import * as AuthStore from '../../store/auth';
|
||||||
|
import { Member } from '../../model';
|
||||||
|
import { AuthSelector } from '../../store';
|
||||||
|
import { Store } from '@ngrx/store';
|
||||||
|
import {FormBuilder, FormGroup} from '@angular/forms';
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'of-member-profile',
|
selector: 'of-member-profile',
|
||||||
|
@ -7,9 +16,39 @@ import { Component, OnInit } from '@angular/core';
|
||||||
})
|
})
|
||||||
export class ProfileComponent implements OnInit {
|
export class ProfileComponent implements OnInit {
|
||||||
|
|
||||||
constructor() { }
|
member: Member;
|
||||||
|
modifyForm: FormGroup;
|
||||||
|
|
||||||
|
constructor(
|
||||||
|
public app: PagesComponent,
|
||||||
|
private activatedRoute: ActivatedRoute,
|
||||||
|
private router: Router,
|
||||||
|
private store: Store<AuthStore.State>,
|
||||||
|
private formBuilder: FormBuilder,
|
||||||
|
) {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
|
this.store.select(AuthSelector.select('member')).subscribe(
|
||||||
|
(member: Member) => {
|
||||||
|
this.member = member;
|
||||||
|
},
|
||||||
|
(error) => {
|
||||||
|
console.log(error);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
this.initForm();
|
||||||
|
}
|
||||||
|
|
||||||
|
initForm() {
|
||||||
|
this.modifyForm = this.formBuilder.group({
|
||||||
|
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
modifyProfile() {
|
||||||
|
console.log('clicked');
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user