Created
January 8, 2019 07:10
-
-
Save keerthanaRajendran/4dd858e2a0b313974651e48fcb441222 to your computer and use it in GitHub Desktop.
Uploadbox : events
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<require from="./events.css"></require> | |
<div> | |
<div class="posupload">Select a file to upload </div> | |
<div class="uploadbox-events-control"> | |
<ej-uploadbox id="UploadEvents" e-save-url.bind="saveURL" e-remove-url.bind="removeURL" | |
e-on-error.trigger="error($event)" e-on-success.trigger="success($event)"> | |
</ej-uploadbox> | |
</div> | |
</div> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export class EventsUploadbox { | |
constructor() { | |
this.saveURL = 'http://mvc.syncfusion.com/Services/FileUpload/UploadBox/saveFiles'; | |
this.removeURL = 'http://mvc.syncfusion.com/Services/FileUpload/UploadBox/removeFiles'; | |
} | |
error(event) { | |
alert(event.detail.error); | |
} | |
success(event) { | |
alert("Success"); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.uploadbox-events-control { | |
margin: 0 auto; | |
width:100px; | |
height:35px; | |
} | |
.posupload { | |
text-align:center; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html xmlns="http://www.w3.org/1999/xhtml"> | |
<head> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta name="description" content="Essential Studio for JavaScript"> | |
<meta name="author" content="Syncfusion"> | |
<title>Untitled</title> | |
<!-- Essential Studio for JavaScript theme reference --> | |
<link rel="stylesheet" href="https://cdn.syncfusion.com/14.2.0.28/js/web/flat-azure/ej.web.all.min.css" /> | |
</head> | |
<body aurelia-app="main"> | |
<h1>Loading...</h1> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/systemjs/0.19.6/system.js"></script> | |
<script src="https://rawgit.com/aurelia-ui-toolkits/aurelia-syncfusion-bundles/0.0.1/config2.js"></script> | |
<script> | |
System.import('aurelia-bootstrapper'); | |
</script> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function configure(aurelia) { | |
aurelia.use | |
.standardConfiguration() | |
.developmentLogging() | |
.plugin('aurelia-syncfusion-bridge', syncfusion => syncfusion.useAll()); | |
aurelia.start().then(a => a.setRoot()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment