From ee0fe0e62ad432ecb7b47a68190c68d02d79bc15 Mon Sep 17 00:00:00 2001 From: Mukul Date: Tue, 4 Apr 2017 12:42:12 +0530 Subject: [PATCH] Lexicon Issue --- 400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js | 80 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++----- 400-SOURCECODE/AIAHTML5.Web/content/data/json/da/uc_dat_default.json | 1 + 400-SOURCECODE/AIAHTML5.Web/index.html | 30 +++++++++++------------------- 3 files changed, 87 insertions(+), 24 deletions(-) create mode 100644 400-SOURCECODE/AIAHTML5.Web/content/data/json/da/uc_dat_default.json diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index 75de438..6b21d61 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -1,7 +1,7 @@ 'use strict'; -AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", "$timeout", "DataService", "AuthenticationService", "LoginConstants","UserModules","LoginMessageConstants","AdminService", "AdminConstants", "UserTypeConstants", -function ($rootScope, Modules, $log, $location, $timeout, DataService, AuthenticationService, LoginConstants, UserModules, LoginMessageConstants, AdminService, AdminConstants, UserTypeConstants) { +AIA.controller("HomeController", ["$rootScope", "Modules", "$log", "$location", "$timeout", "DataService", "AuthenticationService", "LoginConstants","UserModules","LoginMessageConstants","AdminService","$http", "AdminConstants", "UserTypeConstants", +function ($rootScope, Modules, $log, $location, $timeout, DataService, AuthenticationService, LoginConstants, UserModules, LoginMessageConstants, AdminService, AdminConstants, UserTypeConstants, $http) { //$scope.pageToOpen = { // name: 'MainMenu' @@ -332,11 +332,79 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic $("#messageModal").modal('show'); } } + + + $(document).ready(function () { + // getUserDetails(); + + // var ajaxResult = []; + // var ajaxResult1 = []; + $rootScope.isLexiconTabClicked = true; + $rootScope.lexiconData = function () { + if ($rootScope.isLexiconTabClicked == true) { + $rootScope.isLexiconTabClicked = false; + $.ajax({ + url: '~/../content/data/json/da/uc_dat_default.json', + dataType: "json", + success: function (result) { + $(result.root.uc.al.lx).each(function (key, value) { + // alert(this._tl); + $('#lexiconLangDropdown').append('') + }); + } - $(document).ready(function () { - // getUserDetails(); + }); + } + $('#lexiconLangDropdown').change(function () { + $rootScope.isLexiconLanguageClicked = true; + $('#laxiconLangAdd').removeAttr('disabled'); + $('#laxicanlanguageChagne').removeAttr('disabled'); + $rootScope.selectedId = $("#lexiconLangDropdown option:selected").attr('val'); + $rootScope.selectedText = $("#lexiconLangDropdown option:selected").text(); + }); + + $('#laxiconLangAdd').click(function () { + if($rootScope.isLexiconLanguageClicked == true){ + $rootScope.isLexiconLanguageClicked = false; + $("#lexiconLangDropdown :selected").remove(); + $('#secondLax').append(''); + } + }); + + $('#secondLax').change(function () { + $rootScope.isActiveLexiconLanguageClicked = true; + $rootScope.secondlaxdid = $("#secondLax option:selected").attr('val'); + $rootScope.secondlaxtext = $("#secondLax option:selected").text(); + + }); + + $("#laxiconLangRemove").click(function () { + if ($rootScope.isActiveLexiconLanguageClicked == true) { + $rootScope.isActiveLexiconLanguageClicked = false; + $("#secondLax :selected").remove(); + $('#lexiconLangDropdown').append(''); + } + }); + $("#laxicanlanguageChagne").click(function () { + if ($rootScope.isLexiconLanguageClicked == true) + { + $rootScope.isLexiconLanguageClicked = false; + var primarylaxiid = $("#lexiconLangDropdown option:selected").attr('val'); + var primarylaxicantext = $("#lexiconLangDropdown option:selected").text(); + $("#lexiconLangDropdown :selected").remove(); + $('#lexiconLangDropdown').append(''); + $('#primarylaxican').val(primarylaxicantext); + $('#primarylaxican').attr("name", primarylaxiid); + } + + }); + } + + + + $(function () { var colpick = $('.demo').each(function () { @@ -2978,6 +3046,7 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic $('#listManager').draggable(); + $rootScope.islistManagerEventAlredayDispachted = true; @@ -3374,7 +3443,8 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic top: 70, left: 1, }, - size: { width: $(window).outerWidth(), height: $(window).outerHeight() + 60}, + size: { width: $(window).outerWidth(), height: $(window).outerHeight() + 60}, + //size: { width: $(window).outerWidth() - 10, height: $(window).outerHeight() - 110 }, }); } diff --git a/400-SOURCECODE/AIAHTML5.Web/content/data/json/da/uc_dat_default.json b/400-SOURCECODE/AIAHTML5.Web/content/data/json/da/uc_dat_default.json new file mode 100644 index 0000000..47e416a --- /dev/null +++ b/400-SOURCECODE/AIAHTML5.Web/content/data/json/da/uc_dat_default.json @@ -0,0 +1 @@ +{ "root": {"uc": {"pl": {"lx": {"_id": "1", "_tl": "English" } }, "al": { "lx": [ {"_id": "2", "_tl": "English (Undergraduate)" }, {"_id": "3", "_tl": "Swedish" }, {"_id": "4", "_tl": "German" }, {"_id": "5", "_tl": "Spanish" }, {"_id": "6", "_tl": "Hungarian" }, {"_id": "7", "_tl": "Italian" }, {"_id": "8", "_tl": "French" }, {"_id": "9", "_tl": "Portuguese" }, {"_id": "10", "_tl": "Japanese (Kanji)" }, {"_id": "11", "_tl": "Japanese (Yomi)" } ] }, "sl": null, "sktn": {"_id": "W" }, "mst": {"_st": "1" }, "an": {"_st": "1" }, "fn": {"_fml": "Arial", "_wht": "normal", "_stl": "normal", "_sz": "12" } } }} \ No newline at end of file diff --git a/400-SOURCECODE/AIAHTML5.Web/index.html b/400-SOURCECODE/AIAHTML5.Web/index.html index 0c63087..8a06d9d 100644 --- a/400-SOURCECODE/AIAHTML5.Web/index.html +++ b/400-SOURCECODE/AIAHTML5.Web/index.html @@ -464,7 +464,7 @@ @@ -490,33 +490,25 @@
- - -
+ + +
- + + +
- - + +
- -

Note : Some languages require special system fonts to display correctly

-- libgit2 0.21.4