myClientDesc.jsx 60 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349
  1. import React from 'react';
  2. import { Tabs, Table, Icon, Tooltip, Modal, message, AutoComplete, Spin, DatePicker,Upload, Input, InputNumber, Select,TimePicker, Button, Radio, Form, Cascader, Tag, Switch } from 'antd';
  3. import './myClient.less';
  4. import ajax from 'jquery/src/ajax/xhr.js';
  5. import moment from 'moment';
  6. import $ from 'jquery/src/ajax';
  7. import { areaSelect } from '../../NewDicProvinceList';
  8. import { maturityList, innovationList, transferModeList,cityArr ,newFollow,customerStatus,intentionalService,tag} from '../../dataDic';
  9. import { IndustryObject, getIndustryCategory } from '../../DicIndustryList.js';
  10. import { beforeUploadFile, splitUrl, companySearch, getTransferMode, getAchievementCategory, getTechAuditStatus, getDemandType, getMaturity, getInnovation,beforeUpload, getBase64,getsex,getCompanyIntention,getcityArr,getfllowSituation,getcustomerStatue} from '../../tools.js';
  11. import throttle from '../../throttle.js';
  12. const KeyWordTagGroup = React.createClass({
  13. getInitialState() {
  14. return {
  15. tags: [],
  16. inputVisible: false,
  17. inputValue: ''
  18. };
  19. },
  20. handleClose(removedTag) {
  21. const tags = this.state.tags.filter(tag => tag !== removedTag);
  22. this.props.tagsArr(tags);
  23. this.setState({ tags });
  24. },
  25. showInput() {
  26. this.setState({ inputVisible: true }, () => this.input.focus());
  27. },
  28. handleInputChange(e) {
  29. this.setState({ inputValue: e.target.value });
  30. },
  31. handleInputConfirm() {
  32. const state = this.state;
  33. const inputValue = state.inputValue;
  34. let tags = state.tags;
  35. if (inputValue && tags.indexOf(inputValue) === -1 && inputValue.replace(/(^\s*)|(\s*$)/g, "").length != 0) {
  36. tags = [...tags, inputValue.replace(/(^\s*)|(\s*$)/g, "")];
  37. };
  38. this.props.tagsArr(tags);
  39. this.setState({
  40. tags,
  41. inputVisible: false,
  42. inputValue: '',
  43. });
  44. },
  45. componentWillMount() {
  46. this.state.tags = this.props.keyWordArr;
  47. },
  48. componentWillReceiveProps(nextProps) {
  49. if (this.props.keyWordArr != nextProps.keyWordArr) {
  50. this.state.tags = nextProps.keyWordArr;
  51. };
  52. },
  53. render() {
  54. const { tags, inputVisible, inputValue } = this.state;
  55. return (
  56. <div className="keyWord-tips">
  57. {tags.map((tag, index) => {
  58. const isLongTag = tag.length > 10;
  59. const tagElem = (
  60. <Tag key={tag} closable={index !== -1} afterClose={() => this.handleClose(tag)}>
  61. {isLongTag ? `${tag.slice(0, 10)}...` : tag}
  62. </Tag>
  63. );
  64. return isLongTag ? <Tooltip key={tag} title={tag}>{tagElem}</Tooltip> : tagElem;
  65. })}
  66. {inputVisible && (
  67. <Input
  68. ref={input => this.input = input}
  69. type="text"
  70. style={{ width: 78 }}
  71. value={inputValue}
  72. onChange={this.handleInputChange}
  73. onBlur={this.handleInputConfirm}
  74. onPressEnter={this.handleInputConfirm}
  75. />
  76. )}
  77. {!inputVisible && <Button className="addtips" type="dashed" disabled={tags.length > 9 ? true : false} onClick={this.showInput}>+ 新关键词</Button>}
  78. </div>
  79. );
  80. }
  81. });
  82. const PicturesWall = React.createClass({
  83. getInitialState() {
  84. return {
  85. previewVisible: false,
  86. previewImage: '',
  87. fileList: [],
  88. }
  89. },
  90. handleCancel() {
  91. this.setState({ previewVisible: false })
  92. },
  93. handlePreview(file) {
  94. this.setState({
  95. previewImage: file.url || file.thumbUrl,
  96. previewVisible: true,
  97. });
  98. },
  99. handleChange(info) {
  100. let fileList = info.fileList;
  101. this.setState({ fileList });
  102. this.props.fileList(fileList);
  103. },
  104. componentWillReceiveProps(nextProps) {
  105. this.state.fileList = nextProps.pictureUrl;
  106. },
  107. render() {
  108. const { previewVisible, previewImage, fileList } = this.state;
  109. const uploadButton = (
  110. <div>
  111. <Icon type="plus" />
  112. <div className="ant-upload-text">点击上传</div>
  113. </div>
  114. );
  115. return (
  116. <div className="clearfix">
  117. <Upload
  118. action={globalConfig.context + "/api/admin/achievement/uploadPicture"}
  119. data={{ 'sign': this.props.pictureSign }}
  120. listType="picture-card"
  121. fileList={fileList}
  122. onPreview={this.handlePreview}
  123. onChange={this.handleChange} >
  124. {fileList.length >= 5 ? null : uploadButton}
  125. </Upload>
  126. <Modal maskClosable={false} visible={previewVisible} footer={null} onCancel={this.handleCancel}>
  127. <img alt="example" style={{ width: '100%' }} src={previewImage} />
  128. </Modal>
  129. </div>
  130. );
  131. }
  132. });
  133. const AchievementDetailShow = Form.create()(React.createClass({
  134. getInitialState() {
  135. return {
  136. loading: false,
  137. buttonLoading: false,
  138. contactsObj: {},
  139. data: {},
  140. tags: [],
  141. technicalPictureUrl: [],
  142. coverImg: [],
  143. maturityPictureUrl: [],
  144. textFileList: [],
  145. techPlanFileList: [],
  146. businessPlanFileList: []
  147. };
  148. },
  149. //鼠标点击整行的时候的函数
  150. loadData(id, detailApiUrl) {
  151. this.setState({
  152. loading: true
  153. });
  154. $.ajax({
  155. method: "post",
  156. dataType: "json",
  157. crossDomain: false,
  158. url: globalConfig.context + detailApiUrl,
  159. data: {
  160. id: id
  161. },
  162. success: function (data) {
  163. let thisData = data.data;
  164. if (!thisData) {
  165. if (data.error && data.error.length) {
  166. message.warning(data.error[0].message);
  167. };
  168. thisData = {};
  169. };
  170. this.setState({
  171. data: thisData,
  172. orgDisplay: thisData.ownerType,
  173. switchValue: Boolean(!thisData.ownerId),
  174. radios:thisData.hot==='1'?true:false,
  175. tags: thisData.keyword ? (thisData.keyword.replace(/(,|、)/g, ",")).split(',') : [],
  176. technicalPictureUrl: thisData.technicalPictureUrl ? splitUrl(thisData.technicalPictureUrl, ',', globalConfig.avatarHost + '/upload') : [],
  177. coverImg: thisData.coverImg ? splitUrl(thisData.coverImg, ',', globalConfig.avatarHost + '/upload') : [],
  178. maturityPictureUrl: thisData.maturityPictureUrl ? splitUrl(thisData.maturityPictureUrl, ',', globalConfig.avatarHost + '/upload') : [],
  179. });
  180. if (thisData.ownerId) {
  181. this.getContactsList(thisData.ownerId);
  182. };
  183. console.log(thisData);
  184. }.bind(this),
  185. }).always(function () {
  186. this.setState({
  187. loading: false
  188. });
  189. }.bind(this));
  190. },
  191. offShelf() {
  192. this.setState({
  193. loading: true
  194. });
  195. $.ajax({
  196. method: "post",
  197. dataType: "json",
  198. crossDomain: false,
  199. url: globalConfig.context + "/api/admin/achievement/offShelf",
  200. data: { "id": this.props.data.id }
  201. }).done(function (data) {
  202. if (!data.error.length) {
  203. message.success('撤销成功!');
  204. this.setState({
  205. visible: false,
  206. releaseSubmitVisible: false
  207. });
  208. this.props.handleOk();
  209. } else {
  210. message.warning(data.error[0].message);
  211. }
  212. }.bind(this));
  213. },
  214. modifyBroker() {
  215. this.props.form.validateFields((err, values) => {
  216. if (!err) {
  217. this.setState({
  218. loading: true
  219. });
  220. $.ajax({
  221. method: "POST",
  222. dataType: "json",
  223. crossDomain: false,
  224. url: globalConfig.context + '/api/admin/audit/modifyAchievementTechBroker',
  225. data: {
  226. id: this.props.data.id,
  227. techBrokerId: values.modifyTechBrokerId
  228. }
  229. }).done(function (data) {
  230. this.state.auditStatus = 0;
  231. this.setState({
  232. loading: false
  233. });
  234. if (data.error && data.error.length) {
  235. message.warning(data.error[0].message);
  236. } else {
  237. message.success('保存成功!');
  238. this.props.handleOk();
  239. };
  240. }.bind(this));
  241. }
  242. });
  243. },
  244. formSubmit() {
  245. this.props.form.validateFields((err, values) => {
  246. if (!err) {
  247. this.setState({
  248. loading: true
  249. });
  250. $.ajax({
  251. method: "POST",
  252. dataType: "json",
  253. crossDomain: false,
  254. url: globalConfig.context + '/api/admin/audit/achievement',
  255. data: {
  256. id: this.props.data.id,
  257. techBroderId: values.techBrokerId,
  258. auditStatus: values.auditStatus
  259. }
  260. }).done(function (data) {
  261. this.state.auditStatus = 0;
  262. this.setState({
  263. loading: false
  264. });
  265. if (!data.error.length) {
  266. message.success('保存成功!');
  267. this.setState({
  268. formSubmitVisible: false
  269. });
  270. this.props.handleOk();
  271. } else {
  272. message.warning(data.error[0].message);
  273. };
  274. }.bind(this));
  275. }
  276. });
  277. },
  278. handleSubmit(e) {
  279. e.preventDefault();
  280. this.props.form.validateFields((err, values) => {
  281. if (values.auditStatus == 4) {
  282. this.setState({
  283. formSubmitVisible: true
  284. });
  285. } else {
  286. this.formSubmit();
  287. };
  288. });
  289. },
  290. buildMatchList() {
  291. this.setState({
  292. buttonLoading: true
  293. });
  294. $.ajax({
  295. method: "POST",
  296. dataType: "json",
  297. crossDomain: false,
  298. url: globalConfig.context + '/api/admin/achievement/matchDemand',
  299. data: {
  300. id: this.props.data.id,
  301. }
  302. }).done(function (data) {
  303. this.setState({
  304. buttonLoading: false
  305. });
  306. if (!data.error.length) {
  307. message.success('匹配完成!匹配到' + data.data + '条记录');
  308. } else {
  309. message.warning(data.error[0].message);
  310. };
  311. }.bind(this));
  312. },
  313. getContactsList(theUid) {
  314. $.ajax({
  315. method: "get",
  316. dataType: "json",
  317. crossDomain: false,
  318. url: globalConfig.context + "/api/admin/findCustomer",
  319. data: {
  320. id: theUid
  321. },
  322. success: function (data) {
  323. if (!data.data) {
  324. if (data.error && data.error.length) {
  325. message.warning(data.error[0].message);
  326. return;
  327. };
  328. } else {
  329. this.setState({
  330. contactsObj: data.data || {}
  331. });
  332. };
  333. }.bind(this),
  334. });
  335. },
  336. componentWillMount() {
  337. this.loadData(this.props.data.id, this.props.detailApiUrl);
  338. },
  339. componentWillReceiveProps(nextProps) {
  340. if (!this.props.visible && nextProps.visible) {
  341. this.loadData(nextProps.data.id, nextProps.detailApiUrl);
  342. this.state.textFileList = [];
  343. this.state.techPlanFileList = [];
  344. this.state.businessPlanFileList = [];
  345. this.props.form.resetFields();
  346. };
  347. },
  348. render() {
  349. const theData = this.state.data || {};
  350. const { getFieldDecorator } = this.props.form;
  351. const FormItem = Form.Item
  352. const formItemLayout = {
  353. labelCol: { span: 8 },
  354. wrapperCol: { span: 14 },
  355. };
  356. return (
  357. <Form horizontal onSubmit={this.handleSubmit} id="demand-form">
  358. <Spin spinning={this.state.loading}>
  359. <div className="clearfix">
  360. <FormItem className="half-item"
  361. {...formItemLayout}
  362. label="客户类型5555" >
  363. <span>{theData._shareType}</span>
  364. </FormItem>
  365. <div className="clearfix" style={{marginLeft:'40px',marginBottom:'20px',color:'#000000'}}>基本资料:</div>
  366. </div>
  367. {/* <FormItem className="half-item"
  368. {...formItemLayout}
  369. label="录入时间" >
  370. {getFieldDecorator('createTime', {
  371. initialValue: theData.createTime ? moment(theData.createTime) : null
  372. })(
  373. <DatePicker />
  374. )}
  375. </FormItem> */}
  376. <FormItem className="half-item"
  377. {...formItemLayout}
  378. label="跟单人" >
  379. <span>{theData.adminName}</span>
  380. </FormItem>
  381. <div className="clearfix" style={{marginLeft:'40px',marginBottom:'20px',color:'#000000'}}>公司资料:</div>
  382. <div>
  383. <FormItem className="half-item"
  384. {...formItemLayout}
  385. label="公司名称" >
  386. {getFieldDecorator('companyName', {
  387. rules: [{ required: true, message: '此项为必填项!' }],
  388. initialValue: theData.companyName
  389. })(
  390. <Input />
  391. )}
  392. </FormItem>
  393. <FormItem className="half-item"
  394. {...formItemLayout}
  395. label="公司行业" >
  396. {getFieldDecorator('companyIndustry', {
  397. initialValue: theData.companyIndustry
  398. })(
  399. <Input />
  400. )}
  401. </FormItem>
  402. <FormItem className="half-item"
  403. {...formItemLayout}
  404. label="意向服务" >
  405. {getFieldDecorator('companyIntention', {
  406. rules: [{ required: true, message: '此项为必填项!' }],
  407. initialValue: theData.companyIntention
  408. })(
  409. <Select placeholder="选择服务类型" >
  410. {
  411. intentionalService.map(function (item) {
  412. return <Select.Option key={item.value} >{item.key}</Select.Option>
  413. })
  414. }
  415. </Select>
  416. )}
  417. </FormItem>
  418. <FormItem className="half-item"
  419. {...formItemLayout}
  420. label="地区" >
  421. {getFieldDecorator('locationProvince', {
  422. initialValue: theData.locationProvince
  423. })(
  424. <Select placeholder="选择地区" style={{ width: 160 }} >
  425. {
  426. cityArr.map(function (item) {
  427. return <Select.Option key={item.value} >{item.key}</Select.Option>
  428. })
  429. }
  430. </Select>
  431. )}
  432. </FormItem>
  433. <FormItem className="half-item"
  434. {...formItemLayout}
  435. label="最新跟进" >
  436. {getFieldDecorator('followSituation', {
  437. rules: [{ required: true, message: '此项为必填项!' }],
  438. initialValue: getfllowSituation(theData.followSituation)
  439. })(
  440. <Select placeholder="选择跟进进度" style={{ width: 160 }} >
  441. {
  442. newFollow.map(function (item) {
  443. return <Select.Option key={item.value} >{item.key}</Select.Option>
  444. })
  445. }
  446. </Select>
  447. )}
  448. </FormItem>
  449. <FormItem className="half-item"
  450. {...formItemLayout}
  451. label="客户状态" >
  452. {getFieldDecorator('customerStatus', {
  453. rules: [{ required: true, message: '此项为必填项!' }],
  454. initialValue: getcustomerStatue(theData.customerStatus)
  455. })(
  456. <Select placeholder="选择客户状态" style={{ width: 160 }} >
  457. {
  458. customerStatus.map(function (item) {
  459. return <Select.Option key={item.value} >{item.key}</Select.Option>
  460. })
  461. }
  462. </Select>
  463. )}
  464. </FormItem>
  465. <FormItem className="half-item"
  466. {...formItemLayout}
  467. label="详细地址" >
  468. {getFieldDecorator('adress', {
  469. initialValue: theData.adress
  470. })(
  471. <Input type="text" rows={1}/>
  472. )}
  473. </FormItem>
  474. <div className="clearfix">
  475. <FormItem
  476. labelCol={{ span: 4 }}
  477. wrapperCol={{ span: 18 }}
  478. label="备注" >
  479. {getFieldDecorator('remarks', {
  480. initialValue: theData.remarks
  481. })(
  482. <Input type="textarea" rows={4} />
  483. )}
  484. </FormItem>
  485. </div>
  486. </div>
  487. <div className="clearfix" style={{marginLeft:'40px',marginBottom:'20px',color:'#000000'}}>联系资料:</div>
  488. <div>
  489. <FormItem className="half-item"
  490. {...formItemLayout}
  491. label="姓名" >
  492. {getFieldDecorator('contactName', {
  493. rules: [{ required: true, message: '此项为必填项!' }],
  494. initialValue: theData.contactName
  495. })(
  496. <Input type="text" rows={1}/>
  497. )}
  498. </FormItem>
  499. <FormItem className="half-item"
  500. {...formItemLayout}
  501. label="性别" >
  502. {getFieldDecorator('sex', {
  503. rules: [{ required: true, message: '此项为必填项!' }],
  504. initialValue:theData.sex
  505. })(
  506. <Radio.Group onChange={(e) => { this.setState({ radios: e.target.value }); }}>
  507. <Radio value="0">男</Radio>
  508. <Radio value="1">女</Radio>
  509. </Radio.Group>
  510. )}
  511. </FormItem>
  512. <FormItem className="half-item"
  513. {...formItemLayout}
  514. label="手机号码" >
  515. {getFieldDecorator('telNum', {
  516. rules: [{ required: true, message: '此项为必填项!' }],
  517. initialValue: theData.telNum
  518. })(
  519. <Input type="text" rows={1}/>
  520. )}
  521. </FormItem>
  522. <FormItem className="half-item"
  523. {...formItemLayout}
  524. label="座机号" >
  525. {getFieldDecorator('mobile', {
  526. initialValue: theData.mobile
  527. })(
  528. <Input type="text" rows={1}/>
  529. )}
  530. </FormItem>
  531. <FormItem className="half-item"
  532. {...formItemLayout}
  533. label="QQ号码" >
  534. {getFieldDecorator('qq', {
  535. initialValue: theData.qq
  536. })(
  537. <Input type="text" rows={1}/>
  538. )}
  539. </FormItem>
  540. <FormItem className="half-item"
  541. {...formItemLayout}
  542. label="邮箱号" >
  543. {getFieldDecorator('email', {
  544. initialValue: theData.email
  545. })(
  546. <Input type="text" rows={1}/>
  547. )}
  548. </FormItem>
  549. <FormItem className="half-item"
  550. {...formItemLayout}
  551. label="微信" >
  552. {getFieldDecorator('wechat', {
  553. initialValue: theData.wechat
  554. })(
  555. <Input type="text" rows={1}/>
  556. )}
  557. </FormItem>
  558. <FormItem className="half-item"
  559. {...formItemLayout}
  560. label="部门" >
  561. {getFieldDecorator('depatrment', {
  562. initialValue: theData.depatrment
  563. })(
  564. <Input type="text" rows={1}/>
  565. )}
  566. </FormItem>
  567. <FormItem className="half-item"
  568. {...formItemLayout}
  569. label="职位" >
  570. {getFieldDecorator('customerPosition', {
  571. initialValue: theData.customerPosition
  572. })(
  573. <Input type="text" rows={1}/>
  574. )}
  575. </FormItem>
  576. </div>
  577. <div className="clearfix" style={{paddingLeft:"200px",marginBottom:"20px"}}>
  578. <Button className="set-submit" type="primary" htmlType="submit" id="change_keep" style={{marginTop:"20px"}}>保存</Button>
  579. <Button className="set-submit" type="ghost" onClick={this.props.closeDesc} id='change_rem' style={{marginTop:"20px"}}>取消</Button>
  580. </div>
  581. {/* <FormItem wrapperCol={{ span: 12, offset: 4 }}>
  582. {theData.auditStatus == 2 ? <Button className="set-submit" type="primary" htmlType="submit">保存</Button> : <span></span>}
  583. {theData.auditStatus == 3 ? <Button className="set-submit" type="primary" onClick={() => { this.modifyBroker(); }}>保存</Button> : <span></span>}
  584. <Button className="set-submit" type="ghost" onClick={this.props.closeDesc}>取消</Button> */}
  585. {/*{window.showAuditStatus ? <Button className="set-submit" loading={this.state.buttonLoading} type="primary" onClick={this.buildMatchList}>生成匹配列表</Button> : <span></span>}*/}
  586. {/* </FormItem>
  587. */}
  588. </Spin>
  589. </Form >
  590. )
  591. }
  592. }));
  593. const AchievementDetailForm = Form.create()(React.createClass({
  594. getInitialState() {
  595. return {
  596. loading: false,
  597. auditStatus: 0,
  598. textFileList: [],
  599. switchValue: false,
  600. radios: false,
  601. techPlanFileList: [],
  602. data: {},
  603. tags: [],
  604. technicalPictureUrl: [],
  605. coverImg: [],
  606. maturityPictureUrl: [],
  607. businessPlanFileList: [],
  608. dataSource: [],
  609. };
  610. },
  611. loadData(id, detailApiUrl) {
  612. this.setState({
  613. loading: true
  614. });
  615. $.ajax({
  616. method: "get",
  617. dataType: "json",
  618. crossDomain: false,
  619. url: globalConfig.context + detailApiUrl,
  620. data: {
  621. id: id
  622. },
  623. success: function (data) {
  624. let thisData = data.data;
  625. if (!thisData) {
  626. if (data.error && data.error.length) {
  627. message.warning(data.error[0].message);
  628. };
  629. thisData = {};
  630. };
  631. this.setState({
  632. data: thisData,
  633. orgDisplay: thisData.ownerType,
  634. switchValue: Boolean(!thisData.ownerId),
  635. radios: thisData.hot == '1' ? true : false,
  636. transferPriceDis: thisData.transferMode == 1 ? true : false,
  637. tags: thisData.keyword ? (thisData.keyword.replace(/(,|、)/g, ",")).split(',') : [],
  638. technicalPictureUrl: thisData.technicalPictureUrl ? splitUrl(thisData.technicalPictureUrl, ',', globalConfig.avatarHost + '/upload') : [],
  639. coverImg: thisData.coverImg ? splitUrl(thisData.coverImg, ',', globalConfig.avatarHost + '/upload') : [],
  640. maturityPictureUrl: thisData.maturityPictureUrl ? splitUrl(thisData.maturityPictureUrl, ',', globalConfig.avatarHost + '/upload') : [],
  641. });
  642. if (thisData.ownerType == "1" && thisData.ownerId) {
  643. this.getContactsList(thisData.ownerId);
  644. };
  645. }.bind(this),
  646. }).always(function () {
  647. this.setState({
  648. loading: false
  649. });
  650. }.bind(this));
  651. },
  652. getContactsList(theUid) {
  653. $.ajax({
  654. method: "get",
  655. dataType: "json",
  656. crossDomain: false,
  657. url: globalConfig.context + "/api/admin/getContacts",
  658. data: {
  659. uid: theUid
  660. },
  661. success: function (data) {
  662. let theOption = [];
  663. if (!data.data) {
  664. if (data.error && data.error.length) {
  665. message.warning(data.error[0].message);
  666. return;
  667. };
  668. };
  669. for (let item in data.data) {
  670. let theData = data.data[item];
  671. theOption.push(
  672. <Select.Option value={item} key={theData}>{theData}</Select.Option>
  673. );
  674. };
  675. this.setState({
  676. contactsOption: theOption
  677. });
  678. }.bind(this),
  679. });
  680. },
  681. getTagsArr(e) {
  682. this.setState({ tags: e });
  683. },
  684. getMaturityPictureUrl(e) {
  685. this.setState({ maturityPictureUrl: e });
  686. },
  687. getTechnicalPictureUrl(e) {
  688. this.setState({ technicalPictureUrl: e });
  689. },
  690. getcoverImg(e) {
  691. this.setState({coverImg: e });
  692. },
  693. handleSearch(e) {
  694. if (this.props.detailApiUrl.indexOf('org') != -1) {
  695. $.ajax({
  696. method: "get",
  697. dataType: "json",
  698. crossDomain: false,
  699. url: globalConfig.context + "/api/admin/achievement/orgOwner",
  700. data: { name: e },
  701. success: function (data) {
  702. let theArr = [];
  703. let theObj = {};
  704. if (!data.data) {
  705. if (data.error && data.error.length) {
  706. message.warning(data.error[0].message);
  707. };
  708. } else if (!$.isEmptyObject(data.data)) {
  709. data.data.map(function (item) {
  710. theArr.push(item.unitName);
  711. theObj[item.unitName] = item.uid;
  712. });
  713. };
  714. this.setState({
  715. dataSource: theArr,
  716. dataSourceObj: theObj
  717. });
  718. }.bind(this),
  719. });
  720. } else {
  721. $.ajax({
  722. method: "get",
  723. dataType: "json",
  724. crossDomain: false,
  725. url: globalConfig.context + "/api/admin/achievement/userOwner",
  726. data: { name: e },
  727. success: function (data) {
  728. let theArr = [];
  729. let theObj = {};
  730. if (!data.data) {
  731. if (data.error && data.error.length) {
  732. message.warning(data.error[0].message);
  733. };
  734. } else if (!$.isEmptyObject(data.data)) {
  735. for (let item in data.data) {
  736. theArr.push(data.data[item]);
  737. theObj[data.data[item]] = item;
  738. };
  739. };
  740. this.setState({
  741. dataSource: theArr,
  742. dataSourceObj: theObj
  743. });
  744. }.bind(this),
  745. });
  746. };
  747. },
  748. handleSubmit(e) {
  749. e.preventDefault();
  750. this.props.form.validateFields((err, values) => {
  751. //url转化
  752. let theTechnicalPictureUrl = [];
  753. if (this.state.technicalPictureUrl.length) {
  754. let picArr = [];
  755. this.state.technicalPictureUrl.map(function (item) {
  756. picArr.push(item.response.data);
  757. });
  758. theTechnicalPictureUrl = picArr.join(",");
  759. };
  760. let thecoverImg = [];
  761. if (this.state.coverImg.length) {
  762. let picArr = [];
  763. this.state.coverImg.map(function (item) {
  764. picArr.push(item.response.data);
  765. });
  766. thecoverImg = picArr.join(",");
  767. };
  768. let theMaturityPictureUrl = [];
  769. if (this.state.maturityPictureUrl.length) {
  770. let picArr = [];
  771. this.state.maturityPictureUrl.map(function (item) {
  772. picArr.push(item.response.data);
  773. });
  774. theMaturityPictureUrl = picArr.join(",");
  775. };
  776. if (!err) {
  777. this.setState({
  778. loading: true
  779. });
  780. $.ajax({
  781. method: "POST",
  782. dataType: "json",
  783. crossDomain: false,
  784. url: this.props.data.id ? globalConfig.context + '/api/admin/customer/updCustomer' : globalConfig.context + '/api/admin/customer/addCustomer',
  785. data: {
  786. id: this.props.data.id, //编号
  787. customerTyp :values.customerTyp ,//客户信息 1
  788. // createTime: values.createTime ? values.createTime.format('YYYY-MM-DD') : undefined,//时间 1\
  789. companyIntention: this.props.data.companyIntention,
  790. companyName: values.companyName,//公司名称 1
  791. companyIndustry: values.companyIndustry,//公司行业
  792. companyIntention: values.companyIntention,//公司意向1
  793. tag: values.tag,
  794. locationProvince: values.locationProvince,//省份1
  795. adress: values.adress,//详细地址1
  796. remarks: values.remarks,//备注1
  797. followSituation: values.followSituation,//最新跟进1
  798. customerStatus: values.customerStatus,//客户状态1
  799. name: values.name,//客户姓名1
  800. mobile: values.mobile,//座机1
  801. telNum: values.telNum,//手机号码1
  802. sex: values.sex,//性别1
  803. customerPosition: values.customerPosition,//职位1
  804. wechat: values.wechat,//微信号1
  805. qq: values.qq,//qq 1
  806. depatrment: values.depatrment,//部门 1
  807. email: values.email,//邮箱 1
  808. shareTyp:0,
  809. followDates:(values.createTime ? values.createTime.format('YYYY-MM-DD'):undefined)+" "+(values.createTim ? values.createTim.format('YYYY:MM:DD'):undefined),//时间,
  810. primaryFlg:0,
  811. }
  812. }).done(function (data) {
  813. this.state.auditStatus = 0;
  814. this.setState({
  815. loading: false
  816. });
  817. if (!data.error.length) {
  818. message.success('保存成功!');
  819. this.props.handleOk();
  820. } else {
  821. message.warning(data.error[0].message);
  822. }
  823. }.bind(this));
  824. }
  825. });
  826. },
  827. componentWillMount() {
  828. this.state.therottleSearch = throttle(this.handleSearch, 1000, { leading: false }).bind(this);
  829. if (this.props.data && this.props.data.id) {
  830. this.loadData(this.props.data.id, this.props.detailApiUrl);
  831. };
  832. },
  833. componentWillReceiveProps(nextProps) {
  834. if (!this.props.visible && nextProps.visible) {
  835. if (nextProps.data && nextProps.data.id) {
  836. this.loadData(nextProps.data.id, nextProps.detailApiUrl);
  837. };
  838. this.state.data = {};
  839. this.state.tags = [];
  840. this.state.switchValue = false;
  841. this.state.radios = false;
  842. this.state.technicalPictureUrl = [];
  843. this.state.coverImg = [];
  844. this.state.maturityPictureUrl = [];
  845. this.state.textFileList = [];
  846. this.state.techPlanFileList = [];
  847. this.state.businessPlanFileList = [];
  848. this.props.form.resetFields();
  849. };
  850. },
  851. render() {
  852. const theData = this.state.data || {};
  853. const { getFieldDecorator } = this.props.form;
  854. const FormItem = Form.Item
  855. const formItemLayout = {
  856. labelCol: { span: 8 },
  857. wrapperCol: { span: 14 },
  858. };
  859. const { RangePicker } = DatePicker;
  860. return (
  861. <Form horizontal onSubmit={this.handleSubmit} id="demand-form">
  862. <Spin spinning={this.state.loading}>
  863. <div className="clearfix">
  864. <FormItem className="half-item"
  865. {...formItemLayout}
  866. label="客户类型" >
  867. {getFieldDecorator('customerTyp', {
  868. rules: [{ required: true, message: '此项为必填项!' }],
  869. initialValue: theData.customerTyp
  870. })(
  871. <Select placeholder="选择客户类型" style={{ width: 160 }} >
  872. <Select.Option value="0" >个人客户</Select.Option>
  873. <Select.Option value="1" >公司客户</Select.Option>
  874. </Select>
  875. )}
  876. </FormItem>
  877. <div className="clearfix" style={{marginLeft:'40px',marginBottom:'20px',color:'#000000'}}>基本资料:</div>
  878. <div>
  879. <FormItem className="half-item"
  880. {...formItemLayout}
  881. label="录入时间" >
  882. {getFieldDecorator('createTime', {
  883. initialValue: theData.createTime ? moment(theData.createTime) : null
  884. })(
  885. <DatePicker />
  886. )}
  887. {getFieldDecorator('createTim', {
  888. initialValue: theData.createTime ? moment(theData.createTime) : null
  889. })(
  890. <TimePicker />
  891. )}
  892. </FormItem>
  893. {/* <FormItem className="half-item" style={{marginLeft:'-160px'}}
  894. {...formItemLayout}
  895. label="" >
  896. </FormItem> */}
  897. <FormItem className="half-item"
  898. {...formItemLayout}
  899. label="跟单人" >
  900. {getFieldDecorator('ownerId', {
  901. initialValue: theData.ownerId
  902. })(
  903. <Input />
  904. )}
  905. </FormItem>
  906. </div>
  907. <div className="clearfix" style={{marginLeft:'40px',marginBottom:'20px',color:'#000000'}}>公司资料:</div>
  908. <div>
  909. <FormItem className="half-item"
  910. {...formItemLayout}
  911. label="公司名称" >
  912. {getFieldDecorator('companyName', {
  913. rules: [{ required: true, message: '此项为必填项!' }],
  914. initialValue: theData.companyName
  915. })(
  916. <Input />
  917. )}
  918. </FormItem>
  919. <FormItem className="half-item"
  920. {...formItemLayout}
  921. label="公司行业" >
  922. {getFieldDecorator('companyIndustry', {
  923. initialValue: theData.companyIndustry
  924. })(
  925. <Input />
  926. )}
  927. </FormItem>
  928. <FormItem className="half-item"
  929. {...formItemLayout}
  930. label="意向服务" >
  931. {getFieldDecorator('companyIntention', {
  932. rules: [{ required: true, message: '此项为必填项!' }],
  933. initialValue: getCompanyIntention(theData.companyIntention)
  934. })(
  935. <Select placeholder="选择服务类型" >
  936. {
  937. intentionalService.map(function (item) {
  938. return <Select.Option key={item.value} >{item.key}</Select.Option>
  939. })
  940. }
  941. </Select>
  942. )}
  943. </FormItem>
  944. <FormItem className="half-item"
  945. {...formItemLayout}
  946. label="地区" >
  947. {getFieldDecorator('locationProvince', {
  948. initialValue: getcityArr(theData.locationProvince)
  949. })(
  950. <Select placeholder="选择地区" style={{ width: 160 }} >
  951. {
  952. cityArr.map(function (item) {
  953. return <Select.Option key={item.value} >{item.key}</Select.Option>
  954. })
  955. }
  956. </Select>
  957. )}
  958. </FormItem>
  959. <FormItem className="half-item"
  960. {...formItemLayout}
  961. label="最新跟进" >
  962. {getFieldDecorator('followSituation', {
  963. rules: [{ required: true, message: '此项为必填项!' }],
  964. initialValue: getfllowSituation(theData.followSituation)
  965. })(
  966. <Select placeholder="选择跟进进度" style={{ width: 160 }} >
  967. {
  968. newFollow.map(function (item) {
  969. return <Select.Option key={item.value} >{item.key}</Select.Option>
  970. })
  971. }
  972. </Select>
  973. )}
  974. </FormItem>
  975. <FormItem className="half-item"
  976. {...formItemLayout}
  977. label="客户状态" >
  978. {getFieldDecorator('customerStatus', {
  979. rules: [{ required: true, message: '此项为必填项!' }],
  980. initialValue: getcustomerStatue(theData.customerStatus)
  981. })(
  982. <Select placeholder="选择客户状态" style={{ width: 160 }} >
  983. {
  984. customerStatus.map(function (item) {
  985. return <Select.Option key={item.value} >{item.key}</Select.Option>
  986. })
  987. }
  988. </Select>
  989. )}
  990. </FormItem>
  991. <FormItem className="half-item"
  992. {...formItemLayout}
  993. label="详细地址" >
  994. {getFieldDecorator('adress', {
  995. initialValue: theData.adress
  996. })(
  997. <Input />
  998. )}
  999. </FormItem>
  1000. <FormItem className="half-item"
  1001. {...formItemLayout}
  1002. label="标签" >
  1003. {getFieldDecorator('tag', {
  1004. initialValue: theData.tag
  1005. })(
  1006. <Select placeholder="选择客户标签" >
  1007. {
  1008. tag.map(function (item) {
  1009. return <Select.Option key={item.key} >{item.key}</Select.Option>
  1010. })
  1011. }
  1012. </Select>
  1013. )}
  1014. </FormItem>
  1015. <div className="clearfix">
  1016. <FormItem
  1017. labelCol={{ span: 4 }}
  1018. wrapperCol={{ span: 18 }}
  1019. label="备注" >
  1020. {getFieldDecorator('remarks', {
  1021. initialValue: theData.remarks
  1022. })(
  1023. <Input type="textarea" rows={4} />
  1024. )}
  1025. </FormItem>
  1026. </div>
  1027. </div>
  1028. <div className="clearfix" style={{marginLeft:'40px',marginBottom:'20px',color:'#000000'}}>联系资料:</div>
  1029. <div>
  1030. <FormItem className="half-item"
  1031. {...formItemLayout}
  1032. label="姓名" >
  1033. {getFieldDecorator('name', {
  1034. rules: [{ required: true, message: '此项为必填项!' }],
  1035. initialValue: theData.name
  1036. })(
  1037. <Input />
  1038. )}
  1039. </FormItem>
  1040. <FormItem className="half-item"
  1041. {...formItemLayout}
  1042. label="性别" >
  1043. {getFieldDecorator('sex', {
  1044. rules: [{ required: true, message: '此项为必填项!' }],
  1045. initialValue: getsex(theData.sex)
  1046. })(
  1047. <Radio.Group>
  1048. <Radio value="0">男</Radio>
  1049. <Radio value="1">女</Radio>
  1050. </Radio.Group>
  1051. )}
  1052. </FormItem>
  1053. <FormItem className="half-item"
  1054. {...formItemLayout}
  1055. label="手机号码" >
  1056. {getFieldDecorator('telNum', {
  1057. initialValue: theData.telNum
  1058. })(
  1059. <Input />
  1060. )}
  1061. </FormItem>
  1062. <FormItem className="half-item"
  1063. {...formItemLayout}
  1064. label="座机号" >
  1065. {getFieldDecorator('mobile', {
  1066. initialValue: theData.mobile
  1067. })(
  1068. <Input />
  1069. )}
  1070. </FormItem>
  1071. <FormItem className="half-item"
  1072. {...formItemLayout}
  1073. label="QQ号码" >
  1074. {getFieldDecorator('qq', {
  1075. initialValue: theData.qq
  1076. })(
  1077. <Input />
  1078. )}
  1079. </FormItem>
  1080. <FormItem className="half-item"
  1081. {...formItemLayout}
  1082. label="邮箱号" >
  1083. {getFieldDecorator('email', {
  1084. initialValue: theData.email
  1085. })(
  1086. <Input />
  1087. )}
  1088. </FormItem>
  1089. <FormItem className="half-item"
  1090. {...formItemLayout}
  1091. label="微信" >
  1092. {getFieldDecorator('wechat', {
  1093. initialValue: theData.wechat
  1094. })(
  1095. <Input />
  1096. )}
  1097. </FormItem>
  1098. <FormItem className="half-item"
  1099. {...formItemLayout}
  1100. label="部门" >
  1101. {getFieldDecorator('depatrment', {
  1102. initialValue: theData.depatrment
  1103. })(
  1104. <Input />
  1105. )}
  1106. </FormItem>
  1107. <FormItem className="half-item"
  1108. {...formItemLayout}
  1109. label="职位" >
  1110. {getFieldDecorator('customerPosition', {
  1111. initialValue: theData.customerPosition
  1112. })(
  1113. <Input />
  1114. )}
  1115. </FormItem>
  1116. </div>
  1117. </div>
  1118. <FormItem wrapperCol={{ span: 12, offset: 4 }}>
  1119. <Button className="set-submit" type="primary" htmlType="submit">保存</Button>
  1120. {/*<Button className="set-submit" type="ghost" onClick={(e) => { this.state.auditStatus = 1; }} htmlType="submit">发布</Button>*/}
  1121. <Button className="set-submit" type="ghost" onClick={this.props.closeDesc}>取消</Button>
  1122. </FormItem>
  1123. </Spin>
  1124. </Form >
  1125. )
  1126. }
  1127. }));
  1128. const AchievementDetail = React.createClass({
  1129. getInitialState() {
  1130. return {
  1131. visible: false,
  1132. tabsKey: 1,
  1133. loading: false,
  1134. columns: [
  1135. {
  1136. title: '客户信息',
  1137. dataIndex: 'id',
  1138. key: 'id',
  1139. render: text => {
  1140. switch (text) {
  1141. case "0":
  1142. return <span>个人客户</span>;
  1143. case "1":
  1144. return <span>公司客户</span>;
  1145. }
  1146. }
  1147. }, {
  1148. title: '名称',
  1149. dataIndex: 'companyNmae',
  1150. key: 'companyNmae',
  1151. }, {
  1152. title: '关键字',
  1153. dataIndex: 'keyword',
  1154. key: 'keyword',
  1155. }, {
  1156. title: '类型',
  1157. dataIndex: 'demandType',
  1158. key: 'demandType',
  1159. render: text => { return getDemandType(text); }
  1160. }, {
  1161. title: '所有人名称',
  1162. dataIndex: 'theName',
  1163. key: 'theName',
  1164. }, {
  1165. title: '发布时间',
  1166. dataIndex: 'releaseDateFormattedDate',
  1167. key: 'releaseDateFormattedDate',
  1168. }, {
  1169. title: '有效期限',
  1170. dataIndex: 'validityPeriodFormattedDate',
  1171. key: 'validityPeriodFormattedDate',
  1172. },
  1173. ],
  1174. dataSource: [],
  1175. };
  1176. },
  1177. getTechBrodersList() {
  1178. this.setState({
  1179. loading: true
  1180. });
  1181. $.ajax({
  1182. method: "get",
  1183. dataType: "json",
  1184. crossDomain: false,
  1185. url: globalConfig.context + "/api/admin/audit/techBroders",
  1186. success: function (data) {
  1187. if (!data.data) {
  1188. if (data.error && data.error.length) {
  1189. message.warning(data.error[0].message);
  1190. }
  1191. return;
  1192. };
  1193. let _me = this, theArr = [];
  1194. for (var item in data.data) {
  1195. theArr.push(
  1196. <Select.Option key={item}>{data.data[item]}</Select.Option>
  1197. )
  1198. };
  1199. this.setState({
  1200. techBrodersOption: theArr,
  1201. techBrodersObj: data.data
  1202. });
  1203. }.bind(this),
  1204. }).always(function () {
  1205. this.setState({
  1206. loading: false
  1207. });
  1208. }.bind(this));
  1209. },
  1210. getTableList() {
  1211. this.setState({
  1212. loading: true
  1213. });
  1214. $.ajax({
  1215. method: "get",
  1216. dataType: "json",
  1217. crossDomain: false,
  1218. url: globalConfig.context + "/api/admin/achievement/achievementDemand",
  1219. data: { id: this.props.data.id },
  1220. success: function (data) {
  1221. let theArr = [];
  1222. if (!data.data) {
  1223. if (data.error && data.error.length) {
  1224. message.warning(data.error[0].message);
  1225. };
  1226. } else if (data.data.length) {
  1227. for (let i = 0; i < data.data.length; i++) {
  1228. let thisdata = data.data[i];
  1229. theArr.push({
  1230. key: i,
  1231. id: thisdata.id,
  1232. serialNumber: thisdata.serialNumber,
  1233. createTime: thisdata.createTime,
  1234. name: thisdata.name,
  1235. keyword: thisdata.keyword,
  1236. demandType: thisdata.demandType,
  1237. theName: thisdata.username || thisdata.unitName,
  1238. releaseDateFormattedDate: thisdata.releaseDateFormattedDate,
  1239. validityPeriodFormattedDate: thisdata.validityPeriodFormattedDate,
  1240. coverImg: thisdata.coverImg,
  1241. hot: thisdata.hot,
  1242. });
  1243. };
  1244. };
  1245. this.setState({
  1246. dataSource: theArr,
  1247. });
  1248. }.bind(this),
  1249. }).always(function () {
  1250. this.setState({
  1251. loading: false
  1252. });
  1253. }.bind(this));
  1254. },
  1255. tableRowClick(record, index) {
  1256. window.open(globalConfig.context + '/portal/detail/demandDetail.html?id=' + record.id + '&type=' + record.dataCategory);
  1257. },
  1258. handleCancel(e) {
  1259. this.setState({
  1260. visible: false,
  1261. });
  1262. this.props.closeDesc(false);
  1263. },
  1264. handleOk(e) {
  1265. this.setState({
  1266. visible: false,
  1267. });
  1268. this.props.closeDesc(false, true);
  1269. },
  1270. componentWillMount() {
  1271. this.getTechBrodersList();
  1272. },
  1273. componentWillReceiveProps(nextProps) {
  1274. if (!this.state.visible && nextProps.showDesc) {
  1275. this.state.tabsKey = "1";
  1276. };
  1277. this.state.visible = nextProps.showDesc;
  1278. },
  1279. render() {
  1280. if (this.props.data) {
  1281. return (
  1282. <div className="patent-desc">
  1283. <Modal maskClosable={false} visible={this.state.visible}
  1284. onOk={this.checkPatentProcess} onCancel={this.handleCancel}
  1285. width='1000px'
  1286. footer=''
  1287. className="admin-desc-content">
  1288. <Spin spinning={this.state.loading}>
  1289. <Tabs activeKey={this.state.tabsKey}
  1290. onChange={(e) => {
  1291. this.setState({ tabsKey: e });
  1292. if (e == "2") {
  1293. this.getTableList();
  1294. };
  1295. }} >
  1296. <Tabs.TabPane tab="客户详情" key="1">
  1297. {(() => {
  1298. if (this.props.data.id && this.props.data.auditStatus != "0" && this.props.data.auditStatus != "4") {
  1299. return <AchievementDetailShow
  1300. data={this.props.data}
  1301. detailApiUrl={this.props.detailApiUrl}
  1302. techBrodersOption={this.state.techBrodersOption}
  1303. techBrodersObj={this.state.techBrodersObj}
  1304. closeDesc={this.handleCancel}
  1305. visible={this.state.visible}
  1306. handleOk={this.handleOk} />
  1307. } else {
  1308. return <AchievementDetailForm
  1309. data={this.props.data}
  1310. detailApiUrl={this.props.detailApiUrl}
  1311. achievementCategoryOption={this.props.achievementCategoryOption}
  1312. techBrodersObj={this.state.techBrodersObj}
  1313. closeDesc={this.handleCancel}
  1314. visible={this.state.visible}
  1315. handleOk={this.handleOk} />
  1316. };
  1317. })()}
  1318. </Tabs.TabPane>
  1319. </Tabs>
  1320. </Spin>
  1321. </Modal>
  1322. </div>
  1323. );
  1324. } else {
  1325. return <div></div>
  1326. }
  1327. },
  1328. });
  1329. export default AchievementDetail;