Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Subscription handling#1197

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
FalkWolsky merged 53 commits intodevfromsubscription-handling
Nov 18, 2024
Merged
Show file tree
Hide file tree
Changes from1 commit
Commits
Show all changes
53 commits
Select commitHold shift + click to select a range
381663b
Merge pull request #1181 from lowcoder-org/main
FalkWolskySep 21, 2024
12c6654
Subscription Description content
Sep 21, 2024
f41b3e3
Merge branch 'dev' into subscription-handling
FalkWolskySep 28, 2024
b82b19e
Subscription Detail Page
Sep 28, 2024
6eff60b
Adding Help for Subscription
Sep 28, 2024
9c3e246
Merge branch 'dev' into subscription-handling
FalkWolskyOct 5, 2024
3f216d8
Introduce hostId
Oct 5, 2024
77dcd3d
Update Subscription Search API handling
Oct 5, 2024
21cff58
Updating Routes to display success and cancel for Subscription Creation
Oct 5, 2024
e1ca7dc
added deployment_id actions
raheeliftikhar5Oct 5, 2024
f9616aa
actions and selectors for deploymentId
raheeliftikhar5Oct 5, 2024
dd1784b
Getting Workspace User Count
Oct 5, 2024
5eeeb0f
Adding Success Page
Oct 9, 2024
a545620
Merge branch 'dev' into subscription-handling
FalkWolskyOct 26, 2024
9b2334f
Fixing Blank Screen bug
Oct 26, 2024
50b8eb9
Introduce DeploymentID for Subscription-Check
Oct 26, 2024
fc08749
Subscription System Roundup
Oct 26, 2024
3a6ab48
move SubscriptionTypeEnum and initial subscription products in consta…
raheeliftikhar5Oct 31, 2024
f918ac5
removed unused code + avoid fetching subscription again
raheeliftikhar5Oct 31, 2024
3bee7f1
remove polling for deploymentId in fetching user subscription
raheeliftikhar5Oct 31, 2024
e44fd52
removed InitializeSubscription hook + added SubscriptionContext to ha…
raheeliftikhar5Oct 31, 2024
5e7395e
fixed error message
raheeliftikhar5Oct 31, 2024
bfbcd9e
Merge branch 'dev' into subscription-handling
FalkWolskyNov 1, 2024
ba9b6c1
fix search for support tickets
raheeliftikhar5Nov 1, 2024
5af6c32
datasource list loading fix
raheeliftikhar5Nov 1, 2024
cde7340
Merge pull request #1275 from lowcoder-org/updates-subscription-handling
FalkWolskyNov 2, 2024
b40c81a
Introduce Rich Text Editor for Ticket Description
Nov 2, 2024
3868a94
Network Retry mechanism for Flow API
Nov 2, 2024
15cc8a3
Moving Context to make sure Subscription is initialized at Admin Portal
Nov 2, 2024
efd7f25
Changing to SimpleSubscriptionContextProvider for Homepage
Nov 2, 2024
a0843e9
Handling empty Tickets Table
Nov 2, 2024
9a4fb96
Updating Yarn Lock File for Node Service
Nov 2, 2024
739431a
Same Editor Settings for Ticket Details
Nov 2, 2024
dd3e9db
Adapting Payload for Ticket System
Nov 2, 2024
c66018b
Fixing timing issue
Nov 2, 2024
2123eb7
Send less data & receive better Subscription Context
Nov 2, 2024
bdc7d6e
Updating OpenAPI Spec
Nov 2, 2024
87b235b
Fixing Image Display
Nov 4, 2024
458a62c
add group admin count and user count to list api
dragonpooNov 5, 2024
6bb1d91
modify admin user count for all user group
dragonpooNov 5, 2024
fec51dd
count subscription users from groups list
raheeliftikhar5Nov 6, 2024
4ccb1d1
save org user stats and use totalAdminsAndDevelopers count for subscr…
raheeliftikhar5Nov 8, 2024
88ec6f4
Merge pull request #1286 from lowcoder-org/subscription-users-count
FalkWolskyNov 8, 2024
5cc7ebe
Merge branch 'dev' into subscription-handling
FalkWolskyNov 9, 2024
e6d81cf
Switching to Production
Nov 9, 2024
22b3faf
Enable Clearbit for all
Nov 9, 2024
4b8c585
Updating Axios to 1.7.7
Nov 14, 2024
9985ac8
Rounding up Subscriptions
Nov 16, 2024
1538670
Updating Yarn Lock file
Nov 17, 2024
bc38c79
update subscriptiont thank you text
raheeliftikhar5Nov 17, 2024
ce82860
upgrade react-markdown in lowcoder-design
raheeliftikhar5Nov 18, 2024
6153ddf
upgrade react-markdown in lowcoder-design
raheeliftikhar5Nov 18, 2024
ed1a330
Merge branch 'dev' into subscription-handling
FalkWolskyNov 18, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Adapting Payload for Ticket System
  • Loading branch information
FalkWolsky committedNov 2, 2024
commitdd3e9db671a51a27e60481872cde47ff307efd3c
21 changes: 17 additions & 4 deletionsclient/packages/lowcoder/src/api/supportApi.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -118,11 +118,15 @@ class SupportApi extends Api {

// API Functions

export const searchCustomerTickets = async (orgID : string, currentUserId : string, domain : string) => {
export const searchCustomerTickets = async (
deploymentId : string,
orgID : string,
currentUserId : string
) => {

const apiBody = {
path: "webhook/support/get-issues",
data: {"host" :domain, "orgId" : orgID, "userId" : currentUserId},
data: {"hostId" :deploymentId, "orgId" : orgID, "userId" : currentUserId},
method: "post",
headers: lcHeaders
};
Expand DownExpand Up@@ -159,11 +163,20 @@ export const getTicket = async (ticketKey : string) => {
}
};

export const createTicket = async (orgID : string, currentUserId : string, subscriptionId : string, domain : string, summary: string, description : string, errors : string) => {
export const createTicket = async (
domain: string,
deploymentId : string,
orgID : string,
orgName : string,
currentUserId : string,
subscriptionId : string,
summary: string,
description : string,
errors : string) => {

const apiBody = {
path: "webhook/support/create-ticket",
data: {"host" : domain, "orgId" : orgID, "userId" : currentUserId, "subscriptionId": subscriptionId, "summary" : summary, "description" : description, "errors" : errors},
data: {"domain" : domain, "hostId" : deploymentId, "orgId" : orgID, "orgName" : orgName, "userId" : currentUserId, "subscriptionId": subscriptionId, "summary" : summary, "description" : description, "errors" : errors},
method: "post",
headers: lcHeaders
};
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -67,11 +67,9 @@ import { Support } from "pages/support";
import { isEE } from "util/envUtils";
import { getSubscriptions } from 'redux/selectors/subscriptionSelectors';
import { SubscriptionProductsEnum } from '@lowcoder-ee/constants/subscriptionConstants';
import { ReduxActionTypes } from '@lowcoder-ee/constants/reduxActionConstants';

// adding App Editor, so we can show Apps inside the Admin Area
import AppEditor from "../editor/AppEditor";
import { set } from "lodash";
import { fetchDeploymentIdAction } from "@lowcoder-ee/redux/reduxActions/configActions";
import { getDeploymentId } from "@lowcoder-ee/redux/selectors/configSelectors";
import { SimpleSubscriptionContextProvider } from '@lowcoder-ee/util/context/SimpleSubscriptionContext';
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -15,7 +15,10 @@ import ReactQuill from "react-quill";
import 'react-quill/dist/quill.snow.css';
import { Spin } from "antd";
import LoadingOutlined from "@ant-design/icons/LoadingOutlined";

import { useSimpleSubscriptionContext } from "@lowcoder-ee/util/context/SimpleSubscriptionContext";
import { SubscriptionProductsEnum } from '@lowcoder-ee/constants/subscriptionConstants';
import { getDeploymentId } from "@lowcoder-ee/redux/selectors/configSelectors";
import { useSelector } from "react-redux";

const SupportWrapper = styled.div`
display: flex;
Expand DownExpand Up@@ -129,7 +132,7 @@ const handleEditClick = (ticketId: string) => {
};

export function SupportOverview() {
const { orgID, currentUser, domain } = useUserDetails();
const { orgID,orgName,currentUser, domain } = useUserDetails();
const [supportTickets, setSupportTickets] = useState<any>([]);
const [loading, setLoading] = useState<boolean>(true);
const [error, setError] = useState<string | null>(null);
Expand All@@ -141,6 +144,12 @@ export function SupportOverview() {
const [isSubmitting, setIsSubmitting] = useState<boolean>(false);
const [isReloadDisabled, setIsReloadDisabled] = useState<boolean>(false); // State to disable/enable reload button
const [lastReloadTime, setLastReloadTime] = useState<number | null>(null);
const { subscriptions } = useSimpleSubscriptionContext();
const deploymentId = useSelector(getDeploymentId);

const SupportSubscription = subscriptions.filter(
sub => sub.product === SubscriptionProductsEnum.SUPPORT && sub.status === 'active'
);

// Capture global errors using window.onerror
useEffect(() => {
Expand All@@ -162,7 +171,7 @@ export function SupportOverview() {
const fetchSupportTickets = async () => {
setLoading(true); // Set loading to true while fetching data
try {
const ticketData = await searchCustomerTickets(orgID, currentUser.id, domain);
const ticketData = await searchCustomerTickets(deploymentId,orgID, currentUser.id);
setSupportTickets(ticketData);
} catch (err) {
setError("Failed to fetch support tickets.");
Expand DownExpand Up@@ -210,7 +219,7 @@ export function SupportOverview() {

setIsSubmitting(true);
try {
const result = await createTicket(orgID, currentUser.id,'subscription-id', domain, summary, description, capturedErrors.join("\n"));
const result = await createTicket(domain, deploymentId,orgID,orgName,currentUser.id,SupportSubscription[0]?.id, summary, description, capturedErrors.join("\n"));
if (result) {
showCreateForm(false);
setSummary("");
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -6,11 +6,13 @@ export const useUserDetails = () => {
const user = useSelector(getUser);
const currentUser = useSelector(getCurrentUser);
const orgID = user.currentOrgId;
const orgName = user.orgs.find(org => org.id === orgID)?.name || "";
const domain = window.location.protocol + "//" + window.location.hostname + (window.location.port ? ":" + window.location.port : "");
const subscriptions = useSelector(getSubscriptions);

return {
orgID,
orgName,
currentUser,
domain,
subscriptions
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp