mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Merge pull request #6488 from open-sausages/pulls/4.0/campaign-regressions
Fix regression issues in campaigns
This commit is contained in:
commit
1f406fa497
18
admin/client/dist/js/bundle.js
vendored
18
admin/client/dist/js/bundle.js
vendored
@ -2500,14 +2500,14 @@ handleBackButtonClick:this.handleBackButtonClick.bind(this)}
|
|||||||
return p["default"].createElement(A["default"],e)}},{key:"renderDetailEditView",value:function m(){var e=this.props.sectionConfig.form.DetailEditForm.schemaUrl,t=e
|
return p["default"].createElement(A["default"],e)}},{key:"renderDetailEditView",value:function m(){var e=this.props.sectionConfig.form.DetailEditForm.schemaUrl,t=e
|
||||||
this.props.params.id>0&&(t=e+"/"+this.props.params.id)
|
this.props.params.id>0&&(t=e+"/"+this.props.params.id)
|
||||||
var n={createFn:this.campaignEditCreateFn.bind(this),schemaUrl:t}
|
var n={createFn:this.campaignEditCreateFn.bind(this),schemaUrl:t}
|
||||||
return p["default"].createElement("div",null,p["default"].createElement(x["default"],{showBackButton:!0,handleBackButtonClick:this.handleBackButtonClick},p["default"].createElement(C["default"],{multiline:!0
|
return p["default"].createElement("div",{className:"fill-height"},p["default"].createElement(x["default"],{showBackButton:!0,handleBackButtonClick:this.handleBackButtonClick},p["default"].createElement(C["default"],{
|
||||||
})),p["default"].createElement("div",{className:"panel panel--padded panel--scrollable flexbox-area-grow form--inline"},p["default"].createElement(I["default"],n)))}},{key:"renderCreateView",value:function g(){
|
multiline:!0})),p["default"].createElement("div",{className:"panel panel--padded panel--scrollable flexbox-area-grow form--inline"},p["default"].createElement(I["default"],n)))}},{key:"renderCreateView",
|
||||||
var e=this.props.sectionConfig.form.DetailEditForm.schemaUrl,t=e
|
value:function g(){var e=this.props.sectionConfig.form.DetailEditForm.schemaUrl,t=e
|
||||||
this.props.params.id>0&&(t=e+"/"+this.props.params.id)
|
this.props.params.id>0&&(t=e+"/"+this.props.params.id)
|
||||||
var n={createFn:this.campaignAddCreateFn.bind(this),schemaUrl:t}
|
var n={createFn:this.campaignAddCreateFn.bind(this),schemaUrl:t}
|
||||||
return p["default"].createElement("div",null,p["default"].createElement(x["default"],{showBackButton:!0,handleBackButtonClick:this.handleBackButtonClick},p["default"].createElement(C["default"],{multiline:!0
|
return p["default"].createElement("div",{className:"fill-height"},p["default"].createElement(x["default"],{showBackButton:!0,handleBackButtonClick:this.handleBackButtonClick},p["default"].createElement(C["default"],{
|
||||||
})),p["default"].createElement("div",{className:"panel panel--padded panel--scrollable flexbox-area-grow form--inline"},p["default"].createElement(I["default"],n)))}},{key:"campaignEditCreateFn",value:function v(e,t){
|
multiline:!0})),p["default"].createElement("div",{className:"panel panel--padded panel--scrollable flexbox-area-grow form--inline"},p["default"].createElement(I["default"],n)))}},{key:"campaignEditCreateFn",
|
||||||
var n=this,i=this.props.sectionConfig.url
|
value:function v(e,t){var n=this,i=this.props.sectionConfig.url
|
||||||
if("action_cancel"===t.name){var r=d({},t,{handleClick:function a(e){e.preventDefault(),n.props.router.push(i)}})
|
if("action_cancel"===t.name){var r=d({},t,{handleClick:function a(e){e.preventDefault(),n.props.router.push(i)}})
|
||||||
return p["default"].createElement(e,d({key:t.id},r))}return p["default"].createElement(e,d({key:t.id},t))}},{key:"campaignAddCreateFn",value:function b(e,t){var n=this,i=this.props.sectionConfig.url
|
return p["default"].createElement(e,d({key:t.id},r))}return p["default"].createElement(e,d({key:t.id},t))}},{key:"campaignAddCreateFn",value:function b(e,t){var n=this,i=this.props.sectionConfig.url
|
||||||
if("action_cancel"===t.name){var r=d({},t,{handleClick:function a(e){e.preventDefault(),n.props.router.push(i)}})
|
if("action_cancel"===t.name){var r=d({},t,{handleClick:function a(e){e.preventDefault(),n.props.router.push(i)}})
|
||||||
@ -2649,9 +2649,9 @@ case"deleted":t.className="label label-error list-group-item__status",t.Title=p[
|
|||||||
break
|
break
|
||||||
case"none":default:t.className="label label-success list-group-item__status",t.Title=p["default"]._t("CampaignItem.NO_CHANGES","No changes")}var r=u["default"].createElement("span",{className:"list-group-item__info campaign-admin__item-links--has-links font-icon-link"
|
case"none":default:t.className="label label-success list-group-item__status",t.Title=p["default"]._t("CampaignItem.NO_CHANGES","No changes")}var r=u["default"].createElement("span",{className:"list-group-item__info campaign-admin__item-links--has-links font-icon-link"
|
||||||
},"3 linked items")
|
},"3 linked items")
|
||||||
return n.Thumbnail&&(e=u["default"].createElement("span",{className:"list-group-item__thumbnail"},u["default"].createElement("img",{alt:n.Title,src:n.Thumbnail}))),u["default"].createElement("div",null,e,u["default"].createElement("h4",{
|
return n.Thumbnail&&(e=u["default"].createElement("span",{className:"list-group-item__thumbnail"},u["default"].createElement("img",{alt:n.Title,src:n.Thumbnail}))),u["default"].createElement("div",{className:"fill-height"
|
||||||
className:"list-group-item-heading"},n.Title),u["default"].createElement("span",{className:"list-group-item__info campaign-admin__item-links--is-linked font-icon-link"}),r,t.className&&t.Title&&u["default"].createElement("span",{
|
},e,u["default"].createElement("h4",{className:"list-group-item-heading"},n.Title),u["default"].createElement("span",{className:"list-group-item__info campaign-admin__item-links--is-linked font-icon-link"
|
||||||
className:t.className},t.Title))}}]),t}(c["default"])
|
}),r,t.className&&t.Title&&u["default"].createElement("span",{className:t.className},t.Title))}}]),t}(c["default"])
|
||||||
h.propTypes={campaign:u["default"].PropTypes.object.isRequired,item:u["default"].PropTypes.object.isRequired},t["default"]=h},function(e,t,n){"use strict"
|
h.propTypes={campaign:u["default"].PropTypes.object.isRequired,item:u["default"].PropTypes.object.isRequired},t["default"]=h},function(e,t,n){"use strict"
|
||||||
function i(e){return e&&e.__esModule?e:{"default":e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called")
|
function i(e){return e&&e.__esModule?e:{"default":e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called")
|
||||||
|
|
||||||
|
@ -175,7 +175,7 @@ class CampaignAdmin extends SilverStripeComponent {
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div className="fill-height">
|
||||||
<Toolbar showBackButton handleBackButtonClick={this.handleBackButtonClick}>
|
<Toolbar showBackButton handleBackButtonClick={this.handleBackButtonClick}>
|
||||||
<Breadcrumb multiline />
|
<Breadcrumb multiline />
|
||||||
</Toolbar>
|
</Toolbar>
|
||||||
@ -202,7 +202,7 @@ class CampaignAdmin extends SilverStripeComponent {
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div className="fill-height">
|
||||||
<Toolbar showBackButton handleBackButtonClick={this.handleBackButtonClick}>
|
<Toolbar showBackButton handleBackButtonClick={this.handleBackButtonClick}>
|
||||||
<Breadcrumb multiline />
|
<Breadcrumb multiline />
|
||||||
</Toolbar>
|
</Toolbar>
|
||||||
|
@ -56,7 +56,7 @@ class CampaignAdminItem extends SilverStripeComponent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div className="fill-height">
|
||||||
{thumbnail}
|
{thumbnail}
|
||||||
<h4 className="list-group-item-heading">{item.Title}</h4>
|
<h4 className="list-group-item-heading">{item.Title}</h4>
|
||||||
<span
|
<span
|
||||||
|
@ -425,7 +425,7 @@ class CampaignAdmin extends LeftAndMain implements PermissionProvider
|
|||||||
* @param int $id
|
* @param int $id
|
||||||
* @return Form
|
* @return Form
|
||||||
*/
|
*/
|
||||||
public function getDetailEditForm($id)
|
public function getDetailEditForm($id = null)
|
||||||
{
|
{
|
||||||
// Get record-specific fields
|
// Get record-specific fields
|
||||||
$record = null;
|
$record = null;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user