GithubHelp home page GithubHelp logo

Comments (2)

chillu avatar chillu commented on June 27, 2024

I hope we can do this in a minor release of the advancedworkflow module, which means we could introduce this feature in the CWP 2.x release line at some point next year. The data model stays the same, it's just the extension names which change (and we can fix that through subclasses). YAML config keys would need to be adjusted. So we'd add this module to our supported modules under CWP, instead of maintaining the same code twice.

from silverstripe-embargo-expiry.

chrispenny avatar chrispenny commented on June 27, 2024

@chillu I believe support for Workflow should be possible once I have merged:
#28

Model should store separate "desired" dates (yet to be approved) from actual states

I've added matching fields:

  • DesiredPublishDate
  • DesiredUnPublishDate
  • PublishOnDate
  • UnPublishOnDate

Only the approval should trigger a queued job

As part of ensurePublishJob() and ensureUnPublishJob() there are now extension points (publishJobCanBeQueued and unPublishJobCanBeQueued) which the Workflow module could use to prevent the creation of QueuedJobs outside of any context that they desire. The Desired..Date fields will still hold their respective values, and the Workflow module can then "take over" and do their own thing, or simply call ensurePublishJob() and ensureUnPublishJob() again with publishJobCanBeQueued and unPublishJobCanBeQueued now allowing Job creation.

Hide schedule date fields if "desired" dates are set

I don't think there is anything for me to change here. I'm exposing fields that are relevant given the current Object state and whether or not editing during embargo is allowed.

Define if record can be edited during embargo in workflow action

As part of this module's isEditable() method, there is now an extension point available (embargoRecordIsEditable) which Workflow could use to add their own constraints for canEdit()/canPublish().

Migration path shouldn't be required

I believe this is true. As you say, they use the same fields.

from silverstripe-embargo-expiry.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.