myClient.jsx 118 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847
  1. import React from 'react';
  2. import { Radio, Icon, Button, Cascader,Input, Select, Tabs,Spin,Popconfirm, Popover,Table, Switch, message, DatePicker, Modal, Upload,Form ,Row,Col,TimePicker} from 'antd';
  3. import ajax from 'jquery/src/ajax/xhr.js';
  4. import $ from 'jquery/src/ajax';
  5. import moment from 'moment';
  6. import './myClient.less';
  7. import { citySelect,provinceList,areaSelect} from '../../../NewDicProvinceList';
  8. const { Column, ColumnGroup } = Table;
  9. const TabPane = Tabs.TabPane;
  10. import CustomerDetail from './myClientDesc.jsx';
  11. import {socialAttribute,industry,newFollow,lvl,currentMember,cityArr, statuslist,customerStatus,intentionalService,sex} from '../../../dataDic.js';
  12. import {getCompanyIntention,getIndustry,getStatuslist,getContactType,getSocialAttribute,getfllowSituation,beforeUploadFile,getWhether,getcityArr,getcustomerStatue,getfllowSituationOn,getCertification,getcustomerTyp,getLvl,getCurrentMember,getprovince} from '../../../tools.js';
  13. //图片组件
  14. const PicturesWall = React.createClass({
  15. getInitialState() {
  16. return {
  17. previewVisible: false,
  18. previewImage: '',
  19. fileList: [],
  20. }
  21. },
  22. handleCancel() {
  23. this.setState({ previewVisible: false })
  24. },
  25. handlePreview(file) {
  26. this.setState({
  27. previewImage: file.url || file.thumbUrl,
  28. previewVisible: true,
  29. });
  30. },
  31. handleChange(info) {
  32. let fileList = info.fileList;
  33. this.setState({ fileList });
  34. this.props.fileList(fileList);
  35. },
  36. componentWillReceiveProps(nextProps) {
  37. this.state.fileList = nextProps.pictureUrl;
  38. },
  39. render() {
  40. const { previewVisible, previewImage, fileList } = this.state;
  41. const uploadButton = (
  42. <div>
  43. <Icon type="plus" />
  44. <div className="ant-upload-text">点击上传</div>
  45. </div>
  46. );
  47. return (
  48. <div style={{display:"inline-block"}}>
  49. <Upload
  50. action={globalConfig.context + "/api/admin/customer/attachmentUpload"}
  51. data={{ 'sign': this.props.pictureSign }}
  52. listType="picture-card"
  53. fileList={fileList}
  54. onPreview={this.handlePreview}
  55. onChange={this.handleChange} >
  56. {fileList.length >= 5 ? null : uploadButton}
  57. </Upload>
  58. <Modal maskClosable={false} visible={previewVisible} footer={null} onCancel={this.handleCancel}>
  59. <img alt="example" style={{ width: '100%' }} src={previewImage} />
  60. </Modal>
  61. </div>
  62. );
  63. }
  64. });
  65. const MyClient = Form.create()(React.createClass({
  66. loadData(pageNo, apiUrl) {
  67. this.setState({
  68. loading: true
  69. });
  70. $.ajax({
  71. method: "post",
  72. dataType: "json",
  73. crossDomain: false,
  74. url:globalConfig.context + '/api/admin/customer/listPrivateOrganizationCustomer',
  75. data: {
  76. pageNo: pageNo || 1,
  77. pageSize: this.state.pagination.pageSize,
  78. type: this.state.typeSearch, //名称1
  79. name:this.state.nameSearch,
  80. province:!(this.state.addressSearch).length?this.state.provinceSearch:this.state.addressSearch[0],
  81. city: !(this.state.addressSearch).length?'':this.state.addressSearch[1],
  82. //area: this.state.addressSearch?this.state.addressSearch[2].value:'',
  83. status:this.state.statusSearch,
  84. industry:this.state.industrySearch,
  85. serviceCertification:this.state.serviceCertificationSearch,
  86. userCertification: this.state.userCertificationSearch,
  87. international:this.state.internationalSearch,
  88. currentMemberStatus:this.state.currentMemberStatusSearch,
  89. lvl:this.state.lvlSearch,
  90. isMember:this.state.isMemberSearch,
  91. societyTag:this.state.societyTagSearch,
  92. listed:this.state.listedSearch, //是否上市
  93. highTechZone:this.state.highTechZoneSearch, //是否高新
  94. startDate: this.state.releaseDate[0],
  95. endDate: this.state.releaseDate[1],
  96. },
  97. success: function (data) {
  98. let theArr = [];
  99. if (data.error.length || data.data.list=="") {
  100. if (data.error && data.error.length) {
  101. message.warning(data.error[0].message);
  102. };
  103. } else {
  104. for (let i = 0; i < data.data.list.length; i++) {
  105. let thisdata = data.data.list[i];
  106. theArr.push({
  107. key: i,
  108. id: thisdata.uid,
  109. type:thisdata.type,
  110. name:thisdata.name,
  111. status:thisdata.status,
  112. contacts:thisdata.contacts,
  113. contactMobile:thisdata.contactMobile,
  114. industry:thisdata.industry,
  115. createTime:thisdata.createTime,
  116. serviceCertification:thisdata.serviceCertification,
  117. userCertification:thisdata.userCertification,
  118. lvl:thisdata.lvl,
  119. isMember:thisdata.isMember,
  120. status:thisdata.status,
  121. societyTag:thisdata.societyTag,
  122. currentMemberStatus:thisdata.currentMemberStatus,
  123. international:thisdata.international,
  124. listed:thisdata.listed,
  125. highTechZone:thisdata.highTechZone,
  126. locationProvince:thisdata.province?thisdata.province+'-'+thisdata.city||''+'-'+thisdata.area :'--'
  127. });
  128. };
  129. };
  130. this.state.pagination.current = data.data.pageNo;
  131. this.state.pagination.total = data.data.totalCount;
  132. this.setState({
  133. dataSource: theArr,
  134. pagination: this.state.pagination
  135. });
  136. }.bind(this),
  137. }).always(function () {
  138. this.setState({
  139. loading: false
  140. });
  141. }.bind(this));
  142. },
  143. //点击出现函数
  144. setModal2VisibleOk(e) {
  145. this.setState({
  146. modal2Visible:true
  147. });
  148. },
  149. //点击消失函数
  150. setModal2Visiblecancel(e) {
  151. this.setState({
  152. modal2Visible:false
  153. });
  154. },
  155. getPictureUrl(e) {
  156. this.setState({pictureUrl: e });
  157. },
  158. handleOk(e){
  159. this.setState({
  160. visible: false,
  161. });
  162. },
  163. handleCancel(e){
  164. this.setState({
  165. visible: false,
  166. });
  167. },
  168. getInitialState() {
  169. return {
  170. addressSearch:[],
  171. orgCodeUrl:[],
  172. companyLogoUrl:[],
  173. visible: false ,
  174. searchMore: true,
  175. releaseDate: [],
  176. releaseDate: [],
  177. selectedRowKeys: [],
  178. selectedRowKey: [],
  179. selectedRows: [],
  180. loading: false,
  181. pagination: {
  182. defaultCurrent: 1,
  183. defaultPageSize: 10,
  184. showQuickJumper: true,
  185. pageSize: 10,
  186. onChange: function (page) {
  187. this.loadData(page);
  188. }.bind(this),
  189. showTotal: function (total) {
  190. return '共' + total + '条数据';
  191. }
  192. },
  193. paginations: {
  194. defaultCurrent: 1,
  195. defaultPageSize: 10,
  196. showQuickJumper: true,
  197. pageSize: 10,
  198. onChange: function (page) {
  199. this.loadVisit(page);
  200. }.bind(this),
  201. showTotal: function (total) {
  202. return '共' + total + '条数据';
  203. }
  204. },
  205. paginationsy: {
  206. defaultCurrent: 1,
  207. defaultPageSize: 10,
  208. showQuickJumper: true,
  209. pageSize: 10,
  210. onChange: function (page) {
  211. this.loadBfVisit(page,false);
  212. }.bind(this),
  213. showTotal: function (total) {
  214. return '共' + total + '条数据';
  215. }
  216. },
  217. paginationt: {
  218. defaultCurrent: 1,
  219. defaultPageSize: 10,
  220. showQuickJumper: true,
  221. pageSize: 10,
  222. onChange: function (page) {
  223. this.BusinessList(page,false);
  224. }.bind(this),
  225. showTotal: function (total) {
  226. return '共' + total + '条数据';
  227. }
  228. },
  229. //业务意向列表
  230. intentionList:[
  231. {
  232. title: '业务名称',
  233. dataIndex: 'businessGlossoryId',
  234. key: 'businessGlossoryId',
  235. render: (text, record, index) => {
  236. return <Select placeholder="选择业务名称" disabled={record.id?true:false} value={record.businessGlossoryId} onChange={(e) => { record.businessGlossoryId = e; this.setState({ data: this.state.data }); }}>
  237. {
  238. intentionalService.map(function (item) {
  239. return <Select.Option key={item.value} >{item.key}</Select.Option>
  240. })
  241. }
  242. </Select>
  243. }
  244. },
  245. {
  246. title: '最新进度',
  247. dataIndex: 'followSituation',
  248. key: 'followSituation',
  249. render: (text, record, index) => {
  250. return <Select placeholder="选择最新进度" value={record.followSituation} onChange={(e) => { record.followSituation = e; this.setState({ data: this.state.data }); }}>
  251. {
  252. newFollow.map(function (item) {
  253. return <Select.Option key={item.value} >{item.key}</Select.Option>
  254. })
  255. }
  256. </Select>
  257. }
  258. },{
  259. title: '最新状态',
  260. dataIndex: 'customerStatus',
  261. key: 'customerStatus',
  262. render: (text, record, index) => {
  263. return <Select value={record.customerStatus} placeholder="选择最新状态" onChange={(e) => { record.customerStatus = e; this.setState({ data: this.state.data }); }}>
  264. {
  265. customerStatus.map(function (item) {
  266. return <Select.Option key={item.value} >{item.key}</Select.Option>
  267. })
  268. }
  269. </Select>
  270. }
  271. },{
  272. title: '跟进说明',
  273. dataIndex: 'remarks',
  274. key: 'remarks',
  275. render: (text, record, index) => {
  276. return <Input value={record.remarks} placeholder="跟进说明"
  277. onChange={(e) => { record.remarks = e.target.value; this.setState({ data: this.state.data }); }}
  278. style={{width:'120px'}}/>
  279. }
  280. },{
  281. title: '操作',
  282. dataIndex: 'rrr',
  283. key: 'rrr',
  284. render: (text, record, index) => {
  285. return <div>
  286. <Popconfirm title="是否删除?" onConfirm={(e)=>{this.intentionDelet(record,index)}} okText="删除" cancelText="不删除">
  287. <Button style={{marginRight:'10px',color:'#ffffff',background:'#f00',border:'none'}}>删除</Button>
  288. </Popconfirm>
  289. </div>
  290. }
  291. }
  292. ],
  293. businessIntentionList:[{
  294. title: '意向时间',
  295. dataIndex: 'createTime',
  296. key: 'createTime'
  297. },{
  298. title: '客户名称',
  299. dataIndex: 'identifyName',
  300. key: 'identifyName'
  301. },{
  302. title: '业务名',
  303. dataIndex: 'businessName',
  304. key: 'businessName'
  305. }
  306. ,{
  307. title: '营销员',
  308. dataIndex: 'adminName',
  309. key: 'adminName'
  310. },{
  311. title: '业务意向进度',
  312. dataIndex: 'followSituation',
  313. key: 'followSituation',
  314. render:text=>{return getfllowSituation(text)}
  315. },{
  316. title: '客户状态',
  317. dataIndex: 'customerStatus',
  318. key: 'customerStatus' ,
  319. render:text=>{return getcustomerStatue(text)}
  320. },{
  321. title: '操作',
  322. dataIndex: 'ooo',
  323. key: 'ooo',
  324. render:(text,record) =>{return (<Button onClick={(e)=>{this.businessIntentionDetails(record)}}>查看</Button>)}
  325. }
  326. ],
  327. businessFollowList:[
  328. {
  329. title: '跟进时间',
  330. dataIndex: 'followTime',
  331. key: 'followTime',
  332. }, {
  333. title: '营销员',
  334. dataIndex: 'adminName',
  335. key: 'adminName',
  336. }, {
  337. title: '业务意向进度',
  338. dataIndex: 'followSituation',
  339. key: 'followSituation',
  340. render:text=>{return getfllowSituation(text)}
  341. }, {
  342. title: '客户状态',
  343. dataIndex: 'customerStatus',
  344. key: 'customerStatus',
  345. render:text=>{return getcustomerStatue(text)}
  346. },
  347. {
  348. title: '拜访方式',
  349. dataIndex: 'contactType',
  350. key:'contactType',
  351. render:text=>{return getContactType(text)}
  352. }, {
  353. title: '联系人',
  354. dataIndex: 'contacts',
  355. key: 'contacts',
  356. },
  357. {
  358. title: '联系电话',
  359. dataIndex: 'contactMobile',
  360. key:'contactMobile',
  361. },{
  362. title: '操作',
  363. dataIndex: 'ooo',
  364. key: 'ooo',
  365. render:(text,record) =>{return (<Button onClick={(e)=>{this.businessFollowDetails(record)}}>查看</Button>)}
  366. }
  367. ],
  368. visitsList:[{
  369. title: '拜访时间',
  370. dataIndex: 'followTime',
  371. key: 'followTime'
  372. },{
  373. title: '客户名称',
  374. dataIndex: 'identifyName',
  375. key: 'identifyName'
  376. },{
  377. title: '拜访方式',
  378. dataIndex: 'contactType',
  379. key: 'contactType',
  380. render:text=>{return getContactType(text)}
  381. }
  382. ,{
  383. title: '联系人',
  384. dataIndex: 'contacts',
  385. key: 'contacts'
  386. },{
  387. title: '联系电话',
  388. dataIndex: 'contactMobile',
  389. key: 'contactMobile'
  390. },{
  391. title: '拜访人',
  392. dataIndex: 'adminName',
  393. key: 'adminName'
  394. },{
  395. title: '拜访说明',
  396. dataIndex: 'result',
  397. key: 'result'
  398. },{
  399. title: '操作',
  400. dataIndex: 'ttt',
  401. key: 'ttt',
  402. render: (text, record, index) => {
  403. return <div>
  404. <Popconfirm title="是否删除?" onConfirm={(e)=>{this.visitDelet(record)}} okText="删除" cancelText="不删除">
  405. <Button style={{marginRight:'10px',color:'#ffffff',background:'#f00',border:'none'}} onClick={(e)=>{e.stopPropagation()}}>删除</Button>
  406. </Popconfirm>
  407. </div>
  408. }
  409. }
  410. ],
  411. ContactsLists:[{
  412. title: '姓名',
  413. dataIndex: 'name',
  414. key: 'name',
  415. render: (text, record, index) => {
  416. return <Input value={record.name} placeholder="姓名(必填项)" key={record.id} required="required"
  417. onChange={(e) => { record.name = e.target.value;
  418. this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  419. }
  420. },{
  421. title: '联系人部门',
  422. dataIndex: 'depatrment',
  423. key: 'depatrment',
  424. render: (text, record, index) => {
  425. return <Input value={record.depatrment} placeholder="联系人部门" key={record.id}
  426. onChange={(e) => { record.depatrment = e.target.value; this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  427. }
  428. },{
  429. title: '联系人职务',
  430. dataIndex: 'position',
  431. key: 'position',
  432. render: (text, record, index) => {
  433. return <Input value={record.position} placeholder="联系人职务" key={record.id}
  434. onChange={(e) => { record.position = e.target.value; this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  435. }
  436. },{
  437. title: '手机号码',
  438. dataIndex: 'mobile',
  439. key: 'mobile',
  440. render: (text, record, index) => {
  441. return <Input value={record.mobile} placeholder="手机号码(必填项)" key={record.id} required="required"
  442. onChange={(e) => { record.mobile = e.target.value; this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  443. }
  444. },{
  445. title: '微信',
  446. dataIndex: 'wechat',
  447. key: 'wechat',
  448. render: (text, record, index) => {
  449. return <Input value={record.wechat} placeholder="微信" key={record.id}
  450. onChange={(e) => { record.wechat = e.target.value; this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  451. }
  452. },{
  453. title: '联系人QQ',
  454. dataIndex: 'qq',
  455. key: 'qq',
  456. render: (text, record, index) => {
  457. return <Input value={record.qq} placeholder="联系人QQ" key={record.id}
  458. onChange={(e) => { record.qq = e.target.value; this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  459. }
  460. },{
  461. title: '电子邮箱',
  462. dataIndex: 'email',
  463. key: 'email',
  464. render: (text, record, index) => {
  465. return <Input value={record.email} placeholder="电子邮箱" key={record.id}
  466. onChange={(e) => { record.email = e.target.value; this.setState({ contactList: this.state.contactList }); }} style={{width:'120px'}}/>
  467. }
  468. },
  469. {
  470. title: '操作',
  471. dataIndex: 'dels',
  472. key: 'dels',
  473. render: (text, record, index) => {
  474. return <div>
  475. <Popconfirm title="是否删除?" onConfirm={(e)=>{this.confirmDelet(record)}} okText="删除" cancelText="不删除">
  476. <Button style={{marginRight:'10px',color:'#ffffff',background:'#f00',border:'none'}}>删除</Button>
  477. </Popconfirm>
  478. </div>
  479. }
  480. }
  481. ],
  482. columnsman:[{
  483. title: '姓名',
  484. dataIndex: 'name',
  485. key: 'name'
  486. },{
  487. title: '手机号码',
  488. dataIndex: 'mobile',
  489. key: 'mobile'
  490. }
  491. ],
  492. columns: [
  493. {
  494. title: '客户名称',
  495. dataIndex: 'name',
  496. key: 'name',
  497. }, {
  498. title: '客户类型',
  499. dataIndex: 'type',
  500. key: 'type',
  501. render: text => { return getcustomerTyp(text) }
  502. }, {
  503. title: '地区',
  504. dataIndex: 'locationProvince',
  505. key: 'locationProvince',
  506. }, {
  507. title: '联系人',
  508. dataIndex: 'contacts',
  509. key: 'contacts',
  510. },
  511. {
  512. title: '联系电话',
  513. dataIndex: 'contactMobile',
  514. key:'contactMobile',
  515. },
  516. {
  517. title: '行业',
  518. dataIndex: 'industry',
  519. key: 'industry',
  520. },
  521. {
  522. title: '社会性质',
  523. dataIndex: 'societyTag',
  524. key: 'societyTag',
  525. render: text => { return getSocialAttribute(text) }
  526. },
  527. {
  528. title: '创建时间',
  529. dataIndex: 'createTime',
  530. key: 'createTime',
  531. },
  532. {
  533. title: '业务认证',
  534. dataIndex: 'serviceCertification',
  535. key: 'serviceCertification',
  536. render: text => { return getCertification(text) }
  537. },
  538. {
  539. title: '实名认证',
  540. dataIndex: 'userCertification',
  541. key: 'userCertification',
  542. render: text => { return getCertification(text) }
  543. },
  544. {
  545. title: '是否高新',
  546. dataIndex: 'highTechZone',
  547. key: 'highTechZone',
  548. render: text => { return getWhether(text) }
  549. },{
  550. title: '是否上市',
  551. dataIndex: 'listed',
  552. key: 'listed',
  553. render: text => { return getWhether(text) }
  554. },
  555. {
  556. title: '是否国际',
  557. dataIndex: 'international',
  558. key: 'international',
  559. render: text => { return getWhether(text) }
  560. },
  561. {
  562. title: '会员等级',
  563. dataIndex: 'lvl',
  564. key: 'lvl',
  565. render:text => {return getLvl(text)}
  566. },
  567. {
  568. title: '会员状态',
  569. dataIndex: 'currentMemberStatus',
  570. key: 'currentMemberStatus',
  571. render:text => {return getCurrentMember(text)}
  572. },
  573. {
  574. title: '账户状态',
  575. dataIndex: 'status',
  576. key: 'status',
  577. render:text => {return getStatuslist(text)}
  578. },
  579. {
  580. title: '操作',
  581. dataIndex: 'abc',
  582. key: 'abc',
  583. render: (text, record, index) => {
  584. return <div>
  585. <Button onClick={(e) =>{ e.stopPropagation(), this.visit(record)}} type="primary">拜访</Button>
  586. </div>
  587. }
  588. }
  589. ],
  590. data:[],
  591. dataman:[],
  592. dataSource: [],
  593. visitArrList:[],
  594. searchTime: [,]
  595. };
  596. },
  597. //更多操作
  598. ModalOperation(){
  599. this.setState({
  600. visible: true,
  601. });
  602. },
  603. //tab2获取联系人详情
  604. contactLists(ids) {
  605. this.setState({
  606. loading: true
  607. });
  608. $.ajax({
  609. method: "get",
  610. dataType: "json",
  611. crossDomain: false,
  612. url:globalConfig.context + '/api/admin/customer/findCustomerContacts',
  613. data: {
  614. uid:ids , //名称1
  615. },
  616. success: function (data) {
  617. let theArr = [];
  618. if (data.error.length || data.data.list=="") {
  619. if (data.error && data.error.length) {
  620. message.warning(data.error[0].message);
  621. };
  622. } else {
  623. for (let i = 0; i < data.data.length; i++) {
  624. let thisdata = data.data[i];
  625. theArr.push({
  626. id:thisdata.id,
  627. name:thisdata.name,
  628. mobile:thisdata.mobile,
  629. email:thisdata.email,
  630. qq:thisdata.qq,
  631. wechat:thisdata.wechat,
  632. depatrment:thisdata.depatrment,
  633. position:thisdata.position,
  634. });
  635. };
  636. };
  637. this.setState({
  638. contactList: theArr,
  639. });
  640. }.bind(this),
  641. }).always(function () {
  642. this.setState({
  643. loading: false
  644. });
  645. }.bind(this));
  646. },
  647. //刷新新增拜访记录刷新
  648. deletelist(e){
  649. $.ajax({
  650. method: "get",
  651. dataType: "json",
  652. url:globalConfig.context + '/api/admin/customer/toAddFollow',
  653. data: {
  654. uid: e,
  655. },
  656. success: function (data) {
  657. let listArr=[];
  658. let thedata=data.data;
  659. if (!thedata) {
  660. if (data.error && data.error.length) {
  661. message.warning(data.error[0].message);
  662. };
  663. thedata = {};
  664. };
  665. for (let i = 0; i < data.data.userBusinessList.length; i++) {
  666. let thisdata = data.data.userBusinessList[i];
  667. listArr.push({
  668. id: thisdata.id,
  669. businessGlossoryId:String(thisdata.businessGlossoryId),
  670. followSituation:String(thisdata.followSituation),
  671. customerStatus:String(thisdata.customerStatus),
  672. remarks:thisdata.remarks,
  673. });
  674. };
  675. this.setState({
  676. contacts:thedata.contacts,
  677. uid:thedata.uid,
  678. data:listArr,
  679. identifyName:thedata.identifyName,
  680. followTime:thedata.followTime,
  681. businessGlossoryId:thedata.businessGlossoryId,
  682. followSituation:thedata.followSituation,
  683. customerStatus:thedata.customerStatus,
  684. remarks:thedata.remarks,
  685. });
  686. }.bind(this),
  687. }).always(function () {
  688. this.setState({
  689. loading: false
  690. });
  691. }.bind(this));
  692. },
  693. //进入新增拜访记录
  694. visit(e){
  695. this.state.keys=true;
  696. this.getNewWoman(e.id);
  697. this.deletelist(e.id)
  698. this.setState({
  699. result:'',
  700. contactType:undefined,
  701. visitModul:true,
  702. loading: true
  703. });
  704. },
  705. //拜访记录删除
  706. visitDelet(e){
  707. this.setState({
  708. loading:true
  709. });
  710. $.ajax({
  711. method: "get",
  712. dataType: "json",
  713. crossDomain: false,
  714. url: globalConfig.context + "/api/admin/customer/deleteFollow",
  715. data: {
  716. followId: e.followId,//删除的ID
  717. }
  718. }).done(function (data) {
  719. if (!data.error.length) {
  720. message.success('删除成功!');
  721. this.setState({
  722. loading: false,
  723. });
  724. } else {
  725. message.warning(data.error[0].message);
  726. };
  727. this.loadVisit();
  728. }.bind(this));
  729. },
  730. //进入修改拜访记录
  731. visitModify(e){
  732. this.setState({
  733. visitModul:true,
  734. loading: true
  735. });
  736. $.ajax({
  737. method: "get",
  738. dataType: "json",
  739. url:globalConfig.context + '/api/admin/customer/toUpdateFollow',
  740. data: {
  741. followId: e,
  742. },
  743. success: function (data) {
  744. let theArr = [];
  745. let thedata=data.data;
  746. if (!thedata) {
  747. if (data.error && data.error.length) {
  748. message.warning(data.error[0].message);
  749. };
  750. thedata = {};
  751. };
  752. for (let i = 0; i < data.data.userBusinessList.length; i++) {
  753. let thisdata = data.data.userBusinessList[i];
  754. theArr.push({
  755. id: thisdata.id,
  756. businessGlossoryId:String(thisdata.businessGlossoryId),
  757. followSituation:String(thisdata.followSituation),
  758. customerStatus:String(thisdata.customerStatus),
  759. remarks:thisdata.remarks,
  760. });
  761. };
  762. this.setState({
  763. followIds:thedata.followId,
  764. contacts:thedata.contacts,
  765. uid:thedata.uid,
  766. data:theArr,
  767. nub:thedata.contactMobile,
  768. result:thedata.result,
  769. contactType:parseInt(thedata.contactType),
  770. identifyName:thedata.identifyName,
  771. followTime:thedata.followTime,
  772. businessGlossoryId:thedata.businessGlossoryId,
  773. followSituation:thedata.followSituation,
  774. customerStatus:thedata.customerStatus,
  775. adminName:thedata.adminName,
  776. });
  777. }.bind(this),
  778. }).always(function () {
  779. this.setState({
  780. loading: false
  781. });
  782. }.bind(this));
  783. },
  784. //转为公共客户
  785. changeRow() {
  786. let deletedIds;
  787. for (let idx = 0; idx < this.state.selectedRows.length; idx++) {
  788. let rowItem = this.state.selectedRows[idx];
  789. if (rowItem.id) {
  790. deletedIds=rowItem.id;
  791. };
  792. };
  793. this.setState({
  794. selectedRowKeys: [],
  795. });
  796. $.ajax({
  797. method: "get",
  798. dataType: "json",
  799. crossDomain: false,
  800. url: globalConfig.context + "/api/admin/customer/transferToPublic",
  801. data: {
  802. uid: deletedIds,
  803. }
  804. }).done(function (data) {
  805. if (!data.error.length) {
  806. message.success('已转为公共客户!');
  807. this.setState({
  808. loading: false,
  809. });
  810. } else {
  811. message.warning(data.error[0].message);
  812. };
  813. this.loadData();
  814. }.bind(this));
  815. },
  816. //列表删除功能
  817. delectRow() {
  818. let deletedIds;
  819. for (let idx = 0; idx < this.state.selectedRows.length; idx++) {
  820. let rowItem = this.state.selectedRows[idx];
  821. if (rowItem.id) {
  822. deletedIds=rowItem.id;
  823. };
  824. };
  825. this.setState({
  826. loading:true,
  827. selectedRowKeys: [],
  828. });
  829. $.ajax({
  830. method: "get",
  831. dataType: "json",
  832. crossDomain: false,
  833. url: globalConfig.context + "/api/admin/customer/deleteCustomer",
  834. data: {
  835. uid: deletedIds,//删除的ID
  836. }
  837. }).done(function (data) {
  838. if (!data.error.length) {
  839. message.success('删除成功!');
  840. this.setState({
  841. loading: false,
  842. });
  843. } else {
  844. message.warning(data.error[0].message);
  845. };
  846. this.loadData();
  847. }.bind(this));
  848. },
  849. getOrgCodeUrl(e) {
  850. this.setState({ orgCodeUrl: e });
  851. },
  852. getCompanyLogoUrl(e) {
  853. this.setState({ companyLogoUrl: e });
  854. },
  855. componentWillMount(){
  856. //城市
  857. let Province = [];
  858. provinceList.map(function (item) {
  859. var id= String(item.id)
  860. Province.push(
  861. <Select.Option value={id} key={item.name}>{item.name}</Select.Option>
  862. )
  863. });
  864. //行业
  865. let intentionalArr = [];
  866. industry.map(function (item) {
  867. intentionalArr.push(
  868. <Select.Option value={item.value} key={item.key}>{item.key}</Select.Option>
  869. )
  870. });
  871. //会员等级
  872. let lvlArr = [];
  873. lvl.map(function (item) {
  874. lvlArr.push(
  875. <Select.Option value={item.value} key={item.key}>{item.key}</Select.Option>
  876. )
  877. });
  878. //会员状态customerStatus
  879. let currentMemberArr = [];
  880. currentMember.map(function (item) {
  881. currentMemberArr.push(
  882. <Select.Option value={item.value} key={item.key}>{item.key}</Select.Option>
  883. )
  884. });
  885. this.state.Provinces = Province;
  886. this.state.intentionalOption = intentionalArr;
  887. this.state.lvlArrOption = lvlArr;
  888. this.state.currentMemberArrOption = currentMemberArr;
  889. this.loadData();
  890. },
  891. addClick() {
  892. this.state.RowData={};
  893. this.setState({
  894. showDesc: true,
  895. });
  896. },
  897. newmodal(e){
  898. if(e){
  899. this.tableRowClick();
  900. }
  901. },
  902. closeDesc(e, s) {
  903. this.state.showDesc = e;
  904. if (s) {
  905. this.loadData();
  906. };
  907. },
  908. search() {
  909. this.loadData();
  910. },
  911. reset() {
  912. this.state.isMemberSearch=undefined;
  913. this.state.internationalSearch=undefined;
  914. this.state.typeSearch=undefined; //名称1
  915. this.state.nameSearch='';
  916. this.state.addressSearch=[];
  917. this.state.provinceSearch=undefined;
  918. this.state.citySearch=undefined;
  919. this.state.statusSearch=undefined;
  920. this.state.contactsSearch=undefined;
  921. this.state.contactMobileSearch=undefined;
  922. this.state.industrySearch=undefined;
  923. this.state.serviceCertificationSearch=undefined;
  924. this.state.userCertificationSearch=undefined;
  925. this.state.currentMemberStatusSearch=undefined;
  926. this.state.lvlSearch=undefined;
  927. this.state.listedSearch=undefined;
  928. this.state.highTechZoneSearch=undefined;
  929. this.state.releaseDate[0]=undefined;
  930. this.state.releaseDate[1]=undefined;
  931. this.state.societyTagSearch=undefined;
  932. this.loadData();
  933. },
  934. searchSwitch() {
  935. this.setState({
  936. searchMore: !this.state.searchMore
  937. });
  938. },
  939. //详情保存函数
  940. detailsSubmint(){
  941. this.setState({
  942. modal5Visible:false,
  943. })
  944. },
  945. //整行点击
  946. tableRowClick(record, index) {
  947. this.state.RowData = record;
  948. this.detailsModalOk(record);
  949. this.loadInformation(record.id);
  950. this.httpAccount(record.id);
  951. this.loadBfVisit(1,record.id);
  952. this.BusinessList(1,record.id);
  953. this.contactLists(record.id);
  954. this.setState({
  955. selectedRowKeys:[],
  956. rowId:record.id,
  957. })
  958. },
  959. VisitRowClick(record, index) {
  960. this.state.keys=false;
  961. this.state.RowData = record;
  962. this.visitModify(record.followId);
  963. this.setState({
  964. selectedRowKeys:[],
  965. delectId:record.followId,
  966. })
  967. },
  968. //基本信息提交
  969. newSubmit(e){
  970. e.preventDefault();
  971. if(!this.state.industry){
  972. message.warning('请选择行业');
  973. return false;
  974. };
  975. if(!this.state.societyTag){
  976. message.warning('请选择社会性质');
  977. return false;
  978. };
  979. if(!this.state.ProvinceCity[1]){
  980. message.warning('请选择地区');
  981. return false;
  982. };
  983. this.setState({
  984. selectedRowKeys: [],
  985. });
  986. this.props.form.validateFields((err, values) => {
  987. let theorgCodeUrl = [];
  988. if (this.state.orgCodeUrl.length) {
  989. let picArr = [];
  990. this.state.orgCodeUrl.map(function (item) {
  991. picArr.push(item.response.data);
  992. });
  993. theorgCodeUrl = picArr.join(",");
  994. };
  995. let thecompanyLogoUrl = [];
  996. if (this.state.companyLogoUrl.length) {
  997. let picArr = [];
  998. this.state.companyLogoUrl.map(function (item) {
  999. picArr.push(item.response.data);
  1000. });
  1001. thecompanyLogoUrl = picArr.join(",");
  1002. };
  1003. if (!err) {
  1004. this.setState({
  1005. loading: true
  1006. });
  1007. $.ajax({
  1008. method: "post",
  1009. dataType: "json",
  1010. url:globalConfig.context + '/api/admin/customer/updateOrganizationCustomer',
  1011. data: {
  1012. id:this.state.InformationId,
  1013. uid: this.state.InformationUid,
  1014. societyTag:this.state.societyTag,
  1015. introduction:this.state.introduction,
  1016. unitName:this.state.unitName,
  1017. industry:this.state.industry,
  1018. locationProvince:(this.state.ProvinceCity)[0],//省-
  1019. locationCity:(this.state.ProvinceCity)[1],//市
  1020. locationArea:(this.state.ProvinceCity)[2],//区
  1021. postalAddress:this.state.postalAddress,
  1022. contactsFixedTel:this.state.contactsFixedTel,
  1023. contactsFax:this.state.contactsFax,
  1024. registeredCapital:this.state.registeredCapital,
  1025. enterpriseScale:this.state.enterpriseScale,
  1026. legalPerson:this.state.legalPerson,
  1027. legalPersonIdCard:this.state.legalPersonIdCard,
  1028. legalPersonTel:this.state.legalPersonTel,
  1029. legalPersonEmail:this.state.legalPersonEmail,
  1030. highTechZone:this.state.highTechZone,
  1031. listed:this.state.listed,
  1032. international:this.state.international,
  1033. orgCode:this.state.orgCode,
  1034. businessScope:this.state.businessScope,
  1035. introduction:this.state.introduction,
  1036. companyLogoUrl:thecompanyLogoUrl,
  1037. orgCodeUrl:theorgCodeUrl,
  1038. }
  1039. }).done(function (data) {
  1040. this.setState({
  1041. loading: false
  1042. });
  1043. if (!data.error.length) {
  1044. message.success('保存成功!');
  1045. this.detailsModal()
  1046. this.loadData();
  1047. } else {
  1048. message.warning(data.error[0].message);
  1049. }
  1050. }.bind(this));
  1051. }
  1052. })
  1053. },
  1054. //点击整行查看详情
  1055. //查看基本详情基本信息
  1056. loadInformation(record){
  1057. $.ajax({
  1058. method: "get",
  1059. dataType: "json",
  1060. url: globalConfig.context + '/api/admin/customer/findOrganizationCustomerDetail',
  1061. data: {
  1062. uid: record
  1063. },
  1064. success: function (data) {
  1065. let thisData = data.data;
  1066. if (!thisData) {
  1067. if (data.error && data.error.length) {
  1068. message.warning(data.error[0].message);
  1069. };
  1070. thisData = {};
  1071. };
  1072. let ProvinceCityArr=[];
  1073. let ProvinceS=thisData.locationProvince; //getprovince
  1074. let citys=thisData.locationCity;
  1075. let Areas=thisData.locationArea;
  1076. ProvinceCityArr.push(ProvinceS,citys,Areas);
  1077. this.setState({
  1078. InformationId:thisData.id,
  1079. InformationUid:thisData.uid,
  1080. unitName:thisData.unitName,
  1081. listed:thisData.listed,
  1082. highTechZone:thisData.highTechZone,
  1083. orgCodeUrl: thisData.orgCodeUrl ? splitUrl(thisData.orgCodeUrl, ',', globalConfig.avatarHost + '/upload') : [],
  1084. companyLogoUrl: thisData.companyLogoUrl ? splitUrl(thisData.companyLogoUrl, ',', globalConfig.avatarHost + '/upload') : [],
  1085. dataInformation:thisData,
  1086. ProvinceCity:ProvinceCityArr,
  1087. industry:String(thisData.industry)=='null'?undefined:String(thisData.industry),
  1088. international:thisData.international,
  1089. societyTag:thisData.societyTag,
  1090. introduction:thisData.introduction,
  1091. postalAddress:thisData.postalAddress,
  1092. contactsFixedTel:thisData.contactsFixedTel,
  1093. contactsFax:thisData.contactsFax,
  1094. registeredCapital:thisData.registeredCapital,
  1095. enterpriseScale:thisData.enterpriseScale,
  1096. legalPerson:thisData.legalPerson,
  1097. legalPersonIdCard:thisData.legalPersonIdCard,
  1098. legalPersonTel:thisData.legalPersonTel,
  1099. legalPersonEmail:thisData.legalPersonEmail,
  1100. businessScope:thisData.businessScope,
  1101. orgCode:thisData.orgCode,
  1102. });
  1103. }.bind(this),
  1104. }).always(function () {
  1105. this.setState({
  1106. loading: false
  1107. });
  1108. }.bind(this));
  1109. },
  1110. //tab3账户信息请求数据
  1111. httpAccount(record){
  1112. this.RowClick;
  1113. $.ajax({
  1114. method: "get",
  1115. dataType: "json",
  1116. crossDomain: false,
  1117. url: globalConfig.context + '/api/admin/customer/findUserAccountDetail',
  1118. data: {
  1119. uid: record
  1120. },
  1121. success: function (data) {
  1122. let thisData = data.data;
  1123. if (!thisData) {
  1124. if (data.error && data.error.length) {
  1125. message.warning(data.error[0].message);
  1126. };
  1127. thisData = {};
  1128. };
  1129. let sourcecustomer=''
  1130. switch(String(thisData.source)){
  1131. case '0':
  1132. sourcecustomer='注册客户'
  1133. break;
  1134. case '1':
  1135. sourcecustomer='录入客户'
  1136. break;
  1137. }
  1138. this.setState({
  1139. Accountuid:thisData.id,
  1140. mobile:thisData.mobile,
  1141. nickname:thisData.nickname,
  1142. email:thisData.email,
  1143. type:getcustomerTyp(String(thisData.type)),
  1144. source:sourcecustomer,
  1145. isMember:thisData.isMember,
  1146. currentMemberStatus:String(thisData.currentMemberStatus),
  1147. lvl:String(thisData.lvl),
  1148. serviceCertification:thisData.serviceCertification,
  1149. status:String(thisData.status),
  1150. userCertification:thisData.userCertification,
  1151. createTimes:thisData.createTimes,
  1152. });
  1153. }.bind(this),
  1154. }).always(function () {
  1155. this.setState({
  1156. loading: false
  1157. });
  1158. }.bind(this));
  1159. },
  1160. detailsModalOk(e) {
  1161. this.setState({ modal5Visible:true });//需要一个请求数据
  1162. },
  1163. //点击消失函数
  1164. detailsModal(e) {
  1165. this.setState({
  1166. modal5Visible:false
  1167. });
  1168. },
  1169. //拜访modul函数
  1170. visitOk(e) {
  1171. this.setState({
  1172. visitModul:false
  1173. });
  1174. this.loadVisit()
  1175. },
  1176. visitCancel(e) {
  1177. this.setState({
  1178. visitModul:false
  1179. });
  1180. },
  1181. //拜访保存函数
  1182. visitSubmit(e){
  1183. e.preventDefault();
  1184. let GlossoryId;
  1185. this.state.data.map(function(item){
  1186. if(!item.businessGlossoryId){
  1187. GlossoryId=true
  1188. }
  1189. })
  1190. if(this.state.contactType==undefined){
  1191. message.warning('请选择拜访方式')
  1192. return false;
  1193. };
  1194. if(this.state.keys){
  1195. if(this.state.lastName==undefined){
  1196. message.warning('请选择联系人')
  1197. return false;
  1198. }
  1199. };
  1200. if(GlossoryId){
  1201. message.warning("请选择业务名称!")
  1202. return false;
  1203. };
  1204. this.setState({
  1205. loading: true
  1206. });
  1207. let contactsId='';
  1208. if(this.state.keys){
  1209. let conts=this.state.lastName;
  1210. contactsId= this.state.contactsIdArr[conts].id;
  1211. }
  1212. //新增
  1213. $.ajax({
  1214. method: "post",
  1215. dataType: "json",
  1216. url:this.state.keys?globalConfig.context + '/api/admin/customer/addFollow':globalConfig.context + '/api/admin/customer/updateFollow',
  1217. data: this.state.keys?{
  1218. userBusinessList:JSON.stringify(this.state.data),
  1219. uid: this.state.uid,
  1220. ocbId:contactsId ,
  1221. contactType:this.state.contactType,
  1222. result: this.state.result,
  1223. followTime: this.state.followTime,
  1224. }:{
  1225. followId:this.state.followIds,
  1226. userBusinessList:JSON.stringify(this.state.data),
  1227. uid: this.state.uid,
  1228. contactType:this.state.contactType,
  1229. result: this.state.result,
  1230. followTime: this.state.followTime,
  1231. }
  1232. }).done(function (data) {
  1233. this.setState({
  1234. loading: false
  1235. });
  1236. if (!data.error.length) {
  1237. message.success('保存成功!');
  1238. this.loadVisit(); //
  1239. this.loadData();
  1240. this.visitCancel();
  1241. } else {
  1242. message.warning(data.error[0].message);
  1243. }
  1244. }.bind(this));
  1245. },
  1246. //当选择联系人的列表变化时,则执行
  1247. hundleName(e){
  1248. let changNub=this.state.telNum[e];
  1249. this.setState({
  1250. nub:this.state.telNum[e],
  1251. lastName: e,
  1252. });
  1253. },
  1254. //添加新业务及单位客户详情新增
  1255. addNew() {
  1256. this.state.data.push({
  1257. customerStatus:undefined,
  1258. businessGlossoryId:undefined,
  1259. followSituation:undefined,
  1260. remarks: '',
  1261. });
  1262. this.setState({
  1263. data: this.state.data
  1264. })
  1265. },
  1266. //tab2新增联系人
  1267. addcontact() {
  1268. this.state.contactList.push({
  1269. id:null,
  1270. name: '',
  1271. mobile: '',
  1272. email: '',
  1273. qq: '',
  1274. wechat: '',
  1275. depatrment: '',
  1276. position: '',
  1277. });
  1278. this.setState({
  1279. contactList: this.state.contactList
  1280. })
  1281. },
  1282. //tab5进入修改时
  1283. //进入修改时
  1284. listFollowUp(e){
  1285. $.ajax({
  1286. method: "get",
  1287. dataType: "json",
  1288. crossDomain: false,
  1289. url: globalConfig.context + "/api/admin/customer/toUpdateFollowOneBusiness",
  1290. data:{
  1291. ufbId:e
  1292. },
  1293. success: function (data) {
  1294. let thedata=data.data;
  1295. if (!thedata) {
  1296. if (data.error && data.error.length) {
  1297. message.warning(data.error[0].message);
  1298. };
  1299. thedata = {};
  1300. };
  1301. this.setState({
  1302. businessGlossoryIds:thedata.businessGlossoryId,
  1303. followSituations:thedata.followSituation,
  1304. customerStatuss:thedata.customerStatus,
  1305. followTimes:thedata.followTime,
  1306. createTimes:thedata.createTime,
  1307. identifyNames:thedata.identifyName,
  1308. contactTypes:parseInt(thedata.contactType),
  1309. results:thedata.result,
  1310. remarkss:thedata.remarks,
  1311. adminNames:thedata.adminName,
  1312. contactss:thedata.contacts,
  1313. contactMobiles:thedata.contactMobile,
  1314. ufbId:thedata.ufbId,
  1315. followIds:thedata.followId,
  1316. });
  1317. }.bind(this),
  1318. }).always(function () {
  1319. this.setState({
  1320. loading: false
  1321. });
  1322. }.bind(this));
  1323. },
  1324. //修改密码Modul
  1325. modifyPassworld(){
  1326. this.setState({
  1327. passworldModul:true
  1328. });
  1329. },
  1330. passworldOk(e) {
  1331. this.setState({
  1332. passworldModul:false
  1333. });
  1334. },
  1335. passworldCancel(e) {
  1336. this.setState({
  1337. passworldModul:false
  1338. });
  1339. },
  1340. //修改密码保存
  1341. passworldSubmit(e){
  1342. e.preventDefault();
  1343. this.passworldCancel()
  1344. },
  1345. //新增联系人
  1346. addcontactModulOK(){
  1347. this.setState({
  1348. addcontactModul:false
  1349. });
  1350. },
  1351. addcontactModulcancel(){
  1352. this.setState({
  1353. addcontactModul:false
  1354. });
  1355. },
  1356. //点击新增详情
  1357. newContacts(){
  1358. this.setState({
  1359. uids:this.state.uid,
  1360. addcontactModul:true
  1361. });
  1362. },
  1363. //新增联系人保存函数
  1364. submitcontactman(){
  1365. this.setState({
  1366. loading:true
  1367. })
  1368. $.ajax({
  1369. method: "post",
  1370. dataType: "json",
  1371. crossDomain: false,
  1372. url: globalConfig.context + "/api/admin/customer/addOneContact",
  1373. data:{
  1374. uid:this.state.uids,
  1375. name:this.state.newname,
  1376. mobile:this.state.newmobile,
  1377. email:this.state.newemail,
  1378. wechat:this.state.newwechat,
  1379. depatrment:this.state.newdepatrment,
  1380. position:this.state.newposition,
  1381. sex:this.state.newsex,
  1382. qq:this.state.newqq
  1383. },
  1384. success: function (data) {
  1385. if (!data.error.length) {
  1386. this.addcontactModulOK()
  1387. this.getNewWoman(this.state.uids)
  1388. this.setState({
  1389. loading: false,
  1390. })
  1391. } else {
  1392. message.warning(data.error[0].message);
  1393. };
  1394. }.bind(this)
  1395. });
  1396. },
  1397. //获取联系人下拉框
  1398. getNewWoman(ids) {
  1399. this.state.data = []
  1400. $.ajax({
  1401. method: "get",
  1402. dataType: "json",
  1403. crossDomain: false,
  1404. url: globalConfig.context + "/api/admin/customer/findCustomerContacts",
  1405. data:{
  1406. uid:ids,
  1407. },
  1408. success: function (data) {
  1409. let theArr = [];
  1410. let thedata=data.data;
  1411. if (!thedata) {
  1412. if (data.error && data.error.length) {
  1413. message.warning(data.error[0].message);
  1414. };
  1415. thedata = {};
  1416. };
  1417. var telNum=[];
  1418. var contactIds=[];
  1419. thedata.map(function (item,index) {
  1420. contactIds.push(thedata[index].id);
  1421. telNum.push(thedata[index].mobile);
  1422. });
  1423. for (let item in data.data) {
  1424. let theData = data.data[item];
  1425. theArr.push(
  1426. <Select.Option value={item} key={theData.name}>{theData.name}</Select.Option>
  1427. );
  1428. };
  1429. this.setState({
  1430. contactsIdArr:thedata,
  1431. telNum:telNum,
  1432. orderStatusOption: theArr,
  1433. });
  1434. }.bind(this),
  1435. }).always(function () {
  1436. this.setState({
  1437. deletId:ids,
  1438. loading: false
  1439. });
  1440. }.bind(this));
  1441. },
  1442. //拜访意向服务列表单个删除
  1443. intentionDelet(e,index){
  1444. if(!this.state.keys){
  1445. let detId=this.state.followIds;
  1446. if(e.id){
  1447. this.setState({
  1448. selectedRowKeys: [],
  1449. });
  1450. $.ajax({
  1451. method: "get",
  1452. dataType: "json",
  1453. crossDomain: false,
  1454. url: globalConfig.context + "/api/admin/customer/deleteFollowOneBusiness",
  1455. data: {
  1456. ufbId:e.id
  1457. }
  1458. }).done(function (data) {
  1459. if (!data.error.length) {
  1460. message.success('删除成功');
  1461. this.setState({
  1462. loading: false,
  1463. });
  1464. } else {
  1465. message.warning(data.error[0].message);
  1466. };
  1467. this.visitModify(detId);
  1468. }.bind(this));
  1469. }else{
  1470. this.visitModify(detId);
  1471. }
  1472. }else{
  1473. let deteluserBusinessList=(this.state.data).splice(index,1)
  1474. this.setState({
  1475. selectedRowKeys: [],
  1476. });
  1477. }
  1478. },
  1479. //tab5意向业务
  1480. //意向业务查看列表单个详情
  1481. businessIntentionDetails(e){
  1482. $.ajax({
  1483. method: "get",
  1484. dataType: "json",
  1485. crossDomain: false,
  1486. url: globalConfig.context + '/api/admin/customer/toUpdateBusiness',
  1487. data: {
  1488. businessId: e.businessId
  1489. },
  1490. success: function (data) {
  1491. let thisData = data.data;
  1492. if (!thisData) {
  1493. if (data.error && data.error.length) {
  1494. message.warning(data.error[0].message);
  1495. };
  1496. thisData = {};
  1497. };
  1498. this.setState({
  1499. businessGlossoryId:thisData.businessGlossoryId,
  1500. identifyName:thisData.identifyName,
  1501. uid:thisData.uid,
  1502. businessId:thisData.businessId,
  1503. followSituation:thisData.followSituation,
  1504. customerStatus:thisData.customerStatus,
  1505. createTime:thisData.createTime,
  1506. followTime:thisData.followTime,
  1507. adminName:thisData.adminName,
  1508. remarks:thisData.remarks,
  1509. result:thisData.result,
  1510. });
  1511. }.bind(this),
  1512. }).always(function () {
  1513. this.loadVisit();
  1514. this.setState({
  1515. loading: false
  1516. });
  1517. }.bind(this));
  1518. this.setState({
  1519. businessModul:true
  1520. })
  1521. },
  1522. //查看跟进记录列表
  1523. loadVisit(pageNo) {
  1524. this.setState({
  1525. loading: true
  1526. });
  1527. $.ajax({
  1528. method: "get",
  1529. dataType: "json",
  1530. crossDomain: false,
  1531. url:globalConfig.context + '/api/admin/customer/listFollowHistory',
  1532. data: {
  1533. pageNo: pageNo || 1,
  1534. pageSize: this.state.paginations.pageSize,
  1535. uid: this.state.rowId, //名称1
  1536. businessGlossoryId:this.state.businessGlossoryId,
  1537. },
  1538. success: function (data) {
  1539. let theArr = [];
  1540. if (data.error.length || data.data.list=="") {
  1541. if (data.error && data.error.length) {
  1542. message.warning(data.error[0].message);
  1543. };
  1544. } else {
  1545. for (let i = 0; i < data.data.list.length; i++) {
  1546. let thisdata = data.data.list[i];
  1547. theArr.push({
  1548. followId:thisdata.followId,
  1549. followTime:thisdata.followTime,
  1550. identifyName:thisdata.identifyName,
  1551. contacts:thisdata.contacts,
  1552. contactMobile:thisdata.contactMobile,
  1553. result:thisdata.result,
  1554. ufbId:thisdata.ufbId,
  1555. adminName:thisdata.adminName,
  1556. followSituation:thisdata.followSituation,
  1557. customerStatus:thisdata.customerStatus,
  1558. contactType:thisdata.contactType
  1559. });
  1560. };
  1561. this.state.paginations.current = data.data.pageNo;
  1562. this.state.paginations.total = data.data.totalCount;
  1563. };
  1564. this.setState({
  1565. visitArrList: theArr,
  1566. paginations: this.state.paginations
  1567. });
  1568. }.bind(this),
  1569. }).always(function () {
  1570. this.setState({
  1571. loading: false
  1572. });
  1573. }.bind(this));
  1574. },
  1575. //tab3拜访记录
  1576. loadBfVisit(pageNo,uids) {
  1577. this.setState({
  1578. loading: true
  1579. });
  1580. $.ajax({
  1581. method: "get",
  1582. dataType: "json",
  1583. crossDomain: false,
  1584. url:globalConfig.context + '/api/admin/customer/listFollowHistory',
  1585. data: {
  1586. pageNo: pageNo || 1,
  1587. pageSize: this.state.paginationsy.pageSize,
  1588. uid: uids?uids:this.state.rowId, //名称1
  1589. },
  1590. success: function (data) {
  1591. let theArr = [];
  1592. if (data.error.length || data.data.list=="") {
  1593. if (data.error && data.error.length) {
  1594. message.warning(data.error[0].message);
  1595. };
  1596. } else {
  1597. for (let i = 0; i < data.data.list.length; i++) {
  1598. let thisdata = data.data.list[i];
  1599. theArr.push({
  1600. followId:thisdata.followId,
  1601. followTime:thisdata.followTime,
  1602. identifyName:thisdata.identifyName,
  1603. contacts:thisdata.contacts,
  1604. contactMobile:thisdata.contactMobile,
  1605. result:thisdata.result,
  1606. ufbId:thisdata.ufbId,
  1607. adminName:thisdata.adminName,
  1608. followSituation:thisdata.followSituation,
  1609. customerStatus:thisdata.customerStatus,
  1610. contactType:thisdata.contactType
  1611. });
  1612. };
  1613. this.state.paginationsy.current = data.data.pageNo;
  1614. this.state.paginationsy.total = data.data.totalCount;
  1615. };
  1616. this.setState({
  1617. visitArrList: theArr,
  1618. paginationsy: this.state.paginationsy
  1619. });
  1620. }.bind(this),
  1621. }).always(function () {
  1622. this.setState({
  1623. loading: false
  1624. });
  1625. }.bind(this));
  1626. },
  1627. businessIntentionOk(){
  1628. this.setState({
  1629. businessGlossoryId:'',
  1630. businessModul:false
  1631. })
  1632. },
  1633. businessIntentionCancel(){
  1634. this.setState({
  1635. businessGlossoryId:'',
  1636. businessModul:false
  1637. })
  1638. },
  1639. //业务跟进查看跟多
  1640. businessFollowDetails(e){
  1641. this.listFollowUp(e.ufbId)
  1642. this.setState({
  1643. businessFollowModul:true
  1644. })
  1645. },
  1646. businessFollowOk(e){
  1647. this.setState({
  1648. businessFollowModul:false
  1649. })
  1650. },
  1651. businessFollowCancel(e){
  1652. this.setState({
  1653. businessFollowModul:false
  1654. })
  1655. },
  1656. //tab2联系人保存
  1657. contactSave(e) {
  1658. e.preventDefault();
  1659. this.setState({
  1660. loading: true
  1661. });
  1662. $.ajax({
  1663. url: globalConfig.context + '/api/admin/customer/updateCustomerContacts',
  1664. method: 'post',
  1665. data: {
  1666. uid:this.state.rowId,
  1667. contactList: JSON.stringify(this.state.contactList)
  1668. }
  1669. }).done(function (data) {
  1670. this.setState({
  1671. loading: false
  1672. });
  1673. if (!data.error.length) {
  1674. message.success('保存成功!');
  1675. this.detailsModal()
  1676. this.loadData();
  1677. } else {
  1678. message.warning(data.error[0].message);
  1679. }
  1680. }.bind(this));
  1681. },
  1682. //详情tab切换数据处理
  1683. callback(e){
  1684. if(e==1){
  1685. this.loadInformation(this.state.rowId)
  1686. }
  1687. if(e==2){
  1688. this.contactLists(this.state.rowId)
  1689. }
  1690. if(e==3){
  1691. this.httpAccount(this.state.rowId)
  1692. }
  1693. if(e==4){
  1694. this.loadBfVisit(1,this.state.rowId);
  1695. }
  1696. if(e==5){
  1697. this.BusinessList(1,this.state.rowId);
  1698. }
  1699. if(e==6){
  1700. }
  1701. if(e==7){
  1702. }
  1703. if(e==8){
  1704. }
  1705. if(e==9){
  1706. }
  1707. },
  1708. //账户信息保存
  1709. accountSave(e){
  1710. e.preventDefault();
  1711. if(!this.state.mobile){
  1712. message.warning('手机号码不能为空!')
  1713. return false;
  1714. }
  1715. this.setState({
  1716. loading: true
  1717. });
  1718. $.ajax({
  1719. method: "post",
  1720. dataType: "json",
  1721. url:globalConfig.context + '/api/admin/customer/updateUserAccount',
  1722. data: {
  1723. id: this.state.Accountuid,
  1724. mobile: this.state.mobile,
  1725. nickname: this.state.nickname,
  1726. email: this.state.email,
  1727. isMember: this.state.isMember,
  1728. currentMemberStatus: this.state.currentMemberStatus,
  1729. serviceCertification: this.state.serviceCertification,
  1730. userCertification: this.state.userCertification,
  1731. lvl:this.state.lvl,
  1732. status:this.state.status,
  1733. }
  1734. }).done(function (data) {
  1735. this.setState({
  1736. loading: false
  1737. });
  1738. if (!data.error.length) {
  1739. message.success('保存成功!');
  1740. this.detailsModal();
  1741. this.loadData();
  1742. } else {
  1743. message.warning(data.error[0].message);
  1744. }
  1745. }.bind(this));
  1746. },
  1747. //tab2删除
  1748. confirmDelet(e){
  1749. this.setState({
  1750. loading:true
  1751. });
  1752. if(e.id){
  1753. $.ajax({
  1754. method: "get",
  1755. dataType: "json",
  1756. crossDomain: false,
  1757. url: globalConfig.context + "/api/admin/customer/deleteOneContact",
  1758. data: {
  1759. ocbId: e.id,//删除的ID
  1760. }
  1761. }).done(function (data) {
  1762. if (!data.error.length) {
  1763. message.success('删除成功!');
  1764. this.setState({
  1765. loading: false,
  1766. });
  1767. } else {
  1768. message.warning(data.error[0].message);
  1769. };
  1770. this.contactLists(this.state.rowId);
  1771. }.bind(this));
  1772. }else{
  1773. this.contactLists(this.state.rowId);
  1774. }
  1775. },
  1776. //tab5业务意向
  1777. BusinessList(pageNo,uids) {
  1778. this.setState({
  1779. loading: true
  1780. });
  1781. $.ajax({
  1782. method: "post",
  1783. dataType: "json",
  1784. crossDomain: false,
  1785. url:globalConfig.context + '/api/admin/customer/listBusiness',
  1786. data: {
  1787. pageNo: pageNo || 1,
  1788. pageSize: this.state.paginationt.pageSize,
  1789. uid:uids?uids:this.state.rowId
  1790. },
  1791. success: function (data) {
  1792. let theArr = [];
  1793. if (data.error.length || data.data.list=="") {
  1794. if (data.error && data.error.length) {
  1795. message.warning(data.error[0].message);
  1796. };
  1797. } else {
  1798. for (let i = 0; i < data.data.list.length; i++) {
  1799. let thisdata = data.data.list[i];
  1800. theArr.push({
  1801. key: i,
  1802. businessId:thisdata.businessId,
  1803. businessName:thisdata.businessName,
  1804. identifyName:thisdata.identifyName,
  1805. followSituation:thisdata.followSituation,
  1806. customerStatus:thisdata.customerStatus,
  1807. adminName:thisdata.adminName,
  1808. createTime:thisdata.createTime
  1809. });
  1810. };
  1811. this.state.paginationt.current = data.data.pageNo;
  1812. this.state.paginationt.total = data.data.totalCount;
  1813. };
  1814. this.setState({
  1815. dataBusiness: theArr,
  1816. paginationt: this.state.paginationt
  1817. });
  1818. }.bind(this),
  1819. }).always(function () {
  1820. this.setState({
  1821. loading: false
  1822. });
  1823. }.bind(this));
  1824. },
  1825. componentWillReceiveProps(nextProps) {
  1826. if (!this.props.visible && nextProps.visible) {
  1827. if (nextProps.data && nextProps.data.id) {
  1828. this.loadData(nextProps.data.id, nextProps.detailApiUrl);
  1829. };
  1830. this.state.data = {};
  1831. this.state.companyLogoUrl = [];
  1832. this.state.orgCodeUrl = [];
  1833. };
  1834. },
  1835. render() {
  1836. const FormItem = Form.Item
  1837. const rowSelection = {
  1838. selectedRowKeys: this.state.selectedRowKeys,
  1839. onChange: (selectedRowKeys, selectedRows) => {
  1840. this.setState({
  1841. selectedRows: selectedRows.slice(-1),
  1842. selectedRowKeys: selectedRowKeys.slice(-1)
  1843. });
  1844. },
  1845. onSelect: (recordt, selected, selectedRows) => {
  1846. this.setState({
  1847. recordt:recordt.id
  1848. })
  1849. },
  1850. };
  1851. const rowSelections = {
  1852. selectedRowKeys: this.state.selectedRowKey,
  1853. onChange: (selectedRowKey, selectedRow) => {
  1854. this.setState({
  1855. selectedRow: selectedRow.slice(-1),
  1856. selectedRowKey: selectedRowKey.slice(-1)
  1857. });
  1858. },
  1859. onSelect: (records, selected, selectedRow) => {
  1860. this.setState({
  1861. selectedRow: selectedRow.slice(-1),
  1862. records:records.id,
  1863. })
  1864. },
  1865. };
  1866. const hasSelected = this.state.selectedRowKeys.length > 0;
  1867. const { RangePicker } = DatePicker;
  1868. const { getFieldDecorator } = this.props.form;
  1869. const formItemLayout = {
  1870. labelCol: { span: 8 },
  1871. wrapperCol: { span: 14 },
  1872. };
  1873. const theInformation=this.state.dataInformation || {}
  1874. const contactsOption="";
  1875. const formItemLayput = {
  1876. labelCol: { span: 10 },
  1877. wrapperCol: { span: 14 },
  1878. };
  1879. const contacts=this.state.contacts || '';
  1880. return (
  1881. <div className="user-content" >
  1882. <div className="content-title">
  1883. <span>我的客户</span>
  1884. </div>
  1885. <div className="user-search">
  1886. <Input placeholder="客户名称"
  1887. value={this.state.nameSearch}
  1888. onChange={(e) => { this.setState({ nameSearch: e.target.value }); }} />
  1889. <Select placeholder="省"
  1890. style={{ width: 80 }}
  1891. value={this.state.provinceSearch}
  1892. onChange={(e) => {this.setState({ provinceSearch: e});}}>
  1893. {this.state.Provinces}
  1894. </Select>
  1895. <span style={{marginRight:'10px'}}>
  1896. <Cascader options={citySelect()} value={this.state.addressSearch} placeholder="选择城市"
  1897. onChange={(e,pre) => { this.setState({ addressSearch: e }) }} />
  1898. </span>
  1899. <Button type="primary" onClick={this.search}>搜索</Button>
  1900. <Button onClick={this.reset}>重置</Button>
  1901. <Button onClick={() => { window.open(globalConfig.context + '/api/admin/customer/downloadTemplate?type=1') }}>下载批量导入模板</Button>
  1902. <Upload
  1903. name="file"
  1904. action={globalConfig.context + "/api/admin/customer/uploadExcel"}
  1905. beforeUpload={beforeUploadFile}
  1906. showUploadList={false}
  1907. onChange={(info) => {
  1908. if (info.file.status !== 'uploading') {
  1909. console.log(info.file, info.fileList);
  1910. }
  1911. if (info.file.status === 'done') {
  1912. if (!info.file.response.error.length) {
  1913. message.success(`${info.file.name} 文件上传成功!`);
  1914. this.loadData();
  1915. } else {
  1916. message.warning(info.file.response.error[0].message);
  1917. return;
  1918. };
  1919. } else if (info.file.status === 'error') {
  1920. message.error(`${info.file.name} 文件上传失败。`);
  1921. };
  1922. }} >
  1923. <Button>上传批量内容</Button>
  1924. </Upload>
  1925. <Popconfirm title="是否删除?" onConfirm={this.delectRow} okText="是" cancelText="否">
  1926. <Button style={{ background: "#ea0862", border: "none", color: "#fff",marginRight:'10px' ,marginLeft:'10px'}}
  1927. disabled={!hasSelected}
  1928. >删除<Icon type="minus" />
  1929. </Button>
  1930. </Popconfirm>
  1931. <Button style={{ background: "#3fcf9e", border: "none", color: "#fff" }}
  1932. disabled={!hasSelected}
  1933. onClick={this.changeRow}>转为公共客户<Icon /></Button>
  1934. <span style={{marginLeft:'10px',marginRight:'20px'}}>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch} /></span>
  1935. <Button type="primary" className="addButton" onClick={this.addClick}>新增客户<Icon type="plus" /></Button>
  1936. <div className='clearfix' style={{marginTop:'5px'}}>
  1937. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  1938. <RangePicker
  1939. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  1940. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  1941. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  1942. <Select placeholder="账户状态"
  1943. style={{ width: 100 }}
  1944. value={this.state.statusSearch}
  1945. onChange={(e) => { this.setState({ statusSearch: e }) }}>
  1946. <Select.Option value="0" >正常</Select.Option>
  1947. <Select.Option value="2" >锁定</Select.Option>
  1948. </Select>
  1949. <Select placeholder="行业"
  1950. style={{ width: 100 }}
  1951. value={this.state.industrySearch}
  1952. onChange={(e) => { this.setState({ industrySearch: e }) }}>
  1953. {this.state.intentionalOption}
  1954. </Select>
  1955. <span>认证:</span>
  1956. <Select placeholder="业务认证"
  1957. style={{ width: 100 }}
  1958. value={this.state.serviceCertificationSearch}
  1959. onChange={(e) => { this.setState({ serviceCertificationSearch: e }) }}>
  1960. <Select.Option value="0" >未认证</Select.Option>
  1961. <Select.Option value="1" >已认证</Select.Option>
  1962. </Select>
  1963. <Select placeholder="实名认证"
  1964. style={{ width: 100 }}
  1965. value={this.state.userCertificationSearch}
  1966. onChange={(e) => { this.setState({ userCertificationSearch: e }) }}>
  1967. <Select.Option value="0" >未认证</Select.Option>
  1968. <Select.Option value="1" >已认证</Select.Option>
  1969. </Select>
  1970. <span>国际:</span>
  1971. <Select placeholder="国际"
  1972. style={{ width: 100 }}
  1973. value={this.state.internationalSearch}
  1974. onChange={(e) => { this.setState({ internationalSearch: e }) }}>
  1975. <Select.Option value="0" >否</Select.Option>
  1976. <Select.Option value="1" >是</Select.Option>
  1977. </Select>
  1978. <span>高新:</span>
  1979. <Select placeholder="高新"
  1980. style={{ width: 100 }}
  1981. value={this.state.highTechZoneSearch}
  1982. onChange={(e) => { this.setState({ highTechZoneSearch: e }) }}>
  1983. <Select.Option value="0" >否</Select.Option>
  1984. <Select.Option value="1" >是</Select.Option>
  1985. </Select>
  1986. <span>上市:</span>
  1987. <Select placeholder="上市"
  1988. style={{ width: 100 }}
  1989. value={this.state.listedSearch}
  1990. onChange={(e) => { this.setState({ listedSearch: e }) }}>
  1991. <Select.Option value="0" >否</Select.Option>
  1992. <Select.Option value="1" >是</Select.Option>
  1993. </Select>
  1994. <span>会员:</span>
  1995. <Select placeholder="是否会员"
  1996. style={{ width: 100 }}
  1997. value={this.state.isMemberSearch}
  1998. onChange={(e) => { this.setState({ isMemberSearch: e }) }}>
  1999. <Select.Option value="0" >否</Select.Option>
  2000. <Select.Option value="1" >是</Select.Option>
  2001. </Select>
  2002. <Select placeholder="会员等级"
  2003. style={{ width: 100 }}
  2004. value={this.state.lvlSearch}
  2005. onChange={(e) => { this.setState({ lvlSearch: e }) }}>
  2006. {this.state.lvlArrOption}
  2007. </Select>
  2008. <Select placeholder="会员状态"
  2009. style={{ width: 100 }}
  2010. value={this.state.currentMemberStatusSearch}
  2011. onChange={(e) => { this.setState({ currentMemberStatusSearch: e }) }}>
  2012. {this.state.currentMemberArrOption}
  2013. </Select>
  2014. <Select placeholder="社会性质"
  2015. style={{ width: 100 }}
  2016. value={this.state.societyTagSearch}
  2017. onChange={(e) => { this.setState({ societyTagSearch: e }) }}>
  2018. {
  2019. socialAttribute.map(function (item) {
  2020. return <Select.Option key={item.value} >{item.key}</Select.Option>
  2021. })
  2022. }
  2023. </Select>
  2024. </div>
  2025. </div>
  2026. </div>
  2027. <div className="patent-table">
  2028. <Spin spinning={this.state.loading}>
  2029. <Table columns={this.state.columns}
  2030. dataSource={this.state.dataSource}
  2031. rowSelection={rowSelection}
  2032. pagination={this.state.pagination}
  2033. onRowClick={this.tableRowClick}
  2034. />
  2035. </Spin>
  2036. </div>
  2037. <CustomerDetail
  2038. data={this.state.RowData}
  2039. showDesc={this.state.showDesc}
  2040. closeDesc={this.closeDesc}
  2041. newmodal={this.newmodal}
  2042. />
  2043. <Modal
  2044. className="customeDetails"
  2045. title="单位客户详情"
  2046. width='1200px'
  2047. visible={this.state.modal5Visible}
  2048. onOk={this.detailsModal}
  2049. onCancel={this.detailsModal}
  2050. footer=''
  2051. >
  2052. <Tabs defaultActiveKey="1" onChange={this.callback}>
  2053. <TabPane tab="基本信息" key="1">
  2054. <Form horizontal onSubmit={this.newSubmit} id="demand-form">
  2055. <Spin spinning={this.state.loading}>
  2056. <div className="clearfix" style={{paddingLeft:'60px'}}>
  2057. <FormItem className="half-item"
  2058. labelCol={{ span: 4 }}
  2059. wrapperCol={{ span: 18 }}
  2060. label="客户名称"
  2061. >
  2062. <span>{theInformation.unitName}</span>
  2063. </FormItem>
  2064. </div>
  2065. <div className="clearfix" style={{paddingLeft:'60px'}}>
  2066. <FormItem className="half-item"
  2067. labelCol={{ span: 4 }}
  2068. wrapperCol={{ span: 18 }}
  2069. label="行业">
  2070. <Select placeholder="选择行业" value={this.state.industry} style={{width:'300px'}}
  2071. onChange={(e)=>{this.setState({industry:e})}}>
  2072. {
  2073. industry.map(function (item) {
  2074. return <Select.Option key={item.value} >{item.key}</Select.Option>
  2075. })
  2076. }
  2077. </Select>
  2078. <span style={{color:'red',marginLeft:'15px'}}>*</span>
  2079. </FormItem>
  2080. <FormItem className="half-item"
  2081. labelCol={{ span: 4 }}
  2082. wrapperCol={{ span: 18 }}
  2083. label="社会属性"
  2084. >
  2085. <Select placeholder="客户社会属性(必填项)" value={this.state.societyTag} style={{width:'300px'}}
  2086. onChange={(e)=>{this.setState({societyTag:e})}}>
  2087. {
  2088. socialAttribute.map(function (item) {
  2089. return <Select.Option key={item.value} >{item.key}</Select.Option>
  2090. })
  2091. }
  2092. </Select>
  2093. <span style={{color:'red',marginLeft:'15px'}}>*</span>
  2094. </FormItem>
  2095. <FormItem className="half-item"
  2096. labelCol={{ span: 4 }}
  2097. wrapperCol={{ span: 18 }}
  2098. label="省-市-区"
  2099. >
  2100. <Cascader options={areaSelect()} value={this.state.ProvinceCity} placeholder="选择城市" style={{width:'300px'}}
  2101. onChange={(e,pre) => { this.setState({ ProvinceCity: e }) }} />
  2102. <span style={{color:'red',marginLeft:'15px'}}>*</span>
  2103. </FormItem>
  2104. <FormItem className="half-item"
  2105. labelCol={{ span: 4 }}
  2106. wrapperCol={{ span: 18 }}
  2107. label="通信地址"
  2108. >
  2109. <Input placeholder="客户通信地址" value={this.state.postalAddress}
  2110. onChange={(e)=>{this.setState({postalAddress:e.target.value})}}/>
  2111. </FormItem>
  2112. <FormItem className="half-item"
  2113. labelCol={{ span: 4 }}
  2114. wrapperCol={{ span: 18 }}
  2115. label="固定电话"
  2116. >
  2117. <Input placeholder="客户固定电话" value={this.state.contactsFixedTel}
  2118. onChange={(e)=>{this.setState({contactsFixedTel:e.target.value})}}/>
  2119. </FormItem>
  2120. <FormItem className="half-item"
  2121. labelCol={{ span: 4 }}
  2122. wrapperCol={{ span: 18 }}
  2123. label="客户传真"
  2124. >
  2125. <Input placeholder="客户传真" value={this.state.contactsFax}
  2126. onChange={(e)=>{this.setState({contactsFax:e.target.value})}}/>
  2127. </FormItem>
  2128. <FormItem className="half-item"
  2129. labelCol={{ span: 4 }}
  2130. wrapperCol={{ span: 18 }}
  2131. label="注册资本"
  2132. >
  2133. <Input placeholder="注册资本" value={this.state.registeredCapital}
  2134. onChange={(e)=>{this.setState({registeredCapital:e.target.value})}}/>
  2135. </FormItem>
  2136. <FormItem className="half-item"
  2137. labelCol={{ span: 4 }}
  2138. wrapperCol={{ span: 18 }}
  2139. label="单位规模"
  2140. >
  2141. <Input placeholder="单位规模" value={this.state.enterpriseScale}
  2142. onChange={(e)=>{this.setState({enterpriseScale:e.target.value})}}/>
  2143. </FormItem>
  2144. <FormItem className="half-item"
  2145. labelCol={{ span: 4 }}
  2146. wrapperCol={{ span: 18 }}
  2147. label="法人名称"
  2148. >
  2149. <Input placeholder="法人名称" value={this.state.legalPerson}
  2150. onChange={(e)=>{this.setState({legalPerson:e.target.value})}}/>
  2151. </FormItem>
  2152. <FormItem className="half-item"
  2153. labelCol={{ span: 4 }}
  2154. wrapperCol={{ span: 18 }}
  2155. label="身份证号码"
  2156. >
  2157. <Input placeholder="法人身份证号码" value={this.state.legalPersonIdCard}
  2158. onChange={(e)=>{this.setState({legalPersonIdCard:e.target.value})}}/>
  2159. </FormItem>
  2160. <FormItem className="half-item"
  2161. labelCol={{ span: 4 }}
  2162. wrapperCol={{ span: 18 }}
  2163. label="法人电话"
  2164. >
  2165. <Input placeholder="法人电话" value={this.state.legalPersonTel}
  2166. onChange={(e)=>{this.setState({legalPersonTel:e.target.value})}}/>
  2167. </FormItem>
  2168. <FormItem className="half-item"
  2169. labelCol={{ span: 4 }}
  2170. wrapperCol={{ span: 18 }}
  2171. label="电子邮箱"
  2172. >
  2173. <Input placeholder="法人电子邮箱" value={this.state.legalPersonEmail}
  2174. onChange={(e)=>{this.setState({legalPersonEmail:e.target.value})}}/>
  2175. </FormItem>
  2176. <FormItem className="half-item"
  2177. labelCol={{ span: 4 }}
  2178. wrapperCol={{ span: 18 }}
  2179. label="高新"
  2180. >
  2181. <Radio.Group value={this.state.highTechZone} onChange={(e) => {
  2182. this.setState({highTechZone:e.target.value})
  2183. }}>
  2184. <Radio value={0}>否</Radio>
  2185. <Radio value={1}>是</Radio>
  2186. </Radio.Group>
  2187. </FormItem>
  2188. <FormItem className="half-item"
  2189. labelCol={{ span: 4 }}
  2190. wrapperCol={{ span: 18 }}
  2191. label="上市"
  2192. >
  2193. <Radio.Group value={this.state.listed} onChange={(e) => {
  2194. this.setState({listed:e.target.value })
  2195. }}>
  2196. <Radio value={0}>否</Radio>
  2197. <Radio value={1}>是</Radio>
  2198. </Radio.Group>
  2199. </FormItem>
  2200. <FormItem className="half-item"
  2201. labelCol={{ span: 4 }}
  2202. wrapperCol={{ span: 18 }}
  2203. label="国际化"
  2204. >
  2205. <Radio.Group value={this.state.international} onChange={(e) => {
  2206. this.setState({international:e.target.value })
  2207. }}>
  2208. <Radio value={0}>否</Radio>
  2209. <Radio value={1}>是</Radio>
  2210. </Radio.Group>
  2211. </FormItem>
  2212. <FormItem className="half-item"
  2213. labelCol={{ span: 4 }}
  2214. wrapperCol={{ span: 18 }}
  2215. label="机构代码"
  2216. >
  2217. <Input placeholder="社会同意机构代码" value={this.state.orgCode}
  2218. onChange={(e)=>{this.setState({orgCode:e.target.value})}}/>
  2219. </FormItem>
  2220. <div className="clearfix pictures">
  2221. <FormItem
  2222. labelCol={{ span: 4 }}
  2223. wrapperCol={{ span: 18 }}
  2224. label="机构证(PIC)" >
  2225. <PicturesWall
  2226. pictureSign="customer_sys_file"
  2227. fileList={this.getOrgCodeUrl}
  2228. pictureUrl={this.state.orgCodeUrl} />
  2229. <p>图片建议:图片要清晰。</p>
  2230. </FormItem>
  2231. <FormItem
  2232. labelCol={{ span: 4 }}
  2233. wrapperCol={{ span: 18 }}
  2234. label="单位logo" >
  2235. <PicturesWall
  2236. pictureSign="customer_sys_file"
  2237. fileList={this.getCompanyLogoUrl}
  2238. pictureUrl={this.state.companyLogoUrl} />
  2239. <p>图片建议:图片要清晰。</p>
  2240. </FormItem>
  2241. </div>
  2242. <div className="clearfix">
  2243. <FormItem
  2244. labelCol={{ span: 2 }}
  2245. wrapperCol={{ span: 18 }}
  2246. label="业务范围" >
  2247. <Input type="textarea" rows={4} value={this.state.businessScope}
  2248. onChange={(e)=>{this.setState({businessScope:e.target.value})}}/>
  2249. </FormItem>
  2250. <FormItem
  2251. labelCol={{ span: 2 }}
  2252. wrapperCol={{ span: 18 }}
  2253. label="单位简介" >
  2254. <Input type="textarea" rows={4} value={this.state.introduction}
  2255. onChange={(e)=>{this.setState({introduction:e.target.value})}}/>
  2256. </FormItem>
  2257. </div>
  2258. <Button className="set-submit" type="primary" htmlType="submit" style={{marginLeft:'90px',marginBottom:'30px'}}>保存</Button>
  2259. <Button className="set-submit" type="ghost" onClick={this.detailsModal}>取消</Button>
  2260. </div>
  2261. </Spin>
  2262. </Form>
  2263. </TabPane>
  2264. <TabPane tab="联系人信息" key="2">
  2265. <div className="clearfix" >
  2266. <Button className="ContactsList" type="primary" onClick={this.addcontact}>新增</Button>
  2267. </div>
  2268. <div className="clearfix">
  2269. <Spin spinning={this.state.loading}>
  2270. <Form horizontal id="demand-form" onSubmit={this.contactSave} >
  2271. <Table
  2272. pagination={false}
  2273. columns={this.state.ContactsLists}
  2274. dataSource={this.state.contactList}
  2275. />
  2276. <div className="clearfix">
  2277. <Button type="primary" htmlType="submit" style={{fontSize:'16px',margin:'20px 25px 40px 120px'}}>保存</Button>
  2278. <Button type="ghost" onClick={this.detailsModal} style={{fontSize:'18px'}}>取消</Button>
  2279. </div>
  2280. </Form>
  2281. </Spin>
  2282. </div>
  2283. </TabPane>
  2284. <TabPane tab="账户信息" key="3">
  2285. <div className="clearfix">
  2286. <Form horizontal id="demand-form" onSubmit={this.accountSave} >
  2287. <Spin spinning={this.state.loading} >
  2288. <FormItem className="half-item"
  2289. {...formItemLayout}
  2290. label="注册手机号" >
  2291. <Input value={this.state.mobile} onChange={(e) => { this.setState({ mobile: e.target.value }); }} style={{width:'200px',marginRight:'50px'}}/>
  2292. <Button onClick={this.modifyPassworld}>修改密码</Button>
  2293. </FormItem>
  2294. <FormItem className="half-item"
  2295. {...formItemLayout}
  2296. label="注册用户名" >
  2297. <Input value={this.state.nickname} onChange={(e) => { this.setState({ nickname: e.target.value }); }} />
  2298. </FormItem>
  2299. <FormItem className="half-item"
  2300. {...formItemLayout}
  2301. label="注册邮箱" >
  2302. <Input value={this.state.email} onChange={(e) => { this.setState({ email: e.target.value }); }} />
  2303. </FormItem>
  2304. <div className="clearfix">
  2305. <FormItem className="half-item"
  2306. {...formItemLayout}
  2307. label="客户来源" >
  2308. <span>{this.state.source}</span>
  2309. </FormItem>
  2310. <FormItem className="half-item"
  2311. {...formItemLayout}
  2312. label="客户类型" >
  2313. <span>{this.state.type}</span>
  2314. </FormItem>
  2315. <FormItem className="half-item"
  2316. {...formItemLayout}
  2317. label="创建时间" >
  2318. <span>{this.state.createTimes}</span>
  2319. </FormItem>
  2320. <FormItem className="half-item"
  2321. {...formItemLayout}
  2322. label="账户状态"
  2323. >
  2324. <Select placeholder="账户状态" value={this.state.status} onChange={(e) => { this.setState({ status: e }); }} >
  2325. {
  2326. statuslist.map(function (item) {
  2327. return <Select.Option key={item.value} >{item.key}</Select.Option>
  2328. })
  2329. }
  2330. </Select>
  2331. </FormItem>
  2332. </div>
  2333. <div className="clearfix">
  2334. <FormItem className="half-item"
  2335. {...formItemLayout}
  2336. label="会员"
  2337. >
  2338. <Radio.Group value={this.state.isMember} onChange={(e) => {
  2339. this.setState({ isMember: e.target.value })
  2340. }}>
  2341. <Radio value={0}>否</Radio>
  2342. <Radio value={1}>是</Radio>
  2343. </Radio.Group>
  2344. </FormItem>
  2345. <FormItem className="half-item"
  2346. {...formItemLayout}
  2347. label="会员等级"
  2348. >
  2349. <Select placeholder="客户状态" value={this.state.lvl} onChange={(e) => { this.setState({ lvl: e }); }} >
  2350. {
  2351. lvl.map(function (item) {
  2352. return <Select.Option key={item.value} >{item.key}</Select.Option>
  2353. })
  2354. }
  2355. </Select>
  2356. </FormItem>
  2357. <FormItem className="half-item"
  2358. {...formItemLayout}
  2359. label="会员状态"
  2360. >
  2361. <Select placeholder="会员状态" value={this.state.currentMemberStatus} onChange={(e) => { this.setState({ currentMemberStatus: e }); }} >
  2362. {
  2363. currentMember.map(function (item) {
  2364. return <Select.Option key={item.value} >{item.key}</Select.Option>
  2365. })
  2366. }
  2367. </Select>
  2368. </FormItem>
  2369. </div>
  2370. <FormItem className="half-item"
  2371. {...formItemLayout}
  2372. label="业务认证"
  2373. >
  2374. <Radio.Group value={this.state.serviceCertification} onChange={(e) => {
  2375. this.setState({ serviceCertification: e.target.value })
  2376. }}>
  2377. <Radio value={0}>未认证</Radio>
  2378. <Radio value={1}>已认证</Radio>
  2379. </Radio.Group>
  2380. </FormItem>
  2381. <FormItem className="half-item"
  2382. {...formItemLayout}
  2383. label="实名认证"
  2384. >
  2385. <Radio.Group value={this.state.userCertification} onChange={(e) => {
  2386. this.setState({ userCertification: e.target.value })
  2387. }}>
  2388. <Radio value={0}>未认证</Radio>
  2389. <Radio value={1}>已认证</Radio>
  2390. </Radio.Group>
  2391. </FormItem>
  2392. <div className="clearfix">
  2393. <Button className='saveBtn' type="primary" htmlType="submit">保存</Button>
  2394. <Button type="ghost" onClick={this.detailsModal}>取消</Button>
  2395. </div>
  2396. </Spin>
  2397. </Form>
  2398. </div>
  2399. </TabPane>
  2400. <TabPane tab="客户拜访" key="4">
  2401. <div className="clearfix">
  2402. <Spin spinning={this.state.loading}>
  2403. <Table
  2404. pagination={false}
  2405. columns={this.state.visitsList}
  2406. dataSource={this.state.visitArrList}
  2407. onRowClick={this.VisitRowClick}
  2408. />
  2409. </Spin>
  2410. </div>
  2411. </TabPane>
  2412. <TabPane tab="业务意向" key="5">
  2413. <div className="clearfix">
  2414. <Spin spinning={this.state.loading}>
  2415. <Table
  2416. pagination={this.state.paginationt}
  2417. columns={this.state.businessIntentionList}
  2418. dataSource={this.state.dataBusiness}
  2419. />
  2420. </Spin>
  2421. </div>
  2422. </TabPane>
  2423. <TabPane tab="业务订单" key="6">
  2424. </TabPane>
  2425. <TabPane tab="技术需求" key="7">
  2426. </TabPane>
  2427. <TabPane tab="技术成果" key="8">
  2428. </TabPane>
  2429. <TabPane tab="技术专家" key="9">
  2430. </TabPane>
  2431. </Tabs>
  2432. </Modal>
  2433. <Modal
  2434. className="customeDetails"
  2435. footer=''
  2436. title="拜访详情"
  2437. width='1000px'
  2438. visible={this.state.visitModul}
  2439. onOk={this.visitOk}
  2440. onCancel={this.visitCancel}
  2441. >
  2442. <Form horizontal id="demand-form" onSubmit={this.visitSubmit}>
  2443. <Spin spinning={this.state.loading}>
  2444. <div className="clearfix">
  2445. <FormItem className="half-item"
  2446. {...formItemLayout}
  2447. label="拜访方式" >
  2448. <Radio.Group value={this.state.contactType} onChange={(e) => {
  2449. this.setState({ contactType: e.target.value })
  2450. }}>
  2451. <Radio value={0}>外出</Radio>
  2452. <Radio value={1}>电话</Radio>
  2453. <Radio value={2}>QQ</Radio>
  2454. <Radio value={3}>微信</Radio>
  2455. <Radio value={4}>邮箱</Radio>
  2456. </Radio.Group>
  2457. </FormItem>
  2458. <FormItem className="half-item"
  2459. {...formItemLayout}
  2460. >
  2461. <Button type="primary" onClick={this.newContacts} style={{marginLeft:'100px',display:this.state.keys?'inline-block':'none'}}>添加新联系人</Button>
  2462. </FormItem>
  2463. <div className="clearfix">
  2464. <FormItem className="half-item"
  2465. {...formItemLayout}
  2466. label="客户名称"
  2467. >
  2468. <span>{this.state.identifyName}</span>
  2469. </FormItem>
  2470. <FormItem className="half-item"
  2471. {...formItemLayout}
  2472. label="拜访人"
  2473. >
  2474. <span>{this.state.adminName}</span>
  2475. </FormItem>
  2476. <FormItem className="half-item"
  2477. {...formItemLayout}
  2478. label="当前联系人"
  2479. >
  2480. <span>{this.state.contacts}</span>
  2481. </FormItem>
  2482. {this.state.contacts?<span></span>:
  2483. <FormItem className="half-item"
  2484. {...formItemLayout}
  2485. label="联系人"
  2486. >
  2487. <Select placeholder="选择联系人" style={{ width: 140 }}
  2488. value={this.state.lastName}
  2489. onChange={this.hundleName}>
  2490. {this.state.orderStatusOption}
  2491. </Select>
  2492. </FormItem>
  2493. }
  2494. <FormItem className="half-item"
  2495. {...formItemLayout}
  2496. label="拜访时间"
  2497. >
  2498. <span>{this.state.followTime}</span>
  2499. </FormItem>
  2500. <FormItem className="half-item"
  2501. {...formItemLayout}
  2502. label="联系电话"
  2503. >
  2504. <span>{this.state.nub}</span>
  2505. </FormItem>
  2506. </div>
  2507. <div className="clearfix">
  2508. <FormItem
  2509. labelCol={{ span: 4 }}
  2510. wrapperCol={{ span: 16 }}
  2511. label="拜访备注" >
  2512. <Input type="textarea" rows={4} value={this.state.result}
  2513. onChange={(e)=>{this.setState({result:e.target.value})}}/>
  2514. </FormItem>
  2515. </div>
  2516. <div className="clearfix">
  2517. <div style={{fontSize:'18px',marginLeft:'100px',marginTop:'15px',marginBottom:'10px'}}>业务意向<Button onClick={this.addNew} style={{marginLeft:'420px',background:'green',color:'#ffffff'}}>添加新业务</Button></div>
  2518. <div className="clearfix" style={{paddingLeft:'50px',paddingRight:'50px'}}>
  2519. <Spin spinning={this.state.loading}>
  2520. <Table
  2521. rowKey={record => record.id}
  2522. pagination={false}
  2523. columns={this.state.intentionList}
  2524. dataSource={this.state.data}
  2525. />
  2526. </Spin>
  2527. </div>
  2528. </div>
  2529. </div>
  2530. <Button type="primary" size="large" htmlType="submit" style={{margin:'15px 35px 35px 120px'}}>保存</Button>
  2531. <Button size="large" onClick={this.visitCancel}>取消</Button>
  2532. </Spin>
  2533. </Form>
  2534. </Modal>
  2535. <Modal
  2536. footer=''
  2537. title="修改密码"
  2538. width='600px'
  2539. visible={this.state.passworldModul}
  2540. onOk={this.passworldOk}
  2541. onCancel={this.passworldCancel}
  2542. >
  2543. <div className="clearfix">
  2544. <Form horizontal id="demand-form" onSubmit={this.passworldSubmit}>
  2545. <Spin spinning={this.state.loading}>
  2546. <div className="clearfix">
  2547. <FormItem className="half-item"
  2548. {...formItemLayout}
  2549. label="原密码" >
  2550. <Input type="password" value={this.state.companyNamet1} onChange={(e) => { this.setState({ companyNamet1: e.target.value }); }} required="required" />
  2551. </FormItem>
  2552. </div>
  2553. <div className="clearfix">
  2554. <FormItem className="half-item"
  2555. {...formItemLayout}
  2556. label="新密码" >
  2557. <Input type="password" value={this.state.companyName1} onChange={(e) => { this.setState({ companyName1: e.target.value }); }} required="required" />
  2558. </FormItem>
  2559. </div>
  2560. <div className="clearfix">
  2561. <FormItem className="half-item"
  2562. {...formItemLayout}
  2563. label="确认密码" >
  2564. <Input type="password" value={this.state.companyNam1} onChange={(e) => { this.setState({ companyNam1: e.target.value }); }} required="required" />
  2565. </FormItem>
  2566. </div>
  2567. <Button type="primary" size="large" htmlType="submit" style={{margin:'15px 15px 20px 95px'}}>保存</Button>
  2568. <Button size="large" onClick={this.passworldCancel}>取消</Button>
  2569. </Spin>
  2570. </Form>
  2571. </div>
  2572. </Modal>
  2573. <Modal
  2574. footer=''
  2575. width='800px'
  2576. title="新增联系人"
  2577. visible={this.state.addcontactModul}
  2578. onOk={this.addcontactModulOK}
  2579. onCancel={this.addcontactModulcancel}
  2580. >
  2581. <Form horizontal onSubmit={this.submitcontactman} id="demand-form">
  2582. <Spin spinning={this.state.loading}>
  2583. <Row>
  2584. <FormItem
  2585. labelCol={{ span: 3 }}
  2586. wrapperCol={{ span: 14 }}
  2587. label="性别:" style={{marginRight:'10px',marginTop: '-15px'}}>
  2588. <Radio.Group value={this.state.newsex} onChange={(e) => {
  2589. this.setState({ newsex: e.target.value })
  2590. }}>
  2591. <Radio value='男'>男</Radio>
  2592. <Radio value='女'>女</Radio>
  2593. </Radio.Group>
  2594. </FormItem>
  2595. </Row>
  2596. <Row style={{ paddingLeft:'50px' }}>
  2597. <Col span={2}><span style={{color:'red'}}>*</span>姓名:</Col>
  2598. <Col span={8}>
  2599. <Input value={this.state.newname} required="required"
  2600. onChange={(e) => { this.setState({ newname: e.target.value }) }} />
  2601. </Col>
  2602. <Col span={2} style={{ marginLeft: '50px' }}><span style={{color:'red'}}>*</span>手机:</Col>
  2603. <Col span={8}>
  2604. <Input value={this.state.newmobile} required="required"
  2605. onChange={(e) => { this.setState({ newmobile: e.target.value }) }} />
  2606. </Col>
  2607. </Row>
  2608. <Row style={{ marginTop: '20px',paddingLeft:'50px' }}>
  2609. <Col span={2}>微信:</Col>
  2610. <Col span={8}>
  2611. <Input value={this.state.newwechat}
  2612. onChange={(e) => { this.setState({ newwechat: e.target.value }) }} />
  2613. </Col>
  2614. <Col span={2} style={{ marginLeft: '50px' }}>Q Q:</Col>
  2615. <Col span={8}>
  2616. <Input value={this.state.newqq}
  2617. onChange={(e) => { this.setState({ newqq: e.target.value }) }} />
  2618. </Col>
  2619. </Row>
  2620. <Row style={{ marginTop: '20px' ,paddingLeft:'50px'}}>
  2621. <Col span={2}>部门:</Col>
  2622. <Col span={8}>
  2623. <Input value={this.state.newdepatrment}
  2624. onChange={(e) => { this.setState({ newdepatrment: e.target.value }) }} />
  2625. </Col>
  2626. <Col span={2} style={{ marginLeft: '50px' }}>职位:</Col>
  2627. <Col span={8}>
  2628. <Input value={this.state.newposition}
  2629. onChange={(e) => { this.setState({ newposition: e.target.value }) }} />
  2630. </Col>
  2631. </Row>
  2632. <Row style={{ marginTop: '20px',paddingLeft:'50px' }}>
  2633. <Col span={2}>邮箱:</Col>
  2634. <Col span={8}>
  2635. <Input value={this.state.newemail}
  2636. onChange={(e) => { this.setState({ newemail: e.target.value }) }} />
  2637. </Col>
  2638. </Row>
  2639. <Row style={{ marginTop: '20px',paddingLeft:'50px' ,marginBottom:'50px'}}>
  2640. <Button className="set-submit" type="primary" htmlType="submit" id="change_keep" style={{marginLeft:'60px'}}>保存</Button>
  2641. <Button className="set-submit" type="ghost" onClick={this.addcontactModulcancel} id='change_rem'>取消</Button>
  2642. </Row>
  2643. </Spin>
  2644. </Form>
  2645. </Modal>
  2646. <Modal
  2647. footer=''
  2648. title="业务意向详情"
  2649. width='1000px'
  2650. visible={this.state.businessModul}
  2651. onOk={this.businessIntentionOk}
  2652. onCancel={this.businessIntentionCancel}
  2653. >
  2654. <div className="clearfix">
  2655. <Form horizontal id="demand-form" onSubmit={this.passworldSubmit}>
  2656. <Spin spinning={this.state.loading}>
  2657. <div className="clearfix">
  2658. <FormItem className="half-item"
  2659. {...formItemLayout}
  2660. label="意向业务名称" >
  2661. <span>{getCompanyIntention(this.state.businessGlossoryId)}</span>
  2662. </FormItem>
  2663. <FormItem className="half-item"
  2664. {...formItemLayout}
  2665. label="意向时间" >
  2666. <span>{this.state.createTime}</span>
  2667. </FormItem>
  2668. <FormItem className="half-item"
  2669. {...formItemLayout}
  2670. label="客户名称" >
  2671. <span>{this.state.identifyName}</span>
  2672. </FormItem>
  2673. <FormItem className="half-item"
  2674. {...formItemLayout}
  2675. label="营销员" >
  2676. <span>{this.state.adminName}</span>
  2677. </FormItem>
  2678. <FormItem className="half-item"
  2679. {...formItemLayout}
  2680. label="意向业务进度" >
  2681. <span>{getfllowSituation(this.state.followSituation)}</span>
  2682. </FormItem>
  2683. <FormItem className="half-item"
  2684. {...formItemLayout}
  2685. label="业务客户状态" >
  2686. <span>{getcustomerStatue(this.state.customerStatus)}</span>
  2687. </FormItem>
  2688. </div>
  2689. <div className="clearfix">
  2690. <FormItem className="half-item"
  2691. {...formItemLayout}
  2692. label="业务意向说明" >
  2693. <span>{this.state.remarks}</span>
  2694. </FormItem>
  2695. </div>
  2696. <div className="clearfix">
  2697. <div style={{fontSize:'18px',lineHeight:'24px',marginBottom:'10px'}}>业务跟进</div>
  2698. <div className="clearfix">
  2699. <Spin spinning={this.state.loading}>
  2700. <Table
  2701. pagination={this.state.paginations}
  2702. columns={this.state.businessFollowList}
  2703. dataSource={this.state.visitArrList}
  2704. />
  2705. </Spin>
  2706. </div>
  2707. </div>
  2708. </Spin>
  2709. </Form>
  2710. </div>
  2711. </Modal>
  2712. <Modal
  2713. footer=''
  2714. title="业务跟进详情"
  2715. width='600px'
  2716. visible={this.state.businessFollowModul}
  2717. onOk={this.businessFollowOk}
  2718. onCancel={this.businessFollowCancel}
  2719. >
  2720. <div className="clearfix">
  2721. <Form horizontal id="demand-form" onSubmit={this.passworldSubmit}>
  2722. <Spin spinning={this.state.loading}>
  2723. <div className="clearfix">
  2724. <FormItem className="half-item"
  2725. {...formItemLayout}
  2726. label="意向业务名称" >
  2727. <span>{getCompanyIntention(this.state.businessGlossoryIds)}</span>
  2728. </FormItem>
  2729. <FormItem className="half-item"
  2730. {...formItemLayout}
  2731. label="意向时间" >
  2732. <span>{this.state.createTimes}</span>
  2733. </FormItem>
  2734. <FormItem className="half-item"
  2735. {...formItemLayout}
  2736. label="客户名称" >
  2737. <span>{this.state.identifyNames}</span>
  2738. </FormItem>
  2739. <FormItem className="half-item"
  2740. {...formItemLayout}
  2741. label="营销员" >
  2742. <span>{this.state.adminNames}</span>
  2743. </FormItem>
  2744. <FormItem className="half-item"
  2745. {...formItemLayout}
  2746. label="意向业务进度" >
  2747. <span>{getfllowSituation(this.state.followSituations)}</span>
  2748. </FormItem>
  2749. <FormItem className="half-item"
  2750. {...formItemLayout}
  2751. label="业务客户状态" >
  2752. <span>{getcustomerStatue(this.state.customerStatuss)}</span>
  2753. </FormItem>
  2754. </div>
  2755. <div className="clearfix">
  2756. <FormItem className="half-item"
  2757. {...formItemLayout}
  2758. label="业务意向说明" >
  2759. <span>{this.state.remarkss}</span>
  2760. </FormItem>
  2761. </div>
  2762. <div className="clearfix">
  2763. <div style={{fontSize:'18px',lineHeight:'30px'}}>拜访情况</div>
  2764. <FormItem className="half-item"
  2765. {...formItemLayout}
  2766. label="拜访方式" >
  2767. <span>{getContactType(this.state.contactTypes)}</span>
  2768. </FormItem>
  2769. <FormItem className="half-item"
  2770. {...formItemLayout}
  2771. label="联系人" >
  2772. <span>{this.state.contactss}</span>
  2773. </FormItem>
  2774. <FormItem className="half-item"
  2775. {...formItemLayout}
  2776. label="联系电话" >
  2777. <span>{this.state.contactMobiles}</span>
  2778. </FormItem>
  2779. <FormItem className="half-item"
  2780. {...formItemLayout}
  2781. label="拜访时间" >
  2782. <span>{this.state.followTimes}</span>
  2783. </FormItem>
  2784. <FormItem className="half-item"
  2785. {...formItemLayout}
  2786. label="拜访人" >
  2787. <span>{this.state.adminNames}</span>
  2788. </FormItem>
  2789. <div className="clearfix">
  2790. <FormItem className="half-item"
  2791. {...formItemLayout}
  2792. label="拜访备注" >
  2793. <span>{this.state.results}</span>
  2794. </FormItem>
  2795. </div>
  2796. </div>
  2797. </Spin>
  2798. </Form>
  2799. </div>
  2800. </Modal>
  2801. </div >
  2802. );
  2803. }
  2804. }));
  2805. export default MyClient;