reject.jsx 106 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103
  1. import React from 'react';
  2. import {
  3. Tooltip,
  4. Button,
  5. AutoComplete,
  6. Input,
  7. Select,
  8. Spin,
  9. Popconfirm,
  10. Table,
  11. message,
  12. DatePicker,
  13. Upload,
  14. Form,
  15. Modal,
  16. Col,
  17. Tag,
  18. Tabs,
  19. Radio,
  20. Checkbox,
  21. } from 'antd';
  22. import $ from 'jquery/src/ajax';
  23. import moment from 'moment';
  24. import { boutique, tepi, jiedian, salesList, cuiJieDian } from '@/dataDic.js';
  25. import {
  26. getLiquidationStatus,
  27. getProcessStatus,
  28. splitUrl,
  29. getCuikuan,
  30. moneyVerify,
  31. ShowModal,
  32. getProjectName,
  33. getApprovedType,
  34. compare,
  35. } from "@/tools.js";
  36. import './customer.less';
  37. import ShowModalDiv from "@/showModal.jsx"
  38. import OrderRiZi from "@/orderRiZi.jsx";
  39. import ResolutionDetail from "@/resolutionDetail";
  40. import ImgList from "../../../common/imgList";
  41. import { ChooseList } from "./chooseList";
  42. import OrderItemStatus from "../../../common/orderItemStatus";
  43. import EnterpriseNameChange from "../../../common/enterpriseNameChange";
  44. import OrderCoor from './changeComponent/orderCoor';
  45. import ProjectOperation from "../../../common/projectOperation";
  46. import NewAddProject from "../../../common/projectOperation/newAddProject"
  47. import NewEditProject from "../../../common/projectOperation/newEditProject"
  48. import ContentUrl from './contentUrl';
  49. import UpdateSales from './updatesales';//修改销售类型
  50. import PicturesWall from "./changeComponent/picturesWall.js";
  51. import FlowChart from '../../../common/flowchart'; // 流程图
  52. import Gxczx from '../../../common/orderDetail/gxczx' // 高新纯咨询合同说明详情
  53. import Property from '../../../common/orderDetail/property' // 知识产权情况
  54. const CheckboxGroup = Checkbox.Group;
  55. const IntentionCustomer = Form.create()(
  56. React.createClass({
  57. loadData(pageNo) {
  58. this.setState({
  59. visitModul: false,
  60. loading: true,
  61. ispage: pageNo,
  62. modalVisible: false,
  63. });
  64. $.ajax({
  65. method: "get",
  66. dataType: "json",
  67. crossDomain: false,
  68. url: globalConfig.context + "/api/admin/newOrder/orderNewList",
  69. data: {
  70. pageNo: pageNo || 1,
  71. pageSize: this.state.pagination.pageSize,
  72. specially: 2, //审核列表
  73. name: this.state.customerName, //名称
  74. orderNo: this.state.orderNoSearch, //订单编号
  75. starTime: this.state.releaseDate[0], //开始时间
  76. endTime: this.state.releaseDate[1], //结束时间
  77. },
  78. success: function (data) {
  79. ShowModal(this);
  80. let theArr = [];
  81. if (data.error.length || data.data.list == "") {
  82. if (data.error && data.error.length) {
  83. message.warning(data.error[0].message);
  84. }
  85. } else {
  86. for (let i = 0; i < data.data.list.length; i++) {
  87. let thisdata = data.data.list[i];
  88. thisdata.key = i;
  89. thisdata.totalAmount = thisdata.totalAmount + ""; //签单金额
  90. theArr.push(thisdata);
  91. }
  92. this.state.pagination.total = data.data.totalCount;
  93. this.state.pagination.current = data.data.pageNo;
  94. }
  95. if (data.data && data.data.list && !data.data.list.length) {
  96. this.state.pagination.total = 0;
  97. }
  98. this.setState({
  99. dataSource: theArr,
  100. pageNo: pageNo,
  101. pagination: this.state.pagination,
  102. selectedRowKeys: [],
  103. });
  104. }.bind(this),
  105. }).always(
  106. function () {
  107. this.setState({
  108. loading: false,
  109. });
  110. }.bind(this)
  111. );
  112. },
  113. getInitialState() {
  114. return {
  115. approvaType: [],
  116. isShow: true, // 高新纯咨询合同默认填写
  117. page: 1,
  118. orderNos: '',
  119. patentTypeList: [],
  120. releaseDate: [],
  121. orderStatus: 0,
  122. processStatus: 0,
  123. selectedRowKeys: [],
  124. orgCodeUrl: [],
  125. replenishUrl: [],
  126. contentUrl: [],
  127. customerArr: [],
  128. resVisible: false,
  129. pagination: {
  130. defaultCurrent: 1,
  131. defaultPageSize: 10,
  132. showQuickJumper: true,
  133. pageSize: 10,
  134. onChange: function (page) {
  135. this.loadData(page);
  136. }.bind(this),
  137. showTotal: function (total) {
  138. return "共" + total + "条数据";
  139. },
  140. },
  141. columns: [
  142. {
  143. title: "驳回编号",
  144. dataIndex: "backId",
  145. key: "backId",
  146. },
  147. {
  148. title: "驳回日期",
  149. dataIndex: "backDate",
  150. key: "backDate",
  151. },
  152. {
  153. title: "下单时间",
  154. dataIndex: "createDate",
  155. key: "createDate",
  156. },
  157. {
  158. title: "订单编号",
  159. dataIndex: "orderNo",
  160. key: "orderNo",
  161. },
  162. {
  163. title: "客户名称",
  164. dataIndex: "userName",
  165. key: "userName",
  166. render: (text) => {
  167. return (
  168. <Tooltip title={text}>
  169. <div
  170. // style={{
  171. // maxWidth: '150px',
  172. // overflow: 'hidden',
  173. // textOverflow: "ellipsis",
  174. // whiteSpace: 'nowrap',
  175. // }}
  176. >{text}</div>
  177. </Tooltip>
  178. )
  179. },
  180. },
  181. {
  182. title: "驳回人",
  183. dataIndex: "initiateName",
  184. key: "initiateName",
  185. },
  186. {
  187. title: "驳回原因",
  188. dataIndex: "reason",
  189. key: "reason",
  190. render: (text) => {
  191. return text && text.length > 24
  192. ? text.substr(0, 24) + "..."
  193. : text;
  194. },
  195. },
  196. ],
  197. columnsrizhi: [
  198. {
  199. title: "流程",
  200. dataIndex: "processName",
  201. key: "processName",
  202. },
  203. {
  204. title: "操作人",
  205. dataIndex: "adminName",
  206. key: "adminName",
  207. },
  208. {
  209. title: "时间",
  210. dataIndex: "createDate",
  211. key: "createDate",
  212. },
  213. ],
  214. data: [],
  215. dataSource: [],
  216. columnsX: [
  217. {
  218. title: "业务项目名称",
  219. dataIndex: "commodityName",
  220. key: "commodityName",
  221. render: (text, record) => {
  222. return <span>
  223. {text}<span style={{ color: "red" }}>{record.patentTypeName}</span>{"-" + record.id}
  224. <div>
  225. {record.cSort == 6 && record.projectType == 1 && <span>(含{record.htMember == 1 ? '高新会员&' : ''}{record.additionalDeduction == 1 ? '加计扣除&' : ''}{record.rdAwardsubsidy == 1 ? '研发奖补' : ''})</span>}
  226. {record.cSort == 6 && ([0, 3].indexOf(record.projectType) > -1) && <span>(仅提供单边会员服务)</span>}
  227. {record.cSort == 6 && record.projectType == 2 && <span>(仅填报表,仅咨询,不出备查资料)</span>}
  228. {record.cSort == 3 && <span>{record.technologyProjectType==0?'(简易项目)':record.technologyProjectType==1?'(市区级)':record.technologyProjectType==2?'(省级)':record.technologyProjectType==3?'(国家级)':''}</span>}
  229. {record.cSort == 8 ? (record.type != 2 && record.patentType == 1) ? <span>(变更)</span> : <span>{record.ordinaryRisk == 0 ? '(普通申请)' : record.ordinaryRisk == 1 ? '(风险代理)' : ''}</span> : ""}
  230. {record.type == 2 && <span>({record.days == 0 ? '普通' : record.days == 1 ? '加急' : ''}{record.scheme == 0 ? '&无方案' : record.scheme == 1 ? '&有方案' : ''})</span>}
  231. </div>
  232. </span>
  233. }
  234. },
  235. {
  236. title: "项目类别",
  237. dataIndex: "cname",
  238. key: "cname",
  239. },
  240. {
  241. title: "项目数量",
  242. dataIndex: "commodityQuantity",
  243. key: "commodityQuantity",
  244. render: (text, record) => {
  245. if (record.splitStatus == 1) {
  246. return (
  247. <span>
  248. {text}{" "}
  249. {/* <Tag
  250. color="#108ee9"
  251. onClick={(e) => {
  252. e.stopPropagation();
  253. this.showRes(record);
  254. }}
  255. >
  256. 已拆
  257. </Tag> */}
  258. </span>
  259. );
  260. } else {
  261. return text;
  262. }
  263. },
  264. },
  265. {
  266. title: "金额(万元)",
  267. dataIndex: "commodityPrice",
  268. key: "commodityPrice",
  269. },
  270. {
  271. title: "负责人",
  272. dataIndex: "contacts",
  273. key: "contacts",
  274. },
  275. {
  276. title: "负责人电话",
  277. dataIndex: "contactsMobile",
  278. key: "contactsMobile",
  279. },
  280. {
  281. title: "主要项目",
  282. dataIndex: "main",
  283. key: "main",
  284. render: (text) => {
  285. return text ? "是" : "否";
  286. },
  287. },
  288. {
  289. title: "总年限",
  290. dataIndex: "yearSum",
  291. key: "yearSum",
  292. render: (text, record) => {
  293. return (
  294. <div>{["", "一年", "二年", "三年", "四年", "五年"][text]}</div>
  295. );
  296. }
  297. },
  298. {
  299. title: "年限",
  300. dataIndex: "serviceLife",
  301. key: "serviceLife",
  302. render: (text, record) => {
  303. return (
  304. <div>{!!text && JSON.parse(text).toString()}</div>
  305. );
  306. }
  307. },
  308. {
  309. title: "本次派单",
  310. dataIndex: "serviceYear",
  311. key: "serviceYear",
  312. render: (text, record) => {
  313. return (
  314. <div>{!text ? "" : text}</div>
  315. );
  316. }
  317. },
  318. {
  319. title: "项目说明",
  320. dataIndex: "taskComment",
  321. key: "taskComment",
  322. render: (text, record) => {
  323. let textStr = text;
  324. return (
  325. <Tooltip title={textStr}>
  326. <div
  327. style={{
  328. width: 100,
  329. overflow: "hidden",
  330. whiteSpace: "nowrap",
  331. textOverflow: "ellipsis",
  332. }}
  333. >{textStr}</div>
  334. </Tooltip>
  335. )
  336. },
  337. },
  338. {
  339. title: "操作",
  340. dataIndex: "ABC",
  341. key: "ABC",
  342. width: 80,
  343. render: (text, record) => {
  344. return (
  345. this.state.processStatus == 0 &&
  346. <div>
  347. <div>
  348. <Popconfirm
  349. title="是否要删除?如果删除此项目业务,对应的催款节点也会删除!"
  350. onConfirm={() => {
  351. this.delectRow(record);
  352. }}
  353. okText="是"
  354. cancelText="否"
  355. >
  356. <Button
  357. onClick={(e) => {
  358. e.stopPropagation();
  359. }}
  360. type="danger"
  361. >
  362. 删除
  363. </Button>
  364. </Popconfirm>
  365. </div>
  366. <div>
  367. <Button
  368. onClick={(e) => {
  369. e.stopPropagation();
  370. this.setState({
  371. editProjectOperationVisible: true,
  372. dataInfor: record,
  373. })
  374. }}
  375. >
  376. 编辑
  377. </Button>
  378. </div>
  379. </div>
  380. );
  381. },
  382. },
  383. ],
  384. dataSourceX: [],
  385. ContactsListsNew: [
  386. {
  387. title: "项目名称",
  388. dataIndex: "commodityName",
  389. key: "commodityName",
  390. render: (text, record, index) => {
  391. let dataArr = this.state.dataSourceX || [];
  392. if (text) {
  393. return <span>{text + "-" + record.tid}</span>;
  394. }
  395. return (
  396. <Select
  397. placeholder="请选择名称"
  398. style={{ width: "150px" }}
  399. disabled={
  400. this.state.getLoad && record.sortName ? true : false
  401. }
  402. onChange={(e) => {
  403. // record.sortName = e;
  404. // dataArr.forEach((item) => {
  405. // if (item.commodityName == record.sortName) {
  406. // record.cname = item.cname;
  407. // record.tid = item.id;
  408. // record.isSave = true;
  409. // record.sort = item.sort;
  410. // console.log(record);
  411. // cuiJieDian.forEach((item) => {
  412. // if (item.value == record.sort) {
  413. // record.arr = item.children;
  414. // let yearFlag = true;
  415. // if (record.sort == 6) {
  416. // yearFlag = false;
  417. // }
  418. // this.setState({
  419. // getLoad: true,
  420. // yearFlag,
  421. // });
  422. // }
  423. // });
  424. // }
  425. // });
  426. // console.log(e);
  427. let proData = dataArr[e];
  428. record.cname = proData.cname;
  429. record.tid = proData.id;
  430. record.isSave = true;
  431. record.sort = proData.sort;
  432. cuiJieDian.forEach((item) => {
  433. if (item.value == record.sort) {
  434. record.arr = item.children;
  435. let yearFlag = true;
  436. if (record.sort == 6) {
  437. yearFlag = false;
  438. }
  439. this.setState({
  440. getLoad: true,
  441. yearFlag,
  442. });
  443. }
  444. });
  445. }}
  446. >
  447. {dataArr.map((item) => {
  448. return (
  449. <Select.Option key={item.id} value={item.key}>
  450. {item.commodityName + "-" + item.id}
  451. </Select.Option>
  452. );
  453. })}
  454. </Select>
  455. );
  456. },
  457. },
  458. {
  459. title: "项目分类",
  460. dataIndex: "projectType",
  461. key: "projectType",
  462. render: (text, record) => {
  463. if (text) {
  464. let arr = this.state.dataSourceX || [];
  465. let str = "";
  466. for (let i = 0; i < arr.length; i++) {
  467. if (this.state.dataSourceX[i].sort == text) {
  468. str = this.state.dataSourceX[i].cname;
  469. return <span>{str}</span>;
  470. }
  471. }
  472. }
  473. if (this.state.getLoad) {
  474. return (
  475. <Select
  476. style={{ width: "150px" }}
  477. placeholder="请选择分类"
  478. value={record.cname}
  479. >
  480. <Select.Option key={record.sort} value={record.cname}>
  481. {record.cname}
  482. </Select.Option>
  483. </Select>
  484. );
  485. } else {
  486. return (
  487. <Select style={{ width: "150px" }} placeholder="请选择分类">
  488. <Select.Option key={record.sort} value={record.cname}>
  489. {record.cname}
  490. </Select.Option>
  491. </Select>
  492. );
  493. }
  494. },
  495. },
  496. {
  497. title: "催款科目",
  498. dataIndex: "dunTypeName",
  499. key: "dunTypeName",
  500. render: (text, record) => {
  501. if (text) {
  502. if (record.customizeName) {
  503. return record.customizeName;
  504. }
  505. return <span>{text}</span>;
  506. }
  507. if (this.state.getLoad) {
  508. let arr = record.arr || [];
  509. return (
  510. <div>
  511. <Select
  512. style={{ width: "150px" }}
  513. placeholder="请选择分类"
  514. onChange={(e) => {
  515. record.dunType = e;
  516. if (record.dunType == 0) {
  517. record.customizeTimes = "";
  518. record.customizeName = "";
  519. }
  520. if (e == 0) {
  521. record.dunTypeCustom = true;
  522. } else {
  523. record.dunTypeCustom = false;
  524. }
  525. if (e != 1) {
  526. this.setState({
  527. timeFlag: true,
  528. });
  529. } else {
  530. this.setState({
  531. timeFlag: false,
  532. });
  533. }
  534. if (e == 1 && record.sort == 6) {
  535. this.setState({
  536. yearFlag: true,
  537. });
  538. } else if (e != 1 && record.sort == 6) {
  539. this.setState({
  540. yearFlag: false,
  541. });
  542. }
  543. if (record.sort == 3 && e == 3) {
  544. this.setState({
  545. boFlag: true,
  546. });
  547. } else {
  548. this.setState({
  549. boFlag: false,
  550. });
  551. }
  552. }}
  553. >
  554. {arr.map((item) => {
  555. record;
  556. return (
  557. <Select.Option key={item.value} value={item.value}>
  558. {item.key}
  559. </Select.Option>
  560. );
  561. })}
  562. <Select.Option key={0} value={0}>
  563. 自定义
  564. </Select.Option>
  565. </Select>
  566. {record.dunType == 0 ? (
  567. <Input
  568. value={record.customizeName}
  569. placeholder="请输入自定义名称"
  570. required="required"
  571. onChange={(e) => {
  572. record.customizeName = e.target.value;
  573. this.setState({
  574. contactList: this.state.contactList,
  575. });
  576. }}
  577. style={{ width: "120px" }}
  578. />
  579. ) : (
  580. ""
  581. )}
  582. </div>
  583. );
  584. } else {
  585. return (
  586. <Select style={{ width: "150px" }} placeholder="请选择分类">
  587. <Select.Option
  588. key={0}
  589. value={"请选择上一项"}
  590. ></Select.Option>
  591. </Select>
  592. );
  593. }
  594. },
  595. },
  596. {
  597. title: "收款时间(特批需选择时间)",
  598. dataIndex: "waitDay",
  599. key: "waitDay",
  600. render: (text, record) => {
  601. if (record.dunTypeName) {
  602. if (record.customizeTimes) {
  603. return record.customizeTimes;
  604. }
  605. if (text == 0) {
  606. var str = "当天";
  607. } else if (!text) {
  608. var str = "";
  609. } else {
  610. var str = text + "天";
  611. }
  612. return <span>{str}</span>;
  613. }
  614. return (
  615. <div>
  616. {record.dunType == 0 ? (
  617. <DatePicker
  618. style={{ width: 150 }}
  619. onChange={(e, t) => {
  620. record.customizeTimes = t;
  621. }}
  622. />
  623. ) : (
  624. <Select
  625. placeholder="请选择时间"
  626. style={{ width: "160px" }}
  627. disabled={
  628. this.state.approval != 0 && !this.state.timeFlag
  629. ? false
  630. : true
  631. }
  632. onChange={(e) => {
  633. record.waitDay = e;
  634. }}
  635. >
  636. <Select.Option key={0}>当天</Select.Option>
  637. <Select.Option key={3}>3天</Select.Option>
  638. <Select.Option key={5}>5天</Select.Option>
  639. <Select.Option key={7}>7天</Select.Option>
  640. <Select.Option key={15}>15天</Select.Option>
  641. </Select>
  642. )}
  643. </div>
  644. );
  645. },
  646. },
  647. {
  648. title: "金额(万元)",
  649. dataIndex: "money",
  650. key: "money",
  651. render: (text, record) => {
  652. if (record.dunTypeName) {
  653. if (record.appropriationRatio) {
  654. let percent = Number(record.appropriationRatio * 100).toFixed(2);
  655. percent += "%";
  656. return <span>{percent}(拨款比例)</span>;
  657. } else {
  658. return <span>{text}</span>;
  659. }
  660. }
  661. return (
  662. <div>
  663. <div style={{ width: 70, float: "left", marginRight: 5 }}>
  664. <Select
  665. placeholder="选择"
  666. defaultValue={"金额"}
  667. onChange={(e) => {
  668. record.boStatus = e;
  669. }}
  670. >
  671. <Select.Option key={true}>比例</Select.Option>
  672. <Select.Option key={false}>金额</Select.Option>
  673. </Select>
  674. </div>
  675. <div style={{ float: "right" }}>
  676. <Input
  677. value={record.money}
  678. key={record.id}
  679. required="required"
  680. onChange={(e) => {
  681. record.money = e.target.value;
  682. this.setState({
  683. contactList: this.state.contactList,
  684. });
  685. }}
  686. style={{ width: "120px" }}
  687. />
  688. </div>
  689. </div>
  690. );
  691. // if (this.state.boFlag) {
  692. // return (
  693. // <div>
  694. // <div style={{ width: 70, float: "left", marginRight: 5 }}>
  695. // <Select
  696. // placeholder="选择"
  697. // defaultValue={"金额"}
  698. // onChange={(e) => {
  699. // record.boStatus = e;
  700. // }}
  701. // >
  702. // <Select.Option key={true}>比例</Select.Option>
  703. // <Select.Option key={false}>金额</Select.Option>
  704. // </Select>
  705. // </div>
  706. // <div style={{ float: "right" }}>
  707. // <Input
  708. // value={record.money}
  709. // key={record.id}
  710. // required="required"
  711. // onChange={(e) => {
  712. // record.money = e.target.value;
  713. // this.setState({
  714. // contactList: this.state.contactList,
  715. // });
  716. // }}
  717. // style={{ width: "120px" }}
  718. // />
  719. // </div>
  720. // </div>
  721. // );
  722. // } else {
  723. // return (
  724. // <div>
  725. // <Input
  726. // value={record.money}
  727. // placeholder="请输入金额(必填项)"
  728. // key={record.id}
  729. // required="required"
  730. // onChange={(e) => {
  731. // record.money = e.target.value;
  732. // this.setState({ contactList: this.state.contactList });
  733. // }}
  734. // style={{ width: "120px" }}
  735. // />
  736. // </div>
  737. // );
  738. // }
  739. },
  740. },
  741. {
  742. title: "服务年限",
  743. dataIndex: "startDate",
  744. key: "startDate",
  745. render: (text, record) => {
  746. if (record.dunTypeName) {
  747. return <span>{text}</span>;
  748. }
  749. return (
  750. <div>
  751. {
  752. record.dunType != 0 ?
  753. <Select
  754. placeholder="请选择年限"
  755. style={{ width: "150px" }}
  756. disabled={this.state.yearFlag ? true : false}
  757. onChange={(e) => {
  758. record.effectiveCount = e;
  759. }}
  760. >
  761. {/* <Select.Option key={null}>无</Select.Option> */}
  762. <Select.Option key={1}>一年</Select.Option>
  763. <Select.Option key={3}>两年</Select.Option>
  764. <Select.Option key={5}>三年</Select.Option>
  765. <Select.Option key={7}>四年</Select.Option>
  766. <Select.Option key={9}>五年</Select.Option>
  767. </Select> : <div />
  768. }
  769. </div>
  770. );
  771. },
  772. },
  773. {
  774. title: "催款状态",
  775. dataIndex: "status",
  776. key: "status",
  777. render: (text) => {
  778. return <span>{text == 1 ? "已启动" : "未启动"}</span>;
  779. },
  780. },
  781. {
  782. title: "操作",
  783. dataIndex: "dels",
  784. key: "dels",
  785. render: (text, record, index) => {
  786. return (
  787. <div>
  788. {this.state.processStatus == 0 ? (
  789. <Popconfirm
  790. title="是否删除?"
  791. onConfirm={() => {
  792. this.confirmDeletNew(record);
  793. }}
  794. okText="删除"
  795. cancelText="不删除"
  796. >
  797. <Button
  798. style={{
  799. marginRight: "10px",
  800. color: "#ffffff",
  801. background: "#f00",
  802. border: "none",
  803. }}
  804. >
  805. 删除
  806. </Button>
  807. </Popconfirm>
  808. ) : (
  809. ""
  810. )}
  811. {record.isSave ? (
  812. <Button
  813. type="primary"
  814. onClick={(e) => {
  815. this.contactSaveNew(record);
  816. this.setState({
  817. addFlag: false,
  818. });
  819. }}
  820. >
  821. 保存
  822. </Button>
  823. ) : (
  824. ""
  825. )}
  826. </div>
  827. );
  828. },
  829. },
  830. ],
  831. ContactsLists: [
  832. {
  833. title: "催款科目",
  834. dataIndex: "dunSubject",
  835. key: "dunSubject",
  836. render: (text, record) => {
  837. return (
  838. <Select
  839. placeholder="请选择催款科目"
  840. value={record.dunSubject}
  841. disabled
  842. style={{ width: "150px" }}
  843. onChange={(e) => {
  844. record.dunSubject = e;
  845. this.setState({ contactList: this.state.contactList });
  846. }}
  847. >
  848. {jiedian.map(function (item) {
  849. return (
  850. <Select.Option key={item.value}>{item.key}</Select.Option>
  851. );
  852. })}
  853. </Select>
  854. );
  855. },
  856. },
  857. {
  858. title: "金额(万元)",
  859. dataIndex: "money",
  860. key: "money",
  861. render: (text, record) => {
  862. return (
  863. <Input
  864. value={record.money}
  865. disabled
  866. placeholder="请输入金额(必填项)"
  867. key={record.id}
  868. required="required"
  869. onChange={(e) => {
  870. record.money = e.target.value;
  871. this.setState({ contactList: this.state.contactList });
  872. }}
  873. style={{ width: "120px" }}
  874. />
  875. );
  876. },
  877. },
  878. {
  879. title: "催款状态",
  880. dataIndex: "dunStatus",
  881. key: "dunStatus",
  882. render: (text) => {
  883. return getCuikuan(text);
  884. },
  885. },
  886. {
  887. title: "操作",
  888. dataIndex: "dels",
  889. key: "dels",
  890. render: (text, record) => {
  891. return (
  892. <div>
  893. {
  894. <Popconfirm
  895. title="是否删除?"
  896. onConfirm={() => {
  897. this.confirmDelet(record.key);
  898. }}
  899. okText="删除"
  900. cancelText="不删除"
  901. >
  902. <Button
  903. style={{
  904. marginRight: "10px",
  905. color: "#ffffff",
  906. background: "#f00",
  907. border: "none",
  908. }}
  909. >
  910. 删除
  911. </Button>
  912. </Popconfirm>
  913. }
  914. {record.id ? (
  915. ""
  916. ) : (
  917. <Button type="primary" onClick={this.contactSave} disabled>
  918. 保存
  919. </Button>
  920. )}
  921. </div>
  922. );
  923. },
  924. },
  925. ],
  926. updatas: {},
  927. };
  928. },
  929. //删除
  930. delectRow(record) {
  931. this.setState({
  932. loading: true,
  933. });
  934. $.ajax({
  935. method: "post",
  936. dataType: "json",
  937. crossDomain: false,
  938. url: globalConfig.context + "/api/admin/newOrder/deleteOrderTask",
  939. data: {
  940. id: record.id,
  941. },
  942. }).done(
  943. function (data) {
  944. if (!data.error.length) {
  945. message.success("删除成功!");
  946. this.setState({
  947. loading: false,
  948. });
  949. this.xiangmu(this.state.orderNo);
  950. this.jiedianNew(this.state.orderNo);
  951. this.jiedian(this.state.orderNo);
  952. this.loadData(this.state.pageNo);
  953. } else {
  954. message.warning(data.error[0].message);
  955. }
  956. }.bind(this)
  957. );
  958. },
  959. //页面加载函数
  960. componentWillMount() {
  961. this.loadData();
  962. },
  963. //整行点击
  964. tableRowClick(record) {
  965. this.setState({
  966. visible: true,
  967. orderNos: record.orderNo,
  968. orderStatus: record.orderStatus,
  969. processStatus: record.orderStatus
  970. });
  971. this.xiangqing(record.orderNo);
  972. this.xiangmu(record.orderNo);
  973. this.jiedian(record.orderNo);
  974. this.jiedianNew(record.orderNo);
  975. this.departmentList();
  976. this.getpatentTypeList();
  977. },
  978. //点击打卡项目详情
  979. tableRowClickX(record) {
  980. this.setState({
  981. projectOperationVisible: true,
  982. dataInfor: record,
  983. })
  984. },
  985. //项目详情关闭
  986. nextCancel() {
  987. this.setState({
  988. projectOperationVisible: false,
  989. editProjectOperationVisible: false,
  990. gid: "",
  991. dataInfor: {},
  992. }, () => {
  993. this.xiangmu(this.state.orderNo);
  994. });
  995. },
  996. //订单详情
  997. xiangqing(orderNos) {
  998. $.ajax({
  999. method: "get",
  1000. dataType: "json",
  1001. crossDomain: false,
  1002. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  1003. data: {
  1004. orderNo: orderNos,
  1005. },
  1006. success: function (data) {
  1007. if (data.error.length || data.data.list == "") {
  1008. if (data.error && data.error.length) {
  1009. message.warning(data.error[0].message);
  1010. }
  1011. } else {
  1012. let thisdata = data.data;
  1013. if (thisdata.approval == 0) {
  1014. thisdata.approval = 0;
  1015. } else {
  1016. thisdata.approval = 1;
  1017. }
  1018. // if (thisdata.approval == 2) {
  1019. // thisdata.approval = "特批通过";
  1020. // } else if (thisdata.approval == 3) {
  1021. // thisdata.approval = "特批驳回";
  1022. // }
  1023. this.setState({
  1024. id: thisdata.id,
  1025. orderUid: thisdata.uid,
  1026. kehuId: thisdata.buyerId,
  1027. orderNo: thisdata.orderNo, //订单编号
  1028. contractNo: thisdata.contractNo, //合同编号
  1029. userName: thisdata.userName, //客户名称
  1030. signDate: thisdata.signDate, //签单时间
  1031. examineName: thisdata.examineName,
  1032. processStatus: thisdata.processStatus, //流程状态
  1033. liquidationStatus: thisdata.liquidationStatus, //结算状态
  1034. contacts: thisdata.contacts, //企业联系人
  1035. contactMobile: thisdata.contactMobile, //联系人电话
  1036. legalPerson: thisdata.legalPerson, //法人
  1037. legalPersonTel: thisdata.legalPersonTel, //法人电话
  1038. firstAmount: thisdata.firstAmount + "", //签单金额
  1039. totalAmount: thisdata.totalAmount + "", //首付金额
  1040. settlementAmount: thisdata.settlementAmount, //已收款项
  1041. orderRemarks: thisdata.orderRemarks, //订单留言
  1042. orgCodeUrl: thisdata.contractPictureUrl
  1043. ? splitUrl(
  1044. thisdata.contractPictureUrl,
  1045. ",",
  1046. globalConfig.avatarHost + "/upload"
  1047. )
  1048. : [], //图片地址
  1049. replenishUrl: thisdata.agreementUrl
  1050. ? splitUrl(
  1051. thisdata.agreementUrl,
  1052. ",",
  1053. globalConfig.avatarHost + "/upload"
  1054. )
  1055. : [], //图片地址
  1056. contentUrl: thisdata.serviceContent
  1057. ? splitUrl(
  1058. thisdata.serviceContent,
  1059. ",",
  1060. globalConfig.avatarHost + "/upload"
  1061. )
  1062. : [], //图片地址
  1063. salesmanName: thisdata.salesmanName, //营销员名称
  1064. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  1065. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  1066. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  1067. financeName: thisdata.financeName, //财务名称
  1068. financeMobile: thisdata.financeMobile, //财务电话
  1069. nowFinance: thisdata.nowFinance, //财务名称
  1070. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  1071. initiateName: thisdata.initiateName, //驳回人
  1072. backDate: thisdata.backDate, //驳回时间
  1073. reason: thisdata.reason, //驳回原因
  1074. approval: thisdata.approval, //特批状态
  1075. organizationSearch: thisdata.orderDep,
  1076. //approval:thisdata.approval==0?thisdata.approval.toString():thisdata.approval,//特批状态
  1077. outsource: thisdata.outsource == 0 ? "否" : "是",
  1078. deleteSign: thisdata.deleteSign,
  1079. updatas: {
  1080. salesType: thisdata.salesType,//销售类型
  1081. userType: thisdata.userType,//客户所属类型
  1082. other: thisdata.other,//3渠道名 4,5描述
  1083. },
  1084. channelName: thisdata.salesType == "3" ? thisdata.other : "",//销售类型为渠道的时候给编辑出的渠道名称赋值
  1085. knowledgeServices: thisdata.knowledgeServices, //知识产权服务
  1086. auditServices: thisdata.auditServices, //审计服务
  1087. addDeductionServices: thisdata.addDeductionServices, //加计扣除服务
  1088. knowledgeOther: thisdata.knowledgeOther, //知识产权服务其他描述
  1089. auditOther: thisdata.auditOther, //审计服务其他描述
  1090. addDeductionOther: thisdata.addDeductionOther, //加计扣除服务其他描述
  1091. isShow: thisdata.knowledgeServices ? true : false, //无数据默认隐藏
  1092. patentStatus: thisdata.patentStatus, // 知识产权情况
  1093. isProperty: thisdata.patentStatus == null ? null : thisdata.patentStatus == 0 ? 1 : 2,
  1094. approvaType: thisdata.type ? thisdata.type.split(",").map(Number) : [], // 特批类型
  1095. typeExplain: thisdata.typeExplain,
  1096. });
  1097. }
  1098. }.bind(this),
  1099. }).always(
  1100. function () {
  1101. this.setState({
  1102. loading: false,
  1103. });
  1104. }.bind(this)
  1105. );
  1106. },
  1107. // 拆分详细
  1108. showRes(record) {
  1109. this.setState({
  1110. resVisible: true,
  1111. resRecord: record,
  1112. });
  1113. },
  1114. resCancel() {
  1115. this.setState({
  1116. resVisible: false,
  1117. });
  1118. },
  1119. //项目列表
  1120. xiangmu(orderNos) {
  1121. $.ajax({
  1122. method: "get",
  1123. dataType: "json",
  1124. crossDomain: false,
  1125. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  1126. data: {
  1127. orderNo: orderNos,
  1128. },
  1129. success: function (data) {
  1130. let theArr = [];
  1131. if (data.error.length || data.data.list == "") {
  1132. if (data.error && data.error.length) {
  1133. message.warning(data.error[0].message);
  1134. }
  1135. } else {
  1136. for (let i = 0; i < data.data.length; i++) {
  1137. let thisdata = data.data[i];
  1138. thisdata.key = i;
  1139. thisdata.sort = thisdata.cSort;
  1140. theArr.push(thisdata);
  1141. }
  1142. }
  1143. this.setState({
  1144. dataSourceX: theArr,
  1145. paginations: false,
  1146. });
  1147. }.bind(this),
  1148. }).always(
  1149. function () {
  1150. this.setState({
  1151. loading: false,
  1152. });
  1153. }.bind(this)
  1154. );
  1155. },
  1156. //节点列表
  1157. jiedian(orderNos) {
  1158. $.ajax({
  1159. method: "get",
  1160. dataType: "json",
  1161. crossDomain: false,
  1162. url: globalConfig.context + "/api/admin/newOrder/selectOrderDun",
  1163. data: {
  1164. orderNo: orderNos,
  1165. },
  1166. success: function (data) {
  1167. let theArr = [];
  1168. let thisData = [];
  1169. if (data.error.length || data.data.list == "") {
  1170. if (data.error && data.error.length) {
  1171. message.warning(data.error[0].message);
  1172. }
  1173. } else {
  1174. for (let i = 0; i < data.data.length; i++) {
  1175. thisData = data.data[i];
  1176. theArr.push({
  1177. key: i,
  1178. dunSubject: thisData.dunSubject
  1179. ? thisData.dunSubject.toString()
  1180. : "", //催款科目
  1181. id: thisData.id, //节点Id
  1182. money: thisData.money, //催款金额
  1183. dunStatus: thisData.dunStatus, //催款状态
  1184. orderNo: thisData.orderNo,
  1185. });
  1186. }
  1187. this.setState({
  1188. contactList: theArr,
  1189. });
  1190. }
  1191. }.bind(this),
  1192. }).always(
  1193. function () {
  1194. this.setState({
  1195. loading: false,
  1196. });
  1197. }.bind(this)
  1198. );
  1199. },
  1200. //查看催款节点
  1201. jiedianNew(orderNos) {
  1202. $.ajax({
  1203. method: "get",
  1204. dataType: "json",
  1205. crossDomain: false,
  1206. url:
  1207. globalConfig.context + "/api/admin/newOrderDun/selectListNewOrderDun",
  1208. data: {
  1209. orderNo: orderNos,
  1210. },
  1211. success: function (data) {
  1212. if (data.error && data.error.length) {
  1213. message.warning(data.error[0].message);
  1214. } else {
  1215. let theArr = [];
  1216. let thisData = [];
  1217. let arr = data.data || [];
  1218. let totalCui = 0;
  1219. for (let i = 0; i < arr.length; i++) {
  1220. thisData = arr[i];
  1221. totalCui += +thisData.money;
  1222. theArr.push({
  1223. key: i,
  1224. dunSubject: thisData.dunSubject
  1225. ? thisData.dunSubject.toString()
  1226. : "", //催款科目
  1227. id: thisData.id, //节点Id
  1228. money: thisData.money, //催款金额
  1229. // orderNo: record ? record.orderNo : this.props.datauser.orderNo,
  1230. commodityName: thisData.commodityName,
  1231. projectType: thisData.projectType,
  1232. dunTypeName: thisData.dunTypeName,
  1233. status: thisData.status,
  1234. waitDay: thisData.waitDay,
  1235. effectiveCount: thisData.effectiveCount,
  1236. startDate: thisData.startDate,
  1237. dunType: thisData.dunType,
  1238. appropriationRatio: thisData.appropriationRatio,
  1239. customizeName: thisData.customizeName,
  1240. customizeTimes: thisData.customizeTimes,
  1241. tid: thisData.tid,
  1242. });
  1243. }
  1244. if (!totalCui) {
  1245. totalCui = 0;
  1246. }
  1247. totalCui = (Math.round(totalCui * 1000000) / 1000000).toFixed(6);
  1248. this.setState({
  1249. contactListNew: theArr,
  1250. totalCui: parseFloat(totalCui),
  1251. });
  1252. }
  1253. }.bind(this),
  1254. }).always(
  1255. function () {
  1256. this.setState({
  1257. loading: false,
  1258. });
  1259. }.bind(this)
  1260. );
  1261. },
  1262. //催款节点保存
  1263. contactSave() {
  1264. for (let i = 0; i < this.state.contactList.length; i++) {
  1265. if (moneyVerify(this.state.contactList[i].money)) {
  1266. return;
  1267. }
  1268. }
  1269. this.setState({
  1270. loading: true,
  1271. });
  1272. $.ajax({
  1273. url: globalConfig.context + "/api/admin/newOrder/createOrderDun",
  1274. method: "post",
  1275. data: {
  1276. orderNo: this.state.orderNo,
  1277. orderDun: JSON.stringify(this.state.contactList),
  1278. },
  1279. }).done(
  1280. function (data) {
  1281. this.setState({
  1282. loading: false,
  1283. });
  1284. if (!data.error.length) {
  1285. message.success("保存成功!");
  1286. this.jiedian(this.state.orderNo);
  1287. } else {
  1288. message.warning(data.error[0].message);
  1289. }
  1290. }.bind(this)
  1291. );
  1292. },
  1293. //催款节点保存
  1294. contactSaveNew(record) {
  1295. if (record.dunType == 0) {
  1296. if (!record.customizeTimes) {
  1297. message.warning("请输入自定义时间");
  1298. return;
  1299. } else if (!record.customizeName) {
  1300. message.warning("请输入自定义科目");
  1301. return;
  1302. }
  1303. }
  1304. if (
  1305. this.state.approval == 1 &&
  1306. record.dunType == 1 &&
  1307. !record.waitDay
  1308. ) {
  1309. message.warning("请填写收款时间");
  1310. return
  1311. }
  1312. if (record.boStatus == "false") {
  1313. record.boStatus = false;
  1314. } else if (record.boStatus == "true") {
  1315. record.boStatus = true;
  1316. }
  1317. if (!this.state.yearFlag) {
  1318. if (!record.effectiveCount && !record.dunTypeCustom) {
  1319. message.warning("请选择服务年限");
  1320. return;
  1321. }
  1322. } else {
  1323. record.effectiveCount = "";
  1324. }
  1325. if (record.money == "") {
  1326. message.warning("请填写金额");
  1327. return;
  1328. }
  1329. if (record.boStatus) {
  1330. if (
  1331. typeof +record.money == "number" &&
  1332. +record.money >= 0 &&
  1333. +record.money <= 1
  1334. ) {
  1335. record.appropriationRatio = record.money;
  1336. } else {
  1337. message.warning("金额比例填写错误,比例范围0~1");
  1338. return;
  1339. }
  1340. }
  1341. if (!record.dunType && record.dunType != 0) {
  1342. message.warning("请选择对应科目");
  1343. return;
  1344. }
  1345. if (record.dunType != 1) {
  1346. record.waitDay = "";
  1347. }
  1348. this.setState({
  1349. loading: true,
  1350. });
  1351. if (record.boStatus) {
  1352. $.ajax({
  1353. url: globalConfig.context + "/api/admin/newOrderDun/createDun",
  1354. method: "post",
  1355. data: {
  1356. orderNo: record.orderNo,
  1357. tid: record.tid,
  1358. projectType: record.sort,
  1359. dunType: record.dunType,
  1360. appropriationRatio: record.appropriationRatio,
  1361. waitDay: record.waitDay,
  1362. effectiveCount: record.effectiveCount,
  1363. customizeTimes:
  1364. record.dunType == 0 ? record.customizeTimes : undefined,
  1365. customizeName:
  1366. record.dunType == 0 ? record.customizeName : undefined,
  1367. },
  1368. }).done(
  1369. function (data) {
  1370. this.setState({
  1371. loading: false,
  1372. });
  1373. if (!data.error.length) {
  1374. message.success("保存成功!");
  1375. this.setState({
  1376. cuiFlag: false,
  1377. boFlag: false,
  1378. });
  1379. this.jiedianNew(record.orderNo);
  1380. } else {
  1381. message.warning(data.error[0].message);
  1382. }
  1383. }.bind(this)
  1384. );
  1385. } else {
  1386. $.ajax({
  1387. url: globalConfig.context + "/api/admin/newOrderDun/createDun",
  1388. method: "post",
  1389. data: {
  1390. orderNo: record.orderNo,
  1391. tid: record.tid,
  1392. projectType: record.sort,
  1393. dunType: record.dunType,
  1394. money: record.money,
  1395. waitDay: record.waitDay,
  1396. effectiveCount: record.effectiveCount,
  1397. customizeTimes:
  1398. record.dunType == 0 ? record.customizeTimes : undefined,
  1399. customizeName:
  1400. record.dunType == 0 ? record.customizeName : undefined,
  1401. },
  1402. }).done(
  1403. function (data) {
  1404. this.setState({
  1405. loading: false,
  1406. });
  1407. if (!data.error.length) {
  1408. message.success("保存成功!");
  1409. this.setState({
  1410. cuiFlag: false,
  1411. boFlag: false,
  1412. });
  1413. this.jiedianNew(record.orderNo);
  1414. } else {
  1415. message.warning(data.error[0].message);
  1416. }
  1417. }.bind(this)
  1418. );
  1419. }
  1420. },
  1421. //点击新增催款节点
  1422. addcontact() {
  1423. this.state.contactList.push({
  1424. key: this.state.contactList.length,
  1425. money: "",
  1426. dunSubject: undefined,
  1427. orderNo: this.state.orderNo,
  1428. dunTarget: this.state.kehuId,
  1429. });
  1430. this.setState({
  1431. contactList: this.state.contactList,
  1432. });
  1433. },
  1434. //点击新增催款节点
  1435. addcontactNew() {
  1436. this.state.contactListNew.push({
  1437. key: this.state.contactListNew.length,
  1438. money: "",
  1439. dunSubject: undefined,
  1440. orderNo: this.state.orderNo,
  1441. dunTarget: this.state.kehuId,
  1442. });
  1443. this.setState({
  1444. contactListNew: this.state.contactListNew,
  1445. cuiFlag: true,
  1446. });
  1447. },
  1448. //删除收款节点
  1449. confirmDelet(index) {
  1450. this.state.contactList.splice(index, 1);
  1451. this.setState({
  1452. contactList: this.state.contactList,
  1453. });
  1454. this.contactSave();
  1455. },
  1456. //删除收款节点
  1457. confirmDeletNew(index) {
  1458. if (index.id) {
  1459. this.state.contactListNew.splice(index.key, 1);
  1460. this.setState({
  1461. contactListNew: this.state.contactListNew,
  1462. cuiFlag: false,
  1463. addFlag: false,
  1464. boFlag: false,
  1465. });
  1466. $.ajax({
  1467. url: globalConfig.context + "/api/admin/newOrderDun/deleteDun",
  1468. method: "post",
  1469. data: {
  1470. id: index.id,
  1471. },
  1472. }).done(
  1473. function (data) {
  1474. this.setState({
  1475. loading: false,
  1476. });
  1477. if (!data.error.length) {
  1478. message.success("删除成功!");
  1479. this.setState({
  1480. cuiFlag: false,
  1481. });
  1482. this.jiedianNew(this.state.orderNo);
  1483. } else {
  1484. message.warning(data.error[0].message);
  1485. }
  1486. }.bind(this)
  1487. );
  1488. } else {
  1489. this.state.contactListNew.splice(index.key, 1);
  1490. this.setState({
  1491. contactListNew: this.state.contactListNew,
  1492. cuiFlag: false,
  1493. addFlag: false,
  1494. boFlag: false,
  1495. });
  1496. }
  1497. },
  1498. //重新提交
  1499. examOk() {
  1500. let theorgCodeUrl = [];
  1501. if (this.state.orgCodeUrl.length) {
  1502. let picArr = [];
  1503. this.state.orgCodeUrl.map(function (item) {
  1504. if (
  1505. item.response &&
  1506. item.response.data &&
  1507. item.response.data.length
  1508. ) {
  1509. picArr.push(item.response.data);
  1510. }
  1511. });
  1512. theorgCodeUrl = picArr.join(",");
  1513. }
  1514. let theReplenishUrl = [];
  1515. if (this.state.replenishUrl.length) {
  1516. let picArr = [];
  1517. this.state.replenishUrl.map(function (item) {
  1518. if (
  1519. item.response &&
  1520. item.response.data &&
  1521. item.response.data.length
  1522. ) {
  1523. picArr.push(item.response.data);
  1524. }
  1525. });
  1526. theReplenishUrl = picArr.join(",");
  1527. }
  1528. // 服务内容上传图片
  1529. let contentUrl = [];
  1530. if (this.state.contentUrl.length) {
  1531. let picArr = [];
  1532. this.state.contentUrl.map(function (item) {
  1533. if (
  1534. item.response &&
  1535. item.response.data &&
  1536. item.response.data.length
  1537. ) {
  1538. picArr.push(item.response.data);
  1539. }
  1540. });
  1541. contentUrl = picArr.join(",");
  1542. } else {
  1543. message.warning("请上传服务内容图片")
  1544. return
  1545. }
  1546. if (moneyVerify(this.state.totalAmount)) {
  1547. return;
  1548. }
  1549. if (moneyVerify(this.state.firstAmount)) {
  1550. return;
  1551. }
  1552. if (!this.state.totalAmount) {
  1553. message.warning("签单金额不能为空");
  1554. this.refs.signFirstPayment.focus();
  1555. return false;
  1556. }
  1557. if (!this.state.firstAmount) {
  1558. message.warning("首付金额不能为空");
  1559. this.refs.signFirstPayment.focus();
  1560. return false;
  1561. }
  1562. if (!this.state.contacts) {
  1563. message.warning("企业联系人不能为空");
  1564. return
  1565. }
  1566. if (!this.state.contactMobile) {
  1567. message.warning("企业联系人电话不能为空");
  1568. return
  1569. }
  1570. var regeX1 = /^1[3456789]\d{9}$/;
  1571. var regex2 = /^((0\d{2,3})-)?(\d{7,8})$/;
  1572. if (regeX1.test(this.state.contactMobile) == false && regex2.test(this.state.contactMobile) == false) {
  1573. message.warning("请输入正确的企业联系人电话");
  1574. return false;
  1575. }
  1576. if (this.state.isShow) {
  1577. if (this.state.knowledgeServices == null ||
  1578. this.state.auditServices == null ||
  1579. this.state.addDeductionServices == null) {
  1580. message.warn("请完善高新纯咨询合同说明!")
  1581. return
  1582. }
  1583. }
  1584. if (!this.state.isProperty) {
  1585. message.warn("请完善知识产权情况!")
  1586. return
  1587. }
  1588. if (this.state.isProperty == 2 && !this.state.patentStatus) {
  1589. message.warn("请完善知识产权情况!")
  1590. return
  1591. }
  1592. if (!this.state.orderRemarks) {
  1593. message.warning("订单留言不能为空");
  1594. return false;
  1595. }
  1596. if (this.state.approval == 1) {
  1597. if (this.state.approvaType && this.state.approvaType.length == 0) {
  1598. message.warning("请勾选特批状态!");
  1599. return false;
  1600. }
  1601. if (this.state.approvaType.indexOf(0) !== -1 && !this.state.typeExplain) {
  1602. message.warning("请填写特批其他说明!");
  1603. return false;
  1604. }
  1605. }
  1606. // if (!theorgCodeUrl) {
  1607. // message.warning("图片过大,上传失败");
  1608. // this.refs.signFirstPayment.focus();
  1609. // return false;
  1610. // }
  1611. // if (
  1612. // this.state.approval == "特批通过" ||
  1613. // this.state.approval == "特批驳回"
  1614. // ) {
  1615. // message.warning("特批状态不正确,请重新填写");
  1616. // return false;
  1617. // }
  1618. const arr = this.state.contactListNew || [];
  1619. for (let i = 0; i < arr.length; i++) {
  1620. if (
  1621. arr[i].dunType == 1 &&
  1622. arr[i].waitDay != null &&
  1623. this.state.approval == 0
  1624. ) {
  1625. message.warning(
  1626. "非特批存在填写催款节点首付时间的情况,请删除后重新填写保存"
  1627. );
  1628. return false;
  1629. } else if (
  1630. arr[i].dunType == 1 &&
  1631. arr[i].waitDay == null &&
  1632. this.state.approval == 1
  1633. ) {
  1634. message.warning(
  1635. "特批存在首付催款节点未填写时间的情况,请删除后重新填写保存"
  1636. );
  1637. return false;
  1638. }
  1639. if (!this.state.contactListNew[i].id) {
  1640. message.warning("请保存催款节点");
  1641. return false;
  1642. }
  1643. }
  1644. if (this.state.updatas.salesType == null) {
  1645. message.warning("请选择销售类型!");
  1646. return
  1647. }
  1648. this.setState({
  1649. flag: true,
  1650. });
  1651. $.ajax({
  1652. method: "post",
  1653. dataType: "json",
  1654. crossDomain: false,
  1655. // url: globalConfig.context + "/api/admin/newOrder/updateServiceOrderNew",
  1656. url: globalConfig.context + "/api/admin/newOrder/submitOrder",
  1657. data: {
  1658. orderNo: this.state.orderNo, //订单编号
  1659. totalAmount: this.state.totalAmount, //总金额
  1660. firstAmount: this.state.firstAmount, //首付
  1661. isSubmit: 1, //保存草稿还是提交
  1662. signDate: this.state.signDate, //签单日期
  1663. contacts: this.state.contacts, //企业负责人
  1664. contactMobile: this.state.contactMobile, //负责人联系方式
  1665. legalPerson: this.state.legalPerson, //企业法人
  1666. legalPersonTel: this.state.legalPersonTel, //企业法人联系电话
  1667. approval: this.state.approval, //特批状态
  1668. contractNo: this.state.contractNo, //合同编号
  1669. orderRemarks: this.state.orderRemarks, //订单备注
  1670. contractPictureUrl: theorgCodeUrl.length ? theorgCodeUrl : "",
  1671. agreementUrl: theReplenishUrl.length ? theReplenishUrl : "",
  1672. serviceContent: contentUrl.length ? contentUrl : "",
  1673. orderDep: this.state.organizationSearch,
  1674. knowledgeServices: this.state.isShow ? this.state.knowledgeServices : undefined, //知识产权服务
  1675. auditServices: this.state.isShow ? this.state.auditServices : undefined, //审计服务
  1676. addDeductionServices: this.state.isShow ? this.state.addDeductionServices : undefined, //加计扣除服务
  1677. knowledgeOther: this.state.isShow ? this.state.knowledgeOther : undefined, //知识产权服务其他描述
  1678. auditOther: this.state.isShow ? this.state.auditOther : undefined, //审计服务其他描述
  1679. addDeductionOther: this.state.isShow ? this.state.addDeductionOther : undefined, //加计扣除服务其他描述
  1680. patentStatus: this.state.patentStatus, //知识产权情况
  1681. type: this.state.approvaType.sort(compare).toString(), // 特批类型
  1682. typeExplain: this.state.approvaType.indexOf(0) === -1 ? "" : this.state.typeExplain, // 其他备注
  1683. },
  1684. success: function (data) {
  1685. if (data.error.length || data.data.list == "") {
  1686. if (data.error && data.error.length) {
  1687. message.warning(data.error[0].message);
  1688. this.setState({
  1689. flag: false,
  1690. });
  1691. }
  1692. } else {
  1693. message.success("该订单已重新提交~");
  1694. this.setState({
  1695. visible: false,
  1696. flag: false,
  1697. });
  1698. this.loadData(this.state.pageNo);
  1699. }
  1700. }.bind(this),
  1701. }).always(
  1702. function () {
  1703. this.setState({
  1704. loading: false,
  1705. });
  1706. }.bind(this)
  1707. );
  1708. },
  1709. //订单作废
  1710. examOks() {
  1711. this.setState({
  1712. flag: true,
  1713. });
  1714. $.ajax({
  1715. method: "post",
  1716. dataType: "json",
  1717. crossDomain: false,
  1718. url: globalConfig.context + "/api/admin/newOrder/deleteOrderNew",
  1719. data: {
  1720. orderNo: this.state.orderNo, //订单编号
  1721. },
  1722. success: function (data) {
  1723. if (data.error.length || data.data.list == "") {
  1724. if (data.error && data.error.length) {
  1725. message.warning(data.error[0].message);
  1726. }
  1727. } else {
  1728. message.success("该订单已作废~");
  1729. this.setState({
  1730. visible: false,
  1731. flag: false,
  1732. });
  1733. this.loadData(this.state.pageNo);
  1734. }
  1735. }.bind(this),
  1736. }).always(
  1737. function () {
  1738. this.setState({
  1739. loading: false,
  1740. flag: false,
  1741. });
  1742. }.bind(this)
  1743. );
  1744. },
  1745. departmentList() {
  1746. this.setState({
  1747. loading: true,
  1748. });
  1749. $.ajax({
  1750. method: "get",
  1751. dataType: "json",
  1752. crossDomain: false,
  1753. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  1754. data: {},
  1755. success: function (data) {
  1756. let thedata = data.data;
  1757. let theArr = [];
  1758. if (!thedata) {
  1759. if (data.error && data.error.length) {
  1760. message.warning(data.error[0].message);
  1761. }
  1762. thedata = {};
  1763. } else {
  1764. thedata.map(function (item, index) {
  1765. theArr.push({
  1766. key: index,
  1767. name: item.name,
  1768. id: item.id,
  1769. depNo: item.depNo,
  1770. });
  1771. });
  1772. }
  1773. this.setState({
  1774. departmentArr: theArr,
  1775. });
  1776. }.bind(this),
  1777. }).always(
  1778. function () {
  1779. this.setState({
  1780. loading: false,
  1781. });
  1782. }.bind(this)
  1783. );
  1784. },
  1785. rizhi() {
  1786. this.setState({
  1787. loading: true,
  1788. });
  1789. $.ajax({
  1790. method: "get",
  1791. dataType: "json",
  1792. crossDomain: false,
  1793. url: "/api/admin/newOrder/selectOrderLog",
  1794. data: {
  1795. orderNo: this.state.orderNo,
  1796. },
  1797. success: function (data) {
  1798. let theArr = [];
  1799. let thisData = data.data;
  1800. if (!thisData.length) {
  1801. if (data.error && data.error.length) {
  1802. message.warning(data.error[0].message);
  1803. }
  1804. thisData = {};
  1805. } else {
  1806. for (let i = 0; i < data.data.length; i++) {
  1807. let thisdata = data.data[i];
  1808. theArr.push({
  1809. processName: thisdata.processName,
  1810. adminName: thisdata.adminName,
  1811. createDate: thisdata.createDate,
  1812. remarks: thisdata.remarks,
  1813. });
  1814. }
  1815. }
  1816. this.setState({
  1817. dataSourcerizhi: theArr,
  1818. });
  1819. }.bind(this),
  1820. }).always(
  1821. function () {
  1822. this.setState({
  1823. loading: false,
  1824. });
  1825. }.bind(this)
  1826. );
  1827. },
  1828. //查看订单日志
  1829. getOrderLog() {
  1830. this.setState({
  1831. rizhivisible: true,
  1832. });
  1833. this.rizhi();
  1834. },
  1835. closeOrderLog() {
  1836. this.setState({
  1837. rizhivisible: false,
  1838. });
  1839. },
  1840. //点击签单
  1841. handleCancels() {
  1842. this.setState({
  1843. isSubmit: 1,
  1844. });
  1845. },
  1846. //点击签单
  1847. handleCancelq() {
  1848. this.setState({
  1849. isSubmit: 0,
  1850. });
  1851. },
  1852. resets() {
  1853. this.state.orderNoSearch = "";
  1854. this.state.customerName = "";
  1855. this.state.releaseDate[0] = undefined;
  1856. this.state.releaseDate[1] = undefined;
  1857. this.loadData();
  1858. },
  1859. //点击添加项目明细
  1860. addDetailed() {
  1861. const { dataSourceX = [] } = this.state
  1862. this.setState({
  1863. projectOperationVisible: true,
  1864. newData: dataSourceX,
  1865. });
  1866. },
  1867. //搜索
  1868. search() {
  1869. this.setState({
  1870. //signBillVisible:false
  1871. });
  1872. this.loadData();
  1873. },
  1874. getOrgCodeUrl(e) {
  1875. this.setState({ orgCodeUrl: e });
  1876. },
  1877. getReplenishUrl(e) {
  1878. this.setState({ replenishUrl: e });
  1879. },
  1880. getContentUrl(e) {
  1881. this.setState({ contentUrl: e });
  1882. },
  1883. //关闭详情
  1884. visitCancel() {
  1885. this.setState({
  1886. visible: false,
  1887. cuiFlag: false,
  1888. addFlag: false,
  1889. boFlag: false,
  1890. });
  1891. this.loadData(this.state.pageNo);
  1892. },
  1893. visitOk() {
  1894. this.setState({
  1895. visible: false,
  1896. });
  1897. this.resets();
  1898. },
  1899. //客户
  1900. selectAutoCUT(value) {
  1901. let autoIds;
  1902. let fwList = this.state.customerArr;
  1903. fwList.map(function (item) {
  1904. if (value == item.name) {
  1905. autoIds = item.id;
  1906. }
  1907. });
  1908. this.setState({
  1909. customerName: value,
  1910. autoId: autoIds,
  1911. });
  1912. },
  1913. getpatentTypeList() {
  1914. $.ajax({
  1915. method: "get",
  1916. dataType: "json",
  1917. crossDomain: false,
  1918. url: globalConfig.context + '/api/admin/orderProject/getPatentType',
  1919. success: function (data) {
  1920. if (data.error.length === 0) {
  1921. this.setState({
  1922. patentTypeList: data.data
  1923. })
  1924. } else {
  1925. message.warning(data.error[0].message);
  1926. };
  1927. }.bind(this)
  1928. });
  1929. },
  1930. //加载(自动补全)
  1931. supervisor(e, state) {
  1932. //客户名称与服务名称自动补全
  1933. let api = state
  1934. ? "/api/admin/customer/getCustomerByName"
  1935. : "/api/admin/order/getBusinessProjectByName";
  1936. $.ajax({
  1937. method: "get",
  1938. dataType: "json",
  1939. crossDomain: false,
  1940. url: globalConfig.context + api,
  1941. data: state
  1942. ? {
  1943. name: e,
  1944. type: this.state.customType,
  1945. }
  1946. : {
  1947. businessName: e,
  1948. },
  1949. success: function (data) {
  1950. let thedata = data.data;
  1951. if (!thedata) {
  1952. if (data.error && data.error.length) {
  1953. message.warning(data.error[0].message);
  1954. }
  1955. thedata = {};
  1956. }
  1957. this.setState({
  1958. states: state,
  1959. customerArr: thedata,
  1960. });
  1961. }.bind(this),
  1962. }).always(
  1963. function () {
  1964. this.setState({
  1965. loading: false,
  1966. });
  1967. }.bind(this)
  1968. );
  1969. },
  1970. //上级主管输入框失去焦点是判断客户是否存在
  1971. selectAuto(value) {
  1972. let kid = [];
  1973. let fwList = this.state.customerArr;
  1974. fwList.map(function (item) {
  1975. if (value == item.bname) {
  1976. kid = item;
  1977. }
  1978. });
  1979. if (kid.type == "1") {
  1980. this.setState({
  1981. displayFees: "block",
  1982. });
  1983. } else {
  1984. this.setState({
  1985. displayFees: "none",
  1986. });
  1987. }
  1988. this.setState({
  1989. commodityName: value,
  1990. gid: kid.id,
  1991. //commodityPrice:kid.price==0?kid.price.toString():kid.price,
  1992. commodityFirstPayment:
  1993. kid.firstPayment == 0
  1994. ? kid.firstPayment.toString()
  1995. : kid.firstPayment,
  1996. });
  1997. },
  1998. //服务值改变时请求客户名称
  1999. httpChange(e) {
  2000. this.state.gid = "";
  2001. if (e.length >= 1) {
  2002. this.supervisor(e, false);
  2003. }
  2004. this.setState({
  2005. commodityName: e,
  2006. });
  2007. },
  2008. changeList(arr) {
  2009. const newArr = [];
  2010. this.state.columns.forEach(item => {
  2011. arr.forEach(val => {
  2012. if (val === item.title) {
  2013. newArr.push(item);
  2014. }
  2015. });
  2016. });
  2017. this.setState({
  2018. changeList: newArr
  2019. });
  2020. },
  2021. addRowColor(record) {
  2022. if (!!record.splitList && record.splitList.length > 0) {
  2023. return 'light'
  2024. } else {
  2025. return 'dark'
  2026. }
  2027. },
  2028. render() {
  2029. const expandedRowRenderVip = (e) => {
  2030. const data = e.splitList;
  2031. let columns = [];
  2032. if (data instanceof Array && data.length) {
  2033. if (e.cSort == 6) {
  2034. columns = [
  2035. {
  2036. title: "负责人",
  2037. dataIndex: "receiverName",
  2038. key: "receiverName",
  2039. },
  2040. {
  2041. title: "负责人电话",
  2042. dataIndex: "receiverMobile",
  2043. key: "receiverMobile",
  2044. },
  2045. {
  2046. title: "会员负责人",
  2047. dataIndex: "projectMemberName",
  2048. key: "projectMemberName",
  2049. },
  2050. {
  2051. title: "项目状态",
  2052. dataIndex: "projectStatus",
  2053. key: "projectStatus",
  2054. render: (text) => {
  2055. return getProjectName(text);
  2056. },
  2057. },
  2058. {
  2059. title: "本次派单",
  2060. dataIndex: "serviceYear",
  2061. key: "serviceYear",
  2062. },
  2063. {
  2064. title: "项目说明",
  2065. dataIndex: "taskComment",
  2066. key: "taskComment",
  2067. render: (text, record) => {
  2068. let textStr = text;
  2069. let textArr = [];
  2070. if (record.htMember === 1) {
  2071. textArr.push("高新会员");
  2072. }
  2073. if (record.additionalDeduction === 1) {
  2074. textArr.push("加计扣除");
  2075. }
  2076. if (record.rdAwardsubsidy === 1) {
  2077. textArr.push("研发补助");
  2078. }
  2079. if (textArr.length) {
  2080. textStr = `${textArr.join("&")} ${!!text ? `(${text})` : ''}`
  2081. }
  2082. return (
  2083. <Tooltip title={textStr}>
  2084. <div
  2085. // style={{
  2086. // width: 100,
  2087. // overflow: "hidden",
  2088. // whiteSpace: "nowrap",
  2089. // textOverflow: "ellipsis",
  2090. // }}
  2091. >{textStr}</div>
  2092. </Tooltip>
  2093. )
  2094. },
  2095. },
  2096. ];
  2097. } else {
  2098. columns = [
  2099. {
  2100. title: "子项目名称",
  2101. dataIndex: "taskName",
  2102. key: "taskName"
  2103. },
  2104. {
  2105. title: "子项目数量",
  2106. dataIndex: "commodityQuantity",
  2107. key: "commodityQuantity"
  2108. },
  2109. {
  2110. title: "拆分操作人",
  2111. dataIndex: "splitAname",
  2112. key: "splitAname"
  2113. },
  2114. {
  2115. title: "项目负责人",
  2116. dataIndex: "receiverName",
  2117. key: "receiverName"
  2118. },
  2119. {
  2120. title: "拆分时间",
  2121. dataIndex: "splitTimes",
  2122. key: "splitTimes"
  2123. }
  2124. ]
  2125. }
  2126. return (
  2127. <Table
  2128. columns={columns}
  2129. dataSource={data}
  2130. pagination={false}
  2131. />
  2132. );
  2133. } else {
  2134. columns = [];
  2135. return (
  2136. <p
  2137. style={{ fontWeight: "bold", color: "red", textAlign: "center" }}
  2138. >
  2139. {e.cSort == 6 ? "暂无派单" : "此项目暂未拆分"}
  2140. </p>
  2141. );
  2142. }
  2143. };
  2144. const formItemLayout = {
  2145. labelCol: { span: 10 },
  2146. wrapperCol: { span: 14 },
  2147. };
  2148. const FormItem = Form.Item;
  2149. const { RangePicker } = DatePicker;
  2150. const rowSelection = {
  2151. selectedRowKeys: this.state.selectedRowKeys,
  2152. onChange: (selectedRowKeys, selectedRows) => {
  2153. this.setState({
  2154. modalVisible: false,
  2155. selectedRows: selectedRows.slice(-1),
  2156. selectedRowKeys: selectedRowKeys.slice(-1),
  2157. });
  2158. },
  2159. onSelect: (recordt) => {
  2160. this.setState({
  2161. modalVisible: false,
  2162. recordt: recordt.id,
  2163. });
  2164. },
  2165. };
  2166. const cuiDataList = this.state.contactList || [];
  2167. const dataSources = this.state.customerArr || [];
  2168. let departmentArr = this.state.departmentArr || [];
  2169. const options = this.state.states
  2170. ? dataSources.map((group) => (
  2171. <Select.Option key={group.id} value={group.name}>
  2172. {group.name}
  2173. </Select.Option>
  2174. ))
  2175. : dataSources.map((group, index) => (
  2176. <Select.Option key={index} value={group.bname}>
  2177. {group.bname}
  2178. </Select.Option>
  2179. ));
  2180. const { TabPane } = Tabs;
  2181. let approvalOptions = [
  2182. { label: '无前期款', value: 1 },
  2183. { label: '暂无合同款', value: 2 },
  2184. { label: '含高风险条款', value: 3 },
  2185. { label: '新产品首单', value: 4 },
  2186. { label: '通过率低于80%', value: 5 },
  2187. { label: '3万以下会员', value: 6 },
  2188. { label: '认证首期5K以下', value: 7 },
  2189. {
  2190. label: <span>
  2191. <span>其他&nbsp;&nbsp;</span>
  2192. <Input
  2193. type="text"
  2194. style={{ width: 150, borderStyle: "none none solid none" }}
  2195. value={this.state.typeExplain}
  2196. // disabled={this.state.approvaType.indexOf(0) === -1 ? true : false}
  2197. placeholder=""
  2198. onChange={e => {
  2199. this.setState({
  2200. typeExplain: e.target.value
  2201. })
  2202. }}
  2203. />
  2204. </span>, value: 0
  2205. },
  2206. ];
  2207. return (
  2208. <div className="user-content">
  2209. {this.state.resVisible ? (
  2210. <ResolutionDetail
  2211. cancel={this.resCancel}
  2212. detail={this.state.resRecord}
  2213. visible={this.state.resVisible}
  2214. id={this.state.resRecord.orderNo}
  2215. />
  2216. ) : (
  2217. ""
  2218. )}
  2219. <ShowModalDiv ShowModal={this.state.showModal} onClose={() => { this.setState({ showModal: false }) }} />
  2220. <div className="content-title" style={{ marginBottom: 10 }}>
  2221. <span style={{ fontWeight: 900, fontSize: 16 }}>驳回订单列表</span>
  2222. </div>
  2223. <div className="user-search">
  2224. <Tabs
  2225. defaultActiveKey="1"
  2226. onChange={this.callback}
  2227. className="test"
  2228. >
  2229. <TabPane tab="搜索" key="1">
  2230. <div style={{ marginLeft: 10 }}>
  2231. <Input
  2232. placeholder="订单编号"
  2233. style={{ width: "150px", marginRight: 10 }}
  2234. value={this.state.orderNoSearch}
  2235. onChange={(e) => {
  2236. this.setState({ orderNoSearch: e.target.value });
  2237. }}
  2238. />
  2239. <Input
  2240. placeholder="客户名称"
  2241. style={{
  2242. width: "150px",
  2243. marginBottom: "10px",
  2244. marginTop: 10,
  2245. marginLeft: 10,
  2246. marginRight: 10,
  2247. }}
  2248. value={this.state.customerName}
  2249. onChange={(e) => {
  2250. this.setState({ customerName: e.target.value });
  2251. }}
  2252. />
  2253. <span style={{ marginRight: "10px" }}>下单时间 :</span>
  2254. <RangePicker
  2255. value={[
  2256. this.state.releaseDate[0]
  2257. ? moment(this.state.releaseDate[0])
  2258. : null,
  2259. this.state.releaseDate[1]
  2260. ? moment(this.state.releaseDate[1])
  2261. : null,
  2262. ]}
  2263. onChange={(data, dataString) => {
  2264. this.setState({ releaseDate: dataString });
  2265. }}
  2266. />
  2267. <Button
  2268. type="primary"
  2269. onClick={this.search}
  2270. style={{ marginLeft: "10px", marginRight: 10 }}
  2271. >
  2272. 搜索
  2273. </Button>
  2274. <Button onClick={this.resets}>重置</Button>
  2275. </div>
  2276. </TabPane>
  2277. <TabPane tab="更改表格显示数据" key="2">
  2278. <div style={{ marginLeft: 10 }}>
  2279. <ChooseList
  2280. columns={this.state.columns}
  2281. changeFn={this.changeList}
  2282. changeList={this.state.changeList}
  2283. top={55}
  2284. margin={11}
  2285. />
  2286. </div>
  2287. </TabPane>
  2288. </Tabs>
  2289. <div className="patent-table">
  2290. <Spin spinning={this.state.loading}>
  2291. <Table
  2292. columns={
  2293. this.state.changeList
  2294. ? this.state.changeList
  2295. : this.state.columns
  2296. }
  2297. dataSource={this.state.dataSource}
  2298. rowSelection={rowSelection}
  2299. pagination={this.state.pagination}
  2300. onRowClick={this.tableRowClick}
  2301. bordered
  2302. size="small"
  2303. />
  2304. </Spin>
  2305. </div>
  2306. {this.state.visible ? <Modal
  2307. maskClosable={false}
  2308. className="customeDetails"
  2309. footer=""
  2310. title="订单详情"
  2311. width="1200px"
  2312. visible={this.state.visible}
  2313. onOk={this.visitOk}
  2314. onCancel={this.visitCancel}
  2315. >
  2316. <Form
  2317. layout="horizontal"
  2318. onSubmit={this.handleSubmit}
  2319. id="demand-form"
  2320. style={{ paddingBottom: "40px" }}
  2321. >
  2322. <Spin spinning={this.state.loading}>
  2323. <div className="clearfix">
  2324. <div style={{ position: "absolute", top: '-52px', left: '81px', zIndex: 10000 }}>
  2325. <OrderItemStatus deleteSign={this.state.deleteSign} />
  2326. </div>
  2327. <FormItem
  2328. className="half-item"
  2329. {...formItemLayout}
  2330. label="订单编号"
  2331. >
  2332. <span>{this.state.orderNo}</span>
  2333. </FormItem>
  2334. <FormItem
  2335. className="half-item"
  2336. {...formItemLayout}
  2337. label="合同编号"
  2338. >
  2339. <span>{this.state.contractNo}</span>
  2340. </FormItem>
  2341. <FormItem
  2342. className="half-item"
  2343. {...formItemLayout}
  2344. label="客户名称"
  2345. >
  2346. <span>{this.state.userName}</span>
  2347. <EnterpriseNameChange
  2348. type='journal'
  2349. style={{ marginLeft: 10 }}
  2350. enterpriseId={this.state.orderUid} />
  2351. </FormItem>
  2352. <FormItem
  2353. className="half-item"
  2354. {...formItemLayout}
  2355. label="销售类型"
  2356. >
  2357. <span>
  2358. {(["私有客户-", "签单客户-"][this.state.updatas.userType] || " ") +
  2359. (salesList[this.state.updatas.salesType] || "")}
  2360. {/* {
  2361. this.state.updatas.other != null && this.state.updatas.other != "" &&
  2362. <Tooltip title={this.state.updatas.other}>
  2363. <span>
  2364. {"(" + this.state.updatas.other.toString().slice(0, 10) + (this.state.updatas.other.toString().length > 9 ? "...)" : ")")}
  2365. </span>
  2366. </Tooltip>
  2367. } */}
  2368. </span>
  2369. <UpdateSales
  2370. orderNo={this.state.orderNo}
  2371. updatas={this.state.updatas}
  2372. onRefresh={
  2373. e => {
  2374. let ups = this.state.updatas
  2375. ups.salesType = e.salesType
  2376. if (e.salesType == "3") {
  2377. ups.channelId = e.channelId
  2378. ups.other = e.other
  2379. } else if (e.salesType == "4" || e.salesType == "5") {
  2380. ups.other = e.other
  2381. }
  2382. this.setState({
  2383. updatas: ups
  2384. })
  2385. }
  2386. //this.xiangqing.bind(this, this.state.orderNo)
  2387. }
  2388. />
  2389. </FormItem>
  2390. <FormItem
  2391. className="half-item"
  2392. {...formItemLayout}
  2393. label="流程状态"
  2394. >
  2395. <span>{getProcessStatus(this.state.processStatus, this.state.examineName, this.state.approval)}</span>
  2396. <FlowChart
  2397. orderNo={this.state.orderNo}
  2398. />
  2399. </FormItem>
  2400. <FormItem
  2401. className="half-item"
  2402. {...formItemLayout}
  2403. label="结算状态"
  2404. >
  2405. <span>
  2406. {getLiquidationStatus(this.state.liquidationStatus)}
  2407. </span>
  2408. </FormItem>
  2409. <FormItem
  2410. className="half-item"
  2411. {...formItemLayout}
  2412. label="已收款项(万元)"
  2413. >
  2414. <span>{this.state.settlementAmount}</span>
  2415. </FormItem>
  2416. <FormItem
  2417. className="half-item"
  2418. {...formItemLayout}
  2419. label={
  2420. <span>
  2421. <strong style={{ color: "#f00" }}>*</strong>
  2422. 企业联系人
  2423. </span>
  2424. }
  2425. >
  2426. <Input
  2427. placeholder="请输入联系人"
  2428. ref="signTotalAmount"
  2429. value={this.state.contacts}
  2430. onChange={(e) => {
  2431. this.setState({ contacts: e.target.value });
  2432. }}
  2433. style={{ width: "240px" }}
  2434. />
  2435. </FormItem>
  2436. <FormItem
  2437. className="half-item"
  2438. {...formItemLayout}
  2439. label={
  2440. <span>
  2441. <strong style={{ color: "#f00" }}>*</strong>
  2442. 联系人电话
  2443. </span>
  2444. }
  2445. >
  2446. <Input
  2447. placeholder="请输入联系人电话"
  2448. ref="signTotalAmount"
  2449. value={this.state.contactMobile}
  2450. onChange={(e) => {
  2451. this.setState({ contactMobile: e.target.value });
  2452. }}
  2453. style={{ width: "240px" }}
  2454. />
  2455. </FormItem>
  2456. <FormItem
  2457. className="half-item"
  2458. {...formItemLayout}
  2459. label="企业法人"
  2460. >
  2461. <Input
  2462. placeholder="请输入法人"
  2463. ref="signTotalAmount"
  2464. value={this.state.legalPerson}
  2465. onChange={(e) => {
  2466. this.setState({ legalPerson: e.target.value });
  2467. }}
  2468. style={{ width: "240px" }}
  2469. />
  2470. </FormItem>
  2471. <FormItem
  2472. className="half-item"
  2473. {...formItemLayout}
  2474. label="法人电话"
  2475. >
  2476. <Input
  2477. placeholder="请输入法人电话"
  2478. ref="signTotalAmount"
  2479. value={this.state.legalPersonTel}
  2480. onChange={(e) => {
  2481. this.setState({ legalPersonTel: e.target.value });
  2482. }}
  2483. style={{ width: "240px" }}
  2484. />
  2485. </FormItem>
  2486. <FormItem
  2487. className="half-item"
  2488. {...formItemLayout}
  2489. label={
  2490. <span>
  2491. <strong style={{ color: "#f00" }}>*</strong>
  2492. 签单金额(万元)
  2493. </span>
  2494. }
  2495. >
  2496. <Input
  2497. placeholder="签单金额"
  2498. ref="signTotalAmount"
  2499. value={this.state.totalAmount}
  2500. onChange={(e) => {
  2501. this.setState({ totalAmount: e.target.value });
  2502. }}
  2503. style={{ width: "240px" }}
  2504. />
  2505. </FormItem>
  2506. <FormItem
  2507. className="half-item"
  2508. {...formItemLayout}
  2509. label={
  2510. <span>
  2511. <strong style={{ color: "#f00" }}>*</strong>
  2512. 首付金额(万元)
  2513. </span>
  2514. }
  2515. >
  2516. <Input
  2517. placeholder="请输入实签首款金额"
  2518. ref="signFirstPayment"
  2519. value={this.state.firstAmount}
  2520. onChange={(e) => {
  2521. this.setState({ firstAmount: e.target.value });
  2522. }}
  2523. style={{ width: "240px" }}
  2524. />
  2525. </FormItem>
  2526. <div className="clearfix">
  2527. <FormItem
  2528. className="half-item"
  2529. {...formItemLayout}
  2530. label="特批立项"
  2531. >
  2532. <Select
  2533. placeholder="请选择客户所属类型"
  2534. style={{ width: "240px" }}
  2535. value={this.state.approval}
  2536. onChange={(e) => {
  2537. this.setState({ approval: e });
  2538. }}
  2539. >
  2540. {
  2541. [{ id: 0, name: "非特批" },
  2542. { id: 1, name: "特批" }].map(function (item) {
  2543. return (
  2544. <Select.Option key={item.id} value={item.id}>
  2545. {item.name}
  2546. </Select.Option>
  2547. );
  2548. })
  2549. }
  2550. </Select>
  2551. {
  2552. this.state.approval == 1 &&
  2553. <div>
  2554. <CheckboxGroup
  2555. options={approvalOptions}
  2556. value={this.state.approvaType}
  2557. onChange={e => {
  2558. this.setState({
  2559. approvaType: e
  2560. })
  2561. }}
  2562. />
  2563. </div>
  2564. }
  2565. </FormItem>
  2566. </div>
  2567. <FormItem
  2568. className="half-item"
  2569. {...formItemLayout}
  2570. label="合同签订时间"
  2571. >
  2572. <DatePicker
  2573. style={{
  2574. marginTop: "2px",
  2575. width: "240px",
  2576. height: "27px",
  2577. }}
  2578. showTime
  2579. format="YYYY-MM-DD"
  2580. onOk={() => { }}
  2581. value={
  2582. this.state.signDate
  2583. ? moment(this.state.signDate)
  2584. : null
  2585. }
  2586. onChange={(data, dataString) => {
  2587. this.setState({ signDate: dataString });
  2588. }}
  2589. />
  2590. </FormItem>
  2591. <FormItem
  2592. className="half-item"
  2593. {...formItemLayout}
  2594. label="订单部门"
  2595. >
  2596. <Select
  2597. placeholder="请输入订单部门"
  2598. style={{ width: 240 }}
  2599. value={this.state.organizationSearch}
  2600. onChange={(e) => {
  2601. this.setState({ organizationSearch: e });
  2602. }}
  2603. >
  2604. {departmentArr.map(function (item) {
  2605. return (
  2606. <Select.Option key={item.id}>
  2607. {item.name}
  2608. </Select.Option>
  2609. );
  2610. })}
  2611. </Select>
  2612. </FormItem>
  2613. <FormItem
  2614. className="half-item"
  2615. {...formItemLayout}
  2616. label="是否外包"
  2617. >
  2618. {this.state.outsource}
  2619. </FormItem>
  2620. <div className="clearfix">
  2621. <FormItem
  2622. labelCol={{ span: 5 }}
  2623. wrapperCol={{ span: 19 }}
  2624. label={
  2625. <span>
  2626. <strong style={{ color: "#f00" }}>*</strong>
  2627. 合同扫描件
  2628. </span>
  2629. }
  2630. >
  2631. <PicturesWall
  2632. domId={'reject1'}
  2633. fileList={this.getOrgCodeUrl}
  2634. pictureUrl={this.state.orgCodeUrl}
  2635. url="/api/admin/order/uploadOrderImg"
  2636. orderNo={this.state.orderNo}
  2637. sign="contract"
  2638. deleteApi="/api/admin/order/deleteOrderImg"
  2639. />
  2640. <p>图片建议:要清晰。</p>
  2641. </FormItem>
  2642. <FormItem
  2643. labelCol={{ span: 5 }}
  2644. wrapperCol={{ span: 19 }}
  2645. label={
  2646. <span>
  2647. 补充协议
  2648. </span>
  2649. }
  2650. >
  2651. <PicturesWall
  2652. domId={'reject2'}
  2653. fileList={this.getReplenishUrl}
  2654. pictureUrl={this.state.replenishUrl}
  2655. url="/api/admin/order/uploadOrderImg"
  2656. orderNo={this.state.orderNo}
  2657. sign="supplement"
  2658. deleteApi="/api/admin/order/deleteOrderImg"
  2659. />
  2660. <p>图片建议:要清晰。</p>
  2661. <Button
  2662. style={{
  2663. float: "right",
  2664. marginRight: "140px",
  2665. marginTop: "20px",
  2666. }}
  2667. onClick={this.getOrderLog}
  2668. >
  2669. 查看订单日志
  2670. </Button>
  2671. </FormItem>
  2672. </div>
  2673. <Gxczx
  2674. isShow={this.state.isShow}
  2675. isCreat={true}
  2676. knowledgeServices={this.state.knowledgeServices}
  2677. auditServices={this.state.auditServices}
  2678. addDeductionServices={this.state.addDeductionServices}
  2679. knowledgeOther={this.state.knowledgeOther}
  2680. auditOther={this.state.auditOther}
  2681. addDeductionOther={this.state.addDeductionOther}
  2682. selknowledge={e => { this.setState({ knowledgeServices: e.knowledgeServices, knowledgeOther: e.knowledgeOther }) }}
  2683. selaudit={e => { this.setState({ auditServices: e.auditServices, auditOther: e.auditOther }) }}
  2684. seladdDeduction={e => { this.setState({ addDeductionServices: e.addDeductionServices, addDeductionOther: e.addDeductionOther }) }}
  2685. onSwitch={e => { this.setState({ isShow: e }) }}
  2686. />
  2687. {/* 服务内容 */}
  2688. {/* <ContentUrl
  2689. processStatus={this.state.processStatus}
  2690. domId={"rejectContent"}
  2691. contentUrl={this.state.contentUrl}
  2692. getContentUrl={this.getContentUrl}
  2693. imgId={"rejectImg1"}
  2694. /> */}
  2695. <div className="clearfix">
  2696. <FormItem
  2697. labelCol={{ span: 5 }}
  2698. wrapperCol={{ span: 19 }}
  2699. label={
  2700. <span>
  2701. <strong style={{ color: "#f00" }}>*</strong>
  2702. 服务内容
  2703. </span>
  2704. }
  2705. >
  2706. <PicturesWall
  2707. domId={'rejectContent'}
  2708. fileList={this.getContentUrl}
  2709. pictureUrl={this.state.contentUrl}
  2710. url="/api/admin/order/uploadOrderImg"
  2711. orderNo={this.state.orderNo}
  2712. sign="content"
  2713. deleteApi="/api/admin/order/deleteOrderImg"
  2714. />
  2715. <p> <span style={{ color: "red", display: "inline-block" }}>(注:必需上传服务内容、服务年限、时间节点、乙方权利与责任、违约条款、保密条款!)</span>图片建议:要清晰。</p>
  2716. </FormItem>
  2717. <Property
  2718. isCreat={true}
  2719. isProperty={this.state.isProperty}
  2720. setProperty={e => { this.setState({ isProperty: e, patentStatus: e == 1 && 0 }) }}
  2721. patentStatus={this.state.patentStatus}
  2722. setPatentS={e => { this.setState({ patentStatus: e }) }}
  2723. />
  2724. <FormItem
  2725. labelCol={{ span: 5 }}
  2726. wrapperCol={{ span: 16 }}
  2727. label={
  2728. <span>
  2729. <strong style={{ color: "#f00" }}>*</strong>
  2730. 订单留言
  2731. </span>
  2732. }
  2733. >
  2734. <Input
  2735. type="textarea"
  2736. placeholder="请输入订单留言"
  2737. rows={4}
  2738. value={this.state.orderRemarks}
  2739. onChange={(e) => {
  2740. this.setState({ orderRemarks: e.target.value });
  2741. }}
  2742. />
  2743. </FormItem>
  2744. </div>
  2745. <div className="clearfix">
  2746. <FormItem
  2747. className="half-item"
  2748. {...formItemLayout}
  2749. label="订单负责人"
  2750. >
  2751. <span>{this.state.salesmanName}</span>
  2752. </FormItem>
  2753. <FormItem
  2754. className="half-item"
  2755. {...formItemLayout}
  2756. label="订单负责人电话"
  2757. >
  2758. <span>{this.state.salesmanMobile}</span>
  2759. </FormItem>
  2760. </div>
  2761. <div className="clearfix">
  2762. <FormItem
  2763. className="half-item"
  2764. {...formItemLayout}
  2765. label="当前财务负责人"
  2766. >
  2767. <span>{this.state.nowFinance}</span>
  2768. </FormItem>
  2769. <FormItem
  2770. className="half-item"
  2771. {...formItemLayout}
  2772. label="当前财务负责人电话"
  2773. >
  2774. <span>{this.state.nowFinanceMobile}</span>
  2775. </FormItem>
  2776. </div>
  2777. <div className="clearfix">
  2778. <FormItem
  2779. className="half-item"
  2780. {...formItemLayout}
  2781. style={{ opacity: ".5" }}
  2782. label="原订单负责人"
  2783. >
  2784. <span>{this.state.oldSalesmanName}</span>
  2785. </FormItem>
  2786. <FormItem
  2787. className="half-item"
  2788. {...formItemLayout}
  2789. style={{ opacity: ".5" }}
  2790. label="原订单负责人电话"
  2791. >
  2792. <span>{this.state.oldSalesmanMobile}</span>
  2793. </FormItem>
  2794. </div>
  2795. <div className="clearfix">
  2796. <FormItem
  2797. className="half-item"
  2798. style={{ opacity: ".5" }}
  2799. {...formItemLayout}
  2800. label="实际财务操作人"
  2801. >
  2802. <span>{this.state.financeName}</span>
  2803. </FormItem>
  2804. <FormItem
  2805. className="half-item"
  2806. {...formItemLayout}
  2807. style={{ opacity: ".5" }}
  2808. label="实际财务操作人电话"
  2809. >
  2810. <span>{this.state.financeMobile}</span>
  2811. </FormItem>
  2812. </div>
  2813. <div className="clearfix">
  2814. <FormItem
  2815. className="half-item"
  2816. {...formItemLayout}
  2817. label="驳回人"
  2818. >
  2819. <span>{this.state.initiateName}</span>
  2820. </FormItem>
  2821. <FormItem
  2822. className="half-item"
  2823. {...formItemLayout}
  2824. label="驳回时间"
  2825. >
  2826. <span>{this.state.backDate}</span>
  2827. </FormItem>
  2828. </div>
  2829. <div className="clearfix">
  2830. <FormItem
  2831. labelCol={{ span: 5 }}
  2832. wrapperCol={{ span: 16 }}
  2833. label="驳回原因"
  2834. >
  2835. <span>{this.state.reason}</span>
  2836. </FormItem>
  2837. </div>
  2838. {/* 协单人员 */}
  2839. <OrderCoor orderNo={this.state.orderNos} processStatus={this.state.processStatus} orderStatus={this.state.orderStatus} />
  2840. <div>
  2841. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  2842. 项目业务
  2843. </span>
  2844. <Button
  2845. type="primary"
  2846. onClick={this.addDetailed}
  2847. style={{
  2848. float: "right",
  2849. marginRight: "50px",
  2850. marginBottom: "15px",
  2851. }}
  2852. >
  2853. 添加项目明细
  2854. </Button>
  2855. </div>
  2856. <div className="patent-table">
  2857. <Spin spinning={this.state.loading}>
  2858. <Table
  2859. columns={this.state.columnsX}
  2860. dataSource={this.state.dataSourceX}
  2861. pagination={this.state.paginations}
  2862. // onRowClick={this.tableRowClickX}
  2863. expandedRowRender={expandedRowRenderVip}
  2864. rowClassName={this.addRowColor}
  2865. bordered
  2866. size="small"
  2867. />
  2868. </Spin>
  2869. </div>
  2870. <div
  2871. style={{ display: cuiDataList.length ? "block" : "none" }}
  2872. >
  2873. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  2874. 旧催款节点
  2875. </span>
  2876. <Button
  2877. type="primary"
  2878. // onClick={this.addcontact}
  2879. disabled
  2880. onClick={(e) => {
  2881. cuiDataList.length
  2882. ? this.addcontact()
  2883. : this.addcontactNew();
  2884. }}
  2885. style={{
  2886. float: "right",
  2887. marginRight: "50px",
  2888. marginBottom: "15px",
  2889. }}
  2890. >
  2891. 添加催款节点
  2892. </Button>
  2893. </div>
  2894. <div
  2895. className="clearfix"
  2896. style={{ display: cuiDataList.length ? "block" : "none" }}
  2897. >
  2898. <Spin spinning={this.state.loading}>
  2899. <Form layout="horizontal" id="demand-form">
  2900. <Table
  2901. pagination={false}
  2902. columns={this.state.ContactsLists}
  2903. dataSource={this.state.contactList}
  2904. bordered
  2905. size="small"
  2906. scroll={{ x: "max-content", y: 0 }}
  2907. />
  2908. <Col
  2909. span={24}
  2910. offset={9}
  2911. style={{ marginTop: "15px" }}
  2912. ></Col>
  2913. </Form>
  2914. </Spin>
  2915. </div>
  2916. <div>
  2917. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  2918. 新催款节点
  2919. </span>
  2920. <span
  2921. style={{
  2922. display: cuiDataList.length ? "none" : "inline-block",
  2923. marginLeft: 10,
  2924. color: "red",
  2925. }}
  2926. >
  2927. 金额总计(万元): {this.state.totalCui}
  2928. </span>
  2929. <Button
  2930. type="primary"
  2931. disabled={
  2932. cuiDataList.length || this.state.addFlag
  2933. ? true
  2934. : false
  2935. }
  2936. // onClick={this.addcontact}
  2937. onClick={(e) => {
  2938. this.setState({ addFlag: true });
  2939. this.addcontactNew();
  2940. }}
  2941. style={{
  2942. float: "right",
  2943. marginRight: "50px",
  2944. marginBottom: "15px",
  2945. }}
  2946. >
  2947. 添加催款节点
  2948. </Button>
  2949. </div>
  2950. <div className="clearfix">
  2951. <Spin spinning={this.state.loading}>
  2952. <Form layout="horizontal" id="demand-form">
  2953. <Table
  2954. pagination={false}
  2955. columns={this.state.ContactsListsNew}
  2956. dataSource={this.state.contactListNew}
  2957. scroll={{ x: "max-content", y: 0 }}
  2958. bordered
  2959. size="small"
  2960. />
  2961. <Col
  2962. span={24}
  2963. offset={9}
  2964. style={{ marginTop: "15px" }}
  2965. />
  2966. </Form>
  2967. </Spin>
  2968. </div>
  2969. <div className="addSave" style={{ display: "flex", justifyContent: "center" }}>
  2970. {
  2971. // 新需求 除湖南和内蒙古外 不让其他省操作
  2972. (adminData.province == "21" || adminData.province == "11") &&
  2973. <Button
  2974. className="cancel"
  2975. type="primary"
  2976. onClick={this.examOk}
  2977. style={{ margin: 25 }}
  2978. htmlType="submit"
  2979. loading={this.state.flag}
  2980. >
  2981. 重新提交
  2982. </Button>
  2983. }
  2984. <Popconfirm
  2985. title="请确认您是否作废此订单??"
  2986. onConfirm={(e) => {
  2987. this.examOks()
  2988. }}
  2989. okText="确认"
  2990. cancelText="取消"
  2991. >
  2992. <Button
  2993. className="cancel"
  2994. type="danger"
  2995. style={{ margin: 25 }}
  2996. loading={this.state.flag}
  2997. >
  2998. 订单作废
  2999. </Button>
  3000. </Popconfirm>
  3001. <Button
  3002. className="cancel"
  3003. type="ghost"
  3004. onClick={this.visitCancel}
  3005. style={{ margin: 25 }}
  3006. >
  3007. 取消
  3008. </Button>
  3009. </div>
  3010. </div>
  3011. </Spin>
  3012. </Form>
  3013. </Modal> : <div />}
  3014. {/* <Modal
  3015. visible={this.state.rizhivisible}
  3016. className="admin-desc-content"
  3017. width="800px"
  3018. maskClosable={false}
  3019. title="订单日志"
  3020. footer={null}
  3021. onCancel={this.closeOrderLog}
  3022. >
  3023. <div className="patent-table">
  3024. <Spin spinning={this.state.loading}>
  3025. <Table
  3026. columns={this.state.columnsrizhi}
  3027. dataSource={this.state.dataSourcerizhi}
  3028. pagination={false}
  3029. />
  3030. </Spin>
  3031. </div>
  3032. </Modal> */}
  3033. <OrderRiZi
  3034. dataSourcerizhi={this.state.dataSourcerizhi}
  3035. closeOrderLog={this.closeOrderLog}
  3036. visible={this.state.rizhivisible}
  3037. loading={this.state.loading}
  3038. />
  3039. </div>
  3040. {
  3041. // 添加项目
  3042. this.state.projectOperationVisible &&
  3043. <NewAddProject
  3044. readOnly={this.state.dataInfor && Object.keys(this.state.dataInfor).length > 0 && this.state.processStatus !== 0}
  3045. orderNo={this.state.orderNo}
  3046. visible={this.state.projectOperationVisible}
  3047. newData={this.state.newData}
  3048. onCancel={this.nextCancel}
  3049. />
  3050. }
  3051. {
  3052. // 编辑项目
  3053. this.state.editProjectOperationVisible &&
  3054. <NewEditProject
  3055. readOnly={
  3056. this.state.dataInfor &&
  3057. Object.keys(this.state.dataInfor).length > 0 &&
  3058. this.state.processStatus !== 0
  3059. }
  3060. orderNo={this.state.orderNo}
  3061. visible={this.state.editProjectOperationVisible}
  3062. dataInfor={this.state.dataInfor}
  3063. newData={this.state.newData}
  3064. onCancel={this.nextCancel}
  3065. />
  3066. }
  3067. </div>
  3068. );
  3069. },
  3070. })
  3071. );
  3072. export default IntentionCustomer;