Нет описания

liuzhangtu.js 37KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425
  1. $("#save_ssss").click(function() {
  2. partpaat()
  3. })
  4. var bigdataList = null;
  5. setTimeout(function() {
  6. partpaat($('#time1').val().split(' ~ ')[0],$('#time1').val().split(' ~ ')[1]);
  7. }, 3000);
  8. function partpaat(sd, ed) {
  9. var myCha = echarts.init(document.getElementById('cha'));
  10. var myChart = echarts.init(document.getElementById('chart'));
  11. var myChaaaa = echarts.init(document.getElementById('dback1'));
  12. var myChartaaa = echarts.init(document.getElementById('dback'));
  13. var myChaccc = echarts.init(document.getElementById('mold1'));
  14. var myChartbbb = echarts.init(document.getElementById('mold'));
  15. var myCharrr = echarts.init(document.getElementById('genre1'));
  16. var myCharteee = echarts.init(document.getElementById('genre'));
  17. var myChaqqq = echarts.init(document.getElementById('other1'));
  18. var myChartwww = echarts.init(document.getElementById('other'));
  19. var myChalll = echarts.init(document.getElementById('uction1'));
  20. var myChartppp = echarts.init(document.getElementById('uction'));
  21. var myChreti = echarts.init(document.getElementById('sippu1'));
  22. var myChreti1 = echarts.init(document.getElementById('sippu'));
  23. var myKouc = echarts.init(document.getElementById('siupi1'));
  24. var myKouc1 = echarts.init(document.getElementById('siupi'));
  25. var myKucot = echarts.init(document.getElementById('siupiac1'));
  26. var myKucot1 = echarts.init(document.getElementById('siupiac'));
  27. var myTou = echarts.init(document.getElementById('siyi1'));
  28. var myTou1 = echarts.init(document.getElementById('siyi'));
  29. var myRi = echarts.init(document.getElementById('siout1'));
  30. var myRi1 = echarts.init(document.getElementById('siout'));
  31. var myEkit = echarts.init(document.getElementById('seytio1'));
  32. var myEkit1 = echarts.init(document.getElementById('seytio'));
  33. $.ajax({
  34. type: "get",
  35. url: huayi.config.callcenter_url + "WOReport/GetBigdataList",
  36. async: true,
  37. dataType: "json",
  38. data: {
  39. stime: sd,
  40. endtime: ed,
  41. salesBase: $('#xiaoshou').val(), //销售基地
  42. product: $('#Product_Category').val(), //产品
  43. channel: $('#customer_taxPointDes').val(), //渠道类型
  44. area: $('#customer_comaddress').val(), //大区
  45. branch: $('#customer_legalName').val(), //分公司
  46. isEnd: $('#customer_exceed').val(),
  47. type: $('#styqu').val(), //反馈类型
  48. },
  49. success: function(data) {
  50. if(data.state.toLowerCase() == "success") {
  51. //bigdataList = data.rows;
  52. var con = data.rows;
  53. $('.my_numet').html(con.salesBase[0].number); //基地反馈统计
  54. $('.my_yer').html(con.salesBase[0].Lastyear);
  55. $('.my_moye').html(con.salesBase[0].Lastmonth);
  56. $('.ch_numet').html(con.product[0].number); //产品反馈统计
  57. $('.ch_yer').html(con.product[0].Lastyear);
  58. $('.ch_moye').html(con.product[0].Lastmonth);
  59. $('.qd_numet').html(con.channel[0].number); //渠道反馈统计
  60. $('.qd_yer').html(con.channel[0].Lastyear);
  61. $('.qd_moye').html(con.channel[0].Lastmonth);
  62. $('.gdz_numet').html(con.state[0].number); //工单统计
  63. $('.gdz_yer').html(con.state[0].Lastyear);
  64. $('.gdz_moye').html(con.state[0].Lastmonth);
  65. $('.cq_numet').html(con.overdue[0].number); //超期部门统计
  66. $('.cq_yer').html(con.overdue[0].Lastyear);
  67. $('.cq_moye').html(con.overdue[0].Lastmonth);
  68. $('.myd_numet').html(con.satisfaction[0].number); //满意度统计
  69. $('.myd_yer').html(con.satisfaction[0].Lastyear);
  70. $('.myd_moye').html(con.satisfaction[0].Lastmonth);
  71. var channel = con.channel.slice(1);
  72. var overdue = con.overdue.slice(1);
  73. var product = con.product.slice(1);
  74. var stateaa = con.state.slice(1);
  75. var satisfaction = con.satisfaction.slice(1);
  76. var type_data = con.salesBase.slice(1);
  77. // 聚到类型
  78. var type_data_ccc = [];
  79. var type_data_name_arry2 = [];
  80. $(channel).each(function(i, n) {
  81. //type_data_arry.push(n.name)
  82. //数据
  83. var type_data_obj2 = {};
  84. type_data_obj2.name = n.name;
  85. type_data_obj2.value = n.number;
  86. if(n.number!=0){
  87. type_data_ccc.push(type_data_obj2);
  88. }
  89. // type_data_ccc.push(type_data_obj2);
  90. //名称
  91. var type_data_name_obj2 = {};
  92. type_data_name_obj2 = n.name;
  93. if(type_data_name_obj2==$('#customer_taxPointDes').val()){
  94. type_data_name_arry2.splice(0,0,$('#customer_taxPointDes').val())
  95. }else{
  96. type_data_name_arry2.push(type_data_name_obj2);
  97. }
  98. })
  99. // 基地反馈
  100. var type_data_arry = [];
  101. var data_arr = type_data_arry.shift(0);
  102. var type_data_name_arry = [];
  103. $(type_data).each(function(i, n) {
  104. //type_data_arry.push(n.name)
  105. //数据
  106. var type_data_obj = {};
  107. type_data_obj.name = n.name;
  108. type_data_obj.value = n.number;
  109. if(n.number!=0){
  110. type_data_arry.push(type_data_obj);
  111. }
  112. // type_data_arry.push(type_data_obj);
  113. //名称
  114. var type_data_name_obj = {};
  115. type_data_name_obj = n.name;
  116. if(type_data_name_obj==$('#xiaoshou').val()){
  117. type_data_name_arry.splice(0,0,$('#xiaoshou').val())
  118. }else{
  119. type_data_name_arry.push(type_data_name_obj);
  120. }
  121. })
  122. // 产品类型
  123. var type_data_aaa = [];
  124. var type_data_name_arry1 = [];
  125. $(product).each(function(i, n) {
  126. //type_data_arry.push(n.name)
  127. //数据
  128. var type_data_obj1 = {};
  129. type_data_obj1.name = n.name;
  130. type_data_obj1.value = n.number;
  131. if(n.number!=0){
  132. type_data_aaa.push(type_data_obj1);
  133. }
  134. // type_data_aaa.push(type_data_obj1);
  135. //名称
  136. var type_data_name_obj1 = {};
  137. type_data_name_obj1 = n.name;
  138. if(type_data_name_obj1==$('#Product_Category').val()){
  139. type_data_name_arry1.splice(0,0,$('#Product_Category').val());
  140. }else{
  141. type_data_name_arry1.push(type_data_name_obj1);
  142. }
  143. })
  144. // 超期部门
  145. var type_data_bbb = [];
  146. var type_data_name_arry3 = [];
  147. $(overdue).each(function(i, n) {
  148. //type_data_arry.push(n.name)
  149. //数据
  150. var type_data_obj3 = {};
  151. type_data_obj3.name = n.name;
  152. type_data_obj3.value = n.number;
  153. if(n.number!=0){
  154. type_data_bbb.push(type_data_obj3);
  155. }
  156. // type_data_bbb.push(type_data_obj3);
  157. //名称
  158. var type_data_name_obj3 = {};
  159. type_data_name_obj3 = n.name;
  160. type_data_name_arry3.push(type_data_name_obj3);
  161. })
  162. // 满意度
  163. var type_data_nnn = [];
  164. var type_data_name_arry4 = [];
  165. $(satisfaction).each(function(i, n) {
  166. //type_data_arry.push(n.name)
  167. //数据
  168. var type_data_obj4 = {};
  169. type_data_obj4.name = n.name;
  170. type_data_obj4.value = n.number;
  171. if(n.number!=0){
  172. type_data_nnn.push(type_data_obj4);
  173. }
  174. // type_data_nnn.push(type_data_obj4);
  175. //名称
  176. var type_data_name_obj4 = {};
  177. type_data_name_obj4 = n.name;
  178. type_data_name_arry4.push(type_data_name_obj4);
  179. })
  180. // 工单
  181. var type_data_uuu = [];
  182. var type_data_name_arry5 = [];
  183. $(stateaa).each(function(i, n) {
  184. //type_data_arry.push(n.name)
  185. //数据
  186. var type_data_obj5 = {};
  187. type_data_obj5.name = n.name;
  188. type_data_obj5.value = n.number;
  189. if(n.number!=0){
  190. type_data_uuu.push(type_data_obj5);
  191. }
  192. // type_data_uuu.push(type_data_obj5);
  193. //名称
  194. var type_data_name_obj5 = {};
  195. type_data_name_obj5 = n.name;
  196. type_data_name_arry5.push(type_data_name_obj5);
  197. })
  198. myChart.setOption({
  199. color: ['#1852B5'],
  200. textStyle: {
  201. fontSize: 16 * getHeightScale,
  202. },
  203. tooltip: {
  204. "textStyle": {
  205. "fontSize": 16 * getHeightScale,
  206. }
  207. },
  208. xAxis: {
  209. data: type_data_name_arry, //["合计", "咨询", "投诉", "抽检", "建议及其他", ""], ["咨询", "投诉", "抽检", "建议", "合计"]
  210. axisLine: { //这是x轴文字颜色
  211. lineStyle: {
  212. color: "#FFFFFF",
  213. }
  214. },
  215. axisLabel: { //调整x轴的lable
  216. textStyle: {
  217. fontSize: 16 * getHeightScale // 让字体变大
  218. }
  219. }
  220. },
  221. yAxis: {
  222. splitLine: {    
  223. show: false  
  224. },
  225. axisLine: { //这是x轴文字颜色
  226. lineStyle: {
  227. color: "#000946",
  228. }
  229. },
  230. axisLabel: { //调整x轴的lable
  231. textStyle: {
  232. fontSize: 16 * getHeightScale // 让字体变大
  233. }
  234. }
  235. },
  236. series: [{
  237. name: '反馈类型统计',
  238. type: 'bar',
  239. x: 'center',
  240. // barGap:'2%', //两个柱子距离
  241. barWidth: 20 * getHeightScale,
  242. data: type_data_arry
  243. }]
  244. });
  245. myCha.setOption({
  246. textStyle: {
  247. fontSize: 16 * getHeightScale,
  248. },
  249. tooltip: {
  250. trigger: 'item',
  251. formatter: "{a} <br/>{b} : {c} ({d}%)"
  252. },
  253. series: [{
  254. name: '访问来源',
  255. type: 'pie',
  256. radius: '55%',
  257. center: ['50%', '60%'],
  258. data: type_data_arry,
  259. type_data_name_arry,
  260. label: {
  261. normal: {
  262. position: 'inner',
  263. show: false
  264. }
  265. },
  266. itemStyle: {
  267. emphasis: {
  268. shadowBlur: 10 * getHeightScale,
  269. shadowOffsetX: 0,
  270. shadowColor: 'rgba(0, 0, 0, 0.5)'
  271. },
  272. normal: {
  273. color: function(params) {
  274. //自定义颜色
  275. var colorList = [
  276. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  277. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  278. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  279. ];
  280. return colorList[params.dataIndex]
  281. }
  282. }
  283. }
  284. }]
  285. });
  286. myChartaaa.setOption({
  287. color: ['#1852B5'],
  288. textStyle: {
  289. fontSize: 16 * getHeightScale,
  290. },
  291. tooltip: {},
  292. xAxis: {
  293. splitNumber: 5,
  294. data: type_data_name_arry1, //["合计", "尿素", "复合肥", "水溶肥", "车用尿素", "三聚氰胺", "甲醇", "糖醇", "腐殖酸", "二甲醚", "糖醛", "液氨", "其他", ""],
  295. axisLine: { //这是x轴文字颜色
  296. lineStyle: {
  297. color: "#FFFFFF",
  298. }
  299. },
  300. axisLabel: { //调整x轴的lable
  301. textStyle: {
  302. fontSize: 16 * getHeightScale // 让字体变大
  303. }
  304. }
  305. },
  306. yAxis: {
  307. splitLine: {    
  308. show: false  
  309. },
  310. axisLine: { //这是x轴文字颜色
  311. lineStyle: {
  312. color: "#000946",
  313. }
  314. },
  315. axisLabel: { //调整x轴的lable
  316. textStyle: {
  317. fontSize: 16 * getHeightScale // 让字体变大
  318. }
  319. }
  320. },
  321. series: [{
  322. name: '产品类型统计',
  323. type: 'bar',
  324. barWidth: 20 * getHeightScale,
  325. data: type_data_aaa,
  326. }]
  327. });
  328. myChaaaa.setOption({
  329. textStyle: {
  330. fontSize: 16 * getHeightScale,
  331. },
  332. tooltip: {
  333. trigger: 'item',
  334. formatter: "{a} <br/>{b} : {c} ({d}%)"
  335. },
  336. series: [{
  337. name: '访问来源',
  338. type: 'pie',
  339. radius: '55%',
  340. center: ['50%', '60%'],
  341. data: type_data_aaa,
  342. type_data_name_arry1,
  343. label: {
  344. normal: {
  345. position: 'inner',
  346. show: false
  347. }
  348. },
  349. itemStyle: {
  350. emphasis: {
  351. shadowBlur: 10 * getHeightScale,
  352. shadowOffsetX: 0,
  353. shadowColor: 'rgba(0, 0, 0, 0.5)'
  354. },
  355. normal: {
  356. color: function(params) {
  357. //自定义颜色
  358. var colorList = [
  359. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  360. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  361. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  362. ];
  363. return colorList[params.dataIndex]
  364. }
  365. }
  366. }
  367. }]
  368. });
  369. myChartbbb.setOption({
  370. color: ['#1852B5'],
  371. textStyle: {
  372. fontSize: 16 * getHeightScale,
  373. },
  374. tooltip: {},
  375. xAxis: {
  376. data: type_data_name_arry2, //["合计", "总经销", "二级商", "种田大户", "农户", "化工客户", "公司员工", "其他"],
  377. axisLine: { //这是x轴文字颜色
  378. lineStyle: {
  379. color: "#FFFFFF",
  380. }
  381. },
  382. axisLabel: { //调整x轴的lable
  383. textStyle: {
  384. fontSize: 16 * getHeightScale // 让字体变大
  385. }
  386. }
  387. },
  388. yAxis: {
  389. splitLine: {    
  390. show: false  
  391. },
  392. axisLine: { //这是x轴文字颜色
  393. lineStyle: {
  394. color: "#000946",
  395. }
  396. },
  397. axisLabel: { //调整x轴的lable
  398. textStyle: {
  399. fontSize: 16 * getHeightScale // 让字体变大
  400. }
  401. }
  402. },
  403. series: [{
  404. name: '渠道类型统计',
  405. type: 'bar',
  406. barWidth: 20 * getHeightScale,
  407. data: type_data_ccc,
  408. }]
  409. });
  410. myChaccc.setOption({
  411. textStyle: {
  412. fontSize: 16 * getHeightScale,
  413. },
  414. tooltip: {
  415. trigger: 'item',
  416. formatter: "{a} <br/>{b} : {c} ({d}%)"
  417. },
  418. series: [{
  419. name: '渠道类型统计',
  420. type: 'pie',
  421. radius: '55%',
  422. center: ['50%', '60%'],
  423. data: type_data_ccc,
  424. type_data_name_arry2,
  425. label: {
  426. normal: {
  427. position: 'inner',
  428. show: false
  429. }
  430. },
  431. itemStyle: {
  432. emphasis: {
  433. shadowBlur: 10 * getHeightScale,
  434. shadowOffsetX: 0,
  435. shadowColor: 'rgba(0, 0, 0, 0.5)'
  436. },
  437. normal: {
  438. color: function(params) {
  439. //自定义颜色
  440. var colorList = [
  441. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  442. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  443. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  444. ];
  445. return colorList[params.dataIndex]
  446. }
  447. }
  448. }
  449. }]
  450. });
  451. myCharteee.setOption({
  452. color: ['#1852B5'],
  453. textStyle: {
  454. fontSize: 16 * getHeightScale,
  455. },
  456. xAxis: {
  457. data: type_data_name_arry3, // ["合计", "市场管理科", "呼叫中心", "车用尿素", ""],
  458. axisLine: { //这是x轴文字颜色
  459. lineStyle: {
  460. color: "#FFFFFF",
  461. }
  462. },
  463. axisLabel: { //调整x轴的lable
  464. textStyle: {
  465. fontSize: 16 * getHeightScale // 让字体变大
  466. }
  467. }
  468. },
  469. yAxis: {
  470. splitLine: {    
  471. show: false  
  472. },
  473. axisLine: { //这是x轴文字颜色
  474. lineStyle: {
  475. color: "#000946",
  476. }
  477. },
  478. axisLabel: { //调整x轴的lable
  479. textStyle: {
  480. fontSize: 16 * getHeightScale // 让字体变大
  481. }
  482. }
  483. },
  484. series: [{
  485. name: '超期部门统计',
  486. type: 'bar',
  487. barWidth: 20 * getHeightScale,
  488. data: type_data_bbb,
  489. }]
  490. });
  491. myCharrr.setOption({
  492. textStyle: {
  493. fontSize: 16 * getHeightScale,
  494. },
  495. tooltip: {
  496. trigger: 'item',
  497. formatter: "{a} <br/>{b} : {c} ({d}%)"
  498. },
  499. series: [{
  500. name: '超期部门统计',
  501. type: 'pie',
  502. radius: '55%',
  503. center: ['50%', '60%'],
  504. data: type_data_bbb,
  505. type_data_name_arry3,
  506. label: {
  507. normal: {
  508. position: 'inner',
  509. show: false
  510. }
  511. },
  512. itemStyle: {
  513. emphasis: {
  514. shadowBlur: 10 * getHeightScale,
  515. shadowOffsetX: 0,
  516. shadowColor: 'rgba(0, 0, 0, 0.5)'
  517. },
  518. normal: {
  519. color: function(params) {
  520. //自定义颜色
  521. var colorList = [
  522. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  523. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  524. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  525. ];
  526. return colorList[params.dataIndex]
  527. }
  528. }
  529. }
  530. }]
  531. });
  532. myChartwww.setOption({
  533. color: ['#1852B5'],
  534. textStyle: {
  535. fontSize: 16 * getHeightScale,
  536. },
  537. tooltip: {},
  538. xAxis: {
  539. data: type_data_name_arry4, //["合计", "非常满意", "满意", "一般", "不满意", ""],
  540. axisLine: { //这是x轴文字颜色
  541. lineStyle: {
  542. color: "#FFFFFF",
  543. }
  544. },
  545. axisLabel: { //调整x轴的lable
  546. textStyle: {
  547. fontSize: 16 * getHeightScale // 让字体变大
  548. }
  549. }
  550. },
  551. yAxis: {
  552. splitLine: {    
  553. show: false  
  554. },
  555. axisLine: { //这是x轴文字颜色
  556. lineStyle: {
  557. color: "#000946",
  558. }
  559. },
  560. axisLabel: { //调整x轴的lable
  561. textStyle: {
  562. fontSize: 16 * getHeightScale // 让字体变大
  563. }
  564. }
  565. },
  566. series: [{
  567. name: '满意度统计',
  568. type: 'bar',
  569. barWidth: 20 * getHeightScale,
  570. data: type_data_nnn,
  571. }]
  572. });
  573. myChaqqq.setOption({
  574. tooltip: {
  575. trigger: 'item',
  576. formatter: "{a} <br/>{b} : {c} ({d}%)"
  577. },
  578. series: [{
  579. name: '满意度统计',
  580. type: 'pie',
  581. radius: '55%',
  582. center: ['50%', '60%'],
  583. data: type_data_nnn,
  584. type_data_name_arry4,
  585. label: {
  586. normal: {
  587. position: 'inner',
  588. show: false
  589. }
  590. },
  591. itemStyle: {
  592. emphasis: {
  593. shadowBlur: 10 * getHeightScale,
  594. shadowOffsetX: 0,
  595. shadowColor: 'rgba(0, 0, 0, 0.5)'
  596. },
  597. normal: {
  598. color: function(params) {
  599. //自定义颜色
  600. var colorList = [
  601. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  602. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  603. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  604. ];
  605. return colorList[params.dataIndex]
  606. }
  607. }
  608. }
  609. }]
  610. });
  611. myChartppp.setOption({
  612. color: ['#1852B5'],
  613. textStyle: {
  614. fontSize: 16 * getHeightScale,
  615. },
  616. tooltip: {},
  617. xAxis: {
  618. data: type_data_name_arry5,
  619. axisLine: { //这是x轴文字颜色
  620. lineStyle: {
  621. color: "#FFFFFF",
  622. }
  623. },
  624. axisLabel: { //调整x轴的lable
  625. textStyle: {
  626. fontSize: 16 * getHeightScale // 让字体变大
  627. }
  628. }
  629. },
  630. yAxis: {
  631. splitLine: {    
  632. show: false  
  633. },
  634. axisLine: { //这是x轴文字颜色
  635. lineStyle: {
  636. color: "#000946",
  637. }
  638. },
  639. axisLabel: { //调整x轴的lable
  640. textStyle: {
  641. fontSize: 16 * getHeightScale // 让字体变大
  642. }
  643. }
  644. },
  645. series: [{
  646. name: '工单',
  647. type: 'bar',
  648. barWidth: 20 * getHeightScale,
  649. data: type_data_uuu,
  650. }]
  651. });
  652. myChalll.setOption({
  653. textStyle: {
  654. fontSize: 16 * getHeightScale,
  655. },
  656. tooltip: {
  657. trigger: 'item',
  658. formatter: "{a} <br/>{b} : {c} ({d}%)"
  659. },
  660. series: [{
  661. name: '访问来源',
  662. type: 'pie',
  663. radius: '55%',
  664. center: ['50%', '60%'],
  665. data: type_data_uuu,
  666. type_data_name_arry5,
  667. label: {
  668. normal: {
  669. position: 'inner',
  670. show: false
  671. }
  672. },
  673. itemStyle: {
  674. emphasis: {
  675. shadowBlur: 10 * getHeightScale,
  676. shadowOffsetX: 0,
  677. shadowColor: 'rgba(0, 0, 0, 0.5)'
  678. },
  679. normal: {
  680. color: function(params) {
  681. //自定义颜色
  682. var colorList = [
  683. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  684. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  685. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  686. ];
  687. return colorList[params.dataIndex]
  688. }
  689. },
  690. }
  691. }]
  692. });
  693. myKouc1.setOption({
  694. color: ['#1852B5'],
  695. title: {
  696. text: '基地反馈统计',
  697. x: 'center',
  698. textStyle: {
  699. "color": "#53FEC0",
  700. fontSize: 24 * getHeightScale,
  701. }
  702. },
  703. textStyle: {
  704. fontSize: 14 * getHeightScale,
  705. },
  706. tooltip: {},
  707. xAxis: {
  708. data: type_data_name_arry, //["合计", "咨询", "投诉", "抽检", "建议及其他", ""], ["咨询", "投诉", "抽检", "建议", "合计"]
  709. axisLine: { //这是x轴文字颜色
  710. lineStyle: {
  711. color: "#FFFFFF",
  712. }
  713. },
  714. axisLabel: { //调整x轴的lable
  715. textStyle: {
  716. fontSize: 16 * getHeightScale // 让字体变大
  717. }
  718. }
  719. },
  720. yAxis: {
  721. splitLine: {    
  722. show: false  
  723. },
  724. axisLine: { //这是x轴文字颜色
  725. lineStyle: {
  726. color: "#FFFFFF",
  727. }
  728. },
  729. axisLabel: { //调整x轴的lable
  730. textStyle: {
  731. fontSize: 16 * getHeightScale // 让字体变大
  732. }
  733. }
  734. },
  735. dataZoom: [{
  736. show: false, //是否显示下方滚动条
  737. realtime: true,
  738. start: 0, //显示数据开始位置
  739. end: 50 //显示数据结束位置
  740. },
  741. {
  742. type: 'inside',
  743. realtime: true,
  744. start: 0,
  745. end: 50
  746. }
  747. ],
  748. series: [{
  749. name: '基地反馈统计',
  750. type: 'bar',
  751. x: 'center',
  752. // barGap:'2%', //两个柱子距离
  753. barWidth: 20 * getHeightScale,
  754. data: type_data_arry
  755. }]
  756. });
  757. myKouc.setOption({
  758. textStyle: {
  759. fontSize: 16 * getHeightScale,
  760. },
  761. tooltip: {
  762. trigger: 'item',
  763. formatter: "{a} <br/>{b} : {c} ({d}%)"
  764. },
  765. series: [{
  766. name: '基地反馈统计',
  767. type: 'pie',
  768. radius: '40%',
  769. center: ['50%', '60%'],
  770. data: type_data_arry,
  771. type_data_name_arry,
  772. itemStyle: {
  773. emphasis: {
  774. shadowBlur: 10 * getHeightScale,
  775. shadowOffsetX: 0,
  776. shadowColor: 'rgba(0, 0, 0, 0.5)'
  777. },
  778. normal: {
  779. color: function(params) {
  780. //自定义颜色
  781. var colorList = [
  782. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  783. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  784. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  785. ];
  786. return colorList[params.dataIndex]
  787. }
  788. }
  789. }
  790. }]
  791. });
  792. myKucot1.setOption({
  793. color: ['#1852B5'],
  794. title: {
  795. text: '产品类型统计',
  796. x: 'center',
  797. textStyle: {
  798. "color": "#53FEC0",
  799. fontSize: 24 * getHeightScale,
  800. }
  801. },
  802. textStyle: {
  803. fontSize: 16 * getHeightScale,
  804. },
  805. tooltip: {},
  806. xAxis: {
  807. splitNumber: 5,
  808. data: type_data_name_arry1, //["合计", "尿素", "复合肥", "水溶肥", "车用尿素", "三聚氰胺", "甲醇", "糖醇", "腐殖酸", "二甲醚", "糖醛", "液氨", "其他", ""],
  809. axisLine: { //这是x轴文字颜色
  810. lineStyle: {
  811. color: "#FFFFFF",
  812. }
  813. },
  814. axisLabel: { //调整x轴的lable
  815. textStyle: {
  816. fontSize: 16 * getHeightScale // 让字体变大
  817. }
  818. }
  819. },
  820. yAxis: {
  821. splitLine: {    
  822. show: false  
  823. },
  824. axisLine: { //这是x轴文字颜色
  825. lineStyle: {
  826. color: "#FFFFFF",
  827. }
  828. },
  829. axisLabel: { //调整x轴的lable
  830. textStyle: {
  831. fontSize: 16 * getHeightScale // 让字体变大
  832. }
  833. }
  834. },
  835. dataZoom: [{
  836. show: false, //是否显示下方滚动条
  837. realtime: true,
  838. start: 0, //显示数据开始位置
  839. end: 50 //显示数据结束位置
  840. },
  841. {
  842. type: 'inside',
  843. realtime: true,
  844. start: 0,
  845. end: 50
  846. }
  847. ],
  848. series: [{
  849. name: '产品类型统计',
  850. type: 'bar',
  851. barWidth: 20 * getHeightScale,
  852. data: type_data_aaa,
  853. }]
  854. });
  855. myKucot.setOption({
  856. textStyle: {
  857. fontSize: 16 * getHeightScale,
  858. },
  859. tooltip: {
  860. trigger: 'item',
  861. formatter: "{a} <br/>{b} : {c} ({d}%)"
  862. },
  863. series: [{
  864. name: '产品类型统计',
  865. type: 'pie',
  866. radius: '40%',
  867. center: ['50%', '60%'],
  868. data: type_data_aaa,
  869. type_data_name_arry1,
  870. itemStyle: {
  871. emphasis: {
  872. shadowBlur: 10 * getHeightScale,
  873. shadowOffsetX: 0,
  874. shadowColor: 'rgba(0, 0, 0, 0.5)'
  875. },
  876. normal: {
  877. color: function(params) {
  878. //自定义颜色
  879. var colorList = [
  880. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  881. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  882. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  883. ];
  884. return colorList[params.dataIndex]
  885. }
  886. }
  887. }
  888. }]
  889. });
  890. myTou1.setOption({
  891. color: ['#1852B5'],
  892. title: {
  893. text: '渠道类型统计',
  894. x: 'center',
  895. textStyle: {
  896. "color": "#53FEC0",
  897. fontSize: 24 * getHeightScale,
  898. }
  899. },
  900. textStyle: {
  901. fontSize: 16 * getHeightScale,
  902. },
  903. tooltip: {},
  904. xAxis: {
  905. data: type_data_name_arry2, //["合计", "总经销", "二级商", "种田大户", "农户", "化工客户", "公司员工", "其他"],
  906. axisLine: { //这是x轴文字颜色
  907. lineStyle: {
  908. color: "#FFFFFF",
  909. }
  910. },
  911. axisLabel: { //调整x轴的lable
  912. textStyle: {
  913. fontSize: 16 * getHeightScale // 让字体变大
  914. }
  915. }
  916. },
  917. yAxis: {
  918. splitLine: {    
  919. show: false  
  920. },
  921. axisLine: { //这是x轴文字颜色
  922. lineStyle: {
  923. color: "#FFFFFF",
  924. }
  925. },
  926. axisLabel: { //调整x轴的lable
  927. textStyle: {
  928. fontSize: 16 * getHeightScale // 让字体变大
  929. }
  930. }
  931. },
  932. dataZoom: [{
  933. show: false, //是否显示下方滚动条
  934. realtime: true,
  935. start: 0, //显示数据开始位置
  936. end: 150 //显示数据结束位置
  937. },
  938. {
  939. type: 'inside',
  940. realtime: true,
  941. start: 0,
  942. end: 50
  943. }
  944. ],
  945. series: [{
  946. name: '渠道类型统计',
  947. type: 'bar',
  948. barWidth: 20 * getHeightScale,
  949. data: type_data_ccc,
  950. }]
  951. });
  952. myTou.setOption({
  953. textStyle: {
  954. fontSize: 16 * getHeightScale,
  955. },
  956. tooltip: {
  957. trigger: 'item',
  958. formatter: "{a} <br/>{b} : {c} ({d}%)"
  959. },
  960. series: [{
  961. name: '渠道类型统计',
  962. type: 'pie',
  963. radius: '40%',
  964. center: ['50%', '60%'],
  965. data: type_data_ccc,
  966. type_data_name_arry2,
  967. itemStyle: {
  968. emphasis: {
  969. shadowBlur: 10 * getHeightScale,
  970. shadowOffsetX: 0,
  971. shadowColor: 'rgba(0, 0, 0, 0.5)'
  972. },
  973. normal: {
  974. color: function(params) {
  975. //自定义颜色
  976. var colorList = [
  977. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  978. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  979. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  980. ];
  981. return colorList[params.dataIndex]
  982. }
  983. }
  984. }
  985. }]
  986. });
  987. myRi1.setOption({
  988. color: ['#1852B5'],
  989. title: {
  990. text: '超期部门统计',
  991. x: 'center',
  992. textStyle: {
  993. "color": "#53FEC0",
  994. fontSize: 24 * getHeightScale,
  995. }
  996. },
  997. textStyle: {
  998. fontSize: 16 * getHeightScale,
  999. },
  1000. tooltip: {},
  1001. xAxis: {
  1002. data: type_data_name_arry3, // ["合计", "市场管理科", "呼叫中心", "车用尿素", ""],
  1003. axisLine: { //这是x轴文字颜色
  1004. lineStyle: {
  1005. color: "#FFFFFF",
  1006. }
  1007. },
  1008. axisLabel: { //调整x轴的lable
  1009. textStyle: {
  1010. fontSize: 16 * getHeightScale // 让字体变大
  1011. }
  1012. }
  1013. },
  1014. yAxis: {
  1015. splitLine: {    
  1016. show: false  
  1017. },
  1018. axisLine: { //这是x轴文字颜色
  1019. lineStyle: {
  1020. color: "#FFFFFF",
  1021. }
  1022. },
  1023. axisLabel: { //调整x轴的lable
  1024. textStyle: {
  1025. fontSize: 16 * getHeightScale // 让字体变大
  1026. }
  1027. }
  1028. },
  1029. dataZoom: [{
  1030. show: false, //是否显示下方滚动条
  1031. realtime: true,
  1032. start: 0, //显示数据开始位置
  1033. end: 50 //显示数据结束位置
  1034. },
  1035. {
  1036. type: 'inside',
  1037. realtime: true,
  1038. start: 0,
  1039. end: 50
  1040. }
  1041. ],
  1042. series: [{
  1043. name: '超期部门统计',
  1044. type: 'bar',
  1045. barWidth: 20 * getHeightScale,
  1046. data: type_data_bbb,
  1047. }]
  1048. });
  1049. myRi.setOption({
  1050. textStyle: {
  1051. fontSize: 16 * getHeightScale,
  1052. },
  1053. tooltip: {
  1054. trigger: 'item',
  1055. formatter: "{a} <br/>{b} : {c} ({d}%)"
  1056. },
  1057. series: [{
  1058. name: '超期部门统计',
  1059. type: 'pie',
  1060. radius: '40%',
  1061. center: ['50%', '60%'],
  1062. data: type_data_bbb,
  1063. type_data_name_arry3,
  1064. itemStyle: {
  1065. emphasis: {
  1066. shadowBlur: 10,
  1067. shadowOffsetX: 0,
  1068. shadowColor: 'rgba(0, 0, 0, 0.5)'
  1069. },
  1070. normal: {
  1071. color: function(params) {
  1072. //自定义颜色
  1073. var colorList = [
  1074. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  1075. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  1076. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  1077. ];
  1078. return colorList[params.dataIndex]
  1079. }
  1080. }
  1081. }
  1082. }]
  1083. });
  1084. myEkit1.setOption({
  1085. color: ['#1852B5'],
  1086. title: {
  1087. text: '满意度统计',
  1088. x: 'center',
  1089. textStyle: {
  1090. "color": "#53FEC0",
  1091. fontSize: 24 * getHeightScale,
  1092. }
  1093. },
  1094. textStyle: {
  1095. fontSize: 16 * getHeightScale,
  1096. },
  1097. tooltip: {},
  1098. xAxis: {
  1099. data: type_data_name_arry4, //["合计", "非常满意", "满意", "一般", "不满意", ""],
  1100. axisLine: { //这是x轴文字颜色
  1101. lineStyle: {
  1102. color: "#FFFFFF",
  1103. }
  1104. },
  1105. axisLabel: { //调整x轴的lable
  1106. textStyle: {
  1107. fontSize: 16 * getHeightScale // 让字体变大
  1108. }
  1109. }
  1110. },
  1111. yAxis: {
  1112. splitLine: {    
  1113. show: false  
  1114. },
  1115. axisLine: { //这是x轴文字颜色
  1116. lineStyle: {
  1117. color: "#FFFFFF",
  1118. }
  1119. },
  1120. axisLabel: { //调整x轴的lable
  1121. textStyle: {
  1122. fontSize: 16 * getHeightScale // 让字体变大
  1123. }
  1124. }
  1125. },
  1126. dataZoom: [{
  1127. show: false, //是否显示下方滚动条
  1128. realtime: true,
  1129. start: 0, //显示数据开始位置
  1130. end: 300 //显示数据结束位置
  1131. },
  1132. {
  1133. type: 'inside',
  1134. realtime: true,
  1135. start: 0,
  1136. end: 50
  1137. }
  1138. ],
  1139. series: [{
  1140. name: '满意度统计',
  1141. type: 'bar',
  1142. barWidth: 20 * getHeightScale,
  1143. data: type_data_nnn,
  1144. }]
  1145. });
  1146. myEkit.setOption({
  1147. textStyle: {
  1148. fontSize: 16 * getHeightScale,
  1149. },
  1150. tooltip: {
  1151. trigger: 'item',
  1152. formatter: "{a} <br/>{b} : {c} ({d}%)"
  1153. },
  1154. series: [{
  1155. name: '满意度统计',
  1156. type: 'pie',
  1157. radius: '40%',
  1158. center: ['50%', '60%'],
  1159. data: type_data_nnn,
  1160. type_data_name_arry4,
  1161. itemStyle: {
  1162. emphasis: {
  1163. shadowBlur: 10,
  1164. shadowOffsetX: 0,
  1165. shadowColor: 'rgba(0, 0, 0, 0.5)'
  1166. },
  1167. normal: {
  1168. color: function(params) {
  1169. //自定义颜色
  1170. var colorList = [
  1171. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  1172. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  1173. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  1174. ];
  1175. return colorList[params.dataIndex]
  1176. }
  1177. }
  1178. }
  1179. }]
  1180. });
  1181. myChreti1.setOption({
  1182. color: ['#1852B5'],
  1183. title: {
  1184. text: '工单总量统计',
  1185. x: 'center',
  1186. textStyle: {
  1187. "color": "#53FEC0",
  1188. fontSize: 24 * getHeightScale,
  1189. }
  1190. },
  1191. tooltip: {},
  1192. legend: {},
  1193. xAxis: [{
  1194. data: type_data_name_arry5,
  1195. axisLine: { //这是x轴文字颜色
  1196. lineStyle: {
  1197. color: "#FFFFFF",
  1198. }
  1199. },
  1200. axisLabel: { //调整x轴的lable
  1201. textStyle: {
  1202. fontSize: 16 * getHeightScale // 让字体变大
  1203. }
  1204. }
  1205. }],
  1206. yAxis: {
  1207. splitLine: {    
  1208. show: false  
  1209. },
  1210. axisLine: { //这是x轴文字颜色
  1211. lineStyle: {
  1212. color: "#FFFFFF",
  1213. }
  1214. },
  1215. axisLabel: { //调整x轴的lable
  1216. textStyle: {
  1217. fontSize: 16 * getHeightScale // 让字体变大
  1218. }
  1219. }
  1220. },
  1221. dataZoom: [{
  1222. show: false, //是否显示下方滚动条
  1223. realtime: true,
  1224. start: 0, //显示数据开始位置
  1225. end: 50 //显示数据结束位置
  1226. },
  1227. {
  1228. type: 'inside',
  1229. realtime: true,
  1230. start: 0,
  1231. end: 50
  1232. }
  1233. ],
  1234. series: [{
  1235. name: '工单总量统计',
  1236. type: 'bar',
  1237. barWidth: 20 * getHeightScale,
  1238. data: type_data_uuu,
  1239. }]
  1240. });
  1241. myChreti.setOption({
  1242. textStyle: {
  1243. fontSize: 16 * getHeightScale,
  1244. },
  1245. tooltip: {
  1246. trigger: 'item',
  1247. formatter: "{a} <br/>{b} : {c} ({d}%)"
  1248. },
  1249. series: [{
  1250. name: '工单总量统计',
  1251. type: 'pie',
  1252. radius: '40%',
  1253. center: ['50%', '60%'],
  1254. data: type_data_uuu,
  1255. type_data_name_arry5,
  1256. itemStyle: {
  1257. emphasis: {
  1258. shadowBlur: 10 * getHeightScale,
  1259. shadowOffsetX: 0,
  1260. shadowColor: 'rgba(0, 0, 0, 0.5)'
  1261. },
  1262. normal: {
  1263. color: function(params) {
  1264. //自定义颜色
  1265. var colorList = [
  1266. '#1890FF', '#2EC25B', '#FACC14', '#04D9FF', '#8543E0', '#13C2C2',
  1267. '#00C0FF', '#05EB78', '#D141D9', '#05EB61', '#2FCDCD', '#BEEB30',
  1268. '#EB9005', '#FFFF00', '#FF7F50', '#3CB371', '#00BFFF', '#9932CC',
  1269. ];
  1270. return colorList[params.dataIndex]
  1271. }
  1272. }
  1273. }
  1274. }]
  1275. });
  1276. }
  1277. }
  1278. });
  1279. }
  1280. $(document).ready(function() {
  1281. DQQ($("#customer_comaddress")); //大区
  1282. XSJD($("#xiaoshou")); //销售基地
  1283. ZXCPMC($("#Product_Category")); //产品名称
  1284. ZXCPMC($("#product_name")); //三屏产品名称
  1285. QDLXX($("#customer_taxPointDes")); //渠道类型
  1286. XSJD($("#category")); //销售基地
  1287. });
  1288. //渠道类型
  1289. function QDLXX(obj) {
  1290. obj.empty();
  1291. obj.append('<option selected="selected" value="">渠道类型</option>');
  1292. $.getJSON(huayi.config.callcenter_url + "WOReport/GetDicValueListByFlag", {
  1293. // "token": $.cookie("token"),
  1294. flag: "QDLX",
  1295. }, function(data) {
  1296. if(data.state.toLowerCase() == "success") {
  1297. var content = data.data;
  1298. $(content).each(function(i, n) {
  1299. $("<option value='" + n.F_Name + "'>" + n.F_Name + "</option>").appendTo(obj);
  1300. })
  1301. }
  1302. })
  1303. }
  1304. //产品名称
  1305. function ZXCPMC(obj) {
  1306. obj.empty();
  1307. obj.append('<option selected="selected" value="">产品名称</option>');
  1308. $.getJSON(huayi.config.callcenter_url + "WOReport/GetDicValueListByFlag", {
  1309. // "token": $.cookie("token"),
  1310. flag: "CPZL",
  1311. }, function(data) {
  1312. if(data.state.toLowerCase() == "success") {
  1313. var content = data.data;
  1314. $(content).each(function(i, n) {
  1315. $("<option value='" + n.F_Name + "'>" + n.F_Name + "</option>").appendTo(obj);
  1316. })
  1317. }
  1318. })
  1319. }
  1320. //销售基地
  1321. function XSJD(obj) {
  1322. obj.empty();
  1323. obj.append('<option selected="selected" value="">基地</option>');
  1324. $.getJSON(huayi.config.callcenter_url + "WOReport/GetDicValueListByFlag", {
  1325. // "token": $.cookie("token"),
  1326. flag: "XSJD",
  1327. }, function(data) {
  1328. if(data.state.toLowerCase() == "success") {
  1329. var content = data.data;
  1330. $(content).each(function(i, n) {
  1331. $("<option value='" + n.F_Name + "'>" + n.F_Name + "</option>").appendTo(obj);
  1332. })
  1333. }
  1334. })
  1335. }
  1336. function DQQ(obj) {
  1337. obj.empty();
  1338. obj.append('<option selected="selected" value="">大区</option>');
  1339. $.getJSON(huayi.config.callcenter_url + "Department/GetList", {
  1340. // "token": $.cookie("token"),
  1341. F_Layer: 1,
  1342. }, function(data) {
  1343. if(data.state.toLowerCase() == "success") {
  1344. var content = data.data;
  1345. $(content).each(function(i, n) {
  1346. $("<option value='" + n.F_DeptId + "'>" + n.F_DeptName + "</option>").appendTo(obj);
  1347. })
  1348. }
  1349. })
  1350. }
  1351. function KEFENGONG(obj) {
  1352. obj.empty();
  1353. obj.append('<option selected="selected" value="">分公司</option>');
  1354. $.getJSON(huayi.config.callcenter_url + "Department/GetList", {
  1355. // "token": $.cookie("token"),
  1356. F_Layer: 2,
  1357. F_DeptName: $("#customer_comaddress").find("option:selected").text(),
  1358. }, function(data) {
  1359. if(data.state.toLowerCase() == "success") {
  1360. var content = data.data;
  1361. $(content).each(function(i, n) {
  1362. $("<option value='" + n.F_DeptId + "'>" + n.F_DeptName + "</option>").appendTo(obj);
  1363. })
  1364. }
  1365. })
  1366. }
  1367. $('#customer_comaddress').on('change', function() {
  1368. $.getJSON(huayi.config.callcenter_url + "Department/GetList", {
  1369. // "token": $.cookie("token"),
  1370. F_Layer: 2,
  1371. F_DeptName: $("#customer_comaddress").find("option:selected").text(),
  1372. }, function(data) {
  1373. if(data.state.toLowerCase() == "success") {
  1374. var content = data.data;
  1375. $(content).each(function(i, n) {
  1376. $("<option value='" + n.F_DeptId + "'>" + n.F_DeptName + "</option>").appendTo("#customer_legalName");
  1377. })
  1378. KEFENGONG($("#customer_legalName"));
  1379. }
  1380. })
  1381. });