Pārlūkot izejas kodu

Merge branch 'feature/Common.paging_style_round' into 'develop'

Merge of feature/[数据中心]视图分页增加圆角方角设置 to develop

See merge request o2oa/o2oa!264
蔡祥熠 5 gadi atpakaļ
vecāks
revīzija
4b00709d0a

+ 163 - 0
o2web/source/o2_core/o2/widget/$Paging/blue_round/css.wcss

@@ -0,0 +1,163 @@
+{
+    "pagingBarWraper" : {
+        "height" : "60px",
+        "overflow" : "hidden"
+    },
+    "pagingBar" : {
+        "float": "left",
+        "margin-left": "10px",
+        "margin-top": "18px",
+        "height": "24px",
+        "color": "#777777"
+    },
+    "firstPage" : {
+        "height": "24px",
+        "width": "80px",
+        "border": "1px solid #e6e6e6",
+        "border-radius" : "12px",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "margin-right": "10px",
+        "color" : "inherit",
+        "background-color": "#ffffff",
+        "float": "left"
+    },
+    "firstPage_over" : {
+        "color" : "#ffffff",
+        "background-color": "#4a90e2"
+    },
+    "lastPage" : {
+        "height": "24px",
+        "width": "80px",
+        "border": "1px solid #e6e6e6",
+        "border-radius" : "12px",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "color" : "inherit",
+        "background-color": "#ffffff",
+        "float": "left"
+    },
+    "lastPage_over" : {
+        "color" : "#ffffff",
+        "background-color": "#4a90e2"
+    },
+    "prePage" : {
+        "width": "24px",
+        "height": "24px",
+        "border-radius" : "12px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "background-color": "#ffffff",
+        "float": "left",
+        "margin-right": "10px",
+        "background": "url(/o2_core/o2/widget/$Paging/default/icon/left.png) no-repeat center center"
+    },
+    "prePage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "nextPage" : {
+        "width": "24px",
+        "height": "24px",
+        "border-radius" : "12px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "background-color": "#ffffff",
+        "float": "left",
+        "margin-right": "10px",
+        "background": "url(/o2_core/o2/widget/$Paging/default/icon/right.png) no-repeat center center"
+    },
+    "nextPage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "pageTurnContainer" : {
+        "float" : "left"
+    },
+    "pageItem" : {
+        "padding-left": "5px",
+        "padding-right" : "5px",
+        "height": "24px",
+        "border-radius" : "12px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#ffffff"
+    },
+    "pageItem_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "preBatchPage" : {
+        "padding-left": "5px",
+        "padding-right" : "5px",
+        "height": "24px",
+        "line-height": "normal",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "border-radius" : "12px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#ffffff"
+    },
+    "preBatchPage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "nextBatchPage" : {
+        "padding-left": "5px",
+        "padding-right" : "5px",
+        "height": "24px",
+        "line-height": "normal",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "border-radius" : "12px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#ffffff"
+    },
+    "nextBatchPage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "currentPage" : {
+        "width": "24px",
+        "height": "24px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "border-radius" : "12px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#4a90e2",
+        "color": "#ffffff"
+    },
+    "pageJumper" : {
+        "float" : "left",
+        "height" : "20px",
+        "border-radius" : "4px",
+        "line-height" : "20px",
+        "text-align" : "center",
+        "width" : "20px",
+        "margin-left" : "10px",
+        "border" : "1px solid #ddd"
+    },
+    "pageJumper_over" : {
+        "border" : "1px solid #43AAFA"
+    },
+    "pageJumperText" : {
+        "float" : "left",
+        "height" : "20px",
+        "padding" : "2px 5px",
+        "text-align" : "center",
+        "line-height" : "20px",
+        "margin-right" : "5px"
+    }
+}

BIN
o2web/source/o2_core/o2/widget/$Paging/blue_round/icon/left.png


BIN
o2web/source/o2_core/o2/widget/$Paging/blue_round/icon/right.png


+ 13 - 2
o2web/source/o2_core/o2/widget/$Paging/default/css.wcss

@@ -14,6 +14,7 @@
         "height": "24px",
         "width": "80px",
         "border": "1px solid #e6e6e6",
+        "border-radius" : "0px",
         "text-align": "center",
         "line-height": "24px",
         "cursor": "pointer",
@@ -22,12 +23,14 @@
         "float": "left"
     },
     "firstPage_over" : {
+        "color" : "inherit",
         "background-color": "#f1f1f1"
     },
     "lastPage" : {
         "height": "24px",
         "width": "80px",
         "border": "1px solid #e6e6e6",
+        "border-radius" : "0px",
         "text-align": "center",
         "line-height": "24px",
         "cursor": "pointer",
@@ -35,11 +38,13 @@
         "float": "left"
     },
     "lastPage_over" : {
+        "color" : "inherit",
         "background-color": "#f1f1f1"
     },
     "prePage" : {
         "width": "24px",
         "height": "24px",
+        "border-radius" : "0px",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
@@ -55,6 +60,7 @@
     "nextPage" : {
         "width": "24px",
         "height": "24px",
+        "border-radius" : "0px",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
@@ -74,6 +80,7 @@
         "padding-left": "5px",
         "padding-right" : "5px",
         "height": "24px",
+        "border-radius" : "0px",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
@@ -89,9 +96,10 @@
         "padding-left": "5px",
         "padding-right" : "5px",
         "height": "24px",
+        "line-height": "normal",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
-        "line-height": "24px",
+        "border-radius" : "0px",
         "cursor": "pointer",
         "float": "left",
         "margin-right": "10px",
@@ -104,9 +112,10 @@
         "padding-left": "5px",
         "padding-right" : "5px",
         "height": "24px",
+        "line-height": "normal",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
-        "line-height": "24px",
+        "border-radius" : "0px",
         "cursor": "pointer",
         "float": "left",
         "margin-right": "10px",
@@ -121,6 +130,7 @@
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
+        "border-radius" : "0px",
         "cursor": "pointer",
         "float": "left",
         "margin-right": "10px",
@@ -130,6 +140,7 @@
     "pageJumper" : {
         "float" : "left",
         "height" : "20px",
+        "border-radius" : "0px",
         "line-height" : "20px",
         "text-align" : "center",
         "width" : "20px",

+ 13 - 2
o2web/source/o2_core/o2/widget/$Paging/red/css.wcss

@@ -14,6 +14,7 @@
         "height": "24px",
         "width": "80px",
         "border": "1px solid #e6e6e6",
+        "border-radius" : "0px",
         "text-align": "center",
         "line-height": "24px",
         "cursor": "pointer",
@@ -22,12 +23,14 @@
         "float": "left"
     },
     "firstPage_over" : {
+        "color" : "inherit",
         "background-color": "#f1f1f1"
     },
     "lastPage" : {
         "height": "24px",
         "width": "80px",
         "border": "1px solid #e6e6e6",
+        "border-radius" : "0px",
         "text-align": "center",
         "line-height": "24px",
         "cursor": "pointer",
@@ -35,11 +38,13 @@
         "float": "left"
     },
     "lastPage_over" : {
+        "color" : "inherit",
         "background-color": "#f1f1f1"
     },
     "prePage" : {
         "width": "24px",
         "height": "24px",
+        "border-radius" : "0px",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
@@ -55,6 +60,7 @@
     "nextPage" : {
         "width": "24px",
         "height": "24px",
+        "border-radius" : "0px",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
@@ -74,6 +80,7 @@
         "padding-left": "5px",
         "padding-right" : "5px",
         "height": "24px",
+        "border-radius" : "0px",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
@@ -89,9 +96,10 @@
         "padding-left": "5px",
         "padding-right" : "5px",
         "height": "24px",
+        "line-height": "normal",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
-        "line-height": "24px",
+        "border-radius" : "0px",
         "cursor": "pointer",
         "float": "left",
         "margin-right": "10px",
@@ -104,9 +112,10 @@
         "padding-left": "5px",
         "padding-right" : "5px",
         "height": "24px",
+        "line-height": "normal",
         "border": "1px solid #e6e6e6",
         "text-align": "center",
-        "line-height": "24px",
+        "border-radius" : "0px",
         "cursor": "pointer",
         "float": "left",
         "margin-right": "10px",
@@ -121,6 +130,7 @@
         "border": "1px solid #e6e6e6",
         "text-align": "center",
         "line-height": "24px",
+        "border-radius" : "0px",
         "cursor": "pointer",
         "float": "left",
         "margin-right": "10px",
@@ -130,6 +140,7 @@
     "pageJumper" : {
         "float" : "left",
         "height" : "20px",
+        "border-radius" : "0px",
         "line-height" : "20px",
         "text-align" : "center",
         "width" : "20px",

+ 163 - 0
o2web/source/o2_core/o2/widget/$Paging/red_round/css.wcss

@@ -0,0 +1,163 @@
+{
+    "pagingBarWraper" : {
+        "height" : "60px",
+        "overflow" : "hidden"
+    },
+    "pagingBar" : {
+        "float": "left",
+        "margin-left": "10px",
+        "margin-top": "18px",
+        "height": "24px",
+        "color": "#777777"
+    },
+    "firstPage" : {
+        "height": "24px",
+        "width": "80px",
+        "border": "1px solid #e6e6e6",
+        "border-radius" : "12px",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "margin-right": "10px",
+        "color" : "inherit",
+        "background-color": "#ffffff",
+        "float": "left"
+    },
+    "firstPage_over" : {
+        "color" : "#ffffff",
+        "background-color": "#cc3d3d"
+    },
+    "lastPage" : {
+        "height": "24px",
+        "width": "80px",
+        "border": "1px solid #e6e6e6",
+        "border-radius" : "12px",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "color" : "inherit",
+        "background-color": "#ffffff",
+        "float": "left"
+    },
+    "lastPage_over" : {
+        "color" : "#ffffff",
+        "background-color": "#cc3d3d"
+    },
+    "prePage" : {
+        "width": "24px",
+        "height": "24px",
+        "border-radius" : "12px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "background-color": "#ffffff",
+        "float": "left",
+        "margin-right": "10px",
+        "background": "url(/o2_core/o2/widget/$Paging/default/icon/left.png) no-repeat center center"
+    },
+    "prePage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "nextPage" : {
+        "width": "24px",
+        "height": "24px",
+        "border-radius" : "12px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "background-color": "#ffffff",
+        "float": "left",
+        "margin-right": "10px",
+        "background": "url(/o2_core/o2/widget/$Paging/default/icon/right.png) no-repeat center center"
+    },
+    "nextPage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "pageTurnContainer" : {
+        "float" : "left"
+    },
+    "pageItem" : {
+        "padding-left": "5px",
+        "padding-right" : "5px",
+        "height": "24px",
+        "border-radius" : "12px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#ffffff"
+    },
+    "pageItem_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "preBatchPage" : {
+        "padding-left": "5px",
+        "padding-right" : "5px",
+        "height": "24px",
+        "line-height": "normal",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "border-radius" : "12px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#ffffff"
+    },
+    "preBatchPage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "nextBatchPage" : {
+        "padding-left": "5px",
+        "padding-right" : "5px",
+        "height": "24px",
+        "line-height": "normal",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "border-radius" : "12px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#ffffff"
+    },
+    "nextBatchPage_over" : {
+        "background-color": "#f1f1f1"
+    },
+    "currentPage" : {
+        "width": "24px",
+        "height": "24px",
+        "border": "1px solid #e6e6e6",
+        "text-align": "center",
+        "line-height": "24px",
+        "border-radius" : "12px",
+        "cursor": "pointer",
+        "float": "left",
+        "margin-right": "10px",
+        "background-color": "#cc3d3d",
+        "color": "#ffffff"
+    },
+    "pageJumper" : {
+        "float" : "left",
+        "height" : "20px",
+        "border-radius" : "4px",
+        "line-height" : "20px",
+        "text-align" : "center",
+        "width" : "20px",
+        "margin-left" : "10px",
+        "border" : "1px solid #ddd"
+    },
+    "pageJumper_over" : {
+        "border" : "1px solid #cc3d3d"
+    },
+    "pageJumperText" : {
+        "float" : "left",
+        "height" : "20px",
+        "padding" : "2px 5px",
+        "text-align" : "center",
+        "line-height" : "20px",
+        "margin-right" : "5px"
+    }
+}

BIN
o2web/source/o2_core/o2/widget/$Paging/red_round/icon/left.png


BIN
o2web/source/o2_core/o2/widget/$Paging/red_round/icon/right.png


+ 7 - 0
o2web/source/x_component_cms_FormDesigner/Module/Radio/radio.html

@@ -20,6 +20,13 @@
 		    	<input class="editTableRadio" onclick="if (this.checked){ $('text{$.pid}selectEditItemScript').setStyle('display', 'block'); $('text{$.pid}selectEditItemValues').setStyle('display', 'none')}" name="itemType" text{($.itemType=='script')?'checked':''} type="radio" value="script"/>脚本
 		    </td>
 		  </tr>
+			<tr>
+				<td class="editTableTitle">是否只读:</td>
+				<td class="editTableValue">
+					<input type="radio" name="isReadonly" value="true" text{($.isReadonly)?'checked':''}/>是
+					<input type="radio" name="isReadonly" value="false" text{(!$.isReadonly)?'checked':''}/>否
+				</td>
+			</tr>
 		</table>
 		
 		<div id="text{$.pid}selectEditItemValues" style="display: text{($.itemType=='values')?'block':'none'}" class="MWFArraylist" name="itemValues" title="可选值"></div>

+ 7 - 0
o2web/source/x_component_query_ViewDesigner/$View/paging.html

@@ -16,6 +16,13 @@
 
 		</table>
 		<table width="100%" border="0" cellpadding="5" cellspacing="0" class="editTable">
+			<tr>
+				<td class="editTableTitleNoWidth">按钮样式:</td>
+				<td class="editTableValue">
+					<input class="editTableRadio" name="buttonStyle" text{($.buttonStyle==='round')?'checked':''} type="radio" value="round"/>圆角
+					<input class="editTableRadio" name="buttonStyle" text{($.buttonStyle==='rect')?'checked':''} type="radio" value="rect"/>方角
+				</td>
+			</tr>
 			<tr>
 				<td class="editTableTitleNoWidth">显示数字分页:</td>
 				<td class="editTableValue">

+ 1 - 1
o2web/source/x_component_query_ViewDesigner/$View/paging.json

@@ -3,7 +3,7 @@
   "name": "",
   "type": "Paging",
   "description": "",
-  "style": "default",
+  "style": "blue_round",
   "visiblePages" : 9,
   "prePageText" : "",
   "nextPageText" : "",

+ 3 - 1
o2web/source/x_component_query_ViewDesigner/$View/skin/styles_blue-flat.json

@@ -100,6 +100,8 @@
     }
   },
   "paging" : {
-    "style" : "default"
+    "style" : "blue_round",
+    "style_rect" : "default",
+    "style_round" : "blue_round"
   }
 }

+ 3 - 1
o2web/source/x_component_query_ViewDesigner/$View/skin/styles_blue-simple.json

@@ -95,6 +95,8 @@
     }
   },
   "paging" : {
-    "style" : "default"
+    "style" : "blue_round",
+    "style_rect" : "default",
+    "style_round" : "blue_round"
   }
 }

+ 3 - 1
o2web/source/x_component_query_ViewDesigner/$View/skin/styles_cmcc.json

@@ -96,6 +96,8 @@
     }
   },
   "paging" : {
-    "style" : "default"
+    "style" : "blue_round",
+    "style_rect" : "default",
+    "style_round" : "blue_round"
   }
 }

+ 3 - 1
o2web/source/x_component_query_ViewDesigner/$View/skin/styles_default.json

@@ -95,6 +95,8 @@
     }
   },
   "paging" : {
-    "style" : "default"
+    "style" : "blue_round",
+    "style_rect" : "default",
+    "style_round" : "blue_round"
   }
 }

+ 3 - 1
o2web/source/x_component_query_ViewDesigner/$View/skin/styles_official.json

@@ -95,6 +95,8 @@
     }
   },
   "paging" : {
-    "style" : "red"
+    "style" : "red",
+    "style_rect" : "red",
+    "style_round" : "red_round"
   }
 }

+ 3 - 1
o2web/source/x_component_query_ViewDesigner/$View/skin/styles_red-simple.json

@@ -95,6 +95,8 @@
     }
   },
   "paging" : {
-    "style" : "red"
+    "style" : "red_round",
+    "style_rect" : "red",
+    "style_round" : "red_round"
   }
 }

+ 15 - 2
o2web/source/x_component_query_ViewDesigner/View.js

@@ -1969,11 +1969,17 @@ MWF.xApplication.query.ViewDesigner.View.Paging = new Class({
         });
     },
     setTemplateStyles: function(styles){
-        this.json.style = styles.style;
+        if( this.json.buttonStyle === "rect" ){
+            this.json.style = styles.style_rect;
+        }else if( this.json.buttonStyle === "round" ){
+            this.json.style = styles.style_round;
+        }else{
+            this.json.style = styles.style;
+        }
         this.json.forceStyles = styles.forceStyles || "";
     },
     clearTemplateStyles: function(styles){
-        this.json.style = "default";
+        this.json.style = "blue_round";
         this.json.forceStyles = "";
     },
     setAllStyles: function(){
@@ -2100,6 +2106,13 @@ MWF.xApplication.query.ViewDesigner.View.Paging = new Class({
             "firstPageText","lastPageText","prePageText","nextPageText",
             "pagingStyles"].contains(name)){
             this._refreshPaging();
+        }else if( name === "buttonStyle" ){
+            if( this.json.buttonStyle === "rect" ){
+                this.json.style = this.view.templateStyles.paging.style_rect;
+            }else{
+                this.json.style = this.view.templateStyles.paging.style_round;
+            }
+            this._resetPaging();
         }
     }