Browse Source

Merge pull request #143 from Samourai-Wallet/feat_dojo_versionning

improve display of dojo version
use-env-var-docker
kenshin samourai 5 years ago
committed by GitHub
parent
commit
2854bea889
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      docker/my-dojo/node/keys.index.js
  2. 1
      keys/index-example.js
  3. 2
      static/admin/tool/index.html
  4. 12
      static/admin/tool/index.js

2
docker/my-dojo/node/keys.index.js

@ -18,7 +18,7 @@ module.exports = {
/*
* Dojo version
*/
dojoVersion: process.env.DOJO_VERSION_TAG,
dojoVersion: process.env.DOJO_NODEJS_VERSION_TAG,
/*
* Bitcoind
*/

1
keys/index-example.js

@ -216,6 +216,7 @@ module.exports = {
* Testnet parameters
*/
testnet: {
dojoVersion: '1.5.0',
bitcoind: {
rpc: {
user: 'user',

2
static/admin/tool/index.html

@ -22,7 +22,7 @@
<!-- HEADER -->
<div id="header" class="row">
<div class="col-xs-9">
<h1 class="title"><span>DOJO // MAINTENANCE TOOL</span> <span class="beta">beta</span></h1>
<h1 class="title"><span>DOJO // MAINTENANCE TOOL</span> <span id="dojo-version" class="beta">beta</span></h1>
</div>
<div class="col-xs-3 login-box">
<a id="btn-logout" style="display: inline;" href="#" title="DISCONNECT">

12
static/admin/tool/index.js

@ -84,6 +84,18 @@ function initTabs() {
function preparePage() {
const activeTab = sessionStorage.getItem('activeTab');
// Dojo version
let lblVersion = sessionStorage.getItem('lblVersion');
if (lblVersion == null) {
lib_api.getPairingInfo().then(apiInfo => {
lblVersion = 'v' + apiInfo['pairing']['version'] + ' beta';
sessionStorage.setItem('lblVersion', lblVersion);
$('#dojo-version').text(lblVersion);
});
} else {
$('#dojo-version').text(lblVersion);
}
// Pairing
if (activeTab == '#link-pairing') {
$('#screen-pairing').show();

Loading…
Cancel
Save