@valiantys/atlassian-app-frontend 3.0.0-alpha-29 → 3.0.0-alpha-30
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-issue/src/lib/jira-issue-service/index.cjs.js +1 -1
- package/atlassian/jira/shared/data-access-issue/src/lib/jira-issue-service/index.es.js +11 -9
- package/data-access-issue/atlassian-app-frontend-data-access-issue.api.json +3 -3
- package/data-access-issue/atlassian-app-frontend.api.md +5 -3
- package/data-access-issue/index.d.ts +5 -3
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=class a{constructor(e){this.fetchSvc=e}async updateProperty(e,t,s){return this.fetchSvc.fetch({method:"PUT",url:this.fetchSvc.route`/rest/api/3/issue/${e}/properties/${t}`},s)}async updateField(e,t,s){await this.updateFields(e,{[t]:s})}async updateFields(e,t){await this.updateIssue(e,{fields:t})}async getIssueField(e,t){var s;return(s=await this.getIssueFields(e,[t]))==null?void 0:s[t]}async getIssueFields(e,t){return(await this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issue/${e}?fields=${t.join(",")}`})).fields}async getIssue(e,t=["*all"],s=!1){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issue/${e}?fields=${t.join(",")}&expand=${s?"renderedFields":""}`})}async issueSearch(e,t,s=50){let c;const i=[];do{const h=await this.issueSearchByPage(e,t,c,s);i.push(...h.issues),c=h.nextPageToken}while(c!==void 0);return i}async issueSearchByPage(e,t,s,c=50){return this.fetchSvc.fetch({method:"POST",url:this.fetchSvc.route`/rest/api/3/search/jql`},{fields:t,jql:e,maxResults:c,nextPageToken:s})}async addWorklog(e,t){return this.fetchSvc.fetch({method:"POST",url:this.fetchSvc.route`/rest/api/3/issue/${e}/worklog`},t)}async queryForIssuesInProjects(e){const t=`project IN (${e.join(",")})`;return this.issueSearch(t,["key","project"],5e3)}async createIssue(e){return this.fetchSvc.fetch({method:"POST",url:this.fetchSvc.route`/rest/api/3/issue`},e)}async updateIssue(e,t){return this.fetchSvc.fetch({method:"PUT",url:this.fetchSvc.route`/rest/api/3/issue/${e}`},t)}async getIssueComments(e,t=0){const s=t?`?startAt=${t}`:"";return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issue/${e}/comment${s}`})}async getIssueCommentById(e,t){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issue/${e}/comment/${t}`})}async addIssueComment(e,t){return this.fetchSvc.fetch({method:"POST",url:this.fetchSvc.route`/rest/api/3/issue/${e}/comment`},{body:t})}async transitionIssue(e,t){return this.fetchSvc.fetch({method:"POST",url:this.fetchSvc.route`/rest/api/3/issue/${e}/transitions`},t)}async createIssueLink(e){return this.fetchSvc.fetch({method:"POST",url:this.fetchSvc.route`/rest/api/3/issueLink`},e)}async getIssueTypes(){return this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issuetype`})}async getIssueTypeSchemes({maxResults:e,orderBy:t,startAt:s,expand:c,id:i,queryString:h}={}){const r=new URLSearchParams;return c&&r.append("expand",c),e&&r.append("maxResults",e.toString()),t&&r.append("orderBy",t),s&&r.append("startAt",s.toString()),i&&i.forEach(n=>r.append("id",n)),h&&r.append("queryString",h),this.fetchSvc.fetch({method:"GET",url:this.fetchSvc.route`/rest/api/3/issuetypescheme?${r}`})}};a.issueUrl="/rest/api/3/issue";let u=a;exports.JiraIssueService=u;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
1
|
+
const u = class u {
|
|
2
2
|
constructor(e) {
|
|
3
3
|
this.fetchSvc = e;
|
|
4
4
|
}
|
|
@@ -35,12 +35,12 @@ const h = class h {
|
|
|
35
35
|
}
|
|
36
36
|
async issueSearch(e, t, s = 50) {
|
|
37
37
|
let c;
|
|
38
|
-
const
|
|
38
|
+
const h = [];
|
|
39
39
|
do {
|
|
40
40
|
const i = await this.issueSearchByPage(e, t, c, s);
|
|
41
|
-
|
|
41
|
+
h.push(...i.issues), c = i.nextPageToken;
|
|
42
42
|
} while (c !== void 0);
|
|
43
|
-
return
|
|
43
|
+
return h;
|
|
44
44
|
}
|
|
45
45
|
async issueSearchByPage(e, t, s, c = 50) {
|
|
46
46
|
return this.fetchSvc.fetch(
|
|
@@ -138,17 +138,19 @@ const h = class h {
|
|
|
138
138
|
maxResults: e,
|
|
139
139
|
orderBy: t,
|
|
140
140
|
startAt: s,
|
|
141
|
-
expand: c
|
|
141
|
+
expand: c,
|
|
142
|
+
id: h,
|
|
143
|
+
queryString: i
|
|
142
144
|
} = {}) {
|
|
143
145
|
const r = new URLSearchParams();
|
|
144
|
-
return c && r.append("expand", c), e && r.append("maxResults", e.toString()), t && r.append("orderBy", t), s && r.append("startAt", s.toString()), this.fetchSvc.fetch({
|
|
146
|
+
return c && r.append("expand", c), e && r.append("maxResults", e.toString()), t && r.append("orderBy", t), s && r.append("startAt", s.toString()), h && h.forEach((n) => r.append("id", n)), i && r.append("queryString", i), this.fetchSvc.fetch({
|
|
145
147
|
method: "GET",
|
|
146
148
|
url: this.fetchSvc.route`/rest/api/3/issuetypescheme?${r}`
|
|
147
149
|
});
|
|
148
150
|
}
|
|
149
151
|
};
|
|
150
|
-
|
|
151
|
-
let
|
|
152
|
+
u.issueUrl = "/rest/api/3/issue";
|
|
153
|
+
let a = u;
|
|
152
154
|
export {
|
|
153
|
-
|
|
155
|
+
a as JiraIssueService
|
|
154
156
|
};
|
|
@@ -962,11 +962,11 @@
|
|
|
962
962
|
"excerptTokens": [
|
|
963
963
|
{
|
|
964
964
|
"kind": "Content",
|
|
965
|
-
"text": "getIssueTypeSchemes({ maxResults, orderBy, startAt, expand, }?: "
|
|
965
|
+
"text": "getIssueTypeSchemes({ maxResults, orderBy, startAt, expand, id, queryString }?: "
|
|
966
966
|
},
|
|
967
967
|
{
|
|
968
968
|
"kind": "Content",
|
|
969
|
-
"text": "{\n maxResults?: number;\n orderBy?:
|
|
969
|
+
"text": "{\n maxResults?: number;\n orderBy?: 'name' | '-name' | '+name' | 'id' | '-id' | '+id';\n startAt?: number;\n expand?: 'projects,issueTypes' | 'projects' | 'issueTypes';\n id?: string[];\n queryString?: string;\n }"
|
|
970
970
|
},
|
|
971
971
|
{
|
|
972
972
|
"kind": "Content",
|
|
@@ -1014,7 +1014,7 @@
|
|
|
1014
1014
|
"overloadIndex": 1,
|
|
1015
1015
|
"parameters": [
|
|
1016
1016
|
{
|
|
1017
|
-
"parameterName": "{ maxResults, orderBy, startAt, expand, }",
|
|
1017
|
+
"parameterName": "{ maxResults, orderBy, startAt, expand, id, queryString }",
|
|
1018
1018
|
"parameterTypeTokenRange": {
|
|
1019
1019
|
"startIndex": 1,
|
|
1020
1020
|
"endIndex": 2
|
|
@@ -50,11 +50,13 @@ export class JiraIssueService {
|
|
|
50
50
|
// Warning: (ae-forgotten-export) The symbol "IssueTypeScheme" needs to be exported by the entry point data-access-issue.d.ts
|
|
51
51
|
//
|
|
52
52
|
// (undocumented)
|
|
53
|
-
getIssueTypeSchemes({ maxResults, orderBy, startAt, expand, }?: {
|
|
53
|
+
getIssueTypeSchemes({ maxResults, orderBy, startAt, expand, id, queryString }?: {
|
|
54
54
|
maxResults?: number;
|
|
55
|
-
orderBy?:
|
|
55
|
+
orderBy?: 'name' | '-name' | '+name' | 'id' | '-id' | '+id';
|
|
56
56
|
startAt?: number;
|
|
57
|
-
expand?:
|
|
57
|
+
expand?: 'projects,issueTypes' | 'projects' | 'issueTypes';
|
|
58
|
+
id?: string[];
|
|
59
|
+
queryString?: string;
|
|
58
60
|
}): Promise<PagedResponse<IssueTypeScheme>>;
|
|
59
61
|
// Warning: (ae-forgotten-export) The symbol "AtlassianDocumentFormat" needs to be exported by the entry point data-access-issue.d.ts
|
|
60
62
|
//
|
|
@@ -253,11 +253,13 @@ export declare class JiraIssueService {
|
|
|
253
253
|
transitionIssue(issueIdOrKey: string, body: TransitionIssueRequest): Promise<void>;
|
|
254
254
|
createIssueLink(issueLinkRequest: IssueLinkRequest): Promise<void>;
|
|
255
255
|
getIssueTypes(): Promise<IssueTypeDetails[]>;
|
|
256
|
-
getIssueTypeSchemes({ maxResults, orderBy, startAt, expand, }?: {
|
|
256
|
+
getIssueTypeSchemes({ maxResults, orderBy, startAt, expand, id, queryString }?: {
|
|
257
257
|
maxResults?: number;
|
|
258
|
-
orderBy?:
|
|
258
|
+
orderBy?: 'name' | '-name' | '+name' | 'id' | '-id' | '+id';
|
|
259
259
|
startAt?: number;
|
|
260
|
-
expand?:
|
|
260
|
+
expand?: 'projects,issueTypes' | 'projects' | 'issueTypes';
|
|
261
|
+
id?: string[];
|
|
262
|
+
queryString?: string;
|
|
261
263
|
}): Promise<PagedResponse<IssueTypeScheme>>;
|
|
262
264
|
}
|
|
263
265
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@valiantys/atlassian-app-frontend",
|
|
3
|
-
"version": "3.0.0-alpha-
|
|
3
|
+
"version": "3.0.0-alpha-30",
|
|
4
4
|
"description": "This library provides an Atlassian Forge Custom UI wrapper component that handles all the setup necessary to support an app that can run deployed or in standalone mode",
|
|
5
5
|
"exports": {
|
|
6
6
|
"./atlassian-app": {
|