Wiki source code of Home

Version 12.1 by Jiahao Lai on 2026/03/26 15:46

Show last authors
1 {{include reference="Help.Code.VelocityMacros"/}}
2
3 {{velocity output="false"}}
4 #macro (display4Cards $cards)
5 <div class="row">
6 #foreach ($card in $cards)
7 ## See http://getbootstrap.com/css/#grid-responsive-resets .
8 #if ($foreach.index > 0 && $foreach.index % 2 == 0)
9 <div class="clearfix visible-sm-block "></div>
10 #end
11 #if ($foreach.index > 0 && $foreach.index % 3 == 0)
12 <div class="clearfix visible-md-block"></div>
13 #end
14 #if ($foreach.index > 0 && $foreach.index % 4 == 0)
15 <div class="clearfix visible-lg-block"></div>
16 #end
17 <div class="col-xs-12 col-sm-6 col-md-4 col-lg-3">
18 #helpExampleCard($card)
19 </div>
20 #end
21 </div>
22 #end
23
24
25 #set ($PI = [{
26 'icon': 'fa fa-file-text-o',
27 'title': "Manual",
28 'description':'Mainly software configuration manuals',
29 'documentation': "https://docs.we-con.com.cn/bin/view/PIStudio/2.Installation%20Software/"
30 }, {
31 'icon': 'fa fa-support',
32 'title': "Demo",
33 'description': 'Abundant functions are demonstrated through different demo',
34 'documentation': "https://docs.we-con.com.cn/bin/view/PIStudio/2%20Demo/"
35 }, {
36 'icon': 'fa fa-play-circle',
37 'title': "Videos",
38 'description': 'Video shows function more clearly',
39 'documentation': "https://www.youtube.com/playlist?list=PL_Bpnb2RgaktphrxRaCpFA809H_0xs-cU"
40 },{
41 'icon': 'fa fa-download',
42 'title': "Download",
43 'description': 'Software Download',
44 'documentation': "https://docs.we-con.com.cn/bin/view/PIStudio/Download/"
45 }])
46
47
48 #set ($PLC = [{
49 'icon': 'fa fa-file-text-o',
50 'title': "Manual",
51 'description': 'Mainly software configuration manuals',
52 'documentation': "https://docs.we-con.com.cn/bin/view/PLC%20Editor2/01%20Program%20execution/"
53 }, {
54 'icon': 'fa fa-support',
55 'title': "Demo",
56 'description': 'Abundant functions are demonstrated through different demo',
57 'documentation': "https://docs.we-con.com.cn/bin/view/PLC%20Editor2/2%20Demos/"
58 }, {
59 'icon': 'fa fa-play-circle',
60 'title': "Videos",
61 'description': 'Video shows function more clearly',
62 'documentation': "https://www.youtube.com/playlist?list=PL_Bpnb2RgaktxcT6G9n1meunomIw3T81_"
63 },{
64 'icon': 'fa fa-download',
65 'title': "Download",
66 'description': 'Software Download',
67 'documentation': "https://docs.we-con.com.cn/bin/view/PLC%20Editor2/Download/"
68 }])
69
70 #set ($V-BOX = [{
71 'icon': 'fa fa-file-text-o',
72 'title': "Manual",
73 'description': 'Mainly software configuration manuals',
74 'documentation': "https://docs.we-con.com.cn/bin/view/V-BOX/V-Net/Manual/"
75 }, {
76 'icon': 'fa fa-support',
77 'title': "Demo",
78 'description': 'Abundant functions are demonstrated through different demo',
79 'documentation': "https://docs.we-con.com.cn/bin/view/V-BOX/V-Net/Training/"
80 }, {
81 'icon': 'fa fa-play-circle',
82 'title': "Videos",
83 'description': 'Video shows function more clearly',
84 'documentation': "https://www.youtube.com/playlist?list=PL_Bpnb2RgakvYq_Ypk9bydIP7lUfkTDBN"
85 },{
86 'icon': 'fa fa-download',
87 'title': "Download",
88 'description': 'Software Download',
89 'documentation': "https://docs.we-con.com.cn/bin/view/V-BOX/V-Net/Download/"
90 }])
91
92 #set ($Servo = [{
93 'icon': 'fa fa-file-text-o',
94 'title': "Manual",
95 'description': 'Mainly software configuration manuals',
96 'documentation': "https://docs.we-con.com.cn/bin/view/Servo/Manual/"
97 }, {
98 'icon': 'fa fa-support',
99 'title': "Demo",
100 'description': 'Abundant functions are demonstrated through different demo',
101 'documentation': "https://docs.we-con.com.cn/bin/view/Servo/Demo/"
102 }, {
103 'icon': 'fa fa-play-circle',
104 'title': "Videos",
105 'description': 'Video shows function more clearly',
106 'documentation': "https://www.youtube.com/playlist?list=PL_Bpnb2Rgakum51_QOIFgMjqsod2i1UcB"
107 },{
108 'icon': 'fa fa-download',
109 'title': "Download",
110 'description': 'Software Download',
111 'documentation': "https://docs.we-con.com.cn/bin/view/Servo/Download/"
112 }])
113
114 #set ($Inverter = [{
115 'icon': 'fa fa-file-text-o',
116 'title': "Manual",
117 'description': 'Mainly software configuration manuals',
118 'documentation': "https://docs.we-con.com.cn/bin/view/VFD/VM%20AC%20Drive%20User%20Manual/"
119 }, {
120 'icon': 'fa fa-support',
121 'title': "Demo",
122 'description': 'Abundant functions are demonstrated through different demo',
123 'documentation': "https://docs.we-con.com.cn/bin/view/VFD/3.%20Demo/"
124 }, {
125 'icon': 'fa fa-play-circle',
126 'title': "Videos",
127 'description': 'Video shows function more clearly',
128 'documentation': "https://www.youtube.com/playlist?list=PL_Bpnb2RgaktOITeNo-g3fq0jBFoubYGz"
129 },{
130 'icon': 'fa fa-download',
131 'title': "Download",
132 'description': 'Software Download',
133 'documentation': "https://docs.we-con.com.cn/bin/view/VFD/Download/"
134 }])
135
136 {{/velocity}}
137
138 {{velocity}}
139 = $services.localization.render("PI HMI") =
140
141 $services.localization.render("")
142
143 {{html clean="false"}}
144 #display4Cards($PI)
145 {{/html}}
146 {{/velocity}}
147
148
149 {{velocity}}
150 = $services.localization.render("PLC") =
151
152 $services.localization.render("")
153
154 {{html clean="false"}}
155 #display4Cards($PLC)
156 {{/html}}
157 {{/velocity}}
158
159 {{velocity}}
160 = $services.localization.render("V-BOX") =
161
162 $services.localization.render("")
163
164 {{html clean="false"}}
165 #display4Cards($V-BOX)
166 {{/html}}
167 {{/velocity}}
168
169 {{velocity}}
170 = $services.localization.render("Servo") =
171
172 $services.localization.render("")
173
174 {{html clean="false"}}
175 #display4Cards($Servo)
176 {{/html}}
177 {{/velocity}}
178
179 {{velocity}}
180 = $services.localization.render("Inverter") =
181
182 $services.localization.render("")
183
184 {{html clean="false"}}
185 #display4Cards($Inverter)
186 {{/html}}
187 {{/velocity}}
188
189
190
191 {{html clean="false"}}
192 <div id="llm-chat-widget" style="position:fixed;right:20px;bottom:20px;z-index:9999;"></div>
193
194 <script>
195 document.addEventListener('DOMContentLoaded', function() {
196 setTimeout(async () => {
197 try {
198 // 1. 先加载依赖库 marked.js(子 wiki 用的版本)
199 await new Promise((resolve, reject) => {
200 const markedScript = document.createElement('script');
201 markedScript.src = 'https://docs.we-con.com.cn/webjars/wiki%3Awonway/marked/4.0.2/marked.min.js';
202 markedScript.onload = resolve;
203 markedScript.onerror = reject;
204 document.body.appendChild(markedScript);
205 });
206 console.log("✅ marked.js 加载成功");
207
208 // 2. 加载 CSS
209 await new Promise((resolve) => {
210 const link = document.createElement('link');
211 link.rel = 'stylesheet';
212 link.href = 'https://docs.we-con.com.cn/webjars/wiki%3Awonway/application-ai-llm-chat-webjar/0.7.2/chatWidget.css';
213 link.onload = resolve;
214 document.head.appendChild(link);
215 });
216
217 // 3. 加载 chatWidget.js
218 await new Promise((resolve) => {
219 const script = document.createElement('script');
220 script.src = 'https://docs.we-con.com.cn/webjars/wiki%3Awonway/application-ai-llm-chat-webjar/0.7.2/chatWidget.js';
221 script.onload = resolve;
222 document.body.appendChild(script);
223 });
224
225 // 4. 启动浮窗
226 if (window.LLMChatWidget && typeof LLMChatWidget.init === 'function') {
227 LLMChatWidget.init();
228 console.log("✅ 浮窗启动成功!");
229 } else {
230 throw new Error("LLMChatWidget 未初始化");
231 }
232 } catch (e) {
233 console.error("❌ 加载失败", e);
234 alert("浮窗加载失败:" + e.message);
235 }
236 }, 1000);
237 });
238 </script>
239 {{/html}}