I am doing a project in Modx. I created a image slider using Migx. The client wants a image crop tool so I installed Image+. In the Form Tabs: section of the migx variable, I gave
[
{"caption":"Image", "fields":[
{"field":"image","caption":"Image","inputTVtype":"imageplus"}
]}
]
and for Grid Columns: I have given
[
{"header": "Image", "width": "50", "sortable": "false", "dataIndex": "image","renderer": "this.renderImagelus"}
]
In the grid column the selected images are not appearing (rest is working). I guess "renderer": "this.renderImagelus" is wrong, but I don't know what its value should be.
Can someone figure out a solution for this.
The current Image+ version from the MODX Repository could work with MIGX.
Use this in the Form Tabs section "inputTVtype":"imageplus" and this in Grid Columns section "renderer": "ImagePlus.MIGX_Renderer
If you want to use an own media source for the Image+ TV you have to add something like this in Form Tabs section just after the inputTVtype line
"sourceFrom": "migx",
"sources": [{
"context": "web",
"sourceid": "2"
}]
Related
Going through the issues page of bot framework composer, I stumbled on this issue which shows an interesting UI card for getting the user's satisfactory :
Does this looks like an adaptive card ? How can we reproduce that ?
the easiest thing to do is go to the designer on Adaptivecards.io. They have a super simple Adaptive Cards Designer experience that is drag and drop.
on other tabs they have example templates which you can launch in the designer to see how they work and play with them.
In your example above, the card is simply a text field with two image links and the images are clickable.
You can use the containers and/or columns components in the designer to layout the items.
You can use a hero card to get user satisfaction response by using thumbs up/thumbs down emoji.
[Herocard
text = Are you satisfied?
buttons = 👍 | 👎
]
Following JSON is a sample for thumbs up and down input choice
{
"type": "TextBlock",
"text": "Do you like the product"
},
{
"type": "Input.ChoiceSet",
"style": "expanded",
"isMultiSelect": false,
"choices": [
{
"title": "👍",
"value": "yes"
},
{
"title": "👎",
"value": "no"
}
],
"placeholder": "Placeholder text",
"spacing": "None"
},
i try to make an bot with similar layout
we can see it on microsoft teams doc HERE
I use this search example and get an result, but i dont know to make this "tabs" (Recents, Reports, inside image), anyone know or have example to how i make it?
i have only search input and result list, but i need tabs.
Thanks for all
These are actually called messaging extension search commands. Please try providing multiple commands by providing id's, title and other fields to render them as tabs.This documentation serves as best reference guide.
As tabs are only supported by search commands of message extension. To add tabs in your message extension, you would have to define the search commands in the manifest.json file of your respective project with id, title, and other required details.
"commands": [
{
"id": "searchQuery",
"context": [ "compose", "commandBox" ],
"description": "Test command to run query",
"title": "Search",
"type": "query",
"parameters": [
{
"name": "searchQuery",
"title": "Search Query",
"description": "Your search query",
"inputType": "text"
}
]
}
]
slack button getting cut
bot.reply(message, {
attachments:[
{
title: 'Do you want to interact with my buttons?',
callback_id: '123',
attachment_type: 'default',
actions: [
{
"name":"yes",
"text": "Yes",
"value": "yes",
"type": "button",
},
{
"name":"no",
"text": "No",
"value": "no",
"type": "button",
}
]
}
]
});
If text length is more, Button gets wrapped up with fewer text and rest ends up as ... I got stuck here. Please help to show full text in button.
This is a feature of Slack, not of BotFramework nor of Botkit. The Slack interface simply doesn't allow long button titles. I don't know what the character length limit is, but you appear to be hitting it and it is truncating the text and replacing it with an ellipses.
I would recommend you reach out to Slack via their developer support page, located here, to identify any possible workarounds or solutions.
I am creating a Post.message to Slack through Python and want to add in a button feature. I want the button to provide a list of serial numbers that are represented by low2 = low["serials"]. This is the code I currently have and it adds the button to the slack message but when I click the button I get an error saying "Oh no, something went wrong. Please try that again." from slackbot. I saw posts saying that most people have to create a bot to fix their problems with buttons but if the button just has to read this variable I assume there is a way around that. Thanks for the help!
"fields": [
{
"title": "Amount Used:",
"value": low1,
"short": 'true'
},{
"title": "Distinct Device ID's:",
"value": out1,
"short": 'true'
},
{
"title": "Total Connection Time (hr):",
"value": data2,
"short": 'true'
}
],
"actions": [
{
"name": "game",
"text": "Serials",
"type": "button",
"value": "serials",
}
],
No, there is no way around it. You must create a Slack App (or "Internal Integration") in order to use buttons in your app. One reason is that you need to tell Slack what URL to call if someone clicks a button (your "Action URL") and that can only by configured as part of a Slack app. Check out this documentation on interactive messages for details.
Regarding your approach. A button will only display one value to the user. If your aim is to let the use choose from a list of serial numbers, you have two options in my opinion:
a) Create a group of buttons, one for each serial number
b) Use an interactive menu to create a drop-down menu for your list
I solved my problem by converting the confirm action button to display the values I wanted.
with open('Count_BB_Serial_weekly.json', 'r') as lowfile:
low = json.load(lowfile)
low1 = low["total_serials"]
low2 = low["serials"]
low3 = '\r\n'.join(low2)
Above is my script that imports the array and reads the values. Below I put the results into the "confirm" pop up button.
],
"actions": [
{
"name": "game",
"text": "Serials",
"type": "button",
"value": "serials",
"confirm": {
"title": "Serial Numbers",
"text": low3,
"ok_text": "Yes",
"dismiss_text": "No"
}
}],
I am trying to create a bot and deploy it onto different platforms, but when I return images in the carousel for the chatbot, Skype doesn't render them, while the same works for Facebook and even on the web widget provided by Gupshup.
If you want to know the chatbot platform i'm using it would be Gupshup with api.ai hooked for nlp , do you know the problem i am encountering?
I have tried different ways of getting the image. First I got it from the site I am making the chatbot for, then I tried shortening the url using google and finally I tried uploading the image on Google drive.The image format is jpg could that be the issue?
http://imgur.com/a/19aG3
[Update:7/5/2017] - Skype issue is now resolved. The carousel code that is working for Facebook Messenger will also work for Skype.
Sample JSON for Carousel on Skype:
{
"type": "catalogue",
"msgid": "cat_212",
"items": [{
"title": "White T Shirt",
"subtitle": "Soft cotton t-shirt \nXs, S, M, L \n$10",
"imgurl": "https://pixel.nymag.com/imgs/fashion/daily/2016/06/02/t-shirt/everlane.w710.h473.2x.jpg",
"options": [{
"type": "url",
"title": "View Details",
"url": "https://pixel.nymag.com/imgs/fashion/daily/2016/06/02/t-shirt/everlane.w710.h473.2x.jpg"
},
{
"type": "text",
"title": "Buy"
}
]
},
{
"title": "Grey T Shirt",
"subtitle": "Soft cotton t-shirt \nXs, S, M, L \n$12",
"imgurl": "https://cdn.shopify.com/s/files/1/0407/0829/products/Grey_t-shirt_front_1024x1024.jpg?v=1466588290",
"options": [{
"type": "url",
"title": "View Details",
"url": "https://cdn.shopify.com/s/files/1/0407/0829/products/Grey_t-shirt_front_1024x1024.jpg?v=1466588290"
},
{
"type": "text",
"title": "Buy"
}
]
}
]}
Result:
Images are not loading for the carousel on Skype because there have
been recent changes in Microsoft framework which are not yet
incorporated in Gupshup's bot platform. Although next week you should
be able to see those images load once we at Gupshup pushes the fix
into production. There will be no need of changing the code from your
end as the same code for carousel works across the supported
platforms.
I will update this answer once the fix is live into production.
PS: I work for Gupshup.