wagtail-personalisation icon indicating copy to clipboard operation
wagtail-personalisation copied to clipboard

Add basic personalisation blocks

Open tm-kn opened this issue 7 years ago • 3 comments

Issue #68

  • Add "visible to everyone" segment setting for PersonalisedStructBlock.

  • Add the render_fields keyword argument for PersonalisedStructBlock. Setting of the same name can be also set on Meta class of the block.

    • It takes a list of field names and renders them in order without titles.
    • If set to None, it will just use StructBlock's render() (as currently, displaying field titles & content or template specified in Meta).
  • Add a few more default blocks so they work out of the box.

    • PersonalisedCharBlock
    • PersonalisedImageChooserBlock
    • PersonalisedRichTextBlock
    • PersonalisedTextBlock

tm-kn avatar May 31 '17 14:05 tm-kn

Codecov Report

Merging #135 into master will not change coverage. The diff coverage is 57.14%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #135   +/-   ##
=======================================
  Coverage   68.47%   68.47%           
=======================================
  Files          55       55           
  Lines        2217     2217           
=======================================
  Hits         1518     1518           
  Misses        699      699
Impacted Files Coverage Δ
src/wagtail_personalisation/blocks.py 58.82% <57.14%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 94c947a...912b46c. Read the comment docs.

codecov[bot] avatar May 31 '17 15:05 codecov[bot]

@tm-kn can you look at the 2.7 failures, please?

tomdyson avatar May 31 '17 16:05 tomdyson

Codecov Report

Merging #135 into master will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #135   +/-   ##
=======================================
  Coverage   92.83%   92.83%           
=======================================
  Files          66       66           
  Lines        2010     2010           
=======================================
  Hits         1866     1866           
  Misses        144      144

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update a47803e...1d18a82. Read the comment docs.

codecov-io avatar Jul 19 '18 13:07 codecov-io