through image name display image in custom tab in admin gridrender() must be compatible with...
Called into a meeting and told we are being made redundant (laid off) and "not to share outside". Can I tell my partner?
Which aircraft had such a luxurious-looking navigator's station?
Why can I easily sing or whistle a tune I've just heard, but not as easily reproduce it on an instrument?
Dilemma of explaining to interviewer that he is the reason for declining second interview
What can I substitute for soda pop in a sweet pork recipe?
Word to be used for "standing with your toes pointing out"
It took me a lot of time to make this, pls like. (YouTube Comments #1)
Wanted: 5.25 floppy to usb adapter
If all harmonics are generated by plucking, how does a guitar string produce a pure frequency sound?
Eww, those bytes are gross
How to add multiple differently colored borders around a node?
How to approximate rolls for potions of healing using only d6's?
Why didn't Eru and/or the Valar intervene when Sauron corrupted Númenor?
Can a hotel cancel a confirmed reservation?
What is better: yes / no radio, or simple checkbox?
Using AWS Fargate as web server
Why zero tolerance on nudity in space?
How to acknowledge an embarrassing job interview, now that I work directly with the interviewer?
Is divide-by-zero a security vulnerability?
Why does the DC-9-80 have this cusp in its fuselage?
On what did Lego base the appearance of the new Hogwarts minifigs?
How to push a box with physics engine by another object?
How Should I Define/Declare String Constants
Where was Karl Mordo in Infinity War?
through image name display image in custom tab in admin grid
render() must be compatible with MagentoBackendBlockWidgetGridColumnRendererRendererInterface::render(MagentoFrameworkDataObject $row)I created a custom module ,but getting error, not able to figure out what the error is about. How to get out of this error?How to show image in custom grid in magento 2 backend?Magento 2 Add new field to Magento_User admin formDI not working in ControllerI have created an extension to show Customer Company Name in Order grid. But when creating new order, order is not showing in order gridMagento offline custom Payment method with drop down listMagento 2 Create dynamic array From different Model Collection to use in multi select in gridMagento 2.3 Can't view module's front end page output?display uploaded image in custom tab in admin grid in magento2
hello everyone i want to display the uploaded image my code is below
info.php
$fieldset->addField(
'image',
'text',
[
'name' => 'image',
'label' => __('image'),
'renderer' => 'MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRendererLogoImage',
'required' => true,
]
);
logoimage.php
<?php
namespace
MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRenderer;
class LogoImage extends
MagentoBackendBlockWidgetGridColumnRendererAbstractRenderer {
protected $_storeManager;
protected $_fileSystem;
protected $_modelData;
public function __construct(
MagentoBackendBlockContext $context,
MagentoStoreModelStoreManagerInterface $storeManager,
MagentoFrameworkFilesystem $fileSystem,
MagnetoBookFreeLayoutModelAlllayoutFactory $modelData,
array $data = []) {
parent::__construct($context, $data);
$this->_storeManager = $storeManager;
$this->_fileSystem = $fileSystem;
$this->_modelData = $modelData;
$this->_authorization = $context->getAuthorization();
}
public function render(MagentoFrameworkDataObject $row) {
$id = $this->_getValue($row);
$filepath = $this->_fileSystem->getDirectoryRead(MagentoFrameworkAppFilesystemDirectoryList::MEDIA)->getAbsolutePath('images');
$data = $this->_modelData->load($id);
foreach($data as $file)
{
echo "<img src='".$filepath."pub/media/images".$file['image']."' height='30' width='30' />";
}
}
}
magento2 custom-admin-grid
add a comment |
hello everyone i want to display the uploaded image my code is below
info.php
$fieldset->addField(
'image',
'text',
[
'name' => 'image',
'label' => __('image'),
'renderer' => 'MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRendererLogoImage',
'required' => true,
]
);
logoimage.php
<?php
namespace
MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRenderer;
class LogoImage extends
MagentoBackendBlockWidgetGridColumnRendererAbstractRenderer {
protected $_storeManager;
protected $_fileSystem;
protected $_modelData;
public function __construct(
MagentoBackendBlockContext $context,
MagentoStoreModelStoreManagerInterface $storeManager,
MagentoFrameworkFilesystem $fileSystem,
MagnetoBookFreeLayoutModelAlllayoutFactory $modelData,
array $data = []) {
parent::__construct($context, $data);
$this->_storeManager = $storeManager;
$this->_fileSystem = $fileSystem;
$this->_modelData = $modelData;
$this->_authorization = $context->getAuthorization();
}
public function render(MagentoFrameworkDataObject $row) {
$id = $this->_getValue($row);
$filepath = $this->_fileSystem->getDirectoryRead(MagentoFrameworkAppFilesystemDirectoryList::MEDIA)->getAbsolutePath('images');
$data = $this->_modelData->load($id);
foreach($data as $file)
{
echo "<img src='".$filepath."pub/media/images".$file['image']."' height='30' width='30' />";
}
}
}
magento2 custom-admin-grid
add a comment |
hello everyone i want to display the uploaded image my code is below
info.php
$fieldset->addField(
'image',
'text',
[
'name' => 'image',
'label' => __('image'),
'renderer' => 'MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRendererLogoImage',
'required' => true,
]
);
logoimage.php
<?php
namespace
MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRenderer;
class LogoImage extends
MagentoBackendBlockWidgetGridColumnRendererAbstractRenderer {
protected $_storeManager;
protected $_fileSystem;
protected $_modelData;
public function __construct(
MagentoBackendBlockContext $context,
MagentoStoreModelStoreManagerInterface $storeManager,
MagentoFrameworkFilesystem $fileSystem,
MagnetoBookFreeLayoutModelAlllayoutFactory $modelData,
array $data = []) {
parent::__construct($context, $data);
$this->_storeManager = $storeManager;
$this->_fileSystem = $fileSystem;
$this->_modelData = $modelData;
$this->_authorization = $context->getAuthorization();
}
public function render(MagentoFrameworkDataObject $row) {
$id = $this->_getValue($row);
$filepath = $this->_fileSystem->getDirectoryRead(MagentoFrameworkAppFilesystemDirectoryList::MEDIA)->getAbsolutePath('images');
$data = $this->_modelData->load($id);
foreach($data as $file)
{
echo "<img src='".$filepath."pub/media/images".$file['image']."' height='30' width='30' />";
}
}
}
magento2 custom-admin-grid
hello everyone i want to display the uploaded image my code is below
info.php
$fieldset->addField(
'image',
'text',
[
'name' => 'image',
'label' => __('image'),
'renderer' => 'MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRendererLogoImage',
'required' => true,
]
);
logoimage.php
<?php
namespace
MagnetoBookFreeLayoutBlockAdminhtmlExtensionGridRenderer;
class LogoImage extends
MagentoBackendBlockWidgetGridColumnRendererAbstractRenderer {
protected $_storeManager;
protected $_fileSystem;
protected $_modelData;
public function __construct(
MagentoBackendBlockContext $context,
MagentoStoreModelStoreManagerInterface $storeManager,
MagentoFrameworkFilesystem $fileSystem,
MagnetoBookFreeLayoutModelAlllayoutFactory $modelData,
array $data = []) {
parent::__construct($context, $data);
$this->_storeManager = $storeManager;
$this->_fileSystem = $fileSystem;
$this->_modelData = $modelData;
$this->_authorization = $context->getAuthorization();
}
public function render(MagentoFrameworkDataObject $row) {
$id = $this->_getValue($row);
$filepath = $this->_fileSystem->getDirectoryRead(MagentoFrameworkAppFilesystemDirectoryList::MEDIA)->getAbsolutePath('images');
$data = $this->_modelData->load($id);
foreach($data as $file)
{
echo "<img src='".$filepath."pub/media/images".$file['image']."' height='30' width='30' />";
}
}
}
magento2 custom-admin-grid
magento2 custom-admin-grid
edited 30 mins ago
Ashish Ramchandani
asked 35 mins ago
Ashish RamchandaniAshish Ramchandani
17210
17210
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "479"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f264225%2fthrough-image-name-display-image-in-custom-tab-in-admin-grid%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Magento Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f264225%2fthrough-image-name-display-image-in-custom-tab-in-admin-grid%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown