diff --git a/js/actions/contract_agreement_list_actions.js b/js/actions/contract_agreement_list_actions.js index fe089f24..cd78b52b 100644 --- a/js/actions/contract_agreement_list_actions.js +++ b/js/actions/contract_agreement_list_actions.js @@ -16,7 +16,6 @@ class ContractAgreementListActions { fetchContractAgreementList(issuer, accepted, pending) { this.actions.updateContractAgreementList(null); - return Q.Promise((resolve, reject) => { OwnershipFetcher.fetchContractAgreementList(issuer, accepted, pending) .then((contractAgreementList) => { diff --git a/js/components/ascribe_forms/form.js b/js/components/ascribe_forms/form.js index f7b1f76f..c5f60b76 100644 --- a/js/components/ascribe_forms/form.js +++ b/js/components/ascribe_forms/form.js @@ -203,7 +203,7 @@ let Form = React.createClass({ } let buttons = null; - if (this.state.edited){ + if (this.state.edited && !this.props.disabled){ buttons = (
diff --git a/js/components/ascribe_forms/input_textarea_toggable.js b/js/components/ascribe_forms/input_textarea_toggable.js
index 97f880f3..e789b61e 100644
--- a/js/components/ascribe_forms/input_textarea_toggable.js
+++ b/js/components/ascribe_forms/input_textarea_toggable.js
@@ -41,10 +41,6 @@ let InputTextAreaToggable = React.createClass({
}
},
- componentWillUnmount() {
- this.setState({value: null});
- },
-
handleChange(event) {
this.setState({value: event.target.value});
this.props.onChange(event);
diff --git a/js/components/whitelabel/wallet/components/cyland/ascribe_detail/cyland_piece_container.js b/js/components/whitelabel/wallet/components/cyland/ascribe_detail/cyland_piece_container.js
index f4a63ec8..3264c27e 100644
--- a/js/components/whitelabel/wallet/components/cyland/ascribe_detail/cyland_piece_container.js
+++ b/js/components/whitelabel/wallet/components/cyland/ascribe_detail/cyland_piece_container.js
@@ -42,13 +42,6 @@ let CylandPieceContainer = React.createClass({
UserStore.listen(this.onChange);
},
- componentWillReceiveProps(nextProps) {
- if(this.props.params.pieceId !== nextProps.params.pieceId) {
- PieceActions.updatePiece({});
- PieceActions.fetchOne(nextProps.params.pieceId);
- }
- },
-
componentWillUnmount() {
// Every time we're leaving the piece detail page,
// just reset the piece that is saved in the piece store
diff --git a/js/components/whitelabel/wallet/components/ikonotv/ascribe_detail/ikonotv_piece_container.js b/js/components/whitelabel/wallet/components/ikonotv/ascribe_detail/ikonotv_piece_container.js
index 2025c10b..0425d5d8 100644
--- a/js/components/whitelabel/wallet/components/ikonotv/ascribe_detail/ikonotv_piece_container.js
+++ b/js/components/whitelabel/wallet/components/ikonotv/ascribe_detail/ikonotv_piece_container.js
@@ -21,6 +21,12 @@ import Property from '../../../../../../components/ascribe_forms/property';
import InputTextAreaToggable from '../../../../../../components/ascribe_forms/input_textarea_toggable';
import CollapsibleParagraph from '../../../../../../components/ascribe_collapsible/collapsible_paragraph';
+import IkonotvArtistDetailsForm from '../ascribe_forms/ikonotv_artist_details_form';
+import IkonotvArtworkDetailsForm from '../ascribe_forms/ikonotv_artwork_details_form';
+
+import GlobalNotificationModel from '../../../../../../models/global_notification_model';
+import GlobalNotificationActions from '../../../../../../actions/global_notification_actions';
+
import HistoryIterator from '../../../../../ascribe_detail/history_iterator';
import Note from '../../../../../ascribe_detail/note';
@@ -44,23 +50,18 @@ let IkonotvPieceContainer = React.createClass({
componentDidMount() {
PieceStore.listen(this.onChange);
- PieceActions.fetchOne(this.props.params.pieceId);
UserStore.listen(this.onChange);
- },
- componentWillReceiveProps(nextProps) {
- if(this.props.params.pieceId !== nextProps.params.pieceId) {
- PieceActions.updatePiece({});
- PieceActions.fetchOne(nextProps.params.pieceId);
- }
- },
-
- componentWillUnmount() {
// Every time we're leaving the piece detail page,
// just reset the piece that is saved in the piece store
// as it will otherwise display wrong/old data once the user loads
// the piece detail a second time
PieceActions.updatePiece({});
+
+ this.loadPiece();
+ },
+
+ componentWillUnmount() {
PieceStore.unlisten(this.onChange);
UserStore.unlisten(this.onChange);
},
@@ -159,6 +160,7 @@ let IkonotvPieceContainer = React.createClass({
url={ApiUrls.note_private_piece}
currentUser={this.state.currentUser}/>
+