examinejl.jsx 88 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589
  1. import React from "react";
  2. import {
  3. Icon,
  4. Button,
  5. Input,
  6. Spin,
  7. Table,
  8. message,
  9. DatePicker,
  10. Upload,
  11. Form,
  12. Modal,
  13. Tabs,
  14. Col,
  15. Tooltip,
  16. Select,
  17. Radio,
  18. Tag,
  19. } from "antd";
  20. import $ from "jquery/src/ajax";
  21. import moment from "moment";
  22. import {
  23. getLiquidationStatus,
  24. getApprovedState,
  25. getProcessStatus,
  26. splitUrl,
  27. getjiedian,
  28. getboutique,
  29. getCuikuan,
  30. getProjectStatus,
  31. moneyVerify,
  32. ShowModal,
  33. getProjectName,
  34. getApprovalTag,
  35. getApprovedType,
  36. } from "@/tools.js";
  37. import "./customer.less";
  38. import ShowModalDiv from "@/showModal.jsx";
  39. import ResolutionDetail from "@/resolutionDetail";
  40. import OrderRiZi from "@/orderRiZi.jsx";
  41. import ImgList from "../../../common/imgList";
  42. import { ChooseList } from "./chooseList";
  43. import ProjectDetailsReadOnly from "../../../common/projectDetailsReadOnly";
  44. import NewEditProject from "../../../common/projectOperation/newEditProject"
  45. import OrderItemStatus from "../../../common/orderItemStatus";
  46. import EnterpriseNameChange from "../../../common/enterpriseNameChange";
  47. import OrderCoor from "./changeComponent/orderCoor";
  48. import ContentUrl from "./contentUrl";
  49. import { salesList, processStatus, approvalOptions } from "@/dataDic.js";
  50. import FlowChart from '../../../common/flowchart'; // 流程图
  51. import Gxczx from '../../../common/orderDetail/gxczx' // 高新纯咨询合同说明详情
  52. import Property from '../../../common/orderDetail/property' // 知识产权情况
  53. const confirm = Modal.confirm;
  54. const { Option } = Select;
  55. const RadioGroup = Radio.Group;
  56. const RadioButton = Radio.Button;
  57. //图片组件
  58. const PicturesWall = React.createClass({
  59. getInitialState() {
  60. return {
  61. previewVisible: false,
  62. previewImage: "",
  63. declarationBatch: 1,
  64. dataInfor: {},
  65. fileList: this.props.pictureUrl
  66. };
  67. },
  68. handleCancel() {
  69. this.setState({
  70. previewVisible: false
  71. });
  72. },
  73. handlePreview(file) {
  74. this.setState({
  75. previewImage: file.url || file.thumbUrl,
  76. previewVisible: true
  77. });
  78. },
  79. handleChange(info) {
  80. let fileList = info.fileList;
  81. this.setState({
  82. fileList
  83. });
  84. this.props.fileList(fileList);
  85. },
  86. componentWillReceiveProps(nextProps) {
  87. this.state.fileList = nextProps.pictureUrl;
  88. this.state.pojectApplicationUrl = undefined;
  89. },
  90. render() {
  91. const { previewVisible, previewImage, fileList } = this.state;
  92. const uploadButton = (
  93. <div>
  94. <Icon type="plus" />
  95. <div className="ant-upload-text">点击上传</div>
  96. </div>
  97. );
  98. return (
  99. <div style={{ display: "inline-block" }}>
  100. <Upload
  101. action={
  102. globalConfig.context + "/api/admin/outsourceOrg/uploadOutsourceFile"
  103. }
  104. data={{ sign: "order_outsource" }}
  105. listType="picture-card"
  106. fileList={fileList}
  107. multiple
  108. onPreview={this.handlePreview}
  109. onChange={this.handleChange}
  110. >
  111. {uploadButton}
  112. </Upload>
  113. {previewVisible ? <Modal
  114. maskClosable={false}
  115. width={"70px"}
  116. visible={previewVisible}
  117. footer={null}
  118. onCancel={this.handleCancel}
  119. >
  120. <img alt="example" style={{ width: "100%" }} src={previewImage} />
  121. </Modal> : <div />}
  122. </div>
  123. );
  124. }
  125. });
  126. const IntentionCustomer = Form.create()(
  127. React.createClass({
  128. loadData(pageNo) {
  129. this.setState({
  130. visitModul: false,
  131. loading: true,
  132. ispage: pageNo,
  133. modalVisible: false,
  134. });
  135. $.ajax({
  136. method: "get",
  137. dataType: "json",
  138. crossDomain: false,
  139. url: globalConfig.context + "/api/admin/newOrder/orderNewList",
  140. data: {
  141. pageNo: pageNo || 1,
  142. pageSize: this.state.pagination.pageSize,
  143. specially: 10, //营销经理审核 0 个人 1 营销员管理 2 驳回 3 特批 4 咨询师管理 5部门订单查询 6客服查询 7统计签单订单 8客户订单列表 9复审订单 10营销经理 11运营保障
  144. name: this.state.customerName, //名称
  145. orderNo: this.state.orderNoSearch, //订单编号
  146. starTime: this.state.releaseDate[0], //开始时间
  147. endTime: this.state.releaseDate[1], //结束时间
  148. approval: this.state.approvalSearch, //特批状态搜索
  149. processStatus: this.state.processStatusSearch,
  150. amountStatus: this.state.amountStatus,
  151. projectType: this.state.projectType,//会员
  152. type: this.state.approvaType.length > 0 ? this.state.approvaType.toString() : undefined, //特批类型
  153. },
  154. success: function (data) {
  155. ShowModal(this);
  156. let theArr = [];
  157. if (data.error.length || data.data.list == "") {
  158. if (data.error && data.error.length) {
  159. message.warning(data.error[0].message);
  160. }
  161. } else {
  162. for (let i = 0; i < data.data.list.length; i++) {
  163. let thisdata = data.data.list[i];
  164. theArr.push({
  165. key: i,
  166. id: thisdata.id, //用户ID
  167. salesType: thisdata.salesType, //销售类型
  168. deleteSign: thisdata.deleteSign,
  169. projectType: thisdata.projectType,
  170. other: thisdata.other,
  171. contractNo: thisdata.contractNo, //合同编号
  172. orderNo: thisdata.orderNo, //订单编号
  173. totalAmount: thisdata.totalAmount, //签单金额
  174. processStatus: thisdata.processStatus, //流程状态
  175. examineName: thisdata.examineName,
  176. liquidationStatus: thisdata.liquidationStatus, //结算状态
  177. approval: thisdata.approval, //特批状态
  178. signDate: thisdata.signDate, //签单时间
  179. userName: thisdata.userName, //客户名称
  180. salesmanName: thisdata.salesmanName, //营销员名称
  181. financeName: thisdata.financeName, //财务名称
  182. createDate: thisdata.createDate, //下单时间
  183. depName: thisdata.depName,
  184. orderStatus: thisdata.orderStatus,
  185. type: thisdata.type || "", // 特批类型
  186. typeExplain: thisdata.typeExplain,
  187. });
  188. }
  189. this.state.pagination.total = data.data.totalCount;
  190. this.state.pagination.current = data.data.pageNo;
  191. }
  192. if (data.data && data.data.list && !data.data.list.length) {
  193. this.state.pagination.total = 0;
  194. }
  195. this.setState({
  196. dataSource: theArr,
  197. pageNo: pageNo,
  198. pagination: this.state.pagination,
  199. selectedRowKeys: [],
  200. });
  201. }.bind(this),
  202. }).always(
  203. function () {
  204. this.setState({
  205. loading: false,
  206. });
  207. }.bind(this)
  208. );
  209. },
  210. getInitialState() {
  211. return {
  212. approvaType: [],
  213. rotateDeg: 0,
  214. page: 1,
  215. resVisible: false,
  216. releaseDate: [],
  217. selectedRowKeys: [],
  218. pictureUrl: [],
  219. attachmentUrl: [],
  220. paginations: false,
  221. activeKey: "1",
  222. confirmLoading: false,
  223. approvalSearch: undefined,
  224. processStatusSearch: undefined,
  225. aloading: false,
  226. orderNos: '',
  227. pagination: {
  228. defaultCurrent: 1,
  229. defaultPageSize: 10,
  230. showQuickJumper: true,
  231. pageSize: 10,
  232. onChange: function (page) {
  233. this.loadData(page);
  234. }.bind(this),
  235. showTotal: function (total) {
  236. return "共" + total + "条数据";
  237. },
  238. },
  239. columns: [
  240. {
  241. title: "销售类型",
  242. dataIndex: "salesType",
  243. key: "salesType",
  244. render: (text, record) => {
  245. return (
  246. <Tooltip
  247. title={salesList[text] + ((text == 3 || text == 4 || text == 5) ? (!record.other ? "" : "," + record.other) : "")}
  248. >
  249. <span>
  250. {salesList[text]}
  251. </span>
  252. </Tooltip>
  253. );
  254. },
  255. },
  256. {
  257. title: "特批类型",
  258. dataIndex: "type",
  259. key: "type",
  260. width: 110,
  261. render: (text, record) => {
  262. return (
  263. <span>
  264. {getApprovedType(text ? text.split(",").map(Number) : [], record.typeExplain)}
  265. </span>
  266. );
  267. },
  268. },
  269. {
  270. title: "合同编号",
  271. dataIndex: "contractNo",
  272. key: "contractNo",
  273. className: "title-table",
  274. render: (text, record) => {
  275. return (
  276. <Tooltip
  277. title={
  278. <Button
  279. type="primary"
  280. onClick={(e) => {
  281. e.stopPropagation();
  282. let input = document.getElementById("copyText");
  283. input.value = text;
  284. input.select();
  285. document.execCommand("copy");
  286. message.success("复制成功");
  287. }}
  288. >
  289. 复制
  290. </Button>
  291. }
  292. >
  293. <div>
  294. {text}
  295. <div style={{ display: "flex" }}>
  296. <OrderItemStatus deleteSign={record.deleteSign} />
  297. {getApprovalTag(record.approval)}
  298. </div>
  299. </div>
  300. </Tooltip>
  301. );
  302. },
  303. },
  304. {
  305. title: "客户名称",
  306. dataIndex: "userName",
  307. key: "userName",
  308. render: (text) => {
  309. return (
  310. <Tooltip title={text}>
  311. <div
  312. // style={{
  313. // maxWidth: '150px',
  314. // overflow: 'hidden',
  315. // textOverflow: "ellipsis",
  316. // whiteSpace: 'nowrap',
  317. // }}
  318. >{text}</div>
  319. </Tooltip>
  320. )
  321. },
  322. },
  323. {
  324. title: "订单编号",
  325. dataIndex: "orderNo",
  326. key: "orderNo",
  327. width: 140,
  328. render: (text, record) => {
  329. return (
  330. <Tooltip
  331. title={
  332. <Button
  333. type="primary"
  334. onClick={(e) => {
  335. e.stopPropagation();
  336. let input = document.getElementById("copyText");
  337. input.value = text;
  338. input.select();
  339. document.execCommand("copy");
  340. message.success("复制成功");
  341. }}
  342. >
  343. 复制
  344. </Button>
  345. }
  346. >
  347. <div>
  348. {text}
  349. <div>
  350. {record.totalAmount >= 10 && <Tag color="#ef7207">大客户</Tag>}
  351. {record.projectType == 1 && <Tag color="rgb(22, 155, 213)">会员</Tag>}
  352. </div>
  353. </div>
  354. </Tooltip>
  355. );
  356. },
  357. },
  358. {
  359. title: "下单时间",
  360. dataIndex: "createDate",
  361. key: "createTime",
  362. },
  363. {
  364. title: "合同签订时间",
  365. dataIndex: "signDate",
  366. key: "signDate",
  367. },
  368. {
  369. title: "流程状态",
  370. dataIndex: "processStatus",
  371. key: "processStatus",
  372. render: (text, record) => {
  373. return getProcessStatus(text, record.examineName, record.approval);
  374. },
  375. },
  376. {
  377. title: "订单部门",
  378. dataIndex: "depName",
  379. key: "depName",
  380. },
  381. {
  382. title: "签单金额(万元)",
  383. dataIndex: "totalAmount",
  384. key: "totalAmount",
  385. },
  386. {
  387. title: "结算状态",
  388. dataIndex: "liquidationStatus",
  389. key: "liquidationStatus",
  390. render: (text) => {
  391. return getLiquidationStatus(text);
  392. },
  393. },
  394. {
  395. title: "是否特批",
  396. dataIndex: "approval",
  397. key: "approval",
  398. render: (text) => {
  399. return getApprovedState(text);
  400. },
  401. },
  402. {
  403. title: "订单负责人",
  404. dataIndex: "salesmanName",
  405. key: "salesmanName",
  406. },
  407. {
  408. title: "财务负责人",
  409. dataIndex: "financeName",
  410. key: "financeName",
  411. },
  412. ],
  413. data: [],
  414. dataSource: [],
  415. columnsX: [
  416. {
  417. title: "业务项目名称",
  418. dataIndex: "commodityName",
  419. key: "commodityName",
  420. render: (text, record) => {
  421. return <span>{text}<span style={{ color: "red" }}>{record.patentTypeName}</span>{"-" + record.id}</span>
  422. }
  423. },
  424. {
  425. title: "项目类别",
  426. dataIndex: "cname",
  427. key: "cname",
  428. },
  429. {
  430. title: "项目数量",
  431. dataIndex: "commodityQuantity",
  432. key: "commodityQuantity",
  433. render: (text, record) => {
  434. if (record.splitStatus == 1) {
  435. return (
  436. <span>
  437. {text}{" "}
  438. {/* <Tag
  439. color="#108ee9"
  440. onClick={(e) => {
  441. e.stopPropagation();
  442. this.showRes(record);
  443. }}
  444. >
  445. 已拆
  446. </Tag> */}
  447. </span>
  448. );
  449. } else {
  450. return text;
  451. }
  452. },
  453. },
  454. {
  455. title: "金额(万元)",
  456. dataIndex: "commodityPrice",
  457. key: "commodityPrice",
  458. },
  459. {
  460. title: "负责人",
  461. dataIndex: "contacts",
  462. key: "contacts",
  463. },
  464. {
  465. title: "负责人电话",
  466. dataIndex: "contactsMobile",
  467. key: "contactsMobile",
  468. },
  469. {
  470. title: "项目状态",
  471. dataIndex: "projectStatus",
  472. key: "projectStatus",
  473. render: (text) => {
  474. return getProjectName(text);
  475. },
  476. },
  477. {
  478. title: "主要项目",
  479. dataIndex: "main",
  480. key: "main",
  481. width: 50,
  482. render: (text) => {
  483. return text ? "是" : "否";
  484. },
  485. },
  486. {
  487. title: "总年限",
  488. dataIndex: "yearSum",
  489. key: "yearSum",
  490. render: (text, record) => {
  491. return (
  492. <div>{["", "一年", "二年", "三年", "四年", "五年"][text]}</div>
  493. );
  494. }
  495. },
  496. {
  497. title: "年限",
  498. dataIndex: "serviceLife",
  499. key: "serviceLife",
  500. render: (text, record) => {
  501. return (
  502. <div>{!!text && JSON.parse(text).toString()}</div>
  503. );
  504. }
  505. },
  506. {
  507. title: "本次派单",
  508. dataIndex: "serviceYear",
  509. key: "serviceYear",
  510. render: (text, record) => {
  511. return (
  512. <div>{!text ? "" : text}</div>
  513. );
  514. }
  515. },
  516. {
  517. title: "项目说明",
  518. dataIndex: "taskComment",
  519. key: "taskComment",
  520. render: (text) => {
  521. return (
  522. <Tooltip title={text}>
  523. <div
  524. style={{
  525. width: 100,
  526. overflow: "hidden",
  527. whiteSpace: "nowrap",
  528. textOverflow: "ellipsis",
  529. }}
  530. >{text}</div>
  531. </Tooltip>
  532. )
  533. },
  534. },
  535. ],
  536. columnsrizhi: [
  537. {
  538. title: "流程",
  539. dataIndex: "processName",
  540. key: "processName",
  541. },
  542. {
  543. title: "操作人",
  544. dataIndex: "adminName",
  545. key: "adminName",
  546. },
  547. {
  548. title: "时间",
  549. dataIndex: "createDate",
  550. key: "createDate",
  551. },
  552. ],
  553. dataSourceX: [],
  554. ContactsListsNew: [
  555. {
  556. title: "项目名称",
  557. dataIndex: "commodityName",
  558. key: "commodityName",
  559. render: (text, record) => {
  560. return <span>{text + "-" + record.tid}</span>;
  561. },
  562. },
  563. {
  564. title: "项目分类",
  565. dataIndex: "projectType",
  566. key: "projectType",
  567. render: (text) => {
  568. let arr = this.state.dataSourceX || [];
  569. let str = "";
  570. for (let i = 0; i < arr.length; i++) {
  571. if (this.state.dataSourceX[i].sort == text) {
  572. str = this.state.dataSourceX[i].cname;
  573. return <span>{str}</span>;
  574. }
  575. }
  576. },
  577. },
  578. {
  579. title: "催款科目",
  580. dataIndex: "dunTypeName",
  581. key: "dunTypeName",
  582. render: (text, record) => {
  583. if (record.customizeName) {
  584. return text + record.customizeName;
  585. }
  586. return <span>{text}</span>;
  587. },
  588. },
  589. {
  590. title: "时间(天)",
  591. dataIndex: "waitDay",
  592. key: "waitDay",
  593. render: (text, record) => {
  594. if (record.dunTypeName) {
  595. if (record.customizeTimes) {
  596. return record.customizeTimes;
  597. }
  598. if (text == 0) {
  599. var str = "当天";
  600. } else if (!text) {
  601. var str = "";
  602. } else {
  603. var str = text + "天";
  604. }
  605. return <span>{str}</span>;
  606. }
  607. },
  608. },
  609. {
  610. title: "金额(万元)",
  611. dataIndex: "money",
  612. key: "money",
  613. render: (text, record) => {
  614. if (record.dunTypeName) {
  615. if (record.appropriationRatio) {
  616. let percent = Number(record.appropriationRatio * 100).toFixed(2);
  617. percent += "%";
  618. return <span>{percent}(拨款比例)</span>;
  619. } else {
  620. return <span>{text}</span>;
  621. }
  622. }
  623. },
  624. },
  625. {
  626. title: "服务年限",
  627. dataIndex: "startDate",
  628. key: "startDate",
  629. render: (text, record) => {
  630. if (record.dunTypeName) {
  631. return <span>{text}</span>;
  632. }
  633. },
  634. },
  635. {
  636. title: "催款状态",
  637. dataIndex: "status",
  638. key: "status",
  639. render: (text) => {
  640. return <span>{text == 1 ? "已启动" : "未启动"}</span>;
  641. },
  642. },
  643. ],
  644. ContactsLists: [
  645. {
  646. title: "催款科目",
  647. dataIndex: "dunSubject",
  648. key: "dunSubject",
  649. render: (text) => {
  650. return getjiedian(text);
  651. },
  652. },
  653. {
  654. title: "金额(万元)",
  655. visible订单详情dataIndex: "money",
  656. key: "money",
  657. },
  658. {
  659. title: "催款状态",
  660. dataIndex: "dunStatus",
  661. key: "dunStatus",
  662. render: (text) => {
  663. return getCuikuan(text);
  664. },
  665. },
  666. ],
  667. };
  668. },
  669. //页面加载函数
  670. componentWillMount() {
  671. this.loadData();
  672. },
  673. //整行点击
  674. tableRowClick(record) {
  675. this.setState({
  676. visible: true,
  677. orderStatus: record.orderStatus,
  678. id: record.id,
  679. orderNos: record.orderNo
  680. });
  681. this.xiangqing(record.orderNo);
  682. this.xiangmu(record.orderNo);
  683. this.jiedian(record.orderNo);
  684. this.jiedianNew(record.orderNo);
  685. },
  686. //点击打卡项目详情
  687. tableRowClickX(record) {
  688. if (record.type == "1") {
  689. this.setState({
  690. displayFees: "block",
  691. costReduction: record.costReduction,
  692. officialCost: record.officialCost,
  693. });
  694. } else {
  695. this.setState({
  696. displayFees: "none",
  697. });
  698. }
  699. this.setState({
  700. jid: record.id, //项目ID
  701. kid: record.commodityId, //商品ID
  702. commodityName: record.commodityName, //金额
  703. commodityPrice: record.commodityPrice, //金额
  704. commodityQuantity: record.commodityQuantity, //数量
  705. taskComment: record.taskComment, //备注
  706. main: record.main.toString(), //是否为主要
  707. addnextVisible: true,
  708. dataInfor: record,
  709. addState: 0,
  710. });
  711. },
  712. //项目详情关闭
  713. nextCancel() {
  714. this.setState({
  715. addnextVisible: false,
  716. displayFees: "none",
  717. officialCost: "", //是否有官费
  718. costReduction: "", //是否有费减
  719. });
  720. },
  721. //订单详情
  722. xiangqing(orderNos) {
  723. $.ajax({
  724. method: "get",
  725. dataType: "json",
  726. crossDomain: false,
  727. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  728. data: {
  729. orderNo: orderNos,
  730. },
  731. success: function (data) {
  732. if (data.error.length || data.data.list == "") {
  733. if (data.error && data.error.length) {
  734. message.warning(data.error[0].message);
  735. }
  736. } else {
  737. let thisdata = data.data;
  738. this.setState({
  739. orderUid: thisdata.uid,
  740. userType: thisdata.userType,//
  741. salesType: thisdata.salesType, //销售类型
  742. other: thisdata.other,
  743. orderNo: thisdata.orderNo, //订单编号
  744. contractNo: thisdata.contractNo, //合同编号
  745. userName: thisdata.userName, //客户名称
  746. signDate: thisdata.signDate, //签单时间
  747. examineName: thisdata.examineName,
  748. processStatus: thisdata.processStatus, //流程状态
  749. liquidationStatus: thisdata.liquidationStatus, //结算状态
  750. contacts: thisdata.contacts, //企业联系人
  751. contactMobile: thisdata.contactMobile, //联系人电话
  752. legalPerson: thisdata.legalPerson, //法人
  753. legalPersonTel: thisdata.legalPersonTel, //法人电话
  754. firstAmount: thisdata.firstAmount, //签单金额
  755. totalAmount: thisdata.totalAmount, //首付金额
  756. approval: thisdata.approval, //特批状态
  757. settlementAmount: thisdata.settlementAmount, //已收款项
  758. orderRemarks: thisdata.orderRemarks, //订单留言
  759. orgCodeUrl: thisdata.contractPictureUrl
  760. ? splitUrl(
  761. thisdata.contractPictureUrl,
  762. ",",
  763. globalConfig.avatarHost + "/upload"
  764. )
  765. : [], //图片地址
  766. replenishUrl: thisdata.agreementUrl
  767. ? splitUrl(
  768. thisdata.agreementUrl,
  769. ",",
  770. globalConfig.avatarHost + "/upload"
  771. )
  772. : [], //图片地址
  773. contentUrl: thisdata.serviceContent
  774. ? splitUrl(
  775. thisdata.serviceContent,
  776. ",",
  777. globalConfig.avatarHost + "/upload"
  778. )
  779. : [], //图片地址
  780. salesmanName: thisdata.salesmanName, //营销员名称
  781. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  782. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  783. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  784. financeName: thisdata.financeName, //财务名称
  785. financeMobile: thisdata.financeMobile, //财务电话
  786. nowFinance: thisdata.nowFinance, //财务名称
  787. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  788. depName: thisdata.depName,
  789. outsource: thisdata.outsource == 0 ? "否" : "是",
  790. deleteSign: thisdata.deleteSign,
  791. // 高新纯咨询合同说明
  792. knowledgeServices: thisdata.knowledgeServices, //知识产权服务
  793. auditServices: thisdata.auditServices, //审计服务
  794. addDeductionServices: thisdata.addDeductionServices, //加计扣除服务
  795. knowledgeOther: thisdata.knowledgeOther, //知识产权服务其他描述
  796. auditOther: thisdata.auditOther, //审计服务其他描述
  797. addDeductionOther: thisdata.addDeductionOther, //加计扣除服务其他描述
  798. patentStatus: thisdata.patentStatus, //知识产权情况
  799. type: thisdata.type,// 特批类型
  800. typeExplain: thisdata.typeExplain, // 特批类型
  801. });
  802. }
  803. }.bind(this),
  804. }).always(
  805. function () {
  806. this.setState({
  807. loading: false,
  808. });
  809. }.bind(this)
  810. );
  811. },
  812. //项目列表
  813. xiangmu(orderNos) {
  814. $.ajax({
  815. method: "get",
  816. dataType: "json",
  817. crossDomain: false,
  818. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  819. data: {
  820. orderNo: orderNos,
  821. },
  822. success: function (data) {
  823. let theArr = [];
  824. if (data.error.length || data.data.list == "") {
  825. if (data.error && data.error.length) {
  826. message.warning(data.error[0].message);
  827. }
  828. } else {
  829. for (let i = 0; i < data.data.length; i++) {
  830. let thisdata = data.data[i];
  831. thisdata.key = i;
  832. thisdata.sort = thisdata.cSort;
  833. theArr.push(thisdata);
  834. }
  835. }
  836. this.setState({
  837. dataSourceX: theArr,
  838. });
  839. }.bind(this),
  840. }).always(
  841. function () {
  842. this.setState({
  843. loading: false,
  844. });
  845. }.bind(this)
  846. );
  847. },
  848. rizhi() {
  849. this.setState({
  850. loading: true,
  851. });
  852. $.ajax({
  853. method: "get",
  854. dataType: "json",
  855. crossDomain: false,
  856. url: "/api/admin/newOrder/selectOrderLog",
  857. data: {
  858. orderNo: this.state.orderNo,
  859. },
  860. success: function (data) {
  861. let theArr = [];
  862. let thisData = data.data;
  863. if (!thisData.length) {
  864. if (data.error && data.error.length) {
  865. message.warning(data.error[0].message);
  866. }
  867. thisData = {};
  868. } else {
  869. for (let i = 0; i < data.data.length; i++) {
  870. let thisdata = data.data[i];
  871. theArr.push({
  872. processName: thisdata.processName,
  873. adminName: thisdata.adminName,
  874. createDate: thisdata.createDate,
  875. remarks: thisdata.remarks,
  876. });
  877. }
  878. }
  879. this.setState({
  880. dataSourcerizhi: theArr,
  881. });
  882. }.bind(this),
  883. }).always(
  884. function () {
  885. this.setState({
  886. loading: false,
  887. });
  888. }.bind(this)
  889. );
  890. },
  891. // 拆分详细
  892. showRes(record) {
  893. this.setState({
  894. resVisible: true,
  895. resRecord: record,
  896. });
  897. },
  898. resCancel() {
  899. this.setState({
  900. resVisible: false,
  901. });
  902. },
  903. getOrderLog() {
  904. this.setState({
  905. rizhivisible: true,
  906. });
  907. this.rizhi();
  908. },
  909. closeOrderLog() {
  910. this.setState({
  911. rizhivisible: false,
  912. });
  913. },
  914. //节点列表
  915. jiedian(orderNos) {
  916. $.ajax({
  917. method: "get",
  918. dataType: "json",
  919. crossDomain: false,
  920. url: globalConfig.context + "/api/admin/newOrder/selectOrderDun",
  921. data: {
  922. orderNo: orderNos,
  923. },
  924. success: function (data) {
  925. let theArr = [];
  926. let thisData = [];
  927. if (data.error.length || data.data.list == "") {
  928. if (data.error && data.error.length) {
  929. message.warning(data.error[0].message);
  930. }
  931. } else {
  932. for (let i = 0; i < data.data.length; i++) {
  933. thisData = data.data[i];
  934. theArr.push({
  935. key: i,
  936. dunSubject: thisData.dunSubject
  937. ? thisData.dunSubject.toString()
  938. : "", //催款科目
  939. id: thisData.id, //节点Id
  940. money: thisData.money, //催款金额
  941. dunStatus: thisData.dunStatus, //催款状态
  942. });
  943. }
  944. this.setState({
  945. contactList: theArr,
  946. });
  947. }
  948. }.bind(this),
  949. }).always(
  950. function () {
  951. this.setState({
  952. loading: false,
  953. });
  954. }.bind(this)
  955. );
  956. },
  957. //查看催款节点
  958. jiedianNew(orderNos) {
  959. $.ajax({
  960. method: "get",
  961. dataType: "json",
  962. crossDomain: false,
  963. url:
  964. globalConfig.context + "/api/admin/newOrderDun/selectListNewOrderDun",
  965. data: {
  966. orderNo: orderNos,
  967. },
  968. success: function (data) {
  969. if (data.error && data.error.length) {
  970. message.warning(data.error[0].message);
  971. } else {
  972. let theArr = [];
  973. let thisData = [];
  974. let arr = data.data || [];
  975. let totalCui = 0;
  976. for (let i = 0; i < arr.length; i++) {
  977. thisData = arr[i];
  978. totalCui += +thisData.money;
  979. theArr.push({
  980. key: i,
  981. dunSubject: thisData.dunSubject
  982. ? thisData.dunSubject.toString()
  983. : "", //催款科目
  984. id: thisData.id, //节点Id
  985. money: thisData.money, //催款金额
  986. // orderNo: record ? record.orderNo : this.props.datauser.orderNo,
  987. commodityName: thisData.commodityName,
  988. projectType: thisData.projectType,
  989. dunTypeName: thisData.dunTypeName,
  990. status: thisData.status,
  991. waitDay: thisData.waitDay,
  992. effectiveCount: thisData.effectiveCount,
  993. startDate: thisData.startDate,
  994. dunType: thisData.dunType,
  995. appropriationRatio: thisData.appropriationRatio,
  996. customizeName: thisData.customizeName,
  997. customizeTimes: thisData.customizeTimes,
  998. tid: thisData.tid,
  999. });
  1000. }
  1001. if (!totalCui) {
  1002. totalCui = 0;
  1003. }
  1004. totalCui = (Math.round(totalCui * 1000000) / 1000000).toFixed(6);
  1005. this.setState({
  1006. contactListNew: theArr,
  1007. totalCui,
  1008. });
  1009. }
  1010. }.bind(this),
  1011. }).always(
  1012. function () {
  1013. this.setState({
  1014. loading: false,
  1015. });
  1016. }.bind(this)
  1017. );
  1018. },
  1019. //审核通过
  1020. examOk() {
  1021. if (!this.state.reason) {
  1022. message.warning("请填写备注信息");
  1023. return;
  1024. }
  1025. if (!this.state.reason.replace(/\s+/g, '')) {
  1026. message.warning("请填写备注信息");
  1027. return;
  1028. }
  1029. if (this.state.flag) return;
  1030. this.setState({
  1031. flag: true,
  1032. loading: true,
  1033. });
  1034. $.ajax({
  1035. method: "post",
  1036. dataType: "json",
  1037. crossDomain: false,
  1038. url: globalConfig.context + "/api/admin/newOrder/auditOrderNew",
  1039. data: {
  1040. orderNo: this.state.orderNo,
  1041. orderStatus: 2,
  1042. reason: this.state.reason,
  1043. },
  1044. success: function (data) {
  1045. if (data.error.length || data.data.list == "") {
  1046. if (data.error && data.error.length) {
  1047. message.warning(data.error[0].message);
  1048. this.setState({
  1049. flag: false,
  1050. });
  1051. }
  1052. } else {
  1053. message.success("该订单已通过审核~");
  1054. this.setState({
  1055. visible: false,
  1056. flag: false,
  1057. agreeVisible: false,
  1058. });
  1059. this.loadData(this.state.pageNo)
  1060. // this.reset();
  1061. }
  1062. }.bind(this),
  1063. }).always(
  1064. function () {
  1065. this.setState({
  1066. loading: false,
  1067. });
  1068. }.bind(this)
  1069. );
  1070. },
  1071. //通过发给外包
  1072. outsourcing() {
  1073. if (this.state.flag) return;
  1074. this.setState({
  1075. flag: true,
  1076. loading: true,
  1077. });
  1078. $.ajax({
  1079. method: "post",
  1080. dataType: "json",
  1081. crossDomain: false,
  1082. url: globalConfig.context + "/api/admin/newOrder/auditOrderNew",
  1083. data: {
  1084. orderNo: this.state.orderNo,
  1085. orderStatus: 2,
  1086. outsource: 1,
  1087. },
  1088. success: function (data) {
  1089. if (data.error.length == 0 || data.data.list == "") {
  1090. if (data.error && data.error.length) {
  1091. message.warning(data.error[0].message);
  1092. this.setState({
  1093. flag: false,
  1094. });
  1095. }
  1096. } else {
  1097. message.success("该订单已通过审核~");
  1098. this.setState({
  1099. visible: false,
  1100. flag: false,
  1101. });
  1102. // this.reset();
  1103. this.loadData(this.state.pageNo)
  1104. }
  1105. }.bind(this),
  1106. }).always(
  1107. function () {
  1108. this.setState({
  1109. loading: false,
  1110. });
  1111. }.bind(this)
  1112. );
  1113. },
  1114. //审核不通过
  1115. examOks() {
  1116. if (!this.state.reason) {
  1117. message.warn("请先填写拒绝理由");
  1118. return
  1119. }
  1120. if (!this.state.reason.replace(/\s+/g, '')) {
  1121. message.warning("请先填写拒绝理由");
  1122. return;
  1123. }
  1124. this.setState({
  1125. loading: true,
  1126. });
  1127. this.setState({
  1128. aloading: true,
  1129. });
  1130. $.ajax({
  1131. method: "post",
  1132. dataType: "json",
  1133. crossDomain: false,
  1134. url: globalConfig.context + "/api/admin/newOrder/auditOrderNew",
  1135. data: {
  1136. orderNo: this.state.orderNo,
  1137. orderStatus: 3,
  1138. reason: this.state.reason,
  1139. },
  1140. success: function (data) {
  1141. if (data.error.length || data.data.list == "") {
  1142. if (data.error && data.error.length) {
  1143. message.warning(data.error[0].message);
  1144. this.setState({
  1145. aloading: false,
  1146. loading: false,
  1147. });
  1148. }
  1149. } else {
  1150. message.success("该订单已被拒绝~");
  1151. this.setState({
  1152. visible: false,
  1153. aloading: false,
  1154. noVisible: false,
  1155. reason: "",
  1156. loading: false,
  1157. });
  1158. // this.reset();
  1159. this.loadData(this.state.pageNo)
  1160. }
  1161. }.bind(this),
  1162. }).always(
  1163. function () {
  1164. this.setState({
  1165. loading: false,
  1166. });
  1167. }.bind(this)
  1168. );
  1169. },
  1170. //点击拒绝
  1171. examNo() {
  1172. this.setState({
  1173. noVisible: true,
  1174. });
  1175. },
  1176. callback(key) {
  1177. let url = window.location.href.substring(7);
  1178. this.setState({
  1179. activeKey: key,
  1180. });
  1181. if (this.state.pictureUrl.length) {
  1182. let picArr = [];
  1183. this.state.pictureUrl.map(function (item) {
  1184. if (
  1185. item.response &&
  1186. item.response.data &&
  1187. item.response.data.length
  1188. ) {
  1189. picArr.push(item.response.data);
  1190. }
  1191. });
  1192. }
  1193. if (key === "2") {
  1194. this.setState({
  1195. loading: true,
  1196. });
  1197. $.ajax({
  1198. method: "get",
  1199. dataType: "json",
  1200. crossDomain: false,
  1201. url:
  1202. globalConfig.context +
  1203. "/api/admin/outsourceOrg/orderOutsourceDtails",
  1204. data: {
  1205. orderNo: this.state.orderNo,
  1206. },
  1207. success: function (data) {
  1208. if (data.data) {
  1209. let thisdata = data.data;
  1210. this.setState({
  1211. id: thisdata.id,
  1212. createTimes: thisdata.createTimes,
  1213. auditTimes: thisdata.auditTimes,
  1214. remarks: thisdata.remarks,
  1215. attachmentUrl: thisdata.attachmentUrl
  1216. ? splitUrl(
  1217. thisdata.attachmentUrl,
  1218. ",",
  1219. globalConfig.avatarHost + "/upload",
  1220. url
  1221. )
  1222. : [],
  1223. fileUrl: thisdata.attachmentUrl
  1224. ? splitUrl(
  1225. thisdata.attachmentUrl,
  1226. ",",
  1227. globalConfig.avatarHost + "/upload",
  1228. url
  1229. )
  1230. : [],
  1231. pictureUrl: thisdata.pictureUrl
  1232. ? splitUrl(
  1233. thisdata.pictureUrl,
  1234. ",",
  1235. globalConfig.avatarHost + "/upload",
  1236. url
  1237. )
  1238. : [], //图片地址
  1239. amount: thisdata.amount,
  1240. companyName: thisdata.companyName,
  1241. outsourceRemarks: thisdata.outsourceRemarks,
  1242. unitNumber: thisdata.unitNumber,
  1243. unitPrice: thisdata.unitPrice,
  1244. });
  1245. }
  1246. }.bind(this),
  1247. }).always(
  1248. function () {
  1249. this.setState({
  1250. loading: false,
  1251. });
  1252. }.bind(this)
  1253. );
  1254. }
  1255. },
  1256. getUrl(url) {
  1257. let theorgCodeUrl = [];
  1258. if (url.length) {
  1259. let picArr = [];
  1260. url.map(function (item) {
  1261. if (
  1262. item.response &&
  1263. item.response.data &&
  1264. item.response.data.length
  1265. ) {
  1266. picArr.push(item.response.data);
  1267. }
  1268. });
  1269. theorgCodeUrl = picArr.join(",");
  1270. }
  1271. return theorgCodeUrl;
  1272. },
  1273. sureOut() {
  1274. this.setState({
  1275. loading: true,
  1276. });
  1277. if (!this.state.companyName) {
  1278. message.warning("公司名称不能为空");
  1279. return;
  1280. }
  1281. if (!this.state.unitPrice) {
  1282. message.warning("单价不能为空");
  1283. return;
  1284. }
  1285. if (moneyVerify(this.state.unitPrice)) {
  1286. return;
  1287. }
  1288. if (!this.state.unitNumber) {
  1289. message.warning("数量不能为空");
  1290. return;
  1291. }
  1292. if (!this.state.amount) {
  1293. message.warning("总金额不能为空");
  1294. return;
  1295. }
  1296. if (moneyVerify(this.state.amount)) {
  1297. return;
  1298. }
  1299. if (!this.state.outsourceRemarks) {
  1300. message.warning("备注不能为空");
  1301. return;
  1302. }
  1303. if (this.state.pictureUrl.length === 0) {
  1304. message.warning("合同扫描件不能为空");
  1305. return;
  1306. }
  1307. $.ajax({
  1308. method: "POST",
  1309. dataType: "json",
  1310. crossDomain: false,
  1311. url: globalConfig.context + "/api/admin/outsourceOrg/auditOutsource",
  1312. data: {
  1313. id: this.state.id,
  1314. orderNo: this.state.orderNo,
  1315. companyName: this.state.companyName,
  1316. amount: this.state.amount,
  1317. outsourceRemarks: this.state.outsourceRemarks,
  1318. unitNumber: this.state.unitNumber,
  1319. unitPrice: this.state.unitPrice,
  1320. attachmentUrl: this.getUrl(this.state.attachmentUrl).length
  1321. ? this.getUrl(this.state.attachmentUrl)
  1322. : "",
  1323. orderStatus: 2,
  1324. pictureUrl: this.getUrl(this.state.pictureUrl).length
  1325. ? this.getUrl(this.state.pictureUrl)
  1326. : "",
  1327. },
  1328. }).done(
  1329. function (data) {
  1330. this.setState({
  1331. loading: false,
  1332. });
  1333. if (!data.error.length) {
  1334. message.success("发起成功!");
  1335. this.outReset();
  1336. this.visitCancel();
  1337. } else {
  1338. message.warning(data.error[0].message);
  1339. }
  1340. }.bind(this)
  1341. );
  1342. },
  1343. //关闭输入理由框
  1344. noCancel() {
  1345. this.setState({
  1346. noVisible: false,
  1347. aloading: false,
  1348. reason: "",
  1349. });
  1350. },
  1351. //搜索
  1352. search() {
  1353. this.setState({
  1354. //signBillVisible:false
  1355. });
  1356. this.loadData();
  1357. },
  1358. //重置
  1359. reset() {
  1360. this.setState({
  1361. signBillVisible: false,
  1362. });
  1363. this.state.orderNoSearch = "";
  1364. this.state.customerName = "";
  1365. this.state.releaseDate[0] = undefined;
  1366. this.state.releaseDate[1] = undefined;
  1367. this.state.approval = undefined;
  1368. this.state.approvalSearch = undefined;
  1369. this.state.amountStatus = undefined;
  1370. this.state.processStatusSearch = undefined;
  1371. this.state.projectType = undefined;
  1372. this.state.approvaType = [];
  1373. this.loadData(1);
  1374. },
  1375. outReset() {
  1376. this.setState({
  1377. companyName: "",
  1378. amount: "",
  1379. unitPrice: "",
  1380. unitNumber: "",
  1381. outsourceRemarks: "",
  1382. attachmentUrl: [],
  1383. pictureUrl: [],
  1384. });
  1385. },
  1386. resets() {
  1387. this.state.orderNo = "";
  1388. this.state.customerName = "";
  1389. this.state.releaseDate[0] = undefined;
  1390. this.state.releaseDate[1] = undefined;
  1391. },
  1392. getOrgCodeUrl(e) {
  1393. this.setState({ pictureUrl: e });
  1394. },
  1395. //关闭详情
  1396. visitCancel() {
  1397. this.setState(
  1398. {
  1399. visible: false,
  1400. },
  1401. () => {
  1402. this.setState({
  1403. activeKey: "1",
  1404. });
  1405. }
  1406. );
  1407. this.resets();
  1408. this.loadData(this.state.pageNo);
  1409. },
  1410. visitOk() {
  1411. this.setState({
  1412. visible: false,
  1413. });
  1414. this.resets();
  1415. },
  1416. showDeleteConfirm(fn) {
  1417. confirm({
  1418. title: <p style={{ fontSize: 16, fontWeight: 900 }}>注意</p>,
  1419. content: (
  1420. <p style={{ fontWeight: 900, color: "red" }}>
  1421. 当前订单为外包单,您确定修改为普通订单?
  1422. </p>
  1423. ),
  1424. okText: "确定",
  1425. okType: "danger",
  1426. cancelText: "取消",
  1427. onOk() {
  1428. fn();
  1429. },
  1430. onCancel() { },
  1431. });
  1432. },
  1433. downImg() {
  1434. let num = 0;
  1435. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  1436. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  1437. num = i;
  1438. }
  1439. }
  1440. if (num == this.state.orgCodeUrl.length - 1) {
  1441. return message.warning("已经是最后一张了哦");
  1442. }
  1443. this.state.previewImage = this.state.orgCodeUrl[num + 1].url;
  1444. this.setState({
  1445. previewImage: this.state.previewImage,
  1446. rotateDeg: 0,
  1447. });
  1448. },
  1449. upImg() {
  1450. let num = 0;
  1451. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  1452. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  1453. num = i;
  1454. }
  1455. }
  1456. if (num == 0) {
  1457. return message.warning("已经是第一张了哦");
  1458. }
  1459. this.state.previewImage = this.state.orgCodeUrl[num - 1].url;
  1460. this.setState({
  1461. previewImage: this.state.previewImage,
  1462. rotateDeg: 0,
  1463. });
  1464. },
  1465. rotate() {
  1466. let rotateDeg = this.state.rotateDeg + 90;
  1467. this.setState({
  1468. rotateDeg,
  1469. });
  1470. },
  1471. downImgs() {
  1472. let num = 0;
  1473. for (let i = 0; i < this.state.replenishUrl.length; i++) {
  1474. if (this.state.replenishUrl[i].url == this.state.previewImage) {
  1475. num = i;
  1476. }
  1477. }
  1478. if (num == this.state.replenishUrl.length - 1) {
  1479. return message.warning("已经是最后一张了哦");
  1480. }
  1481. this.state.previewImage = this.state.replenishUrl[num + 1].url;
  1482. this.setState({
  1483. previewImage: this.state.previewImage,
  1484. rotateDeg: 0,
  1485. });
  1486. },
  1487. upImgs() {
  1488. let num = 0;
  1489. for (let i = 0; i < this.state.replenishUrl.length; i++) {
  1490. if (this.state.replenishUrl[i].url == this.state.previewImage) {
  1491. num = i;
  1492. }
  1493. }
  1494. if (num == 0) {
  1495. return message.warning("已经是第一张了哦");
  1496. }
  1497. this.state.previewImage = this.state.replenishUrl[num - 1].url;
  1498. this.setState({
  1499. previewImage: this.state.previewImage,
  1500. rotateDeg: 0,
  1501. });
  1502. },
  1503. rotates() {
  1504. let rotateDeg = this.state.rotateDeg + 90;
  1505. this.setState({
  1506. rotateDeg,
  1507. });
  1508. },
  1509. changeList(arr) {
  1510. const newArr = [];
  1511. this.state.columns.forEach(item => {
  1512. arr.forEach(val => {
  1513. if (val === item.title) {
  1514. newArr.push(item);
  1515. }
  1516. });
  1517. });
  1518. this.setState({
  1519. changeList: newArr
  1520. });
  1521. },
  1522. // 可展开颜色不同
  1523. addRowColor(record) {
  1524. if (!!record.splitList && record.splitList.length > 0) {
  1525. return 'light'
  1526. } else {
  1527. return 'dark'
  1528. }
  1529. },
  1530. render() {
  1531. const expandedRowRenderVip = (e) => {
  1532. const data = e.splitList;
  1533. let columns = [];
  1534. if (data instanceof Array && data.length) {
  1535. if (e.cSort == 6) {
  1536. columns = [
  1537. {
  1538. title: "负责人",
  1539. dataIndex: "receiverName",
  1540. key: "receiverName",
  1541. },
  1542. {
  1543. title: "负责人电话",
  1544. dataIndex: "receiverMobile",
  1545. key: "receiverMobile",
  1546. },
  1547. {
  1548. title: "会员负责人",
  1549. dataIndex: "projectMemberName",
  1550. key: "projectMemberName",
  1551. },
  1552. {
  1553. title: "项目状态",
  1554. dataIndex: "projectStatus",
  1555. key: "projectStatus",
  1556. render: (text) => {
  1557. return getProjectName(text);
  1558. },
  1559. },
  1560. {
  1561. title: "本次派单",
  1562. dataIndex: "serviceYear",
  1563. key: "serviceYear",
  1564. },
  1565. {
  1566. title: "项目说明",
  1567. dataIndex: "taskComment",
  1568. key: "taskComment",
  1569. render: (text) => {
  1570. return (
  1571. <Tooltip title={text}>
  1572. <div
  1573. // style={{
  1574. // width: 100,
  1575. // overflow: "hidden",
  1576. // whiteSpace: "nowrap",
  1577. // textOverflow: "ellipsis",
  1578. // }}
  1579. >{text}</div>
  1580. </Tooltip>
  1581. )
  1582. },
  1583. },
  1584. ];
  1585. } else {
  1586. columns = [
  1587. {
  1588. title: "子项目名称",
  1589. dataIndex: "taskName",
  1590. key: "taskName"
  1591. },
  1592. {
  1593. title: "子项目数量",
  1594. dataIndex: "commodityQuantity",
  1595. key: "commodityQuantity"
  1596. },
  1597. {
  1598. title: "拆分操作人",
  1599. dataIndex: "splitAname",
  1600. key: "splitAname"
  1601. },
  1602. {
  1603. title: "项目负责人",
  1604. dataIndex: "receiverName",
  1605. key: "receiverName"
  1606. },
  1607. {
  1608. title: "拆分时间",
  1609. dataIndex: "splitTimes",
  1610. key: "splitTimes"
  1611. }
  1612. ]
  1613. }
  1614. return (
  1615. <Table
  1616. columns={columns}
  1617. dataSource={data}
  1618. pagination={false}
  1619. />
  1620. );
  1621. } else {
  1622. columns = [];
  1623. return (
  1624. <p
  1625. style={{ fontWeight: "bold", color: "red", textAlign: "center" }}
  1626. >
  1627. {e.cSort == 6 ? "暂无派单" : "此项目暂未拆分"}
  1628. </p>
  1629. );
  1630. }
  1631. };
  1632. const formItemLayout = {
  1633. labelCol: { span: 10 },
  1634. wrapperCol: { span: 14 },
  1635. };
  1636. const FormItem = Form.Item;
  1637. const { TabPane } = Tabs;
  1638. const { TextArea } = Input;
  1639. const { RangePicker } = DatePicker;
  1640. const cuiDataList = this.state.contactList || [];
  1641. const approvaChildren = approvalOptions.map(i => (
  1642. <Option key={i.value}>{i.label}</Option>
  1643. ));
  1644. return (
  1645. <div className="user-content">
  1646. {this.state.resVisible ? (
  1647. <ResolutionDetail
  1648. cancel={this.resCancel}
  1649. detail={this.state.resRecord}
  1650. visible={this.state.resVisible}
  1651. id={this.state.resRecord.orderNo}
  1652. />
  1653. ) : (
  1654. ""
  1655. )}
  1656. <ShowModalDiv ShowModal={this.state.showModal} onClose={() => { this.setState({ showModal: false }) }} />
  1657. <div className="content-title" style={{ marginBottom: 10 }}>
  1658. <span style={{ fontWeight: 900, fontSize: 16 }}>订单审核</span>
  1659. </div>
  1660. <Tabs defaultActiveKey="1" onChange={this.callback} className="test">
  1661. <TabPane tab="搜索" key="1">
  1662. <div className="user-search">
  1663. <Input
  1664. placeholder="客户名称"
  1665. style={{
  1666. width: "150px",
  1667. marginBottom: "10px",
  1668. marginLeft: 10,
  1669. }}
  1670. value={this.state.customerName}
  1671. onChange={(e) => {
  1672. this.setState({ customerName: e.target.value });
  1673. }}
  1674. />
  1675. <Input
  1676. placeholder="订单编号"
  1677. style={{ width: "150px" }}
  1678. value={this.state.orderNoSearch}
  1679. onChange={(e) => {
  1680. this.setState({ orderNoSearch: e.target.value });
  1681. }}
  1682. />
  1683. <Select
  1684. style={{ width: 120 }}
  1685. placeholder="特批状态"
  1686. value={this.state.approvalSearch}
  1687. onChange={(e) => {
  1688. this.setState({
  1689. approvalSearch: e,
  1690. });
  1691. }}
  1692. >
  1693. <Option value="0">非特批</Option>
  1694. <Option value="1">特批待审</Option>
  1695. <Option value="2">特批通过</Option>
  1696. <Option value="4">全部特批</Option>
  1697. </Select>
  1698. <Select
  1699. style={{ width: 120 }}
  1700. placeholder="签单金额"
  1701. value={this.state.amountStatus}
  1702. onChange={(e) => {
  1703. this.setState({
  1704. amountStatus: e,
  1705. });
  1706. }}
  1707. >
  1708. <Option value="0">10万元以下</Option>
  1709. <Option value="1">10~20万元</Option>
  1710. <Option value="2">20~30万元</Option>
  1711. <Option value="3">30~40万元</Option>
  1712. <Option value="4">40万元以上</Option>
  1713. </Select>
  1714. <Select
  1715. style={{ width: 120 }}
  1716. placeholder="会员状态"
  1717. value={this.state.projectType}
  1718. onChange={(e) => {
  1719. this.setState({
  1720. projectType: e,
  1721. });
  1722. }}
  1723. >
  1724. <Option value="1">会员</Option>
  1725. <Option value="0">非会员</Option>
  1726. </Select>
  1727. <Select
  1728. style={{ width: 150 }}
  1729. placeholder="流程状态"
  1730. value={this.state.processStatusSearch}
  1731. onChange={e => {
  1732. this.setState({
  1733. processStatusSearch: e
  1734. });
  1735. }}
  1736. >
  1737. <Option value="">全部</Option>
  1738. {
  1739. processStatus.map((item) =>
  1740. <Option value={item.value} key={item.value}>{item.key}</Option>
  1741. )
  1742. }
  1743. </Select>
  1744. <Select
  1745. mode="multiple"
  1746. style={{ width: 200 }}
  1747. placeholder="特批类型"
  1748. value={this.state.approvaType}
  1749. onChange={e => {
  1750. this.setState({
  1751. approvaType: e
  1752. })
  1753. }}
  1754. >
  1755. {approvaChildren}
  1756. </Select>
  1757. <span style={{ marginRight: "10px" }}>下单时间 :</span>
  1758. <RangePicker
  1759. value={[
  1760. this.state.releaseDate[0]
  1761. ? moment(this.state.releaseDate[0])
  1762. : null,
  1763. this.state.releaseDate[1]
  1764. ? moment(this.state.releaseDate[1])
  1765. : null,
  1766. ]}
  1767. onChange={(data, dataString) => {
  1768. this.setState({ releaseDate: dataString });
  1769. }}
  1770. />
  1771. <Button
  1772. type="primary"
  1773. onClick={this.search}
  1774. style={{ marginLeft: "10px" }}
  1775. >
  1776. 搜索
  1777. </Button>
  1778. <Button onClick={this.reset}>重置</Button>
  1779. </div>
  1780. </TabPane>
  1781. <TabPane tab="更改表格显示数据" key="2">
  1782. <div style={{ marginLeft: 10 }}>
  1783. <ChooseList
  1784. columns={this.state.columns}
  1785. changeFn={this.changeList}
  1786. changeList={this.state.changeList}
  1787. top={55}
  1788. margin={11}
  1789. />
  1790. </div>
  1791. </TabPane>
  1792. </Tabs>
  1793. <div className="patent-table">
  1794. <Spin spinning={this.state.loading}>
  1795. <Table
  1796. columns={
  1797. this.state.changeList
  1798. ? this.state.changeList
  1799. : this.state.columns
  1800. }
  1801. dataSource={this.state.dataSource}
  1802. pagination={this.state.pagination}
  1803. onRowClick={this.tableRowClick}
  1804. bordered
  1805. size="small"
  1806. />
  1807. </Spin>
  1808. {this.state.visible &&
  1809. <Modal
  1810. maskClosable={false}
  1811. className="customeDetails"
  1812. footer=""
  1813. width="1200px"
  1814. visible={this.state.visible}
  1815. onOk={this.visitOk}
  1816. onCancel={this.visitCancel}
  1817. >
  1818. <Tabs activeKey={this.state.activeKey} onChange={this.callback}>
  1819. <TabPane tab="订单详情" key="1">
  1820. <Form
  1821. layout="horizontal"
  1822. onSubmit={this.handleSubmit}
  1823. id="demand-form"
  1824. style={{ paddingBottom: "40px" }}
  1825. >
  1826. <Spin spinning={this.state.loading}>
  1827. <div className="clearfix">
  1828. <div style={{ position: "absolute", top: '-30px', left: '92px', zIndex: 10000 }}>
  1829. <OrderItemStatus deleteSign={this.state.deleteSign} />
  1830. </div>
  1831. <FormItem
  1832. className="half-item"
  1833. {...formItemLayout}
  1834. label="订单编号"
  1835. >
  1836. <span>{this.state.orderNo}</span>
  1837. </FormItem>
  1838. <FormItem
  1839. className="half-item"
  1840. {...formItemLayout}
  1841. label="合同编号"
  1842. >
  1843. <span>{this.state.contractNo}</span>
  1844. </FormItem>
  1845. <FormItem
  1846. className="half-item"
  1847. {...formItemLayout}
  1848. label="客户名称"
  1849. >
  1850. <span>{this.state.userName}</span>
  1851. <EnterpriseNameChange
  1852. type='journal'
  1853. style={{ marginLeft: 10 }}
  1854. enterpriseId={this.state.orderUid} />
  1855. </FormItem>
  1856. <FormItem
  1857. className="half-item"
  1858. {...formItemLayout}
  1859. label="销售类型"
  1860. >
  1861. <span>
  1862. {(["私有客户-", "签单客户-"][this.state.userType] || " ") +
  1863. (salesList[this.state.salesType] || "")}
  1864. {
  1865. this.state.other != null && this.state.other != "" &&
  1866. <Tooltip title={this.state.other}>
  1867. <span>
  1868. {"(" + this.state.other.toString().slice(0, 10) + (this.state.other.toString().length > 9 ? "...)" : ")")}
  1869. </span>
  1870. </Tooltip>
  1871. }
  1872. </span>
  1873. {/* <span>{(["私有客户-", "签单客户-"][this.state.userType] || " ") +
  1874. (salesList[this.state.salesType] || "")}
  1875. </span> */}
  1876. </FormItem>
  1877. <FormItem
  1878. className="half-item"
  1879. {...formItemLayout}
  1880. label="合同签订时间"
  1881. >
  1882. <span>{this.state.signDate}</span>
  1883. </FormItem>
  1884. <FormItem
  1885. className="half-item"
  1886. {...formItemLayout}
  1887. label="流程状态"
  1888. >
  1889. <span>
  1890. {getProcessStatus(this.state.processStatus, this.state.examineName, this.state.approval)}
  1891. </span>
  1892. <FlowChart
  1893. orderNo={this.state.orderNos}
  1894. />
  1895. </FormItem>
  1896. <FormItem
  1897. className="half-item"
  1898. {...formItemLayout}
  1899. label="结算状态"
  1900. >
  1901. <span>
  1902. {getLiquidationStatus(this.state.liquidationStatus)}
  1903. </span>
  1904. </FormItem>
  1905. <FormItem
  1906. className="half-item"
  1907. {...formItemLayout}
  1908. label="企业联系人"
  1909. >
  1910. <span>{this.state.contacts}</span>
  1911. </FormItem>
  1912. <FormItem
  1913. className="half-item"
  1914. {...formItemLayout}
  1915. label="联系人电话"
  1916. >
  1917. <span>{this.state.contactMobile}</span>
  1918. </FormItem>
  1919. <FormItem
  1920. className="half-item"
  1921. {...formItemLayout}
  1922. label="企业法人"
  1923. >
  1924. <span>{this.state.legalPerson}</span>
  1925. </FormItem>
  1926. <FormItem
  1927. className="half-item"
  1928. {...formItemLayout}
  1929. label="法人电话"
  1930. >
  1931. <span>{this.state.legalPersonTel}</span>
  1932. </FormItem>
  1933. <FormItem
  1934. className="half-item"
  1935. {...formItemLayout}
  1936. label="签单金额(万元)"
  1937. >
  1938. <span>{this.state.totalAmount}</span>
  1939. </FormItem>
  1940. <FormItem
  1941. className="half-item"
  1942. {...formItemLayout}
  1943. label="首付金额(万元)"
  1944. >
  1945. <span>{this.state.firstAmount}</span>
  1946. </FormItem>
  1947. <FormItem
  1948. className="half-item"
  1949. {...formItemLayout}
  1950. label="特批立项"
  1951. >
  1952. <span>
  1953. {getApprovedState(this.state.approval)}
  1954. {getApprovedType(this.state.type ? this.state.type.split(",").map(Number) : [], this.state.typeExplain, 1)}
  1955. </span>
  1956. </FormItem>
  1957. <FormItem
  1958. className="half-item"
  1959. {...formItemLayout}
  1960. label="已收款项(万元)"
  1961. >
  1962. <span>{this.state.settlementAmount}</span>
  1963. </FormItem>
  1964. <FormItem
  1965. className="half-item"
  1966. {...formItemLayout}
  1967. label="订单部门"
  1968. >
  1969. <span>{this.state.depName}</span>
  1970. </FormItem>
  1971. <FormItem
  1972. className="half-item"
  1973. {...formItemLayout}
  1974. label="是否外包"
  1975. >
  1976. {this.state.outsource}
  1977. </FormItem>
  1978. <div className="clearfix">
  1979. <FormItem
  1980. labelCol={{ span: 5 }}
  1981. wrapperCol={{ span: 19 }}
  1982. label="订单留言"
  1983. >
  1984. <p style={{ width: 500, wordWrap: "break-word" }}>
  1985. {this.state.orderRemarks}
  1986. </p>
  1987. </FormItem>
  1988. </div>
  1989. <div className="clearfix">
  1990. <div>
  1991. <FormItem
  1992. labelCol={{ span: 5 }}
  1993. wrapperCol={{ span: 19 }}
  1994. label="合同扫描件"
  1995. >
  1996. <div style={{ paddingTop: '10px', paddingBottom: '10px' }}>
  1997. {this.state.orgCodeUrl && this.state.visible ? <ImgList fileList={this.state.orgCodeUrl} ItemWidth={'96px'} /> : <div />}
  1998. </div>
  1999. <Button
  2000. style={{
  2001. float: "right",
  2002. marginRight: "140px",
  2003. marginTop: "20px",
  2004. }}
  2005. onClick={this.getOrderLog}
  2006. >
  2007. 查看订单日志
  2008. </Button>
  2009. </FormItem>
  2010. {/* 高新纯咨询合同说明详情 */}
  2011. <Gxczx
  2012. knowledgeServices={this.state.knowledgeServices}
  2013. auditServices={this.state.auditServices}
  2014. addDeductionServices={this.state.addDeductionServices}
  2015. knowledgeOther={this.state.knowledgeOther}
  2016. auditOther={this.state.auditOther}
  2017. addDeductionOther={this.state.addDeductionOther}
  2018. />
  2019. <FormItem
  2020. labelCol={{ span: 5 }}
  2021. wrapperCol={{ span: 19 }}
  2022. label="补充协议"
  2023. >
  2024. <div style={{ paddingTop: '10px', paddingBottom: '10px' }}>
  2025. {this.state.replenishUrl && this.state.visible ? <ImgList domId={'examine1'} fileList={this.state.replenishUrl} ItemWidth={'96px'} /> : <div />}
  2026. </div>
  2027. </FormItem>
  2028. </div>
  2029. </div>
  2030. <ContentUrl
  2031. processStatus={2}
  2032. domId={"examineContents"}
  2033. contentUrl={this.state.contentUrl}
  2034. imgId={"examineContentsImg"}
  2035. />
  2036. {/* 知识产权情况 */}
  2037. <Property
  2038. patentStatus={this.state.patentStatus}
  2039. />
  2040. <div className="clearfix">
  2041. <FormItem
  2042. className="half-item"
  2043. {...formItemLayout}
  2044. label="订单负责人"
  2045. >
  2046. <span>{this.state.salesmanName}</span>
  2047. </FormItem>
  2048. <FormItem
  2049. className="half-item"
  2050. {...formItemLayout}
  2051. label="订单负责人电话"
  2052. >
  2053. <span>{this.state.salesmanMobile}</span>
  2054. </FormItem>
  2055. </div>
  2056. <div className="clearfix">
  2057. <FormItem
  2058. className="half-item"
  2059. {...formItemLayout}
  2060. label="当前财务负责人"
  2061. >
  2062. <span>{this.state.nowFinance}</span>
  2063. </FormItem>
  2064. <FormItem
  2065. className="half-item"
  2066. {...formItemLayout}
  2067. label="当前财务负责人电话"
  2068. >
  2069. <span>{this.state.nowFinanceMobile}</span>
  2070. </FormItem>
  2071. </div>
  2072. <div className="clearfix">
  2073. <FormItem
  2074. className="half-item"
  2075. {...formItemLayout}
  2076. style={{ opacity: ".5" }}
  2077. label="原订单负责人"
  2078. >
  2079. <span>{this.state.oldSalesmanName}</span>
  2080. </FormItem>
  2081. <FormItem
  2082. className="half-item"
  2083. {...formItemLayout}
  2084. style={{ opacity: ".5" }}
  2085. label="原订单负责人电话"
  2086. >
  2087. <span>{this.state.oldSalesmanMobile}</span>
  2088. </FormItem>
  2089. </div>
  2090. <div className="clearfix">
  2091. <FormItem
  2092. className="half-item"
  2093. style={{ opacity: ".5" }}
  2094. {...formItemLayout}
  2095. label="实际财务操作人"
  2096. >
  2097. <span>{this.state.financeName}</span>
  2098. </FormItem>
  2099. <FormItem
  2100. className="half-item"
  2101. {...formItemLayout}
  2102. style={{ opacity: ".5" }}
  2103. label="实际财务操作人电话"
  2104. >
  2105. <span>{this.state.financeMobile}</span>
  2106. </FormItem>
  2107. </div>
  2108. {/* 协单人员 */}
  2109. <OrderCoor orderNo={this.state.orderNos} />
  2110. <div>
  2111. <span
  2112. style={{ marginLeft: "50px", fontSize: "20px" }}
  2113. >
  2114. 项目业务
  2115. </span>
  2116. {this.state.processStatus == 0 ? (
  2117. <Button
  2118. type="primary"
  2119. onClick={this.addDetailed}
  2120. style={{
  2121. float: "right",
  2122. marginRight: "50px",
  2123. marginBottom: "15px",
  2124. }}
  2125. >
  2126. 添加项目明细
  2127. </Button>
  2128. ) : (
  2129. ""
  2130. )}
  2131. </div>
  2132. <div className="patent-table">
  2133. <Spin spinning={this.state.loading}>
  2134. <Table
  2135. columns={this.state.columnsX}
  2136. dataSource={this.state.dataSourceX}
  2137. pagination={this.state.paginations}
  2138. onRowClick={this.tableRowClickX}
  2139. expandedRowRender={expandedRowRenderVip}
  2140. rowClassName={this.addRowColor}
  2141. bordered
  2142. size="small"
  2143. />
  2144. </Spin>
  2145. </div>
  2146. <div>
  2147. <span
  2148. style={{ marginLeft: "50px", fontSize: "20px" }}
  2149. >
  2150. 催款节点
  2151. </span>
  2152. <span
  2153. style={{
  2154. display: cuiDataList.length
  2155. ? "none"
  2156. : "inline-block",
  2157. marginLeft: 10,
  2158. color: "red",
  2159. }}
  2160. >
  2161. 金额总计(万元): {this.state.totalCui}
  2162. </span>
  2163. {this.state.processStatus == 0 ? (
  2164. <Button
  2165. type="primary"
  2166. onClick={this.addcontact}
  2167. style={{
  2168. float: "right",
  2169. marginRight: "50px",
  2170. marginBottom: "15px",
  2171. }}
  2172. >
  2173. 添加催款节点
  2174. </Button>
  2175. ) : (
  2176. ""
  2177. )}
  2178. </div>
  2179. <div className="clearfix">
  2180. <Spin spinning={this.state.loading}>
  2181. <Form layout="horizontal" id="demand-form">
  2182. <Table
  2183. pagination={false}
  2184. bordered
  2185. size="small"
  2186. columns={
  2187. cuiDataList.length
  2188. ? this.state.ContactsLists
  2189. : this.state.ContactsListsNew
  2190. }
  2191. dataSource={
  2192. cuiDataList.length
  2193. ? this.state.contactList
  2194. : this.state.contactListNew
  2195. }
  2196. />
  2197. <Col
  2198. span={24}
  2199. offset={9}
  2200. style={{ marginTop: "15px" }}
  2201. ></Col>
  2202. </Form>
  2203. </Spin>
  2204. </div>
  2205. <div
  2206. className="addSave"
  2207. style={{
  2208. marginTop: "15px",
  2209. display: "flex",
  2210. justifyContent: "center",
  2211. }}
  2212. >
  2213. <Button
  2214. type="primary"
  2215. onClick={() => {
  2216. this.setState({
  2217. agreeVisible: true,
  2218. reason: "",
  2219. });
  2220. }}
  2221. style={{ margin: "0 25px" }}
  2222. htmlType="submit"
  2223. >
  2224. 通过
  2225. </Button>
  2226. <Button
  2227. type="primary"
  2228. onClick={this.examNo}
  2229. style={{ margin: "0 25px" }}
  2230. htmlType="submit"
  2231. >
  2232. 驳回
  2233. </Button>
  2234. <Button
  2235. type="ghost"
  2236. onClick={this.visitCancel}
  2237. style={{ margin: "0 25px" }}
  2238. >
  2239. 取消
  2240. </Button>
  2241. {/*<Button className='warn-button' type="primary" onClick={this.outsourcing} style={{marginLeft:"50px"}}>通过不走总部</Button>
  2242. <p className='hint'>提示:高于总部价格,费用个人承担!</p>*/}
  2243. </div>
  2244. </div>
  2245. </Spin>
  2246. </Form>
  2247. </TabPane>
  2248. {/* <TabPane tab="外包(不走总部)" key="2">
  2249. <Spin spinning={this.state.loading}>
  2250. <div className="clearfix" style={{ marginTop: 10 }}>
  2251. <FormItem
  2252. className="half-item"
  2253. {...formItemLayout}
  2254. label={
  2255. <span>
  2256. <strong style={{ color: "#f00" }}>*</strong>外包公司
  2257. </span>
  2258. }
  2259. >
  2260. <Input
  2261. value={this.state.companyName}
  2262. onChange={(e) => {
  2263. this.setState({
  2264. companyName: e.target.value,
  2265. });
  2266. }}
  2267. placeholder="请填写外包公司名称"
  2268. />
  2269. </FormItem>
  2270. <span className="tip">如多个公司,请用间隔</span>
  2271. </div>
  2272. <div className="clearfix">
  2273. <FormItem
  2274. className="half-item"
  2275. {...formItemLayout}
  2276. label={
  2277. <span>
  2278. <strong style={{ color: "#f00" }}>*</strong>
  2279. 单价(万元)
  2280. </span>
  2281. }
  2282. >
  2283. <Input
  2284. value={this.state.unitPrice}
  2285. onChange={(e) => {
  2286. this.setState({
  2287. unitPrice: e.target.value,
  2288. });
  2289. }}
  2290. placeholder="请填写单价"
  2291. />
  2292. </FormItem>
  2293. </div>
  2294. <div className="clearfix">
  2295. <FormItem
  2296. className="half-item"
  2297. {...formItemLayout}
  2298. label={
  2299. <span>
  2300. <strong style={{ color: "#f00" }}>*</strong>数量(个)
  2301. </span>
  2302. }
  2303. >
  2304. <Input
  2305. value={this.state.unitNumber}
  2306. onChange={(e) => {
  2307. this.setState({
  2308. unitNumber: e.target.value,
  2309. });
  2310. }}
  2311. placeholder="请填写数量"
  2312. />
  2313. </FormItem>
  2314. </div>
  2315. <div className="clearfix">
  2316. <FormItem
  2317. className="half-item"
  2318. {...formItemLayout}
  2319. label={
  2320. <span>
  2321. <strong style={{ color: "#f00" }}>*</strong>
  2322. 总金额(万元)
  2323. </span>
  2324. }
  2325. >
  2326. <Input
  2327. value={this.state.amount}
  2328. onChange={(e) => {
  2329. this.setState({
  2330. amount: e.target.value,
  2331. });
  2332. }}
  2333. placeholder="请填写本次外包公司的价格"
  2334. />
  2335. </FormItem>
  2336. </div>
  2337. <div className="clearfix">
  2338. <FormItem
  2339. className="half-item"
  2340. style={{ height: "auto" }}
  2341. {...formItemLayout}
  2342. label={
  2343. <span>
  2344. <strong style={{ color: "#f00" }}>*</strong>备注
  2345. </span>
  2346. }
  2347. >
  2348. <TextArea
  2349. rows={4}
  2350. value={this.state.outsourceRemarks}
  2351. onChange={(e) => {
  2352. this.setState({
  2353. outsourceRemarks: e.target.value,
  2354. });
  2355. }}
  2356. placeholder="请输入备注"
  2357. />
  2358. </FormItem>
  2359. </div>
  2360. <p
  2361. className="tip"
  2362. style={{
  2363. paddingBottom: "12px",
  2364. width: "240px",
  2365. marginLeft: "145px",
  2366. }}
  2367. >
  2368. 首次派单项目,需上传协议,第2次起,同项目,只需写外包公司
  2369. </p>
  2370. <div className="clearfix">
  2371. <FormItem
  2372. labelCol={{ span: 4 }}
  2373. wrapperCol={{ span: 18 }}
  2374. label={
  2375. <span>
  2376. <strong style={{ color: "#f00" }}>*</strong>
  2377. 合同/协议扫描件
  2378. <span style={{ color: "#f00" }}>(外包合同)</span>
  2379. </span>
  2380. }
  2381. >
  2382. <PicturesWall
  2383. fileList={this.getOrgCodeUrl}
  2384. pictureUrl={this.state.pictureUrl}
  2385. />
  2386. <p>请上传与外包公司签订的合同协议</p>
  2387. <p>图片建议:要清晰。</p>
  2388. </FormItem>
  2389. </div>
  2390. <div className="clearfix">
  2391. <div
  2392. style={{ display: "inline-black", textAlign: "center" }}
  2393. >
  2394. <Button type="primary" onClick={this.sureOut}>
  2395. 确认发起外包,不通过总部
  2396. </Button>
  2397. <p className="tip">提示:高于总部价格,费用个人承担</p>
  2398. </div>
  2399. </div>
  2400. </Spin>
  2401. </TabPane> */}
  2402. </Tabs>
  2403. </Modal>}
  2404. {this.state.noVisible ? <Modal
  2405. maskClosable={false}
  2406. visible={this.state.noVisible}
  2407. onOk={this.handleOk}
  2408. onCancel={this.noCancel}
  2409. width="400px"
  2410. title={"拒绝理由"}
  2411. footer=""
  2412. className="admin-desc-content"
  2413. confirmLoading={this.state.confirmLoading}
  2414. >
  2415. <Form layout="horizontal" id="demand-form">
  2416. <Spin spinning={this.state.loading}>
  2417. <div className="clearfix">
  2418. <FormItem
  2419. labelCol={{ span: 4 }}
  2420. wrapperCol={{ span: 16 }}
  2421. label="拒绝理由"
  2422. >
  2423. <Input
  2424. type="textarea"
  2425. placeholder="请输入拒绝理由"
  2426. rows={4}
  2427. value={this.state.reason}
  2428. onChange={(e) => {
  2429. this.setState({ reason: e.target.value });
  2430. }}
  2431. />
  2432. </FormItem>
  2433. </div>
  2434. <div className="clearfix">
  2435. <Button
  2436. className="cancel"
  2437. type="primary"
  2438. onClick={this.examOks}
  2439. style={{ marginLeft: "50px" }}
  2440. htmlType="submit"
  2441. loading={this.state.aloading}
  2442. >
  2443. 确定
  2444. </Button>
  2445. <Button
  2446. className="cancel"
  2447. type="ghost"
  2448. onClick={this.noCancel}
  2449. style={{ marginLeft: "50px" }}
  2450. >
  2451. 取消
  2452. </Button>
  2453. </div>
  2454. </Spin>
  2455. </Form>
  2456. </Modal> : <div />}
  2457. {this.state.agreeVisible ? <Modal
  2458. maskClosable={false}
  2459. visible={this.state.agreeVisible}
  2460. onOk={(e) => {
  2461. this.setState({
  2462. agreeVisible: false,
  2463. });
  2464. }}
  2465. onCancel={(e) => {
  2466. this.setState({
  2467. agreeVisible: false,
  2468. });
  2469. }}
  2470. width="400px"
  2471. title={"同意备注"}
  2472. footer=""
  2473. className="admin-desc-content"
  2474. confirmLoading={this.state.confirmLoading}
  2475. >
  2476. <Form layout="horizontal" id="demand-form">
  2477. <Spin spinning={this.state.loading}>
  2478. <div className="clearfix">
  2479. <FormItem
  2480. labelCol={{ span: 4 }}
  2481. wrapperCol={{ span: 16 }}
  2482. label="同意理由"
  2483. >
  2484. <Input
  2485. type="textarea"
  2486. placeholder="请输入同意理由"
  2487. rows={4}
  2488. value={this.state.reason}
  2489. onChange={(e) => {
  2490. this.setState({ reason: e.target.value });
  2491. }}
  2492. />
  2493. </FormItem>
  2494. </div>
  2495. <div className="clearfix">
  2496. <Button
  2497. className="cancel"
  2498. type="primary"
  2499. onClick={(e) => {
  2500. if (this.state.outsource == "是") {
  2501. this.showDeleteConfirm(this.examOk);
  2502. } else {
  2503. this.examOk();
  2504. }
  2505. }}
  2506. style={{ marginLeft: "50px" }}
  2507. htmlType="submit"
  2508. loading={this.state.aloading}
  2509. >
  2510. 确定
  2511. </Button>
  2512. <Button
  2513. className="cancel"
  2514. type="ghost"
  2515. onClick={(e) => {
  2516. this.setState({
  2517. agreeVisible: false,
  2518. });
  2519. }}
  2520. style={{ marginLeft: "50px" }}
  2521. >
  2522. 取消
  2523. </Button>
  2524. </div>
  2525. </Spin>
  2526. </Form>
  2527. </Modal> : <div />}
  2528. {/* <Modal
  2529. visible={this.state.rizhivisible}
  2530. className="admin-desc-content"
  2531. width="800px"
  2532. maskClosable={false}
  2533. title="订单日志"
  2534. footer={null}
  2535. onCancel={this.closeOrderLog}
  2536. >
  2537. <div className="patent-table">
  2538. <Spin spinning={this.state.loading}>
  2539. <Table
  2540. columns={this.state.columnsrizhi}
  2541. dataSource={this.state.dataSourcerizhi}
  2542. pagination={false}
  2543. />
  2544. </Spin>
  2545. </div>
  2546. </Modal> */}
  2547. <OrderRiZi
  2548. dataSourcerizhi={this.state.dataSourcerizhi}
  2549. closeOrderLog={this.closeOrderLog}
  2550. visible={this.state.rizhivisible}
  2551. loading={this.state.loading}
  2552. />
  2553. </div>
  2554. <textarea id="copyText" style={{ opacity: 0 }} />
  2555. {this.state.addnextVisible &&
  2556. <NewEditProject
  2557. readOnly={this.state.dataInfor && Object.keys(this.state.dataInfor).length > 0 && this.state.processStatus !== 0}
  2558. orderNo={this.state.orderNo}
  2559. visible={this.state.addnextVisible}
  2560. dataInfor={this.state.dataInfor}
  2561. onCancel={this.nextCancel}
  2562. />
  2563. // <ProjectDetailsReadOnly
  2564. // infor={this.state.dataInfor}
  2565. // visible={this.state.addnextVisible}
  2566. // onCancel={this.nextCancel}
  2567. // />
  2568. }
  2569. </div>
  2570. );
  2571. },
  2572. })
  2573. );
  2574. export default IntentionCustomer;