@longvansoftware/storefront-js-client 2.4.3 → 2.4.5

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.
@@ -14,3 +14,4 @@ export declare const UPDATE_CONNECTOR_DESCRIPTION: import("graphql").DocumentNod
14
14
  export declare const REMOVE_TAG: import("graphql").DocumentNode;
15
15
  export declare const CLOSE_TOPIC: import("graphql").DocumentNode;
16
16
  export declare const CREATE_TOPIC: import("graphql").DocumentNode;
17
+ export declare const ADD_TOPIC_RELATED_RESOURCE: import("graphql").DocumentNode;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CREATE_TOPIC = exports.CLOSE_TOPIC = exports.REMOVE_TAG = exports.UPDATE_CONNECTOR_DESCRIPTION = exports.ADD_TAG = exports.CREATE_CONNECTOR = exports.UPDATE_WORK_EFFORT_PROCESS_STATUS = exports.CREATE_WORK_EFFORT = exports.ADD_COMMENT = exports.ADD_TICKED = exports.ADD_ATTACHMENT_FOR_WORK_EFFORT = exports.UPDATE_WORK_EFFORT_STATUS = exports.UPDATE_WORK_EFFORT_NAME = exports.UPDATE_WORK_EFFORT_DESCRIPTION = exports.UPDATE_STATUS_ATTACHMENT_BY_ID = exports.ADD_OPPORTUNITY_MUTATION = void 0;
3
+ exports.ADD_TOPIC_RELATED_RESOURCE = exports.CREATE_TOPIC = exports.CLOSE_TOPIC = exports.REMOVE_TAG = exports.UPDATE_CONNECTOR_DESCRIPTION = exports.ADD_TAG = exports.CREATE_CONNECTOR = exports.UPDATE_WORK_EFFORT_PROCESS_STATUS = exports.CREATE_WORK_EFFORT = exports.ADD_COMMENT = exports.ADD_TICKED = exports.ADD_ATTACHMENT_FOR_WORK_EFFORT = exports.UPDATE_WORK_EFFORT_STATUS = exports.UPDATE_WORK_EFFORT_NAME = exports.UPDATE_WORK_EFFORT_DESCRIPTION = exports.UPDATE_STATUS_ATTACHMENT_BY_ID = exports.ADD_OPPORTUNITY_MUTATION = void 0;
4
4
  const graphql_tag_1 = require("graphql-tag");
5
5
  exports.ADD_OPPORTUNITY_MUTATION = (0, graphql_tag_1.gql) `
6
6
  mutation AddOpportunity(
@@ -782,13 +782,13 @@ exports.CLOSE_TOPIC = (0, graphql_tag_1.gql) `
782
782
  status
783
783
  name
784
784
  communicationChannel
785
- customerId
786
785
  accountableId
787
786
  accountableName
788
- customerName
789
787
  createdStamp
790
788
  threadId
791
789
  roomId
790
+ channelId
791
+ channelType
792
792
  }
793
793
  }
794
794
  `;
@@ -817,3 +817,18 @@ exports.CREATE_TOPIC = (0, graphql_tag_1.gql) `
817
817
  }
818
818
  }
819
819
  `;
820
+ exports.ADD_TOPIC_RELATED_RESOURCE = (0, graphql_tag_1.gql) `
821
+ mutation AddTopicRelatedResource(
822
+ $topicId: String!
823
+ $resourceId: String!
824
+ $resourceType: String!
825
+ $createdBy: String!
826
+ ) {
827
+ addTopicRelatedResource(
828
+ topicId: $topicId
829
+ resourceId: $resourceId
830
+ resourceType: $resourceType
831
+ createdBy: $createdBy
832
+ )
833
+ }
834
+ `;
@@ -12,3 +12,4 @@ export declare const GET_TAG: import("graphql").DocumentNode;
12
12
  export declare const SEARCH_TOPIC: import("graphql").DocumentNode;
13
13
  export declare const GET_MY_WORK_EFFORT_TODAY: import("graphql").DocumentNode;
14
14
  export declare const GET_MESSAGES: import("graphql").DocumentNode;
15
+ export declare const GET_RESOURCE_RELATED_TOPIC: import("graphql").DocumentNode;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.GET_MESSAGES = exports.GET_MY_WORK_EFFORT_TODAY = exports.SEARCH_TOPIC = exports.GET_TAG = exports.GET_CONNECTOR_BY_RESOURCE = exports.GET_WORK_EFFORT_BY_ID = exports.GET_WORK_EFFORTS = exports.GET_LIST_COMMENT = exports.GET_ATTACHMENT_BY_WORK_EFFORT_ID = exports.GET_TICKET_BY_ID = exports.GET_LIST_TICKET = exports.GET_LIST_WORK_EFFORT_TYPE = exports.GET_LIST_TODO = exports.GET_LIST_OPPORTUNITY_QUERY = void 0;
3
+ exports.GET_RESOURCE_RELATED_TOPIC = exports.GET_MESSAGES = exports.GET_MY_WORK_EFFORT_TODAY = exports.SEARCH_TOPIC = exports.GET_TAG = exports.GET_CONNECTOR_BY_RESOURCE = exports.GET_WORK_EFFORT_BY_ID = exports.GET_WORK_EFFORTS = exports.GET_LIST_COMMENT = exports.GET_ATTACHMENT_BY_WORK_EFFORT_ID = exports.GET_TICKET_BY_ID = exports.GET_LIST_TICKET = exports.GET_LIST_WORK_EFFORT_TYPE = exports.GET_LIST_TODO = exports.GET_LIST_OPPORTUNITY_QUERY = void 0;
4
4
  const graphql_tag_1 = require("graphql-tag");
5
5
  exports.GET_LIST_OPPORTUNITY_QUERY = (0, graphql_tag_1.gql) `
6
6
  query GetListOpportunity(
@@ -670,3 +670,11 @@ exports.GET_MESSAGES = (0, graphql_tag_1.gql) `
670
670
  }
671
671
  }
672
672
  `;
673
+ exports.GET_RESOURCE_RELATED_TOPIC = (0, graphql_tag_1.gql) `
674
+ query GetResourceRelatedTopic(
675
+ $topicId: String!
676
+ $resourceType: String!
677
+ ){
678
+ getResourceRelatedTopic(topicId: $topicId, resourceType: $resourceType)
679
+ }
680
+ `;
@@ -34,4 +34,6 @@ export declare class CrmService extends Service {
34
34
  getTopicByCustomerId(filterTopicRequest: any, pageSize: number, currentPage: number): Promise<any>;
35
35
  getMyWorkEffortToday(performerId: string, source: string): Promise<any>;
36
36
  getMessages(topicId: String, pageSize: Number, pageNumber: Number): Promise<any>;
37
+ getResourceRelatedTopic(topicId: string, resourceType: string): Promise<any>;
38
+ addTopicRelatedResource(topicId: string, resourceId: string, resourceType: string, createdBy: string): Promise<any>;
37
39
  }
@@ -576,5 +576,39 @@ class CrmService extends serviceSDK_1.Service {
576
576
  }
577
577
  });
578
578
  }
579
+ getResourceRelatedTopic(topicId, resourceType) {
580
+ return __awaiter(this, void 0, void 0, function* () {
581
+ const query = queries_1.GET_RESOURCE_RELATED_TOPIC;
582
+ const variables = {
583
+ topicId,
584
+ resourceType,
585
+ };
586
+ try {
587
+ const response = yield this.graphqlQuery(query, variables);
588
+ return response.getResourceRelatedTopic;
589
+ }
590
+ catch (error) {
591
+ throw error;
592
+ }
593
+ });
594
+ }
595
+ addTopicRelatedResource(topicId, resourceId, resourceType, createdBy) {
596
+ return __awaiter(this, void 0, void 0, function* () {
597
+ const mutation = mutations_1.ADD_TOPIC_RELATED_RESOURCE;
598
+ const variables = {
599
+ topicId,
600
+ resourceId,
601
+ resourceType,
602
+ createdBy,
603
+ };
604
+ try {
605
+ const response = yield this.graphqlMutation(mutation, variables);
606
+ return response.addTopicRelatedResource;
607
+ }
608
+ catch (error) {
609
+ throw error;
610
+ }
611
+ });
612
+ }
579
613
  }
580
614
  exports.CrmService = CrmService;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@longvansoftware/storefront-js-client",
3
- "version": "2.4.3",
3
+ "version": "2.4.5",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "files": [