index.jsx 66 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731
  1. import React, { Component } from "react";
  2. import { View, Input, Button, Text, Picker, RadioGroup, Label, Radio } from "@tarojs/components";
  3. import Taro, { getCurrentInstance } from "@tarojs/taro";
  4. import { getProvince } from '../../utils/tools/index'
  5. import {
  6. AtSearchBar,
  7. AtCheckbox,
  8. AtTextarea,
  9. AtModal,
  10. AtModalHeader,
  11. AtModalContent,
  12. AtModalAction,
  13. AtInput,
  14. AtIcon,
  15. AtButton,
  16. AtTag,
  17. AtRadio
  18. } from "taro-ui";
  19. import Skeleton from "taro-skeleton";
  20. import {
  21. queryByUidAll,
  22. updateUserDate,
  23. updateUser,
  24. addOneContact,
  25. findCustomerContacts,
  26. updateMainContact,
  27. limitUser,
  28. getBusinessProjectByName,
  29. } from "../../utils/servers/servers";
  30. import "./index.less";
  31. import "taro-ui/dist/style/components/icon.scss";
  32. import "taro-ui/dist/style/components/textarea.scss";
  33. import "taro-ui/dist/style/components/modal.scss";
  34. import "taro-ui/dist/style/components/timeline.scss";
  35. import "taro-ui/dist/style/components/calendar.scss";
  36. import "taro-ui/dist/style/components/input.scss";
  37. import "taro-ui/dist/style/components/checkbox.scss";
  38. import "taro-ui/dist/style/components/search-bar.scss";
  39. import "taro-ui/dist/style/components/tag.scss";
  40. import MessageNoticebar from "../../components/common/messageNoticebar";
  41. import { industry, channelTypeList } from '../../utils/tools/config';
  42. import { getChannel } from "../../utils/tools";
  43. import Superior from "../../components/common/superior";
  44. import CheckboxPicker from "../../components/common/CheckboxPicker";
  45. import AddressPicker from "../../components/common/addressPicker"
  46. import InteractList from "./components/InteractList";
  47. class CustomerProfile extends Component {
  48. $instance = getCurrentInstance();
  49. constructor(props) {
  50. super(props);
  51. this.state = {
  52. upType: -1,
  53. isOpened: false,
  54. dtails: {},
  55. info: {},
  56. sector: {},
  57. isAdd: false,
  58. obj: {},
  59. userList: [],
  60. options: [],
  61. checkOptions: [],
  62. isSuperior: false,
  63. channe: {},
  64. isMask: false,
  65. addressPickerShow: false,
  66. region: [],
  67. customItem: [],
  68. multiplePickerShow: false,
  69. multiplePickerTitle: '',
  70. multiplePickerType: '',
  71. multiplePickerOptions: [],
  72. multiplePickerCheckedList: [],
  73. addItemShow: false,
  74. addItemType: '',
  75. addItemTitle: '',
  76. addItemInputVal: '',
  77. interactShow: false,
  78. interactShowType: '',
  79. interactTitle: ''
  80. };
  81. this.queryByUidAll = this.queryByUidAll.bind(this);
  82. this.update = this.update.bind(this);
  83. this.add = this.add.bind(this);
  84. this.getUserList = this.getUserList.bind(this);
  85. this.getBusinessProjectByName = this.getBusinessProjectByName.bind(this);
  86. this.onSearchChange = this.onSearchChange.bind(this);
  87. this.handleOpenMultiplePicker = this.handleOpenMultiplePicker.bind(this);
  88. this.handleMultipleConfirm = this.handleMultipleConfirm.bind(this);
  89. this.handleAddItemSave = this.handleAddItemSave.bind(this);
  90. this.handleCloseAddItemDialog = this.handleCloseAddItemDialog.bind(this);
  91. }
  92. componentDidMount() {
  93. this.setState({
  94. isMask: false
  95. })
  96. this.queryByUidAll();
  97. if (!this.isLogin()) {
  98. Taro.setStorageSync('currentPage', `/pages/customerProfile/index?id=${this.$instance.router.params.id}`)
  99. }
  100. }
  101. toggleAddressPicker(e) {
  102. const addressIds = getProvince(e.province, e.city, e.area);
  103. const { dtails } = this.state;
  104. dtails.locationProvince = addressIds[0];
  105. dtails.locationProvinceName = e.province;
  106. dtails.locationCity = addressIds[1];
  107. dtails.locationCityName = e.city;
  108. dtails.locationArea = addressIds[2];
  109. dtails.locationAreaName = e.area;
  110. this.setState({ dtails, addressPickerShow: false });
  111. }
  112. handleOpenMultiplePicker(type) {
  113. let multiplePickerOptions = [];
  114. let multiplePickerTitle = '';
  115. let multiplePickerCheckedList = [];
  116. const { dtails } = this.state;
  117. switch (type) {
  118. case 'industry':
  119. // 企业所属行业
  120. multiplePickerOptions = industry;
  121. multiplePickerCheckedList = !!dtails.industry ? dtails.industry.toString().split(',') : [];
  122. multiplePickerTitle = '请选择企业所属行业';
  123. break;
  124. case 'externalInvestIndustry':
  125. // 对外投资控股的行业
  126. multiplePickerOptions = industry;
  127. multiplePickerCheckedList = !!dtails.externalInvestIndustry ? dtails.externalInvestIndustry.toString().split(',') : [];
  128. multiplePickerTitle = '请选择对外投资控股的行业';
  129. break;
  130. default:
  131. break;
  132. }
  133. this.setState({
  134. multiplePickerShow: true,
  135. multiplePickerType: type,
  136. multiplePickerTitle,
  137. multiplePickerOptions,
  138. multiplePickerCheckedList: multiplePickerCheckedList.map(item => Number(item))
  139. })
  140. }
  141. handleMultipleConfirm(selectedIds, selectedLabels) {
  142. const { multiplePickerType, dtails } = this.state;
  143. switch (multiplePickerType) {
  144. case "industry":
  145. // 企业所属行业
  146. dtails.industry = selectedIds.join(',');
  147. dtails.industryName = selectedLabels.join('、');
  148. break;
  149. case "externalInvestIndustry":
  150. // 对外投资控股的行业
  151. dtails.externalInvestIndustry = selectedIds.join(',');
  152. dtails.externalInvestIndustryName = selectedLabels.join('、');
  153. break;
  154. default:
  155. break;
  156. }
  157. this.setState({ dtails })
  158. }
  159. bindRegionChange (e) {
  160. console.log('picker发送选择改变,携带值为', e.detail.value)
  161. this.setState({
  162. region: e.detail.value
  163. })
  164. }
  165. isLogin() {
  166. return !!Taro.getStorageSync('userInfor');
  167. }
  168. onShareAppMessage() {
  169. this.limitUser();
  170. return {
  171. title: "客户档案",
  172. path: "/pages/customerProfile/index?id=" + this.$instance.router.params.id,
  173. };
  174. }
  175. // 客户档案详情
  176. queryByUidAll() {
  177. queryByUidAll(
  178. this.$instance.router.params.notRequired,
  179. { id: this.$instance.router.params.id, }
  180. )
  181. .then((v) => {
  182. if (v.error.length === 0) {
  183. this.setState({
  184. dtails: v.data
  185. })
  186. } else {
  187. setTimeout(() => {
  188. Taro.navigateBack({
  189. delta: 1
  190. })
  191. }, 1800);
  192. Taro.showToast({
  193. title: v.error[0].message,
  194. icon: "none",
  195. duration: 1800,
  196. });
  197. }
  198. })
  199. .catch((err) => {
  200. Taro.showToast({ title: "系统错误,请稍后再试", icon: "none" });
  201. });
  202. }
  203. onSaveAllData() {
  204. const { dtails } = this.state;
  205. const params = {
  206. id: dtails.id,
  207. uid: dtails.uid,
  208. industry: dtails.industry,
  209. industryName: dtails.industryName,
  210. earlyCommunication: dtails.earlyCommunication,
  211.     customerDemand: dtails.customerDemand,
  212.     interviewIdeas: dtails.interviewIdeas,
  213.     interviewPurpose: dtails.interviewPurpose,
  214.     interviewRecommend: dtails.interviewRecommend,
  215.     interviewFeedback: dtails.interviewFeedback,
  216.     followUpPlan: dtails.followUpPlan,
  217.     patentCount: dtails.patentCount,
  218.     inventionPatentCount: dtails.inventionPatentCount,
  219.     utilityModelCount: dtails.utilityModelCount,
  220.     appearancePatentCount: dtails.appearancePatentCount,
  221.     softwareWorksCount: dtails.softwareWorksCount,
  222.     otherCount: dtails.otherCount,
  223.     financialData: dtails.financialData,
  224.     companyCount: dtails.companyCount,
  225.     socialSecurityCount: dtails.socialSecurityCount,
  226.     externalInvestCount: dtails.externalInvestCount,
  227.     externalInvestIndustry: dtails.externalInvestIndustry,
  228. externalInvestIndustryName: dtails.externalInvestIndustryName,
  229. externalInvestId: '0,0',
  230.     externalInvestName: dtails.externalInvestName,
  231.     financialRevenue: dtails.financialRevenue,
  232.     financialTax: dtails.financialTax,
  233.     financialProperty: dtails.financialProperty,
  234.     financialRd: dtails.financialRd,
  235. locationProvince: dtails.locationProvince,
  236. locationProvinceName: dtails.locationProvinceName,
  237. locationCity: dtails.locationCity,
  238. locationCityName: dtails.locationCityName,
  239. locationArea: dtails.locationArea,
  240. locationAreaName: dtails.locationAreaName,
  241. standard: dtails.standard,
  242. };
  243. for (let key in params) {
  244. if (params[key] === undefined || params[key] === 'undefined' || params[key] === null || params[key] === 'null') {
  245. delete params[key];
  246. }
  247. }
  248. updateUser(params).then((v) => {
  249. if (v.error.length === 0) {
  250. Taro.showToast({
  251. title: "修改成功",
  252. });
  253. setTimeout(() => {
  254. //表示回到上一页面
  255. Taro.navigateBack({
  256. delta: 1
  257. });
  258. }, 1000)
  259. } else {
  260. Taro.showToast({
  261. title: v.error[0].message,
  262. icon: "none",
  263. });
  264. }
  265. })
  266. }
  267. // 修改客户档案
  268. update() {
  269. // const { upType, info } = this.state
  270. // console.log(info)
  271. // let tipList = [
  272. // { key: "inventionPatentCount", value: "请填写发明专利数" },
  273. // { key: "utilityModelCount", value: "请填写实用新型数" },
  274. // { key: "appearancePatentCount", value: "请填写外观专利数" },
  275. // { key: "softwareWorksCount", value: "请填写软著数" },
  276. // { key: "otherCount", value: "请填写其他数量" },
  277. // { key: "financialData", value: "请填写财务数据" },
  278. // { key: "earlyCommunication", value: "请填写前期沟通" },
  279. // { key: "interviewIdeas", value: "请填写面谈思路及目的" },
  280. // { key: "interviewDistribution", value: "请填写主要面谈人及分工" },
  281. // { key: "enterpriseCount", value: "请填写覆盖企业数" },
  282. // { key: "channelIndicators", value: "请填写渠道考核指标" },
  283. // ]
  284. // if (!info.id) {
  285. // delete info.id
  286. // }
  287. // for (let i in info) {
  288. // if (!info[i] && info[i] !== 0) {
  289. // for (var j = 0; j < tipList.length; j++) {
  290. // if (tipList[j].key == i) {
  291. // Taro.showToast({
  292. // title: tipList[j].value,
  293. // icon: "none",
  294. // });
  295. // }
  296. // }
  297. // return
  298. // } else if (info[i] == 0) {
  299. // if (i == "channelType") {
  300. // Taro.showToast({
  301. // title: "请选择渠道类型",
  302. // icon: "none",
  303. // });
  304. // return
  305. // }
  306. // }
  307. // if ((i == "financialData" || i == "earlyCommunication" || i == "interviewIdeas" || i == "interviewDistribution")
  308. // && info[i].length < 20) {
  309. // Taro.showToast({
  310. // title: "至少20字以上",
  311. // icon: "none",
  312. // });
  313. // return
  314. // }
  315. // }
  316. // updateUserDate(upType, info).then((v) => {
  317. // if (v.error.length === 0) {
  318. // Taro.showToast({
  319. // title: "修改成功",
  320. // });
  321. // this.setState({
  322. // isOpened: false
  323. // })
  324. // this.queryByUidAll()
  325. // } else {
  326. // Taro.showToast({
  327. // title: v.error[0].message,
  328. // icon: "none",
  329. // });
  330. // }
  331. // }).catch(() => {
  332. // })
  333. this.setState({ isOpened: false, dtails: { ...this.state.dtails, ...this.state.info } })
  334. }
  335. // 新建联系人
  336. add() {
  337. let data = this.state.obj
  338. for (let i in data) {
  339. if (!data[i] && data[i] !== 0) {
  340. Taro.showToast({
  341. title: "请完善信息",
  342. icon: "none",
  343. });
  344. return
  345. } else if (i == "mobile") {
  346. if (!(/^1[3-9]\d{9}$/.test(data[i]))) {
  347. Taro.showToast({
  348. title: "请输入正确地手机号",
  349. icon: "none",
  350. });
  351. return
  352. }
  353. }
  354. }
  355. data.major = 1
  356. addOneContact(data).then((v) => {
  357. if (v.error.length === 0) {
  358. Taro.showToast({
  359. title: "添加成功",
  360. });
  361. this.setState({
  362. isAdd: false
  363. })
  364. this.queryByUidAll()
  365. } else {
  366. Taro.showToast({
  367. title: v.error[0].message,
  368. icon: "none",
  369. });
  370. }
  371. }).catch(() => {
  372. })
  373. }
  374. // 项目列表
  375. getBusinessProjectByName(val) {
  376. getBusinessProjectByName({
  377. businessName: val || "",
  378. })
  379. .then((v) => {
  380. if (v.error.length === 0) {
  381. let theArr = [];
  382. if (v.data.length > 0) {
  383. for (let i = 0; i < v.data.length; i++) {
  384. let thisdata = v.data[i];
  385. theArr.push({
  386. value: thisdata.bname,
  387. label: thisdata.bname,
  388. });
  389. };
  390. }
  391. this.setState({
  392. options: theArr
  393. })
  394. } else {
  395. Taro.showToast({ title: v.error[0].message, icon: "none" });
  396. }
  397. })
  398. .catch((err) => {
  399. Taro.showToast({ title: "系统错误,请稍后再试", icon: "none" });
  400. });
  401. }
  402. onSearchChange(value) {
  403. this.setState({
  404. value,
  405. });
  406. }
  407. getUserList() {
  408. findCustomerContacts({
  409. uid: this.$instance.router.params.id,
  410. })
  411. .then((v) => {
  412. if (v.error.length === 0) {
  413. this.setState({
  414. userList: v.data || []
  415. })
  416. } else {
  417. Taro.showToast({ title: v.error[0].message, icon: "none" });
  418. }
  419. })
  420. .catch((err) => {
  421. Taro.showToast({ title: "系统错误,请稍后再试", icon: "none" });
  422. });
  423. }
  424. updateMainContact(id) {
  425. updateMainContact({
  426. uid: this.$instance.router.params.id,
  427. ocbId: id,
  428. }).then((v) => {
  429. if (v.error.length === 0) {
  430. Taro.showToast({
  431. title: "设置成功",
  432. });
  433. this.getUserList()
  434. } else {
  435. Taro.showToast({
  436. title: v.error[0].message,
  437. icon: "none",
  438. });
  439. }
  440. }).catch(() => {
  441. })
  442. }
  443. limitUser() {
  444. limitUser({
  445. uid: this.$instance.router.params.id,
  446. // hours: 1,
  447. }).then((v) => {
  448. if (v.error.length === 0) {
  449. } else {
  450. Taro.showToast({
  451. title: v.error[0].message,
  452. icon: "none",
  453. });
  454. }
  455. }).catch(() => {
  456. })
  457. }
  458. addItemDialog(type) {
  459. let title;
  460. switch (type) {
  461. case 'externalInvestName':
  462. // 对外投资控股的企业名称
  463. title = '添加对外投资控股的企业名称';
  464. break;
  465. default:
  466. break;
  467. }
  468. this.setState({ addItemShow: true, addItemType: type, addItemTitle: title });
  469. }
  470. handleCloseAddItemDialog() {
  471. this.setState({ addItemShow: false, addItemType: '', addItemInputVal: '' });
  472. }
  473. handleAddItemSave() {
  474. switch (this.state.addItemType) {
  475. case 'externalInvestName':
  476. const { dtails } = this.state;
  477. let externalInvestName = this.state.dtails.externalInvestName || '';
  478. let externalInvestNameArr = externalInvestName.split('、').filter(item => !!item);
  479. externalInvestNameArr.push(this.state.addItemInputVal);
  480. dtails.externalInvestName = externalInvestNameArr.join('、');
  481. this.setState({ dtails }, () => {
  482. this.handleCloseAddItemDialog();
  483. });
  484. break;
  485. default:
  486. break;
  487. }
  488. }
  489. openInteractHis(type) {
  490. console.log(this.state.dtails)
  491. this.setState({
  492. interactShow: true,
  493. interactShowType: type,
  494. interactTitle: '客户的难处历史记录'
  495. });
  496. }
  497. render() {
  498. const { dtails, upType, info, obj, userList } = this.state;
  499. return (
  500. <View className="customerProfile">
  501. <MessageNoticebar />
  502. <View
  503. className="titleContent"
  504. >
  505. {Object.keys(dtails).length === 0 ? (
  506. <Skeleton
  507. title
  508. row={3}
  509. animateName="elastic"
  510. avatarShape="square"
  511. loading
  512. />
  513. ) : (
  514. <View className="content">
  515. <View className="name">
  516. <Text style={{ width: "80%" }}>
  517. <Text className="bod">{dtails.nickname}&nbsp;&nbsp;</Text>
  518. <Text style={{ fontSize: "12px", color: ["red", "green"][dtails.signBills] }}>{["未签单", "已签单"][dtails.signBills]}</Text>
  519. </Text>
  520. {dtails.myUser == 1 && <Button className="share" plain type='primary' open-type="share">分享</Button>}
  521. {/* <View className="share">分享</View> */}
  522. </View>
  523. <View className="button">
  524. <View className="but"
  525. onClick={e => {
  526. e.stopPropagation()
  527. this.setState({
  528. isSuperior: true
  529. })
  530. }}
  531. >上级指导</View>
  532. {
  533. this.state.isSuperior &&
  534. <Superior
  535. id={dtails.uid}
  536. userNames={dtails.nickname}
  537. isOpinion={this.state.isSuperior}
  538. isFill={dtails.myUser == 0}
  539. onClose={() => {
  540. this.setState({
  541. isSuperior: false
  542. })
  543. }}
  544. />
  545. }
  546. <View className="but"
  547. onClick={e => {
  548. e.stopPropagation()
  549. Taro.navigateTo({
  550. url: "/pages/situation/index?id=" + this.$instance.router.params.id + "&notRequired=" + this.$instance.router.params.notRequired,
  551. });
  552. }}
  553. >公出记录</View>
  554. </View>
  555. <View className="row">
  556. <View className="code">{dtails.orgCode}</View>
  557. <View className="time">{dtails.createTime}</View>
  558. </View>
  559. {
  560. dtails.newChannel == 1
  561. ?
  562. <View className="first">
  563. <View className="tit">
  564. 已知渠道情况
  565. {
  566. dtails.myUser == 1 &&
  567. <View className="up"
  568. onClick={e => {
  569. e.stopPropagation()
  570. this.setState({
  571. upType: 7,
  572. isOpened: true,
  573. info: {
  574. uid: this.$instance.router.params.id,
  575. channelType: dtails.channelType,
  576. enterpriseCount: dtails.enterpriseCount,
  577. channelIndicators: dtails.channelIndicators,
  578. },
  579. channe: {
  580. id: dtails.channelType,
  581. title: getChannel(dtails.channelType)
  582. }
  583. })
  584. }}
  585. >修改</View>
  586. }
  587. </View>
  588. <View className="val">渠道类别:{getChannel(dtails.channelType)}</View>
  589. <View className="val">渠道企业数:{dtails.enterpriseCount}</View>
  590. <View className="val">渠道考核指标:{dtails.channelIndicators}</View>
  591. <View className="tit">
  592. <Text>
  593. 联系人
  594. <Text className="txt">(面谈人)</Text>
  595. </Text>
  596. {
  597. dtails.myUser == 1 &&
  598. <View className="up"
  599. onClick={e => {
  600. e.stopPropagation()
  601. this.getUserList();
  602. this.setState({
  603. isAdd: true,
  604. obj: {
  605. uid: this.$instance.router.params.id,
  606. name: "",
  607. position: "",
  608. department: "",
  609. mobile: "",
  610. }
  611. })
  612. }}
  613. >新增</View>
  614. }
  615. </View>
  616. {
  617. !!dtails.contactList && dtails.contactList.map((v, k) =>
  618. <View className="val" key={k}>{v.name}&nbsp;&nbsp;{v.position}&nbsp;&nbsp;{v.department}&nbsp;&nbsp;{v.mobile}</View>
  619. )
  620. }
  621. </View>
  622. :
  623. <View className="first">
  624. <View className="title">企业面谈思路表</View>
  625. <View className="val" style={{ display: 'flex' }}>
  626. 企业所在地省市区:
  627. {/* <Picker
  628. mode='region'
  629. value={this.state.region}
  630. customItem={this.state.customItem}
  631. onChange={this.bindRegionChange.bind(this)}
  632. >
  633. <View className='picker'>
  634. { this.state.region.length ? this.state.region.join('-') : '请选择' }
  635. </View>
  636. </Picker> */}
  637. <View onClick={() => {this.setState({ addressPickerShow: true })}}>
  638. { dtails.locationProvince ? `${dtails.locationProvinceName}-${dtails.locationCityName}-${dtails.locationAreaName}` : '请选择' }
  639. </View>
  640. <AddressPicker
  641. pickerShow={this.state.addressPickerShow}
  642. onHandleToggleShow={this.toggleAddressPicker.bind(this)}
  643. />
  644. </View>
  645. {/* <View className="tit">
  646. 企业面谈思路表
  647. {
  648. dtails.myUser == 1 &&
  649. <View className="up"
  650. onClick={e => {
  651. e.stopPropagation()
  652. this.setState({
  653. upType: 0,
  654. isOpened: true,
  655. info: {
  656. uid: this.$instance.router.params.id,
  657. industry: dtails.industry,
  658. businessScope: dtails.businessScope,
  659. },
  660. sector: {
  661. id: dtails.industry,
  662. title: dtails.industryName
  663. }
  664. })
  665. }}
  666. >修改</View>
  667. }
  668. </View> */}
  669. <View className="val" style={{display: 'flex'}}>
  670. 企业所属行业:
  671. <View onClick={() => this.handleOpenMultiplePicker('industry')}>
  672. { this.state.dtails.industryName || '请选择' }
  673. </View>
  674. </View>
  675. <View className="val" style={{display: 'flex', alignItems: 'center'}}>
  676. 主营产品:
  677. <View style={{flex: 1}}>
  678. <AtInput
  679. value={dtails.businessScope}
  680. name='businessScope'
  681. placeholder='可填写多个,用“、”隔开'
  682. size='mini'
  683. onChange={value => {
  684. dtails.businessScope = value;
  685. this.setState({ dtails })
  686. }}
  687. />
  688. </View>
  689. </View>
  690. <View className="val" style={{ display: 'flex', alignItems: 'center' }}>
  691. 母/子公司数:
  692. <View style={{width: '180rpx'}}>
  693. <AtInput
  694. value={dtails.companyCount}
  695. name='companyCount'
  696. type='number'
  697. placeholder='请输入数量'
  698. size='mini'
  699. onChange={value => {
  700. dtails.companyCount = value;
  701. this.setState({ dtails })
  702. }}
  703. />
  704. </View>
  705. </View>
  706. <View className="val" style={{ display: 'flex', alignItems: 'center' }}>
  707. 社保人数:
  708. <View style={{width: '180rpx'}}>
  709. <AtInput
  710. value={dtails.socialSecurityCount}
  711. name='socialSecurityCount'
  712. type='number'
  713. placeholder='请输入数量'
  714. size='mini'
  715. onChange={value => {
  716. dtails.socialSecurityCount = value;
  717. this.setState({ dtails })
  718. }}
  719. />
  720. </View>
  721. </View>
  722. <View className="val" style={{ display: 'flex', alignItems: 'center' }}>
  723. 对外投资控股的企业数:
  724. <View style={{width: '180rpx'}}>
  725. <AtInput
  726. value={dtails.externalInvestCount}
  727. name='externalInvestCount'
  728. type='number'
  729. placeholder='请输入数量'
  730. size='mini'
  731. onChange={value => {
  732. dtails.externalInvestCount = value;
  733. this.setState({ dtails })
  734. }}
  735. />
  736. </View>
  737. </View>
  738. <View className="val" style={{display: 'flex'}}>
  739. 对外投资控股的行业:
  740. <View onClick={() => this.handleOpenMultiplePicker('externalInvestIndustry')}>
  741. { this.state.dtails.externalInvestIndustryName || '请选择' }
  742. </View>
  743. </View>
  744. <View className="val" style={{display: 'flex'}}>
  745. 对外投资控股的企业名称:
  746. <View onClick={() => this.addItemDialog('externalInvestName')}>
  747. { this.state.dtails.externalInvestName || '点击新增' }
  748. </View>
  749. </View>
  750. <View className="tit">
  751. <Text>
  752. 主要面谈联系信息
  753. {/* <Text className="txt">(面谈人)</Text> */}
  754. </Text>
  755. {
  756. dtails.myUser == 1 &&
  757. <View className="up"
  758. onClick={e => {
  759. e.stopPropagation()
  760. this.getUserList();
  761. this.setState({
  762. isAdd: true,
  763. obj: {
  764. uid: this.$instance.router.params.id,
  765. name: "",
  766. position: "",
  767. department: "",
  768. mobile: "",
  769. }
  770. })
  771. }}
  772. >新增</View>
  773. }
  774. </View>
  775. {
  776. !!dtails.contactList && dtails.contactList.map((v, k) =>
  777. <View className="val" key={k}>
  778. {v.name}&nbsp;&nbsp;{v.position}&nbsp;&nbsp;{v.department}&nbsp;&nbsp;{v.mobile}
  779. {this.state.isMask && <View className="mask"></View>}
  780. </View>
  781. )
  782. }
  783. <View className="tit">
  784. 本次面谈项目
  785. {
  786. dtails.myUser == 1 &&
  787. <View className="up"
  788. onClick={e => {
  789. e.stopPropagation()
  790. this.getBusinessProjectByName("")
  791. this.setState({
  792. upType: 5,
  793. isOpened: true,
  794. info: {
  795. uid: this.$instance.router.params.id,
  796. intendedProject: dtails.intendedProject,
  797. },
  798. checkOptions: !!dtails.intendedProject ? dtails.intendedProject.split(",") : []
  799. })
  800. }}
  801. >新增</View>
  802. }
  803. </View>
  804. <View className="val">{dtails.intendedProject || "无"}</View>
  805. <View style={{marginTop: '60rpx'}}>
  806. <View className="title">面谈已知企业情况</View>
  807. <View className="tit">
  808. <Text>
  809. 1.知识产权情况
  810. <Text className="txt">(专利信息、标准、专利、软著)</Text>
  811. </Text>
  812. {
  813. dtails.myUser == 1 &&
  814. <View className="up"
  815. onClick={e => {
  816. e.stopPropagation()
  817. this.setState({
  818. upType: 1,
  819. isOpened: true,
  820. info: {
  821. uid: this.$instance.router.params.id,
  822. id: dtails.id,
  823. inventionPatentCount: dtails.inventionPatentCount || 0,
  824. utilityModelCount: dtails.utilityModelCount || 0,
  825. appearancePatentCount: dtails.appearancePatentCount || 0,
  826. softwareWorksCount: dtails.softwareWorksCount || 0,
  827. otherCount: dtails.otherCount || 0,
  828. }
  829. })
  830. }}
  831. >修改</View>
  832. }
  833. </View>
  834. <View className="val">
  835. 专利&nbsp;<Text className="num">{dtails.patentCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  836. 其中发明专利&nbsp;<Text className="num">{dtails.inventionPatentCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  837. 实用新型&nbsp;<Text className="num">{dtails.utilityModelCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  838. 外观设计&nbsp;<Text className="num">{dtails.appearancePatentCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  839. 软著&nbsp;<Text className="num">{dtails.softwareWorksCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  840. 标准&nbsp;<Text className="num">{dtails.standard == 1 ? '有' : '无'}</Text>&nbsp;&nbsp;&nbsp;
  841. 其他类型&nbsp;<Text className="num">{dtails.otherCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  842. </View>
  843. <View className="tit">2.财务数据</View>
  844. <View className="val" style={{display: 'flex', alignItems: 'center'}}>
  845. 营收(万元):
  846. <View style={{width: '180rpx'}}>
  847. <AtInput
  848. value={dtails.financialRevenue}
  849. name='financialRevenue'
  850. type='number'
  851. placeholder='请输入数量'
  852. size='mini'
  853. onChange={value => {
  854. dtails.financialRevenue = value;
  855. this.setState({ dtails })
  856. }}
  857. />
  858. </View>
  859. </View>
  860. <View className="val" style={{display: 'flex', alignItems: 'center'}}>
  861. 税收(万元):
  862. <View style={{width: '180rpx'}}>
  863. <AtInput
  864. value={dtails.financialTax}
  865. name='financialTax'
  866. type='number'
  867. placeholder='请输入数量'
  868. size='mini'
  869. onChange={value => {
  870. dtails.financialTax = value;
  871. this.setState({ dtails })
  872. }}
  873. />
  874. </View>
  875. </View>
  876. <View className="val" style={{display: 'flex', alignItems: 'center'}}>
  877. 资产(万元):
  878. <View style={{width: '180rpx'}}>
  879. <AtInput
  880. value={dtails.financialProperty}
  881. name='financialProperty'
  882. type='number'
  883. placeholder='请输入数量'
  884. size='mini'
  885. onChange={value => {
  886. dtails.financialProperty = value;
  887. this.setState({ dtails })
  888. }}
  889. />
  890. </View>
  891. </View>
  892. <View className="val" style={{display: 'flex', alignItems: 'center'}}>
  893. 研发费用(万元):
  894. <View style={{width: '180rpx'}}>
  895. <AtInput
  896. value={dtails.financialRd}
  897. name='financialRd'
  898. type='number'
  899. placeholder='请输入数量'
  900. size='mini'
  901. onChange={value => {
  902. dtails.financialRd = value;
  903. this.setState({ dtails })
  904. }}
  905. />
  906. </View>
  907. </View>
  908. <View className="tit">3.前期沟通情况</View>
  909. <View className="tit">
  910. <Text>
  911. 客户的难处
  912. <Text className="txt">(20字以上)</Text>
  913. </Text>
  914. <Text onClick={() => this.openInteractHis('earlyCommunication')}>历史记录</Text>
  915. </View>
  916. <View className="val">
  917. <AtTextarea
  918. value={dtails.earlyCommunication}
  919. maxLength={200}
  920. placeholder='请编写本次面谈客户难处~'
  921. height={70}
  922. onChange={value => {
  923. dtails.earlyCommunication = value;
  924. this.setState({ dtails });
  925. }}
  926. />
  927. </View>
  928. <View className="tit">
  929. <Text>
  930. 客户的需求
  931. <Text className="txt">(20字以上)</Text>
  932. </Text>
  933. <Text onClick={() => this.openInteractHis('customerDemand')}>历史记录</Text>
  934. </View>
  935. <View className="val">
  936. <AtTextarea
  937. value={dtails.customerDemand}
  938. maxLength={200}
  939. placeholder='请编写本次面谈客户需求~'
  940. height={70}
  941. onChange={value => {
  942. dtails.customerDemand = value;
  943. this.setState({ dtails });
  944. }}
  945. />
  946. </View>
  947. <View className="tit">
  948. <Text>
  949. 面谈思路
  950. <Text className="txt">(20字以上)</Text>
  951. </Text>
  952. <Text onClick={() => this.openInteractHis('interviewIdeas')}>历史记录</Text>
  953. </View>
  954. <View className="val">
  955. <AtTextarea
  956. value={dtails.interviewIdeas}
  957. maxLength={200}
  958. placeholder='请编写本次面谈客户思路~'
  959. height={70}
  960. onChange={value => {
  961. dtails.interviewIdeas = value;
  962. this.setState({ dtails });
  963. }}
  964. />
  965. </View>
  966. <View className="tit">
  967. <Text>
  968. 面谈达成的目的
  969. <Text className="txt">(20字以上)</Text>
  970. </Text>
  971. <Text onClick={() => this.openInteractHis('interviewPurpose')}>历史记录</Text>
  972. </View>
  973. <View className="val">
  974. <AtTextarea
  975. value={dtails.interviewPurpose}
  976. maxLength={200}
  977. placeholder='请编写本次面谈达成的目的~'
  978. height={70}
  979. onChange={value => {
  980. dtails.interviewPurpose = value;
  981. this.setState({ dtails });
  982. }}
  983. />
  984. </View>
  985. <View className="tit">
  986. <Text>
  987. 经理/上级面谈建议
  988. <Text className="txt">(由经理/上级口述,本人整理,20字以上)</Text>
  989. </Text>
  990. <Text onClick={() => this.openInteractHis('interviewRecommend')}>历史记录</Text>
  991. </View>
  992. <View className="val">
  993. <AtTextarea
  994. value={dtails.interviewRecommend}
  995. maxLength={200}
  996. placeholder='请编写本次面谈建议~'
  997. height={70}
  998. onChange={value => {
  999. dtails.interviewRecommend = value;
  1000. this.setState({ dtails });
  1001. }}
  1002. />
  1003. </View>
  1004. <AtButton type="primary" onClick={this.onSaveAllData.bind(this)}>保存</AtButton>
  1005. </View>
  1006. </View>
  1007. }
  1008. {/* {
  1009. dtails.newChannel == 1
  1010. ?
  1011. <View className="two">
  1012. <View className="title">面谈前渠道情况</View>
  1013. <View className="tit">
  1014. <Text>
  1015. 面谈项目
  1016. </Text>
  1017. {
  1018. dtails.myUser == 1 &&
  1019. <View className="up"
  1020. onClick={e => {
  1021. e.stopPropagation()
  1022. this.getBusinessProjectByName("")
  1023. this.setState({
  1024. upType: 5,
  1025. isOpened: true,
  1026. info: {
  1027. uid: this.$instance.router.params.id,
  1028. intendedProject: dtails.intendedProject,
  1029. },
  1030. checkOptions: !!dtails.intendedProject ? dtails.intendedProject.split(",") : []
  1031. })
  1032. }}
  1033. >修改</View>
  1034. }
  1035. </View>
  1036. <View className="val">{dtails.intendedProject || "无"}</View>
  1037. <View className="tit">
  1038. <Text>
  1039. 面谈思路及目的
  1040. </Text>
  1041. {
  1042. dtails.myUser == 1 &&
  1043. <View className="up"
  1044. onClick={e => {
  1045. e.stopPropagation()
  1046. this.setState({
  1047. upType: 4,
  1048. isOpened: true,
  1049. info: {
  1050. uid: this.$instance.router.params.id,
  1051. id: dtails.id,
  1052. interviewIdeas: dtails.interviewIdeas,
  1053. }
  1054. })
  1055. }}
  1056. >修改</View>
  1057. }
  1058. </View>
  1059. <View className="val">{dtails.interviewIdeas || "无"}</View>
  1060. <View className="tit">
  1061. <Text>
  1062. 我方主要面谈人及分工
  1063. </Text>
  1064. {
  1065. dtails.myUser == 1 &&
  1066. <View className="up"
  1067. onClick={e => {
  1068. e.stopPropagation()
  1069. this.setState({
  1070. upType: 6,
  1071. isOpened: true,
  1072. info: {
  1073. uid: this.$instance.router.params.id,
  1074. id: dtails.id,
  1075. interviewDistribution: dtails.interviewDistribution,
  1076. }
  1077. })
  1078. }}
  1079. >修改</View>
  1080. }
  1081. </View>
  1082. <View className="val">{dtails.interviewDistribution || "无"}</View>
  1083. </View>
  1084. :
  1085. <View className="two">
  1086. <View className="title">面谈企业情况</View>
  1087. <AtInput
  1088. name='mzgssl'
  1089. title='母/子公司数'
  1090. type='number'
  1091. placeholder='请输入数量'
  1092. />
  1093. <AtInput
  1094. name='sbrs'
  1095. title=''
  1096. type='number'
  1097. placeholder='请输入数量'
  1098. size='mini'
  1099. />
  1100. <AtInput
  1101. name='qyes'
  1102. title='对外投资控股的企业数'
  1103. type='number'
  1104. placeholder='请输入数量'
  1105. />
  1106. <View className="tit">
  1107. <Text>
  1108. 知识产权情况
  1109. <Text className="txt">(专利信息、标准、专利、软著)</Text>
  1110. </Text>
  1111. {
  1112. dtails.myUser == 1 &&
  1113. <View className="up"
  1114. onClick={e => {
  1115. e.stopPropagation()
  1116. this.setState({
  1117. upType: 1,
  1118. isOpened: true,
  1119. info: {
  1120. uid: this.$instance.router.params.id,
  1121. id: dtails.id,
  1122. inventionPatentCount: dtails.inventionPatentCount || 0,
  1123. utilityModelCount: dtails.utilityModelCount || 0,
  1124. appearancePatentCount: dtails.appearancePatentCount || 0,
  1125. softwareWorksCount: dtails.softwareWorksCount || 0,
  1126. otherCount: dtails.otherCount || 0,
  1127. }
  1128. })
  1129. }}
  1130. >修改</View>
  1131. }
  1132. </View>
  1133. <View className="val">
  1134. 专利&nbsp;<Text className="num">{dtails.patentCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  1135. 其中发明专利&nbsp;<Text className="num">{dtails.inventionPatentCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  1136. 实用新型&nbsp;<Text className="num">{dtails.utilityModelCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  1137. 外观设计&nbsp;<Text className="num">{dtails.appearancePatentCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  1138. 软著&nbsp;<Text className="num">{dtails.softwareWorksCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  1139. 标准&nbsp;<Text className="num">{'有'}</Text>&nbsp;&nbsp;&nbsp;
  1140. 其他类型&nbsp;<Text className="num">{dtails.otherCount || 0}</Text>&nbsp;&nbsp;&nbsp;
  1141. </View>
  1142. <View className="tit">
  1143. <Text>
  1144. 财务数据
  1145. <Text className="txt">(包括营收、税收、资产、研发费用等)</Text>
  1146. </Text>
  1147. {
  1148. dtails.myUser == 1 &&
  1149. <View className="up"
  1150. onClick={e => {
  1151. e.stopPropagation()
  1152. this.setState({
  1153. upType: 2,
  1154. isOpened: true,
  1155. info: {
  1156. uid: this.$instance.router.params.id,
  1157. id: dtails.id,
  1158. financialData: dtails.financialData,
  1159. }
  1160. })
  1161. }}
  1162. >修改</View>
  1163. }
  1164. </View>
  1165. <View className="val">{dtails.financialData || "无"}</View>
  1166. <View className="tit">
  1167. <Text>
  1168. 前期沟通
  1169. <Text className="txt">(客户的难处、需求)</Text>
  1170. </Text>
  1171. {
  1172. dtails.myUser == 1 &&
  1173. <View className="up"
  1174. onClick={e => {
  1175. e.stopPropagation()
  1176. this.setState({
  1177. upType: 3,
  1178. isOpened: true,
  1179. info: {
  1180. uid: this.$instance.router.params.id,
  1181. id: dtails.id,
  1182. earlyCommunication: dtails.earlyCommunication,
  1183. }
  1184. })
  1185. }}
  1186. >修改</View>
  1187. }
  1188. </View>
  1189. <View className="val">{dtails.earlyCommunication || "无"}</View>
  1190. <View className="tit">
  1191. <Text>
  1192. 面谈思路及目的
  1193. </Text>
  1194. {
  1195. dtails.myUser == 1 &&
  1196. <View className="up"
  1197. onClick={e => {
  1198. e.stopPropagation()
  1199. this.setState({
  1200. upType: 4,
  1201. isOpened: true,
  1202. info: {
  1203. uid: this.$instance.router.params.id,
  1204. id: dtails.id,
  1205. interviewIdeas: dtails.interviewIdeas,
  1206. }
  1207. })
  1208. }}
  1209. >修改</View>
  1210. }
  1211. </View>
  1212. <View className="val">{dtails.interviewIdeas || "无"}</View>
  1213. </View>
  1214. } */}
  1215. </View>
  1216. )}
  1217. </View>
  1218. <AtModal
  1219. isOpened={this.state.isOpened}
  1220. onClose={() => {
  1221. this.setState({
  1222. isOpened: false
  1223. })
  1224. }}
  1225. >
  1226. <AtModalHeader>信息修改</AtModalHeader>
  1227. <AtModalContent>
  1228. {
  1229. upType == 0 &&
  1230. <View>
  1231. <View className='selectTitle'>企业行业</View>
  1232. <Picker
  1233. value={this.state.sector.id}
  1234. range={industry} rangeKey='title' mode='selector'
  1235. onChange={(e) => {
  1236. this.setState({
  1237. sector: industry[e.detail.value],
  1238. info: Object.assign(info, {
  1239. industry: industry[e.detail.value].id,
  1240. })
  1241. })
  1242. }}>
  1243. <View style={{ marginBottom: "10px", color: !this.state.sector.title && "#CCCCCC" }}>
  1244. {!this.state.sector.title ? "请选择" : this.state.sector.title}
  1245. </View>
  1246. </Picker>
  1247. <View className='selectTitle'>企业主营产品/服务</View>
  1248. <Input
  1249. // name='value'
  1250. // title='企业主营产品/服务'
  1251. type='text'
  1252. placeholder='请用,符号隔开关键字'
  1253. value={info.businessScope}
  1254. onInput={e => {
  1255. this.setState({
  1256. info: Object.assign(info, {
  1257. businessScope: e.detail.value,
  1258. })
  1259. })
  1260. }}
  1261. />
  1262. </View>
  1263. }
  1264. {
  1265. upType == 1 &&
  1266. <View>
  1267. <AtInput
  1268. name='inventionPatentCount'
  1269. title='发明专利'
  1270. type='number'
  1271. value={info.inventionPatentCount}
  1272. onChange={e => {
  1273. this.setState({
  1274. info: Object.assign(info, {
  1275. inventionPatentCount: e,
  1276. })
  1277. })
  1278. }}
  1279. />
  1280. <AtInput
  1281. name='utilityModelCount'
  1282. title='实用新型'
  1283. type='number'
  1284. value={info.utilityModelCount}
  1285. onChange={e => {
  1286. this.setState({
  1287. info: Object.assign(info, {
  1288. utilityModelCount: e,
  1289. })
  1290. })
  1291. }}
  1292. />
  1293. <AtInput
  1294. name='appearancePatentCount'
  1295. title='外观专利'
  1296. type='number'
  1297. value={info.appearancePatentCount}
  1298. onChange={e => {
  1299. this.setState({
  1300. info: Object.assign(info, {
  1301. appearancePatentCount: e,
  1302. })
  1303. })
  1304. }}
  1305. />
  1306. <AtInput
  1307. name='softwareWorksCount'
  1308. title='软著'
  1309. type='number'
  1310. value={info.softwareWorksCount}
  1311. onChange={e => {
  1312. this.setState({
  1313. info: Object.assign(info, {
  1314. softwareWorksCount: e,
  1315. })
  1316. })
  1317. }}
  1318. />
  1319. <View style={{display: 'flex', margin: '12rpx 0'}}>
  1320. <Text style={{ fontSize: '32rpx', marginRight: '16rpx', width: '172rpx' }}>标准</Text>
  1321. <RadioGroup title="标准" onChange={e => {
  1322. dtails.standard = Number(e.target.value);
  1323. this.setState({ dtails });
  1324. }}>
  1325. <Label className='radio-list__label'>
  1326. <Radio className='radio-list__radio' value={1} checked={dtails.standard == 1}>有</Radio>
  1327. </Label>
  1328. <Label className='radio-list__label'>
  1329. <Radio className='radio-list__radio' value={0} checked={!dtails.standard}>无</Radio>
  1330. </Label>
  1331. </RadioGroup>
  1332. </View>
  1333. <AtInput
  1334. name='otherCount'
  1335. title='其他'
  1336. type='number'
  1337. value={dtails.otherCount}
  1338. onChange={e => {
  1339. this.setState({
  1340. info: Object.assign(dtails, {
  1341. otherCount: e,
  1342. })
  1343. })
  1344. }}
  1345. />
  1346. </View>
  1347. }
  1348. {
  1349. upType == 2 &&
  1350. <View>
  1351. <View className='selectTitle'>财务数据</View>
  1352. <AtTextarea
  1353. value={info.financialData || ""}
  1354. onChange={e => {
  1355. this.setState({
  1356. info: Object.assign(info, {
  1357. financialData: e,
  1358. }),
  1359. })
  1360. }}
  1361. maxLength={200}
  1362. placeholder='请填写财务数据~'
  1363. />
  1364. </View>
  1365. }
  1366. {
  1367. upType == 3 &&
  1368. <View>
  1369. <View className='selectTitle'>前期沟通</View>
  1370. <AtTextarea
  1371. value={info.earlyCommunication || ""}
  1372. onChange={e => {
  1373. this.setState({
  1374. info: Object.assign(info, {
  1375. earlyCommunication: e,
  1376. }),
  1377. })
  1378. }}
  1379. maxLength={200}
  1380. placeholder='请填写前期沟通~'
  1381. />
  1382. </View>
  1383. }
  1384. {
  1385. upType == 4 &&
  1386. <View>
  1387. <View className='selectTitle'>面谈思路及目的</View>
  1388. <AtTextarea
  1389. value={info.interviewIdeas || ""}
  1390. onChange={e => {
  1391. this.setState({
  1392. info: Object.assign(info, {
  1393. interviewIdeas: e,
  1394. }),
  1395. })
  1396. }}
  1397. maxLength={200}
  1398. placeholder='请填写面谈思路及目的~'
  1399. />
  1400. </View>
  1401. }
  1402. {
  1403. upType == 5 &&
  1404. <View>
  1405. <AtSearchBar
  1406. placeholder="请输入项目名称"
  1407. showActionButton
  1408. value={this.state.value}
  1409. onChange={this.onSearchChange}
  1410. onActionClick={() => {
  1411. this.getBusinessProjectByName(this.state.value);
  1412. }}
  1413. onClear={() => {
  1414. this.setState({
  1415. value: "",
  1416. }, () => { this.getBusinessProjectByName(this.state.value) });
  1417. }}
  1418. />
  1419. {
  1420. this.state.checkOptions.length > 0 &&
  1421. <View className="selproject">
  1422. 已选择:
  1423. {
  1424. this.state.checkOptions.map((v, i) =>
  1425. <View className="selptxt" key={i}
  1426. onClick={() => {
  1427. let list = this.state.checkOptions
  1428. for (var j = 0; j < list.length; j++) {
  1429. if (list[j] == v) {
  1430. list.splice(j, 1)
  1431. this.setState({
  1432. checkOptions: list,
  1433. info: Object.assign(info, {
  1434. intendedProject: list.toString(),
  1435. }),
  1436. })
  1437. }
  1438. }
  1439. }}
  1440. >{v}&nbsp;<AtIcon className='atIcon' value='close-circle' size='12' color='#fff' /></View>
  1441. )
  1442. }
  1443. </View>
  1444. }
  1445. <AtCheckbox
  1446. options={this.state.options}
  1447. selectedList={this.state.checkOptions}
  1448. onChange={e => {
  1449. this.setState({
  1450. checkOptions: e,
  1451. info: Object.assign(info, {
  1452. intendedProject: e.toString(),
  1453. }),
  1454. })
  1455. }}
  1456. />
  1457. </View>
  1458. }
  1459. {
  1460. upType == 6 &&
  1461. <View>
  1462. <View className='selectTitle'>我方主要面谈人及分工</View>
  1463. <AtTextarea
  1464. value={info.interviewDistribution || ""}
  1465. onChange={e => {
  1466. this.setState({
  1467. info: Object.assign(info, {
  1468. interviewDistribution: e,
  1469. }),
  1470. })
  1471. }}
  1472. maxLength={200}
  1473. placeholder='请填写我方主要面谈人及分工~'
  1474. />
  1475. </View>
  1476. }
  1477. {
  1478. upType == 7 &&
  1479. <View>
  1480. <View className='selectTitle' style={{ height: "30px" }}>
  1481. 渠道类别:
  1482. <Picker
  1483. value={this.state.channe.id}
  1484. range={channelTypeList} rangeKey='title' mode='selector'
  1485. onChange={(e) => {
  1486. this.setState({
  1487. channe: channelTypeList[e.detail.value],
  1488. info: Object.assign(info, {
  1489. channelType: channelTypeList[e.detail.value].id,
  1490. })
  1491. })
  1492. }}>
  1493. <View style={{ marginBottom: "10px", width: "160px", color: !this.state.channe.title && "#CCCCCC" }}>
  1494. {!this.state.channe.title ? "请选择" : this.state.channe.title}
  1495. </View>
  1496. </Picker>
  1497. </View>
  1498. <View className='selectTitle' style={{ height: "30px" }}>
  1499. 覆盖企业数:
  1500. <Input
  1501. style={{ width: "50%" }}
  1502. type='number'
  1503. placeholder='请填写个数'
  1504. value={info.enterpriseCount}
  1505. onInput={e => {
  1506. this.setState({
  1507. info: Object.assign(info, {
  1508. enterpriseCount: e.detail.value,
  1509. })
  1510. })
  1511. }}
  1512. />
  1513. </View>
  1514. <View className='selectTitle' >渠道考核指标</View>
  1515. <AtTextarea
  1516. value={info.channelIndicators || ""}
  1517. onChange={e => {
  1518. this.setState({
  1519. info: Object.assign(info, {
  1520. channelIndicators: e,
  1521. }),
  1522. })
  1523. }}
  1524. maxLength={200}
  1525. placeholder='请填写渠道考核指标~'
  1526. />
  1527. </View>
  1528. }
  1529. </AtModalContent>
  1530. <AtModalAction>
  1531. <Button type='secondary' onClick={() => { this.setState({ isOpened: false }) }}>取消</Button>
  1532. <Button type='primary' onClick={this.update}>确定修改</Button>
  1533. </AtModalAction>
  1534. </AtModal>
  1535. <AtModal
  1536. isOpened={this.state.isAdd}
  1537. onClose={() => {
  1538. this.setState({
  1539. isAdd: false
  1540. })
  1541. }}
  1542. >
  1543. <AtModalHeader>联系人</AtModalHeader>
  1544. <AtModalContent>
  1545. {
  1546. userList.map((item) =>
  1547. <View key={item.id} className="additem">
  1548. <Text className="txt">{item.name || " "}</Text>
  1549. <Text className="txt">{item.position || " "}</Text>
  1550. <Text className="txt">{item.department || " "}</Text>
  1551. <Text className="mobile">{item.mobile || " "}</Text>
  1552. <View
  1553. className={item.major == 1 ? "bts" : "bt"}
  1554. onClick={() => {
  1555. item.major != 1 && this.updateMainContact(item.id)
  1556. }}
  1557. >
  1558. {item.major == 1 ? "已选" : "选择"}
  1559. </View>
  1560. </View>
  1561. )
  1562. }
  1563. <AtInput
  1564. required
  1565. name='name'
  1566. title='姓名'
  1567. type='text'
  1568. placeholder='请填写姓名'
  1569. value={obj.name}
  1570. onChange={e => {
  1571. this.setState({
  1572. obj: Object.assign(obj, {
  1573. name: e,
  1574. })
  1575. })
  1576. }}
  1577. />
  1578. <AtInput
  1579. required
  1580. name='position'
  1581. title='职位'
  1582. type='text'
  1583. placeholder='请填写职位'
  1584. value={obj.position}
  1585. onChange={e => {
  1586. this.setState({
  1587. obj: Object.assign(obj, {
  1588. position: e,
  1589. })
  1590. })
  1591. }}
  1592. />
  1593. <AtInput
  1594. required
  1595. name='department'
  1596. title='部门'
  1597. type='text'
  1598. placeholder='请填写部门'
  1599. value={obj.department}
  1600. onChange={e => {
  1601. this.setState({
  1602. obj: Object.assign(obj, {
  1603. department: e,
  1604. })
  1605. })
  1606. }}
  1607. />
  1608. <AtInput
  1609. required
  1610. name='mobile'
  1611. title='手机'
  1612. type='phone'
  1613. placeholder='请填写手机号'
  1614. value={obj.mobile}
  1615. onChange={e => {
  1616. this.setState({
  1617. obj: Object.assign(obj, {
  1618. mobile: e,
  1619. })
  1620. })
  1621. }}
  1622. />
  1623. </AtModalContent>
  1624. <AtModalAction>
  1625. <Button type='secondary'
  1626. onClick={() => {
  1627. this.setState({
  1628. isAdd: false
  1629. }, () => {
  1630. this.queryByUidAll()
  1631. })
  1632. }}>取消</Button>
  1633. <Button type='primary' onClick={this.add}>保存</Button>
  1634. </AtModalAction>
  1635. </AtModal>
  1636. <AtModal
  1637. isOpened={this.state.addItemShow}
  1638. onClose={this.handleCloseAddItemDialog}
  1639. >
  1640. <AtModalHeader>新增对外投资控股的企业</AtModalHeader>
  1641. <AtModalContent>
  1642. <AtInput
  1643. required
  1644. name='mobile'
  1645. title='企业名称'
  1646. placeholder='请输入企业名称'
  1647. value={this.state.addItemInputVal}
  1648. onChange={value => this.setState({ addItemInputVal: value })}
  1649. />
  1650. </AtModalContent>
  1651. <AtModalAction>
  1652. <Button type='secondary' onClick={this.handleCloseAddItemDialog}>取消</Button>
  1653. <Button type='primary' onClick={this.handleAddItemSave}>保存</Button>
  1654. </AtModalAction>
  1655. </AtModal>
  1656. {/* 多选框 */}
  1657. <CheckboxPicker
  1658. isOpened={this.state.multiplePickerShow}
  1659. title={this.state.multiplePickerTitle}
  1660. options={this.state.multiplePickerOptions}
  1661. checkedList={this.state.multiplePickerCheckedList}
  1662. onClose={() => {this.setState({multiplePickerShow: false})}}
  1663. onConfirm={this.handleMultipleConfirm}
  1664. ></CheckboxPicker>
  1665. {/* 沟通情况历史记录 */}
  1666. <InteractList
  1667. isOpened={this.state.interactShow}
  1668. list={dtails.interviewList || []}
  1669. type={this.state.interactShowType}
  1670. title={this.state.interactTitle}
  1671. onClose={() => {
  1672. this.setState({ interactShow: false })
  1673. }}
  1674. />
  1675. </View>
  1676. );
  1677. }
  1678. }
  1679. export default CustomerProfile;