Skip to content

Commit

Permalink
Merge pull request #30 from MZC-CSC/develop
Browse files Browse the repository at this point in the history
Development for Release
  • Loading branch information
MZC-CSC authored Oct 31, 2024
2 parents 79d5476 + 1f4e135 commit 692e59f
Show file tree
Hide file tree
Showing 63 changed files with 3,248 additions and 1,783 deletions.
133 changes: 0 additions & 133 deletions .github/workflows/continuous-integration.yaml

This file was deleted.

6 changes: 0 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,6 @@ front/dist/
front/generated/
front/.vendor/
front/.pnp.*
front/.yarn/*
front/!.yarn/patches
front/!.yarn/plugins
front/!.yarn/releases
front/!.yarn/sdks
front/!.yarn/versions

front-backup/*

Expand Down
10 changes: 7 additions & 3 deletions api/actions/env.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,14 @@ import (
"strconv"
)

var MCIAM_USE = false // MC-IAM-MANAGER 사용여부, init 에서 재정의
var MCIAM_TICKET_USE = false // MC-IAM-MANAGER 티켓 사용여부, init 에서 재정의

var IFRAME_TARGET_IS_HOST = false // init 에서 재정의

func init() {
MCIAM_USE, _ = strconv.ParseBool(os.Getenv("MCIAM_USE"))
MCIAM_TICKET_USE, _ = strconv.ParseBool(os.Getenv("MCIAM_TICKET_USE"))
}

var MCIAM_USE = false // MC-IAM-MANAGER 사용여부, init 에서 재정의
var MCIAM_TICKET_USE = false // MC-IAM-MANAGER 티켓 사용여부, init 에서 재정의
IFRAME_TARGET_IS_HOST, _ = strconv.ParseBool(os.Getenv("IFRAME_TARGET_IS_HOST"))
}
16 changes: 16 additions & 0 deletions api/actions/routes.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
package actions

import (
"fmt"
"log"
"mc_web_console_api/handler"
"regexp"
"strings"

"github.com/gobuffalo/buffalo"
Expand Down Expand Up @@ -59,5 +61,19 @@ func GetApiHosts(c buffalo.Context) error {
return c.Render(200, r.JSON(map[string]interface{}{"error": err.Error()}))
}
commonResponse := handler.CommonResponseStatusOK(apiHosts)

re := regexp.MustCompile(`:(\d+.*)`)
if IFRAME_TARGET_IS_HOST {
for fw, host := range apiHosts {
portUrlStr := re.FindString(host.BaseURL)
if portUrlStr != "" {
host.BaseURL = portUrlStr
apiHosts[fw] = host
}
}
fmt.Println(apiHosts)
commonResponse = handler.CommonResponseStatusOK(apiHosts)
}

return c.Render(commonResponse.Status.StatusCode, r.JSON(commonResponse))
}
5 changes: 5 additions & 0 deletions conf/.env.sample
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,10 @@ export DATABASE_HOST=DATABASE_HOST # Please CHANGE ME (REQUIRE)
export DATABASE=DATABASE # Please CHANGE ME (REQUIRE)
export DATABASE_URL=postgres://${DATABASE_USER}:${DATABASE_PASS}@${DATABASE_HOST}:5432/${DATABASE}

# IFRAME_TARGET_IS_HOST [ true || false ]
export IFRAME_TARGET_IS_HOST=false
# if IFRAME_TARGET_IS_HOST is false, iframe will see the other server
# if true, iframe will see the host

export MCIAM_USE=true
export MCIAM_TICKET_USE=false
23 changes: 20 additions & 3 deletions front/assets/css/tabler.css
Original file line number Diff line number Diff line change
Expand Up @@ -4807,13 +4807,22 @@ body[data-bs-theme=dark] .navbar[data-bs-theme=light] {
margin-left: var(--tblr-card-spacer-x);
}


.card-header {
padding: var(--tblr-card-cap-padding-y) var(--tblr-card-cap-padding-x);
margin-bottom: 0;
color: var(--tblr-card-cap-color);
background-color: var(--tblr-card-cap-bg);
border-bottom: var(--tblr-card-border-width) solid var(--tblr-card-border-color);
}
.card-header.summary {
display: flex;
flex-direction: column;
padding: 0;
justify-content: center;
flex-wrap: nowrap;
align-items: flex-start;
}
.card-header:first-child {
border-radius: var(--tblr-card-inner-border-radius) var(--tblr-card-inner-border-radius) 0 0;
}
Expand Down Expand Up @@ -17498,11 +17507,12 @@ Navbar vertical
letter-spacing: 0.04em;
line-height: 1rem;
color: var(--tblr-secondary);
margin-bottom: 0.2rem;
}

.page-title {
margin: 0;
font-size: var(--tblr-font-size-h2);
font-size: 1.5rem;
line-height: var(--tblr-line-height-h4);
font-weight: var(--tblr-font-weight-headings);
color: inherit;
Expand Down Expand Up @@ -20598,10 +20608,17 @@ Card table
padding-right: 1.25rem;
border-right: 0;
}
.card-table thead tr:first-child,
.card-table tbody tr:first-child,
.card-table thead tr:first-child{
font-weight: var(--tblr-font-weight-bold)
}
.card-table tbody tr:first-child{
font-size: 0.875rem
}
.card-table tfoot tr:first-child {
border-top: 0;
font-size: 0.75rem;
padding-top: 0.25rem;
padding-bottom: 0.25rem;
}
.card-table thead tr:first-child td,
.card-table thead tr:first-child th,
Expand Down
2 changes: 1 addition & 1 deletion front/assets/css/tabler_custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

//summary font size
.card-title.summary {
font-size: 200%;
font-size: 1.1rem;
}

// sidebar non-clickable text set
Expand Down
1 change: 1 addition & 0 deletions front/assets/css/tabulator_for_tabler.scss
Original file line number Diff line number Diff line change
Expand Up @@ -92,5 +92,6 @@ $rangeHeaderTextHighlightBackground: #000000; //header text color when highlight
.tabulator-page{
&.active{
font-weight: bold;
background-color: var(--tblr-primary-lt);
}
}
Binary file added front/assets/images/common/img_logo_azure.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added front/assets/images/common/img_logo_mcmp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion front/assets/js/common/api/http.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export async function commonAPIPost(url, data, attempt) {
console.log("refreshCookieAccessToken success. Retrying request with refreshed token...");
return commonAPIPost(url, data, true);
} else {
alert("you logged in other device : ", error.message);
alert("session is expired");
window.location = "/auth/login"
return
}
Expand Down
Loading

0 comments on commit 692e59f

Please sign in to comment.