Нет описания

customerListAdd.html 5.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <script src="../Script/Common/huayi.load.js"></script>
  6. <script src="../Script/Common/huayi.http.js"></script>
  7. <script src="../Script/Common/huayi.config.js"></script>
  8. <link rel="stylesheet" href="../css/jquery-ui.css" />
  9. <link rel="stylesheet" href="../css/tpkerjqui.css" />
  10. <link rel="stylesheet" href="../css/timePicker.css" />
  11. <link rel="stylesheet" href="../css/plugins/awesome-bootstrap-checkbox/awesome-bootstrap-checkbox.css">
  12. <link rel="stylesheet" href="../css/stty.css" />
  13. <link rel="stylesheet" href="../css/init.css" />
  14. <link rel="stylesheet" type="text/css" href="../js/bootstrap-treeview/bootstrap-treeview.min.css" />
  15. <title>添加任务</title>
  16. <style>
  17. .page-title {
  18. padding: 0px;
  19. font-size: 16px;
  20. font-weight: bold;
  21. letter-spacing: -1px;
  22. display: block;
  23. color: #1570A6;
  24. margin: 20px 0px 15px 0px;
  25. }
  26. hr {
  27. margin: 20px 0;
  28. border: 0;
  29. border-top: 1px solid #E0DFDF;
  30. border-bottom: 1px solid #FEFEFE;
  31. }
  32. .bjCon {
  33. padding-top: 20px;
  34. /*border: 1px solid #e5e5e5;
  35. border-top: 0;*/
  36. }
  37. .bjright table td input {
  38. padding-left: 30px;
  39. }
  40. .tub {
  41. position: absolute;
  42. left: 18px;
  43. top: 13px;
  44. font-size: 18px;
  45. color: #ccc;
  46. }
  47. .ui-datepicker.ui-widget-content {
  48. background: none !important;
  49. background-color: #eee !important;
  50. }
  51. .ui-widget-header .ui-icon {
  52. background-image: url(../img/ui-icons_444444_256x240.png) !important;
  53. }
  54. .box {
  55. width: 55%;
  56. margin: 0 auto;
  57. margin-top: 5%;
  58. }
  59. .box .btop {
  60. height: 35px;
  61. background: #1ab394;
  62. color: #fff;
  63. line-height: 35px;
  64. padding: 0 15px;
  65. /* margin-bottom: 15px; */
  66. }
  67. .btl {
  68. float: left;
  69. margin: 0;
  70. }
  71. .btr {
  72. float: right;
  73. margin: 0;
  74. cursor: pointer;
  75. }
  76. .boxCon {
  77. width: 100%;
  78. min-height: 400px;
  79. background: #fff;
  80. text-align: center;
  81. padding: 10px 15px;
  82. height: auto;
  83. overflow-y: scroll;
  84. }
  85. .select_ {
  86. width: 150px;
  87. background-color: #FFF;
  88. background-image: none;
  89. border: 1px solid #ccc;
  90. border-radius: 1px;
  91. color: inherit;
  92. padding: 6px 12px;
  93. outline: none;
  94. vertical-align: middle;
  95. margin-top: 20px;
  96. margin-right: 20px;
  97. }
  98. .tool {
  99. margin: 20px 0;
  100. }
  101. .searchbox input {
  102. width: 99%;
  103. height: 98%;
  104. border: 0;
  105. outline: none;
  106. padding-left: 10px;
  107. }
  108. .secon {
  109. width: 100%;
  110. height: 34px;
  111. margin-bottom: 15px;
  112. }
  113. .secl {
  114. width: 65%;
  115. display: inline-block;
  116. height: 100%;
  117. margin: 0;
  118. border: 1px solid #eee;
  119. }
  120. </style>
  121. </head>
  122. <body>
  123. <form class="container-fluid" enctype="multipart/form-data">
  124. <div class="row-fluid clearfix">
  125. <div class="tool clearfix">
  126. <div class="searchbox col-sm-2">
  127. <div class="secon">
  128. <b>号码:</b>
  129. <p class="secl"><input type="text" placeholder="号码" class="phone" /></p>
  130. </div>
  131. </div>
  132. </div>
  133. </div>
  134. <p style="text-align: center; padding: 20px 0;">
  135. <button class="btns sureCun" type="button">保存</button>
  136. <a class="btns" id="return">取消</a>
  137. </p>
  138. </form>
  139. <script src="../js/jquery-ui.js"></script>
  140. <script src="../js/timePicker.js"></script>
  141. <!--<script src="../js/ajaxfileupload.js"></script>-->
  142. <script src="../dianXiao/js/jquery.form.min.js"></script>
  143. <script src="../js/bootstrap-treeview/bootstrap-treeview.min.js"></script>
  144. <script>
  145. var token = $.cookie("token");
  146. $(document).ready(function() {
  147. //取消
  148. $('#return').click(function () {
  149. var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
  150. parent.layer.close(index); //再执行关闭
  151. });
  152. $.ajax({
  153. type:"get",
  154. url: huayi.config.callcenter_url + 'Customer/GetCustomerField',
  155. async:true,
  156. dataType:'json',
  157. data:{
  158. token: token,
  159. },
  160. success:function(res){
  161. if(res.state.toLowerCase()=='success'){
  162. $('.tool').html('');
  163. var nameList=res.data.namelist,
  164. headList=res.data.headlist;
  165. $(nameList).each(function(i,n){
  166. $('<div class="searchbox col-sm-3">'+
  167. '<div class="secon">'+
  168. '<b>'+headList[i] +':</b>'+
  169. '<p class="secl"><input type="text" class="phone" name="'+n+'"/></p>'+
  170. '</div>'+
  171. '</div>').appendTo('.tool')
  172. })
  173. }
  174. }
  175. });
  176. $('.sureCun').click(function() {
  177. $(".container-fluid")
  178. .attr("method", "post")
  179. .attr("action", huayi.config.callcenter_url + "Customer/AddCustomer")
  180. .attr("enctype", "multipart/form-data");
  181. $(".container-fluid").ajaxSubmit({
  182. dataType: "json",
  183. data: {
  184. // deptid: $("#department").attr('data-id'),
  185. token: token
  186. },
  187. success: function(res) {
  188. //debugger;
  189. if(res.state.toLowerCase() == "success") {
  190. var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
  191. parent.layer.close(index); //再执行关闭
  192. parent.layer.msg(res.message);
  193. parent.initTable();
  194. } else {
  195. layer.msg(res.message);
  196. }
  197. }
  198. });
  199. })
  200. })
  201. </script>
  202. </body>
  203. </html>