설정 DB 주소
에이. src/aircto/model/init.go 파일에서 적절한 DB 연결 주소를 제공하십시오.
비. sql.Open("mysql", "homestead:secret@tcp([192.168.11.11]:3306)/")
기음. DB 연결 주소를 여기에서 교체하십시오.
처음으로 DB 마이그레이션을 실행하십시오
에이. mani@Mani:~/aircto-assignments-16_08/src$ 프로젝트 디렉토리로 이동하십시오.
비. run go run aircto/migration/run_migration.go
기음. 이제 데이터베이스 및 user 일부 사용자로 생성 된 테이블을 issues 하고 시드 데이터를 발행합니다. 디. 사용자를 생성 할 API가 없으며 종자 사용자 데이터를 사용하십시오. 여기에서 모든 사용자 목록을 찾을 수 있습니다 http://localhost:3011/api/users
코드를 실행하십시오.
에이. mani@Mani:~/aircto-assignments-16_08/src$ 프로젝트 디렉토리로 이동하십시오.
비. go run aircto/main.go
비. 이제 서버는 http://localhost:3011/api/ 로 제공되기 시작했습니다.
테스트 할 수있는 API.
# The following API's no need of any authendication/access token
1. http://localhost:3011/api/
2. http://localhost:3011/api/users
3. http://localhost:3011/api/login
< br / >
# After login access token will be provided for the user, need to send access token along with the request.
1. http://localhost:3011/api/issues // get - all issues
2. http://localhost:3011/api/issue/{issueID:[0-9]+} // get - issue details
3. http://localhost:3011/api/issue // post - create issue
4. http://localhost:3011/api/issue/{issueID:[0-9]+} // put - update issue info
5. http://localhost:3011/api/issue/{issueID:[0-9]+} // delete - delete issue
6. http://localhost:3011/api/issues-by-me
7. http://localhost:3011/api/issues-for-me
Every issue created or updated mail will send to the assigned user with issue info.
Cron Job for generate report mail to all the user. API에 대한 자세한 정보가 필요합니다. 다음 우편 번호 문서를 참조하십시오.
참고 :이 문서에 수명이 제한되어 있습니다.
자세한 내용은 @ [email protected], 9578628779, Skype : Manigandan.dharmalingam
디자인 : 시스템에는 사용자와 문제라는 두 가지 모델이 있습니다. 다음 정보로
#1. 사용자
에이. 이메일 b. 사용자 이름 c. FirstName d. 마지막 이름 e. 비밀번호 f. AccessToken
#2. 문제
문제 설명 : 문제 자원의 CRUD 작동을 위해 편안한 API를 노출시킵니다.
메모: