diff --git a/js/components/ascribe_forms/form_consign.js b/js/components/ascribe_forms/form_consign.js
index cf68d429..708ab70e 100644
--- a/js/components/ascribe_forms/form_consign.js
+++ b/js/components/ascribe_forms/form_consign.js
@@ -34,7 +34,7 @@ Truly yours,
${username}`;
return (
-
+ );
+ }
+});
+
+export default ConsignForm;
\ No newline at end of file
diff --git a/js/components/ascribe_forms/form_unconsign.js b/js/components/ascribe_forms/form_unconsign.js
new file mode 100644
index 00000000..60112334
--- /dev/null
+++ b/js/components/ascribe_forms/form_unconsign.js
@@ -0,0 +1,58 @@
+import fetch from 'isomorphic-fetch';
+
+import React from 'react';
+
+import ApiUrls from '../../constants/api_urls';
+import FormMixin from '../../mixins/form_mixin';
+import InputText from './input_text';
+import InputTextArea from './input_textarea';
+import ButtonSubmitOrClose from './button_submit_close';
+
+let UnConsignForm = React.createClass({
+ mixins: [FormMixin],
+
+ url() {
+ return ApiUrls.ownership_unconsigns
+ },
+ getFormData() {
+ return {
+ bitcoin_id: this.props.edition.bitcoin_id,
+ unconsign_message: this.refs.unconsign_message.state.value,
+ password: this.refs.password.state.value
+ }
+ },
+ renderForm() {
+ let title = this.props.edition.title;
+ let username = this.props.currentUser.username;
+ let message =
+`Hi,
+
+I un-consign \" ${title} \" from you.
+
+Truly yours,
+${username}`;
+
+ return (
+
+ );
+ }
+});
+
+export default UnConsignForm;
\ No newline at end of file
diff --git a/js/components/ascribe_forms/form_unconsign_request.js b/js/components/ascribe_forms/form_unconsign_request.js
new file mode 100644
index 00000000..f572a287
--- /dev/null
+++ b/js/components/ascribe_forms/form_unconsign_request.js
@@ -0,0 +1,49 @@
+import fetch from 'isomorphic-fetch';
+
+import React from 'react';
+
+import ApiUrls from '../../constants/api_urls';
+import FormMixin from '../../mixins/form_mixin';
+import InputText from './input_text';
+import InputTextArea from './input_textarea';
+import ButtonSubmitOrClose from './button_submit_close';
+
+let UnConsignRequestForm = React.createClass({
+ mixins: [FormMixin],
+
+ url() {
+ return ApiUrls.ownership_unconsigns_request
+ },
+ getFormData() {
+ return {
+ bitcoin_id: this.props.edition.bitcoin_id,
+ unconsign_request_message: this.refs.unconsign_request_message.state.value
+ }
+ },
+ renderForm() {
+ let title = this.props.edition.title;
+ let username = this.props.currentUser.username;
+ let message =
+`Hi,
+
+I request you to un-consign \" ${title} \".
+
+Truly yours,
+${username}`;
+
+ return (
+
+ );
+ }
+});
+
+export default UnConsignRequestForm;
\ No newline at end of file
diff --git a/js/components/ascribe_modal/modal_loan.js b/js/components/ascribe_modal/modal_loan.js
new file mode 100644
index 00000000..bcd47973
--- /dev/null
+++ b/js/components/ascribe_modal/modal_loan.js
@@ -0,0 +1,43 @@
+import React from 'react';
+import Modal from 'react-bootstrap/lib/Modal';
+import OverlayTrigger from 'react-bootstrap/lib/OverlayTrigger';
+import ModalTrigger from 'react-bootstrap/lib/ModalTrigger';
+import Tooltip from 'react-bootstrap/lib/Tooltip';
+
+import ConsignForm from '../ascribe_forms/form_consign'
+import ModalMixin from '../../mixins/modal_mixin'
+
+let ConsignModalButton = React.createClass({
+ render() {
+ return (
+ Have someone else sell the artwork}>
+ }>
+
+ CONSIGN
+
+
+
+ )
+ }
+});
+
+let ConsignModal = React.createClass({
+ mixins : [ModalMixin],
+
+ render() {
+ return (
+
+
+
+
+
+ )
+ }
+});
+
+
+export default ConsignModalButton;
diff --git a/js/components/ascribe_modal/modal_unconsign.js b/js/components/ascribe_modal/modal_unconsign.js
new file mode 100644
index 00000000..1245fc01
--- /dev/null
+++ b/js/components/ascribe_modal/modal_unconsign.js
@@ -0,0 +1,43 @@
+import React from 'react';
+import Modal from 'react-bootstrap/lib/Modal';
+import OverlayTrigger from 'react-bootstrap/lib/OverlayTrigger';
+import ModalTrigger from 'react-bootstrap/lib/ModalTrigger';
+import Tooltip from 'react-bootstrap/lib/Tooltip';
+
+import UnConsignForm from '../ascribe_forms/form_unconsign'
+import ModalMixin from '../../mixins/modal_mixin'
+
+let UnConsignModalButton = React.createClass({
+ render() {
+ return (
+ Unconsign this artwork}>
+ }>
+
+ UNCONSIGN
+
+
+
+ )
+ }
+});
+
+let UnConsignModal = React.createClass({
+ mixins : [ModalMixin],
+
+ render() {
+ return (
+
+
+
+
+
+ )
+ }
+});
+
+
+export default UnConsignModalButton;
diff --git a/js/components/ascribe_modal/modal_unconsign_request.js b/js/components/ascribe_modal/modal_unconsign_request.js
new file mode 100644
index 00000000..c74e637b
--- /dev/null
+++ b/js/components/ascribe_modal/modal_unconsign_request.js
@@ -0,0 +1,43 @@
+import React from 'react';
+import Modal from 'react-bootstrap/lib/Modal';
+import OverlayTrigger from 'react-bootstrap/lib/OverlayTrigger';
+import ModalTrigger from 'react-bootstrap/lib/ModalTrigger';
+import Tooltip from 'react-bootstrap/lib/Tooltip';
+
+import UnConsignRequestForm from '../ascribe_forms/form_unconsign_request'
+import ModalMixin from '../../mixins/modal_mixin'
+
+let UnConsignRequestModalButton = React.createClass({
+ render() {
+ return (
+ Request to unconsign the artwork}>
+ }>
+
+ UNCONSIGN REQUEST
+
+
+
+ )
+ }
+});
+
+let UnConsignRequestModal = React.createClass({
+ mixins : [ModalMixin],
+
+ render() {
+ return (
+
+
+
+
+
+ )
+ }
+});
+
+
+export default UnConsignRequestModalButton;
diff --git a/js/components/edition.js b/js/components/edition.js
index 65fa2a51..2c5279c1 100644
--- a/js/components/edition.js
+++ b/js/components/edition.js
@@ -2,6 +2,8 @@ import React from 'react';
import ImageViewer from './ascribe_media/image_viewer';
import ConsignModalButton from './ascribe_modal/modal_consign';
+import UnConsignModalButton from './ascribe_modal/modal_unconsign';
+import UnConsignRequestModalButton from './ascribe_modal/modal_unconsign_request';
import TransferModalButton from './ascribe_modal/modal_transfer';
import ShareModalButton from './ascribe_modal/modal_share';
@@ -49,6 +51,8 @@ let EditionDetails = React.createClass({
+
+
diff --git a/js/constants/api_urls.js b/js/constants/api_urls.js
index d26352bc..6099710b 100644
--- a/js/constants/api_urls.js
+++ b/js/constants/api_urls.js
@@ -3,7 +3,9 @@ import AppConstants from './application_constants';
let apiUrls = {
'ownership_shares_mail' : AppConstants.baseUrl + 'ownership/shares/mail/',
'ownership_transfers' : AppConstants.baseUrl + 'ownership/transfers/',
- 'ownership_consigns' : AppConstants.baseUrl + 'ownership/consigns/'
+ 'ownership_consigns' : AppConstants.baseUrl + 'ownership/consigns/',
+ 'ownership_unconsigns' : AppConstants.baseUrl + 'ownership/unconsigns/',
+ 'ownership_unconsigns_request' : AppConstants.baseUrl + 'ownership/unconsigns/request/'
};
export default apiUrls;
\ No newline at end of file
diff --git a/js/constants/application_constants.js b/js/constants/application_constants.js
index 17a6d7df..9c20a7ba 100644
--- a/js/constants/application_constants.js
+++ b/js/constants/application_constants.js
@@ -1,6 +1,6 @@
let constants = {
- //'baseUrl': 'http://localhost:8000/api/',
- 'baseUrl': 'http://staging.ascribe.io/api/',
+ 'baseUrl': 'http://localhost:8000/api/',
+ //'baseUrl': 'http://staging.ascribe.io/api/',
'debugCredentialBase64': 'ZGltaUBtYWlsaW5hdG9yLmNvbTowMDAwMDAwMDAw', // dimi@mailinator:0000000000
'aclList': ['edit', 'consign', 'transfer', 'loan', 'share', 'download', 'view', 'delete', 'del_from_collection', 'add_to_collection']
};