├── .gitignore ├── Dockerfile ├── LICENSE ├── README.md ├── package.json ├── src ├── images │ ├── bg_01.jpg │ ├── bg_02.jpg │ ├── bg_03.jpg │ ├── bg_04.jpg │ ├── bg_05.jpg │ ├── logo_100.png │ ├── os_windows.png │ ├── qq_32.png │ ├── qzone_32.png │ ├── sexy_girl.jpg │ └── weibo_32.png ├── index.html ├── js │ ├── echartsdemo.js │ ├── echartsdemo.min.js │ ├── index.js │ ├── index.min.js │ ├── menulist.js │ ├── menulist.min.js │ ├── rolelist.js │ └── rolelist.min.js ├── json │ ├── allmenu.json │ ├── desktopmenu.json │ ├── menulist.json │ ├── resfailed.json │ ├── resok.json │ └── rolelist.json ├── lib │ ├── animate │ │ └── animate.min.css │ ├── echarts │ │ ├── echarts.js │ │ └── echartsTheme.js │ ├── font-awesome-4.7.0 │ │ ├── HELP-US-OUT.txt │ │ ├── css │ │ │ ├── font-awesome.css │ │ │ └── font-awesome.min.css │ │ ├── fonts │ │ │ ├── FontAwesome.otf │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.svg │ │ │ ├── fontawesome-webfont.ttf │ │ │ ├── fontawesome-webfont.woff │ │ │ └── fontawesome-webfont.woff2 │ │ ├── less │ │ │ ├── animated.less │ │ │ ├── bordered-pulled.less │ │ │ ├── core.less │ │ │ ├── fixed-width.less │ │ │ ├── font-awesome.less │ │ │ ├── icons.less │ │ │ ├── larger.less │ │ │ ├── list.less │ │ │ ├── mixins.less │ │ │ ├── path.less │ │ │ ├── rotated-flipped.less │ │ │ ├── screen-reader.less │ │ │ ├── stacked.less │ │ │ └── variables.less │ │ └── scss │ │ │ ├── _animated.scss │ │ │ ├── _bordered-pulled.scss │ │ │ ├── _core.scss │ │ │ ├── _fixed-width.scss │ │ │ ├── _icons.scss │ │ │ ├── _larger.scss │ │ │ ├── _list.scss │ │ │ ├── _mixins.scss │ │ │ ├── _path.scss │ │ │ ├── _rotated-flipped.scss │ │ │ ├── _screen-reader.scss │ │ │ ├── _stacked.scss │ │ │ ├── _variables.scss │ │ │ └── font-awesome.scss │ ├── layui │ │ ├── css │ │ │ ├── layui.css │ │ │ ├── layui.mobile.css │ │ │ └── modules │ │ │ │ ├── code.css │ │ │ │ ├── laydate │ │ │ │ └── default │ │ │ │ │ ├── font.css │ │ │ │ │ └── laydate.css │ │ │ │ └── layer │ │ │ │ └── default │ │ │ │ ├── icon-ext.png │ │ │ │ ├── icon.png │ │ │ │ ├── layer.css │ │ │ │ ├── loading-0.gif │ │ │ │ ├── loading-1.gif │ │ │ │ └── loading-2.gif │ │ ├── font │ │ │ ├── iconfont.eot │ │ │ ├── iconfont.svg │ │ │ ├── iconfont.ttf │ │ │ └── iconfont.woff │ │ ├── images │ │ │ └── face │ │ │ │ ├── 0.gif │ │ │ │ ├── 1.gif │ │ │ │ ├── 10.gif │ │ │ │ ├── 11.gif │ │ │ │ ├── 12.gif │ │ │ │ ├── 13.gif │ │ │ │ ├── 14.gif │ │ │ │ ├── 15.gif │ │ │ │ ├── 16.gif │ │ │ │ ├── 17.gif │ │ │ │ ├── 18.gif │ │ │ │ ├── 19.gif │ │ │ │ ├── 2.gif │ │ │ │ ├── 20.gif │ │ │ │ ├── 21.gif │ │ │ │ ├── 22.gif │ │ │ │ ├── 23.gif │ │ │ │ ├── 24.gif │ │ │ │ ├── 25.gif │ │ │ │ ├── 26.gif │ │ │ │ ├── 27.gif │ │ │ │ ├── 28.gif │ │ │ │ ├── 29.gif │ │ │ │ ├── 3.gif │ │ │ │ ├── 30.gif │ │ │ │ ├── 31.gif │ │ │ │ ├── 32.gif │ │ │ │ ├── 33.gif │ │ │ │ ├── 34.gif │ │ │ │ ├── 35.gif │ │ │ │ ├── 36.gif │ │ │ │ ├── 37.gif │ │ │ │ ├── 38.gif │ │ │ │ ├── 39.gif │ │ │ │ ├── 4.gif │ │ │ │ ├── 40.gif │ │ │ │ ├── 41.gif │ │ │ │ ├── 42.gif │ │ │ │ ├── 43.gif │ │ │ │ ├── 44.gif │ │ │ │ ├── 45.gif │ │ │ │ ├── 46.gif │ │ │ │ ├── 47.gif │ │ │ │ ├── 48.gif │ │ │ │ ├── 49.gif │ │ │ │ ├── 5.gif │ │ │ │ ├── 50.gif │ │ │ │ ├── 51.gif │ │ │ │ ├── 52.gif │ │ │ │ ├── 53.gif │ │ │ │ ├── 54.gif │ │ │ │ ├── 55.gif │ │ │ │ ├── 56.gif │ │ │ │ ├── 57.gif │ │ │ │ ├── 58.gif │ │ │ │ ├── 59.gif │ │ │ │ ├── 6.gif │ │ │ │ ├── 60.gif │ │ │ │ ├── 61.gif │ │ │ │ ├── 62.gif │ │ │ │ ├── 63.gif │ │ │ │ ├── 64.gif │ │ │ │ ├── 65.gif │ │ │ │ ├── 66.gif │ │ │ │ ├── 67.gif │ │ │ │ ├── 68.gif │ │ │ │ ├── 69.gif │ │ │ │ ├── 7.gif │ │ │ │ ├── 70.gif │ │ │ │ ├── 71.gif │ │ │ │ ├── 8.gif │ │ │ │ └── 9.gif │ │ ├── lay │ │ │ ├── all-mobile.js │ │ │ ├── all.js │ │ │ └── modules │ │ │ │ ├── carousel.js │ │ │ │ ├── code.js │ │ │ │ ├── element.js │ │ │ │ ├── flow.js │ │ │ │ ├── form.js │ │ │ │ ├── jquery.js │ │ │ │ ├── laydate.js │ │ │ │ ├── layedit.js │ │ │ │ ├── layer.js │ │ │ │ ├── laypage.js │ │ │ │ ├── laytpl.js │ │ │ │ ├── mobile.js │ │ │ │ ├── mobile │ │ │ │ ├── layer-mobile.js │ │ │ │ ├── layim-mobile-open.js │ │ │ │ ├── upload-mobile.js │ │ │ │ └── zepto.js │ │ │ │ ├── table.js │ │ │ │ ├── tree.js │ │ │ │ ├── upload.js │ │ │ │ └── util.js │ │ └── layui.js │ └── winui │ │ ├── audio │ │ ├── 236.mp3 │ │ ├── 236.wav │ │ ├── 5885.mp3 │ │ └── 5885.wav │ │ ├── css │ │ ├── helper.css │ │ ├── lockscreen.css │ │ ├── theme.css │ │ └── winui.css │ │ ├── html │ │ ├── helper │ │ │ └── settings.html │ │ ├── setting │ │ │ └── theme.html │ │ └── system │ │ │ └── lockscreen.html │ │ ├── images │ │ └── window_ico.png │ │ ├── js │ │ ├── theme.js │ │ ├── theme.min.js │ │ ├── winui.desktop.js │ │ ├── winui.desktop.min.js │ │ ├── winui.helper.js │ │ ├── winui.helper.min.js │ │ ├── winui.start.js │ │ ├── winui.start.min.js │ │ ├── winui.window.js │ │ └── winui.window.min.js │ │ ├── json │ │ ├── allmenu.json │ │ └── desktopmenu.json │ │ ├── winui.js │ │ └── winui.min.js └── views │ ├── demo │ └── introduce.html │ ├── echarts │ └── demo.html │ ├── error │ ├── 404.html │ └── 500.html │ ├── menu │ ├── add.html │ ├── edit.html │ ├── list.html │ ├── list_iframe.html │ └── setting.html │ └── role │ ├── edit.html │ └── list.html └── src里面的内容复制到你的网站根目录即可.txt /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | package-lock.json 7 | 8 | # User-specific files 9 | *.suo 10 | *.user 11 | *.userosscache 12 | *.sln.docstates 13 | 14 | # User-specific files (MonoDevelop/Xamarin Studio) 15 | *.userprefs 16 | 17 | # Build results 18 | [Dd]ebug/ 19 | [Dd]ebugPublic/ 20 | [Rr]elease/ 21 | [Rr]eleases/ 22 | x64/ 23 | x86/ 24 | bld/ 25 | [Bb]in/ 26 | [Oo]bj/ 27 | [Ll]og/ 28 | 29 | # Visual Studio 2015 cache/options directory 30 | .vs/ 31 | # Uncomment if you have tasks that create the project's static files in wwwroot 32 | #wwwroot/ 33 | 34 | # MSTest test Results 35 | [Tt]est[Rr]esult*/ 36 | [Bb]uild[Ll]og.* 37 | 38 | # NUNIT 39 | *.VisualState.xml 40 | TestResult.xml 41 | 42 | # Build Results of an ATL Project 43 | [Dd]ebugPS/ 44 | [Rr]eleasePS/ 45 | dlldata.c 46 | 47 | # Benchmark Results 48 | BenchmarkDotNet.Artifacts/ 49 | 50 | # .NET Core 51 | project.lock.json 52 | project.fragment.lock.json 53 | artifacts/ 54 | **/Properties/launchSettings.json 55 | 56 | *_i.c 57 | *_p.c 58 | *_i.h 59 | *.ilk 60 | *.meta 61 | *.obj 62 | *.pch 63 | *.pdb 64 | *.pgc 65 | *.pgd 66 | *.rsp 67 | *.sbr 68 | *.tlb 69 | *.tli 70 | *.tlh 71 | *.tmp 72 | *.tmp_proj 73 | *.log 74 | *.vspscc 75 | *.vssscc 76 | .builds 77 | *.pidb 78 | *.svclog 79 | *.scc 80 | 81 | # Chutzpah Test files 82 | _Chutzpah* 83 | 84 | # Visual C++ cache files 85 | ipch/ 86 | *.aps 87 | *.ncb 88 | *.opendb 89 | *.opensdf 90 | *.sdf 91 | *.cachefile 92 | *.VC.db 93 | *.VC.VC.opendb 94 | 95 | # Visual Studio profiler 96 | *.psess 97 | *.vsp 98 | *.vspx 99 | *.sap 100 | 101 | # Visual Studio Trace Files 102 | *.e2e 103 | 104 | # TFS 2012 Local Workspace 105 | $tf/ 106 | 107 | # Guidance Automation Toolkit 108 | *.gpState 109 | 110 | # ReSharper is a .NET coding add-in 111 | _ReSharper*/ 112 | *.[Rr]e[Ss]harper 113 | *.DotSettings.user 114 | 115 | # JustCode is a .NET coding add-in 116 | .JustCode 117 | 118 | # TeamCity is a build add-in 119 | _TeamCity* 120 | 121 | # DotCover is a Code Coverage Tool 122 | *.dotCover 123 | 124 | # AxoCover is a Code Coverage Tool 125 | .axoCover/* 126 | !.axoCover/settings.json 127 | 128 | # Visual Studio code coverage results 129 | *.coverage 130 | *.coveragexml 131 | 132 | # NCrunch 133 | _NCrunch_* 134 | .*crunch*.local.xml 135 | nCrunchTemp_* 136 | 137 | # MightyMoose 138 | *.mm.* 139 | AutoTest.Net/ 140 | 141 | # Web workbench (sass) 142 | .sass-cache/ 143 | 144 | # Installshield output folder 145 | [Ee]xpress/ 146 | 147 | # DocProject is a documentation generator add-in 148 | DocProject/buildhelp/ 149 | DocProject/Help/*.HxT 150 | DocProject/Help/*.HxC 151 | DocProject/Help/*.hhc 152 | DocProject/Help/*.hhk 153 | DocProject/Help/*.hhp 154 | DocProject/Help/Html2 155 | DocProject/Help/html 156 | 157 | # Click-Once directory 158 | publish/ 159 | 160 | # Publish Web Output 161 | *.[Pp]ublish.xml 162 | *.azurePubxml 163 | # Note: Comment the next line if you want to checkin your web deploy settings, 164 | # but database connection strings (with potential passwords) will be unencrypted 165 | *.pubxml 166 | *.publishproj 167 | 168 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 169 | # checkin your Azure Web App publish settings, but sensitive information contained 170 | # in these scripts will be unencrypted 171 | PublishScripts/ 172 | 173 | # NuGet Packages 174 | *.nupkg 175 | # The packages folder can be ignored because of Package Restore 176 | **/[Pp]ackages/* 177 | # except build/, which is used as an MSBuild target. 178 | !**/[Pp]ackages/build/ 179 | # Uncomment if necessary however generally it will be regenerated when needed 180 | #!**/[Pp]ackages/repositories.config 181 | # NuGet v3's project.json files produces more ignorable files 182 | *.nuget.props 183 | *.nuget.targets 184 | 185 | # Microsoft Azure Build Output 186 | csx/ 187 | *.build.csdef 188 | 189 | # Microsoft Azure Emulator 190 | ecf/ 191 | rcf/ 192 | 193 | # Windows Store app package directories and files 194 | AppPackages/ 195 | BundleArtifacts/ 196 | Package.StoreAssociation.xml 197 | _pkginfo.txt 198 | *.appx 199 | 200 | # Visual Studio cache files 201 | # files ending in .cache can be ignored 202 | *.[Cc]ache 203 | # but keep track of directories ending in .cache 204 | !*.[Cc]ache/ 205 | 206 | # Others 207 | ClientBin/ 208 | ~$* 209 | *~ 210 | *.dbmdl 211 | *.dbproj.schemaview 212 | *.jfm 213 | *.pfx 214 | *.publishsettings 215 | orleans.codegen.cs 216 | 217 | # Since there are multiple workflows, uncomment next line to ignore bower_components 218 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 219 | #bower_components/ 220 | 221 | # RIA/Silverlight projects 222 | Generated_Code/ 223 | 224 | # Backup & report files from converting an old project file 225 | # to a newer Visual Studio version. Backup files are not needed, 226 | # because we have git ;-) 227 | _UpgradeReport_Files/ 228 | Backup*/ 229 | UpgradeLog*.XML 230 | UpgradeLog*.htm 231 | 232 | # SQL Server files 233 | *.mdf 234 | *.ldf 235 | *.ndf 236 | 237 | # Business Intelligence projects 238 | *.rdl.data 239 | *.bim.layout 240 | *.bim_*.settings 241 | 242 | # Microsoft Fakes 243 | FakesAssemblies/ 244 | 245 | # GhostDoc plugin setting file 246 | *.GhostDoc.xml 247 | 248 | # Node.js Tools for Visual Studio 249 | .ntvs_analysis.dat 250 | node_modules/ 251 | 252 | # Typescript v1 declaration files 253 | typings/ 254 | 255 | # Visual Studio 6 build log 256 | *.plg 257 | 258 | # Visual Studio 6 workspace options file 259 | *.opt 260 | 261 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 262 | *.vbw 263 | 264 | # Visual Studio LightSwitch build output 265 | **/*.HTMLClient/GeneratedArtifacts 266 | **/*.DesktopClient/GeneratedArtifacts 267 | **/*.DesktopClient/ModelManifest.xml 268 | **/*.Server/GeneratedArtifacts 269 | **/*.Server/ModelManifest.xml 270 | _Pvt_Extensions 271 | 272 | # Paket dependency manager 273 | .paket/paket.exe 274 | paket-files/ 275 | 276 | # FAKE - F# Make 277 | .fake/ 278 | 279 | # JetBrains Rider 280 | .idea/ 281 | *.sln.iml 282 | 283 | # CodeRush 284 | .cr/ 285 | 286 | # Python Tools for Visual Studio (PTVS) 287 | __pycache__/ 288 | *.pyc 289 | 290 | # Cake - Uncomment if you are using it 291 | # tools/** 292 | # !tools/packages.config 293 | 294 | # Tabs Studio 295 | *.tss 296 | 297 | # Telerik's JustMock configuration file 298 | *.jmconfig 299 | 300 | # BizTalk build output 301 | *.btp.cs 302 | *.btm.cs 303 | *.odx.cs 304 | *.xsd.cs 305 | 306 | # OpenCover UI analysis results 307 | OpenCover/ 308 | 309 | #vs 310 | .vs -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM nginx 2 | COPY src/ /usr/share/nginx/html/ 3 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Leo 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 作者博客:[点击前往](https://www.leo96.com) 3 | 4 | 预览效果:[点击前往](https://leo0216.github.io/winadmin/src/) 5 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "winadmin", 3 | "version": "1.0.0", 4 | "description": "1, npm i 2, npm run dev", 5 | "scripts": { 6 | "dev": "http-server ./src -p 8090 -o" 7 | }, 8 | "author": "rocching", 9 | "devDependencies": { 10 | "http-server": "^0.9.0" 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/images/bg_01.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/bg_01.jpg -------------------------------------------------------------------------------- /src/images/bg_02.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/bg_02.jpg -------------------------------------------------------------------------------- /src/images/bg_03.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/bg_03.jpg -------------------------------------------------------------------------------- /src/images/bg_04.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/bg_04.jpg -------------------------------------------------------------------------------- /src/images/bg_05.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/bg_05.jpg -------------------------------------------------------------------------------- /src/images/logo_100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/logo_100.png -------------------------------------------------------------------------------- /src/images/os_windows.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/os_windows.png -------------------------------------------------------------------------------- /src/images/qq_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/qq_32.png -------------------------------------------------------------------------------- /src/images/qzone_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/qzone_32.png -------------------------------------------------------------------------------- /src/images/sexy_girl.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/sexy_girl.jpg -------------------------------------------------------------------------------- /src/images/weibo_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/images/weibo_32.png -------------------------------------------------------------------------------- /src/js/echartsdemo.js: -------------------------------------------------------------------------------- 1 | layui.config({ 2 | base: '../../lib/' //指定 lib 路径 3 | , version: '1.0.0-beta' 4 | }).extend({ 5 | echarts: 'echarts/echarts', 6 | echartsTheme: 'echarts/echartsTheme', 7 | winui: 'winui/winui' 8 | }).define(['winui', 'echarts'], function (exports) { 9 | winui.renderColor(); 10 | 11 | var $ = layui.jquery, 12 | echartDom = [$('#bar')[0], $('#line')[0], $('#area')[0], $('#pie')[0]], 13 | echartInstance = []; 14 | 15 | var echartsOption = [{ 16 | title: { 17 | text: 'ECharts入门示例', 18 | textStyle: { 19 | fontSize: 14 20 | } 21 | }, 22 | tooltip: {}, 23 | legend: { 24 | data: ['销量'] 25 | }, 26 | xAxis: { 27 | data: ["衬衫", "羊毛衫", "雪纺衫", "裤子", "高跟鞋", "袜子"] 28 | }, 29 | yAxis: {}, 30 | series: [{ 31 | name: '销量', 32 | type: 'bar', 33 | data: [5, 20, 36, 10, 10, 20] 34 | }] 35 | }, { 36 | title: { 37 | text: 'ECharts入门示例', 38 | x: 'center', 39 | textStyle: { 40 | fontSize: 14 41 | } 42 | }, 43 | tooltip: {}, 44 | legend: { 45 | orient: 'vertical', 46 | left: 'left', 47 | data: ['销量'] 48 | }, 49 | xAxis: { 50 | data: ["衬衫", "羊毛衫", "雪纺衫", "裤子", "高跟鞋", "袜子"] 51 | }, 52 | yAxis: {}, 53 | series: [{ 54 | name: '销量', 55 | type: 'line', 56 | data: [5, 20, 36, 10, 10, 20] 57 | }] 58 | }, { 59 | title: { 60 | text: '今日流量趋势', 61 | x: 'center', 62 | textStyle: { 63 | fontSize: 14 64 | } 65 | }, 66 | tooltip: { 67 | trigger: 'axis' 68 | }, 69 | legend: { 70 | data: ['', ''] 71 | }, 72 | xAxis: [{ 73 | type: 'category', 74 | boundaryGap: false, 75 | data: ['06:00', '06:30', '07:00', '07:30', '08:00', '08:30', '09:00', '09:30', '10:00', '11:30', '12:00', '12:30', '13:00', '13:30', '14:00', '14:30', '15:00', '15:30', '16:00', '16:30', '17:00', '17:30', '18:00', '18:30', '19:00', '19:30', '20:00', '20:30', '21:00', '21:30', '22:00', '22:30', '23:00', '23:30'] 76 | }], 77 | yAxis: [{ 78 | type: 'value' 79 | }], 80 | series: [{ 81 | name: 'PV', 82 | type: 'line', 83 | smooth: true, 84 | itemStyle: { normal: { areaStyle: { type: 'default' } } }, 85 | data: [111, 222, 333, 444, 555, 666, 3333, 33333, 55555, 66666, 33333, 3333, 6666, 11888, 26666, 38888, 56666, 42222, 39999, 28888, 17777, 9666, 6555, 5555, 3333, 2222, 3111, 6999, 5888, 2777, 1666, 999, 888, 777] 86 | }, { 87 | name: 'UV', 88 | type: 'line', 89 | smooth: true, 90 | itemStyle: { normal: { areaStyle: { type: 'default' } } }, 91 | data: [11, 22, 33, 44, 55, 66, 333, 3333, 5555, 12666, 3333, 333, 666, 1188, 2666, 3888, 6666, 4222, 3999, 2888, 1777, 966, 655, 555, 333, 222, 311, 699, 588, 277, 166, 99, 88, 77] 92 | }] 93 | }, { 94 | title: { 95 | text: '用户访问来源', 96 | x: 'center' 97 | }, 98 | tooltip: { 99 | trigger: 'item', 100 | formatter: "{a}
{b} : {c} ({d}%)" 101 | }, 102 | legend: { 103 | orient: 'vertical', 104 | left: 'left', 105 | data: ['直接访问', '邮件营销', '联盟广告', '视频广告', '搜索引擎'] 106 | }, 107 | series: [ 108 | { 109 | name: '访问来源', 110 | type: 'pie', 111 | radius: '55%', 112 | center: ['50%', '60%'], 113 | data: [ 114 | { value: 335, name: '直接访问' }, 115 | { value: 310, name: '邮件营销' }, 116 | { value: 234, name: '联盟广告' }, 117 | { value: 135, name: '视频广告' }, 118 | { value: 1548, name: '搜索引擎' } 119 | ], 120 | itemStyle: { 121 | emphasis: { 122 | shadowBlur: 10, 123 | shadowOffsetX: 0, 124 | shadowColor: 'rgba(0, 0, 0, 0.5)' 125 | } 126 | } 127 | } 128 | ] 129 | }]; 130 | 131 | loadECharts(0); 132 | 133 | //监听Winui的左右Tab切换 134 | winui.tab.on('tabchange(winuitab)', function (data) { 135 | loadECharts(data.index); 136 | }); 137 | 138 | 139 | function loadECharts(i) { 140 | echartInstance[i] = echarts.init(echartDom[i], layui.echartsTheme); 141 | echartInstance[i].clear(); 142 | echartInstance[i].resize(); 143 | echartInstance[i].setOption(echartsOption[i]); 144 | window.onresize = echartInstance[i].resize; 145 | } 146 | 147 | exports('echartsdemo', {}); 148 | }); 149 | -------------------------------------------------------------------------------- /src/js/echartsdemo.min.js: -------------------------------------------------------------------------------- 1 | layui.config({base:"../../lib/",version:"1.0.0-beta"}).extend({echarts:"echarts/echarts",echartsTheme:"echarts/echartsTheme",winui:"winui/winui"}).define(["winui","echarts"],function(n){function r(n){t[n]=echarts.init(u[n],layui.echartsTheme);t[n].clear();t[n].resize();t[n].setOption(f[n]);window.onresize=t[n].resize}winui.renderColor();var i=layui.jquery,u=[i("#bar")[0],i("#line")[0],i("#area")[0],i("#pie")[0]],t=[],f=[{title:{text:"ECharts入门示例",textStyle:{fontSize:14}},tooltip:{},legend:{data:["销量"]},xAxis:{data:["衬衫","羊毛衫","雪纺衫","裤子","高跟鞋","袜子"]},yAxis:{},series:[{name:"销量",type:"bar",data:[5,20,36,10,10,20]}]},{title:{text:"ECharts入门示例",x:"center",textStyle:{fontSize:14}},tooltip:{},legend:{orient:"vertical",left:"left",data:["销量"]},xAxis:{data:["衬衫","羊毛衫","雪纺衫","裤子","高跟鞋","袜子"]},yAxis:{},series:[{name:"销量",type:"line",data:[5,20,36,10,10,20]}]},{title:{text:"今日流量趋势",x:"center",textStyle:{fontSize:14}},tooltip:{trigger:"axis"},legend:{data:["",""]},xAxis:[{type:"category",boundaryGap:!1,data:["06:00","06:30","07:00","07:30","08:00","08:30","09:00","09:30","10:00","11:30","12:00","12:30","13:00","13:30","14:00","14:30","15:00","15:30","16:00","16:30","17:00","17:30","18:00","18:30","19:00","19:30","20:00","20:30","21:00","21:30","22:00","22:30","23:00","23:30"]}],yAxis:[{type:"value"}],series:[{name:"PV",type:"line",smooth:!0,itemStyle:{normal:{areaStyle:{type:"default"}}},data:[111,222,333,444,555,666,3333,33333,55555,66666,33333,3333,6666,11888,26666,38888,56666,42222,39999,28888,17777,9666,6555,5555,3333,2222,3111,6999,5888,2777,1666,999,888,777]},{name:"UV",type:"line",smooth:!0,itemStyle:{normal:{areaStyle:{type:"default"}}},data:[11,22,33,44,55,66,333,3333,5555,12666,3333,333,666,1188,2666,3888,6666,4222,3999,2888,1777,966,655,555,333,222,311,699,588,277,166,99,88,77]}]},{title:{text:"用户访问来源",x:"center"},tooltip:{trigger:"item",formatter:"{a}
{b} : {c} ({d}%)"},legend:{orient:"vertical",left:"left",data:["直接访问","邮件营销","联盟广告","视频广告","搜索引擎"]},series:[{name:"访问来源",type:"pie",radius:"55%",center:["50%","60%"],data:[{value:335,name:"直接访问"},{value:310,name:"邮件营销"},{value:234,name:"联盟广告"},{value:135,name:"视频广告"},{value:1548,name:"搜索引擎"}],itemStyle:{emphasis:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}}}]}];r(0);winui.tab.on("tabchange(winuitab)",function(n){r(n.index)});n("echartsdemo",{})}); -------------------------------------------------------------------------------- /src/js/index.min.js: -------------------------------------------------------------------------------- 1 | layui.config({base:"./lib/winui/",version:"1.0.0-beta"}).extend({window:"js/winui.window",desktop:"js/winui.desktop",start:"js/winui.start",helper:"js/winui.helper"}).define(["window","desktop","start","helper"],function(n){function i(n){var i=t(n),u=i.attr("win-url"),f=i.attr("win-title"),e=i.attr("win-id"),o=parseInt(i.attr("win-opentype")),s=parseInt(i.attr("win-maxopen"))||-1,r;if(u=="theme"){winui.window.openTheme();return}if(!u||!f||!e){winui.window.msg("菜单配置错误(菜单链接、标题、id缺一不可)");return}o===1?t.ajax({type:"get",url:u,async:!1,success:function(n){r=n},error:function(n){var i="";switch(n.status){case 404:i="404.html";break;case 500:i="500.html";break;default:r="打开窗口失败"}t.ajax({type:"get",url:"views/error/"+i,async:!1,success:function(n){r=n},error:function(){layer.close(load)}})}}):r=u;winui.window.config({anim:0,miniAnim:0,maxOpen:-1}).open({id:e,type:o,title:f,content:r,maxOpen:s})}var t=layui.jquery;t(function(){winui.window.msg("Welcome To WinAdmin",{time:4500,offset:"40px",btn:["点击进入全屏"],btnAlign:"c",yes:function(n){winui.fullScreen(document.documentElement);layer.close(n)}});winui.config({settings:layui.data("winui").settings||{color:32,taskbarMode:"bottom",startSize:"sm",bgSrc:"images/bg_01.jpg",lockBgSrc:"images/bg_04.jpg"},desktop:{options:{},done:function(n){n.ondblclick(function(n,t){i(t)});n.contextmenu({item:["打开","删除","右键菜单可自定义"],item1:function(n,t){i(t)},item2:function(n,i,r){winui.window.msg("删除回调");t(i).remove();r.reLocaApp()},item3:function(){winui.window.msg("自定义回调")}})}},menu:{options:{url:"json/allmenu.json",method:"get",data:{nihaoa:""}},done:function(n){n.onclick(function(n){i(n)});n.contextmenu({item:[{icon:"fa-cog",text:"设置"},{icon:"fa-close",text:"关闭"},{icon:"fa-qq",text:"右键菜单可自定义"}],item1:function(n,t){console.log(n);console.log(t)},item2:function(){},item3:function(){winui.window.msg("自定义回调")}})}}}).init({audioPlay:!1,renderBg:!0},function(){})});t(".winui-tile").on("click",function(){i(this)});t(".winui-start-item.winui-start-individuation").on("click",function(){winui.window.openTheme()});t(".logout").on("click",function(){winui.hideStartMenu();winui.window.confirm("确认注销吗?",{icon:3,title:"提示"},function(n){winui.window.msg("执行注销操作,返回登录界面");layer.close(n)})});window.localStorage.getItem("lockscreen")=="true"&&winui.lockScreen(function(n){return n==="winadmin"?!0:(winui.window.msg("密码错误",{shift:6}),!1)});winui.helper.addTool([{tips:"锁屏",icon:"fa-power-off",click:function(){winui.lockScreen(function(n){return n==="winadmin"?!0:(winui.window.msg("密码错误",{shift:6}),!1)})}},{tips:"切换壁纸",icon:"fa-television",click:function(){layer.msg("这个是自定义的工具栏",{zIndex:layer.zIndex})}}]);n("index",{})}); -------------------------------------------------------------------------------- /src/js/menulist.js: -------------------------------------------------------------------------------- 1 | //@ sourceURL=menulist.js 2 | layui.config({ 3 | base: '../../lib/' //指定 winui 路径 4 | , version: '1.0.0-beta' 5 | }).extend({ 6 | winui: 'winui/winui', 7 | window: 'winui/js/winui.window' 8 | }).define(['table', 'jquery', 'winui', 'window', 'layer'], function (exports) { 9 | 10 | winui.renderColor(); 11 | 12 | var table = layui.table, 13 | $ = layui.$, tableId = 'tableid'; 14 | //桌面显示提示消息的函数 15 | var msg = top.winui.window.msg; 16 | //表格渲染 17 | table.render({ 18 | id: tableId, 19 | elem: '#menu', 20 | url: '../../json/menulist.json', 21 | //height: 'full-65', //自适应高度 22 | //size: '', //表格尺寸,可选值sm lg 23 | //skin: '', //边框风格,可选值line row nob 24 | //even:true, //隔行变色 25 | page: true, 26 | limits: [10, 20, 30, 40, 50, 60, 70, 100], 27 | limit: 10, 28 | cols: [[ 29 | { field: 'id', type: 'checkbox' }, 30 | { field: 'icon', title: '图标', width: 120 }, 31 | { field: 'name', title: '名称', width: 150 }, 32 | { field: 'title', title: '标题', width: 150 }, 33 | { field: 'pageURL', title: '页面地址', width: 200 }, 34 | { field: 'openType', title: '页面类型', width: 120, templet: '#openTypeTpl' }, 35 | { field: 'isNecessary', title: '系统菜单', width: 100, templet: '#isNecessary' }, 36 | { field: 'order', title: '排序', width: 80, edit: 'text' }, 37 | { title: '操作', fixed: 'right', align: 'center', toolbar: '#barMenu', width: 200 } 38 | ]] 39 | }); 40 | //监听工具条 41 | table.on('tool(menutable)', function (obj) { //注:tool是工具条事件名,test是table原始容器的属性 lay-filter="对应的值" 42 | var data = obj.data; //获得当前行数据 43 | var layEvent = obj.event; //获得 lay-event 对应的值 44 | var tr = obj.tr; //获得当前行 tr 的DOM对象 45 | var ids = ''; //选中的Id 46 | $(data).each(function (index, item) { 47 | ids += item.id + ','; 48 | }); 49 | if (layEvent === 'del') { //删除 50 | deleteMenu(ids, obj); 51 | } else if (layEvent === 'edit') { //编辑 52 | openEditWindow(data.id); 53 | } else if (layEvent === 'setting') { //功能设置 54 | $.ajax({ 55 | type: 'get', 56 | url: 'setting.html?menuId=' + data.id, 57 | async: false, 58 | success: function (data) { 59 | content = data; 60 | //从桌面打开 61 | top.winui.window.open({ 62 | id: 'settingMenu', 63 | type: 1, 64 | title: '权限设置', 65 | content: content, 66 | area: ['55vw', '70vh'], 67 | offset: ['15vh', '25vw'], 68 | }); 69 | }, 70 | error: function (xml) { 71 | msg("获取页面失败", { 72 | icon: 2, 73 | time: 2000 74 | }); 75 | console.log(xml.responseText); 76 | } 77 | }); 78 | } 79 | }); 80 | //监听单元格编辑 81 | table.on('edit(menutable)', function (obj) { //注:tool是工具条事件名,test是table原始容器的属性 lay-filter="对应的值" 82 | if (/^[0-9]+$/.test(obj.value)) { 83 | var index = layer.load(1); 84 | $.ajax({ 85 | type: 'post', 86 | url: 'views/menu/updatemenuorder', 87 | data: { "id": obj.data.id, "order": obj.value }, 88 | success: function (json) { 89 | layer.close(index); 90 | if (!json.isSucceed) { 91 | msg(json.message); 92 | } 93 | }, 94 | error: function (xml) { 95 | layer.close(index); 96 | msg("修改失败", { 97 | icon: 2, 98 | time: 2000 99 | }); 100 | console.log(xml.responseText); 101 | } 102 | }); 103 | } 104 | }); 105 | //打开编辑窗口 106 | function openEditWindow(id) { 107 | if (!id) return; 108 | var content; 109 | var index = layer.load(1); 110 | $.ajax({ 111 | type: 'get', 112 | url: 'edit.html?id=' + id, 113 | success: function (data) { 114 | layer.close(index); 115 | content = data; 116 | //从桌面打开 117 | top.winui.window.open({ 118 | id: 'editMenu', 119 | type: 1, 120 | title: '编辑菜单', 121 | content: content, 122 | area: ['50vw', '70vh'], 123 | offset: ['15vh', '25vw'], 124 | }); 125 | }, 126 | error: function (xml) { 127 | layer.close(index); 128 | msg("获取页面失败", { 129 | icon: 2, 130 | time: 2000 131 | }); 132 | console.log(xml.responseText); 133 | } 134 | }); 135 | } 136 | //删除菜单 137 | function deleteMenu(ids, obj) { 138 | var msg = obj ? '确认删除菜单【' + obj.data.name + '】吗?' : '确认删除选中数据吗?'; 139 | top.winui.window.confirm(msg, { icon: 3, title: '删除系统菜单' }, function (index) { 140 | layer.close(index); 141 | 142 | msg('删除成功', { 143 | icon: 1, 144 | time: 2000 145 | }); 146 | //刷新表格 147 | if (obj) { 148 | obj.del(); //删除对应行(tr)的DOM结构 149 | } else { 150 | reloadTable(); //直接刷新表格 151 | } 152 | }); 153 | } 154 | //表格刷新 155 | function reloadTable() { 156 | table.reload(tableId, {}); 157 | } 158 | //绑定工具栏添加按钮事件 159 | $('#addMenu').on('click', function () { 160 | var content; 161 | var index = layer.load(1); 162 | $.ajax({ 163 | type: 'get', 164 | url: 'add.html', 165 | success: function (data) { 166 | layer.close(index); 167 | content = data; 168 | //从桌面打开 169 | top.winui.window.open({ 170 | id: 'addMenu', 171 | type: 1, 172 | title: '新增菜单', 173 | content: content, 174 | area: ['50vw', '70vh'], 175 | offset: ['15vh', '25vw'] 176 | }); 177 | }, 178 | error: function (xml) { 179 | layer.close(load); 180 | msg('操作失败', { 181 | icon: 2, 182 | time: 2000 183 | }); 184 | console.error(xml.responseText); 185 | } 186 | }); 187 | }); 188 | //绑定工具栏编辑按钮事件 189 | $('#editMenu').on('click', function () { 190 | var checkStatus = table.checkStatus(tableId); 191 | var checkCount = checkStatus.data.length; 192 | if (checkCount < 1) { 193 | msg('请选择一条数据', { 194 | time: 2000 195 | }); 196 | return false; 197 | } 198 | if (checkCount > 1) { 199 | msg('只能选择一条数据', { 200 | time: 2000 201 | }); 202 | return false; 203 | } 204 | openEditWindow(checkStatus.data[0].id); 205 | }); 206 | //绑定工具栏删除按钮事件 207 | $('#deleteMenu').on('click', function () { 208 | var checkStatus = table.checkStatus(tableId); 209 | var checkCount = checkStatus.data.length; 210 | if (checkCount < 1) { 211 | msg('请选择一条数据', { 212 | time: 2000 213 | }); 214 | return false; 215 | } 216 | var ids = ''; 217 | $(checkStatus.data).each(function (index, item) { 218 | ids += item.id + ','; 219 | }); 220 | deleteMenu(ids); 221 | }); 222 | //绑定工具栏刷新按钮事件 223 | $('#reloadTable').on('click', reloadTable); 224 | 225 | exports('menulist', {}); 226 | }); 227 | -------------------------------------------------------------------------------- /src/js/menulist.min.js: -------------------------------------------------------------------------------- 1 | layui.config({base:"../../lib/",version:"1.0.0-beta"}).extend({winui:"winui/winui",window:"winui/js/winui.window"}).define(["table","jquery","winui","window","layer"],function(n){function f(n){if(n){var r,u=layer.load(1);t.ajax({type:"get",url:"edit.html?id="+n,success:function(n){layer.close(u);r=n;top.winui.window.open({id:"editMenu",type:1,title:"编辑菜单",content:r,area:["50vw","70vh"],offset:["15vh","25vw"]})},error:function(n){layer.close(u);i("获取页面失败",{icon:2,time:2e3});console.log(n.responseText)}})}}function e(n,t){var i=t?"确认删除菜单【"+t.data.name+"】吗?":"确认删除选中数据吗?";top.winui.window.confirm(i,{icon:3,title:"删除系统菜单"},function(n){layer.close(n);i("删除成功",{icon:1,time:2e3});t?t.del():o()})}function o(){r.reload(u,{})}winui.renderColor();var r=layui.table,t=layui.$,u="tableid",i=top.winui.window.msg;r.render({id:u,elem:"#menu",url:"../../json/menulist.json",page:!0,limits:[10,20,30,40,50,60,70,100],limit:10,cols:[[{field:"id",type:"checkbox"},{field:"icon",title:"图标",width:120},{field:"name",title:"名称",width:150},{field:"title",title:"标题",width:150},{field:"pageURL",title:"页面地址",width:200},{field:"openType",title:"页面类型",width:120,templet:"#openTypeTpl"},{field:"isNecessary",title:"系统菜单",width:100,templet:"#isNecessary"},{field:"order",title:"排序",width:80,edit:"text"},{title:"操作",fixed:"right",align:"center",toolbar:"#barMenu",width:200}]]});r.on("tool(menutable)",function(n){var r=n.data,u=n.event,s=n.tr,o="";t(r).each(function(n,t){o+=t.id+","});u==="del"?e(o,n):u==="edit"?f(r.id):u==="setting"&&t.ajax({type:"get",url:"setting.html?menuId="+r.id,async:!1,success:function(n){content=n;top.winui.window.open({id:"settingMenu",type:1,title:"权限设置",content:content,area:["55vw","70vh"],offset:["15vh","25vw"]})},error:function(n){i("获取页面失败",{icon:2,time:2e3});console.log(n.responseText)}})});r.on("edit(menutable)",function(n){if(/^[0-9]+$/.test(n.value)){var r=layer.load(1);t.ajax({type:"post",url:"views/menu/updatemenuorder",data:{id:n.data.id,order:n.value},success:function(n){layer.close(r);n.isSucceed||i(n.message)},error:function(n){layer.close(r);i("修改失败",{icon:2,time:2e3});console.log(n.responseText)}})}});t("#addMenu").on("click",function(){var n,r=layer.load(1);t.ajax({type:"get",url:"add.html",success:function(t){layer.close(r);n=t;top.winui.window.open({id:"addMenu",type:1,title:"新增菜单",content:n,area:["50vw","70vh"],offset:["15vh","25vw"]})},error:function(n){layer.close(load);i("操作失败",{icon:2,time:2e3});console.error(n.responseText)}})});t("#editMenu").on("click",function(){var n=r.checkStatus(u),t=n.data.length;if(t<1)return i("请选择一条数据",{time:2e3}),!1;if(t>1)return i("只能选择一条数据",{time:2e3}),!1;f(n.data[0].id)});t("#deleteMenu").on("click",function(){var f=r.checkStatus(u),o=f.data.length,n;if(o<1)return i("请选择一条数据",{time:2e3}),!1;n="";t(f.data).each(function(t,i){n+=i.id+","});e(n)});t("#reloadTable").on("click",o);n("menulist",{})}); -------------------------------------------------------------------------------- /src/js/rolelist.js: -------------------------------------------------------------------------------- 1 | layui.config({ 2 | base: '../../lib/winui/' //指定 winui 路径 3 | , version: '1.0.0-beta' 4 | }).define(['table', 'jquery', 'winui'], function (exports) { 5 | 6 | winui.renderColor(); 7 | 8 | var table = layui.table, 9 | $ = layui.$, 10 | tableId = 'tableid'; 11 | //表格渲染 12 | table.render({ 13 | id: tableId, 14 | elem: '#role', 15 | url: '../../json/rolelist.json', 16 | //height: 'full-65', //自适应高度 17 | //size: '', //表格尺寸,可选值sm lg 18 | //skin: '', //边框风格,可选值line row nob 19 | //even:true, //隔行变色 20 | page: true, 21 | limits: [8, 16, 24, 32, 40, 48, 56], 22 | limit: 8, 23 | cols: [[ 24 | { field: 'id', type: 'checkbox' }, 25 | { field: 'roleName', title: '名称', width: 120 }, 26 | { field: 'description', title: '描述', width: 582 }, 27 | { field: 'dataState', title: '状态', width: 60, templet: '#stateTpl' }, 28 | { title: '操作', fixed: 'right', align: 'center', toolbar: '#barRole', width: 120 } 29 | ]] 30 | }); 31 | //监听工具条 32 | table.on('tool(roletable)', function (obj) { //注:tool是工具条事件名,test是table原始容器的属性 lay-filter="对应的值" 33 | var data = obj.data; //获得当前行数据 34 | var layEvent = obj.event; //获得 lay-event 对应的值 35 | var tr = obj.tr; //获得当前行 tr 的DOM对象 36 | var ids = ''; //选中的Id 37 | $(data).each(function (index, item) { 38 | ids += item.id + ','; 39 | }); 40 | if (layEvent === 'del') { //删除 41 | deleteRole(ids, obj); 42 | } else if (layEvent === 'edit') { //编辑 43 | if (!data.id) return; 44 | var content; 45 | var index = layer.load(1); 46 | $.ajax({ 47 | type: 'get', 48 | url: 'edit.html?id=' + data.id, 49 | async: true, 50 | success: function (data) { 51 | layer.close(index); 52 | content = data; 53 | //从桌面打开 54 | top.winui.window.open({ 55 | id: 'editRole', 56 | type: 1, 57 | title: '编辑角色', 58 | content: content, 59 | area: ['60vw', '70vh'], 60 | offset: ['15vh', '20vw'], 61 | }); 62 | top.winui.window.msg("选择框带联动的,尽情享用", { 63 | time: 2000 64 | }); 65 | }, 66 | error: function (xml) { 67 | layer.close(index); 68 | top.winui.window.msg("获取页面失败", { 69 | icon: 2, 70 | time: 2000 71 | }); 72 | console.log(xml.responseText); 73 | } 74 | }); 75 | } 76 | }); 77 | //表格重载 78 | function reloadTable() { 79 | table.reload(tableId, {}); 80 | } 81 | 82 | //打开添加页面 83 | function addRole() { 84 | top.winui.window.msg("自行脑补画面", { 85 | icon: 2, 86 | time: 2000 87 | }); 88 | } 89 | //删除角色 90 | function deleteRole(ids, obj) { 91 | var msg = obj ? '确认删除角色【' + obj.data.roleName + '】吗?' : '确认删除选中数据吗?' 92 | top.winui.window.confirm(msg, { icon: 3, title: '删除系统角色' }, function (index) { 93 | layer.close(index); 94 | //向服务端发送删除指令 95 | //刷新表格 96 | if (obj) { 97 | top.winui.window.msg('删除成功', { 98 | icon: 1, 99 | time: 2000 100 | }); 101 | obj.del(); //删除对应行(tr)的DOM结构 102 | } else { 103 | top.winui.window.msg('向服务端发送删除指令后刷新表格即可', { 104 | time: 2000 105 | }); 106 | reloadTable(); //直接刷新表格 107 | } 108 | }); 109 | } 110 | //绑定按钮事件 111 | $('#addRole').on('click', addRole); 112 | $('#deleteRole').on('click', function () { 113 | var checkStatus = table.checkStatus(tableId); 114 | var checkCount = checkStatus.data.length; 115 | if (checkCount < 1) { 116 | top.winui.window.msg('请选择一条数据', { 117 | time: 2000 118 | }); 119 | return false; 120 | } 121 | var ids = ''; 122 | $(checkStatus.data).each(function (index, item) { 123 | ids += item.id + ','; 124 | }); 125 | deleteRole(ids); 126 | }); 127 | $('#reloadTable').on('click', reloadTable); 128 | 129 | exports('rolelist', {}); 130 | }); 131 | -------------------------------------------------------------------------------- /src/js/rolelist.min.js: -------------------------------------------------------------------------------- 1 | layui.config({base:"../../lib/winui/",version:"1.0.0-beta"}).define(["table","jquery","winui"],function(n){function u(){i.reload(r,{})}function e(){top.winui.window.msg("自行脑补画面",{icon:2,time:2e3})}function f(n,t){var i=t?"确认删除角色【"+t.data.roleName+"】吗?":"确认删除选中数据吗?";top.winui.window.confirm(i,{icon:3,title:"删除系统角色"},function(n){layer.close(n);t?(top.winui.window.msg("删除成功",{icon:1,time:2e3}),t.del()):(top.winui.window.msg("向服务端发送删除指令后刷新表格即可",{time:2e3}),u())})}winui.renderColor();var i=layui.table,t=layui.$,r="tableid";i.render({id:r,elem:"#role",url:"../../json/rolelist.json",page:!0,limits:[8,16,24,32,40,48,56],limit:8,cols:[[{field:"id",type:"checkbox"},{field:"roleName",title:"名称",width:120},{field:"description",title:"描述",width:582},{field:"dataState",title:"状态",width:60,templet:"#stateTpl"},{title:"操作",fixed:"right",align:"center",toolbar:"#barRole",width:120}]]});i.on("tool(roletable)",function(n){var i=n.data,u=n.event,s=n.tr,e="",o,r;if(t(i).each(function(n,t){e+=t.id+","}),u==="del")f(e,n);else if(u==="edit"){if(!i.id)return;r=layer.load(1);t.ajax({type:"get",url:"edit.html?id="+i.id,async:!0,success:function(n){layer.close(r);o=n;top.winui.window.open({id:"editRole",type:1,title:"编辑角色",content:o,area:["60vw","70vh"],offset:["15vh","20vw"]});top.winui.window.msg("选择框带联动的,尽情享用",{time:2e3})},error:function(n){layer.close(r);top.winui.window.msg("获取页面失败",{icon:2,time:2e3});console.log(n.responseText)}})}});t("#addRole").on("click",e);t("#deleteRole").on("click",function(){var u=i.checkStatus(r),e=u.data.length,n;if(e<1)return top.winui.window.msg("请选择一条数据",{time:2e3}),!1;n="";t(u.data).each(function(t,i){n+=i.id+","});f(n)});t("#reloadTable").on("click",u);n("rolelist",{})}); -------------------------------------------------------------------------------- /src/json/desktopmenu.json: -------------------------------------------------------------------------------- 1 | { 2 | "code": 1, 3 | "message": "成功", 4 | "data": [ 5 | { 6 | "title": "主题", 7 | "pageURL": "theme", 8 | "name": "主题", 9 | "icon": "fa-television", 10 | "openType": 1, 11 | "maxOpen": -1, 12 | "extend": false, 13 | "childs": null, 14 | "id": 1 15 | }, 16 | { 17 | "title": "打赏作者", 18 | "pageURL": "/home/reward", 19 | "name": "打赏作者", 20 | "icon": "fa-qrcode", 21 | "openType": 1, 22 | "maxOpen": -1, 23 | "extend": false, 24 | "childs": null, 25 | "id": 3 26 | }, 27 | { 28 | "title": "基本说明", 29 | "pageURL": "views/demo/introduce.html", 30 | "name": "基本说明", 31 | "icon": "fa-info-circle", 32 | "openType": 2, 33 | "maxOpen": -1, 34 | "extend": false, 35 | "childs": null, 36 | "id": 4 37 | }, 38 | { 39 | "title": "系统菜单", 40 | "pageURL": "views/menu/list_iframe.html", 41 | "name": "系统菜单", 42 | "icon": "fa-navicon", 43 | "openType": 2, 44 | "maxOpen": -1, 45 | "extend": false, 46 | "childs": null, 47 | "id": 2 48 | }, 49 | { 50 | "title": "角色管理", 51 | "pageURL": "views/role/list.html", 52 | "name": "角色管理", 53 | "icon": "fa-th-large", 54 | "openType": 2, 55 | "maxOpen": -1, 56 | "extend": false, 57 | "childs": null, 58 | "id": 22 59 | }, 60 | { 61 | "title": "更新日志", 62 | "pageURL": "/systemlog/index", 63 | "name": "更新日志", 64 | "icon": "fa-clock-o", 65 | "openType": 1, 66 | "extend": false, 67 | "childs": null, 68 | "id": 60 69 | }, 70 | { 71 | "title": "点赞", 72 | "pageURL": "http://fly.layui.com/case/u/3547992", 73 | "name": "点赞", 74 | "icon": "fa-thumbs-up", 75 | "openType": 2, 76 | "extend": false, 77 | "childs": null, 78 | "id": 62 79 | }, 80 | { 81 | "title": "Layui框架", 82 | "pageURL": "http://www.layui.com/", 83 | "name": "Layui", 84 | "icon": "http://www.layui.com/favicon.ico", 85 | "openType": 2, 86 | "extend": false, 87 | "childs": null, 88 | "id": 57 89 | }, 90 | { 91 | "title": "ECharts", 92 | "pageURL": "views/echarts/demo.html", 93 | "name": "ECharts", 94 | "icon": "fa-bar-chart", 95 | "openType": 2, 96 | "extend": false, 97 | "childs": null, 98 | "id": 58 99 | } 100 | ] 101 | } -------------------------------------------------------------------------------- /src/json/menulist.json: -------------------------------------------------------------------------------- 1 | { 2 | "code": 0, 3 | "msg": "", 4 | "count": 41, 5 | "data": [ 6 | { 7 | "title": "个性化", 8 | "pageURL": "/home/individuation", 9 | "name": "个性化", 10 | "icon": "fa-television", 11 | "openType": 2, 12 | "level": 1, 13 | "isNecessary": true, 14 | "parentId": 0, 15 | "order": 0, 16 | "extend": false, 17 | "childs": null, 18 | "id": 1 19 | }, 20 | { 21 | "title": "打赏作者", 22 | "pageURL": "/home/reward", 23 | "name": "打赏作者", 24 | "icon": "fa-qrcode", 25 | "openType": 1, 26 | "level": 1, 27 | "isNecessary": true, 28 | "parentId": 0, 29 | "order": 1, 30 | "extend": false, 31 | "childs": null, 32 | "id": 3 33 | }, 34 | { 35 | "title": "基本说明", 36 | "pageURL": "views/demo/introduce.html", 37 | "name": "基本说明", 38 | "icon": "fa-info-circle", 39 | "openType": 2, 40 | "level": 1, 41 | "isNecessary": true, 42 | "parentId": 0, 43 | "order": 2, 44 | "extend": false, 45 | "childs": null, 46 | "id": 4 47 | }, 48 | { 49 | "title": "菜单设置", 50 | "pageURL": "views/menu/list_iframe.html", 51 | "name": "菜单设置", 52 | "icon": "fa-navicon", 53 | "openType": 2, 54 | "level": 2, 55 | "isNecessary": true, 56 | "parentId": 23, 57 | "order": 3, 58 | "extend": false, 59 | "childs": null, 60 | "id": 2 61 | }, 62 | { 63 | "title": "操作员管理", 64 | "pageURL": "/operator/index", 65 | "name": "操作员管理", 66 | "icon": "fa-user", 67 | "openType": 2, 68 | "level": 2, 69 | "isNecessary": true, 70 | "parentId": 23, 71 | "order": 4, 72 | "extend": false, 73 | "childs": null, 74 | "id": 19 75 | }, 76 | { 77 | "title": "角色管理", 78 | "pageURL": "/role/index", 79 | "name": "角色管理", 80 | "icon": "fa-th-large", 81 | "openType": 2, 82 | "level": 2, 83 | "isNecessary": true, 84 | "parentId": 23, 85 | "order": 5, 86 | "extend": false, 87 | "childs": null, 88 | "id": 22 89 | }, 90 | { 91 | "title": "系统设置", 92 | "pageURL": null, 93 | "name": "系统设置", 94 | "icon": "fa-cog", 95 | "openType": 2, 96 | "level": 1, 97 | "isNecessary": true, 98 | "parentId": 0, 99 | "order": 98, 100 | "extend": false, 101 | "childs": null, 102 | "id": 23 103 | }, 104 | { 105 | "title": "Font Awesome图标展示", 106 | "pageURL": null, 107 | "name": "Font Awesome图标展示", 108 | "icon": "fa-user", 109 | "openType": 2, 110 | "level": 1, 111 | "isNecessary": true, 112 | "parentId": 0, 113 | "order": 99, 114 | "extend": false, 115 | "childs": null, 116 | "id": 27 117 | }, 118 | { 119 | "title": "图片", 120 | "pageURL": null, 121 | "name": "图片", 122 | "icon": "fa-photo", 123 | "openType": 2, 124 | "level": 0, 125 | "isNecessary": true, 126 | "parentId": 27, 127 | "order": 99, 128 | "extend": false, 129 | "childs": null, 130 | "id": 28 131 | }, 132 | { 133 | "title": "书签", 134 | "pageURL": null, 135 | "name": "书签", 136 | "icon": "fa-bookmark", 137 | "openType": 2, 138 | "level": 0, 139 | "isNecessary": true, 140 | "parentId": 27, 141 | "order": 99, 142 | "extend": false, 143 | "childs": null, 144 | "id": 29 145 | } 146 | ] 147 | } -------------------------------------------------------------------------------- /src/json/resfailed.json: -------------------------------------------------------------------------------- 1 | { 2 | "code": -1, 3 | "isSucceed": false, 4 | "message": "响应返回消息:操作失败" 5 | } 6 | -------------------------------------------------------------------------------- /src/json/resok.json: -------------------------------------------------------------------------------- 1 | { 2 | "code": 1, 3 | "isSucceed": true, 4 | "message": "成功" 5 | } 6 | -------------------------------------------------------------------------------- /src/json/rolelist.json: -------------------------------------------------------------------------------- 1 | { 2 | "code": 0, 3 | "msg": "", 4 | "count": 2, 5 | "data": [ 6 | { 7 | "roleName": "超级管理员", 8 | "description": "可查看所有菜单,可使用所有功能。", 9 | "dataState": 1, 10 | "lastOperTime": "2017-12-27 17:19:40", 11 | "id": 3 12 | }, 13 | { 14 | "roleName": "游客", 15 | "description": "可查看所有菜单,可使用增加功能,不可使用修改和删除功能。可删除非系统菜单。", 16 | "dataState": 1, 17 | "lastOperTime": "2017-12-27 17:49:44", 18 | "id": 4 19 | } 20 | ] 21 | } -------------------------------------------------------------------------------- /src/lib/echarts/echartsTheme.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:echarts 主题 4 | @Author:贤心 5 | @Site:http://www.layui.com/admin/ 6 | @License:GPL-2 7 | 8 | */ 9 | 10 | 11 | layui.define(function(exports) { 12 | exports('echartsTheme', { 13 | // 默认色板 14 | color: [ 15 | '#009688','#1E9FFF','#5FB878','#FFB980','#D87A80', 16 | '#8d98b3','#e5cf0d','#97b552','#95706d','#dc69aa', 17 | '#07a2a4','#9a7fd1','#588dd5','#f5994e','#c05050', 18 | '#59678c','#c9ab00','#7eb00a','#6f5553','#c14089' 19 | ], 20 | 21 | // 图表标题 22 | title: { 23 | textStyle: { 24 | fontWeight: 'normal', 25 | color: '#666' // 主标题文字颜色 26 | } 27 | }, 28 | 29 | // 值域 30 | dataRange: { 31 | itemWidth: 15, 32 | color: ['#009688','#e0ffff'] 33 | }, 34 | 35 | // 工具箱 36 | toolbox: { 37 | color : ['#1e90ff', '#1e90ff', '#1e90ff', '#1e90ff'], 38 | effectiveColor : '#ff4500' 39 | }, 40 | 41 | // 提示框 42 | tooltip: { 43 | backgroundColor: 'rgba(50,50,50,0.5)', // 提示背景颜色,默认为透明度为0.7的黑色 44 | axisPointer : { // 坐标轴指示器,坐标轴触发有效 45 | type : 'line', // 默认为直线,可选为:'line' | 'shadow' 46 | lineStyle : { // 直线指示器样式设置 47 | color: '#009688' 48 | }, 49 | crossStyle: { 50 | color: '#008acd' 51 | }, 52 | shadowStyle : { // 阴影指示器样式设置 53 | color: 'rgba(200,200,200,0.2)' 54 | } 55 | } 56 | }, 57 | 58 | // 区域缩放控制器 59 | dataZoom: { 60 | dataBackgroundColor: '#efefff', // 数据背景颜色 61 | fillerColor: 'rgba(182,162,222,0.2)', // 填充颜色 62 | handleColor: '#008acd' // 手柄颜色 63 | }, 64 | 65 | // 网格 66 | grid: { 67 | borderColor: '#eee' 68 | }, 69 | 70 | // 类目轴 - X轴 71 | categoryAxis: { 72 | axisLine: { // 坐标轴线 73 | lineStyle: { // 属性lineStyle控制线条样式 74 | color: '#009688' 75 | } 76 | }, 77 | axisTick: { //小标记 78 | show: false 79 | }, 80 | splitLine: { // 分隔线 81 | lineStyle: { // 属性lineStyle(详见lineStyle)控制线条样式 82 | color: ['#eee'] 83 | } 84 | } 85 | }, 86 | 87 | // 数值型坐标轴默认参数 - Y轴 88 | valueAxis: { 89 | axisLine: { // 坐标轴线 90 | lineStyle: { // 属性lineStyle控制线条样式 91 | color: '#009688' 92 | } 93 | }, 94 | splitArea : { 95 | show : true, 96 | areaStyle : { 97 | color: ['rgba(250,250,250,0.1)','rgba(200,200,200,0.1)'] 98 | } 99 | }, 100 | splitLine: { // 分隔线 101 | lineStyle: { // 属性lineStyle(详见lineStyle)控制线条样式 102 | color: ['#eee'] 103 | } 104 | } 105 | }, 106 | 107 | polar : { 108 | axisLine: { // 坐标轴线 109 | lineStyle: { // 属性lineStyle控制线条样式 110 | color: '#ddd' 111 | } 112 | }, 113 | splitArea : { 114 | show : true, 115 | areaStyle : { 116 | color: ['rgba(250,250,250,0.2)','rgba(200,200,200,0.2)'] 117 | } 118 | }, 119 | splitLine : { 120 | lineStyle : { 121 | color : '#ddd' 122 | } 123 | } 124 | }, 125 | 126 | timeline : { 127 | lineStyle : { 128 | color : '#009688' 129 | }, 130 | controlStyle : { 131 | normal : { color : '#009688'}, 132 | emphasis : { color : '#009688'} 133 | }, 134 | symbol : 'emptyCircle', 135 | symbolSize : 3 136 | }, 137 | 138 | // 柱形图默认参数 139 | bar: { 140 | itemStyle: { 141 | normal: { 142 | barBorderRadius: 2 143 | }, 144 | emphasis: { 145 | barBorderRadius: 2 146 | } 147 | } 148 | }, 149 | 150 | // 折线图默认参数 151 | line: { 152 | smooth : true, 153 | symbol: 'emptyCircle', // 拐点图形类型 154 | symbolSize: 3 // 拐点图形大小 155 | }, 156 | 157 | // K线图默认参数 158 | k: { 159 | itemStyle: { 160 | normal: { 161 | color: '#d87a80', // 阳线填充颜色 162 | color0: '#2ec7c9', // 阴线填充颜色 163 | lineStyle: { 164 | color: '#d87a80', // 阳线边框颜色 165 | color0: '#2ec7c9' // 阴线边框颜色 166 | } 167 | } 168 | } 169 | }, 170 | 171 | // 散点图默认参数 172 | scatter: { 173 | symbol: 'circle', // 图形类型 174 | symbolSize: 4 // 图形大小,半宽(半径)参数,当图形为方向或菱形则总宽度为symbolSize * 2 175 | }, 176 | 177 | // 雷达图默认参数 178 | radar : { 179 | symbol: 'emptyCircle', // 图形类型 180 | symbolSize:3 181 | //symbol: null, // 拐点图形类型 182 | //symbolRotate : null, // 图形旋转控制 183 | }, 184 | 185 | map: { 186 | itemStyle: { 187 | normal: { 188 | areaStyle: { 189 | color: '#ddd' 190 | }, 191 | label: { 192 | textStyle: { 193 | color: '#d87a80' 194 | } 195 | } 196 | }, 197 | emphasis: { // 也是选中样式 198 | areaStyle: { 199 | color: '#fe994e' 200 | } 201 | } 202 | } 203 | }, 204 | 205 | force : { 206 | itemStyle: { 207 | normal: { 208 | linkStyle : { 209 | color : '#1e90ff' 210 | } 211 | } 212 | } 213 | }, 214 | 215 | chord : { 216 | itemStyle : { 217 | normal : { 218 | borderWidth: 1, 219 | borderColor: 'rgba(128, 128, 128, 0.5)', 220 | chordStyle : { 221 | lineStyle : { 222 | color : 'rgba(128, 128, 128, 0.5)' 223 | } 224 | } 225 | }, 226 | emphasis : { 227 | borderWidth: 1, 228 | borderColor: 'rgba(128, 128, 128, 0.5)', 229 | chordStyle : { 230 | lineStyle : { 231 | color : 'rgba(128, 128, 128, 0.5)' 232 | } 233 | } 234 | } 235 | } 236 | }, 237 | 238 | gauge : { 239 | axisLine: { // 坐标轴线 240 | lineStyle: { // 属性lineStyle控制线条样式 241 | color: [[0.2, '#2ec7c9'],[0.8, '#5ab1ef'],[1, '#d87a80']], 242 | width: 10 243 | } 244 | }, 245 | axisTick: { // 坐标轴小标记 246 | splitNumber: 10, // 每份split细分多少段 247 | length :15, // 属性length控制线长 248 | lineStyle: { // 属性lineStyle控制线条样式 249 | color: 'auto' 250 | } 251 | }, 252 | splitLine: { // 分隔线 253 | length :22, // 属性length控制线长 254 | lineStyle: { // 属性lineStyle(详见lineStyle)控制线条样式 255 | color: 'auto' 256 | } 257 | }, 258 | pointer : { 259 | width : 5 260 | } 261 | }, 262 | 263 | textStyle: { 264 | fontFamily: '微软雅黑, Arial, Verdana, sans-serif' 265 | } 266 | }); 267 | }); -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/HELP-US-OUT.txt: -------------------------------------------------------------------------------- 1 | I hope you love Font Awesome. If you've found it useful, please do me a favor and check out my latest project, 2 | Fort Awesome (https://fortawesome.com). It makes it easy to put the perfect icons on your website. Choose from our awesome, 3 | comprehensive icon sets or copy and paste your own. 4 | 5 | Please. Check it out. 6 | 7 | -Dave Gandy 8 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/font-awesome-4.7.0/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/animated.less: -------------------------------------------------------------------------------- 1 | // Animated Icons 2 | // -------------------------- 3 | 4 | .@{fa-css-prefix}-spin { 5 | -webkit-animation: fa-spin 2s infinite linear; 6 | animation: fa-spin 2s infinite linear; 7 | } 8 | 9 | .@{fa-css-prefix}-pulse { 10 | -webkit-animation: fa-spin 1s infinite steps(8); 11 | animation: fa-spin 1s infinite steps(8); 12 | } 13 | 14 | @-webkit-keyframes fa-spin { 15 | 0% { 16 | -webkit-transform: rotate(0deg); 17 | transform: rotate(0deg); 18 | } 19 | 100% { 20 | -webkit-transform: rotate(359deg); 21 | transform: rotate(359deg); 22 | } 23 | } 24 | 25 | @keyframes fa-spin { 26 | 0% { 27 | -webkit-transform: rotate(0deg); 28 | transform: rotate(0deg); 29 | } 30 | 100% { 31 | -webkit-transform: rotate(359deg); 32 | transform: rotate(359deg); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/bordered-pulled.less: -------------------------------------------------------------------------------- 1 | // Bordered & Pulled 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-border { 5 | padding: .2em .25em .15em; 6 | border: solid .08em @fa-border-color; 7 | border-radius: .1em; 8 | } 9 | 10 | .@{fa-css-prefix}-pull-left { float: left; } 11 | .@{fa-css-prefix}-pull-right { float: right; } 12 | 13 | .@{fa-css-prefix} { 14 | &.@{fa-css-prefix}-pull-left { margin-right: .3em; } 15 | &.@{fa-css-prefix}-pull-right { margin-left: .3em; } 16 | } 17 | 18 | /* Deprecated as of 4.4.0 */ 19 | .pull-right { float: right; } 20 | .pull-left { float: left; } 21 | 22 | .@{fa-css-prefix} { 23 | &.pull-left { margin-right: .3em; } 24 | &.pull-right { margin-left: .3em; } 25 | } 26 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/core.less: -------------------------------------------------------------------------------- 1 | // Base Class Definition 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix} { 5 | display: inline-block; 6 | font: normal normal normal @fa-font-size-base/@fa-line-height-base FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/fixed-width.less: -------------------------------------------------------------------------------- 1 | // Fixed Width Icons 2 | // ------------------------- 3 | .@{fa-css-prefix}-fw { 4 | width: (18em / 14); 5 | text-align: center; 6 | } 7 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/font-awesome.less: -------------------------------------------------------------------------------- 1 | /*! 2 | * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome 3 | * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) 4 | */ 5 | 6 | @import "variables.less"; 7 | @import "mixins.less"; 8 | @import "path.less"; 9 | @import "core.less"; 10 | @import "larger.less"; 11 | @import "fixed-width.less"; 12 | @import "list.less"; 13 | @import "bordered-pulled.less"; 14 | @import "animated.less"; 15 | @import "rotated-flipped.less"; 16 | @import "stacked.less"; 17 | @import "icons.less"; 18 | @import "screen-reader.less"; 19 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/larger.less: -------------------------------------------------------------------------------- 1 | // Icon Sizes 2 | // ------------------------- 3 | 4 | /* makes the font 33% larger relative to the icon container */ 5 | .@{fa-css-prefix}-lg { 6 | font-size: (4em / 3); 7 | line-height: (3em / 4); 8 | vertical-align: -15%; 9 | } 10 | .@{fa-css-prefix}-2x { font-size: 2em; } 11 | .@{fa-css-prefix}-3x { font-size: 3em; } 12 | .@{fa-css-prefix}-4x { font-size: 4em; } 13 | .@{fa-css-prefix}-5x { font-size: 5em; } 14 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/list.less: -------------------------------------------------------------------------------- 1 | // List Icons 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-ul { 5 | padding-left: 0; 6 | margin-left: @fa-li-width; 7 | list-style-type: none; 8 | > li { position: relative; } 9 | } 10 | .@{fa-css-prefix}-li { 11 | position: absolute; 12 | left: -@fa-li-width; 13 | width: @fa-li-width; 14 | top: (2em / 14); 15 | text-align: center; 16 | &.@{fa-css-prefix}-lg { 17 | left: (-@fa-li-width + (4em / 14)); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/mixins.less: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------- 3 | 4 | .fa-icon() { 5 | display: inline-block; 6 | font: normal normal normal @fa-font-size-base/@fa-line-height-base FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | 14 | .fa-icon-rotate(@degrees, @rotation) { 15 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=@{rotation})"; 16 | -webkit-transform: rotate(@degrees); 17 | -ms-transform: rotate(@degrees); 18 | transform: rotate(@degrees); 19 | } 20 | 21 | .fa-icon-flip(@horiz, @vert, @rotation) { 22 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=@{rotation}, mirror=1)"; 23 | -webkit-transform: scale(@horiz, @vert); 24 | -ms-transform: scale(@horiz, @vert); 25 | transform: scale(@horiz, @vert); 26 | } 27 | 28 | 29 | // Only display content to screen readers. A la Bootstrap 4. 30 | // 31 | // See: http://a11yproject.com/posts/how-to-hide-content/ 32 | 33 | .sr-only() { 34 | position: absolute; 35 | width: 1px; 36 | height: 1px; 37 | padding: 0; 38 | margin: -1px; 39 | overflow: hidden; 40 | clip: rect(0,0,0,0); 41 | border: 0; 42 | } 43 | 44 | // Use in conjunction with .sr-only to only display content when it's focused. 45 | // 46 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1 47 | // 48 | // Credit: HTML5 Boilerplate 49 | 50 | .sr-only-focusable() { 51 | &:active, 52 | &:focus { 53 | position: static; 54 | width: auto; 55 | height: auto; 56 | margin: 0; 57 | overflow: visible; 58 | clip: auto; 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/path.less: -------------------------------------------------------------------------------- 1 | /* FONT PATH 2 | * -------------------------- */ 3 | 4 | @font-face { 5 | font-family: 'FontAwesome'; 6 | src: url('@{fa-font-path}/fontawesome-webfont.eot?v=@{fa-version}'); 7 | src: url('@{fa-font-path}/fontawesome-webfont.eot?#iefix&v=@{fa-version}') format('embedded-opentype'), 8 | url('@{fa-font-path}/fontawesome-webfont.woff2?v=@{fa-version}') format('woff2'), 9 | url('@{fa-font-path}/fontawesome-webfont.woff?v=@{fa-version}') format('woff'), 10 | url('@{fa-font-path}/fontawesome-webfont.ttf?v=@{fa-version}') format('truetype'), 11 | url('@{fa-font-path}/fontawesome-webfont.svg?v=@{fa-version}#fontawesomeregular') format('svg'); 12 | // src: url('@{fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/rotated-flipped.less: -------------------------------------------------------------------------------- 1 | // Rotated & Flipped Icons 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-rotate-90 { .fa-icon-rotate(90deg, 1); } 5 | .@{fa-css-prefix}-rotate-180 { .fa-icon-rotate(180deg, 2); } 6 | .@{fa-css-prefix}-rotate-270 { .fa-icon-rotate(270deg, 3); } 7 | 8 | .@{fa-css-prefix}-flip-horizontal { .fa-icon-flip(-1, 1, 0); } 9 | .@{fa-css-prefix}-flip-vertical { .fa-icon-flip(1, -1, 2); } 10 | 11 | // Hook for IE8-9 12 | // ------------------------- 13 | 14 | :root .@{fa-css-prefix}-rotate-90, 15 | :root .@{fa-css-prefix}-rotate-180, 16 | :root .@{fa-css-prefix}-rotate-270, 17 | :root .@{fa-css-prefix}-flip-horizontal, 18 | :root .@{fa-css-prefix}-flip-vertical { 19 | filter: none; 20 | } 21 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/screen-reader.less: -------------------------------------------------------------------------------- 1 | // Screen Readers 2 | // ------------------------- 3 | 4 | .sr-only { .sr-only(); } 5 | .sr-only-focusable { .sr-only-focusable(); } 6 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/less/stacked.less: -------------------------------------------------------------------------------- 1 | // Stacked Icons 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-stack { 5 | position: relative; 6 | display: inline-block; 7 | width: 2em; 8 | height: 2em; 9 | line-height: 2em; 10 | vertical-align: middle; 11 | } 12 | .@{fa-css-prefix}-stack-1x, .@{fa-css-prefix}-stack-2x { 13 | position: absolute; 14 | left: 0; 15 | width: 100%; 16 | text-align: center; 17 | } 18 | .@{fa-css-prefix}-stack-1x { line-height: inherit; } 19 | .@{fa-css-prefix}-stack-2x { font-size: 2em; } 20 | .@{fa-css-prefix}-inverse { color: @fa-inverse; } 21 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_animated.scss: -------------------------------------------------------------------------------- 1 | // Spinning Icons 2 | // -------------------------- 3 | 4 | .#{$fa-css-prefix}-spin { 5 | -webkit-animation: fa-spin 2s infinite linear; 6 | animation: fa-spin 2s infinite linear; 7 | } 8 | 9 | .#{$fa-css-prefix}-pulse { 10 | -webkit-animation: fa-spin 1s infinite steps(8); 11 | animation: fa-spin 1s infinite steps(8); 12 | } 13 | 14 | @-webkit-keyframes fa-spin { 15 | 0% { 16 | -webkit-transform: rotate(0deg); 17 | transform: rotate(0deg); 18 | } 19 | 100% { 20 | -webkit-transform: rotate(359deg); 21 | transform: rotate(359deg); 22 | } 23 | } 24 | 25 | @keyframes fa-spin { 26 | 0% { 27 | -webkit-transform: rotate(0deg); 28 | transform: rotate(0deg); 29 | } 30 | 100% { 31 | -webkit-transform: rotate(359deg); 32 | transform: rotate(359deg); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_bordered-pulled.scss: -------------------------------------------------------------------------------- 1 | // Bordered & Pulled 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-border { 5 | padding: .2em .25em .15em; 6 | border: solid .08em $fa-border-color; 7 | border-radius: .1em; 8 | } 9 | 10 | .#{$fa-css-prefix}-pull-left { float: left; } 11 | .#{$fa-css-prefix}-pull-right { float: right; } 12 | 13 | .#{$fa-css-prefix} { 14 | &.#{$fa-css-prefix}-pull-left { margin-right: .3em; } 15 | &.#{$fa-css-prefix}-pull-right { margin-left: .3em; } 16 | } 17 | 18 | /* Deprecated as of 4.4.0 */ 19 | .pull-right { float: right; } 20 | .pull-left { float: left; } 21 | 22 | .#{$fa-css-prefix} { 23 | &.pull-left { margin-right: .3em; } 24 | &.pull-right { margin-left: .3em; } 25 | } 26 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_core.scss: -------------------------------------------------------------------------------- 1 | // Base Class Definition 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix} { 5 | display: inline-block; 6 | font: normal normal normal #{$fa-font-size-base}/#{$fa-line-height-base} FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_fixed-width.scss: -------------------------------------------------------------------------------- 1 | // Fixed Width Icons 2 | // ------------------------- 3 | .#{$fa-css-prefix}-fw { 4 | width: (18em / 14); 5 | text-align: center; 6 | } 7 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_larger.scss: -------------------------------------------------------------------------------- 1 | // Icon Sizes 2 | // ------------------------- 3 | 4 | /* makes the font 33% larger relative to the icon container */ 5 | .#{$fa-css-prefix}-lg { 6 | font-size: (4em / 3); 7 | line-height: (3em / 4); 8 | vertical-align: -15%; 9 | } 10 | .#{$fa-css-prefix}-2x { font-size: 2em; } 11 | .#{$fa-css-prefix}-3x { font-size: 3em; } 12 | .#{$fa-css-prefix}-4x { font-size: 4em; } 13 | .#{$fa-css-prefix}-5x { font-size: 5em; } 14 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_list.scss: -------------------------------------------------------------------------------- 1 | // List Icons 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-ul { 5 | padding-left: 0; 6 | margin-left: $fa-li-width; 7 | list-style-type: none; 8 | > li { position: relative; } 9 | } 10 | .#{$fa-css-prefix}-li { 11 | position: absolute; 12 | left: -$fa-li-width; 13 | width: $fa-li-width; 14 | top: (2em / 14); 15 | text-align: center; 16 | &.#{$fa-css-prefix}-lg { 17 | left: -$fa-li-width + (4em / 14); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_mixins.scss: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------- 3 | 4 | @mixin fa-icon() { 5 | display: inline-block; 6 | font: normal normal normal #{$fa-font-size-base}/#{$fa-line-height-base} FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | 14 | @mixin fa-icon-rotate($degrees, $rotation) { 15 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation})"; 16 | -webkit-transform: rotate($degrees); 17 | -ms-transform: rotate($degrees); 18 | transform: rotate($degrees); 19 | } 20 | 21 | @mixin fa-icon-flip($horiz, $vert, $rotation) { 22 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation}, mirror=1)"; 23 | -webkit-transform: scale($horiz, $vert); 24 | -ms-transform: scale($horiz, $vert); 25 | transform: scale($horiz, $vert); 26 | } 27 | 28 | 29 | // Only display content to screen readers. A la Bootstrap 4. 30 | // 31 | // See: http://a11yproject.com/posts/how-to-hide-content/ 32 | 33 | @mixin sr-only { 34 | position: absolute; 35 | width: 1px; 36 | height: 1px; 37 | padding: 0; 38 | margin: -1px; 39 | overflow: hidden; 40 | clip: rect(0,0,0,0); 41 | border: 0; 42 | } 43 | 44 | // Use in conjunction with .sr-only to only display content when it's focused. 45 | // 46 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1 47 | // 48 | // Credit: HTML5 Boilerplate 49 | 50 | @mixin sr-only-focusable { 51 | &:active, 52 | &:focus { 53 | position: static; 54 | width: auto; 55 | height: auto; 56 | margin: 0; 57 | overflow: visible; 58 | clip: auto; 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_path.scss: -------------------------------------------------------------------------------- 1 | /* FONT PATH 2 | * -------------------------- */ 3 | 4 | @font-face { 5 | font-family: 'FontAwesome'; 6 | src: url('#{$fa-font-path}/fontawesome-webfont.eot?v=#{$fa-version}'); 7 | src: url('#{$fa-font-path}/fontawesome-webfont.eot?#iefix&v=#{$fa-version}') format('embedded-opentype'), 8 | url('#{$fa-font-path}/fontawesome-webfont.woff2?v=#{$fa-version}') format('woff2'), 9 | url('#{$fa-font-path}/fontawesome-webfont.woff?v=#{$fa-version}') format('woff'), 10 | url('#{$fa-font-path}/fontawesome-webfont.ttf?v=#{$fa-version}') format('truetype'), 11 | url('#{$fa-font-path}/fontawesome-webfont.svg?v=#{$fa-version}#fontawesomeregular') format('svg'); 12 | // src: url('#{$fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_rotated-flipped.scss: -------------------------------------------------------------------------------- 1 | // Rotated & Flipped Icons 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-rotate-90 { @include fa-icon-rotate(90deg, 1); } 5 | .#{$fa-css-prefix}-rotate-180 { @include fa-icon-rotate(180deg, 2); } 6 | .#{$fa-css-prefix}-rotate-270 { @include fa-icon-rotate(270deg, 3); } 7 | 8 | .#{$fa-css-prefix}-flip-horizontal { @include fa-icon-flip(-1, 1, 0); } 9 | .#{$fa-css-prefix}-flip-vertical { @include fa-icon-flip(1, -1, 2); } 10 | 11 | // Hook for IE8-9 12 | // ------------------------- 13 | 14 | :root .#{$fa-css-prefix}-rotate-90, 15 | :root .#{$fa-css-prefix}-rotate-180, 16 | :root .#{$fa-css-prefix}-rotate-270, 17 | :root .#{$fa-css-prefix}-flip-horizontal, 18 | :root .#{$fa-css-prefix}-flip-vertical { 19 | filter: none; 20 | } 21 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_screen-reader.scss: -------------------------------------------------------------------------------- 1 | // Screen Readers 2 | // ------------------------- 3 | 4 | .sr-only { @include sr-only(); } 5 | .sr-only-focusable { @include sr-only-focusable(); } 6 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/_stacked.scss: -------------------------------------------------------------------------------- 1 | // Stacked Icons 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-stack { 5 | position: relative; 6 | display: inline-block; 7 | width: 2em; 8 | height: 2em; 9 | line-height: 2em; 10 | vertical-align: middle; 11 | } 12 | .#{$fa-css-prefix}-stack-1x, .#{$fa-css-prefix}-stack-2x { 13 | position: absolute; 14 | left: 0; 15 | width: 100%; 16 | text-align: center; 17 | } 18 | .#{$fa-css-prefix}-stack-1x { line-height: inherit; } 19 | .#{$fa-css-prefix}-stack-2x { font-size: 2em; } 20 | .#{$fa-css-prefix}-inverse { color: $fa-inverse; } 21 | -------------------------------------------------------------------------------- /src/lib/font-awesome-4.7.0/scss/font-awesome.scss: -------------------------------------------------------------------------------- 1 | /*! 2 | * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome 3 | * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) 4 | */ 5 | 6 | @import "variables"; 7 | @import "mixins"; 8 | @import "path"; 9 | @import "core"; 10 | @import "larger"; 11 | @import "fixed-width"; 12 | @import "list"; 13 | @import "bordered-pulled"; 14 | @import "animated"; 15 | @import "rotated-flipped"; 16 | @import "stacked"; 17 | @import "icons"; 18 | @import "screen-reader"; 19 | -------------------------------------------------------------------------------- /src/lib/layui/css/modules/code.css: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name: layui.code 4 | @Author: 贤心 5 | @Site: http://www.layui.com 6 | 7 | */ 8 | 9 | /* 加载就绪标志 */ 10 | html #layuicss-skincodecss{display:none; position: absolute; width:1989px;} 11 | 12 | /* 默认风格 */ 13 | .layui-code-view{display: block; position: relative; margin: 10px 0; padding: 0; border: 1px solid #e2e2e2; border-left-width: 6px; background-color: #F2F2F2; color: #333; font-family: Courier New; font-size: 12px;} 14 | .layui-code-h3{position: relative; padding: 0 10px; height: 32px; line-height: 32px; border-bottom: 1px solid #e2e2e2; font-size: 12px;} 15 | .layui-code-h3 a{position: absolute; right: 10px; top: 0; color: #999;} 16 | .layui-code-view .layui-code-ol{position: relative; overflow: auto;} 17 | .layui-code-view .layui-code-ol li{position: relative; margin-left: 45px; line-height: 20px; padding: 0 5px; border-left: 1px solid #e2e2e2; list-style-type: decimal-leading-zero; *list-style-type: decimal; background-color: #fff;} 18 | .layui-code-view pre{margin: 0;} 19 | 20 | /* notepadd++风格 */ 21 | .layui-code-notepad{border: 1px solid #0C0C0C; border-left-color: #3F3F3F; background-color: #0C0C0C; color: #C2BE9E} 22 | .layui-code-notepad .layui-code-h3{border-bottom: none;} 23 | .layui-code-notepad .layui-code-ol li{background-color: #3F3F3F; border-left: none;} -------------------------------------------------------------------------------- /src/lib/layui/css/modules/laydate/default/font.css: -------------------------------------------------------------------------------- 1 | /** 图标字体 **/ 2 | @font-face {font-family: 'laydate-icon'; 3 | src: url('./font/iconfont.eot'); 4 | src: url('./font/iconfont.eot#iefix') format('embedded-opentype'), 5 | url('./font/iconfont.svg#iconfont') format('svg'), 6 | url('./font/iconfont.woff') format('woff'), 7 | url('./font/iconfont.ttf') format('truetype'); 8 | } 9 | 10 | .laydate-icon{ 11 | font-family:"laydate-icon" !important; 12 | font-size: 16px; 13 | font-style: normal; 14 | -webkit-font-smoothing: antialiased; 15 | -moz-osx-font-smoothing: grayscale; 16 | } -------------------------------------------------------------------------------- /src/lib/layui/css/modules/layer/default/icon-ext.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/css/modules/layer/default/icon-ext.png -------------------------------------------------------------------------------- /src/lib/layui/css/modules/layer/default/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/css/modules/layer/default/icon.png -------------------------------------------------------------------------------- /src/lib/layui/css/modules/layer/default/loading-0.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/css/modules/layer/default/loading-0.gif -------------------------------------------------------------------------------- /src/lib/layui/css/modules/layer/default/loading-1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/css/modules/layer/default/loading-1.gif -------------------------------------------------------------------------------- /src/lib/layui/css/modules/layer/default/loading-2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/css/modules/layer/default/loading-2.gif -------------------------------------------------------------------------------- /src/lib/layui/font/iconfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/font/iconfont.eot -------------------------------------------------------------------------------- /src/lib/layui/font/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/font/iconfont.ttf -------------------------------------------------------------------------------- /src/lib/layui/font/iconfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/font/iconfont.woff -------------------------------------------------------------------------------- /src/lib/layui/images/face/0.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/0.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/1.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/10.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/10.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/11.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/11.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/12.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/12.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/13.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/13.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/14.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/14.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/15.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/15.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/16.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/16.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/17.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/17.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/18.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/19.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/19.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/2.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/20.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/20.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/21.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/21.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/22.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/22.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/23.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/23.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/24.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/24.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/25.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/25.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/26.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/26.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/27.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/27.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/28.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/28.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/29.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/29.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/3.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/3.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/30.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/30.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/31.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/31.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/32.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/32.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/33.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/33.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/34.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/34.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/35.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/35.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/36.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/36.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/37.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/37.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/38.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/38.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/39.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/39.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/4.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/4.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/40.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/40.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/41.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/41.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/42.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/42.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/43.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/43.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/44.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/44.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/45.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/45.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/46.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/46.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/47.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/47.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/48.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/48.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/49.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/49.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/5.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/5.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/50.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/50.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/51.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/51.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/52.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/52.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/53.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/53.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/54.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/54.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/55.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/55.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/56.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/56.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/57.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/57.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/58.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/58.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/59.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/59.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/6.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/6.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/60.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/60.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/61.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/61.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/62.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/62.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/63.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/63.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/64.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/64.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/65.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/65.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/66.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/66.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/67.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/67.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/68.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/68.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/69.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/69.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/7.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/7.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/70.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/70.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/71.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/71.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/8.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/8.gif -------------------------------------------------------------------------------- /src/lib/layui/images/face/9.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/layui/images/face/9.gif -------------------------------------------------------------------------------- /src/lib/layui/lay/all-mobile.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:用于打包移动完整版 4 | @Author:贤心 5 | @License:LGPL 6 | 7 | */ 8 | 9 | layui.define(function(exports){ 10 | exports('layui.mobile', layui.v); 11 | }); 12 | -------------------------------------------------------------------------------- /src/lib/layui/lay/all.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:用于打包PC完整版,即包含layui.js和所有模块的完整合并(该文件不会存在于构建后的目录) 4 | @Author:贤心 5 | @License:LGPL 6 | 7 | */ 8 | 9 | layui.define(function(exports){ 10 | var cache = layui.cache; 11 | layui.config({ 12 | dir: cache.dir.replace(/lay\/dest\/$/, '') 13 | }); 14 | exports('layui.all', layui.v); 15 | }); 16 | -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/code.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:layui.code 代码修饰器 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | layui.define('jquery', function(exports){ 10 | "use strict"; 11 | 12 | var $ = layui.$; 13 | var about = 'http://www.layui.com/doc/modules/code.html'; //关于信息 14 | 15 | exports('code', function(options){ 16 | var elems = []; 17 | options = options || {}; 18 | options.elem = $(options.elem||'.layui-code'); 19 | options.about = 'about' in options ? options.about : true; 20 | 21 | options.elem.each(function(){ 22 | elems.push(this); 23 | }); 24 | 25 | layui.each(elems.reverse(), function(index, item){ 26 | var othis = $(item), html = othis.html(); 27 | 28 | //转义HTML标签 29 | if(othis.attr('lay-encode') || options.encode){ 30 | html = html.replace(/&(?!#?[a-zA-Z0-9]+;)/g, '&') 31 | .replace(//g, '>').replace(/'/g, ''').replace(/"/g, '"') 32 | } 33 | 34 | othis.html('
  1. ' + html.replace(/[\r\t\n]+/g, '
  2. ') + '
') 35 | 36 | if(!othis.find('>.layui-code-h3')[0]){ 37 | othis.prepend('

'+ (othis.attr('lay-title')||options.title||'code') + (options.about ? 'layui.code' : '') + '

'); 38 | } 39 | 40 | var ol = othis.find('>.layui-code-ol'); 41 | othis.addClass('layui-box layui-code-view'); 42 | 43 | //识别皮肤 44 | if(othis.attr('lay-skin') || options.skin){ 45 | othis.addClass('layui-code-' +(othis.attr('lay-skin') || options.skin)); 46 | } 47 | 48 | //按行数适配左边距 49 | if((ol.find('li').length/100|0) > 0){ 50 | ol.css('margin-left', (ol.find('li').length/100|0) + 'px'); 51 | } 52 | 53 | //设置最大高度 54 | if(othis.attr('lay-height') || options.height){ 55 | ol.css('max-height', othis.attr('lay-height') || options.height); 56 | } 57 | 58 | }); 59 | 60 | }); 61 | }).addcss('modules/code.css', 'skincodecss'); -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/flow.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:layui.flow 流加载 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | 10 | layui.define('jquery', function(exports){ 11 | "use strict"; 12 | 13 | var $ = layui.$, Flow = function(options){} 14 | ,ELEM_MORE = 'layui-flow-more' 15 | ,ELEM_LOAD = ''; 16 | 17 | //主方法 18 | Flow.prototype.load = function(options){ 19 | var that = this, page = 0, lock, isOver, lazyimg, timer; 20 | options = options || {}; 21 | 22 | var elem = $(options.elem); if(!elem[0]) return; 23 | var scrollElem = $(options.scrollElem || document); //滚动条所在元素 24 | var mb = options.mb || 50; //与底部的临界距离 25 | var isAuto = 'isAuto' in options ? options.isAuto : true; //是否自动滚动加载 26 | var end = options.end || '没有更多了'; //“末页”显示文案 27 | 28 | //滚动条所在元素是否为document 29 | var notDocment = options.scrollElem && options.scrollElem !== document; 30 | 31 | //加载更多 32 | var ELEM_TEXT = '加载更多' 33 | ,more = $('
'+ ELEM_TEXT +'
'); 34 | 35 | if(!elem.find('.layui-flow-more')[0]){ 36 | elem.append(more); 37 | } 38 | 39 | //加载下一个元素 40 | var next = function(html, over){ 41 | html = $(html); 42 | more.before(html); 43 | over = over == 0 ? true : null; 44 | over ? more.html(end) : more.find('a').html(ELEM_TEXT); 45 | isOver = over; 46 | lock = null; 47 | lazyimg && lazyimg(); 48 | }; 49 | 50 | //触发请求 51 | var done = function(){ 52 | lock = true; 53 | more.find('a').html(ELEM_LOAD); 54 | typeof options.done === 'function' && options.done(++page, next); 55 | }; 56 | 57 | done(); 58 | 59 | //不自动滚动加载 60 | more.find('a').on('click', function(){ 61 | var othis = $(this); 62 | if(isOver) return; 63 | lock || done(); 64 | }); 65 | 66 | //如果允许图片懒加载 67 | if(options.isLazyimg){ 68 | var lazyimg = that.lazyimg({ 69 | elem: options.elem + ' img' 70 | ,scrollElem: options.scrollElem 71 | }); 72 | } 73 | 74 | if(!isAuto) return that; 75 | 76 | scrollElem.on('scroll', function(){ 77 | var othis = $(this), top = othis.scrollTop(); 78 | 79 | if(timer) clearTimeout(timer); 80 | if(isOver) return; 81 | 82 | timer = setTimeout(function(){ 83 | //计算滚动所在容器的可视高度 84 | var height = notDocment ? othis.height() : $(window).height(); 85 | 86 | //计算滚动所在容器的实际高度 87 | var scrollHeight = notDocment 88 | ? othis.prop('scrollHeight') 89 | : document.documentElement.scrollHeight; 90 | 91 | //临界点 92 | if(scrollHeight - top - height <= mb){ 93 | lock || done(); 94 | } 95 | }, 100); 96 | }); 97 | return that; 98 | }; 99 | 100 | //图片懒加载 101 | Flow.prototype.lazyimg = function(options){ 102 | var that = this, index = 0, haveScroll; 103 | options = options || {}; 104 | 105 | var scrollElem = $(options.scrollElem || document); //滚动条所在元素 106 | var elem = options.elem || 'img'; 107 | 108 | //滚动条所在元素是否为document 109 | var notDocment = options.scrollElem && options.scrollElem !== document; 110 | 111 | //显示图片 112 | var show = function(item, height){ 113 | var start = scrollElem.scrollTop(), end = start + height; 114 | var elemTop = notDocment ? function(){ 115 | return item.offset().top - scrollElem.offset().top + start; 116 | }() : item.offset().top; 117 | 118 | /* 始终只加载在当前屏范围内的图片 */ 119 | if(elemTop >= start && elemTop <= end){ 120 | if(!item.attr('src')){ 121 | var src = item.attr('lay-src'); 122 | layui.img(src, function(){ 123 | var next = that.lazyimg.elem.eq(index); 124 | item.attr('src', src).removeAttr('lay-src'); 125 | 126 | /* 当前图片加载就绪后,检测下一个图片是否在当前屏 */ 127 | next[0] && render(next); 128 | index++; 129 | }); 130 | } 131 | } 132 | }, render = function(othis, scroll){ 133 | 134 | //计算滚动所在容器的可视高度 135 | var height = notDocment ? (scroll||scrollElem).height() : $(window).height(); 136 | var start = scrollElem.scrollTop(), end = start + height; 137 | 138 | that.lazyimg.elem = $(elem); 139 | 140 | if(othis){ 141 | show(othis, height); 142 | } else { 143 | //计算未加载过的图片 144 | for(var i = 0; i < that.lazyimg.elem.length; i++){ 145 | var item = that.lazyimg.elem.eq(i), elemTop = notDocment ? function(){ 146 | return item.offset().top - scrollElem.offset().top + start; 147 | }() : item.offset().top; 148 | 149 | show(item, height); 150 | index = i; 151 | 152 | //如果图片的top坐标,超出了当前屏,则终止后续图片的遍历 153 | if(elemTop > end) break; 154 | } 155 | } 156 | }; 157 | 158 | render(); 159 | 160 | if(!haveScroll){ 161 | var timer; 162 | scrollElem.on('scroll', function(){ 163 | var othis = $(this); 164 | if(timer) clearTimeout(timer) 165 | timer = setTimeout(function(){ 166 | render(null, othis); 167 | }, 50); 168 | }); 169 | haveScroll = true; 170 | } 171 | return render; 172 | }; 173 | 174 | //暴露接口 175 | exports('flow', new Flow()); 176 | }); 177 | -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/laytpl.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name : layui.laytpl 模板引擎 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | layui.define(function(exports){ 10 | 11 | "use strict"; 12 | 13 | var config = { 14 | open: '{{', 15 | close: '}}' 16 | }; 17 | 18 | var tool = { 19 | exp: function(str){ 20 | return new RegExp(str, 'g'); 21 | }, 22 | //匹配满足规则内容 23 | query: function(type, _, __){ 24 | var types = [ 25 | '#([\\s\\S])+?', //js语句 26 | '([^{#}])*?' //普通字段 27 | ][type || 0]; 28 | return exp((_||'') + config.open + types + config.close + (__||'')); 29 | }, 30 | escape: function(html){ 31 | return String(html||'').replace(/&(?!#?[a-zA-Z0-9]+;)/g, '&') 32 | .replace(//g, '>').replace(/'/g, ''').replace(/"/g, '"'); 33 | }, 34 | error: function(e, tplog){ 35 | var error = 'Laytpl Error:'; 36 | typeof console === 'object' && console.error(error + e + '\n'+ (tplog || '')); 37 | return error + e; 38 | } 39 | }; 40 | 41 | var exp = tool.exp, Tpl = function(tpl){ 42 | this.tpl = tpl; 43 | }; 44 | 45 | Tpl.pt = Tpl.prototype; 46 | 47 | window.errors = 0; 48 | 49 | //编译模版 50 | Tpl.pt.parse = function(tpl, data){ 51 | var that = this, tplog = tpl; 52 | var jss = exp('^'+config.open+'#', ''), jsse = exp(config.close+'$', ''); 53 | 54 | tpl = tpl.replace(/\s+|\r|\t|\n/g, ' ') 55 | .replace(exp(config.open+'#'), config.open+'# ') 56 | .replace(exp(config.close+'}'), '} '+config.close).replace(/\\/g, '\\\\') 57 | 58 | //不匹配指定区域的内容 59 | .replace(exp(config.open + '!(.+?)!' + config.close), function(str){ 60 | str = str.replace(exp('^'+ config.open + '!'), '') 61 | .replace(exp('!'+ config.close), '') 62 | .replace(exp(config.open + '|' + config.close), function(tag){ 63 | return tag.replace(/(.)/g, '\\$1') 64 | }); 65 | return str 66 | }) 67 | 68 | //匹配JS规则内容 69 | .replace(/(?="|')/g, '\\').replace(tool.query(), function(str){ 70 | str = str.replace(jss, '').replace(jsse, ''); 71 | return '";' + str.replace(/\\/g, '') + ';view+="'; 72 | }) 73 | 74 | //匹配普通字段 75 | .replace(tool.query(1), function(str){ 76 | var start = '"+('; 77 | if(str.replace(/\s/g, '') === config.open+config.close){ 78 | return ''; 79 | } 80 | str = str.replace(exp(config.open+'|'+config.close), ''); 81 | if(/^=/.test(str)){ 82 | str = str.replace(/^=/, ''); 83 | start = '"+_escape_('; 84 | } 85 | return start + str.replace(/\\/g, '') + ')+"'; 86 | }); 87 | 88 | tpl = '"use strict";var view = "' + tpl + '";return view;'; 89 | 90 | try{ 91 | that.cache = tpl = new Function('d, _escape_', tpl); 92 | return tpl(data, tool.escape); 93 | } catch(e){ 94 | delete that.cache; 95 | return tool.error(e, tplog); 96 | } 97 | }; 98 | 99 | Tpl.pt.render = function(data, callback){ 100 | var that = this, tpl; 101 | if(!data) return tool.error('no data'); 102 | tpl = that.cache ? that.cache(data, tool.escape) : that.parse(that.tpl, data); 103 | if(!callback) return tpl; 104 | callback(tpl); 105 | }; 106 | 107 | var laytpl = function(tpl){ 108 | if(typeof tpl !== 'string') return tool.error('Template not found'); 109 | return new Tpl(tpl); 110 | }; 111 | 112 | laytpl.config = function(options){ 113 | options = options || {}; 114 | for(var i in options){ 115 | config[i] = options[i]; 116 | } 117 | }; 118 | 119 | laytpl.v = '1.2.0'; 120 | 121 | exports('laytpl', laytpl); 122 | 123 | }); -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/mobile.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:layui 移动模块入口 | 构建后则为移动模块集合 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | 10 | if(!layui['layui.mobile']){ 11 | layui.config({ 12 | base: layui.cache.dir + 'lay/modules/mobile/' 13 | }).extend({ 14 | 'layer-mobile': 'layer-mobile' 15 | ,'zepto': 'zepto' 16 | ,'upload-mobile': 'upload-mobile' 17 | ,'layim-mobile': 'layim-mobile' 18 | }); 19 | } 20 | 21 | layui.define([ 22 | 'layer-mobile' 23 | ,'zepto' 24 | ,'layim-mobile' 25 | ], function(exports){ 26 | exports('mobile', { 27 | layer: layui['layer-mobile'] //弹层 28 | ,layim: layui['layim-mobile'] //WebIM 29 | }); 30 | }); -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/mobile/layer-mobile.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | @Name:layer mobile v2.0.0 弹层组件移动版 4 | @Author:贤心 5 | @Site:http://layer.layui.com/mobie/ 6 | @License:MIT 7 | 8 | */ 9 | 10 | layui.define(function(exports){ 11 | 12 | "use strict"; 13 | 14 | var win = window, doc = document, query = 'querySelectorAll', claname = 'getElementsByClassName', S = function(s){ 15 | return doc[query](s); 16 | }; 17 | 18 | //默认配置 19 | var config = { 20 | type: 0 21 | ,shade: true 22 | ,shadeClose: true 23 | ,fixed: true 24 | ,anim: 'scale' //默认动画类型 25 | }; 26 | 27 | var ready = { 28 | extend: function(obj){ 29 | var newobj = JSON.parse(JSON.stringify(config)); 30 | for(var i in obj){ 31 | newobj[i] = obj[i]; 32 | } 33 | return newobj; 34 | }, 35 | timer: {}, end: {} 36 | }; 37 | 38 | //点触事件 39 | ready.touch = function(elem, fn){ 40 | elem.addEventListener('click', function(e){ 41 | fn.call(this, e); 42 | }, false); 43 | }; 44 | 45 | var index = 0, classs = ['layui-m-layer'], Layer = function(options){ 46 | var that = this; 47 | that.config = ready.extend(options); 48 | that.view(); 49 | }; 50 | 51 | Layer.prototype.view = function(){ 52 | var that = this, config = that.config, layerbox = doc.createElement('div'); 53 | 54 | that.id = layerbox.id = classs[0] + index; 55 | layerbox.setAttribute('class', classs[0] + ' ' + classs[0]+(config.type || 0)); 56 | layerbox.setAttribute('index', index); 57 | 58 | //标题区域 59 | var title = (function(){ 60 | var titype = typeof config.title === 'object'; 61 | return config.title 62 | ? '

'+ (titype ? config.title[0] : config.title) +'

' 63 | : ''; 64 | }()); 65 | 66 | //按钮区域 67 | var button = (function(){ 68 | typeof config.btn === 'string' && (config.btn = [config.btn]); 69 | var btns = (config.btn || []).length, btndom; 70 | if(btns === 0 || !config.btn){ 71 | return ''; 72 | } 73 | btndom = ''+ config.btn[0] +'' 74 | if(btns === 2){ 75 | btndom = ''+ config.btn[1] +'' + btndom; 76 | } 77 | return '
'+ btndom + '
'; 78 | }()); 79 | 80 | if(!config.fixed){ 81 | config.top = config.hasOwnProperty('top') ? config.top : 100; 82 | config.style = config.style || ''; 83 | config.style += ' top:'+ ( doc.body.scrollTop + config.top) + 'px'; 84 | } 85 | 86 | if(config.type === 2){ 87 | config.content = '

'+ (config.content||'') +'

'; 88 | } 89 | 90 | if(config.skin) config.anim = 'up'; 91 | if(config.skin === 'msg') config.shade = false; 92 | 93 | layerbox.innerHTML = (config.shade ? '
' : '') 94 | +'
' 95 | +'
' 96 | +'
' 97 | + title 98 | +'
'+ config.content +'
' 99 | + button 100 | +'
' 101 | +'
' 102 | +'
'; 103 | 104 | if(!config.type || config.type === 2){ 105 | var dialogs = doc[claname](classs[0] + config.type), dialen = dialogs.length; 106 | if(dialen >= 1){ 107 | layer.close(dialogs[0].getAttribute('index')) 108 | } 109 | } 110 | 111 | document.body.appendChild(layerbox); 112 | var elem = that.elem = S('#'+that.id)[0]; 113 | config.success && config.success(elem); 114 | 115 | that.index = index++; 116 | that.action(config, elem); 117 | }; 118 | 119 | Layer.prototype.action = function(config, elem){ 120 | var that = this; 121 | 122 | //自动关闭 123 | if(config.time){ 124 | ready.timer[that.index] = setTimeout(function(){ 125 | layer.close(that.index); 126 | }, config.time*1000); 127 | } 128 | 129 | //确认取消 130 | var btn = function(){ 131 | var type = this.getAttribute('type'); 132 | if(type == 0){ 133 | config.no && config.no(); 134 | layer.close(that.index); 135 | } else { 136 | config.yes ? config.yes(that.index) : layer.close(that.index); 137 | } 138 | }; 139 | if(config.btn){ 140 | var btns = elem[claname]('layui-m-layerbtn')[0].children, btnlen = btns.length; 141 | for(var ii = 0; ii < btnlen; ii++){ 142 | ready.touch(btns[ii], btn); 143 | } 144 | } 145 | 146 | //点遮罩关闭 147 | if(config.shade && config.shadeClose){ 148 | var shade = elem[claname]('layui-m-layershade')[0]; 149 | ready.touch(shade, function(){ 150 | layer.close(that.index, config.end); 151 | }); 152 | } 153 | 154 | config.end && (ready.end[that.index] = config.end); 155 | }; 156 | 157 | var layer = { 158 | v: '2.0 m', 159 | index: index, 160 | 161 | //核心方法 162 | open: function(options){ 163 | var o = new Layer(options || {}); 164 | return o.index; 165 | }, 166 | 167 | close: function(index){ 168 | var ibox = S('#'+classs[0]+index)[0]; 169 | if(!ibox) return; 170 | ibox.innerHTML = ''; 171 | doc.body.removeChild(ibox); 172 | clearTimeout(ready.timer[index]); 173 | delete ready.timer[index]; 174 | typeof ready.end[index] === 'function' && ready.end[index](); 175 | delete ready.end[index]; 176 | }, 177 | 178 | //关闭所有layer层 179 | closeAll: function(){ 180 | var boxs = doc[claname](classs[0]); 181 | for(var i = 0, len = boxs.length; i < len; i++){ 182 | layer.close((boxs[0].getAttribute('index')|0)); 183 | } 184 | } 185 | }; 186 | 187 | exports('layer-mobile', layer); 188 | 189 | }); -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/mobile/layim-mobile-open.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:layim mobile 开源包 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | layui.define(function(exports){ 10 | exports('layim-mobile', layui.v); 11 | }); -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/mobile/upload-mobile.js: -------------------------------------------------------------------------------- 1 | /*! 2 | 3 | @Title: layui.upload 单文件上传 - 全浏览器兼容版 4 | @Author: 贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | layui.define(['layer-mobile', 'zepto'] , function(exports){ 10 | "use strict"; 11 | 12 | var $ = layui.zepto; 13 | var layer = layui['layer-mobile']; 14 | var device = layui.device(); 15 | 16 | var elemDragEnter = 'layui-upload-enter'; 17 | var elemIframe = 'layui-upload-iframe'; 18 | 19 | var msgConf = { 20 | icon: 2 21 | ,shift: 6 22 | }, fileType = { 23 | file: '文件' 24 | ,video: '视频' 25 | ,audio: '音频' 26 | }; 27 | 28 | layer.msg = function(content){ 29 | return layer.open({ 30 | content: content || '' 31 | ,skin: 'msg' 32 | ,time: 2 //2秒后自动关闭 33 | }); 34 | }; 35 | 36 | var Upload = function(options){ 37 | this.options = options; 38 | }; 39 | 40 | //初始化渲染 41 | Upload.prototype.init = function(){ 42 | var that = this, options = that.options; 43 | var body = $('body'), elem = $(options.elem || '.layui-upload-file'); 44 | var iframe = $(''); 45 | 46 | //插入iframe 47 | $('#'+elemIframe)[0] || body.append(iframe); 48 | 49 | return elem.each(function(index, item){ 50 | item = $(item); 51 | var form = '
'; 52 | 53 | var type = item.attr('lay-type') || options.type; //获取文件类型 54 | 55 | //包裹ui元素 56 | if(!options.unwrap){ 57 | form = '
' + form + ''+ ( 58 | item.attr('lay-title') || options.title|| ('上传'+ (fileType[type]||'图片') ) 59 | ) +'
'; 60 | } 61 | 62 | form = $(form); 63 | 64 | //拖拽支持 65 | if(!options.unwrap){ 66 | form.on('dragover', function(e){ 67 | e.preventDefault(); 68 | $(this).addClass(elemDragEnter); 69 | }).on('dragleave', function(){ 70 | $(this).removeClass(elemDragEnter); 71 | }).on('drop', function(){ 72 | $(this).removeClass(elemDragEnter); 73 | }); 74 | } 75 | 76 | //如果已经实例化,则移除包裹元素 77 | if(item.parent('form').attr('target') === elemIframe){ 78 | if(options.unwrap){ 79 | item.unwrap(); 80 | } else { 81 | item.parent().next().remove(); 82 | item.unwrap().unwrap(); 83 | } 84 | }; 85 | 86 | //包裹元素 87 | item.wrap(form); 88 | 89 | //触发上传 90 | item.off('change').on('change', function(){ 91 | that.action(this, type); 92 | }); 93 | }); 94 | }; 95 | 96 | //提交上传 97 | Upload.prototype.action = function(input, type){ 98 | var that = this, options = that.options, val = input.value; 99 | var item = $(input), ext = item.attr('lay-ext') || options.ext || ''; //获取支持上传的文件扩展名; 100 | 101 | if(!val){ 102 | return; 103 | }; 104 | 105 | //校验文件 106 | switch(type){ 107 | case 'file': //一般文件 108 | if(ext && !RegExp('\\w\\.('+ ext +')$', 'i').test(escape(val))){ 109 | layer.msg('不支持该文件格式', msgConf); 110 | return input.value = ''; 111 | } 112 | break; 113 | case 'video': //视频文件 114 | if(!RegExp('\\w\\.('+ (ext||'avi|mp4|wma|rmvb|rm|flash|3gp|flv') +')$', 'i').test(escape(val))){ 115 | layer.msg('不支持该视频格式', msgConf); 116 | return input.value = ''; 117 | } 118 | break; 119 | case 'audio': //音频文件 120 | if(!RegExp('\\w\\.('+ (ext||'mp3|wav|mid') +')$', 'i').test(escape(val))){ 121 | layer.msg('不支持该音频格式', msgConf); 122 | return input.value = ''; 123 | } 124 | break; 125 | default: //图片文件 126 | if(!RegExp('\\w\\.('+ (ext||'jpg|png|gif|bmp|jpeg') +')$', 'i').test(escape(val))){ 127 | layer.msg('不支持该图片格式', msgConf); 128 | return input.value = ''; 129 | } 130 | break; 131 | } 132 | 133 | options.before && options.before(input); 134 | item.parent().submit(); 135 | 136 | var iframe = $('#'+elemIframe), timer = setInterval(function() { 137 | var res; 138 | try { 139 | res = iframe.contents().find('body').text(); 140 | } catch(e) { 141 | layer.msg('上传接口存在跨域', msgConf); 142 | clearInterval(timer); 143 | } 144 | if(res){ 145 | clearInterval(timer); 146 | iframe.contents().find('body').html(''); 147 | try { 148 | res = JSON.parse(res); 149 | } catch(e){ 150 | res = {}; 151 | return layer.msg('请对上传接口返回JSON字符', msgConf); 152 | } 153 | typeof options.success === 'function' && options.success(res, input); 154 | } 155 | }, 30); 156 | 157 | input.value = ''; 158 | }; 159 | 160 | //暴露接口 161 | exports('upload-mobile', function(options){ 162 | var upload = new Upload(options = options || {}); 163 | upload.init(); 164 | }); 165 | }); 166 | 167 | -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/tree.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:layui.tree 树组件 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | 10 | layui.define('jquery', function(exports){ 11 | "use strict"; 12 | 13 | var $ = layui.$ 14 | ,hint = layui.hint(); 15 | 16 | var enterSkin = 'layui-tree-enter', Tree = function(options){ 17 | this.options = options; 18 | }; 19 | 20 | //图标 21 | var icon = { 22 | arrow: ['', ''] //箭头 23 | ,checkbox: ['', ''] //复选框 24 | ,radio: ['', ''] //单选框 25 | ,branch: ['', ''] //父节点 26 | ,leaf: '' //叶节点 27 | }; 28 | 29 | //初始化 30 | Tree.prototype.init = function(elem){ 31 | var that = this; 32 | elem.addClass('layui-box layui-tree'); //添加tree样式 33 | if(that.options.skin){ 34 | elem.addClass('layui-tree-skin-'+ that.options.skin); 35 | } 36 | that.tree(elem); 37 | that.on(elem); 38 | }; 39 | 40 | //树节点解析 41 | Tree.prototype.tree = function(elem, children){ 42 | var that = this, options = that.options 43 | var nodes = children || options.nodes; 44 | 45 | layui.each(nodes, function(index, item){ 46 | var hasChild = item.children && item.children.length > 0; 47 | var ul = $(''); 48 | var li = $(['
  • ' 49 | //展开箭头 50 | ,function(){ 51 | return hasChild ? ''+ ( 52 | item.spread ? icon.arrow[1] : icon.arrow[0] 53 | ) +'' : ''; 54 | }() 55 | 56 | //复选框/单选框 57 | ,function(){ 58 | return options.check ? ( 59 | ''+ ( 60 | options.check === 'checkbox' ? icon.checkbox[0] : ( 61 | options.check === 'radio' ? icon.radio[0] : '' 62 | ) 63 | ) +'' 64 | ) : ''; 65 | }() 66 | 67 | //节点 68 | ,function(){ 69 | return '' 72 | + (''+ ( 73 | hasChild ? ( 74 | item.spread ? icon.branch[1] : icon.branch[0] 75 | ) : icon.leaf 76 | ) +'') //节点图标 77 | + (''+ (item.name||'未命名') +''); 78 | }() 79 | 80 | ,'
  • '].join('')); 81 | 82 | //如果有子节点,则递归继续生成树 83 | if(hasChild){ 84 | li.append(ul); 85 | that.tree(ul, item.children); 86 | } 87 | 88 | elem.append(li); 89 | 90 | //触发点击节点回调 91 | typeof options.click === 'function' && that.click(li, item); 92 | 93 | //伸展节点 94 | that.spread(li, item); 95 | 96 | //拖拽节点 97 | options.drag && that.drag(li, item); 98 | }); 99 | }; 100 | 101 | //点击节点回调 102 | Tree.prototype.click = function(elem, item){ 103 | var that = this, options = that.options; 104 | elem.children('a').on('click', function(e){ 105 | layui.stope(e); 106 | options.click(item) 107 | }); 108 | }; 109 | 110 | //伸展节点 111 | Tree.prototype.spread = function(elem, item){ 112 | var that = this, options = that.options; 113 | var arrow = elem.children('.layui-tree-spread') 114 | var ul = elem.children('ul'), a = elem.children('a'); 115 | 116 | //执行伸展 117 | var open = function(){ 118 | if(elem.data('spread')){ 119 | elem.data('spread', null) 120 | ul.removeClass('layui-show'); 121 | arrow.html(icon.arrow[0]); 122 | a.find('.layui-icon').html(icon.branch[0]); 123 | } else { 124 | elem.data('spread', true); 125 | ul.addClass('layui-show'); 126 | arrow.html(icon.arrow[1]); 127 | a.find('.layui-icon').html(icon.branch[1]); 128 | } 129 | }; 130 | 131 | //如果没有子节点,则不执行 132 | if(!ul[0]) return; 133 | 134 | arrow.on('click', open); 135 | a.on('dblclick', open); 136 | } 137 | 138 | //通用事件 139 | Tree.prototype.on = function(elem){ 140 | var that = this, options = that.options; 141 | var dragStr = 'layui-tree-drag'; 142 | 143 | //屏蔽选中文字 144 | elem.find('i').on('selectstart', function(e){ 145 | return false 146 | }); 147 | 148 | //拖拽 149 | if(options.drag){ 150 | $(document).on('mousemove', function(e){ 151 | var move = that.move; 152 | if(move.from){ 153 | var to = move.to, treeMove = $('
    '); 154 | e.preventDefault(); 155 | $('.' + dragStr)[0] || $('body').append(treeMove); 156 | var dragElem = $('.' + dragStr)[0] ? $('.' + dragStr) : treeMove; 157 | (dragElem).addClass('layui-show').html(move.from.elem.children('a').html()); 158 | dragElem.css({ 159 | left: e.pageX + 10 160 | ,top: e.pageY + 10 161 | }) 162 | } 163 | }).on('mouseup', function(){ 164 | var move = that.move; 165 | if(move.from){ 166 | move.from.elem.children('a').removeClass(enterSkin); 167 | move.to && move.to.elem.children('a').removeClass(enterSkin); 168 | that.move = {}; 169 | $('.' + dragStr).remove(); 170 | } 171 | }); 172 | } 173 | }; 174 | 175 | //拖拽节点 176 | Tree.prototype.move = {}; 177 | Tree.prototype.drag = function(elem, item){ 178 | var that = this, options = that.options; 179 | var a = elem.children('a'), mouseenter = function(){ 180 | var othis = $(this), move = that.move; 181 | if(move.from){ 182 | move.to = { 183 | item: item 184 | ,elem: elem 185 | }; 186 | othis.addClass(enterSkin); 187 | } 188 | }; 189 | a.on('mousedown', function(){ 190 | var move = that.move 191 | move.from = { 192 | item: item 193 | ,elem: elem 194 | }; 195 | }); 196 | a.on('mouseenter', mouseenter).on('mousemove', mouseenter) 197 | .on('mouseleave', function(){ 198 | var othis = $(this), move = that.move; 199 | if(move.from){ 200 | delete move.to; 201 | othis.removeClass(enterSkin); 202 | } 203 | }); 204 | }; 205 | 206 | //暴露接口 207 | exports('tree', function(options){ 208 | var tree = new Tree(options = options || {}); 209 | var elem = $(options.elem); 210 | if(!elem[0]){ 211 | return hint.error('layui.tree 没有找到'+ options.elem +'元素'); 212 | } 213 | tree.init(elem); 214 | }); 215 | }); 216 | -------------------------------------------------------------------------------- /src/lib/layui/lay/modules/util.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:layui.util 工具集 4 | @Author:贤心 5 | @License:MIT 6 | 7 | */ 8 | 9 | layui.define('jquery', function(exports){ 10 | "use strict"; 11 | 12 | var $ = layui.$ 13 | 14 | //外部接口 15 | ,util = { 16 | //固定块 17 | fixbar: function(options){ 18 | var ELEM = 'layui-fixbar', TOP_BAR = 'layui-fixbar-top' 19 | ,dom = $(document), body = $('body') 20 | ,is, timer; 21 | 22 | options = $.extend({ 23 | showHeight: 200 //出现TOP的滚动条高度临界值 24 | }, options); 25 | 26 | options.bar1 = options.bar1 === true ? '' : options.bar1; 27 | options.bar2 = options.bar2 === true ? '' : options.bar2; 28 | options.bgcolor = options.bgcolor ? ('background-color:' + options.bgcolor) : ''; 29 | 30 | var icon = [options.bar1, options.bar2, ''] //图标:信息、问号、TOP 31 | ,elem = $([''].join('')) 36 | ,topBar = elem.find('.'+TOP_BAR) 37 | ,scroll = function(){ 38 | var stop = dom.scrollTop(); 39 | if(stop >= (options.showHeight)){ 40 | is || (topBar.show(), is = 1); 41 | } else { 42 | is && (topBar.hide(), is = 0); 43 | } 44 | }; 45 | if($('.'+ ELEM)[0]) return; 46 | 47 | typeof options.css === 'object' && elem.css(options.css); 48 | body.append(elem), scroll(); 49 | 50 | //bar点击事件 51 | elem.find('li').on('click', function(){ 52 | var othis = $(this), type = othis.attr('lay-type'); 53 | if(type === 'top'){ 54 | $('html,body').animate({ 55 | scrollTop : 0 56 | }, 200); 57 | } 58 | options.click && options.click.call(this, type); 59 | }); 60 | 61 | //Top显示控制 62 | dom.on('scroll', function(){ 63 | clearTimeout(timer); 64 | timer = setTimeout(function(){ 65 | scroll(); 66 | }, 100); 67 | }); 68 | } 69 | 70 | //倒计时 71 | ,countdown: function(endTime, serverTime, callback){ 72 | var that = this 73 | ,type = typeof serverTime === 'function' 74 | ,end = new Date(endTime).getTime() 75 | ,now = new Date((!serverTime || type) ? new Date().getTime() : serverTime).getTime() 76 | ,count = end - now 77 | ,time = [ 78 | Math.floor(count/(1000*60*60*24)) //天 79 | ,Math.floor(count/(1000*60*60)) % 24 //时 80 | ,Math.floor(count/(1000*60)) % 60 //分 81 | ,Math.floor(count/1000) % 60 //秒 82 | ]; 83 | 84 | if(type) callback = serverTime; 85 | 86 | var timer = setTimeout(function(){ 87 | that.countdown(endTime, now + 1000, callback); 88 | }, 1000); 89 | 90 | callback && callback(count > 0 ? time : [0,0,0,0], serverTime, timer); 91 | 92 | if(count <= 0) clearTimeout(timer); 93 | return timer; 94 | } 95 | 96 | //某个时间在当前时间的多久前 97 | ,timeAgo: function(time, onlyDate){ 98 | var that = this 99 | ,arr = [[], []] 100 | ,stamp = new Date().getTime() - new Date(time).getTime(); 101 | 102 | //返回具体日期 103 | if(stamp > 1000*60*60*24*8){ 104 | stamp = new Date(time); 105 | arr[0][0] = that.digit(stamp.getFullYear(), 4); 106 | arr[0][1] = that.digit(stamp.getMonth() + 1); 107 | arr[0][2] = that.digit(stamp.getDate()); 108 | 109 | //是否输出时间 110 | if(!onlyDate){ 111 | arr[1][0] = that.digit(stamp.getHours()); 112 | arr[1][1] = that.digit(stamp.getMinutes()); 113 | arr[1][2] = that.digit(stamp.getSeconds()); 114 | } 115 | return arr[0].join('-') + ' ' + arr[1].join(':'); 116 | } 117 | 118 | //30天以内,返回“多久前” 119 | if(stamp >= 1000*60*60*24){ 120 | return ((stamp/1000/60/60/24)|0) + '天前'; 121 | } else if(stamp >= 1000*60*60){ 122 | return ((stamp/1000/60/60)|0) + '小时前'; 123 | } else if(stamp >= 1000*60*2){ //2分钟以内为:刚刚 124 | return ((stamp/1000/60)|0) + '分钟前'; 125 | } else if(stamp < 0){ 126 | return '未来'; 127 | } else { 128 | return '刚刚'; 129 | } 130 | } 131 | 132 | //数字前置补零 133 | ,digit: function(num, length){ 134 | var str = ''; 135 | num = String(num); 136 | length = length || 2; 137 | for(var i = num.length; i < length; i++){ 138 | str += '0'; 139 | } 140 | return num < Math.pow(10, length) ? str + (num|0) : num; 141 | } 142 | 143 | //转化为日期格式字符 144 | ,toDateString: function(time, format){ 145 | var that = this 146 | ,date = new Date(time || new Date()) 147 | ,ymd = [ 148 | that.digit(date.getFullYear(), 4) 149 | ,that.digit(date.getMonth() + 1) 150 | ,that.digit(date.getDate()) 151 | ] 152 | ,hms = [ 153 | that.digit(date.getHours()) 154 | ,that.digit(date.getMinutes()) 155 | ,that.digit(date.getSeconds()) 156 | ]; 157 | 158 | format = format || 'yyyy-MM-dd HH:mm:ss'; 159 | 160 | return format.replace(/yyyy/g, ymd[0]) 161 | .replace(/MM/g, ymd[1]) 162 | .replace(/dd/g, ymd[2]) 163 | .replace(/HH/g, hms[0]) 164 | .replace(/mm/g, hms[1]) 165 | .replace(/ss/g, hms[2]); 166 | } 167 | }; 168 | 169 | exports('util', util); 170 | }); -------------------------------------------------------------------------------- /src/lib/winui/audio/236.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/winui/audio/236.mp3 -------------------------------------------------------------------------------- /src/lib/winui/audio/236.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/winui/audio/236.wav -------------------------------------------------------------------------------- /src/lib/winui/audio/5885.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/winui/audio/5885.mp3 -------------------------------------------------------------------------------- /src/lib/winui/audio/5885.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/winui/audio/5885.wav -------------------------------------------------------------------------------- /src/lib/winui/css/helper.css: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name: winui 4 | @Author: Leo 5 | @Site: www.leo96.com 6 | 7 | */ 8 | 9 | /*皮肤*/ 10 | body .layer-ext-winhelper { 11 | min-width: 258px; 12 | border: 1px solid rgba(255, 255, 255, 0.1); 13 | } 14 | 15 | body .layer-ext-winhelper * { 16 | font-size: 12px; 17 | } 18 | 19 | body .layer-ext-winhelper .layui-layer-title { 20 | height: 37px; 21 | line-height: 37px; 22 | background-color: transparent; 23 | color: #fff; 24 | border-bottom: none; 25 | padding: 0 80px 0 10px; 26 | } 27 | 28 | body .layer-ext-hprsettings { 29 | border: 1px solid rgba(255, 255, 255, 0.1); 30 | } 31 | 32 | body .layer-ext-hprsettings * { 33 | font-size: 12px; 34 | cursor: default; 35 | } 36 | 37 | body .layer-ext-hprsettings .layui-layer-title { 38 | height: 30px; 39 | line-height: 30px; 40 | background-color: transparent; 41 | color: #7b7b7b; 42 | border-bottom: none; 43 | padding: 0 80px 0 10px; 44 | } 45 | 46 | body .layer-ext-hprsettings .layui-layer-setwin { 47 | top: 8px; 48 | right: 10px; 49 | } 50 | 51 | body .layer-ext-hprsettings .layui-layer-setwin .layui-layer-close1 { 52 | cursor: default; 53 | } 54 | /*皮肤End*/ 55 | .winui-helper-content { 56 | padding: 0 10px; 57 | } 58 | 59 | .winui-helper-content hr { 60 | margin: 0; 61 | background-color: rgba(255, 255, 255, 0.4); 62 | } 63 | 64 | .winui-helper-content .winui-helper-tool { 65 | padding: 8px 0; 66 | width: 238px; 67 | } 68 | 69 | .winui-helper-content .winui-helper-tool > span { 70 | color: rgba(255, 255, 255, 0.8); 71 | margin: 5px; 72 | cursor: default; 73 | display: inline-block; 74 | } 75 | 76 | .winui-helper-content .winui-helper-tool > span:hover { 77 | color: #ffffff; 78 | } 79 | 80 | .winui-helper-content .winui-helper-tool > span:nth-child(8n+1) { 81 | margin-left: 2px; 82 | } 83 | 84 | .winui-helper-content .winui-helper-tool > span:nth-child(8n) { 85 | margin-right: 1px; 86 | } 87 | 88 | .winui-helper-content .winui-helper-tool > span > i { 89 | font-size: 16px; 90 | } 91 | 92 | .winui-helper-setwin { 93 | position: absolute; 94 | right: 10px; 95 | top: 8px; 96 | font-size: 0; 97 | line-height: initial; 98 | } 99 | 100 | .winui-helper-setwin a { 101 | position: relative; 102 | width: 20px; 103 | height: 20px; 104 | margin-left: 5px; 105 | font-size: 12px; 106 | color: #ffffff; 107 | display: inline-block; 108 | line-height: 20px; 109 | text-align: center; 110 | -moz-box-sizing: border-box; 111 | -webkit-box-sizing: border-box; 112 | box-sizing: border-box; 113 | border: 1px solid transparent; 114 | } 115 | 116 | .winui-helper-setwin a:hover { 117 | border: 1px solid rgba(255, 255, 255, 0.4); 118 | } 119 | 120 | .winui-helper-setwin .winui-helper-switch i { 121 | bottom: 1px; 122 | position: relative; 123 | } 124 | 125 | body .winui-helper-tips .layui-layer-content { 126 | color: #000000; 127 | padding: 3px 5px; 128 | } 129 | 130 | .tags-content { 131 | margin: 10px 0; 132 | } 133 | 134 | .tags-content textarea { 135 | display: block; 136 | width: 238px; 137 | height: 72px; 138 | min-width: 238px; 139 | min-height: 72px; 140 | line-height: 20px; 141 | padding: 6px; 142 | border: none; 143 | box-sizing: border-box; 144 | background-color: rgba(255,255,255,0.1); 145 | color: rgba(255, 255, 255, 0.8); 146 | word-wrap: break-word; 147 | /*cursor: default;*/ 148 | } 149 | 150 | .tags-content textarea::-webkit-input-placeholder { 151 | color: #949494; 152 | } 153 | 154 | .tags-content textarea:-moz-placeholder { 155 | color: #ddd; 156 | } 157 | 158 | .tags-content textarea::-moz-placeholder { 159 | color: #ddd; 160 | } 161 | 162 | .tags-content textarea:-ms-input-placeholder { 163 | color: #ddd; 164 | } 165 | 166 | 167 | .helper-menu { 168 | width: 160px; 169 | padding: 2px; 170 | border: 1px solid #dcf0ff; 171 | z-index: 201704011157; 172 | box-sizing: border-box; 173 | background-color: #F0F0F0; 174 | position: fixed; 175 | -moz-box-shadow: 2px 2px 1px #353535; 176 | -webkit-box-shadow: 2px 2px 1px #353535; 177 | box-shadow: 2px 2px 1px #353535; 178 | } 179 | 180 | .helper-menu li { 181 | line-height: 22px; 182 | font-size: 12px; 183 | cursor: default; 184 | padding-left: 34px; 185 | padding-right: 10px; 186 | position: relative; 187 | } 188 | 189 | .helper-menu li:hover { 190 | background-color: #91C9F7; 191 | } 192 | 193 | .helper-menu li i { 194 | position: absolute; 195 | left: 4px; 196 | top: 2px; 197 | padding: 3px 2px; 198 | background-color: #0063B1; 199 | color: #fff; 200 | } 201 | 202 | 203 | /*助手设置页面样式*/ 204 | .winui-hprsetings-content { 205 | padding: 0 10px; 206 | } 207 | 208 | .winui-hprsetings-content .layui-tab { 209 | margin: 0; 210 | } 211 | 212 | .winui-hprsetings-content .layui-tab-title { 213 | height: 30px; 214 | } 215 | 216 | .winui-hprsetings-content .layui-tab-title li { 217 | line-height: 30px; 218 | padding: 0 5px; 219 | } 220 | 221 | .winui-hprsetings-content .layui-tab-title .layui-this:after { 222 | height: 31px; 223 | } 224 | 225 | .winui-hprsetings-content .layui-tab-content { 226 | padding: 20px; 227 | } 228 | 229 | .winui-hprsetings-content .layui-field-box { 230 | padding: 10px; 231 | padding-left: 12px; 232 | } 233 | 234 | .bgcolor-item { 235 | padding: 10px; 236 | -moz-box-sizing: border-box; 237 | -webkit-box-sizing: border-box; 238 | box-sizing: border-box; 239 | border: 1px solid transparent; 240 | display: inline-block; 241 | margin: 1px; 242 | position: relative; 243 | } 244 | 245 | .bgcolor-item:hover { 246 | border: 1px solid #91C9F7; 247 | } 248 | 249 | .bgcolor-item.selected::after { 250 | content: '√'; 251 | width: 16px; 252 | height: 16px; 253 | display: inline-block; 254 | background-color: #5FB878; 255 | position: absolute; 256 | border-radius: 50%; 257 | right: 4px; 258 | bottom: 4px; 259 | color: #fff; 260 | text-indent: 4px; 261 | line-height: 20px; 262 | } 263 | 264 | .bgcolor-item > div { 265 | width: 40px; 266 | height: 40px; 267 | } 268 | 269 | .slidearea { 270 | padding: 10px 0; 271 | } 272 | 273 | .slider { 274 | display: inline-block; 275 | position: absolute; 276 | width: 12px; 277 | height: 12px; 278 | top: -3px; 279 | left: 2px; 280 | border-radius: 50%; 281 | box-shadow: 0px 0px 1px 1px #808080; 282 | background-color: #fff; 283 | } 284 | 285 | #opacity .layui-progress-bar { 286 | -moz-transition: all 0s; 287 | -o-transition: all 0s; 288 | -webkit-transition: all 0s; 289 | transition: all 0s; 290 | } 291 | 292 | 293 | .basic .layui-form-checked[lay-skin="primary"] i { 294 | background-color: #5FB878 !important; 295 | } 296 | .basic .layui-form-checkbox[lay-skin="primary"]:hover i, 297 | .basic .layui-form-checked[lay-skin="primary"] i { 298 | border-color: #5FB878 !important; 299 | } -------------------------------------------------------------------------------- /src/lib/winui/css/lockscreen.css: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name: winui 4 | @Author: Leo 5 | @Site: www.leo96.com 6 | 7 | */ 8 | 9 | .lock-body { 10 | background-color: #000000; 11 | background: center no-repeat fixed; 12 | background-size: cover; 13 | position: fixed; 14 | top: 0; 15 | right: 0; 16 | left: 0; 17 | bottom: 0; 18 | } 19 | 20 | #date_time { 21 | color: white; 22 | position: fixed; 23 | left: 5%; 24 | bottom: 10%; 25 | font-family: Arial; 26 | } 27 | 28 | #time { 29 | font-size: 86px; 30 | } 31 | 32 | #date { 33 | font-size: 30px; 34 | padding-left: 10px; 35 | } 36 | 37 | #login_div { 38 | margin-top: 20vh; 39 | text-align: center; 40 | } 41 | 42 | #login_div > img { 43 | width: 150px; 44 | height: 150px; 45 | box-shadow: 0 0 4px 4px #fff; 46 | background-color: rgba(255, 255, 255, 0.4); 47 | } 48 | 49 | #user_name { 50 | font-size: 46px; 51 | font-weight: 100; 52 | margin: 15px 0; 53 | padding-top: 10px; 54 | color: #fff; 55 | font-family: Arial, Helvetica, sans-serif; 56 | } 57 | 58 | .winui-from-group { 59 | display: inline-block; 60 | width: 288px; 61 | border: 1px solid rgba(255, 255, 255, 0.70); 62 | -moz-box-sizing: border-box; 63 | -webkit-box-sizing: border-box; 64 | box-sizing: border-box; 65 | } 66 | 67 | .winui-from-group input { 68 | width: 250px; 69 | height: 36px; 70 | color: #fff; 71 | border: none; 72 | background: rgba(0, 0, 0, 0.30); 73 | float: left; 74 | padding-left: 5px; 75 | -moz-box-sizing: border-box; 76 | -webkit-box-sizing: border-box; 77 | box-sizing: border-box; 78 | } 79 | 80 | .winui-from-group button { 81 | height: 36px; 82 | width: 36px; 83 | background: rgba(255, 255, 255, 0.40); 84 | border: none; 85 | float: right; 86 | cursor: pointer; 87 | color: #fff; 88 | } 89 | 90 | :-moz-placeholder { /* Mozilla Firefox 4 to 18 */ 91 | color: #fff; 92 | opacity: .8; 93 | } 94 | 95 | ::-moz-placeholder { /* Mozilla Firefox 19+ */ 96 | color: #fff; 97 | opacity: .8; 98 | } 99 | 100 | input:-ms-input-placeholder { 101 | color: #fff; 102 | opacity: .8; 103 | } 104 | 105 | input::-webkit-input-placeholder { 106 | color: #fff; 107 | opacity: .8; 108 | } 109 | -------------------------------------------------------------------------------- /src/lib/winui/html/helper/settings.html: -------------------------------------------------------------------------------- 1 | 
    2 |
    3 | 7 |
    8 |
    9 | 10 |
    11 | 基本设置 12 |
    13 |
    14 | 15 |
    16 |
    17 |
    18 |
    19 |
    20 |
    21 | 背景色 22 |
    23 |
    24 |
    25 |
    26 |
    27 |
    28 |
    29 |
    30 |
    31 |
    32 |
    33 |
    34 |
    35 |
    36 |
    37 |
    38 |
    39 |
    40 |
    41 |
    42 |
    43 |
    44 |
    45 |
    46 |
    47 |
    48 |
    49 |
    50 |
    51 |
    52 |
    53 |
    54 |
    55 |
    56 |
    57 |
    58 |
    59 |
    60 |
    61 |
    62 |
    63 |
    64 |
    65 |
    66 |
    67 |
    68 | 透明度 69 |
    70 |
    71 |
    72 |
    73 | 74 |
    75 |
    76 |
    77 |
    78 |
    79 | 80 |
    81 |
    82 |
    83 |
    84 |
    85 | -------------------------------------------------------------------------------- /src/lib/winui/html/system/lockscreen.html: -------------------------------------------------------------------------------- 1 |  4 |
    5 |
    6 | 7 |

    WinAdmin

    8 |
    9 |
    10 | 11 | 12 |
    13 |
    14 |
    15 |
    16 |
    17 | -------------------------------------------------------------------------------- /src/lib/winui/images/window_ico.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Leo0216/winadmin/57101fdb78fbee1a6df82a93edf3f72b9c66a99b/src/lib/winui/images/window_ico.png -------------------------------------------------------------------------------- /src/lib/winui/js/theme.js: -------------------------------------------------------------------------------- 1 | /** 2 | 3 | @Name:主题设置 4 | @Author:Leo 5 | @License:MIT 6 | 7 | */ 8 | layui.use(['layer', 'form'], function (exports) { 9 | var $ = layui.jquery, form = layui.form, unfinished = '暂未实现'; 10 | 11 | $(function () { 12 | winui.renderColor(); 13 | winui.tab.init(); 14 | //设置预览背景为当前背景 15 | $('.background-preview').css('background-image', layui.jquery('body').css('background-image')); 16 | //设置锁屏预览背景为当前锁屏预览背景 17 | $('.lockscreen-preview').css('background-image', 'url(' + winui.getSetting('lockBgSrc') + ')'); 18 | 19 | //设置主题预览中任务栏位置 20 | var taskbarMode = winui.getSetting('taskbarMode'); 21 | $('.taskbar-position input[value=' + taskbarMode + ']').prop('checked', true); 22 | //设置主题预览中开始菜单尺寸 23 | var startSize = winui.getSetting('startSize'); 24 | $('.start-size input[value=' + startSize + ']').prop('checked', true); 25 | $('.preview-start').removeClass('xs sm lg'); 26 | $('.preview-start').addClass(startSize); 27 | 28 | form.render(); 29 | 30 | //预览锁屏界面 31 | var Week = ['日', '一', '二', '三', '四', '五', '六']; 32 | var dateTime = new Date(); 33 | $('.lockscreen-preview-time').html('

    ' + (dateTime.getHours() > 9 ? dateTime.getHours().toString() : '0' + dateTime.getHours()) + ':' + (dateTime.getMinutes() > 9 ? dateTime.getMinutes().toString() : '0' + dateTime.getMinutes()) + '

    ' + (dateTime.getMonth() + 1) + '月' + dateTime.getDate() + '日,星期' + Week[dateTime.getDay()] + '

    '); 34 | }); 35 | //背景图片点击 36 | $('.background-choose>img').on('click', function () { 37 | //获取当前图片路径 38 | var bgSrc = $(this).prop('src'); 39 | //改变预览背景 40 | $('.background-preview').css('background-image', 'url(' + bgSrc + ')'); 41 | //改变父页面背景 42 | winui.resetBg(bgSrc); 43 | }) 44 | //背景图片上传 45 | $('.background-upload').on('click', function () { 46 | var input = $(this).prev('input[type=file]'); 47 | input.trigger('click'); 48 | input.on('change', function () { 49 | var src = $(this).val(); 50 | if (src) { 51 | layer.msg('选择了路径【' + src + '】下的图片,返回一张性感的Girl给你') 52 | //改变预览背景 53 | $('.background-preview').css('background-image', 'url(images/sexy_girl.jpg)'); 54 | //改变父页面背景 55 | winui.resetBg('images/sexy_girl.jpg'); 56 | 57 | $(this).val('').off('change'); 58 | } 59 | }) 60 | }); 61 | //锁屏界面点击 62 | $('.lockscreen-choose>img').on('click', function () { 63 | //获取当前图片路径 64 | var bgSrc = $(this).prop('src'); 65 | //改变锁屏预览 66 | $('.lockscreen-preview').css('background-image', 'url(' + bgSrc + ')'); 67 | //设置锁屏背景 68 | winui.resetLockBg(bgSrc); 69 | }) 70 | //锁屏界面图片上传 71 | $('.lockscreen-upload').on('click', function () { 72 | var input = $(this).prev('input[type=file]'); 73 | input.trigger('click'); 74 | input.on('change', function () { 75 | var src = $(this).val(); 76 | if (src) { 77 | layer.msg('选择了路径【' + src + '】下的图片,返回一张性感的Girl给你') 78 | //改变锁屏预览 79 | $('.lockscreen-preview').css('background-image', 'url(images/sexy_girl.jpg'); 80 | //设置锁屏背景 81 | winui.resetLockBg('images/sexy_girl.jpg'); 82 | $(this).val('').off('change'); 83 | } 84 | }) 85 | }); 86 | //颜色选择 87 | $('.color-choose>div').on('click', function () { 88 | var color = Number($(this)[0].classList[0].replace('theme-color-', '')); 89 | winui.resetColor(color); 90 | }); 91 | 92 | form.on('switch(toggleTransparent)', function (data) { 93 | if (data.elem.checked) { 94 | $(data.elem).siblings('span').text('开'); 95 | } else { 96 | $(data.elem).siblings('span').text('关'); 97 | } 98 | layer.msg(unfinished); 99 | }); 100 | 101 | form.on('switch(toggleTaskbar)', function (data) { 102 | if (data.elem.checked) { 103 | $(data.elem).siblings('span').text('开'); 104 | } else { 105 | $(data.elem).siblings('span').text('关'); 106 | } 107 | }); 108 | //任务栏位置 109 | form.on('radio(taskPosition)', function (data) { 110 | switch (data.value) { 111 | case 'top': 112 | winui.resetTaskbar(data.value); 113 | break; 114 | case 'bottom': 115 | winui.resetTaskbar(data.value); 116 | break; 117 | case 'left': 118 | winui.window.msg(unfinished); 119 | break; 120 | case 'right': 121 | winui.window.msg(unfinished); 122 | break; 123 | default: 124 | } 125 | }); 126 | //开始菜单尺寸 127 | form.on('radio(startSize)', function (data) { 128 | winui.resetStartSize(data.value); 129 | }); 130 | }); -------------------------------------------------------------------------------- /src/lib/winui/js/theme.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | @Name:主题设置 3 | @Author:Leo 4 | @License:MIT 5 | 6 | */ 7 | layui.use(["layer","form"],function(){var n=layui.jquery,t=layui.form,i="暂未实现";n(function(){var u,r,f,i;winui.renderColor();winui.tab.init();n(".background-preview").css("background-image",layui.jquery("body").css("background-image"));n(".lockscreen-preview").css("background-image","url("+winui.getSetting("lockBgSrc")+")");u=winui.getSetting("taskbarMode");n(".taskbar-position input[value="+u+"]").prop("checked",!0);r=winui.getSetting("startSize");n(".start-size input[value="+r+"]").prop("checked",!0);n(".preview-start").removeClass("xs sm lg");n(".preview-start").addClass(r);t.render();f=["日","一","二","三","四","五","六"];i=new Date;n(".lockscreen-preview-time").html('

    '+(i.getHours()>9?i.getHours().toString():"0"+i.getHours())+":"+(i.getMinutes()>9?i.getMinutes().toString():"0"+i.getMinutes())+'<\/p>

    '+(i.getMonth()+1)+"月"+i.getDate()+"日,星期"+f[i.getDay()]+"<\/p>")});n(".background-choose>img").on("click",function(){var t=n(this).prop("src");n(".background-preview").css("background-image","url("+t+")");winui.resetBg(t)});n(".background-upload").on("click",function(){var t=n(this).prev("input[type=file]");t.trigger("click");t.on("change",function(){var t=n(this).val();t&&(layer.msg("选择了路径【"+t+"】下的图片,返回一张性感的Girl给你"),n(".background-preview").css("background-image","url(images/sexy_girl.jpg)"),winui.resetBg("images/sexy_girl.jpg"),n(this).val("").off("change"))})});n(".lockscreen-choose>img").on("click",function(){var t=n(this).prop("src");n(".lockscreen-preview").css("background-image","url("+t+")");winui.resetLockBg(t)});n(".lockscreen-upload").on("click",function(){var t=n(this).prev("input[type=file]");t.trigger("click");t.on("change",function(){var t=n(this).val();t&&(layer.msg("选择了路径【"+t+"】下的图片,返回一张性感的Girl给你"),n(".lockscreen-preview").css("background-image","url(images/sexy_girl.jpg"),winui.resetLockBg("images/sexy_girl.jpg"),n(this).val("").off("change"))})});n(".color-choose>div").on("click",function(){var t=Number(n(this)[0].classList[0].replace("theme-color-",""));winui.resetColor(t)});t.on("switch(toggleTransparent)",function(t){t.elem.checked?n(t.elem).siblings("span").text("开"):n(t.elem).siblings("span").text("关");layer.msg(i)});t.on("switch(toggleTaskbar)",function(t){t.elem.checked?n(t.elem).siblings("span").text("开"):n(t.elem).siblings("span").text("关")});t.on("radio(taskPosition)",function(n){switch(n.value){case"top":winui.resetTaskbar(n.value);break;case"bottom":winui.resetTaskbar(n.value);break;case"left":winui.window.msg(i);break;case"right":winui.window.msg(i)}});t.on("radio(startSize)",function(n){winui.resetStartSize(n.value)})}); -------------------------------------------------------------------------------- /src/lib/winui/js/winui.desktop.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | @Name:winui.dektop 桌面模块 3 | @Author:Leo 4 | @License:MIT 5 | 6 | */ 7 | layui.define(["jquery","layer","winui"],function(n){"use strict";var t=layui.jquery,u=function(n){this.options=n||{url:winui.path+"json/desktopmenu.json",method:"get"};this.data=null},i;u.prototype.render=function(n){if(this.data!==null){var i="";t(this.data).each(function(n,t){var u=t.id==""||t.id==undefined?"":'win-id="'+t.id+'"',f=t.pageURL==""||t.pageURL==undefined?"":'win-url="'+t.pageURL+'"',e=t.title==""||t.title==undefined?"":'win-title="'+t.title+'"',o=t.openType==""||t.openType==undefined?"":'win-opentype="'+t.openType+'"',s=t.maxOpen==""||t.maxOpen==undefined?"":'win-maxOpen="'+t.maxOpen+'"',r=t.icon.indexOf("fa-")!=-1&&t.icon.indexOf(".")==-1,h=r?'<\/i>':'';i+='

    ";i+='
    ';i+=h;i+="<\/div>";i+="

    "+t.name+"<\/p>";i+="<\/div>"});t(".winui-desktop").html(i);r.locaApp();typeof n=="function"&&n.call(this,e)}};u.prototype.setData=function(n){var i=this,r=i.options;r.url&&r.method&&t.ajax({url:r.url,type:r.method,data:t.extend({},r.data),dataType:"json",success:function(t){t=t.data;typeof t=="string"?(i.data=JSON.parse(t),typeof n=="function"&&n.call(i)):typeof t=="object"&&(Object.prototype.toString.call(t).toLowerCase()=="[object object]"||Object.prototype.toString.call(t).toLowerCase()=="[object array]")?(i.data=t,typeof n=="function"&&n.call(i)):layer.msg("请对接口返回json对象或者json字符串",{offset:"40px",zIndex:layer.zIndex})},error:function(n){n.status!=200?console.error(n.statusText):layer.msg("请对接口返回json对象或者json字符串",{offset:"40px",zIndex:layer.zIndex})}})};i=function(){this.contextmenuOptions={}};i.prototype.contextmenu=function(n){n.item&&(r.resetEvent(".winui-desktop>.winui-desktop-item","mouseup",function(i){var u;if(i||(i=window.event),u=this,i.button==2){var e=i.clientX,s=i.clientY,f='