Skip to content

Commit

Permalink
Fix stripe issues (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
harishmohanraj authored Jan 11, 2024
1 parent 06a70bb commit 962646d
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 14 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ env:
DATABASE_URL: ${{ secrets.DATABASE_URL }}
JWT_SECRET: ${{ secrets.JWT_SECRET }}
ADS_SERVER_URL: ${{ vars.ADS_SERVER_URL }}
STRIPE_KEY: ${{ secrets.STRIPE_KEY }}
SUBSCRIPTION_PRICE_ID: ${{ secrets.SUBSCRIPTION_PRICE_ID }}

jobs:
unit_test:
Expand Down Expand Up @@ -85,6 +83,9 @@ jobs:
GOOGLE_CLIENT_ID: ${{ secrets.GOOGLE_CLIENT_ID }}
GOOGLE_CLIENT_SECRET: ${{ secrets.GOOGLE_CLIENT_SECRET }}
AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }}
STRIPE_KEY: ${{ secrets.STRIPE_KEY }}
SUBSCRIPTION_PRICE_ID: ${{ secrets.SUBSCRIPTION_PRICE_ID }}
CREDITS_PRICE_ID: ${{ secrets.CREDITS_PRICE_ID }}
steps:
- uses: actions/checkout@v3
# This is to fix GIT not liking owner of the checkout dir - https://github.com/actions/runner/issues/2033#issuecomment-1204205989
Expand Down
10 changes: 5 additions & 5 deletions src/client/AccountPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export default function Example({ user }: { user: User }) {
</dd>
</div>
<div className="py-4 sm:grid sm:grid-cols-3 sm:gap-4 sm:py-5 sm:px-6">
{/* <dt className="text-sm font-medium text-gray-500">
<dt className="text-sm font-medium text-gray-500">
Credits remaining
</dt>
<>
Expand All @@ -44,7 +44,7 @@ export default function Example({ user }: { user: User }) {
isLoading={isLoading}
setIsLoading={setIsLoading}
/>
</> */}
</>
{/* <dt className="text-sm font-medium text-gray-500">Your Plan</dt>
{user.hasPaid ? (
<>
Expand All @@ -68,7 +68,7 @@ export default function Example({ user }: { user: User }) {
</>
)}
*/}
<dt className="text-sm font-medium text-gray-500">Your Plan</dt>
{/* <dt className="text-sm font-medium text-gray-500">Your Plan</dt>
{user.hasPaid ? (
<>
<dd className="mt-1 text-sm text-gray-900 sm:col-span-1 sm:mt-0">
Expand All @@ -89,7 +89,7 @@ export default function Example({ user }: { user: User }) {
setIsLoading={setIsLoading}
/>
</>
)}
)} */}
</div>
<div className="py-4 sm:grid sm:grid-cols-3 sm:gap-4 sm:py-5 sm:px-6">
<dt className="text-sm font-medium text-gray-500">About</dt>
Expand Down Expand Up @@ -146,7 +146,7 @@ function BuyMoreButton({
return (
<div className="ml-4 flex-shrink-0 sm:col-span-1 sm:mt-0">
<p className="font-medium text-sm text-indigo-600 hover:text-indigo-500">
{!isLoading ? <Link to="/pricing">Upgrade Plan</Link> : "Loading..."}
{!isLoading ? <Link to="/pricing">Buy More</Link> : "Loading..."}
</p>
{/* <button
onClick={handleClick}
Expand Down
14 changes: 7 additions & 7 deletions src/client/PricingPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,22 @@ const prices = [
// name: "Credits",
// id: "credits",
// href: "",
// price: "$",
// price: "$1",
// description: "Buy credits to use for your projects.",
// features: ["Use them any time", "No expiration date"],
// disabled: false,
// priceMonthly: "",
// },
{
name: "Lifetime Subscription",
id: "Lifetime",
name: "Credits",
id: "credits",
href: "#",
priceMonthly: "$1",
description: "Get access to all premium features.",
description: "Buy credits to use for your projects.",
features: [
"Unlimited usage of all features",
"Priority support",
"Cancel any time",
"Buy 10 credits for $1",
"Use them any time",
"No expiration date",
],
},
];
Expand Down

0 comments on commit 962646d

Please sign in to comment.