-
Notifications
You must be signed in to change notification settings - Fork 261
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #882 from colinin/fix-openiddict
Fix about openiddict
- Loading branch information
Showing
40 changed files
with
999 additions
and
270 deletions.
There are no files selected for viewing
118 changes: 76 additions & 42 deletions
118
apps/vue/src/api/openiddict/open-iddict-application/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,65 +1,99 @@ | ||
import { defAbpHttp } from '/@/utils/http/abp'; | ||
import { OpenIddictApplicationDto,OpenIddictApplicationGetListInput, OpenIddictApplicationCreateDto, OpenIddictApplicationUpdateDto, } from './model'; | ||
import { | ||
OpenIddictApplicationDto, | ||
OpenIddictApplicationGetListInput, | ||
OpenIddictApplicationCreateDto, | ||
OpenIddictApplicationUpdateDto, | ||
} from './model'; | ||
|
||
const remoteServiceName = 'AbpOpenIddict'; | ||
const controllerName = 'OpenIddictApplication'; | ||
// export const GetAsyncById = (id: string) => { | ||
// return defAbpHttp.request<OpenIddictApplicationDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'GetAsync', | ||
// uniqueName: 'GetAsyncById', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const GetAsyncById = (id: string) => { | ||
return defAbpHttp.request<OpenIddictApplicationDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'GetAsync', | ||
uniqueName: 'GetAsyncById', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.get<OpenIddictApplicationDto>({ | ||
url: `/api/openiddict/applications/${id}`, | ||
}); | ||
}; | ||
|
||
// export const GetListAsyncByInput = (input: OpenIddictApplicationGetListInput) => { | ||
// return defAbpHttp.pagedRequest<OpenIddictApplicationDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'GetListAsync', | ||
// uniqueName: 'GetListAsyncByInput', | ||
// params: { | ||
// input: input, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const GetListAsyncByInput = (input: OpenIddictApplicationGetListInput) => { | ||
return defAbpHttp.pagedRequest<OpenIddictApplicationDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'GetListAsync', | ||
uniqueName: 'GetListAsyncByInput', | ||
params: { | ||
input: input, | ||
}, | ||
return defAbpHttp.get<PagedResultDto<OpenIddictApplicationDto>>({ | ||
url: '/api/openiddict/applications', | ||
params: input, | ||
}); | ||
}; | ||
|
||
// export const CreateAsyncByInput = (input: OpenIddictApplicationCreateDto) => { | ||
// return defAbpHttp.request<OpenIddictApplicationDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'CreateAsync', | ||
// uniqueName: 'CreateAsyncByInput', | ||
// data: input, | ||
// }); | ||
// }; | ||
|
||
export const CreateAsyncByInput = (input: OpenIddictApplicationCreateDto) => { | ||
return defAbpHttp.request<OpenIddictApplicationDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'CreateAsync', | ||
uniqueName: 'CreateAsyncByInput', | ||
return defAbpHttp.post<OpenIddictApplicationDto>({ | ||
url: '/api/openiddict/applications', | ||
data: input, | ||
}); | ||
}; | ||
|
||
// export const UpdateAsyncByIdAndInput = (id: string, input: OpenIddictApplicationUpdateDto) => { | ||
// return defAbpHttp.request<OpenIddictApplicationDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'UpdateAsync', | ||
// uniqueName: 'UpdateAsyncByIdAndInput', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// data: input, | ||
// }); | ||
// }; | ||
|
||
export const UpdateAsyncByIdAndInput = (id: string, input: OpenIddictApplicationUpdateDto) => { | ||
return defAbpHttp.request<OpenIddictApplicationDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'UpdateAsync', | ||
uniqueName: 'UpdateAsyncByIdAndInput', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.put<OpenIddictApplicationDto>({ | ||
url: `/api/openiddict/applications/${id}`, | ||
data: input, | ||
}); | ||
}; | ||
|
||
// export const DeleteAsyncById = (id: string) => { | ||
// return defAbpHttp.request<void>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'DeleteAsync', | ||
// uniqueName: 'DeleteAsyncById', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const DeleteAsyncById = (id: string) => { | ||
return defAbpHttp.request<void>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'DeleteAsync', | ||
uniqueName: 'DeleteAsyncById', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.delete<void>({ | ||
url: `/api/openiddict/applications/${id}`, | ||
}); | ||
}; | ||
|
||
}; |
73 changes: 44 additions & 29 deletions
73
apps/vue/src/api/openiddict/open-iddict-authorization/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,57 @@ | ||
import { defAbpHttp } from '/@/utils/http/abp'; | ||
import { OpenIddictAuthorizationDto,OpenIddictAuthorizationGetListInput, } from './model'; | ||
import { OpenIddictAuthorizationDto, OpenIddictAuthorizationGetListInput, } from './model'; | ||
|
||
const remoteServiceName = 'AbpOpenIddict'; | ||
const controllerName = 'OpenIddictAuthorization'; | ||
// export const DeleteAsyncById = (id: string) => { | ||
// return defAbpHttp.request<void>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'DeleteAsync', | ||
// uniqueName: 'DeleteAsyncById', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const DeleteAsyncById = (id: string) => { | ||
return defAbpHttp.request<void>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'DeleteAsync', | ||
uniqueName: 'DeleteAsyncById', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.delete<void>({ | ||
url: `/api/openiddict/authorizations/${id}`, | ||
}); | ||
}; | ||
|
||
// export const GetAsyncById = (id: string) => { | ||
// return defAbpHttp.request<OpenIddictAuthorizationDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'GetAsync', | ||
// uniqueName: 'GetAsyncById', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const GetAsyncById = (id: string) => { | ||
return defAbpHttp.request<OpenIddictAuthorizationDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'GetAsync', | ||
uniqueName: 'GetAsyncById', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.get<OpenIddictAuthorizationDto>({ | ||
url: `/api/openiddict/authorizations/${id}`, | ||
}); | ||
}; | ||
|
||
// export const GetListAsyncByInput = (input: OpenIddictAuthorizationGetListInput) => { | ||
// return defAbpHttp.pagedRequest<OpenIddictAuthorizationDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'GetListAsync', | ||
// uniqueName: 'GetListAsyncByInput', | ||
// params: { | ||
// input: input, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const GetListAsyncByInput = (input: OpenIddictAuthorizationGetListInput) => { | ||
return defAbpHttp.pagedRequest<OpenIddictAuthorizationDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'GetListAsync', | ||
uniqueName: 'GetListAsyncByInput', | ||
params: { | ||
input: input, | ||
}, | ||
return defAbpHttp.get<PagedResultDto<OpenIddictAuthorizationDto>>({ | ||
url: '/api/openiddict/authorizations', | ||
params: input, | ||
}); | ||
}; | ||
|
||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,65 +1,99 @@ | ||
import { defAbpHttp } from '/@/utils/http/abp'; | ||
import { OpenIddictScopeCreateDto, OpenIddictScopeDto,OpenIddictScopeGetListInput, OpenIddictScopeUpdateDto, } from './model'; | ||
import { | ||
OpenIddictScopeCreateDto, | ||
OpenIddictScopeDto, | ||
OpenIddictScopeGetListInput, | ||
OpenIddictScopeUpdateDto, | ||
} from './model'; | ||
|
||
const remoteServiceName = 'AbpOpenIddict'; | ||
const controllerName = 'OpenIddictScope'; | ||
// export const CreateAsyncByInput = (input: OpenIddictScopeCreateDto) => { | ||
// return defAbpHttp.request<OpenIddictScopeDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'CreateAsync', | ||
// uniqueName: 'CreateAsyncByInput', | ||
// data: input, | ||
// }); | ||
// }; | ||
|
||
export const CreateAsyncByInput = (input: OpenIddictScopeCreateDto) => { | ||
return defAbpHttp.request<OpenIddictScopeDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'CreateAsync', | ||
uniqueName: 'CreateAsyncByInput', | ||
return defAbpHttp.post<OpenIddictScopeDto>({ | ||
url: '/api/openiddict/scopes', | ||
data: input, | ||
}); | ||
}; | ||
|
||
// export const DeleteAsyncById = (id: string) => { | ||
// return defAbpHttp.request<void>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'DeleteAsync', | ||
// uniqueName: 'DeleteAsyncById', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const DeleteAsyncById = (id: string) => { | ||
return defAbpHttp.request<void>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'DeleteAsync', | ||
uniqueName: 'DeleteAsyncById', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.delete<void>({ | ||
url: `/api/openiddict/scopes/${id}` | ||
}); | ||
}; | ||
|
||
// export const GetAsyncById = (id: string) => { | ||
// return defAbpHttp.request<OpenIddictScopeDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'GetAsync', | ||
// uniqueName: 'GetAsyncById', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const GetAsyncById = (id: string) => { | ||
return defAbpHttp.request<OpenIddictScopeDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'GetAsync', | ||
uniqueName: 'GetAsyncById', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.get<OpenIddictScopeDto>({ | ||
url: `/api/openiddict/scopes/${id}` | ||
}); | ||
}; | ||
|
||
// export const GetListAsyncByInput = (input: OpenIddictScopeGetListInput) => { | ||
// return defAbpHttp.pagedRequest<OpenIddictScopeDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'GetListAsync', | ||
// uniqueName: 'GetListAsyncByInput', | ||
// params: { | ||
// input: input, | ||
// }, | ||
// }); | ||
// }; | ||
|
||
export const GetListAsyncByInput = (input: OpenIddictScopeGetListInput) => { | ||
return defAbpHttp.pagedRequest<OpenIddictScopeDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'GetListAsync', | ||
uniqueName: 'GetListAsyncByInput', | ||
params: { | ||
input: input, | ||
}, | ||
return defAbpHttp.get<PagedResultDto<OpenIddictScopeDto>>({ | ||
url: '/api/openiddict/scopes', | ||
params: input, | ||
}); | ||
}; | ||
|
||
// export const UpdateAsyncByIdAndInput = (id: string, input: OpenIddictScopeUpdateDto) => { | ||
// return defAbpHttp.request<OpenIddictScopeDto>({ | ||
// service: remoteServiceName, | ||
// controller: controllerName, | ||
// action: 'UpdateAsync', | ||
// uniqueName: 'UpdateAsyncByIdAndInput', | ||
// params: { | ||
// id: id, | ||
// }, | ||
// data: input, | ||
// }); | ||
// }; | ||
|
||
export const UpdateAsyncByIdAndInput = (id: string, input: OpenIddictScopeUpdateDto) => { | ||
return defAbpHttp.request<OpenIddictScopeDto>({ | ||
service: remoteServiceName, | ||
controller: controllerName, | ||
action: 'UpdateAsync', | ||
uniqueName: 'UpdateAsyncByIdAndInput', | ||
params: { | ||
id: id, | ||
}, | ||
return defAbpHttp.put<OpenIddictScopeDto>({ | ||
url: `/api/openiddict/scopes/${id}`, | ||
data: input, | ||
}); | ||
}; | ||
|
||
}; |
Oops, something went wrong.