Skip to content

Commit 140b44b

Browse files
author
sunxingba
committed
EI管理控制台UI个性化项目初始化
0 parents  commit 140b44b

File tree

8 files changed

+427
-0
lines changed

8 files changed

+427
-0
lines changed

README.md

+93
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
![长城数字](assets/gdslogo-dark.png)
2+
3+
## 适用EI版本
4+
5+
本项目仅适用于定制EI的6.4.0版本,依赖的carbon-ui版本是4.4.36.
6+
7+
> 若针对其它EI版本或WSO2产品,需要查看该版本所依赖的carbon-ui版本修改项目主pom.xml中的**CARBON.UI.VERSION.NUMBER**属性,然后执行mvn clean install进行项目构建。
8+
9+
## 一、说明
10+
11+
每个carbon产品的用户界面允许您配置、监控、调整和维护产品。 的组件制定这些用户界面的设计和风格在资源(jar)文件中定义。
12+
13+
每一个carbon产品的用户界面由两层组成:
14+
15+
- 常见的产品布局/设计继承了carbon平台:所有常见的模板,风格(CSS文件),和图像存储在carbon核心UI包,命名`org.wso2.carbon.ui-<version-number>.jar`(`<version-number>`是包的特定版本)。 这个包是负责整个carbon平台的整体外观和感觉。
16+
- 每个产品特有的风格/图片:每个carbon产品(即建立在carbon内核)还有另一个风格包,其中包含所有最重要的样式表和图片:`org.wso2.<product-name>.styles-<version-number>.jar`
17+
18+
您可以定制用户界面通过修改这些资源文件。 您需要创建一个片段为原始资源文件包。 然后,您可以把修改资源文件中所需的包。 文件所需的包将会得到优先级和将会覆盖在原来的文件包。
19+
20+
你可以使用相同的技术来定制用户界面的任何方面。 这种技术的优点是,你不会失去你的定制应用官方补丁的产品替换原有的包。
21+
22+
## 二、参考
23+
24+
详细说明请参考:[Customizing+the+Management+Console](https://docs.wso2.com/display/ADMIN44x/Customizing+the+Management+Console)
25+
26+
## 三、如何使用该项目来自定义EI的管理控制台?
27+
28+
1、拉取项目
29+
30+
```
31+
git clone https://github.com/tongpi/carbon-ui-custom-ei.git
32+
```
33+
34+
2、创建项目分支
35+
36+
```shell
37+
git checkout -b wch_lbb
38+
# wch_lbb是根据项目信息定义的分支名称
39+
```
40+
41+
3、开始定制
42+
43+
> 1)、修改pom.xml文件中的**CARBON.UI.VERSION.NUMBER**属性适合你的产品版本
44+
>
45+
> 2)、修改模块项目**org.wso2.carbon.ui_patch**中的src/main/resources/web/admin文件夹下的三个子文件夹中的内容
46+
>
47+
> css/customizations.css 你需要修改的样式文件。
48+
>
49+
> images/ 你需要添加或修改的图片文件
50+
>
51+
> layout/template.jsp 你需要修改的界面布局文件
52+
53+
54+
55+
4、构建这个项目。
56+
57+
> 打开终端,导航到相关项目目录(上述),并执行下面的命令:
58+
>
59+
> ```
60+
> mvn clean install
61+
> ```
62+
>
63+
> 这个项目包含两个模块:
64+
>
65+
> ```
66+
> org.wso2.carbon.ui_4.4.36_fragment
67+
> org.wso2.carbon.ui_4.4.36_patch
68+
> ```
69+
>
70+
> 项目构建成功后,会分别在上述两个模块的target目录下各生成一个jar文件。
71+
>
72+
> ```
73+
> org.wso2.carbon.ui_4.4.36_fragment-1.0.0.jar
74+
> org.wso2.carbon.ui_4.4.36_patch-1.0.0.jar
75+
> ```
76+
77+
5、复制上面两个jar文件到下面的目录中
78+
79+
```
80+
<PRODUCT_HOME>/dropins/
81+
```
82+
83+
6、重新启动WSO2产品服务器。
84+
85+
7、提交你的修改到你创建的分支并push到https://github.com/tongpi/carbon-ui-custom-ei.git
86+
87+
```shell
88+
git commit -am "<message>"
89+
90+
git push -u origin wch_lbb
91+
# wch_lbb是根据项目信息定义的分支名称
92+
```
93+

assets/gdslogo-dark.png

7.22 KB
Loading
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
5+
<modelVersion>4.0.0</modelVersion>
6+
<parent>
7+
<groupId>gds.ei</groupId>
8+
<artifactId>carbon-ui-custom-ei</artifactId>
9+
<relativePath>../../pom.xml</relativePath>
10+
<version>1.0.0</version>
11+
</parent>
12+
<groupId>org.wso2.carbon</groupId>
13+
<artifactId>org.wso2.carbon.ui_${CARBON.UI.VERSION.NUMBER}_fragment</artifactId>
14+
<version>1.0.0</version>
15+
<packaging>bundle</packaging>
16+
17+
<build>
18+
<plugins>
19+
<plugin>
20+
<groupId>org.apache.felix</groupId>
21+
<artifactId>maven-bundle-plugin</artifactId>
22+
<version>3.0.1</version>
23+
<extensions>true</extensions>
24+
<configuration>
25+
<instructions>
26+
<Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
27+
<Bundle-Name>${project.artifactId}</Bundle-Name>
28+
<Require-Bundle>org.wso2.carbon.ui_${CARBON.UI.VERSION.NUMBER}_patch</Require-Bundle>
29+
<Fragment-Host>org.wso2.carbon.ui</Fragment-Host>
30+
</instructions>
31+
</configuration>
32+
</plugin>
33+
</plugins>
34+
</build>
35+
</project>
+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
5+
<modelVersion>4.0.0</modelVersion>
6+
<parent>
7+
<groupId>gds.ei</groupId>
8+
<artifactId>carbon-ui-custom-ei</artifactId>
9+
<relativePath>../../pom.xml</relativePath>
10+
<version>1.0.0</version>
11+
</parent>
12+
<groupId>org.wso2.carbon</groupId>
13+
<artifactId>org.wso2.carbon.ui_${CARBON.UI.VERSION.NUMBER}_patch</artifactId>
14+
<packaging>bundle</packaging>
15+
16+
<build>
17+
<plugins>
18+
<plugin>
19+
<groupId>org.apache.felix</groupId>
20+
<artifactId>maven-bundle-plugin</artifactId>
21+
<version>3.0.1</version>
22+
<extensions>true</extensions>
23+
<configuration>
24+
<instructions>
25+
<Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
26+
<Bundle-Name>${project.artifactId}</Bundle-Name>
27+
<Export-Package>web.admin.*</Export-Package>
28+
</instructions>
29+
</configuration>
30+
</plugin>
31+
</plugins>
32+
</build>
33+
</project>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#header div#header-div div.left-logo {
2+
background-image: url( ../images/ei-header-logo.png );
3+
background-repeat: no-repeat;
4+
background-position: left top;
5+
background-size: contain;
6+
height: 32px;
7+
width: 330px;
8+
margin-top: 23px;
9+
margin-left: 20px;
10+
float: left;
11+
}
Loading

0 commit comments

Comments
 (0)