Browse Source

fix: 解决网站配置文件更新之后参数丢失的问题 (#4231)

Refs https://github.com/1Panel-dev/1Panel/issues/4171
pull/4235/head
zhengkunwang 8 months ago committed by GitHub
parent
commit
d916f2ba6f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 4
      backend/utils/nginx/parser/parser.go
  2. 2
      frontend/src/views/app-store/installed/index.vue

4
backend/utils/nginx/parser/parser.go

@ -61,7 +61,7 @@ func NewParserFromLexer(lexer *lexer) *Parser {
parser.directiveWrappers = map[string]func(*components.Directive) components.IDirective{ parser.directiveWrappers = map[string]func(*components.Directive) components.IDirective{
"server": func(directive *components.Directive) components.IDirective { "server": func(directive *components.Directive) components.IDirective {
return parser.parseUpstreamServer(directive) return parser.wrapServer(directive)
}, },
} }
@ -113,7 +113,7 @@ parsingloop:
case p.curTokenIs(flag.LuaCode): case p.curTokenIs(flag.LuaCode):
context.IsLuaBlock = true context.IsLuaBlock = true
context.LiteralCode = p.currentToken.Literal context.LiteralCode = p.currentToken.Literal
case p.curTokenIs(flag.Keyword): case p.curTokenIs(flag.Keyword) || p.curTokenIs(flag.QuotedString):
s, err := p.parseStatement() s, err := p.parseStatement()
if err != nil { if err != nil {
return nil, err return nil, err

2
frontend/src/views/app-store/installed/index.vue

@ -390,7 +390,7 @@ const changeTag = (key: string) => {
searchReq.tags = [key]; searchReq.tags = [key];
} }
const index = tags.value.findIndex((tag) => tag.key === key); const index = tags.value.findIndex((tag) => tag.key === key);
if (index > 5) { if (index > 6) {
moreTag.value = key; moreTag.value = key;
} else { } else {
moreTag.value = ''; moreTag.value = '';

Loading…
Cancel
Save