├── .gitignore ├── public ├── icon.png ├── chromeicon.png ├── script.js ├── manifest.json └── assets │ └── styles.css ├── .github ├── images │ └── screenshot.png └── workflows │ ├── release.yml │ └── deploy.yml ├── .gitattributes ├── test ├── StudentStationPreference.aspx_files │ ├── Default.jpg │ ├── logo_Bits_small.png │ ├── buttons.bootstrap.min.js │ ├── buttons.print.min.js │ ├── jquery.ui.touch-punch.min.js │ ├── table-manage-combine.demo.js │ ├── buttons.bootstrap.min.css │ ├── buttons.colvis.min.js │ ├── dataTables.bootstrap.min.js │ ├── responsive.bootstrap.min.css │ ├── e94.css │ ├── blue.css │ ├── jquery.slimscroll.min(1).js │ ├── e94(1).css │ ├── jquery.slimscroll.min.js │ ├── dataTables.responsive.min.js │ ├── StudentStationPref.js │ ├── buttons.flash.min.js │ ├── buttons.html5.min.js │ ├── dataTables.select.min.js │ ├── css │ ├── dataTables.buttons.min.js │ ├── style-responsive.min.css │ ├── apps.min.js │ └── font-awesome.min.css └── README.md ├── vite.config.js ├── index.html ├── package.json ├── tsconfig.json ├── .devcontainer └── devcontainer.json ├── LICENSE ├── README.md └── src ├── templates ├── globalControls.html └── itemControls.html ├── content.ts └── utils.ts /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist 3 | .DS_Store -------------------------------------------------------------------------------- /public/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mehulmpt/ps-extender/HEAD/public/icon.png -------------------------------------------------------------------------------- /public/chromeicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mehulmpt/ps-extender/HEAD/public/chromeicon.png -------------------------------------------------------------------------------- /.github/images/screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mehulmpt/ps-extender/HEAD/.github/images/screenshot.png -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | test/StudentStationPreference.aspx_files/** linguist-vendored 2 | test/StudentStationPreference.aspx.html linguist-vendored -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/Default.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mehulmpt/ps-extender/HEAD/test/StudentStationPreference.aspx_files/Default.jpg -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/logo_Bits_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mehulmpt/ps-extender/HEAD/test/StudentStationPreference.aspx_files/logo_Bits_small.png -------------------------------------------------------------------------------- /public/script.js: -------------------------------------------------------------------------------- 1 | chrome.browserAction.onClicked.addListener((activeTab) => { 2 | chrome.tabs.insertCSS(null, { file: 'assets/styles.css' }); 3 | chrome.tabs.executeScript(null, { file: 'content.js' }) 4 | }) 5 | -------------------------------------------------------------------------------- /vite.config.js: -------------------------------------------------------------------------------- 1 | import { resolve } from 'node:path' 2 | import { defineConfig } from 'vite' 3 | 4 | export default defineConfig({ 5 | build: { 6 | sourcemap: 'inline', 7 | lib: { 8 | entry: resolve(__dirname, 'src/content.ts'), 9 | fileName: 'content', 10 | formats: ['es'] 11 | }, 12 | }, 13 | }) -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | PS Extender 7 | 8 | 9 | Fill Preferences 10 | 11 | 12 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/buttons.bootstrap.min.js: -------------------------------------------------------------------------------- 1 | (function(b,a){b.extend(!0,a.Buttons.defaults,{dom:{container:{className:"dt-buttons btn-group"},button:{className:"btn btn-default"},collection:{tag:"ul",className:"dt-button-collection dropdown-menu",button:{tag:"li",className:"dt-button"},buttonLiner:{tag:"a",className:""}}}});a.ext.buttons.collection.text=function(a){return a.i18n("buttons.collection",'Collection ')}})(jQuery,jQuery.fn.dataTable); 2 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ps-extender", 3 | "version": "2.4.0", 4 | "description": "Practice School Extender for BITS Pilani", 5 | "private": "true", 6 | "type": "module", 7 | "scripts": { 8 | "test": "echo \"Error: no test specified\" && exit 1", 9 | "build": "tsc && vite build", 10 | "build:watch": "tsc && vite build --watch", 11 | "dev": "vite" 12 | }, 13 | "devDependencies": { 14 | "typescript": "^4.6.4", 15 | "vite": "^3.2.3" 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "manifest_version": 2, 3 | "name": "Practice School Extender for BITS Pilani", 4 | "version": "2.4.0", 5 | "description": "Extends functionality of PSD interface by adding controls for sorting rows, backups, problem bank viewer", 6 | "browser_action": {}, 7 | "icons": { 8 | "32": "icon.png", 9 | "48": "icon.png", 10 | "64": "icon.png", 11 | "128": "icon.png" 12 | }, 13 | "background": { 14 | "scripts": ["script.js"] 15 | }, 16 | "permissions": ["activeTab"] 17 | } 18 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "useDefineForClassFields": true, 5 | "module": "ESNext", 6 | "lib": ["ESNext", "DOM"], 7 | "moduleResolution": "Node", 8 | "strict": true, 9 | "resolveJsonModule": true, 10 | // "isolatedModules": true, 11 | "esModuleInterop": true, 12 | "noEmit": true, 13 | "noUnusedLocals": true, 14 | "noUnusedParameters": true, 15 | "noImplicitReturns": true, 16 | "skipLibCheck": true 17 | }, 18 | "include": ["src"] 19 | } 20 | -------------------------------------------------------------------------------- /.devcontainer/devcontainer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Node.js & TypeScript", 3 | "image": "mcr.microsoft.com/devcontainers/typescript-node:16-bullseye", 4 | 5 | // Use 'forwardPorts' to make a list of ports inside the container available locally. 6 | // "forwardPorts": [], 7 | 8 | // Use 'postCreateCommand' to run commands after the container is created. 9 | // "postCreateCommand": "yarn install", 10 | 11 | // Set `remoteUser` to `root` to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root. 12 | "remoteUser": "node" 13 | } 14 | -------------------------------------------------------------------------------- /test/README.md: -------------------------------------------------------------------------------- 1 | `StudentStationPreference.aspx.html` is saved from `http://psd.bits-pilani.ac.in/Student/StudentStationPreference.aspx` 2 | 3 | These changes have been made to `StudentStationPreference.aspx.html` 4 | 5 | ```diff 6 | - 7 | + 8 | ``` 9 | 10 | ```diff 11 | 12 | + 13 | 14 | ``` 15 | 16 | ```diff 17 | 18 | 19 | - 20 | + 21 | 22 | 23 | ``` -------------------------------------------------------------------------------- /.github/workflows/release.yml: -------------------------------------------------------------------------------- 1 | name: Create Archive 2 | on: 3 | push: 4 | branches: 5 | - 'master' 6 | jobs: 7 | build: 8 | runs-on: ubuntu-latest 9 | steps: 10 | - uses: actions/checkout@master 11 | 12 | - uses: actions/setup-node@v3 13 | with: 14 | node-version: 16 15 | cache: 'npm' 16 | 17 | - name: install dependencies 18 | run: npm ci 19 | 20 | - name: build extension 21 | run: npm run build 22 | 23 | - name: generate archive 24 | run: (cd dist && zip -r ../PSExtender.zip .) 25 | 26 | - name: create release 27 | uses: marvinpinto/action-automatic-releases@latest 28 | with: 29 | repo_token: ${{ secrets.GITHUB_TOKEN }} 30 | automatic_release_tag: latest 31 | prerelease: true 32 | title: Development Build 33 | files: | 34 | PSExtender.zip -------------------------------------------------------------------------------- /.github/workflows/deploy.yml: -------------------------------------------------------------------------------- 1 | name: Zip and deploy to webstore 2 | on: 3 | workflow_dispatch: 4 | jobs: 5 | zip_and_deploy: 6 | runs-on: ubuntu-latest 7 | steps: 8 | - uses: actions/checkout@v2 9 | 10 | - uses: actions/setup-node@v3 11 | with: 12 | node-version: 16 13 | cache: 'npm' 14 | 15 | - name: install dependencies 16 | run: npm ci 17 | 18 | - name: 🚧 Building 19 | run: npm run build 20 | 21 | - name: 🚨 Zipping 22 | run: (cd dist && zip -r ../PSExtender.zip .) 23 | 24 | - uses: trmcnvn/chrome-addon@v2 25 | name: ✅ Deploying to webstore 26 | with: 27 | extension: bbaegmboolkgheghdaoahaabjnkofmdm 28 | zip: PSExtender.zip 29 | client-id: ${{ secrets.CLIENT_ID }} 30 | client-secret: ${{ secrets.CLIENT_SECRET }} 31 | refresh-token: ${{ secrets.REFRESH_TOKEN }} 32 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019-present Mehul Mohan 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/buttons.print.min.js: -------------------------------------------------------------------------------- 1 | (function(f,g){var b=document.createElement("a"),i=function(c,a){"link"===a.nodeName.toLowerCase()&&(b.href=a.href,a.href=b.protocol+"//"+b.host+b.pathname+b.search)};g.ext.buttons.print={className:"buttons-print",text:function(c){return c.i18n("buttons.print","Print")},action:function(c,a,b,d){c=a.buttons.exportData(d.exportOptions);b=function(a,c){for(var b="",d=0,e=a.length;d"+a[d]+"";return b+""};a='';d.header&&(a+= 2 | ""+b(c.header,"th")+"");for(var a=a+"",h=0,g=c.body.length;h";d.footer&&(a+=""+b(c.footer,"th")+"");var e=window.open("",""),c=d.title.replace("*",f("title").text());f(e.document.head).append(""+c+"").append(f("style, link").clone().each(i));f(e.document.body).append("

"+c+"

").append("
"+d.message+"
").append(a);d.customize&&d.customize(e);setTimeout(function(){d.autoPrint&&(e.print(),e.close())}, 3 | 250)},title:"*",message:"",exportOptions:{},header:!0,footer:!1,autoPrint:!0,customize:null}})(jQuery,jQuery.fn.dataTable); 4 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/jquery.ui.touch-punch.min.js: -------------------------------------------------------------------------------- 1 | /* 2 | * jQuery UI Touch Punch 0.2.2 3 | * 4 | * Copyright 2011, Dave Furfero 5 | * Dual licensed under the MIT or GPL Version 2 licenses. 6 | * 7 | * Depends: 8 | * jquery.ui.widget.js 9 | * jquery.ui.mouse.js 10 | */ 11 | (function(b){b.support.touch="ontouchend" in document;if(!b.support.touch){return;}var c=b.ui.mouse.prototype,e=c._mouseInit,a;function d(g,h){if(g.originalEvent.touches.length>1){return;}g.preventDefault();var i=g.originalEvent.changedTouches[0],f=document.createEvent("MouseEvents");f.initMouseEvent(h,true,true,window,1,i.screenX,i.screenY,i.clientX,i.clientY,false,false,false,false,0,null);g.target.dispatchEvent(f);}c._touchStart=function(g){var f=this;if(a||!f._mouseCapture(g.originalEvent.changedTouches[0])){return;}a=true;f._touchMoved=false;d(g,"mouseover");d(g,"mousemove");d(g,"mousedown");};c._touchMove=function(f){if(!a){return;}this._touchMoved=true;d(f,"mousemove");};c._touchEnd=function(f){if(!a){return;}d(f,"mouseup");d(f,"mouseout");if(!this._touchMoved){d(f,"click");}a=false;};c._mouseInit=function(){var f=this;f.element.bind("touchstart",b.proxy(f,"_touchStart")).bind("touchmove",b.proxy(f,"_touchMove")).bind("touchend",b.proxy(f,"_touchEnd"));e.call(f);};})(jQuery); -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/table-manage-combine.demo.js: -------------------------------------------------------------------------------- 1 | /* 2 | Template Name: Color Admin - Responsive Admin Dashboard Template build with Twitter Bootstrap 3.3.5 3 | Version: 1.9.0 4 | Author: Sean Ngu 5 | Website: http://www.seantheme.com/color-admin-v1.9/admin/ 6 | */ 7 | 8 | var handleDataTableCombinationSetting = function() { 9 | "use strict"; 10 | 11 | if ($('#data-table').length !== 0) { 12 | $('#data-table').DataTable({ 13 | dom: 'lBfrtip', 14 | buttons: [ 15 | { extend: 'copy', className: 'btn-sm' }, 16 | { extend: 'csv', className: 'btn-sm' }, 17 | { extend: 'excel', className: 'btn-sm' }, 18 | { extend: 'pdf', className: 'btn-sm' }, 19 | { extend: 'print', className: 'btn-sm' } 20 | ], 21 | responsive: true, 22 | autoFill: true, 23 | colReorder: true, 24 | keys: true, 25 | rowReorder: true, 26 | select: true 27 | }); 28 | } 29 | }; 30 | 31 | var TableManageCombine = function () { 32 | "use strict"; 33 | return { 34 | //main function 35 | init: function () { 36 | handleDataTableCombinationSetting(); 37 | } 38 | }; 39 | }(); -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/buttons.bootstrap.min.css: -------------------------------------------------------------------------------- 1 | div.dt-button-info{position:fixed;top:50%;left:50%;width:400px;margin-top:-100px;margin-left:-200px;background-color:white;border:2px solid #111;box-shadow:3px 3px 8px rgba(0,0,0,0.3);border-radius:3px;text-align:center;z-index:21}div.dt-button-info h2{padding:0.5em;margin:0;font-weight:normal;border-bottom:1px solid #ddd;background-color:#f3f3f3}div.dt-button-info>div{padding:1em}ul.dt-button-collection.dropdown-menu{display:block;z-index:2002;-webkit-column-gap:8px;-moz-column-gap:8px;-ms-column-gap:8px;-o-column-gap:8px;column-gap:8px}ul.dt-button-collection.dropdown-menu.fixed{position:fixed;top:50%;left:50%;margin-left:-75px}ul.dt-button-collection.dropdown-menu.fixed.two-column{margin-left:-150px}ul.dt-button-collection.dropdown-menu.fixed.three-column{margin-left:-225px}ul.dt-button-collection.dropdown-menu.fixed.four-column{margin-left:-300px}ul.dt-button-collection.dropdown-menu>*{-webkit-column-break-inside:avoid;break-inside:avoid}ul.dt-button-collection.dropdown-menu.two-column{width:300px;padding-bottom:1px;-webkit-column-count:2;-moz-column-count:2;-ms-column-count:2;-o-column-count:2;column-count:2}ul.dt-button-collection.dropdown-menu.three-column{width:450px;padding-bottom:1px;-webkit-column-count:3;-moz-column-count:3;-ms-column-count:3;-o-column-count:3;column-count:3}ul.dt-button-collection.dropdown-menu.four-column{width:600px;padding-bottom:1px;-webkit-column-count:4;-moz-column-count:4;-ms-column-count:4;-o-column-count:4;column-count:4}div.dt-button-background{position:fixed;top:0;left:0;width:100%;height:100%;z-index:2001} 2 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/buttons.colvis.min.js: -------------------------------------------------------------------------------- 1 | (function(e,f){e.extend(f.ext.buttons,{colvis:function(a,b){return{extend:"collection",text:function(a){return a.i18n("buttons.colvis","Column visibility")},className:"buttons-colvis",buttons:[{extend:"columnsToggle",columns:b.columns}]}},columnsToggle:function(a,b){return a.columns(b.columns).indexes().map(function(a){return{extend:"columnToggle",columns:a}}).toArray()},columnToggle:function(a,b){return{extend:"columnVisibility",columns:b.columns}},columnsVisibility:function(a,b){return a.columns(b.columns).indexes().map(function(a){return{extend:"columnVisibility", 2 | columns:a,visibility:b.visibility}}).toArray()},columnVisibility:{columns:null,text:function(a,b,c){return e(a.column(c.columns).header()).text()},className:"buttons-columnVisibility",action:function(a,b,c,d){a=b.column(d.columns);a.visible(void 0!==d.visibility?d.visibility:!a.visible())},init:function(a,b,c){var d=this,b=a.column(c.columns);a.on("column-visibility.dt"+c.namespace,function(a,b,e,f){e===c.columns&&d.active(f)});this.active(b.visible())},destroy:function(a,b,c){a.off("column-visibility.dt"+ 3 | c.namespace)}},colvisRestore:{className:"buttons-colvisRestore",text:function(a){return a.i18n("buttons.colvisRestore","Restore visibility")},init:function(a,b,c){c._visOriginal=a.columns().indexes().map(function(b){return a.column(b).visible()}).toArray()},action:function(a,b,c,d){b.columns().every(function(a){this.visible(d._visOriginal[a])})}},colvisGroup:{className:"buttons-colvisGroup",action:function(a,b,c,d){b.columns(d.show).visible(!0);b.columns(d.hide).visible(!1)},show:[],hide:[]}})})(jQuery, 4 | jQuery.fn.dataTable); 5 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/dataTables.bootstrap.min.js: -------------------------------------------------------------------------------- 1 | /*! 2 | DataTables Bootstrap 3 integration 3 | ©2011-2014 SpryMedia Ltd - datatables.net/license 4 | */ 5 | (function(l,q){var d=function(b,c){b.extend(!0,c.defaults,{dom:"<'row'<'col-sm-6'l><'col-sm-6'f>><'row'<'col-sm-12'tr>><'row'<'col-sm-5'i><'col-sm-7'p>>",renderer:"bootstrap"});b.extend(c.ext.classes,{sWrapper:"dataTables_wrapper form-inline dt-bootstrap",sFilterInput:"form-control input-sm",sLengthSelect:"form-control input-sm"});c.ext.renderer.pageButton.bootstrap=function(g,d,r,s,i,m){var t=new c.Api(g),u=g.oClasses,j=g.oLanguage.oPaginate,e,f,n=0,p=function(c,d){var k,h,o,a,l=function(a){a.preventDefault(); 6 | b(a.currentTarget).hasClass("disabled")||t.page(a.data.action).draw("page")};k=0;for(h=d.length;k",{"class":u.sPageButton+ 7 | " "+f,id:0===r&&"string"===typeof a?g.sTableId+"_"+a:null}).append(b("",{href:"#","aria-controls":g.sTableId,"data-dt-idx":n,tabindex:g.iTabIndex}).html(e)).appendTo(c),g.oApi._fnBindAction(o,{action:a},l),n++)}},h;try{h=b(d).find(q.activeElement).data("dt-idx")}catch(l){}p(b(d).empty().html('
    ').children("ul"),s);h&&b(d).find("[data-dt-idx="+h+"]").focus()};c.TableTools&&(b.extend(!0,c.TableTools.classes,{container:"DTTT btn-group",buttons:{normal:"btn btn-default",disabled:"disabled"}, 8 | collection:{container:"DTTT_dropdown dropdown-menu",buttons:{normal:"",disabled:"disabled"}},print:{info:"DTTT_print_info"},select:{row:"active"}}),b.extend(!0,c.TableTools.DEFAULTS.oTags,{collection:{container:"ul",button:"li",liner:"a"}}))};"function"===typeof define&&define.amd?define(["jquery","datatables"],d):"object"===typeof exports?d(require("jquery"),require("datatables")):jQuery&&d(jQuery,jQuery.fn.dataTable)})(window,document); 9 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |
    2 | 3 | BITS Pilani 4 | 5 |

    6 |

    PSD Extender

    7 |

    Extends functionality of PSD interface.

    8 | 9 | ![GitHub stars](https://img.shields.io/github/stars/mehulmpt/ps-extender?style=social) 10 | ![GitHub watchers](https://img.shields.io/github/watchers/mehulmpt/ps-extender?label=Watch&style=social) 11 | 12 |
    13 | 14 | ## Features 15 | 16 | 👉 Adds controls for swapping PS station 17 | 18 | 👉 Select and move multiple stations 19 | 20 | 👉 Adds button to view problem bank, which automatically adds all relevent information to the row 21 | 22 | 👉 Backup your preferences 23 | 24 | 👉 Add notes 25 | 26 | 👉 Removes the default jQuery implementation on the website 27 | 28 | ![Screenshot of the preference page with this extension enabled](.github/images/screenshot.png) 29 | 30 | ## 🎓 Usage 31 | 32 | The easiest way to use this is to install is using webstore [here](http://bit.ly/ps-extender). For some reason, if you want to set it up manually: 33 | 34 | 1. Download the latest version of `PSExtender.zip` from [Releases](https://github.com/mehulmpt/ps-extender/releases) 35 | 1. Unzip this folder 36 | 1. Type [`chrome://extensions/`](chrome://extensions/) in your URL 37 | 1. Enable Developer Mode (top-right) 38 | 1. Click on "Load unpacked" 39 | 1. Locate the extracted folder 40 | 1. Visit/Refresh your PSD page and click on the extension icon in your toolbar 41 | 1. You should now see an interface with the controls 42 | 43 | ## Setup 44 | 45 | - run `npm install` to install dependencies 46 | - uses Vite in library mode to bundle extension 47 | - `public/` + compiled source code is output to `dist/` folder 48 | - run `npm run build` to build once. refresh browser and rerun extension. 49 | - run `npm run build:watch` to watch for changes and build automatically. refresh and rerun. 50 | - run `npm run dev` to test the extension on a local copy of the page (no need to install the extension). Auto-reloads 51 | 52 | ## 🚀 Contributing 53 | 54 | PRs are welcome and in fact, appreciated :) 55 | 56 | - Check open Issues and PRs before you start 57 | - Try to take up each issue in a separate PR 58 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/responsive.bootstrap.min.css: -------------------------------------------------------------------------------- 1 | table.dataTable.dtr-inline.collapsed>tbody>tr>td:first-child,table.dataTable.dtr-inline.collapsed>tbody>tr>th:first-child{position:relative;padding-left:30px;cursor:pointer}table.dataTable.dtr-inline.collapsed>tbody>tr>td:first-child:before,table.dataTable.dtr-inline.collapsed>tbody>tr>th:first-child:before{top:8px;left:4px;height:16px;width:16px;display:block;position:absolute;color:white;border:2px solid white;border-radius:16px;text-align:center;line-height:14px;box-shadow:0 0 3px #444;box-sizing:content-box;content:'+';background-color:#337ab7}table.dataTable.dtr-inline.collapsed>tbody>tr>td:first-child.dataTables_empty:before,table.dataTable.dtr-inline.collapsed>tbody>tr>th:first-child.dataTables_empty:before{display:none}table.dataTable.dtr-inline.collapsed>tbody>tr.parent>td:first-child:before,table.dataTable.dtr-inline.collapsed>tbody>tr.parent>th:first-child:before{content:'-';background-color:#d33333}table.dataTable.dtr-inline.collapsed>tbody>tr.child td:before{display:none}table.dataTable.dtr-inline.collapsed.compact>tbody>tr>td:first-child,table.dataTable.dtr-inline.collapsed.compact>tbody>tr>th:first-child{padding-left:27px}table.dataTable.dtr-inline.collapsed.compact>tbody>tr>td:first-child:before,table.dataTable.dtr-inline.collapsed.compact>tbody>tr>th:first-child:before{top:5px;left:4px;height:14px;width:14px;border-radius:14px;line-height:12px}table.dataTable.dtr-column>tbody>tr>td.control,table.dataTable.dtr-column>tbody>tr>th.control{position:relative;cursor:pointer}table.dataTable.dtr-column>tbody>tr>td.control:before,table.dataTable.dtr-column>tbody>tr>th.control:before{top:50%;left:50%;height:16px;width:16px;margin-top:-10px;margin-left:-10px;display:block;position:absolute;color:white;border:2px solid white;border-radius:16px;text-align:center;line-height:14px;box-shadow:0 0 3px #444;box-sizing:content-box;content:'+';background-color:#337ab7}table.dataTable.dtr-column>tbody>tr.parent td.control:before,table.dataTable.dtr-column>tbody>tr.parent th.control:before{content:'-';background-color:#d33333}table.dataTable>tbody>tr.child{padding:0.5em 1em}table.dataTable>tbody>tr.child:hover{background:transparent !important}table.dataTable>tbody>tr.child ul{display:inline-block;list-style-type:none;margin:0;padding:0}table.dataTable>tbody>tr.child ul li{border-bottom:1px solid #efefef;padding:0.5em 0}table.dataTable>tbody>tr.child ul li:first-child{padding-top:0}table.dataTable>tbody>tr.child ul li:last-child{border-bottom:none}table.dataTable>tbody>tr.child span.dtr-title{display:inline-block;min-width:75px;font-weight:bold} 2 | -------------------------------------------------------------------------------- /src/templates/globalControls.html: -------------------------------------------------------------------------------- 1 |
    2 |
    3 |
    4 |
    5 | 6 |
    7 | 8 | 9 | 10 |
    11 |
    12 |
    13 |
    14 | 15 |
    16 | 17 |
    18 |
    19 | 20 | 21 |
    22 |
    23 |
    24 | 25 |
    26 | 27 |
    28 |
    29 | 30 | 31 |
    32 |
    33 |
    34 | 35 |
    36 | 37 | 0 selected 38 |
    39 |
    40 |
    41 |
    42 | 43 |
    44 | 45 |
    46 |
    47 | 48 | 49 | 50 |
    51 |
    52 |
    53 |
    54 | 55 |
    56 | 57 | Warning: this will take a long time 58 | 59 |
    60 |
    61 |
    62 |
    63 | 64 |
    65 | Report an issue 66 |
    67 |
    68 |
    69 | 70 |
    71 | 72 |
    73 | 74 |
    -------------------------------------------------------------------------------- /public/assets/styles.css: -------------------------------------------------------------------------------- 1 | #__PSZY_INFO__, 2 | #__PSZY_CONTROLS__ { 3 | flex: 0 0 auto; 4 | display: flex; 5 | align-items: center; 6 | height: 24px; 7 | } 8 | 9 | #__PSZY_INFO__ { 10 | justify-content: flex-start; 11 | gap: 8px; 12 | order: 2; 13 | } 14 | 15 | #__PSZY_CONTROLS__ { 16 | position: absolute; 17 | right: 50px; 18 | justify-content: flex-end; 19 | gap: 10px; 20 | order: 6; 21 | } 22 | 23 | ul#sortable_nav>li { 24 | display: flex; 25 | gap: 15px; 26 | align-items: center; 27 | } 28 | 29 | ul#sortable_nav>li .sortable-number { 30 | flex: 0 0 auto; 31 | order: 1; 32 | margin-left: -60px; 33 | float: none; 34 | } 35 | 36 | ul#sortable_nav>li .uiicon { 37 | margin: 0px; 38 | order: 3; 39 | } 40 | 41 | .spacer { 42 | flex: 1 1 auto; 43 | } 44 | 45 | ul#sortable_nav>li .spacer { 46 | order: 4; 47 | } 48 | 49 | ul#sortable_nav>li input.accomo { 50 | flex: 0 0 auto; 51 | order: 7; 52 | float: none; 53 | margin: 0; 54 | width: 24px; 55 | height: 24px; 56 | } 57 | 58 | /* hide buttons that do nothing */ 59 | #sortable_nav>li:first-child div #__PSZY_MOVEUP__, 60 | #sortable_nav>li:first-child div #__PSZY_TOP__, 61 | #sortable_nav>li:last-child div #__PSZY_MOVEDOWN__, 62 | #sortable_nav>li:last-child div #__PSZY_BOTTOM__ { 63 | opacity: 40%; 64 | pointer-events: none; 65 | } 66 | 67 | /* hide controls when not hovered */ 68 | #sortable_nav>li:not(:hover) #__PSZY_CONTROLS__ { 69 | display: none; 70 | } 71 | 72 | /* but show if something is in focus */ 73 | #sortable_nav>li #__PSZY_CONTROLS__:focus-within { 74 | display: flex; 75 | } 76 | 77 | /* hide note if empty and not in focus */ 78 | #__PSZY_NOTE__:empty:not(:focus), 79 | #sortable_nav>li:hover #__PSZY_NOTE__:empty:not(:focus) { 80 | display: none; 81 | } 82 | 83 | /* note style when not hovered */ 84 | #sortable_nav>li:not(:hover) #__PSZY_NOTE__ { 85 | position: relative; 86 | order: 5; 87 | } 88 | 89 | /* note styles when hovered */ 90 | #sortable_nav>li:hover #__PSZY_NOTE__ { 91 | display: inline-block; 92 | position: absolute; 93 | right: 48px; 94 | bottom: 100%; 95 | transform: translateY(10px); 96 | padding: 8px; 97 | color: #555555; 98 | background-color: #ffffff; 99 | border: 1px solid #c1c1c1; 100 | border-radius: 4px; 101 | box-shadow: 0 0 10px #c1c1c1; 102 | } 103 | 104 | #sortable_nav>li:hover #__PSZY_NOTE__::before, 105 | #sortable_nav>li:hover #__PSZY_NOTE__::after { 106 | content: ""; 107 | position: absolute; 108 | width: 12px; 109 | height: 6px; 110 | top: 100%; 111 | right: 2px; 112 | -webkit-clip-path: polygon(0% 0%, 100% 0%, 50% 100%); 113 | clip-path: polygon(0% 0%, 100% 0%, 50% 100%); 114 | } 115 | 116 | #sortable_nav>li:hover #__PSZY_NOTE__::before { 117 | background-color: #c1c1c1; 118 | z-index: 2; 119 | } 120 | 121 | #sortable_nav>li:hover #__PSZY_NOTE__::after { 122 | background-color: #ffffff; 123 | transform: translateY(-1.414px); 124 | z-index: 3; 125 | } 126 | 127 | /* ignore click events */ 128 | svg, 129 | #__PSZY_STIPEND__ *, 130 | #__PSZY_STUDENTS__ *, 131 | #__PSZY_PROJECTS__ *, 132 | #__PSZY_DISCIPLINE__ * { 133 | pointer-events: none; 134 | } 135 | 136 | svg { 137 | vertical-align: middle; 138 | display: inline-block; 139 | width: auto; 140 | height: 1em; 141 | } 142 | 143 | #__PSZY_CONTROLS__ svg { 144 | height: 1.2em; 145 | } 146 | 147 | #__PSZY_FETCHINFOPROGRESS__:indeterminate { 148 | display: none; 149 | } 150 | 151 | @keyframes glow { 152 | 0% { 153 | opacity: 1; 154 | } 155 | 156 | 50% { 157 | opacity: 0.5; 158 | } 159 | 160 | 100% { 161 | opacity: 1; 162 | } 163 | } 164 | 165 | .glow { 166 | animation: glow 0.4s linear; 167 | } -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/e94.css: -------------------------------------------------------------------------------- 1 | 2 | /*close popup */ 3 | 4 | 5 | 6 | #panel-close:not(:hover) { 7 | background: #ffffff; 8 | } 9 | #panel-close:hover { 10 | background: black; 11 | color:white!important; 12 | } 13 | #panel-close { 14 | border: 2px solid #fff; 15 | color: transparent; 16 | height: 30px; 17 | position: absolute; 18 | font-size: 0; 19 | overflow: hidden; 20 | padding: 0; 21 | right: -12px; 22 | text-align: left; 23 | top: -12px; 24 | width: 30px; 25 | } 26 | 27 | button.outline, .btn.outline { 28 | background: transparent; 29 | box-shadow: inset #3e3e3e 0 0 0 1px; 30 | color: #3e3e3e; 31 | } 32 | 33 | 34 | panelheadingStyle{ 35 | font-size: 13px; 36 | color: brown; 37 | border: 1px solid #ddd; 38 | background-color: #f0f3f4; 39 | } 40 | 41 | .HeaderColor { 42 | font-size: 13px; 43 | color: brown; 44 | 45 | 46 | } 47 | 48 | .Space-20 { 49 | padding-top:50px; 50 | 51 | 52 | } 53 | 54 | 55 | .Space-10 { 56 | padding-top:25px; 57 | 58 | 59 | } 60 | 61 | /**//**//**//**//**//**//**//**//**//*/*/*/*end*/*/*/*/ 62 | .ace-nav>li.active>a, .ace-nav>li.active>a:hover, .ace-nav>li.active>a:focus 63 | 64 | { 65 | 66 | 67 | background-color:#2e6589; 68 | color: #FFF; 69 | display: block; 70 | line-height: inherit; 71 | text-align: center; 72 | height: 100%; 73 | width: auto; 74 | min-width: 50px; 75 | padding: 0 8px; 76 | position: relative; 77 | } 78 | .ace-nav>li>a:hover 79 | { 80 | 81 | 82 | background-color:#2e6589; 83 | color: #FFF; 84 | display: block; 85 | line-height: inherit; 86 | text-align: center; 87 | height: 100%; 88 | width: auto; 89 | min-width: 50px; 90 | padding: 0 8px; 91 | position: relative; 92 | } 93 | .ace-nav>li>a 94 | { 95 | background-color:#62a8d1; 96 | } 97 | 98 | 99 | .FormHeader 100 | { 101 | margin:0; padding:0; border-left:3px solid #FFB44B; padding-left:8px; 102 | } 103 | 104 | .FormHeaderLine 105 | { 106 | margin:0; line-height:40px; 107 | } 108 | .spacebtm { 109 | margin-bottom:5px; 110 | } 111 | .dropdown-submenu{position:relative;} 112 | .dropdown-submenu>.dropdown-menu{top:0;left:100%;margin-top:-6px;margin-left:-1px;-webkit-border-radius:0 6px 6px 6px;-moz-border-radius:0 6px 6px 6px;border-radius:0 6px 6px 6px;} 113 | .dropdown-submenu:hover>.dropdown-menu{display:block;} 114 | .dropdown-submenu>a:after{display:block;content:" ";float:right;width:0;height:0;border-color:transparent;border-style:solid;border-width:5px 0 5px 5px;border-left-color:#000;margin-top:5px;margin-right:-10px;} 115 | .dropdown-submenu:hover>a:after{border-left-color:#000;} 116 | .dropdown-submenu.pull-left{float:none;}.dropdown-submenu.pull-left>.dropdown-menu{left:-100%;margin-left:10px;-webkit-border-radius:6px 0 6px 6px;-moz-border-radius:6px 0 6px 6px;border-radius:6px 0 6px 6px;} 117 | 118 | .accordion-style1.panel-group .panel-heading .accordion-toggle 119 | { 120 | background-color:#307ecc !important; 121 | color:#fff !important; 122 | } 123 | .panel-primary>.panel-heading+.panel-collapse .panel-body 124 | { 125 | border:1px solid #428bca !important; 126 | } 127 | .accordion-style1.panel-group .panel-heading .accordion-toggle 128 | { 129 | font-weight:normal !important; 130 | font-size:15px !important; 131 | } 132 | .panel-group .panel-heading+.panel-collapse .panel-body 133 | { 134 | border:1px solid #428bca !important; 135 | } 136 | 137 | 138 | .box { 139 | background: #fff; 140 | padding: 22px; 141 | opacity:0.85; 142 | } 143 | .bck 144 | { 145 | background: #222 url(../assets/img/bg2.png); 146 | } 147 | 148 | .outer { 149 | width: 1px; 150 | height: 100%; 151 | margin: auto; 152 | position: relative; 153 | background: green; 154 | overflow: hidden; 155 | } 156 | .inner { 157 | position: absolute; 158 | width:100%; 159 | height: 40%; 160 | background: red 161 | ; 162 | top: 30%; 163 | box-shadow: 0px 0px 30px 20px grey; 164 | } 165 | 166 | 167 | 168 | 169 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/blue.css: -------------------------------------------------------------------------------- 1 | /* 2 | Template Name: Color Admin - Responsive Admin Dashboard Template build with Twitter Bootstrap 3.3.5 3 | Version: 1.9.0 4 | Author: Sean Ngu 5 | Website: http://www.seantheme.com/color-admin-v1.9/admin/ 6 | */ 7 | 8 | .navbar-logo, 9 | .coming-soon .brand .logo, 10 | .login .login-header .brand .logo { 11 | border-color: #2F83CF #2a72b5 #1f5688; 12 | } 13 | .navbar.navbar-inverse .navbar-brand, 14 | .sidebar .nav > li.active > a, 15 | .sidebar .nav > li.active > a:focus, 16 | .sidebar .nav > li.active > a:hover, 17 | .page-sidebar-minified .sidebar .nav > li.has-sub.active:focus > a, 18 | .page-sidebar-minified .sidebar .nav > li.has-sub.active:hover > a, 19 | .page-sidebar-minified .sidebar .nav > li.has-sub.active > a, 20 | .label.label-theme, 21 | .btn.btn-scroll-to-top { 22 | background: #348fe2; 23 | } 24 | .navbar.navbar-inverse .navbar-brand { 25 | color: #fff !important; 26 | } 27 | .text-theme, 28 | .sidebar .sub-menu > li.active > a:before { 29 | color: #348fe2; 30 | } 31 | @media (max-width: 767px) { 32 | .navbar-inverse .navbar-header { 33 | background: #348fe2; 34 | } 35 | } 36 | 37 | 38 | /* Added in v1.5 */ 39 | 40 | .gradient-enabled .navbar.navbar-inverse .navbar-brand, 41 | .gradient-enabled .sidebar .nav > li.active > a, 42 | .gradient-enabled .sidebar .nav > li.active > a:focus, 43 | .gradient-enabled .sidebar .nav > li.active > a:hover, 44 | .gradient-enabled.page-sidebar-minified .sidebar .nav > li.has-sub.active:focus > a, 45 | .gradient-enabled.page-sidebar-minified .sidebar .nav > li.has-sub.active:hover > a, 46 | .gradient-enabled.page-sidebar-minified .sidebar .nav > li.has-sub.active > a, 47 | .gradient-enabled .label.label-theme, 48 | .gradient-enabled .btn.btn-scroll-to-top, 49 | .gradient-enabled .top-menu .nav > li.active > a, 50 | .gradient-enabled .top-menu .nav > li.active > a:focus, 51 | .gradient-enabled .top-menu .nav > li.active > a:hover { 52 | background: rgb(103,176,240); /* Old browsers */ 53 | /* IE9 SVG, needs conditional override of 'filter' to 'none' */ 54 | background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzY3YjBmMCIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiMzNDhmZTIiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+); 55 | background: -moz-linear-gradient(top, rgba(103,176,240,1) 0%, rgba(52,143,226,1) 100%); /* FF3.6+ */ 56 | background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(103,176,240,1)), color-stop(100%,rgba(52,143,226,1))); /* Chrome,Safari4+ */ 57 | background: -webkit-linear-gradient(top, rgba(103,176,240,1) 0%,rgba(52,143,226,1) 100%); /* Chrome10+,Safari5.1+ */ 58 | background: -o-linear-gradient(top, rgba(103,176,240,1) 0%,rgba(52,143,226,1) 100%); /* Opera 11.10+ */ 59 | background: -ms-linear-gradient(top, rgba(103,176,240,1) 0%,rgba(52,143,226,1) 100%); /* IE10+ */ 60 | background: linear-gradient(to bottom, rgba(103,176,240,1) 0%,rgba(52,143,226,1) 100%); /* W3C */ 61 | filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#67b0f0', endColorstr='#348fe2',GradientType=0 ); /* IE6-8 */ 62 | } 63 | .pace-progress { 64 | background: #348fe2; 65 | } 66 | .pace .pace-activity { 67 | border-top-color: #348fe2; 68 | border-left-color: #348fe2; 69 | } 70 | 71 | 72 | /* Added in v1.7 */ 73 | 74 | .page-with-light-sidebar .sidebar .nav > li.active > a > i { 75 | color: #348fe2; 76 | } 77 | .page-with-light-sidebar .sidebar .nav > li.active > a .badge, 78 | .page-with-light-sidebar .sidebar .nav > li.active > a .label.label-theme { 79 | background: #348fe2; 80 | } 81 | 82 | 83 | /* Added in v1.9 */ 84 | 85 | .top-menu .nav > li.active > a, 86 | .top-menu .nav > li.active > a:focus, 87 | .top-menu .nav > li.active > a:hover { 88 | background: #348fe2; 89 | } -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/jquery.slimscroll.min(1).js: -------------------------------------------------------------------------------- 1 | /*! Copyright (c) 2011 Piotr Rochala (http://rocha.la) 2 | * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) 3 | * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses. 4 | * 5 | * Version: 1.2.0 6 | * 7 | */ 8 | (function(e){jQuery.fn.extend({slimScroll:function(h){var a=e.extend({width:"auto",height:"250px",size:"7px",color:"#000",position:"right",distance:"1px",start:"top",opacity:0.4,alwaysVisible:!1,disableFadeOut:!1,railVisible:!1,railColor:"#333",railOpacity:0.2,railDraggable:!0,railClass:"slimScrollRail",barClass:"slimScrollBar",wrapperClass:"slimScrollDiv",allowPageScroll:!1,wheelStep:20,touchScrollStep:200},h);this.each(function(){function s(d){if(q){d=d||window.event;var c=0;d.wheelDelta&&(c=-d.wheelDelta/ 9 | 120);d.detail&&(c=d.detail/3);e(d.target||d.srcTarget||d.srcElement).closest("."+a.wrapperClass).is(b.parent())&&k(c,!0);d.preventDefault&&!m&&d.preventDefault();m||(d.returnValue=!1)}}function k(d,e,h){var f=d,g=b.outerHeight()-c.outerHeight();e&&(f=parseInt(c.css("top"))+d*parseInt(a.wheelStep)/100*c.outerHeight(),f=Math.min(Math.max(f,0),g),f=0=b.outerHeight()?m=!0:(c.stop(!0,!0).fadeIn("fast"),a.railVisible&&g.stop(!0,!0).fadeIn("fast"))}function n(){a.alwaysVisible||(x=setTimeout(function(){if((!a.disableFadeOut||!q)&&!v&&!w)c.fadeOut("slow"),g.fadeOut("slow")},1E3))}var q,v,w,x,z,r,j,y,B=30,m=!1,b=e(this);if(b.parent().hasClass(a.wrapperClass)){var l=b.scrollTop(),c=b.parent().find("."+a.barClass),g=b.parent().find("."+a.railClass);u();if(e.isPlainObject(h)){if("height"in 12 | h&&"auto"==h.height){b.parent().css("height","auto");b.css("height","auto");var p=b.parent().parent().height();b.parent().css("height",p);b.css("height",p)}if("scrollTo"in h)l=parseInt(a.scrollTo);else if("scrollBy"in h)l+=parseInt(a.scrollBy);else if("destroy"in h){c.remove();g.remove();b.unwrap();return}k(l,!1,!0)}}else{a.height="auto"==a.height?b.parent().height():a.height;l=e("
    ").addClass(a.wrapperClass).css({position:"relative",overflow:"hidden",width:a.width,height:a.height});b.css({overflow:"hidden", 13 | width:a.width,height:a.height});var g=e("
    ").addClass(a.railClass).css({width:a.size,height:"100%",position:"absolute",top:0,display:a.alwaysVisible&&a.railVisible?"block":"none","border-radius":a.size,background:a.railColor,opacity:a.railOpacity,zIndex:90}),c=e("
    ").addClass(a.barClass).css({background:a.color,width:a.size,position:"absolute",top:0,opacity:a.opacity,display:a.alwaysVisible?"block":"none","border-radius":a.size,BorderRadius:a.size,MozBorderRadius:a.size,WebkitBorderRadius:a.size, 14 | zIndex:99}),p="right"==a.position?{right:a.distance}:{left:a.distance};g.css(p);c.css(p);b.wrap(l);b.parent().append(c);b.parent().append(g);a.railDraggable&&(e.ui&&"function"==typeof e.ui.draggable)&&c.draggable({axis:"y",containment:"parent",start:function(){w=!0},stop:function(){w=!1;n()},drag:function(){k(0,e(this).position().top,!1)}});g.hover(function(){t()},function(){n()});c.hover(function(){v=!0},function(){v=!1});b.hover(function(){q=!0;t();n()},function(){q=!1;n()});b.bind("touchstart", 15 | function(a){a.originalEvent.touches.length&&(z=a.originalEvent.touches[0].pageY)});b.bind("touchmove",function(b){b.originalEvent.preventDefault();b.originalEvent.touches.length&&k((z-b.originalEvent.touches[0].pageY)/a.touchScrollStep,!0)});"bottom"===a.start?(c.css({top:b.outerHeight()-c.outerHeight()}),k(0,!0)):"top"!==a.start&&(k(e(a.start).position().top,null,!0),a.alwaysVisible||c.hide());A();u()}});return this}});jQuery.fn.extend({slimscroll:jQuery.fn.slimScroll})})(jQuery); -------------------------------------------------------------------------------- /src/content.ts: -------------------------------------------------------------------------------- 1 | // @ts-nocheck 2 | 3 | import globalControls from './templates/globalControls.html?raw' 4 | import itemControls from './templates/itemControls.html?raw' 5 | import { $, moveup, movedown, movetotop, movetobottom, moveswap, moveto, exportCsv, importCsv, selectRange, deselectRange, selectPattern, deselectPattern, deselectAll, moveselectedto, moveselectedtop, moveselectedbottom, selectNode, viewProblemBank, fillAllStationInfo } from './utils' 6 | 7 | function checks() { 8 | if (!['psd.bits-pilani.ac.in', 'localhost', '127.0.0.1'].includes(location.hostname)) { 9 | alert('Only works on http://psd.bits-pilani.ac.in') 10 | return false 11 | } 12 | 13 | if (!location.pathname.includes('StudentStationPreference.aspx')) { 14 | alert('You need to be on Fill Station Prefrence page') 15 | return false 16 | } 17 | 18 | if (window.__PSZYSET__ === true) { 19 | alert('Already ran here once. Please refresh') 20 | return false 21 | } 22 | 23 | return true 24 | } 25 | 26 | if (checks()) { 27 | 28 | window.__PSZYSET__ = true 29 | 30 | // disable default sorting library 31 | const script = document.createElement('script') 32 | script.innerHTML = `$('#sortable_nav').sortable('destroy'); $('#sortable_nav').enableSelection();` 33 | document.head.appendChild(script) 34 | 35 | // add global controls 36 | const divider = $('#rptlist > .hr.hr-dotted') 37 | divider.outerHTML = globalControls + divider.outerHTML 38 | 39 | // add item controls 40 | const lis = $('#sortable_nav').querySelectorAll('li') 41 | lis.forEach((li) => (li.innerHTML += itemControls)) 42 | 43 | document.addEventListener('click', checkPSZYClicks, false) 44 | 45 | function checkPSZYClicks(e) { 46 | switch (e.target.id) { 47 | case '__PSZY_ADDNOTE__': { 48 | const note = e.target.parentNode.parentNode.querySelector('#__PSZY_NOTE__') 49 | note.focus() 50 | if (note.innerText.length > 0) break 51 | note.innerText = 'Edit me' 52 | // select text 53 | const range = document.createRange(); 54 | range.selectNodeContents(note); 55 | const sel = window.getSelection(); 56 | sel.removeAllRanges(); 57 | sel.addRange(range); 58 | break 59 | } 60 | case '__PSZY_NOTE__': 61 | // ignore click 62 | break 63 | case '__PSZY_MOVEUP__': 64 | moveup(e.target.parentNode.parentNode) 65 | break 66 | case '__PSZY_MOVEDOWN__': 67 | movedown(e.target.parentNode.parentNode) 68 | break 69 | case '__PSZY_TOP__': 70 | movetotop(e.target.parentNode.parentNode) 71 | break 72 | case '__PSZY_BOTTOM__': 73 | movetobottom(e.target.parentNode.parentNode) 74 | break 75 | case '__PSZY_SWAP__': 76 | moveswap(e.target.parentNode.parentNode) 77 | break 78 | case '__PSZY_MOVETO__': 79 | moveto(e.target.parentNode.parentNode) 80 | break 81 | case '__PSZY_PBANK__': 82 | viewProblemBank(e.target.parentNode.parentNode, { openInBackground: false }) 83 | break 84 | case '__PSZY_STIPEND__': 85 | case '__PSZY_STUDENTS__': 86 | case '__PSZY_PROJECTS__': 87 | case '__PSZY_DISCIPLINE__': 88 | viewProblemBank(e.target.parentNode.parentNode, { openInBackground: true }) 89 | break 90 | case '__PSZY_FETCHINFO__': { 91 | fillAllStationInfo() 92 | break 93 | } 94 | case '__PSZY_EXPORT__': 95 | exportCsv() 96 | break 97 | case '__PSZY_IMPORT__': 98 | importCsv() 99 | break 100 | case '__PSZY_SELECTRANGE__': 101 | selectRange() 102 | break 103 | case '__PSZY_DESELECTRANGE__': 104 | deselectRange() 105 | break 106 | case '__PSZY_SELECTPATTERN__': 107 | selectPattern() 108 | break 109 | case '__PSZY_DESELECTPATTERN__': 110 | deselectPattern() 111 | break 112 | case '__PSZY_DESELECTALL__': 113 | deselectAll() 114 | break 115 | case '__PSZY_MOVESELECTED__': 116 | moveselectedto() 117 | break 118 | case '__PSZY_MOVESELECTEDTOP__': 119 | moveselectedtop() 120 | break 121 | case '__PSZY_MOVESELECTEDBOTTOM__': 122 | moveselectedbottom() 123 | break 124 | case '__PSZY_SCROLLTOTOP__': 125 | window.scrollTo({ 126 | top: 0, 127 | left: 0, 128 | behavior: 'smooth', 129 | }) 130 | break 131 | default: 132 | selectNode(e.target) 133 | break 134 | } 135 | } 136 | 137 | } 138 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/e94(1).css: -------------------------------------------------------------------------------- 1 | body 2 | { 3 | 4 | } 5 | 6 | .tblborder 7 | { 8 | border-right:1px solid Black ; 9 | } 10 | 11 | .theadbackcolor 12 | { 13 | background-color: #307ECC ; 14 | color : White ; 15 | font-weight: normal; 16 | 17 | } 18 | 19 | .top-space 20 | { 21 | padding-top:8px; 22 | } 23 | 24 | .top-margin 25 | { 26 | padding-bottom:15px; 27 | padding-left:18px; 28 | } 29 | 30 | .ro_space 31 | { 32 | padding-bottom:15px; 33 | } 34 | 35 | .row-space 36 | { 37 | padding-top:4px; 38 | } 39 | 40 | .FormHeader 41 | { 42 | margin:0; padding:0; border-left:3px solid #FFB44B; padding-left:8px; 43 | } 44 | 45 | .FormHeaderLine 46 | { 47 | margin:0; line-height:40px; 48 | } 49 | 50 | .pagearea 51 | { 52 | margin:0; 53 | padding:0; 54 | } 55 | 56 | .bodyColor 57 | { 58 | background-color:#FFF; 59 | } 60 | .PageWidth 61 | { 62 | width:98%; margin:0px auto; padding:0; 63 | } 64 | .rowWidth 65 | { 66 | width:100%; margin:auto; 67 | } 68 | 69 | #tasks li { background:#f4f6f7; } 70 | body { padding:10px; } 71 | .sortable { list-style-type: none; margin: 0; padding: 0; width: 60%; } 72 | .sortable li { margin: 0 3px 3px 3px; padding: 0.4em; padding-left: 1.5em; font-size: 1.4em; height: 18px; } 73 | .sortable li span { position: absolute; margin-left: -1.3em; padding-bottom: 300em;} 74 | .ui-state-highlight { height: 1.5em; line-height: 1.2em; } 75 | 76 | .sortable-number {float: left;background-color: #428bca!important; 77 | border-color: #428bca; 78 | border-width: 4px; 79 | font-size: 13px; 80 | padding: 4px 9px; 81 | line-height: 1.39; 82 | border-radius: 3px; 83 | color:#fff; 84 | font-weight: normal; 85 | line-height: 15px; 86 | padding-bottom: 3px; 87 | padding-top: 1px; 88 | } 89 | 90 | .uiicon 91 | { 92 | margin-left : 30px; 93 | } 94 | 95 | .divMargin 96 | { 97 | margin-bottom:580px; 98 | } 99 | .estat 100 | { 101 | display: inline-block; 102 | position: absolute; 103 | right: 20px; 104 | top: 11px; 105 | text-shadow: none; 106 | color:#9abc32; 107 | font-size: 13px; 108 | font-weight: bold; 109 | padding-right: 18px; 110 | padding-top: 3px; 111 | } 112 | .profile-info-value 113 | { 114 | min-height:30px; 115 | 116 | } 117 | 118 | .ddhendelchange { 119 | background-color:#fff !important; 120 | font-weight:normal !important; 121 | font-size:15px; 122 | color:#000 !important; 123 | } 124 | .lblchange { 125 | font-size:22px !important; height:35px !important; font-weight:lighter !important; 126 | } 127 | .dropdown-submenu{position:relative;} 128 | .dropdown-submenu>.dropdown-menu{top:0;right:100%;margin-top:-6px;margin-left:-1px;-webkit-border-radius:0 6px 6px 6px;-moz-border-radius:0 6px 6px 6px;border-radius:0 6px 6px 6px;} 129 | .dropdown-submenu:hover>.dropdown-menu{display:block;} 130 | /*.dropdown-submenu>a:after{display:block;content:" ";float:left;width:0;height:0;border-color:transparent;border-style:solid;border-width:5px 0 5px 5px;border-right-color:#000;margin-top:5px;margin-right:-10px;}*/ 131 | .dropdown-submenu:hover>a:after{border-left-color:#000;} 132 | .dropdown-submenu.pull-left{float:none;}.dropdown-submenu.pull-left>.dropdown-menu{right:-100%;margin-left:10px;-webkit-border-radius:6px 0 6px 6px;-moz-border-radius:6px 0 6px 6px;border-radius:6px 0 6px 6px;} 133 | .borderbtm 134 | { 135 | border-bottom: 1px solid #d7d7d7; 136 | } 137 | 138 | #overlay 139 | { 140 | position: fixed; 141 | top: 0; 142 | left: 0; 143 | width: 100%; 144 | height: 100%; 145 | background-color: #000; 146 | filter: alpha(opacity=70); 147 | -moz-opacity: 0.7; 148 | -khtml-opacity: 0.7; 149 | opacity: 0.7; 150 | z-index: 100; 151 | display: none; 152 | } 153 | .popup 154 | { 155 | width: 100%; 156 | margin: 0 auto; 157 | display: none; 158 | position: fixed; 159 | z-index: 101; 160 | } 161 | 162 | .table.table-bordered thead tr th 163 | { 164 | text-transform:uppercase !important; 165 | } 166 | .table.table-bordered thead tr td 167 | { 168 | text-transform:uppercase !important; 169 | } -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/jquery.slimscroll.min.js: -------------------------------------------------------------------------------- 1 | /*! Copyright (c) 2011 Piotr Rochala (http://rocha.la) 2 | * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) 3 | * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses. 4 | * 5 | * Version: 1.2.0 6 | * 7 | */ 8 | (function(a){jQuery.fn.extend({slimScroll:function(b){var c={width:"auto",height:"250px",size:"7px",color:"#000",position:"right",distance:"1px",start:"top",opacity:0.4,alwaysVisible:false,disableFadeOut:false,railVisible:false,railColor:"#333",railOpacity:0.2,railDraggable:true,railClass:"slimScrollRail",barClass:"slimScrollBar",wrapperClass:"slimScrollDiv",allowPageScroll:false,wheelStep:20,touchScrollStep:200,borderRadius:"7px",railBorderRadius:"7px"};var d=a.extend(c,b);this.each(function(){var w,r,k,p,z,s,o,j,l="
    ",t=30,q=false;var A=a(this);if(A.parent().hasClass(d.wrapperClass)){var h=A.scrollTop();u=A.parent().find("."+d.barClass);e=A.parent().find("."+d.railClass);B();if(a.isPlainObject(b)){if("height" in b&&b.height=="auto"){A.parent().css("height","auto");A.css("height","auto");var n=A.parent().parent().height();A.parent().css("height",n);A.css("height",n)}if("scrollTo" in b){h=parseInt(d.scrollTo)}else{if("scrollBy" in b){h+=parseInt(d.scrollBy)}else{if("destroy" in b){u.remove();e.remove();A.unwrap();return}}}v(h,false,true)}return}d.height=(d.height=="auto")?A.parent().height():d.height;var i=a(l).addClass(d.wrapperClass).css({position:"relative",overflow:"hidden",width:d.width,height:d.height});A.css({overflow:"hidden",width:d.width,height:d.height});var e=a(l).addClass(d.railClass).css({width:d.size,height:"100%",position:"absolute",top:0,display:(d.alwaysVisible&&d.railVisible)?"block":"none","border-radius":d.railBorderRadius,background:d.railColor,opacity:d.railOpacity,zIndex:90});var u=a(l).addClass(d.barClass).css({background:d.color,width:d.size,position:"absolute",top:0,opacity:d.opacity,display:d.alwaysVisible?"block":"none","border-radius":d.borderRadius,BorderRadius:d.borderRadius,MozBorderRadius:d.borderRadius,WebkitBorderRadius:d.borderRadius,zIndex:99});var f=(d.position=="right")?{right:d.distance}:{left:d.distance};e.css(f);u.css(f);A.wrap(i);A.parent().append(u);A.parent().append(e);if(d.railDraggable&&a.ui&&typeof(a.ui.draggable)=="function"){u.draggable({axis:"y",containment:"parent",start:function(){k=true},stop:function(){k=false;m()},drag:function(C){v(0,a(this).position().top,false)}})}e.hover(function(){g()},function(){m()});u.hover(function(){r=true},function(){r=false});A.hover(function(){w=true;g();m()},function(){w=false;m()});A.bind("touchstart",function(D,C){if(D.originalEvent.touches.length){z=D.originalEvent.touches[0].pageY}});A.bind("touchmove",function(D){D.originalEvent.preventDefault();if(D.originalEvent.touches.length){var C=(z-D.originalEvent.touches[0].pageY)/d.touchScrollStep;v(C,true)}});if(d.start==="bottom"){u.css({top:A.outerHeight()-u.outerHeight()});v(0,true)}else{if(d.start!=="top"){v(a(d.start).position().top,null,true);if(!d.alwaysVisible){u.hide()}}}x();B();function y(D){if(!w){return}var D=D||window.event;var E=0;if(D.wheelDelta){E=-D.wheelDelta/120}if(D.detail){E=D.detail/3}var C=D.target||D.srcTarget||D.srcElement;if(a(C).closest("."+d.wrapperClass).is(A.parent())){v(E,true)}if(D.preventDefault&&!q){D.preventDefault()}if(!q){D.returnValue=false}}function v(H,E,C){var G=H;var F=A.outerHeight()-u.outerHeight();if(E){G=parseInt(u.css("top"))+H*parseInt(d.wheelStep)/100*u.outerHeight();G=Math.min(Math.max(G,0),F);G=(H>0)?Math.ceil(G):Math.floor(G);u.css({top:G+"px"})}o=parseInt(u.css("top"))/(A.outerHeight()-u.outerHeight());G=o*(A[0].scrollHeight-A.outerHeight());if(C){G=H;var D=G/A[0].scrollHeight*A.outerHeight();D=Math.min(Math.max(D,0),F);u.css({top:D+"px"})}A.scrollTop(G);A.trigger("slimscrolling",~~G);g();m()}function x(){if(window.addEventListener){this.addEventListener("DOMMouseScroll",y,false);this.addEventListener("mousewheel",y,false)}else{document.attachEvent("onmousewheel",y)}}function B(){s=Math.max((A.outerHeight()/A[0].scrollHeight)*A.outerHeight(),t);u.css({height:s+"px"});var C=s==A.outerHeight()?"none":"block";u.css({display:C})}function g(){B();clearTimeout(p);if(o==~~o){q=d.allowPageScroll;if(j!=o){var C=(~~o==0)?"top":"bottom";A.trigger("slimscroll",C)}}else{q=false}j=o;if(s>=A.outerHeight()){q=true;return}u.stop(true,true).fadeIn("fast");if(d.railVisible){e.stop(true,true).fadeIn("fast")}}function m(){if(!d.alwaysVisible){p=setTimeout(function(){if(!(d.disableFadeOut&&w)&&!r&&!k){u.fadeOut("slow");e.fadeOut("slow")}},1000)}}});return this}});jQuery.fn.extend({slimscroll:jQuery.fn.slimScroll})})(jQuery); -------------------------------------------------------------------------------- /src/templates/itemControls.html: -------------------------------------------------------------------------------- 1 |
    2 |
    3 | 4 | - 5 |
    6 |
    7 | 8 | - 9 |
    10 |
    11 | 12 | - 13 |
    14 |
    15 | 16 | - 17 |
    18 |
    19 |
     
    20 |
    21 |
    22 | 23 |
    24 |
    25 | 26 |
    27 |
    28 | 29 |
    30 |
    31 | 32 |
    33 |
    34 | 35 |
    36 |
    MoveTo
    37 |
    38 | 39 |
    40 |
    41 | 42 |
    43 |
    44 |
    -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/dataTables.responsive.min.js: -------------------------------------------------------------------------------- 1 | /*! 2 | Responsive 1.0.7 3 | 2014-2015 SpryMedia Ltd - datatables.net/license 4 | */ 5 | (function(n,p){var o=function(e,k){var h=function(d,a){if(!k.versionCheck||!k.versionCheck("1.10.1"))throw"DataTables Responsive requires DataTables 1.10.1 or newer";this.s={dt:new k.Api(d),columns:[]};this.s.dt.settings()[0].responsive||(a&&"string"===typeof a.details&&(a.details={type:a.details}),this.c=e.extend(!0,{},h.defaults,k.defaults.responsive,a),d.responsive=this,this._constructor())};h.prototype={_constructor:function(){var d=this,a=this.s.dt;a.settings()[0]._responsive=this;e(n).on("resize.dtr orientationchange.dtr", 6 | a.settings()[0].oApi._fnThrottle(function(){d._resize()}));a.on("destroy.dtr",function(){e(n).off("resize.dtr orientationchange.dtr draw.dtr")});this.c.breakpoints.sort(function(a,c){return a.widthc.width?-1:0});this._classLogic();this._resizeAuto();var c=this.c.details;c.type&&(d._detailsInit(),this._detailsVis(),a.on("column-visibility.dtr",function(){d._detailsVis()}),a.on("draw.dtr",function(){a.rows({page:"current"}).iterator("row",function(b,c){var f=a.row(c);if(f.child.isShown()){var i= 7 | d.c.details.renderer(a,c);f.child(i,"child").show()}})}),e(a.table().node()).addClass("dtr-"+c.type));this._resize()},_columnsVisiblity:function(d){var a=this.s.dt,c=this.s.columns,b,g,f=e.map(c,function(a){return a.auto&&null===a.minWidth?!1:!0===a.auto?"-":-1!==e.inArray(d,a.includeIn)}),i=0;b=0;for(g=f.length;ba-c[b].minWidth?(i=!0,f[b]=!1):f[b]=!0,a-=c[b].minWidth);a=!1;b=0;for(g=c.length;b=j&&b(f,a[g].name)}else{if("not-"===e){g=0;for(e=a.length;g").append(f).appendTo(b);"inline"===this.c.details.type&&e(c).addClass("dtr-inline collapsed");c=e("
    ").css({width:1,height:1,overflow:"hidden"}).append(c);c.find("th.never, td.never").remove();c.insertBefore(d.table().node());d.columns().eq(0).each(function(b){a[b].minWidth=f[b].offsetWidth||0});c.remove()}}};h.breakpoints=[{name:"desktop",width:Infinity},{name:"tablet-l",width:1024},{name:"tablet-p",width:768},{name:"mobile-l",width:480},{name:"mobile-p",width:320}];h.defaults={breakpoints:h.breakpoints, 16 | auto:!0,details:{renderer:function(d,a){var c=d.cells(a,":hidden").eq(0).map(function(a){var c=e(d.column(a.column).header()),a=d.cell(a).index();if(c.hasClass("control")||c.hasClass("never"))return"";var f=d.settings()[0],f=f.oApi._fnGetCellData(f,a.row,a.column,"display");(c=c.text())&&(c+=":");return'
  • '+c+' '+f+"
  • "}).toArray().join("");return c?e('
      ').append(c):!1},target:0, 17 | type:"inline"}};var m=e.fn.dataTable.Api;m.register("responsive()",function(){return this});m.register("responsive.index()",function(d){d=e(d);return{column:d.data("dtr-index"),row:d.parent().data("dtr-index")}});m.register("responsive.rebuild()",function(){return this.iterator("table",function(d){d._responsive&&d._responsive._classLogic()})});m.register("responsive.recalc()",function(){return this.iterator("table",function(d){d._responsive&&(d._responsive._resizeAuto(),d._responsive._resize())})}); 18 | h.version="1.0.7";e.fn.dataTable.Responsive=h;e.fn.DataTable.Responsive=h;e(p).on("init.dt.dtr",function(d,a){if("dt"===d.namespace&&(e(a.nTable).hasClass("responsive")||e(a.nTable).hasClass("dt-responsive")||a.oInit.responsive||k.defaults.responsive)){var c=a.oInit.responsive;!1!==c&&new h(a,e.isPlainObject(c)?c:{})}});return h};"function"===typeof define&&define.amd?define(["jquery","datatables"],o):"object"===typeof exports?o(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.Responsive&& 19 | o(jQuery,jQuery.fn.dataTable)})(window,document); 20 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/StudentStationPref.js: -------------------------------------------------------------------------------- 1 | $(document).ready(function () { 2 | 3 | 4 | getdetail("0"); 5 | StudentStationpref(); 6 | 7 | 8 | //window.onbeforeunload = function () { 9 | // var changesSaved = confirm("We have saved your changes. Are you sure you want to leave the page?"); 10 | // if (changesSaved) { 11 | // return true; 12 | // } else { 13 | // return false; 14 | // } 15 | //} 16 | 17 | 18 | 19 | var responsejson = ""; 20 | 21 | 22 | 23 | 24 | $('#btnSave').one("click", function () { 25 | 26 | //$('#btnSave').click(function () { 27 | 28 | 29 | 30 | 31 | 32 | 33 | var accomo = "false"; 34 | var contistation = 1; 35 | var i = 0; 36 | jsondata = ""; 37 | jsonvalue = ""; 38 | 39 | 40 | 41 | jsondata = "["; 42 | 43 | $('.spanclass').each(function () { 44 | // $('#PS-II').is(':checked') == true 45 | if ($('.accomo[chkaccomo="' + $(this).attr("spn") + '"]').is(':checked') == true) { 46 | accomo = "true"; 47 | } 48 | else { 49 | accomo = "false"; 50 | } 51 | 52 | //if ($('#consta').is(":checked")) { 53 | // contistation = 1; 54 | //} 55 | //else { 56 | // contistation = 0; 57 | //} 58 | i = i + 1; 59 | jsondata += "{" 60 | jsondata += "'isActive':'1'," 61 | jsondata += "'PreferenceNo':'" + i + "','StationId':'" + $(this).attr("spn") + "'," 62 | jsondata += "'Accommodation':'" + accomo + "'," 63 | 64 | jsondata += "}," 65 | 66 | }); 67 | jsondata = jsondata.substr(0, jsondata.length - 1); 68 | jsondata += "]"; 69 | 70 | 71 | if ($('#consta').is(":checked")) { 72 | contistation = 1; 73 | jsonvalue += "'isActive':'1'," 74 | jsonvalue += "'ContinueStation':'"+ contistation+"'," 75 | jsonvalue = jsonvalue.substr(0, jsonvalue.length - 1); 76 | jsonvalue = '{' + jsonvalue + '}'; 77 | } 78 | else { 79 | contistation = 0; 80 | 81 | } 82 | 83 | 84 | // alert(jsondata); 85 | saveprefdata(jsondata, jsonvalue, contistation); 86 | 87 | 88 | }); 89 | 90 | $('#Reset').click(function () { 91 | window.location = self.location; 92 | getdetail("0"); 93 | 94 | }); 95 | 96 | 97 | }); 98 | 99 | function getUrlVars() { 100 | var vars = [], hash; 101 | var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&'); 102 | for (var i = 0; i < hashes.length; i++) { 103 | hash = hashes[i].split('='); 104 | vars.push(hash[0]); 105 | vars[hash[0]] = hash[1]; 106 | } 107 | return vars; 108 | } 109 | 110 | function saveprefdata(data, jsonvalue, contistation) { 111 | 112 | $('#loading').html(''); 113 | $('#loading').show() 114 | $.ajax({ 115 | type: "POST", 116 | url: "StudentStationPreference.aspx/saveStudentStationPref", 117 | contentType: "application/json; charset=utf-8", 118 | // global: false, 119 | // async: false, 120 | 121 | 122 | data: '{ jsondata: "' + encodeURIComponent(data) + '", jsonvalue: "' + encodeURIComponent(jsonvalue) + '", contistation: "' + encodeURIComponent(contistation) + '"}', 123 | dataType: "json", 124 | 125 | 126 | 127 | success: function (response) { 128 | 129 | var sParsedJson = jQuery.parseJSON(response.d); 130 | if (sParsedJson[0].message.trim() != "") { 131 | 132 | 133 | alert(sParsedJson[0].message); 134 | 135 | 136 | } 137 | // $('#loading').html("").hide(); 138 | // alert("Station Preference Submitted Successfully."); 139 | $('#loading').html("").hide(); 140 | 141 | 142 | // "window.location.replace("FillProbBankSkills.aspx", "_newtab");" 143 | window.location.replace("NEWStudentDashboard.aspx"); 144 | 145 | // this.GetType(), "OpenWindow", 146 | 147 | 148 | // window.open('FillProbBankSkills.aspx','_newtab',true); 149 | 150 | } 151 | }); 152 | 153 | } 154 | 155 | 156 | function getdetail(id) { 157 | $('#loading').html(''); 158 | $('#loading').show() 159 | $.ajax({ 160 | type: "POST", 161 | url: "StudentStationPreference.aspx/getinfoStation", 162 | contentType: "application/json; charset=utf-8", 163 | global: false, 164 | async: false, 165 | data: '{CompanyId: "' + id + '" }', 166 | dataType: "json", 167 | success: function (response) { 168 | 169 | $('#loading').html("").hide(); 170 | 171 | var sParsedJson = jQuery.parseJSON(response.d); 172 | 173 | for (var i = 0; i < sParsedJson.length; i++) { 174 | $("#Sno").text(i + 1); 175 | 176 | $(".list ul").append('
    • ' + sParsedJson[i].Companyname + '    
      ' + sParsedJson[i].Sno + '
    • '); 177 | } 178 | } 179 | }); 180 | $('#loading').html("").hide(); 181 | } 182 | 183 | function StudentStationpref() { 184 | $('#loading').html(''); 185 | $('#loading').show() 186 | $.ajax({ 187 | type: "POST", 188 | url: "StudentStationPreference.aspx/chkStationpref", 189 | contentType: "application/json; charset=utf-8", 190 | global: false, 191 | async: false, 192 | data: '{contactid: "0"}', 193 | dataType: "json", 194 | success: function (response) { 195 | if (response.d == '[]') { 196 | 197 | $('#loading').html("").hide(); 198 | return false; 199 | } 200 | $('#loading').html("").hide(); 201 | var sParsedJson = jQuery.parseJSON(response.d); 202 | $(".list ul").empty() 203 | for (var i = 0; i < sParsedJson.length; i++) { 204 | var sno= $("#Sno").text(i + 1); 205 | $(".list ul").append('
    • ' + sParsedJson[i].Companyname + '    
      ' + (i+1) + '
    • '); 206 | 207 | if (sParsedJson[i].Accommodation == "true") { 208 | $('input[type="checkbox"][name="accomoPreference"][value="' + sParsedJson[i].StationId + '"]').attr("checked", "checked") 209 | } 210 | 211 | } 212 | } 213 | }); 214 | $('#loading').html("").hide(); 215 | } 216 | 217 | function show() { 218 | 219 | $('#loading').show() 220 | } 221 | function hide() { 222 | $('#loading').html("").hide(); 223 | } 224 | -------------------------------------------------------------------------------- /test/StudentStationPreference.aspx_files/buttons.flash.min.js: -------------------------------------------------------------------------------- 1 | (function(g,f){var e={version:"1.0.4-TableTools2",clients:{},moviePath:"",nextId:1,$:function(a){"string"==typeof a&&(a=document.getElementById(a));a.addClass||(a.hide=function(){this.style.display="none"},a.show=function(){this.style.display=""},a.addClass=function(a){this.removeClass(a);this.className+=" "+a},a.removeClass=function(a){this.className=this.className.replace(RegExp("\\s*"+a+"\\s*")," ").replace(/^\s+/,"").replace(/\s+$/,"")},a.hasClass=function(a){return!!this.className.match(RegExp("\\s*"+ 2 | a+"\\s*"))});return a},setMoviePath:function(a){this.moviePath=a},dispatch:function(a,b,d){(a=this.clients[a])&&a.receiveEvent(b,d)},register:function(a,b){this.clients[a]=b},getDOMObjectPosition:function(a){var b={left:0,top:0,width:a.width?a.width:a.offsetWidth,height:a.height?a.height:a.offsetHeight};""!==a.style.width&&(b.width=a.style.width.replace("px",""));""!==a.style.height&&(b.height=a.style.height.replace("px",""));for(;a;)b.left+=a.offsetLeft,b.top+=a.offsetTop,a=a.offsetParent;return b}, 3 | Client:function(a){this.handlers={};this.id=e.nextId++;this.movieId="ZeroClipboard_TableToolsMovie_"+this.id;e.register(this.id,this);a&&this.glue(a)}};e.Client.prototype={id:0,ready:!1,movie:null,clipText:"",fileName:"",action:"copy",handCursorEnabled:!0,cssEffects:!0,handlers:null,sized:!1,glue:function(a,b){this.domElement=e.$(a);var d=99;this.domElement.style.zIndex&&(d=parseInt(this.domElement.style.zIndex,10)+1);var c=e.getDOMObjectPosition(this.domElement);this.div=document.createElement("div"); 4 | var h=this.div.style;h.position="absolute";h.left="0px";h.top="0px";h.width=c.width+"px";h.height=c.height+"px";h.zIndex=d;"undefined"!=typeof b&&""!==b&&(this.div.title=b);0!==c.width&&0!==c.height&&(this.sized=!0);this.domElement&&(this.domElement.appendChild(this.div),this.div.innerHTML=this.getHTML(c.width,c.height).replace(/&/g,"&"))},positionElement:function(){var a=e.getDOMObjectPosition(this.domElement),b=this.div.style;b.position="absolute";b.width=a.width+"px";b.height=a.height+"px"; 5 | 0!==a.width&&0!==a.height&&(this.sized=!0,b=this.div.childNodes[0],b.width=a.width,b.height=a.height)},getHTML:function(a,b){var d="",c="id="+this.id+"&width="+a+"&height="+b;if(navigator.userAgent.match(/MSIE/))var h=location.href.match(/^https/i)?"https://":"http://",d=d+('');else d+='';return d},hide:function(){this.div&&(this.div.style.left="-2000px")},show:function(){this.reposition()},destroy:function(){var a=this;this.domElement&&this.div&&(g(this.div).remove(),this.div=this.domElement=null,g.each(e.clients,function(b,d){d===a&&delete e.clients[b]}))},reposition:function(a){a&&((this.domElement=e.$(a))||this.hide());if(this.domElement&&this.div){var a=e.getDOMObjectPosition(this.domElement),b=this.div.style;b.left=""+a.left+"px";b.top=""+a.top+"px"}}, 8 | clearText:function(){this.clipText="";this.ready&&this.movie.clearText()},appendText:function(a){this.clipText+=a;this.ready&&this.movie.appendText(a)},setText:function(a){this.clipText=a;this.ready&&this.movie.setText(a)},setFileName:function(a){this.fileName=a;this.ready&&this.movie.setFileName(a)},setAction:function(a){this.action=a;this.ready&&this.movie.setAction(a)},addEventListener:function(a,b){a=a.toString().toLowerCase().replace(/^on/,"");this.handlers[a]||(this.handlers[a]=[]);this.handlers[a].push(b)}, 9 | setHandCursor:function(a){this.handCursorEnabled=a;this.ready&&this.movie.setHandCursor(a)},setCSSEffects:function(a){this.cssEffects=!!a},receiveEvent:function(a,b){var d,a=a.toString().toLowerCase().replace(/^on/,"");switch(a){case "load":this.movie=document.getElementById(this.movieId);if(!this.movie){d=this;setTimeout(function(){d.receiveEvent("load",null)},1);return}if(!this.ready&&navigator.userAgent.match(/Firefox/)&&navigator.userAgent.match(/Windows/)){d=this;setTimeout(function(){d.receiveEvent("load", 10 | null)},100);this.ready=!0;return}this.ready=!0;this.movie.clearText();this.movie.appendText(this.clipText);this.movie.setFileName(this.fileName);this.movie.setAction(this.action);this.movie.setHandCursor(this.handCursorEnabled);break;case "mouseover":this.domElement&&this.cssEffects&&this.recoverActive&&this.domElement.addClass("active");break;case "mouseout":this.domElement&&this.cssEffects&&(this.recoverActive=!1,this.domElement.hasClass("active")&&(this.domElement.removeClass("active"),this.recoverActive= 11 | !0));break;case "mousedown":this.domElement&&this.cssEffects&&this.domElement.addClass("active");break;case "mouseup":this.domElement&&this.cssEffects&&(this.domElement.removeClass("active"),this.recoverActive=!1)}if(this.handlers[a])for(var c=0,h=this.handlers[a].length;c'+a[c]+"":''+a[c]+"");return""+b.join("")+""};c.header&&(a+=e(b.header));for(var f=0,i=b.body.length;f\t', 8 | "xl/_rels/workbook.xml.rels":'\t',"[Content_Types].xml":'\t\t\t\t\t', 9 | "xl/workbook.xml":'\t\t\t\t\t\t\t\t\t\t', 10 | "xl/worksheets/sheet1.xml":'\t\t\t__DATA__\t'};n.ext.buttons.copyHtml5={className:"buttons-copy buttons-html5", 11 | text:function(a){return a.i18n("buttons.copy","Copy")},action:function(a,b,d,c){q(c);a=z(b,c).str;a=h(""+b.i18n("buttons.copyKeys","Press ctrl or + C to copy the table data
      to your system clipboard.

      To cancel, click this message or press escape.")+"
      ").append(h("
      ").css({height:1,width:1,overflow:"hidden"}).append(h("