', {
- class: ['col-xs-12', 'col-sm-6', 'col-md-4'].join(' ')
+ class: ['col-xs-12', 'col-sm-4'].join(' ')
}).append(
$('
', {
class: config.moduleHeadClass
diff --git a/public/js/v1.5.4/app/ui/module/system_info.js b/public/js/v1.5.4/app/ui/module/system_info.js
index 5136c3bb..737a40a3 100644
--- a/public/js/v1.5.4/app/ui/module/system_info.js
+++ b/public/js/v1.5.4/app/ui/module/system_info.js
@@ -27,7 +27,8 @@ define([
typeLinkClass: 'pf-system-info-type', // class for "type" name
urlLinkClass: 'pf-system-info-url', // class for "url" copy link
- // info table
+ // info col/table
+ systemInfoSectionClass: 'pf-system-info-section', // class for system info section
systemInfoTableClass: 'pf-module-table', // class for system info table
systemInfoNameClass: 'pf-system-info-name', // class for "name" information element
systemInfoEffectClass: 'pf-system-info-effect', // class for "effect" information element
@@ -37,9 +38,21 @@ define([
systemInfoWormholeClass: 'pf-system-info-wormhole-', // class prefix for static wormhole element
// description field
- descriptionAreaClass: 'pf-system-info-description-area', // class for "description" area
+ descriptionSectionClass: 'pf-system-description-section', // class for system description section
+ descriptionAreaClass: 'pf-system-info-description-area', // class for description area
addDescriptionButtonClass: 'pf-system-info-description-button', // class for "add description" button
- descriptionTextareaElementClass: 'pf-system-info-description', // class for "description" textarea element (Summernote)
+ descriptionTextareaElementClass: 'pf-system-info-description', // class for description textarea element (Summernote)
+
+ // sovereignty col/table
+ systemSovSectionClass: 'pf-system-sov-section', // class for system sov. section
+ systemSovTableClass: 'pf-module-table', // class for system sov. table
+ systemSovFwContestedRowClass: 'pf-system-sov-fw-contested-row', // class for "contested" sov. table row
+ systemSovFwOccupationRowClass: 'pf-system-sov-fw-occupation-row', // class for "-occupation" sov. table row
+ systemSovFwContestedClass: 'pf-system-sov-fw-contested',
+ systemSovFwPercentageClass: 'pf-system-sov-fw-percentage',
+ systemSovFwOccupationClass: 'pf-system-sov-fw-occupation',
+ systemSovFwOccupationImageClass: 'pf-system-sov-fw-occupation-image',
+ systemSovFwStatusIconClass: 'pf-system-sov-fw-status-icon',
// fonts
fontTriglivianClass: 'pf-triglivian', // class for "Triglivian" names (e.g. Abyssal systems)
@@ -115,12 +128,64 @@ define([
}
}
+ // update faction warfare rows ----------------------------------------------------------------------------
+ let fwContestedRow = moduleElement.find('.' + config.systemSovFwContestedRowClass);
+ let fwOccupationRow = moduleElement.find('.' + config.systemSovFwOccupationRowClass);
+ if(systemData.factionWar){
+ let contested = String(Util.getObjVal(systemData.factionWar, 'contested') || '');
+ let percentage = parseInt(Util.getObjVal(systemData.factionWar, 'victoryPercentage')) || 0;
+ let occupierFaction = Util.getObjVal(systemData.factionWar, 'occupierFaction');
+
+ let statusColor = 'red';
+ if(occupierFaction){
+ // system is "occupied" by hostile "occupierFaction" (stable)
+ // -> hide percent
+ statusColor = '#d9534f';
+ percentage += '%';
+ }else if('uncontested' === contested){
+ // system is "uncontested" and owned by default ownerFaction (stable)
+ // -> hide percent
+ statusColor = '#4f9e4f';
+ percentage = 'stable';
+ }else if('contested' === contested){
+ // system is "contested", 0%-99% percentage
+ statusColor = '#e28a0d';
+ percentage += '%';
+ }else if(
+ 'vulnerable' === contested ||
+ 'captured' === contested
+ ){
+ // system is "vulnerable", 100% percentage
+ // -> "captured" state is might be the same?!
+ statusColor = '#d747d6';
+ percentage = '100%';
+ }
+
+ fwContestedRow.find('.' + config.systemSovFwStatusIconClass)[0].style.setProperty('--color', statusColor);
+ fwContestedRow.find('.' + config.systemSovFwContestedClass).text(contested);
+ fwContestedRow.find('.' + config.systemSovFwPercentageClass).text(percentage);
+ fwContestedRow.show();
+
+ let occupierFactionImage = Util.eveImageUrl('alliance', (occupierFaction ? occupierFaction.id : 0), 64);
+ let occupierFactionName = occupierFaction ? occupierFaction.name : '';
+
+ fwOccupationRow.find('.' + config.systemSovFwOccupationImageClass)[0].style.setProperty('--bg-image', 'url(\'' + occupierFactionImage + '\')');
+ fwOccupationRow.find('.' + config.systemSovFwOccupationClass).text(occupierFactionName);
+ if(occupierFaction){
+ fwOccupationRow.show();
+ }
+ }else{
+ fwContestedRow.hide();
+ fwOccupationRow.hide();
+ }
+
if(setUpdated){
moduleElement.data('updated', systemData.updated.updated);
}
}
moduleElement.find('.' + config.descriptionAreaClass).hideLoadingAnimation();
+ moduleElement.find('.' + config.systemSovSectionClass + ' .' + Util.config.dynamicAreaClass).hideLoadingAnimation();
};
/**
@@ -135,6 +200,56 @@ define([
// store systemId -> module can be updated with the correct data
moduleElement.data('id', systemData.id);
+ // system "sovereignty" data
+ // "primary" data is eigther "alliance" -> 0.0 space
+ // or "faction" -> Empire Regions (LS, HS)
+ let sovereigntyDefault = {
+ row1Label: 'Sov.',
+ row1Val: '???',
+ row1Img: undefined,
+ row1ImgTitle: undefined,
+ row2Label: undefined,
+ row2Val: undefined,
+ row3Label: undefined,
+ row3Val: undefined
+ };
+
+ let sovereigntyPrimary;
+ let sovereigntySecondary;
+
+ if(systemData.sovereignty){
+ let sovDataFact = Util.getObjVal(systemData.sovereignty, 'faction');
+ let sovDataAlly = Util.getObjVal(systemData.sovereignty, 'alliance');
+ let sovDataCorp = Util.getObjVal(systemData.sovereignty, 'corporation');
+
+ if(sovDataFact){
+ sovereigntyPrimary = {
+ row1Val: 'Faction',
+ row1Img: Util.eveImageUrl('alliance', sovDataFact.id, 64),
+ row1ImgTitle: sovDataFact.name,
+ row2Val: sovDataFact.name
+ };
+ }else{
+ if(sovDataAlly){
+ sovereigntyPrimary = {
+ row1Val: 'Alliance',
+ row1Img: Util.eveImageUrl('alliance', sovDataAlly.id, 64),
+ row1ImgTitle: sovDataAlly.name,
+ row2Val: '<' + sovDataAlly.ticker + '>',
+ row3Label: 'Ally',
+ row3Val: sovDataAlly.name
+ };
+ }
+ if(sovDataCorp){
+ sovereigntySecondary = {
+ row1Label: 'Corp',
+ row1Val: sovDataCorp.name,
+ row1Img: Util.eveImageUrl('corporation', sovDataCorp.id, 64)
+ };
+ }
+ }
+ }
+
// system "static" wh data
let staticsData = [];
if(
@@ -152,9 +267,15 @@ define([
let data = {
system: systemData,
+ sovereigntyPrimary: sovereigntyPrimary ? Object.assign({}, sovereigntyDefault, sovereigntyPrimary) : undefined,
+ sovereigntySecondary: sovereigntySecondary ? Object.assign({}, sovereigntyDefault, sovereigntySecondary) : undefined,
static: staticsData,
moduleHeadlineIconClass: config.moduleHeadlineIconClass,
- tableClass: config.systemInfoTableClass,
+ infoSectionClass: config.systemInfoSectionClass,
+ descriptionSectionClass: config.descriptionSectionClass,
+ sovSectionClass: config.systemSovSectionClass,
+ infoTableClass: config.systemInfoTableClass,
+ sovTableClass: config.systemSovTableClass,
nameInfoClass: config.systemInfoNameClass,
effectInfoClass: config.systemInfoEffectClass,
planetsInfoClass: config.systemInfoPlanetsClass,
@@ -162,6 +283,15 @@ define([
statusInfoClass: config.systemInfoStatusLabelClass,
popoverTriggerClass: Util.config.popoverTriggerClass,
+ // sovereignty table
+ sovFwContestedRowClass: config.systemSovFwContestedRowClass,
+ sovFwOccupationRowClass: config.systemSovFwOccupationRowClass,
+ sovFwContestedInfoClass: config.systemSovFwContestedClass,
+ sovFwPercentageInfoClass: config.systemSovFwPercentageClass,
+ sovFwOccupationInfoClass: config.systemSovFwOccupationClass,
+ sovFwOccupationImageClass: config.systemSovFwOccupationImageClass,
+ sovFwStatusIconClass: config.systemSovFwStatusIconClass,
+
systemUrl: MapUtil.getMapDeeplinkUrl(mapId, systemData.id),
systemTypeName: MapUtil.getSystemTypeInfo(systemData.type.id, 'name'),
systemIsWormhole: MapUtil.getSystemTypeInfo(systemData.type.id, 'name') === 'w-space',
@@ -194,19 +324,22 @@ define([
systemConstellationLinkClass: config.constellationLinkClass,
systemRegionLinkClass: config.regionLinkClass,
systemTypeLinkClass: config.typeLinkClass,
- systemUrlLinkClass: config.urlLinkClass
+ systemUrlLinkClass: config.urlLinkClass,
+ ccpImageServerUrl: Init.url.ccpImageServer,
};
requirejs(['text!templates/modules/system_info.html', 'mustache', 'summernote.loader'], (template, Mustache, Summernote) => {
let content = Mustache.render(template, data);
moduleElement.append(content);
+ let sovSectionArea = moduleElement.find('.' + config.systemSovSectionClass + ' .' + Util.config.dynamicAreaClass);
let descriptionArea = moduleElement.find('.' + config.descriptionAreaClass);
let descriptionButton = moduleElement.find('.' + config.addDescriptionButtonClass);
let descriptionTextareaElement = moduleElement.find('.' + config.descriptionTextareaElementClass);
// lock "description" field until first update
descriptionArea.showLoadingAnimation();
+ sovSectionArea.showLoadingAnimation();
// WYSIWYG init on button click ---------------------------------------------------------------------------
descriptionButton.on('click', function(e){
diff --git a/public/js/v1.5.4/app/ui/module/system_intel.js b/public/js/v1.5.4/app/ui/module/system_intel.js
index 378c9d42..3407bc74 100644
--- a/public/js/v1.5.4/app/ui/module/system_intel.js
+++ b/public/js/v1.5.4/app/ui/module/system_intel.js
@@ -452,7 +452,7 @@ define([
_: function(data, type, row, meta){
let value = data;
if(type === 'display' && value){
- value = '

';
+ value = '
 +')
';
}
return value;
}
@@ -486,7 +486,7 @@ define([
let value = data;
if(type === 'display' && value){
value = '
';
- value += '
';
+ value += '
';
value += '';
}
return value;
@@ -625,7 +625,7 @@ define([
'
' +
' | ' +
'' +
- ' ' +
+ ' ' +
' | ' +
'' + group.name + ' | ' +
'
'
diff --git a/public/js/v1.5.4/app/util.js b/public/js/v1.5.4/app/util.js
index 1c9a55c0..54458cf3 100644
--- a/public/js/v1.5.4/app/util.js
+++ b/public/js/v1.5.4/app/util.js
@@ -552,7 +552,7 @@ define([
userData: userData,
otherCharacters: () => {
return userData.characters.filter((character, i) => {
- let characterImage = Init.url.ccpImageServer + '/Character/' + character.id + '_32.jpg';
+ let characterImage = eveImageUrl('character', character.id);
// preload image (prevent UI flicker
let img= new Image();
img.src = characterImage;
@@ -852,6 +852,23 @@ define([
*/
let showVersionInfo = () => Con.showVersionInfo(getVersion());
+ /**
+ * get CCP image URLs for
+ * @param type 'alliance'|'corporation'|'character'|'type'|'render'
+ * @param id
+ * @param size
+ * @returns {boolean}
+ */
+ let eveImageUrl = (type, id, size = 32) => {
+ let url = false;
+ if(typeof type === 'string' && typeof id === 'number' && typeof size === 'number'){
+ type = type.capitalize();
+ let format = type === 'Character' ? 'jpg' : 'png';
+ url = Init.url.ccpImageServer + '/' + type + '/' + id + '_' + size + '.' + format;
+ }
+ return url;
+ };
+
/**
* polyfill for "passive" events
* -> see https://github.com/zzarcon/default-passive-events
@@ -2303,26 +2320,28 @@ define([
* get a HTML table with universe region information
* e.g. for popover
* @param regionName
- * @param faction
+ * @param sovereignty
* @returns {string}
*/
- let getSystemRegionTable = (regionName, faction) => {
+ let getSystemRegionTable = (regionName, sovereignty) => {
+ let data = [{label: 'Region', value: regionName}];
+ if(sovereignty){
+ if(sovereignty.faction){
+ data.push({label: 'Sov. Faction', value: sovereignty.faction.name});
+ }
+ if(sovereignty.alliance){
+ data.push({label: 'Sov. Ally', value: sovereignty.alliance.name});
+ }
+ }
+
let table = '
';
- table += '';
- table += '| ';
- table += 'Region';
- table += ' | ';
- table += '';
- table += regionName;
- table += ' | ';
- table += '
';
- table += '';
- if(faction){
+ for(let rowData of data){
+ table += '
';
table += '| ';
- table += 'Faction';
+ table += rowData.label;
table += ' | ';
table += '';
- table += faction.name;
+ table += rowData.value;
table += ' | ';
table += '
';
}
@@ -3425,6 +3444,7 @@ define([
config: config,
getVersion: getVersion,
showVersionInfo: showVersionInfo,
+ eveImageUrl: eveImageUrl,
initPrototypes: initPrototypes,
initDefaultBootboxConfig: initDefaultBootboxConfig,
initDefaultConfirmationConfig: initDefaultConfirmationConfig,
diff --git a/public/templates/dialog/api_status.html b/public/templates/dialog/api_status.html
index d720cfcc..f79c2121 100644
--- a/public/templates/dialog/api_status.html
+++ b/public/templates/dialog/api_status.html
@@ -1,7 +1,10 @@
Shows status information for external used APIs. Provides a general health indicator per route and method.
-{{ apiData.name }}
-
+
+
+
+ {{ apiData.name }}
+ {{ apiData.cache }}
@@ -42,7 +45,7 @@
{{#apiData.routes}}
- |
+ |
|
diff --git a/public/templates/dialog/jump_info.html b/public/templates/dialog/jump_info.html
index 40ff5f3d..baac3836 100644
--- a/public/templates/dialog/jump_info.html
+++ b/public/templates/dialog/jump_info.html
@@ -44,8 +44,8 @@
| {{#massValue}}{{massIndividual}}{{/massValue}} |
{{#massValue}}{{massRegeneration}}{{/massValue}} |
{{#formatTime}}{{maxStableTime}}{{/formatTime}} |
-
- {{#sigStrengthValue}}{{signatureStrength}}{{/sigStrengthValue}}
+ |
+ {{#sigStrengthValue}}{{scanWormholeStrength}}{{/sigStrengthValue}}
|
{{/wormholes}}
diff --git a/public/templates/layout/header_map.html b/public/templates/layout/header_map.html
index fe5466fa..47a18d2a 100644
--- a/public/templates/layout/header_map.html
+++ b/public/templates/layout/header_map.html
@@ -1,13 +1,9 @@
-
-{{! Render the *.svg logo. So it can be used through the "use" tag}}
-{{{logo}}}
-