/*
	Stempora Web Framework
	Copyright (c) 2002-2018 Stempora. 
	All rights reserved.
		web:  www.stempora.com
		mail: support@stempora.com				
*/

var STBModuleJobs = Object.create(STBModule.prototype);

STBModuleJobs.name = "ModuleJobs";
STBModuleJobs.initPlugin = function() {

	var el=$(".module-jobs:not(.__done) .job-contact > ul ");

	if (el.length) {
		el.each(function() {
			if (!$(this).find("li").length) {
				$(this).parent().remove();
			}

			$(this).closest(".module").addClass("__done");
		});	
	}
}

STBModuleJobs.runOnReady = function() {
	STBModuleJobs.initPlugin();
}

STBModuleJobs.runOnContentUpdate = function() {
	STBModuleJobs.initPlugin();
}

site.registerModule(STBModuleJobs);