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

插件疑问及建议 #14

Open
meifu2027 opened this issue Feb 22, 2019 · 16 comments
Open

插件疑问及建议 #14

meifu2027 opened this issue Feb 22, 2019 · 16 comments

Comments

@meifu2027
Copy link
Contributor

  1. 模板生成路径是否可以固定?由于已经有subPath的配置,建议增加默认配置项:default package

  2. subPath为何不能使用参数?

  3. 无需数据源如何生成?比如我只需要生成某些固定的前端页面;

  4. extention设置为html,生成的文件是.md

其他有想到再补充

@IceMimosa
Copy link
Collaborator

👍好建议,多谢。

@meifu2027
Copy link
Contributor Author

👍好建议,多谢。

其中几个是问题,烦请解答下。

@hykes
Copy link
Owner

hykes commented Feb 24, 2019

  1. codegen目前的设计是:选择路径(就是你指的default package,这是整个模版组共用的),同时可以设置subPath。 关于default package配置的建议,我们会考虑在下一版本中增加。
    2.subPath使用参数这个问题,烦请描述一下具体的场景。
    3.当前无数据源无法生成,这个问题我们考虑改进。
    4.目前支持 .kt .java .sql .md 四种后缀。下一版会加入 .xml .html。

感谢你的反馈! @meifu2027

@meifu2027
Copy link
Contributor Author

meifu2027 commented Feb 25, 2019

第2点,subPath无论设置为${model}(示例模板的动态参数)或 $!{directory}(中文文档中的自定义参数配置https://github.com/hykes/CodeGen/blob/master/doc/Guide_zh_v1.2.md ) 最终生成的子目录名都不是预期的动态参数,而是${model}或$!{directory}为目录名,也就是说参数设置不生效;
第4点,是否还会考虑加入.js .css等web开发中比较常见的文件类型?当前版本已实现.xml 文件类型。

@IceMimosa
Copy link
Collaborator

@meifu2027 有理有据,可以支持一下。

@meifu2027
Copy link
Contributor Author

@meifu2027 有理有据,可以支持一下。

谢谢老哥

@FutureStill
Copy link

请教一下,codegen插件模板,我这边显示是乱码问题。 怎么解决

@meifu2027
Copy link
Contributor Author

请教一下,codegen插件模板,我这边显示是乱码问题。 怎么解决

设置下idea的默认编码为utf-8再看看

@FutureStill
Copy link

我设置了utf-8,现在出现的是,Volecity模板引擎 不乱码,但是,Templates 中的模板乱码

@meifu2027
Copy link
Contributor Author

这个要作者来解答一下了

@FutureStill
Copy link

算了,我这边根据源码中的Templates 模板,手动把Templates 模板给改了。 谢谢

@hykes
Copy link
Owner

hykes commented Mar 25, 2019

是说CodeGen提供的默认模板出现乱码吗?麻烦提供下使用的插件版本号和IDEA版本号。

@FutureStill
Copy link

idea 是2018.3.5 ,插件版本v1.2.6

@FutureStill
Copy link

idea 是 Ultimate ,破解的。

@ailibob
Copy link

ailibob commented Mar 16, 2020

部分属性注释是乱码,请问是为什么

@hykes
Copy link
Owner

hykes commented Mar 18, 2020

部分属性注释是乱码,请问是为什么

能否提供一下截图和版本信息

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants