Quellcode durchsuchen

代码模板,列固定

CzRger vor 9 Monaten
Ursprung
Commit
3168e21976

+ 3 - 3
snowy-plugin/snowy-plugin-gen/src/main/resources/frontend/index.vue.btl

@@ -193,10 +193,10 @@
 			ellipsis: true,
 			<% } %>
 			<% if(configList[i].whetherSort) { %>
-                sorter: true,
+            sorter: true,
             <% } %>
-            <% if(configList[i].whetherFixed) { %>
-                fixed: ${configList[i].whetherFixed == 1 ? 'left' : 'right'},
+            <% if(configList[i].whetherFixed != 0) { %>
+            fixed: '<% if(configList[i].whetherFixed == 1) { %>left<% } %><% if(configList[i].whetherFixed == 2) { %>right<% } %>',
             <% } %>
 		},
 	<% } %>

+ 4 - 4
snowy-plugin/snowy-plugin-gen/src/main/resources/frontend/index_inside.vue.btl

@@ -191,13 +191,13 @@
 			title: '${configList[i].fieldRemark}',
 			dataIndex: '${configList[i].fieldNameCamelCase}',
 			<% if(configList[i].whetherRetract) { %>
-                ellipsis: true,
+            ellipsis: true,
             <% } %>
             <% if(configList[i].whetherSort) { %>
-                sorter: true,
+            sorter: true,
             <% } %>
-            <% if(configList[i].whetherFixed) { %>
-                fixed: ${configList[i].whetherFixed == 1 ? 'left' : 'right'},
+            <% if(configList[i].whetherFixed != 0) { %>
+            fixed: '<% if(configList[i].whetherFixed == 1) { %>left<% } %><% if(configList[i].whetherFixed == 2) { %>right<% } %>',
             <% } %>
 		},
 	<% } %>