├── .gitignore ├── LICENSE ├── README.md ├── asset ├── __init__.py ├── admin.py ├── asset_info.py ├── form.py ├── models.py ├── tests.py └── views.py ├── demo ├── code_deploy.jpg ├── command_exec.jpg ├── data_center.jpg ├── device_asset.jpg ├── host_list.jpg ├── install.jpg ├── install_record.jpg ├── key.jpg ├── module.jpg └── server_asset.jpg ├── deploy ├── __init__.py ├── admin.py ├── code.py ├── json_data.py ├── models.py ├── saltapi.py ├── tests.py └── views.py ├── install.txt ├── installed ├── __init__.py ├── admin.py ├── cobbler_api.py ├── form.py ├── models.py ├── tests.py └── views.py ├── manage.py ├── oms ├── .vimrc ├── __init__.py ├── models.py ├── mysql.py ├── settings.py ├── settings_local.py ├── urls.py ├── views.py └── wsgi.py ├── requirements.txt ├── static ├── css │ ├── animate.css │ ├── font-awesome.min.css │ ├── main.css │ └── main.min.css ├── fonts │ ├── fontawesome-webfont.eot- │ ├── fontawesome-webfont.eot-v=4.0.3 │ ├── fontawesome-webfont.svg-v=4.0.3 │ ├── fontawesome-webfont.ttf-v=4.0.3 │ └── fontawesome-webfont.woff-v=4.0.3 ├── img │ ├── avatar.gif │ ├── avatar.png │ ├── avatar1.gif │ ├── avatar2.gif │ ├── avatar3.gif │ ├── avatar4.gif │ ├── avatar5.gif │ ├── avatar6.gif │ ├── favicon.ico │ ├── logo.png │ └── spaceship.gif ├── js │ ├── application.js │ ├── html5shiv.js │ ├── jquery-1.10.2.min.js │ ├── modernizr-2.6.2.min.js │ └── respond.min.js └── plugins │ ├── bootstrap-slider │ ├── css │ │ └── slider.css │ └── js │ │ └── bootstrap-slider.js │ ├── bootstrap-wysihtml5 │ ├── css │ │ ├── bootstrap-wysihtml5.css │ │ └── bootstrap3-wysiwyg5-color.css │ └── js │ │ ├── bootstrap3-wysihtml5.js │ │ └── wysihtml5-0.3.0.js │ ├── bootstrap │ ├── css │ │ └── bootstrap.min.css │ ├── fonts │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.eot- │ │ ├── glyphicons-halflings-regular.eot~.eot │ │ ├── glyphicons-halflings-regular.svg │ │ ├── glyphicons-halflings-regular.ttf │ │ └── glyphicons-halflings-regular.woff │ └── js │ │ └── bootstrap.min.js │ ├── c3Chart │ ├── css │ │ └── c3.css │ └── js │ │ ├── c3-demo.js │ │ ├── c3.js │ │ └── d3.v3.min.js │ ├── chartjs │ ├── Chart.min.js │ └── chartjs-demo.js │ ├── ckeditor │ ├── CHANGES.md │ ├── LICENSE.md │ ├── README.md │ ├── adapters │ │ └── jquery.js │ ├── build-config.js │ ├── ckeditor.js │ ├── config.js │ ├── contents.css │ ├── lang │ │ ├── af.js │ │ ├── ar.js │ │ ├── bg.js │ │ ├── bn.js │ │ ├── bs.js │ │ ├── ca.js │ │ ├── cs.js │ │ ├── cy.js │ │ ├── da.js │ │ ├── de.js │ │ ├── el.js │ │ ├── en-au.js │ │ ├── en-ca.js │ │ ├── en-gb.js │ │ ├── en.js │ │ ├── eo.js │ │ ├── es.js │ │ ├── et.js │ │ ├── eu.js │ │ ├── fa.js │ │ ├── fi.js │ │ ├── fo.js │ │ ├── fr-ca.js │ │ ├── fr.js │ │ ├── gl.js │ │ ├── gu.js │ │ ├── he.js │ │ ├── hi.js │ │ ├── hr.js │ │ ├── hu.js │ │ ├── id.js │ │ ├── is.js │ │ ├── it.js │ │ ├── ja.js │ │ ├── ka.js │ │ ├── km.js │ │ ├── ko.js │ │ ├── ku.js │ │ ├── lt.js │ │ ├── lv.js │ │ ├── mk.js │ │ ├── mn.js │ │ ├── ms.js │ │ ├── nb.js │ │ ├── nl.js │ │ ├── no.js │ │ ├── pl.js │ │ ├── pt-br.js │ │ ├── pt.js │ │ ├── ro.js │ │ ├── ru.js │ │ ├── si.js │ │ ├── sk.js │ │ ├── sl.js │ │ ├── sq.js │ │ ├── sr-latn.js │ │ ├── sr.js │ │ ├── sv.js │ │ ├── th.js │ │ ├── tr.js │ │ ├── ug.js │ │ ├── uk.js │ │ ├── vi.js │ │ ├── zh-cn.js │ │ └── zh.js │ ├── plugins │ │ ├── a11yhelp │ │ │ └── dialogs │ │ │ │ ├── a11yhelp.js │ │ │ │ └── lang │ │ │ │ ├── _translationstatus.txt │ │ │ │ ├── ar.js │ │ │ │ ├── bg.js │ │ │ │ ├── ca.js │ │ │ │ ├── cs.js │ │ │ │ ├── cy.js │ │ │ │ ├── da.js │ │ │ │ ├── de.js │ │ │ │ ├── el.js │ │ │ │ ├── en.js │ │ │ │ ├── eo.js │ │ │ │ ├── es.js │ │ │ │ ├── et.js │ │ │ │ ├── fa.js │ │ │ │ ├── fi.js │ │ │ │ ├── fr-ca.js │ │ │ │ ├── fr.js │ │ │ │ ├── gl.js │ │ │ │ ├── gu.js │ │ │ │ ├── he.js │ │ │ │ ├── hi.js │ │ │ │ ├── hr.js │ │ │ │ ├── hu.js │ │ │ │ ├── id.js │ │ │ │ ├── it.js │ │ │ │ ├── ja.js │ │ │ │ ├── km.js │ │ │ │ ├── ko.js │ │ │ │ ├── ku.js │ │ │ │ ├── lt.js │ │ │ │ ├── lv.js │ │ │ │ ├── mk.js │ │ │ │ ├── mn.js │ │ │ │ ├── nb.js │ │ │ │ ├── nl.js │ │ │ │ ├── no.js │ │ │ │ ├── pl.js │ │ │ │ ├── pt-br.js │ │ │ │ ├── pt.js │ │ │ │ ├── ro.js │ │ │ │ ├── ru.js │ │ │ │ ├── si.js │ │ │ │ ├── sk.js │ │ │ │ ├── sl.js │ │ │ │ ├── sq.js │ │ │ │ ├── sr-latn.js │ │ │ │ ├── sr.js │ │ │ │ ├── sv.js │ │ │ │ ├── th.js │ │ │ │ ├── tr.js │ │ │ │ ├── ug.js │ │ │ │ ├── uk.js │ │ │ │ ├── vi.js │ │ │ │ ├── zh-cn.js │ │ │ │ └── zh.js │ │ ├── about │ │ │ └── dialogs │ │ │ │ ├── about.js │ │ │ │ ├── hidpi │ │ │ │ └── logo_ckeditor.png │ │ │ │ └── logo_ckeditor.png │ │ ├── clipboard │ │ │ └── dialogs │ │ │ │ └── paste.js │ │ ├── dialog │ │ │ └── dialogDefinition.js │ │ ├── fakeobjects │ │ │ └── images │ │ │ │ └── spacer.gif │ │ ├── icons.png │ │ ├── icons_hidpi.png │ │ ├── image │ │ │ ├── dialogs │ │ │ │ └── image.js │ │ │ └── images │ │ │ │ └── noimage.png │ │ ├── link │ │ │ ├── dialogs │ │ │ │ ├── anchor.js │ │ │ │ └── link.js │ │ │ └── images │ │ │ │ ├── anchor.png │ │ │ │ └── hidpi │ │ │ │ └── anchor.png │ │ ├── magicline │ │ │ └── images │ │ │ │ ├── hidpi │ │ │ │ └── icon.png │ │ │ │ └── icon.png │ │ ├── pastefromword │ │ │ └── filter │ │ │ │ └── default.js │ │ ├── scayt │ │ │ ├── LICENSE.md │ │ │ ├── README.md │ │ │ └── dialogs │ │ │ │ ├── options.js │ │ │ │ └── toolbar.css │ │ ├── specialchar │ │ │ └── dialogs │ │ │ │ ├── lang │ │ │ │ ├── _translationstatus.txt │ │ │ │ ├── ar.js │ │ │ │ ├── bg.js │ │ │ │ ├── ca.js │ │ │ │ ├── cs.js │ │ │ │ ├── cy.js │ │ │ │ ├── de.js │ │ │ │ ├── el.js │ │ │ │ ├── en.js │ │ │ │ ├── eo.js │ │ │ │ ├── es.js │ │ │ │ ├── et.js │ │ │ │ ├── fa.js │ │ │ │ ├── fi.js │ │ │ │ ├── fr-ca.js │ │ │ │ ├── fr.js │ │ │ │ ├── gl.js │ │ │ │ ├── he.js │ │ │ │ ├── hr.js │ │ │ │ ├── hu.js │ │ │ │ ├── id.js │ │ │ │ ├── it.js │ │ │ │ ├── ja.js │ │ │ │ ├── km.js │ │ │ │ ├── ku.js │ │ │ │ ├── lv.js │ │ │ │ ├── nb.js │ │ │ │ ├── nl.js │ │ │ │ ├── no.js │ │ │ │ ├── pl.js │ │ │ │ ├── pt-br.js │ │ │ │ ├── pt.js │ │ │ │ ├── ru.js │ │ │ │ ├── si.js │ │ │ │ ├── sk.js │ │ │ │ ├── sl.js │ │ │ │ ├── sq.js │ │ │ │ ├── sv.js │ │ │ │ ├── th.js │ │ │ │ ├── tr.js │ │ │ │ ├── ug.js │ │ │ │ ├── uk.js │ │ │ │ ├── vi.js │ │ │ │ ├── zh-cn.js │ │ │ │ └── zh.js │ │ │ │ └── specialchar.js │ │ ├── table │ │ │ └── dialogs │ │ │ │ └── table.js │ │ ├── tabletools │ │ │ └── dialogs │ │ │ │ └── tableCell.js │ │ └── wsc │ │ │ ├── LICENSE.md │ │ │ ├── README.md │ │ │ └── dialogs │ │ │ ├── ciframe.html │ │ │ ├── tmp.html │ │ │ ├── tmpFrameset.html │ │ │ ├── wsc.css │ │ │ ├── wsc.js │ │ │ └── wsc_ie.js │ ├── samples │ │ ├── ajax.html │ │ ├── api.html │ │ ├── appendto.html │ │ ├── assets │ │ │ ├── inlineall │ │ │ │ └── logo.png │ │ │ ├── outputxhtml │ │ │ │ └── outputxhtml.css │ │ │ ├── posteddata.php │ │ │ ├── sample.css │ │ │ ├── sample.jpg │ │ │ └── uilanguages │ │ │ │ └── languages.js │ │ ├── datafiltering.html │ │ ├── divreplace.html │ │ ├── index.html │ │ ├── inlineall.html │ │ ├── inlinebycode.html │ │ ├── inlinetextarea.html │ │ ├── jquery.html │ │ ├── plugins │ │ │ ├── dialog │ │ │ │ ├── assets │ │ │ │ │ └── my_dialog.js │ │ │ │ └── dialog.html │ │ │ ├── enterkey │ │ │ │ └── enterkey.html │ │ │ ├── htmlwriter │ │ │ │ ├── assets │ │ │ │ │ └── outputforflash │ │ │ │ │ │ ├── outputforflash.fla │ │ │ │ │ │ ├── outputforflash.swf │ │ │ │ │ │ └── swfobject.js │ │ │ │ ├── outputforflash.html │ │ │ │ └── outputhtml.html │ │ │ ├── magicline │ │ │ │ └── magicline.html │ │ │ ├── toolbar │ │ │ │ └── toolbar.html │ │ │ └── wysiwygarea │ │ │ │ └── fullpage.html │ │ ├── readonly.html │ │ ├── replacebyclass.html │ │ ├── replacebycode.html │ │ ├── sample.css │ │ ├── sample.js │ │ ├── sample_posteddata.php │ │ ├── tabindex.html │ │ ├── uicolor.html │ │ ├── uilanguages.html │ │ └── xhtmlstyle.html │ ├── skins │ │ └── moono │ │ │ ├── dialog.css │ │ │ ├── dialog_ie.css │ │ │ ├── dialog_ie7.css │ │ │ ├── dialog_ie8.css │ │ │ ├── dialog_iequirks.css │ │ │ ├── dialog_opera.css │ │ │ ├── editor.css │ │ │ ├── editor_gecko.css │ │ │ ├── editor_ie.css │ │ │ ├── editor_ie7.css │ │ │ ├── editor_ie8.css │ │ │ ├── editor_iequirks.css │ │ │ ├── icons.png │ │ │ ├── icons_hidpi.png │ │ │ ├── images │ │ │ ├── arrow.png │ │ │ ├── close.png │ │ │ ├── hidpi │ │ │ │ ├── close.png │ │ │ │ ├── lock-open.png │ │ │ │ ├── lock.png │ │ │ │ └── refresh.png │ │ │ ├── lock-open.png │ │ │ ├── lock.png │ │ │ └── refresh.png │ │ │ └── readme.md │ └── styles.js │ ├── countTo │ └── jquery.countTo.js │ ├── dataTables │ ├── css │ │ └── dataTables.css │ ├── images │ │ ├── sort_asc.png │ │ ├── sort_asc_disabled.png │ │ ├── sort_both.png │ │ ├── sort_desc.png │ │ └── sort_desc_disabled.png │ └── js │ │ ├── dataTables.bootstrap.js │ │ └── jquery.dataTables.js │ ├── dropzone │ ├── css │ │ ├── basic.css │ │ └── dropzone.css │ ├── images │ │ ├── spritemap.png │ │ └── spritemap@2x.png │ └── js │ │ └── dropzone.min.js │ ├── flot │ └── js │ │ ├── jquery.colorhelpers.min.js │ │ ├── jquery.flot.canvas.min.js │ │ ├── jquery.flot.categories.min.js │ │ ├── jquery.flot.crosshair.min.js │ │ ├── jquery.flot.errorbars.min.js │ │ ├── jquery.flot.example.js │ │ ├── jquery.flot.fillbetween.min.js │ │ ├── jquery.flot.image.min.js │ │ ├── jquery.flot.min.js │ │ ├── jquery.flot.navigate.min.js │ │ ├── jquery.flot.pie.min.js │ │ ├── jquery.flot.resize.min.js │ │ ├── jquery.flot.selection.min.js │ │ ├── jquery.flot.stack.min.js │ │ ├── jquery.flot.symbol.min.js │ │ ├── jquery.flot.threshold.min.js │ │ └── jquery.flot.time.min.js │ ├── fullcalendar │ ├── css │ │ └── fullcalendar.css │ └── js │ │ ├── calendar.js │ │ ├── fullcalendar.min.js │ │ └── jquery-ui-1.10.1.custom.min.js │ ├── gmaps │ ├── gmaps-demo.js │ └── gmaps.js │ ├── icheck │ ├── css │ │ ├── _all.css │ │ ├── aero.png │ │ ├── aero@2x.png │ │ ├── blue.png │ │ ├── blue@2x.png │ │ ├── flat.png │ │ ├── flat@2x.png │ │ ├── green.png │ │ ├── green@2x.png │ │ ├── grey.png │ │ ├── grey@2x.png │ │ ├── orange.png │ │ ├── orange@2x.png │ │ ├── pink.png │ │ ├── pink@2x.png │ │ ├── purple.png │ │ ├── purple@2x.png │ │ ├── red.png │ │ ├── red@2x.png │ │ ├── yellow.png │ │ └── yellow@2x.png │ └── js │ │ └── icheck.min.js │ ├── jvectormap │ ├── css │ │ └── jquery-jvectormap-1.2.2.css │ └── js │ │ ├── jquery-jvectormap-1.2.2.min.js │ │ ├── jquery-jvectormap-ca-lcc-en.js │ │ ├── jquery-jvectormap-demo.js │ │ ├── jquery-jvectormap-europe-mill-en.js │ │ ├── jquery-jvectormap-it-mill-en.js │ │ ├── jquery-jvectormap-map.js │ │ ├── jquery-jvectormap-uk-mill-en.js │ │ ├── jquery-jvectormap-us-aea-en.js │ │ ├── jquery-jvectormap-us-il-chicago-mill-en.js │ │ ├── jquery-jvectormap-us-ny-newyork-mill-en.js │ │ └── jquery-jvectormap-world-mill-en.js │ ├── mask │ └── js │ │ └── jquery.maskedinput.min.js │ ├── messenger │ ├── css │ │ ├── location-sel.css │ │ ├── messenger-theme-flat.css │ │ └── messenger.css │ └── js │ │ ├── demo │ │ ├── demo-messages.js │ │ ├── demo.js │ │ ├── location-sel.js │ │ └── theme-sel.js │ │ ├── messenger-theme-future.js │ │ └── messenger.min.js │ ├── morris │ ├── css │ │ └── morris.css │ └── js │ │ ├── morris-example.js │ │ ├── morris.min.js │ │ └── raphael.2.1.0.min.js │ ├── nanoScroller │ └── jquery.nanoscroller.min.js │ ├── sortNestable │ └── js │ │ └── jquery.nestable.js │ ├── todo │ ├── css │ │ └── todos.css │ ├── img │ │ └── destroy.png │ └── js │ │ └── todos.js │ ├── validation │ └── js │ │ └── jquery.validate.min.js │ ├── waypoints │ └── waypoints.min.js │ ├── weather │ └── js │ │ └── skycons.js │ └── wizard │ └── js │ └── loader.min.js └── templates ├── 404.html ├── 500.html ├── code_deploy.html ├── device_list.html ├── device_manage.html ├── host_list.html ├── host_manage.html ├── idc_list.html ├── idc_manage.html ├── index.html ├── install_list.html ├── install_manage.html ├── install_record_list.html ├── login.html ├── salt_key_list.html ├── salt_module_deploy.html ├── salt_remote_execution.html ├── server_asset_list.html └── sign-up.html /.gitignore: -------------------------------------------------------------------------------- 1 | *.py[co] 2 | *.swp 3 | *.DS_Store 4 | 5 | # setuptools stuff 6 | *.egg-info 7 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | oms 2 | === 3 | 4 | OMS运维管理平台 5 | 6 | 写在前言: 7 | 分享,平台里的东西是采用各家之精华,自己融合才有了那么个东西,发表OMS博客那天,答应过后续开源,那么今天就把它分享出来 8 | 学习,自我赶脚代码不是很好,分享出来; 希望得到学习,毕竟闭门造车不好嘛。希望得到反馈,谢谢~ 9 | 总结,从13年底就想写这么个东西,刚好下半年有空,就利用9月份把这个写了,算是对自动化运维一个小小总结,里面还有不够好的地方,希望可以得到交流,毕竟每人角度不一,观点也不一样。 10 | 感谢蝴蝶运维老大支持,小马哥代码指点迷津,绿肥在OMS平台写的时候提供帮助~ 11 | 12 | redhat.binbin@gmail.com //欢迎来件~,TKS ALL~ 13 | 14 | 组件要求查看requirements.txt,安装查看install.txt 15 | 16 | OMS管理平台界面 17 | ![主页](https://github.com/binbin91/oms/raw/master/demo/install.jpg) 18 | ![主页](https://github.com/binbin91/oms/raw/master/demo/install_record.jpg) 19 | ![主页](https://github.com/binbin91/oms/raw/master/demo/key.jpg) 20 | ![主页](https://github.com/binbin91/oms/raw/master/demo/module.jpg) 21 | ![主页](https://github.com/binbin91/oms/raw/master/demo/command_exec.jpg) 22 | ![主页](https://github.com/binbin91/oms/raw/master/demo/code_deploy.jpg) 23 | ![主页](https://github.com/binbin91/oms/raw/master/demo/host_list.jpg) 24 | ![主页](https://github.com/binbin91/oms/raw/master/demo/server_asset.jpg) 25 | ![主页](https://github.com/binbin91/oms/raw/master/demo/device_asset.jpg) 26 | ![主页](https://github.com/binbin91/oms/raw/master/demo/data_center.jpg) 27 | 28 | -------------------------------------------------------------------------------- /asset/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/asset/__init__.py -------------------------------------------------------------------------------- /asset/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | 3 | # Register your models here. 4 | -------------------------------------------------------------------------------- /asset/asset_info.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from sys import path 3 | if 'deploy' not in path: 4 | path.append(r'deploy') 5 | from saltapi import SaltAPI 6 | from oms import settings 7 | import threading 8 | 9 | asset_info = [] 10 | 11 | def get_server_asset_info(tgt): 12 | ''' 13 | Salt API得到资产信息,进行格式化输出 14 | ''' 15 | global asset_info 16 | info = [] 17 | sapi = SaltAPI(url=settings.SALT_API['url'],username=settings.SALT_API['user'],password=settings.SALT_API['password']) 18 | ret = sapi.remote_noarg_execution(tgt,'grains.items') 19 | manufacturer = ret['manufacturer'] 20 | info.append(manufacturer) 21 | productname = ret['productname'] 22 | info.append(productname) 23 | serialnumber = ret['serialnumber'] 24 | info.append(serialnumber) 25 | cpu_model = ret['cpu_model'] 26 | info.append(cpu_model) 27 | num_cpus = int(ret['num_cpus']) 28 | info.append(num_cpus) 29 | num_gpus = int(ret['num_gpus']) 30 | info.append(num_gpus) 31 | mem_total = str(round(int(ret['mem_total'])/1000.0,))[:-2] + 'G' 32 | info.append(mem_total) 33 | disk_size = ret['disk_size'] 34 | info.append(disk_size) 35 | raidlevel = ret['raidlevel'] 36 | info.append(raidlevel) 37 | id = ret['id'] 38 | info.append(id) 39 | lan_ip = ret['lan_ip'][0] 40 | info.append(lan_ip) 41 | lan_mac = ret['hwaddr_interfaces']['eth0'] 42 | info.append(lan_mac) 43 | sys_ver = ret['os'] + ret['osrelease'] + '-' + ret['osarch'] 44 | info.append(sys_ver) 45 | virtual = ret['virtual'] 46 | info.append(virtual) 47 | idc_name = ret['idc_name'] 48 | info.append(idc_name) 49 | asset_info.append(info) 50 | 51 | 52 | def multitle_collect(tgt): 53 | global asset_info 54 | #全局变量置空,避免多次请求的时候返回结果叠加 55 | aseet_info = [] 56 | threads = [] 57 | loop = 0 58 | numtgt = len(tgt) 59 | for i in range(0, numtgt, 2): 60 | nkeys = range(loop*2, (loop+1)*2, 1) 61 | #实例化线程 62 | for i in nkeys: 63 | if i >= numtgt: 64 | break 65 | else: 66 | t = threading.Thread(target=get_server_asset_info, args=(tgt[i],)) 67 | threads.append(t) 68 | #启动线程 69 | for i in nkeys: 70 | if i >= numtgt: 71 | break 72 | else: 73 | threads[i].start() 74 | #等待并发线程结束 75 | for i in nkeys: 76 | if i >= numtgt: 77 | break 78 | else: 79 | threads[i].join() 80 | loop = loop + 1 81 | return asset_info 82 | 83 | ''' 84 | if __name__ == '__main__': 85 | print multitle_collect(['test-02', 'test-01']) 86 | ''' 87 | -------------------------------------------------------------------------------- /asset/form.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django import forms 3 | from asset.models import * 4 | 5 | class HostsListForm(forms.ModelForm): 6 | class Meta: 7 | model = HostList 8 | widgets = { 9 | 'ip': forms.TextInput(attrs={'class': 'form-control'}), 10 | 'hostname': forms.TextInput(attrs={'class': 'form-control'}), 11 | 'product': forms.TextInput(attrs={'class': 'form-control'}), 12 | 'application': forms.TextInput(attrs={'class': 'form-control'}), 13 | 'idc_jg': forms.TextInput(attrs={'class': 'form-control'}), 14 | 'status': forms.TextInput(attrs={'class': 'form-control'}), 15 | 'remark': forms.TextInput(attrs={'class': 'form-control'}), 16 | } 17 | 18 | class NetworkAssetForm(forms.ModelForm): 19 | class Meta: 20 | model = NetworkAsset 21 | widgets = { 22 | 'ip': forms.TextInput(attrs={'class': 'form-control'}), 23 | 'hostname': forms.TextInput(attrs={'class': 'form-control'}), 24 | 'manufacturer': forms.TextInput(attrs={'class': 'form-control'}), 25 | 'productname': forms.TextInput(attrs={'class': 'form-control'}), 26 | 'idc_jg': forms.TextInput(attrs={'class': 'form-control'}), 27 | 'service_tag': forms.TextInput(attrs={'class': 'form-control'}), 28 | 'remark': forms.TextInput(attrs={'class': 'form-control'}), 29 | } 30 | 31 | class IdcAssetForm(forms.ModelForm): 32 | class Meta: 33 | model = IdcAsset 34 | widgets = { 35 | 'idc_name': forms.TextInput(attrs={'class': 'form-control'}), 36 | 'idc_type': forms.TextInput(attrs={'class': 'form-control'}), 37 | 'idc_location': forms.TextInput(attrs={'class': 'form-control'}), 38 | 'contract_date': forms.TextInput(attrs={'class': 'form-control'}), 39 | 'idc_contacts': forms.TextInput(attrs={'class': 'form-control'}), 40 | 'remark': forms.TextInput(attrs={'class': 'form-control'}), 41 | } 42 | -------------------------------------------------------------------------------- /asset/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /demo/code_deploy.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/code_deploy.jpg -------------------------------------------------------------------------------- /demo/command_exec.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/command_exec.jpg -------------------------------------------------------------------------------- /demo/data_center.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/data_center.jpg -------------------------------------------------------------------------------- /demo/device_asset.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/device_asset.jpg -------------------------------------------------------------------------------- /demo/host_list.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/host_list.jpg -------------------------------------------------------------------------------- /demo/install.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/install.jpg -------------------------------------------------------------------------------- /demo/install_record.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/install_record.jpg -------------------------------------------------------------------------------- /demo/key.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/key.jpg -------------------------------------------------------------------------------- /demo/module.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/module.jpg -------------------------------------------------------------------------------- /demo/server_asset.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/demo/server_asset.jpg -------------------------------------------------------------------------------- /deploy/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/deploy/__init__.py -------------------------------------------------------------------------------- /deploy/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | 3 | # Register your models here. 4 | -------------------------------------------------------------------------------- /deploy/code.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from subprocess import Popen,PIPE,STDOUT,call 3 | import os 4 | 5 | class Code_Work(object): 6 | def __init__(self,pro,url,ver): 7 | self.__pro = pro 8 | self.__url = url 9 | self.__ver = ver 10 | path = {'tg': 'opt/www/v', 'hdworkers': 'home/hpn'} 11 | self.__tgt = path[self.__pro] 12 | 13 | def pull_code(self): 14 | ''' 15 | From the pull of gitlab project code 16 | ''' 17 | ret = { 18 | 'result': True, 19 | 'comment': [], 20 | } 21 | if os.path.isdir('/home/work'): 22 | os.system('rm -rf /home/work/*') #每次拉取,work都是干净目录 23 | os.chdir('/home/work') 24 | else: 25 | os.mkdir('/home/work') 26 | os.chdir('/home/work') 27 | args = 'git clone %s %s' % (self.__url,self.__tgt) 28 | try: 29 | obj = Popen(args, shell=True, stdout=PIPE, stderr=STDOUT) 30 | ret['comment'].append(obj.stdout.readlines()) 31 | except Exception, e: 32 | ret['result'] = False 33 | ret['comment'].append(str(e)) 34 | return ret 35 | 36 | def build_rpm(self): 37 | ''' 38 | Project of the latest code into the RPM 39 | ''' 40 | ret = { 41 | 'result': True, 42 | 'comment': [], 43 | } 44 | f_args = 'fpm -s dir -t rpm -n %s --epoch 0 -v %s -C /home/work -p /mirros/package %s' % (self.__pro,self.__ver,self.__tgt) 45 | try: 46 | obj = Popen(f_args, shell=True, stdout=PIPE, stderr=STDOUT) 47 | ret['comment'].append(obj.stdout.readlines()) 48 | except Exception, e: 49 | ret['result'] = False 50 | ret['comment'].append(str(e)) 51 | return ret 52 | 53 | def push_repo(self): 54 | ''' 55 | push to yum warehouse 56 | ''' 57 | ret = { 58 | 'result': True, 59 | 'comment': [], 60 | } 61 | c_args = 'createrepo /mirros/package' 62 | try: 63 | obj = Popen(c_args, shell=True, stdout=PIPE, stderr=STDOUT) 64 | ret['comment'].append(obj.stdout.readlines()) 65 | except Exception, e: 66 | ret['result'] = False 67 | ret['comment'].append(str(e)) 68 | return ret 69 | 70 | def work(self): 71 | ret = { 72 | 'comment': [], 73 | } 74 | ret['comment'].append(self.pull_code()) 75 | ret['comment'].append(self.build_rpm()) 76 | ret['comment'].append(self.push_repo()) 77 | return ret 78 | 79 | def main(): 80 | capi = Code_Work(pro=,url=,ver=) 81 | print capi.work() 82 | #print capi.pull_code() 83 | #print capi.build_rpm() 84 | #print capi.push_repo() 85 | 86 | if __name__ == '__main__': 87 | main() 88 | -------------------------------------------------------------------------------- /deploy/json_data.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | import json 3 | import os 4 | 5 | class BuildJson(object): 6 | ''' 7 | Build JSON data(base and minion_id etc..) 8 | ''' 9 | def base_data(self,args): 10 | ''' 11 | build base data 12 | ''' 13 | info = {} 14 | ret = dict(info,**args) 15 | self.write_data('base',ret) 16 | 17 | def build_data(self,id,args): 18 | if not os.path.exists('/home/api/pillar/%s' % (id)): 19 | with open('/home/api/pillar/base') as f: 20 | obj = f.readlines()[0] 21 | ret = eval(obj) 22 | self.write_data(id,ret) 23 | with open('/home/api/pillar/%s' % (id)) as f: 24 | data = f.readlines()[0] 25 | cov_data = eval(data) 26 | if not cov_data.has_key(args.keys()[0]): 27 | ret = dict(cov_data,**args) 28 | self.write_data(id,ret) 29 | else: 30 | cov_data.update(args) 31 | self.write_data(id,cov_data) 32 | 33 | def write_data(self,file,ret): 34 | f = open('/home/api/pillar/%s' % (file),'w+') 35 | f.write(str(ret)) 36 | f.close() 37 | 38 | -------------------------------------------------------------------------------- /deploy/models.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | 3 | # Create your models here. 4 | -------------------------------------------------------------------------------- /deploy/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /install.txt: -------------------------------------------------------------------------------- 1 | 功能简介: 2 | installed App: 系统安装、安装记录 3 | deploy App: Salt Key管理、模块部署、远程管理、代码发布 4 | asset App: 主机列表、服务器软硬资产、网络设备资产、数据中心资产 5 | 6 | 设计流程: 7 | 传送门:http://binbin158.blog.51cto.com/2659767/1561175 8 | 9 | 安装 10 | 1.Cobbler(OMS需要调用cobbler代码模块) 11 | yum localinstall /tmp/cobbler-2.6.3-1.el6.noarch.rpm // yum install cobbler 12 | 13 | 2.Saltstack 14 | rpm -ivh http://mirrors.sohu.com/fedora-epel/6/x86_64/epel-release-6-8.noarch.rpm 15 | yum install salt-master //最近epel源有问题,可以上官网直接下载代码install 16 | 17 | 3.Saltstack API、配置 18 | 传送门:http://pengyao.org/salt-api-deploy-and-use.html 19 | 20 | 4.MySQL-python 21 | yum install MySQL-python 22 | 23 | 5.MySQL安装配置(OMS数据模型、APP代码需要调用),只要python manage.py validate没问题就OK 24 | 1.新装一个MySQL 25 | 2.使用现用滴, 这个环节我就略了~ 26 | 27 | 6.salt_event_to_mysql.py 28 | 传送门:http://pengyao.org/saltstack_master_retuner_over_event_system.html 29 | 30 | 7.ext_pillar(oms.py) 31 | 传送门:http://binbin158.blog.51cto.com/2659767/1570433 32 | 33 | 配置(根据环境自行配置): 34 | settings.py 数据库信息 35 | settings_local.py API接口信息,数据库信息 36 | cobble_api.py 连接信息 37 | 38 | 启动 39 | 1.导入数据类型 40 | mysql -uroot -p -e 'create database oms;' 41 | python manage.py validate 42 | python manage.py syncdb 43 | 44 | 2.启动程序 45 | a#直接启动, python manage.py runserver 0.0.0.0:8000 46 | b#nginx + uwsgin,参考链接:http://binbin158.blog.51cto.com/2659767/1569298 47 | -------------------------------------------------------------------------------- /installed/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/installed/__init__.py -------------------------------------------------------------------------------- /installed/admin.py: -------------------------------------------------------------------------------- 1 | from django.contrib import admin 2 | 3 | # Register your models here. 4 | -------------------------------------------------------------------------------- /installed/cobbler_api.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # @author: binbin 5 | # Created on Aug 8, 2014 6 | 7 | import cobbler 8 | import xmlrpclib 9 | 10 | class CobblerAPI(object): 11 | def __init__(self,url,user,password): 12 | self.cobbler_user= user 13 | self.cobbler_pass = password 14 | self.cobbler_url = url 15 | 16 | def add_system(self,hostname,ip_add,mac_add,profile): 17 | ''' 18 | Add Cobbler System Infomation 19 | ''' 20 | ret = { 21 | "result": True, 22 | "comment": [], 23 | } 24 | 25 | remote = xmlrpclib.Server(self.cobbler_url) 26 | token = remote.login(self.cobbler_user,self.cobbler_pass) 27 | system_id = remote.new_system(token) 28 | remote.modify_system(system_id,"name",hostname,token) 29 | remote.modify_system(system_id,"hostname",hostname,token) 30 | remote.modify_system(system_id,'modify_interface', { 31 | "macaddress-eth0" : mac_add, 32 | "ipaddress-eth0" : ip_add, 33 | "dnsname-eth0" : hostname, 34 | }, token) 35 | remote.modify_system(system_id,"profile",profile,token) 36 | remote.save_system(system_id, token) 37 | try: 38 | remote.sync(token) 39 | except Exception as e: 40 | ret['result'] = False 41 | ret['comment'].append(str(e)) 42 | return ret 43 | 44 | def main(): 45 | cobbler = CobblerAPI(url=,user,password,) 46 | ret = cobbler.add_system(hostname='test',ip_add='#',mac_add='#',profile='CentOS6.3-x86_64') 47 | print ret 48 | 49 | if __name__ == '__main__': 50 | main() 51 | -------------------------------------------------------------------------------- /installed/form.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django import forms 3 | from installed.models import SystemInstall 4 | 5 | class SystemInstallForm(forms.ModelForm): 6 | class Meta: 7 | model = SystemInstall 8 | exclude = ('install_date',) 9 | widgets = { 10 | 'ip': forms.TextInput(attrs={'class': 'form-control'}), 11 | 'hostname': forms.TextInput(attrs={'class': 'form-control'}), 12 | 'macaddress': forms.TextInput(attrs={'class': 'form-control'}), 13 | 'system_version': forms.TextInput(attrs={'class': 'form-control'}), 14 | } 15 | -------------------------------------------------------------------------------- /installed/models.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django.db import models 3 | 4 | class SystemInstall(models.Model): 5 | """ 6 | System Install Manage 7 | """ 8 | ip = models.CharField(max_length=20, verbose_name=u'待装机IP') 9 | hostname = models.CharField(max_length=30, verbose_name=u'主机名') 10 | macaddress = models.CharField(max_length=50, verbose_name=u'MAC地址') 11 | system_version = models.CharField(max_length=20, verbose_name=u'操作系统') 12 | install_date = models.DateTimeField(auto_now_add=True, verbose_name=u'安装时间') 13 | 14 | def __unicode__(self): 15 | return u'%s -- %s' %(self.ip, self.install_date) 16 | 17 | class Meta: 18 | verbose_name = u'装机列表' 19 | verbose_name_plural = u'装机列表管理' 20 | 21 | class InstallRecord(models.Model): 22 | """ 23 | Server Install Recored 24 | """ 25 | install_date = models.CharField(max_length=20, verbose_name=u'安装时间') 26 | ip = models.CharField(max_length=20, verbose_name=u'安装IP') 27 | system_version = models.CharField(max_length=20, verbose_name = '安装操作系统版本') 28 | 29 | def __unicode__(self): 30 | return u'%s - %s' %(self.ip, self.system_version) 31 | 32 | class Meta: 33 | verbose_name = u'装机记录' 34 | verbose_name = u'装机记录管理' 35 | -------------------------------------------------------------------------------- /installed/tests.py: -------------------------------------------------------------------------------- 1 | from django.test import TestCase 2 | 3 | # Create your tests here. 4 | -------------------------------------------------------------------------------- /manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import os 3 | import sys 4 | 5 | if __name__ == "__main__": 6 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "oms.settings") 7 | 8 | from django.core.management import execute_from_command_line 9 | 10 | execute_from_command_line(sys.argv) 11 | -------------------------------------------------------------------------------- /oms/.vimrc: -------------------------------------------------------------------------------- 1 | syntax on 2 | filetype plugin indent on 3 | -------------------------------------------------------------------------------- /oms/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/oms/__init__.py -------------------------------------------------------------------------------- /oms/models.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django.db import models 3 | 4 | class Users(models.Model): 5 | """ 6 | OMS User Manage 7 | """ 8 | username = models.CharField(max_length=30, verbose_name=u'用户名') 9 | password = models.CharField(max_length=30, verbose_name=u'密码') 10 | 11 | def __unicode__(self): 12 | return self.username 13 | 14 | class Meta: 15 | verbose_name = u'用户信息' 16 | verbose_name = u'用户信息管理' 17 | 18 | class Message(models.Model): 19 | """ 20 | Platform audit information 21 | """ 22 | audit_time = models.DateTimeField(auto_now_add=True, verbose_name=u'时间') 23 | type = models.CharField(max_length=10, verbose_name=u'类型') 24 | action = models.CharField(max_length=10, verbose_name=u'动作') 25 | action_ip = models.CharField(max_length=15, verbose_name=u'执行IP') 26 | content = models.CharField(max_length=50, verbose_name=u'内容') 27 | 28 | class Meta: 29 | verbose_name = u'审计信息' 30 | verbose_name = u'审计信息管理' 31 | -------------------------------------------------------------------------------- /oms/mysql.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | import MySQLdb 3 | import settings 4 | 5 | class db_operate: 6 | def mysql_command(self,conn,sql_cmd): 7 | try: 8 | ret = [] 9 | conn=MySQLdb.connect(host=conn["host"],user=conn["user"],passwd=conn["password"],db=conn["database"],port=conn["port"],charset="utf8") 10 | cursor = conn.cursor() 11 | n = cursor.execute(sql_cmd) 12 | for row in cursor.fetchall(): 13 | for i in row: 14 | ret.append(i) 15 | except MySQLdb.Error,e: 16 | ret.append(e) 17 | 18 | return ret 19 | 20 | def select_table(self,conn,sql_cmd,parmas): 21 | try: 22 | ret = [] 23 | conn=MySQLdb.connect(host=conn["host"],user=conn["user"],passwd=conn["password"],db=conn["database"],port=conn["port"],charset="utf8") 24 | cursor = conn.cursor() 25 | n = cursor.execute(sql_cmd,parmas) 26 | for row in cursor.fetchall(): 27 | for i in row: 28 | ret.append(i) 29 | except MySQLdb.Error,e: 30 | ret.append(e) 31 | 32 | return ret 33 | 34 | -------------------------------------------------------------------------------- /oms/settings.py: -------------------------------------------------------------------------------- 1 | """ 2 | Django settings for oms project. 3 | 4 | For more information on this file, see 5 | https://docs.djangoproject.com/en/1.6/topics/settings/ 6 | 7 | For the full list of settings and their values, see 8 | https://docs.djangoproject.com/en/1.6/ref/settings/ 9 | """ 10 | 11 | # Build paths inside the project like this: os.path.join(BASE_DIR, ...) 12 | import os 13 | BASE_DIR = os.path.dirname(os.path.dirname(__file__)) 14 | 15 | # Quick-start development settings - unsuitable for production 16 | # See https://docs.djangoproject.com/en/1.6/howto/deployment/checklist/ 17 | 18 | # SECURITY WARNING: keep the secret key used in production secret! 19 | SECRET_KEY = ')_4x-6mbf8j0j=-y)115vr^!#^^%fltpn_2(pro1no9a^_x_st' 20 | 21 | # SECURITY WARNING: don't run with debug turned on in production! 22 | DEBUG = True 23 | 24 | TEMPLATE_DEBUG = True 25 | 26 | TEMPLATE_DIRS = ( 27 | BASE_DIR + '/templates', 28 | ) 29 | 30 | ALLOWED_HOSTS = [] 31 | 32 | 33 | # Application definition 34 | 35 | INSTALLED_APPS = ( 36 | 'django.contrib.admin', 37 | 'django.contrib.auth', 38 | 'django.contrib.contenttypes', 39 | 'django.contrib.sessions', 40 | 'django.contrib.messages', 41 | 'django.contrib.staticfiles', 42 | 'oms', 43 | 'asset', 44 | 'installed', 45 | ) 46 | 47 | MIDDLEWARE_CLASSES = ( 48 | 'django.contrib.sessions.middleware.SessionMiddleware', 49 | 'django.middleware.common.CommonMiddleware', 50 | 'django.middleware.csrf.CsrfViewMiddleware', 51 | 'django.contrib.auth.middleware.AuthenticationMiddleware', 52 | 'django.contrib.messages.middleware.MessageMiddleware', 53 | #'django.middleware.clickjacking.XFrameOptionsMiddleware', 54 | ) 55 | 56 | ROOT_URLCONF = 'oms.urls' 57 | 58 | WSGI_APPLICATION = 'oms.wsgi.application' 59 | 60 | 61 | # Database 62 | # https://docs.djangoproject.com/en/1.6/ref/settings/#databases 63 | 64 | DATABASES = { 65 | 'default': { 66 | 'ENGINE': 'django.db.backends.mysql', 67 | 'NAME': 'oms', 68 | 'USER': 'root', 69 | 'PORT': 63306, 70 | 'PASSWORD': '#', 71 | } 72 | } 73 | 74 | # Internationalization 75 | # https://docs.djangoproject.com/en/1.6/topics/i18n/ 76 | 77 | LANGUAGE_CODE = 'zh-CN' 78 | 79 | TIME_ZONE = 'Asia/Shanghai' 80 | 81 | USE_I18N = True 82 | 83 | USE_L10N = True 84 | 85 | USE_TZ = False 86 | 87 | 88 | # Static files (CSS, JavaScript, Images) 89 | # https://docs.djangoproject.com/en/1.6/howto/static-files/ 90 | 91 | STATIC_URL = '/static/' 92 | 93 | STATICFILES_DIRS = ( 94 | BASE_DIR + '/static', 95 | ) 96 | 97 | try: 98 | from settings_local import * 99 | except ImportError: 100 | pass 101 | -------------------------------------------------------------------------------- /oms/settings_local.py: -------------------------------------------------------------------------------- 1 | SALT_API = {"url": "", 2 | "user": "", 3 | "password": "" 4 | } 5 | 6 | Cobbler_API = {"url": "", 7 | "user": "", 8 | "password": "" 9 | } 10 | 11 | # salt result 12 | RETURNS_MYSQL = {"host": "localhost", 13 | "port": 63306, 14 | "database": "salt", 15 | "user": "salt", 16 | "password": "salt" 17 | } 18 | 19 | SERVICE = {"nginx": "nginx", 20 | "php": "php", 21 | "mysql": "mysql", 22 | "sysinit": "sysinit", 23 | "logstash": "logstash", 24 | "zabbix": "zabbix", 25 | "redis": "redis", 26 | "memcached": "memcached" 27 | } 28 | 29 | OMS_MYSQL = {"host": "localhost", 30 | "port": 63306, 31 | "database": "oms", 32 | "user": "root", 33 | "password": "" 34 | } 35 | -------------------------------------------------------------------------------- /oms/urls.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django.conf.urls import patterns, include, url 3 | from django.contrib import admin 4 | admin.autodiscover() 5 | 6 | # import views 7 | from asset.views import * 8 | from oms.views import index 9 | from installed.views import system_install_managed,system_install_list,system_install,system_install_record 10 | from deploy.views import * 11 | 12 | urlpatterns = patterns('', 13 | # Examples: 14 | # url(r'^$', 'oms.views.home', name='home'), 15 | # url(r'^blog/', include('blog.urls')), 16 | 17 | url(r'^oms/admin/', include(admin.site.urls)), 18 | url(r'^$', index, name='index'), 19 | url(r'^asset/host_list/$', host_list, name='host_list'), 20 | url(r'^asset/add_host/$', host_list_manage, name='add_host'), 21 | url(r'^asset/delete_host/$', host_list_manage, name='host_delete'), 22 | url(r'^asset/host_manage/(?P\d+)/$', host_list_manage, name='host_manage'), 23 | url(r'^asset/server_asset/$', server_asset_list, name='server_asset_list'), 24 | url(r'^asset/server_get/$', get_server_asset, name='get_server_asset'), 25 | url(r'^asset/device_list/$', network_device_list, name='network_device_list'), 26 | url(r'^asset/device_add/$', network_device_discovery, name='add_device'), 27 | url(r'^asset/idc_list/$', idc_asset_list, name='idc_asset_list'), 28 | url(r'^asset/add_idc/$', idc_asset_manage, name='add_idc'), 29 | url(r'^install/install_list/$', system_install_list, name='install_list'), 30 | url(r'^install/install_manage/(?P\d+)/$', system_install_managed, name='install_manage'), 31 | url(r'^install/system_install/$',system_install, name='system_install'), 32 | url(r'^install/install_record/$',system_install_record, name='install_record'), 33 | url(r'^deploy/key_list/$', salt_key_list, name='key_list'), 34 | url(r'^deploy/key_delete/$', salt_delete_key, name='delete_key'), 35 | url(r'^deploy/key_accept/$', salt_accept_key, name='accept_key'), 36 | url(r'^deploy/module_deploy/$', module_deploy, name='module_deploy'), 37 | url(r'^deploy/remote_execution/$', remote_execution, name='remote_execution'), 38 | url(r'^deploy/code_deploy/$', code_deploy, name='code_deploy'), 39 | ) 40 | -------------------------------------------------------------------------------- /oms/views.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from django.http import HttpResponseRedirect 3 | from django.shortcuts import render_to_response 4 | from django.contrib import auth 5 | from django.contrib.auth.decorators import login_required 6 | 7 | def index(request): 8 | return render_to_response('index.html') 9 | 10 | -------------------------------------------------------------------------------- /oms/wsgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | WSGI config for oms project. 3 | 4 | It exposes the WSGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/1.6/howto/deployment/wsgi/ 8 | """ 9 | 10 | import os 11 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "oms.settings") 12 | 13 | from django.core.wsgi import get_wsgi_application 14 | application = get_wsgi_application() 15 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | 组件要求: 2 | 1.Django1.6.X 3 | 2.Cobbler 4 | 3.Saltstack 2014.1.X(只要能实现saltapi.py里list_all_ky函数即可,开发环境为2014.1.4) 5 | 4.Salt API 0.8.4.1 6 | 5.MySQL-python、MySQL 7 | 6.salt_event_to_mysql.py(事件捕捉程序) 8 | -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.eot-: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/fonts/fontawesome-webfont.eot- -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.eot-v=4.0.3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/fonts/fontawesome-webfont.eot-v=4.0.3 -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.ttf-v=4.0.3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/fonts/fontawesome-webfont.ttf-v=4.0.3 -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.woff-v=4.0.3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/fonts/fontawesome-webfont.woff-v=4.0.3 -------------------------------------------------------------------------------- /static/img/avatar.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar.gif -------------------------------------------------------------------------------- /static/img/avatar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar.png -------------------------------------------------------------------------------- /static/img/avatar1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar1.gif -------------------------------------------------------------------------------- /static/img/avatar2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar2.gif -------------------------------------------------------------------------------- /static/img/avatar3.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar3.gif -------------------------------------------------------------------------------- /static/img/avatar4.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar4.gif -------------------------------------------------------------------------------- /static/img/avatar5.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar5.gif -------------------------------------------------------------------------------- /static/img/avatar6.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/avatar6.gif -------------------------------------------------------------------------------- /static/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/favicon.ico -------------------------------------------------------------------------------- /static/img/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/logo.png -------------------------------------------------------------------------------- /static/img/spaceship.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/img/spaceship.gif -------------------------------------------------------------------------------- /static/js/application.js: -------------------------------------------------------------------------------- 1 | var app=function(){var e=function(){t(),o(),a(),l(),n(),i()},t=function(){$("#toggle-left").tooltip()},n=function(){$(".actions > .fa-chevron-down").click(function(){$(this).parent().parent().next().slideToggle("fast"),$(this).toggleClass("fa-chevron-down fa-chevron-up")})},o=function(){$("#toggle-left").bind("click",function(e){$(".sidebarRight").hasClass(".sidebar-toggle-right")||($(".sidebarRight").removeClass("sidebar-toggle-right"),$(".main-content-wrapper").removeClass("main-content-toggle-right")),$(".sidebar").toggleClass("sidebar-toggle"),$(".main-content-wrapper").toggleClass("main-content-toggle-left"),e.stopPropagation()})},a=function(){$("#toggle-right").bind("click",function(e){$(".sidebar").hasClass(".sidebar-toggle")||($(".sidebar").addClass("sidebar-toggle"),$(".main-content-wrapper").addClass("main-content-toggle-left")),$(".sidebarRight").toggleClass("sidebar-toggle-right animated bounceInRight"),$(".main-content-wrapper").toggleClass("main-content-toggle-right"),$(window).width()<660&&($(".sidebar").removeClass("sidebar-toggle"),$(".main-content-wrapper").removeClass("main-content-toggle-left main-content-toggle-right")),e.stopPropagation()})},i=function(){$(".actions > .fa-times").click(function(){$(this).parent().parent().parent().fadeOut()})},l=function(){$("#leftside-navigation .sub-menu > a").click(function(e){$("#leftside-navigation ul ul").slideUp(),$(this).next().is(":visible")||$(this).next().slideDown(),e.stopPropagation()})},s=function(){$(".timer").countTo()},r=function(){$("#map").vectorMap({map:"world_mill_en",backgroundColor:"transparent",regionStyle:{initial:{fill:"#1ABC9C"},hover:{"fill-opacity":.8}},markerStyle:{initial:{r:10},hover:{r:12,stroke:"rgba(255,255,255,0.8)","stroke-width":3}},markers:[{latLng:[27.9881,86.9253],name:"36 Employees",style:{fill:"#E84C3D",stroke:"rgba(255,255,255,0.7)","stroke-width":3}},{latLng:[48.8582,2.2945],name:"58 Employees",style:{fill:"#E84C3D",stroke:"rgba(255,255,255,0.7)","stroke-width":3}},{latLng:[-40.6892,-74.0444],name:"109 Employees",style:{fill:"#E84C3D",stroke:"rgba(255,255,255,0.7)","stroke-width":3}},{latLng:[34.05,-118.25],name:"85 Employees ",style:{fill:"#E84C3D",stroke:"rgba(255,255,255,0.7)","stroke-width":3}}]})},c=function(){var e=new Skycons({color:"white"});e.set("clear-day",Skycons.CLEAR_DAY),e.set("clear-night",Skycons.CLEAR_NIGHT),e.set("partly-cloudy-day",Skycons.PARTLY_CLOUDY_DAY),e.set("partly-cloudy-night",Skycons.PARTLY_CLOUDY_NIGHT),e.set("cloudy",Skycons.CLOUDY),e.set("rain",Skycons.RAIN),e.set("sleet",Skycons.SLEET),e.set("snow",Skycons.SNOW),e.set("wind",Skycons.WIND),e.set("fog",Skycons.FOG),e.play()},g=function(){Morris.Donut({element:"donut-example",data:[{label:"Chrome",value:73},{label:"Firefox",value:71},{label:"Safari",value:69},{label:"Internet Explorer",value:40},{label:"Opera",value:20},{label:"Android Browser",value:10}],colors:["#1abc9c","#293949","#e84c3d","#3598db","#2dcc70","#f1c40f"]})},d=function(){$(".slider-span").slider()};return{init:e,timer:s,map:r,sliders:d,weather:c,morrisPie:g}}();$(document).ready(function(){app.init()}); -------------------------------------------------------------------------------- /static/js/html5shiv.js: -------------------------------------------------------------------------------- 1 | /* 2 | HTML5 Shiv v3.7.0 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed 3 | */ 4 | (function(l,f){function m(){var a=e.elements;return"string"==typeof a?a.split(" "):a}function i(a){var b=n[a[o]];b||(b={},h++,a[o]=h,n[h]=b);return b}function p(a,b,c){b||(b=f);if(g)return b.createElement(a);c||(c=i(b));b=c.cache[a]?c.cache[a].cloneNode():r.test(a)?(c.cache[a]=c.createElem(a)).cloneNode():c.createElem(a);return b.canHaveChildren&&!s.test(a)?c.frag.appendChild(b):b}function t(a,b){if(!b.cache)b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag(); 5 | a.createElement=function(c){return!e.shivMethods?b.createElem(c):p(c,a,b)};a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+m().join().replace(/[\w\-]+/g,function(a){b.createElem(a);b.frag.createElement(a);return'c("'+a+'")'})+");return n}")(e,b.frag)}function q(a){a||(a=f);var b=i(a);if(e.shivCSS&&!j&&!b.hasCSS){var c,d=a;c=d.createElement("p");d=d.getElementsByTagName("head")[0]||d.documentElement;c.innerHTML="x"; 6 | c=d.insertBefore(c.lastChild,d.firstChild);b.hasCSS=!!c}g||t(a,b);return a}var k=l.html5||{},s=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,r=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,j,o="_html5shiv",h=0,n={},g;(function(){try{var a=f.createElement("a");a.innerHTML="";j="hidden"in a;var b;if(!(b=1==a.childNodes.length)){f.createElement("a");var c=f.createDocumentFragment();b="undefined"==typeof c.cloneNode|| 7 | "undefined"==typeof c.createDocumentFragment||"undefined"==typeof c.createElement}g=b}catch(d){g=j=!0}})();var e={elements:k.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video",version:"3.7.0",shivCSS:!1!==k.shivCSS,supportsUnknownElements:g,shivMethods:!1!==k.shivMethods,type:"default",shivDocument:q,createElement:p,createDocumentFragment:function(a,b){a||(a=f); 8 | if(g)return a.createDocumentFragment();for(var b=b||i(a),c=b.frag.cloneNode(),d=0,e=m(),h=e.length;d li { 14 | float: left; 15 | display: list-item; 16 | list-style: none; 17 | margin: 0 5px 10px 0; 18 | } 19 | 20 | ul.wysihtml5-toolbar a[data-wysihtml5-command=bold] { 21 | font-weight: bold; 22 | } 23 | 24 | ul.wysihtml5-toolbar a[data-wysihtml5-command=italic] { 25 | font-style: italic; 26 | } 27 | 28 | ul.wysihtml5-toolbar a[data-wysihtml5-command=underline] { 29 | text-decoration: underline; 30 | } 31 | 32 | ul.wysihtml5-toolbar a.btn.wysihtml5-command-active { 33 | background-image: none; 34 | -webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15),0 1px 2px rgba(0, 0, 0, 0.05); 35 | -moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15),0 1px 2px rgba(0, 0, 0, 0.05); 36 | box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15),0 1px 2px rgba(0, 0, 0, 0.05); 37 | background-color: #E6E6E6; 38 | background-color: #D9D9D9; 39 | outline: 0; 40 | } 41 | 42 | ul.wysihtml5-commands-disabled .dropdown-menu { 43 | display: none !important; 44 | } 45 | 46 | ul.wysihtml5-toolbar div.wysihtml5-colors { 47 | display:block; 48 | width: 50px; 49 | height: 20px; 50 | margin-top: 2px; 51 | margin-left: 5px; 52 | position: absolute; 53 | pointer-events: none; 54 | } 55 | 56 | ul.wysihtml5-toolbar a.wysihtml5-colors-title { 57 | padding-left: 70px; 58 | } 59 | 60 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="black"] { 61 | background: black !important; 62 | } 63 | 64 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="silver"] { 65 | background: silver !important; 66 | } 67 | 68 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="gray"] { 69 | background: gray !important; 70 | } 71 | 72 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="maroon"] { 73 | background: maroon !important; 74 | } 75 | 76 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="red"] { 77 | background: red !important; 78 | } 79 | 80 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="purple"] { 81 | background: purple !important; 82 | } 83 | 84 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="green"] { 85 | background: green !important; 86 | } 87 | 88 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="olive"] { 89 | background: olive !important; 90 | } 91 | 92 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="navy"] { 93 | background: navy !important; 94 | } 95 | 96 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="blue"] { 97 | background: blue !important; 98 | } 99 | 100 | ul.wysihtml5-toolbar div[data-wysihtml5-command-value="orange"] { 101 | background: orange !important; 102 | } -------------------------------------------------------------------------------- /static/plugins/bootstrap-wysihtml5/css/bootstrap3-wysiwyg5-color.css: -------------------------------------------------------------------------------- 1 | .wysiwyg-color-black { 2 | color: black; 3 | } 4 | 5 | .wysiwyg-color-silver { 6 | color: silver; 7 | } 8 | 9 | .wysiwyg-color-gray { 10 | color: gray; 11 | } 12 | 13 | .wysiwyg-color-white { 14 | color: white; 15 | } 16 | 17 | .wysiwyg-color-maroon { 18 | color: maroon; 19 | } 20 | 21 | .wysiwyg-color-red { 22 | color: red; 23 | } 24 | 25 | .wysiwyg-color-purple { 26 | color: purple; 27 | } 28 | 29 | .wysiwyg-color-fuchsia { 30 | color: fuchsia; 31 | } 32 | 33 | .wysiwyg-color-green { 34 | color: green; 35 | } 36 | 37 | .wysiwyg-color-lime { 38 | color: lime; 39 | } 40 | 41 | .wysiwyg-color-olive { 42 | color: olive; 43 | } 44 | 45 | .wysiwyg-color-yellow { 46 | color: yellow; 47 | } 48 | 49 | .wysiwyg-color-navy { 50 | color: navy; 51 | } 52 | 53 | .wysiwyg-color-blue { 54 | color: blue; 55 | } 56 | 57 | .wysiwyg-color-teal { 58 | color: teal; 59 | } 60 | 61 | .wysiwyg-color-aqua { 62 | color: aqua; 63 | } 64 | 65 | .wysiwyg-color-orange { 66 | color: orange; 67 | } -------------------------------------------------------------------------------- /static/plugins/bootstrap/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/bootstrap/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /static/plugins/bootstrap/fonts/glyphicons-halflings-regular.eot-: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/bootstrap/fonts/glyphicons-halflings-regular.eot- -------------------------------------------------------------------------------- /static/plugins/bootstrap/fonts/glyphicons-halflings-regular.eot~.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/bootstrap/fonts/glyphicons-halflings-regular.eot~.eot -------------------------------------------------------------------------------- /static/plugins/bootstrap/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/bootstrap/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /static/plugins/bootstrap/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/bootstrap/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /static/plugins/c3Chart/css/c3.css: -------------------------------------------------------------------------------- 1 | 2 | /*-- Chart --*/ 3 | 4 | svg { 5 | font: 10px sans-serif; 6 | } 7 | path, line { 8 | fill: none; 9 | stroke: #000; 10 | stroke-width: 1px; 11 | } 12 | text { 13 | -webkit-user-select: none; 14 | -moz-user-select: none; 15 | user-select: none; 16 | } 17 | 18 | .chart-arc path { 19 | stroke: #fff; 20 | 21 | } 22 | .chart-arc text { 23 | fill: #fff; 24 | font-size: 13px; 25 | } 26 | 27 | /*-- Grid --*/ 28 | 29 | .grid line { 30 | stroke: #aaa; 31 | } 32 | .grid text { 33 | fill: #aaa; 34 | } 35 | .xgrid, .ygrid { 36 | stroke-dasharray: 3 3; 37 | } 38 | .xgrid-focus { 39 | } 40 | 41 | /*-- Line --*/ 42 | 43 | .-line { 44 | stroke-width: 1px; 45 | } 46 | /*-- Point --*/ 47 | 48 | .-circle._expanded_ { 49 | stroke-width: 1px; 50 | stroke: white; 51 | } 52 | .selected-circle { 53 | fill: white; 54 | stroke-width: 2px; 55 | } 56 | 57 | /*-- Bar --*/ 58 | 59 | .-bar._expanded_ { 60 | stroke-width: 1px; 61 | fill-opacity: 0.6; 62 | } 63 | /* TODO: use this*/ 64 | .-bar._selected_ { 65 | stroke-width: 1px; 66 | fill-opacity: 0.3; 67 | } 68 | .selected-bar { 69 | fill: white; 70 | stroke-width: 2px; 71 | } 72 | 73 | /*-- Arc --*/ 74 | 75 | .chart-arcs-title { 76 | font-size: 1.3em; 77 | } 78 | 79 | /*-- Focus --*/ 80 | 81 | .target.focused path.-line { 82 | stroke-width: 2px; 83 | } 84 | 85 | /*-- Region --*/ 86 | 87 | .region { 88 | fill: steelblue; 89 | fill-opacity: .1; 90 | } 91 | 92 | /*-- Brush --*/ 93 | 94 | .brush .extent { 95 | fill-opacity: .1; 96 | } 97 | 98 | /*-- Select - Drag --*/ 99 | 100 | .dragarea { 101 | } 102 | 103 | /*-- Legend --*/ 104 | 105 | .legend-item { 106 | font-size: 12px; 107 | } 108 | 109 | /*-- Tooltip --*/ 110 | 111 | .-tooltip { 112 | border-collapse:collapse; 113 | border-spacing:0; 114 | background-color:#fff; 115 | empty-cells:show; 116 | -webkit-box-shadow: 7px 7px 12px -9px rgb(119,119,119); 117 | -moz-box-shadow: 7px 7px 12px -9px rgb(119,119,119); 118 | box-shadow: 7px 7px 12px -9px rgb(119,119,119); 119 | opacity: 0.9; 120 | } 121 | .-tooltip tr { 122 | border:1px solid #CCC; 123 | } 124 | .-tooltip th { 125 | background-color: #aaa; 126 | font-size:14px; 127 | padding:2px 5px; 128 | text-align:left; 129 | color:#FFF; 130 | } 131 | .-tooltip td { 132 | font-size:13px; 133 | padding: 3px 6px; 134 | background-color:#fff; 135 | border-left:1px dotted #999; 136 | } 137 | .-tooltip td > span { 138 | display: inline-block; 139 | width: 10px; 140 | height: 10px; 141 | margin-right: 6px; 142 | } 143 | .-tooltip td.value{ 144 | text-align: right; 145 | } 146 | 147 | .-area { 148 | stroke-width: 0; 149 | opacity: 0.2; 150 | } 151 | -------------------------------------------------------------------------------- /static/plugins/c3Chart/js/c3-demo.js: -------------------------------------------------------------------------------- 1 | $(function () { 2 | var chart = c3.generate({ 3 | bindto: '#area-chart', 4 | data: { 5 | columns: [ 6 | ['data1', 300, 350, 300, 0, 0, 0], 7 | ['data2', 130, 100, 140, 200, 150, 50] 8 | ], 9 | types: { 10 | data1: 'area', 11 | data2: 'area-spline' 12 | } 13 | } 14 | }); 15 | 16 | }); 17 | 18 | $(function () { 19 | var chart = c3.generate({ 20 | bindto: '#combination-chart', 21 | data: { 22 | columns: [ 23 | ['data1', 30, 20, 50, 40, 60, 50], 24 | ['data2', 200, 130, 90, 240, 130, 220], 25 | ['data3', 300, 200, 160, 400, 250, 250], 26 | ['data4', 200, 130, 90, 240, 130, 220], 27 | ['data5', 130, 120, 150, 140, 160, 150], 28 | ['data6', 90, 70, 20, 50, 60, 120], 29 | ], 30 | type: 'bar', 31 | types: { 32 | data3: 'spline', 33 | data4: 'line', 34 | data6: 'area', 35 | }, 36 | groups: [ 37 | ['data1','data2'] 38 | ] 39 | }, 40 | axis: { 41 | x: { 42 | type: 'categorized' 43 | } 44 | } 45 | }); 46 | }); 47 | 48 | $(function () { 49 | var chart = c3.generate({ 50 | bindto: '#zoom', 51 | data: { 52 | columns: [ 53 | ['sample', 30, 200, 100, 400, 150, 250, 150, 200, 170, 240, 350, 150, 100, 400, 150, 250, 150, 200, 170, 240, 100, 150, 250, 150, 200, 170, 240, 30, 200, 100, 400, 150, 250, 150, 200, 170, 240, 350, 150, 100, 400, 350, 220, 250, 300, 270, 140, 150, 90, 150, 50, 120, 70, 40] 54 | ] 55 | }, 56 | zoom: { 57 | enabled: true 58 | } 59 | }); 60 | }); 61 | -------------------------------------------------------------------------------- /static/plugins/chartjs/chartjs-demo.js: -------------------------------------------------------------------------------- 1 | var doughnutData = [ 2 | { 3 | value: 30, 4 | color:"#F7464A" 5 | }, 6 | { 7 | value : 50, 8 | color : "#46BFBD" 9 | }, 10 | { 11 | value : 100, 12 | color : "#FDB45C" 13 | }, 14 | { 15 | value : 40, 16 | color : "#949FB1" 17 | }, 18 | { 19 | value : 120, 20 | color : "#4D5360" 21 | } 22 | 23 | ]; 24 | 25 | var myDoughnut = new Chart(document.getElementById("doughnut").getContext("2d")).Doughnut(doughnutData); 26 | 27 | 28 | var lineChartData = { 29 | labels : ["January","February","March","April","May","June","July"], 30 | datasets : [ 31 | { 32 | fillColor : "rgba(220,220,220,0.5)", 33 | strokeColor : "rgba(220,220,220,1)", 34 | pointColor : "rgba(220,220,220,1)", 35 | pointStrokeColor : "#fff", 36 | data : [65,59,90,81,56,55,40] 37 | }, 38 | { 39 | fillColor : "rgba(151,187,205,0.5)", 40 | strokeColor : "rgba(151,187,205,1)", 41 | pointColor : "rgba(151,187,205,1)", 42 | pointStrokeColor : "#fff", 43 | data : [28,48,40,19,96,27,100] 44 | } 45 | ] 46 | 47 | } 48 | 49 | var myLine = new Chart(document.getElementById("line").getContext("2d")).Line(lineChartData); 50 | 51 | 52 | var barChartData = { 53 | labels : ["January","February","March","April","May","June","July"], 54 | datasets : [ 55 | { 56 | fillColor : "rgba(220,220,220,0.5)", 57 | strokeColor : "rgba(220,220,220,1)", 58 | data : [65,59,90,81,56,55,40] 59 | }, 60 | { 61 | fillColor : "rgba(151,187,205,0.5)", 62 | strokeColor : "rgba(151,187,205,1)", 63 | data : [28,48,40,19,96,27,100] 64 | } 65 | ] 66 | 67 | } 68 | 69 | var myLine = new Chart(document.getElementById("bar").getContext("2d")).Bar(barChartData); 70 | 71 | var chartData = [ 72 | { 73 | value : Math.random(), 74 | color: "#D97041" 75 | }, 76 | { 77 | value : Math.random(), 78 | color: "#C7604C" 79 | }, 80 | { 81 | value : Math.random(), 82 | color: "#21323D" 83 | }, 84 | { 85 | value : Math.random(), 86 | color: "#9D9B7F" 87 | }, 88 | { 89 | value : Math.random(), 90 | color: "#7D4F6D" 91 | }, 92 | { 93 | value : Math.random(), 94 | color: "#584A5E" 95 | } 96 | ]; 97 | var myPolarArea = new Chart(document.getElementById("polarArea").getContext("2d")).PolarArea(chartData); 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/README.md: -------------------------------------------------------------------------------- 1 | CKEditor 4 2 | ========== 3 | 4 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 5 | http://ckeditor.com - See LICENSE.md for license information. 6 | 7 | CKEditor is a text editor to be used inside web pages. It's not a replacement 8 | for desktop text editors like Word or OpenOffice, but a component to be used as 9 | part of web applications and websites. 10 | 11 | ## Documentation 12 | 13 | The full editor documentation is available online at the following address: 14 | http://docs.ckeditor.com 15 | 16 | ## Installation 17 | 18 | Installing CKEditor is an easy task. Just follow these simple steps: 19 | 20 | 1. **Download** the latest version from the CKEditor website: 21 | http://ckeditor.com. You should have already completed this step, but be 22 | sure you have the very latest version. 23 | 2. **Extract** (decompress) the downloaded file into the root of your website. 24 | 25 | **Note:** CKEditor is by default installed in the `ckeditor` folder. You can 26 | place the files in whichever you want though. 27 | 28 | ## Checking Your Installation 29 | 30 | The editor comes with a few sample pages that can be used to verify that 31 | installation proceeded properly. Take a look at the `samples` directory. 32 | 33 | To test your installation, just call the following page at your website: 34 | 35 | http:////samples/index.html 36 | 37 | For example: 38 | 39 | http://www.example.com/ckeditor/samples/index.html 40 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/adapters/jquery.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | (function(a){CKEDITOR.config.jqueryOverrideVal="undefined"==typeof CKEDITOR.config.jqueryOverrideVal?!0:CKEDITOR.config.jqueryOverrideVal;"undefined"!=typeof a&&(a.extend(a.fn,{ckeditorGet:function(){var a=this.eq(0).data("ckeditorInstance");if(!a)throw"CKEditor is not initialized yet, use ckeditor() with a callback.";return a},ckeditor:function(g,d){if(!CKEDITOR.env.isCompatible)throw Error("The environment is incompatible.");if(!a.isFunction(g))var k=d,d=g,g=k;var i=[],d=d||{};this.each(function(){var b= 6 | a(this),c=b.data("ckeditorInstance"),f=b.data("_ckeditorInstanceLock"),h=this,j=new a.Deferred;i.push(j.promise());if(c&&!f)g&&g.apply(c,[this]),j.resolve();else if(f)c.once("instanceReady",function(){setTimeout(function(){c.element?(c.element.$==h&&g&&g.apply(c,[h]),j.resolve()):setTimeout(arguments.callee,100)},0)},null,null,9999);else{if(d.autoUpdateElement||"undefined"==typeof d.autoUpdateElement&&CKEDITOR.config.autoUpdateElement)d.autoUpdateElementJquery=!0;d.autoUpdateElement=!1;b.data("_ckeditorInstanceLock", 7 | !0);c=a(this).is("textarea")?CKEDITOR.replace(h,d):CKEDITOR.inline(h,d);b.data("ckeditorInstance",c);c.on("instanceReady",function(d){var e=d.editor;setTimeout(function(){if(e.element){d.removeListener();e.on("dataReady",function(){b.trigger("dataReady.ckeditor",[e])});e.on("setData",function(a){b.trigger("setData.ckeditor",[e,a.data])});e.on("getData",function(a){b.trigger("getData.ckeditor",[e,a.data])},999);e.on("destroy",function(){b.trigger("destroy.ckeditor",[e])});e.on("save",function(){a(h.form).submit(); 8 | return!1},null,null,20);if(e.config.autoUpdateElementJquery&&b.is("textarea")&&a(h.form).length){var c=function(){b.ckeditor(function(){e.updateElement()})};a(h.form).submit(c);a(h.form).bind("form-pre-serialize",c);b.bind("destroy.ckeditor",function(){a(h.form).unbind("submit",c);a(h.form).unbind("form-pre-serialize",c)})}e.on("destroy",function(){b.removeData("ckeditorInstance")});b.removeData("_ckeditorInstanceLock");b.trigger("instanceReady.ckeditor",[e]);g&&g.apply(e,[h]);j.resolve()}else setTimeout(arguments.callee, 9 | 100)},0)},null,null,9999)}});var f=new a.Deferred;this.promise=f.promise();a.when.apply(this,i).then(function(){f.resolve()});this.editor=this.eq(0).data("ckeditorInstance");return this}}),CKEDITOR.config.jqueryOverrideVal&&(a.fn.val=CKEDITOR.tools.override(a.fn.val,function(g){return function(d){if(arguments.length){var k=this,i=[],f=this.each(function(){var b=a(this),c=b.data("ckeditorInstance");if(b.is("textarea")&&c){var f=new a.Deferred;c.setData(d,function(){f.resolve()});i.push(f.promise()); 10 | return!0}return g.call(b,d)});if(i.length){var b=new a.Deferred;a.when.apply(this,i).done(function(){b.resolveWith(k)});return b.promise()}return f}var f=a(this).eq(0),c=f.data("ckeditorInstance");return f.is("textarea")&&c?c.getData():g.call(f)}})))})(window.jQuery); -------------------------------------------------------------------------------- /static/plugins/ckeditor/build-config.js: -------------------------------------------------------------------------------- 1 | /** 2 | * @license Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | * For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | 6 | /** 7 | * This file was added automatically by CKEditor builder. 8 | * You may re-use it at any time to build CKEditor again. 9 | * 10 | * If you would like to build CKEditor online again 11 | * (for example to upgrade), visit one the following links: 12 | * 13 | * (1) http://ckeditor.com/builder 14 | * Visit online builder to build CKEditor from scratch. 15 | * 16 | * (2) http://ckeditor.com/builder/5346be27bc0918d0fd5cc09a6bae537b 17 | * Visit online builder to build CKEditor, starting with the same setup as before. 18 | * 19 | * (3) http://ckeditor.com/builder/download/5346be27bc0918d0fd5cc09a6bae537b 20 | * Straight download link to the latest version of CKEditor (Optimized) with the same setup as before. 21 | * 22 | * NOTE: 23 | * This file is not used by CKEditor, you may remove it. 24 | * Changing this file will not change your CKEditor configuration. 25 | */ 26 | 27 | var CKBUILDER_CONFIG = { 28 | skin: 'moono', 29 | preset: 'standard', 30 | ignore: [ 31 | 'dev', 32 | '.gitignore', 33 | '.gitattributes', 34 | 'README.md', 35 | '.mailmap' 36 | ], 37 | plugins : { 38 | 'a11yhelp' : 1, 39 | 'about' : 1, 40 | 'basicstyles' : 1, 41 | 'blockquote' : 1, 42 | 'clipboard' : 1, 43 | 'contextmenu' : 1, 44 | 'elementspath' : 1, 45 | 'enterkey' : 1, 46 | 'entities' : 1, 47 | 'filebrowser' : 1, 48 | 'floatingspace' : 1, 49 | 'format' : 1, 50 | 'horizontalrule' : 1, 51 | 'htmlwriter' : 1, 52 | 'image' : 1, 53 | 'indentlist' : 1, 54 | 'link' : 1, 55 | 'list' : 1, 56 | 'magicline' : 1, 57 | 'maximize' : 1, 58 | 'pastefromword' : 1, 59 | 'pastetext' : 1, 60 | 'removeformat' : 1, 61 | 'resize' : 1, 62 | 'scayt' : 1, 63 | 'sourcearea' : 1, 64 | 'specialchar' : 1, 65 | 'stylescombo' : 1, 66 | 'tab' : 1, 67 | 'table' : 1, 68 | 'tabletools' : 1, 69 | 'toolbar' : 1, 70 | 'undo' : 1, 71 | 'wsc' : 1, 72 | 'wysiwygarea' : 1 73 | }, 74 | languages : { 75 | 'af' : 1, 76 | 'ar' : 1, 77 | 'bg' : 1, 78 | 'bn' : 1, 79 | 'bs' : 1, 80 | 'ca' : 1, 81 | 'cs' : 1, 82 | 'cy' : 1, 83 | 'da' : 1, 84 | 'de' : 1, 85 | 'el' : 1, 86 | 'en' : 1, 87 | 'en-au' : 1, 88 | 'en-ca' : 1, 89 | 'en-gb' : 1, 90 | 'eo' : 1, 91 | 'es' : 1, 92 | 'et' : 1, 93 | 'eu' : 1, 94 | 'fa' : 1, 95 | 'fi' : 1, 96 | 'fo' : 1, 97 | 'fr' : 1, 98 | 'fr-ca' : 1, 99 | 'gl' : 1, 100 | 'gu' : 1, 101 | 'he' : 1, 102 | 'hi' : 1, 103 | 'hr' : 1, 104 | 'hu' : 1, 105 | 'id' : 1, 106 | 'is' : 1, 107 | 'it' : 1, 108 | 'ja' : 1, 109 | 'ka' : 1, 110 | 'km' : 1, 111 | 'ko' : 1, 112 | 'ku' : 1, 113 | 'lt' : 1, 114 | 'lv' : 1, 115 | 'mk' : 1, 116 | 'mn' : 1, 117 | 'ms' : 1, 118 | 'nb' : 1, 119 | 'nl' : 1, 120 | 'no' : 1, 121 | 'pl' : 1, 122 | 'pt' : 1, 123 | 'pt-br' : 1, 124 | 'ro' : 1, 125 | 'ru' : 1, 126 | 'si' : 1, 127 | 'sk' : 1, 128 | 'sl' : 1, 129 | 'sq' : 1, 130 | 'sr' : 1, 131 | 'sr-latn' : 1, 132 | 'sv' : 1, 133 | 'th' : 1, 134 | 'tr' : 1, 135 | 'ug' : 1, 136 | 'uk' : 1, 137 | 'vi' : 1, 138 | 'zh' : 1, 139 | 'zh-cn' : 1 140 | } 141 | }; -------------------------------------------------------------------------------- /static/plugins/ckeditor/config.js: -------------------------------------------------------------------------------- 1 | /** 2 | * @license Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | * For licensing, see LICENSE.html or http://ckeditor.com/license 4 | */ 5 | 6 | CKEDITOR.editorConfig = function( config ) { 7 | // Define changes to default configuration here. 8 | // For the complete reference: 9 | // http://docs.ckeditor.com/#!/api/CKEDITOR.config 10 | 11 | // The toolbar groups arrangement, optimized for two toolbar rows. 12 | config.toolbarGroups = [ 13 | { name: 'clipboard', groups: [ 'clipboard', 'undo' ] }, 14 | { name: 'editing', groups: [ 'find', 'selection', 'spellchecker' ] }, 15 | { name: 'links' }, 16 | { name: 'insert' }, 17 | { name: 'forms' }, 18 | { name: 'tools' }, 19 | { name: 'document', groups: [ 'mode', 'document', 'doctools' ] }, 20 | { name: 'others' }, 21 | '/', 22 | { name: 'basicstyles', groups: [ 'basicstyles', 'cleanup' ] }, 23 | { name: 'paragraph', groups: [ 'list', 'indent', 'blocks', 'align', 'bidi' ] }, 24 | { name: 'styles' }, 25 | { name: 'colors' }, 26 | { name: 'about' } 27 | ]; 28 | 29 | // Remove some buttons, provided by the standard plugins, which we don't 30 | // need to have in the Standard(s) toolbar. 31 | config.removeButtons = 'Underline,Subscript,Superscript'; 32 | 33 | // Se the most common block elements. 34 | config.format_tags = 'p;h1;h2;h3;pre'; 35 | 36 | // Make dialogs simpler. 37 | config.removeDialogTabs = 'image:advanced;link:advanced'; 38 | }; 39 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/contents.css: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | 6 | body 7 | { 8 | /* Font */ 9 | font-family: sans-serif, Arial, Verdana, "Trebuchet MS"; 10 | font-size: 12px; 11 | 12 | /* Text color */ 13 | color: #333; 14 | 15 | /* Remove the background color to make it transparent */ 16 | background-color: #fff; 17 | 18 | margin: 20px; 19 | } 20 | 21 | .cke_editable 22 | { 23 | font-size: 13px; 24 | line-height: 1.6; 25 | } 26 | 27 | blockquote 28 | { 29 | font-style: italic; 30 | font-family: Georgia, Times, "Times New Roman", serif; 31 | padding: 2px 0; 32 | border-style: solid; 33 | border-color: #ccc; 34 | border-width: 0; 35 | } 36 | 37 | .cke_contents_ltr blockquote 38 | { 39 | padding-left: 20px; 40 | padding-right: 8px; 41 | border-left-width: 5px; 42 | } 43 | 44 | .cke_contents_rtl blockquote 45 | { 46 | padding-left: 8px; 47 | padding-right: 20px; 48 | border-right-width: 5px; 49 | } 50 | 51 | a 52 | { 53 | color: #0782C1; 54 | } 55 | 56 | ol,ul,dl 57 | { 58 | /* IE7: reset rtl list margin. (#7334) */ 59 | *margin-right: 0px; 60 | /* preserved spaces for list items with text direction other than the list. (#6249,#8049)*/ 61 | padding: 0 40px; 62 | } 63 | 64 | h1,h2,h3,h4,h5,h6 65 | { 66 | font-weight: normal; 67 | line-height: 1.2; 68 | } 69 | 70 | hr 71 | { 72 | border: 0px; 73 | border-top: 1px solid #ccc; 74 | } 75 | 76 | img.right 77 | { 78 | border: 1px solid #ccc; 79 | float: right; 80 | margin-left: 15px; 81 | padding: 5px; 82 | } 83 | 84 | img.left 85 | { 86 | border: 1px solid #ccc; 87 | float: left; 88 | margin-right: 15px; 89 | padding: 5px; 90 | } 91 | 92 | pre 93 | { 94 | white-space: pre-wrap; /* CSS 2.1 */ 95 | word-wrap: break-word; /* IE7 */ 96 | } 97 | 98 | .marker 99 | { 100 | background-color: Yellow; 101 | } 102 | 103 | span[lang] 104 | { 105 | font-style: italic; 106 | } 107 | 108 | figure 109 | { 110 | text-align: center; 111 | border: solid 1px #ccc; 112 | border-radius: 2px; 113 | background: rgba(0,0,0,0.05); 114 | padding: 10px; 115 | margin: 10px 20px; 116 | display: block; /* For IE8 */ 117 | } 118 | 119 | figure figcaption 120 | { 121 | text-align: center; 122 | display: block; /* For IE8 */ 123 | } 124 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/a11yhelp/dialogs/a11yhelp.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.dialog.add("a11yHelp",function(j){var a=j.lang.a11yhelp,l=CKEDITOR.tools.getNextId(),e={8:a.backspace,9:a.tab,13:a.enter,16:a.shift,17:a.ctrl,18:a.alt,19:a.pause,20:a.capslock,27:a.escape,33:a.pageUp,34:a.pageDown,35:a.end,36:a.home,37:a.leftArrow,38:a.upArrow,39:a.rightArrow,40:a.downArrow,45:a.insert,46:a["delete"],91:a.leftWindowKey,92:a.rightWindowKey,93:a.selectKey,96:a.numpad0,97:a.numpad1,98:a.numpad2,99:a.numpad3,100:a.numpad4,101:a.numpad5,102:a.numpad6,103:a.numpad7,104:a.numpad8, 6 | 105:a.numpad9,106:a.multiply,107:a.add,109:a.subtract,110:a.decimalPoint,111:a.divide,112:a.f1,113:a.f2,114:a.f3,115:a.f4,116:a.f5,117:a.f6,118:a.f7,119:a.f8,120:a.f9,121:a.f10,122:a.f11,123:a.f12,144:a.numLock,145:a.scrollLock,186:a.semiColon,187:a.equalSign,188:a.comma,189:a.dash,190:a.period,191:a.forwardSlash,192:a.graveAccent,219:a.openBracket,220:a.backSlash,221:a.closeBracket,222:a.singleQuote};e[CKEDITOR.ALT]=a.alt;e[CKEDITOR.SHIFT]=a.shift;e[CKEDITOR.CTRL]=a.ctrl;var f=[CKEDITOR.ALT,CKEDITOR.SHIFT, 7 | CKEDITOR.CTRL],m=/\$\{(.*?)\}/g,p=function(){var a=j.keystrokeHandler.keystrokes,g={},c;for(c in a)g[a[c]]=c;return function(a,c){var b;if(g[c]){b=g[c];for(var h,i,k=[],d=0;d=h&&(b-=i,k.push(e[i]));k.push(e[b]||String.fromCharCode(b));b=k.join("+")}else b=a;return b}}();return{title:a.title,minWidth:600,minHeight:400,contents:[{id:"info",label:j.lang.common.generalTab,expand:!0,elements:[{type:"html",id:"legends",style:"white-space:normal;",focus:function(){this.getElement().focus()}, 8 | html:function(){for(var e='
%1
'+a.contents+" ",g=[],c=a.legend,j=c.length,f=0;f%1
%2
".replace("%1",n.name).replace("%2",o))}g.push("

%1

%2
".replace("%1",b.name).replace("%2",h.join("")))}return e.replace("%1", 9 | g.join(""))}()+''}]}], 10 | buttons:[CKEDITOR.dialog.cancelButton]}}); -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/a11yhelp/dialogs/lang/_translationstatus.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 2 | For licensing, see LICENSE.md or http://ckeditor.com/license 3 | 4 | cs.js Found: 30 Missing: 0 5 | cy.js Found: 30 Missing: 0 6 | da.js Found: 12 Missing: 18 7 | de.js Found: 30 Missing: 0 8 | el.js Found: 25 Missing: 5 9 | eo.js Found: 30 Missing: 0 10 | fa.js Found: 30 Missing: 0 11 | fi.js Found: 30 Missing: 0 12 | fr.js Found: 30 Missing: 0 13 | gu.js Found: 12 Missing: 18 14 | he.js Found: 30 Missing: 0 15 | it.js Found: 30 Missing: 0 16 | mk.js Found: 5 Missing: 25 17 | nb.js Found: 30 Missing: 0 18 | nl.js Found: 30 Missing: 0 19 | no.js Found: 30 Missing: 0 20 | pt-br.js Found: 30 Missing: 0 21 | ro.js Found: 6 Missing: 24 22 | tr.js Found: 30 Missing: 0 23 | ug.js Found: 27 Missing: 3 24 | vi.js Found: 6 Missing: 24 25 | zh-cn.js Found: 30 Missing: 0 26 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/a11yhelp/dialogs/lang/ja.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang("a11yhelp","ja",{title:"ユーザー補助の説明",contents:"ヘルプ このダイアログを閉じるには ESCを押してください。",legend:[{name:"全般",items:[{name:"エディターツールバー",legend:"${toolbarFocus} を押すとツールバーのオン/オフ操作ができます。カーソルをツールバーのグループで移動させるにはTabかSHIFT+Tabを押します。グループ内でカーソルを移動させるには、右カーソルか左カーソルを押します。スペースキーやエンターを押すとボタンを有効/無効にすることができます。"},{name:"編集ダイアログ",legend:"ダイヤログ内では、ダイアログの次の選択肢に移動するにはTabを押します。前の選択肢に移動するには、SHIFT+Tabを押します。ダイアログを決定するには、ENTERを押します。ESCでダイアログをキャンセルできます。複数のタブがあるダイアログではタブリストを操作するにはALT+F10を押します。次のタブに移動するにはTabか右カーソル、前のタブに戻るにはSHIFT+Tabか左カーソルです。タブページを決定するにはスペースもしくは、ENTERキーを押してください。"}, 6 | {name:"エディターのメニュー",legend:"${contextMenu} キーかAPPLICATION KEYを押すとコンテキストメニューが開きます。Tabか下カーソルでメニューのオプション選択が下に移動します。戻るには、SHIFT+Tabか上カーソルです。スペースもしくはENTERキーでメニューオプションを決定できます。現在選んでいるオプションのサブメニューを開くには、スペース、もしくは右カーソルを押します。サブメニューから親メニューに戻るには、ESCか左カーソルを押してください。ESCでコンテキストメニュー自体をキャンセルできます。"},{name:"エディターリストボックス",legend:"リストボックス内で移動するには、Tabか下カーソルで次のアイテムへ移動します。SHIFT+Tabで前のアイテムに戻ります。リストのオプションを選択するには、スペースもしくは、ENTERを押してください。リストボックスを閉じるには、ESCを押してください。"},{name:"エディター要素パスバー",legend:"${elementsPathFocus} を押すとエレメントパスバーを操作出来ます。Tabか右カーソルで次のエレメントを選択できます。前のエレメントを選択するには、SHIFT+Tabか左カーソルです。スペースもしくは、ENTERでエディタ内の対象エレメントを選択出来ます。"}]}, 7 | {name:"コマンド",items:[{name:"元に戻す",legend:"${undo} をクリック"},{name:"やり直し",legend:"${redo} をクリック"},{name:"太字",legend:"${bold} をクリック"},{name:"斜体 ",legend:"${italic} をクリック"},{name:"下線",legend:"${underline} をクリック"},{name:"リンク",legend:"${link} をクリック"},{name:"ツールバーを縮める",legend:"${toolbarCollapse} をクリック"},{name:"前のカーソル移動のできないポイントへ",legend:"${accessPreviousSpace} を押すとカーソルより前にあるカーソルキーで入り込めないスペースへ移動できます。例えば、HRエレメントが2つ接している場合などです。離れた場所へは、複数回キーを押します。"},{name:"次のカーソル移動のできないポイントへ",legend:"${accessNextSpace} を押すとカーソルより後ろにあるカーソルキーで入り込めないスペースへ移動できます。例えば、HRエレメントが2つ接している場合などです。離れた場所へは、複数回キーを押します。"}, 8 | {name:"ユーザー補助ヘルプ",legend:"${a11yHelp} をクリック"}]}],backspace:"Backspace",tab:"Tab",enter:"Enter",shift:"Shift",ctrl:"Ctrl",alt:"Alt",pause:"Pause",capslock:"Caps Lock",escape:"Escape",pageUp:"Page Up",pageDown:"Page Down",end:"End",home:"Home",leftArrow:"左矢印",upArrow:"上矢印",rightArrow:"右矢印",downArrow:"下矢印",insert:"Insert","delete":"Delete",leftWindowKey:"左Windowキー",rightWindowKey:"右のWindowキー",selectKey:"Select",numpad0:"Num 0",numpad1:"Num 1",numpad2:"Num 2",numpad3:"Num 3",numpad4:"Num 4",numpad5:"Num 5", 9 | numpad6:"Num 6",numpad7:"Num 7",numpad8:"Num 8",numpad9:"Num 9",multiply:"掛ける",add:"足す",subtract:"引く",decimalPoint:"小数点",divide:"割る",f1:"F1",f2:"F2",f3:"F3",f4:"F4",f5:"F5",f6:"F6",f7:"F7",f8:"F8",f9:"F9",f10:"F10",f11:"F11",f12:"F12",numLock:"Num Lock",scrollLock:"Scroll Lock",semiColon:"セミコロン",equalSign:"イコール記号",comma:"カンマ",dash:"ダッシュ",period:"ピリオド",forwardSlash:"フォワードスラッシュ",graveAccent:"グレイヴアクセント",openBracket:"開きカッコ",backSlash:"バックスラッシュ",closeBracket:"閉じカッコ",singleQuote:"シングルクォート"}); -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/a11yhelp/dialogs/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang("a11yhelp","zh-cn",{title:"辅助功能说明",contents:"帮助内容。要关闭此对话框请按 ESC 键。",legend:[{name:"常规",items:[{name:"编辑器工具栏",legend:"按 ${toolbarFocus} 导航到工具栏,使用 TAB 键和 SHIFT+TAB 组合键移动到上一个和下一个工具栏组。使用左右箭头键移动到上一个和下一个工具栏按钮。按空格键或回车键以选中工具栏按钮。"},{name:"编辑器对话框",legend:"在对话框内,TAB 键移动到下一个字段,SHIFT + TAB 组合键移动到上一个字段,ENTER 键提交对话框,ESC 键取消对话框。对于有多选项卡的对话框,用ALT + F10来移到选项卡列表。然后用 TAB 键或者向右箭头来移动到下一个选项卡;SHIFT + TAB 组合键或者向左箭头移动到上一个选项卡。用 SPACE 键或者 ENTER 键选择选项卡。"},{name:"编辑器上下文菜单",legend:"用 ${contextMenu} 或者“应用程序键”打开上下文菜单。然后用 TAB 键或者下箭头键来移动到下一个菜单项;SHIFT + TAB 组合键或者上箭头键移动到上一个菜单项。用 SPACE 键或者 ENTER 键选择菜单项。用 SPACE 键,ENTER 键或者右箭头键打开子菜单。返回菜单用 ESC 键或者左箭头键。用 ESC 键关闭上下文菜单。"}, 6 | {name:"编辑器列表框",legend:"在列表框中,移到下一列表项用 TAB 键或者下箭头键。移到上一列表项用SHIFT + TAB 组合键或者上箭头键,用 SPACE 键或者 ENTER 键选择列表项。用 ESC 键收起列表框。"},{name:"编辑器元素路径栏",legend:"按 ${elementsPathFocus} 以导航到元素路径栏,使用 TAB 键或右箭头键选择下一个元素,使用 SHIFT+TAB 组合键或左箭头键选择上一个元素,按空格键或回车键以选定编辑器里的元素。"}]},{name:"命令",items:[{name:" 撤消命令",legend:"按 ${undo}"},{name:" 重做命令",legend:"按 ${redo}"},{name:" 加粗命令",legend:"按 ${bold}"},{name:" 倾斜命令",legend:"按 ${italic}"},{name:" 下划线命令",legend:"按 ${underline}"},{name:" 链接命令",legend:"按 ${link}"},{name:" 工具栏折叠命令",legend:"按 ${toolbarCollapse}"}, 7 | {name:"访问前一个焦点区域的命令",legend:"按 ${accessPreviousSpace} 访问^符号前最近的不可访问的焦点区域,例如:两个相邻的 HR 元素。重复此组合按键可以到达远处的焦点区域。"},{name:"访问下一个焦点区域命令",legend:"按 ${accessNextSpace} 以访问^符号后最近的不可访问的焦点区域。例如:两个相邻的 HR 元素。重复此组合按键可以到达远处的焦点区域。"},{name:"辅助功能帮助",legend:"按 ${a11yHelp}"}]}],backspace:"Backspace",tab:"Tab",enter:"Enter",shift:"Shift",ctrl:"Ctrl",alt:"Alt",pause:"Pause",capslock:"Caps Lock",escape:"Escape",pageUp:"Page Up",pageDown:"Page Down",end:"End",home:"Home",leftArrow:"Left Arrow",upArrow:"Up Arrow",rightArrow:"Right Arrow", 8 | downArrow:"Down Arrow",insert:"Insert","delete":"Delete",leftWindowKey:"Left Windows key",rightWindowKey:"Right Windows key",selectKey:"Select key",numpad0:"Numpad 0",numpad1:"Numpad 1",numpad2:"Numpad 2",numpad3:"Numpad 3",numpad4:"Numpad 4",numpad5:"Numpad 5",numpad6:"Numpad 6",numpad7:"Numpad 7",numpad8:"Numpad 8",numpad9:"Numpad 9",multiply:"Multiply",add:"Add",subtract:"Subtract",decimalPoint:"Decimal Point",divide:"Divide",f1:"F1",f2:"F2",f3:"F3",f4:"F4",f5:"F5",f6:"F6",f7:"F7",f8:"F8",f9:"F9", 9 | f10:"F10",f11:"F11",f12:"F12",numLock:"Num Lock",scrollLock:"Scroll Lock",semiColon:"Semicolon",equalSign:"Equal Sign",comma:"Comma",dash:"Dash",period:"Period",forwardSlash:"Forward Slash",graveAccent:"Grave Accent",openBracket:"Open Bracket",backSlash:"Backslash",closeBracket:"Close Bracket",singleQuote:"Single Quote"}); -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/a11yhelp/dialogs/lang/zh.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang("a11yhelp","zh",{title:"輔助工具指南",contents:"說明內容。若要關閉此對話框請按「ESC」。",legend:[{name:"一般",items:[{name:"編輯器工具列",legend:"請按「${toolbarFocus}」以瀏覽工具列。\r\n利用「TAB」或「SHIFT+TAB」以便移動到下一個或前一個工具列群組。\r\n利用「→」或「←」以便移動到下一個或前一個工具列按鈕。\r\n請按下「空白鍵」或「ENTER」鍵啟動工具列按鈕。"},{name:"編輯器對話方塊",legend:"在對話框中,請按 TAB 鍵以便移動到下個欄位,請按 SHIFT + TAB 以便移動到前個欄位;請按 ENTER 以提交對話框資料,或按下 ESC 取消對話框。\r\n若是有多個頁框的對話框,請按 ALT + F10 以移動到頁框列表,並以 TAB 或是 → 方向鍵移動到下個頁框。以 SHIFT + TAB 或是 ← 方向鍵移動到前個頁框。按下 空白鍵 或是 ENTER 以選取頁框。"},{name:"編輯器內容功能表", 6 | legend:"請按下「${contextMenu}」或是「應用程式鍵」以開啟內容選單。以「TAB」或是「↓」鍵移動到下一個選單選項。以「SHIFT + TAB」或是「↑」鍵移動到上一個選單選項。按下「空白鍵」或是「ENTER」鍵以選取選單選項。以「空白鍵」或「ENTER」或「→」開啟目前選項之子選單。以「ESC」或「←」回到父選單。以「ESC」鍵關閉內容選單」。"},{name:"編輯器清單方塊",legend:"在列表中,請利用 TAB 或 ↓ 方向鍵以移動到下一個項目;或利用 SHIFT + TAB 或 ↑ 方向鍵移動到前一個項目。請按下 空白鍵 或是 ENTER 以選取項目。請按 ESC 關閉列表。"},{name:"編輯器元件路徑工具列",legend:"請按「${elementsPathFocus}」以瀏覽元素路徑工具列。\r\n利用「TAB」或「→」以便移動到下一個元素按鈕。\r\n利用「SHIFT+TAB」或「←」以便移動到前一個元素按鈕。\r\n請按下「空白鍵」或「ENTER」鍵選擇編輯器中的元素。"}]},{name:"命令",items:[{name:"復原命令", 7 | legend:"請按下「${undo}」"},{name:"重複命令",legend:"請按下「 ${redo}」"},{name:"粗體命令",legend:"請按下「${bold}」"},{name:"斜體",legend:"請按下「${italic}」"},{name:"底線命令",legend:"請按下「${underline}」"},{name:"連結",legend:"請按下「${link}」"},{name:"隱藏工具列",legend:"請按下「${toolbarCollapse}」"},{name:"存取前一個焦點空間命令",legend:"請按下 ${accessPreviousSpace} 以存取最近但無法靠近之插字符號前的焦點空間。舉例:二個相鄰的 HR 元素。\r\n重複按鍵以存取較遠的焦點空間。"},{name:"存取下一個焦點空間命令",legend:"請按下 ${accessNextSpace} 以存取最近但無法靠近之插字符號後的焦點空間。舉例:二個相鄰的 HR 元素。\r\n重複按鍵以存取較遠的焦點空間。"},{name:"協助工具說明",legend:"請按下「${a11yHelp}」"}]}], 8 | backspace:"Backspace",tab:"Tab",enter:"Enter",shift:"Shift",ctrl:"Ctrl",alt:"Alt",pause:"Pause",capslock:"Caps Lock",escape:"Escape",pageUp:"Page Up",pageDown:"Page Down",end:"End",home:"Home",leftArrow:"Left Arrow",upArrow:"Up Arrow",rightArrow:"Right Arrow",downArrow:"Down Arrow",insert:"Insert","delete":"Delete",leftWindowKey:"Left Windows key",rightWindowKey:"Right Windows key",selectKey:"Select key",numpad0:"Numpad 0",numpad1:"Numpad 1",numpad2:"Numpad 2",numpad3:"Numpad 3",numpad4:"Numpad 4", 9 | numpad5:"Numpad 5",numpad6:"Numpad 6",numpad7:"Numpad 7",numpad8:"Numpad 8",numpad9:"Numpad 9",multiply:"Multiply",add:"Add",subtract:"Subtract",decimalPoint:"Decimal Point",divide:"Divide",f1:"F1",f2:"F2",f3:"F3",f4:"F4",f5:"F5",f6:"F6",f7:"F7",f8:"F8",f9:"F9",f10:"F10",f11:"F11",f12:"F12",numLock:"Num Lock",scrollLock:"Scroll Lock",semiColon:"Semicolon",equalSign:"Equal Sign",comma:"Comma",dash:"Dash",period:"Period",forwardSlash:"Forward Slash",graveAccent:"Grave Accent",openBracket:"Open Bracket", 10 | backSlash:"Backslash",closeBracket:"Close Bracket",singleQuote:"Single Quote"}); -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/about/dialogs/about.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.dialog.add("about",function(a){var a=a.lang.about,b=CKEDITOR.plugins.get("about").path+"dialogs/"+(CKEDITOR.env.hidpi?"hidpi/":"")+"logo_ckeditor.png";return{title:CKEDITOR.env.ie?a.dlgTitle:a.title,minWidth:390,minHeight:230,contents:[{id:"tab1",label:"",title:"",expand:!0,padding:0,elements:[{type:"html",html:'

CKEditor '+CKEDITOR.version+" (revision "+CKEDITOR.revision+')
http://ckeditor.com

'+a.help.replace("$1",''+ 7 | a.userGuide+"")+"

"+a.moreInfo+'
http://ckeditor.com/about/license

'+a.copy.replace("$1",'CKSource - Frederico Knabben')+"

"}]}],buttons:[CKEDITOR.dialog.cancelButton]}}); -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/about/dialogs/logo_ckeditor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/plugins/about/dialogs/logo_ckeditor.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/clipboard/dialogs/paste.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.dialog.add("paste",function(c){function h(a){var b=new CKEDITOR.dom.document(a.document),f=b.getBody(),d=b.getById("cke_actscrpt");d&&d.remove();f.setAttribute("contenteditable",!0);if(CKEDITOR.env.ie&&8>CKEDITOR.env.version)b.getWindow().on("blur",function(){b.$.selection.empty()});b.on("keydown",function(a){var a=a.data,b;switch(a.getKeystroke()){case 27:this.hide();b=1;break;case 9:case CKEDITOR.SHIFT+9:this.changeFocus(1),b=1}b&&a.preventDefault()},this);c.fire("ariaWidget",new CKEDITOR.dom.element(a.frameElement)); 6 | b.getWindow().getFrame().removeCustomData("pendingFocus")&&f.focus()}var e=c.lang.clipboard;c.on("pasteDialogCommit",function(a){a.data&&c.fire("paste",{type:"auto",dataValue:a.data})},null,null,1E3);return{title:e.title,minWidth:CKEDITOR.env.ie&&CKEDITOR.env.quirks?370:350,minHeight:CKEDITOR.env.quirks?250:245,onShow:function(){this.parts.dialog.$.offsetHeight;this.setupContent();this.parts.title.setHtml(this.customTitle||e.title);this.customTitle=null},onLoad:function(){(CKEDITOR.env.ie7Compat|| 7 | CKEDITOR.env.ie6Compat)&&"rtl"==c.lang.dir&&this.parts.contents.setStyle("overflow","hidden")},onOk:function(){this.commitContent()},contents:[{id:"general",label:c.lang.common.generalTab,elements:[{type:"html",id:"securityMsg",html:'
'+e.securityMsg+"
"},{type:"html",id:"pasteMsg",html:'
'+e.pasteMsg+"
"},{type:"html",id:"editing_area",style:"width:100%;height:100%",html:"",focus:function(){var a=this.getInputElement(), 8 | b=a.getFrameDocument().getBody();!b||b.isReadOnly()?a.setCustomData("pendingFocus",1):b.focus()},setup:function(){var a=this.getDialog(),b=' 64 | 65 |

66 | 67 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/wsc/dialogs/tmpFrameset.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/wsc/dialogs/wsc.css: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.html or http://ckeditor.com/license 4 | */ 5 | 6 | html, body 7 | { 8 | background-color: transparent; 9 | margin: 0px; 10 | padding: 0px; 11 | } 12 | 13 | body 14 | { 15 | padding: 10px; 16 | } 17 | 18 | body, td, input, select, textarea 19 | { 20 | font-size: 11px; 21 | font-family: 'Microsoft Sans Serif' , Arial, Helvetica, Verdana; 22 | } 23 | 24 | .midtext 25 | { 26 | padding:0px; 27 | margin:10px; 28 | } 29 | 30 | .midtext p 31 | { 32 | padding:0px; 33 | margin:10px; 34 | } 35 | 36 | .Button 37 | { 38 | border: #737357 1px solid; 39 | color: #3b3b1f; 40 | background-color: #c7c78f; 41 | } 42 | 43 | .PopupTabArea 44 | { 45 | color: #737357; 46 | background-color: #e3e3c7; 47 | } 48 | 49 | .PopupTitleBorder 50 | { 51 | border-bottom: #d5d59d 1px solid; 52 | } 53 | .PopupTabEmptyArea 54 | { 55 | padding-left: 10px; 56 | border-bottom: #d5d59d 1px solid; 57 | } 58 | 59 | .PopupTab, .PopupTabSelected 60 | { 61 | border-right: #d5d59d 1px solid; 62 | border-top: #d5d59d 1px solid; 63 | border-left: #d5d59d 1px solid; 64 | padding: 3px 5px 3px 5px; 65 | color: #737357; 66 | } 67 | 68 | .PopupTab 69 | { 70 | margin-top: 1px; 71 | border-bottom: #d5d59d 1px solid; 72 | cursor: pointer; 73 | } 74 | 75 | .PopupTabSelected 76 | { 77 | font-weight: bold; 78 | cursor: default; 79 | padding-top: 4px; 80 | border-bottom: #f1f1e3 1px solid; 81 | background-color: #f1f1e3; 82 | } 83 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/plugins/wsc/dialogs/wsc_ie.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.html or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.dialog.add("checkspell",function(a){function c(a,c){var d=0;return function(){"function"==typeof window.doSpell?("undefined"!=typeof e&&window.clearInterval(e),j(a)):180==d++&&window._cancelOnError(c)}}function j(c){var f=new window._SP_FCK_LangCompare,b=CKEDITOR.getUrl(a.plugins.wsc.path+"dialogs/"),e=b+"tmpFrameset.html";window.gFCKPluginName="wsc";f.setDefaulLangCode(a.config.defaultLanguage);window.doSpell({ctrl:g,lang:a.config.wsc_lang||f.getSPLangCode(a.langCode),intLang:a.config.wsc_uiLang|| 6 | f.getSPLangCode(a.langCode),winType:d,onCancel:function(){c.hide()},onFinish:function(b){a.focus();c.getParentEditor().setData(b.value);c.hide()},staticFrame:e,framesetPath:e,iframePath:b+"ciframe.html",schemaURI:b+"wsc.css",userDictionaryName:a.config.wsc_userDictionaryName,customDictionaryName:a.config.wsc_customDictionaryIds&&a.config.wsc_customDictionaryIds.split(","),domainName:a.config.wsc_domainName});CKEDITOR.document.getById(h).setStyle("display","none");CKEDITOR.document.getById(d).setStyle("display", 7 | "block")}var b=CKEDITOR.tools.getNextNumber(),d="cke_frame_"+b,g="cke_data_"+b,h="cke_error_"+b,e,b=document.location.protocol||"http:",i=a.lang.wsc.notAvailable,k='', 8 | l=a.config.wsc_customLoaderScript||b+"//loader.webspellchecker.net/sproxy_fck/sproxy.php?plugin=fck2&customerid="+a.config.wsc_customerId+"&cmd=script&doc=wsc&schema=22";a.config.wsc_customLoaderScript&&(i+='

'+a.lang.wsc.errorLoading.replace(/%s/g,a.config.wsc_customLoaderScript)+"

");window._cancelOnError=function(c){if("undefined"==typeof window.WSC_Error){CKEDITOR.document.getById(d).setStyle("display", 9 | "none");var b=CKEDITOR.document.getById(h);b.setStyle("display","block");b.setHtml(c||a.lang.wsc.notAvailable)}};return{title:a.config.wsc_dialogTitle||a.lang.wsc.title,minWidth:485,minHeight:380,buttons:[CKEDITOR.dialog.cancelButton],onShow:function(){var b=this.getContentElement("general","content").getElement();b.setHtml(k);b.getChild(2).setStyle("height",this._.contentSize.height+"px");"function"!=typeof window.doSpell&&CKEDITOR.document.getHead().append(CKEDITOR.document.createElement("script", 10 | {attributes:{type:"text/javascript",src:l}}));b=a.getData();CKEDITOR.document.getById(g).setValue(b);e=window.setInterval(c(this,i),250)},onHide:function(){window.ooo=void 0;window.int_framsetLoaded=void 0;window.framesetLoaded=void 0;window.is_window_opened=!1},contents:[{id:"general",label:a.config.wsc_dialogTitle||a.lang.wsc.title,padding:0,elements:[{type:"html",id:"content",html:""}]}]}}); 11 | CKEDITOR.dialog.on("resize",function(a){var a=a.data,c=a.dialog;"checkspell"==c._.name&&((c=(c=c.getContentElement("general","content").getElement())&&c.getChild(2))&&c.setSize("height",a.height),c&&c.setSize("width",a.width))}); -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/ajax.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | Ajax — CKEditor Sample 10 | 11 | 12 | 40 | 41 | 42 |

43 | CKEditor Samples » Create and Destroy Editor Instances for Ajax Applications 44 |

45 |
46 |

47 | This sample shows how to create and destroy CKEditor instances on the fly. After the removal of CKEditor the content created inside the editing 48 | area will be displayed in a <div> element. 49 |

50 |

51 | For details of how to create this setup check the source code of this sample page 52 | for JavaScript code responsible for the creation and destruction of a CKEditor instance. 53 |

54 |
55 |

Click the buttons to create and remove a CKEditor instance.

56 |

57 | 58 | 59 |

60 | 61 |
62 |
63 | 71 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/appendto.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | CKEDITOR.appendTo — CKEditor Sample 10 | 11 | 12 | 13 | 14 |

15 | CKEditor Samples » Append To Page Element Using JavaScript Code 16 |

17 |
18 |
19 |

20 | CKEDITOR.appendTo is basically to place editors 21 | inside existing DOM elements. Unlike CKEDITOR.replace, 22 | a target container to be replaced is no longer necessary. A new editor 23 | instance is inserted directly wherever it is desired. 24 |

25 |
CKEDITOR.appendTo( 'container_id',
26 | 	{ /* Configuration options to be used. */ }
27 | 	'Editor content to be used.'
28 | );
29 |
30 | 44 |
45 |
46 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/assets/inlineall/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/samples/assets/inlineall/logo.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/assets/outputxhtml/outputxhtml.css: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | * For licensing, see LICENSE.md or http://ckeditor.com/license 4 | * 5 | * Styles used by the XHTML 1.1 sample page (xhtml.html). 6 | */ 7 | 8 | /** 9 | * Basic definitions for the editing area. 10 | */ 11 | body 12 | { 13 | font-family: Arial, Verdana, sans-serif; 14 | font-size: 80%; 15 | color: #000000; 16 | background-color: #ffffff; 17 | padding: 5px; 18 | margin: 0px; 19 | } 20 | 21 | /** 22 | * Core styles. 23 | */ 24 | 25 | .Bold 26 | { 27 | font-weight: bold; 28 | } 29 | 30 | .Italic 31 | { 32 | font-style: italic; 33 | } 34 | 35 | .Underline 36 | { 37 | text-decoration: underline; 38 | } 39 | 40 | .StrikeThrough 41 | { 42 | text-decoration: line-through; 43 | } 44 | 45 | .Subscript 46 | { 47 | vertical-align: sub; 48 | font-size: smaller; 49 | } 50 | 51 | .Superscript 52 | { 53 | vertical-align: super; 54 | font-size: smaller; 55 | } 56 | 57 | /** 58 | * Font faces. 59 | */ 60 | 61 | .FontComic 62 | { 63 | font-family: 'Comic Sans MS'; 64 | } 65 | 66 | .FontCourier 67 | { 68 | font-family: 'Courier New'; 69 | } 70 | 71 | .FontTimes 72 | { 73 | font-family: 'Times New Roman'; 74 | } 75 | 76 | /** 77 | * Font sizes. 78 | */ 79 | 80 | .FontSmaller 81 | { 82 | font-size: smaller; 83 | } 84 | 85 | .FontLarger 86 | { 87 | font-size: larger; 88 | } 89 | 90 | .FontSmall 91 | { 92 | font-size: 8pt; 93 | } 94 | 95 | .FontBig 96 | { 97 | font-size: 14pt; 98 | } 99 | 100 | .FontDouble 101 | { 102 | font-size: 200%; 103 | } 104 | 105 | /** 106 | * Font colors. 107 | */ 108 | .FontColor1 109 | { 110 | color: #ff9900; 111 | } 112 | 113 | .FontColor2 114 | { 115 | color: #0066cc; 116 | } 117 | 118 | .FontColor3 119 | { 120 | color: #ff0000; 121 | } 122 | 123 | .FontColor1BG 124 | { 125 | background-color: #ff9900; 126 | } 127 | 128 | .FontColor2BG 129 | { 130 | background-color: #0066cc; 131 | } 132 | 133 | .FontColor3BG 134 | { 135 | background-color: #ff0000; 136 | } 137 | 138 | /** 139 | * Indentation. 140 | */ 141 | 142 | .Indent1 143 | { 144 | margin-left: 40px; 145 | } 146 | 147 | .Indent2 148 | { 149 | margin-left: 80px; 150 | } 151 | 152 | .Indent3 153 | { 154 | margin-left: 120px; 155 | } 156 | 157 | /** 158 | * Alignment. 159 | */ 160 | 161 | .JustifyLeft 162 | { 163 | text-align: left; 164 | } 165 | 166 | .JustifyRight 167 | { 168 | text-align: right; 169 | } 170 | 171 | .JustifyCenter 172 | { 173 | text-align: center; 174 | } 175 | 176 | .JustifyFull 177 | { 178 | text-align: justify; 179 | } 180 | 181 | /** 182 | * Other. 183 | */ 184 | 185 | code 186 | { 187 | font-family: courier, monospace; 188 | background-color: #eeeeee; 189 | padding-left: 1px; 190 | padding-right: 1px; 191 | border: #c0c0c0 1px solid; 192 | } 193 | 194 | kbd 195 | { 196 | padding: 0px 1px 0px 1px; 197 | border-width: 1px 2px 2px 1px; 198 | border-style: solid; 199 | } 200 | 201 | blockquote 202 | { 203 | color: #808080; 204 | } 205 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/assets/posteddata.php: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | 11 | Sample — CKEditor 12 | 13 | 14 | 15 |

16 | CKEditor — Posted Data 17 |

18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | $value ) 31 | { 32 | if ( ( !is_string($value) && !is_numeric($value) ) || !is_string($key) ) 33 | continue; 34 | 35 | if ( get_magic_quotes_gpc() ) 36 | $value = htmlspecialchars( stripslashes((string)$value) ); 37 | else 38 | $value = htmlspecialchars( (string)$value ); 39 | ?> 40 | 41 | 42 | 43 | 44 | 48 |
Field NameValue
49 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/assets/sample.css: -------------------------------------------------------------------------------- 1 | /** 2 | * Required by tests (dom/document.html). 3 | */ 4 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/assets/sample.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/samples/assets/sample.jpg -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/assets/uilanguages/languages.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | var CKEDITOR_LANGS=function(){var c={af:"Afrikaans",ar:"Arabic",bg:"Bulgarian",bn:"Bengali/Bangla",bs:"Bosnian",ca:"Catalan",cs:"Czech",cy:"Welsh",da:"Danish",de:"German",el:"Greek",en:"English","en-au":"English (Australia)","en-ca":"English (Canadian)","en-gb":"English (United Kingdom)",eo:"Esperanto",es:"Spanish",et:"Estonian",eu:"Basque",fa:"Persian",fi:"Finnish",fo:"Faroese",fr:"French","fr-ca":"French (Canada)",gl:"Galician",gu:"Gujarati",he:"Hebrew",hi:"Hindi",hr:"Croatian",hu:"Hungarian",id:"Indonesian", 6 | is:"Icelandic",it:"Italian",ja:"Japanese",ka:"Georgian",km:"Khmer",ko:"Korean",ku:"Kurdish",lt:"Lithuanian",lv:"Latvian",mk:"Macedonian",mn:"Mongolian",ms:"Malay",nb:"Norwegian Bokmal",nl:"Dutch",no:"Norwegian",pl:"Polish",pt:"Portuguese (Portugal)","pt-br":"Portuguese (Brazil)",ro:"Romanian",ru:"Russian",si:"Sinhala",sk:"Slovak",sq:"Albanian",sl:"Slovenian",sr:"Serbian (Cyrillic)","sr-latn":"Serbian (Latin)",sv:"Swedish",th:"Thai",tr:"Turkish",ug:"Uighur",uk:"Ukrainian",vi:"Vietnamese",zh:"Chinese Traditional", 7 | "zh-cn":"Chinese Simplified"},b=[],a;for(a in CKEDITOR.lang.languages)b.push({code:a,name:c[a]||a});b.sort(function(a,b){return a.name 2 | 6 | 7 | 8 | 9 | Using the CKEditor Read-Only API — CKEditor Sample 10 | 11 | 12 | 38 | 39 | 40 |

41 | CKEditor Samples » Using the CKEditor Read-Only API 42 |

43 |
44 |

45 | This sample shows how to use the 46 | setReadOnly 47 | API to put editor into the read-only state that makes it impossible for users to change the editor contents. 48 |

49 |

50 | For details on how to create this setup check the source code of this sample page. 51 |

52 |
53 |
54 |

55 | 56 |

57 |

58 | 59 | 60 |

61 |
62 | 72 | 73 | 74 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/sample.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | * For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | 6 | // Tool scripts for the sample pages. 7 | // This file can be ignored and is not required to make use of CKEditor. 8 | 9 | ( function() { 10 | CKEDITOR.on( 'instanceReady', function( ev ) { 11 | // Check for sample compliance. 12 | var editor = ev.editor, 13 | meta = CKEDITOR.document.$.getElementsByName( 'ckeditor-sample-required-plugins' ), 14 | requires = meta.length ? CKEDITOR.dom.element.get( meta[ 0 ] ).getAttribute( 'content' ).split( ',' ) : [], 15 | missing = [], 16 | i; 17 | 18 | if ( requires.length ) { 19 | for ( i = 0; i < requires.length; i++ ) { 20 | if ( !editor.plugins[ requires[ i ] ] ) 21 | missing.push( '' + requires[ i ] + '' ); 22 | } 23 | 24 | if ( missing.length ) { 25 | var warn = CKEDITOR.dom.element.createFromHtml( 26 | '
' + 27 | 'To fully experience this demo, the ' + missing.join( ', ' ) + ' plugin' + ( missing.length > 1 ? 's are' : ' is' ) + ' required.' + 28 | '
' 29 | ); 30 | warn.insertBefore( editor.container ); 31 | } 32 | } 33 | 34 | // Set icons. 35 | var doc = new CKEDITOR.dom.document( document ), 36 | icons = doc.find( '.button_icon' ); 37 | 38 | for ( i = 0; i < icons.count(); i++ ) { 39 | var icon = icons.getItem( i ), 40 | name = icon.getAttribute( 'data-icon' ), 41 | style = CKEDITOR.skin.getIconStyle( name, ( CKEDITOR.lang.dir == 'rtl' ) ); 42 | 43 | icon.addClass( 'cke_button_icon' ); 44 | icon.addClass( 'cke_button__' + name + '_icon' ); 45 | icon.setAttribute( 'style', style ); 46 | icon.setStyle( 'float', 'none' ); 47 | 48 | } 49 | } ); 50 | } )(); 51 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/sample_posteddata.php: -------------------------------------------------------------------------------- 1 |
 2 | 
 3 | -------------------------------------------------------------------------------------------
 4 |   CKEditor - Posted Data
 5 | 
 6 |   We are sorry, but your Web server does not support the PHP language used in this script.
 7 | 
 8 |   Please note that CKEditor can be used with any other server-side language than just PHP.
 9 |   To save the content created with CKEditor you need to read the POST data on the server
10 |   side and write it to a file or the database.
11 | 
12 |   Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved.
13 |   For licensing, see LICENSE.md or http://ckeditor.com/license
14 | -------------------------------------------------------------------------------------------
15 | 
16 | 
*/ include "assets/posteddata.php"; ?> 17 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/tabindex.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | TAB Key-Based Navigation — CKEditor Sample 10 | 11 | 12 | 22 | 42 | 43 | 44 |

45 | CKEditor Samples » TAB Key-Based Navigation 46 |

47 |
48 |

49 | This sample shows how tab key navigation among editor instances is 50 | affected by the tabIndex attribute from 51 | the original page element. Use TAB key to move between the editors. 52 |

53 |
54 |

55 | 56 |

57 |
58 |

59 | 60 |

61 |

62 | 63 |

64 | 74 | 75 | 76 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/samples/uicolor.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | UI Color Picker — CKEditor Sample 10 | 11 | 12 | 13 | 14 |

15 | CKEditor Samples » UI Color 16 |

17 |
18 |

19 | This sample shows how to automatically replace <textarea> elements 20 | with a CKEditor instance with an option to change the color of its user interface.
21 | Note:The UI skin color feature depends on the CKEditor skin 22 | compatibility. The Moono and Kama skins are examples of skins that work with it. 23 |

24 |
25 |
26 |

27 | This editor instance has a UI color value defined in configuration to change the skin color, 28 | To specify the color of the user interface, set the uiColor property: 29 |

30 |
31 | CKEDITOR.replace( 'textarea_id', {
32 | 	uiColor: '#14B8C4'
33 | });
34 |

35 | Note that textarea_id in the code above is the id attribute of 36 | the <textarea> element to be replaced. 37 |

38 |

39 | 40 | 53 |

54 |

55 | 56 |

57 |
58 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/icons.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/icons_hidpi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/icons_hidpi.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/arrow.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/close.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/hidpi/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/hidpi/close.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/hidpi/lock-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/hidpi/lock-open.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/hidpi/lock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/hidpi/lock.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/hidpi/refresh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/hidpi/refresh.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/lock-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/lock-open.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/lock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/lock.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/images/refresh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/ckeditor/skins/moono/images/refresh.png -------------------------------------------------------------------------------- /static/plugins/ckeditor/skins/moono/readme.md: -------------------------------------------------------------------------------- 1 | "Moono" Skin 2 | ==================== 3 | 4 | This skin has been chosen for the **default skin** of CKEditor 4.x, elected from the CKEditor 5 | [skin contest](http://ckeditor.com/blog/new_ckeditor_4_skin) and further shaped by 6 | the CKEditor team. "Moono" is maintained by the core developers. 7 | 8 | For more information about skins, please check the [CKEditor Skin SDK](http://docs.cksource.com/CKEditor_4.x/Skin_SDK) 9 | documentation. 10 | 11 | Features 12 | ------------------- 13 | "Moono" is a monochromatic skin, which offers a modern look coupled with gradients and transparency. 14 | It comes with the following features: 15 | 16 | - Chameleon feature with brightness, 17 | - high-contrast compatibility, 18 | - graphics source provided in SVG. 19 | 20 | Directory Structure 21 | ------------------- 22 | 23 | CSS parts: 24 | - **editor.css**: the main CSS file. It's simply loading several other files, for easier maintenance, 25 | - **mainui.css**: the file contains styles of entire editor outline structures, 26 | - **toolbar.css**: the file contains styles of the editor toolbar space (top), 27 | - **richcombo.css**: the file contains styles of the rich combo ui elements on toolbar, 28 | - **panel.css**: the file contains styles of the rich combo drop-down, it's not loaded 29 | until the first panel open up, 30 | - **elementspath.css**: the file contains styles of the editor elements path bar (bottom), 31 | - **menu.css**: the file contains styles of all editor menus including context menu and button drop-down, 32 | it's not loaded until the first menu open up, 33 | - **dialog.css**: the CSS files for the dialog UI, it's not loaded until the first dialog open, 34 | - **reset.css**: the file defines the basis of style resets among all editor UI spaces, 35 | - **preset.css**: the file defines the default styles of some UI elements reflecting the skin preference, 36 | - **editor_XYZ.css** and **dialog_XYZ.css**: browser specific CSS hacks. 37 | 38 | Other parts: 39 | - **skin.js**: the only JavaScript part of the skin that registers the skin, its browser specific files and its icons and defines the Chameleon feature, 40 | - **icons/**: contains all skin defined icons, 41 | - **images/**: contains a fill general used images, 42 | - **dev/**: contains SVG source of the skin icons. 43 | 44 | License 45 | ------- 46 | 47 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 48 | 49 | Licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html). 50 | 51 | See LICENSE.md for more information. 52 | -------------------------------------------------------------------------------- /static/plugins/countTo/jquery.countTo.js: -------------------------------------------------------------------------------- 1 | (function ($) { 2 | $.fn.countTo = function (options) { 3 | options = options || {}; 4 | 5 | return $(this).each(function () { 6 | // set options for current element 7 | var settings = $.extend({}, $.fn.countTo.defaults, { 8 | from: $(this).data('from'), 9 | to: $(this).data('to'), 10 | speed: $(this).data('speed'), 11 | refreshInterval: $(this).data('refresh-interval'), 12 | decimals: $(this).data('decimals') 13 | }, options); 14 | 15 | // how many times to update the value, and how much to increment the value on each update 16 | var loops = Math.ceil(settings.speed / settings.refreshInterval), 17 | increment = (settings.to - settings.from) / loops; 18 | 19 | // references & variables that will change with each update 20 | var self = this, 21 | $self = $(this), 22 | loopCount = 0, 23 | value = settings.from, 24 | data = $self.data('countTo') || {}; 25 | 26 | $self.data('countTo', data); 27 | 28 | // if an existing interval can be found, clear it first 29 | if (data.interval) { 30 | clearInterval(data.interval); 31 | } 32 | data.interval = setInterval(updateTimer, settings.refreshInterval); 33 | 34 | // initialize the element with the starting value 35 | render(value); 36 | 37 | function updateTimer() { 38 | value += increment; 39 | loopCount++; 40 | 41 | render(value); 42 | 43 | if (typeof(settings.onUpdate) == 'function') { 44 | settings.onUpdate.call(self, value); 45 | } 46 | 47 | if (loopCount >= loops) { 48 | // remove the interval 49 | $self.removeData('countTo'); 50 | clearInterval(data.interval); 51 | value = settings.to; 52 | 53 | if (typeof(settings.onComplete) == 'function') { 54 | settings.onComplete.call(self, value); 55 | } 56 | } 57 | } 58 | 59 | function render(value) { 60 | var formattedValue = settings.formatter.call(self, value, settings); 61 | $self.text(formattedValue); 62 | } 63 | }); 64 | }; 65 | 66 | $.fn.countTo.defaults = { 67 | from: 0, // the number the element should start at 68 | to: 0, // the number the element should end at 69 | speed: 1000, // how long it should take to count between the target numbers 70 | refreshInterval: 100, // how often the element should be updated 71 | decimals: 0, // the number of decimal places to show 72 | formatter: formatter, // handler for formatting the value before rendering 73 | onUpdate: null, // callback method for every time the element is updated 74 | onComplete: null // callback method for when the element finishes updating 75 | }; 76 | 77 | function formatter(value, settings) { 78 | return value.toFixed(settings.decimals); 79 | } 80 | }(jQuery)); 81 | -------------------------------------------------------------------------------- /static/plugins/dataTables/images/sort_asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dataTables/images/sort_asc.png -------------------------------------------------------------------------------- /static/plugins/dataTables/images/sort_asc_disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dataTables/images/sort_asc_disabled.png -------------------------------------------------------------------------------- /static/plugins/dataTables/images/sort_both.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dataTables/images/sort_both.png -------------------------------------------------------------------------------- /static/plugins/dataTables/images/sort_desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dataTables/images/sort_desc.png -------------------------------------------------------------------------------- /static/plugins/dataTables/images/sort_desc_disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dataTables/images/sort_desc_disabled.png -------------------------------------------------------------------------------- /static/plugins/dataTables/js/jquery.dataTables.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dataTables/js/jquery.dataTables.js -------------------------------------------------------------------------------- /static/plugins/dropzone/images/spritemap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dropzone/images/spritemap.png -------------------------------------------------------------------------------- /static/plugins/dropzone/images/spritemap@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/dropzone/images/spritemap@2x.png -------------------------------------------------------------------------------- /static/plugins/flot/js/jquery.colorhelpers.min.js: -------------------------------------------------------------------------------- 1 | (function($){$.color={};$.color.make=function(r,g,b,a){var o={};o.r=r||0;o.g=g||0;o.b=b||0;o.a=a!=null?a:1;o.add=function(c,d){for(var i=0;i=1){return"rgb("+[o.r,o.g,o.b].join(",")+")"}else{return"rgba("+[o.r,o.g,o.b,o.a].join(",")+")"}};o.normalize=function(){function clamp(min,value,max){return valuemax?max:value}o.r=clamp(0,parseInt(o.r),255);o.g=clamp(0,parseInt(o.g),255);o.b=clamp(0,parseInt(o.b),255);o.a=clamp(0,o.a,1);return o};o.clone=function(){return $.color.make(o.r,o.b,o.g,o.a)};return o.normalize()};$.color.extract=function(elem,css){var c;do{c=elem.css(css).toLowerCase();if(c!=""&&c!="transparent")break;elem=elem.parent()}while(elem.length&&!$.nodeName(elem.get(0),"body"));if(c=="rgba(0, 0, 0, 0)")c="transparent";return $.color.parse(c)};$.color.parse=function(str){var res,m=$.color.make;if(res=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10));if(res=/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10),parseFloat(res[4]));if(res=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55);if(res=/rgba\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55,parseFloat(res[4]));if(res=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(str))return m(parseInt(res[1],16),parseInt(res[2],16),parseInt(res[3],16));if(res=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(str))return m(parseInt(res[1]+res[1],16),parseInt(res[2]+res[2],16),parseInt(res[3]+res[3],16));var name=$.trim(str).toLowerCase();if(name=="transparent")return m(255,255,255,0);else{res=lookupColors[name]||[0,0,0];return m(res[0],res[1],res[2])}};var lookupColors={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0]}})(jQuery); -------------------------------------------------------------------------------- /static/plugins/flot/js/jquery.flot.categories.min.js: -------------------------------------------------------------------------------- 1 | (function($){var options={xaxis:{categories:null},yaxis:{categories:null}};function processRawData(plot,series,data,datapoints){var xCategories=series.xaxis.options.mode=="categories",yCategories=series.yaxis.options.mode=="categories";if(!(xCategories||yCategories))return;var format=datapoints.format;if(!format){var s=series;format=[];format.push({x:true,number:true,required:true});format.push({y:true,number:true,required:true});if(s.bars.show||s.lines.show&&s.lines.fill){var autoscale=!!(s.bars.show&&s.bars.zero||s.lines.show&&s.lines.zero);format.push({y:true,number:true,required:false,defaultValue:0,autoscale:autoscale});if(s.bars.horizontal){delete format[format.length-1].y;format[format.length-1].x=true}}datapoints.format=format}for(var m=0;mindex)index=categories[v];return index+1}function categoriesTickGenerator(axis){var res=[];for(var label in axis.categories){var v=axis.categories[label];if(v>=axis.min&&v<=axis.max)res.push([v,label])}res.sort(function(a,b){return a[0]-b[0]});return res}function setupCategoriesForAxis(series,axis,datapoints){if(series[axis].options.mode!="categories")return;if(!series[axis].categories){var c={},o=series[axis].options.categories||{};if($.isArray(o)){for(var i=0;i' + contents + '
').css( { 94 | position: 'absolute', 95 | display: 'none', 96 | top: y + 5, 97 | left: x + 5, 98 | opacity: 0.80 99 | }).appendTo("body").fadeIn(200); 100 | } 101 | 102 | 103 | $('#sales-chart').bind("plothover", function (event, pos, item) { 104 | $("#x").text(pos.x.toFixed(2)); 105 | $("#y").text(pos.y.toFixed(2)); 106 | 107 | if (item) { 108 | if (previousPoint != item.dataIndex) { 109 | previousPoint = item.dataIndex; 110 | 111 | $(".chart-tooltip").remove(); 112 | var x = item.datapoint[0].toFixed(2), 113 | y = item.datapoint[1].toFixed(2); 114 | 115 | showTooltip(item.pageX, item.pageY, y); 116 | } 117 | } 118 | else { 119 | $(".chart-tooltip").remove(); 120 | previousPoint = null; 121 | } 122 | }); 123 | 124 | 125 | sales_chart.init(); 126 | 127 | 128 | })(jQuery); -------------------------------------------------------------------------------- /static/plugins/flot/js/jquery.flot.fillbetween.min.js: -------------------------------------------------------------------------------- 1 | (function($){var options={series:{fillBetween:null}};function init(plot){function findBottomSeries(s,allseries){var i;for(i=0;i=allseries.length){return null}return allseries[s.fillBetween]}return null}function computeFillBottoms(plot,s,datapoints){if(s.fillBetween==null){return}var other=findBottomSeries(s,plot.getData());if(!other){return}var ps=datapoints.pointsize,points=datapoints.points,otherps=other.datapoints.pointsize,otherpoints=other.datapoints.points,newpoints=[],px,py,intery,qx,qy,bottom,withlines=s.lines.show,withbottom=ps>2&&datapoints.format[2].y,withsteps=withlines&&s.lines.steps,fromgap=true,i=0,j=0,l,m;while(true){if(i>=points.length){break}l=newpoints.length;if(points[i]==null){for(m=0;m=otherpoints.length){if(!withlines){for(m=0;mqx){if(withlines&&i>0&&points[i-ps]!=null){intery=py+(points[i-ps+1]-py)*(qx-px)/(points[i-ps]-px);newpoints.push(qx);newpoints.push(intery);for(m=2;m0&&otherpoints[j-otherps]!=null){bottom=qy+(otherpoints[j-otherps+1]-qy)*(px-qx)/(otherpoints[j-otherps]-qx)}i+=ps}fromgap=false;if(l!==newpoints.length&&withbottom){newpoints[l+2]=bottom}}if(withsteps&&l!==newpoints.length&&l>0&&newpoints[l]!==null&&newpoints[l]!==newpoints[l-ps]&&newpoints[l+1]!==newpoints[l-ps+1]){for(m=0;m").load(handler).error(handler).attr("src",url)})};function drawSeries(plot,ctx,series){var plotOffset=plot.getPlotOffset();if(!series.images||!series.images.show)return;var points=series.datapoints.points,ps=series.datapoints.pointsize;for(var i=0;ix2){tmp=x2;x2=x1;x1=tmp}if(y1>y2){tmp=y2;y2=y1;y1=tmp}if(series.images.anchor=="center"){tmp=.5*(x2-x1)/(img.width-1);x1-=tmp;x2+=tmp;tmp=.5*(y2-y1)/(img.height-1);y1-=tmp;y2+=tmp}if(x1==x2||y1==y2||x1>=xaxis.max||x2<=xaxis.min||y1>=yaxis.max||y2<=yaxis.min)continue;var sx1=0,sy1=0,sx2=img.width,sy2=img.height;if(x1xaxis.max){sx2+=(sx2-sx1)*(xaxis.max-x2)/(x2-x1);x2=xaxis.max}if(y1yaxis.max){sy1+=(sy1-sy2)*(yaxis.max-y2)/(y2-y1);y2=yaxis.max}x1=xaxis.p2c(x1);x2=xaxis.p2c(x2);y1=yaxis.p2c(y1);y2=yaxis.p2c(y2);if(x1>x2){tmp=x2;x2=x1;x1=tmp}if(y1>y2){tmp=y2;y2=y1;y1=tmp}tmp=ctx.globalAlpha;ctx.globalAlpha*=series.images.alpha;ctx.drawImage(img,sx1,sy1,sx2-sx1,sy2-sy1,x1+plotOffset.left,y1+plotOffset.top,x2-x1,y2-y1);ctx.globalAlpha=tmp}}function processRawData(plot,series,data,datapoints){if(!series.images.show)return;datapoints.format=[{required:true},{x:true,number:true,required:true},{y:true,number:true,required:true},{x:true,number:true,required:true},{y:true,number:true,required:true}]}function init(plot){plot.hooks.processRawData.push(processRawData);plot.hooks.drawSeries.push(drawSeries)}$.plot.plugins.push({init:init,options:options,name:"image",version:"1.1"})})(jQuery); -------------------------------------------------------------------------------- /static/plugins/flot/js/jquery.flot.resize.min.js: -------------------------------------------------------------------------------- 1 | (function($,t,n){function p(){for(var n=r.length-1;n>=0;n--){var o=$(r[n]);if(o[0]==t||o.is(":visible")){var h=o.width(),d=o.height(),v=o.data(a);!v||h===v.w&&d===v.h?i[f]=i[l]:(i[f]=i[c],o.trigger(u,[v.w=h,v.h=d]))}else v=o.data(a),v.w=0,v.h=0}s!==null&&(s=t.requestAnimationFrame(p))}var r=[],i=$.resize=$.extend($.resize,{}),s,o="setTimeout",u="resize",a=u+"-special-event",f="delay",l="pendingDelay",c="activeDelay",h="throttleWindow";i[l]=250,i[c]=20,i[f]=i[l],i[h]=!0,$.event.special[u]={setup:function(){if(!i[h]&&this[o])return!1;var t=$(this);r.push(this),t.data(a,{w:t.width(),h:t.height()}),r.length===1&&(s=n,p())},teardown:function(){if(!i[h]&&this[o])return!1;var t=$(this);for(var n=r.length-1;n>=0;n--)if(r[n]==this){r.splice(n,1);break}t.removeData(a),r.length||(cancelAnimationFrame(s),s=null)},add:function(t){function s(t,i,s){var o=$(this),u=o.data(a);u.w=i!==n?i:o.width(),u.h=s!==n?s:o.height(),r.apply(this,arguments)}if(!i[h]&&this[o])return!1;var r;if($.isFunction(t))return r=t,s;r=t.handler,t.handler=s}},t.requestAnimationFrame||(t.requestAnimationFrame=function(){return t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e,n){return t.setTimeout(e,i[f])}}()),t.cancelAnimationFrame||(t.cancelAnimationFrame=function(){return t.webkitCancelRequestAnimationFrame||t.mozCancelRequestAnimationFrame||t.oCancelRequestAnimationFrame||t.msCancelRequestAnimationFrame||clearTimeout}())})(jQuery,this);(function($){var options={};function init(plot){function onResize(){var placeholder=plot.getPlaceholder();if(placeholder.width()==0||placeholder.height()==0)return;plot.resize();plot.setupGrid();plot.draw()}function bindEvents(plot,eventHolder){plot.getPlaceholder().resize(onResize)}function shutdown(plot,eventHolder){plot.getPlaceholder().unbind("resize",onResize)}plot.hooks.bindEvents.push(bindEvents);plot.hooks.shutdown.push(shutdown)}$.plot.plugins.push({init:init,options:options,name:"resize",version:"1.0"})})(jQuery); -------------------------------------------------------------------------------- /static/plugins/flot/js/jquery.flot.stack.min.js: -------------------------------------------------------------------------------- 1 | (function($){var options={series:{stack:null}};function init(plot){function findMatchingSeries(s,allseries){var res=null;for(var i=0;i2&&(horizontal?datapoints.format[2].x:datapoints.format[2].y),withsteps=withlines&&s.lines.steps,fromgap=true,keyOffset=horizontal?1:0,accumulateOffset=horizontal?0:1,i=0,j=0,l,m;while(true){if(i>=points.length)break;l=newpoints.length;if(points[i]==null){for(m=0;m=otherpoints.length){if(!withlines){for(m=0;mqx){if(withlines&&i>0&&points[i-ps]!=null){intery=py+(points[i-ps+accumulateOffset]-py)*(qx-px)/(points[i-ps+keyOffset]-px);newpoints.push(qx);newpoints.push(intery+qy);for(m=2;m0&&otherpoints[j-otherps]!=null)bottom=qy+(otherpoints[j-otherps+accumulateOffset]-qy)*(px-qx)/(otherpoints[j-otherps+keyOffset]-qx);newpoints[l+accumulateOffset]+=bottom;i+=ps}fromgap=false;if(l!=newpoints.length&&withbottom)newpoints[l+2]+=bottom}if(withsteps&&l!=newpoints.length&&l>0&&newpoints[l]!=null&&newpoints[l]!=newpoints[l-ps]&&newpoints[l+1]!=newpoints[l-ps+1]){for(m=0;m0&&origpoints[i-ps]!=null){var interx=x+(below-y)*(x-origpoints[i-ps])/(y-origpoints[i-ps+1]);prevp.push(interx);prevp.push(below);for(m=2;m0){var origIndex=$.inArray(s,plot.getData());plot.getData().splice(origIndex+1,0,thresholded)}}function processThresholds(plot,s,datapoints){if(!s.threshold)return;if(s.threshold instanceof Array){s.threshold.sort(function(a,b){return a.below-b.below});$(s.threshold).each(function(i,th){thresholdData(plot,s,datapoints,th.below,th.color)})}else{thresholdData(plot,s,datapoints,s.threshold.below,s.threshold.color)}}plot.hooks.processDatapoints.push(processThresholds)}$.plot.plugins.push({init:init,options:options,name:"threshold",version:"1.2"})})(jQuery); -------------------------------------------------------------------------------- /static/plugins/icheck/css/aero.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/aero.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/aero@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/aero@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/blue.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/blue@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/blue@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/flat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/flat.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/flat@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/flat@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/green.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/green@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/green@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/grey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/grey.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/grey@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/grey@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/orange.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/orange@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/orange@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/pink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/pink.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/pink@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/pink@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/purple.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/purple.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/purple@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/purple@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/red.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/red@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/red@2x.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/yellow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/yellow.png -------------------------------------------------------------------------------- /static/plugins/icheck/css/yellow@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/icheck/css/yellow@2x.png -------------------------------------------------------------------------------- /static/plugins/jvectormap/css/jquery-jvectormap-1.2.2.css: -------------------------------------------------------------------------------- 1 | .jvectormap-label { 2 | position: absolute; 3 | display: none; 4 | border: solid 1px #17212b; 5 | -webkit-border-radius: 3px; 6 | -moz-border-radius: 3px; 7 | border-radius: 3px; 8 | background: #23313F; 9 | color: white; 10 | font-family: sans-serif, Verdana; 11 | font-size: smaller; 12 | padding: 3px; 13 | } 14 | 15 | .jvectormap-zoomin, .jvectormap-zoomout { 16 | position: absolute; 17 | left: 10px; 18 | -webkit-border-radius: 3px; 19 | -moz-border-radius: 3px; 20 | background: #23313F; 21 | padding: 2px; 22 | color: white; 23 | width: 15px; 24 | height: 15px; 25 | cursor: pointer; 26 | line-height: 10px; 27 | text-align: center; 28 | } 29 | 30 | .jvectormap-zoomin { 31 | top: 10px; 32 | } 33 | 34 | .jvectormap-zoomout { 35 | top: 30px; 36 | } 37 | -------------------------------------------------------------------------------- /static/plugins/messenger/css/location-sel.css: -------------------------------------------------------------------------------- 1 | .location-selector { 2 | width: 100%; 3 | height: 250px; 4 | background-color: #eeeeee; 5 | position: relative; } 6 | .location-selector .bit { 7 | background-color: #dddddd; 8 | cursor: pointer; 9 | position: absolute; } 10 | .location-selector .bit:hover { 11 | background-color: #cccccc; } 12 | .location-selector .bit.top, .location-selector .bit.bottom { 13 | height: 25%; 14 | width: 40%; 15 | margin: 0 30%; } 16 | .location-selector .bit.top { 17 | top: 0; } 18 | .location-selector .bit.bottom { 19 | bottom: 0; } 20 | .location-selector .bit.right, .location-selector .bit.left { 21 | height: 20%; 22 | width: 20%; 23 | margin-left: 0; 24 | margin-right: 0; } 25 | .location-selector .bit.right { 26 | right: 0; } 27 | .location-selector .bit.left { 28 | left: 0; } 29 | -------------------------------------------------------------------------------- /static/plugins/messenger/css/messenger.css: -------------------------------------------------------------------------------- 1 | /* line 4, ../../src/sass/messenger.sass */ 2 | ul.messenger { 3 | margin: 0; 4 | padding: 0; 5 | } 6 | /* line 8, ../../src/sass/messenger.sass */ 7 | ul.messenger li { 8 | list-style: none; 9 | margin: 0; 10 | padding: 0; 11 | } 12 | /* line 14, ../../src/sass/messenger.sass */ 13 | ul.messenger.messenger-empty { 14 | display: none; 15 | } 16 | /* line 17, ../../src/sass/messenger.sass */ 17 | ul.messenger .messenger-message { 18 | overflow: hidden; 19 | *zoom: 1; 20 | } 21 | /* line 20, ../../src/sass/messenger.sass */ 22 | ul.messenger .messenger-message.messenger-hidden { 23 | display: none; 24 | } 25 | /* line 23, ../../src/sass/messenger.sass */ 26 | ul.messenger .messenger-message .messenger-phrase, ul.messenger .messenger-message .messenger-actions a { 27 | padding-right: 5px; 28 | } 29 | /* line 26, ../../src/sass/messenger.sass */ 30 | ul.messenger .messenger-message .messenger-actions { 31 | float: right; 32 | } 33 | /* line 29, ../../src/sass/messenger.sass */ 34 | ul.messenger .messenger-message .messenger-actions a { 35 | cursor: pointer; 36 | text-decoration: underline; 37 | } 38 | /* line 33, ../../src/sass/messenger.sass */ 39 | ul.messenger.messenger-fixed { 40 | position: fixed; 41 | z-index: 10000; 42 | } 43 | /* line 37, ../../src/sass/messenger.sass */ 44 | ul.messenger.messenger-fixed .messenger-message { 45 | min-width: 0; 46 | -webkit-box-sizing: border-box; 47 | -moz-box-sizing: border-box; 48 | box-sizing: border-box; 49 | } 50 | /* line 42, ../../src/sass/messenger.sass */ 51 | ul.messenger.messenger-fixed .message .messenger-actions { 52 | float: left; 53 | } 54 | /* line 45, ../../src/sass/messenger.sass */ 55 | ul.messenger.messenger-fixed.messenger-on-top { 56 | top: 20px; 57 | } 58 | /* line 48, ../../src/sass/messenger.sass */ 59 | ul.messenger.messenger-fixed.messenger-on-bottom { 60 | bottom: 20px; 61 | } 62 | /* line 51, ../../src/sass/messenger.sass */ 63 | ul.messenger.messenger-fixed.messenger-on-top, ul.messenger.messenger-fixed.messenger-on-bottom { 64 | left: 50%; 65 | width: 800px; 66 | margin-left: -400px; 67 | } 68 | @media (max-width: 960px) { 69 | /* line 51, ../../src/sass/messenger.sass */ 70 | ul.messenger.messenger-fixed.messenger-on-top, ul.messenger.messenger-fixed.messenger-on-bottom { 71 | left: 10%; 72 | width: 80%; 73 | margin-left: 0px; 74 | } 75 | } 76 | /* line 61, ../../src/sass/messenger.sass */ 77 | ul.messenger.messenger-fixed.messenger-on-top.messenger-on-right, ul.messenger.messenger-fixed.messenger-on-bottom.messenger-on-right { 78 | right: 20px; 79 | left: auto; 80 | } 81 | /* line 65, ../../src/sass/messenger.sass */ 82 | ul.messenger.messenger-fixed.messenger-on-top.messenger-on-left, ul.messenger.messenger-fixed.messenger-on-bottom.messenger-on-left { 83 | left: 260px; 84 | margin-left: 0px; 85 | } 86 | /* line 69, ../../src/sass/messenger.sass */ 87 | ul.messenger.messenger-fixed.messenger-on-right, ul.messenger.messenger-fixed.messenger-on-left { 88 | width: 350px; 89 | } 90 | /* line 72, ../../src/sass/messenger.sass */ 91 | ul.messenger.messenger-fixed.messenger-on-right .messenger-actions, ul.messenger.messenger-fixed.messenger-on-left .messenger-actions { 92 | float: left; 93 | } 94 | /* line 75, ../../src/sass/messenger.sass */ 95 | ul.messenger .messenger-spinner { 96 | display: none; 97 | } 98 | -------------------------------------------------------------------------------- /static/plugins/messenger/js/demo/demo-messages.js: -------------------------------------------------------------------------------- 1 | function showSuccess(msg){ 2 | Messenger().post({ 3 | message: msg, 4 | type: 'success', 5 | showCloseButton: true 6 | }); 7 | } 8 | 9 | function showErrorMessage(msg){ 10 | Messenger().post({ 11 | message: msg, 12 | type: 'error', 13 | showCloseButton: false 14 | }); 15 | } 16 | 17 | function tryAgain(){ 18 | var i = 0; 19 | Messenger().run({ 20 | errorMessage: 'Error destroying alien planet', 21 | successMessage: 'Alien planet destroyed!', 22 | action: function(opts) { 23 | if (++i < 3) { 24 | return opts.error({ 25 | status: 500, 26 | readyState: 0, 27 | responseText: 0 28 | }); 29 | } else { 30 | return opts.success(); 31 | } 32 | } 33 | }); 34 | } 35 | 36 | -------------------------------------------------------------------------------- /static/plugins/messenger/js/demo/demo.js: -------------------------------------------------------------------------------- 1 | $(function(){ 2 | Messenger().post("Thanks for checking out SpaceLab!"); 3 | 4 | var loc = ['bottom', 'right']; 5 | var style = 'flat'; 6 | 7 | var $output = $('.controls output'); 8 | var $lsel = $('.location-selector'); 9 | var $tsel = $('.theme-selector'); 10 | 11 | var update = function(){ 12 | var classes = 'messenger-fixed'; 13 | 14 | for (var i=0; i < loc.length; i++) 15 | classes += ' messenger-on-' + loc[i]; 16 | 17 | $.globalMessenger({ extraClasses: classes, theme: style }); 18 | Messenger.options = { extraClasses: classes, theme: style }; 19 | 20 | $output.text("Messenger.options = {\n extraClasses: '" + classes + "',\n theme: '" + style + "'\n}"); 21 | }; 22 | 23 | update(); 24 | 25 | $lsel.locationSelector() 26 | .on('update', function(pos){ 27 | loc = pos; 28 | 29 | update(); 30 | }) 31 | ; 32 | 33 | $tsel.themeSelector({ 34 | themes: ['flat', 'future', 'block', 'air', 'ice'] 35 | }).on('update', function(theme){ 36 | style = theme; 37 | 38 | update(); 39 | }); 40 | 41 | }); -------------------------------------------------------------------------------- /static/plugins/messenger/js/demo/location-sel.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var LocationSelector, 3 | __hasProp = {}.hasOwnProperty, 4 | __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; 5 | 6 | LocationSelector = (function(_super) { 7 | 8 | __extends(LocationSelector, _super); 9 | 10 | function LocationSelector() { 11 | return LocationSelector.__super__.constructor.apply(this, arguments); 12 | } 13 | 14 | LocationSelector.prototype.className = 'location-selector'; 15 | 16 | LocationSelector.prototype.events = { 17 | 'http://authenticgoods.co/wrapbootstrap/themes/spacelab/assets/plugins/messenger/js/demo/click .bit': 'handleClick' 18 | }; 19 | 20 | LocationSelector.prototype.render = function() { 21 | this.$el.html(''); 22 | return this.draw(); 23 | }; 24 | 25 | LocationSelector.prototype.draw = function() { 26 | this._addBit('top left'); 27 | this._addBit('top right'); 28 | this._addBit('top'); 29 | this._addBit('bottom left'); 30 | this._addBit('bottom right'); 31 | return this._addBit('bottom'); 32 | }; 33 | 34 | LocationSelector.prototype._addBit = function(classes) { 35 | var bit; 36 | bit = $('
'); 37 | bit.addClass("bit " + classes); 38 | bit.attr('data-position', classes); 39 | this.$el.append(bit); 40 | return bit; 41 | }; 42 | 43 | LocationSelector.prototype.handleClick = function(e) { 44 | var $bit; 45 | $bit = $(e.target); 46 | return this.trigger('update', $bit.attr('data-position').split(' ')); 47 | }; 48 | 49 | return LocationSelector; 50 | 51 | })(Backbone.View); 52 | 53 | $.fn.locationSelector = function(opts) { 54 | var loc; 55 | loc = new LocationSelector($.extend({}, opts, { 56 | el: this 57 | })); 58 | $(this).addClass(loc.className); 59 | loc.render(); 60 | return loc; 61 | }; 62 | 63 | }).call(this); 64 | -------------------------------------------------------------------------------- /static/plugins/messenger/js/demo/theme-sel.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var ThemeSelector, 3 | __hasProp = {}.hasOwnProperty, 4 | __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; 5 | 6 | ThemeSelector = (function(_super) { 7 | 8 | __extends(ThemeSelector, _super); 9 | 10 | function ThemeSelector() { 11 | return ThemeSelector.__super__.constructor.apply(this, arguments); 12 | } 13 | 14 | ThemeSelector.prototype.tagName = 'ul'; 15 | 16 | ThemeSelector.prototype.className = 'theme-selector'; 17 | 18 | ThemeSelector.prototype.events = { 19 | 'click li': 'handleClick' 20 | }; 21 | /* 22 | ThemeSelector.prototype.render = function() { 23 | var $li, theme, _i, _len, _ref, _results; 24 | this.$el.html(''); 25 | _ref = this.options.themes; 26 | _results = []; 27 | for (_i = 0, _len = _ref.length; _i < _len; _i++) { 28 | theme = _ref[_i]; 29 | $li = $('
  • '); 30 | $li.attr('data-id', theme); 31 | $li.text(theme); 32 | _results.push(this.$el.append($li)); 33 | } 34 | return _results; 35 | }; 36 | */ 37 | ThemeSelector.prototype.handleClick = function(e) { 38 | var $li; 39 | $li = $(e.target); 40 | return this.trigger('update', $li.attr('data-id')); 41 | }; 42 | 43 | return ThemeSelector; 44 | 45 | })(Backbone.View); 46 | 47 | $.fn.themeSelector = function(opts) { 48 | var sel; 49 | sel = new ThemeSelector($.extend({}, opts, { 50 | el: this 51 | })); 52 | $(this).addClass(sel.className); 53 | sel.render(); 54 | return sel; 55 | }; 56 | 57 | }).call(this); 58 | -------------------------------------------------------------------------------- /static/plugins/messenger/js/messenger-theme-future.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var $, FutureMessage, spinner_template, 3 | __hasProp = {}.hasOwnProperty, 4 | __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; 5 | 6 | $ = jQuery; 7 | 8 | spinner_template = '
    \n \n \n \n \n \n \n
    '; 9 | 10 | FutureMessage = (function(_super) { 11 | 12 | __extends(FutureMessage, _super); 13 | 14 | function FutureMessage() { 15 | return FutureMessage.__super__.constructor.apply(this, arguments); 16 | } 17 | 18 | FutureMessage.prototype.template = function(opts) { 19 | var $message; 20 | $message = FutureMessage.__super__.template.apply(this, arguments); 21 | $message.append($(spinner_template)); 22 | return $message; 23 | }; 24 | 25 | return FutureMessage; 26 | 27 | })(window.Messenger.Message); 28 | 29 | window.Messenger.themes.future = { 30 | Message: FutureMessage 31 | }; 32 | 33 | }).call(this); 34 | -------------------------------------------------------------------------------- /static/plugins/morris/css/morris.css: -------------------------------------------------------------------------------- 1 | .morris-hover{position:absolute;z-index:1000;}.morris-hover.morris-default-style{border-radius:10px;padding:6px;color:#666;background:rgba(255, 255, 255, 0.8);border:solid 2px rgba(230, 230, 230, 0.8);font-family:sans-serif;font-size:12px;text-align:center;}.morris-hover.morris-default-style .morris-hover-row-label{font-weight:bold;margin:0.25em 0;} 2 | .morris-hover.morris-default-style .morris-hover-point{white-space:nowrap;margin:0.1em 0;} 3 | -------------------------------------------------------------------------------- /static/plugins/morris/js/morris-example.js: -------------------------------------------------------------------------------- 1 | // Updating 2 | var nReloads = 0; 3 | 4 | function data(offset) { 5 | var ret = []; 6 | for (var x = 0; x <= 360; x += 10) { 7 | var v = (offset + x) % 360; 8 | ret.push({ 9 | x: x, 10 | y: Math.sin(Math.PI * v / 180).toFixed(4), 11 | z: Math.cos(Math.PI * v / 180).toFixed(4) 12 | }); 13 | } 14 | return ret; 15 | } 16 | var graph = Morris.Line({ 17 | element: 'graph', 18 | data: data(0), 19 | xkey: 'x', 20 | ykeys: ['y', 'z'], 21 | labels: ['sin()', 'cos()'], 22 | parseTime: false, 23 | ymin: -1.0, 24 | ymax: 1.0, 25 | lineColors: ['#1ABC9C'], 26 | pointFillColors: ['#19a88b'], 27 | hideHover: true 28 | }); 29 | 30 | // Area as Line 31 | 32 | function update() { 33 | nReloads++; 34 | graph.setData(data(5 * nReloads)); 35 | $('#reloadStatus').text(nReloads + ' reloads'); 36 | } 37 | setInterval(update, 100); 38 | 39 | Morris.Area({ 40 | element: 'area-as-line', 41 | behaveLikeLine: false, 42 | data: [ 43 | {x: '2014 Q1', y: 3, z: 3}, 44 | {x: '2014 Q2', y: 2, z: 1}, 45 | {x: '2014 Q3', y: 2, z: 4}, 46 | {x: '2014 Q4', y: 3, z: 3} 47 | ], 48 | xkey: 'x', 49 | ykeys: ['y', 'z'], 50 | labels: ['Y', 'Z'], 51 | lineColors:['#1ABC9C','#293949'] 52 | 53 | }); 54 | 55 | //Donut 56 | Morris.Donut({ 57 | element: 'donut', 58 | data: [ 59 | {value: 70, label: 'foo', formatted: 'at least 70%' }, 60 | {value: 15, label: 'bar', formatted: 'approx. 15%' }, 61 | {value: 10, label: 'baz', formatted: 'approx. 10%' }, 62 | {value: 5, label: 'A really really long label', formatted: 'at most 5%' } 63 | ], 64 | backgroundColor: '#fff', 65 | labelColor: '#1abc9c', 66 | colors: [ 67 | '#1abc9c','#2dcc70','#f1c40f','#e84c3d' 68 | ], 69 | formatter: function (x, data) { return data.formatted; } 70 | }); 71 | 72 | 73 | // Use Morris.Bar 74 | Morris.Bar({ 75 | element: 'bar', 76 | data: [ 77 | {x: '2014 Q1', y: 3, z: 2, a: 3}, 78 | {x: '2014 Q2', y: 2, z: null, a: 1}, 79 | {x: '2014 Q3', y: 0, z: 2, a: 4}, 80 | {x: '2014 Q4', y: 2, z: 4, a: 3} 81 | ], 82 | xkey: 'x', 83 | ykeys: ['y', 'z', 'a'], 84 | labels: ['Y', 'Z', 'A'], 85 | barColors:['#1abc9c','#2dcc70','#e84c3d'] 86 | 87 | 88 | }); 89 | -------------------------------------------------------------------------------- /static/plugins/morris/js/raphael.2.1.0.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/morris/js/raphael.2.1.0.min.js -------------------------------------------------------------------------------- /static/plugins/todo/css/todos.css: -------------------------------------------------------------------------------- 1 | 2 | 3 | #todo-list { 4 | margin: 10px 0; 5 | padding: 0; 6 | list-style: none; 7 | } 8 | #todo-list li { 9 | background: #F1F2F7; 10 | -webkit-border-radius: 3px; 11 | -moz-border-radius: 3px; 12 | border-radius: 3px; 13 | position: relative; 14 | padding: 10px; 15 | margin-bottom: 5px; 16 | font-size: 16px; 17 | font-weight: normal; 18 | 19 | } 20 | #todo-list li.done label { 21 | 22 | 23 | text-decoration: line-through; 24 | } 25 | label[data='done']{ 26 | color: #ABADB1; 27 | } 28 | #todo-list .destroy { 29 | position: absolute; 30 | right: 16px; 31 | top: 13px; 32 | display: none; 33 | cursor: pointer; 34 | width: 20px; 35 | height: 20px; 36 | background: url(../img/destroy.png) no-repeat; 37 | } 38 | #todo-list li:hover .destroy { 39 | display: block; 40 | } 41 | #todo-list .destroy:hover { 42 | background-position: 0 -20px; 43 | } 44 | 45 | input[type=checkbox]{ 46 | margin:0 10px; 47 | } 48 | #todo-list li.editing { 49 | border-bottom: none; 50 | margin-top: -1px; 51 | padding: 0; 52 | } 53 | #todo-list li.editing:last-child { 54 | margin-bottom: -1px; 55 | } 56 | #todo-list li.editing .edit { 57 | display: block; 58 | width: 444px; 59 | padding: 13px 15px 14px 20px; 60 | margin: 0; 61 | } 62 | #todo-list li.editing .view { 63 | display: none; 64 | } 65 | #todo-list li .view label { 66 | word-break: break-word; 67 | } 68 | #todo-list li .edit { 69 | display: none; 70 | } 71 | #todoapp footer { 72 | display: none; 73 | margin: 0 -20px -20px -20px; 74 | overflow: hidden; 75 | color: #555555; 76 | background: #f4fce8; 77 | border-top: 1px solid #ededed; 78 | padding: 0 20px; 79 | line-height: 37px; 80 | -webkit-border-radius: 0 0 5px 5px; 81 | -moz-border-radius: 0 0 5px 5px; 82 | -ms-border-radius: 0 0 5px 5px; 83 | -o-border-radius: 0 0 5px 5px; 84 | border-radius: 0 0 5px 5px; 85 | } 86 | -------------------------------------------------------------------------------- /static/plugins/todo/img/destroy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/binbin91/oms/a99edc4873c0207a6fd20e60bc616c87d4fd2db8/static/plugins/todo/img/destroy.png -------------------------------------------------------------------------------- /static/plugins/todo/js/todos.js: -------------------------------------------------------------------------------- 1 | var EnterKey = 13; 2 | 3 | $.fn.isBound = function(type, fn) { 4 | var data = this.data('events')[type]; 5 | 6 | if (data === undefined || data.length === 0) { 7 | return false; 8 | } 9 | 10 | return (-1 !== $.inArray(fn, data)); 11 | }; 12 | 13 | $(document).ready(function() { 14 | function runBind() { 15 | $('.destroy').on('click', function(e) { 16 | $currentListItem = $(this).closest('li'); 17 | 18 | $currentListItem.remove(); 19 | }); 20 | 21 | $('.toggle').on('click', function(e) { 22 | var $currentListItemLabel = $(this).closest('li').find('label'); 23 | /* 24 | * Do this or add css and remove JS dynamic css. 25 | */ 26 | if ( $currentListItemLabel.attr('data') == 'done' ) { 27 | $currentListItemLabel.attr('data', ''); 28 | $currentListItemLabel.css('text-decoration', 'none'); 29 | } 30 | else { 31 | $currentListItemLabel.attr('data', 'done'); 32 | $currentListItemLabel.css('text-decoration', 'line-through'); 33 | } 34 | }); 35 | } 36 | 37 | 38 | $todoList = $('#todo-list'); 39 | $('#new-todo').keypress(function(e) { 40 | if (e.which === EnterKey) { 41 | $('.destroy').off('click'); 42 | $('.toggle').off('click'); 43 | var todos = $todoList.html(); 44 | todos += ""+ 45 | "
  • " + 46 | "
    " + 47 | "" + 48 | "" + 49 | "" + 50 | "
    " + 51 | "
  • "; 52 | 53 | $(this).val(''); 54 | $todoList.html(todos); 55 | runBind(); 56 | $('#main').show(); 57 | 58 | }}); // end if 59 | 60 | $('#todo-enter').click(function(e) { 61 | $('.destroy').off('click'); 62 | $('.toggle').off('click'); 63 | var todos = $todoList.html(); 64 | todos += ""+ 65 | "
  • " + 66 | "
    " + 67 | "" + 68 | "" + 69 | "" + 70 | "
    " + 71 | "
  • "; 72 | 73 | $(this).val(''); 74 | $todoList.html(todos); 75 | runBind(); 76 | $('#main').show(); 77 | 78 | }); 79 | 80 | }); 81 | 82 | -------------------------------------------------------------------------------- /templates/404.html: -------------------------------------------------------------------------------- 1 | {% extends "index.html" %} 2 | {% block title %}OMS{% endblock %} 3 | {% block container %} 4 |
    5 | 6 |
    7 | 8 |
    9 |

    404

    10 |

    Page not found

    11 |
    12 | 13 |

    Houston, we have a problem. We're having trouble loading the page you are looking for.

    14 |
    15 |
    16 | Back to Dashboard 17 |
    18 |
    19 | 20 |
    21 |
    22 |
    23 | 24 |
    25 | 26 | {% endblock %} 27 | -------------------------------------------------------------------------------- /templates/500.html: -------------------------------------------------------------------------------- 1 | {% extends "index.html" %} 2 | {% block title %}500-OMS{% endblock %} 3 | {% block container %} 4 |
    5 | 6 |
    7 | 8 |
    9 |

    500

    10 |

    Something went wrong.

    11 |
    12 | 13 |

    Houston, we have a problem. Please try again later.

    14 |
    15 |
    16 | Back to Dashboard 17 |
    18 |
    19 |
    20 | 21 |
    22 | 23 | {% endblock %} 24 | -------------------------------------------------------------------------------- /templates/login.html: -------------------------------------------------------------------------------- 1 | {% extends "index.html" %} 2 | {% block title %}登录OMS{% endblock %} 3 | {% block container %} 4 |
    5 | 6 |
    7 |
    8 |
    9 |
    10 |

    11 | Sign In 12 |

    13 |
    14 |
    15 |

    Login to access your account.

    16 |
    17 |
    18 |
    19 | 20 | 21 |
    22 |
    23 |
    24 |
    25 | 26 | 27 | Forgot Your Password? 28 |
    29 |
    30 |
    31 |
    32 | Sign in 33 |
    34 | Not a member? Sign Up 35 |
    36 |
    37 |
    38 |
    39 |
    40 |
    41 |
    42 | 43 |
    44 | 45 | {% endblock %} 46 | -------------------------------------------------------------------------------- /templates/salt_key_list.html: -------------------------------------------------------------------------------- 1 | {% extends "index.html" %} 2 | {% block title %}OMS{% endblock %} 3 | {% block css %} 4 | 5 | 6 | {% endblock %} 7 | {% block content %} 8 |
    9 |
    10 | 11 | 17 | 18 |

    Key管理

    19 |
    20 |
    21 | 22 |
    23 |
    24 |
    25 |
    26 | 27 | 28 | 29 | 30 |
    所有salt-key列表
    31 |

    未允许的key

    32 | 33 | 34 | {% for each_pre in all_minions_pre %} 35 | 36 | 37 | {% endfor %} 38 | 39 |
    {{ each_pre }}允许
    40 |

    已管理的key

    41 | 42 | 43 | {% for each_minion in all_minions %} 44 | 45 | 46 | 47 | 48 | {% endfor %} 49 | 50 |
    {{ each_minion }}删除
    51 |
    52 |
    53 | 54 |
    55 |
    56 |
    57 |
    58 |
    59 |
    60 |
    61 |
    62 |
    63 |
    64 | 65 | 66 | {% endblock %} 67 | -------------------------------------------------------------------------------- /templates/salt_remote_execution.html: -------------------------------------------------------------------------------- 1 | {% extends "index.html" %} 2 | {% block title %}OMS{% endblock %} 3 | {% block content %} 4 |
    5 |
    6 | 7 | 13 | 14 |

    命令执行

    15 |
    16 |
    17 | 18 |
    19 |
    20 |
    21 |
    22 |
    23 | {% csrf_token %} 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 | {% endblock %} 55 | -------------------------------------------------------------------------------- /templates/sign-up.html: -------------------------------------------------------------------------------- 1 | {% extends "index.html" %} 2 | {% block title %}OMS{% endblock %} 3 | {% block container %} 4 |
    5 | 6 |
    7 |
    8 |
    9 |
    10 |

    11 | Sign Up 12 |

    13 |
    14 |
    15 |

    Already a member? 16 | 17 | Sign In 18 | 19 |

    20 |
    21 |
    22 | 23 | 24 |
    25 |
    26 | 27 | 28 |
    29 |
    30 | 31 | 32 |
    33 | 34 | Sign Up 35 |
    36 | 37 |
    38 |
    39 |
    40 |
    41 | 42 |
    43 | 44 | {% endblock %} 45 | --------------------------------------------------------------------------------