mirror of
https://github.com/kingomarnajjar/flex-template-web.git
synced 2026-07-28 03:43:28 +10:00
Read category from publicData
This commit is contained in:
parent
187d6ce5e3
commit
6c19e36588
1 changed files with 2 additions and 2 deletions
|
|
@ -24,7 +24,7 @@ const EditListingDescriptionPanel = props => {
|
|||
|
||||
const classes = classNames(rootClassName || css.root, className);
|
||||
const currentListing = ensureListing(listing);
|
||||
const { description, title, customAttributes } = currentListing.attributes;
|
||||
const { description, title, publicData } = currentListing.attributes;
|
||||
const listingTitle = title || '';
|
||||
const listingLink = currentListing.id ? (
|
||||
<NamedLink name="ListingPage" params={{ id: currentListing.id.uuid, slug: createSlug(title) }}>
|
||||
|
|
@ -48,7 +48,7 @@ const EditListingDescriptionPanel = props => {
|
|||
<h1 className={css.title}>{panelTitle}</h1>
|
||||
<EditListingDescriptionForm
|
||||
className={css.form}
|
||||
initialValues={{ title, description, ...customAttributes }}
|
||||
initialValues={{ title, description, category: publicData.category }}
|
||||
saveActionMsg={submitButtonText}
|
||||
onSubmit={values => {
|
||||
const { title, description, category } = values;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue