examine.jsx 53 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632
  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. } from "antd";
  16. import $ from "jquery/src/ajax";
  17. import moment from "moment";
  18. import {
  19. getLiquidationStatus,
  20. getApprovedState,
  21. getProcessStatus,
  22. splitUrl,
  23. getjiedian,
  24. getboutique,
  25. getCuikuan,
  26. getProjectStatus,
  27. moneyVerify
  28. } from "@/tools.js";
  29. import "./customer.less";
  30. //图片组件
  31. const PicturesWall = React.createClass({
  32. getInitialState() {
  33. return {
  34. previewVisible: false,
  35. previewImage: "",
  36. fileList: this.props.pictureUrl
  37. };
  38. },
  39. handleCancel() {
  40. this.setState({
  41. previewVisible: false
  42. });
  43. },
  44. handlePreview(file) {
  45. this.setState({
  46. previewImage: file.url || file.thumbUrl,
  47. previewVisible: true
  48. });
  49. },
  50. handleChange(info) {
  51. let fileList = info.fileList;
  52. this.setState({
  53. fileList
  54. });
  55. this.props.fileList(fileList);
  56. },
  57. componentWillReceiveProps(nextProps) {
  58. this.state.fileList = nextProps.pictureUrl;
  59. this.state.pojectApplicationUrl = undefined;
  60. },
  61. render() {
  62. const { previewVisible, previewImage, fileList } = this.state;
  63. const uploadButton = (
  64. <div>
  65. <Icon type="plus" />
  66. <div className="ant-upload-text">点击上传</div>
  67. </div>
  68. );
  69. return (
  70. <div style={{ display: "inline-block" }}>
  71. <Upload
  72. action={
  73. globalConfig.context + "/api/admin/outsourceOrg/uploadOutsourceFile"
  74. }
  75. data={{ sign: "order_outsource" }}
  76. listType="picture-card"
  77. fileList={fileList}
  78. onPreview={this.handlePreview}
  79. onChange={this.handleChange}
  80. >
  81. {fileList.length >= 18 ? null : uploadButton}
  82. </Upload>
  83. <Modal
  84. maskClosable={false}
  85. visible={previewVisible}
  86. footer={null}
  87. onCancel={this.handleCancel}
  88. >
  89. <img alt="example" style={{ width: "100%" }} src={previewImage} />
  90. </Modal>
  91. </div>
  92. );
  93. }
  94. });
  95. const IntentionCustomer = Form.create()(
  96. React.createClass({
  97. loadData(pageNo) {
  98. this.setState({
  99. visitModul: false,
  100. loading: true,
  101. ispage: pageNo,
  102. modalVisible: false
  103. });
  104. $.ajax({
  105. method: "get",
  106. dataType: "json",
  107. crossDomain: false,
  108. url: globalConfig.context + "/api/admin/newOrder/orderNewList",
  109. data: {
  110. pageNo: pageNo || 1,
  111. pageSize: this.state.pagination.pageSize,
  112. specially: 1, //审核列表
  113. name: this.state.customerName, //名称
  114. orderNo: this.state.orderNoSearch, //订单编号
  115. starTime: this.state.releaseDate[0], //开始时间
  116. endTime: this.state.releaseDate[1] //结束时间
  117. },
  118. success: function(data) {
  119. let theArr = [];
  120. if (data.error.length || data.data.list == "") {
  121. if (data.error && data.error.length) {
  122. message.warning(data.error[0].message);
  123. }
  124. } else {
  125. for (let i = 0; i < data.data.list.length; i++) {
  126. let thisdata = data.data.list[i];
  127. theArr.push({
  128. key: i,
  129. id: thisdata.id, //用户ID
  130. orderNo: thisdata.orderNo, //订单编号
  131. totalAmount: thisdata.totalAmount, //签单金额
  132. processStatus: thisdata.processStatus, //流程状态
  133. liquidationStatus: thisdata.liquidationStatus, //结算状态
  134. approval: thisdata.approval, //特批状态
  135. signDate: thisdata.signDate, //签单时间
  136. userName: thisdata.userName, //客户名称
  137. salesmanName: thisdata.salesmanName, //营销员名称
  138. financeName: thisdata.financeName, //财务名称
  139. createDate: thisdata.createDate, //下单时间
  140. depName: thisdata.depName,
  141. orderStatus: thisdata.orderStatus
  142. });
  143. }
  144. this.state.pagination.total = data.data.totalCount;
  145. this.state.pagination.current = data.data.pageNo;
  146. }
  147. if (data.data && data.data.list && !data.data.list.length) {
  148. this.state.pagination.total = 0;
  149. }
  150. this.setState({
  151. dataSource: theArr,
  152. pageNo: pageNo,
  153. pagination: this.state.pagination,
  154. selectedRowKeys: []
  155. });
  156. }.bind(this)
  157. }).always(
  158. function() {
  159. this.setState({
  160. loading: false
  161. });
  162. }.bind(this)
  163. );
  164. },
  165. getInitialState() {
  166. return {
  167. page: 1,
  168. releaseDate: [],
  169. selectedRowKeys: [],
  170. pictureUrl: [],
  171. attachmentUrl: [],
  172. paginations: false,
  173. activeKey: "1",
  174. confirmLoading: false,
  175. aloading: false,
  176. pagination: {
  177. defaultCurrent: 1,
  178. defaultPageSize: 10,
  179. showQuickJumper: true,
  180. pageSize: 10,
  181. onChange: function(page) {
  182. this.loadData(page);
  183. }.bind(this),
  184. showTotal: function(total) {
  185. return "共" + total + "条数据";
  186. }
  187. },
  188. columns: [
  189. {
  190. title: "订单编号",
  191. dataIndex: "orderNo",
  192. key: "orderNo"
  193. },
  194. {
  195. title: "下单时间",
  196. dataIndex: "createDate",
  197. key: "createTime"
  198. },
  199. {
  200. title: "合同签订时间",
  201. dataIndex: "signDate",
  202. key: "signDate"
  203. },
  204. {
  205. title: "客户名称",
  206. dataIndex: "userName",
  207. key: "userName",
  208. render: text => {
  209. return text && text.length > 9 ? text.substr(0, 9) + "..." : text;
  210. }
  211. },
  212. {
  213. title: "流程状态",
  214. dataIndex: "processStatus",
  215. key: "processStatus",
  216. render: text => {
  217. return getProcessStatus(text);
  218. }
  219. },
  220. {
  221. title: "订单部门",
  222. dataIndex: "depName",
  223. key: "depName"
  224. },
  225. {
  226. title: "签单金额(万元)",
  227. dataIndex: "totalAmount",
  228. key: "totalAmount"
  229. },
  230. {
  231. title: "结算状态",
  232. dataIndex: "liquidationStatus",
  233. key: "liquidationStatus",
  234. render: text => {
  235. return getLiquidationStatus(text);
  236. }
  237. },
  238. {
  239. title: "是否特批",
  240. dataIndex: "approval",
  241. key: "approval",
  242. render: text => {
  243. return getApprovedState(text);
  244. }
  245. },
  246. {
  247. title: "订单负责人",
  248. dataIndex: "salesmanName",
  249. key: "salesmanName"
  250. },
  251. {
  252. title: "财务负责人",
  253. dataIndex: "financeName",
  254. key: "financeName"
  255. }
  256. ],
  257. data: [],
  258. dataSource: [],
  259. columnsX: [
  260. {
  261. title: "业务项目名称",
  262. dataIndex: "commodityName",
  263. key: "commodityName"
  264. },
  265. {
  266. title: "项目类别",
  267. dataIndex: "cname",
  268. key: "cname"
  269. },
  270. {
  271. title: "项目数量",
  272. dataIndex: "commodityQuantity",
  273. key: "commodityQuantity"
  274. },
  275. {
  276. title: "金额(万元)",
  277. dataIndex: "commodityPrice",
  278. key: "commodityPrice"
  279. },
  280. {
  281. title: "负责人",
  282. dataIndex: "contacts",
  283. key: "contacts"
  284. },
  285. {
  286. title: "负责人电话",
  287. dataIndex: "contactsMobile",
  288. key: "contactsMobile"
  289. },
  290. {
  291. title: "项目状态",
  292. dataIndex: "projectStatus",
  293. key: "projectStatus",
  294. render: text => {
  295. return getProjectStatus(text);
  296. }
  297. },
  298. {
  299. title: "主要项目",
  300. dataIndex: "main",
  301. key: "main",
  302. render: text => {
  303. return text ? "是" : "否";
  304. }
  305. },
  306. {
  307. title: "项目说明",
  308. dataIndex: "taskComment",
  309. key: "taskComment",
  310. render: text => {
  311. return text && text.length > 8 ? text.substr(0, 8) + "…" : text;
  312. }
  313. }
  314. ],
  315. columnsrizhi: [
  316. {
  317. title: "流程",
  318. dataIndex: "processName",
  319. key: "processName"
  320. },
  321. {
  322. title: "操作人",
  323. dataIndex: "adminName",
  324. key: "adminName"
  325. },
  326. {
  327. title: "时间",
  328. dataIndex: "createDate",
  329. key: "createDate"
  330. }
  331. ],
  332. dataSourceX: [],
  333. ContactsLists: [
  334. {
  335. title: "催款科目",
  336. dataIndex: "dunSubject",
  337. key: "dunSubject",
  338. render: text => {
  339. return getjiedian(text);
  340. }
  341. },
  342. {
  343. title: "金额(万)",
  344. dataIndex: "money",
  345. key: "money"
  346. },
  347. {
  348. title: "催款状态",
  349. dataIndex: "dunStatus",
  350. key: "dunStatus",
  351. render: text => {
  352. return getCuikuan(text);
  353. }
  354. }
  355. ]
  356. };
  357. },
  358. //页面加载函数
  359. componentWillMount() {
  360. this.loadData();
  361. },
  362. //整行点击
  363. tableRowClick(record) {
  364. this.setState({
  365. visible: true,
  366. orderStatus: record.orderStatus,
  367. id: record.id
  368. });
  369. this.xiangqing(record.orderNo);
  370. this.xiangmu(record.orderNo);
  371. this.jiedian(record.orderNo);
  372. },
  373. //点击打卡项目详情
  374. tableRowClickX(record) {
  375. this.setState({
  376. jid: record.id, //项目ID
  377. kid: record.commodityId, //商品ID
  378. commodityName: record.commodityName, //金额
  379. commodityPrice: record.commodityPrice, //金额
  380. commodityQuantity: record.commodityQuantity, //数量
  381. taskComment: record.taskComment, //备注
  382. main: record.main.toString(), //是否为主要
  383. addnextVisible: true,
  384. addState: 0
  385. });
  386. },
  387. //项目详情关闭
  388. nextCancel() {
  389. this.setState({
  390. addnextVisible: false
  391. });
  392. },
  393. //订单详情
  394. xiangqing(orderNos) {
  395. $.ajax({
  396. method: "get",
  397. dataType: "json",
  398. crossDomain: false,
  399. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  400. data: {
  401. orderNo: orderNos
  402. },
  403. success: function(data) {
  404. if (data.error.length || data.data.list == "") {
  405. if (data.error && data.error.length) {
  406. message.warning(data.error[0].message);
  407. }
  408. } else {
  409. let thisdata = data.data;
  410. this.setState({
  411. orderNo: thisdata.orderNo, //订单编号
  412. contractNo: thisdata.contractNo, //合同编号
  413. userName: thisdata.userName, //客户名称
  414. signDate: thisdata.signDate, //签单时间
  415. processStatus: thisdata.processStatus, //流程状态
  416. liquidationStatus: thisdata.liquidationStatus, //结算状态
  417. contacts: thisdata.contacts, //企业联系人
  418. contactMobile: thisdata.contactMobile, //联系人电话
  419. legalPerson: thisdata.legalPerson, //法人
  420. legalPersonTel: thisdata.legalPersonTel, //法人电话
  421. firstAmount: thisdata.firstAmount, //签单金额
  422. totalAmount: thisdata.totalAmount, //首付金额
  423. approval: thisdata.approval, //特批状态
  424. settlementAmount: thisdata.settlementAmount, //已收款项
  425. orderRemarks: thisdata.orderRemarks, //订单留言
  426. orgCodeUrl: thisdata.contractPictureUrl
  427. ? splitUrl(
  428. thisdata.contractPictureUrl,
  429. ",",
  430. globalConfig.avatarHost + "/upload"
  431. )
  432. : [], //图片地址
  433. salesmanName: thisdata.salesmanName, //营销员名称
  434. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  435. financeName: thisdata.financeName, //财务名称
  436. financeMobile: thisdata.financeMobile, //财务电话
  437. depName: thisdata.depName
  438. });
  439. }
  440. }.bind(this)
  441. }).always(
  442. function() {
  443. this.setState({
  444. loading: false
  445. });
  446. }.bind(this)
  447. );
  448. },
  449. //项目列表
  450. xiangmu(orderNos) {
  451. $.ajax({
  452. method: "get",
  453. dataType: "json",
  454. crossDomain: false,
  455. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  456. data: {
  457. orderNo: orderNos
  458. },
  459. success: function(data) {
  460. let theArr = [];
  461. if (data.error.length || data.data.list == "") {
  462. if (data.error && data.error.length) {
  463. message.warning(data.error[0].message);
  464. }
  465. } else {
  466. for (let i = 0; i < data.data.length; i++) {
  467. let thisdata = data.data[i];
  468. theArr.push({
  469. key: i,
  470. id: thisdata.id,
  471. orderNo: thisdata.orderNo, //订单编号
  472. commodityId: thisdata.commodityId, //项目ID
  473. commodityName: thisdata.commodityName, //项目名称
  474. cname: thisdata.cname, //项目类别
  475. commodityPrice: thisdata.commodityPrice, //项目价格
  476. commodityQuantity: thisdata.commodityQuantity, //项目数量
  477. main: thisdata.main, //是否为主要任务
  478. taskComment: thisdata.taskComment, //任务说明
  479. contacts: thisdata.contacts, //联系人
  480. contactsMobile: thisdata.contactsMobile, //联系人电话
  481. projectStatus: thisdata.projectStatus //项目状态
  482. });
  483. }
  484. }
  485. this.setState({
  486. dataSourceX: theArr
  487. });
  488. }.bind(this)
  489. }).always(
  490. function() {
  491. this.setState({
  492. loading: false
  493. });
  494. }.bind(this)
  495. );
  496. },
  497. rizhi() {
  498. console.log(this.state.orderNo);
  499. this.setState({
  500. loading: true
  501. });
  502. $.ajax({
  503. method: "get",
  504. dataType: "json",
  505. crossDomain: false,
  506. url: "/api/admin/newOrder/selectOrderLog",
  507. data: {
  508. orderNo: this.state.orderNo
  509. },
  510. success: function(data) {
  511. let theArr = [];
  512. let thisData = data.data;
  513. if (!thisData.length) {
  514. if (data.error && data.error.length) {
  515. message.warning(data.error[0].message);
  516. }
  517. thisData = {};
  518. } else {
  519. for (let i = 0; i < data.data.length; i++) {
  520. let thisdata = data.data[i];
  521. theArr.push({
  522. processName: thisdata.processName,
  523. adminName: thisdata.adminName,
  524. createDate: thisdata.createDate
  525. });
  526. }
  527. }
  528. this.setState({
  529. dataSourcerizhi: theArr
  530. });
  531. }.bind(this)
  532. }).always(
  533. function() {
  534. this.setState({
  535. loading: false
  536. });
  537. }.bind(this)
  538. );
  539. },
  540. getOrderLog() {
  541. this.setState({
  542. rizhivisible: true
  543. });
  544. this.rizhi();
  545. },
  546. closeOrderLog() {
  547. this.setState({
  548. rizhivisible: false
  549. });
  550. },
  551. //节点列表
  552. jiedian(orderNos) {
  553. $.ajax({
  554. method: "get",
  555. dataType: "json",
  556. crossDomain: false,
  557. url: globalConfig.context + "/api/admin/newOrder/selectOrderDun",
  558. data: {
  559. orderNo: orderNos
  560. },
  561. success: function(data) {
  562. let theArr = [];
  563. let thisData = [];
  564. if (data.error.length || data.data.list == "") {
  565. if (data.error && data.error.length) {
  566. message.warning(data.error[0].message);
  567. }
  568. } else {
  569. for (let i = 0; i < data.data.length; i++) {
  570. thisData = data.data[i];
  571. theArr.push({
  572. key: i,
  573. dunSubject: thisData.dunSubject
  574. ? thisData.dunSubject.toString()
  575. : "", //催款科目
  576. id: thisData.id, //节点Id
  577. money: thisData.money, //催款金额
  578. dunStatus: thisData.dunStatus //催款状态
  579. });
  580. }
  581. this.setState({
  582. contactList: theArr
  583. });
  584. }
  585. }.bind(this)
  586. }).always(
  587. function() {
  588. this.setState({
  589. loading: false
  590. });
  591. }.bind(this)
  592. );
  593. },
  594. //审核通过
  595. examOk() {
  596. $.ajax({
  597. method: "post",
  598. dataType: "json",
  599. crossDomain: false,
  600. url: globalConfig.context + "/api/admin/newOrder/auditOrderNew",
  601. data: {
  602. orderNo: this.state.orderNo,
  603. orderStatus: 2
  604. },
  605. success: function(data) {
  606. if (data.error.length || data.data.list == "") {
  607. if (data.error && data.error.length) {
  608. message.warning(data.error[0].message);
  609. }
  610. } else {
  611. message.success("该订单已通过审核~");
  612. this.setState({
  613. visible: false
  614. });
  615. this.reset();
  616. }
  617. }.bind(this)
  618. }).always(
  619. function() {
  620. this.setState({
  621. loading: false
  622. });
  623. }.bind(this)
  624. );
  625. },
  626. //通过发给外包
  627. outsourcing() {
  628. $.ajax({
  629. method: "post",
  630. dataType: "json",
  631. crossDomain: false,
  632. url: globalConfig.context + "/api/admin/newOrder/auditOrderNew",
  633. data: {
  634. orderNo: this.state.orderNo,
  635. orderStatus: 2,
  636. outsource: 1
  637. },
  638. success: function(data) {
  639. if (data.error.length || data.data.list == "") {
  640. if (data.error && data.error.length) {
  641. message.warning(data.error[0].message);
  642. }
  643. } else {
  644. message.success("该订单已通过审核~");
  645. this.setState({
  646. visible: false
  647. });
  648. this.reset();
  649. }
  650. }.bind(this)
  651. }).always(
  652. function() {
  653. this.setState({
  654. loading: false
  655. });
  656. }.bind(this)
  657. );
  658. },
  659. //审核不通过
  660. examOks() {
  661. this.setState({
  662. aloading: true
  663. });
  664. $.ajax({
  665. method: "post",
  666. dataType: "json",
  667. crossDomain: false,
  668. url: globalConfig.context + "/api/admin/newOrder/auditOrderNew",
  669. data: {
  670. orderNo: this.state.orderNo,
  671. orderStatus: 3,
  672. reason: this.state.reason
  673. },
  674. success: function(data) {
  675. if (data.error.length || data.data.list == "") {
  676. if (data.error && data.error.length) {
  677. message.warning(data.error[0].message);
  678. this.setState({
  679. aloading: true
  680. });
  681. }
  682. } else {
  683. message.success("该订单已被拒绝~");
  684. this.setState({
  685. visible: false,
  686. aloading: false,
  687. noVisible: false,
  688. reason: ""
  689. });
  690. this.reset();
  691. }
  692. }.bind(this)
  693. }).always(
  694. function() {
  695. this.setState({
  696. loading: false
  697. });
  698. }.bind(this)
  699. );
  700. },
  701. //点击拒绝
  702. examNo() {
  703. this.setState({
  704. noVisible: true
  705. });
  706. },
  707. callback(key) {
  708. let url = window.location.href.substring(7);
  709. this.setState({
  710. activeKey: key
  711. });
  712. if (this.state.pictureUrl.length) {
  713. let picArr = [];
  714. this.state.pictureUrl.map(function(item) {
  715. if (
  716. item.response &&
  717. item.response.data &&
  718. item.response.data.length
  719. ) {
  720. picArr.push(item.response.data);
  721. }
  722. });
  723. }
  724. if (key === "2") {
  725. this.setState({
  726. loading: true
  727. });
  728. $.ajax({
  729. method: "get",
  730. dataType: "json",
  731. crossDomain: false,
  732. url:
  733. globalConfig.context +
  734. "/api/admin/outsourceOrg/orderOutsourceDtails",
  735. data: {
  736. orderNo: this.state.orderNo
  737. },
  738. success: function(data) {
  739. if (data.data) {
  740. let thisdata = data.data;
  741. this.setState({
  742. id: thisdata.id,
  743. createTimes: thisdata.createTimes,
  744. auditTimes: thisdata.auditTimes,
  745. remarks: thisdata.remarks,
  746. attachmentUrl: thisdata.attachmentUrl
  747. ? splitUrl(
  748. thisdata.attachmentUrl,
  749. ",",
  750. globalConfig.avatarHost + "/upload",
  751. url
  752. )
  753. : [],
  754. fileUrl: thisdata.attachmentUrl
  755. ? splitUrl(
  756. thisdata.attachmentUrl,
  757. ",",
  758. globalConfig.avatarHost + "/upload",
  759. url
  760. )
  761. : [],
  762. pictureUrl: thisdata.pictureUrl
  763. ? splitUrl(
  764. thisdata.pictureUrl,
  765. ",",
  766. globalConfig.avatarHost + "/upload",
  767. url
  768. )
  769. : [], //图片地址
  770. amount: thisdata.amount,
  771. companyName: thisdata.companyName,
  772. outsourceRemarks: thisdata.outsourceRemarks,
  773. unitNumber: thisdata.unitNumber,
  774. unitPrice: thisdata.unitPrice
  775. });
  776. }
  777. }.bind(this)
  778. }).always(
  779. function() {
  780. this.setState({
  781. loading: false
  782. });
  783. }.bind(this)
  784. );
  785. }
  786. },
  787. getUrl(url) {
  788. let theorgCodeUrl = [];
  789. if (url.length) {
  790. let picArr = [];
  791. url.map(function(item) {
  792. if (
  793. item.response &&
  794. item.response.data &&
  795. item.response.data.length
  796. ) {
  797. picArr.push(item.response.data);
  798. }
  799. });
  800. theorgCodeUrl = picArr.join(",");
  801. }
  802. return theorgCodeUrl;
  803. },
  804. sureOut() {
  805. if (!this.state.companyName) {
  806. message.warning("公司名称不能为空");
  807. return;
  808. }
  809. if (!this.state.unitPrice) {
  810. message.warning("单价不能为空");
  811. return;
  812. }
  813. if(moneyVerify(this.state.unitPrice)) {
  814. return
  815. }
  816. if (!this.state.unitNumber) {
  817. message.warning("数量不能为空");
  818. return;
  819. }
  820. if (!this.state.amount) {
  821. message.warning("总金额不能为空");
  822. return;
  823. }
  824. if (moneyVerify(this.state.amount)) {
  825. return;
  826. }
  827. if (!this.state.outsourceRemarks) {
  828. message.warning("备注不能为空");
  829. return;
  830. }
  831. if (this.state.pictureUrl.length === 0) {
  832. message.warning("合同扫描件不能为空");
  833. return;
  834. }
  835. $.ajax({
  836. method: "POST",
  837. dataType: "json",
  838. crossDomain: false,
  839. url: globalConfig.context + "/api/admin/outsourceOrg/auditOutsource",
  840. data: {
  841. id: this.state.id,
  842. orderNo: this.state.orderNo,
  843. companyName: this.state.companyName,
  844. amount: this.state.amount,
  845. outsourceRemarks: this.state.outsourceRemarks,
  846. unitNumber: this.state.unitNumber,
  847. unitPrice: this.state.unitPrice,
  848. attachmentUrl: this.getUrl(this.state.attachmentUrl).length
  849. ? this.getUrl(this.state.attachmentUrl)
  850. : "",
  851. orderStatus: 2,
  852. pictureUrl: this.getUrl(this.state.pictureUrl).length
  853. ? this.getUrl(this.state.pictureUrl)
  854. : ""
  855. }
  856. }).done(
  857. function(data) {
  858. this.setState({
  859. loading: false
  860. });
  861. if (!data.error.length) {
  862. message.success("发起成功!");
  863. this.outReset();
  864. this.visitCancel();
  865. } else {
  866. message.warning(data.error[0].message);
  867. }
  868. }.bind(this)
  869. );
  870. },
  871. //关闭输入理由框
  872. noCancel() {
  873. this.setState({
  874. noVisible: false,
  875. aloading: false,
  876. reason: ""
  877. });
  878. },
  879. //搜索
  880. search() {
  881. this.setState({
  882. //signBillVisible:false
  883. });
  884. this.loadData();
  885. },
  886. //重置
  887. reset() {
  888. this.setState({
  889. signBillVisible: false
  890. });
  891. this.state.orderNo = "";
  892. this.state.customerName = "";
  893. this.state.releaseDate[0] = undefined;
  894. this.state.releaseDate[1] = undefined;
  895. this.state.approval = undefined;
  896. this.loadData(1);
  897. },
  898. outReset() {
  899. this.setState({
  900. companyName: "",
  901. amount: "",
  902. unitPrice: "",
  903. unitNumber: "",
  904. outsourceRemarks: "",
  905. attachmentUrl: [],
  906. pictureUrl: []
  907. });
  908. },
  909. resets() {
  910. this.state.orderNo = "";
  911. this.state.customerName = "";
  912. this.state.releaseDate[0] = undefined;
  913. this.state.releaseDate[1] = undefined;
  914. },
  915. getOrgCodeUrl(e) {
  916. this.setState({ pictureUrl: e });
  917. },
  918. //关闭详情
  919. visitCancel() {
  920. this.setState(
  921. {
  922. visible: false
  923. },
  924. () => {
  925. this.setState({
  926. activeKey: "1"
  927. });
  928. }
  929. );
  930. this.resets();
  931. this.loadData();
  932. },
  933. visitOk() {
  934. this.setState({
  935. visible: false
  936. });
  937. this.resets();
  938. },
  939. render() {
  940. const formItemLayout = {
  941. labelCol: { span: 8 },
  942. wrapperCol: { span: 14 }
  943. };
  944. const FormItem = Form.Item;
  945. const { TabPane } = Tabs;
  946. const { TextArea } = Input;
  947. const { RangePicker } = DatePicker;
  948. return (
  949. <div className="user-content">
  950. <div className="content-title">
  951. <span>订单审核</span>
  952. </div>
  953. <div className="user-search">
  954. <Input
  955. placeholder="客户名称"
  956. style={{ width: "150px", marginBottom: "10px" }}
  957. value={this.state.customerName}
  958. onChange={e => {
  959. this.setState({ customerName: e.target.value });
  960. }}
  961. />
  962. <Input
  963. placeholder="订单编号"
  964. style={{ width: "150px" }}
  965. value={this.state.orderNoSearch}
  966. onChange={e => {
  967. this.setState({ orderNoSearch: e.target.value });
  968. }}
  969. />
  970. <span style={{ marginRight: "10px" }}>下单时间 :</span>
  971. <RangePicker
  972. value={[
  973. this.state.releaseDate[0]
  974. ? moment(this.state.releaseDate[0])
  975. : null,
  976. this.state.releaseDate[1]
  977. ? moment(this.state.releaseDate[1])
  978. : null
  979. ]}
  980. onChange={(data, dataString) => {
  981. this.setState({ releaseDate: dataString });
  982. }}
  983. />
  984. <Button
  985. type="primary"
  986. onClick={this.search}
  987. style={{ marginLeft: "10px" }}
  988. >
  989. 搜索
  990. </Button>
  991. <Button onClick={this.reset}>重置</Button>
  992. <div className="patent-table">
  993. <Spin spinning={this.state.loading}>
  994. <Table
  995. columns={this.state.columns}
  996. dataSource={this.state.dataSource}
  997. pagination={this.state.pagination}
  998. onRowClick={this.tableRowClick}
  999. />
  1000. </Spin>
  1001. </div>
  1002. <Modal
  1003. className="customeDetails"
  1004. footer=""
  1005. width="900px"
  1006. visible={this.state.visible}
  1007. onOk={this.visitOk}
  1008. onCancel={this.visitCancel}
  1009. >
  1010. <Tabs activeKey={this.state.activeKey} onChange={this.callback}>
  1011. <TabPane tab="订单详情" key="1">
  1012. <Form
  1013. layout="horizontal"
  1014. onSubmit={this.handleSubmit}
  1015. id="demand-form"
  1016. style={{ paddingBottom: "40px" }}
  1017. >
  1018. <Spin spinning={this.state.loading}>
  1019. <div className="clearfix">
  1020. <FormItem
  1021. className="half-item"
  1022. {...formItemLayout}
  1023. label="订单编号"
  1024. >
  1025. <span>{this.state.orderNo}</span>
  1026. </FormItem>
  1027. <FormItem
  1028. className="half-item"
  1029. {...formItemLayout}
  1030. label="合同编号"
  1031. >
  1032. <span>{this.state.contractNo}</span>
  1033. </FormItem>
  1034. <FormItem
  1035. className="half-item"
  1036. {...formItemLayout}
  1037. label="客户名称"
  1038. >
  1039. <span>{this.state.userName}</span>
  1040. </FormItem>
  1041. <FormItem
  1042. className="half-item"
  1043. {...formItemLayout}
  1044. label="合同签订时间"
  1045. >
  1046. <span>{this.state.signDate}</span>
  1047. </FormItem>
  1048. <FormItem
  1049. className="half-item"
  1050. {...formItemLayout}
  1051. label="流程状态"
  1052. >
  1053. <span>
  1054. {getProcessStatus(this.state.processStatus)}
  1055. </span>
  1056. </FormItem>
  1057. <FormItem
  1058. className="half-item"
  1059. {...formItemLayout}
  1060. label="结算状态"
  1061. >
  1062. <span>
  1063. {getLiquidationStatus(this.state.liquidationStatus)}
  1064. </span>
  1065. </FormItem>
  1066. <FormItem
  1067. className="half-item"
  1068. {...formItemLayout}
  1069. label="企业联系人"
  1070. >
  1071. <span>{this.state.contacts}</span>
  1072. </FormItem>
  1073. <FormItem
  1074. className="half-item"
  1075. {...formItemLayout}
  1076. label="联系人电话"
  1077. >
  1078. <span>{this.state.contactMobile}</span>
  1079. </FormItem>
  1080. <FormItem
  1081. className="half-item"
  1082. {...formItemLayout}
  1083. label="企业法人"
  1084. >
  1085. <span>{this.state.legalPerson}</span>
  1086. </FormItem>
  1087. <FormItem
  1088. className="half-item"
  1089. {...formItemLayout}
  1090. label="法人电话"
  1091. >
  1092. <span>{this.state.legalPersonTel}</span>
  1093. </FormItem>
  1094. <FormItem
  1095. className="half-item"
  1096. {...formItemLayout}
  1097. label="签单金额(万元)"
  1098. >
  1099. <span>{this.state.totalAmount}</span>
  1100. </FormItem>
  1101. <FormItem
  1102. className="half-item"
  1103. {...formItemLayout}
  1104. label="首付金额(万元)"
  1105. >
  1106. <span>{this.state.firstAmount}</span>
  1107. </FormItem>
  1108. <FormItem
  1109. className="half-item"
  1110. {...formItemLayout}
  1111. label="特批立项"
  1112. >
  1113. <span>{getApprovedState(this.state.approval)}</span>
  1114. </FormItem>
  1115. <FormItem
  1116. className="half-item"
  1117. {...formItemLayout}
  1118. label="已收款项(万元)"
  1119. >
  1120. <span>{this.state.settlementAmount}</span>
  1121. </FormItem>
  1122. <FormItem
  1123. className="half-item"
  1124. {...formItemLayout}
  1125. label="订单部门"
  1126. >
  1127. <span>{this.state.depName}</span>
  1128. </FormItem>
  1129. <div className="clearfix">
  1130. <FormItem
  1131. labelCol={{ span: 4 }}
  1132. wrapperCol={{ span: 16 }}
  1133. label="订单留言"
  1134. >
  1135. <p style={{ width: 500, wordWrap: "break-word" }}>
  1136. {this.state.orderRemarks}
  1137. </p>
  1138. </FormItem>
  1139. </div>
  1140. <div className="clearfix">
  1141. <FormItem
  1142. labelCol={{ span: 4 }}
  1143. wrapperCol={{ span: 18 }}
  1144. label="合同扫描件"
  1145. >
  1146. <Upload
  1147. className="demandDetailShow-upload"
  1148. listType="picture-card"
  1149. fileList={this.state.orgCodeUrl}
  1150. onPreview={file => {
  1151. this.setState({
  1152. previewImage: file.url || file.thumbUrl,
  1153. previewVisible: true
  1154. });
  1155. }}
  1156. ></Upload>
  1157. <Modal
  1158. maskClosable={false}
  1159. footer={null}
  1160. visible={this.state.previewVisible}
  1161. onCancel={() => {
  1162. this.setState({ previewVisible: false });
  1163. }}
  1164. >
  1165. <img
  1166. alt=""
  1167. style={{ width: "100%" }}
  1168. src={this.state.previewImage || ""}
  1169. />
  1170. </Modal>
  1171. <Button
  1172. style={{
  1173. float: "right",
  1174. marginRight: "140px",
  1175. marginTop: "20px"
  1176. }}
  1177. onClick={this.getOrderLog}
  1178. >
  1179. 查看订单日志
  1180. </Button>
  1181. </FormItem>
  1182. </div>
  1183. <div className="clearfix">
  1184. <FormItem
  1185. className="half-item"
  1186. {...formItemLayout}
  1187. label="订单负责人"
  1188. >
  1189. <span>{this.state.salesmanName}</span>
  1190. </FormItem>
  1191. <FormItem
  1192. className="half-item"
  1193. {...formItemLayout}
  1194. label="订单负责人电话"
  1195. >
  1196. <span>{this.state.salesmanMobile}</span>
  1197. </FormItem>
  1198. </div>
  1199. <div className="clearfix">
  1200. <FormItem
  1201. className="half-item"
  1202. {...formItemLayout}
  1203. label="财务负责人"
  1204. >
  1205. <span>{this.state.financeName}</span>
  1206. </FormItem>
  1207. <FormItem
  1208. className="half-item"
  1209. {...formItemLayout}
  1210. label="财务负责人电话"
  1211. >
  1212. <span>{this.state.financeMobile}</span>
  1213. </FormItem>
  1214. </div>
  1215. <div>
  1216. <span
  1217. style={{ marginLeft: "50px", fontSize: "20px" }}
  1218. >
  1219. 催款节点
  1220. </span>
  1221. {this.state.processStatus == 0 ? (
  1222. <Button
  1223. type="primary"
  1224. onClick={this.addcontact}
  1225. style={{
  1226. float: "right",
  1227. marginRight: "50px",
  1228. marginBottom: "15px"
  1229. }}
  1230. >
  1231. 添加催款节点
  1232. </Button>
  1233. ) : (
  1234. ""
  1235. )}
  1236. </div>
  1237. <div className="clearfix">
  1238. <Spin spinning={this.state.loading}>
  1239. <Form layout="horizontal" id="demand-form">
  1240. <Table
  1241. pagination={false}
  1242. columns={this.state.ContactsLists}
  1243. dataSource={this.state.contactList}
  1244. />
  1245. <Col
  1246. span={24}
  1247. offset={9}
  1248. style={{ marginTop: "15px" }}
  1249. ></Col>
  1250. </Form>
  1251. </Spin>
  1252. </div>
  1253. <div>
  1254. <span
  1255. style={{ marginLeft: "50px", fontSize: "20px" }}
  1256. >
  1257. 项目业务
  1258. </span>
  1259. {this.state.processStatus == 0 ? (
  1260. <Button
  1261. type="primary"
  1262. onClick={this.addDetailed}
  1263. style={{
  1264. float: "right",
  1265. marginRight: "50px",
  1266. marginBottom: "15px"
  1267. }}
  1268. >
  1269. 添加项目明细
  1270. </Button>
  1271. ) : (
  1272. ""
  1273. )}
  1274. </div>
  1275. <div className="patent-table">
  1276. <Spin spinning={this.state.loading}>
  1277. <Table
  1278. columns={this.state.columnsX}
  1279. dataSource={this.state.dataSourceX}
  1280. pagination={this.state.paginations}
  1281. onRowClick={this.tableRowClickX}
  1282. />
  1283. </Spin>
  1284. </div>
  1285. <div className="addSave" style={{ marginTop: "15px" }}>
  1286. <Button
  1287. type="primary"
  1288. onClick={this.examOk}
  1289. style={{ marginLeft: "200px" }}
  1290. htmlType="submit"
  1291. >
  1292. 通过
  1293. </Button>
  1294. <Button
  1295. type="primary"
  1296. onClick={this.examNo}
  1297. style={{ marginLeft: "50px" }}
  1298. htmlType="submit"
  1299. >
  1300. 驳回
  1301. </Button>
  1302. <Button
  1303. type="ghost"
  1304. onClick={this.visitCancel}
  1305. style={{ marginLeft: "50px" }}
  1306. >
  1307. 取消
  1308. </Button>
  1309. {/*<Button className='warn-button' type="primary" onClick={this.outsourcing} style={{marginLeft:"50px"}}>通过不走总部</Button>
  1310. <p className='hint'>提示:高于总部价格,费用个人承担!</p>*/}
  1311. </div>
  1312. </div>
  1313. </Spin>
  1314. </Form>
  1315. </TabPane>
  1316. <TabPane tab="外包(不走总部)" key="2">
  1317. <div className="clearfix">
  1318. <FormItem
  1319. className="half-item"
  1320. {...formItemLayout}
  1321. label={
  1322. <span>
  1323. <strong style={{ color: "#f00" }}>*</strong>外包公司
  1324. </span>
  1325. }
  1326. >
  1327. <Input
  1328. value={this.state.companyName}
  1329. onChange={e => {
  1330. this.setState({
  1331. companyName: e.target.value
  1332. });
  1333. }}
  1334. placeholder="请填写外包公司名称"
  1335. />
  1336. </FormItem>
  1337. <span className="tip">如多个公司,请用间隔</span>
  1338. </div>
  1339. <div className="clearfix">
  1340. <FormItem
  1341. className="half-item"
  1342. {...formItemLayout}
  1343. label={
  1344. <span>
  1345. <strong style={{ color: "#f00" }}>*</strong>单价(万元)
  1346. </span>
  1347. }
  1348. >
  1349. <Input
  1350. value={this.state.unitPrice}
  1351. onChange={e => {
  1352. this.setState({
  1353. unitPrice: e.target.value
  1354. });
  1355. }}
  1356. placeholder="请填写单价"
  1357. />
  1358. </FormItem>
  1359. </div>
  1360. <div className="clearfix">
  1361. <FormItem
  1362. className="half-item"
  1363. {...formItemLayout}
  1364. label={
  1365. <span>
  1366. <strong style={{ color: "#f00" }}>*</strong>数量(个)
  1367. </span>
  1368. }
  1369. >
  1370. <Input
  1371. value={this.state.unitNumber}
  1372. onChange={e => {
  1373. this.setState({
  1374. unitNumber: e.target.value
  1375. });
  1376. }}
  1377. placeholder="请填写数量"
  1378. />
  1379. </FormItem>
  1380. </div>
  1381. <div className="clearfix">
  1382. <FormItem
  1383. className="half-item"
  1384. {...formItemLayout}
  1385. label={
  1386. <span>
  1387. <strong style={{ color: "#f00" }}>*</strong>
  1388. 总金额(万元)
  1389. </span>
  1390. }
  1391. >
  1392. <Input
  1393. value={this.state.amount}
  1394. onChange={e => {
  1395. this.setState({
  1396. amount: e.target.value
  1397. });
  1398. }}
  1399. placeholder="请填写本次外包公司的价格"
  1400. />
  1401. </FormItem>
  1402. </div>
  1403. {/*<div className="clearfix">
  1404. <FormItem className="half-item"
  1405. {...formItemLayout}
  1406. label="上传协议文件" style={{height:"auto"}}>
  1407. <Upload header={{authorization: 'authorization-text'}} action={globalConfig.context + "/api/admin/outsourceOrg/uploadOutsourceFile"}
  1408. data={(e)=>{
  1409. return {
  1410. 'sign': e.name.substring(0,e.name.lastIndexOf("."))
  1411. }
  1412. }}
  1413. fileList={this.state.attachmentUrl}
  1414. onChange={(e)=>{
  1415. this.setState({attachmentUrl:e.fileList})
  1416. }}>
  1417. {this.state.attachmentUrl.length>1?null:<Button>
  1418. <Icon type="upload" /> 点击上传
  1419. </Button>}
  1420. </Upload>
  1421. <span className="tip" style={{display:"inline-block"}}>支持文件格式: doc,excel,ppt</span>
  1422. </FormItem>
  1423. </div>*/}
  1424. <div className="clearfix">
  1425. <FormItem
  1426. className="half-item"
  1427. style={{ height: "auto" }}
  1428. {...formItemLayout}
  1429. label={
  1430. <span>
  1431. <strong style={{ color: "#f00" }}>*</strong>备注
  1432. </span>
  1433. }
  1434. >
  1435. <TextArea
  1436. rows={4}
  1437. value={this.state.outsourceRemarks}
  1438. onChange={e => {
  1439. this.setState({
  1440. outsourceRemarks: e.target.value
  1441. });
  1442. }}
  1443. placeholder="请输入备注"
  1444. />
  1445. </FormItem>
  1446. </div>
  1447. <p
  1448. className="tip"
  1449. style={{
  1450. paddingBottom: "12px",
  1451. width: "240px",
  1452. marginLeft: "145px"
  1453. }}
  1454. >
  1455. 首次派单项目,需上传协议,第2次起,同项目,只需写外包公司
  1456. </p>
  1457. <div className="clearfix">
  1458. <FormItem
  1459. labelCol={{ span: 4 }}
  1460. wrapperCol={{ span: 18 }}
  1461. label={
  1462. <span>
  1463. <strong style={{ color: "#f00" }}>*</strong>
  1464. 合同/协议扫描件
  1465. <span style={{ color: "#f00" }}>(外包合同)</span>
  1466. </span>
  1467. }
  1468. >
  1469. <PicturesWall
  1470. fileList={this.getOrgCodeUrl}
  1471. pictureUrl={this.state.pictureUrl}
  1472. />
  1473. <p>请上传与外包公司签订的合同协议</p>
  1474. <p>图片建议:要清晰。</p>
  1475. </FormItem>
  1476. </div>
  1477. <div className="clearfix">
  1478. <div
  1479. style={{ display: "inline-black", textAlign: "center" }}
  1480. >
  1481. <Button type="primary" onClick={this.sureOut}>
  1482. 确认发起外包,不通过总部
  1483. </Button>
  1484. <p className="tip">提示:高于总部价格,费用个人承担</p>
  1485. </div>
  1486. </div>
  1487. </TabPane>
  1488. </Tabs>
  1489. </Modal>
  1490. <Modal
  1491. maskClosable={false}
  1492. visible={this.state.addnextVisible}
  1493. onOk={this.nextCancel}
  1494. onCancel={this.nextCancel}
  1495. confirmLoading={this.state.confirmLoading}
  1496. width="800px"
  1497. title={"项目任务详情"}
  1498. footer=""
  1499. className="admin-desc-content"
  1500. >
  1501. <Form layout="horizontal" id="demand-form">
  1502. <Spin spinning={this.state.loading}>
  1503. <div className="clearfix">
  1504. <FormItem
  1505. className="half-item"
  1506. {...formItemLayout}
  1507. label="项目名称"
  1508. >
  1509. <span>{this.state.commodityName}</span>
  1510. </FormItem>
  1511. <FormItem
  1512. className="half-item"
  1513. {...formItemLayout}
  1514. label="项目数量"
  1515. >
  1516. <span>{this.state.commodityQuantity}</span>
  1517. </FormItem>
  1518. <FormItem
  1519. className="half-item"
  1520. {...formItemLayout}
  1521. label="金额(万元)"
  1522. >
  1523. <span>{this.state.commodityPrice}</span>
  1524. </FormItem>
  1525. <FormItem
  1526. className="half-item"
  1527. {...formItemLayout}
  1528. label="主要项目"
  1529. >
  1530. <span>{getboutique(this.state.main)}</span>
  1531. </FormItem>
  1532. <div className="clearfix">
  1533. <FormItem
  1534. labelCol={{ span: 4 }}
  1535. wrapperCol={{ span: 16 }}
  1536. label="服务说明"
  1537. >
  1538. <span>{this.state.taskComment}</span>
  1539. </FormItem>
  1540. </div>
  1541. </div>
  1542. </Spin>
  1543. </Form>
  1544. </Modal>
  1545. <Modal
  1546. maskClosable={false}
  1547. visible={this.state.noVisible}
  1548. onOk={this.handleOk}
  1549. onCancel={this.noCancel}
  1550. width="400px"
  1551. title={"拒绝理由"}
  1552. footer=""
  1553. className="admin-desc-content"
  1554. confirmLoading={this.state.confirmLoading}
  1555. >
  1556. <Form layout="horizontal" id="demand-form">
  1557. <Spin spinning={this.state.loading}>
  1558. <div className="clearfix">
  1559. <FormItem
  1560. labelCol={{ span: 4 }}
  1561. wrapperCol={{ span: 16 }}
  1562. label="拒绝理由"
  1563. >
  1564. <Input
  1565. type="textarea"
  1566. placeholder="请输入拒绝理由"
  1567. rows={4}
  1568. value={this.state.reason}
  1569. onChange={e => {
  1570. this.setState({ reason: e.target.value });
  1571. }}
  1572. />
  1573. </FormItem>
  1574. </div>
  1575. <div className="clearfix">
  1576. <Button
  1577. className="cancel"
  1578. type="primary"
  1579. onClick={this.examOks}
  1580. style={{ marginLeft: "50px" }}
  1581. htmlType="submit"
  1582. loading={this.state.aloading}
  1583. >
  1584. 确定
  1585. </Button>
  1586. <Button
  1587. className="cancel"
  1588. type="ghost"
  1589. onClick={this.noCancel}
  1590. style={{ marginLeft: "50px" }}
  1591. >
  1592. 取消
  1593. </Button>
  1594. </div>
  1595. </Spin>
  1596. </Form>
  1597. </Modal>
  1598. <Modal
  1599. visible={this.state.rizhivisible}
  1600. className="admin-desc-content"
  1601. width="800px"
  1602. maskClosable={false}
  1603. title="订单日志"
  1604. footer={null}
  1605. onCancel={this.closeOrderLog}
  1606. >
  1607. <div className="patent-table">
  1608. <Spin spinning={this.state.loading}>
  1609. <Table
  1610. columns={this.state.columnsrizhi}
  1611. dataSource={this.state.dataSourcerizhi}
  1612. pagination={false}
  1613. />
  1614. </Spin>
  1615. </div>
  1616. </Modal>
  1617. </div>
  1618. </div>
  1619. );
  1620. }
  1621. })
  1622. );
  1623. export default IntentionCustomer;