12345678910111213141516171819 |
- (function ($) {
- $.fn.switchView = function () {
- $(this).on('click', function(e) {
- e.preventDefault();
- change();
- });
- function change () {
- $.ajax({
- url: "/changeview",
- type: 'GET',
- dataType: 'json',
- success: function (reponse) {
- window.location.reload();
- }
- })
- }
- }
- })(jQuery);
|