You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

23 lines
980 B

function sevominJobViewer(settings) {
var jobs = $$jobs;
if (settings.container == undefined || settings.container == '')
throw 'You did not specify any container';
var container = document.querySelector(settings.container);
if (container == undefined)
throw 'You did not specify any container';
this.show = function () {
var content = '<ul class="sevomin-jobs">';
if (settings.linkText == undefined || settings.linkText == '')
settings.linkText = 'مشاهده در سومین';
for (var i = 0; i < jobs.length; i++) {
content += '<li class="sevomin-job"><p class="sevomin-job-summary">';
content += jobs[i].JobSummary + '<a href="http://www.sevom.in/jobs/'
+ jobs[i].Id + '">' + settings.linkText + '</a></p>';
content += '</li>';
}
content = content + '</ul>'
container.innerHTML = content;
}
}