Update the referencing content

I have…

I’m submitting a…

  • [ ] Regression (a behavior that stopped working in a new release)
  • [ ] Bug report
  • [ ] Performance issue
  • [ ] Documentation issue or request

Current behavior

Expected behavior

Minimal reproduction of the problem

Environment

App Name:

  • [ ] Self hosted with docker
  • [#] Self hosted with IIS
  • [ ] Self hosted with other version
  • [ ] Cloud version

Version: 6.5

Browser:

  • [ #] Chrome (desktop)
  • [ ] Chrome (Android)
  • [ ] Chrome (iOS)
  • [ ] Firefox
  • [ ] Safari (desktop)
  • [ ] Safari (iOS)
  • [ ] IE
  • [ ] Edge

Hi Sebastian,

I have a requirement say there is a market having field region (reference to Schema region) and a field region working hrs (which get populated using scripts getReference as working hrs is Region’s field) is string field in market
Now suppose the working hrs in region schema is updated but the changes aren’t getting reflected in Market schema as working Hrs is not directly refered

Is there any work around for this, basically i want some rule or script so that i can update all the content(in other schemas) referencing that content which is getting updated (in parent schema)

No, sorry. You could just use GraphQL for that and calculate the working hours client side.

sorry i don’t undestand how. Is there any sample available?

You just make a query like this

query {
   queryMarketContents {
      id,
      flatData {
          region { // reference
             id,
             flatData { 
                workingHours
             }
          }
      }
  }
}

The brackets are probably not correct :wink: