Hi there.
I have my database query and results table all working well however one of the columns contains a URL. The table is disconnected from the database.
I have searched for the past couple of hours and cannot find a way to make the link clickable.
It just displays as text.
Any ideas how I can make this happen?
import wixData from "wix-data";
export function CodeInput_input(event) {
wixData.query("PAFKonly")
.eq("customerCode", $w("#CodeInput").value)
.eq("category",("Pots"))
//used to filter the results by price
.ascending("order")
.find() // Run the query
.then(res => {
// Set the table data to be the results of the query
$w("#table1").rows = res.items;
//Counting the number of records returned
wixData.query("PAFKonly")
.eq("customerCode", $w("#CodeInput").value)
.eq("category",("Pots"))
.count()
.then( (num) => {
let numberOfItems = num;
$w("#resnum").text = "" + num;
});
});
$w.onReady(function () {
$w("#table1").columns = [{
"id": "fkDescription",
"dataPath": "fkDescription",
"label": "Description",
"type": "string",
"width": 500,
}, {
"id": "fkArticleCode",
"dataPath": "fkArticleCode",
"label": "Article Code",
"type": "string",
"width": 100,
}, {
"id": "baseUnitQuantity",
"dataPath": "baseUnitQuantity",
"label": "Box QTY",
"type": "number",
"width": 50,
}, {
"id": "contractEachPrice",
"dataPath": "contractEachPrice",
"label": "Contract Each $",
"type": "number",
"width": 60,
}, {
"id": "contractBoxPrice",
"dataPath": "contractBoxPrice",
"label": "Contract Box $",
"type": "number",
"width": 60,
}, {
"id": "nonContractEachPrice",
"dataPath": "nonContractEachPrice",
"label": "Non-con Each $",
"type": "number",
"width": 60,
}, {
"id": "nonContractBoxPrice",
"dataPath": "nonContractBoxPrice",
"label": "Non-con Box $",
"type": "number",
"width": 60,
}, {
"id": "fkWebLink1",
"dataPath": "fkWebLink1",
"label": "Info",
"type": "URL", <---------------------------Issue is with this column
"width": 60,
}];
});