forked from xufei/ng-control
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.js
2 lines (2 loc) · 12.6 KB
/
app.js
1
2
!function(e){function n(a){if(t[a])return t[a].exports;var o=t[a]={exports:{},id:a,loaded:!1};return e[a].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}({0:function(e,n,t){"use strict";function a(e){return e&&e.__esModule?e:{"default":e}}var o=t(82),r=a(o);angular.module("snail",["sn.components",r["default"]])},68:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}var a=function(){function e(e,n){for(var t=0;t<n.length;t++){var a=n[t];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}return function(n,t,a){return t&&e(n.prototype,t),a&&e(n,a),n}}();Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(n,a){t(this,e),this.AlertService=a,n.myAlert=this.myAlert.bind(this),n.myAlertWithHint=this.myAlertWithHint.bind(this),n.myConfirm=this.myConfirm.bind(this)}return a(e,[{key:"myAlert",value:function(){this.AlertService.alert({title:"测试",content:"你好,我是警告"}).then(function(){alert("你刚才点了确定")})}},{key:"myAlertWithHint",value:function(){this.AlertService.alert({title:"测试",content:"你好,我是警告",hint:["操作提示1","如果想要在操作的时候给点提示,那就写在这里"]}).then(function(){alert("你刚才点了确定")})}},{key:"myConfirm",value:function(){this.AlertService.confirm({title:"测试",contents:["你好,确定要删除以下内容吗?","aaa, bbb"]}).then(function(){alert("你刚才点了确定")},function(){alert("你刚才点了取消")})}}]),e}();n["default"]=o,o.$inject=["$scope","AlertService"]},69:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){t(this,o),e.checkValue=!1};n["default"]=a,a.$inject=["$scope"]},70:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){t(this,o),e.students=[{name:"Tom",age:18,gender:"Male"},{name:"Lily",age:15,gender:"Female"},{name:"Jerry",age:14,gender:"Male"}],e.itemMenu=function(e){var n=[{title:"greet",action:function(){alert("Hello, I am "+e.name)}},{title:"divider"},{title:"sleep",action:function(){alert("zzz")}}];return e.age>=18&&n.push({title:"smoke",action:function(){alert("I am adult, I can smoke!")}}),"Female"==e.gender&&n.push({title:"make up",action:function(){alert("I am a girl, am I beautiful?")}}),n}};n["default"]=a,a.$inject=["$scope"]},71:function(e,n,t){"use strict";function a(e){return e&&e.__esModule?e:{"default":e}}function o(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var r=t(125),l=a(r),i=t(127),c=a(i),u=t(126),s=a(u),d=t(124),f=a(d),h=function m(e){o(this,m),e.cols=[{label:"Name",key:"name"},{label:"Age",key:"age"},{label:"Gender",key:"gender"}],e.students=[{name:"Tom",age:18,gender:"1"},{name:"Lily",age:15,gender:"0"},{name:"Jerry",age:14,gender:"1"}],e.checkboxCols=[{label:"",key:"$checked"},{label:"Name",key:"name"},{label:"Age",key:"age"},{label:"Gender",key:"gender"}],e.checkboxTpl=l["default"],e.sortHeaderTpl=c["default"],e.headerSort=function(n){e.desc=!e.desc,e.desc?e.students.sort(function(e,t){return e[n]-t[n]}):e.students.sort(function(e,t){return t[n]-e[n]})},e.checkboxHeaderTpl=s["default"],e.buttonCellTpl=f["default"],e.buttonCols=[{label:"",key:"$checked"},{label:"Name",key:"name"},{label:"Age",key:"age"},{label:"Gender",key:"gender"},{label:"",key:"$operation"}]};n["default"]=h,h.$inject=["$scope"]},72:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}var a=function(){function e(e,n){for(var t=0;t<n.length;t++){var a=n[t];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}return function(n,t,a){return t&&e(n.prototype,t),a&&e(n,a),n}}();Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){t(this,e),this.oneDay=new Date(2012,3,9),this.anotherDay=new Date(2012,11,2,3,4,5),this.year=this.oneDay.getFullYear(),this.month=this.oneDay.getMonth(),this.date=this.oneDay.getDate(),this.min=new Date(2015,8,3),this.max=new Date(2016,2,1),this.fromDate=new Date(1995,1,3),this.toDate=new Date(2016,7,6),this.hour=3,this.minute=4,this.second=5}return a(e,[{key:"click",value:function(){alert(111)}}]),e}();n["default"]=o},73:function(e,n,t){"use strict";function a(e){return e&&e.__esModule?e:{"default":e}}function o(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}var r=function(){function e(e,n){for(var t=0;t<n.length;t++){var a=n[t];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}return function(n,t,a){return t&&e(n.prototype,t),a&&e(n,a),n}}();Object.defineProperty(n,"__esModule",{value:!0}),n.TestDialogController=n.DialogController=void 0;var l=t(128),i=a(l),c=n.DialogController=function(){function e(n){o(this,e),this.DialogService=n,this.name="aaaa"}return r(e,[{key:"myDialog",value:function(){var e=this;this.DialogService.modal(i["default"],{name:"pass in: "+this.name},function(n){return e.name=n.name})}}]),e}();c.$inject=["DialogService"],n.TestDialogController=function(){function e(){o(this,e)}return r(e,[{key:"ok",value:function(){this.dialog.onOk(this.dialog.data)}}]),e}()},74:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e,n){t(this,o),e.hintContent="测试操作结果a",e.myHint=function(){n.hint({title:"我操作成功了",content:"结果是:"+e.hintContent})}};n["default"]=a,a.$inject=["$scope","HintService"]},75:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(){t(this,o),this.listData=Array.from(Array(1e4),function(e,n){return{index:n,label:"Item"+n}}),this.selectedItem=null};n["default"]=a},76:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){t(this,o),e.value=5,e.maxValue=11};n["default"]=a,a.$inject=["$scope"]},77:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}var a=function(){function e(e,n){for(var t=0;t<n.length;t++){var a=n[t];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}return function(n,t,a){return t&&e(n.prototype,t),a&&e(n,a),n}}();Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(n){t(this,e),this.count=177,n.$watch("pageCtrl.currentPage",function(e){console.log(e)})}return a(e,[{key:"changeIndex",value:function(){this.currentPage=1}}]),e}();n["default"]=o,o.$inject=["$scope"]},78:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){t(this,o),e.options=[{name:"aaa",value:111},{name:"bbb",value:222},{name:"ccc",value:333},"seperator",{name:"ddd",value:444},{name:"eee",value:555}]};n["default"]=a,a.$inject=["$scope"]},79:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){t(this,o)};n["default"]=a,a.$inject=["$scope"]},80:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){function n(e,t){e.children&&(e.$expanded=t,e.children.forEach(function(e){return n(e,t)}))}function a(e){var n=[];return e.forEach(function(e){e.$checked&&n.push(e),e.children&&(n=n.concat(a(e.children)))}),n}t(this,o),e.areaData=[{name:"Jiangsu",code:"js",children:[{name:"Nanjing",code:"nj"},{name:"Suzhou",code:"sz",children:[{name:"Wujiang",code:"wj"},{name:"Changshu",code:"cs"}]}]},{name:"Yunnan",code:"yn"},{name:"Fujian",code:"fj"}],e.$on("sn.controls.tree:selectedNodeChanged",function(n,t){e.selectedTreeItem=t.newNode}),e.getCheckedItems=function(){console.table(a(e.areaData))},e.expandAll=function(){e.areaData.forEach(function(e){return n(e,!0)})},e.collapseAll=function(){e.areaData.forEach(function(e){return n(e,!1)})}};n["default"]=a,a.$inject=["$scope"]},81:function(e,n){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var a=function o(e){t(this,o),e.areaData=[{name:"江苏",code:"js",children:[{name:"南京",code:"nj",children:[{name:"江宁",code:"jn",children:[{name:"秣陵",code:"ml"},{name:"湖熟",code:"cs"}]},{name:"溧水",code:"ls"}]},{name:"苏州",code:"sz",children:[{name:"吴江",code:"wj"},{name:"常熟",code:"cs"}]}]},{name:"云南",code:"yn"},{name:"福建",code:"fj"}],e.item1=e.areaData[0].children[1]};n["default"]=a,a.$inject=["$scope"]},82:function(e,n,t){"use strict";function a(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(68),r=a(o),l=t(74),i=a(l),c=t(73),u=t(79),s=a(u),d=t(70),f=a(d),h=t(69),m=a(h),g=t(76),p=a(g),y=t(72),b=a(y),v=t(78),C=a(v),k=t(75),j=a(k),$=t(80),w=a($),_=t(71),D=a(_),T=t(81),x=a(T),M=t(77),P=a(M);n["default"]=angular.module("modules.demo",[]).controller("AlertController",r["default"]).controller("HintController",i["default"]).controller("DialogController",c.DialogController).controller("TestDialogController",c.TestDialogController).controller("ToolTipController",s["default"]).controller("ContextMenuController",f["default"]).controller("CheckboxController",m["default"]).controller("NumberController",p["default"]).controller("DateController",b["default"]).controller("SelectController",C["default"]).controller("TreeSelectController",x["default"]).controller("PagerController",P["default"]).controller("ListController",j["default"]).controller("TreeController",w["default"]).controller("DataGridController",D["default"]).name},124:function(e,n){e.exports='<td ng-repeat-start="col in datagridCtrl.cols" ng-if="$first">\n <input type="checkbox" ng-model="item.$checked" ng-change="datagridCtrl.checkItem(item)"/>\n</td>\n<td ng-repeat-end ng-if="!$first">\n <span ng-if="(!$last) || (!item.$checked)">{{item[col.key]}}</span>\n \n <button ng-if="$last && item.$checked" class="btn btn-default" ng-click="item.gender=1-item.gender">选中的时候可点,变性</button>\n</td>'},125:function(e,n){e.exports='<td ng-repeat-start="col in datagridCtrl.cols" ng-if="$first">\n <input type="checkbox" ng-model="item.$checked" ng-change="datagridCtrl.checkItem(item)"/>\n</td>\n<td ng-repeat-end ng-if="!$first">{{item[col.key]}}</td>'},126:function(e,n){e.exports='<th ng-repeat-start="col in datagridCtrl.cols" ng-if="$first">\n <input type="checkbox" ng-model="datagridCtrl.$allChecked" ng-change="datagridCtrl.checkAll()"/>\n</th>\n<th ng-repeat-end ng-if="!$first">{{col.label}}</th>'},127:function(e,n){e.exports='<th ng-repeat="col in datagridCtrl.cols">\n {{col.label}}\n <button class="btn btn-xs glyphicon"\n ng-click="datagridCtrl.headerSort(col.key)"\n ng-class="{\'glyphicon-triangle-bottom\':!datagridCtrl.desc, \'glyphicon-triangle-top\':datagridCtrl.desc}"></button>\n</th>'},128:function(e,n){e.exports='<div class="modal fade in" ng-controller="TestDialogController as dialogCtrl" ng-init="dialogCtrl.dialog=dialog">\n <div class="modal-dialog">\n <div class="modal-content">\n <div class="modal-header">\n <button type="button" class="close" data-dismiss="modal" ng-click="dialog.onClose()"><span\n aria-hidden="true">×</span><span\n class="sr-only">Close</span></button>\n <h4 class="modal-title">我是一个对话框</h4>\n </div>\n <div class="modal-body">\n <form class="form-horizontal" role="form">\n <div class="form-group">\n <label class="col-sm-2 control-label">Name</label>\n\n <div class="col-sm-10">\n <input type="text" class="form-control" placeholder="Name" ng-model="dialog.data.name"/>\n </div>\n </div>\n </form>\n </div>\n <div class="modal-footer">\n <button type="button" class="btn btn-primary" ng-click="dialogCtrl.ok()">OK</button>\n <button type="button" class="btn btn-primary" ng-click="dialog.onCancel()">Cancel</button>\n </div>\n </div>\n </div>\n</div>'}});
//# sourceMappingURL=app.js.map