@valiantys/atlassian-app 3.2.0-alpha-18 → 3.2.0-alpha-19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/atlassian/jira/shared/data-access-project/src/lib/jira-project-service/index.cjs.js +1 -1
- package/atlassian/jira/shared/data-access-project/src/lib/jira-project-service/index.es.js +8 -0
- package/data-access-project/atlassian-app-data-access-project.api.json +62 -0
- package/data-access-project/atlassian-app.api.md +2 -0
- package/data-access-project/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../../../../../../shared/util-fetch/src/lib/shared-util-fetch/index.cjs.js"),h=class h{constructor(t){this.fetchSvc=t}getVersions(t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}/versions`})}getProject(t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}`})}async getAllProjects(){return await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project`})||[]}async projectSearchByIds(t){var e;if(t.length>50)throw new Error("Too many project ids, max allowed is 50.");const r=this.fetchSvc.route`/rest/api/3/project/search?${t.map(c=>"id="+c).join("&")}`;return(e=await this.fetchSvc.fetch({method:"GET",url:r}))==null?void 0:e.values}async projectSearchByKeys(t){var e;if(t.length>50)throw new Error("Too many project keys, max allowed is 50.");const r=this.fetchSvc.route`/rest/api/3/project/search?${t.map(c=>"key="+c).join("&")}`;return(e=await this.fetchSvc.fetch({method:"GET",url:r}))==null?void 0:e.values}async getProjectIssueTypes(t){return await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issuetype/project?projectId=${t}`})||[]}getProjectStatuses(t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}/statuses`})}async getProjectProperty(t,r){try{return(await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}/properties/${r}`})).value}catch(e){if(e instanceof o.FetchError&&e.statusCode===404)return;throw e}}setProjectProperty(t,r,e){return this.fetchSvc.fetch({method:"PUT",url:this.fetchSvc.route`/rest/api/3/project/${t}/properties/${r}`},e)}};h.projectUrl="/rest/api/3/project";let s=h;exports.JiraProjectService=s;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../../../../../../shared/util-fetch/src/lib/shared-util-fetch/index.cjs.js"),h=class h{constructor(t){this.fetchSvc=t}getVersions(t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}/versions`})}getProject(t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}`})}async getAllProjects(){return await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project`})||[]}async projectSearchByIds(t){var e;if(t.length>50)throw new Error("Too many project ids, max allowed is 50.");const r=this.fetchSvc.route`/rest/api/3/project/search?${t.map(c=>"id="+c).join("&")}`;return(e=await this.fetchSvc.fetch({method:"GET",url:r}))==null?void 0:e.values}async projectSearchByKeys(t){var e;if(t.length>50)throw new Error("Too many project keys, max allowed is 50.");const r=this.fetchSvc.route`/rest/api/3/project/search?${t.map(c=>"key="+c).join("&")}`;return(e=await this.fetchSvc.fetch({method:"GET",url:r}))==null?void 0:e.values}async projectSearchByQuery(t){var c;const r=new URLSearchParams({query:t}),e=this.fetchSvc.route`/rest/api/3/project/search?${r}`;return(c=await this.fetchSvc.fetch({method:"GET",url:e}))==null?void 0:c.values}async getProjectIssueTypes(t){return await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issuetype/project?projectId=${t}`})||[]}getProjectStatuses(t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}/statuses`})}async getProjectProperty(t,r){try{return(await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/project/${t}/properties/${r}`})).value}catch(e){if(e instanceof o.FetchError&&e.statusCode===404)return;throw e}}setProjectProperty(t,r,e){return this.fetchSvc.fetch({method:"PUT",url:this.fetchSvc.route`/rest/api/3/project/${t}/properties/${r}`},e)}};h.projectUrl="/rest/api/3/project";let s=h;exports.JiraProjectService=s;
|
|
@@ -44,6 +44,14 @@ const s = class s {
|
|
|
44
44
|
url: r
|
|
45
45
|
})) == null ? void 0 : e.values;
|
|
46
46
|
}
|
|
47
|
+
async projectSearchByQuery(t) {
|
|
48
|
+
var c;
|
|
49
|
+
const r = new URLSearchParams({ query: t }), e = this.fetchSvc.route`/rest/api/3/project/search?${r}`;
|
|
50
|
+
return (c = await this.fetchSvc.fetch({
|
|
51
|
+
method: "GET",
|
|
52
|
+
url: e
|
|
53
|
+
})) == null ? void 0 : c.values;
|
|
54
|
+
}
|
|
47
55
|
async getProjectIssueTypes(t) {
|
|
48
56
|
return await this.fetchSvc.fetch({
|
|
49
57
|
method: "GET",
|
|
@@ -715,6 +715,68 @@
|
|
|
715
715
|
"isAbstract": false,
|
|
716
716
|
"name": "projectSearchByKeys"
|
|
717
717
|
},
|
|
718
|
+
{
|
|
719
|
+
"kind": "Method",
|
|
720
|
+
"canonicalReference": "@valiantys/atlassian-app!JiraProjectService#projectSearchByQuery:member(1)",
|
|
721
|
+
"docComment": "",
|
|
722
|
+
"excerptTokens": [
|
|
723
|
+
{
|
|
724
|
+
"kind": "Content",
|
|
725
|
+
"text": "projectSearchByQuery(query: "
|
|
726
|
+
},
|
|
727
|
+
{
|
|
728
|
+
"kind": "Content",
|
|
729
|
+
"text": "string"
|
|
730
|
+
},
|
|
731
|
+
{
|
|
732
|
+
"kind": "Content",
|
|
733
|
+
"text": "): "
|
|
734
|
+
},
|
|
735
|
+
{
|
|
736
|
+
"kind": "Reference",
|
|
737
|
+
"text": "Promise",
|
|
738
|
+
"canonicalReference": "!Promise:interface"
|
|
739
|
+
},
|
|
740
|
+
{
|
|
741
|
+
"kind": "Content",
|
|
742
|
+
"text": "<"
|
|
743
|
+
},
|
|
744
|
+
{
|
|
745
|
+
"kind": "Reference",
|
|
746
|
+
"text": "Project",
|
|
747
|
+
"canonicalReference": "@valiantys/atlassian-app!~Project:interface"
|
|
748
|
+
},
|
|
749
|
+
{
|
|
750
|
+
"kind": "Content",
|
|
751
|
+
"text": "[]>"
|
|
752
|
+
},
|
|
753
|
+
{
|
|
754
|
+
"kind": "Content",
|
|
755
|
+
"text": ";"
|
|
756
|
+
}
|
|
757
|
+
],
|
|
758
|
+
"isStatic": false,
|
|
759
|
+
"returnTypeTokenRange": {
|
|
760
|
+
"startIndex": 3,
|
|
761
|
+
"endIndex": 7
|
|
762
|
+
},
|
|
763
|
+
"releaseTag": "Public",
|
|
764
|
+
"isProtected": false,
|
|
765
|
+
"overloadIndex": 1,
|
|
766
|
+
"parameters": [
|
|
767
|
+
{
|
|
768
|
+
"parameterName": "query",
|
|
769
|
+
"parameterTypeTokenRange": {
|
|
770
|
+
"startIndex": 1,
|
|
771
|
+
"endIndex": 2
|
|
772
|
+
},
|
|
773
|
+
"isOptional": false
|
|
774
|
+
}
|
|
775
|
+
],
|
|
776
|
+
"isOptional": false,
|
|
777
|
+
"isAbstract": false,
|
|
778
|
+
"name": "projectSearchByQuery"
|
|
779
|
+
},
|
|
718
780
|
{
|
|
719
781
|
"kind": "Property",
|
|
720
782
|
"canonicalReference": "@valiantys/atlassian-app!JiraProjectService.projectUrl:member",
|
|
@@ -31,6 +31,8 @@ export class JiraProjectService {
|
|
|
31
31
|
// (undocumented)
|
|
32
32
|
projectSearchByKeys(projectKeys: string[]): Promise<Project[]>;
|
|
33
33
|
// (undocumented)
|
|
34
|
+
projectSearchByQuery(query: string): Promise<Project[]>;
|
|
35
|
+
// (undocumented)
|
|
34
36
|
static readonly projectUrl = "/rest/api/3/project";
|
|
35
37
|
// (undocumented)
|
|
36
38
|
setProjectProperty<T>(projectIdOrKey: string, propertyKey: string, value: T): Promise<T>;
|
|
@@ -53,6 +53,7 @@ export declare class JiraProjectService {
|
|
|
53
53
|
getAllProjects(): Promise<Project[]>;
|
|
54
54
|
projectSearchByIds(projectIds: string[]): Promise<Project[]>;
|
|
55
55
|
projectSearchByKeys(projectKeys: string[]): Promise<Project[]>;
|
|
56
|
+
projectSearchByQuery(query: string): Promise<Project[]>;
|
|
56
57
|
getProjectIssueTypes(projectId: string): Promise<IssueTypeDetails[]>;
|
|
57
58
|
getProjectStatuses(projectIdOrKey: string): Promise<unknown>;
|
|
58
59
|
getProjectProperty<T>(projectIdOrKey: string, propertyKey: string): Promise<T | undefined>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@valiantys/atlassian-app",
|
|
3
|
-
"version": "3.2.0-alpha-
|
|
3
|
+
"version": "3.2.0-alpha-19",
|
|
4
4
|
"description": "This library provides Atlassian Forge components, wrappers, and utilities to support writing Forge apps that can run deployed or in standalone mode",
|
|
5
5
|
"exports": {
|
|
6
6
|
"./frontend-app": {
|