fix claims publisher name display
This commit is contained in:
parent
5941c102b9
commit
f3454d78a2
3 changed files with 17 additions and 6 deletions
|
@ -163,7 +163,7 @@ CREATE TABLE `TransactionsAddresses`
|
||||||
`AddressId` BIGINT UNSIGNED NOT NULL,
|
`AddressId` BIGINT UNSIGNED NOT NULL,
|
||||||
`DebitAmount` DECIMAL(18,8) DEFAULT 0 NOT NULL COMMENT 'Sum of the inputs to this address for the tx',
|
`DebitAmount` DECIMAL(18,8) DEFAULT 0 NOT NULL COMMENT 'Sum of the inputs to this address for the tx',
|
||||||
`CreditAmount` DECIMAL(18,8) DEFAULT 0 NOT NULL COMMENT 'Sum of the outputs to this address for the tx',
|
`CreditAmount` DECIMAL(18,8) DEFAULT 0 NOT NULL COMMENT 'Sum of the outputs to this address for the tx',
|
||||||
`TransactionTime` DATETIME DEFAULT UTC_TIMESTAMP() NOT NULL,
|
`LatestTransactionTime` DATETIME DEFAULT UTC_TIMESTAMP() NOT NULL,
|
||||||
PRIMARY KEY `PK_TransactionAddress` (`TransactionId`, `AddressId`),
|
PRIMARY KEY `PK_TransactionAddress` (`TransactionId`, `AddressId`),
|
||||||
FOREIGN KEY `Idx_TransactionsAddressesTransaction` (`TransactionId`) REFERENCES `Transactions` (`Id`),
|
FOREIGN KEY `Idx_TransactionsAddressesTransaction` (`TransactionId`) REFERENCES `Transactions` (`Id`),
|
||||||
FOREIGN KEY `Idx_TransactionsAddressesAddress` (`AddressId`) REFERENCES `Addresses` (`Id`),
|
FOREIGN KEY `Idx_TransactionsAddressesAddress` (`AddressId`) REFERENCES `Addresses` (`Id`),
|
||||||
|
|
|
@ -41,10 +41,13 @@
|
||||||
$a = ['purple', 'orange', 'blue', 'teal', 'green', 'yellow'];
|
$a = ['purple', 'orange', 'blue', 'teal', 'green', 'yellow'];
|
||||||
$autoThumbText = '';
|
$autoThumbText = '';
|
||||||
$link = $claim->Name;
|
$link = $claim->Name;
|
||||||
|
$rawLink = $claim->Name;
|
||||||
if (isset($claim->Publisher->Name)) {
|
if (isset($claim->Publisher->Name)) {
|
||||||
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
||||||
|
$rawLink = $claim->Publisher->Name . '/' . $rawLink;
|
||||||
}
|
}
|
||||||
$link = 'lbry://' . $link;
|
$link = 'lbry://' . $link;
|
||||||
|
$rawLink = 'lbry://' . $rawLink;
|
||||||
if ($claim->ClaimType == 1) { $autoThumbText = strtoupper(substr($claim->Name, 1, min( strlen($claim->Name), 10 ))); } else {
|
if ($claim->ClaimType == 1) { $autoThumbText = strtoupper(substr($claim->Name, 1, min( strlen($claim->Name), 10 ))); } else {
|
||||||
$str = str_replace(' ', '', (strlen(trim($claim->Title)) > 0) ? $claim->Title : $claim->Name);
|
$str = str_replace(' ', '', (strlen(trim($claim->Title)) > 0) ? $claim->Title : $claim->Name);
|
||||||
$autoThumbText = strtoupper(mb_substr($str, 0, min( strlen($str), 10 )));
|
$autoThumbText = strtoupper(mb_substr($str, 0, min( strlen($str), 10 )));
|
||||||
|
@ -163,10 +166,13 @@ if (strlen(trim($desc)) == 0) {
|
||||||
|
|
||||||
$autoThumbText = '';
|
$autoThumbText = '';
|
||||||
$link = $claim->Name;
|
$link = $claim->Name;
|
||||||
|
$rawLink = $claim->Name;
|
||||||
if (isset($claim->Publisher->Name)) {
|
if (isset($claim->Publisher->Name)) {
|
||||||
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
||||||
|
$rawLink = $claim->Publisher->Name . '/' . $rawLink;
|
||||||
}
|
}
|
||||||
$link = 'lbry://' . $link;
|
$link = 'lbry://' . $link;
|
||||||
|
$rawLink = 'lbry://' . $rawLink;
|
||||||
$cost = '';
|
$cost = '';
|
||||||
if (isset($claim->Price) && $claim->Price > 0) {
|
if (isset($claim->Price) && $claim->Price > 0) {
|
||||||
$cost = $this->Amount->formatCurrency($claim->Price) . ' LBC';
|
$cost = $this->Amount->formatCurrency($claim->Price) . ' LBC';
|
||||||
|
@ -218,7 +224,7 @@ if (strlen(trim($desc)) == 0) {
|
||||||
|
|
||||||
<div class="metadata">
|
<div class="metadata">
|
||||||
<div class="title" title="<?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '') ?>"><?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '<em>No Title</em>') ?></div>
|
<div class="title" title="<?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '') ?>"><?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '<em>No Title</em>') ?></div>
|
||||||
<div class="link" title="<?php echo $link ?>"><a href="<?php echo $link ?>" rel="nofollow"><?php echo $link ?></a></div>
|
<div class="link" title="<?php echo $rawLink ?>"><a href="<?php echo $link ?>" rel="nofollow"><?php echo $rawLink ?></a></div>
|
||||||
|
|
||||||
<div class="desc"><?php echo strlen(trim($claim->Description)) > 0 ? $claim->Description : '<em>No description available</em>' ?></div>
|
<div class="desc"><?php echo strlen(trim($claim->Description)) > 0 ? $claim->Description : '<em>No description available</em>' ?></div>
|
||||||
|
|
||||||
|
@ -286,11 +292,13 @@ if (strlen(trim($desc)) == 0) {
|
||||||
}
|
}
|
||||||
$autoThumbText = '';
|
$autoThumbText = '';
|
||||||
$link = $claim->Name;
|
$link = $claim->Name;
|
||||||
|
$rawLink = $claim->Name;
|
||||||
if (isset($claim->Publisher->Name)) {
|
if (isset($claim->Publisher->Name)) {
|
||||||
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
||||||
|
$rawLink = $claim->Publisher->Name . '/' . $rawLink;
|
||||||
}
|
}
|
||||||
$link = 'lbry://' . $link;
|
$link = 'lbry://' . $link;
|
||||||
|
$rawLink = 'lbry://' . $rawLink;
|
||||||
$cost = '';
|
$cost = '';
|
||||||
if (isset($claim->Price) && $claim->Price > 0) {
|
if (isset($claim->Price) && $claim->Price > 0) {
|
||||||
$cost = $this->Amount->formatCurrency($claim->Price) . ' LBC';
|
$cost = $this->Amount->formatCurrency($claim->Price) . ' LBC';
|
||||||
|
@ -342,7 +350,7 @@ if (strlen(trim($desc)) == 0) {
|
||||||
|
|
||||||
<div class="metadata">
|
<div class="metadata">
|
||||||
<div class="title" title="<?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '') ?>"><?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '<em>No Title</em>') ?></div>
|
<div class="title" title="<?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '') ?>"><?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '<em>No Title</em>') ?></div>
|
||||||
<div class="link" title="<?php echo $link ?>"><a href="<?php echo $link ?>" rel="nofollow"><?php echo $link ?></a></div>
|
<div class="link" title="<?php echo $rawLink ?>"><a href="<?php echo $link ?>" rel="nofollow"><?php echo $rawLink ?></a></div>
|
||||||
|
|
||||||
<div class="desc"><?php echo strlen(trim($claim->Description)) > 0 ? $claim->Description : '<em>No description available</em>' ?></div>
|
<div class="desc"><?php echo strlen(trim($claim->Description)) > 0 ? $claim->Description : '<em>No description available</em>' ?></div>
|
||||||
|
|
||||||
|
|
|
@ -181,10 +181,13 @@
|
||||||
$idx++;
|
$idx++;
|
||||||
$autoThumbText = '';
|
$autoThumbText = '';
|
||||||
$link = $claim->Name;
|
$link = $claim->Name;
|
||||||
|
$rawLink = $claim->Name;
|
||||||
if (isset($claim->Publisher->Name)) {
|
if (isset($claim->Publisher->Name)) {
|
||||||
$link = $claim->Publisher->Name . '/' . $link;
|
$link = urlencode($claim->Publisher->Name) . '/' . $link;
|
||||||
|
$rawLink = $claim->Publisher->Name . '/' . $link;
|
||||||
}
|
}
|
||||||
$link = 'lbry://' . $link;
|
$link = 'lbry://' . $link;
|
||||||
|
$rawLink = 'lbry://' . $rawLink;
|
||||||
|
|
||||||
// content type
|
// content type
|
||||||
$ctTag = null;
|
$ctTag = null;
|
||||||
|
@ -225,7 +228,7 @@
|
||||||
|
|
||||||
<div class="metadata">
|
<div class="metadata">
|
||||||
<div class="title" title="<?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : ''); ?>"><?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '<em>No Title</em>') ?></div>
|
<div class="title" title="<?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : ''); ?>"><?php echo $claim->ClaimType == 1 ? $claim->Name : ((strlen(trim($claim->Title)) > 0) ? $claim->Title : '<em>No Title</em>') ?></div>
|
||||||
<div class="link"><a href="<?php echo $link ?>"><?php echo $link ?></a></div>
|
<div class="link" title="<?php echo $rawLink ?>"><a href="<?php echo $link ?>"><?php echo $rawLink ?></a></div>
|
||||||
|
|
||||||
<div class="clear"></div>
|
<div class="clear"></div>
|
||||||
<?php if ($claim->ClaimType == 2 && strlen(trim($claim->Description)) > 0): ?>
|
<?php if ($claim->ClaimType == 2 && strlen(trim($claim->Description)) > 0): ?>
|
||||||
|
|
Loading…
Reference in a new issue