Thu Aug 1 16:38:01 CST 2019 Source Update...
This commit is contained in:
parent
99967cb1d6
commit
ea0bd38cae
@ -1,4 +1,21 @@
|
||||
/*@import url('https://fonts.googleapis.com/css?family=Roboto:400,500,700&subset=cyrillic');*/
|
||||
/* latin */
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v19/KFOmCnqEu92Fr1Mu4mxKKTU1Kg.woff2) format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
/* cyrillic */
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: local('Roboto'), local('Roboto-Regular'), url(https://fonts.gstatic.com/s/roboto/v19/KFOmCnqEu92Fr1Mu5mxKKTU1Kvnz.woff2) format('woff2');
|
||||
unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
|
||||
}
|
||||
|
||||
|
||||
:root {
|
||||
--blue-grey: #445368;
|
||||
@ -1104,7 +1121,7 @@ textarea {
|
||||
z-index: 10;
|
||||
}
|
||||
.dapp-modal {
|
||||
top: calc(50% - 210px);
|
||||
top: calc(50% - 160px);
|
||||
left: 20px;
|
||||
right: 20px;
|
||||
transform: none;
|
||||
@ -1272,7 +1289,7 @@ textarea {
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
.modal__btns-wrap .btn {
|
||||
margin: 0 15px;
|
||||
margin: 0 5px;
|
||||
padding: 14px 10px;
|
||||
min-width: 125px;
|
||||
}
|
||||
@ -2774,10 +2791,22 @@ iframe
|
||||
|
||||
|
||||
|
||||
.btn--float
|
||||
.btn--setdapp
|
||||
{
|
||||
float: left;
|
||||
width: 220px;
|
||||
margin: 10px;
|
||||
}
|
||||
.dapp_desc
|
||||
{
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
@media (max-width: 600px)
|
||||
{
|
||||
.btn--setdapp
|
||||
{
|
||||
float: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -959,7 +959,7 @@ function RetOpenDapps(Item,bNum,AccountNum)
|
||||
if(Item.HTMLLength > 0)
|
||||
{
|
||||
var StrText = RetIconDapp(Item) + Name;
|
||||
return '<button type="button" class="bt_open_dapp" style="margin: -2px 0 0 0" onclick="OpenDapps(' + Item.Num + ',' + AccountNum + ')">' + StrText + '</button>';
|
||||
return '<button type="button" class="bt_open_dapp" style="margin: -2px 0 0 0" onclick="OpenDapps(' + Item.Num + ',' + AccountNum + ',1)">' + StrText + '</button>';
|
||||
}
|
||||
else
|
||||
return RetIconDapp(Item) + Name;
|
||||
|
@ -8,7 +8,7 @@
|
||||
* Telegram: https://t.me/terafoundation
|
||||
*/
|
||||
|
||||
var WEB_WALLET_VERSION = "0.04";
|
||||
var WEB_WALLET_VERSION = "0.05";
|
||||
var SaveIdArr = ["idAccount", "idTo", "idSumSend", "idDescription", "idCurTabName", "idViewBlockNum", "idViewAccountNum", "idViewDappNum",
|
||||
"idLang"];
|
||||
var CONFIG_DATA = {PRICE_DAO:{NewAccount:10}, MaxNumBlockDB:0, MaxAccID:0, MaxDappsID:0};
|
||||
@ -1265,27 +1265,27 @@ var LangMap = {};
|
||||
LangMap["ENG"] = {};
|
||||
LangMap["RUS"] = {"TERA WALLET":"TERA КОШЕЛЕК", "Generate key":"Сгенерировать ключ", "OK":"OK", "Cancel":"Отмена", "Edit":"Редактирование",
|
||||
"Save key":"Сохран.", "+ CREATE A NEW ACCOUNT":"+ СОЗДАТЬ НОВЫЙ СЧЕТ", "Create account":"Создать счет", "Send":"Отправить",
|
||||
"CONFIRM":"Подтверждение", "Accounts":"Счета", "Account(s)":"Счет(а,ов)", "Blocks and Tx":"Блоки и Транзакции", "Counters":"Показатели",
|
||||
"Open DApp":"Открыть Дапп", "Back":"Назад", "Delete":"Удалить", "Save to book":"Сохранить в книгу", "Choose":"Выбрать", "RECONNECT":"КОННЕКТ",
|
||||
"CONFIRM":"Подтвердить", "Accounts":"Счета", "Account(s)":"Счет(а,ов)", "Blocks and Tx":"Блоки и Транзакции", "Counters":"Показатели",
|
||||
"Open DApp":"Открыть", "Back":"Назад", "Delete":"Удалить", "Save to book":"Сохранить в книгу", "Choose":"Выбрать", "RECONNECT":"КОННЕКТ",
|
||||
"DApps":"DApps", "ID":"ИД", "Amount":"Величина", "Cur":"Вал", "Name":"Имя", "PubKey":"Пуб.ключ", "Operation":"Операция", "Smart":"Смарт",
|
||||
"Block Num":"Ном блока", "Num":"Ном", "Date":"Дата", "Data Hash":"Хеш данных", "PowHash":"Хеш сложности", "Block Hash":"Хеш блока",
|
||||
"Bytes":"Байт", "Pow":"Сложн", "Miner":"Майнер", "(secret)":"(секрет)", "Show":"Показать", "TERA":"TERA", "Blockchain height:":"Высота блокчейна:",
|
||||
"Current create:":"Текущий блок:", "Protocol ver:":"Версия протокола:", "ID: $Item.Num":"ИД: $Item.Num", "Token generate":"Генерация токенов",
|
||||
"ACCOUNTS":"СЧЕТА", "SEND":"ОТПРАВИТЬ", "DAPPS":"ДАППС", "EXPLORER":"ПРОСМ", "ATTENTION: Before using the wallet, save the private key.":"ВНИМАНИЕ: Перед использованием кошелька сохраните приватный ключ",
|
||||
"Web-site":"Веб-сайт", "Bitcointalk":"Bitcointalk", "Twitter":"Твиттер", "Telegram":"Телеграм", "Discord":"Дискорд", "QQchat":"QQchat",
|
||||
"Buy/sell/mine TERA":"Купить/Продать", "+ CREATE NEW":"+ СОЗДАТЬ", "Confirm Transaction":"Подтверждение транзакции", "CREATE DAPPS":"СОЗДАТЬ",
|
||||
"Set pass":"Установить пароль", "Unlock":"Разблокировать", "Entrance to sub-wallet":"Войти в под-кошелек", "Public name":"Публичное имя",
|
||||
"Currency":"Валюта", "Pay to:":"Получатель:", "Amount:":"Сумма:", "Description:":"Описание:", "Welcome to TERA Wallet":"Добро пожаловать в кошелек TERA",
|
||||
"Edit your wallet":"Редактирование вашего кошелька", "Key settings":"Задание ключей", "KEY SETTINGS":"КЛЮЧИ", "Create an account":"Создание счета",
|
||||
"Sending coins":"Отправка монет", "Decentralized applications (dApps)":"Децентрализованные приложения (DApps)", "Secure your wallet":"Безопасность вашего кошелька",
|
||||
"Wallet is secured":"Установлен пароль", "Total":"Всего", "Item.Name":"Item.Name", "You have no accounts yet":"У вас нет ни одного счета",
|
||||
"Wait 10-15 sec":"Ждите 10-15 сек", "Creating your account":"Идет создание вашего счета", "From:":"Отправитель:", "Set a password for protect entry":"Установите пароль для безопасности",
|
||||
"Enter password to unlock wallet":"Введите пароль для разблокировки кошелька", "From ID:":"Отправитель:", "Pay to ID:":"Получатель:",
|
||||
"Account":"Счет", "Owner":"Владелец", "Block num":"Ном блока", "Private key (secret)":"Приватный ключ (секретно)", "Load key":"Загруз.",
|
||||
"Create your first account and start using TERA":"Создайте свой первый счет и начните использовать TERA", "0 Accounts":"0 Счетов",
|
||||
"OWNER: {Item.Owner}":"Владелец: {Item.Owner}", "More info":"Информация", "Public key":"Публичный ключ", "Enter number of dapp":"Введите номер Даппа",
|
||||
"Enter the dapps number that will be added to your account. Attention make sure that you trust this dapp, otherwise you may lose all funds in this account.":"Введите номер Даппа, который будет добавлен в ваш аккаунт. Внимание убедитесь, что Вы доверяете ему, в противном случае вы можете потерять все средства на этом счете.",
|
||||
"Sending Tx":"Отправка транзакции", };
|
||||
"Buy/sell/mine TERA":"Купить/продать/майнить", "+ CREATE NEW":"+ СОЗДАТЬ", "Confirm Transaction":"Подтверждение транзакции",
|
||||
"CREATE DAPPS":"СОЗДАТЬ", "Set pass":"Установить пароль", "Unlock":"Разблокировать", "Entrance to sub-wallet":"Войти в под-кошелек",
|
||||
"Public name":"Публичное имя", "Currency":"Валюта", "Pay to:":"Получатель:", "Amount:":"Сумма:", "Description:":"Описание:",
|
||||
"Welcome to TERA Wallet":"Добро пожаловать в кошелек TERA", "Edit your wallet":"Редактирование вашего кошелька", "Key settings":"Задание ключей",
|
||||
"KEY SETTINGS":"КЛЮЧИ", "Create an account":"Создание счета", "Sending coins":"Отправка монет", "Decentralized applications (dApps)":"Децентрализованные приложения (DApps)",
|
||||
"Secure your wallet":"Безопасность вашего кошелька", "Wallet is secured":"Установлен пароль", "Total":"Всего", "Item.Name":"Item.Name",
|
||||
"You have no accounts yet":"У вас нет ни одного счета", "Wait 10-15 sec":"Ждите 10-15 сек", "Creating your account":"Идет создание вашего счета",
|
||||
"From:":"Отправитель:", "Set a password for protect entry":"Установите пароль для безопасности", "Enter password to unlock wallet":"Введите пароль для разблокировки кошелька",
|
||||
"From ID:":"Отправитель:", "Pay to ID:":"Получатель:", "Account":"Счет", "Owner":"Владелец", "Block num":"Ном блока", "Private key (secret)":"Приватный ключ (секретно)",
|
||||
"Load key":"Загруз.", "Create your first account and start using TERA":"Создайте свой первый счет и начните использовать TERA",
|
||||
"0 Accounts":"0 Счетов", "OWNER: {Item.Owner}":"Владелец: {Item.Owner}", "More info":"Инфо", "Public key":"Публичный ключ",
|
||||
"Enter number of dapp":"Введите номер Dapp", "Enter the dapps number that will be added to your account. Attention make sure that you trust this dapp, otherwise you may lose all funds in this account.":"Введите номер Dapp, который будет добавлен в ваш аккаунт. Внимание убедитесь, что Вы доверяете ему, в противном случае вы можете потерять все средства на этом счете.",
|
||||
"Sending Tx":"Отправка транзакции", "Wallet ver:":"Версия:", };
|
||||
LangMap["简体中文"] = {"TERA WALLET":"TERA 钱包", "Generate key":"生成私钥", "OK":"OK", "Cancel":"取消", "Edit":"编辑", "Save key":"保存私钥",
|
||||
"+ CREATE A NEW ACCOUNT":"+ 新建账号", "Create account":"创建账号", "Send":"发送", "SEND":"转账", "CONFIRM":"确认", "Accounts":"账号", "Account(s)":"账号",
|
||||
"Blocks and Tx":"区块和交易", "Counters":"状态统计", "Open DApp":"打开DApp", "Back":"返回", "Delete":"删除", "Save to book":"保存到地址本", "Choose":"选择",
|
||||
|
@ -510,11 +510,11 @@
|
||||
<div class="modal__title-wrap">
|
||||
<span class="light-grey-text">ID: $Item.Num</span>
|
||||
<h3>$Item.Name</h3>
|
||||
<ol class="modal__ol">
|
||||
<ul class="modal__ol">
|
||||
<li class="modal__category dappcategory1">$Item.Category1</li>
|
||||
<li class="modal__category dappcategory2">$Item.Category2</li>
|
||||
<li class="modal__category dappcategory3">$Item.Category3</li>
|
||||
</ol>
|
||||
</ul>
|
||||
<p class="dapp-modal__token-status dapp-modal__token-status--ok">
|
||||
<!--<span class="light-grey-text">Without token generate</span>-->
|
||||
<span class="dapp-modal__ok-token">Token generate</span>
|
||||
@ -524,7 +524,7 @@
|
||||
<img $item.iconpath alt="dApp logo" width="32">
|
||||
</div>
|
||||
</div>
|
||||
<p>$Item.Description</p>
|
||||
<p class="dapp_desc">$Item.Description</p>
|
||||
<dl class="modal__def-list def-list">
|
||||
<div class="def-list__item">
|
||||
<dt>Account</dt>
|
||||
@ -628,13 +628,14 @@
|
||||
</section>
|
||||
|
||||
|
||||
<section class="modal dapp-modal" id="idSmartEnter" style="display: none; margin-top: 20px; padding: 20px">
|
||||
<section class="modal dapp-modal" id="idSmartEnter" style="display: none; margin-top: -10px; padding: 20px">
|
||||
<h2 class="password-modal__title"><span>Enter number of dapp</span></h2>
|
||||
<p class="password-modal__subtitle">Enter the dapps number that will be added to your account. Attention make sure that you trust this dapp, otherwise you may lose all funds in this account.</p>
|
||||
|
||||
<input type="number" class="password-modal__input" placeholder="Dapp number" id="idSmartNum">
|
||||
<a class="btn btn--270 btn--float" onclick="DoSetSmartLocal()">OK</a>
|
||||
<a class="btn btn--270 btn--float btn--white" onclick="closeModal()">Cancel</a>
|
||||
<DIV align='center'>
|
||||
<input type="number" class="password-modal__input" placeholder="" id="idSmartNum">
|
||||
<a class="btn btn--270 btn--setdapp" onclick="DoSetSmartLocal()">OK</a>
|
||||
<a class="btn btn--270 btn--setdapp btn--white" onclick="closeModal()">Cancel</a>
|
||||
</DIV>
|
||||
</section>
|
||||
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
* Telegram: https://t.me/terafoundation
|
||||
*/
|
||||
|
||||
global.UPDATE_CODE_VERSION_NUM = 1167;
|
||||
global.UPDATE_CODE_VERSION_NUM = 1171;
|
||||
global.MIN_CODE_VERSION_NUM = 1114;
|
||||
global.MINING_VERSION_NUM = 0;
|
||||
global.InitParamsArg = InitParamsArg;
|
||||
@ -17,9 +17,9 @@ global.CONST_NAME_ARR = ["AUTO_CORRECT_TIME", "DELTA_CURRENT_TIME", "COMMON_KEY"
|
||||
"WALLET_NAME", "WALLET_DESCRIPTION", "USE_API_WALLET", "USE_API_V1", "USE_HARD_API_V2", "COUNT_VIEW_ROWS", "USE_HINT", "ALL_VIEW_ROWS",
|
||||
"ALL_LOG_TO_CLIENT", "LOG_LEVEL", "USE_MINING", "MINING_START_TIME", "MINING_PERIOD_TIME", "POW_MAX_PERCENT", "COUNT_MINING_CPU",
|
||||
"SIZE_MINING_MEMORY", "POW_RUN_COUNT", "USE_AUTO_UPDATE", "RESTART_PERIOD_SEC", "MAX_GRAY_CONNECTIONS_TO_SERVER", "TRANSACTION_PROOF_COUNT",
|
||||
"UPDATE_NUM_COMPLETE", "LIMIT_SEND_TRAFIC", "WATCHDOG_DEV", "ADDRLIST_MODE", "CheckPointDelta", "MIN_VER_STAT", "DEBUG_WALLET",
|
||||
"HTTP_HOSTING_PORT", "HTTPS_HOSTING_DOMAIN", "HTTP_MAX_COUNT_ROWS", "HTTP_ADMIN_PASSWORD", "HTTP_START_PAGE", "WATCHDOG_BADACCOUNT",
|
||||
"RESYNC_CONDITION", "MAX_CONNECTIONS_COUNT", "TRUST_PROCESS_COUNT", "REST_START_COUNT", "LOAD_TO_BEGIN", ];
|
||||
"LIMIT_SEND_TRAFIC", "WATCHDOG_DEV", "ADDRLIST_MODE", "CheckPointDelta", "MIN_VER_STAT", "DEBUG_WALLET", "HTTP_HOSTING_PORT",
|
||||
"HTTPS_HOSTING_DOMAIN", "HTTP_MAX_COUNT_ROWS", "HTTP_ADMIN_PASSWORD", "HTTP_START_PAGE", "WATCHDOG_BADACCOUNT", "RESYNC_CONDITION",
|
||||
"MAX_CONNECTIONS_COUNT", "TRUST_PROCESS_COUNT", "REST_START_COUNT", "LOAD_TO_BEGIN", ];
|
||||
global.MAX_LENGTH_SENDER_MAP = 3000;
|
||||
global.DELTA_START_SENDER_MAP = 24;
|
||||
global.NODES_DELTA_CALC_HOUR = 4;
|
||||
@ -35,7 +35,7 @@ global.WATCHDOG_BADACCOUNT = 1;
|
||||
global.WATCHDOG_DEV = 0;
|
||||
global.RESYNC_CONDITION = {"OWN_BLOCKS":20, "K_POW":5};
|
||||
global.REST_BLOCK_SCALE = 1000;
|
||||
global.REST_START_COUNT = 1000;
|
||||
global.REST_START_COUNT = 10000;
|
||||
global.LOAD_TO_BEGIN = 2;
|
||||
global.DEBUG_WALLET = 0;
|
||||
global.CHECK_GLOBAL_TIME = 1;
|
||||
@ -48,7 +48,6 @@ global.USE_NET_FOR_SERVER_ADDRES = 1;
|
||||
global.NET_WORK_MODE = undefined;
|
||||
global.STAT_MODE = 0;
|
||||
global.MAX_STAT_PERIOD = 1 * 3600;
|
||||
global.UPDATE_NUM_COMPLETE = 0;
|
||||
global.WALLET_NAME = "TERA";
|
||||
global.WALLET_DESCRIPTION = "";
|
||||
global.USE_MINING = 0;
|
||||
|
@ -29,13 +29,12 @@ ContenTypeMap["html"] = "text/html";
|
||||
ContenTypeMap["txt"] = "text/plain";
|
||||
ContenTypeMap["csv"] = "text/csv";
|
||||
ContenTypeMap["svg"] = "image/svg+xml";
|
||||
ContenTypeMap[""] = "application/octet-stream";
|
||||
ContenTypeMap["zip"] = "application/zip";
|
||||
ContenTypeMap["pdf"] = "application/pdf";
|
||||
ContenTypeMap["exe"] = "application/octet-stream";
|
||||
ContenTypeMap["msi"] = "application/octet-stream";
|
||||
ContenTypeMap["woff"] = "application/font-woff";
|
||||
ContenTypeMap["html"] = "text/html";
|
||||
var DefaultContentType = "application/octet-stream";
|
||||
ContenTypeMap["psd"] = "application/octet-stream";
|
||||
global.HTTPCaller = {};
|
||||
|
||||
@ -1453,8 +1452,8 @@ var MapFileHTML5 = {};
|
||||
function SendWebFile(response,name,StrCookie,bParsing)
|
||||
{
|
||||
var type = name.substr(name.length - 4, 4);
|
||||
if(type.substr(0, 1) === ".")
|
||||
type = type.substr(1);
|
||||
var index1 = type.indexOf(".");
|
||||
type = type.substr(index1 + 1);
|
||||
var Path;
|
||||
if(name.substr(0, 2) !== "./")
|
||||
Path = "./" + name;
|
||||
@ -1473,7 +1472,9 @@ function SendWebFile(response,name,StrCookie,bParsing)
|
||||
return ;
|
||||
}
|
||||
var StrContentType = ContenTypeMap[type];
|
||||
if(!StrContentType || StrContentType === "text/html")
|
||||
if(!StrContentType)
|
||||
StrContentType = DefaultContentType;
|
||||
if(StrContentType === "text/html")
|
||||
{
|
||||
var Headers = {'Content-Type':'text/html', "X-Frame-Options":"sameorigin"};
|
||||
if(StrCookie)
|
||||
@ -1700,7 +1701,7 @@ function SetSafeResponce(response)
|
||||
{
|
||||
try
|
||||
{
|
||||
if(arguments && arguments[0] && arguments[0].length)
|
||||
if(global.STAT_MODE === 2 && arguments && arguments[0] && arguments[0].length)
|
||||
{
|
||||
ADD_TO_STAT("HTTP_SEND", arguments[0].length);
|
||||
if(response.DetailStatName)
|
||||
|
@ -151,9 +151,11 @@ function MainHTTPFunction(request,response)
|
||||
var Params = querystring.parse(DataURL.query);
|
||||
var Path = querystring.unescape(DataURL.pathname);
|
||||
ToLogWeb("Get Path:" + Path);
|
||||
ADD_TO_STAT("HTTP_ALL");
|
||||
if(global.STAT_MODE === 2)
|
||||
{
|
||||
ADD_TO_STAT("HTTP_ALL");
|
||||
response.DetailStatName = ":" + Path;
|
||||
}
|
||||
var Type = request.method;
|
||||
if(Type === "POST")
|
||||
{
|
||||
@ -186,12 +188,12 @@ function MainHTTPFunction(request,response)
|
||||
Response.end("Error data parsing");
|
||||
}
|
||||
}
|
||||
DoCommandNew(response, Type, Path, Data);
|
||||
DoCommandNew(request, response, Type, Path, Data);
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
DoCommandNew(response, Type, Path, Params);
|
||||
DoCommandNew(request, response, Type, Path, Params);
|
||||
}
|
||||
};
|
||||
var bWasRun = 0;
|
||||
@ -284,20 +286,19 @@ WalletFileMap["glass.svg"] = 1;
|
||||
WalletFileMap["dapp-edit.html"] = 1;
|
||||
WalletFileMap["TeraLogo.svg"] = 1;
|
||||
WalletFileMap["mobile-wallet.html"] = "web-wallet.html";
|
||||
var MapRedirect = {};
|
||||
MapRedirect["map.html"] = "teraexplorer.org";
|
||||
MapRedirect["explorer.html"] = "teraexplorer.org";
|
||||
MapRedirect["history.html"] = "teraexplorer.org";
|
||||
MapRedirect["GetSupply"] = "teraexplorer.org";
|
||||
MapRedirect["DappTemplateFile"] = "terawallet.org";
|
||||
global.WebApi2 = {};
|
||||
global.HostingCaller = {};
|
||||
|
||||
function DoCommandNew(response,Type,Path,Params)
|
||||
function DoCommandNew(request,response,Type,Path,Params)
|
||||
{
|
||||
if(Path.substring(0, 1) === "/")
|
||||
Path = Path.substring(1);
|
||||
var ArrPath = Path.split('/', 5);
|
||||
if(global.AddonCommand)
|
||||
{
|
||||
if(!global.AddonCommand(request, response, Type, Path, Params, ArrPath))
|
||||
return ;
|
||||
}
|
||||
var Caller = HostingCaller;
|
||||
var Method = ArrPath[0];
|
||||
var APIv2 = 0;
|
||||
@ -316,9 +317,11 @@ function DoCommandNew(response,Type,Path,Params)
|
||||
}
|
||||
Method = ArrPath[2];
|
||||
}
|
||||
ADD_TO_STAT("HTTP:" + Method);
|
||||
if(global.STAT_MODE === 2)
|
||||
{
|
||||
ADD_TO_STAT("HTTP:" + Method);
|
||||
response.DetailStatName = ":" + Method;
|
||||
}
|
||||
var F = Caller[Method];
|
||||
if(F)
|
||||
{
|
||||
@ -359,17 +362,6 @@ function DoCommandNew(response,Type,Path,Params)
|
||||
Method = Method.toLowerCase();
|
||||
if(Method === "dapp" && ArrPath.length === 2)
|
||||
Method = "DappTemplateFile";
|
||||
if(HTTPS_HOSTING_DOMAIN === "terafoundation.org")
|
||||
{
|
||||
var DomenName = MapRedirect[Method];
|
||||
if(DomenName)
|
||||
{
|
||||
if(Path.substr(0, 1) !== "/")
|
||||
Path = "/" + Path;
|
||||
response.writeHead(301, {"Location":'http://' + DomenName + Path});
|
||||
return response.end();
|
||||
}
|
||||
}
|
||||
switch(Method)
|
||||
{
|
||||
case "index.html":
|
||||
@ -841,8 +833,6 @@ HostingCaller.GetHistoryTransactions = function (Params)
|
||||
};
|
||||
HostingCaller.GetSupply = function (Params)
|
||||
{
|
||||
if(HTTPS_HOSTING_DOMAIN === "terafoundation.org")
|
||||
return "" + (1000000000 - 420000000);
|
||||
var Data = DApps.Accounts.ReadState(0);
|
||||
if(!Data)
|
||||
return "";
|
||||
|
@ -293,7 +293,6 @@ class AccountApp extends require("./dapp")
|
||||
var MaxNum = this.DBAct.GetMaxNum();
|
||||
if(MaxNum >= TRANSACTION_PROOF_COUNT * 2)
|
||||
{
|
||||
ToLog("Rename act files")
|
||||
this.DBActPrev.CloseDBFile(this.DBActPrev.FileName)
|
||||
this.DBAct.CloseDBFile(this.DBAct.FileName)
|
||||
if(fs.existsSync(this.DBActPrev.FileNameFull))
|
||||
|
Loading…
Reference in New Issue
Block a user