File tree Expand file tree Collapse file tree 4 files changed +11
-4
lines changed
Expand file tree Collapse file tree 4 files changed +11
-4
lines changed Original file line number Diff line number Diff line change 5151 "react" : " ^15.6.1" ,
5252 "react-addons-css-transition-group" : " ^15.6.0" ,
5353 "react-addons-pure-render-mixin" : " ^15.6.0" ,
54+ "query-string" : " ^4.3.4" ,
5455 "react-color" : " ^2.13.1" ,
5556 "react-datetime" : " 2.7.1" ,
5657 "react-dom" : " ^15.6.1" ,
Original file line number Diff line number Diff line change @@ -253,3 +253,5 @@ export const MAINTENANCE_MODE = false
253253export const LS_INCOMPLETE_PROJECT = 'incompleteProject'
254254
255255export const CONNECT_MESSAGE_API_URL = process . env . CONNECT_MESSAGE_API_URL || TC_API_URL
256+
257+ export const NEW_PROJECT_PATH = '/new-project'
Original file line number Diff line number Diff line change @@ -11,7 +11,8 @@ import {
1111 CREATE_PROJECT_FAILURE ,
1212 LS_INCOMPLETE_PROJECT ,
1313 PROJECT_STATUS_IN_REVIEW ,
14- ACCOUNTS_APP_REGISTER_URL
14+ ACCOUNTS_APP_REGISTER_URL ,
15+ NEW_PROJECT_PATH
1516} from '../../../config/constants'
1617
1718const page404 = compose (
@@ -141,10 +142,10 @@ class CreateConainer extends React.Component {
141142 processing = { this . state . creatingProject }
142143 onStepChange = { ( wizardStep ) => {
143144 if ( wizardStep === ProjectWizard . Steps . WZ_STEP_INCOMP_PROJ_CONF ) {
144- browserHistory . push ( '/new-project /incomplete')
145+ browserHistory . push ( NEW_PROJECT_PATH + ' /incomplete')
145146 }
146147 if ( wizardStep === ProjectWizard . Steps . WZ_STEP_SELECT_PROD_TYPE ) {
147- browserHistory . push ( '/new-project/' )
148+ browserHistory . push ( NEW_PROJECT_PATH + '' + window . location . search )
148149 }
149150 this . setState ( {
150151 wizardStep
@@ -157,7 +158,7 @@ class CreateConainer extends React.Component {
157158 // compares updated product with previous product to know if user has updated the product
158159 if ( prevProduct !== product ) {
159160 if ( product ) {
160- browserHistory . push ( '/new-project/ ' + product )
161+ browserHistory . push ( NEW_PROJECT_PATH + '/ ' + product + window . location . search )
161162 }
162163 }
163164 this . setState ( {
Original file line number Diff line number Diff line change 11import React , { PropTypes } from 'react'
2+ import qs from 'query-string'
23import { Tabs , Tab , TCFormFields } from 'appirio-tech-react-components'
34import _ from 'lodash'
45import SpecQuestions from './SpecQuestions'
@@ -98,6 +99,7 @@ const SpecSection = props => {
9899 case 'project-name' : {
99100 const refCodeFieldName = 'details.utm.code'
100101 const refCode = _ . get ( project , refCodeFieldName , undefined )
102+ const queryParamRefCode = qs . parse ( window . location . search ) . refCode
101103 return (
102104 < div className = "project-name-section" >
103105 { ( ! project . status || project . status === PROJECT_STATUS_DRAFT ) &&
@@ -129,6 +131,7 @@ const SpecSection = props => {
129131 wrapperClass = "project-refcode"
130132 maxLength = { PROJECT_REF_CODE_MAX_LENGTH }
131133 theme = "paper-form-dotted"
134+ disabled = { queryParamRefCode && queryParamRefCode . length > 0 }
132135 />
133136 < div className = "refcode-desc" >
134137 Optional
You can’t perform that action at this time.
0 commit comments