From 7bfd823339a0dad5c0df6a6f75b4f68658b2856c Mon Sep 17 00:00:00 2001 From: Pritish Budhiraja <77892330+PritishBudhiraja@users.noreply.github.com> Date: Mon, 4 Dec 2023 14:53:43 +0530 Subject: [PATCH 1/7] chore: workflow-changes (#49) --- .github/workflows/release-new-version.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release-new-version.yml b/.github/workflows/release-new-version.yml index 01ca10b53..73640cfb7 100644 --- a/.github/workflows/release-new-version.yml +++ b/.github/workflows/release-new-version.yml @@ -30,9 +30,9 @@ jobs: steps: - name: Checkout repository uses: actions/checkout@v4 - # with: - # fetch-depth: 0 - # token: ${{ secrets.AUTO_RELEASE_PAT }} + with: + fetch-depth: 0 + token: ${{ secrets.AUTO_RELEASE_PAT }} - name: Install Rust uses: dtolnay/rust-toolchain@master From 68c61169e048e54892b71df8ed5844b3d00138e0 Mon Sep 17 00:00:00 2001 From: Jeeva Ramachandran Date: Mon, 4 Dec 2023 15:11:11 +0530 Subject: [PATCH 2/7] 1.0.3 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index a315ba727..01c1d9929 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "rescript-euler-dashboard", - "version": "1.0.2", + "version": "1.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "rescript-euler-dashboard", - "version": "1.0.2", + "version": "1.0.3", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index c2f9c4eac..8e36174b9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "rescript-euler-dashboard", - "version": "1.0.2", + "version": "1.0.3", "main": "index.js", "author": "Shiva Nandan ", "license": "MIT", From 0133ff13a7e915c4c796bd98fbaf92400690531a Mon Sep 17 00:00:00 2001 From: Jeeva Ramachandran <120017870+JeevaRamu0104@users.noreply.github.com> Date: Mon, 4 Dec 2023 15:26:43 +0530 Subject: [PATCH 3/7] chore: remove dead code (#50) --- src/screens/HyperSwitch/HSwitchUtils.res | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/screens/HyperSwitch/HSwitchUtils.res b/src/screens/HyperSwitch/HSwitchUtils.res index cdeb685ff..68048672a 100644 --- a/src/screens/HyperSwitch/HSwitchUtils.res +++ b/src/screens/HyperSwitch/HSwitchUtils.res @@ -227,18 +227,6 @@ let getBrowswerDetails = () => { } } -let getLabelToCountryMapper = primary_business_details => { - primary_business_details->Array.reduce(Js.Dict.empty(), ( - acc, - currentDetail: HSwitchSettingTypes.businessEntity, - ) => { - let labelsYet = acc->Js.Dict.get(currentDetail.country)->Belt.Option.getWithDefault([]) - labelsYet->Array.push(currentDetail.business) - acc->Js.Dict.set(currentDetail.country, labelsYet) - acc - }) -} - module BackgroundImageWrapper = { @react.component let make = ( From eebee659a8326aa32ebcbe2d06c21e8487bea377 Mon Sep 17 00:00:00 2001 From: Pritish Budhiraja <77892330+PritishBudhiraja@users.noreply.github.com> Date: Mon, 4 Dec 2023 15:38:59 +0530 Subject: [PATCH 4/7] fix: dead code removal (#52) --- package.json | 2 +- .../UserManagement/HSwitchUserRoleEntity.res | 50 ------------------- 2 files changed, 1 insertion(+), 51 deletions(-) diff --git a/package.json b/package.json index 8e36174b9..0ca190a14 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "rescript-euler-dashboard", + "name": "hyperswitch-dashboard", "version": "1.0.3", "main": "index.js", "author": "Shiva Nandan ", diff --git a/src/screens/HyperSwitch/UserManagement/HSwitchUserRoleEntity.res b/src/screens/HyperSwitch/UserManagement/HSwitchUserRoleEntity.res index d27ae6dfb..23afdc956 100644 --- a/src/screens/HyperSwitch/UserManagement/HSwitchUserRoleEntity.res +++ b/src/screens/HyperSwitch/UserManagement/HSwitchUserRoleEntity.res @@ -31,10 +31,6 @@ type roleColTypes = | Description | ActiveUsers -let defaultColumnsForRole = [Role, Description, CreatedBy, CreatedOn, ActiveUsers] - -let allColumnsForRole = [Role, Description, CreatedBy, CreatedOn, ActiveUsers] - let itemToObjMapperForUser = dict => { { user_id: getString(dict, "user_id", ""), @@ -74,18 +70,6 @@ let itemToObjMapperForRole = dict => { } } -let getHeadingForRole = colType => { - switch colType { - | Role => Table.makeHeaderInfo(~key="role", ~title="Role name", ~showSort=true, ()) - | Description => - Table.makeHeaderInfo(~key="description", ~title="Description", ~showSort=true, ()) - | CreatedBy => Table.makeHeaderInfo(~key="created_by", ~title="Created By", ~showSort=true, ()) - | CreatedOn => Table.makeHeaderInfo(~key="created_on", ~title="Created On", ~showSort=true, ()) - | ActiveUsers => - Table.makeHeaderInfo(~key="activeUsers", ~title="Active Users", ~showSort=true, ()) - } -} - let roleToVariantMapper = role => { switch role->Js.String2.toUpperCase { | "ADMIN" => Admin @@ -149,32 +133,10 @@ let getCellForUser = (data: userTableTypes, colType: userColTypes): Table.cell = } } -let getCellForRole = (data: roleTableTypes, colType: roleColTypes): Table.cell => { - let role = data.role_id->roleToVariantMapper - switch colType { - | Role => - CustomCell( -
getCssMapperForRole}`}> - {data.role_id->Js.String2.toUpperCase->React.string} -
, - "", - ) - | Description => Text(data.role_id) - | CreatedBy => Text(data.role_id) - | CreatedOn => Date(data.role_id) - | ActiveUsers => Text(data.role_id) - } -} - let getUserData: Js.Json.t => array = json => { getArrayDataFromJson(json, itemToObjMapperForUser) } -let getRoleData: Js.Json.t => array = json => { - getArrayDataFromJson(json, itemToObjMapperForRole) -} - let userEntity = EntityType.makeEntity( ~uri="", ~getObjects=getUserData, @@ -186,15 +148,3 @@ let userEntity = EntityType.makeEntity( ~getShowLink={userId => `/users/${userId.user_id}?state=user`}, (), ) - -// let roleEntity = EntityType.makeEntity( -// ~uri="", -// ~getObjects=getRoleData, -// ~defaultColumns=defaultColumnsForRole, -// ~allColumns=allColumnsForRole, -// ~getHeading=getHeadingForRole, -// ~getCell=getCellForRole, -// ~dataKey="", -// ~getShowLink={roleId => `/users/${roleId.role_id}?state=role`}, -// (), -// ) From 6978bf6814fb856c67a0fe409638982239c1af80 Mon Sep 17 00:00:00 2001 From: Pritish Budhiraja <77892330+PritishBudhiraja@users.noreply.github.com> Date: Mon, 4 Dec 2023 16:00:24 +0530 Subject: [PATCH 5/7] fix: remove CHANGELOG.md (#53) --- .githooks/commit-msg | 2 +- .prettierignore | 1 + CHANGELOG.md | 18 ------------------ 3 files changed, 2 insertions(+), 19 deletions(-) create mode 100644 .prettierignore delete mode 100644 CHANGELOG.md diff --git a/.githooks/commit-msg b/.githooks/commit-msg index 865cf65c2..0848397bd 100755 --- a/.githooks/commit-msg +++ b/.githooks/commit-msg @@ -11,7 +11,7 @@ npx prettier --write . npm run re:format # Define your commit message convention (e.g., starts with "feature:", "fix:", etc.) -commit_regex="^(Merge branch|feat|fix|chore|docs|style|refactor|test|enhancement).+" +commit_regex="^(Merge branch|feat|fix|chore|docs|style|refactor|test|enhancement):.+" if ! echo "$commit_msg" | grep -Ei "$commit_regex" ; then echo "Aborting commit. Your commit message does not follow the conventional format." diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 000000000..83b694704 --- /dev/null +++ b/.prettierignore @@ -0,0 +1 @@ +CHANGELOG.md \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index ccce7288b..000000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,18 +0,0 @@ -# Changelog - -All notable changes to this project will be documented in this file. See [conventional commits](https://www.conventionalcommits.org/) for commit guidelines. - ---- - -## 1.1.0 (2023-11-29) - -### Features - -- Add-release-new-version-action ([`880a10e`](https://github.com/juspay/hyperswitch-control-center/commit/880a10e0695284bb76a6e4cf156774a8a6e0fb01)) -- Add change log template ([`9475c4a`](https://github.com/juspay/hyperswitch-control-center/commit/9475c4a2863c12110a4f8bf2826fa68cdba7ab09)) - -**Full Changelog:** [`v1.0.2...v1.1.0`](https://github.com/juspay/hyperswitch-control-center/compare/v1.0.2...v1.1.0) - ---- - -Changelog generated by [cocogitto](https://github.com/cocogitto/cocogitto). From 20d93eb1186ad2e3e12f7628276a658aa13ca692 Mon Sep 17 00:00:00 2001 From: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 4 Dec 2023 10:32:48 +0000 Subject: [PATCH 6/7] chore(version): v1.0.4 --- CHANGELOG.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 000000000..a4247f0cb --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,21 @@ +# Changelog +All notable changes to this project will be documented in this file. See [conventional commits](https://www.conventionalcommits.org/) for commit guidelines. + +- - - + +## 1.0.4 (2023-12-04) + +### Bug Fixes + +- Dead code removal ([#52](https://github.com/juspay/hyperswitch-control-center/pull/52)) ([`eebee65`](https://github.com/juspay/hyperswitch-control-center/commit/eebee659a8326aa32ebcbe2d06c21e8487bea377)) +- Remove CHANGELOG.md ([#53](https://github.com/juspay/hyperswitch-control-center/pull/53)) ([`6978bf6`](https://github.com/juspay/hyperswitch-control-center/commit/6978bf6814fb856c67a0fe409638982239c1af80)) + +### Miscellaneous Tasks + +- Remove dead code ([#50](https://github.com/juspay/hyperswitch-control-center/pull/50)) ([`0133ff1`](https://github.com/juspay/hyperswitch-control-center/commit/0133ff13a7e915c4c796bd98fbaf92400690531a)) + +**Full Changelog:** [`v1.0.3...v1.0.4`](https://github.com/juspay/hyperswitch-control-center/compare/v1.0.3...v1.0.4) + +- - - + +Changelog generated by [cocogitto](https://github.com/cocogitto/cocogitto). \ No newline at end of file From 4ef0b5707aa9293ae3904858daaf645fa69fc7cc Mon Sep 17 00:00:00 2001 From: Pritish Budhiraja <77892330+PritishBudhiraja@users.noreply.github.com> Date: Mon, 4 Dec 2023 16:32:55 +0530 Subject: [PATCH 7/7] chore: Release new version workflow fixes (#54) --- .github/workflows/release-new-version.yml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/release-new-version.yml b/.github/workflows/release-new-version.yml index 73640cfb7..ade4f1982 100644 --- a/.github/workflows/release-new-version.yml +++ b/.github/workflows/release-new-version.yml @@ -1,19 +1,19 @@ name: Release a new hyperswitch version -# on: -# schedule: -# - cron: "30 14 * * 0-4" # Run workflow at 8 PM IST every Sunday-Thursday +on: + schedule: + - cron: "30 14 * * 0-4" # Run workflow at 8 PM IST every Sunday-Thursday -# workflow_dispatch: + workflow_dispatch: -# concurrency: -# group: ${{ github.workflow }}-${{ github.ref }} -# cancel-in-progress: true +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true -on: - pull_request_target: - types: - - closed +# on: +# pull_request_target: +# types: +# - closed env: # Allow more retries for network requests in cargo (downloading crates) and