diff --git a/src/ts/containers/member/Regist.tsx b/src/ts/containers/member/Regist.tsx index fef10cf..8954777 100644 --- a/src/ts/containers/member/Regist.tsx +++ b/src/ts/containers/member/Regist.tsx @@ -13,6 +13,7 @@ import SelectField from 'material-ui/SelectField'; import MenuItem from 'material-ui/MenuItem'; import Slider from 'material-ui/Slider'; +import { OFRest } from '../../components/Rest'; const styles = { body: { @@ -79,84 +80,22 @@ export class Regist extends React.Component { "phone": this.state.phone }; + let os: OFRest = new OFRest("Member", "Regist", obj); + + os.Call().then(function (res) { + return res.json(); + }).then(function (json) { + console.log(json); + }).catch(function (err) { + console.log(err); + }); + } public validateEmail(email: any) { return EMailRegex.test(email); } - handleTestRead = () => { - let output: string; - let obj: any; //new object declaration - obj = { - "id": this.state.id, - "email": this.state.email, - "pwSalt": this.state.pw, - "name": this.state.name, - "company": this.state.company, - "phone": this.state.phone - }; - - let exeObj: any; - exeObj = { - "serviceName": "Member", - "methodName": "Read", - "param": obj - }; - - - output = JSON.stringify(exeObj); - - } - - handleTestUpdate = () => { - let output: string; - let obj: any; //new object declaration - obj = { - "id": this.state.id, - "email": this.state.email, - "pwSalt": this.state.pw, - "name": this.state.name, - "company": this.state.company, - "phone": this.state.phone - }; - - let exeObj: any; - exeObj = { - "serviceName": "Member", - "methodName": "Modify", - "param": obj - }; - - - output = JSON.stringify(exeObj); - - } - - handleTestDelete = () => { - let output: string; - let obj: any; //new object declaration - obj = { - "id": this.state.id, - "email": this.state.email, - "pwSalt": this.state.pw, - "name": this.state.name, - "company": this.state.company, - "phone": this.state.phone - }; - - let exeObj: any; - exeObj = { - "serviceName": "Member", - "methodName": "Remove", - "param": obj - }; - - - output = JSON.stringify(exeObj); - - } - handleResultContainer = () => { } @@ -232,20 +171,7 @@ export class Regist extends React.Component { />
- - - - - -
- this.setState({ id: newValue })} - /> + ); }