Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can't save properties config #3103

Closed
gz-yami opened this issue Jun 18, 2020 · 12 comments
Closed

can't save properties config #3103

gz-yami opened this issue Jun 18, 2020 · 12 comments
Assignees
Labels
area/Nacos console Related to Nacos consle contribution welcome kind/bug Category issues or prs related to bug.
Milestone

Comments

@gz-yami
Copy link

gz-yami commented Jun 18, 2020

version 1.3.0 release

if properties like this:

# port
server.port=8762

it will not work

chrome console error "Uncaught TypeError: Cannot read property 'currentLanguageCode' of undefined"

chinese:
properties 文件,有 "#" 注释的时候,就保存不了,控制台报错。"Uncaught TypeError: Cannot read property 'currentLanguageCode' of undefined"

写个配置文件的时候有注释很正常呀,以前是可以的,所以认为这个是一个挺影响使用的bug。

@KomachiSion KomachiSion added area/Config kind/bug Category issues or prs related to bug. area/Nacos console Related to Nacos consle and removed area/Config labels Jun 18, 2020
@KomachiSion KomachiSion added this to the 1.3.1 milestone Jun 18, 2020
@KomachiSion
Copy link
Collaborator

It may be a console bug.

@gz-yami
Copy link
Author

gz-yami commented Jun 18, 2020

It may be a console bug.

add a new config, choose format 'properties'

use

# port
server.port=8762

if you add a new properties, It will reappear. properties config can't save

if you update old properties, It will not reproduce. properties config can update

chinese:

  1. 新下载一个最新的 1.3.0 release 启动, 输入账号密码,进入“配置管理 - 配置列表 - 页面有个加号按钮,点击新建”

新建一个配置文件,选格式为 'properties'

输入

# 端口
server.port=8762

控制台就会报错,没有保存办法。

如果用编辑的话,是没有问题的。

@metaphysical-road
Copy link

这个在1.2.1也存在这样的问题
This problem also exists in 1.2.1

@chuntaojun
Copy link
Collaborator

#3173

@z589533
Copy link

z589533 commented Jul 21, 2020

这个问题一直存在,难道不打算搞好了?1.3.1也是一样

@chenhj520
Copy link

chenhj520 commented Jul 25, 2020

@KomachiSion
问题原因
使用的aliwareIntl 对象在globalLib文件中未定义

NewConfig.js  文件中 aliwareIntl对象从globalLib.js 引用,但是globalLib.js文件没有定义aliwareIntl对象。
import { getParams, setParams, request, aliwareIntl } from '../../../globalLib';

问题修复,有两处需要修改


       let currentLanguageCode = 'zh-cn';
        if (typeof aliwareIntl.currentLanguageCode !== 'undefined') {
          currentLanguageCode = aliwareIntl.currentLanguageCode || 'zh-cn';
        }
        Dialog.confirm({
          content: locale.confirmSyanx,
          language: currentLanguageCode,
          onOk: () => {
            this.publicConfigBeforeCheck(content);
          },
        });

@ljhrot
Copy link
Contributor

ljhrot commented Jul 25, 2020

@i will solve it@

@zongtanghu
Copy link
Collaborator

zongtanghu commented Jul 28, 2020

It's yours. @ljhrot And Can you put forward a pr in this week?

@ljhrot
Copy link
Contributor

ljhrot commented Jul 28, 2020

@zongtanghu Ok

@zongtanghu
Copy link
Collaborator

Okay, thanks your contribution.

@zongtanghu
Copy link
Collaborator

@ljhrot any progress?

KomachiSion pushed a commit that referenced this issue Jul 31, 2020
* Fix browser Uncaught TypeError when create a Properties type configuration

* Change Properties content verification method

* Update front end resources
@ljhrot
Copy link
Contributor

ljhrot commented Aug 2, 2020

@ready to close@

@KomachiSion KomachiSion modified the milestones: 1.3.2, 1.4.0 Aug 3, 2020
@KomachiSion KomachiSion mentioned this issue Aug 4, 2020
5 tasks
@KomachiSion KomachiSion modified the milestones: 1.4.0, 1.3.2 Aug 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/Nacos console Related to Nacos consle contribution welcome kind/bug Category issues or prs related to bug.
Projects
None yet
Development

No branches or pull requests

10 participants