Update custom-fields.js

This commit is contained in:
Joel Varty 2021-10-14 11:57:33 -04:00 committed by GitHub
parent 79dad4cadc
commit 6140c50196
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6,8 +6,6 @@
* THIS FILE IS USED FOR THE AGILITY'S CUSTOM FIELDS * THIS FILE IS USED FOR THE AGILITY'S CUSTOM FIELDS
*/ */
var baseUrl = "https://forzaforni-commerce-agilitycms.vercel.app/"
var FriendlyURLFormField = function () { var FriendlyURLFormField = function () {
var self = this; var self = this;
@ -267,6 +265,8 @@ var ChooseProductCustomField = function () {
/// </param> /// </param>
var self = this; var self = this;
ContentManager.DataAccess.GetPreviewUrl()
self.ajaxRequest = null; self.ajaxRequest = null;
self.selectedValue = options.fieldBinding.extend({ throttle: 500 }); self.selectedValue = options.fieldBinding.extend({ throttle: 500 });
@ -307,7 +307,7 @@ var ChooseProductCustomField = function () {
}, },
ajax: { // instead of writing the function to execute the request we use Select2's convenient helper ajax: { // instead of writing the function to execute the request we use Select2's convenient helper
url: "https://nextjs-commerce-agility-cms.vercel.app/api/search-products", url: "https://my-bigcommerce-store-oct-14.vercel.app/api/search-products",
//url: "http://localhost:3000/api/search-products", //url: "http://localhost:3000/api/search-products",
dataType: 'json', dataType: 'json',
type: "get", type: "get",