I have created a custom Dropdown widget and in render I get the value as below – if undefined then setting the caption to whatever user sets it in widget General tab:
const selectedCaption = this.props.enumAttribute.value === undefined ? this.props.stringCaption : this.props.enumAttribute.value;
then pass this to my component :
<Dropdown
list={keyVals}
caption={selectedCaption}
onUpdate={this.onUpdateHandle}
disabled={this.isReadOnly()}
/> In my component I set it in as below and then set my html as well:
constructor(props: any) {
super(props)
this.state = {
isDisplayed: false,
titleCaption: this.props.caption,
}
}
render(): ReactNode {
const { titleCaption } = this.state
<div className="ui-dropdown__placeholder">{titleCaption}</div>
...
} But I get undefined for this.props.enumAttribute.value in “selectedCaption” const. I debugged it in chrome and can see the render method running twice, first time it is undefined and second time I get the value I selected, but component’s render only runs once and sets the value to this.props.stringCaption.
↧
Custom Widget Value
↧
Errors during portal build but errors not shown in modeller
In version 7.23.3. I have a third case (3) where the modeller indicates local there are now error but the deploment in free node fails. So the two environments do not agree what is a clean build with no errors. This happens both with free apps and full node. In the full node i upload the project, thats fine. Starting build for Mendix Project file: /srv/cloud/slots/tr10000/deploy/data/tmp/b510a646-a087-4d66-969f-13f71b622356/src/RCA_app.mpr Using the following options: * Build target: Package * Deployment package file: /srv/cloud/slots/tr10000/deploy/data/tmp/buildjob62452169469382549.mda * Model version: 1.0.0.768 * Model description: Automatically generated deployment package for Free App deployment. * Project name: RCA_app Reading project file... Building project... Executing step 'Synchronize with file system' * Synchronizing with file system... Executing step 'Initialize' * Preparing deployment... Executing step 'Check prerequisites' * Checking for errors... ERROR: The project cannot be deployed, because it contains errors. ERROR at RCA_main, Page 'Rubric_Select', -: At least one allowed role must be selected if the page is used from navigation or a button. BUILD FAILED
↧
↧
Page break disconnects table contents
Hey guys, I am using a document template in which there is a template grid. Within that there is a table that consist of a text container and another template grid. A page break will disconnect my table contents, so that the text container is on page 1 and the other template grid on page 2. How can i prevent that ? Thanks in advance.
↧
Remove the space on top of the multi select dropdown list
Hi All, I am using Bootstrap multi select widget for drop down list. I want to remove the space on top of the multi select drop-down list. I have set the padding and margin to 0. It looks like below image. Can you tell what is the issue?
↧
changing default homepage does not work in native app
When a default homepage was previously set to “page A” and you change that to “page B” then reloading the app in the make it native app does not show the new default homepage. No matter which combination of starting, stopping, cleaning deployment directory, rescanning QR-codes etc. one tries, it always keeps pointing to the original default homepage. Any idea what might have caused this? P.S.: No role based home pages have been set, that could be overwriting the default homepage with the exception of a login page for anonymous users.
↧
↧
Any first experiences with the Video Widget?
The Video Widget has been introduced since release 8.1. Anyone already having some experience with this widget?
↧
Build error
After upgrading tot 7.02 and updating all APP modules to last version I get this error.... I dont know yet where to start to fix it clues? Buildfile: C:\Users\arthur\Documents\Mendix\KWALE-main_6\deployment\build_core.xml compile: [javac] Compiling 294 source files to C:\Users\arthur\Documents\Mendix\KWALE-main_6\deployment\run\bin [javac] C:\Users\arthur\Documents\Mendix\KWALE-main_6\javasource\communitycommons\Misc.java:656: error: unreported exception COSVisitorException; must be caught or declared to be thrown [javac] overlay.overlay(new HashMap<Integer, String>()).save(baos); [javac] ^ [javac] Note: Some input files use or override a deprecated API. [javac] Note: Recompile with -Xlint:deprecation for details. [javac] 1 error
↧
Replace image from input with Compressed one by Javascript?
I want to client-side compress an uploaded image, before sending it to the server, in order to save bandwidth and maximize upload speeds. With the help of this JS compression library I’m already able to compress the image, but I’m not able to return the image back, so Mendix will pick it up. Inside the console (of the browser, Chrome, I can see the reduced size being logged, but if I click next, to commit the object, I can clearly see the original file being transferred. Does anyone has experience in this area and can help me out?
↧
Build and Deploy API Calls with Postman
Good day! I am using Postman and learning to access the Build and Deploy APIs using the docs: https://docs.mendix.com/apidocs-mxsdk/apidocs/build-api https://docs.mendix.com/apidocs-mxsdk/apidocs/deploy-api But I seem to have an authorization issue. Below is a snapshot of my request. I generated the Mendix-ApiKey within my Developer Portal as suggested in another post. What am I missing? Thanks, Keith
↧
↧
Scroll bar in Drop down search field
I am using a datagrid with xpath source and using search toggle bar where I am using drop down search field to select the associated data. I notified the drop down don’t have a scroll bar inside due to which for a long list of items i need to scroll down whole page which inconvenient。 Is there some thing need to change with dropdown options?
↧
Inline - Edit/Delete location (Data Grid)
Good Morning all, I’ve a page where we add complaints, every time we add complaint, it will get added to the page with a new row. I want my ‘Edit and Delete’ buttons to be appeared Inline (on each row at end of the complaint), my page is built on a ‘DataGrid’. Please share your thoughts, if anyone has worked on something similar. Thanks, Venu
↧
Set X-Frame-Options http header when running mendix app locally
I want to add below http header to my mendix app Header always append X-Frame-Options SAMEORIGIN Can someone help me how to add above when running app locally on desktop modeler?
↧
Mendix Cannot Run Locally
When I search my question on this mendix forum , I found that this question has already asked 3 years ago. But time has changed Mendix Studio versions are also changed.So my question is that I have first installed mendix in my laptop window 10 (Mendix Studio Pro 8.0.0).I simply download the blank app template and run locally then this error occur . and this is my error details ,
Mendix.Modeler.M2EEConnector.M2EEException: The server encountered an error. at Mendix.Modeler.M2EEConnector.M2EEResponse.CheckSuccess() in C:\jenkins-ci\workspace\AppStudio3.0-Build@3\modeler\Mendix.Modeler.M2EEConnector\M2EEResponse.cs:line 57 at Mendix.Modeler.M2EEConnector.M2EEClient.CreateTcpJsonLogSubscriber(String name, LogLevel autoSubscribeLevel, String host, Int32 port) in C:\jenkins-ci\workspace\AppStudio3.0-Build@3\modeler\Mendix.Modeler.M2EEConnector\M2EEClient.cs:line 68 at Mendix.Modeler.M2EEConnector.TcpJsonLogSubscriber.SubscribeAndListen(LogLevel autoSubscribeLevel) in C:\jenkins-ci\workspace\AppStudio3.0-Build@3\modeler\Mendix.Modeler.M2EEConnector\TcpJsonLogSubscriber.cs:line 41 at Mendix.Modeler.M2EEConnector.RuntimeController.SubscribeToLogging(IM2EEClient zeeClient, LogLevel autoSubscribeLogLevel) in C:\jenkins-ci\workspace\AppStudio3.0-Build@3\modeler\Mendix.Modeler.M2EEConnector\RuntimeController.cs:line 166 at Mendix.Modeler.M2EEConnector.RuntimeController.Start(StartupInfo info, LogLevel autoSubscribeLogLevel) in C:\jenkins-ci\workspace\AppStudio3.0-Build@3\modeler\Mendix.Modeler.M2EEConnector\RuntimeController.cs:line 133 at Mendix.Modeler.Utility.BackgroundUtil.<>c__DisplayClass1_0`1.<Do>b__0(Object s, DoWorkEventArgs e) in C:\jenkins-ci\workspace\AppStudio3.0-Build@3\modeler\Mendix.Modeler.Utility\BackgroundUtil.cs:line 28 at System.ComponentModel.BackgroundWorker.OnDoWork(DoWorkEventArgs e) at System.ComponentModel.BackgroundWorker.WorkerThreadStart(Object argument)
↧
↧
Display wide grids with horizontal scrolling
I have a need to display a wide data grid and filter the records. Attempt #1: Overflow The first attempt I made was to use fixed width columns adding overflow-x:auto; style to the grid. I now have a horizontal bar at the bottom of the grid and my search criteria fit the width of the page. The problem is that in order to see the right most part of the grid, I need to page down to see the horizontal scroll bar, scroll, and then page up to see the data. Users are very unhappy. Attempt #2: Container Width My second attempt was to add style width: 1800px; to the container which holds the grid. Now the horizontal scroll bar appears at the bottom of the browser (excellent!!!) but my search criteria Search button is way to the right and not visible on the screen. Question The users are happy having horizontal scroll bar at the bottom of the browser screen, but need the search criteria fit the width of the screen. How can I achieve it?
↧
Export Mapping to XML encodes HTML element start bracket but not the end bracket
I have a string attribute as part of one of my entities that is then used in the Export to XML action. The attribute contains HTML, and during the export process, the opening bracket of each HTML element (<) is encoded to ‘<’. The problem is, the ending bracket (>) is not encoded to ‘>’. The consumer of my webservice requires this, but there is no easy way to “force” this to happen. Is this a bug in the Export with Mapping activity?
↧
Publishing App for 1st Time Errors
I have two errors when trying to publish my app for the first time. 1 : Message stated “The selected page 'MyFirstModule.LearnNow Training Management' no longer exists.” Element stated “Property 'Page' of navigation profile ‘Responsive’. Message stated “The selected page 'MyFirstModule.LearnNow Training Management' no longer exists.” Element stated Property 'Page' of menu item ‘Home’. Please help! I don’t know what to do.
↧
Package Download Forbidden
Thanks for the help yesterday on accessing the APIs so that I can do some CI/CD. Today I am trying to download a new package that I have created using the APIs. I used a Post and created the package and took the generated PackageId and used it to Retrieve the package until it succeeded. Which gave me this result:
{
"Status": "Succeeded",
"CreationDate": 1567713908157,
"ExpiryDate": null,
"Description": "A Signature Manual Build.",
"Version": "1.0.97.97",
"Size": 53430893,
"PackageId": "6f******-****-****-****-**********99",
"MendixVersion": "7.23.6.53654",
"Creator": "Keith Nicholson",
"Name": "Main line-1.0.97.97.mda"
} So my next step was to do the download:
https://deploy.mendix.com/api/1/apps/inhousemaintenance/packages/6f******-****-****-****-**********99/download However I get a 403 Forbidden error, I’m using the same Mendix Username and ApiKey as the other call and I removed the Content-Type to keep it from forcing json. Perhaps this will help as well. I am not using the Mendix Cloud as my environment. Currently I am using the SAP Cloud Platform. So when I go to my Apps Deploy/Environments setting, of course I do not see my new package. Perhaps by unlinking the Mendix Cloud, I do not have permissions to the packages? Even when I run the above request stopping after “…./packages/”, I get the 403 error. So two questions: How do I get the downloads? Even If I do get them, is the build the same between environments or do they differ? If the answer to the last question is “yes, they differ”, should I be trying SAP APIs instead to do a build? I’m sure I’ll have to do that for deployment anyway. I look forward to your assistance. Peace, Keith Nicholson
↧
↧
Mendix Pro: memory consumption, memory leak? New feature?
On windows 10 machine: Just Mendix Pro , no project loaded 486 MB memory usage After loading a project, doing nothing, the memory usage increases from the 486 MB initial to to 744 MB and 800 MB and 900 MB and 1000 MB Still doiing no work at all, memory usage is still increasing, normal? so 1120 MB now, still increasing This will continue until 1300 MB… still increasing This can't be ok?
↧
Time Widget to display ETA
Please can you suggest how to display time for ETA. It should display current time and future time with 30 minutes interval. it should not display previouse time. for example if date is today date and time is 13.30 , it should show time at drop down like 14.00, 14.30 etc. it should not display before time like 13.00 12.30. if we chose next day it should display time like 00.00 to 11.30, all slots for 24 hours.
↧
Error Anonymous users must be enabled to use native navigation profile.
I am currently at step ‘Add data to your app’ of the learning path Become a Rapid Developer (Analyst). I am trying to view my app, but the error: ‘Error Anonymous users must be enabled to use native navigation profile.’ appears. It says ‘The selected document type can only be edited using Mendix Studio Pro.’ So I have tried to fix it in Mendix Studio Pro but I do not know how, so I am stuck. Can someone help me out?
↧