AUTO SAVE CODE MERGE--SV
This commit is contained in:
commit
4ff82d2995
@ -40,8 +40,10 @@
|
||||
<link rel="stylesheet" href="assets/css/responsive.css" type="text/css" media="all" />
|
||||
<!-- modernizr js -->
|
||||
<script src="assets/js/vendor/modernizr-3.5.0.min.js"></script>
|
||||
<link href='https://fonts.googleapis.com/css?family=Titillium+Web:400,600' rel='stylesheet' type='text/css'>
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.9.1/font/bootstrap-icons.css">
|
||||
<link rel="stylesheet" href="./assets/css/titillium.css" type="text/css">
|
||||
<!-- <link href='https://fonts.googleapis.com/css?family=Titillium+Web:400,600' rel='stylesheet' type='text/css'> -->
|
||||
<link rel="stylesheet" href="./node_modules/bootstrap-icons/font/bootstrap-icons.css">
|
||||
<!-- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.9.1/font/bootstrap-icons.css"> -->
|
||||
|
||||
|
||||
|
||||
@ -219,8 +221,10 @@
|
||||
|
||||
|
||||
<script>
|
||||
const fs = require('fs');
|
||||
const fs = require('fs');
|
||||
|
||||
require('dotenv').config();
|
||||
//get value from .env
|
||||
const isEncrypted = process.env.ENCRYPTED;
|
||||
|
||||
const url = new URL(window.location.href);// Get the URL of the current page for JSON
|
||||
@ -233,9 +237,12 @@
|
||||
|
||||
// Function to load XML from a file
|
||||
function loadXML(xmlFileName) {
|
||||
|
||||
//XmlPath get from .env
|
||||
const xmlPath=process.env.XML_FILE_PATH;
|
||||
console.log(xmlFileName)
|
||||
return new Promise((resolve, reject) => {
|
||||
fs.readFile('xml/'+xmlFileName, 'utf8', (error, data) => {
|
||||
fs.readFile(`${xmlPath}`+xmlFileName, 'utf8', (error, data) => {
|
||||
if (error) {
|
||||
reject(error);
|
||||
} else {
|
||||
|
||||
67
addform.html
67
addform.html
@ -354,7 +354,7 @@
|
||||
<ul>
|
||||
<li><a href="dashboard.html"><i class="fa fa-home" aria-hidden="true" style="font-size: 24px;"></i> Home</a></li>
|
||||
<li><a href="#" class="myBtn" onclick="saveFile()" id="SaveButton"><i class="fa fa-floppy-o" aria-hidden="true" style="font-size: 20px;"></i> Save</a></li>
|
||||
<li><a id="editpreview" href=""><i class="fa fa-eye" aria-hidden="true" style="font-size: 24px;"></i> Preview</a></li>
|
||||
<li><a id="editPreview" href=""><i class="fa fa-eye" aria-hidden="true" style="font-size: 24px;"></i> Preview</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@ -537,17 +537,13 @@
|
||||
<!-- RTC Hide and Show Script -->
|
||||
<script src="rtc_hide_and_show.js"></script>
|
||||
|
||||
<!-- decrypt -->
|
||||
<script src="decode.js"></script>
|
||||
|
||||
|
||||
<!-- nave pane -->
|
||||
<script src="nav_pane.js"></script>
|
||||
<!-- <script>
|
||||
var questionPaperElement = document.getElementById("questionPaper");
|
||||
function saveoldnav(){
|
||||
localStorage.setItem("OLD_JSON_FOR_NAV", JSON.stringify((questionPaperElement)));
|
||||
}
|
||||
</script> -->
|
||||
|
||||
<script src="main.js"></script>
|
||||
<script>
|
||||
var sidebarWrapper = document.getElementById("questionPaper");
|
||||
|
||||
@ -557,17 +553,38 @@
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
const { ipcRenderer } = require('electron');
|
||||
ipcRenderer.on('button-click', async () => {
|
||||
const saveButton = document.getElementById('SaveButton');
|
||||
|
||||
if (saveButton) {
|
||||
saveButton.click();
|
||||
await new Promise(resolve => setTimeout(resolve, 1000));
|
||||
const swalButton = document.querySelector('.swal2-confirm.swal2-styled');
|
||||
if (swalButton) {
|
||||
swalButton.click();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
</script>
|
||||
<script>
|
||||
|
||||
const url = new URL(window.location.href);// Get the URL of the current page for JSON
|
||||
const params = new URLSearchParams(url.search);// Create a URLSearchParams object from the query string
|
||||
const FileName = params.get('filename');// Get the value of a specific parameter
|
||||
|
||||
var xmlPath ="" //get the xml filepath in .env file local variable
|
||||
|
||||
$(document).ready(function() {
|
||||
|
||||
|
||||
require('dotenv').config();
|
||||
//xmlPath added
|
||||
xmlPath=process.env.XML_FILE_PATH;
|
||||
// console.log(xmlPath);
|
||||
const isEncrypted = process.env.ENCRYPTED;
|
||||
// console.log(isEncrypted);
|
||||
|
||||
$('.ql-toolbar').hide(); // Hide the Quill Text Editor if PAge load
|
||||
|
||||
@ -575,7 +592,8 @@ $(document).ready(function() {
|
||||
var random_no = Date.now();
|
||||
addSection(false, false, random_no, false, false, false, false); //Call the Default section on the QUestion paper
|
||||
}else {
|
||||
loadXML(FileName); //send filename to read xml files to using this function
|
||||
loadXML(FileName); //send filename to read xml files to using this function
|
||||
|
||||
}
|
||||
|
||||
})
|
||||
@ -595,8 +613,6 @@ $(document).on("click", function (event) {
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
const scrollToTopBtn = document.getElementById('SaveButton');
|
||||
const scrollToTopBtn2 = document.getElementById('SaveButton2');
|
||||
// require('dotenv').config();
|
||||
// const isEncrypted = process.env.ENCRYPTED;
|
||||
|
||||
// Function to keep the cursor at its current position
|
||||
function keepCursorAtPosition(event) {
|
||||
@ -610,27 +626,29 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
|
||||
|
||||
//EditPreview
|
||||
document.getElementById("editpreview").href = "QuestionPreview.html?filename=" + FileName;
|
||||
document.getElementById("editPreview").href = "QuestionPreview.html?filename=" + FileName;
|
||||
|
||||
// Function to load XML from a file
|
||||
function loadXML(xmlFileName) {
|
||||
var decodeData ="";
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
fs.readFile('xml/'+xmlFileName, 'utf8', (error, data) => {
|
||||
fs.readFile(`${xmlPath}${xmlFileName}`, 'utf8', (error, data) => {
|
||||
if (error) {
|
||||
console.error('Error reading file:', error);
|
||||
reject(error);
|
||||
} else {
|
||||
if (isEncrypted === 'YES') {
|
||||
// decrypt function call
|
||||
var decodeData = decode(data);
|
||||
resolve(decodeData);
|
||||
xml2json(decodeData);
|
||||
} else {
|
||||
resolve(data)
|
||||
xml2json(data)
|
||||
}
|
||||
// decrypt function call go to decode.js
|
||||
decodeData = decode(data);
|
||||
} else{
|
||||
decodeData = data;
|
||||
}
|
||||
resolve(decodeData)
|
||||
xml2json(decodeData)
|
||||
// json2nav();
|
||||
// clearSidebarWrapper();
|
||||
// navpane();
|
||||
// navpane();
|
||||
}
|
||||
});
|
||||
});
|
||||
@ -638,8 +656,9 @@ function loadXML(xmlFileName) {
|
||||
|
||||
// Function for Save the XML File
|
||||
function saveFile() {
|
||||
|
||||
console.log("html2json");
|
||||
html2json();
|
||||
console.log("json2xml");
|
||||
json2xml();
|
||||
|
||||
if(FileName == "" || FileName == null ){
|
||||
|
||||
32
assets/css/titillium.css
Normal file
32
assets/css/titillium.css
Normal file
@ -0,0 +1,32 @@
|
||||
/* latin-ext */
|
||||
@font-face {
|
||||
font-family: 'Titillium Web';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: url(https://fonts.gstatic.com/s/titilliumweb/v17/NaPecZTIAOhVxoMyOr9n_E7fdM3mDbRS.woff2) format('woff2');
|
||||
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
||||
}
|
||||
/* latin */
|
||||
@font-face {
|
||||
font-family: 'Titillium Web';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: url(https://fonts.gstatic.com/s/titilliumweb/v17/NaPecZTIAOhVxoMyOr9n_E7fdMPmDQ.woff2) format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
/* latin-ext */
|
||||
@font-face {
|
||||
font-family: 'Titillium Web';
|
||||
font-style: normal;
|
||||
font-weight: 600;
|
||||
src: url(https://fonts.gstatic.com/s/titilliumweb/v17/NaPDcZTIAOhVxoMyOr9n_E7ffBzCGIVzY4SY.woff2) format('woff2');
|
||||
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
||||
}
|
||||
/* latin */
|
||||
@font-face {
|
||||
font-family: 'Titillium Web';
|
||||
font-style: normal;
|
||||
font-weight: 600;
|
||||
src: url(https://fonts.gstatic.com/s/titilliumweb/v17/NaPDcZTIAOhVxoMyOr9n_E7ffBzCGItzYw.woff2) format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
@ -40,8 +40,10 @@
|
||||
<link rel="stylesheet" href="assets/css/responsive.css" type="text/css" media="all" />
|
||||
<!-- modernizr js -->
|
||||
<script src="assets/js/vendor/modernizr-3.5.0.min.js"></script>
|
||||
<link href='https://fonts.googleapis.com/css?family=Titillium+Web:400,600' rel='stylesheet' type='text/css'>
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.9.1/font/bootstrap-icons.css">
|
||||
<link rel="stylesheet" href="./assets/css/titillium.css" type="text/css">
|
||||
<!-- <link href='https://fonts.googleapis.com/css?family=Titillium+Web:400,600' rel='stylesheet' type='text/css'> -->
|
||||
<link rel="stylesheet" href="./node_modules/bootstrap-icons/font/bootstrap-icons.css">
|
||||
<!-- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.9.1/font/bootstrap-icons.css"> -->
|
||||
|
||||
|
||||
|
||||
@ -285,6 +287,9 @@ const Swal = require('sweetalert2')
|
||||
var msgDiv = document.getElementById('Message');
|
||||
var modal = document.getElementById('myModal');
|
||||
var fileInput = document.getElementById('fileInput');
|
||||
require('dotenv').config();
|
||||
//XmlPath get from .env
|
||||
const xmlPath=process.env.XML_FILE_PATH;
|
||||
|
||||
function fileupload(filePaths) {
|
||||
|
||||
@ -292,7 +297,7 @@ console.log('File path:', filePaths);
|
||||
|
||||
// Handle the selected folder path here
|
||||
// You can specify the destination folder path where you want to copy/move the files
|
||||
const destinationFolderPath = 'xml';
|
||||
const destinationFolderPath = `${xmlPath}`;
|
||||
|
||||
// Use fs to copy or move the file
|
||||
const fileName =filePaths.name;
|
||||
@ -384,6 +389,8 @@ sourceStream.on('error', (err) => {
|
||||
// Get the <span> element that closes the modal
|
||||
var span = document.getElementsByClassName("close")[0];
|
||||
|
||||
|
||||
|
||||
// When the user clicks the button, open the modal
|
||||
btn.onclick = function() {
|
||||
modal.style.display = "block";
|
||||
@ -406,21 +413,18 @@ sourceStream.on('error', (err) => {
|
||||
const file = input.files[0];
|
||||
const allowedExtensions = ["xml"];
|
||||
const fileExtension = file.name.split(".").pop().toLowerCase();
|
||||
|
||||
if (!allowedExtensions.includes(fileExtension)) {
|
||||
alert('Invalid file type. Only xml files are allowed.')
|
||||
input.value = "";
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// Function to download a file by filename
|
||||
|
||||
// Function to download a file by filename
|
||||
function downloadFile(filename) {
|
||||
|
||||
// You can change the path to your server or specify a URL to download the file
|
||||
const fileURL = `xml/${filename}`;
|
||||
const fileURL = `${xmlPath}${filename}`;
|
||||
console.log(fileURL)
|
||||
// Create a hidden anchor element to trigger the download
|
||||
const a = document.createElement('a');
|
||||
|
||||
8
index.js
8
index.js
@ -19,7 +19,11 @@
|
||||
return [];
|
||||
}
|
||||
}
|
||||
const folderName = "/xml";
|
||||
require('dotenv').config();
|
||||
//XmlPath get from .env
|
||||
const xmlPath=process.env.XML_FILE_PATH;
|
||||
|
||||
const folderName = `/${xmlPath}`;
|
||||
const filePaths = [];
|
||||
const files = getFilesInFolder(folderName);
|
||||
files.forEach((file) => {
|
||||
@ -31,7 +35,7 @@ files.forEach((file) => {
|
||||
|
||||
// Function to load XML data and populate the list view
|
||||
function loadList(xmlFilePath) {
|
||||
return fetch('xml/'+xmlFilePath)
|
||||
return fetch(`${xmlPath}`+xmlFilePath)
|
||||
.then(response => response.text())
|
||||
.then(xmlContent => {
|
||||
const parser = new DOMParser();
|
||||
|
||||
33
main.js
33
main.js
@ -7,6 +7,10 @@ const jquery = require('jquery');
|
||||
let onlineStatus = true;
|
||||
const { dialog } = require('electron');
|
||||
const saveFile = require('./savexml')
|
||||
require('dotenv').config()
|
||||
|
||||
const auto_close= process.env.DISABLE_AUTO_CLOSE;
|
||||
const auto_close_time = parseInt(process.env.AUTO_CLOSE_TIME) * 1000;
|
||||
|
||||
let mainWindow;
|
||||
|
||||
@ -26,7 +30,7 @@ async function createWindow() {
|
||||
mainWindow = null;
|
||||
});
|
||||
|
||||
// setInterval(checkInternetConnection, 5000);
|
||||
setInterval(checkInternetConnection, 5000);
|
||||
}
|
||||
|
||||
async function checkInternetConnection() {
|
||||
@ -35,20 +39,23 @@ async function checkInternetConnection() {
|
||||
if (response.ok && onlineStatus) {
|
||||
onlineStatus = false;
|
||||
|
||||
// mainWindow.webContents.send('online');
|
||||
|
||||
dialog.showMessageBox(mainWindow, {
|
||||
type: 'info',
|
||||
message: 'Internet is available. Click OK to close the app. Otherwise app will auto close in 10 seconds',
|
||||
buttons: ['OK'],
|
||||
});
|
||||
|
||||
setTimeout(() => {
|
||||
app.quit();
|
||||
}, 10000);
|
||||
if (auto_close === 'TRUE') {
|
||||
|
||||
}else{
|
||||
dialog.showMessageBox(mainWindow, {
|
||||
type: 'info',
|
||||
message: `Internet is available. Click OK to close the app. Otherwise app will auto close in ${auto_close_time/1000} Seconds`,
|
||||
buttons: ['OK'],
|
||||
});
|
||||
//Send the tigger to AutoSave the question Paper when System come's online
|
||||
mainWindow.webContents.send('button-click');
|
||||
|
||||
setTimeout(() => {
|
||||
app.quit();
|
||||
}, auto_close_time);
|
||||
}
|
||||
} else if (!response.ok && !onlineStatus) {
|
||||
onlineStatus = true;
|
||||
// mainWindow.webContents.send('offline');
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('Error checking internet connection');
|
||||
|
||||
16
package-lock.json
generated
16
package-lock.json
generated
@ -9,6 +9,7 @@
|
||||
"version": "1.0.0",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"bootstrap-icons": "^1.11.1",
|
||||
"cheerio": "^1.0.0-rc.12",
|
||||
"desandro-matches-selector": "^2.0.2",
|
||||
"dotenv": "^16.3.1",
|
||||
@ -208,6 +209,21 @@
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"node_modules/bootstrap-icons": {
|
||||
"version": "1.11.1",
|
||||
"resolved": "https://registry.npmjs.org/bootstrap-icons/-/bootstrap-icons-1.11.1.tgz",
|
||||
"integrity": "sha512-F0DDp7nKUX+x/QtpfRZ+XHFya60ng9nfdpdS59vDDfs4Uhuxp7zym/QavMsu/xx51txkoM9eVmpE7D08N35blw==",
|
||||
"funding": [
|
||||
{
|
||||
"type": "github",
|
||||
"url": "https://github.com/sponsors/twbs"
|
||||
},
|
||||
{
|
||||
"type": "opencollective",
|
||||
"url": "https://opencollective.com/bootstrap"
|
||||
}
|
||||
]
|
||||
},
|
||||
"node_modules/buffer-crc32": {
|
||||
"version": "0.2.13",
|
||||
"resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz",
|
||||
|
||||
@ -13,6 +13,7 @@
|
||||
"electron": "^26.1.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"bootstrap-icons": "^1.11.1",
|
||||
"cheerio": "^1.0.0-rc.12",
|
||||
"desandro-matches-selector": "^2.0.2",
|
||||
"dotenv": "^16.3.1",
|
||||
|
||||
@ -2,7 +2,9 @@ const fs = require('fs');
|
||||
const cheerio = require('cheerio');
|
||||
const Swal = require('sweetalert2')
|
||||
const encode = require('./encode')
|
||||
|
||||
require('dotenv').config();
|
||||
//Get the value from .env
|
||||
const isEncrypted = process.env.ENCRYPTED;
|
||||
|
||||
function saveXmlToFile(xmlData, filePath) {
|
||||
@ -47,6 +49,9 @@ function savexml(UserFilename) {
|
||||
enc = xmlString;
|
||||
}
|
||||
|
||||
//XmlPath get from .env
|
||||
const xmlPath=process.env.XML_FILE_PATH;
|
||||
|
||||
// Get the json string from localStorage for set fileName
|
||||
var jsonData = localStorage.getItem("json");
|
||||
|
||||
@ -55,7 +60,7 @@ function savexml(UserFilename) {
|
||||
// var jsonfilename = `${UserFilename}.json`;
|
||||
|
||||
// file path where you want to save the XML file
|
||||
const xmlfilePath = process.cwd() + '/xml/' + xmlfilename;
|
||||
const xmlfilePath = process.cwd() + `/${xmlPath}` + xmlfilename;
|
||||
// const jsonfilePath = process.cwd() + '/xml/' + jsonfilename;
|
||||
|
||||
// Call the function to save the XML file
|
||||
|
||||
File diff suppressed because one or more lines are too long
1
xml2/Check-Auto-Save-1n.xml
Normal file
1
xml2/Check-Auto-Save-1n.xml
Normal file
@ -0,0 +1 @@
|
||||
Ond5CUhtmItDkbsWB7/g6A==jIi6QXH7u9VEH8T0CFJ4FgC5cFXCL7WP5U63YUHNMtX17qFkwPpMIKhtfl4vyxUuekZKJnMrTmYfPDT9M4vXL6qv63bqBwzf75mTZd3b/akXKmpEEMpV/m4BICKpHHP3lZPHrTiu7ovoHpk75SWmcJiifF2/42VlN2Ast68hlE16W3N5qNd2jxBU0rYH1Dz25WHmiOg3u2VV+96LspoX3UXkFA5XQffn+iXE4eG3axSeJ+anEcsDDcDe88qzZYiSTag41I3rhnTRli/1w0L1Z8XLsVcTy+2Lwq0YdwgWpmkL/6DoODSLrefadnWqMNxUpNBNx5KxFZ1bX/4wKo7JZETcZBgeYnAKwuxrZmsyox4aJM++zD+55co+YpFw+EUgtHNaXmUVKb2NG/v9Q5KpmsIXbb/XXhtoDgdOdu8qEh1CJQfo4HSaikVQybHtzlfGOzaHKHLeBpGJFleJzVH3MUP2trESjaIdrycBE2NniYdHxRQzHTQm8VOwoZSzNRt6ASPABX+u04bQkmR7PxJ9NXY5JNeZCdJ7hWJIiltasEHIn0K80S5o6zyBMCnHUBHwzpPAdoFb/I/VDc9gfKdJnJQj1U8JXAmq078ro7M80dtXSxBEOtuN/M1gtntmgjQsZcwoFAw65HNu6oI7yq/EdrqN5BKR5QA5sPuy2Vf/bE3b/tutxCJpLNNuCsYKiFxSVK8V3iDhzJfe7sJpNlMlv+3gPuqPSmPhjje4y3JdO80RlnsH42AkZb8VlsIU+QGcmx5EP4LKrIPJFZo9stV+jGsTU0iXFEqRZroPDmDt7sHEDimfM4NroU8e54knAwK/HGOnde+5bzHFVhfYOjkWlKULDtUkTvpLz1ueshJf/PckDFb+5d6m4QKR9L3H8ql6WIkIBbaxZpehldxVZ1kfNSRCc6SJwHwtitLai/82S+aVc9dhxqeENFcrEKfqpOo//4VBJUItVH5QQGA81P/o1F0nNQivmwtKAgzxPJI+i2kPPz+97PnKglb2cYAC9MAC0LZYG7U5g+Si5XbwUcBEhuiyaBWEOgDhTW3UpZ/nqgqcLlnIgOhzeGt/BeCitO8HQ/JhNRqfeh0ZKfl3tDoFSpXy8Dvni+Pf3xgORGyqd8iDKjXExE6V+v4273W0tYW4ts/v+MHPMWd+sv6g41W6OD3fj3ds57MCjhns8iYWMTDYn4VFAss/s6/vssbBvmhc23zkrf7ToXh+GM+M/x8SnOb0LfKZo+MHlRWug5/M/HHAd+Hzep3vQnL1sgPUeIv7aEE63bkuZc0YhjzuhDeCfNLlP3NENOXfbbCfvZvXUBvGZqO9eb1VObxnYLNJKgBJUh088+p8lXRUgA5m4MZcbCpb91ZD924c1EFIB5FoJfdOPT5fcUGYk14Pm+yDu5Btl7JhLiH2obZjcIxzhvBGSPIx+J+o8G4sXWuT38QltXgScTxCzRb3M7bd4jt+CEeqgzt8NVLt0xzxtIXbcjk9tjYVZQDON/hMvJrxYEfDn4KrPwSswLrWqriuf5Wo/lYb5MoPkF/OkHEXyXdqPvEWldFV3IYolp93nxN3LfPpb/q5iI8s3m6U8v94qxCviE8qLjSJUVf8wSIUar2J6I52BgZE8RYSKIotKkTpqPSsawmxoO7Gd8wyTBeU8LWf1RUd3mqqUG1ySTPrm0KLxmkdNHD2jVeQY1shla2+NvG4HxDRuhKRieF5DMeOudZH0DaWki8AjFjATYQo3IV0dxlVsQ==
|
||||
2
xml2/Sample.xml
Normal file
2
xml2/Sample.xml
Normal file
File diff suppressed because one or more lines are too long
1
xml2/vf.xml
Normal file
1
xml2/vf.xml
Normal file
@ -0,0 +1 @@
|
||||
+cQcMhFlgMkbrF+i7iP25Q==7IbbJ+oG7KTi6Im1DLQqGsG/4bfBr32ec56wEKAZRfcvUCUe+BW1RUx+wB3KC9chpNkalv2i5yaTQWGnFxVB3i8jvnrJyDxdN2vhZCVOnAuyTMqLxrvRsCJ5rMJMsxVLZeRlYpi7d1l1LoCeWhgnfdLuSQnhcS5ZWz5m7YffTntmML7GTEm22PuOS5p7FsEpyK9xcWt7YQ8PEif0BYzxudB/QfN/ThOwxYfmIUGtDXNeZi4HidEwxDzwubHVC0rT0GnXqCyBwUdBJj5dTGrp/2Kh8vS/MxvTRGwrJcwvMEw/LQGCmFWs/nfBBB3jPIk1LF/7Zz1M5IoJnATvJWcfKYq8Tux77ImB76BwsKFJcTShdtpBAAtSyBtCIUxgioE57hWIkM7X2SUkb8otsYb9i7feCimJgHndIODS93MTIyDF81aEYUxo+19enH501gxOApS0tS7n+2UkLvCkcm3WYTfb4rLJNVn5sCk1jCEnWgQuAgd/rHzrYS08sEwwtuFy0PEpuV/dyF61PGaxyFC8FvF6wcYR7pTA4HpuaOCAF4kxgCRzZizmoQYp193ifMEEtYoFmRIpgMSRUGmLCQdC41/3foq3d0OjhZpvek5daKWEVj7kN+i5WJMT0ofUu7Ug2lciCdC4VvFuvg23sToJBbP3IKAedgwNL2oRvCJEaVeYitP3Iv/+jwu9Te1p2Ze6SV+luL5lAmmSCk4bZvXKX3ooiRqrwKH1rGBhO5wDS9sCFiBIf38ShY2jGtj5gRWzzlWwHPJWwqe77Bp8u2sdh1JCh/qMz3e2lsdEef3K1kQtbzjp14Yg3EoKTRUQ+vHCKNqiEMGlBP2WQiKbCBULhTcxhsS0kyGtCIiHT0q6IYt5CY1QBucqvdtpFqsY1dag7nkCyfaymVc50igpqCnNG7IFITbLb/SLYwCsvcfSnablPnZgHn8bti3RrBZnv01AUB/Bja7dGl8xFalNjW6qTSojLSK4bZtWdfbzRUhdNQ/u7ae67j953knAVm83QnCdTixEMQzmH+GtHQDDkIeRhPK2uZB2/qnjUtj+U99BldVEcTQ9WWb+215wwgbvrIe3CZC2pNI/naOtqmywhA6EdeLitju7pyxEvHkGdlEQ2ZenaAXM9ZI5JwLZuWkkkeu5Ik2oQyjU9B8UFj8s+xcr2wds68UOuU4UtMfaFgRjuU/3D9vfRLZkw+OmcFjYBuait51W1vWNNx3Mbv33LVG4DK3LMU21e631M/B1sQlLtccAXZpL6jalzaeChmbXqfMV
|
||||
@ -1,8 +1,8 @@
|
||||
|
||||
function xml2json(xmlData) {
|
||||
// console.clear();
|
||||
// console.log('xml to json converstion');
|
||||
// console.log(xmlData);
|
||||
console.log('xml to json converstion');
|
||||
console.log(xmlData);
|
||||
|
||||
function getAttributesOfXMLNode(node)
|
||||
{
|
||||
|
||||
@ -159,7 +159,6 @@ jsonObj['sections'] = [];
|
||||
|
||||
var jsonData = JSON.stringify(jsonObj);
|
||||
localStorage.setItem('pjsonData', jsonData );
|
||||
|
||||
QuestionPaperPreview(jsonObj);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user