reject.jsx 104 KB

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